/* ========================================
   1. WIZARD CONTAINER
   ======================================== */

.acg-wizard-container {
    max-width: 900px;
    margin: 40px auto;
    font-family: 'Unbounded', sans-serif;
    color: #2C3E50;
}

/* ========================================
   2. LOADING STATES & SPINNERS
   ======================================== */

.acg-wizard-loading,
.acg-spinner-container {
    text-align: center;
    padding: 60px 20px;
}

.acg-spinner {
    display: inline-block;
    width: 50px;
    height: 50px;
    border: 4px solid #F0F0F0;
    border-top: 4px solid #5FA332;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 20px;
}

@keyframes spin {
    0% {
        transform: rotate(0deg);
    }
    100% {
        transform: rotate(360deg);
    }
}

.acg-spinner-container p {
    font-family: 'Unbounded', sans-serif;
    font-size: 16px;
    font-weight: 500;
    color: #999;
    margin: 0;
}

.btn-spinner {
    display: inline-block;
    width: 16px;
    height: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-top: 2px solid #fff;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    vertical-align: middle;
    margin-right: 8px;
}

.btn-checkmark {
    display: inline-block;
    color: #fff;
    font-size: 18px;
    margin-right: 5px;
}

/* ========================================
   3. ERROR & VALIDATION MESSAGES
   ======================================== */

.acg-error-message,
.acg-inline-error,
.acg-booking-error {
    background: #FEE;
    border-left: 4px solid #dc3545;
    border-radius: 12px;
    padding: 14px 24px;
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
    animation: slideDown 0.3s ease-out;
    margin-bottom: 14px !important;
}

.acg-booking-error {
    background: #FFF3CD;
    border-left-color: #f39c12;
}

@keyframes slideDown {
    from {
        opacity: 0;
        transform: translateY(-10px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.acg-error-icon {
    font-size: 28px;
    flex-shrink: 0;
}

.acg-error-message p,
.acg-inline-error,
.acg-booking-error p {
    margin: 0;
    font-family: 'Unbounded', sans-serif;
    font-size: 14px;
    font-weight: 500;
    color: #721c24;
}

/* Empty States */
.acg-no-slots,
.acg-addons-placeholder {
    text-align: center;
    padding: 60px 20px;
}

.no-slots-icon,
.addons-icon {
    font-size: 64px;
    margin-bottom: 20px;
    opacity: 0.5;
}

.acg-no-slots p,
.acg-addons-placeholder p {
    font-family: 'Unbounded', sans-serif;
    font-size: 18px;
    font-weight: 600;
    color: #2C3E50;
    margin: 10px 0;
}

.acg-no-slots small,
.acg-addons-placeholder small {
    font-family: 'Walkway UltraBold', sans-serif;
    color: #999;
    font-size: 14px;
    letter-spacing: 0.5px;
}

/* ========================================
   4. PROGRESS BAR
   ======================================== */

.acg-wizard-progress {
    display: flex;
    justify-content: space-between;
    margin-bottom: 35px;
    position: relative;
    padding: 0 10px;
}

.acg-wizard-progress::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 0;
    width: 100%;
    height: 3px;
    background: #E5E5E5;
    z-index: 0;
    transform: translateY(-50%);
}

.acg-wizard-progress .step {
    position: relative;
    z-index: 1;
    background: #F8F8F8;
    padding: 8px 16px;
    border-radius: 50px;
    font-family: 'Unbounded', sans-serif;
    color: #999;
    font-size: 13px;
    font-weight: 600;
    transition: all 0.3s ease;
    border: 2px solid #E5E5E5;
}

.acg-wizard-progress .step.completed {
    color: #27ae60;
    background: #d4edda;
    border-color: #27ae60;
}

.acg-wizard-progress .step.completed::after {
    content: '✓';
    display: inline-block;
    margin-left: 6px;
    font-weight: bold;
}

.acg-wizard-progress .step.active {
    color: #FFFFFF;
    background: #4B8226;
    border-color: #4B8226;
    font-weight: 700;
    transform: scale(1.05);
    box-shadow: 0 4px 12px rgba(95, 163, 50, 0.3);
}

/* ========================================
   5. WIZARD PANELS
   ======================================== */

.wizard-panel {
    background: #FFFFFF;
    border: 2px solid #E5E5E5;
    border-radius: 20px;
    padding: 40px;
    min-height: 400px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.05);
    transition: box-shadow 0.3s ease;
}

.wizard-panel:hover {
    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.08);
}

.wizard-step-title {
    font-family: 'Unbounded', sans-serif;
    font-size: 26px;
    font-weight: 700;
    margin-bottom: 30px;
    color: #2C3E50;
    border-bottom: 2px solid #F0F0F0;
    padding-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 15px;
}

.step-number {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 45px;
    height: 45px;
    background: #4B8226;
    color: #FFFFFF;
    border-radius: 50%;
    font-size: 20px;
    font-weight: 700;
    flex-shrink: 0;
}

/* ========================================
   6. FORM ELEMENTS
   ======================================== */

.acg-wizard-field {
    margin-bottom: 30px;
}

.field-label {
    display: block;
    margin-bottom: 12px;
    font-family: 'Unbounded', sans-serif;
    font-weight: 700;
    font-size: 15px;
    color: #2C3E50;
}

.field-hint {
    display: block;
    margin-top: 10px;
    font-family: 'Walkway UltraBold', sans-serif;
    color: #999;
    font-size: 13px;
    letter-spacing: 0.5px;
}

