/* ==========================================================================
   THE BANSARA ROYALE  —  components.css
   --------------------------------------------------------------------------
   Reusable UI components. Load AFTER base.css.

   Table of contents
   -----------------
   1.  Buttons (sweep fill, ghost, link-arrow, icon)
   2.  Icon sizing
   3.  Media frames + Ken Burns
   4.  Cards — experience / room / amenity / venue / review
   5.  Badge + price display
   6.  Feature list + spec list
   7.  Accordion
   8.  Tabs / filter pills
   9.  Form controls
   10. Gallery + lightbox
   11. Marquee ribbon
   12. Toast notifications
   13. Loading spinner
   ========================================================================== */


/* ==========================================================================
   1. BUTTONS
   ========================================================================== */

/* Shared skeleton for every button variant. */
.btn {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 0.7em;
    padding: 1.05em 2.1em;
    font-family: var(--font-body);
    font-size: var(--fs-sm);
    font-weight: 500;
    letter-spacing: var(--ls-button);
    text-transform: uppercase;
    line-height: 1;
    white-space: nowrap;
    border: 1px solid transparent;
    border-radius: var(--r-sm);
    cursor: pointer;
    overflow: hidden;
    isolation: isolate;              /* keeps the ::before sweep behind text */
    transition:
        color            var(--t-base) var(--ease-out),
        border-color     var(--t-base) var(--ease-out),
        background-color var(--t-base) var(--ease-out),
        transform        var(--t-fast) var(--ease-out),
        box-shadow       var(--t-base) var(--ease-out);
    -webkit-tap-highlight-color: transparent;
}

/* The animated fill. Scales in horizontally from the left edge on hover.
   Using transform (not width) keeps the animation on the compositor. */
.btn::before {
    content: "";
    position: absolute;
    inset: 0;
    z-index: -1;
    transform: scaleX(0);
    transform-origin: left center;
    transition: transform 460ms var(--ease-out);
}

.btn:hover::before,
.btn:focus-visible::before {
    transform: scaleX(1);
}

/* On release, the fill retracts to the right so it never "snaps" back. */
.btn:not(:hover)::before {
    transform-origin: right center;
}

.btn:active {
    transform: translateY(1px);
}

.btn__label {
    position: relative;
    z-index: 1;
}

/* Arrow that nudges forward on hover. */
.btn__arrow {
    position: relative;
    z-index: 1;
    display: inline-flex;
    transition: transform var(--t-base) var(--ease-spring);
}

.btn:hover .btn__arrow {
    transform: translateX(5px);
}

/* --- Primary: solid copper, fills to deep navy -------------------------- */
.btn--primary {
    background-color: var(--c-copper);
    border-color: var(--c-copper);
    color: #FFFFFF;
    box-shadow: 0 8px 22px -12px rgba(213, 121, 56, 0.9);
}

.btn--primary::before {
    background-color: var(--c-navy);
}

.btn--primary:hover,
.btn--primary:focus-visible {
    border-color: var(--c-navy);
    color: #FFFFFF;
    box-shadow: 0 10px 28px -14px rgba(3, 28, 42, 0.9);
}

/* --- Outline: hairline border, fills to copper -------------------------- */
.btn--outline {
    background-color: transparent;
    border-color: color-mix(in srgb, var(--fg) 32%, transparent);
    color: var(--fg);
}

.btn--outline::before {
    background-color: var(--c-copper);
}

.btn--outline:hover,
.btn--outline:focus-visible {
    border-color: var(--c-copper);
    color: #FFFFFF;
}

/* --- Solid: navy on light sections, ivory on dark ----------------------- */
.btn--solid {
    background-color: var(--c-navy);
    border-color: var(--c-navy);
    color: var(--c-on-dark);
}

.btn--solid::before {
    background-color: var(--c-copper);
}

.btn--solid:hover,
.btn--solid:focus-visible {
    border-color: var(--c-copper);
    color: #FFFFFF;
}

.theme-dark .btn--solid,
.theme-dark-deep .btn--solid {
    background-color: var(--c-on-dark);
    border-color: var(--c-on-dark);
    color: var(--c-navy);
}

.theme-dark .btn--solid:hover,
.theme-dark-deep .btn--solid:hover {
    color: #FFFFFF;
}

/* --- Ghost: text only, underline grows from the left -------------------- */
.btn--ghost {
    padding-inline: 0;
    padding-block: 0.4em;
    background: none;
    border: 0;
    border-radius: 0;
    color: var(--fg);
}

.btn--ghost::before {
    top: auto;
    bottom: 0;
    height: 1px;
    background-color: var(--c-copper);
    z-index: 0;
}

