/* Silt Strider
   Ash, bone and volcanic amber. One stylesheet, no build step, no external
   requests, no JavaScript. Shared by every page. */

:root {
  --bg:          #17120e;
  --bg-alt:      #1b1510;
  --surface:     #221a14;
  --surface-2:   #2a2018;

  --line:        rgba(212, 186, 148, 0.14);
  --line-strong: rgba(212, 186, 148, 0.30);

  --text:        #e8dcc8;
  --text-dim:    #bfae96;
  --text-faint:  #8d7c69;

  --accent:      #d08b3c;
  --accent-lift: #e3a75a;
  --ember:       #c4622c;
  --live:        #8fae72;
  --warn:        #c9a227;

  --font-display: "Iowan Old Style", "Palatino Linotype", Palatino, Georgia,
                  "Times New Roman", serif;
  --font-sans: "Segoe UI Variable Text", "Segoe UI", system-ui, -apple-system,
               "Helvetica Neue", Arial, sans-serif;
  --font-mono: "Cascadia Mono", ui-monospace, "SFMono-Regular", Consolas,
               "Liberation Mono", monospace;

  --wrap: 1060px;
  --gutter: 20px;
  --radius: 10px;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 92px;
  -webkit-text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-sans);
  font-size: 17px;
  line-height: 1.68;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
}

h1, h2, h3, h4 {
  margin: 0;
  font-family: var(--font-display);
  font-weight: 600;
  line-height: 1.2;
  letter-spacing: -0.01em;
}

p { margin: 0 0 1em; }
p:last-child { margin-bottom: 0; }
a { color: inherit; }

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: 3px;
}

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.skip {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  background: var(--accent);
  color: #1a1109;
  padding: 10px 16px;
  font-weight: 600;
  text-decoration: none;
}
.skip:focus { left: 12px; top: 12px; }

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

.site-head {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(23, 18, 14, 0.82);
  backdrop-filter: saturate(130%) blur(12px);
  border-bottom: 1px solid var(--line);
}

.head-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  min-height: 66px;
  flex-wrap: wrap;
}

.brand {
  display: inline-flex;
  align-items: baseline;
  gap: 10px;
  text-decoration: none;
  color: var(--text);
  font-family: var(--font-display);
}
.brand-name {
  font-size: 1.12rem;
  letter-spacing: 0.04em;
  font-weight: 600;
}
.brand-sub {
  font-family: var(--font-mono);
  font-size: 0.62rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.nav {
  display: flex;
  align-items: center;
  gap: 2px;
  flex-wrap: wrap;
}
.nav a {
  padding: 7px 11px;
  border-radius: 6px;
  font-size: 0.9rem;
  color: var(--text-dim);
  text-decoration: none;
  transition: color 0.18s ease, background-color 0.18s ease;
}
.nav a:hover { color: var(--text); background: rgba(208, 139, 60, 0.10); }
.nav a[aria-current="page"] {
  color: var(--accent);
  background: rgba(208, 139, 60, 0.09);
}

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

.hero {
  position: relative;
  padding: clamp(68px, 12vw, 128px) 0 clamp(56px, 9vw, 96px);
  border-bottom: 1px solid var(--line);
  overflow: hidden;
}
.hero::before {
  content: "";
  position: absolute;
  inset: -50% -10% auto -10%;
  height: 140%;
  background:
    radial-gradient(55% 50% at 20% 16%, rgba(208, 139, 60, 0.15), transparent 70%),
    radial-gradient(45% 45% at 82% 4%, rgba(196, 98, 44, 0.11), transparent 72%);
  pointer-events: none;
}
.hero-inner { position: relative; }

.page-head {
  padding: clamp(48px, 8vw, 84px) 0 clamp(28px, 4vw, 44px);
  border-bottom: 1px solid var(--line);
}

.eyebrow {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.24em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: 18px;
}
.eyebrow::before {
  content: "";
  display: inline-block;
  width: 24px;
  height: 1px;
  background: var(--accent);
  vertical-align: middle;
  margin-right: 11px;
  opacity: 0.75;
}

/* text-wrap: balance evens the lines out so no heading strands its last word.
   Browsers without it fall back to wrapping at the measure, which is still fine. */
h1 {
  font-size: clamp(2rem, 5.6vw, 3.4rem);
  max-width: 26ch;
  text-wrap: balance;
}
.hero h1 { margin-bottom: 22px; }
.page-head h1 { margin-bottom: 14px; }

.lede {
  font-size: clamp(1.02rem, 2.1vw, 1.16rem);
  color: var(--text-dim);
  max-width: 64ch;
}
.hero .lede { margin-bottom: 32px; }

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

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 21px;
  border-radius: 999px;
  border: 1px solid var(--line-strong);
  background: transparent;
  color: var(--text);
  font-size: 0.93rem;
  font-weight: 500;
  text-decoration: none;
  transition: border-color 0.18s ease, background-color 0.18s ease,
              transform 0.18s ease;
}
.btn:hover {
  border-color: var(--accent);
  background: rgba(208, 139, 60, 0.10);
  transform: translateY(-1px);
}
.btn-primary {
  background: var(--accent);
  border-color: var(--accent);
  color: #1a1109;
  font-weight: 600;
}
.btn-primary:hover { background: var(--accent-lift); border-color: var(--accent-lift); }