.acg-date-input {
    width: 100%;
    padding: 16px 20px;
    border: 2px solid #E5E5E5;
    border-radius: 15px;
    font-family: 'Unbounded', sans-serif;
    font-size: 16px;
    font-weight: 500;
    color: #2C3E50;
    transition: all 0.3s ease;
}

.acg-date-input:focus {
    outline: none;
    border-color: #5FA332;
    box-shadow: 0 0 0 4px rgba(95, 163, 50, 0.1);
}

.acg-date-input.value-selected {
    border-color: #27ae60;
    background: #f0fdf4;
}

/* ========================================
   7. FACILITY CARDS (STEP 2)
   ======================================== */

.facility-grid {
    display: grid;
    grid-template-rows: repeat(auto-fit, minmax(60px, 1fr));
    gap: 20px;
    max-height: 260px;
    overflow-y: auto;
    overflow-x: hidden;
    padding-right: 10px;
}

/* Scrollbar styling for Firefox */
.facility-grid {
    scrollbar-width: thin;
    scrollbar-color: #c0c0c0 #F0F0F0;
}

/* Scrollbar styling for Chrome/Safari/Edge */
.facility-grid::-webkit-scrollbar {
    width: 6px;
}

.facility-grid::-webkit-scrollbar-track {
    background: #F0F0F0;
    border-radius: 10px;
}

.facility-grid::-webkit-scrollbar-thumb {
    background: #c0c0c0;
    border-radius: 10px;
}

.facility-grid::-webkit-scrollbar-thumb:hover {
    background: #a0a0a0;
}

.facility-card {
    border: 2px solid #E5E5E5;
    padding: 5px 25px;
    border-radius: 20px;
    cursor: pointer;
    text-align: center;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
    background: #FFFFFF;
    display: flex;
    justify-content: space-between;
    align-items: center;
    min-height: 70px;
}

.facility-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(95, 163, 50, 0.05), transparent);
    transition: left 0.5s ease;
}

.facility-card:hover::before {
    left: 100%;
}

.facility-card:hover {
    border-color: #5FA332;
    background: #F4FAF0;
}

.facility-card.selected {
    border-color: #5FA332;
    background: #F4FAF0;
}

.facility-icon {
    font-size: 30px;
    margin-bottom: 0;
    color: #2C3E50;
}

.facility-name {
    font-family: 'Unbounded', sans-serif;
    font-size: 18px;
    font-weight: 700;
    color: #2C3E50;
    margin-bottom: 0;
}

.facility-status {
    font-family: 'Walkway UltraBold', sans-serif;
    font-size: 13px;
    color: #27ae60;
    font-weight: 600;
    letter-spacing: 0.5px;
}

.facility-status i {
    margin-right: 5px;
}


/* ========================================
   8. SLOT GRID (STEP 3)
   ======================================== */

.slot-grid {
    /* Tile layout — auto-fits from 1 column on phones up to 5+ on wide desktops.
       Min tile width 140px gives 2 cols at ~320px wide, 3 at ~480px, 4 at ~640px,
       5 at ~800px. No internal scrollbar: 30 slots in 3 sections flow naturally
       on the page. */
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
    gap: 10px;
    margin-top: 12px;
}

.slot-btn {
    padding: 12px 10px 10px;
    border: 2px solid #E5E5E5;
    background: #FFFFFF;
    border-radius: 12px;
    cursor: pointer;
    font-family: 'Unbounded', sans-serif;
    transition: border-color 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
    position: relative;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    justify-content: flex-start;
    gap: 5px;
    text-align: left;
    min-height: 0;
}

/* Phone — exactly 2 columns; tighter padding/fonts so the time + price fit
   without wrapping. minmax with auto-fill can collapse to 1 col when slot
   content (e.g. "IDR 250,000.00") has min-content wider than the min, so
   we hard-pin 2 columns under 480px. */
@media (max-width: 480px) {
    .slot-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 8px;
    }
    .slot-btn { padding: 10px 8px 8px; gap: 4px; border-radius: 10px; }
    .slot-btn .slot-time { font-size: 10px; }
    .slot-btn .slot-price { font-size: 12px; }
    .slot-btn .slot-member-badge { font-size: 7px; padding: 2px 6px; }
    .slot-reason-chip { font-size: 9px; padding: 2px 6px; }
    .slot-section-label { font-size: 11px; margin: 14px 0 6px; }
    .slot-section-label small { display: none; } /* hide range hint */
}

.slot-btn:hover:not(:disabled) {
    border-color: #5FA332;
    color: #2c3e50;
    background: #F4FAF0;
}

.slot-btn.selected {
    background: #5FA332;
    color: #FFFFFF;
    border-color: #5FA332;
}

.slot-btn:disabled {
    background: #F0F0F0;
    color: #CCC;
    cursor: not-allowed;
    border-color: #E5E5E5;
}

.slot-time {
    font-weight: 700;
    font-size: 10px;
}

.slot-price {
    font-size: 12px;
    font-weight: 700;
    color: #27ae60;
}
.acg-modal-content .slot-price {
       font-size: 10px;
}
.slot-btn.selected .slot-price {
    color: #FFFFFF;
}

.slot-btn.selected:not(:disabled) .slot-price {
    color: #000000;
}

/* Member savings badge inside each slot button */
.slot-member-badge {
    margin-top: 4px;
    font-size: 7px;
    font-weight: 700;
    padding: 2px 6px;
    border-radius: 10px;
    line-height: 1.3;
    display: inline-block;
}
.slot-member-free {
    background: #d1fae5;
    color: #047857;
}
.slot-member-rate {
    background: #fef3c7;
    color: #92400e;
}
.slot-btn.selected .slot-member-free,
.slot-btn.selected .slot-member-rate {
    background: rgba(255,255,255,0.85);
}
.slot-member-badge i {
    margin-right: 3px;
}