.btn--ghost:hover,
.btn--ghost:focus-visible {
    color: var(--c-copper);
}

/* --- Size modifiers ----------------------------------------------------- */
.btn--sm    { padding: 0.85em 1.5em; font-size: var(--fs-xs); }
.btn--lg    { padding: 1.2em 2.6em; }
.btn--block { display: flex; width: 100%; }

.btn[disabled],
.btn[aria-disabled="true"] {
    opacity: 0.45;
    pointer-events: none;
}

/* --- Circular icon button ----------------------------------------------- */
.icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 44px;
    height: 44px;
    flex: none;
    border: 1px solid color-mix(in srgb, var(--fg) 22%, transparent);
    border-radius: 50%;
    color: var(--fg);
    background: transparent;
    transition:
        background-color var(--t-base) var(--ease-out),
        border-color     var(--t-base) var(--ease-out),
        color            var(--t-base) var(--ease-out),
        transform        var(--t-base) var(--ease-spring);
}

.icon-btn:hover,
.icon-btn:focus-visible {
    background-color: var(--c-copper);
    border-color: var(--c-copper);
    color: #FFFFFF;
    transform: translateY(-2px);
}

.icon-btn--sm { width: 36px; height: 36px; }


/* ==========================================================================
   2. ICON SIZING
   --------------------------------------------------------------------------
   All icons are inline SVG using `currentColor`, so they inherit the text
   colour of whatever they sit inside. Stroke width is kept at 1.25 for a
   fine, engraved look rather than the chunky default of most icon sets.
   ========================================================================== */

.ico {
    width: 1.25em;
    height: 1.25em;
    flex: none;
    stroke: currentColor;
    stroke-width: 1.25;
    stroke-linecap: round;
    stroke-linejoin: round;
    fill: none;
}

.ico--xs { width: 1em;    height: 1em; }
.ico--sm { width: 1.1em;  height: 1.1em; }
.ico--lg { width: 1.75em; height: 1.75em; }
.ico--xl { width: 2.25em; height: 2.25em; stroke-width: 1; }

/* Solid-fill variant for logos such as Instagram / Facebook glyphs. */
.ico--fill {
    fill: currentColor;
    stroke: none;
}


/* ==========================================================================
   3. MEDIA FRAMES + KEN BURNS
   ========================================================================== */

/* Fixed-ratio image container. Set --ar to change the aspect ratio. */
.frame {
    position: relative;
    overflow: hidden;
    background-color: var(--c-navy-800);
    aspect-ratio: var(--ar, 4 / 3);
    border-radius: var(--r-sm);
}

.frame > img,
.frame > video {
    width: 100%;
    height: 100%;
    object-fit: cover;
    object-position: var(--pos, center);
}

/* Slow zoom on hover — reads as expensive rather than bouncy. */
.frame--zoom > img {
    transition: transform 1100ms var(--ease-out);
}

.frame--zoom:hover > img,
a:hover .frame--zoom > img {
    transform: scale(1.06);
}

/* Thin copper outline offset behind an image, editorial style. */
.frame--offset {
    isolation: isolate;
}

.frame--offset::after {
    content: "";
    position: absolute;
    inset: 12px;
    border: 1px solid rgba(255, 255, 255, 0.28);
    pointer-events: none;
    z-index: 2;
}

/* Gradient scrim so overlaid text stays legible on any photograph. */
.scrim::after {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: linear-gradient(
        to top,
        rgba(3, 28, 42, 0.88) 0%,
        rgba(3, 28, 42, 0.45) 38%,
        rgba(3, 28, 42, 0.05) 72%,
        rgba(3, 28, 42, 0) 100%
    );
}

.scrim--full::after {
    background: linear-gradient(
        to top,
        rgba(3, 28, 42, 0.82) 0%,
        rgba(3, 28, 42, 0.55) 50%,
        rgba(3, 28, 42, 0.72) 100%
    );
}

/* --- Ken Burns slideshow ------------------------------------------------
   Used for the banner background on every interior page. Slides are
   cross-faded by main.js which toggles .is-active. The active slide runs a
   slow pan-and-zoom so the still photograph never feels static.          */

.kenburns {
    position: absolute;
    inset: 0;
    overflow: hidden;
    background-color: var(--c-navy);
}

.kenburns__slide {
    position: absolute;
    inset: 0;
    opacity: 0;
    transition: opacity 1600ms var(--ease-in-out);
}

.kenburns__slide.is-active {
    opacity: 1;
}

.kenburns__slide img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform: scale(1.02);
}

