/* ===========================================================================
   BOOKING — the global "Secure your charter" popup (book-modal.php) and the
   inline passenger panel on the tour pages (book-panel.php).
   Loaded on every page from header.php. Behaviour in assets/js/booking.js.
   =========================================================================== */

/* ---------------------------------------------------------------------------
   Popup shell — a deep-water screen with four glass cards on it
   --------------------------------------------------------------------------- */
.book-modal {
    position: fixed;
    inset: 0;
    z-index: 120;
    display: grid;
    place-items: center;
    padding: clamp(0.5rem, 2.5vw, 1.5rem);
    opacity: 0;
    transition: opacity 0.35s var(--ease);
}

.book-modal.is-open { opacity: 1; }
.book-modal[hidden] { display: none; }

.book-modal__overlay {
    position: absolute;
    inset: 0;
    background: rgba(3, 21, 31, 0.72);
    -webkit-backdrop-filter: blur(8px);
    backdrop-filter: blur(8px);
}

.book-modal__dialog {
    position: relative;
    width: 100%;
    max-width: 1120px;
    max-height: calc(100svh - 1rem);
    overflow-y: auto;
    overscroll-behavior: contain;
    padding: clamp(1.25rem, 3.5vw, 2.5rem);
    background:
        radial-gradient(90% 60% at 15% 0%, rgba(41, 145, 215, 0.22) 0%, rgba(41, 145, 215, 0) 60%),
        linear-gradient(170deg, #0A3352 0%, var(--navy-d) 55%, #031A27 100%);
    color: var(--white);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 28px;
    box-shadow: 0 40px 100px rgba(0, 0, 0, 0.55);
    transform: translateY(18px) scale(0.985);
    transition: transform 0.45s var(--ease);
    text-align: left;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}

.book-modal.is-open .book-modal__dialog { transform: none; }

.book-modal__close {
    position: absolute;
    top: clamp(0.875rem, 2.5vw, 1.5rem);
    right: clamp(0.875rem, 2.5vw, 1.5rem);
    z-index: 3;
    display: grid;
    place-items: center;
    width: 42px;
    height: 42px;
    padding: 0;
    background: rgba(255, 255, 255, 0.08);
    color: var(--white);
    border: 1px solid rgba(255, 255, 255, 0.16);
    border-radius: 50%;
    cursor: pointer;
    transition: background 0.3s var(--ease), transform 0.3s var(--ease);
}
.book-modal__close:hover { background: rgba(255, 255, 255, 0.18); transform: rotate(90deg); }
.book-modal__close svg { width: 18px; height: 18px; }

/* Heading */
.charter-head { padding-right: 3.5rem; margin-bottom: clamp(1.25rem, 3vw, 2rem); }

.charter-head__title {
    margin: 0;
    font-family: var(--font-display);
    font-size: clamp(1.875rem, 1.3rem + 2.4vw, 3rem);
    font-weight: 700;
    line-height: 1.05;
    letter-spacing: -0.02em;
    color: var(--white);
}
.charter-head__title span { color: var(--turq); }

.charter-head__sub {
    margin: 0.5rem 0 0;
    font-family: var(--font-ui);
    font-size: 0.9375rem;
    color: rgba(255, 255, 255, 0.7);
}

/* ---------------------------------------------------------------------------
   Grid of cards
   --------------------------------------------------------------------------- */
.book-form { display: block; }

.charter-grid {
    display: grid;
    gap: clamp(0.875rem, 1.8vw, 1.25rem);
}

@media (min-width: 900px) {
    .charter-grid {
        grid-template-columns: minmax(0, 1.55fr) minmax(0, 1fr);
        grid-template-areas:
            "route when"
            "pax   pay";
    }
    .charter-card--route { grid-area: route; }
    .charter-card--when  { grid-area: when; }
    .charter-card--pax   { grid-area: pax; }
    .charter-card--pay   { grid-area: pay; }
}

.charter-card {
    margin: 0;
    min-width: 0;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: clamp(1.125rem, 2.4vw, 1.5rem);
    background: rgba(255, 255, 255, 0.045);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 22px;
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.06);
}

.charter-card__head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.75rem;
    flex-wrap: wrap;
}

.charter-card__title {
    display: inline-flex;
    align-items: center;
    gap: 0.625rem;
    font-family: var(--font-ui);
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--white);
}

