/* Taste Hospitality: shared tokens, type, buttons, nav, footer, motion.
   Spec: HOMEPAGE-SPEC.md, locked in DECISIONS.md (2026-09-18).
   Used by index.html only for now; other pages move across in a later pass. */

:root {
  /* palette */
  --ink: #161412;
  --deep: #0E0C0B;
  --panel: #211E1B;
  --paper: #FFFFFF;
  --paper-2: #F7F5F2;
  --tile: #EEEAE4;
  --tile-hover: #E6E1D9;
  --mute: #6B665E;
  --mute-dk: #A39D92;
  --line: rgba(22, 20, 18, .12);
  --line-dk: rgba(247, 245, 242, .18);
  --orange: #F0631D;
  --orange-dk: #B8480F;

  /* layout */
  --gutter: 50px;
  --measure: 68ch;
  --section: 120px;
  --nav-h: 78px;
  --r-card: 16px;
  --r-small: 8px;
  --r-panel: 24px;
  --r-pill: 999px;

  /* motion */
  --ease-enter: cubic-bezier(0.16, 1, 0.3, 1);
  --dur-enter: 800ms;
  --rise: 40px;
  --stagger: 200ms;
  --ease-hover: cubic-bezier(0.44, 0, 0.56, 1);
  --dur-hover: 300ms;

  --font: 'Switzer', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
}
@media (max-width: 1024px) { :root { --gutter: 32px; --section: 96px; } }
@media (max-width: 640px)  { :root { --gutter: 20px; --section: 72px; --nav-h: 68px; } }

/* ---------- base ---------- */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
[hidden] { display: none !important; }
html { -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font); font-size: 16px; line-height: 1.6; font-weight: 400;
  color: var(--ink); background: var(--paper);
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  overflow-x: clip;
}
img { display: block; max-width: 100%; }
a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; background: none; border: 0; cursor: pointer; }
ul, ol { list-style: none; }
:focus-visible { outline: 2px solid var(--orange); outline-offset: 3px; }
section[id], footer[id] { scroll-margin-top: var(--nav-h); }

.container { width: 100%; max-width: 1760px; margin-inline: auto; padding-inline: var(--gutter); }
.section { padding-block: var(--section); }
.sr-only { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }

/* ---------- type ---------- */
.h1, .h2, .h3-lg { font-weight: 400; }
.h1 { font-size: clamp(44px, 6.6vw, 96px); line-height: .98; letter-spacing: -0.06em; word-spacing: .1em; }
.h2 { font-size: clamp(36px, 4.2vw, 60px); line-height: 1.04; letter-spacing: -0.045em; word-spacing: .06em; }
.h3-lg { font-size: clamp(26px, 2.4vw, 34px); line-height: 1.1; letter-spacing: -0.04em; }
.h3 { font-size: 22px; line-height: 1.2; font-weight: 500; letter-spacing: -0.02em; }
.lead { font-size: 18px; line-height: 1.6; letter-spacing: -0.01em; }

.eyebrow {
  display: inline-flex; align-items: center; gap: 10px;
  font-size: 13px; line-height: 1.2; font-weight: 500;
  text-transform: uppercase; letter-spacing: .12em; color: var(--mute);
}
.eyebrow::before {
  content: ""; flex: 0 0 auto; width: 12px; height: 11px;
  background: url('../images/taste-asterisk.png') no-repeat center / contain;
}
.on-dark .eyebrow, .eyebrow.on-dark { color: var(--mute-dk); }
.eyebrow + .h2 { margin-top: 20px; }

