
/* Prevent FullCalendar's default "past" styling from conflicting */
.fc-day-past {
    background-color: #f9fafb !important;
}


/* 1. FORCE THE GRID TO STAY VISIBLE */
#reschedule-calendar .fc-day, 
#schedule-calendar .fc-day {
    visibility: visible !important;
    display: table-cell !important; /* Forces the table layout */
    background-color: #ffffff;      /* Default background */
}

/* 2. STYLE THE "OFF" DAYS (Greyed out) */
.fc-day-disabled {
    background-color: #f9fafb !important; /* Very light grey */
    cursor: not-allowed !important;
    pointer-events: none !important;      /* Prevents clicking */
}

/* 3. MAKE THE NUMBERS FAINT ON OFF DAYS */
.fc-day-disabled .fc-daygrid-day-number {
    color: #d1d5db !important; /* Grey text */
    opacity: 0.6;
}

/* 4. STYLE WORKING DAYS */
.teacher-working-day {
    background-color: #ffffff !important;
    cursor: pointer !important;
}

/* 5. STYLE THE SELECTED DAY (The Blue Square) */
.v3-selected-day {
    background-color: #3b82f6 !important; /* Blue */
    border-radius: 4px;
}
.v3-selected-day .fc-daygrid-day-number {
    color: #ffffff !important; /* White text when selected */
}



/* Skeleton Overlay Container */
.calendar-skeleton-wrapper {
    position: relative;
    min-height: 300px;
}

.calendar-skeleton-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: white;
    z-index: 100;
    display: none; /* Hidden by default */
    grid-template-columns: repeat(7, 1fr);
    grid-template-rows: repeat(5, 1fr);
    gap: 1px;
    padding: 1px;
    border: 1px solid #e5e7eb;
}

/* Create the grid cells for the skeleton */
.calendar-skeleton-overlay::before {
    content: "";
    position: absolute;
    inset: 0;
    background-image: 
        linear-gradient(90deg, #f3f4f6 1px, transparent 1px),
        linear-gradient(180deg, #f3f4f6 1px, transparent 1px);
    background-size: 14.28% 20%;
}

/* The Shimmering Bar */
.calendar-shimmer {
    grid-column: 1 / -1;
    grid-row: 1 / -1;
    position: relative;
    overflow: hidden;
    background: #f9fafb;
}

.calendar-shimmer::after {
    content: "";
    position: absolute;
    top: 0;
    left: -150%;
    width: 150%;
    height: 100%;
    background: linear-gradient(
        to right,
        transparent 0%,
        rgba(255, 255, 255, 0.6) 50%,
        transparent 100%
    );
    animation: shimmer 1.5s infinite;
}

@keyframes shimmer {
    100% { left: 100%; }
}

/* Show state */
.calendar-loading .calendar-skeleton-overlay {
    display: grid;
}



/* FORCE THE CALENDAR GRID TO STAY VISIBLE */
#reschedule-calendar .fc-day, 
#schedule-calendar .fc-day {
    visibility: visible !important;
    display: table-cell !important;
    border: 1px solid #e2e8f0 !important; /* Force borders */
    background-color: #ffffff;
}

/* STYLE FOR DISABLED/OFF DAYS */
.fc-day-disabled {
    background-color: #f8fafc !important; /* Very light grey */
    cursor: not-allowed !important;
    pointer-events: none !important;
}

/* DATE NUMBERS ON DISABLED DAYS */
.fc-day-disabled .fc-daygrid-day-number {
    color: #cbd5e1 !important;
    opacity: 0.5;
}

/* SELECTED DAY (Blue Square) */
.v3-selected-day {
    background-color: #3b82f6 !important;
    border: 1px solid #2563eb !important;
    z-index: 5;
}

.v3-selected-day .fc-daygrid-day-number {
    color: #ffffff !important;
    font-weight: 800;
}

/* WORKING DAYS (Clickable) */
.teacher-working-day {
    cursor: pointer !important;
}

/* Ensure the split view fills the modal properly */
.modal-split-view {
    display: flex;
    gap: 20px;
    min-height: 400px;
}
#reschedule-step-1-date { flex: 1.2; }
.modal-time-side { flex: 0.8; border-left: 1px solid #f1f5f9; padding-left: 20px; }




/* 1. SKELETON WRAPPER */
.calendar-skeleton-wrapper {
    position: relative;
    min-height: 420px; /* Matches FullCalendar height */
}

/* 2. THE SKELETON OVERLAY */
.calendar-skeleton-overlay {
    position: absolute;
    top: 0; left: 0; right: 0; bottom: 0;
    background: #ffffff;
    z-index: 100;
    display: none; /* Hidden by default */
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    padding: 10px;
}

/* 3. THE SHIMMER GRID ANIMATION */
.calendar-shimmer-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    grid-template-rows: repeat(5, 1fr);
    gap: 10px;
    height: 100%;
    width: 100%;
}

.skeleton-cell {
    background: #f1f5f9;
    border-radius: 8px;
    position: relative;
    overflow: hidden;
}

.skeleton-cell::after {
    content: "";
    position: absolute;
    top: 0; left: -150%;
    width: 150%; height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.6), transparent);
    animation: calendar-shimmer-run 1.5s infinite linear;
}

