/*
 * Shared shell styles: header/nav, hero + booking card, buttons and footer.
 * Used by the homepage and by the legal pages. The homepage content sections
 * live in home-scrapbook.css (all classes prefixed `vo3-`).
 *
 * Desktop-first: no @media queries here — breakpoints live in shell-responsive.css.
 */

/* ==========================================================================
   Layout helpers
   ========================================================================== */

.vo-container {
    max-width: var(--vo-container);
    margin-inline: auto;
    padding-inline: var(--vo-gutter);
}

section[id] {
    scroll-margin-top: 24px;
}

/* ==========================================================================
   Entrance keyframes (pure CSS, used on the hero on load).
   Scroll-triggered entrances are handled by the "enter" Stimulus controller and
   home-scrapbook.css — elements stay visible by default so content is never
   hidden without JS or under reduced motion.
   ========================================================================== */

@keyframes voFade {
    from { opacity: 0; }
    to { opacity: 1; }
}

@keyframes voUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: none; }
}

/* ==========================================================================
   Buttons
   ========================================================================== */

.vo-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    border-radius: 14px;
    padding: 16px 26px;
    font-family: var(--vo-font-sans);
    font-size: 14.5px;
    font-weight: 600;
    text-decoration: none;
    border: none;
    cursor: pointer;
    white-space: nowrap;
    transition: background .25s ease, color .25s ease, border-color .25s ease;
}

.vo-btn--primary {
    background: var(--vo-terracotta);
    color: var(--vo-cream);
}

.vo-btn--primary:hover {
    background: var(--vo-terracotta-hover);
}

.vo-btn--ghost {
    background: transparent;
    color: var(--vo-cream);
    border: 1px solid rgba(250, 246, 238, .5);
    padding: 11px 22px;
    font-size: 14px;
}

.vo-btn--ghost:hover {
    background: var(--vo-cream);
    color: var(--vo-ink);
    border-color: var(--vo-cream);
}

.vo-btn--evenement {
    background: var(--vo-plum);
    color: var(--vo-cream);
    padding: 13px 22px;
    font-size: 13.5px;
}

.vo-btn--evenement:hover {
    background: color-mix(in srgb, var(--vo-plum) 82%, black);
}

.vo-btn--entreprise {
    background: var(--vo-cream);
    color: var(--vo-slate);
    border: 1px solid var(--vo-slate);
    padding: 13px 22px;
    font-size: 13.5px;
}

.vo-btn--entreprise:hover {
    background: var(--vo-slate);
    color: var(--vo-cream);
}

/* Feature not built yet: rendered but disabled, with a small "coming soon" badge. */
.vo-btn.is-soon {
    opacity: .88;
    cursor: not-allowed;
}

.vo-soon {
    display: inline-block;
    background: rgba(0, 0, 0, .15);
    border-radius: 999px;
    padding: 2px 7px;
    font-size: 10px;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
}

/* ==========================================================================
   Header (overlaid on the hero image)
   ========================================================================== */

.vo-header {
    position: relative;
    /* Above .vo-hero__center (z-index 2), which follows it in the DOM: the
       mobile panel lives inside this header, and at an equal z-index the hero
       title would paint over it and swallow every tap on the nav links. */
    z-index: 5;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    animation: voFade 1s .1s both;
}

.vo-header__brand {
    display: flex;
    align-items: center;
    gap: 11px;
    /* It is a link home on every page, including the homepage itself. */
    color: inherit;
    text-decoration: none;
}

.vo-header__logo {
    height: 40px;
    width: auto;
}

.vo-header__name {
    font-family: var(--vo-font-serif);
    font-size: 22px;
}

.vo-header__nav {
    display: flex;
    gap: 30px;
    font-size: 14px;
    font-weight: 500;
}

.vo-header__nav a {
    text-decoration: none;
    transition: opacity .2s ease;
}

.vo-header__nav a:hover {
    opacity: .7;
}

/* The page you are on. A cream underline rather than a colour change: the nav sits
   over a photograph, where the universe accents (plum, slate) have no contrast. */
.vo-header__nav a.is-current {
    border-bottom: 1px solid currentColor;
    padding-bottom: 2px;
}

.vo-header__actions {
    display: flex;
    align-items: center;
    gap: 14px;
}

/* Burger + mobile nav panel: hidden on desktop, the responsive executor
   toggles their display below the desktop breakpoint. */