/* ---------- sections ---------- */

.section { padding: clamp(56px, 9vw, 96px) 0; }
.section-alt { background: var(--bg-alt); border-block: 1px solid var(--line); }
.section-head { margin-bottom: clamp(32px, 5vw, 48px); }
.section-head h2 { font-size: clamp(1.5rem, 3.4vw, 2.05rem); margin-bottom: 10px; }
.section-note { color: var(--text-faint); font-size: 0.97rem; }

.prose { max-width: 68ch; }
.prose h2 {
  font-size: clamp(1.35rem, 3vw, 1.7rem);
  margin: 2.2em 0 0.6em;
}
.prose h2:first-child { margin-top: 0; }
.prose h3 {
  font-size: 1.1rem;
  margin: 1.8em 0 0.4em;
  color: var(--text);
}
.prose ul, .prose ol { padding-left: 1.3em; margin: 0 0 1em; }
.prose li { margin-bottom: 0.45em; }
.prose li::marker { color: var(--text-faint); }

/* Numbered rule lists: hanging amber numerals, hairline between each. */
.rules {
  list-style: none;
  counter-reset: rule;
  margin: 0 0 1.8em;
  padding: 0;
}
.rules > li {
  counter-increment: rule;
  position: relative;
  padding: 15px 0 15px 48px;
  border-top: 1px solid var(--line);
  margin: 0;
}
.rules > li:first-child { border-top: 0; padding-top: 4px; }
.rules > li::before {
  content: counter(rule);
  position: absolute;
  left: 0;
  top: 17px;
  width: 30px;
  text-align: right;
  font-family: var(--font-mono);
  font-size: 0.82rem;
  color: var(--accent);
}
.rules > li:first-child::before { top: 6px; }

code {
  font-family: var(--font-mono);
  font-size: 0.88em;
  background: var(--surface-2);
  border: 1px solid var(--line);
  border-radius: 4px;
  padding: 1px 6px;
  color: var(--text);
}

.link {
  color: var(--accent);
  text-decoration: none;
  border-bottom: 1px solid rgba(208, 139, 60, 0.35);
  transition: color 0.18s ease, border-color 0.18s ease;
}
.link:hover { color: var(--accent-lift); border-bottom-color: currentColor; }

/* ---------- feature grid ---------- */

.features {
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
  list-style: none;
  margin: 0;
  padding: 0;
}
.feature {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 24px;
}
.feature h3 {
  font-size: 1.12rem;
  margin-bottom: 8px;
}
.feature p { color: var(--text-dim); font-size: 0.96rem; margin: 0; }

/* ---------- video gallery ----------
   One large newest video plus three compact rows, on a CSS grid that ties the
   bottom edges together however the titles wrap. No script, no scroller, no
   clipped card hanging off the viewport. The grid folds to a single column on
   a phone. Thumbnails are self-hosted, so nothing loads from YouTube until a
   click, and letterbox bars are trimmed off them at build time. */

.videos-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
}
.videos-head > div { flex: 1 1 320px; min-width: 0; }
.videos-head .eyebrow { margin-bottom: 12px; }
.videos-head .section-note { margin: 0; max-width: 60ch; }
.videos-more { flex: none; }

/* The gallery sits on its own recessed panel, so the four cards read as one
   block rather than as loose rectangles floating on the page. */
.videos {
  display: grid;
  gap: 12px;
  list-style: none;
  margin: 0;
  padding: 12px;
  background: var(--bg-alt);
  border: 1px solid var(--line);
  border-radius: calc(var(--radius) + 4px);
}

.video { min-width: 0; }

.video-link {
  position: relative;
  display: grid;
  grid-template-columns: 110px minmax(0, 1fr);
  align-items: center;
  gap: 14px;
  height: 100%;
  padding: 10px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  text-decoration: none;
  color: var(--text);
  transition: border-color 0.18s ease, background-color 0.18s ease,
              transform 0.18s ease;
}
.video-link:hover {
  border-color: var(--line-strong);
  background: var(--surface-2);
  transform: translateY(-2px);
}
/* The card is the target, so the ring follows the card, not a text box. */
.video-link:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: var(--radius);
}

