/* ---------------------------------------------------------------
   Family site stylesheet.
   Loaded directly from public/ via <link> in every .html page,
   so it is NOT bundled by Vite. Edit freely - changes show up on
   refresh, no build step needed.
   --------------------------------------------------------------- */

:root {
  --bg: #fdfaf5;
  --surface: #ffffff;
  --surface-2: #f7f1e8;
  --ink: #2b2621;
  --muted: #6f6459;
  --accent: #c2410c;
  --accent-soft: #fdece1;
  --line: #ece3d8;
  --shadow: 0 1px 2px rgba(43, 38, 33, 0.06), 0 8px 24px rgba(43, 38, 33, 0.06);
  --radius: 16px;
  --serif: 'Iowan Old Style', 'Palatino Linotype', Palatino, Georgia, serif;
  --sans:
    ui-sans-serif, system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #15120e;
    --surface: #201c17;
    --surface-2: #272119;
    --ink: #f2ece3;
    --muted: #a89c8d;
    --accent: #fb923c;
    --accent-soft: #2c2118;
    --line: #322b23;
    --shadow: 0 1px 2px rgba(0, 0, 0, 0.4), 0 8px 24px rgba(0, 0, 0, 0.35);
  }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 17px;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--accent);
}

h1,
h2,
h3 {
  font-family: var(--serif);
  font-weight: 600;
  line-height: 1.2;
  margin: 0 0 0.4em;
}

h1 {
  font-size: clamp(2rem, 5vw, 3rem);
}

h2 {
  font-size: clamp(1.4rem, 3vw, 1.9rem);
}

h3 {
  font-size: 1.15rem;
}

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

.wrap {
  width: min(1080px, 100% - 2.5rem);
  margin-inline: auto;
}

/* ---------- header / nav ---------- */

.site-header {
  border-bottom: 1px solid var(--line);
  background: var(--bg);
  position: sticky;
  top: 0;
  z-index: 20;
}

.site-header .wrap {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  flex-wrap: wrap;
  padding: 0.9rem 0;
}

.brand {
  font-family: var(--serif);
  font-size: 1.15rem;
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
  white-space: nowrap;
}

.brand span {
  color: var(--accent);
}

.nav {
  display: flex;
  gap: 0.35rem;
  flex-wrap: wrap;
  margin-left: auto;
}

.nav a {
  color: var(--muted);
  text-decoration: none;
  font-size: 0.92rem;
  padding: 0.35rem 0.75rem;
  border-radius: 999px;
}

.nav a:hover {
  background: var(--surface-2);
  color: var(--ink);
}

.nav a[aria-current='page'] {
  background: var(--accent-soft);
  color: var(--accent);
  font-weight: 600;
}

/* ---------- page head ---------- */

.page-head {
  padding: 3rem 0 1.5rem;
}

.page-head p.lede {
  color: var(--muted);
  font-size: 1.05rem;
  max-width: 60ch;
  margin: 0;
}

main {
  padding-bottom: 5rem;
}

/* ---------- home hero ---------- */

.hero {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  gap: 2.5rem;
  align-items: center;
  padding: 3.5rem 0 2rem;
}

.hero p {
  color: var(--muted);
  font-size: 1.08rem;
  max-width: 52ch;
}

.hero-photo {
  border-radius: var(--radius);
  overflow: hidden;
  box-shadow: var(--shadow);
  aspect-ratio: 4 / 3;
}

@media (max-width: 760px) {
  .hero {
    grid-template-columns: 1fr;
    padding-top: 2rem;
  }
}

/* ---------- generic cards ---------- */

.grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
}

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  overflow: hidden;
  text-decoration: none;
  color: inherit;
  display: flex;
  flex-direction: column;
  transition:
    transform 0.15s ease,
    box-shadow 0.15s ease;
}

a.card:hover {
  transform: translateY(-3px);
}

.card-body {
  padding: 1.1rem 1.2rem 1.3rem;
}

.card-body h3 {
  margin-bottom: 0.15rem;
}

.card .role {
  color: var(--accent);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  font-weight: 600;
}

.card p {
  margin: 0.5rem 0 0;
  color: var(--muted);
  font-size: 0.95rem;
}

/* ---------- photos & placeholders ---------- */

.photo {
  position: relative;
  background: linear-gradient(135deg, var(--accent-soft), var(--surface-2));
  aspect-ratio: 4 / 3;
  display: grid;
  place-items: center;
  overflow: hidden;
}

.photo img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.photo.is-missing::after {
  content: attr(data-label);
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
  padding: 1rem;
  text-align: center;
  font-size: 0.8rem;
  color: var(--muted);
  letter-spacing: 0.03em;
}

.photo.is-missing img {
  display: none;
}

