:root {
  --ink: #243028;
  --ink-soft: #3d4c43;
  --cream: #f6f1e6;
  --paper: #fffdf8;
  --sage: #8f9b86;
  --sage-deep: #5d6b56;
  --gold: #e2b03a;
  --gold-deep: #8d6412;
  --line: rgba(36, 48, 40, 0.12);
  --shadow: 0 22px 50px rgba(36, 48, 40, 0.12);
  --radius: 22px;
  --header: 76px;
  --wrap: 1120px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--ink);
  font-family: Outfit, "Segoe UI", sans-serif;
  font-size: 1.05rem;
  line-height: 1.6;
  background:
    radial-gradient(900px 420px at 80% -8%, #c5e7fb 0%, transparent 62%),
    linear-gradient(180deg, #e7f4fc 0%, #f7f3ea 320px, var(--cream) 640px);
}

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

a {
  color: var(--gold-deep);
  text-underline-offset: 3px;
}

a:hover {
  color: #6d4c0c;
}

h1,
h2,
h3 {
  font-family: Fraunces, Georgia, serif;
  font-weight: 680;
  letter-spacing: -0.03em;
  line-height: 1.08;
  margin: 0;
}

h1 {
  font-size: clamp(2.6rem, 6vw, 4.6rem);
}

h2 {
  font-size: clamp(2rem, 4vw, 3.15rem);
}

h3 {
  font-size: 1.45rem;
}

p {
  margin: 0;
}

.wrap {
  width: min(var(--wrap), calc(100% - 40px));
  margin-inline: auto;
}

.skip {
  position: absolute;
  left: 12px;
  top: -40px;
  background: var(--ink);
  color: white;
  padding: 8px 12px;
  z-index: 20;
}

.skip:focus {
  top: 12px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  border: 0;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 10;
  height: var(--header);
  display: flex;
  align-items: center;
  background: rgba(246, 241, 230, 0.78);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid transparent;
}

.site-header.scrolled {
  border-bottom-color: var(--line);
  box-shadow: 0 10px 30px rgba(36, 48, 40, 0.06);
}

.nav {
  display: flex;
  align-items: center;
  gap: 22px;
  width: min(var(--wrap), calc(100% - 40px));
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--ink);
  text-decoration: none;
  font-weight: 700;
  letter-spacing: -0.03em;
}

.brand img {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  object-position: center 32%;
  border: 2px solid #fff;
  box-shadow: 0 0 0 2px var(--gold);
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-left: auto;
}

.nav-links a {
  color: var(--ink-soft);
  text-decoration: none;
  font-weight: 560;
  font-size: 0.95rem;
}

.nav-links a:hover {
  color: var(--ink);
}

.nav-x {
  display: inline-flex;
  align-items: center;
  gap: 6px;
}

.nav-x svg {
  width: 14px;
  height: 14px;
}

.nav-toggle {
  display: none;
  width: 44px;
  height: 44px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--paper);
  padding: 0;
  position: relative;
}

.nav-toggle span:not(.sr-only) {
  position: absolute;
  left: 12px;
  right: 12px;
  height: 2px;
  background: var(--ink);
}

.nav-toggle span:nth-of-type(2) {
  top: 17px;
}

.nav-toggle span:nth-of-type(3) {
  top: 25px;
}

.btn {
  appearance: none;
  border: 0;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  border-radius: 999px;
  font: 650 0.95rem Outfit, sans-serif;
  letter-spacing: -0.01em;
}

.btn-gold {
  color: #3a2808;
  background: linear-gradient(180deg, #ffe7a6 0%, #e2b03a 48%, #c48a16 100%);
  box-shadow: inset 0 1px 0 #fff6d0, 0 8px 18px rgba(168, 112, 20, 0.25);
}

.btn-gold:hover {
  color: #2a1c06;
  filter: brightness(1.04);
}

.btn-ink {
  background: var(--ink);
  color: #f6f1e6;
}

.btn-ink:hover {
  color: white;
  background: #1a2420;
}

.btn-ghost {
  background: transparent;
  color: var(--ink);
  box-shadow: inset 0 0 0 1.5px rgba(36, 48, 40, 0.28);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.55);
  color: var(--ink);
}

