/* =========================================
   Padel Simulator Page
   ========================================= */

.ps-body {
    background: var(--bg-warm);
    font-family: var(--font-main);
    color: var(--text-dark);
}

.ps-body main {
    padding-bottom: 96px;
}

/* Breadcrumb spacing under fixed nav */
.ps-body .breadcrumb {
    padding-top: 110px;
    margin-bottom: 24px;
}

/* ---------- Hero ---------- */
.ps-hero {
    padding-bottom: 64px;
}

.ps-hero-grid {
    display: grid;
    grid-template-columns: 1.1fr 1fr;
    gap: 48px;
    align-items: center;
    background: var(--bg-white);
    border-radius: var(--radius-2xl);
    padding: 56px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-light);
}

.ps-hero-body .section-label {
    margin-bottom: 16px;
}

.ps-hero-body h1 {
    font-size: clamp(2.2rem, 4vw, 3.25rem);
    font-weight: 800;
    line-height: 1.1;
    letter-spacing: -0.02em;
    color: var(--text-dark);
    margin-bottom: 16px;
}

.ps-hero-body p {
    font-size: var(--text-lg);
    line-height: 1.6;
    color: var(--text-body);
    margin-bottom: 24px;
    max-width: 540px;
}

.ps-hero-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-bottom: 32px;
}

.ps-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 8px 14px;
    background: var(--bg-light);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-pill);
    font-size: var(--text-sm);
    font-weight: 600;
    color: var(--text-body);
}

.ps-chip i {
    width: 16px;
    height: 16px;
}

.ps-chip--accent {
    background: var(--primary-blue-10);
    border-color: transparent;
    color: var(--primary-blue);
}

.ps-hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.ps-hero-visual {
    display: flex;
    justify-content: center;
    align-items: center;
    background: linear-gradient(135deg, var(--primary-blue-light) 0%, var(--bg-light) 100%);
    border-radius: var(--radius-xl);
    padding: 32px;
    aspect-ratio: 1 / 0.95;
}

.ps-hero-img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

/* ---------- How it works ---------- */
.ps-how {
    padding: 80px 0;
}

.ps-section-sub {
    margin-top: 12px;
    font-size: var(--text-base);
    color: var(--text-body);
    max-width: 560px;
    margin-left: auto;
    margin-right: auto;
}

.ps-how-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 24px;
    margin-top: 48px;
}

.ps-how-card {
    position: relative;
    background: var(--bg-white);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-xl);
    padding: 28px;
    display: flex;
    flex-direction: column;
    transition: transform var(--duration-normal) var(--ease-out-expo),
                box-shadow var(--duration-normal) var(--ease-out-expo);
}

.ps-how-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-md);
}

.ps-how-step {
    position: absolute;
    top: 20px;
    right: 24px;
    font-size: var(--text-2xl);
    font-weight: 800;
    color: var(--primary-blue);
    opacity: 0.18;
    letter-spacing: -0.02em;
}

.ps-how-img-wrap {
    background: linear-gradient(135deg, var(--primary-blue-light) 0%, var(--bg-light) 100%);
    border-radius: var(--radius-lg);
    padding: 12px;
    aspect-ratio: 1 / 1.05;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 20px;
}

.ps-how-img,
.ps-how-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    border-radius: calc(var(--radius-lg) - 4px);
}

.ps-how-body h3 {
    font-size: var(--text-xl);
    font-weight: 700;
    margin-bottom: 8px;
    color: var(--text-dark);
}

.ps-how-body p {
    font-size: var(--text-sm);
    line-height: 1.6;
    color: var(--text-body);
}

/* ---------- How-it-works card — clickable hint ---------- */
.ps-how-card {
    cursor: pointer;
}

.ps-how-card-hint {
    position: absolute;
    bottom: 16px;
    right: 16px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: var(--primary-blue);
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transform: scale(0.7);
    transition: opacity 200ms ease, transform 200ms var(--ease-out-back);
    pointer-events: none;
}

.ps-how-card-hint i {
    width: 16px;
    height: 16px;
}