/* The image sits in its own clipped box, so a thumbnail of any shape fills a
   clean rectangle instead of leaving bars inside the card. */
.video-frame {
  position: relative;
  display: block;
  overflow: hidden;
  aspect-ratio: 16 / 9;
  border-radius: calc(var(--radius) - 5px);
  background: var(--bg-alt);
}
.video-thumb {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.video-link:hover .video-thumb { transform: scale(1.03); }

/* Play glyph: a disc and a triangle, both drawn in CSS. Nothing to download. */
.video-play {
  position: absolute;
  left: 50%;
  top: 50%;
  width: 30px;
  height: 30px;
  margin: -15px 0 0 -15px;
  border: 1px solid var(--line-strong);
  border-radius: 50%;
  background: rgba(23, 18, 14, 0.62);
  transition: background-color 0.18s ease, border-color 0.18s ease;
}
.video-play::after {
  content: "";
  position: absolute;
  left: 52%;
  top: 50%;
  width: 9px;
  height: 11px;
  margin: -5.5px 0 0 -4.5px;
  background: var(--text);
  clip-path: polygon(0 0, 100% 50%, 0 100%);
  transition: background-color 0.18s ease;
}
.video-link:hover .video-play {
  background: var(--accent);
  border-color: var(--accent);
}
.video-link:hover .video-play::after { background: #1a1109; }

.video-body {
  display: block;
  min-width: 0;
  padding-right: 6px;
}

.video-title {
  display: -webkit-box;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 4;
  line-clamp: 4;
  overflow: hidden;
  font-family: var(--font-display);
  font-size: 1rem;
  line-height: 1.32;
}

.video-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 7px;
  font-family: var(--font-mono);
  font-size: 0.64rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--text-faint);
}
.video-flag { color: var(--accent); }

/* ---- the lead card ----
   On a phone it is simply a bigger card: image on top, title under it, where a
   scrim would eat half a short thumbnail. From 560px up the title moves onto
   the image, under a gradient, which is where the layout earns its hierarchy. */

.video-lead .video-link { display: block; }
.video-lead .video-play {
  width: 46px;
  height: 46px;
  margin: -23px 0 0 -23px;
  z-index: 1;
}
.video-lead .video-play::after {
  width: 13px;
  height: 15px;
  margin: -7px 0 0 -5px;
}
.video-lead .video-body { padding: 13px 6px 5px; }
.video-lead .video-title {
  font-size: clamp(1.08rem, 2.4vw, 1.42rem);
  text-wrap: balance;
}
.video-lead .video-meta { margin-bottom: 8px; }

@media (min-width: 560px) {
  .video-link { grid-template-columns: 158px minmax(0, 1fr); gap: 18px; }
  .video-title { font-size: 1.05rem; -webkit-line-clamp: 3; line-clamp: 3; }

  .video-lead .video-link { padding: 0; overflow: hidden; }
  .video-lead .video-frame { height: 100%; border-radius: 0; }
  .video-lead .video-frame::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(14, 10, 7, 0.94) 0%,
                rgba(14, 10, 7, 0.55) 34%, rgba(14, 10, 7, 0) 62%);
  }
  .video-lead .video-play {
    width: 58px;
    height: 58px;
    margin: -29px 0 0 -29px;
    top: 45%;
  }
  .video-lead .video-play::after {
    width: 16px;
    height: 19px;
    margin: -9px 0 0 -7px;
  }
  .video-lead .video-body {
    position: absolute;
    inset-inline: 0;
    bottom: 0;
    padding: 22px clamp(18px, 3vw, 26px) clamp(17px, 2.6vw, 23px);
  }
  .video-lead .video-title { -webkit-line-clamp: 2; line-clamp: 2; }
}

@media (min-width: 880px) {
  .videos {
    grid-template-columns: minmax(0, 1.72fr) minmax(0, 1fr);
    grid-auto-rows: 1fr;
  }
  .video-lead {
    grid-column: 1;
    grid-row: 1 / span 3;
  }
  .video-lead .video-frame { aspect-ratio: auto; }
  .video-link { grid-template-columns: 134px minmax(0, 1fr); gap: 16px; }
}

@media (prefers-reduced-motion: reduce) {
  .video-link, .video-thumb { transition: none; }
  .video-link:hover { transform: none; }
  .video-link:hover .video-thumb { transform: none; }
}

/* ---------- stat strip ---------- */

.stats {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 1px;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
  list-style: none;
  margin: 0;
  padding: 0;
}
.stats li { background: var(--bg-alt); padding: 20px 22px; }
.stat-value {
  display: block;
  font-family: var(--font-display);
  font-size: 1.7rem;
  color: var(--text);
  line-height: 1.1;
}
.stat-label {
  display: block;
  margin-top: 5px;
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.17em;
  text-transform: uppercase;
  color: var(--text-faint);
}