@keyframes calendar-shimmer-run {
    0% { left: -150%; }
    100% { left: 150%; }
}

/* 4. SHOW STATE */
.calendar-loading .calendar-skeleton-overlay {
    display: block;
}





/* 1. Ensure 'Other Month' days are fully visible when selected */
.fc-day-other.v3-selected-day {
    opacity: 1 !important;
    background-color: #3b82f6 !important; /* Force the Blue */
}

.fc-day-other.v3-selected-day .fc-daygrid-day-number {
    color: #ffffff !important; /* Force the White text */
    opacity: 1 !important;
}

/* 2. Prevent FullCalendar from fading out the numbers on selection */
.v3-selected-day .fc-daygrid-day-number {
    color: #ffffff !important;
    font-weight: 800 !important;
}

/* 3. Keep the grid borders consistent even for other-month days */
.fc-day-other {
    background-color: #ffffff; /* Start white, don't let it be transparent */
}

/* 4. If an other-month day is disabled, make it grey but keep it visible */
.fc-day-other.fc-day-disabled {
    background-color: #f8fafc !important;
    opacity: 0.4 !important;
}






/* 1. FORCE "OTHER MONTH" DAYS TO BE SOLID WHEN SELECTED */
/* This stops the "fading" effect in your second screenshot */
#reschedule-calendar .fc-day-other.v3-selected-day,
#schedule-calendar .fc-day-other.v3-selected-day {
    background-color: #3b82f6 !important; /* Your Blue */
    opacity: 1 !important;
    visibility: visible !important;
}

/* 2. FORCE TEXT TO BE WHITE ON SELECTED OTHER-MONTH DAYS */
#reschedule-calendar .fc-day-other.v3-selected-day .fc-daygrid-day-number,
#schedule-calendar .fc-day-other.v3-selected-day .fc-daygrid-day-number {
    color: #ffffff !important;
    opacity: 1 !important;
}

/* 3. ENSURE OTHER-MONTH DAYS DON'T LOOK BLANK WHEN DISABLED */
/* This fixes the "empty white space" look */
.fc-day-other.fc-day-disabled {
    background-color: #f8fafc !important;
    opacity: 0.5 !important;
}

/* 4. MAINTAIN BORDERS REGARDLESS OF MONTH */
.fc-day-other {
    border: 1px solid #e2e8f0 !important;
    background-color: #ffffff;
}

/* 5. FIX THE DATE NUMBERS FOR NON-SELECTED OTHER DAYS */
/* They should be visible but grey, not invisible */
.fc-day-other .fc-daygrid-day-number {
   color: #000000 !important; /* Standard Success Green */
    opacity: 1 !important;
    font-weight: 800 !important;
}




/* Hide all loaders/spinners by default */
.v3-btn-loader, .spinner, .circle-loader {
    display: none;
}