.charter-card__no {
    display: grid;
    place-items: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(56, 225, 197, 0.16);
    color: var(--turq);
    font-size: 0.6875rem;
    font-weight: 800;
    letter-spacing: 0.04em;
}

.charter-badge {
    padding: 0.375rem 0.875rem;
    background: rgba(138, 240, 223, 0.16);
    border: 1px solid rgba(138, 240, 223, 0.4);
    border-radius: 999px;
    font-family: var(--font-ui);
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--turq-l);
}

.charter-label {
    display: block;
    font-family: var(--font-ui);
    font-size: 0.6875rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.55);
}

.charter-fine {
    margin: 0;
    font-family: var(--font-ui);
    font-size: 0.75rem;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.55);
}
.charter-fine--center { text-align: center; }

/* ---------------------------------------------------------------------------
   01 — trip chooser + route chart
   --------------------------------------------------------------------------- */
.charter-trips {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.5rem;
}

.charter-trip {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: 0.15rem;
    padding: 0.75rem 0.875rem;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 14px;
    cursor: pointer;
    transition: background 0.3s var(--ease), border-color 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

.charter-trip:hover { background: rgba(255, 255, 255, 0.08); }

.charter-trip:has(:checked) {
    background: rgba(56, 225, 197, 0.12);
    border-color: var(--turq);
    box-shadow: 0 0 0 1px var(--turq) inset;
}

.charter-trip:has(:focus-visible) { outline: 3px solid var(--turq); outline-offset: 2px; }

.charter-trip__radio { position: absolute; opacity: 0; pointer-events: none; }

.charter-trip__name {
    font-family: var(--font-ui);
    font-size: 0.875rem;
    font-weight: 700;
    line-height: 1.25;
    color: var(--white);
}

.charter-trip__meta {
    font-family: var(--font-ui);
    font-size: 0.6875rem;
    font-weight: 600;
    color: rgba(255, 255, 255, 0.6);
}

.charter-map {
    position: relative;
    overflow: hidden;
    border-radius: 16px;
    background:
        radial-gradient(80% 90% at 40% 80%, rgba(41, 145, 215, 0.16), rgba(41, 145, 215, 0) 70%),
        rgba(2, 18, 28, 0.55);
    border: 1px solid rgba(255, 255, 255, 0.08);
}

.charter-map__svg { width: 100%; height: auto; }

.charter-map__land {
    fill: rgba(255, 255, 255, 0.06);
    stroke: rgba(255, 255, 255, 0.22);
    stroke-width: 1;
}

.charter-map__labels text {
    font-family: var(--font-ui);
    font-size: 9px;
    font-weight: 700;
    letter-spacing: 0.16em;
    fill: rgba(255, 255, 255, 0.42);
    text-anchor: middle;
}

.charter-map__labels .charter-map__sea { font-size: 10px; letter-spacing: 0.5em; fill: rgba(255, 255, 255, 0.18); }

.charter-route { opacity: 0; transition: opacity 0.4s var(--ease); }
.charter-route.is-on { opacity: 1; }

.charter-route__ghost {
    fill: none;
    stroke: rgba(56, 225, 197, 0.22);
    stroke-width: 1.5;
    stroke-dasharray: 2 6;
    stroke-linecap: round;
}

.charter-route__line {
    fill: none;
    stroke: var(--turq);
    stroke-width: 2.5;
    stroke-linecap: round;
    filter: drop-shadow(0 0 6px rgba(56, 225, 197, 0.6));
}

.charter-map__dest circle:first-child { animation: dest-ping 2.4s var(--ease-io) infinite; transform-box: fill-box; transform-origin: center; }

@keyframes dest-ping {
    0%   { transform: scale(0.6); opacity: 0.9; }
    100% { transform: scale(1.8); opacity: 0; }
}

/* Departure ↔ destination strip */
.charter-legs {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    padding: 0.75rem 0.875rem;
    background: rgba(2, 18, 28, 0.45);
    border: 1px solid rgba(255, 255, 255, 0.08);
    border-radius: 14px;
}

.charter-leg { display: flex; align-items: center; gap: 0.625rem; min-width: 0; }
.charter-leg--end { text-align: right; }

.charter-leg__icon {
    display: grid;
    place-items: center;
    flex-shrink: 0;
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.08);
    color: var(--turq);
}
.charter-leg__icon svg { width: 17px; height: 17px; }

