/* Joey Dawson, chef. Palette is taken from the plates. */
:root {
  /* Palette borrowed from a navy and blush reference site */
  --bg: #292C40;
  --surface: #323650;
  --ink: #E6D9D0;
  --muted: #AEA8B3;
  --line: #424753;
  --line-strong: #5A5F78;
  --accent: #C9A998;
  --serif: "Marcellus", Georgia, "Times New Roman", serif;
  --sans: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --gutter: clamp(1.25rem, 5vw, 3rem);
  --max: 1120px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-top: 4.5rem; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 400 1.0625rem/1.7 var(--sans);
  -webkit-font-smoothing: antialiased;
}
[hidden] { display: none !important; }
img { display: block; max-width: 100%; height: auto; }
a { color: inherit; }
h1, h2 { color: var(--accent); font-family: var(--serif); font-weight: 400; line-height: 1.1; margin: 0; letter-spacing: -0.01em; }
p { margin: 0 0 1.1em; }
ul { list-style: none; margin: 0; padding: 0; }

.wrap { width: 100%; max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap; margin: -1px; padding: 0; border: 0;
}

/* Focus: the one place the accent is always visible */
:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; border-radius: 2px; }

.skip {
  position: absolute; left: 1rem; top: -4rem; background: var(--accent); color: var(--bg);
  padding: .6rem 1rem; z-index: 100; text-decoration: none;
}
.skip:focus { top: 1rem; }

/* Header (dark, so it sits cleanly on the hero) */
.site-header {
  position: sticky; top: 0; z-index: 20;
  background: rgba(41, 44, 64, .94);
  color: var(--ink);
  backdrop-filter: blur(8px);
}
.site-header__inner { display: flex; align-items: center; justify-content: space-between; min-height: 3.5rem; gap: 1rem; max-width: none; }
.brand { font-family: var(--serif); font-size: 1.2rem; text-decoration: none; color: var(--accent); }
.nav { display: flex; gap: clamp(1rem, 4vw, 2rem); font-size: .95rem; }
.nav a { text-decoration: none; padding: .5rem 0; background: linear-gradient(var(--accent), var(--accent)) 0 100% / 0 1px no-repeat; transition: background-size .25s; }
.nav a:hover { background-size: 100% 1px; }

@media (max-width: 359px) {
  .brand { font-size: 1rem; white-space: nowrap; }
  .nav { gap: .75rem; font-size: .85rem; }
}

/* Hero: the food is the stage. Full-bleed photo with the name and tagline on top of it. */
.hero { background: var(--bg); color: var(--ink); position: relative; overflow: hidden; }
.hero__inner {
  position: relative; display: grid; align-content: end; gap: .5rem;
  height: min(calc(100svh - 3.5rem), 133.4vw); min-height: 440px;
  padding: 0 var(--gutter) clamp(1.5rem, 6vw, 2.5rem);
}
.hero__photo { position: absolute; inset: 0; }
.hero__photo::after { content: ""; position: absolute; inset: 0; background: linear-gradient(to top, rgba(41,44,64,.92) 0%, rgba(41,44,64,.5) 38%, rgba(41,44,64,0) 62%); }
.hero__img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 50%; }
.hero__name, .hero__tagline, .cue { position: relative; z-index: 1; }
.hero__name { font-size: clamp(2.4rem, 11.5vw, 4.5rem); font-weight: 400; line-height: 1; white-space: nowrap; color: var(--accent); }
.hero__tagline { font-family: var(--serif); font-size: clamp(1.25rem, 5vw, 1.7rem); margin: .4rem 0 .6rem; opacity: .95; }
.cue { justify-self: start; font-size: .95rem; text-decoration: none; border-bottom: 1px solid currentColor; padding-bottom: 2px; }
.cue:hover { color: var(--accent); }