.ps-how-card:hover .ps-how-card-hint,
.ps-how-card:focus-visible .ps-how-card-hint {
    opacity: 1;
    transform: scale(1);
}

.ps-how-card:focus-visible {
    outline: 2px solid var(--primary-blue);
    outline-offset: 3px;
}

/* ---------- How-it-works lightbox ---------- */
.ps-how-lb-overlay {
    position: fixed;
    inset: 0;
    background: rgba(10, 18, 36, 0.65);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 300;
    animation: ps-overlay-in 220ms ease both;
}

.ps-how-lb {
    position: fixed;
    inset: 0;
    z-index: 301;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px 72px;
    pointer-events: none;
}

/* Respect [hidden] attribute on lightbox + modal containers — */
/* without this, `display: flex` would override the UA `[hidden]` rule. */
.ps-how-lb[hidden],
.ps-how-lb-overlay[hidden],
.ps-modal[hidden],
.ps-modal-overlay[hidden] {
    display: none !important;
}

.ps-how-lb-inner {
    pointer-events: all;
    background: var(--bg-white);
    border-radius: var(--radius-2xl);
    box-shadow: 0 32px 80px rgba(0,0,0,0.28);
    display: grid;
    grid-template-columns: 1.4fr 1fr;
    overflow: hidden;
    width: 100%;
    max-width: 860px;
    max-height: calc(100vh - 80px);
    animation: ps-lb-in 280ms var(--ease-out-back) both;
}

@keyframes ps-lb-in {
    from { opacity: 0; transform: scale(0.92); }
    to   { opacity: 1; transform: scale(1); }
}

.ps-how-lb-media {
    background: linear-gradient(135deg, var(--primary-blue-light) 0%, var(--bg-light) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    overflow: hidden;
}

.ps-how-lb-video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.ps-how-lb-body {
    padding: 40px 36px;
    display: flex;
    flex-direction: column;
    justify-content: center;
    gap: 12px;
}

.ps-how-lb-step {
    font-size: 3rem;
    font-weight: 800;
    color: var(--primary-blue);
    opacity: 0.15;
    line-height: 1;
    letter-spacing: -0.04em;
}

.ps-how-lb-body h3 {
    font-size: var(--text-2xl);
    font-weight: 800;
    color: var(--text-dark);
    line-height: 1.2;
    margin: 0;
}

.ps-how-lb-body p {
    font-size: var(--text-base);
    line-height: 1.7;
    color: var(--text-body);
    margin: 0;
}

.ps-how-lb-dots {
    display: flex;
    gap: 8px;
    margin-top: 8px;
}

.ps-how-lb-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--border-light);
    transition: background 200ms ease, transform 200ms ease;
    cursor: pointer;
}

.ps-how-lb-dot.is-active {
    background: var(--primary-blue);
    transform: scale(1.3);
}

/* Nav buttons */
.ps-how-lb-close {
    pointer-events: all;
    position: fixed;
    top: 20px;
    right: 20px;
    z-index: 302;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    border: 1.5px solid rgba(255,255,255,0.3);
    background: rgba(255,255,255,0.15);
    backdrop-filter: blur(6px);
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 180ms ease;
}

.ps-how-lb-close:hover { background: rgba(255,255,255,0.28); }
.ps-how-lb-close i { width: 20px; height: 20px; }

.ps-how-lb-nav {
    pointer-events: all;
    position: fixed;
    top: 50%;
    transform: translateY(-50%);
    z-index: 302;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    border: 1.5px solid rgba(255,255,255,0.3);
    background: rgba(255,255,255,0.15);
    backdrop-filter: blur(6px);
    color: #fff;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 180ms ease, opacity 180ms ease;
}

.ps-how-lb-nav:hover { background: rgba(255,255,255,0.28); }
.ps-how-lb-nav:disabled { opacity: 0.25; cursor: default; }
.ps-how-lb-nav i { width: 22px; height: 22px; }

.ps-how-lb-prev { left: 16px; }
.ps-how-lb-next { right: 16px; }

