/* Posy: a garden wedding site. Watercolour sage, blush and butter on a near-white, tinted ground.
   Handwritten accent (Caveat) plus a clean sans (Figtree). Edit the tokens below to re-colour. */
:root {
  --ground: #FAFBF7;          /* page background: near-white with a green tint */
  --paper: #FFFFFF;           /* cards and form fields */
  --ink: #26322A;             /* body text */
  --muted: #4D5B50;           /* secondary text, still 7:1 on --ground */
  --sage: #B9C9B0;            /* sage band and watercolour */
  --sage-soft: #E4EDDD;       /* pale sage panels */
  --sage-deep: #3D5843;       /* links, primary buttons, rules */
  --blush: #F3CFC8;           /* blush blocks and petals */
  --blush-deep: #8E4E47;      /* small blush text on light panels */
  --butter: #F6E4A2;          /* butter highlights */
  --font-display: "Figtree", system-ui, sans-serif;
  --font-hand: "Caveat", "Segoe Script", cursive;
  --font-body: "Figtree", system-ui, sans-serif;
  --radius: 28px;
  --gutter: 16px;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font: 400 1rem/1.6 var(--font-body);
  overflow-x: clip;
}
img, svg { display: block; max-width: 100%; }
a { color: var(--sage-deep); text-underline-offset: 0.2em; }
a:hover { color: var(--ink); }
:focus-visible { outline: 3px solid var(--sage-deep); outline-offset: 3px; border-radius: 6px; }
h1, h2, h3 { margin: 0; font-family: var(--font-display); line-height: 1.02; letter-spacing: -0.02em; font-weight: 700; }
h1 { font-size: clamp(2.6rem, 9vw, 6.6rem); }
h2 { font-size: clamp(2rem, 5vw, 3.6rem); }
h3 { font-size: 1.25rem; letter-spacing: -0.01em; }
.story-copy h2, .panel h2, .rsvp-grid h2 { margin-bottom: 18px; }
p { margin: 0 0 1em; }
.wrap { width: 100%; max-width: 1180px; margin: 0 auto; padding: 0 var(--gutter); }
@media (min-width: 900px) { :root { --gutter: 40px; } }

.skip { position: absolute; left: var(--gutter); top: -60px; background: var(--paper); padding: 10px 14px; border-radius: 10px; z-index: 10; }
.skip:focus { top: 12px; }

.hand { font-family: var(--font-hand); font-weight: 500; font-size: 1.6rem; line-height: 1.1; color: var(--blush-deep); letter-spacing: 0; }