.btn-ghost-light {
  color: #f6f1e6;
  box-shadow: inset 0 0 0 1.5px rgba(246, 241, 230, 0.45);
}

.btn-ghost-light:hover {
  color: white;
  background: rgba(255, 255, 255, 0.08);
}

.banner-frame {
  margin-top: 18px;
  padding: 8px;
  background: #fff;
  border-radius: 28px;
  box-shadow: var(--shadow);
}

.banner-frame img {
  display: block;
  width: 100%;
  border-radius: 22px;
}

.porch {
  position: relative;
  z-index: 1;
  margin: -72px auto 0;
  width: min(820px, 100%);
  padding: 32px 34px 28px;
  background: rgba(255, 253, 248, 0.94);
  border: 8px solid #fff;
  border-radius: 28px;
  box-shadow: var(--shadow);
  text-align: center;
}

.kicker,
.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 12px;
  color: var(--sage-deep);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.lamp {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #ffb15a;
  box-shadow: 0 0 0 4px rgba(255, 177, 90, 0.25), 0 0 12px #ff9d42;
}

.lede {
  margin: 16px auto 0;
  max-width: 62ch;
  color: var(--ink-soft);
  font-size: 1.08rem;
}

.fine {
  margin-top: 12px;
  color: #66746b;
  font-size: 0.92rem;
}