/* Responsive lightbox */
@media (max-width: 768px) {
    .ps-how-lb {
        padding: 16px;
        align-items: flex-end;
    }

    .ps-how-lb-inner {
        grid-template-columns: 1fr;
        grid-template-rows: 1fr auto;
        max-height: 90vh;
        border-radius: var(--radius-xl) var(--radius-xl) 0 0;
    }

    .ps-how-lb-media {
        aspect-ratio: 16 / 9;
        max-height: 45vw;
    }

    .ps-how-lb-body {
        padding: 24px 20px;
    }

    .ps-how-lb-body h3 {
        font-size: var(--text-xl);
    }

    .ps-how-lb-nav {
        top: auto;
        bottom: 24px;
        transform: none;
    }

    .ps-how-lb-prev { left: 16px; }
    .ps-how-lb-next { right: 16px; }
}

/* ---------- Info strip ---------- */
.ps-info-strip {
    padding-bottom: 64px;
}

.ps-info-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
    background: var(--bg-white);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-xl);
    padding: 24px 28px;
}

.ps-info-item {
    display: flex;
    align-items: center;
    gap: 14px;
}

.ps-info-item > i {
    width: 28px;
    height: 28px;
    color: var(--primary-blue);
    flex-shrink: 0;
}

.ps-info-item div {
    display: flex;
    flex-direction: column;
}

.ps-info-label {
    font-size: var(--text-xs);
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    font-weight: 600;
}

.ps-info-item strong {
    font-size: var(--text-sm);
    font-weight: 700;
    color: var(--text-dark);
}

/* ---------- Booking section ---------- */
.ps-book {
    padding: 32px 0 64px;
    scroll-margin-top: 90px;
}

.ps-book-layout {
    display: grid;
    grid-template-columns: 1fr 360px;
    gap: 32px;
    margin-top: 32px;
    align-items: start;
}

.ps-book-main {
    display: flex;
    flex-direction: column;
    gap: 24px;
    min-width: 0; /* prevent grid-children min-content from overflowing the track */
}

/* Court info card */
.ps-court-card {
    background: var(--bg-white);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-xl);
    padding: 24px 28px;
}

.ps-court-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
    flex-wrap: wrap;
    gap: 8px;
}

.ps-court-head h3 {
    font-size: var(--text-xl);
    font-weight: 700;
    color: var(--text-dark);
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.ps-court-head h3 i {
    width: 20px;
    height: 20px;
    color: var(--text-faint);
}

.ps-court-loc {
    font-size: var(--text-sm);
    color: var(--text-muted);
    font-weight: 500;
}

.ps-court-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.ps-court-tag {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    padding: 6px 12px;
    background: var(--bg-light);
    border-radius: var(--radius-pill);
    font-size: var(--text-xs);
    font-weight: 600;
    color: var(--text-body);
}

.ps-court-tag i {
    width: 14px;
    height: 14px;
}

/* Date strip */
.ps-date-section {
    background: var(--bg-white);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-xl);
    padding: 24px 28px;
}

.ps-date-head {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 16px;
}

.ps-date-head h4 {
    font-size: var(--text-base);
    font-weight: 700;
    color: var(--text-dark);
}

.ps-date-nav {
    display: flex;
    gap: 8px;
}

.ps-date-arrow {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    border: 1px solid var(--border-light);
    background: var(--bg-white);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--text-body);
    transition: all var(--duration-fast);
}

.ps-date-arrow:hover {
    background: var(--bg-light);
    color: var(--primary-blue);
}

.ps-date-arrow i {
    width: 16px;
    height: 16px;
}

.ps-date-strip {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
    padding-bottom: 4px;
}

.ps-date-strip::-webkit-scrollbar { display: none; }