.slot-checkmark {
    display: none;
    font-size: 24px;
    position: relative;
    top: 50%;
    right: 12px;
    transform: translateY(-50%);
}

.slot-btn.selected .slot-checkmark {
    display: none;
}

.slot-multi-hint {
    font-size: 12px;
    color: #64748b;
    margin: 10px 4px 0;
    line-height: 1.5;
}

.slot-multi-hint i {
    margin-right: 4px;
}

/* ========================================
   9. SUMMARY CARD (STEP 5)
   ======================================== */

.summary-card {
    background: #F8F8F8;
    border-radius: 20px;
    padding: 35px;
}

.summary-card h3 {
    margin: 0 0 25px 0;
    font-family: 'Unbounded', sans-serif;
    font-size: 22px;
    font-weight: 700;
    color: #2C3E50;
}

.summary-table {
    width: 100%;
    /* Deliberately NOT `table-layout: fixed`.
       Fixed layout stops the table outgrowing its card, but it sizes every
       column from the FIRST ROW and makes percentage widths binding — which
       squeezed the label column to ~60px and left the text ~5px wide, hiding
       every label. Auto layout keeps the labels readable; the overflow it used
       to cause is handled instead by letting the VALUE column wrap (see
       .summary-table .value below), which is what actually made the table
       demand more width than the card had. */
    border-collapse: collapse;
    margin-bottom: 25px;
    background: #FFFFFF;
    border-radius: 15px;
    overflow: hidden;
    border: 2px solid #E5E5E5;
}

.summary-table tr {
    border-bottom: 1px solid #F0F0F0;
}

.summary-table tr:last-child {
    border-bottom: none;
}

.summary-table td {
    padding: 18px 20px;
}

.summary-table .label {
    font-family: 'Unbounded', sans-serif;
    font-weight: 700;
    font-size: 14px;
    width: 45%;
    color: #2C3E50;
}
.summary-table .label {
    display: flex;             
    flex-direction: row;
    align-items: center;
    align-content: center;        
}

.summary-table .label .icon {
    margin-right: 10px;
    font-size: 20px;
    color: #5FA332;

    /* Fixed box so every row's text starts at the same x.
       Font Awesome glyphs have different intrinsic widths (calendar 14px,
       marker 12px, money-bill 20px), and with an auto-width icon the label
       text inherited that variance — the left edge of "Date/Location/Time/
       Court Booking" stepped in and out by up to 8px. Centring a fixed box
       decouples label alignment from whichever glyph a row uses. */
    flex: 0 0 22px;
    width: 22px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    line-height: 1;
}

/* The label cell is a flex row (icon + text).
   `min-width: auto` and `flex: 0 0 auto` are both deliberate: with
   `min-width: 0` and a growable flex basis the row happily shrinks the text
   span to a few pixels — `white-space: nowrap` does NOT prevent this, because
   flex shrinking wins over the intrinsic width. That is exactly what made
   every label collapse to ~5px and disappear. Letting the span keep its
   natural width is what keeps "Court Booking:" readable. */
.summary-table .label .label-text {
    flex: 0 0 auto;
    min-width: auto;
}

.summary-table .value {
    font-family: 'Unbounded', sans-serif;
    /* Darker and heavier than the label so the booking details read as the
       content and the labels as their captions. Previously both were #2C3E50
       at near-identical size (14px vs 15px), which flattened the row into an
       undifferentiated strip of text. 14.0:1 on white — comfortably AA. */
    color: #1F2D3D;
    font-size: 15px;
    font-weight: 700;
    text-align: end;
     white-space: nowrap;
}

/* Label demoted to a caption. #647382 is the LIGHTEST grey that still clears
   WCAG AA (4.5:1) on both the white table and the #F8F8F8 card — a lighter
   #7A8A99 was tried first and measured only 3.55:1, which fails for text this
   small. Do not lighten further without re-checking contrast. */
.summary-table .label .label-text {
    color: #647382;
    font-weight: 600;
}

.summary-total {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 30px;
    /* background: linear-gradient(135deg, #5FA332, #4B8226); */
    color: #FFFFFF;
    border-radius: 15px;
    font-family: 'Unbounded', sans-serif;
    font-size: 18px;
    font-weight: 700;
    margin-top: 25px;
    /* box-shadow: 0 6px 20px rgba(95, 163, 50, 0.3); */
}

#acg-booking-wizard .summary-total {
    color: #000;
    border: 1px solid;
}

.total-price {
    font-size: 20px;
    font-weight: 700;
}

.summary-note {
    text-align: center;
    font-family: 'Walkway UltraBold', sans-serif;
    color: #999;
    font-size: 13px;
    margin: 20px 0 0 0;
    letter-spacing: 0.5px;
}

.addons-scroll-wrapper {
    max-height: 130px;
    overflow-y: auto;
    border-radius: 15px;
    margin-bottom: 25px;
    border: 2px solid #E5E5E5;
    touch-action: pan-y;
    -webkit-overflow-scrolling: touch;
    /* Thin scrollbar - Firefox */
    scrollbar-width: thin;
    scrollbar-color: #5FA332 #F0F0F0;
}

.addons-scroll-wrapper .summary-table {
    margin-bottom: 0;
    border: none;
}

/* Thin scrollbar - Chrome/Safari/Edge */
.addons-scroll-wrapper::-webkit-scrollbar {
    width: 6px;
    height: 6px; /* Controls horizontal scrollbar thickness */
}

