/* MootHall's public page: warm paper and sandstone, ivy green as the one accent, crisp edges. */

:root {
  --paper: #FBF7EE;
  --sky: #F4E6CC;
  --sand: #E3CBA2;
  --sand-deep: #CDB088;
  --ink: #1D1C1A;
  --ink-soft: #4A4640;
  --ivy: #3E8E3A;
  --ivy-deep: #2C6A29;
  --field: #FFFDF8;
  --shadow: 5px 5px 0 var(--ink);
  --gutter: clamp(16px, 4vw, 48px);
  --max: 1520px;
  --serif: 'Newsreader', 'Iowan Old Style', 'Palatino Linotype', Palatino, Georgia, serif;
  /* Gentium Book Plus: the closest web font to Gentilis, the face of the bronze MootHall sign over the keep's oak door. */
  --display: 'Gentium Book Plus', 'Gentium Plus', 'Palatino Linotype', Palatino, Georgia, serif;
  --bronze: #B07A3C;
  --bronze-deep: #6E4519;
  --bronze-face: linear-gradient(180deg, #F0CF8F 0%, #D29B55 34%, #A86F32 58%, #7E4E1E 80%, #6A4119 100%);
}

*, *::before, *::after { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: no-preference) {
  html { scroll-behavior: smooth; }
}

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: var(--serif);
  font-size: clamp(1.0625rem, 0.98rem + 0.35vw, 1.25rem);
  line-height: 1.6;
  text-align: left;
  overflow-x: hidden;
}

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

h1, h2, h3 {
  font-family: var(--display);
  line-height: 1.08;
  margin: 0 0 0.5em;
  letter-spacing: -0.01em;
}
h2 { font-size: clamp(1.9rem, 1.4rem + 2.2vw, 3rem); font-weight: 800; }
h3 { font-size: 1.2rem; font-weight: 700; }
p { margin: 0 0 1em; }

a { color: var(--ink); text-decoration-color: var(--ivy); text-decoration-thickness: 2px; text-underline-offset: 3px; }
a:hover { color: var(--ivy-deep); }

:focus-visible { outline: 3px solid var(--ivy); outline-offset: 3px; }
main:focus { outline: none; }

.skip {
  position: absolute;
  left: 16px;
  top: -100px;
  z-index: 10;
  padding: 10px 16px;
  background: var(--ink);
  color: var(--paper);
  font-family: var(--display);
  font-weight: 700;
}
.skip:focus { top: 12px; }

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

.top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  width: min(var(--max), 100% - 2 * var(--gutter));
  margin: 0 auto;
  padding: 18px 0;
  border-bottom: 2px solid var(--ink);
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  text-decoration: none;
  color: var(--ink);
  font-family: var(--display);
  font-weight: 800;
  font-size: 1.45rem;
  letter-spacing: -0.02em;
}
.brand .mark { width: 40px; height: 40px; color: var(--ivy); flex: none; }
.top ul { display: flex; gap: 24px; list-style: none; margin: 0; padding: 0; align-items: center; }
.top nav a {
  font-family: var(--display);
  font-weight: 600;
  font-size: 0.98rem;
  text-decoration: none;
}
.top nav a:hover { text-decoration: underline; text-decoration-color: var(--ivy); }
.top .nav-apply {
  display: inline-block;
  padding: 6px 12px;
  border: 2px solid var(--ink);
  box-shadow: 3px 3px 0 var(--ink);
  background: var(--paper);
}

/* ---------- shared ---------- */

section { padding: clamp(56px, 8vw, 104px) max(var(--gutter), calc((100% - var(--max)) / 2)); }
.section-intro { max-width: none; }