.ps-date-pill {
    flex: 0 0 auto;
    min-width: 76px;
    padding: 12px 14px;
    border-radius: var(--radius-md);
    border: 1px solid var(--border-light);
    background: var(--bg-white);
    cursor: pointer;
    text-align: center;
    scroll-snap-align: start;
    transition: all var(--duration-fast);
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.ps-date-pill:hover {
    border-color: var(--primary-blue);
}

.ps-date-pill.is-active {
    background: var(--primary-blue);
    border-color: var(--primary-blue);
    color: var(--bg-white);
}

.ps-date-pill .ps-date-day {
    font-size: var(--text-xs);
    font-weight: 600;
    text-transform: uppercase;
    color: var(--text-muted);
    letter-spacing: 0.5px;
}

.ps-date-pill.is-active .ps-date-day { color: rgba(255,255,255,0.85); }

.ps-date-pill .ps-date-num {
    font-size: var(--text-xl);
    font-weight: 800;
    color: var(--text-dark);
    line-height: 1.2;
}

.ps-date-pill.is-active .ps-date-num { color: var(--bg-white); }

.ps-date-pill .ps-date-mon {
    font-size: var(--text-xs);
    color: var(--text-muted);
    font-weight: 600;
}

.ps-date-pill.is-active .ps-date-mon { color: rgba(255,255,255,0.85); }

/* Slot section */
.ps-slot-section {
    background: var(--bg-white);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-xl);
    padding: 0;
    overflow: hidden;
}

.ps-slot-toggle {
    width: 100%;
    background: var(--primary-blue);
    color: var(--bg-white);
    border: 0;
    padding: 14px 24px;
    font-family: var(--font-main);
    font-size: var(--text-base);
    font-weight: 700;
    cursor: pointer;
    display: flex;
    justify-content: space-between;
    align-items: center;
    transition: background var(--duration-fast);
}

.ps-slot-toggle:hover { background: var(--primary-blue-hover); }

.ps-slot-toggle i {
    width: 18px;
    height: 18px;
    transition: transform var(--duration-normal);
}

.ps-slot-toggle[aria-expanded="false"] i {
    transform: rotate(180deg);
}

.ps-slot-grid {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    padding: 24px;
    transition: max-height var(--duration-normal) var(--ease-out-expo);
}

.ps-slot-grid.is-collapsed {
    display: none;
}

.ps-slot-card {
    border: 1px solid var(--border-light);
    border-radius: var(--radius-md);
    padding: 16px 14px;
    background: var(--bg-white);
    cursor: pointer;
    text-align: center;
    transition: all var(--duration-fast);
}

.ps-slot-card:hover {
    border-color: var(--primary-blue);
    transform: translateY(-2px);
    box-shadow: var(--shadow-sm);
}

.ps-slot-card.is-selected {
    border-color: var(--primary-blue);
    background: var(--primary-blue-10);
    box-shadow: 0 0 0 2px rgba(0,102,255,.12);
}

/* Multi-select checkmark on selected slot */
.ps-slot-card.is-selected::after {
    content: '✓';
    position: absolute;
    top: 6px;
    right: 8px;
    font-size: 11px;
    font-weight: 800;
    color: var(--primary-blue);
}
.ps-slot-card { position: relative; }

/* "N dipilih" badge in slot toggle header */
.ps-slot-selected-badge {
    color: var(--primary-blue);
    font-weight: 700;
}

.ps-slot-card.is-disabled {
    opacity: 0.45;
    pointer-events: none;
    background: var(--bg-light);
}

.ps-slot-duration {
    display: block;
    font-size: var(--text-xs);
    color: var(--text-muted);
    font-weight: 600;
    margin-bottom: 4px;
}

.ps-slot-time {
    display: block;
    font-size: var(--text-base);
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 6px;
}

.ps-slot-original {
    display: block;
    font-size: var(--text-xs);
    color: var(--text-muted);
    text-decoration: line-through;
    line-height: 1.2;
}

.ps-slot-price {
    display: block;
    font-size: var(--text-sm);
    color: var(--text-dark);
    font-weight: 700;
}

/* Date strip wrapper — needed for slide animation overflow clip */
.ps-date-strip-wrap {
    overflow: hidden;
}

/* Racket addon section */
.ps-addon-section {
    background: var(--bg-white);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-xl);
    padding: 20px 24px;
}

.ps-addon-label-row {
    display: flex;
    align-items: baseline;
    gap: 10px;
    margin-bottom: 14px;
}

