/* The couple sites' shared layer on the Fluid base (theme/fluid.min.css): the palette tokens from /…/palette.css
   (src/couple/palette.js, every text pair already checked) mapped onto Fluid's, the font pairings, and the sections
   every style shares. A style's own file (classic.css, …) arranges them. Light only: the couple's colours are the
   scheme, so a guest's dark mode does not repaint their wedding. */
@layer reset, tokens, base, layouts, components, themes, utilities;

@layer themes {
  html.w-site {
    color-scheme: light;
    --color-background: var(--c-bg); --color-text: var(--c-ink); --color-text-muted: var(--c-soft); --color-text-subtle: var(--c-soft);
    --color-border: var(--c-line); --color-border-strong: var(--c-soft); --color-focus: var(--c-link); --color-error: var(--c-error);
    --color-surface: var(--c-tint); --color-selection: var(--c-tint);
    --accent: var(--c-btn); --accent-fill: var(--c-btn); --accent-fill-hover: var(--c-head); --on-accent: var(--c-btn-ink); --on-accent-fill: var(--c-btn-ink);
    --accent-ink: var(--c-link); --accent-subtle: var(--c-tint);
    --gutter: clamp(1.25rem, 0.5rem + 3.5vw, 4rem);
    --f-label: "Instrument Sans", "Helvetica Neue", Arial, sans-serif;
    background: var(--c-bg); color: var(--c-ink);
  }
  /* the pairings: heading, body, script (src/couple/styles.js FONTS) */
  html.w-site[data-fonts="cormorant-pinyon"] { --f-head: "Cormorant Garamond", Garamond, "Times New Roman", serif; --f-body: "Cormorant Garamond", Garamond, Georgia, serif; --f-script: "Pinyon Script", "Snell Roundhand", cursive; --f-body-size: 1.25rem; --f-script-scale: 1; }
  html.w-site[data-fonts="bodoni-instrument"] { --f-head: "Bodoni Moda", Didot, "Bodoni MT", serif; --f-body: "Instrument Sans", "Helvetica Neue", Arial, sans-serif; --f-script: "Bodoni Moda", Didot, serif; --f-body-size: 1.0625rem; --f-script-scale: 0.62; --f-script-style: italic; }
  html.w-site[data-fonts="playfair-greatvibes"] { --f-head: "Playfair Display", Georgia, serif; --f-body: "Hanken Grotesk", "Helvetica Neue", Arial, sans-serif; --f-script: "Great Vibes", "Snell Roundhand", cursive; --f-body-size: 1.0625rem; --f-script-scale: 0.95; }
  html.w-site[data-fonts="instrument-only"] { --f-head: "Instrument Sans", "Helvetica Neue", Arial, sans-serif; --f-body: "Instrument Sans", "Helvetica Neue", Arial, sans-serif; --f-script: "Instrument Sans", Arial, sans-serif; --f-body-size: 1.0625rem; --f-script-scale: 0.6; --f-script-weight: 600; }

  .w-site body { font-family: var(--f-body); font-size: var(--f-body-size, 1.125rem); line-height: 1.6; background: var(--c-bg); color: var(--c-ink); overflow-wrap: break-word; }
  .w-site :is(h1, h2, h3) { font-family: var(--f-head); color: var(--c-head); font-weight: 500; line-height: 1.1; }
  .w-site h2 { font-size: clamp(2.2rem, 1.6rem + 2.6vw, 3.6rem); }
  .w-site h3 { font-size: clamp(1.35rem, 1.2rem + 0.6vw, 1.7rem); }
  .w-site a { color: var(--c-link); text-underline-offset: 0.18em; }
  .w-site .skip-link { background: var(--c-btn); color: var(--c-btn-ink); }
  .w-site .hp { position: absolute !important; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
  .w-site .form-help { color: var(--c-soft); }
  .w-site .form-error { color: var(--c-error); font-family: var(--f-label); }
  .w-site :is(label, legend) { font-family: var(--f-label); font-size: 0.95rem; font-weight: 600; }
  .w-site :is(input, select, textarea) { font-family: var(--f-label); font-size: 1rem; background: var(--c-bg); color: var(--c-ink); }
  .w-site fieldset.form-group { border: 0; padding: 0; margin: 0; min-width: 0; }
  .w-site fieldset.form-group legend { margin-bottom: 0.5rem; padding: 0; }
  .w-site .choice-row { display: flex; flex-wrap: wrap; gap: 0.25rem 1.5rem; }
  .w-site .choice { display: inline-flex; gap: 0.5rem; align-items: center; font-weight: 400; min-height: 2.75rem; }

  .w-site .w-button { font-family: var(--f-label); letter-spacing: 0.14em; text-transform: uppercase; font-size: 0.8rem; font-weight: 600;
    background: var(--c-btn); color: var(--c-btn-ink); border: 0; border-radius: 0; text-decoration: none; min-inline-size: 0; }
  .w-site .w-button:hover { background: var(--c-head); color: var(--c-bg); }
  .w-amp { font-style: italic; padding-inline: 0.08em; }
  .w-site .w-preview { max-width: none; margin: 0; padding: 0.6rem var(--gutter); background: var(--c-ink); color: var(--c-bg); font: 500 0.85rem/1.4 var(--f-label); text-align: center; }

  /* sections */
  .w-section { padding: clamp(3.5rem, 2rem + 6vw, 7.5rem) var(--gutter); max-width: 76rem; margin-inline: auto; }
  .w-head { margin-bottom: clamp(1.75rem, 1rem + 2.5vw, 3rem); }
  .w-eyebrow { margin: 0 0 0.6rem; font: 600 0.78rem/1.3 var(--f-label); letter-spacing: 0.2em; text-transform: uppercase; color: var(--c-soft); }
  .w-section p { max-width: 62ch; }
  .w-section p + p { margin-top: 1em; }
  .w-story__cols { display: grid; gap: clamp(2rem, 4vw, 5rem); grid-template-columns: repeat(auto-fit, minmax(min(100%, 22rem), 1fr)); }
  .w-story__part h3 { font-style: italic; margin-bottom: 0.75rem; }
  .w-events { margin: 0; padding: 0; list-style: none; border-top: 1px solid var(--c-line); }
  .w-event { display: grid; grid-template-columns: minmax(9rem, 14rem) 1fr; gap: 0.5rem 2rem; padding-block: 1.4rem; border-bottom: 1px solid var(--c-line); }
  .w-event__time { margin: 0; font: 600 0.82rem/1.5 var(--f-label); letter-spacing: 0.12em; text-transform: uppercase; color: var(--c-soft); padding-top: 0.35em; }
  .w-event__place { margin: 0.25rem 0 0; font-style: italic; }
  .w-event__note { margin: 0.25rem 0 0; color: var(--c-soft); }
  @media (max-width: 40rem) { .w-event { grid-template-columns: 1fr; } }
  .w-venue__grid { display: grid; gap: 2rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 20rem), 1fr)); align-items: start; }
  .w-address { font-size: 1.15em; }
  .w-links { display: flex; flex-wrap: wrap; gap: 0.5rem 1.5rem; font-family: var(--f-label); font-size: 0.95rem; }
  .w-map { border: 1px solid var(--c-line); line-height: 0; }
  .w-map iframe { width: 100%; height: clamp(16rem, 40vw, 24rem); border: 0; filter: grayscale(0.55) sepia(0.12); }
  .w-cards { display: grid; gap: 1.25rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr)); margin: 2rem 0 0; padding: 0; list-style: none; }
  .w-card { border: 1px solid var(--c-line); padding: 1.5rem; }
  .w-card h3 { font-size: 1.35rem; margin-bottom: 0.4rem; }
  .w-grid { display: grid; gap: clamp(0.75rem, 2vw, 1.5rem); grid-template-columns: repeat(auto-fill, minmax(min(100%, 15rem), 1fr)); }
  .w-grid .w-pic img { aspect-ratio: 4 / 5; object-fit: cover; width: 100%; }
  /* data-bleed="full" (render.js picture()) opts out of Fluid's figure frame: no 85svh cap, no contain */
  .w-site .w-pic { margin: 0; }
  .w-site .w-pic img { border-radius: 0; display: block; }
  .w-pic__credit { margin-top: 0.4rem; font: 400 0.78rem/1.4 var(--f-label); color: var(--c-soft); }
  .w-people { display: grid; gap: 1.25rem 2rem; grid-template-columns: repeat(auto-fill, minmax(min(100%, 13rem), 1fr)); margin: 0; padding: 0; list-style: none; }
  .w-person { display: block; font-family: var(--f-head); font-size: 1.4rem; color: var(--c-head); }
  .w-role { display: block; font: 600 0.78rem/1.4 var(--f-label); letter-spacing: 0.14em; text-transform: uppercase; color: var(--c-soft); }
  .w-faqs details { border-bottom: 1px solid var(--c-line); padding-block: 1rem; }
  .w-faqs details:first-child { border-top: 1px solid var(--c-line); }
  .w-faqs summary { cursor: pointer; font-family: var(--f-head); font-size: 1.3rem; color: var(--c-head); min-height: 2.75rem; display: flex; align-items: center; }
  .w-faqs details p { margin-top: 0.5rem; }
  .w-pills { display: flex; flex-wrap: wrap; gap: 0.75rem; margin: 1.5rem 0 0; padding: 0; list-style: none; }
  .w-site .w-pill { display: inline-flex; align-items: center; min-height: 2.75rem; padding: 0.4rem 1.4rem; border: 1px solid currentColor; font: 600 0.8rem/1.2 var(--f-label); letter-spacing: 0.14em; text-transform: uppercase; text-decoration: none; }
  .w-site .w-pill:hover { background: var(--c-btn); color: var(--c-btn-ink); border-color: var(--c-btn); }

  /* RSVP: a band of the couple's 30 colour, the form on a panel of the 60 */
  .w-rsvp { max-width: none; background: var(--c-band); color: var(--c-band-ink); }
  .w-rsvp > * { max-width: 46rem; margin-inline: auto; }
  .w-rsvp :is(h2, .w-eyebrow) { color: var(--c-band-ink); }
  .w-rsvp form, .w-rsvp .w-done, .w-rsvp > p { background: var(--c-bg); color: var(--c-ink); padding: clamp(1.5rem, 4vw, 3rem); }
  .w-rsvp > .form-error { background: var(--c-bg); color: var(--c-error); padding: 1rem clamp(1.5rem, 4vw, 3rem); margin-bottom: 0; }
  .w-done__big { font-family: var(--f-script); font-size: calc(3.5rem * var(--f-script-scale, 1)); line-height: 1.1; color: var(--c-head); margin: 0 0 0.5rem; }
  .w-seat { display: grid; gap: 1rem; padding: 1rem 0 0; border-top: 1px solid var(--c-line); }
  /* show only what applies (forms.md 7): the party questions after a "yes", one seat per guest in the party */
  @supports selector(:has(*)) {
    .w-form:not(:has(input[name="attending"][value="yes"]:checked)) .if-yes { display: none; }
    .w-form:has(select[name="party_size"] option[value="1"]:checked) :is(.seat-2, .seat-3, .seat-4) { display: none; }
    .w-form:has(select[name="party_size"] option[value="2"]:checked) :is(.seat-3, .seat-4) { display: none; }
    .w-form:has(select[name="party_size"] option[value="3"]:checked) .seat-4 { display: none; }
  }

  .w-footer { padding: clamp(3rem, 6vw, 5rem) var(--gutter); text-align: center; border-top: 1px solid var(--c-line); font-size: 0.95em; display: grid; gap: 0.6rem; justify-items: center; }
  .w-footer p { margin: 0; max-width: 60ch; }
  .w-footer__mono { font-family: var(--f-script); font-style: var(--f-script-style, normal); font-size: calc(3rem * var(--f-script-scale, 1)); line-height: 1; color: var(--c-head); }
  .w-footer__credits, .w-footer__made { font: 400 0.8rem/1.5 var(--f-label); color: var(--c-soft); }
  .w-site .w-footer a { color: inherit; }

  .w-gate { min-height: 80svh; display: grid; place-content: center; gap: 2rem; padding: var(--gutter); text-align: center; }
  .w-gate form { text-align: start; min-width: min(22rem, 100%); }
}