.addons-scroll-wrapper::-webkit-scrollbar-track {
    background: #F0F0F0;
    border-radius: 10px;
}

.addons-scroll-wrapper::-webkit-scrollbar-thumb {
    background: #5FA332;
    border-radius: 10px;
}

/* Prevent currency text from breaking to new line */
.summary-table .value {
    white-space: nowrap;
}



/* ========================================
   10. NAVIGATION BUTTONS
   ======================================== */

.acg-wizard-nav {
    display: flex;
    justify-content: space-between;
    margin-top: 35px;
    gap: 15px;
}

.acg-wizard-nav button {
    padding: 16px 40px;
    border-radius: 50px;
    cursor: pointer;
    font-family: 'Unbounded', sans-serif;
    font-size: 16px;
    font-weight: 700;
    transition: all 0.3s ease;
    border: none;
    position: relative;
    overflow: hidden;
}

.acg-wizard-nav button::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.3);
    transform: translate(-50%, -50%);
    transition: width 0.6s ease, height 0.6s ease;
}

.acg-wizard-nav button:hover::before {
    width: 300px;
    height: 300px;
}

.btn-prev {
    background: #F0F0F0;
    color: #2C3E50;
}

.btn-prev:hover {
    background: #E5E5E5;
    transform: translateX(-3px);
}