.ps-addon-heading {
    font-size: var(--text-base);
    font-weight: 700;
    color: var(--text-dark);
}

.ps-addon-sub {
    font-size: var(--text-xs);
    color: var(--text-muted);
}

.ps-addon-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 12px;
}

.ps-addon-card {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 16px 18px;
    border: 1.5px solid var(--border-light);
    border-radius: var(--radius-md);
    background: var(--bg-white);
    cursor: pointer;
    text-align: left;
    font-family: var(--font-main);
    transition: all var(--duration-fast);
}

.ps-addon-card:hover { border-color: var(--primary-blue); }

.ps-addon-card.is-selected {
    border-color: var(--primary-blue);
    background: var(--primary-blue-10);
    box-shadow: 0 0 0 2px rgba(0,102,255,0.08);
}

.ps-addon-icon {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    border-radius: var(--radius-md);
    background: var(--bg-light);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: var(--primary-blue);
    transition: background var(--duration-fast);
}

.ps-addon-card.is-selected .ps-addon-icon { background: var(--bg-white); }
.ps-addon-icon i { width: 20px; height: 20px; }

.ps-addon-body {
    flex: 1;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.ps-addon-body strong {
    font-size: var(--text-sm);
    font-weight: 700;
    color: var(--text-dark);
}

.ps-addon-body span {
    font-size: var(--text-xs);
    color: var(--text-muted);
    line-height: 1.4;
}

.ps-addon-free {
    flex-shrink: 0;
    font-size: var(--text-sm);
    font-weight: 700;
    color: var(--text-muted);
    white-space: nowrap;
}

.ps-addon-price {
    flex-shrink: 0;
    font-size: var(--text-sm);
    font-weight: 700;
    color: var(--primary-blue);
    white-space: nowrap;
}

.ps-addon-price small {
    font-size: var(--text-xs);
    font-weight: 500;
    color: var(--text-muted);
}

/* Calendar */
.ps-calendar {
    margin-top: 16px;
    border: 1px solid var(--border-light);
    border-radius: var(--radius-lg);
    padding: 16px;
    background: var(--bg-white);
    animation: ps-cal-in 200ms var(--ease-out-expo) both;
}

@keyframes ps-cal-in {
    from { opacity: 0; transform: translateY(-8px); }
    to   { opacity: 1; transform: translateY(0); }
}

.ps-cal-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 14px;
}

.ps-cal-title {
    font-size: var(--text-sm);
    font-weight: 700;
    color: var(--text-dark);
}

.ps-cal-arrow {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    border: 1px solid var(--border-light);
    background: var(--bg-white);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--text-body);
    transition: all var(--duration-fast);
}

.ps-cal-arrow:hover { background: var(--bg-light); }

.ps-cal-arrow i { width: 14px; height: 14px; }

.ps-cal-grid {
    display: grid;
    grid-template-columns: repeat(7, 1fr);
    gap: 4px;
    text-align: center;
}

.ps-cal-dow {
    font-size: 10px;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    padding: 4px 0;
}

.ps-cal-day {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: var(--radius-sm);
    font-size: var(--text-sm);
    font-weight: 500;
    cursor: pointer;
    border: 1px solid transparent;
    background: none;
    color: var(--text-body);
    font-family: var(--font-main);
    transition: all var(--duration-fast);
}

.ps-cal-day:hover:not(:disabled) {
    background: var(--bg-light);
    border-color: var(--border-light);
}

.ps-cal-day.is-active {
    background: var(--primary-blue);
    color: #fff;
    border-color: var(--primary-blue);
    font-weight: 700;
}

.ps-cal-day.is-today:not(.is-active) {
    border-color: var(--primary-blue);
    color: var(--primary-blue);
    font-weight: 700;
}

.ps-cal-day:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.ps-cal-day.is-empty {
    cursor: default;
}

/* Racket modal */
.ps-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.45);
    z-index: 200;
    animation: ps-overlay-in 200ms ease both;
}

@keyframes ps-overlay-in {
    from { opacity: 0; }
    to   { opacity: 1; }
}