/* Buttons */
.button {
  display: inline-flex; align-items: center; gap: 0.5em;
  min-height: 48px; padding: 12px 22px; border-radius: 999px;
  background: var(--sage-deep); color: #FFFFFF; font-weight: 600; text-decoration: none;
  border: 0; font-size: 1rem; cursor: pointer;
}
.button:hover { background: var(--ink); color: #FFFFFF; }
.button.quiet { background: transparent; color: var(--sage-deep); box-shadow: inset 0 0 0 2px var(--sage-deep); }
.button.quiet:hover { background: var(--sage-deep); color: #FFFFFF; }
.text-link { font-weight: 600; }

/* Header */
.site-header { position: relative; z-index: 5; }
.header-inner { display: flex; align-items: center; justify-content: space-between; gap: 12px; min-height: 76px; }
.wordmark { font-family: var(--font-display); font-weight: 800; font-size: 1.1rem; color: var(--ink); text-decoration: none; letter-spacing: -0.01em; }
.wordmark .amp { font-family: var(--font-hand); font-weight: 500; font-size: 1.6rem; color: var(--blush-deep); margin: 0 0.1em; }
.nav-links { display: none; align-items: center; gap: 26px; }
.nav-links a, .nav-panel a { color: var(--ink); text-decoration: none; font-weight: 600; }
.nav-links a:hover, .nav-panel a:hover { color: var(--sage-deep); text-decoration: underline; }
.nav-links a[aria-current="page"], .nav-panel a[aria-current="page"] { color: var(--sage-deep); text-decoration: underline; text-underline-offset: 6px; }
.nav-links .button { min-height: 44px; padding: 9px 18px; }
.nav-links a.button, .nav-links a.button:hover, .nav-links a.button[aria-current="page"] { color: #FFFFFF; text-decoration: none; }
.nav-disclosure summary {
  list-style: none; cursor: pointer; min-height: 44px; min-width: 44px; display: inline-flex; align-items: center;
  padding: 8px 16px; border-radius: 999px; background: var(--paper); box-shadow: inset 0 0 0 2px var(--sage-deep); font-weight: 600; color: var(--ink);
}
.nav-disclosure summary::-webkit-details-marker { display: none; }
.nav-panel { display: grid; gap: 4px; padding: 16px 0 8px; }
.nav-panel a { display: flex; align-items: center; min-height: 48px; font-size: 1.1rem; border-bottom: 1px solid var(--sage); }
.nav-panel .button { margin-top: 12px; justify-content: center; border-bottom: 0; }
.nav-panel .button, .nav-panel .button:hover { color: #FFFFFF; text-decoration: none; }
@media (min-width: 820px) {
  .nav-links { display: flex; }
  .nav-disclosure { display: none; }
}

/* Hero */
.hero { padding: 28px 0 56px; }
.hero-grid { display: grid; gap: 36px; align-items: center; }
.hero h1 { margin-top: 4px; }
.hero h1 .amp { font-family: var(--font-hand); font-weight: 500; color: var(--blush-deep); font-size: 0.8em; line-height: 1; vertical-align: 0.1em; margin: 0 0.04em; }
.hero-date { font-size: 1.2rem; font-weight: 600; margin: 22px 0 6px; }
.hero-line { font-size: 1.1rem; color: var(--muted); max-width: 34ch; }
.countdown { font-weight: 600; color: var(--sage-deep); min-height: 1.6em; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 26px; }
.arch {
  position: relative; margin: 0 auto; width: min(100%, 420px); aspect-ratio: 5 / 6;
  border-radius: 999px 999px 28px 28px; overflow: hidden; background: var(--sage-soft);
  box-shadow: 0 0 0 12px var(--paper), 0 0 0 14px var(--sage);
}
.arch img { width: 100%; height: 100%; object-fit: cover; transform-origin: 50% 80%; }
.arch-tag {
  position: absolute; left: 14px; bottom: 14px; background: var(--paper); padding: 8px 14px; border-radius: 999px;
  font-weight: 600; font-size: 0.95rem;
}
@media (min-width: 900px) {
  .hero { padding: 56px 0 96px; }
  .hero-grid { grid-template-columns: 1.1fr 0.9fr; gap: 64px; }
  .arch { margin: 0 0 0 auto; }
}

/* Dividers: pressed flowers */
.divider { display: flex; justify-content: center; padding: 8px 0; }
.divider svg { width: min(260px, 70%); height: auto; }

/* Sections */
.section { padding: 64px 0; }
.section-head { display: grid; gap: 10px; margin-bottom: 36px; }
.story { display: grid; gap: 32px; align-items: center; }
.story-copy p { font-size: 1.12rem; max-width: 60ch; }
.story-art { position: relative; border-radius: var(--radius); overflow: hidden; background: var(--blush); }
.story-art img { width: 100%; height: auto; }
.story-copy .story-sign { font-family: var(--font-hand); font-size: 1.9rem; color: var(--sage-deep); margin-top: 6px; }
/* Section paragraph sizes must not shrink the handwritten eyebrows. */
.story-copy .hand, .band .hand, .page-top .hand { font-size: 1.6rem; }
.page-top .hand { color: var(--blush-deep); }
.section > .wrap > h2 { margin-bottom: 24px; }
.glance + p { margin-top: 20px; }
@media (min-width: 900px) {
  .story { grid-template-columns: 1fr 1fr; gap: 72px; }
  .story-art.flip { order: -1; }
}

/* Day at a glance: a ledger, not cards */
.glance { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--sage-deep); }
.glance li { display: grid; grid-template-columns: 90px 1fr; gap: 6px 20px; padding: 22px 0; border-bottom: 1px solid var(--sage); align-items: baseline; }
.glance time { font-family: var(--font-display); font-weight: 800; font-size: 1.6rem; color: var(--sage-deep); letter-spacing: -0.02em; }
.glance h3 { font-size: 1.35rem; }
.glance p { margin: 0; color: var(--muted); grid-column: 2; }
@media (min-width: 900px) { .glance li { grid-template-columns: 140px 1fr 1fr; } .glance p { grid-column: auto; } }

/* Blush band */
.band { background: var(--blush); border-radius: 36px; padding: 48px 24px; position: relative; overflow: hidden; }
.band-inner { display: grid; gap: 24px; position: relative; z-index: 1; }
.band p { font-size: 1.1rem; max-width: 52ch; }
.band .hand { color: var(--ink); }
@media (min-width: 900px) { .band { padding: 72px 72px; } .band-inner { grid-template-columns: 1.2fr 1fr; align-items: center; } }

/* Page title for inner pages */
.page-top { padding-block: 40px 28px; display: grid; gap: 14px; }
.page-top p { font-size: 1.15rem; max-width: 56ch; color: var(--muted); margin: 0; }
.meadow { height: 140px; overflow: hidden; background: var(--sage-soft); border-radius: var(--radius); }
.meadow svg { width: 100%; height: 100%; }
@media (min-width: 900px) { .page-top { grid-template-columns: 1.3fr 1fr; align-items: end; } .meadow { height: 200px; } }

/* Timeline */
.run { list-style: none; margin: 0; padding: 0; display: grid; gap: 0; position: relative; }
.run li { display: grid; grid-template-columns: 96px 1fr; gap: 16px; padding: 22px 0; border-top: 1px dashed var(--sage-deep); }
.run time { font-weight: 800; font-size: 1.25rem; color: var(--sage-deep); }
.run h3 { margin-bottom: 4px; }
.run p { margin: 0; color: var(--muted); }
.run li:nth-child(even) h3 { color: var(--blush-deep); }

/* Venue and travel cards */
.panel-grid { display: grid; gap: 20px; }
.panel { background: var(--paper); border-radius: var(--radius); padding: 28px; box-shadow: 0 1px 0 var(--sage); }
.panel.sage { background: var(--sage-soft); }
.panel.butter { background: var(--butter); }
.panel h3 { margin-bottom: 8px; }
.panel p:last-child { margin-bottom: 0; }
.stays { display: grid; gap: 16px; }
.stays article { display: grid; gap: 4px; align-content: start; padding: 22px; border-radius: 22px; background: var(--paper); }
.stays span { color: var(--muted); font-size: 0.98rem; }
.note-line { font-family: var(--font-hand); font-size: 1.7rem; color: var(--sage-deep); line-height: 1.2; margin: 0 0 20px; }
@media (min-width: 900px) {
  .panel-grid { grid-template-columns: repeat(3, 1fr); }
  .panel-grid.two { grid-template-columns: repeat(2, 1fr); }
  .stays { grid-template-columns: repeat(3, 1fr); }
}

/* Details: dress code, gifts, FAQ */
.details-grid { display: grid; gap: 20px; }
.faq { display: grid; gap: 12px; }
.faq details { background: var(--paper); border-radius: 22px; padding: 18px 22px; }
.faq summary { cursor: pointer; font-weight: 700; font-size: 1.1rem; list-style: none; display: flex; justify-content: space-between; gap: 12px; min-height: 44px; align-items: center; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 1.5rem; line-height: 1; color: var(--sage-deep); }
.faq details[open] summary::after { content: "–"; }
.faq details p { margin: 12px 0 0; color: var(--muted); }
@media (min-width: 900px) { .details-grid { grid-template-columns: 1fr 1fr; gap: 28px; } }

/* RSVP: slot fallback and inert demo form */
.rsvp-grid { display: grid; gap: 24px; }
.rsvp-card { background: var(--paper); border-radius: var(--radius); padding: 28px; box-shadow: 0 0 0 2px var(--sage); }
.rsvp-card h2 { font-size: clamp(1.7rem, 4vw, 2.4rem); margin-bottom: 12px; }
.rsvp-card .slot p { color: var(--muted); }
.slot-form { display: grid; gap: 10px; }
.slot-form label { font-weight: 600; margin-top: 8px; }
.slot-form input, .slot-form select, .slot-form textarea {
  font: inherit; min-height: 48px; padding: 10px 14px; border-radius: 14px; border: 1.5px solid var(--sage); background: var(--ground); color: var(--ink); width: 100%;
}
.slot-form textarea { min-height: 110px; }
.slot-form .button { margin-top: 12px; justify-self: start; }
@media (min-width: 900px) { .rsvp-grid { grid-template-columns: 0.8fr 1.2fr; gap: 48px; align-items: start; } }

/* Footer */
.site-footer { background: var(--sage-deep); color: #F4F8F1; padding: 48px 0 40px; margin-top: 56px; }
.site-footer a { color: #FFFFFF; }
.site-footer a:hover { color: var(--butter); }
.site-footer :focus-visible { outline-color: var(--butter); }
.footer-grid { display: grid; gap: 28px; }
.footer-names { font-family: var(--font-display); font-size: 1.6rem; font-weight: 800; margin: 0 0 4px; }
.footer-grid p { margin: 0 0 6px; }
.footer-cta { margin-top: 18px; }
.footer-cta .button { background: var(--butter); color: var(--ink); }
.footer-cta .button:hover { background: #FFFFFF; color: var(--ink); }
@media (min-width: 900px) { .footer-grid { grid-template-columns: 1fr 1fr 1fr; } }

/* Legal and 404 */
.legal { display: grid; gap: 22px; padding-block: 40px 72px; max-width: 72ch; }
.legal h2 { font-size: 1.5rem; }
.legal p:last-child { margin-bottom: 0; }
.lost { min-height: 62vh; display: grid; align-content: center; gap: 18px; padding-block: 64px; }
.lost p { font-size: 1.15rem; color: var(--muted); max-width: 40ch; }

/* Reveal on scroll (only when JS runs and motion is allowed) */
.js .reveal { opacity: 0; transform: translateY(14px); transition: opacity 0.7s ease, transform 0.7s ease; }
.js .reveal.is-in { opacity: 1; transform: none; }

/* Hero bloom on load (CSS only) */
@keyframes bloom { from { transform: scale(1.08); opacity: 0.2; } to { transform: scale(1); opacity: 1; } }
.arch img { animation: bloom 1.6s ease-out both; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .arch img, .js .reveal { animation: none; transition: none; }
  .js .reveal { opacity: 1; transform: none; }
}

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