.photo.round {
  aspect-ratio: 1;
  border-radius: 50%;
}

/* ---------- gallery ---------- */

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

.gallery-item {
  border: 0;
  padding: 0;
  background: none;
  cursor: zoom-in;
  border-radius: 12px;
  overflow: hidden;
  box-shadow: var(--shadow);
  font: inherit;
}

.gallery-item .caption {
  padding: 0.55rem 0.7rem;
  font-size: 0.85rem;
  color: var(--muted);
  background: var(--surface);
  text-align: left;
}

.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(20, 16, 12, 0.9);
  display: grid;
  place-items: center;
  padding: 2rem;
  z-index: 50;
  cursor: zoom-out;
}

.lightbox figure {
  margin: 0;
  max-width: min(1000px, 100%);
}

.lightbox img {
  max-height: 78vh;
  width: auto;
  margin-inline: auto;
  border-radius: 10px;
}

.lightbox figcaption {
  color: #f3ece2;
  text-align: center;
  padding-top: 0.9rem;
  font-size: 0.95rem;
}

/* ---------- timeline (memories) ---------- */

.timeline {
  border-left: 2px solid var(--line);
  margin: 1rem 0 0;
  padding-left: 1.75rem;
}

.entry {
  position: relative;
  padding-bottom: 2.5rem;
}

.entry::before {
  content: '';
  position: absolute;
  left: -2.32rem;
  top: 0.55rem;
  width: 11px;
  height: 11px;
  border-radius: 50%;
  background: var(--accent);
  box-shadow: 0 0 0 4px var(--bg);
}

.entry time {
  color: var(--accent);
  font-size: 0.82rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.entry h3 {
  margin: 0.15rem 0 0.35rem;
}

.entry p {
  margin: 0;
  color: var(--muted);
  max-width: 65ch;
}

.entry .photo {
  margin-top: 1rem;
  border-radius: 12px;
  max-width: 420px;
}

/* ---------- blog ---------- */

.post-list {
  display: grid;
  gap: 1rem;
}

.post-link {
  display: block;
  padding: 1.3rem 1.4rem;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  text-decoration: none;
  color: inherit;
}

.post-link:hover {
  border-color: var(--accent);
}

.post-link h3 {
  margin: 0.25rem 0 0.35rem;
}

.post-link p {
  margin: 0;
  color: var(--muted);
  font-size: 0.95rem;
}

.meta {
  color: var(--muted);
  font-size: 0.85rem;
}

.meta .dot {
  opacity: 0.5;
  padding: 0 0.4rem;
}

.article {
  max-width: 68ch;
}

.article p {
  margin: 0 0 1.15em;
}

.tags {
  display: flex;
  gap: 0.4rem;
  flex-wrap: wrap;
  margin-top: 0.8rem;
}

.tag {
  font-size: 0.78rem;
  background: var(--surface-2);
  color: var(--muted);
  padding: 0.15rem 0.6rem;
  border-radius: 999px;
}

/* ---------- member page ---------- */

.member-head {
  display: grid;
  grid-template-columns: 200px 1fr;
  gap: 2rem;
  align-items: center;
  padding-top: 3rem;
}

@media (max-width: 640px) {
  .member-head {
    grid-template-columns: 1fr;
  }
}

.fact-list {
  list-style: none;
  padding: 0;
  margin: 1rem 0 0;
  display: grid;
  gap: 0.45rem;
}

.fact-list li {
  display: flex;
  gap: 0.75rem;
  font-size: 0.95rem;
}

.fact-list .k {
  color: var(--muted);
  min-width: 7.5rem;
}

.chip-row {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
  margin-top: 0.75rem;
}

.chip {
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 0.85rem;
  font-weight: 600;
  padding: 0.25rem 0.75rem;
  border-radius: 999px;
}

/* ---------- misc ---------- */

.section {
  padding-top: 2.5rem;
}

.section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.1rem;
}

.section-head a {
  font-size: 0.9rem;
  text-decoration: none;
}

.section-head a:hover {
  text-decoration: underline;
}

.empty {
  border: 1px dashed var(--line);
  border-radius: var(--radius);
  padding: 2rem;
  text-align: center;
  color: var(--muted);
}

.empty code {
  background: var(--surface-2);
  padding: 0.1rem 0.4rem;
  border-radius: 5px;
  font-size: 0.9em;
}

.site-footer {
  border-top: 1px solid var(--line);
  padding: 2rem 0 3rem;
  color: var(--muted);
  font-size: 0.88rem;
}

.site-footer .wrap {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

/* Shown only while the dev server is running - the link to the editor. */
.nav a.edit-link {
  border: 1px solid var(--line);
  color: var(--accent);
}

/* An article or member block that opens a page needs room under the header. */
main > section:first-child .article {
  padding-top: 3rem;
}