.vo-burger {
    display: none;
    flex-direction: column;
    /* Both axes: the bars are narrower than the (round) button. */
    justify-content: center;
    align-items: center;
    gap: 5px;
    width: 40px;
    height: 40px;
    border: none;
    background: transparent;
    cursor: pointer;
    padding: 0;
}

.vo-burger__bar {
    display: block;
    width: 22px;
    height: 2px;
    background: var(--vo-cream);
    border-radius: 2px;
    transition: transform .3s ease, opacity .3s ease;
}

.vo-mobile-panel {
    display: none;
}

/* ==========================================================================
   Hero
   ========================================================================== */

.vo-hero {
    position: relative;
    min-height: 100vh;
    /* Small-viewport units keep the bottom booking card above the collapsed
       mobile browser UI; the plain 100vh line above is the fallback. */
    min-height: 100svh;
    display: flex;
    flex-direction: column;
    color: var(--vo-cream);
    padding: 24px var(--vo-gutter) 40px;
    overflow: hidden;
}

.vo-hero__media {
    position: absolute;
    inset: 0;
    z-index: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transform-origin: center;
    will-change: transform;
}

.vo-hero__scrim {
    position: absolute;
    inset: 0;
    z-index: 1;
    /* Slightly stronger mid-section than the mockup: the video loop contains
       bright frames (white villa roof) that the cream title must stay readable on. */
    background: linear-gradient(180deg, rgba(20, 16, 12, .5) 0%, rgba(20, 16, 12, .26) 26%, rgba(20, 16, 12, .3) 58%, rgba(16, 12, 8, .72) 100%);
}

.vo-hero__center {
    position: relative;
    z-index: 2;
    flex: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    text-align: center;
    padding: 40px 0;
    will-change: transform, opacity;
    animation: voUp 1.1s .15s both;
}

.vo-hero__eyebrow {
    display: inline-flex;
    align-items: center;
    gap: 9px;
    font-size: 13px;
    font-weight: 600;
    letter-spacing: .16em;
    text-transform: uppercase;
    margin: 0 0 24px;
}

.vo-hero__rule {
    width: 26px;
    height: 1px;
    background: rgba(250, 246, 238, .6);
}

.vo-hero__title {
    font-family: var(--vo-font-serif);
    font-weight: 500;
    font-size: clamp(50px, 9vw, 128px);
    line-height: .92;
    margin: 0;
    letter-spacing: -1px;
    text-shadow: 0 4px 40px rgba(0, 0, 0, .3);
}

.vo-hero__title em {
    font-style: italic;
}

.vo-hero__subtitle {
    max-width: 540px;
    margin: 28px 0 0;
    font-size: 17px;
    line-height: 1.6;
    opacity: .92;
}

.vo-hero__book {
    position: relative;
    z-index: 2;
    align-self: center;
    width: 100%;
    max-width: 880px;
    animation: voUp 1.1s .35s both;
}

.vo-hero__note {
    text-align: center;
    margin-top: 16px;
    font-size: 13.5px;
    opacity: .92;
}

.vo-hero__note a {
    color: var(--vo-cream);
    font-weight: 700;
    text-decoration: underline;
    text-underline-offset: 3px;
}

/* Glass booking card */
.vo-book {
    background: rgba(250, 246, 238, .14);
    border: 1px solid rgba(250, 246, 238, .28);
    /* Safari needs the prefix until 18. */
    -webkit-backdrop-filter: blur(18px);
    backdrop-filter: blur(18px);
    border-radius: 22px;
    padding: 14px 14px 14px 24px;
    display: flex;
    align-items: center;
    gap: 10px;
    flex-wrap: wrap;
    box-shadow: var(--vo-shadow-card);
}

.vo-book__field {
    flex: 1;
    min-width: 120px;
}

/* No cursor:pointer here until the date picker actually exists. */
.vo-book__field--dates {
    min-width: 130px;
}

.vo-book__label {
    display: block;
    font-size: 11px;
    font-weight: 600;
    letter-spacing: .05em;
    text-transform: uppercase;
    opacity: .8;
}

.vo-book__price {
    display: block;
    font-family: var(--vo-font-serif);
    font-size: 26px;
    margin-top: 1px;
}

.vo-book__price small {
    font-size: 14px;
    font-family: var(--vo-font-sans);
    opacity: .85;
}

.vo-book__value {
    display: block;
    font-size: 15px;
    font-weight: 600;
    margin-top: 3px;
}

.vo-book__divider {
    width: 1px;
    height: 38px;
    background: rgba(250, 246, 238, .3);
}

.vo-book__field--guests {
    min-width: 140px;
}

