/* ============================================================
   کانتینر اصلی
   ============================================================ */
#wcpc-form {
    direction: rtl;
    text-align: right;
    font-family: Tahoma, Arial, sans-serif;
    margin: 0 0 15px 0;
    padding: 0;
}

/* ============================================================
   هر مرحله — Accordion
   ============================================================ */
.wcpc-step-block {
    background: #fff;
    border: 1px solid #e0e0e0;
    border-radius: 10px;
    margin-bottom: 12px;
    overflow: hidden;
    transition: all .3s ease;
    box-shadow: 0 1px 3px rgba(0,0,0,.04);
}
.wcpc-step-block.wcpc-active {
    border-color: #2271b1;
    box-shadow: 0 2px 8px rgba(34,113,177,.15);
}
.wcpc-step-block.wcpc-done {
    border-color: #4caf50;
    background: #f7fdf9;
}
.wcpc-step-block.wcpc-locked {
    opacity: .5;
    pointer-events: none;
    background: #f9f9f9;
}

/* ─── هدر مرحله ─── */
.wcpc-step-head {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 15px;
    background: #f8f9fa;
    border-bottom: 1px solid transparent;
    cursor: pointer;
    user-select: none;
    transition: background .2s;
}
.wcpc-step-block.wcpc-active .wcpc-step-head {
    background: #eaf3fb;
    border-bottom-color: #d0e3f0;
}
.wcpc-step-block.wcpc-done .wcpc-step-head {
    background: #e8f5ec;
    border-bottom-color: #c7e6d0;
}

.wcpc-step-num {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 26px;
    height: 26px;
    background: #ccc;
    color: #fff;
    border-radius: 50%;
    font-size: 12px;
    font-weight: 700;
    flex-shrink: 0;
    transition: all .3s;
}
.wcpc-step-block.wcpc-active .wcpc-step-num { background: #2271b1; }
.wcpc-step-block.wcpc-done   .wcpc-step-num { background: #4caf50; }

.wcpc-step-title {
    flex: 1;
    font-size: 14px;
    font-weight: 700;
    color: #333;
}
.wcpc-step-status {
    font-size: 12px;
    color: #888;
    font-weight: 500;
}
.wcpc-step-block.wcpc-done .wcpc-step-status {
    color: #4caf50;
}
.wcpc-step-block.wcpc-done .wcpc-step-status::before {
    content: "✓ ";
    font-weight: 700;
}

/* ─── بدنه مرحله ─── */
.wcpc-step-body {
    display: none;
    padding: 15px;
}
.wcpc-step-block.wcpc-active .wcpc-step-body,
.wcpc-step-block.wcpc-done   .wcpc-step-body {
    display: block;
}

/* ─── فوتر مرحله (دکمه بعدی) ─── */
.wcpc-step-footer {
    display: none;
    padding: 12px 15px;
    border-top: 1px dashed #e0e0e0;
    background: #fafbfc;
    text-align: left;
}
.wcpc-step-block.wcpc-active .wcpc-step-footer {
    display: block;
}
.wcpc-step-block.wcpc-done .wcpc-step-footer {
    display: none;
}
.wcpc-step-block:last-child .wcpc-step-footer {
    display: none;
}

/* ============================================================
   فیلد عددی
   ============================================================ */
.wcpc-field {
    margin-bottom: 14px;
}
.wcpc-field:last-child {
    margin-bottom: 0;
}
.wcpc-field-label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #333;
    margin-bottom: 6px;
}
.wcpc-req {
    color: #d63638;
    margin-right: 2px;
}
.wcpc-input-wrap {
    display: flex;
    align-items: center;
    gap: 8px;
}
.wcpc-num-input {
    flex: 1;
    height: 42px;
    padding: 0 14px;
    border: 1.5px solid #ddd;
    border-radius: 8px;
    background: #fff;
    font-size: 14px;
    font-family: inherit;
    color: #333;
    box-sizing: border-box;
    transition: all .2s;
    outline: none;
}
.wcpc-num-input:focus {
    border-color: #2271b1;
    box-shadow: 0 0 0 3px rgba(34,113,177,.1);
}
.wcpc-num-input.wcpc-error {
    border-color: #d63638;
    box-shadow: 0 0 0 3px rgba(214,54,56,.1);
}
.wcpc-unit {
    font-size: 13px;
    color: #666;
    font-weight: 500;
    white-space: nowrap;
    min-width: 30px;
    text-align: left;
}

/* ============================================================
   کارت‌های سلکت
   ============================================================ */
.wcpc-card-select {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}
@media (max-width: 500px) {
    .wcpc-card-select {
        grid-template-columns: 1fr;
    }
}
.wcpc-card-option {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    padding: 14px 12px;
    background: #fff;
    border: 2px solid #e0e0e0;
    border-radius: 10px;
    cursor: pointer;
    user-select: none;
    transition: all .2s ease;
    font-size: 14px;
    font-weight: 600;
    color: #555;
    position: relative;
    text-align: center;
}
.wcpc-card-option:hover {
    border-color: #2271b1;
    color: #2271b1;
    transform: translateY(-1px);
    box-shadow: 0 3px 10px rgba(34,113,177,.1);
}
.wcpc-card-option.wcpc-selected {
    border-color: #2271b1;
    background: linear-gradient(135deg, #eaf3fb, #f5faff);
    color: #2271b1;
    box-shadow: 0 4px 12px rgba(34,113,177,.2);
}
.wcpc-card-option.wcpc-error {
    border-color: #d63638;
}
.wcpc-card-check {
    display: none;
    align-items: center;
    justify-content: center;
    width: 20px;
    height: 20px;
    border-radius: 50%;
    background: #2271b1;
    color: #fff;
    flex-shrink: 0;
}
.wcpc-card-option.wcpc-selected .wcpc-card-check {
    display: inline-flex;
}
.wcpc-card-label {
    line-height: 1.3;
}

/* ============================================================
   دکمه‌ها
   ============================================================ */
.wcpc-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 10px 24px;
    background: #2271b1;
    color: #fff;
    border: 0;
    border-radius: 8px;
    font-size: 13px;
    font-weight: 700;
    font-family: inherit;
    cursor: pointer;
    transition: all .2s;
}
.wcpc-btn:hover {
    background: #135e96;
    transform: translateY(-1px);
    box-shadow: 0 4px 12px rgba(34,113,177,.25);
}
.wcpc-btn::after {
    content: "←";
    font-weight: 700;
    font-size: 15px;
}

/* ============================================================
   باکس نتیجه
   ============================================================ */
.wcpc-result {
    display: none;
    margin-top: 12px;
    border: 1px solid #b7dfc2;
    border-radius: 10px;
    overflow: hidden;
    background: #f0f9f2;
}

/* ============================================================
   خطا
   ============================================================ */
.wcpc-error-msg {
    color: #d63638;
    font-size: 12px;
    margin-top: 5px;
    font-weight: 500;
}