.kenburns__slide.is-active img {
    animation: kenburns-pan 11s var(--ease-in-out) forwards;
}

/* Alternate slides pan in the opposite direction to avoid a repeating tic. */
.kenburns__slide:nth-child(even).is-active img {
    animation-name: kenburns-pan-alt;
}

@keyframes kenburns-pan {
    from { transform: scale(1.02) translate3d(0, 0, 0); }
    to   { transform: scale(1.14) translate3d(-1.6%, -1.2%, 0); }
}

@keyframes kenburns-pan-alt {
    from { transform: scale(1.14) translate3d(1.4%, 1%, 0); }
    to   { transform: scale(1.02) translate3d(0, 0, 0); }
}


/* ==========================================================================
   4. CARDS
   ========================================================================== */

/* --- Experience card: full-bleed photo with text laid over the bottom --- */
.exp-card {
    position: relative;
    display: block;
    overflow: hidden;
    border-radius: var(--r-sm);
    aspect-ratio: 1 / 1;
    background-color: var(--c-navy-800);
}

.exp-card__img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 1200ms var(--ease-out);
}

.exp-card:hover .exp-card__img {
    transform: scale(1.07);
}

.exp-card__body {
    position: absolute;
    inset-inline: 0;
    bottom: 0;
    z-index: 2;
    padding: clamp(1.25rem, 0.9rem + 1.4vw, 2rem);
    color: #FFFFFF;
}

.exp-card__title {
    color: #FFFFFF;
    font-size: var(--fs-h4);
    margin-bottom: 0.35rem;
}

.exp-card__meta {
    font-size: var(--fs-sm);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--c-copper-300);
}

/* Copper hairline that draws itself across the card on hover. */
.exp-card__body::before {
    content: "";
    position: absolute;
    left: clamp(1.25rem, 0.9rem + 1.4vw, 2rem);
    right: clamp(1.25rem, 0.9rem + 1.4vw, 2rem);
    top: 0;
    height: 1px;
    background-color: var(--c-copper);
    transform: scaleX(0);
    transform-origin: left center;
    transition: transform 560ms var(--ease-out);
}

.exp-card:hover .exp-card__body::before {
    transform: scaleX(1);
}

/* --- Room card ----------------------------------------------------------
   Photo on top, details beneath, price block pinned to the card footer so
   that cards of differing text length still align along the bottom edge. */

.room-card {
    display: flex;
    flex-direction: column;
    background-color: var(--surface);
    border: 1px solid var(--rule);
    border-radius: var(--r-md);
    overflow: hidden;
    transition:
        transform    var(--t-slow) var(--ease-out),
        box-shadow   var(--t-slow) var(--ease-out),
        border-color var(--t-base) var(--ease-out);
}

.room-card:hover {
    transform: translateY(-6px);
    border-color: color-mix(in srgb, var(--c-copper) 45%, transparent);
    box-shadow: var(--shadow-md);
}

.room-card__media {
    position: relative;
    aspect-ratio: 16 / 11;
    overflow: hidden;
    background-color: var(--c-navy-800);
}

.room-card__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 1200ms var(--ease-out);
}

.room-card:hover .room-card__media img {
    transform: scale(1.06);
}

.room-card__body {
    display: flex;
    flex-direction: column;
    flex: 1;
    gap: var(--sp-4);
    padding: clamp(1.25rem, 1rem + 1vw, 1.85rem);
}

.room-card__title {
    font-size: var(--fs-h4);
}

.room-card__desc {
    font-size: var(--fs-sm);
    line-height: var(--lh-loose);
}

.room-card__foot {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: var(--sp-4);
    margin-top: auto;
    padding-top: var(--sp-4);
    border-top: 1px solid var(--rule);
}

/* Compact icon+label strip describing size / occupancy / bedding. */
.room-specs {
    display: flex;
    flex-wrap: wrap;
    gap: var(--sp-2) var(--sp-4);
    font-size: var(--fs-xs);
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: var(--fg-muted);
}

.room-specs li {
    display: inline-flex;
    align-items: center;
    gap: 0.45em;
}

.room-specs .ico {
    color: var(--c-copper);
}

/* --- Amenity card: icon, title, one line of copy ------------------------ */
.amenity {
    position: relative;
    display: flex;
    flex-direction: column;
    gap: var(--sp-3);
    padding: clamp(1.5rem, 1.1rem + 1.6vw, 2.25rem) clamp(1.25rem, 1rem + 1vw, 1.75rem);
    border: 1px solid var(--rule);
    border-radius: var(--r-md);
    background-color: transparent;
    overflow: hidden;
    transition:
        border-color     var(--t-base) var(--ease-out),
        background-color var(--t-base) var(--ease-out),
        transform        var(--t-base) var(--ease-out);
}

