/* ============================================================
   Gianna & York -- yorkandgianna.com
   Shared stylesheet. Tokens first, then base, then components.
   ============================================================ */

:root {
  --paper: #f7f3ea;        /* page background */
  --paper-deep: #efe8d9;   /* card / alternate section fill */
  --ink: #26251f;          /* primary text, olive-black */
  --ink-soft: #6d675c;     /* secondary text */
  --cypress: #3f5138;      /* primary accent: buttons, links, active nav */
  --cypress-dark: #33422d;
  --sienna: #b0603e;       /* small labels + highlights only */
  --brass: #ad9a76;        /* hairlines, rules, borders */
  --line: #d9d0bd;         /* soft borders on cards/inputs */
  --serif: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;
  --sans: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto,
          Helvetica, Arial, sans-serif;
}

* { margin: 0; padding: 0; box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  background: var(--paper);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

/* ---------- Type ---------- */

h1, h2, h3, .display {
  font-family: var(--serif);
  font-weight: 600;
  line-height: 1.15;
}

h1 { font-size: clamp(2.6rem, 8vw, 4.6rem); }
h2 { font-size: clamp(1.7rem, 4vw, 2.4rem); }
h3 { font-size: 1.3rem; }

.eyebrow {
  font-family: var(--sans);
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.22em;
  text-transform: uppercase;
  color: var(--sienna);
}

.lede {
  font-family: var(--serif);
  font-size: 1.25rem;
  font-style: italic;
  color: var(--ink-soft);
}

a { color: var(--cypress); }
a:hover { color: var(--cypress-dark); }

:focus-visible {
  outline: 2px solid var(--cypress);
  outline-offset: 2px;
}

/* ---------- Header / nav ---------- */

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1.1rem clamp(1rem, 4vw, 3rem);
  border-bottom: 1px solid var(--line);
  background: var(--paper);
}

.wordmark {
  font-family: var(--serif);
  font-size: 1.35rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-decoration: none;
  color: var(--ink);
}

.wordmark span { color: var(--sienna); }

.site-nav { display: flex; gap: 1.4rem; align-items: center; }

.site-nav a {
  font-size: 0.85rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-decoration: none;
  color: var(--ink);
  padding: 0.2rem 0;
  border-bottom: 2px solid transparent;
}

.site-nav a:hover { color: var(--cypress); }

.site-nav a[aria-current="page"] {
  color: var(--cypress);
  border-bottom-color: var(--cypress);
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--line);
  border-radius: 6px;
  padding: 0.45rem 0.7rem;
  font: inherit;
  font-size: 0.85rem;
  color: var(--ink);
  cursor: pointer;
}

@media (max-width: 840px) {
  .nav-toggle { display: inline-block; }
  .site-nav {
    display: none;
    position: absolute;
    top: 64px;
    left: 0;
    right: 0;
    z-index: 20;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    padding: 0.5rem 1rem 1rem;
  }
  .site-nav.open { display: flex; }
  .site-nav a { padding: 0.7rem 0.3rem; border-bottom: 1px solid var(--line); }
  .site-nav a[aria-current="page"] { border-bottom-color: var(--line); }
  .site-header { position: relative; }
}

/* ---------- Layout ---------- */

.page {
  max-width: 760px;
  margin: 0 auto;
  padding: clamp(2rem, 6vw, 4rem) 1.25rem 4rem;
}

.page-wide { max-width: 980px; }

.section { margin-top: 3rem; }

.rule {
  width: 3.2rem;
  height: 1px;
  background: var(--brass);
  border: none;
  margin: 1.4rem 0;
}

.rule-center { margin-left: auto; margin-right: auto; }

.center { text-align: center; }

/* ---------- Hero (homepage) ---------- */

.hero {
  min-height: 72vh;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 4rem 1.25rem 3rem;
}

.hero h1 {
  font-style: italic;
  font-weight: 600;
}

.hero .date-line {
  font-family: var(--serif);
  font-size: clamp(1.2rem, 3vw, 1.6rem);
  letter-spacing: 0.08em;
  margin-top: 0.4rem;
}

.cta-row {
  display: flex;
  gap: 0.8rem;
  flex-wrap: wrap;
  justify-content: center;
  margin-top: 2rem;
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-block;
  font-family: var(--sans);
  font-size: 0.9rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  padding: 0.75rem 1.6rem;
  border-radius: 999px;
  border: 1px solid var(--cypress);
  background: var(--cypress);
  color: var(--paper);
  text-decoration: none;
  cursor: pointer;
}

.btn:hover { background: var(--cypress-dark); color: var(--paper); }

.btn-ghost {
  background: transparent;
  color: var(--cypress);
}

.btn-ghost:hover { background: var(--paper-deep); color: var(--cypress-dark); }

.btn-small { padding: 0.5rem 1.1rem; font-size: 0.8rem; }

/* ---------- Photo placeholders ---------- */

.photo-band {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.9rem;
  margin-top: 2.5rem;
  width: min(100%, 900px);
}

.photo-ph {
  aspect-ratio: 3 / 4;
  border: 1px solid var(--line);
  border-radius: 4px;
  background:
    linear-gradient(160deg, var(--paper-deep) 0%, #e4dbc6 60%, #ddd2b8 100%);
  display: flex;
  align-items: flex-end;
  padding: 0.8rem;
}

.photo-ph span {
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(210px, 1fr));
  gap: 0.9rem;
  margin-top: 2rem;
}