/* The sections only 603010.wedding has (render.js): Our colours (Free) and Our places (Plus), and the add-to-calendar
   link. The swatches are the couple's own colours from palette.css, so they need no text contrast of their own; each
   has a hairline so a near-white 60 colour still shows on the page. */
@layer themes {
  .w-swatches { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 12rem), 1fr)); margin: 0 0 1.75rem; padding: 0; list-style: none; }
  .w-swatches li { display: grid; gap: 0.25rem; }
  .w-swatch { display: block; height: 6rem; box-shadow: inset 0 0 0 1px var(--c-line); margin-bottom: 0.5rem; }
  .w-swatch--60 { background: var(--p60); }
  .w-swatch--30 { background: var(--p30); }
  .w-swatch--10 { background: var(--p10); }
  .w-swatch__role { font-family: var(--f-head); font-size: 1.3rem; color: var(--c-head); }
  .w-swatch__hex { font: 600 0.78rem/1.3 var(--f-label); letter-spacing: 0.14em; text-transform: uppercase; color: var(--c-soft); }
  .w-places__list { display: grid; gap: 2rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 14rem), 1fr)); margin: 0; padding: 0; list-style: none; counter-reset: place; }
  .w-place { display: grid; gap: 0.35rem; justify-items: start; padding-top: 1.25rem; border-top: 1px solid var(--c-line); }
  .w-place p { margin: 0; }
  .w-place__pin { width: 1.25rem; height: 1.25rem; border-radius: 50% 50% 50% 0; transform: rotate(-45deg); box-shadow: inset 0 0 0 1px var(--c-line); margin-bottom: 0.5rem; }
  .w-place--one .w-place__pin { background: var(--p30); }
  .w-place--two .w-place__pin { background: var(--p10); }
  .w-place--three .w-place__pin { background: var(--c-head); }
  .w-place__label { font: 600 0.78rem/1.4 var(--f-label); letter-spacing: 0.14em; text-transform: uppercase; color: var(--c-soft); }
  .w-place__name { font-family: var(--f-head); font-size: 1.5rem; color: var(--c-head); }
  .w-cal { margin-top: 1.5rem; }

  /* the sample site only: the bar across the top (switch style, colours, plan), the tags on its sections, the paper */
  .w-site .w-demo { display: grid; gap: 0.6rem; padding: 0.8rem var(--gutter); background: #141414; color: #f4f1ea; font: 400 0.88rem/1.4 var(--f-label); }
  .w-site .w-demo p { margin: 0; max-width: none; }
  .w-site .w-demo a { color: #f4f1ea; }
  .w-demo__rows { display: flex; flex-wrap: wrap; gap: 0.5rem 2rem; align-items: center; }
  .w-demo__row { display: flex; flex-wrap: wrap; align-items: center; gap: 0.5rem; }
  .w-demo__row ul { display: flex; flex-wrap: wrap; gap: 0.35rem; margin: 0; padding: 0; list-style: none; }
  .w-demo__label { font-weight: 600; font-size: 0.72rem; letter-spacing: 0.16em; text-transform: uppercase; color: #cfc9bd; }
  .w-site .w-demo__opt { display: inline-flex; align-items: center; min-height: 2.5rem; min-width: 2.5rem; justify-content: center; padding: 0 0.85rem; border: 1px solid #6f6a61; border-radius: 999px; text-decoration: none; }
  .w-site .w-demo__opt:hover { border-color: #f4f1ea; }
  .w-site .w-demo__opt[aria-current="true"] { background: #f4f1ea; color: #141414; border-color: #f4f1ea; }
  .w-site .w-demo__opt:focus-visible { outline: 2px solid #f4f1ea; outline-offset: 2px; }
  .w-site .w-demo__opt--sw { padding: 0 0.45rem; }
  .w-demo__sw { display: block; width: 2.2rem; height: 1rem; box-shadow: 0 0 0 1px rgb(255 255 255 / 0.35); }
  .w-demo__plan { color: #cfc9bd; }
  .w-tag { display: inline-block; margin: 0 0 0.75rem; padding: 0.2rem 0.6rem; background: #141414; color: #f4f1ea; font: 600 0.7rem/1.4 var(--f-label); letter-spacing: 0.14em; text-transform: uppercase; }
  .w-rsvp .w-tag { background: var(--c-bg); color: var(--c-ink); }
  .w-paper__set { display: grid; gap: clamp(1.5rem, 3vw, 2.5rem); grid-template-columns: repeat(auto-fit, minmax(min(100%, 15rem), 1fr)); margin: 2rem 0 0; padding: 0; list-style: none; align-items: end; }
  .w-paper__card { display: grid; align-content: center; justify-items: center; gap: 0.6rem; text-align: center; padding: 1.5rem 1.25rem; aspect-ratio: 5 / 7;
    background: var(--p60); color: var(--c-head); box-shadow: 0 1px 2px rgb(0 0 0 / 0.08), 0 18px 36px -18px rgb(0 0 0 / 0.4); outline: 1px solid var(--c-line); outline-offset: -0.7rem; }
  .w-paper__card p { margin: 0; max-width: none; }
  .w-paper__card--std { background: var(--c-band); color: var(--c-band-ink); outline-color: currentColor; }
  .w-paper__card--sign { aspect-ratio: 3 / 4; }
  .w-paper__k { font: 600 0.62rem/1.4 var(--f-label); letter-spacing: 0.2em; text-transform: uppercase; }
  .w-paper__names { font-family: var(--f-script); font-style: var(--f-script-style, normal); font-size: calc(2.4rem * var(--f-script-scale, 1)); line-height: 1.1; }
  .w-paper__names span { font-size: 0.7em; }
  .w-paper__d { font-family: var(--f-head); font-style: italic; }
  .w-paper__bar { display: flex; width: 6rem; height: 0.4rem; }
  .w-paper__bar > span:nth-child(1) { flex: 6; background: var(--p60); box-shadow: inset 0 0 0 1px var(--c-line); }
  .w-paper__bar > span:nth-child(2) { flex: 3; background: var(--p30); }
  .w-paper__bar > span:nth-child(3) { flex: 1; background: var(--p10); }
  .w-paper__label { margin-top: 0.75rem; font: 600 0.78rem/1.4 var(--f-label); letter-spacing: 0.12em; text-transform: uppercase; color: var(--c-soft); text-align: center; }
}