/* Show them only when their parent is in a loading state */
.loading .v3-btn-loader, 
.loading .spinner,
.calendar-loading .calendar-skeleton-overlay {
    display: inline-block !important;
}

/* Ensure the success view is strictly hidden until the server responds */
#schedule-success-view, #reschedule-success-view {
    display: none;
}



/* Grey out and Disable Clicks */
.fc-day-disabled {
    background-color: #f8fafc !important; /* Light Grey */
    cursor: not-allowed !important;
    pointer-events: none !important;      /* This is key! */
}

/* Ensure borders stay visible so the grid doesn't disappear */
.fc-day {
    border: 1px solid #e2e8f0 !important;
}












[v-cloak] { display: none; }

.am-booking-container {
    display: flex;
    background: #fff;
    border-radius: 12px;
    overflow: hidden;
    min-height: 450px;
}

/* LEFT COLUMN */
.am-calendar-column {
    flex: 1.2;
    padding: 20px;
    border-right: 1px solid #f1f5f9;
}

/* RIGHT COLUMN */
.am-slots-column {
    flex: 0.8;
    padding: 20px;
    display: flex;
    flex-direction: column;
    background: #fafafa;
}

.am-slots-header {
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.am-slots-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    overflow-y: auto;
    max-height: 350px;
    padding-right: 5px;
}

/* THE PILLS */
.am-slot-pill {
    background: #fff;
    border: 1px solid #e2e8f0;
    border-radius: 8px;
    padding: 12px;
    font-size: 14px;
    font-weight: 600;
    color: #475569;
    cursor: pointer;
    transition: all 0.2s ease;
    text-align: center;
}

.am-slot-pill:hover {
    border-color: #3b82f6;
    color: #3b82f6;
}

.am-slot-pill.is-selected {
    background: #3b82f6;
    border-color: #3b82f6;
    color: #fff;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.3);
}

/* SKELETONS */
.am-slot-skeleton {
    height: 45px;
    background: #f1f5f9;
    border-radius: 8px;
    animation: am-shimmer 1.5s infinite linear;
}

@keyframes am-shimmer {
    0% { opacity: 1; } 50% { opacity: 0.5; } 100% { opacity: 1; }
}