/* Copper wash that rises from the bottom of the card on hover. */
.amenity::before {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(
        to top,
        color-mix(in srgb, var(--c-copper) 14%, transparent),
        transparent 70%
    );
    opacity: 0;
    transition: opacity var(--t-slow) var(--ease-out);
}

.amenity:hover {
    transform: translateY(-4px);
    border-color: color-mix(in srgb, var(--c-copper) 50%, transparent);
}

.amenity:hover::before {
    opacity: 1;
}

.amenity__icon {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 52px;
    height: 52px;
    color: var(--c-copper);
    border: 1px solid color-mix(in srgb, var(--c-copper) 35%, transparent);
    border-radius: 50%;
    transition: transform var(--t-slow) var(--ease-spring);
}

.amenity:hover .amenity__icon {
    transform: rotate(-8deg) scale(1.06);
}

.amenity__title {
    position: relative;
    font-size: var(--fs-h6);
    letter-spacing: 0.06em;
    text-transform: uppercase;
}

.amenity__text {
    position: relative;
    font-size: var(--fs-sm);
    line-height: var(--lh-loose);
}

/* --- Venue card: dining outlets ----------------------------------------- */
.venue {
    display: flex;
    flex-direction: column;
    background-color: var(--surface);
    border: 1px solid var(--rule);
    border-radius: var(--r-md);
    overflow: hidden;
    transition: transform var(--t-slow) var(--ease-out),
                box-shadow var(--t-slow) var(--ease-out);
}

.venue:hover {
    transform: translateY(-6px);
    box-shadow: var(--shadow-md);
}

.venue__media {
    aspect-ratio: 4 / 3;
    overflow: hidden;
    background-color: var(--c-navy-800);
}

.venue__media img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 1200ms var(--ease-out);
}

.venue:hover .venue__media img {
    transform: scale(1.06);
}

.venue__body {
    display: flex;
    flex: 1;
    flex-direction: column;
    gap: var(--sp-3);
    padding: clamp(1.25rem, 1rem + 1vw, 1.85rem);
}

.venue__tagline {
    font-size: var(--fs-sm);
    line-height: var(--lh-loose);
}

.venue__phone {
    display: inline-flex;
    align-items: center;
    gap: 0.55em;
    margin-top: auto;
    padding-top: var(--sp-3);
    font-size: var(--fs-sm);
    letter-spacing: 0.05em;
    color: var(--c-copper);
    border-top: 1px solid var(--rule);
    transition: gap var(--t-base) var(--ease-out);
}

.venue__phone:hover {
    gap: 0.9em;
}

/* --- Review card --------------------------------------------------------- */
.review {
    display: flex;
    flex-direction: column;
    gap: var(--sp-4);
    padding: clamp(1.5rem, 1.2rem + 1.2vw, 2.25rem);
    background-color: var(--surface);
    border: 1px solid var(--rule);
    border-radius: var(--r-md);
    height: 100%;
}

.review__stars {
    display: flex;
    gap: 3px;
    color: var(--c-copper);
}

.review__stars .ico {
    width: 1.05em;
    height: 1.05em;
    fill: currentColor;
    stroke: none;
}

.review__quote {
    flex: 1;
    font-size: var(--fs-base);
    line-height: var(--lh-loose);
}

.review__author {
    display: flex;
    align-items: center;
    gap: var(--sp-3);
    padding-top: var(--sp-3);
    border-top: 1px solid var(--rule);
}

.review__avatar {
    display: grid;
    place-items: center;
    width: 40px;
    height: 40px;
    flex: none;
    border-radius: 50%;
    background-color: var(--c-copper);
    color: #FFFFFF;
    font-family: var(--font-display);
    font-size: var(--fs-sm);
}

.review__name {
    font-family: var(--font-display);
    font-size: var(--fs-sm);
    letter-spacing: 0.05em;
    color: var(--fg);
}

.review__date {
    font-size: var(--fs-xs);
    color: var(--fg-muted);
}


/* ==========================================================================
   5. BADGE + PRICE DISPLAY
   ========================================================================== */

.badge {
    display: inline-flex;
    align-items: center;
    gap: 0.4em;
    padding: 0.42em 0.85em;
    font-size: var(--fs-xs);
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    line-height: 1;
    border-radius: var(--r-pill);
    border: 1px solid transparent;
    white-space: nowrap;
}