.mat {
  margin: 22px auto 0;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 12px;
  align-items: center;
  text-align: left;
  padding: 10px 10px 10px 16px;
  border-radius: 18px;
  background:
    repeating-linear-gradient(90deg, rgba(74, 49, 18, 0.08) 0 1px, transparent 1px 7px),
    linear-gradient(180deg, #f3e2c4, #e7d0a4);
  box-shadow: inset 0 0 0 1px rgba(120, 82, 28, 0.25);
}

.mat-word {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #7a5420;
}

.mat code {
  font-family: ui-monospace, "Cascadia Code", Consolas, monospace;
  font-size: 0.98rem;
  color: var(--ink);
  overflow-wrap: anywhere;
}

.hero-actions {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.marquee {
  margin-top: 42px;
  overflow: hidden;
  max-width: 100%;
  border-block: 1px solid var(--line);
  background: rgba(255, 253, 248, 0.7);
}

.marquee-track {
  display: flex;
  width: max-content;
  animation: ticker 32s linear infinite;
}

.marquee p {
  display: flex;
  gap: 0;
  margin: 0;
  padding: 14px 0;
}

.marquee span {
  padding: 0 22px;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--sage-deep);
}

.marquee span::before {
  content: "◆";
  margin-right: 22px;
  color: var(--gold);
  font-size: 0.7rem;
}

@keyframes ticker {
  from {
    transform: translateX(0);
  }
  to {
    transform: translateX(-50%);
  }
}

.section,
.band,
.closer {
  scroll-margin-top: 88px;
}

.section {
  padding: 88px 0;
}

.story-grid,
.post-grid {
  display: grid;
  grid-template-columns: minmax(0, 0.92fr) minmax(0, 1.08fr);
  gap: 48px;
  align-items: center;
}

.story-grid > *,
.post-grid > * {
  min-width: 0;
}

.house-frame {
  margin: 0;
  background: #fff;
  padding: 8px;
  border-radius: 28px;
  box-shadow: var(--shadow);
}

.house-frame img {
  display: block;
  width: 100%;
  border-radius: 22px;
  aspect-ratio: 1;
  object-fit: cover;
  object-position: center 40%;
}

.house-frame figcaption {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 8px 8px;
  font-weight: 650;
  letter-spacing: -0.02em;
}

.story-copy p + p,
.story-copy .rules {
  margin-top: 14px;
}

.story-copy p {
  color: var(--ink-soft);
}

.rules {
  list-style: none;
  padding: 0;
  display: grid;
  gap: 12px;
}

.rules li {
  padding: 14px 16px;
  background: var(--paper);
  border-radius: 16px;
  box-shadow: inset 0 0 0 1px var(--line);
  color: var(--ink-soft);
}

.rules strong {
  display: block;
  color: var(--ink);
  font-family: Fraunces, Georgia, serif;
  font-weight: 640;
  font-size: 1.12rem;
  margin-bottom: 2px;
}

.lattice {
  height: 28px;
  background-color: #f3efe6;
  background-image:
    linear-gradient(45deg, #243028 25%, transparent 25%),
    linear-gradient(-45deg, #243028 25%, transparent 25%),
    linear-gradient(45deg, transparent 75%, #243028 75%),
    linear-gradient(-45deg, transparent 75%, #243028 75%);
  background-size: 14px 14px;
  background-position:
    0 0,
    0 7px,
    7px -7px,
    -7px 0;
  border-block: 8px solid #fff;
}

.post-section {
  background:
    linear-gradient(180deg, rgba(255, 253, 248, 0.2), rgba(255, 253, 248, 0.65)),
    repeating-linear-gradient(90deg, rgba(36, 48, 40, 0.035) 0 1px, transparent 1px 22px);
}

.post-copy p {
  color: var(--ink-soft);
  margin-top: 14px;
}

.post-meta {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
  margin: 22px 0 18px;
}

.post-meta div {
  padding: 12px 14px;
  background: var(--paper);
  border-radius: 14px;
  box-shadow: inset 0 0 0 1px var(--line);
}

.post-meta dt {
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--sage-deep);
}

.post-meta dd {
  margin: 2px 0 0;
  font-weight: 700;
}

.text-link {
  font-weight: 700;
}

.tweet-slot {
  display: flex;
  justify-content: center;
  min-height: 280px;
  width: 100%;
  max-width: 550px;
  margin-inline: auto;
}

.tweet-slot .twitter-tweet,
.tweet-slot iframe {
  margin: 0 !important;
  width: 100% !important;
  max-width: 100% !important;
}

.tweet-slot .twitter-tweet {
  background: var(--paper);
  border-radius: 16px;
  padding: 8px 16px 4px;
  box-shadow: var(--shadow);
}

.band {
  padding: 28px 0 88px;
}

.section-intro {
  max-width: 640px;
  margin-bottom: 28px;
}

.lede-left {
  margin-left: 0;
  margin-top: 14px;
}

.passport {
  background: var(--paper);
  border-radius: 28px;
  padding: 22px;
  box-shadow: var(--shadow), inset 0 0 0 8px #fff;
}

.passport-top {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 6px 8px 18px;
}

.passport-top img {
  width: 72px;
  height: 72px;
  border-radius: 18px;
  object-fit: cover;
  object-position: center 30%;
}

.passport-top h3 {
  font-size: 1.8rem;
}

.ticker {
  margin-left: auto;
  font-family: Fraunces, Georgia, serif;
  font-weight: 680;
  font-size: clamp(1.4rem, 3vw, 2rem);
  color: var(--gold-deep);
}

.facts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  margin: 0;
  background: var(--line);
  border-radius: 18px;
  overflow: hidden;
}

.facts div {
  background: #fbf8f2;
  padding: 16px 18px;
}

.facts dt,
.network dt {
  font-size: 0.72rem;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--sage-deep);
}

.facts dd,
.network dd {
  margin: 4px 0 0;
  font-weight: 700;
}

.mat-flat {
  margin-top: 16px;
}

.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 8px;
}

.step {
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 8px;
}

.rail {
  display: flex;
  flex-direction: column;
  align-items: center;
}

.rail span {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--ink);
  color: var(--cream);
  font-family: Fraunces, Georgia, serif;
  font-weight: 680;
}