.vo-book__guests {
    display: flex;
    align-items: center;
    gap: 13px;
    margin-top: 2px;
}

.vo-book__guest-btn {
    /* 34px minimum so touch targets stay usable on tablets between the
       mobile and desktop breakpoints. */
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 1px solid rgba(250, 246, 238, .5);
    background: transparent;
    color: var(--vo-cream);
    font-size: 15px;
    line-height: 1;
    cursor: pointer;
    transition: background .2s ease;
}

.vo-book__guest-btn:hover {
    background: rgba(250, 246, 238, .18);
}

/* Bound reached (min/max guests): the counter button is disabled by JS. */
.vo-book__guest-btn:disabled {
    opacity: .4;
    cursor: default;
}

.vo-book__guest-btn:disabled:hover {
    background: transparent;
}

.vo-book__count {
    font-size: 16px;
    font-weight: 700;
    min-width: 16px;
    text-align: center;
}

.vo-hero__book .vo-btn--primary {
    white-space: nowrap;
}

/* ==========================================================================
   Misc
   ========================================================================== */

.vo-star {
    color: var(--vo-gold);
}

/* ==========================================================================
   Footer
   ========================================================================== */

.vo-footer {
    border-top: 1px solid rgba(33, 28, 23, .12);
}

.vo-footer__inner {
    padding-block: 34px 70px;
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 30px;
    flex-wrap: wrap;
}

.vo-footer__brand {
    display: flex;
    align-items: center;
    gap: 12px;
}

.vo-footer__logo {
    height: 46px;
    width: auto;
}

.vo-footer__name {
    font-family: var(--vo-font-serif);
    font-size: 22px;
}

.vo-footer__place {
    font-size: 13px;
    color: var(--vo-muted);
    margin-top: 2px;
}

.vo-footer__contact {
    display: flex;
    flex-direction: column;
    gap: 6px;
    font-style: normal;
    font-size: 13.5px;
    color: var(--vo-muted);
}

.vo-footer__contact a {
    text-decoration: none;
}

.vo-footer__contact a:hover {
    color: var(--vo-terracotta);
}

.vo-footer__social {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-top: 2px;
}

.vo-footer__social svg {
    width: 18px;
    height: 18px;
    fill: currentColor;
}

.vo-footer__links {
    display: flex;
    gap: 26px;
    font-size: 13.5px;
    color: var(--vo-muted);
    flex-wrap: wrap;
    align-items: center;
}

.vo-footer__links a {
    text-decoration: none;
}

.vo-footer__links a:hover {
    color: var(--vo-terracotta);
}

/* ==========================================================================
   Back to top

   Lives in the shell, not in the scrapbook layer: the legal pages carry neither,
   and they are the pages where a reader is most likely to be far from the top.
   ========================================================================== */

.vo-to-top {
    position: fixed;
    right: clamp(16px, 3vw, 32px);
    bottom: clamp(16px, 3vw, 32px);
    /* Under the cursor blob (90), and a modal <dialog> is in the top layer, so
       neither ever has to be fought with. */
    z-index: 60;
    display: grid;
    place-items: center;
    width: 48px;
    height: 48px;
    border-radius: 50%;
    /* The accent lives in the scrapbook layer, which the legal pages do not load:
       there the fallback is the site's default terracotta. */
    background: var(--vo3-accent, var(--vo-terracotta));
    color: var(--vo-cream);
    box-shadow: 0 12px 28px -10px rgba(33, 28, 23, .55);

    /* Hidden until the controller says there is a top to go back to. Not
       `display: none`: the arrow has to be able to animate its way in. */
    opacity: 0;
    visibility: hidden;
    transform: translateY(14px);
    transition: opacity .35s ease, transform .45s cubic-bezier(.22, .61, .36, 1),
                visibility 0s linear .35s, background .3s ease;
}

.vo-to-top.is-visible {
    opacity: 1;
    visibility: visible;
    transform: none;
    /* Visibility must flip immediately on the way in, and only after the fade on
       the way out — hence the delay above and its removal here. */
    transition-delay: 0s;
}

.vo-to-top:hover {
    background: var(--vo-ink);
    transform: translateY(-3px);
}

.vo-to-top svg {
    width: 20px;
    height: 20px;
    fill: none;
    stroke: currentColor;
    stroke-width: 2;
    stroke-linecap: round;
    stroke-linejoin: round;
}

/* The custom cursor hides the native one wherever it applies; the arrow is a
   control, so it keeps a pointer of its own. */
body:has(.vo3-cursor) .vo-to-top {
    cursor: pointer;
}