.badge--copper  { background: var(--c-copper); color: #FFFFFF; }
.badge--outline { border-color: color-mix(in srgb, var(--fg) 28%, transparent); color: var(--fg-muted); }
.badge--save    { background: color-mix(in srgb, var(--c-success) 14%, transparent); color: var(--c-success); border-color: color-mix(in srgb, var(--c-success) 35%, transparent); }
.badge--muted   { background: color-mix(in srgb, var(--fg) 8%, transparent); color: var(--fg-muted); }

.theme-dark .badge--save,
.theme-dark-deep .badge--save {
    background: rgba(72, 187, 137, 0.14);
    color: #6EDBA8;
    border-color: rgba(110, 219, 168, 0.35);
}

/* Absolute badge pinned to the top-left of a card photo. */
.badge--float {
    position: absolute;
    top: 14px;
    left: 14px;
    z-index: 3;
    backdrop-filter: blur(6px);
}

/* --- Price block --------------------------------------------------------- */
.price {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
    line-height: 1.2;
}

.price__strike {
    font-size: var(--fs-sm);
    color: var(--fg-muted);
    text-decoration: line-through;
    text-decoration-thickness: 1px;
}

.price__now {
    display: flex;
    align-items: baseline;
    gap: 0.35em;
    font-family: var(--font-display);
    font-size: var(--fs-h4);
    color: var(--fg);
}

.price__unit {
    font-family: var(--font-body);
    font-size: var(--fs-xs);
    letter-spacing: 0.08em;
    text-transform: uppercase;
    color: var(--fg-muted);
}

.price__note {
    font-size: var(--fs-xs);
    color: var(--fg-muted);
}


/* ==========================================================================
   6. FEATURE LIST + SPEC LIST
   ========================================================================== */

/* Checkmarked list of inclusions. */
.feature-list {
    display: grid;
    gap: var(--sp-3);
}

.feature-list li {
    display: flex;
    align-items: flex-start;
    gap: 0.7em;
    font-size: var(--fs-sm);
    line-height: var(--lh-loose);
    color: var(--fg-muted);
}

.feature-list .ico {
    margin-top: 0.32em;
    color: var(--c-copper);
}

.feature-list--2col {
    grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr));
    column-gap: var(--sp-6);
}

/* Definition-style specification table (label left, value right). */
.spec-list {
    display: grid;
    gap: 0;
}

.spec-list > div {
    display: grid;
    grid-template-columns: minmax(120px, 34%) 1fr;
    gap: var(--sp-4);
    padding-block: var(--sp-3);
    border-bottom: 1px solid var(--rule);
    font-size: var(--fs-sm);
}

.spec-list > div:first-child {
    border-top: 1px solid var(--rule);
}

.spec-list dt {
    font-family: var(--font-display);
    letter-spacing: 0.05em;
    color: var(--fg);
}

.spec-list dd {
    color: var(--fg-muted);
    line-height: var(--lh-loose);
}


/* ==========================================================================
   7. ACCORDION
   ========================================================================== */

.accordion {
    border-top: 1px solid var(--rule);
}

.accordion__item {
    border-bottom: 1px solid var(--rule);
}

.accordion__trigger {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--sp-4);
    width: 100%;
    padding-block: var(--sp-5);
    text-align: left;
    font-family: var(--font-display);
    font-size: var(--fs-h6);
    letter-spacing: 0.04em;
    color: var(--fg);
    transition: color var(--t-base) var(--ease-out);
}

.accordion__trigger:hover {
    color: var(--c-copper);
}

/* Plus-to-minus morph: the vertical bar of the "+" rotates away. */
.accordion__sign {
    position: relative;
    width: 16px;
    height: 16px;
    flex: none;
    color: var(--c-copper);
}

.accordion__sign::before,
.accordion__sign::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 0;
    width: 100%;
    height: 1.5px;
    background-color: currentColor;
    transform: translateY(-50%);
    transition: transform 400ms var(--ease-out);
}

.accordion__sign::after {
    transform: translateY(-50%) rotate(90deg);
}

.accordion__trigger[aria-expanded="true"] .accordion__sign::after {
    transform: translateY(-50%) rotate(0deg);
}

/* Height is animated by main.js via an inline max-height in pixels. */
.accordion__panel {
    max-height: 0;
    overflow: hidden;
    transition: max-height 480ms var(--ease-out);
}

.accordion__panel-inner {
    padding-bottom: var(--sp-5);
    font-size: var(--fs-sm);
    line-height: var(--lh-loose);
    color: var(--fg-muted);
}


/* ==========================================================================
   8. TABS / FILTER PILLS
   ========================================================================== */