.button {
  display: inline-block;
  padding: 14px 26px;
  background: var(--ivy);
  color: #fff;
  border: 2px solid var(--ink);
  box-shadow: var(--shadow);
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.2rem;
  line-height: 1.2;
  text-decoration: none;
  cursor: pointer;
}
.button:hover { background: var(--ivy-deep); color: #fff; }
.button:active { transform: translate(3px, 3px); box-shadow: 2px 2px 0 var(--ink); }
.button:focus-visible { outline-color: var(--ink); }
@media (prefers-reduced-motion: no-preference) {
  .button { transition: transform 80ms ease-out, box-shadow 80ms ease-out, background-color 120ms; }
}

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

.hero { padding-top: clamp(40px, 6vw, 80px); padding-bottom: 40px; }
.hero h1 {
  font-size: clamp(2.3rem, 1.2rem + 5vw, 5.1rem);
  font-weight: 800;
  line-height: 1.02;
  letter-spacing: -0.025em;
  max-width: 30ch;
  margin-bottom: 0.45em;
}
.lede { max-width: none; font-size: 1.12em; color: var(--ink); }
.lede + .lede { color: var(--ink-soft); font-size: 1em; }
.hero .button { margin-top: 0.4em; }

.hero-art { margin: clamp(32px, 5vw, 56px) 0 0; }
.hero-art img {
  width: 100%;
  border: 2px solid var(--ink);
  box-shadow: var(--shadow);
  background: var(--sand);
}
figcaption {
  margin-top: 14px;
  font-size: 0.9rem;
  font-style: italic;
  color: var(--ink-soft);
  max-width: none;
}

/* ---------- inside: the steps, and the Great Hall in an arch ---------- */

.inside {
  border-top: 2px solid var(--ink);
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 32px;
}
.inside > * { margin: 0; }
.inside-head p { font-size: 1.1em; color: var(--ink-soft); }

.steps { list-style: none; counter-reset: step; padding: 0; margin: 0; }
.steps li {
  counter-increment: step;
  display: grid;
  grid-template-columns: 3.2rem minmax(0, 1fr);
  column-gap: 16px;
  padding: 20px 0;
  border-top: 1px solid var(--sand-deep);
}
.steps li:last-child { border-bottom: 1px solid var(--sand-deep); }
.steps li::before {
  content: counter(step);
  grid-row: span 2;
  font-family: var(--display);
  font-weight: 800;
  font-size: 2.2rem;
  line-height: 1;
  color: var(--ivy);
}
.steps h3 { margin-bottom: 0.25em; }
.steps p { margin: 0; max-width: none; }

.hall { margin: 0; }
.hall .arch {
  filter: drop-shadow(5px 5px 0 var(--ink));
}
.hall .arch img {
  width: 100%;
  aspect-ratio: 740 / 726;
  object-fit: cover;
  border-radius: 50% 50% 0 0 / 34% 34% 0 0;
  border: 0;
}

@media (min-width: 900px) {
  .inside {
    grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
    grid-template-areas: "head hall" "steps hall";
    column-gap: clamp(40px, 6vw, 88px);
    align-items: start;
  }
  .inside-head { grid-area: head; }
  .steps { grid-area: steps; }
  /* The one thing that breaks the grid: the hall's arch rises out of its section, over the rule above it. */
  .hall { grid-area: hall; margin-top: -150px; position: sticky; top: 24px; }
}

/* ---------- what MootHall is becoming: illustrations of the dream ---------- */

.today { border-top: 2px solid var(--ink); padding-bottom: clamp(72px, 10vw, 136px); }
.today-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 32px;
  margin-top: 36px;
}
.today figure { margin: 0; }
.today img {
  width: 100%;
  border: 2px solid var(--ink);
  box-shadow: var(--shadow);
  background: var(--sand);
}
@media (min-width: 900px) {
  .today-grid {
    grid-template-columns: minmax(0, 2.3fr) minmax(0, 1fr);
    column-gap: clamp(28px, 3vw, 48px);
    row-gap: 28px;
    align-items: start;
  }
  .today-main { grid-row: span 2; }
}

/* ---------- the Virtual Friends ---------- */

.friends { background: var(--sky); border-top: 2px solid var(--ink); }
.friend-list {
  list-style: none;
  padding: 0;
  margin-top: 40px;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 280px), 1fr));
  gap: 40px;
}
.friend-list li { border-top: 4px solid var(--ivy); padding-top: 18px; }
.friend-list .portrait {
  display: block;
  width: 100%;
  max-width: 320px;
  height: auto;
  margin-bottom: 18px;
  border: 2px solid var(--ink);
  box-shadow: var(--shadow);
}
.friend-list h3 { font-size: 1.7rem; font-weight: 800; margin-bottom: 0.1em; }
.brings { font-family: var(--display); font-weight: 600; font-size: 0.95rem; color: var(--ivy-deep); margin-bottom: 0.8em; }
.friend-list blockquote { margin: 0; font-style: italic; color: var(--ink-soft); }
.friend-list blockquote p { margin: 0; }

/* ---------- what you need ---------- */

.need { border-top: 2px solid var(--ink); }
.needs {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 260px), 1fr));
  gap: 32px;
  margin-top: 40px;
  margin-bottom: 48px;
}
.needs dt { font-family: var(--display); font-weight: 700; font-size: 1.15rem; line-height: 1.2; margin-bottom: 8px; }
.needs dd { margin: 0; }
.not-ready {
  max-width: none;
  margin: 0;
  padding: 20px 24px;
  border: 2px solid var(--ink);
  box-shadow: 5px 5px 0 var(--ivy);
  background: var(--field);
}

/* ---------- terms ---------- */

.terms { background: var(--sand); border-top: 2px solid var(--ink); border-bottom: 2px solid var(--ink); }
.terms p { max-width: none; }
.terms .draft {
  display: inline-block;
  font-family: var(--display);
  font-weight: 700;
  font-size: 1rem;
  line-height: 1.4;
  padding: 10px 14px;
  border: 2px solid var(--ink);
  background: var(--paper);
  margin-bottom: 0;
}