/* ---------- steps ---------- */

.steps { list-style: none; margin: 0; padding: 0; counter-reset: step; }
.steps > li {
  counter-increment: step;
  position: relative;
  padding: 0 0 30px 56px;
  border-left: 1px solid var(--line);
  margin-left: 15px;
}
.steps > li:last-child { border-left-color: transparent; padding-bottom: 0; }
.steps > li::before {
  content: counter(step);
  position: absolute;
  left: -16px;
  top: -2px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--surface);
  border: 1px solid var(--line-strong);
  color: var(--accent);
  font-family: var(--font-mono);
  font-size: 0.82rem;
  display: grid;
  place-items: center;
}
.steps h3 { font-size: 1.1rem; margin-bottom: 6px; }
.steps p { color: var(--text-dim); font-size: 0.96rem; }

/* ---------- callouts ---------- */

.note {
  border-left: 3px solid var(--accent);
  background: var(--surface);
  border-radius: 0 var(--radius) var(--radius) 0;
  padding: 16px 20px;
  margin: 1.6em 0;
  font-size: 0.96rem;
  color: var(--text-dim);
}
.note strong { color: var(--text); }
.note-warn { border-left-color: var(--warn); }

/* ---------- address block ---------- */

.address {
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 8px 16px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin: 1.4em 0;
}
.address dt {
  font-family: var(--font-mono);
  font-size: 0.66rem;
  letter-spacing: 0.17em;
  text-transform: uppercase;
  color: var(--text-faint);
}
.address dd {
  margin: 0;
  font-family: var(--font-mono);
  font-size: 1rem;
  color: var(--accent);
  word-break: break-all;
}

/* ---------- mod list ---------- */

.tier { margin-bottom: 26px; }
.tier > summary {
  cursor: pointer;
  list-style: none;
  padding: 18px 22px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  font-family: var(--font-display);
  font-size: 1.2rem;
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.tier > summary::-webkit-details-marker { display: none; }
.tier > summary:hover { border-color: var(--line-strong); }
.tier[open] > summary { border-radius: var(--radius) var(--radius) 0 0; }
.tier-count {
  font-family: var(--font-mono);
  font-size: 0.7rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--text-faint);
}
.tier > summary::after {
  content: "Show";
  font-family: var(--font-mono);
  font-size: 0.68rem;
  letter-spacing: 0.15em;
  text-transform: uppercase;
  color: var(--accent);
}
.tier[open] > summary::after { content: "Hide"; }

.modlist {
  list-style: none;
  margin: 0;
  padding: 0;
  border: 1px solid var(--line);
  border-top: 0;
  border-radius: 0 0 var(--radius) var(--radius);
}
.modlist li {
  padding: 13px 22px;
  border-top: 1px solid var(--line);
  display: flex;
  flex-wrap: wrap;
  align-items: baseline;
  gap: 4px 12px;
}
.modlist li:first-child { border-top: 0; }
.mod-name { font-weight: 500; }
.mod-by { color: var(--text-faint); font-size: 0.88rem; }
.mod-link { margin-left: auto; font-size: 0.84rem; }

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

.site-foot {
  border-top: 1px solid var(--line);
  background: var(--bg-alt);
  padding: 34px 0 46px;
}
.foot-inner {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 26px;
  align-items: baseline;
  justify-content: space-between;
}
.foot-brand {
  margin: 0;
  font-family: var(--font-display);
  letter-spacing: 0.05em;
  color: var(--text-dim);
}
.foot-legal { margin: 0; font-size: 0.82rem; color: var(--text-faint); max-width: 62ch; }
.foot-nav { display: flex; gap: 14px; flex-wrap: wrap; font-size: 0.86rem; }
.foot-nav a { color: var(--text-faint); text-decoration: none; }
.foot-nav a:hover { color: var(--text-dim); }

/* ---------- larger screens ---------- */

@media (min-width: 700px) {
  :root { --gutter: 30px; }
  .features { grid-template-columns: 1fr 1fr; }
  .stats { grid-template-columns: repeat(4, 1fr); }
}

@media (min-width: 900px) {
  .features-3 { grid-template-columns: repeat(3, 1fr); }
}

@media (max-width: 560px) {
  :root { --gutter: 16px; }
  .head-inner { min-height: 58px; padding-block: 8px; }
  .nav a { padding: 6px 8px; font-size: 0.82rem; }
  .brand-name { font-size: 1rem; }
  .steps > li { padding-left: 44px; }
  .modlist li { padding: 12px 16px; }
  .mod-link { margin-left: 0; flex-basis: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    transition-duration: 0.001ms !important;
  }
}