.pills {
    display: flex;
    flex-wrap: wrap;
    gap: var(--sp-2);
}

/* Horizontal scroll on narrow screens instead of wrapping into many rows. */
.pills--scroll {
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding-bottom: 4px;
    scroll-snap-type: x proximity;
}

.pills--scroll::-webkit-scrollbar {
    display: none;
}

.pill {
    position: relative;
    padding: 0.7em 1.35em;
    font-size: var(--fs-xs);
    font-weight: 500;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    white-space: nowrap;
    color: var(--fg-muted);
    border: 1px solid var(--rule);
    border-radius: var(--r-pill);
    background: transparent;
    scroll-snap-align: start;
    transition:
        color            var(--t-base) var(--ease-out),
        border-color     var(--t-base) var(--ease-out),
        background-color var(--t-base) var(--ease-out);
}

.pill:hover {
    color: var(--fg);
    border-color: color-mix(in srgb, var(--c-copper) 55%, transparent);
}

.pill.is-active,
.pill[aria-selected="true"] {
    background-color: var(--c-copper);
    border-color: var(--c-copper);
    color: #FFFFFF;
}


/* ==========================================================================
   9. FORM CONTROLS
   ========================================================================== */

.field {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.field__label {
    display: flex;
    align-items: center;
    gap: 0.4em;
    font-size: var(--fs-xs);
    font-weight: 500;
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--fg-muted);
}

.field__label .req {
    color: var(--c-copper);
}

.input,
.select,
.textarea {
    width: 100%;
    padding: 0.95rem 1.05rem;
    font-family: var(--font-body);
    font-size: var(--fs-base);
    color: var(--fg);
    background-color: color-mix(in srgb, var(--surface) 88%, transparent);
    border: 1px solid var(--rule);
    border-radius: var(--r-sm);
    transition:
        border-color var(--t-base) var(--ease-out),
        box-shadow   var(--t-base) var(--ease-out),
        background-color var(--t-base) var(--ease-out);
    appearance: none;
}

.theme-dark .input,
.theme-dark .select,
.theme-dark .textarea,
.theme-dark-deep .input,
.theme-dark-deep .select,
.theme-dark-deep .textarea {
    background-color: rgba(255, 255, 255, 0.04);
}

.input::placeholder,
.textarea::placeholder {
    color: color-mix(in srgb, var(--fg-muted) 75%, transparent);
}

.input:focus,
.select:focus,
.textarea:focus {
    outline: none;
    border-color: var(--c-copper);
    box-shadow: 0 0 0 3px color-mix(in srgb, var(--c-copper) 18%, transparent);
}

.textarea {
    min-height: 130px;
    resize: vertical;
    line-height: var(--lh-normal);
}

/* Custom select chevron drawn with a background SVG. */
.select {
    padding-right: 2.75rem;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='14' height='9' viewBox='0 0 14 9' fill='none'%3E%3Cpath d='M1 1L7 7L13 1' stroke='%23D57938' stroke-width='1.4' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1.05rem center;
    cursor: pointer;
}

/* Native date inputs: force the picker icon to match the brand colour. */
.input[type="date"]::-webkit-calendar-picker-indicator {
    cursor: pointer;
    opacity: 0.75;
    filter: invert(52%) sepia(64%) saturate(600%) hue-rotate(340deg) brightness(94%);
}

.theme-dark .input[type="date"],
.theme-dark-deep .input[type="date"] {
    color-scheme: dark;
}

/* Inline validation message. */
.field__error {
    display: none;
    font-size: var(--fs-xs);
    letter-spacing: 0.04em;
    color: var(--c-danger);
}

.field.has-error .input,
.field.has-error .select,
.field.has-error .textarea {
    border-color: var(--c-danger);
}

.field.has-error .field__error {
    display: block;
}

.theme-dark .field__error,
.theme-dark-deep .field__error {
    color: #F0857A;
}

/* Form grid: fields flow into two columns above 700px. */
.form-grid {
    display: grid;
    gap: var(--sp-4);
    grid-template-columns: repeat(auto-fit, minmax(min(240px, 100%), 1fr));
}

.form-grid .span-2 {
    grid-column: 1 / -1;
}

/* Number stepper used for guest counts. */
.stepper {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: var(--sp-2);
    padding: 0.5rem 0.6rem;
    border: 1px solid var(--rule);
    border-radius: var(--r-sm);
    background-color: color-mix(in srgb, var(--surface) 88%, transparent);
}

.theme-dark .stepper,
.theme-dark-deep .stepper {
    background-color: rgba(255, 255, 255, 0.04);
}