.charter-leg__label {
    display: block;
    font-family: var(--font-ui);
    font-size: 0.625rem;
    font-weight: 700;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: rgba(255, 255, 255, 0.5);
}

.charter-leg__value {
    display: block;
    font-family: var(--font-ui);
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--white);
}

.charter-legs__line {
    position: relative;
    flex: 1;
    min-width: 24px;
    height: 2px;
    border-radius: 2px;
    background: rgba(255, 255, 255, 0.14);
}

.charter-legs__line span {
    position: absolute;
    top: 50%;
    left: 0;
    width: 7px;
    height: 7px;
    margin-top: -3.5px;
    border-radius: 50%;
    background: var(--turq);
    box-shadow: 0 0 10px var(--turq);
    animation: leg-travel 3s var(--ease-io) infinite;
}

@keyframes leg-travel {
    0%   { left: 0; }
    100% { left: calc(100% - 7px); }
}

/* ---------------------------------------------------------------------------
   02 — date & time
   --------------------------------------------------------------------------- */
.charter-days {
    display: flex;
    gap: 0.5rem;
    overflow-x: auto;
    padding-bottom: 0.25rem;
    scrollbar-width: none;
}
.charter-days::-webkit-scrollbar { display: none; }

.charter-day {
    flex: 0 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.1rem;
    min-width: 58px;
    padding: 0.625rem 0.5rem;
    background: rgba(255, 255, 255, 0.04);
    color: var(--white);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-radius: 14px;
    cursor: pointer;
    font-family: var(--font-ui);
    transition: background 0.3s var(--ease), border-color 0.3s var(--ease), color 0.3s var(--ease);
}

.charter-day:hover { background: rgba(255, 255, 255, 0.09); }

.charter-day.is-on {
    background: var(--turq-l);
    border-color: var(--turq-l);
    color: var(--navy);
}

.charter-day__dow { font-size: 0.625rem; font-weight: 700; letter-spacing: 0.1em; text-transform: uppercase; opacity: 0.75; }
.charter-day__num { font-family: var(--font-display); font-size: 1.375rem; font-weight: 800; line-height: 1.1; }
.charter-day__mon { font-size: 0.625rem; font-weight: 600; opacity: 0.7; }

.charter-other { display: flex; align-items: center; justify-content: space-between; gap: 0.75rem; }

.charter-input {
    width: 100%;
    padding: 0.8125rem 1rem;
    background: var(--white);
    color: var(--navy);
    font-family: var(--font-ui);
    font-size: 0.9375rem;
    font-weight: 600;
    border: 2px solid transparent;
    border-radius: 12px;
    transition: border-color 0.3s var(--ease), box-shadow 0.3s var(--ease);
}