.btn-next {
    background: linear-gradient(135deg, #5FA332, #4B8226);
    color: #FFFFFF;
}

.btn-next:hover:not(:disabled) {
    background: linear-gradient(135deg, #2C3E50, #34495e);
}

.btn-next:disabled {
    background: #CCC;
    cursor: not-allowed;
    box-shadow: none;
}


/* ========================================
   12. ANIMATIONS
   ======================================== */

.fade-in {
    animation: fadeIn 0.3s ease-in;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}





/* ========================================
   13. RESPONSIVE DESIGN - BOOKING WIZARD
   ======================================== */

@media (max-width: 1200px) {
    .acg-wizard-container {
        max-width: 800px;
        margin: 35px auto;
    }

    /* Progress Bar - Hide Text on Mobile, Show Numbers Only */
    .acg-wizard-progress {
        gap: 8px;
        margin-bottom: 25px;
    }

    .acg-wizard-progress .step {
        font-size: 0;
        padding: 0;
        width: 40px;
        height: 40px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .acg-wizard-progress .step::before {
        content: attr(data-step);
        font-size: 14px;
        font-weight: 700;
    }

    .acg-wizard-progress .step.completed::after {
        content: '';
        margin: 0;
    }

    .wizard-panel {
        padding: 35px;
    }

    .wizard-step-title {
        font-size: 22px;
    }

    .step-number {
        width: 42px;
        height: 42px;
        font-size: 18px;
    }

     /* Facility Grid */
    .facility-grid {
        max-height: 240px;
    }

    /* Summary */
    .summary-card {
        padding: 25px 20px;
    }

    .summary-card h3 {
        font-size: 18px;
        margin-bottom: 18px;
    }

    .summary-table td {
        padding: 14px 16px;
    }

    .summary-table .label {
        font-size: 13px;
        width: 50%;
    }

    .summary-table .label .icon {
        font-size: 16px;
        /* margin-right only: a blanket `margin:5px` re-introduced the
           per-glyph horizontal variance the base rule exists to remove. */
        margin: 0 8px 0 0;
        flex: 0 0 20px;
        width: 20px;
    }

    .summary-table .value {
        font-size: 14px;
    }

    .summary-total {
        padding: 12px 22px;
        font-size: 15px;
        flex-direction: column;
        gap: 5px;
        text-align: center;
    }

    .total-price {
        font-size: 20px;
    }

    .summary-note {
        font-size: 12px;
        margin-top: 15px;
    }

   /* Keep the row labels on mobile.
    *
    * These used to be hidden so only the icon showed, but Font Awesome was
    * removed from the plugin in v2.10.3 — the icons no longer render, so
    * hiding the text left the left-hand column completely blank and the
    * summary read as four unlabelled values. Showing the words is the fix;
    * they are short and there is room for them. */
    .summary-table .label-text {
        display: inline;
    }

    .summary-table .label {
        /* `auto` is correct here — the table uses auto layout, so this sizes
           the column to its content and keeps every label fully readable. */
        width: auto;
        white-space: nowrap;
    }

}

/* ========================================
   TABLET & BELOW (991px)
   ======================================== */
@media (max-width: 991px) {
    .acg-wizard-container {
        max-width: 100%;
        margin: 30px 20px;
    }

    /* Progress Bar - Hide Text on Mobile, Show Numbers Only */
    .acg-wizard-progress {
        gap: 8px;
        margin-bottom: 25px;
    }

    .acg-wizard-progress .step {
        font-size: 0;
        padding: 0;
        width: 40px;
        height: 40px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .acg-wizard-progress .step::before {
        content: attr(data-step);
        font-size: 14px;
        font-weight: 700;
    }

    .acg-wizard-progress .step.completed::after {
        content: '';
        margin: 0;
    }

    /* Panels */
    .wizard-panel {
        padding: 30px 25px;
        min-height: 350px;
    }

    .wizard-step-title {
        font-size: 17px;
        margin-bottom: 25px;
        padding-bottom: 15px;
    }

    .step-number {
        width: 40px;
        height: 40px;
        font-size: 17px;
    }

    /* Form Elements */
    .acg-date-input {
        padding: 14px 18px;
        font-size: 15px;
    }

    /* Facility Grid */
    .facility-grid {
        gap: 15px;
        max-height: 225px;
    }

    .facility-card {
        padding: 5px 20px;
        min-height: 65px;
    }

    .facility-icon {
        font-size: 28px;
    }

    .facility-name {
        font-size: 15px;
    }

    .facility-status {
        font-size: 12px;
    }

    .slot-time {
        font-size: 10px;
    }

    .slot-price {
        font-size: 12px;
    }

    /* Summary */
    .summary-card {
        padding: 30px 25px;
    }

    .summary-card h3 {
        font-size: 20px;
        margin-bottom: 20px;
    }

    .summary-table td {
        padding: 16px 18px;
    }

    .summary-total {
        padding: 10px 25px;
        font-size: 15px;
    }

    .total-price {
        font-size: 20px;
    }

    /* Navigation */
    .acg-wizard-nav {
        margin-top: 30px;
        gap: 12px;
    }

    .acg-wizard-nav button {
        padding: 14px 35px;
        font-size: 15px;
    }
}

/* ========================================
   MOBILE LANDSCAPE & BELOW (768px)
   ======================================== */
@media (max-width: 768px) {
    .acg-wizard-container {
        margin: 25px 15px;
    }

    /* Progress Bar - Hide Text on Mobile, Show Numbers Only */
    .acg-wizard-progress {
        gap: 8px;
        margin-bottom: 25px;
    }

    .acg-wizard-progress .step {
        font-size: 0;
        padding: 0;
        width: 40px;
        height: 40px;
        border-radius: 50%;
        display: flex;
        align-items: center;
        justify-content: center;
    }

    .acg-wizard-progress .step::before {
        content: attr(data-step);
        font-size: 14px;
        font-weight: 700;
    }

    .acg-wizard-progress .step.completed::after {
        content: '';
        margin: 0;
    }

    /* Panels */
    .wizard-panel {
        padding: 25px 20px;
        min-height: 300px;
    }

    .wizard-step-title {
        font-size: 20px;
        margin-bottom: 20px;
        flex-direction: column;
        text-align: center;
        gap: 10px;
    }

    .step-number {
        width: 38px;
        height: 38px;
        font-size: 16px;
    }

    /* Form Elements */
    .field-label {
        font-size: 14px;
        margin-bottom: 10px;
    }

    .field-hint {
        font-size: 12px;
        margin-top: 8px;
    }

    .acg-date-input {
        padding: 12px 16px;
        font-size: 14px;
    }

    /* Facility Grid - Single Column on Mobile */
    .facility-grid {
        grid-template-columns: 1fr;
        gap: 12px;
        max-height: 215px;
    }

    .facility-card {
        padding: 15px 20px;
        min-height: 60px;
        flex-direction: row;
        gap: 15px;
    }

    .facility-icon {
        font-size: 26px;
    }

    .facility-name {
        font-size: 16px;
    }

    .facility-status {
        font-size: 11px;
    }

    /* Slot grid responsive sizing is now handled by the operating-day rules
       at the top of this file (auto-fill minmax + a 480px override for 2 cols).
       Legacy single-column + max-height layout removed — was causing the
       30-slot grid to scroll inside a 210px box. */
    .slot-checkmark {
        font-size: 20px;
        right: 10px;
    }

    /* Summary */
    .summary-card {
        padding: 25px 20px;
    }

    .summary-card h3 {
        font-size: 18px;
        margin-bottom: 18px;
    }

    .summary-table td {
        padding: 14px 16px;
    }

    .summary-table .label {
        font-size: 13px;
        width: 50%;
    }

    .summary-table .label .icon {
        font-size: 16px;
        /* margin-right only: a blanket `margin:5px` re-introduced the
           per-glyph horizontal variance the base rule exists to remove. */
        margin: 0 8px 0 0;
        flex: 0 0 20px;
        width: 20px;
    }

    .summary-table .value {
        font-size: 14px;
    }

    .summary-total {
        padding: 10px 20px;
        font-size: 15px;
        flex-direction: column;
        gap: 5px;
        text-align: center;
    }

    .total-price {
        font-size: 20px;
    }

    .summary-note {
        font-size: 12px;
        margin-top: 15px;
    }

    /* Navigation - Stack on Mobile */
    .acg-wizard-nav {
        flex-direction: column-reverse;
        margin-top: 25px;
        gap: 10px;
    }

    .acg-wizard-nav button {
        width: 100%;
        padding: 14px 30px;
        font-size: 14px;
    }

    /* Error Messages */
    .acg-error-message,
    .acg-inline-error,
    .acg-booking-error {
        padding: 15px 18px;
        gap: 12px;
        font-size: 13px;
    }

    .acg-error-icon {
        font-size: 24px;
    }

    /* Empty States */
    .acg-no-slots,
    .acg-addons-placeholder {
        padding: 50px 15px;
    }

    .no-slots-icon,
    .addons-icon {
        font-size: 56px;
    }

    .acg-no-slots p,
    .acg-addons-placeholder p {
        font-size: 16px;
    }

    .acg-no-slots small,
    .acg-addons-placeholder small {
        font-size: 13px;
    }

    /* Loading */
    .acg-wizard-loading,
    .acg-spinner-container {
        padding: 50px 15px;
    }

    .acg-spinner {
        width: 45px;
        height: 45px;
    }

    .acg-spinner-container p {
        font-size: 15px;
    }
}

/* ========================================
   MOBILE PORTRAIT (576px)
   ======================================== */
@media (max-width: 576px) {
    .acg-wizard-container {
        margin: 20px 12px;
    }

    /* Progress Bar */
    .acg-wizard-progress {
        gap: 6px;
        margin-bottom: 20px;
    }

    .acg-wizard-progress .step {
        width: 36px;
        height: 36px;
    }

    .acg-wizard-progress .step::before {
        font-size: 13px;
    }

    /* Panels */
    .wizard-panel {
        padding: 20px 15px;
        min-height: 280px;
    }

    .wizard-step-title {
        font-size: 18px;
        margin-bottom: 18px;
    }

    .step-number {
        width: 36px;
        height: 36px;
        font-size: 15px;
    }

    /* Form Elements */
    .field-label {
        font-size: 13px;
    }

    .field-hint {
        font-size: 11px;
    }

    .acg-date-input {
        padding: 12px 14px;
        font-size: 13px;
    }

    /* Facility Grid */
    .facility-grid {
        gap: 10px;
        max-height: 205px;
    }

    .facility-card {
        padding: 12px 16px;
    }

    .facility-icon {
        font-size: 24px;
    }

    .facility-name {
        font-size: 15px;
    }

    .facility-status {
        font-size: 10px;
    }

    .slot-time {
        font-size: 10px;
    }

    .slot-price {
        font-size: 12px;
    }

    .slot-checkmark {
        font-size: 18px;
        right: 8px;
    }

    /* Summary */
    .summary-card {
        padding: 20px 15px;
    }

    .summary-card h3 {
        font-size: 17px;
        margin-bottom: 15px;
    }

    .summary-table td {
        padding: 12px 14px;
    }

    .summary-table .label {
        font-size: 12px;
    }

    .summary-table .label .icon {
        font-size: 16px;
        /* margin-right only: a blanket `margin:5px` re-introduced the
           per-glyph horizontal variance the base rule exists to remove. */
        margin: 0 8px 0 0;
        flex: 0 0 20px;
        width: 20px;
    }

    .summary-table .value {
        font-size: 13px;
    }

    .summary-total {
        padding: 8px 18px;
        font-size: 14px;
    }

    .total-price {
        font-size: 15px;
    }

    /* Navigation */
    .acg-wizard-nav {
        margin-top: 20px;
        gap: 8px;
    }

    .acg-wizard-nav button {
        padding: 12px 25px;
        font-size: 13px;
    }

    /* Error Messages */
    .acg-error-message,
    .acg-inline-error,
    .acg-booking-error {
        padding: 12px 15px;
        gap: 10px;
    }

    .acg-error-message p,
    .acg-inline-error,
    .acg-booking-error p {
        font-size: 12px;
    }

    .acg-error-icon {
        font-size: 20px;
    }

    /* Empty States */
    .acg-no-slots,
    .acg-addons-placeholder {
        padding: 40px 12px;
    }

    .no-slots-icon,
    .addons-icon {
        font-size: 48px;
    }

    .acg-no-slots p,
    .acg-addons-placeholder p {
        font-size: 15px;
    }

    .acg-no-slots small,
    .acg-addons-placeholder small {
        font-size: 12px;
    }

    /* Loading */
    .acg-wizard-loading,
    .acg-spinner-container {
        padding: 40px 12px;
    }

    .acg-spinner {
        width: 40px;
        height: 40px;
        border-width: 3px;
    }

    .acg-spinner-container p {
        font-size: 14px;
    }

    .btn-spinner {
        width: 14px;
        height: 14px;
    }
}

/* ========================================
   SMALL MOBILE (320px)
   ======================================== */
@media (max-width: 320px) {
    .acg-wizard-container {
        margin: 15px 10px;
    }

    /* Progress Bar */
    .acg-wizard-progress {
        gap: 4px;
        margin-bottom: 18px;
    }

    .acg-wizard-progress .step {
        width: 32px;
        height: 32px;
    }

    .acg-wizard-progress .step::before {
        font-size: 12px;
    }

    /* Panels */
    .wizard-panel {
        padding: 18px 12px;
        min-height: 260px;
    }

    .wizard-step-title {
        font-size: 17px;
        margin-bottom: 15px;
    }

    .step-number {
        width: 34px;
        height: 34px;
        font-size: 14px;
    }

    /* Form Elements */
    .field-label {
        font-size: 12px;
    }

    .acg-date-input {
        padding: 10px 12px;
        font-size: 12px;
    }

    /* Facility Grid */
    .facility-card {
        padding: 10px 12px;
    }

    .facility-icon {
        font-size: 22px;
    }

    .facility-name {
        font-size: 14px;
    }

    /* Slot Grid */
    .slot-btn {
        padding: 10px 12px;
    }

    .slot-time {
        font-size: 10px;
    }

    .slot-price {
        font-size: 12px;
    }

    /* Summary */
    .summary-card {
        padding: 18px 12px;
    }

    .summary-card h3 {
        font-size: 16px;
    }

    .summary-table td {
        padding: 10px 12px;
    }

    .addons-scroll-wrapper {
    max-height: 100px;
    border-radius: 8px;
}


    .summary-table .label {
        font-size: 11px;
        margin-left: 15px;
    }

    .summary-table .value {
        font-size: 12px;
    }

    .summary-total {
        padding: 8px 18px;
        font-size: 12px;
    }

    .total-price {
        font-size: 15px;
    }

    /* Navigation */
    .acg-wizard-nav button {
        padding: 10px 20px;
        font-size: 12px;
    }
}

/* ========================================
   14. LANDSCAPE ORIENTATION FIX
   ======================================== */
@media (max-height: 600px) and (orientation: landscape) {
    .wizard-panel {
        min-height: 250px;
    }

    .facility-grid {
        max-height: 200px;
    }

    .acg-wizard-progress {
        margin-bottom: 15px;
    }

    .wizard-step-title {
        margin-bottom: 15px;
        padding-bottom: 10px;
    }

    .acg-wizard-nav {
        margin-top: 20px;
    }
}

/* ───────────────────────────────────────────────────────────
   Operating-day slot grid: section headers, unavailable
   slot states, reason chips, range-select error banner.
   ─────────────────────────────────────────────────────────── */

.slot-section-label {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 22px 0 10px;
    color: #5a5a6a;
    font-family: 'Unbounded', sans-serif;
    font-weight: 700;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}
.slot-section-label::before,
.slot-section-label::after {
    content: '';
    flex: 1;
    border-top: 1px dashed #ddd;
}
.slot-section-label span {
    padding: 0 10px;
    background: transparent;
    white-space: nowrap;
}
.slot-section-label small {
    color: #888;
    font-size: 11px;
    font-weight: 500;
    text-transform: none;
    letter-spacing: 0;
    margin-left: 4px;
}
.slot-section-label::after {
    margin-left: auto;
}

/* Greyed-out unavailable slots — visible but unselectable */
.slot-btn.unavailable {
    cursor: not-allowed !important;
    opacity: 0.55;
    background: #F5F5F8;
    pointer-events: none;
}
.slot-btn.unavailable .slot-time {
    text-decoration: line-through;
    color: #888;
}
.slot-btn.unavailable .slot-price {
    color: #999;
}
.slot-btn.unavailable .slot-member-badge,
.slot-btn.unavailable .slot-checkmark {
    display: none;
}

/* Reason chip in the upper-right of an unavailable slot */
.slot-reason-chip {
    position: absolute;
    top: 6px;
    right: 8px;
    font-size: 10px;
    padding: 3px 8px;
    border-radius: 12px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    font-family: 'Unbounded', sans-serif;
}
.slot-reason-chip.slot-reason-past     { background: #ECEFF1; color: #607D8B; }
.slot-reason-chip.slot-reason-booked   { background: #FFEBEE; color: #C62828; }
.slot-reason-chip.slot-reason-locked   { background: #FFF3E0; color: #E65100; }
.slot-reason-chip.slot-reason-blackout { background: #E1F5FE; color: #01579B; }

/* Range-select error banner */
.acg-range-error {
    background: #FFEBEE;
    color: #C62828;
    padding: 0 14px;
    border-radius: 8px;
    margin-bottom: 0;
    font-size: 13px;
    font-weight: 500;
    line-height: 1.4;
    opacity: 0;
    max-height: 0;
    overflow: hidden;
    transition: opacity 0.2s ease, max-height 0.2s ease, padding 0.2s ease, margin-bottom 0.2s ease;
}
.acg-range-error.visible {
    opacity: 1;
    max-height: 100px;
    padding: 12px 14px;
    margin-bottom: 14px;
}




/* ========================================
   Mobile refinements (<=782px)
   ======================================== */
@media (max-width: 782px) {
    /* "Booking Details" wrapped to two lines at 22px on a 390px screen and
       pushed the actual details below the fold. */
    #acg-booking-wizard .summary-card h3 {
        font-size: 17px;
        margin-bottom: 16px;
    }

    /* Tighter summary rows so the whole confirmation fits one screen. */
    #acg-booking-wizard .summary-table td {
        padding: 12px 14px;
    }

    /* The site's floating WhatsApp bubble sits bottom-left and overlapped the
       Back button. Reserve room beneath the nav so both stay tappable. */
    #acg-booking-wizard .acg-wizard-nav {
        padding-bottom: 8px;
        margin-bottom: 56px;
    }
}


/* "Court Booking:" wrapped to two lines and made its row taller than the
   others. The label cell is display:flex, so nowrap has to go on the inner
   text span, not the cell.

   Deliberately NO `overflow:hidden; text-overflow:ellipsis` here. That was
   tried and made every label VANISH rather than truncate, because the text box
   can compute to ~0px once the icon has taken its share of a narrow column.
   Letting the text overflow slightly is far safer than hiding it. */
#acg-booking-wizard .summary-table .label .label-text {
    white-space: nowrap;
}

/* On a phone the value column is what forced the table wider than its card:
   `white-space: nowrap` on values like "150,000.00 Rp" and "17:00 - 18:00"
   meant the table could not shrink to fit. Allowing them to wrap below 480px
   keeps the whole table inside the card without touching the label column. */
/* ── Confirm-step summary on a phone: stack label above value ───────────
   Two columns simply do not fit a ~245px card once the label ("Court
   Booking:") and an unbreakable value ("150,000.00 Rp") sit side by side —
   the table grew to 342px and spilled out of its card.

   Wrapping the value was tried first and rejected: `word-break: break-word`
   split values into nonsense ("150,0 / 00.00 Rp", a three-line "Aug / 18, /
   2026"), and `overflow-wrap: normal` kept them intact but brought the
   overflow straight back. Stacking is what actually fits: each row becomes a
   block with the label on one line and the value beneath it, so every value
   stays on a single unbroken line and the table sits inside the card. */
@media (max-width: 480px) {
    #acg-booking-wizard .summary-table,
    #acg-booking-wizard .summary-table tbody,
    #acg-booking-wizard .summary-table tr {
        display: block;
        width: 100%;
    }

    #acg-booking-wizard .summary-table tr {
        padding: 10px 14px;
        border-bottom: 1px solid #F0F0F0;
    }

    #acg-booking-wizard .summary-table tr:last-child {
        border-bottom: none;
    }

    #acg-booking-wizard .summary-table td {
        display: block;
        padding: 0;
        /* Uncode puts `border-bottom` on every `td`. In a normal table that is
           the row rule; with the cells stacked as blocks it drew a line under
           each value, so every field read as an empty text input. */
        border: 0 !important;
    }

    /* ── Hierarchy: the value is the content, the label is just its caption ──
       Previously label (12px) and value (13px) were near-identical weights and
       shared one colour, so the details a customer is actually checking did
       not stand out. Demoting the label and promoting the value makes each row
       scannable at a glance, and the tighter rhythm brings the Total Amount
       above the fold instead of below it. */
    #acg-booking-wizard .summary-table .label {
        width: 100% !important;
        margin-bottom: 1px;
    }

    #acg-booking-wizard .summary-table .label-text {
        font-size: 11px;
        font-weight: 600;
        color: #647382;
        letter-spacing: 0.03em;
        /* Deliberately not uppercased: add-on rows put the PRODUCT NAME in
           this slot ("20 Balls"), and shouting a product name looks like a
           rendering fault rather than a style. */
        text-transform: none;
    }

    #acg-booking-wizard .summary-table .label .icon {
        font-size: 13px;
    }

    #acg-booking-wizard .summary-table .value {
        /* Left-aligned under its label rather than right-aligned across a gap,
           and indented to line up with the label text past the icon. */
        text-align: left !important;
        white-space: nowrap !important;
        padding-left: 28px !important;
        font-size: 15px;
        font-weight: 700;
        color: #1F2D3D;
    }

    /* Section headings become quiet eyebrow labels so they frame the data
       without competing with it. */
    #acg-booking-wizard .summary-card {
        padding: 18px 14px;
    }

    #acg-booking-wizard .summary-card h3 {
        font-size: 13px;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.08em;
        color: #5F6E7D;
        margin: 0 0 10px 0;
    }
}

