/* ==========================================================================
   Innamorato — site styles
   Palette and type follow the Brand Strategy Blueprint v1.0 (section 8).
   Signature device: the arch — a quiet nod to Italian architecture and to
   the proscenium of the theatre where the Innamorati first took the stage.
   Everything else stays restrained.
   ========================================================================== */

@font-face {
  font-family: "Bodoni Moda";
  src: url("/assets/fonts/bodoni-moda-latin-opsz-normal.woff2") format("woff2-variations");
  font-weight: 400 900;
  font-style: normal;
  font-display: swap;
}
@font-face {
  font-family: "Bodoni Moda";
  src: url("/assets/fonts/bodoni-moda-latin-opsz-italic.woff2") format("woff2-variations");
  font-weight: 400 900;
  font-style: italic;
  font-display: swap;
}
@font-face {
  font-family: "Jost";
  src: url("/assets/fonts/jost-latin-wght-normal.woff2") format("woff2-variations");
  font-weight: 300 700;
  font-style: normal;
  font-display: swap;
}

:root {
  /* Brand palette */
  --ivory: #F4F0E7;
  --champagne: #D9C6A3;
  --burgundy: #572B35;
  --espresso: #302621;
  --sage: #858B78;

  /* Working tints derived from the palette */
  --ivory-deep: #EBE4D6;      /* alternate section ground */
  --sage-ink: #5C6253;        /* sage dark enough for text on ivory (AA) */
  --burgundy-deep: #44212A;   /* hover / pressed */
  --champagne-soft: #E8DCC4;
  --line: rgba(48, 38, 33, 0.16);
  --line-on-dark: rgba(217, 198, 163, 0.35);

  --serif: "Bodoni Moda", "Didot", "Bodoni 72", Georgia, serif;
  --sans: "Jost", "Futura", "Century Gothic", system-ui, sans-serif;

  /* Type scale — a 1.25 ratio from an 18px body */
  --fs-sm: 0.875rem;
  --fs-base: 1.125rem;
  --fs-md: 1.375rem;
  --fs-lg: clamp(1.6rem, 1.3rem + 1.2vw, 2.1rem);
  --fs-xl: clamp(2.1rem, 1.6rem + 2.2vw, 3.2rem);
  --fs-display: clamp(2.6rem, 1.6rem + 4.2vw, 5.4rem);

  --measure: 34em;
  --gutter: clamp(1.25rem, 4vw, 3.5rem);
  --section: clamp(4.5rem, 9vw, 9rem);
  --max: 78rem;
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) { html { scroll-behavior: auto; } }

body {
  margin: 0;
  background: var(--ivory);
  color: var(--espresso);
  font-family: var(--sans);
  font-size: var(--fs-base);
  font-weight: 380;
  line-height: 1.6;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; display: block; }

h1, h2, h3 {
  font-family: var(--serif);
  font-weight: 400;
  line-height: 1.08;
  letter-spacing: -0.01em;
  margin: 0 0 0.5em;
  font-optical-sizing: auto;
  text-wrap: balance;
}
h1 { font-size: var(--fs-display); }
h2 { font-size: var(--fs-xl); }
h3 { font-size: var(--fs-lg); line-height: 1.15; }

p { margin: 0 0 1.1em; max-width: var(--measure); text-wrap: pretty; }

a { color: inherit; text-decoration-thickness: 1px; text-underline-offset: 0.22em; }
a:hover { text-decoration-color: var(--burgundy); }

:focus-visible {
  outline: 2px solid var(--burgundy);
  outline-offset: 3px;
}
.on-dark :focus-visible { outline-color: var(--champagne); }

.skip-link {
  position: absolute; left: 1rem; top: -4rem;
  background: var(--burgundy); color: var(--ivory);
  padding: 0.6rem 1rem; z-index: 100; text-decoration: none;
}
.skip-link:focus { top: 1rem; }

.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); white-space: nowrap;
}

.wrap { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }

/* ---------- Placeholder content still to be confirmed ---------- */
.tbc {
  background: rgba(133, 139, 120, 0.16);
  border-bottom: 1px dashed var(--sage-ink);
  padding: 0 0.2em;
  font-style: normal;
}
.on-dark .tbc { background: rgba(217, 198, 163, 0.14); border-color: var(--champagne); }

