/* Vertical split venue section (homepage hero + location choosers).
   The divider is a straight vertical line whose horizontal position is a
   single custom property (--x) — hover states just slide the line. */

/* the hero sits flush behind the transparent header */
main#home.has-split { padding-top: 0; }

/* has-split zeroes main's usual padding-top, so restore breathing room
   between the hero and the section that follows it (desktop only) */
@media (min-width: 768px) {
    .split-hero--hero { margin-bottom: 4rem; }
}

.split-hero {
    --x: 50%;
    position: relative;
    width: 100%;
    height: 100vh;
    overflow: hidden;
    background: var(--color1, #232327);
}
.split-hero--chooser { height: 72vh; min-height: 34rem; }

.split-hero[data-active="left"] { --x: 72%; }
.split-hero[data-active="right"] { --x: 28%; }

.split-side {
    position: absolute;
    inset: 0;
    transition: clip-path 0.55s cubic-bezier(0.65, 0, 0.35, 1), filter 0.45s ease;
}
.split-side--left { clip-path: polygon(0 0, var(--x) 0, var(--x) 100%, 0 100%); }
.split-side--right { clip-path: polygon(var(--x) 0, 100% 0, 100% 100%, var(--x) 100%); }

/* divider line riding the split */
.split-hero::after {
    content: '';
    position: absolute;
    top: 0;
    bottom: 0;
    left: var(--x);
    width: 2px;
    transform: translateX(-1px);
    background: rgba(255, 255, 255, 0.55);
    box-shadow: 0 0 10px rgba(0, 0, 0, 0.4);
    z-index: 2;
    pointer-events: none;
    transition: left 0.55s cubic-bezier(0.65, 0, 0.35, 1);
}

/* softly dim the side that is NOT being explored — keep it recognizable */
.split-hero[data-active="left"] .split-side--right,
.split-hero[data-active="right"] .split-side--left {
    filter: grayscale(0.5) brightness(0.7);
}
.split-hero[data-active="left"] .split-side--right .split-buttons,
.split-hero[data-active="right"] .split-side--left .split-buttons,
.split-hero[data-active="left"] .split-side--right .split-desc,
.split-hero[data-active="right"] .split-side--left .split-desc {
    opacity: 0;
    pointer-events: none;
}

/* The media box matches its side's VISIBLE window (not the full viewport) and
   tracks the divider, so the focal point is positioned within what's actually
   shown and the crop re-centers as the window grows/shrinks. */
.split-media {
    position: absolute;
    top: 0;
    bottom: 0;
    transition: left 0.55s cubic-bezier(0.65, 0, 0.35, 1), width 0.55s cubic-bezier(0.65, 0, 0.35, 1);
}
.split-side--left .split-media { left: 0; width: var(--x); }
.split-side--right .split-media { left: var(--x); width: calc(100% - var(--x)); }

.split-media img,
.split-media video {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    /* editor-set focal point from the Directus image editor */
    object-position: var(--anchor, 50% 50%);
}
.split-media video {
    opacity: 0;
    transition: opacity 0.4s ease;
}
.split-side.playing .split-media video { opacity: 1; }

/* keep the image visible: shade only the lower text area, feather to clear */
.split-shade {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(20, 20, 24, 0.72) 0%, rgba(20, 20, 24, 0.15) 45%, rgba(20, 20, 24, 0.2) 100%);
}

/* each side's content is centered within its own (visible) half and tracks
   the divider as it slides */
.split-content {
    position: absolute;
    bottom: 14%;
    color: #fff;
    text-align: center;
    z-index: 2;
    padding: 0 clamp(1rem, 4vw, 3.5rem);
    transition: width 0.55s cubic-bezier(0.65, 0, 0.35, 1), left 0.55s cubic-bezier(0.65, 0, 0.35, 1);
}
.split-side--left .split-content { left: 0; width: var(--x); }
.split-side--right .split-content { left: var(--x); width: calc(100% - var(--x)); }

.split-name {
    font-size: clamp(1.4rem, 3.2vw, 2.6rem);
    font-weight: 700;
    margin: 0;
    text-shadow: 0 2px 12px rgba(0, 0, 0, 0.6);
}
.split-tagline { margin: 0.25rem 0 0; font-size: clamp(0.95rem, 1.6vw, 1.2rem); text-shadow: 0 1px 8px rgba(0, 0, 0, 0.6); }
.split-capacity {
    margin: 0.15rem 0 0;
    color: var(--color2, #F28A2E);
    font-weight: 600;
    letter-spacing: 0.05em;
    text-shadow: 0 1px 8px rgba(0, 0, 0, 0.7);
}

/* description appears only while a side is expanded */
.split-desc {
    max-width: 34rem;
    margin: 0.75rem auto 0;
    opacity: 0;
    max-height: 0;
    overflow: hidden;
    transition: opacity 0.45s ease 0.15s, max-height 0.5s ease;
    text-shadow: 0 1px 8px rgba(0, 0, 0, 0.7);
}
.split-hero[data-active="left"] .split-side--left .split-desc,
.split-hero[data-active="right"] .split-side--right .split-desc {
    opacity: 1;
    max-height: 14rem;
}

.split-buttons {
    margin-top: 1rem;
    display: flex;
    gap: 0.75rem;
    justify-content: center;
    transition: opacity 0.3s ease;
}
.split-hero .cta-btn {
    font-size: 16pt;
    padding: 0.5rem 2rem;
    font-family: "Quattrocento", serif;
    font-weight: 700;
    font-style: normal;
}

.split-logo {
    position: absolute;
    top: 1.75rem;
    left: 50%;
    transform: translateX(-50%);
    width: min(20vw, 9rem);
    z-index: 3;
    pointer-events: none;
    filter: drop-shadow(0 2px 10px rgba(0, 0, 0, 0.6));
}
.split-logo svg {
    width: 100%;
    height: auto;
    fill: #fff;
}

/* --- mobile: stacked halves, tap to explore ---------------------------- */
@media (max-width: 767px), (hover: none) and (pointer: coarse) {
    .split-hero { height: auto; min-height: 100vh; display: flex; flex-direction: column; }
    .split-hero--chooser { min-height: 80vh; }
    .split-hero::after { display: none; }

    .split-side {
        position: relative;
        inset: auto;
        clip-path: none !important;
        flex: 1 1 50%;
        min-height: 42vh;
        transition: flex 0.5s cubic-bezier(0.65, 0, 0.35, 1), filter 0.45s ease;
    }
    .split-side--left .split-media,
    .split-side--right .split-media { left: 0; width: 100%; }
    .split-hero[data-active="left"] .split-side--left,
    .split-hero[data-active="right"] .split-side--right { flex: 3 1 65%; }

    .split-side .split-content,
    .split-side--left .split-content,
    .split-side--right .split-content {
        left: 0;
        width: 100%;
        text-align: center;
        padding: 0 1.25rem;
        bottom: 2.5rem;
    }

    /* on touch, buttons stay visible on the inactive side — tapping is the hover */
    .split-hero[data-active="left"] .split-side--right .split-buttons,
    .split-hero[data-active="right"] .split-side--left .split-buttons {
        opacity: 1;
        pointer-events: auto;
    }

    .split-logo { width: 9rem; }
}