/* ============================================================================
   SIDE-BY-SIDE COURT AVAILABILITY (step 2)
   ============================================================================
   Step 2 used to show one court at a time, chosen blind on step 1. It now shows
   every court in its own column so a customer can compare who has 19:00 free
   without backtracking.

   Both courts share opening hours and are filtered against the same clock, so
   each column holds the same number of slots in the same order — the rows line
   up by time on their own, no shared time gutter needed.

   --court-cols is set inline from JS (facilities.length), so a third court
   would lay itself out without a CSS change.
   ========================================================================= */

.court-compare {
    margin-top: 4px;
}

.court-compare-head,
.court-compare-row {
    display: grid;
    /* minmax(0,1fr) not 1fr: grid items default to min-width:auto, which would
       let a long court name push the column wider than its share and break the
       alignment between the two columns. */
    grid-template-columns: repeat(var(--court-cols, 2), minmax(0, 1fr));
    gap: 10px;
}

.court-compare-head {
    margin: 10px 0 4px;
}

.court-col-head {
    font-family: 'Unbounded', sans-serif;
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.4px;
    color: var(--dark-grey, #2E3D28);
    text-align: center;
    padding: 7px 6px;
    background: #F4FAF0;
    border: 1px solid #E2EFD9;
    border-radius: 10px;
    /* A long name truncates rather than wrapping, so the two headers keep the
       same height and the slot rows below them stay aligned. */
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* Slot buttons are DIRECT children of .court-compare-row, laid out by the grid
   in time order: court A 06:00, court B 06:00, court A 07:00, court B 07:00 ...
   Grid rows size to their tallest cell, so the two courts stay aligned on the
   same hour even when one card is taller (a "Booked" chip, a member badge). */
.court-compare-row {
    /* Deliberately NOT grid-auto-rows:1fr - that equalises EVERY row to the
       tallest row on the page, so one "Booked" card (taller, it carries a chip)
       padded every available card with dead space. Auto rows size each row to
       its own content, while grid's default align-items:stretch still makes the
       two cells WITHIN a row equal height. That is all the alignment needs. */
    margin-bottom: 4px;
}

.court-compare-row > .slot-btn {
    width: 100%;
    min-width: 0;
}

/* In the two-court grid a card is roughly half its old width (~127px on a
   390px phone). The reason chip is absolutely positioned top-right, so at that
   width "BOOKED" sat on top of the time and clipped it to "11:00 - 12:". Inside
   the comparison grid the chip flows in normal order instead - it is emitted
   before .slot-time, so it stacks above it - which holds at every card width
   without guessing a breakpoint. */
.court-compare-row > .slot-btn .slot-reason-chip {
    position: static;
    align-self: flex-start;
    margin: 0 0 1px;
}

.court-compare-row > .slot-btn .slot-time {
    min-width: 0;
    max-width: 100%;
}

/* Placeholder where one court has no slot at an hour the other does, so the
   grid never closes the gap and slides later hours out of alignment. */
.slot-cell-empty {
    font-family: 'Unbounded', sans-serif;
    font-size: 11px;
    color: #C9C9C9;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px dashed #EAEAEA;
    border-radius: 12px;
    min-height: 100%;
}

@media (max-width: 782px) {
    /* Two columns are kept on phones — collapsing to one would defeat the whole
       point of the side-by-side comparison. The cards shrink instead. */
    .court-compare-head,
    .court-compare-row { gap: 7px; }
    .court-col-head { font-size: 9px; padding: 6px 4px; letter-spacing: 0.2px; }
    .court-compare-row > .slot-btn { padding: 9px 6px 7px; }
    .court-compare-row > .slot-btn .slot-time { font-size: 9.5px; }
    .court-compare-row > .slot-btn .slot-price { font-size: 11px; }
    .slot-cell-empty { font-size: 10px; }
}