.ps-modal {
    position: fixed;
    left: 50%;
    top: 50%;
    transform: translate(-50%, -50%);
    z-index: 201;
    background: var(--bg-white);
    border-radius: var(--radius-xl);
    width: 90%;
    max-width: 560px;
    max-height: 90vh;
    overflow-y: auto;
    box-shadow: var(--shadow-xl);
    animation: ps-modal-in 250ms var(--ease-out-back) both;
}

@keyframes ps-modal-in {
    from { opacity: 0; transform: translate(-50%, calc(-50% + 20px)); }
    to   { opacity: 1; transform: translate(-50%, -50%); }
}

.ps-modal-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    padding: 24px 24px 0;
}

.ps-modal-head h3 {
    font-size: var(--text-xl);
    font-weight: 800;
    color: var(--text-dark);
}

.ps-modal-head p {
    font-size: var(--text-sm);
    color: var(--text-muted);
    margin-top: 2px;
}

.ps-modal-close {
    flex-shrink: 0;
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border: 1px solid var(--border-light);
    background: var(--bg-white);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--text-body);
    transition: background var(--duration-fast);
}

.ps-modal-close:hover { background: var(--bg-light); }
.ps-modal-close i { width: 18px; height: 18px; }

.ps-modal-body {
    padding: 20px 24px;
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.ps-modal-section-label {
    font-size: var(--text-xs);
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 1px;
    color: var(--text-muted);
}

.ps-modal-section-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
}

/* Pagination — arrow style */
.ps-racket-pagination {
    display: flex;
    gap: 6px;
    align-items: center;
}

.ps-racket-arrow-btn {
    width: 28px;
    height: 28px;
    border-radius: var(--radius-sm);
    border: 1.5px solid var(--border-light);
    background: var(--bg-white);
    color: var(--text-body);
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: all var(--duration-fast);
    padding: 0;
}
.ps-racket-arrow-btn svg { width: 14px; height: 14px; }
.ps-racket-arrow-btn:hover:not(:disabled) {
    border-color: var(--primary-blue);
    color: var(--primary-blue);
}
.ps-racket-arrow-btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.ps-racket-page-indicator {
    font-size: var(--text-xs);
    color: var(--text-muted);
    padding: 0 4px;
    font-weight: 600;
}

.ps-racket-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 10px;
}

.ps-racket-opt {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    padding: 14px 10px;
    border: 1.5px solid var(--border-light);
    border-radius: var(--radius-lg);
    background: var(--bg-white);
    cursor: pointer;
    text-align: center;
    font-family: var(--font-main);
    transition: all var(--duration-fast);
}

.ps-racket-opt:hover:not(.is-unavailable) { border-color: var(--primary-blue); }

.ps-racket-opt.is-selected {
    border-color: var(--primary-blue);
    background: var(--primary-blue-10);
}

.ps-racket-opt.is-unavailable {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
    background: var(--bg-light);
}

.ps-racket-unavail-badge {
    font-size: 9px;
    font-weight: 700;
    color: var(--text-muted);
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-top: 2px;
    display: block;
}

.ps-racket-img-wrap {
    width: 72px;
    height: 72px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.ps-racket-img-wrap img {
    max-width: 100%;
    max-height: 100%;
    object-fit: contain;
}

.ps-racket-info {
    display: flex;
    flex-direction: column;
    gap: 2px;
}

.ps-racket-info strong {
    font-size: var(--text-xs);
    font-weight: 700;
    color: var(--text-dark);
    line-height: 1.3;
}

.ps-racket-info span {
    font-size: 10px;
    color: var(--text-muted);
}

.ps-dur-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
}

.ps-dur-opt {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    padding: 14px 16px;
    border: 1.5px solid var(--border-light);
    border-radius: var(--radius-md);
    background: var(--bg-white);
    cursor: pointer;
    font-family: var(--font-main);
    transition: all var(--duration-fast);
}

.ps-dur-opt:hover { border-color: var(--primary-blue); }

.ps-dur-opt.is-selected {
    border-color: var(--primary-blue);
    background: var(--primary-blue-10);
}