.charter-input::placeholder { color: #7D8C97; font-weight: 500; }

.charter-input:focus {
    outline: none;
    border-color: var(--turq);
    box-shadow: 0 0 0 4px rgba(56, 225, 197, 0.25);
}

.charter-input.is-error { border-color: var(--coral); }

.charter-input--date {
    width: auto;
    padding: 0.5rem 0.75rem;
    font-size: 0.875rem;
    background: rgba(255, 255, 255, 0.08);
    color: var(--white);
    border: 1px solid rgba(255, 255, 255, 0.16);
    color-scheme: dark;
}

.charter-slots-wrap { display: grid; gap: 0.625rem; }

.charter-slots {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.5rem;
}

.charter-slots.is-many { grid-template-columns: repeat(3, minmax(0, 1fr)); }

.charter-slot { position: relative; cursor: pointer; }

.charter-slot__radio { position: absolute; opacity: 0; pointer-events: none; }

.charter-slot span {
    display: block;
    padding: 0.75rem 0.5rem;
    text-align: center;
    background: rgba(255, 255, 255, 0.04);
    border: 1px solid rgba(255, 255, 255, 0.14);
    border-radius: 12px;
    font-family: var(--font-ui);
    font-size: 0.9375rem;
    font-weight: 700;
    color: var(--white);
    font-variant-numeric: tabular-nums;
    transition: background 0.3s var(--ease), border-color 0.3s var(--ease), color 0.3s var(--ease);
}

.charter-slots.is-many .charter-slot span { padding: 0.5625rem 0.25rem; font-size: 0.875rem; }

.charter-slot:hover span { background: rgba(255, 255, 255, 0.09); }

.charter-slot__radio:checked + span {
    background: rgba(56, 225, 197, 0.14);
    border-color: var(--turq);
    color: var(--turq-l);
    box-shadow: 0 0 0 1px var(--turq) inset;
}

.charter-slot__radio:focus-visible + span { outline: 3px solid var(--turq); outline-offset: 2px; }

.charter-slot__radio:disabled + span { opacity: 0.3; text-decoration: line-through; cursor: not-allowed; }

.charter-slots__none {
    grid-column: 1 / -1;
    margin: 0;
    font-family: var(--font-ui);
    font-size: 0.8125rem;
    color: var(--yellow);
}

.charter-note {
    display: flex;
    gap: 0.625rem;
    margin: auto 0 0;
    padding: 0.75rem 0.875rem;
    background: rgba(251, 199, 41, 0.08);
    border: 1px solid rgba(251, 199, 41, 0.28);
    border-radius: 12px;
    font-family: var(--font-ui);
    font-size: 0.8125rem;
    line-height: 1.5;
    color: rgba(255, 255, 255, 0.85);
}

.charter-note svg { width: 18px; height: 18px; flex-shrink: 0; margin-top: 0.1rem; color: var(--yellow); }
.charter-note a { color: var(--yellow); font-weight: 700; white-space: nowrap; }
.charter-note a:hover { text-decoration: underline; }

/* ---------------------------------------------------------------------------
   03 — passengers (steppers are shared with the inline panel, below)
   --------------------------------------------------------------------------- */
.charter-pax { display: grid; gap: 1rem; }

@media (min-width: 640px) {
    .charter-pax { grid-template-columns: 1fr 1fr; align-items: start; }
}

.charter-fields { display: grid; gap: 0.625rem; }

/* ---------------------------------------------------------------------------
   04 — payment
   --------------------------------------------------------------------------- */
.charter-sum { margin: 0; display: grid; }

.charter-sum__row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 1rem;
    padding: 0.5rem 0;
    font-family: var(--font-ui);
}

.charter-sum__row[hidden] { display: none; }

.charter-sum dt { font-size: 0.8125rem; font-weight: 600; color: rgba(255, 255, 255, 0.65); }

.charter-sum dd {
    margin: 0;
    text-align: right;
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--white);
    font-variant-numeric: tabular-nums;
}

.charter-sum__row--total {
    margin-top: 0.375rem;
    padding-top: 0.875rem;
    border-top: 1px solid rgba(255, 255, 255, 0.14);
    align-items: center;
}

.charter-sum__row--total dt { font-size: 1rem; font-weight: 700; color: var(--white); }

.charter-sum__row--total dd {
    font-family: var(--font-display);
    font-size: clamp(1.75rem, 1.4rem + 1.2vw, 2.25rem);
    font-weight: 800;
    line-height: 1;
    color: var(--turq-l);
}

.charter-submit {
    --btn-bg: var(--white);
    --btn-fg: var(--navy);
    width: 100%;
    justify-content: center;
    padding-block: 1.0625rem;
}

.book-form__error {
    margin: 0;
    padding: 0.625rem 0.875rem;
    background: rgba(255, 107, 74, 0.14);
    border: 1px solid rgba(255, 107, 74, 0.4);
    border-radius: 10px;
    font-family: var(--font-ui);
    font-size: 0.8125rem;
    font-weight: 600;
    color: #FFB4A3;
}
.book-form__error[hidden] { display: none; }

.book-form__wa {
    align-self: center;
    font-family: var(--font-ui);
    font-size: 0.8125rem;
    font-weight: 700;
    color: var(--turq);
}
.book-form__wa:hover { color: var(--white); }

/* ---------------------------------------------------------------------------
   Passenger steppers (popup + inline panel)
   --------------------------------------------------------------------------- */
.pax { display: grid; gap: 0.625rem; }

.pax__row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.875rem 1rem;
    background: var(--pale);
    border-radius: var(--r);
}

.pax__who { display: flex; flex-direction: column; gap: 0.15rem; }

.pax__label {
    font-family: var(--font-ui);
    font-size: 1rem;
    font-weight: 700;
    color: var(--navy);
}

