/* ============================================
   نیلا - استایل‌های سفارشی
   ============================================ */

@font-face {
    font-family: 'YekanBakh';
    src: url('../fonts/YekanBakh.woff') format('woff');
    font-weight: normal;
    font-style: normal;
    font-display: swap;
}

:root {
    --nila-primary: #03045E;
    --nila-light: #E8EDF5;
    --nila-hover: #020349;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'YekanBakh', 'Vazirmatn', sans-serif;
}




::-webkit-scrollbar {
    width: 6px;
}
::-webkit-scrollbar-track {
    background: #f1f1f1;
}
::-webkit-scrollbar-thumb {
    background: #03045E40;
    border-radius: 3px;
}

/* فیلدهای ورودی */
.input-field {
    width: 100%;
    padding: 12px 14px;
    border: 2px solid #e5e7eb;
    border-radius: 12px;
    font-size: 14px;
    font-family: 'Vazirmatn', sans-serif;
    transition: all 0.3s ease;
    background: #fafafa;
    color: #1f2937;
    outline: none;
    -webkit-appearance: none;
}

.input-field:focus {
    border-color: var(--nila-primary);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(3, 4, 94, 0.08);
}

.input-field::placeholder {
    color: #9ca3af;
    font-size: 13px;
}

.input-field.error {
    border-color: #ef4444;
    box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.08);
}

/* Select */
select.input-field {
    cursor: pointer;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%236b7280' d='M6 8L1 3h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: left 14px center;
    padding-left: 36px;
    -webkit-appearance: none;
    -moz-appearance: none;
    appearance: none;
}

/* دکمه اصلی */
.btn-primary {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    padding: 13px 24px;
    background: var(--nila-primary);
    color: #fff;
    border: none;
    border-radius: 12px;
    font-size: 14px;
    font-weight: 600;
    font-family: 'Vazirmatn', sans-serif;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 14px rgba(3, 4, 94, 0.25);
}

.btn-primary:hover:not(:disabled) {
    background: var(--nila-hover);
    box-shadow: 0 6px 20px rgba(3, 4, 94, 0.35);
    transform: translateY(-1px);
}

.btn-primary:active:not(:disabled) {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(3, 4, 94, 0.2);
}

.btn-primary:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    box-shadow: none;
}

/* فیلد OTP */
.otp-input {
    width: 52px;
    height: 58px;
    text-align: center;
    font-size: 24px;
    font-weight: 700;
    font-family: 'Vazirmatn', sans-serif;
    border: 2px solid #e5e7eb;
    border-radius: 14px;
    background: #fafafa;
    color: var(--nila-primary);
    outline: none;
    transition: all 0.3s ease;
    caret-color: var(--nila-primary);
}

.otp-input:focus {
    border-color: var(--nila-primary);
    background: #fff;
    box-shadow: 0 0 0 4px rgba(3, 4, 94, 0.08);
    transform: scale(1.05);
}

.otp-input.filled {
    border-color: var(--nila-primary);
    background: var(--nila-light);
}

.otp-input.error {
    border-color: #ef4444;
    animation: shake 0.5s ease;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    20%, 60% { transform: translateX(-4px); }
    40%, 80% { transform: translateX(4px); }
}

/* کارت بخش‌ها */
.dept-card {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 14px 16px;
    border: 2px solid #e5e7eb;
    border-radius: 14px;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #fafafa;
}

.dept-card:hover {
    border-color: #c5d0e8;
    background: #f0f4fa;
}

.dept-option input:checked + .dept-card {
    border-color: var(--nila-primary);
    background: var(--nila-light);
    box-shadow: 0 0 0 4px rgba(3, 4, 94, 0.08);
}

.dept-check {
    opacity: 0;
    transition: all 0.3s ease;
}

.dept-option input:checked + .dept-card .dept-check {
    opacity: 1;
}

/* ناحیه آپلود */
.upload-area {
    border: 2px dashed #d1d5db;
    border-radius: 14px;
    padding: 24px;
    text-align: center;
    cursor: pointer;
    transition: all 0.3s ease;
    background: #fafafa;
}

.upload-area:hover {
    border-color: #9ca3af;
    background: #f5f5f5;
}

.upload-area.drag-over {
    border-color: var(--nila-primary);
    background: var(--nila-light);
}

.upload-area.has-file {
    border-style: solid;
    border-color: var(--nila-primary);
    background: #f8f9fc;
}

.upload-placeholder {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}

.upload-preview {
    display: flex;
    flex-direction: column;
    align-items: center;
}

/* انیمیشن‌های مرحله */
.step-content {
    animation: fadeSlideIn 0.4s ease;
}

@keyframes fadeSlideIn {
    from {
        opacity: 0;
        transform: translateY(16px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* استپ‌ها */
.step-dot {
    display: flex;
    flex-direction: column;
    align-items: center;
    transition: all 0.3s ease;
}

.line-active {
    background: var(--nila-primary) !important;
}

.step-dot.active span {
    color: var(--nila-primary) !important;
}

.step-dot.completed span {
    color: var(--nila-primary) !important;
}

/* Toast */
#toast.show {
    opacity: 1;
    transform: translateX(-50%) translateY(0);
    pointer-events: auto;
}

/* لودینگ */
.btn-loader {
    display: inline-flex;
    align-items: center;
    gap: 6px;
}

/* خلاصه نوبت */
.summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 10px 0;
    border-bottom: 1px solid #e5e7eb;
}

.summary-row:last-child {
    border-bottom: none;
}

.summary-label {
    font-size: 12px;
    color: #9ca3af;
}

.summary-value {
    font-size: 13px;
    font-weight: 600;
    color: #1f2937;
}

/* واکنش‌گرایی */
@media (max-width: 480px) {
    .otp-input {
        width: 46px;
        height: 52px;
        font-size: 20px;
    }
    
    .dept-card {
        padding: 12px 14px;
    }

    .upload-area {
        padding: 16px;
    }
}