.stepper__btn {
    display: grid;
    place-items: center;
    width: 34px;
    height: 34px;
    flex: none;
    border-radius: 50%;
    border: 1px solid var(--rule);
    color: var(--fg);
    font-size: 1.1rem;
    line-height: 1;
    transition:
        background-color var(--t-fast) var(--ease-out),
        border-color     var(--t-fast) var(--ease-out),
        color            var(--t-fast) var(--ease-out);
}

.stepper__btn:hover:not(:disabled) {
    background-color: var(--c-copper);
    border-color: var(--c-copper);
    color: #FFFFFF;
}

.stepper__btn:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.stepper__value {
    min-width: 2ch;
    text-align: center;
    font-family: var(--font-display);
    font-size: var(--fs-h6);
    color: var(--fg);
}

/* Checkbox / radio with a custom copper indicator. */
.check {
    display: flex;
    align-items: flex-start;
    gap: 0.7em;
    font-size: var(--fs-sm);
    line-height: var(--lh-normal);
    color: var(--fg-muted);
    cursor: pointer;
}

.check input {
    appearance: none;
    width: 18px;
    height: 18px;
    flex: none;
    margin-top: 0.2em;
    border: 1px solid color-mix(in srgb, var(--fg) 34%, transparent);
    border-radius: var(--r-sm);
    background-color: transparent;
    cursor: pointer;
    transition:
        background-color var(--t-fast) var(--ease-out),
        border-color     var(--t-fast) var(--ease-out);
}

.check input[type="radio"] {
    border-radius: 50%;
}

.check input:checked {
    background-color: var(--c-copper);
    border-color: var(--c-copper);
    /* White tick drawn as a background image so no extra markup is needed. */
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='10' viewBox='0 0 12 10' fill='none'%3E%3Cpath d='M1 5L4.2 8.2L11 1.4' stroke='white' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: center;
}

.check input[type="radio"]:checked {
    background-image: none;
    box-shadow: inset 0 0 0 3px var(--surface);
}


/* ==========================================================================
   10. GALLERY + LIGHTBOX
   ========================================================================== */

/* Masonry-flavoured grid built with explicit row spans so the layout stays
   deterministic across browsers (true masonry is still not widely shipped). */
.gallery {
    display: grid;
    gap: var(--sp-3);
    grid-template-columns: repeat(2, 1fr);
    grid-auto-rows: 150px;
}

@media (min-width: 640px) {
    .gallery { grid-template-columns: repeat(3, 1fr); grid-auto-rows: 180px; }
}

@media (min-width: 1024px) {
    .gallery { grid-template-columns: repeat(4, 1fr); grid-auto-rows: 210px; }
}

.gallery__item {
    position: relative;
    grid-row: span 1;
    overflow: hidden;
    border-radius: var(--r-sm);
    background-color: var(--c-navy-800);
    cursor: zoom-in;
}

/* Two size modifiers create the irregular, non-gridded rhythm. */
.gallery__item--tall { grid-row: span 2; }

@media (min-width: 640px) {
    .gallery__item--wide { grid-column: span 2; }
}

.gallery__item img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 1200ms var(--ease-out),
                filter    var(--t-slow) var(--ease-out);
}

.gallery__item:hover img {
    transform: scale(1.07);
}

/* Hover overlay with an expand glyph. */
.gallery__item::after {
    content: "";
    position: absolute;
    inset: 0;
    background: rgba(3, 28, 42, 0.42);
    opacity: 0;
    transition: opacity var(--t-base) var(--ease-out);
}

.gallery__item:hover::after {
    opacity: 1;
}

.gallery__zoom {
    position: absolute;
    top: 50%;
    left: 50%;
    z-index: 2;
    transform: translate(-50%, -50%) scale(0.7);
    color: #FFFFFF;
    opacity: 0;
    transition: opacity var(--t-base) var(--ease-out),
                transform var(--t-base) var(--ease-spring);
    pointer-events: none;
}

.gallery__item:hover .gallery__zoom {
    opacity: 1;
    transform: translate(-50%, -50%) scale(1);
}

/* --- Lightbox ----------------------------------------------------------- */

.lightbox {
    position: fixed;
    inset: 0;
    z-index: var(--z-modal);
    display: grid;
    place-items: center;
    padding: clamp(1rem, 3vw, 3rem);
    background: rgba(2, 20, 30, 0.94);
    backdrop-filter: blur(8px);
    opacity: 0;
    visibility: hidden;
    transition: opacity var(--t-base) var(--ease-out),
                visibility var(--t-base) linear;
}

