/* Shared page and component styles. Theme colors are defined in :root below. */
:root {
      --paper: #101012;
      --ink: #f4f1ed;
      --body: #c6bfba;
      --gold: #dfb997;
      --rule: #393637;
  --surface: #1a191b;
  --surface-raised: #222022;
  --surface-input: #272426;
  --accent-text: #171310;
  --accent-hover: #f0d2b6;
  --focus: #edc8a6;
  --portrait-filter: saturate(.68) sepia(.10) contrast(1.04) brightness(.91);
  color-scheme: dark;
      --serif: "Baskervville", "Iowan Old Style", "Palatino Linotype", Georgia, serif;
      font-family: "DM Sans", "Segoe UI", Arial, sans-serif;
      color: var(--ink);
      background: var(--paper);
      scroll-behavior: smooth;
    }
    * { box-sizing: border-box; }
    body { margin: 0; }
    a { color: inherit; }
    a:focus-visible { outline: 3px solid #bd7c35; outline-offset: 5px; }
    .wrap { width: min(1152px, 86%); margin-inline: auto; }
    .skip { position: absolute; top: -6rem; z-index: 5; padding: 1rem; background: white; }
    .skip:focus { top: 0; }
    .masthead { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 88px; border-bottom: 1px solid var(--rule); }
    .brand { display: inline-flex; align-items: center; gap: 12px; text-decoration: none; font: 600 1.25rem var(--serif); }
    .avatar { display: block; width: 40px; height: 40px; border-radius: 50%; }
    nav { display: flex; align-items: center; gap: clamp(1rem, 3.8vw, 3.4rem); }
    nav a, .social a { padding-block: .7rem; font-size: .94rem; text-decoration: none; }
    nav a:hover, .social a:hover { text-decoration: underline; text-underline-offset: 5px; }
    .hero {
      display: grid;
      grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) minmax(0, 1fr);
      gap: clamp(1.5rem, 3.4vw, 3.25rem);
      align-items: stretch;
      padding-block: clamp(2.5rem, 4.9vw, 4.9rem);
    }
    .hero-intro { display: flex; flex-direction: column; align-items: flex-start; justify-content: center; }
    .hello { display: flex; align-items: center; gap: .9rem; margin: 0 0 .75rem; font-size: 1.05rem; }
    .hello::before { content: ""; width: 38px; height: 1px; background: var(--gold); }
    h1, h2, h3, p { margin: 0; }
    h1, h2, h3 { font-family: var(--serif); font-weight: 400; }
    h1 { font-size: clamp(3.2rem, 5.6vw, 5.4rem); letter-spacing: -.075em; line-height: .9; }
    h1 em { display: block; font-weight: 400; }
    .period { color: var(--gold); }
    .intro { max-width: 35ch; margin-top: .75rem; font-size: clamp(1rem, 1.35vw, 1.13rem); line-height: 1.5; color: var(--body); }
    .button { display: inline-flex; align-items: center; min-height: 46px; margin-top: 1.65rem; padding: .8rem 1.5rem; background: var(--ink); color: white; border-radius: 40px; text-decoration: none; }
    .button:hover { background: #343e56; }
    .hero-intro .button { min-height: 44px; margin-top: .75rem; padding-block: .65rem; }
    .portrait { display: flex; justify-content: flex-end; min-width: 0; margin: 0; }
    .portrait img { display: block; width: min(66.3%, 15.4rem); aspect-ratio: 3 / 4; object-fit: cover; object-position: center 18%; }
    section[id] { scroll-margin-top: 1.5rem; }
    .about { color: #f7f6ec; background: var(--ink); }
    .split { display: grid; grid-template-columns: 1fr 2.15fr; gap: 6%; padding-block: clamp(3.4rem, 6.4vw, 6rem); }
    .label { display: flex; gap: .75rem; align-items: baseline; font-family: inherit; font-size: .875rem; font-weight: 600; letter-spacing: .09em; text-transform: uppercase; }
    .label::before { content: ""; width: 21px; height: 1px; background: currentColor; transform: translateY(-.24em); }
    .statement { max-width: 32ch; font-family: var(--serif); font-size: clamp(1.75rem, 3.1vw, 3rem); line-height: 1.27; letter-spacing: -.035em; }
    .interests { padding-block: clamp(3.5rem, 6.5vw, 6.6rem); }
    .interests h2 { font-size: clamp(2.4rem, 4.3vw, 4.2rem); line-height: 1.1; letter-spacing: -.055em; }
    .topics { display: grid; grid-template-columns: repeat(3, 1fr); gap: 5%; margin-top: 2.1rem; }
    .topic { border-top: 1px solid var(--rule); padding-top: 1.45rem; }
    .topic h3 { font-size: 1.75rem; letter-spacing: -.025em; }
    .topic p { margin-top: .6rem; max-width: 30ch; line-height: 1.6; color: var(--body); }
    .connect { display: flex; flex-direction: column; justify-content: center; padding: clamp(1.1rem, 2vw, 1.7rem); border-radius: 1rem; background: #e7eaf1; }
    .connect h2 { font-size: clamp(1.9rem, 2.65vw, 2.65rem); line-height: 1.1; letter-spacing: -.055em; }
    .social { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); column-gap: .75rem; margin-top: .75rem; }
    .social a { display: flex; align-items: center; gap: .5rem; padding-block: .55rem; border-bottom: 1px solid #a7adba; }
    .social svg { width: 1.15rem; height: 1.15rem; flex: none; }
    @media (901px <= width <= 1100px) {
      .hero-intro h1 em { display: inline; }
    }
    @media (701px <= width <= 900px) {
      .hero { grid-template-columns: repeat(2, minmax(0, 1fr)); }
      .portrait { grid-column: 1 / -1; justify-content: center; }
      .portrait img { width: min(31%, 15.4rem); }
    }
    @media (max-width: 700px) {
      .wrap { width: 89%; }
      .masthead { min-height: 72px; }
      .brand { gap: 7px; }
      .brand-name { display: none; }
      .hero { grid-template-columns: 1fr; gap: 1.5rem; padding-block: 2.25rem 2.75rem; }
      h1 { font-size: clamp(2.65rem, 10vw, 4.2rem); }
      h1 em { display: inline; }
      .hello { margin-bottom: 1rem; }
      .intro { margin-top: 1.2rem; }
      .portrait { justify-content: center; }
      .portrait img { width: min(60%, 15.4rem); }
      .split { grid-template-columns: 1fr; gap: 1.4rem; }
      .topics { grid-template-columns: 1fr; gap: 1.4rem; }
      .topic p { max-width: 46ch; }
    }
    @media (prefers-reduced-motion: reduce) { :root { scroll-behavior: auto; } }

    .drop { margin-top: 1.5rem; padding: clamp(1.6rem,4vw,3.5rem); border-radius: 1.5rem; background: #e7eaf1; display: grid; grid-template-columns: .9fr 1.1fr; align-items: center; gap: 3%; }
    .drop h2 { font-size: clamp(3.2rem,5.8vw,5.8rem); line-height: .97; letter-spacing: -.055em; max-width: 9ch; }
    .drop h2 em { font-weight: 400; }
    .drop-copy p { margin-top: 1.05rem; line-height: 1.6; color: var(--body); max-width: 30ch; }
    button, input, select { font: inherit; }
    button { cursor: pointer; }
    button:focus-visible, input:focus-visible, select:focus-visible { outline: 3px solid #98632d; outline-offset: 3px; }
    .drop .button, .request .button { border: 0; justify-content: center; font-weight: 600; }
    .gallery { min-width: 0; }
    .cards { position: relative; height: clamp(230px,25vw,315px); overflow: hidden; }
    .card { position: absolute; inset: 7% 25%; margin: 0; padding: 12px; background: #fff8ec; border: 1px solid #fff; border-radius: 12px; box-shadow: 0 6px 17px #20253320; transition: transform .85s ease, opacity .85s ease; }
    .card:nth-child(even) { background: #d8e1ed; }
    .card img { display: block; width: 100%; height: 100%; object-fit: contain; }
    .card[data-slot="0"] { z-index: 3; transform: rotate(-2deg); }
    .card[data-slot="-1"] { z-index: 2; transform: translate(-48%,5%) scale(.78) rotate(-11deg); }
    .card[data-slot="1"] { z-index: 2; transform: translate(48%,5%) scale(.78) rotate(11deg); }
    .card[data-slot="-2"], .card[data-slot="2"] { opacity: 0; transform: scale(.65); }
    .gallery-controls { display: flex; justify-content: center; align-items: center; gap: .8rem; }
    .gallery-controls button, .close-modal { border: 1px solid #a7adba; color: var(--ink); background: transparent; min-width: 42px; min-height: 42px; border-radius: 2rem; }
    .gallery-controls button:hover, .close-modal:hover { background: white; }
    .gallery-controls output { font-variant-numeric: tabular-nums; font-size: .9rem; }
    .cycle { padding-inline: .9rem; }
    .request { color: var(--ink); background: var(--paper); border: none; border-radius: 1rem; padding: clamp(1.4rem,4vw,2.1rem); width: min(27.5rem,92vw); max-height: 90vh; }
    .request::backdrop { background: rgb(23 28 42 / 55%); }
    .modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: .8rem; }
    .modal-head h2 { font-size: 2.4rem; line-height: 1.08; letter-spacing: -.04em; }
    .close-modal { font-size: 1.4rem; }
    .request form { display: grid; gap: .9rem; margin-top: 1.1rem; }
    .request form[hidden] { display: none; }
    .field { display: grid; gap: .35rem; font-weight: 600; }
    .field input, .field select { width: 100%; color: var(--ink); background: white; border: 1px solid #8b92a0; border-radius: .45rem; padding: .65rem; }
    .consent { display: flex; align-items: flex-start; gap: .65rem; line-height: 1.4; }
    .consent input { margin: .18rem 0 0; width: 1.1rem; height: 1.1rem; accent-color: var(--ink); flex: none; }
    .form-note, .form-status { font-size: .93rem; line-height: 1.45; color: var(--body); }
    .form-note { margin-top: .7rem; }
    .request .button { margin-top: 0; }
    .form-status:empty { display: none; }
    .pack-ready { margin-top: 1.1rem; }
    .pack-ready p { color: var(--body); line-height: 1.5; }
    .pack-ready .button {
      display: flex;
      gap: .75rem;
      justify-content: flex-start;
      margin-top: 1.25rem;
      padding: .75rem 1rem;
      border-radius: .85rem;
      line-height: 1.35;
    }
    .drive-icon {
      display: grid;
      flex: none;
      place-items: center;
      width: 2.5rem;
      height: 2.5rem;
      border-radius: .5rem;
      background: white;
    }
    .drive-icon svg { width: 1.55rem; height: 1.55rem; }
    @media(max-width:700px) {
      .drop { grid-template-columns: 1fr; gap: 1rem; }
      .drop h2 { max-width: 13ch; }
      .cards { height: 235px; }
      .card { inset-inline: 23%; }
    }
    @media(prefers-reduced-motion:reduce) { .card { transition: none; } }

/* Reference-inspired component theme. Shared colors are declared at the top. */
body { background: var(--paper); color: var(--ink); }
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible { outline-color: var(--focus); }
.skip { background: var(--surface-raised); color: var(--ink); }
.avatar { object-fit: cover; object-position: center 20%; filter: var(--portrait-filter); }
.button { background: var(--gold); color: var(--accent-text); font-weight: 600; }
.button:hover { background: var(--accent-hover); }
.drop, .connect { background: var(--surface); border: 1px solid var(--rule); }
.drop h2 em { color: var(--gold); }
.portrait img { height: auto; border-radius: 1rem; filter: var(--portrait-filter); }
.about { background: var(--surface); color: var(--ink); border-block: 1px solid var(--rule); }
.label { color: var(--gold); }
.topic { padding: 1.4rem; border: 1px solid var(--rule); border-radius: 1rem; background: var(--surface); }
.topic h3 { color: var(--ink); }
.social a { border-color: var(--rule); }
.social a:hover, nav a:hover { color: var(--gold); }
.card, .card:nth-child(even) { background: var(--surface-raised); border-color: var(--rule); box-shadow: 0 8px 24px #0008; }
.gallery-controls button, .close-modal { border-color: var(--rule); color: var(--ink); }
.gallery-controls button:hover, .close-modal:hover { background: var(--surface-raised); }
.request { color: var(--ink); background: var(--surface); border: 1px solid var(--rule); }
.request::backdrop { background: rgb(0 0 0 / 75%); }
.field input, .field select { color: var(--ink); background: var(--surface-input); border-color: #716962; }
.consent input { accent-color: var(--gold); }
.drive-icon { background: #fff; }
@media (max-width: 700px) { .topics { gap: 1rem; } }