/* MOBILE RESPONSIVENESS */
@media (max-width: 768px) {
    .am-booking-container { flex-direction: column; }
    .am-calendar-column { border-right: none; border-bottom: 1px solid #eee; }
    .am-slots-column { flex: 1; }
}



/* Package Detail Two-Column Layout */
.package-detail-grid {
    display: grid;
    grid-template-columns: 340px 1fr;
    gap: 30px;
    align-items: start;
    margin-top: 20px;
}

/* Left Side Sidebar Card */
.package-sidebar-card {
    background: #ffffff;
    border: 1px solid #eef2f6;
    border-radius: 24px;
    padding: 30px 24px;
    position: sticky;
    top: 100px;
  
}

.package-sidebar-teacher {
    text-align: center;
    margin-bottom: 25px;
}

.package-sidebar-teacher img {
    width: 90px;
    height: 90px;
    border-radius: 20px;
    object-fit: cover;
    margin-bottom: 15px;
    border: 3px solid #eff6ff;
}

.package-sidebar-teacher h4 {
    margin: 0;
    font-size: 18px;
    font-weight: 800;
    color: #1e293b;
}

/* Progress Section */
.package-stats-box {
    background: #f8fafc;
    border-radius: 18px;
    padding: 20px;
    margin-bottom: 25px;
}

.p-stat-row {
    display: flex;
    justify-content: space-between;
    margin-bottom: 12px;
    font-size: 14px;
    font-weight: 700;
}

.p-stat-row .label { color: #64748b; }
.p-stat-row .value { color: #1e293b; }

.package-progress-wrapper {
    height: 8px;
    background: #e2e8f0;
    border-radius: 10px;
    overflow: hidden;
    margin-top: 15px;
}

.package-progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #3b82f6, #60a5fa);
    border-radius: 10px;
    transition: width 1s ease-in-out;
}

/* Mobile Responsiveness */
@media (max-width: 1024px) {
    .package-detail-grid {
        grid-template-columns: 1fr;
    }
    .package-sidebar-card {
        position: static;
    }
}




/* ============================================================
   LOGICAL STATUS COLOR ENGINE
   ============================================================ */

/* 1. SCHEDULED (Blue - Default) */
.pro-lesson-card.status-scheduled .card-accent-border { background: #3b82f6; }
.pro-lesson-card.status-scheduled .status-pill { background: #eff6ff; color: #1d4ed8; }

/* 2. AWAITING RESPONSE (Amber/Orange) */
.pro-lesson-card.status-awaiting .card-accent-border { background: #f59e0b; }
.pro-lesson-card.status-awaiting .status-pill { background: #fffbeb; color: #b45309; }

/* 3. COMPLETED (Green) */
.pro-lesson-card.status-completed .card-accent-border { background: #10b981; }
.pro-lesson-card.status-completed .status-pill { background: #f0fdf4; color: #047857; }

/* 4. UNDER REVIEW / DISPUTED (Red) */
.pro-lesson-card.status-disputed .card-accent-border { background: #ef4444; }
.pro-lesson-card.status-disputed .status-pill { background: #fef2f2; color: #dc2626; }

/* 5. RESOLVED (Teal/Cyan) */
.pro-lesson-card.status-resolved .card-accent-border { background: #06b6d4; }
.pro-lesson-card.status-resolved .status-pill { background: #ecfeff; color: #0891b2; }

/* 6. CANCELED (Slate/Grey) */
.pro-lesson-card.status-canceled .card-accent-border { background: #94a3b8; }
.pro-lesson-card.status-canceled .status-pill { background: #f8fafc; color: #475569; }

/* 7. LIVE NOW (Pulsing Red) */
.pro-lesson-card.status-in-progress .card-accent-border { background: #ef4444; }
.pro-lesson-card.status-in-progress .status-pill { 
    background: #fee2e2; 
    color: #ef4444; 
    font-weight: 800;
    animation: status-pulse-red 2s infinite;
}

@keyframes status-pulse-red {
    0% { opacity: 1; }
    50% { opacity: 0.6; }
    100% { opacity: 1; }
}



/* Package Sidebar Detail Items */
.package-details-list {
    display: flex;
    flex-direction: column;
    gap: 15px;
    padding: 10px 5px;
    border-top: 1px solid #f1f5f9;
    padding-top: 20px;
}

.p-detail-item {
    display: flex;
    align-items: center;
    gap: 15px;
}

.p-detail-item i {
    width: 32px;
    height: 32px;
    background: #f8fafc;
    color: #3b82f6;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 14px;
    flex-shrink: 0;
}

.p-detail-info {
    display: flex;
    flex-direction: column;
}

.p-detail-info label {
    font-size: 11px;
    font-weight: 800;
    color: #94a3b8;
    text-transform: uppercase;
    line-height: 1;
    margin-bottom: 4px;
}

.p-detail-info span {
    font-size: 13px;
    font-weight: 700;
    color: #1e293b;
}




/* Sidebar Banners */
.p-status-banner {
    padding: 14px;
    border-radius: 14px;
    text-align: center;
    font-size: 14px;
    font-weight: 700;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
}
.banner-blue { background: #eff6ff; color: #1d4ed8; border: 1px solid #dbeafe; }
.banner-green { background: #f0fdf4; color: #166534; border: 1px solid #dcfce7; }

/* Sidebar Detail Rows */
.package-info-footer {
    margin-top: 25px;
    padding-top: 20px;
    border-top: 1px solid #f1f5f9;
    display: flex;
    flex-direction: column;
    gap: 15px;
}
.p-info-row { display: flex; align-items: center; gap: 12px; }
.p-info-row i { width: 28px; color: #94a3b8; font-size: 14px; }
.p-info-text { display: flex; flex-direction: column; }
.p-info-text label { font-size: 10px; font-weight: 800; color: #94a3b8; text-transform: uppercase; margin: 0; }
.p-info-text span { font-size: 13px; font-weight: 700; color: #1e293b; }


.p-badge-status {
    font-size: 9px;
    font-weight: 800;
    padding: 2px 8px;
    border-radius: 4px;
    margin-left: 10px;
    letter-spacing: 0.05em;
}
.p-badge-status.active { background: #dcfce7; color: #15803d; }
.p-badge-status.expired { background: #f1f5f9; color: #64748b; }
.package-expired { opacity: 0.8; border-left-color: #cbd5e1 !important; }



/* --- MORE ACTIONS DROPDOWN --- */
.p-action-row {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.btn-more-trigger {
    width: 50px;
    height: 50px;
    background: #ffffff;
    border: 1.5px solid #e2e8f0;
    border-radius: 14px;
    color: #64748b;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.btn-more-trigger:hover {
    background: #f8fafc;
    border-color: #cbd5e1;
    color: #1e293b;
}

/* Termination UI */
.termination-preview-box {
    background: #fef2f2;
    border: 1px solid #fee2e2;
    border-radius: 18px;
    padding: 20px;
    margin: 20px 0;
}

.t-math-row {
    display: flex;
    justify-content: space-between;
    font-size: 14px;
    margin-bottom: 8px;
    color: #991b1b;
}

.t-math-row.total {
    border-top: 1px solid #fecaca;
    padding-top: 10px;
    margin-top: 10px;
    font-weight: 800;
    font-size: 16px;
}

.termination-warning {
    display: flex;
    gap: 12px;
    background: #fff;
    padding: 15px;
    border-radius: 12px;
    border-left: 4px solid #ef4444;
    font-size: 13px;
    color: #4b5563;
}




.p-badge-status.terminated {
    background: #fee2e2; /* Red wash */
    color: #b91c1c;      /* Dark Red */
}

.package-terminated {
    border-left-color: #f87171 !important;
    opacity: 0.8;
    background-color: #fffafb !important;
}

.package-terminated .package-icon {
    background-color: #f87171 !important;
}



/* ============================================================
   PREMIUM PACKAGE DETAIL THEME
   ============================================================ */

/* 1. Sticky SaaS Header */
.package-view-header {
    position: sticky;
    top: 0;
    z-index: 1000;
    display: flex;
    align-items: center;
    gap: 15px;
    padding: 15px 5%;
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(12px);
    -webkit-backdrop-filter: blur(12px);
    border-bottom: 1px solid #f1f5f9;
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
    width: 100vw;
    box-sizing: border-box;
}

.package-view-header h2 {
    font-size: clamp(16px, 4vw, 24px) !important;
    font-weight: 850 !important;
    color: #0f172a;
    margin: 0;
    letter-spacing: -0.02em;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* 2. Grid Optimization */
.package-detail-grid {
    display: grid;
    grid-template-columns: 340px 1fr;
    gap: 30px;
    margin-top: 30px;
    align-items: start;
}

/* Sidebar Improvements */
.package-sidebar-card {
    background: #fff;
    border: 1px solid #eef2f6;
    border-radius: 24px;
    padding: 24px;
   
}

.teacher-squircle-wrap img {
    width: 80px; height: 80px; border-radius: 22px; 
    object-fit: cover; margin-bottom: 12px; border: 3px solid #f8fafc;
}

.instructor-badge {
    background: #eff6ff; color: #3b82f6; font-size: 10px; font-weight: 800;
    padding: 3px 10px; border-radius: 6px; text-transform: uppercase;
}

/* Stats Styling */
.package-stats-box { background: #f8fafc; padding: 20px; border-radius: 20px; margin: 20px 0; }
.p-stat-row { display: flex; justify-content: space-between; margin-bottom: 8px; font-size: 13px; font-weight: 700; }
.p-stat-row .label { color: #64748b; }
.progress-pct-label { font-size: 10px; font-weight: 800; color: #3b82f6; text-align: center; margin-top: 8px; }

/* Protection Policy Box */
.package-protection-box {
    background: #fffcf0; border: 1px solid #fef3c7; border-radius: 16px; padding: 15px; margin-bottom: 20px;
}
.package-protection-box label { font-size: 10px; font-weight: 800; color: #b45309; display: block; margin-bottom: 5px; }
.package-protection-box p { font-size: 11px; line-height: 1.5; color: #92400e; margin: 0; font-weight: 500; }

/* Banners */
.p-status-banner { padding: 12px; border-radius: 12px; font-size: 13px; font-weight: 700; text-align: center; margin-bottom: 20px; }
.banner-terminated { background: #fff1f2; color: #be123c; border: 1px solid #fecaca; }
.banner-expired { background: #f1f5f9; color: #64748b; border: 1px solid #e2e8f0; }

/* 3. Mobile Overrides */
@media (max-width: 1024px) {
    .package-detail-grid { grid-template-columns: 1fr; gap: 20px; }
    .package-view-header { padding: 12px 15px; }
    .package-sidebar-card { border-radius: 0; border-left: none; border-right: none; margin: -30px -1rem 0; }
    
    .package-main-content { padding: 0 5px; }
    .section-label-premium h3 { font-size: 12px !important; }
}

/* Timeline Polish */
.timeline-card-wrap { margin-top: 40px; padding: 20px 0; border-top: 1px solid #f1f5f9; }
.dot-red { background: #ef4444 !important; border-color: #ef4444 !important; }
.dot-grey { background: #64748b !important; border-color: #64748b !important; }
.bold-red { color: #b91c1c !important; font-weight: 800; }
.bold-dark { color: #1e293b !important; font-weight: 800; }












/* --- GLOBAL BACKGROUND LOGIC --- */
/* Gray for Dashboard and Package Details, White for Lesson Details only */
.view-gray-bg { 
    background-color: #f8fafc !important; /* Professional Slate Gray */
    min-height: 100vh;
}

/* Ensure the full width spans the screen */
#student-dashboard-container.view-gray-bg {
    margin-left: calc(-50vw + 50%);
    margin-right: calc(-50vw + 50%);
    padding-left: calc(50vw - 50%);
    padding-right: calc(50vw - 50%);
    width: 100vw;
}

/* Make the sticky header white so it stands out against the gray */
.package-view-header {
    background: rgba(255, 255, 255, 0.95) !important;
    border-bottom: 1px solid #e2e8f0;
}

/* Ensure cards remain white to "pop" off the gray */
.package-sidebar-card, 
.package-main-history .long-appointment-card,
.timeline-card-wrap,
.v3-card {
    background-color: #ffffff !important;
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.05), 0 2px 4px -1px rgba(0, 0, 0, 0.03) !important;
}

/* Mobile Full Screen Fixes */
@media (max-width: 768px) {
    .package-detail-grid {
        padding: 0 15px 40px; /* Space at bottom for scrolling */
    }
    .package-sidebar-card {
        border-radius: 0;
        margin: 0 -15px 20px; /* Pull to edges of mobile screen */
        border-left: none;
        border-right: none;
    }
}








/* --- GLOBAL SAAS BACKGROUND --- */
#student-dashboard-container.view-dashboard-active {
    background-color: #f8fafc !important; /* Soft Slate Gray */
    min-height: 100vh;
    padding-bottom: 60px;
}

/* --- THE WHITE CARD "POP" --- */
.package-sidebar-card, 
.package-main-history .v3-card,
.timeline-card-wrap {
    background-color: #ffffff !important;
    border: 1px solid #eef2f6 !important;
    border-radius: 24px !important;
    
}

/* Ensure the sticky header stays white and clean */
.package-view-header {
    background: rgba(255, 255, 255, 0.95) !important;
    border-bottom: 1px solid #e2e8f0;
    backdrop-filter: blur(10px);
}

/* Add padding to the history list so it fits nicely in the card */
.package-main-content .long-appointment-card-container {
    padding: 5px;
}