/* ---------- buttons: split button (label pill + arrow circle) ---------- */
.btn { display: inline-flex; align-items: stretch; gap: 4px; font-size: 15px; font-weight: 500; letter-spacing: -0.01em; line-height: 1; white-space: nowrap; }
.btn__label { display: inline-flex; align-items: center; height: 48px; padding: 0 24px; border-radius: var(--r-pill); }
.btn__arrow { display: inline-grid; place-items: center; width: 48px; height: 48px; border-radius: 50%; overflow: hidden; }
.btn__arrow svg { width: 16px; height: 16px; transition: transform var(--dur-hover) var(--ease-hover); }
.btn__label, .btn__arrow { transition: background-color var(--dur-hover) var(--ease-hover), color var(--dur-hover) var(--ease-hover), border-color var(--dur-hover) var(--ease-hover); }

.btn--primary .btn__label, .btn--primary .btn__arrow { background: var(--orange); color: var(--ink); }
.btn--ink .btn__label, .btn--ink .btn__arrow { background: var(--ink); color: var(--paper); }
.btn--ghost-dk .btn__label, .btn--ghost-dk .btn__arrow { border: 1px solid var(--line-dk); color: var(--paper); }
.btn--ghost .btn__label, .btn--ghost .btn__arrow { border: 1px solid var(--line); color: var(--ink); }