/* ---------- apply ---------- */

.apply { display: grid; gap: 40px; }
.apply > * { margin: 0; }
.apply-head p { max-width: none; }
@media (min-width: 900px) {
  .apply {
    grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
    column-gap: clamp(40px, 6vw, 88px);
    align-items: start;
  }
}

.form {
  background: var(--field);
  border: 2px solid var(--ink);
  box-shadow: var(--shadow);
  padding: clamp(20px, 4vw, 36px);
}
.field { margin: 0 0 22px; padding: 0; border: 0; min-width: 0; }
.field label, .field legend {
  display: block;
  font-family: var(--display);
  font-weight: 700;
  font-size: 1.05rem;
  margin-bottom: 8px;
  padding: 0;
}
input[type="text"], input[type="url"], textarea {
  width: 100%;
  font: inherit;
  color: var(--ink);
  background: #fff;
  border: 2px solid var(--ink);
  border-radius: 0;
  padding: 10px 12px;
}
textarea { resize: vertical; min-height: 5.5em; }
input::placeholder { color: #8A8378; }
.hint { font-size: 0.9rem; color: var(--ink-soft); margin: 6px 0 0; }
.choices { display: flex; flex-wrap: wrap; gap: 10px 14px; }
.choices label {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin: 0;
  padding: 10px 14px;
  border: 2px solid var(--ink);
  background: #fff;
  font-family: var(--serif);
  font-weight: 400;
  font-size: 1rem;
  cursor: pointer;
}
.choices label:has(input:checked) { background: var(--sky); box-shadow: 3px 3px 0 var(--ivy); }
.choices input { width: 20px; height: 20px; margin: 0; accent-color: var(--ivy); }
.form-error {
  border-left: 4px solid #A33A2A;
  padding: 8px 12px;
  background: #FBEDE8;
  color: #6B1E12;
}
.sent { margin-top: 28px; padding-top: 22px; border-top: 2px solid var(--ink); }
.sent:focus { outline: none; }
.sent pre {
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font-family: var(--serif);
  font-size: 0.95rem;
  background: var(--paper);
  border: 1px solid var(--sand-deep);
  padding: 14px 16px;
  margin: 0;
}

/* ---------- footer ---------- */

.foot {
  width: min(var(--max), 100% - 2 * var(--gutter));
  margin: 0 auto;
  padding: 28px 0 48px;
  border-top: 2px solid var(--ink);
  font-size: 0.92rem;
  color: var(--ink-soft);
}
.foot p { margin: 0; text-align: left; }
.foot .sep { margin: 0 0.35em; }

/* ---------- phones ---------- */

@media (max-width: 720px) {
  .top nav .wide { display: none; }
  .brand { font-size: 1.25rem; }
  .brand .mark { width: 34px; height: 34px; }
}

/* ---------- bronze lettering, like the MootHall sign over the keep's oak door ---------- */

/* Raised bronze: a lit gradient face, a few one-pixel steps of darker bronze for the depth, then a soft cast shadow.
   drop-shadow follows the clipped letters, where text-shadow would show through the transparent face. */
.hero h1,
.brand span {
  color: var(--bronze);
  font-weight: 700;
  letter-spacing: 0;
}
@supports ((-webkit-background-clip: text) or (background-clip: text)) {
  .hero h1,
  .brand span {
    background: var(--bronze-face);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
    -webkit-text-fill-color: transparent;
  }
}
.hero h1 {
  line-height: 1.08;
  padding-bottom: 0.08em;
  /* One lit face per line: the gradient repeats every line-height. */
  background-size: 100% 1.08em;
  background-position: 0 0.22em;
  filter:
    drop-shadow(1px 1px 0 #8A5A26)
    drop-shadow(1px 1px 0 var(--bronze-deep))
    drop-shadow(1px 1px 0 var(--bronze-deep))
    drop-shadow(1px 2px 0 #4F3010)
    drop-shadow(4px 7px 8px rgba(45, 28, 10, 0.38));
}
.brand span {
  font-size: 1.6rem;
  filter:
    drop-shadow(1px 1px 0 var(--bronze-deep))
    drop-shadow(1px 1px 0 #4F3010)
    drop-shadow(2px 3px 3px rgba(45, 28, 10, 0.35));
}
h2 { color: #5A3812; }

/* The tagline over the headline: small bronze capitals on a short bronze rule. */
.tagline {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  margin: 0 0 1.1em;
  font-family: var(--display);
  font-weight: 700;
  font-size: clamp(0.95rem, 0.85rem + 0.35vw, 1.15rem);
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #7A4D1F;
}
.tagline::before {
  content: '';
  width: 48px;
  height: 3px;
  background: linear-gradient(90deg, #D29B55, #8A5A26);
}