@media (max-width: 640px) {
  .photo-band { grid-template-columns: 1fr; }
  .photo-ph { aspect-ratio: 4 / 3; }
}

/* ---------- Date rail (signature element) ---------- */

.rail {
  list-style: none;
  margin: 2.2rem 0 0;
  padding-left: 1.6rem;
  border-left: 1px solid var(--brass);
}

.rail li {
  position: relative;
  padding: 0 0 2rem 1.2rem;
}

.rail li:last-child { padding-bottom: 0.2rem; }

.rail li::before {
  content: attr(data-day);
  position: absolute;
  left: -2.85rem;
  top: -0.15rem;
  width: 2.4rem;
  height: 2.4rem;
  border-radius: 50%;
  border: 1px solid var(--brass);
  background: var(--paper);
  color: var(--cypress);
  font-family: var(--serif);
  font-size: 1.05rem;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
}

.rail .rail-date {
  font-size: 0.72rem;
  font-weight: 600;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--sienna);
}

.rail h3 { margin: 0.15rem 0 0.2rem; }

.rail p { color: var(--ink-soft); font-size: 0.95rem; }

/* ---------- Cards, forms, tables ---------- */

.card {
  background: #fffdf8;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 1.5rem;
  margin-top: 1.5rem;
}

.card-tinted { background: var(--paper-deep); }

label {
  display: block;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.05em;
  margin: 1rem 0 0.3rem;
}

input[type="text"],
input[type="email"],
input[type="search"],
textarea,
select {
  width: 100%;
  font: inherit;
  font-size: 0.95rem;
  padding: 0.65rem 0.8rem;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  color: var(--ink);
}

textarea { min-height: 90px; resize: vertical; }

input:focus, textarea:focus, select:focus {
  outline: 2px solid var(--cypress);
  outline-offset: 1px;
  border-color: var(--cypress);
}

.hint { font-size: 0.8rem; color: var(--ink-soft); margin-top: 0.3rem; }

.member-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.8rem 0;
  border-bottom: 1px solid var(--line);
  flex-wrap: wrap;
}

.member-row:last-child { border-bottom: none; }

.member-name { font-family: var(--serif); font-size: 1.15rem; font-weight: 600; }

.toggle-group { display: flex; gap: 0.5rem; }

.chip {
  font: inherit;
  font-size: 0.78rem;
  font-weight: 600;
  padding: 0.45rem 0.95rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: #fff;
  color: var(--ink-soft);
  cursor: pointer;
}

.chip[aria-pressed="true"].chip-yes {
  background: var(--cypress);
  border-color: var(--cypress);
  color: var(--paper);
}

.chip[aria-pressed="true"].chip-no {
  background: var(--sienna);
  border-color: var(--sienna);
  color: var(--paper);
}

.lookup-results { list-style: none; margin-top: 0.6rem; }

.lookup-results li { margin-top: 0.4rem; }

.lookup-results button {
  width: 100%;
  text-align: left;
  font: inherit;
  font-size: 0.95rem;
  padding: 0.7rem 0.9rem;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: #fff;
  cursor: pointer;
}

.lookup-results button:hover { border-color: var(--cypress); color: var(--cypress); }

.notice {
  margin-top: 1rem;
  padding: 0.9rem 1.1rem;
  border-left: 3px solid var(--cypress);
  background: var(--paper-deep);
  font-size: 0.9rem;
}

.notice-warn { border-left-color: var(--sienna); }

.placeholder { color: var(--sienna); font-weight: 600; }

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.87rem;
  margin-top: 1rem;
}

.data-table th, .data-table td {
  text-align: left;
  padding: 0.6rem 0.7rem;
  border-bottom: 1px solid var(--line);
  vertical-align: top;
}

.data-table th {
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

.stat-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 0.9rem;
  margin-top: 1.5rem;
}

.stat {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 1rem;
  background: #fffdf8;
}

.stat .num {
  font-family: var(--serif);
  font-size: 2rem;
  font-weight: 700;
  color: var(--cypress);
}

.stat .lab {
  font-size: 0.72rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--ink-soft);
}

/* ---------- FAQ ---------- */

details {
  border-bottom: 1px solid var(--line);
  padding: 1rem 0;
}

summary {
  font-family: var(--serif);
  font-size: 1.2rem;
  font-weight: 600;
  cursor: pointer;
  list-style: none;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

summary::-webkit-details-marker { display: none; }

summary::after {
  content: "+";
  font-family: var(--sans);
  color: var(--brass);
  font-size: 1.3rem;
}

details[open] summary::after { content: "\2013"; }

details p { margin-top: 0.7rem; color: var(--ink-soft); }

/* ---------- Guestbook ---------- */

.gb-entry {
  border-bottom: 1px solid var(--line);
  padding: 1.2rem 0;
}

.gb-entry .gb-msg {
  font-family: var(--serif);
  font-size: 1.15rem;
  font-style: italic;
}

.gb-entry .gb-name {
  margin-top: 0.4rem;
  font-size: 0.8rem;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--sienna);
}

/* ---------- Footer ---------- */

.site-footer {
  margin-top: 4rem;
  padding: 2.5rem 1.25rem 3rem;
  border-top: 1px solid var(--line);
  text-align: center;
  color: var(--ink-soft);
  font-size: 0.85rem;
}

.site-footer .names {
  font-family: var(--serif);
  font-size: 1.2rem;
  font-style: italic;
  color: var(--ink);
}