@media (min-width: 900px) {
  .hero__inner {
    height: calc(100svh - 3.5rem); min-height: 520px; max-height: 1000px;
    padding: 0 clamp(2rem, 6vw, 6rem) clamp(2.5rem, 6vh, 4.5rem);
  }
  .hero__photo::after {
    background:
      linear-gradient(to top, rgba(41,44,64,.94) 0%, rgba(41,44,64,.65) 28%, rgba(41,44,64,0) 60%),
      linear-gradient(to right, rgba(41,44,64,.6) 0%, rgba(41,44,64,0) 55%);
  }
  /* Enlarge the photo and anchor it left, so the dessert sits right of centre and the text has room on the left */
  .hero__img { position: absolute; left: 6vw; top: 0; width: 128%; max-width: none; height: 100%; object-fit: cover; object-position: 0 46%;
    -webkit-mask-image: linear-gradient(to right, transparent 0, #000 12vw); mask-image: linear-gradient(to right, transparent 0, #000 12vw); }
  .hero__name { font-size: clamp(3.6rem, 6.4vw, 6.75rem); }
  .hero__tagline { font-size: clamp(1.4rem, 2.3vw, 2.2rem); margin: .6rem 0 1.25rem; }
}

/* Sections */
.section { padding-block: clamp(3.5rem, 9vw, 7rem); }
.section h2 { font-size: clamp(2rem, 6vw, 3rem); }

/* About */
.about__inner { display: grid; gap: 2rem; }
.about__portrait { width: min(240px, 60%); }
.about__img { width: 100%; border-radius: 2px; }
.about__copy { max-width: 38rem; }
.about__copy h2 { margin-bottom: 1.25rem; }
.about__copy p { font-size: .95rem; line-height: 1.7; }
@media (min-width: 540px) {
  .about__inner { grid-template-columns: clamp(150px, 30vw, 240px) 1fr; gap: clamp(1.5rem, 6vw, 5rem); align-items: start; }
  .about__portrait { width: 100%; }
}

/* Food */
.food { border-top: 1px solid var(--line); }
.food__head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 1rem 2rem; margin-bottom: 2rem; }
.filters { display: flex; gap: .5rem; flex-wrap: wrap; }
.filter {
  font: inherit; font-size: .95rem; background: none; color: var(--ink); cursor: pointer;
  border: 1px solid var(--line-strong); border-radius: 999px; padding: .4rem 1.1rem; line-height: 1.4;
  transition: background-color .2s, color .2s, border-color .2s;
}
.filter:hover { border-color: var(--accent); }
.filter[aria-pressed="true"] { background: var(--accent); border-color: var(--accent); color: var(--bg); }

/* Masonry that keeps each photo's own proportions */
.gallery { column-count: 2; column-gap: clamp(.6rem, 2vw, 1.25rem); }
.item { break-inside: avoid; margin: 0 0 clamp(.6rem, 2vw, 1.25rem); }
.item[hidden] { display: none; }
.thumb { display: block; width: 100%; padding: 0; border: 0; background: var(--surface); cursor: zoom-in; border-radius: 2px; overflow: hidden; }
.thumb img { width: 100%; height: auto; transition: transform .5s ease; }
.thumb:hover img { transform: scale(1.02); }
@media (min-width: 900px) { .gallery { column-count: 3; } }

.food__more { margin: 2.5rem 0 0; text-align: center; }
.link { text-decoration: none; color: var(--accent); border-bottom: 1px solid currentColor; padding-bottom: 2px; font-weight: 500; }
.link:hover { color: var(--ink); }

/* Contact */
.contact { border-top: 1px solid var(--line); }
.contact__inner { display: grid; gap: 2rem; }
.contact__intro p { font-family: var(--serif); font-size: clamp(1.25rem, 3.5vw, 1.6rem); line-height: 1.35; margin: 1.25rem 0 0; max-width: 24rem; }
.form { display: grid; gap: 1.25rem; max-width: 34rem; }
.field label { display: block; font-size: .9rem; color: var(--muted); margin-bottom: .35rem; }
.field input, .field textarea {
  width: 100%; font: inherit; color: var(--ink); background: var(--surface);
  border: 1px solid var(--line-strong); border-radius: 3px; padding: .75rem .9rem;
}
.field textarea { resize: vertical; min-height: 9rem; }
.field input:focus-visible, .field textarea:focus-visible { outline-offset: 1px; border-color: var(--accent); }
.btn {
  justify-self: start; font: 500 1rem var(--sans); background: var(--accent); color: var(--bg);
  border: 0; border-radius: 3px; padding: .85rem 1.8rem; cursor: pointer; transition: background-color .2s;
}
.btn:hover { background: var(--ink); }
.btn[disabled] { opacity: .6; cursor: progress; }
.form__error { color: #F3B7A6; margin: 0; font-weight: 500; }
.form__success { max-width: 30rem; }
.form__success > p:first-child { font-family: var(--serif); font-size: 1.4rem; line-height: 1.4; }
.form__fallback, .form__copied { font-size: .95rem; color: var(--muted); }
.linkbtn { font: inherit; color: var(--accent); background: none; border: 0; border-bottom: 1px solid currentColor; padding: 0; cursor: pointer; }
.linkbtn:hover { color: var(--ink); }
.form__success:focus { outline: none; }
@media (min-width: 900px) { .contact__inner { grid-template-columns: 1fr 1.2fr; gap: 5rem; } }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding-block: 2rem; font-size: .95rem; color: var(--muted); }
.site-footer__inner { display: flex; justify-content: space-between; flex-wrap: wrap; gap: .5rem 2rem; }
.site-footer p { margin: 0; }

/* Lightbox */
.lightbox {
  position: fixed; inset: 0; width: 100%; height: 100%; max-width: none; max-height: none;
  margin: 0; padding: 0; border: 0; background: rgba(22, 24, 38, .97); color: var(--ink);
}
.lightbox::backdrop { background: rgba(22, 24, 38, .97); }
.lightbox[open] { display: grid; place-items: center; }
.lb-figure { margin: 0; padding: 4rem 1rem 1.5rem; max-width: 100%; display: grid; justify-items: center; gap: 1rem; }
.lb-figure img { max-width: min(100%, 1400px); max-height: calc(100svh - 9rem); width: auto; height: auto; object-fit: contain; border-radius: 2px; }
.lb-figure figcaption { font-family: var(--serif); font-size: 1.15rem; text-align: center; min-height: 1.6em; }
.lb-btn {
  position: absolute; background: rgba(230, 217, 208, .12); color: var(--ink); border: 0; border-radius: 50%;
  width: 3rem; height: 3rem; font: 300 2rem/1 var(--sans); cursor: pointer; display: grid; place-items: center; padding-bottom: .2rem;
}
.lb-btn:hover { background: rgba(230, 217, 208, .25); }
.lightbox :focus-visible { outline-color: var(--accent); }
.lb-close { top: .75rem; right: .75rem; }
.lb-prev, .lb-next { top: 50%; transform: translateY(-50%); }
.lb-prev { left: .5rem; }
.lb-next { right: .5rem; }
@media (max-width: 600px) {
  .lb-prev, .lb-next { top: auto; bottom: .75rem; transform: none; }
  .lb-figure { padding-bottom: 4.5rem; }
  .lb-figure img { max-height: calc(100svh - 12rem); }
}

/* Gentle fade-in on scroll (only when JS is on and motion is OK) */
@media (prefers-reduced-motion: no-preference) {
  .js .reveal { opacity: 0; transform: translateY(14px); transition: opacity .8s ease, transform .8s ease; }
  .js .reveal.is-in { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  * { transition: none !important; animation: none !important; }
}