.lightbox.is-open {
    opacity: 1;
    visibility: visible;
}

.lightbox__figure {
    position: relative;
    max-width: min(1100px, 100%);
    max-height: 100%;
    transform: scale(0.96);
    transition: transform var(--t-slow) var(--ease-out);
}

.lightbox.is-open .lightbox__figure {
    transform: scale(1);
}

.lightbox__img {
    max-width: 100%;
    max-height: calc(100vh - 9rem);
    object-fit: contain;
    border-radius: var(--r-sm);
}

.lightbox__caption {
    margin-top: var(--sp-3);
    text-align: center;
    font-size: var(--fs-sm);
    letter-spacing: 0.1em;
    text-transform: uppercase;
    color: var(--c-on-dark-muted);
}

.lightbox__close {
    position: absolute;
    top: clamp(1rem, 3vw, 2rem);
    right: clamp(1rem, 3vw, 2rem);
    color: var(--c-on-dark);
    border-color: rgba(255, 255, 255, 0.25);
}

.lightbox__nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    color: var(--c-on-dark);
    border-color: rgba(255, 255, 255, 0.25);
    background: rgba(3, 28, 42, 0.5);
}

.lightbox__nav--prev { left:  clamp(0.5rem, 2vw, 2rem); }
.lightbox__nav--next { right: clamp(0.5rem, 2vw, 2rem); }


/* ==========================================================================
   11. MARQUEE RIBBON
   --------------------------------------------------------------------------
   A slow, continuously scrolling strip of words. The track holds two
   identical copies of the content so the loop is seamless at -50%.
   ========================================================================== */

.marquee {
    overflow: hidden;
    padding-block: var(--sp-5);
    border-block: 1px solid var(--rule);
    user-select: none;
}

.marquee__track {
    display: flex;
    width: max-content;
    animation: marquee-scroll 38s linear infinite;
}

.marquee:hover .marquee__track {
    animation-play-state: paused;
}

.marquee__group {
    display: flex;
    align-items: center;
    flex: none;
}

.marquee__item {
    display: inline-flex;
    align-items: center;
    gap: clamp(1.5rem, 4vw, 3rem);
    padding-inline: clamp(1.5rem, 4vw, 3rem);
    font-family: var(--font-display);
    font-size: clamp(1rem, 0.85rem + 0.7vw, 1.5rem);
    letter-spacing: 0.14em;
    text-transform: uppercase;
    color: var(--fg);
    white-space: nowrap;
}

.marquee__item::after {
    content: "";
    width: 6px;
    height: 6px;
    background: var(--c-copper);
    transform: rotate(45deg);
    flex: none;
}

@keyframes marquee-scroll {
    from { transform: translate3d(0, 0, 0); }
    to   { transform: translate3d(-50%, 0, 0); }
}


/* ==========================================================================
   12. TOAST NOTIFICATIONS
   ========================================================================== */

.toast-stack {
    position: fixed;
    right: clamp(1rem, 3vw, 2rem);
    bottom: clamp(1rem, 3vw, 2rem);
    z-index: var(--z-modal);
    display: flex;
    flex-direction: column;
    gap: var(--sp-2);
    width: min(360px, calc(100vw - 2rem));
    pointer-events: none;
}

.toast {
    display: flex;
    align-items: flex-start;
    gap: var(--sp-3);
    padding: 1rem 1.15rem;
    background-color: var(--c-navy-800);
    color: var(--c-on-dark);
    border: 1px solid rgba(255, 255, 255, 0.12);
    border-left: 3px solid var(--c-copper);
    border-radius: var(--r-sm);
    box-shadow: var(--shadow-lg);
    font-size: var(--fs-sm);
    line-height: var(--lh-normal);
    pointer-events: auto;
    transform: translateX(120%);
    opacity: 0;
    transition: transform 460ms var(--ease-spring),
                opacity   var(--t-base) var(--ease-out);
}

.toast.is-visible {
    transform: translateX(0);
    opacity: 1;
}

.toast--success { border-left-color: #4CAF7D; }
.toast--error   { border-left-color: #E0685C; }

.toast .ico {
    margin-top: 0.15em;
    color: var(--c-copper);
}

.toast--success .ico { color: #4CAF7D; }
.toast--error   .ico { color: #E0685C; }


/* ==========================================================================
   13. LOADING SPINNER
   ========================================================================== */

.spinner {
    width: 18px;
    height: 18px;
    flex: none;
    border: 2px solid color-mix(in srgb, currentColor 25%, transparent);
    border-top-color: currentColor;
    border-radius: 50%;
    animation: spin 720ms linear infinite;
}

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