/* María Gamero · chrome: the page wrap, the static header, the band, the drop-card menu, the curtain, the footer and its film. */

/* ── Page wrap: the header is sticky inside it, so the footer pushes the header off and it never returns [O] ── */
.page { position: relative; z-index: 1; background: var(--cal); }
main { display: block; position: relative; margin-top: calc(-1 * var(--hd)); }
main:focus { outline: none; }

/* ── navStatic: transparent, Tinta, z 94 under the hero's 95; never hides on scroll [O] ── */
.hd { position: sticky; top: 0; z-index: 94; height: var(--hd); color: var(--ink); }
.hd__in { height: 100%; align-items: center; }
.hd__mark { grid-column: 1 / span 2; justify-self: start; }
.hd__end { grid-column: 10 / -1; display: flex; align-items: center; justify-content: space-between; }
.hd__menu, .hd__book { min-height: var(--hd); display: inline-flex; align-items: center; white-space: nowrap; }
/* js/header.js: white while a photo lies under the item, fading in 0.3 s; back to ink at once (the reviewer's fix,
   2026-10-26: no frame of white labels on Cal) */
.hd .is-on-photo { color: var(--blanco); transition: color .3s var(--std); }
@media (max-width: 767px) {
  .hd__end { grid-column: 4 / -1; justify-content: flex-end; gap: 28px; }
  .hd__end > a { order: -1; } /* [O] mobile: Book, then Menu */
}

/* ── heroBandReveal: the brand band sticky at mid-screen inside the hero [O] ── */
.band-track { position: absolute; inset: 0; z-index: 3; padding-top: 50svh; pointer-events: none; }
.band { position: sticky; top: 50%; height: var(--hd); align-items: center; color: var(--blanco); pointer-events: auto; }
.band__mark { grid-column: 1 / span 2; justify-self: start; }
.band__tag { grid-column: 3 / span 5; }
.band__links { grid-column: 8 / -1; display: flex; justify-content: flex-end; gap: 60px; } /* [O] 60 px gaps */
.band__links a, .band__mob a, .band__mob button { display: inline-flex; align-items: center; min-height: var(--hd); white-space: nowrap; }
.band__mob { display: none; }
@media (max-width: 767px) {
  .band__tag, .band__links { display: none; }
  .band__mob { grid-column: 4 / -1; display: flex; justify-content: flex-end; gap: 28px; }
}
/* first load [O]: wordmark, then tagline, then the film over the Estuco ground, then the links */
.is-loading [data-load] { opacity: 0; }
.is-loading [data-load] { animation: load-failsafe 0s 4s forwards; }
@keyframes load-failsafe { to { opacity: 1; } }

/* ── dropCardMenu [O] ── */
.shade {
  position: fixed; inset: 0; z-index: 120;
  background: rgb(107 90 100 / .18);               /* [O] 20 % warm grey */
  -webkit-backdrop-filter: blur(10px) grayscale(1); /* [O] */
  backdrop-filter: blur(10px) grayscale(1);
  opacity: 0; visibility: hidden; pointer-events: none;
  transition: opacity .5s var(--std), visibility 0s linear .5s; /* [O] 0.5 s (.4,0,.2,1) */
}
.is-menu .shade { opacity: 1; visibility: visible; pointer-events: auto; transition: opacity .5s var(--std); }
.menu { position: fixed; top: 0; right: 0; z-index: 130; width: calc((100% - 2 * var(--m) - 11 * var(--g)) / 12 * 3 + 2 * var(--g) + var(--m)); pointer-events: none; }
.menu__card { position: relative; pointer-events: auto; transform: translate3d(0, -100%, 0); transition: transform 1.2s var(--expo); } /* [O-lib CSS] −693 → 0, 1.2 s easeOutExpo */
.menu__top { position: relative; z-index: 2; background: var(--cal); padding: 0 var(--m) 24px; }
.menu__contact { position: relative; z-index: 1; background: var(--tinta); color: var(--cal); padding: 22px var(--m) 24px; transform: translate3d(0, -100%, 0); transition: transform 1.2s var(--expo); } /* travels its own height further (873): it trails */
.menu.is-open .menu__card, .menu.is-open .menu__contact { transform: none; }
.menu__close { display: flex; align-items: center; min-height: var(--hd); margin-left: 12px; }
.menu__links { margin-top: 18px; }
.menu__links a { display: flex; align-items: baseline; padding-block: 1px; transition: opacity 1.2s var(--expo); }
.menu__links:has(a:hover) a:not(:hover), .menu__links:has(a:focus-visible) a:not(:focus-visible) { opacity: .1; } /* [O] the others dim to 0.1 */
.menu__n { width: 30px; flex: none; transform: translateY(-2px); }
.menu__peeks { position: relative; margin-top: 64px; height: 137px; }
.menu__peek { position: absolute; inset: 0; display: grid; grid-template-columns: 100px 1fr; gap: 12px; opacity: 0; transition: opacity .6s var(--std); }
.menu__peek.is-on { opacity: 1; }
.menu__peek img { width: 100px; height: 137px; object-fit: cover; }
.menu__peek figcaption { align-self: start; }
.menu__contact dl { display: grid; gap: 14px; }
.menu__row { display: grid; grid-template-columns: 30px 1fr; }
[data-menu-item] { opacity: 0; transform: translate3d(0, 24px, 0); }
.menu.is-shown [data-menu-item] { opacity: 1; transform: none; }
.menu.is-open [data-menu-item] { transition: opacity 1.2s var(--expo) calc(.2s + var(--i, 0) * .1s), transform 1.2s var(--expo) calc(.2s + var(--i, 0) * .1s); } /* [O-lib] y 24 → 0, 1.2 s, after 0.2 s, stagger 0.1 */
@media (max-width: 767px) {
  .menu { left: var(--m); right: var(--m); width: auto; top: var(--m); } /* [O] the same card, inset 16 px */
}