.pax__label small {
    margin-left: 0.25rem;
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--grey);
}

.pax__price {
    font-family: var(--font-ui);
    font-size: 0.8125rem;
    font-weight: 600;
    color: var(--blue-d);
}

.stepper {
    display: flex;
    align-items: center;
    gap: 0.25rem;
}

.stepper__btn {
    display: grid;
    place-items: center;
    width: 38px;
    height: 38px;
    padding: 0;
    background: var(--white);
    border: 2px solid var(--steel);
    border-radius: 50%;
    color: var(--navy);
    font-size: 1.25rem;
    font-weight: 600;
    line-height: 1;
    cursor: pointer;
    transition: border-color 0.3s var(--ease), background 0.3s var(--ease), transform 0.2s var(--ease);
}

.stepper__btn:hover:not(:disabled) { border-color: var(--navy); }
.stepper__btn:active:not(:disabled) { transform: scale(0.92); }
.stepper__btn:disabled { opacity: 0.35; cursor: not-allowed; }

.stepper__value {
    width: 2.75rem;
    padding: 0.25rem 0;
    background: none;
    border: 0;
    text-align: center;
    font-family: var(--font-display);
    font-size: 1.25rem;
    font-weight: 800;
    color: var(--navy);
    font-variant-numeric: tabular-nums;
    -moz-appearance: textfield;
}

.stepper__value::-webkit-outer-spin-button,
.stepper__value::-webkit-inner-spin-button { -webkit-appearance: none; margin: 0; }

.stepper__value:focus { outline: 2px solid var(--turq); border-radius: 6px; }

/* On the popup's dark cards */
.book-modal .pax__row {
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
}
.book-modal .pax__label { color: var(--white); }
.book-modal .pax__label small { display: block; margin: 0.1rem 0 0; color: rgba(255, 255, 255, 0.55); }
.book-modal .pax__price { color: var(--turq-l); }
.book-modal .stepper__btn {
    background: transparent;
    border-color: rgba(255, 255, 255, 0.28);
    color: var(--white);
}
.book-modal .stepper__btn:hover:not(:disabled) { border-color: var(--turq); }
.book-modal .stepper__value { color: var(--white); }
.book-modal .stepper__value.is-error { outline: 2px solid var(--coral); border-radius: 6px; }

/* ---------------------------------------------------------------------------
   Payment options
   --------------------------------------------------------------------------- */
.pay-options {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.375rem;
    padding: 0.3125rem;
    background: rgba(2, 18, 28, 0.45);
    border: 1px solid rgba(255, 255, 255, 0.1);
    border-radius: 14px;
}

.pay-option { position: relative; cursor: pointer; }

.pay-option__radio { position: absolute; opacity: 0; pointer-events: none; }

.pay-option__label {
    display: grid;
    place-items: center;
    height: 100%;
    min-height: 44px;
    padding: 0.5rem 0.375rem;
    text-align: center;
    border-radius: 10px;
    font-family: var(--font-ui);
    font-size: 0.75rem;
    font-weight: 700;
    line-height: 1.25;
    color: rgba(255, 255, 255, 0.72);
    transition: background 0.3s var(--ease), color 0.3s var(--ease);
}

.pay-option:hover .pay-option__label { color: var(--white); background: rgba(255, 255, 255, 0.06); }

.pay-option__radio:checked + .pay-option__label {
    background: var(--turq-l);
    color: var(--navy);
}

.pay-option__radio:focus-visible + .pay-option__label { outline: 3px solid var(--turq); outline-offset: 2px; }

.pay-note {
    margin: -0.375rem 0 0;
    min-height: 2.6em;
    font-family: var(--font-ui);
    font-size: 0.75rem;
    line-height: 1.45;
    color: rgba(255, 255, 255, 0.62);
}

.charter-textarea {
    min-height: 0;
    resize: vertical;
    font-weight: 500;
    line-height: 1.5;
}

/* ---------------------------------------------------------------------------
   Phones: full-height sheet, cards stacked in booking order
   --------------------------------------------------------------------------- */
@media (max-width: 599px) {
    .book-modal { padding: 0; place-items: end stretch; }
    .book-modal__dialog {
        max-height: 100svh;
        height: 100svh;
        border-radius: 0;
        border: 0;
        padding-bottom: calc(1.5rem + env(safe-area-inset-bottom));
    }
    .charter-trips { grid-template-columns: 1fr; }
    .charter-legs { padding: 0.625rem; gap: 0.5rem; }
    .charter-leg__icon { display: none; }
}