.ps-dur-opt strong {
    font-size: var(--text-base);
    font-weight: 700;
    color: var(--text-dark);
}

.ps-dur-opt span {
    font-size: var(--text-sm);
    color: var(--text-body);
}

.ps-dur-opt em {
    font-style: normal;
    font-size: var(--text-xs);
    font-weight: 700;
    color: var(--primary-blue);
    margin-left: 6px;
}

.ps-modal-foot {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    padding: 0 24px 24px;
    border-top: 1px solid var(--border-light);
    padding-top: 16px;
}

/* Summary breakdown lines (line items above total) */
.ps-summary-breakdown {
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding-bottom: 14px;
    margin-bottom: 14px;
    border-bottom: 1px dashed var(--border-light);
}

.ps-summary-line {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: var(--text-sm);
    color: var(--text-body);
}

.ps-summary-line span:last-child {
    font-weight: 600;
    color: var(--text-dark);
}

/* Summary card (right rail desktop) */
.ps-summary-card {
    background: var(--bg-white);
    border: 1px solid var(--border-light);
    border-radius: var(--radius-xl);
    padding: 24px 24px 20px;
    position: sticky;
    top: 100px;
}

.ps-summary-card h4 {
    font-size: var(--text-lg);
    font-weight: 700;
    color: var(--text-dark);
    margin-bottom: 16px;
}

.ps-summary-rows {
    display: flex;
    flex-direction: column;
    gap: 12px;
    padding-bottom: 16px;
    border-bottom: 1px dashed var(--border-light);
    margin-bottom: 16px;
}

.ps-summary-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: var(--text-sm);
    color: var(--text-body);
}

.ps-summary-row strong {
    color: var(--text-dark);
    font-weight: 700;
    text-align: right;
}

.ps-summary-total {
    display: flex;
    justify-content: space-between;
    align-items: flex-end;
    margin-bottom: 16px;
}

.ps-summary-total > span {
    font-size: var(--text-sm);
    color: var(--text-muted);
    font-weight: 600;
}

.ps-summary-total-price {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 2px;
}

.ps-price-original {
    font-size: var(--text-xs);
    color: var(--text-muted);
    text-decoration: line-through;
}

.ps-summary-total-price strong {
    font-size: var(--text-xl);
    font-weight: 800;
    color: var(--primary-blue);
}

.ps-book-cta {
    width: 100%;
    justify-content: center;
}

.ps-book-cta:disabled {
    opacity: 0.5;
    cursor: not-allowed;
    pointer-events: none;
}

.ps-summary-note {
    margin-top: 12px;
    font-size: var(--text-xs);
    color: var(--text-muted);
    display: flex;
    align-items: center;
    gap: 6px;
    justify-content: center;
}

.ps-summary-note i {
    width: 14px;
    height: 14px;
}

/* ---------- Sticky bottom CTA (mobile only) ---------- */
.ps-sticky-cta {
    display: none;
    position: fixed;
    left: 0;
    right: 0;
    bottom: 0;
    z-index: 60;
    background: var(--bg-white);
    border-top: 1px solid var(--border-light);
    box-shadow: 0 -8px 24px rgba(0,0,0,0.08);
    padding: 12px 16px;
    align-items: center;
    gap: 12px;
}

.ps-sticky-info {
    display: flex;
    flex-direction: column;
    flex: 1;
    min-width: 0;
}

.ps-sticky-label {
    font-size: var(--text-xs);
    color: var(--text-muted);
    font-weight: 600;
}

.ps-sticky-price {
    font-size: var(--text-base);
    color: var(--text-dark);
    font-weight: 800;
}