/* ---------- Header ---------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(244, 240, 231, 0.94);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--line);
}
.site-header .wrap {
  display: flex; align-items: center; justify-content: space-between;
  gap: 1.5rem; min-height: 4.75rem;
}
.wordmark {
  font-family: var(--serif);
  font-size: 1.65rem;
  font-weight: 400;
  letter-spacing: 0.04em;
  text-decoration: none;
  color: var(--burgundy);
  line-height: 1;
}
.wordmark span { font-style: italic; }

.nav { display: flex; align-items: center; gap: 2rem; }
.nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 1.6rem; }
.nav a {
  text-decoration: none; font-size: 0.98rem; letter-spacing: 0.02em;
  padding: 0.3rem 0; border-bottom: 1px solid transparent;
}
.nav a:hover, .nav a[aria-current="page"] { border-bottom-color: var(--burgundy); }
.nav .btn { padding: 0.6rem 1.15rem; border: 1px solid var(--burgundy); }

.nav-toggle {
  display: none; background: none; border: 1px solid var(--line);
  font: inherit; font-size: 0.95rem; color: var(--espresso);
  padding: 0.45rem 0.9rem; cursor: pointer;
}

@media (max-width: 1020px) {
  .nav-toggle { display: inline-block; }
  .nav {
    position: absolute; left: 0; right: 0; top: 100%;
    flex-direction: column; align-items: stretch; gap: 0;
    background: var(--ivory); border-bottom: 1px solid var(--line);
    padding: 0.5rem var(--gutter) 1.5rem;
    display: none;
  }
  .nav.is-open { display: flex; }
  .nav ul { flex-direction: column; gap: 0; }
  .nav ul a { display: block; padding: 0.85rem 0; border-bottom: 1px solid var(--line); font-size: 1.1rem; }
  .nav .btn { margin-top: 1.25rem; text-align: center; }
  .no-js .nav { display: flex; position: static; }
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-block;
  font-family: var(--sans); font-size: 0.98rem; font-weight: 450; letter-spacing: 0.03em;
  text-decoration: none; cursor: pointer;
  padding: 0.85rem 1.6rem;
  border: 1px solid var(--burgundy);
  background: var(--burgundy); color: var(--ivory);
  transition: background-color 0.2s ease, color 0.2s ease;
}
.btn:hover { background: var(--burgundy-deep); }
.btn-quiet { background: transparent; color: var(--burgundy); }
.btn-quiet:hover { background: var(--burgundy); color: var(--ivory); }
.on-dark .btn { background: var(--champagne); border-color: var(--champagne); color: var(--espresso); }
.on-dark .btn:hover { background: var(--ivory); border-color: var(--ivory); }
.on-dark .btn-quiet { background: transparent; color: var(--champagne); }
.on-dark .btn-quiet:hover { background: var(--champagne); color: var(--espresso); }
.actions { display: flex; flex-wrap: wrap; gap: 0.9rem; margin-top: 2rem; }

/* ---------- Image frames (placeholders until real photography) ---------- */
.frame {
  position: relative; overflow: hidden;
  background:
    radial-gradient(120% 80% at 50% 100%, rgba(217,198,163,0.55), transparent 70%),
    linear-gradient(180deg, var(--champagne-soft), #D7CCB6);
  aspect-ratio: 4 / 5;
}
.frame > img { width: 100%; height: 100%; object-fit: cover; }
.frame.arch { border-radius: 999px 999px 0 0; }
.frame.wide { aspect-ratio: 3 / 2; }
.frame.square { aspect-ratio: 1; }
.frame.tall { aspect-ratio: 2 / 3; }
.frame.dark {
  background:
    radial-gradient(90% 60% at 50% 78%, rgba(217,198,163,0.32), transparent 70%),
    linear-gradient(180deg, #6A3742, #3E1F27);
}
.ph-note {
  position: absolute; left: 0; right: 0; bottom: 0;
  padding: 1rem 1.1rem;
  font-size: var(--fs-sm); line-height: 1.45;
  color: var(--espresso);
}
.ph-note b { font-weight: 500; display: block; }
.frame.dark .ph-note { color: var(--champagne); }
.frame.arch .ph-note { text-align: center; padding-bottom: 1.4rem; }

/* ---------- Hero ---------- */
.hero {
  background: var(--burgundy); color: var(--ivory);
  padding: clamp(3rem, 5.5vw, 5rem) 0;
  overflow: hidden;
}
.hero .wrap {
  display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: clamp(2rem, 5vw, 5rem); align-items: center;
}
.hero h1 { color: var(--ivory); margin-bottom: 0.45em; }
.hero h1 .line { display: block; }
.hero h1 .line + .line { font-style: italic; padding-left: clamp(1.5rem, 6vw, 5.5rem); color: var(--champagne); }
.hero .lede { font-size: var(--fs-md); line-height: 1.5; color: var(--champagne-soft); max-width: 28em; }
.hero-copy { padding-bottom: 0; }
.hero-arch { justify-self: end; width: min(100%, 30rem); }
.hero-arch .frame { aspect-ratio: 3 / 4; }

/* The one orchestrated moment: the hero photograph warms into view, like a candle being lit. */
.hero-arch .frame { background: var(--burgundy-deep); }
.hero-arch img { animation: candle-in 2.2s ease-out 0.2s both; }
@keyframes candle-in { from { opacity: 0; filter: brightness(0.55); } to { opacity: 1; filter: brightness(1); } }
@media (prefers-reduced-motion: reduce) { .hero-arch img { animation: none; } }
.candle {
  position: absolute; inset: 0; pointer-events: none;
  background: radial-gradient(55% 38% at 50% 72%, rgba(244, 222, 170, 0.55), transparent 72%);
  opacity: 0;
  animation: candle-light 2.4s ease-out 0.4s forwards, candle-breathe 7s ease-in-out 2.8s infinite;
}
@keyframes candle-light { to { opacity: 1; } }
@keyframes candle-breathe { 0%, 100% { opacity: 1; } 50% { opacity: 0.78; } }
@media (prefers-reduced-motion: reduce) {
  .candle { animation: none; opacity: 1; }
}

.page-hero { background: var(--burgundy); color: var(--ivory); padding: clamp(3.5rem, 7vw, 6rem) 0; }
.page-hero h1 { font-size: clamp(2.6rem, 1.8rem + 3.6vw, 4.8rem); color: var(--ivory); }
.page-hero p { font-size: var(--fs-md); line-height: 1.5; color: var(--champagne-soft); max-width: 32em; }
.page-hero .actions { margin-top: 1.5rem; }

/* ---------- Sections ---------- */
.section { padding: var(--section) 0; }
.section.alt { background: var(--ivory-deep); }
.section.dark { background: var(--espresso); color: var(--ivory); }
.section.dark h2, .section.dark h3 { color: var(--ivory); }
.section.dark p { color: var(--champagne-soft); }

.intro { max-width: 46rem; }
.intro p { font-size: var(--fs-md); line-height: 1.55; }
.statement {
  font-family: var(--serif); font-size: var(--fs-lg); line-height: 1.35;
  max-width: 30em; margin: 0;
}

.split {
  display: grid; grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(2rem, 6vw, 6rem); align-items: center;
}
.split.reverse > :first-child { order: 2; }

.split.form-split { grid-template-columns: minmax(0, 0.75fr) minmax(0, 1.25fr); align-items: start; }

/* Home: the two ways in */
.paths { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: clamp(2rem, 5vw, 5rem); }
.path .frame { margin-bottom: 1.8rem; }
.path h3 { font-size: var(--fs-xl); }
.path p { color: var(--sage-ink); }
.path:nth-child(2) { margin-top: clamp(0rem, 8vw, 7rem); }

/* Lists of offerings */
.offer-list { list-style: none; padding: 0; margin: 2rem 0 0; border-top: 1px solid var(--line); }
.offer-list li {
  display: grid; grid-template-columns: minmax(10rem, 0.9fr) minmax(0, 1.6fr);
  gap: 1rem 2.5rem; padding: 1.6rem 0; border-bottom: 1px solid var(--line);
}
.offer-list h3 { font-size: var(--fs-md); margin: 0; }
.offer-list p { margin: 0; color: var(--sage-ink); }
.on-dark .offer-list, .section.dark .offer-list { border-color: var(--line-on-dark); }
.section.dark .offer-list li { border-color: var(--line-on-dark); }

/* Sequenced journey (a real sequence, so it is numbered) */
.journey { list-style: none; margin: 2.5rem 0 0; padding: 0; display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 1.5rem; counter-reset: step; }
.journey li { counter-increment: step; border-top: 1px solid var(--line-on-dark); padding-top: 1.2rem; }
.journey li::before {
  content: counter(step); display: block;
  font-family: var(--serif); font-style: italic; font-size: 1.6rem; color: var(--champagne); margin-bottom: 0.4rem;
}
.journey h3 { font-size: var(--fs-md); margin-bottom: 0.4rem; }
.journey p { font-size: 0.98rem; margin: 0; }

/* Principles */
.principles { list-style: none; margin: 2.5rem 0 0; padding: 0; columns: 2; column-gap: clamp(2rem, 6vw, 6rem); counter-reset: p; }
.principles li { break-inside: avoid; counter-increment: p; padding: 1.25rem 0 1.25rem 3rem; position: relative; border-top: 1px solid var(--line); }
.principles li::before {
  content: counter(p); position: absolute; left: 0; top: 1.15rem;
  font-family: var(--serif); font-style: italic; font-size: 1.35rem; color: var(--burgundy);
}
.principles strong { font-family: var(--serif); font-weight: 400; font-size: var(--fs-md); display: block; margin-bottom: 0.2rem; line-height: 1.25; }
.principles span { color: var(--sage-ink); }

/* Manifesto */
.manifesto { max-width: 40rem; margin: 0 auto; }
.manifesto p { font-family: var(--serif); font-size: clamp(1.2rem, 1.05rem + 0.5vw, 1.45rem); line-height: 1.65; max-width: none; }
.manifesto p:first-of-type::first-letter {
  font-size: 4.2em; float: left; line-height: 0.8; padding: 0.08em 0.1em 0 0; color: var(--burgundy);
}
.manifesto .closing { font-style: italic; color: var(--burgundy); }

/* Quote / testimonial placeholders */
.voices { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(1.5rem, 4vw, 3.5rem); margin-top: 2.5rem; }
.voice { border-top: 1px solid var(--line); padding-top: 1.3rem; }
.voice p { font-family: var(--serif); font-size: var(--fs-md); line-height: 1.45; }
.voice { margin: 0; }
.voice figcaption { font-size: 0.98rem; color: var(--burgundy); }

/* Gallery */
.gallery { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: clamp(0.75rem, 2vw, 1.5rem); }
.gallery .frame { aspect-ratio: auto; height: 100%; min-height: 15rem; }
.gallery > div { min-height: 0; }
.g-a { grid-column: span 5; grid-row: span 2; }
.g-b { grid-column: span 7; }
.g-c { grid-column: span 4; }
.g-d { grid-column: span 3; }
.g-e { grid-column: span 4; }
.g-f { grid-column: span 8; }
.gallery-filter { display: flex; flex-wrap: wrap; gap: 0.6rem; margin: 0 0 2rem; }
.gallery-filter button {
  font: inherit; font-size: 0.95rem; background: transparent; color: var(--espresso);
  border: 1px solid var(--line); padding: 0.45rem 1.05rem; cursor: pointer;
}
.gallery-filter button[aria-pressed="true"] { background: var(--burgundy); color: var(--ivory); border-color: var(--burgundy); }
.gallery [hidden] { display: none; }

/* Facts / visit details */
.facts { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 2rem 3rem; margin-top: 2rem; }
.facts h3 { font-family: var(--sans); font-size: 1rem; font-weight: 500; letter-spacing: 0.02em; margin-bottom: 0.4rem; color: var(--burgundy); }
.section.dark .facts h3 { color: var(--champagne); }
.facts p { margin: 0; }

/* Menu */
.menu-course { margin-top: 2.5rem; }
.menu-course h3 { border-bottom: 1px solid var(--line); padding-bottom: 0.6rem; }
.menu-item { display: grid; grid-template-columns: 1fr auto; gap: 0.2rem 1.5rem; padding: 0.8rem 0; }
.menu-item h4 { margin: 0; font-family: var(--serif); font-weight: 400; font-size: var(--fs-md); }
.menu-item p { grid-column: 1 / -1; margin: 0; color: var(--sage-ink); font-size: 1rem; }

/* FAQ */
.faq { margin-top: 2rem; border-top: 1px solid var(--line); max-width: 52rem; }
.faq details { border-bottom: 1px solid var(--line); }
.faq summary {
  cursor: pointer; list-style: none; padding: 1.25rem 2.5rem 1.25rem 0; position: relative;
  font-family: var(--serif); font-size: var(--fs-md);
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after {
  content: "+"; position: absolute; right: 0.2rem; top: 1.05rem;
  font-family: var(--sans); font-weight: 300; font-size: 1.6rem; color: var(--burgundy);
  transition: transform 0.25s ease;
}
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details > div { padding: 0 0 1.3rem; }
.faq details > div p { color: var(--sage-ink); }

/* ---------- Forms ---------- */
.form-panel { background: var(--ivory); border: 1px solid var(--line); padding: clamp(1.5rem, 4vw, 3rem); }
.section.alt .form-panel { background: var(--ivory); }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1.2rem 1.5rem; }
.field { display: flex; flex-direction: column; gap: 0.4rem; }
.field.full { grid-column: 1 / -1; }
.field label, .field legend { font-size: 0.95rem; font-weight: 450; }
.field .hint { font-size: var(--fs-sm); color: var(--sage-ink); }
.field input, .field select, .field textarea {
  font: inherit; font-size: 1rem; color: var(--espresso);
  background: #FBF9F4; border: 1px solid rgba(48, 38, 33, 0.3);
  padding: 0.75rem 0.85rem; border-radius: 0; width: 100%;
}
.field textarea { min-height: 8rem; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus { outline: 2px solid var(--burgundy); outline-offset: 0; border-color: var(--burgundy); }
.field [aria-invalid="true"] { border-color: #8A2A2A; }
.field .error { font-size: var(--fs-sm); color: #8A2A2A; min-height: 0; }
fieldset.field { border: 0; padding: 0; margin: 0; }
.choice-row { display: flex; flex-wrap: wrap; gap: 0.5rem 1.4rem; }
.choice-row label { font-weight: 380; display: inline-flex; align-items: center; gap: 0.45rem; }
.choice-row input { width: auto; accent-color: var(--burgundy); }
.consent { display: flex; gap: 0.7rem; align-items: flex-start; font-size: 0.95rem; }
.consent input { width: auto; margin-top: 0.35rem; accent-color: var(--burgundy); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-status { margin-top: 1.2rem; font-size: 1rem; max-width: none; }
.form-status.is-error { color: #8A2A2A; }
.form-status.is-success { color: var(--burgundy); font-family: var(--serif); font-size: var(--fs-md); }
.form-actions { display: flex; align-items: center; gap: 1.2rem; flex-wrap: wrap; margin-top: 1.6rem; }
.form-actions .btn[disabled] { opacity: 0.6; cursor: wait; }

.booking-embed {
  border: 1px dashed var(--sage-ink); padding: 1.5rem; margin-bottom: 2rem;
  font-size: 0.98rem; color: var(--sage-ink);
}

/* ---------- Closing invitation band ---------- */
.invite { background: var(--burgundy); color: var(--ivory); padding: clamp(4rem, 8vw, 7rem) 0; }
.invite .wrap { display: grid; grid-template-columns: minmax(0, 1.2fr) auto; gap: 2rem; align-items: end; }
.invite h2 { color: var(--ivory); margin: 0; max-width: 16em; }
.invite .actions { margin: 0; }

/* ---------- Footer ---------- */
.site-footer { background: var(--espresso); color: var(--champagne-soft); padding: 4rem 0 2rem; font-size: 0.98rem; }
.site-footer a { color: var(--ivory); }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr 1fr; gap: 2.5rem; }
.site-footer .wordmark { color: var(--ivory); font-size: 2rem; }
.site-footer h2 { font-family: var(--sans); font-size: 1rem; font-weight: 500; color: var(--champagne); margin-bottom: 0.8rem; letter-spacing: 0.02em; }
.site-footer ul { list-style: none; margin: 0; padding: 0; }
.site-footer li { margin-bottom: 0.45rem; }
.site-footer p { margin-bottom: 0.6rem; }
.footer-base { margin-top: 3rem; padding-top: 1.5rem; border-top: 1px solid var(--line-on-dark); display: flex; justify-content: space-between; flex-wrap: wrap; gap: 1rem; font-size: var(--fs-sm); }
.footer-base p { margin: 0; max-width: none; }

/* ---------- Prose pages (privacy etc.) ---------- */
.prose { max-width: 44rem; }
.prose h2 { font-size: var(--fs-lg); margin-top: 2.2em; }
.prose ul { padding-left: 1.2rem; }
.prose li { margin-bottom: 0.5rem; }

/* ---------- Responsive ---------- */
@media (max-width: 900px) {
  .hero .wrap, .split, .split.form-split, .paths, .invite .wrap { grid-template-columns: 1fr; }
  .split.reverse > :first-child { order: 0; }
  .hero-arch { justify-self: start; width: min(100%, 26rem); }
  .path:nth-child(2) { margin-top: 0; }
  .journey { grid-template-columns: 1fr 1fr; }
  .principles { columns: 1; }
  .voices, .facts { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
  .offer-list li { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: 1fr 1fr; }
  .g-a, .g-b, .g-c, .g-d, .g-e, .g-f { grid-column: span 1; grid-row: auto; }
  .g-a, .g-f { grid-column: 1 / -1; }
}
@media (max-width: 600px) {
  .form-grid { grid-template-columns: 1fr; }
  .journey { grid-template-columns: 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .gallery { grid-template-columns: 1fr; }
  .wordmark { font-size: 1.4rem; }
}
