/* ================= صفحه رزروهای من ================= */
.bookings-container {
    padding: 30px 30px 60px;    
    max-width: 1400px;
    margin: 0 auto;
}

/* ================= بریدکرامب ================= */
.breadcrumb {
    margin-bottom: 25px;
    font-size: 0.85rem;
    color: var(--gray, #6b7280);
    display: flex;
    align-items: center;
    gap: 8px;
}

.breadcrumb .separator {
    font-size: 0.7rem;
    color: var(--border, #e5e7eb);
}

/* ================= هدر ================= */
.bookings-header {
    text-align: center;
    margin-bottom: 30px;
}

.bookings-title {
    font-size: 2rem;
    font-weight: 800;
    color: var(--dark, #1e1e1e);
    margin-bottom: 8px;
}

.bookings-subtitle {
    font-size: 1rem;
    color: var(--gray, #6b7280);
}

/* ================= تب‌ها ================= */
.bookings-tabs {
    display: flex;
    gap: 10px;
    justify-content: center;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.booking-tab {
    padding: 10px 24px;
    border: 2px solid var(--border, #e5e7eb);
    border-radius: 30px;
    background: white;
    color: var(--gray, #6b7280);
    font-weight: 600;
    font-size: 0.95rem;
    cursor: pointer;
    transition: all 0.2s;
}

.booking-tab:hover {
    border-color: var(--primary, #3396D3);
    color: var(--primary, #3396D3);
}

.booking-tab.active {
    background: var(--primary, #3396D3);
    color: white;
    border-color: var(--primary, #3396D3);
}

/* ================= لیست رزروها ================= */
.bookings-list {
    display: grid;
    gap: 20px;
    margin-bottom: 40px;
}

/* کارت رزرو */
.booking-card {
    background: white;
    border: 1px solid var(--border, #e5e7eb);
    border-radius: 20px;
    padding: 20px;
    transition: all 0.2s;
    margin-bottom: 10px;
}

.booking-card:hover {
    box-shadow: 0 10px 25px rgba(51, 150, 211, 0.1);
    border-color: var(--primary, #3396D3);
}

.booking-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px;
    flex-wrap: wrap;
    gap: 10px;
}

.booking-id {
    font-size: 0.85rem;
    color: var(--gray, #6b7280);
    background: var(--light, #f9fafb);
    padding: 4px 10px;
    border-radius: 20px;
    direction: ltr;
    display: inline-block;
}

.booking-status {
    padding: 5px 15px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

/* ---------- وضعیت‌های واقعی رزرو (۶ حالت) ---------- */
.status-pending {     /* 0: در انتظار پرداخت */
    background: #fff3cd;
    color: #856404;
}
.status-confirmed {   /* 1: تایید شده */
    background: #dbeafe;
    color: #1e3a8a;
}
.status-started {     /* 2: شروع شده - تحویل داده شده */
    background: #d1fae5;
    color: #065f46;
}
.status-completed {   /* 3: پایان یافته */
    background: #f3f4f6;
    color: #374151;
}
.status-cancelled {   /* 4: لغو شده */
    background: #fee2e2;
    color: #991b1b;
}
.status-expired {     /* 6: منقضی شده */
    background: #e5e7eb;
    color: #111827;
}

/* کلاس قدیمی paid تبدیل به confirmed */
.status-paid {
    background: #dbeafe;
    color: #1e3a8a;
}
/* کلاس قدیمی failed حذف شده چون دیگر نداریم */

.booking-body {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: 15px;
    margin-bottom: 15px;
}

.booking-image {
    width: 80px;
    height: 80px;
    border-radius: 12px;
    overflow: hidden;
    background: var(--light, #f9fafb);
}

.booking-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.booking-info h3 {
    font-size: 1.1rem;
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--dark, #1e1e1e);
}

.booking-meta {
    display: flex;
    gap: 15px;
    flex-wrap: wrap;
    font-size: 0.9rem;
    color: var(--gray, #6b7280);
}

.booking-meta i {
    color: var(--primary, #3396D3);
    margin-left: 4px;
}

.booking-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-top: 15px;
    padding-top: 15px;
    border-top: 1px solid var(--border, #e5e7eb);
}

.booking-price {
    font-size: 1.2rem;
    font-weight: 800;
    color: var(--primary, #3396D3);
}

.booking-actions {
    display: flex;
    gap: 10px;
}

.btn-pay {
    padding: 8px 16px;
    background: #d1fae5;
    border: 1px solid #a7f3d0;
    border-radius: 8px;
    color: #065f46;
    font-size: 0.9rem;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}
.btn-pay:hover {
    background: #a7f3d0;
    border-color: #10b981;
}

/* تایمر شمارش معکوس پرداخت */
.timer-badge {
    font-weight: bold;
    color: #065f46;          /* سبز تیره */
    background-color: #d1fae5;
    padding: 4px 8px;
    border-radius: 4px;
    font-family: monospace;
    margin-left: 10px;
    display: inline-block;
    min-width: 50px;
    text-align: center;
}

/* دکمه‌های عملیات */
.btn-details {
    padding: 8px 16px;
    background: var(--light, #f9fafb);
    border: 1px solid var(--border, #e5e7eb);
    border-radius: 8px;
    color: var(--dark, #1e1e1e);
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.btn-details:hover {
    background: white;
    border-color: var(--primary, #3396D3);
    color: var(--primary, #3396D3);
}

.btn-cancel {
    padding: 8px 16px;
    background: #fee2e2;
    border: 1px solid #fecaca;
    border-radius: 8px;
    color: #b91c1c;
    font-size: 0.9rem;
    cursor: pointer;
    transition: all 0.2s;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.btn-cancel:hover {
    background: #fecaca;
    border-color: #ef4444;
    color: #991b1b;
}

.btn-cancel:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

/* ================= حالت‌های صفحه ================= */
.state-box {
    text-align: center;
    padding: 80px 20px;
    background: #fff;
    border-radius: 20px;
    border: 1px solid var(--border, #e5e7eb);
    margin: 40px auto;
    max-width: 600px;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid var(--border, #e5e7eb);
    border-top-color: var(--primary, #3396D3);
    border-radius: 50%;
    margin: 0 auto 20px;
    animation: spin 1s infinite linear;
}

@keyframes spin {
    100% {
        transform: rotate(360deg);
    }
}

.error-state i,
.empty-state i,
.access-denied i {
    font-size: 4rem;
    margin-bottom: 20px;
}

.error-state i {
    color: #ef4444;
}

.error-state h3 {
    color: #b91c1c;
    margin-bottom: 15px;
    font-size: 1.5rem;
}

.empty-state i {
    color: var(--gray, #6b7280);
}

.empty-state h3 {
    color: var(--dark, #1e1e1e);
    margin-bottom: 15px;
}

.access-denied i {
    color: #f59e0b;
}

.access-denied h3 {
    color: #b45309;
    margin-bottom: 15px;
}

.btn-retry,
.btn-primary,
.btn-outline {
    display: inline-block;
    padding: 12px 30px;
    border-radius: 8px;
    font-size: 1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s;
    text-decoration: none;
    border: none;
}

.btn-retry,
.btn-primary {
    background: var(--primary, #3396D3);
    color: white;
}

.btn-retry:hover,
.btn-primary:hover {
    background: var(--primary-hover, #2a73a8);
    transform: translateY(-2px);
    box-shadow: 0 5px 15px rgba(51, 150, 211, 0.3);
}

.btn-retry {
    margin-top: 20px;
}

.btn-outline {
    background: white;
    color: var(--primary, #3396D3);
    border: 2px solid var(--primary, #3396D3);
}

.btn-outline:hover {
    background: var(--primary, #3396D3);
    color: white;
}

/* ================= صفحه‌بندی ================= */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 8px;
    margin-top: 40px;
    flex-wrap: wrap;
}

.page-btn {
    min-width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #fff;
    border: 1px solid var(--border, #e5e7eb);
    border-radius: 8px;
    font-size: 0.9rem;
    color: var(--dark, #1e1e1e);
    cursor: pointer;
    transition: all 0.2s;
    padding: 0 10px;
}

.page-btn:hover:not(.active):not(.disabled) {
    background: var(--light, #f9fafb);
    border-color: var(--primary, #3396D3);
    color: var(--primary, #3396D3);
}

.page-btn.active {
    background: var(--primary, #3396D3);
    border-color: var(--primary, #3396D3);
    color: #fff;
    cursor: default;
}

.page-btn.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

/* ================= مودال ================= */
.booking-modal {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 2000;
    backdrop-filter: blur(4px);
}

.booking-modal .modal-content {
    background: white;
    border-radius: 20px;
    max-width: 500px;
    width: 90%;
    max-height: 80vh;
    overflow-y: auto;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.2);
}

.modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    border-bottom: 1px solid var(--border, #e5e7eb);
}

.modal-header h3 {
    margin: 0;
    color: var(--dark, #1e1e1e);
}

.close-modal {
    background: none;
    border: none;
    font-size: 1.5rem;
    cursor: pointer;
    color: var(--gray, #6b7280);
    transition: color 0.2s;
    width: 30px;
    height: 30px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.close-modal:hover {
    background: var(--light, #f9fafb);
    color: var(--dark, #1e1e1e);
}

.modal-body {
    padding: 20px;
}

.modal-actions {
    display: flex;
    gap: 10px;
    margin-top: 20px;
}

.cancel-modal .warning-text {
    color: #b91c1c;
    font-size: 0.9rem;
    margin: 10px 0;
    text-align: center;
}

/* ================= جزئیات رزرو ================= */
.booking-detail-item {
    display: flex;
    margin-bottom: 15px;
    padding: 10px;
    background: var(--light, #f9fafb);
    border-radius: 10px;
}

.booking-detail-label {
    width: 120px;
    font-weight: 600;
    color: var(--gray, #6b7280);
}

.booking-detail-value {
    flex: 1;
    color: var(--dark, #1e1e1e);
}

.booking-detail-value.id {
    direction: ltr;
    font-family: monospace;
    background: white;
    padding: 10px;
    border-radius: 20px;
}

/* ================= ریسپانسیو ================= */
@media (max-width: 768px) {
    .bookings-container {
        padding: 0 20px;
    }

    .bookings-title {
        font-size: 1.8rem;
    }

    .booking-tab {
        padding: 8px 16px;
        font-size: 0.85rem;
    }

    .booking-body {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .booking-meta {
        justify-content: center;
    }

    .booking-footer {
        flex-direction: column;
        gap: 15px;
        align-items: flex-start;
    }

    .booking-actions {
        width: 100%;
        justify-content: space-between;
    }
}

@media (max-width: 480px) {
    .bookings-title {
        font-size: 1.5rem;
    }

    .booking-header {
        flex-direction: column;
        align-items: flex-start;
    }

    .booking-meta {
        flex-direction: column;
        gap: 8px;
        align-items: center;
    }

    .booking-actions {
        flex-direction: column;
        gap: 8px;
    }

    .btn-details,
    .btn-cancel {
        width: 100%;
        justify-content: center;
    }

    .modal-actions {
        flex-direction: column;
    }

    .modal-actions button {
        width: 100%;
    }
}
/* ================= گزارش خرابی ================= */
.video-url-row {
    display: flex;
    gap: 10px;
    margin-bottom: 8px;
    align-items: center;
}
.video-url-row .form-control {
    flex: 1;
}
.remove-video-btn {
    background: none;
    border: 1px solid #ddd;
    border-radius: 6px;
    padding: 5px 10px;
    cursor: pointer;
    color: #666;
}
.remove-video-btn:hover {
    background: #fee2e2;
    color: #b91c1c;
    border-color: #fecaca;
}
.btn-report {
    background: #fff3e0;
    border: 1px solid #ffb74d;
    color: #b45309;
    padding: 6px 12px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    display: inline-flex;
    align-items: center;
    gap: 4px;
    transition: all 0.2s;
}
.btn-report:hover {
    background: #ffb74d;
    color: #fff;
}
.btn-report:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

/* استایل‌های عمومی فرم داخل مودال (در صورت نیاز) */
.form-group {
    margin-bottom: 15px;
}
.form-group label {
    display: block;
    margin-bottom: 5px;
    font-weight: 600;
    color: var(--dark, #1e1e1e);
}
.form-control {
    width: 100%;
    padding: 10px 12px;
    border: 1px solid var(--border, #e5e7eb);
    border-radius: 8px;
    font-family: inherit;
    font-size: 0.9rem;
}
.required-star {
    color: #ef4444;
}
.msg-box {
    margin-top: 10px;
    padding: 10px;
    border-radius: 8px;
    font-size: 0.85rem;
}
.msg-box.error {
    background: #fee2e2;
    color: #b91c1c;
    border: 1px solid #fecaca;
}
.msg-box.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #bbf7d0;
}
.uploaded-files-list .uploaded-item {
    background: #f8f9fa;
    border-radius: 8px;
    padding: 8px 12px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    justify-content: space-between;
}
.uploaded-files-list .file-info {
    display: flex;
    align-items: center;
    gap: 10px;
    font-size: 0.9rem;
}
.uploaded-files-list .remove-upload {
    background: none;
    border: none;
    color: #dc3545;
    cursor: pointer;
    font-size: 1.2rem;
}
.progress-bar {
    transition: width 0.3s;
    background: #0d6efd;
    border-radius: 2px;
}