.ps-sticky-btn {
    flex-shrink: 0;
}

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

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
    .ps-hero-grid {
        grid-template-columns: 1fr;
        padding: 40px 32px;
    }

    .ps-hero-visual {
        order: -1;
        aspect-ratio: 16 / 9;
        max-width: 480px;
        margin: 0 auto;
    }

    .ps-how-grid {
        grid-template-columns: 1fr;
        gap: 16px;
        max-width: 480px;
        margin-left: auto;
        margin-right: auto;
    }

    /* Vertical card layout: large image on top, text below.
       Cap the media height so it doesn't take the whole viewport. */
    .ps-how-card {
        padding: 20px;
    }

    .ps-how-img-wrap {
        aspect-ratio: 16 / 9;
        max-height: 280px;
        margin-bottom: 16px;
    }

    .ps-how-img,
    .ps-how-video {
        object-fit: contain;
    }

    .ps-info-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .ps-book-layout {
        grid-template-columns: 1fr;
    }

    .ps-summary-card {
        position: static;
    }

    .ps-slot-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

@media (max-width: 768px) {
    .ps-body main {
        padding-bottom: 110px; /* leave room for sticky CTA */
    }

    .ps-body .breadcrumb {
        padding-top: 90px;
        margin-bottom: 16px;
    }

    .ps-hero {
        padding-bottom: 48px;
    }

    .ps-hero-grid {
        padding: 28px 20px;
        border-radius: var(--radius-xl);
        /* Let the hero grow with its content. Without an explicit auto height
           the visual's aspect-ratio box could clip the body copy underneath it. */
        height: auto;
        overflow: visible;
    }

    /* Visual sits on top on phones — cap its height so it doesn't eat the
       screen and push the heading + CTA out of view. */
    .ps-hero-visual {
        order: -1;
        width: 100%;
        max-width: 100%;
        aspect-ratio: auto;
        max-height: 240px;
        padding: 20px;
    }

    .ps-hero-img {
        max-height: 200px;
    }

    .ps-hero-body h1 {
        font-size: 1.85rem;
    }

    .ps-hero-actions {
        flex-direction: column;
    }

    .ps-hero-actions .btn { width: 100%; justify-content: center; }

    .ps-how {
        padding: 56px 0;
    }

    /* Cara kerja cards: force each card to stay within the phone width.
       Grid items default to min-width:auto, which lets wide content (the
       video) blow the track out past the viewport — pinning min-width:0 +
       an explicit max-width keeps every card inside the screen. */
    .ps-how-grid {
        grid-template-columns: 1fr;
        max-width: 100%;
        margin-left: 0;
        margin-right: 0;
        gap: 14px;
    }

    .ps-how-card {
        min-width: 0;
        max-width: 100%;
        width: 100%;
        padding: 18px;
    }

    /* Tutorial image cap on phone — keep cards readable instead of giant blocks. */
    .ps-how-img-wrap {
        aspect-ratio: 16 / 9;
        max-height: 220px;
        min-width: 0;
    }

    .ps-info-grid {
        grid-template-columns: 1fr;
        padding: 20px;
    }

    .ps-court-card,
    .ps-date-section {
        padding: 18px 20px;
    }

    .ps-slot-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
        padding: 18px;
    }

    .ps-addon-section { padding: 14px 16px; }
    .ps-addon-grid { grid-template-columns: 1fr; }
    .ps-racket-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
    .ps-modal { max-width: calc(100% - 32px); }

    .ps-summary-card {
        padding: 20px;
    }

    /* Hide desktop CTA in summary on mobile (sticky bar takes over) */
    .ps-summary-card .ps-book-cta {
        display: none;
    }

    .ps-summary-card .ps-summary-note {
        display: none;
    }

    .ps-sticky-cta {
        display: flex;
    }
}

@media (max-width: 480px) {
    .ps-slot-grid {
        /* Keep 2 columns on phones — 1 column makes the slot list way too tall. */
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
        padding: 14px;
    }

    .ps-slot-card { padding: 12px 10px; }

    .ps-hero-body h1 {
        font-size: 1.65rem;
    }

    /* Modal footer: stack the two CTAs so they never overflow on narrow phones. */
    .ps-modal-foot {
        flex-direction: column-reverse;
        gap: 8px;
    }
    .ps-modal-foot .btn { width: 100%; justify-content: center; }

    /* Date head: keep title + arrows on the same row even on very small screens. */
    .ps-date-head h4 { font-size: var(--text-sm); }
    .ps-date-nav { gap: 6px; }
    .ps-date-arrow { width: 30px; height: 30px; }
}