@media (prefers-reduced-motion: reduce) {
    .charter-map__dest circle:first-child,
    .charter-legs__line span { animation: none; }
}

/* ===========================================================================
   INLINE PASSENGER PANEL — "Book this experience" on the tour pages.
   Sits beside the trip cards so the section reads as one complete block.
   =========================================================================== */
.xp-book {
    display: grid;
    gap: clamp(1.25rem, 2.5vw, 1.75rem);
    margin-top: clamp(1.75rem, 3.5vw, 2.5rem);
    align-items: start;
}

.book-card {
    display: grid;
    gap: 1rem;
    padding: clamp(1.375rem, 2.5vw, 1.875rem);
    background: var(--navy);
    color: var(--white);
    border-radius: var(--r-lg);
    box-shadow: var(--shadow-lg);
}

.book-card__title {
    margin: 0;
    font-family: var(--font-ui);
    font-size: 0.8125rem;
    font-weight: 700;
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--turq);
}

.book-card__heading {
    margin: -0.5rem 0 0;
    font-family: var(--font-display);
    font-size: var(--t-h3);
    font-weight: 300;
    line-height: 1.2;
    color: var(--white);
}

/* Steppers on navy */
.book-card .pax__row { background: rgba(255, 255, 255, 0.07); }
.book-card .pax__label { color: var(--white); }
.book-card .pax__label small { color: rgba(255, 255, 255, 0.6); }
.book-card .pax__price { color: var(--turq-l); }
.book-card .stepper__btn {
    background: transparent;
    border-color: rgba(255, 255, 255, 0.3);
    color: var(--white);
}
.book-card .stepper__btn:hover:not(:disabled) { border-color: var(--turq); }
.book-card .stepper__value { color: var(--white); }

.book-card__select {
    width: 100%;
    padding: 0.8125rem 2.5rem 0.8125rem 1rem;
    background: rgba(255, 255, 255, 0.07) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 6 6.5 11 1.5' fill='none' stroke='%23ffffff' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") no-repeat right 1rem center / 12px;
    color: var(--white);
    font-family: var(--font-ui);
    font-size: 0.9375rem;
    font-weight: 600;
    border: 1px solid rgba(255, 255, 255, 0.22);
    border-radius: var(--r-sm);
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
}
.book-card__select option { color: var(--navy); }
.book-card__select:focus { outline: none; border-color: var(--turq); }

.book-card__total {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    padding-top: 1rem;
    border-top: 1px solid rgba(255, 255, 255, 0.16);
    font-family: var(--font-ui);
    font-weight: 600;
    color: rgba(255, 255, 255, 0.75);
}

.book-card__total-value {
    font-family: var(--font-display);
    font-size: 1.75rem;
    font-weight: 800;
    color: var(--white);
    font-variant-numeric: tabular-nums;
}

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

.book-card__note {
    margin: 0;
    font-family: var(--font-ui);
    font-size: 0.75rem;
    color: rgba(255, 255, 255, 0.6);
    text-align: center;
}

.book-card__slots {
    margin: 0;
    padding-top: 0.875rem;
    border-top: 1px solid rgba(255, 255, 255, 0.12);
    font-family: var(--font-ui);
    font-size: 0.75rem;
    line-height: 1.55;
    color: rgba(255, 255, 255, 0.7);
}
.book-card__slots strong { color: var(--white); }
.book-card__slots a { color: var(--yellow); font-weight: 700; white-space: nowrap; }

@media (min-width: 900px) {
    .xp-book { grid-template-columns: 1fr minmax(320px, 380px); }
    .book-card { position: sticky; top: calc(var(--header-h) + 1.5rem); }
}

/* A card's Book button on the same page flashes the panel it just updated */
.book-card.is-pulse { animation: card-pulse 0.9s var(--ease); }

@keyframes card-pulse {
    0%   { box-shadow: 0 0 0 0 rgba(56, 225, 197, 0.6), var(--shadow-lg); }
    100% { box-shadow: 0 0 0 16px rgba(56, 225, 197, 0), var(--shadow-lg); }
}