.rail i {
  flex: 1;
  width: 2px;
  min-height: 18px;
  margin: 6px 0;
  background: linear-gradient(var(--gold), transparent);
}

.step h3 {
  margin-bottom: 6px;
}

.step p {
  color: var(--ink-soft);
}

.network {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin: 14px 0;
}

.network div {
  padding: 12px 14px;
  background: var(--paper);
  border-radius: 14px;
  box-shadow: inset 0 0 0 1px var(--line);
}

.network dd {
  overflow-wrap: anywhere;
  font-size: 0.98rem;
}

.row-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.status {
  min-height: 1.4em;
  margin-top: 8px;
  color: var(--sage-deep);
  font-weight: 600;
}

.help-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 18px;
  margin-top: 28px;
  font-weight: 700;
}

.closer {
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.16), transparent 40%),
    repeating-linear-gradient(90deg, rgba(0, 0, 0, 0.05) 0 1px, transparent 1px 28px),
    repeating-linear-gradient(#9aa58f 0 18px, #8d987f 18px 19px);
  color: #f7f4ee;
  padding: 84px 0;
  border-top: 10px solid #fff;
}

.closer-inner {
  text-align: center;
  max-width: 760px;
}

.eyebrow-light {
  color: #ffe7a8;
}

.closer h2 {
  color: white;
}

.closer p:not(.eyebrow) {
  margin: 14px auto 0;
  max-width: 46ch;
  color: rgba(247, 244, 238, 0.88);
}

.footer {
  background: #1c2621;
  color: #d5ddd6;
  padding: 36px 0 42px;
}

.footer-grid {
  display: flex;
  justify-content: space-between;
  gap: 28px;
}

.footer-brand {
  color: white;
  font-family: Fraunces, Georgia, serif;
  font-size: 1.25rem;
  font-weight: 680;
}

.disclaimer {
  max-width: 68ch;
  margin-top: 8px;
  font-size: 0.9rem;
  color: #aeb8b1;
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 8px;
  align-items: flex-end;
  font-weight: 650;
}

.footer a {
  color: #f0d48a;
}

.toast {
  position: fixed;
  left: 50%;
  bottom: 22px;
  transform: translateX(-50%) translateY(12px);
  background: var(--ink);
  color: var(--cream);
  padding: 10px 16px;
  border-radius: 999px;
  opacity: 0;
  pointer-events: none;
  transition: 0.2s ease;
  font-weight: 650;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

:focus-visible {
  outline: 3px solid #e2b03a;
  outline-offset: 3px;
}

::selection {
  background: #f0d48a;
  color: var(--ink);
}

@media (max-width: 860px) {
  .nav-toggle {
    display: inline-block;
    margin-left: auto;
  }

  .nav-cta {
    display: none;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: calc(var(--header) - 8px);
    left: 20px;
    right: 20px;
    flex-direction: column;
    align-items: flex-start;
    gap: 4px;
    padding: 12px;
    background: var(--paper);
    border-radius: 18px;
    box-shadow: var(--shadow);
  }

  .nav-links.open {
    display: flex;
  }

  .nav-links a {
    width: 100%;
    padding: 10px 8px;
  }

  .porch {
    margin-top: -36px;
    padding: 24px 18px 20px;
    border-width: 6px;
  }

  .story-grid,
  .post-grid,
  .footer-grid {
    grid-template-columns: 1fr;
  }

  .footer-grid {
    display: grid;
  }

  .footer-links {
    align-items: flex-start;
  }

  .facts,
  .post-meta,
  .network {
    grid-template-columns: 1fr 1fr;
  }

  .section {
    padding: 64px 0;
  }
}

@media (max-width: 560px) {
  .mat {
    grid-template-columns: 1fr;
    text-align: left;
  }

  .facts,
  .post-meta,
  .network {
    grid-template-columns: 1fr;
  }

  .ticker {
    display: none;
  }

  h1 {
    font-size: 2.35rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .marquee-track {
    animation: none;
  }

  .toast {
    transition: none;
  }
}