/* ── curtain: Cal rises over the leaving page, then exits the top [O-lib] (js/router.js moves it) ── */
.curtain { position: fixed; inset: 0; z-index: 300; background: var(--cal); transform: translate3d(0, 100%, 0); visibility: hidden; pointer-events: none; }
.curtain.is-on { visibility: visible; pointer-events: auto; }

/* ── the film morph (js/morph.js): a film's frame travels into its page, over the leaving page and under the dock.
   The box is one screen at rest (sized in JS), moved by transform alone; the picture inside carries its own rect ── */
.morph-veil { position: fixed; inset: 0; z-index: 298; pointer-events: none; }
.morph { position: fixed; left: 0; top: 0; z-index: 299; overflow: hidden; transform-origin: 0 0; pointer-events: none; will-change: transform; }
.morph__pic { position: absolute; left: 0; top: 0; transform-origin: 0 0; will-change: transform; }
.morph__media { display: block; width: 100%; height: 100%; object-fit: cover; }
.player__loop { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.player__frame.is-playing > .player__loop { display: none; }

/* ── Footer: the Cal panel slides up off a closing film held under it (footerFilmReveal) [O, audit] ── */
.ft { position: relative; z-index: 0; color: var(--ink); }
.ft__panel { position: relative; z-index: 2; background: var(--cal); min-height: 589px; padding-block: 16px 64px; } /* [O] 589 */
.ft__in { row-gap: 0; }
.ft__tag { grid-column: 1 / span 6; }
.ft__rows { grid-column: 1 / span 3; margin-top: 106px; display: grid; gap: 14px; }
.ft__row { display: grid; grid-template-columns: 52px 1fr; }
.ft__hours { grid-column: 4 / span 3; margin-top: 106px; align-self: start; }
.ft__hours th { width: 52px; padding: 0 0 3px; font-weight: 400; }
.ft__hours td { padding: 0 0 3px; }
.ft__hours tr { color: var(--ink-soft); }
.ft__hours tr.is-today { color: var(--ink); }
.ft__legal { grid-column: 1 / -1; margin-top: 150px; display: grid; grid-template-columns: subgrid; align-items: center; }
.ft__legal > :nth-child(1) { grid-column: 1 / span 3; }
.ft__clock { grid-column: 4 / span 2; display: inline-flex; align-items: center; gap: 8px; }
.ft__dot { width: 6px; height: 6px; border-radius: 50%; background: var(--buganvilla); }
.ft__demo { grid-column: 6 / span 4; color: var(--ink-soft); }
.ft__legal > a:nth-of-type(1) { grid-column: 10 / span 1; }
.ft__legal > a:nth-of-type(2) { grid-column: 11 / span 2; justify-self: end; }
.ft__zone { height: var(--film-h); }
.ft__track { position: absolute; z-index: 1; left: 0; right: 0; bottom: 0; height: calc(2 * var(--film-h)); }
.ft__film {
  position: sticky; top: calc(100% - var(--film-h)); display: block; height: var(--film-h);
  overflow: hidden; clip-path: inset(0); background: #3b3427; color: var(--blanco);
}
.ft__media { position: absolute; inset: 0; transform-origin: 50% 50%; will-change: transform; }
.ft__media > * { width: 100%; height: 100%; object-fit: cover; }
/* the cursor label: fixed, moved to the pointer 1:1, clipped to the film by its clip-path [O, audit] */
.ft__label { position: fixed; left: -14px; top: 0; z-index: 5; padding-left: 14px; white-space: nowrap; pointer-events: none; visibility: hidden; }
.ft__label::before { content: ""; position: absolute; left: 0; top: 50%; width: 6px; height: 6px; margin-top: -3px; border-radius: 50%; background: currentColor; }
.has-pointer .ft__label { visibility: visible; }
@media (hover: hover) and (pointer: fine) { .ft__film { cursor: none; } }
@media (hover: none), (pointer: coarse) {
  .ft__label { position: absolute; left: 50%; top: auto; bottom: 22px; visibility: visible; transform: translateX(-50%) !important; }
}
@media (max-width: 767px) {
  .ft__panel { min-height: 0; padding-block: 16px 40px; }
  .ft__rows, .ft__hours { grid-column: 1 / -1; margin-top: 56px; }
  .ft__hours { margin-top: 32px; }
  .ft__legal { margin-top: 56px; display: flex; flex-wrap: wrap; gap: 10px 20px; }
}