@media (hover: hover) {
  .btn:hover .btn__arrow svg { transform: translateX(3px); }
  .btn--primary:hover .btn__label, .btn--primary:hover .btn__arrow { background: #F47C40; }
  .btn--ink:hover .btn__label, .btn--ink:hover .btn__arrow { background: #2E2A26; }
  .btn--ghost-dk:hover .btn__label, .btn--ghost-dk:hover .btn__arrow { background: rgba(247, 245, 242, .08); border-color: rgba(247, 245, 242, .32); }
  .btn--ghost:hover .btn__label, .btn--ghost:hover .btn__arrow { background: var(--tile); }
}
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

.link-arrow { display: inline-flex; align-items: center; gap: 10px; font-size: 15px; font-weight: 500; color: var(--orange-dk); }
.link-arrow svg { width: 16px; height: 16px; transition: transform var(--dur-hover) var(--ease-hover); }
@media (hover: hover) { .link-arrow:hover svg { transform: translateX(3px); } }

.chip { display: inline-flex; align-items: center; height: 28px; padding: 0 12px; border-radius: var(--r-pill); font-size: 12px; font-weight: 500; letter-spacing: .06em; text-transform: uppercase; }
.chip--light { background: var(--tile); color: var(--ink); }
.chip--dark { background: var(--deep); color: var(--orange); }

/* ---------- grain (bank §2) ---------- */
.grain { position: relative; isolation: isolate; }
.grain::after {
  content: ""; position: absolute; inset: 0; pointer-events: none; z-index: 1;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='240' height='240'%3E%3Cfilter id='g'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.5' numOctaves='2' stitchTiles='stitch' result='n'/%3E%3CfeColorMatrix in='n' type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23g)'/%3E%3C/svg%3E");
  background-size: 240px 240px; opacity: .16; mix-blend-mode: soft-light;
}

/* ---------- nav ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50; height: var(--nav-h);
  background: rgba(14, 12, 11, .72);
  -webkit-backdrop-filter: blur(15px); backdrop-filter: blur(15px);
  border-bottom: 1px solid var(--line-dk);
  color: var(--paper);
}
.nav { height: 100%; display: flex; align-items: center; gap: 40px; }
.nav__logo img { height: 30px; width: auto; }
.nav__menu { flex: 1; display: flex; align-items: center; justify-content: space-between; gap: 32px; }
.navlinks { display: flex; align-items: center; gap: 28px; margin-inline: auto; }
.navlinks > a, .nav-drop__trigger {
  display: inline-flex; align-items: center; gap: 6px; height: var(--nav-h);
  font-size: 15px; color: var(--mute-dk); transition: color var(--dur-hover) var(--ease-hover);
}
.navlinks > a:hover, .nav-drop__trigger:hover, .nav-drop.open .nav-drop__trigger { color: var(--paper); }
.nav-drop { position: relative; }
.nav-drop__caret { width: 10px; height: 10px; transition: transform var(--dur-hover) var(--ease-hover); }
.nav-drop.open .nav-drop__caret { transform: rotate(180deg); }
.nav-drop__panel {
  position: absolute; top: calc(100% - 8px); left: 50%; translate: -50% 0;
  display: none; gap: 40px; padding: 28px 32px;
  background: var(--deep); border: 1px solid var(--line-dk); border-radius: var(--r-card);
  box-shadow: 0 24px 48px -16px rgba(0, 0, 0, .5);
}
.nav-drop.open .nav-drop__panel { display: flex; }
@media (hover: hover) and (min-width: 1101px) {
  .nav-drop:hover .nav-drop__panel, .nav-drop:focus-within .nav-drop__panel { display: flex; }
}
.nav-drop__col { display: flex; flex-direction: column; gap: 4px; min-width: 220px; }
.nav-drop__col .eyebrow { margin-bottom: 8px; color: var(--mute-dk); }
.nav-drop__col a { font-size: 15px; padding: 6px 0; color: var(--paper); white-space: nowrap; transition: color var(--dur-hover) var(--ease-hover); }
.nav-drop__col a:hover { color: var(--orange); }

.nav-actions { display: flex; align-items: center; gap: 20px; }
.nav-call { display: inline-flex; align-items: center; gap: 8px; font-size: 15px; color: var(--paper); }
.nav-call svg { width: 16px; height: 16px; color: var(--orange); }
.nav-actions .btn__label { height: 40px; padding: 0 18px; }
.nav-actions .btn__arrow { width: 40px; height: 40px; }
.nav-mobile { display: none; align-items: center; gap: 8px; margin-left: auto; }
.nav-mobile__call, .nav-toggle { display: inline-grid; place-items: center; width: 44px; height: 44px; border-radius: 50%; border: 1px solid var(--line-dk); }
.nav-mobile__call svg { width: 18px; height: 18px; color: var(--orange); }
.nav-toggle span { display: block; width: 18px; height: 1.5px; background: var(--paper); transition: transform var(--dur-hover) var(--ease-hover), opacity var(--dur-hover); }
.nav-toggle { grid-template-rows: repeat(3, 6px); align-content: center; }

@media (max-width: 1100px) {
  .nav { gap: 16px; }
  .nav-mobile { display: flex; }
  .nav__menu {
    position: absolute; top: var(--nav-h); left: 0; right: 0;
    display: none; flex-direction: column; align-items: stretch; gap: 24px;
    max-height: calc(100svh - var(--nav-h)); overflow-y: auto;
    padding: 12px var(--gutter) 32px; background: var(--deep); border-bottom: 1px solid var(--line-dk);
  }
  .site-header.nav-open .nav__menu { display: flex; }
  .navlinks { flex-direction: column; align-items: stretch; gap: 0; margin: 0; }
  .navlinks > a, .nav-drop__trigger { height: auto; width: 100%; justify-content: space-between; padding: 16px 0; font-size: 20px; color: var(--paper); border-bottom: 1px solid var(--line-dk); }
  .nav-drop__panel { position: static; translate: none; flex-direction: column; gap: 20px; padding: 16px 0 20px; background: none; border: 0; box-shadow: none; }
  .nav-actions { flex-direction: column; align-items: flex-start; gap: 16px; }
  .site-header.nav-open .nav-toggle span:nth-child(1) { transform: translateY(6px) rotate(45deg); }
  .site-header.nav-open .nav-toggle span:nth-child(2) { opacity: 0; }
  .site-header.nav-open .nav-toggle span:nth-child(3) { transform: translateY(-6px) rotate(-45deg); }
}

/* ---------- footer ---------- */
.site-footer { background: var(--ink); color: var(--paper); padding: var(--section) 0 40px; overflow: clip; }
.site-footer > .container { position: relative; z-index: 2; }
.foot-top { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: end; gap: 40px; padding-bottom: 80px; }
.foot-top .h1 { max-width: 14em; transform-origin: left bottom; }
.foot-grid { display: grid; grid-template-columns: repeat(4, 1fr); border-top: 1px solid var(--line-dk); border-bottom: 1px solid var(--line-dk); }
.foot-cell { padding: 32px 32px 40px; display: flex; flex-direction: column; gap: 10px; }
.foot-cell + .foot-cell { border-left: 1px solid var(--line-dk); }
.foot-cell:first-child { padding-left: 0; }
.foot-cell .eyebrow { margin-bottom: 10px; }
.foot-cell a { font-size: 15px; color: var(--mute-dk); width: fit-content; transition: color var(--dur-hover) var(--ease-hover); }
.foot-cell a:hover { color: var(--paper); }
.foot-cell a.foot-phone { font-size: clamp(26px, 2.4vw, 34px); letter-spacing: -0.04em; color: var(--paper); line-height: 1.1; }
.foot-cell a.foot-phone:hover { color: var(--orange); }
.foot-wordmark { padding: 64px 0 32px; }
.foot-wordmark img { width: 100%; height: auto; }
.foot-bottom { display: flex; justify-content: space-between; gap: 20px; flex-wrap: wrap; font-size: 13px; color: var(--mute-dk); }
.foot-bottom a { text-decoration: underline; text-underline-offset: 3px; }
@media (max-width: 1024px) {
  .foot-top { grid-template-columns: 1fr; }
  .foot-grid { grid-template-columns: 1fr 1fr; }
  .foot-cell:nth-child(3) { border-left: 0; padding-left: 0; }
  .foot-cell:nth-child(n+3) { border-top: 1px solid var(--line-dk); }
}
@media (max-width: 560px) {
  .foot-grid { grid-template-columns: 1fr; }
  .foot-cell { padding-left: 0; padding-right: 0; }
  .foot-cell + .foot-cell { border-left: 0; border-top: 1px solid var(--line-dk); }
}

/* ---------- shared components (homepage + inner pages) ---------- */
/* ===== 8. Mid CTA: photo + orange panel over its corner ===== */
.brief-cta { background: var(--paper); padding-bottom: calc(var(--section) + 64px); }
.brief-cta__grid { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: 20px; }
.brief-cta__photo { grid-column: 1 / 9; grid-row: 1; height: 560px; border-radius: var(--r-panel); overflow: hidden; }
.brief-cta__photo img { width: 100%; height: 100%; object-fit: cover; }
.brief-cta__panel {
  grid-column: 7 / 13; grid-row: 1; align-self: end; margin-bottom: -64px; position: relative;
  background: var(--orange); color: var(--ink); border-radius: var(--r-panel); padding: 48px;
}
.brief-cta__panel p { margin-top: 20px; font-size: 17px; line-height: 1.6; max-width: 40ch; }
.brief-cta__panel .btn { margin-top: 32px; }
@media (max-width: 900px) {
  .brief-cta { padding-bottom: var(--section); }
  .brief-cta__grid { display: block; }
  .brief-cta__photo { height: 340px; }
  .brief-cta__panel { margin: -48px 12px 0; padding: 32px 28px; }
}


/* ruled role rows */
.role-row { display: flex; align-items: center; justify-content: space-between; gap: 16px; min-height: 64px; padding: 12px 16px 12px 24px; border-bottom: 1px solid var(--line); transition: background-color var(--dur-hover) var(--ease-hover); }
.role-row:last-child { border-bottom: 0; }
.role-row span:first-child { font-size: 20px; line-height: 1.25; letter-spacing: -0.02em; transition: transform var(--dur-hover) var(--ease-hover); }
.arrow-circle { display: grid; place-items: center; flex: 0 0 auto; width: 36px; height: 36px; border-radius: 50%; border: 1px solid var(--line); transition: background-color var(--dur-hover) var(--ease-hover), border-color var(--dur-hover) var(--ease-hover); }
.arrow-circle svg { width: 14px; height: 14px; }
@media (hover: hover) {
  .role-row:hover { background: var(--tile); }
  .role-row:hover span:first-child { transform: translateX(8px); }
  .role-row:hover .arrow-circle { background: var(--orange); border-color: var(--orange); }
}

/* space-between card with hover lift and tonal shift */
.pcell { display: flex; }
.pcard {
  flex: 1; min-height: 300px; padding: 32px; border-radius: var(--r-card); background: var(--tile);
  display: flex; flex-direction: column; justify-content: space-between; gap: 48px;
  transition: transform var(--dur-hover) var(--ease-hover), background-color var(--dur-hover) var(--ease-hover), box-shadow var(--dur-hover) var(--ease-hover);
}
.icon-tile { display: grid; place-items: center; width: 48px; height: 48px; border-radius: var(--r-small); background: var(--ink); color: var(--orange); transition: background-color var(--dur-hover) var(--ease-hover), color var(--dur-hover) var(--ease-hover); }
.icon-tile svg { width: 24px; height: 24px; fill: currentColor; }
.pcard__text { display: flex; flex-direction: column; gap: 12px; }
.pcard__step { font-size: 13px; font-weight: 500; color: var(--mute); letter-spacing: .02em; }
.pcard__text p:last-child { font-size: 15px; line-height: 1.55; color: var(--mute); min-height: calc(3 * 1.55em); max-width: 40ch; }
/* Hover lift with tonal shift, driven from the stable cell so the card can
   never rise out from under the pointer (the lift-flicker trap). */
@media (hover: hover) {
  .pcell:hover .pcard { transform: translateY(-6px); background: var(--tile-hover); box-shadow: 0 18px 32px -20px rgba(22,20,18,.28); }
  .pcell:hover .icon-tile { background: var(--orange); color: var(--ink); }
}

/* ---------- motion ----------
   Page-load hero: pure CSS, gated on html.js (set inline in <head>).
   Scroll entrances: gated on html.anim, which site.js sets only when it runs
   and motion is allowed. Without JS nothing is ever hidden. */
.js .hero-in { animation: rise var(--dur-enter) var(--ease-enter) both; animation-delay: calc(var(--i, 0) * var(--stagger)); }
.js .hero-in--big { --d: 80px; }
.js .hero-draw { animation: draw var(--dur-enter) var(--ease-enter) both; animation-delay: calc(var(--i, 0) * var(--stagger)); transform-origin: left center; }
@keyframes rise { from { opacity: 0; transform: translateY(var(--d, 40px)); } }
@keyframes draw { from { transform: scaleX(0); } }

[data-reveal], [data-stagger] > * {
  transition: opacity var(--dur-enter) var(--ease-enter), transform var(--dur-enter) var(--ease-enter);
  transition-delay: calc(var(--i, 0) * var(--stagger));
}
.anim [data-reveal]:not(.is-in),
.anim [data-stagger]:not(.is-in) > * { opacity: 0; transform: translateY(var(--rise)); }

@keyframes pull-img { from { transform: scale(1.2); } to { transform: none; } }
@keyframes pull-type { from { transform: scale(1.4); } to { transform: none; } }
@supports (animation-timeline: view()) {
  @media (prefers-reduced-motion: no-preference) {
    .pullback img { animation: pull-img linear both; animation-timeline: view(); animation-range: entry 0% cover 50%; }
    .pullback-type { animation: pull-type linear both; animation-timeline: view(); animation-range: entry 0% cover 45%; }
  }
}
@media (max-width: 640px) { @keyframes pull-type { from { transform: scale(1.2); } to { transform: none; } } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition-duration: 0s !important; transition-delay: 0s !important; scroll-behavior: auto !important; }
  .anim [data-reveal]:not(.is-in), .anim [data-stagger]:not(.is-in) > * { opacity: 1; transform: none; }
}
