:root {
  color-scheme: dark;
  --bg: #050403;
  --panel: #120d0b;
  --panel-2: #1d1210;
  --text: #f5ece1;
  --muted: #b99f78;
  --line: #3a2119;
  --accent: #c91f1f;
  --accent-2: #c99038;
  --warn: #e4b84e;
  --code: #090604;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at top left, rgba(201, 31, 31, .18), transparent 28rem),
    radial-gradient(circle at bottom right, rgba(201, 144, 56, .08), transparent 34rem),
    var(--bg);
  color: var(--text);
}

a { color: var(--accent-2); text-decoration: none; }
a:hover { color: var(--accent); }

.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: 19rem;
  padding: 1rem;
  overflow: auto;
  border-right: 1px solid var(--line);
  background: rgba(5, 4, 3, .95);
  backdrop-filter: blur(12px);
}

.brand {
  display: flex;
  align-items: center;
  gap: .75rem;
  min-height: 2.75rem;
  color: var(--text);
  font-weight: 800;
}

.gallery-shortcut {
  display: block;
  margin-top: .75rem;
  padding: .6rem .7rem;
  border: 1px solid rgba(201, 144, 56, .3);
  border-radius: 6px;
  color: var(--text);
  background: rgba(201, 31, 31, .16);
  font-size: .92rem;
  font-weight: 700;
}
.gallery-shortcut:hover { background: rgba(201, 144, 56, .14); }

.brand-mark {
  display: grid;
  place-items: center;
  width: 2.25rem;
  height: 2.25rem;
  border: 1px solid rgba(201, 31, 31, .65);
  border-radius: 6px;
  color: var(--accent);
  background: linear-gradient(135deg, rgba(201, 31, 31, .18), rgba(201, 144, 56, .12));
  letter-spacing: .04em;
}

.search {
  display: block;
  margin: 1rem 0 1.25rem;
  color: var(--muted);
  font-size: .8rem;
  text-transform: uppercase;
}

.search input {
  width: 100%;
  margin-top: .4rem;
  padding: .7rem .8rem;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--panel);
  color: var(--text);
}

.nav-group { margin: 0 0 1.25rem; }
.nav-group h2 {
  margin: 0 0 .4rem;
  color: var(--muted);
  font-size: .76rem;
  font-weight: 700;
  text-transform: uppercase;
}

.nav-link {
  display: block;
  padding: .45rem .55rem;
  border-radius: 6px;
  color: #cfdee3;
  font-size: .94rem;
}
.nav-link:hover, .nav-link.active {
  background: var(--panel-2);
  color: var(--text);
}
.nav-link.active { box-shadow: inset 3px 0 0 var(--accent); }

.main {
  margin-left: 19rem;
  padding: 2rem clamp(1.25rem, 2.5vw, 3rem) 4rem;
}

.hero {
  min-height: 27rem;
  display: grid;
  align-content: center;
  max-width: 62rem;
}

.home-hero {
  position: relative;
  isolation: isolate;
  min-height: min(78vh, 52rem);
  max-width: none;
  margin: -2rem calc(clamp(1.25rem, 2.5vw, 3rem) * -1) 2rem;
  padding: clamp(2rem, 5vw, 5rem);
  align-content: end;
  overflow: hidden;
  border-bottom: 1px solid rgba(201, 144, 56, .3);
  background:
    linear-gradient(90deg, rgba(5, 4, 3, .96) 0%, rgba(5, 4, 3, .82) 34%, rgba(5, 4, 3, .25) 70%, rgba(5, 4, 3, .85) 100%),
    linear-gradient(0deg, rgba(5, 4, 3, .98) 0%, rgba(5, 4, 3, .22) 42%, rgba(5, 4, 3, .72) 100%),
    url("slayer-noodles-theme.png") center right / min(72rem, 82vw) auto no-repeat,
    #050403;
}
.home-hero::before {
  content: "";
  position: absolute;
  inset: 1rem;
  z-index: -1;
  border: 1px solid rgba(201, 144, 56, .38);
  pointer-events: none;
}
.home-hero::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  background-image:
    repeating-linear-gradient(0deg, rgba(245, 236, 225, .035) 0 1px, transparent 1px 4px),
    radial-gradient(circle at 72% 42%, rgba(201, 31, 31, .2), transparent 22rem);
  mix-blend-mode: screen;
  pointer-events: none;
}
.hero-copy {
  max-width: 42rem;
}
.home-hero h1 {
  max-width: 44rem;
  margin: .25rem 0 1rem;
  color: #f7eee3;
  font-size: clamp(3rem, 8vw, 7.2rem);
  line-height: .88;
  text-transform: uppercase;
  letter-spacing: .02em;
  text-shadow: .06em .06em 0 rgba(0, 0, 0, .75), 0 0 1.5rem rgba(201, 31, 31, .28);
}
.home-hero .lede {
  max-width: 40rem;
  color: #d5bea0;
  font-size: clamp(1rem, 1.5vw, 1.2rem);
}
.home-hero .hero-actions {
  margin-top: 1.5rem;
}

.eyebrow {
  color: var(--accent-2);
  font-size: .8rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .08em;
}

h1, h2, h3, h4 { line-height: 1.15; }
h1 { margin: .2rem 0 1rem; font-size: clamp(2.25rem, 4vw, 3.6rem); }
.doc-header h1 {
  max-width: 72rem;
  font-size: clamp(2rem, 3.1vw, 3.15rem);
  text-wrap: balance;
}
.lede, .doc-header p:last-child {
  max-width: 72rem;
  color: var(--muted);
  font-size: 1.12rem;
  line-height: 1.65;
}

.hero-actions { display: flex; flex-wrap: wrap; gap: .75rem; margin-top: 1.25rem; }
.button {
  display: inline-flex;
  align-items: center;
  min-height: 2.6rem;
  padding: 0 1rem;
  border: 1px solid var(--line);
  border-radius: 6px;
  color: var(--text);
  background: rgba(18, 13, 11, .88);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .04em;
}
.button:hover {
  border-color: rgba(201, 144, 56, .62);
  color: var(--warn);
}
.button.primary {
  border-color: rgba(201, 144, 56, .75);
  color: #fff2dc;
  background: linear-gradient(135deg, #8d1414, #d12b24);
}

.start-here {
  max-width: 74rem;
  margin: 2rem 0;
}
.start-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(15rem, 1fr));
  gap: 1rem;
}
.start-card {
  position: relative;
  display: block;
  min-height: 12rem;
  padding: 1.1rem;
  overflow: hidden;
  border: 1px solid rgba(201, 144, 56, .36);
  border-radius: 8px;
  background:
    linear-gradient(135deg, rgba(141, 20, 20, .26), rgba(18, 13, 11, .92) 48%),
    rgba(18, 13, 11, .9);
  color: var(--text);
}
.start-card::after {
  content: "";
  position: absolute;
  inset: .55rem;
  border: 1px solid rgba(201, 144, 56, .18);
  pointer-events: none;
}
.start-card:hover {
  transform: translateY(-1px);
  border-color: rgba(201, 144, 56, .78);
}
.start-card span {
  color: var(--accent-2);
  font-size: .78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .08em;
}
.start-card strong {
  display: block;
  margin: .6rem 0;
  font-size: 1.45rem;
}
.start-card p {
  color: #d5bea0;
  line-height: 1.5;
}

.stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(9rem, 1fr));
  gap: .75rem;
  max-width: 62rem;
  margin-bottom: 2rem;
}
.stats div, .doc-card {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(18, 13, 11, .86);
}
.stats div { padding: 1rem; }
.stats strong { display: block; font-size: 1.9rem; }
.stats span, .doc-card span { color: var(--muted); font-size: .82rem; text-transform: uppercase; }

.panel { max-width: 74rem; }
.visual-panel { margin-top: 2rem; }
.section-title { display: flex; align-items: end; justify-content: space-between; gap: 1rem; }
.section-title h2 { margin-bottom: .4rem; }
.section-title span { color: var(--muted); }
.section-title a { font-weight: 700; }
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(17rem, 1fr));
  gap: 1rem;
}
.doc-card {
  display: block;
  min-height: 12rem;
  padding: 1rem;
  color: var(--text);
}
.doc-card strong { display: block; margin: .5rem 0; font-size: 1.2rem; }
.doc-card p { color: var(--muted); line-height: 1.5; }

.doc {
  width: min(100%, 110rem);
  margin: 0 auto;
}
.doc-header {
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--line);
}
.doc-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) clamp(14rem, 18vw, 18rem);
  gap: clamp(1.5rem, 3vw, 3rem);
  align-items: start;
}
.doc-content {
  width: min(100%, 82rem);
  min-width: 0;
  padding-top: 1.25rem;
}
.doc-content h2, .doc-content h3 {
  margin-top: 2rem;
}
.doc-content h2 { font-size: clamp(1.55rem, 2vw, 2.15rem); }
.doc-content h3 { font-size: clamp(1.2rem, 1.4vw, 1.45rem); }
.doc-content p, .doc-content li, .doc-content blockquote {
  color: #d7e4e8;
  line-height: 1.72;
}
.doc-content ul, .doc-content ol { padding-left: 1.35rem; }
.doc-content li { margin: .3rem 0; }
.anchor {
  margin-left: -1.2rem;
  padding-right: .35rem;
  opacity: 0;
  color: var(--accent);
}
h1:hover .anchor, h2:hover .anchor, h3:hover .anchor, h4:hover .anchor { opacity: 1; }

blockquote {
  margin: 1rem 0;
  padding: .8rem 1rem;
  border-left: 3px solid var(--accent);
  border-radius: 0 6px 6px 0;
  background: rgba(201, 31, 31, .08);
}

pre, code {
  border-radius: 5px;
  background: var(--code);
  color: #e6edf3;
  font-family: "Cascadia Code", Consolas, monospace;
}
code { padding: .14rem .32rem; font-size: .9em; }
pre {
  overflow: auto;
  padding: 1rem;
  border: 1px solid var(--line);
}
pre code { padding: 0; background: transparent; }

table {
  display: block;
  width: 100%;
  overflow: auto;
  border-collapse: collapse;
  margin: 1rem 0;
}
td, th {
  padding: .65rem .75rem;
  border: 1px solid var(--line);
  vertical-align: top;
}
th { color: var(--text); background: var(--panel-2); text-align: left; }
img {
  max-width: 100%;
  height: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
}

.gallery-header {
  max-width: 74rem;
  margin-bottom: 1.5rem;
}
.gallery-filter {
  display: block;
  max-width: 34rem;
  margin-top: 1.25rem;
  color: var(--muted);
  font-size: .8rem;
  font-weight: 700;
  text-transform: uppercase;
}
.gallery-filter input {
  width: 100%;
  margin-top: .45rem;
  padding: .75rem .85rem;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--panel);
  color: var(--text);
}
.gallery-clear {
  margin-top: .75rem;
  min-height: 2.25rem;
  padding: 0 .85rem;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--panel);
  color: var(--text);
  cursor: pointer;
}
.gallery-clear:hover {
  border-color: rgba(201, 144, 56, .58);
  color: var(--warn);
}
.gallery-count {
  margin: .75rem 0 0;
  color: var(--muted);
  font-size: .92rem;
}
.gallery-empty {
  max-width: 42rem;
  margin: .75rem 0 0;
  padding: .75rem .9rem;
  border: 1px solid rgba(255, 209, 102, .32);
  border-radius: 6px;
  background: rgba(255, 209, 102, .08);
  color: #d9c891;
}
.shot-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(15rem, 1fr));
  gap: 1rem;
}
.shot-grid.compact {
  grid-template-columns: repeat(auto-fit, minmax(13rem, 1fr));
}
.shot-card {
  display: grid;
  gap: .55rem;
  align-content: start;
  min-width: 0;
  padding: .6rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(16, 25, 34, .82);
  color: var(--text);
}
.shot-card img {
  width: 100%;
  aspect-ratio: 16 / 9;
  object-fit: cover;
  background: var(--code);
}
.shot-card span {
  color: var(--muted);
  font-size: .76rem;
}
.shot-card strong {
  overflow-wrap: anywhere;
  font-size: .9rem;
  line-height: 1.25;
}
.shot-card.compact { padding: .5rem; }
.related-shots {
  margin: 1.25rem 0 2rem;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(201, 31, 31, .06);
}
.related-shots h2 {
  margin: 0 0 .9rem;
  font-size: 1.1rem;
}
.opens-lightbox {
  cursor: zoom-in;
}
body.lightbox-open {
  overflow: hidden;
}
.lightbox {
  position: fixed;
  inset: 0;
  z-index: 100;
  display: grid;
  grid-template-columns: minmax(3rem, 1fr) minmax(0, 82rem) minmax(3rem, 1fr);
  align-items: center;
  gap: 1rem;
  padding: 1.25rem;
  background:
    radial-gradient(circle at 50% 15%, rgba(201, 31, 31, .24), transparent 34rem),
    rgba(3, 2, 1, .92);
  backdrop-filter: blur(8px);
}
.lightbox[hidden] {
  display: none;
}
.lightbox figure {
  min-width: 0;
  margin: 0;
}
.lightbox img {
  display: block;
  max-width: 100%;
  max-height: calc(100vh - 8rem);
  margin: 0 auto;
  border: 1px solid rgba(201, 144, 56, .48);
  border-radius: 8px;
  box-shadow: 0 1.5rem 5rem rgba(0, 0, 0, .72);
  object-fit: contain;
}
.lightbox figcaption {
  max-width: 70rem;
  margin: .8rem auto 0;
  color: var(--muted);
  text-align: center;
  overflow-wrap: anywhere;
}
.lightbox-close,
.lightbox-nav {
  border: 1px solid rgba(201, 144, 56, .42);
  background: rgba(18, 13, 11, .82);
  color: var(--text);
  cursor: pointer;
}
.lightbox-close:hover,
.lightbox-nav:hover {
  border-color: var(--accent-2);
  color: var(--warn);
}
.lightbox-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 2.75rem;
  height: 2.75rem;
  border-radius: 999px;
  font-size: 2rem;
  line-height: 1;
}
.lightbox-nav {
  width: 3rem;
  min-height: 5rem;
  border-radius: 8px;
  font-size: 2.4rem;
}
.lightbox-prev {
  justify-self: end;
}
.lightbox-next {
  justify-self: start;
}

.toc {
  position: sticky;
  top: 1rem;
  margin-top: 1.25rem;
  padding-left: 1rem;
  border-left: 1px solid var(--line);
}
.toc h2 {
  margin: 0 0 .7rem;
  color: var(--muted);
  font-size: .76rem;
  text-transform: uppercase;
}
.toc a {
  display: block;
  margin: .45rem 0;
  color: var(--muted);
  font-size: .9rem;
}
.toc .toc-l3 { padding-left: .75rem; font-size: .84rem; }

@media (max-width: 1200px) {
  .doc-layout { display: block; }
  .toc { display: none; }
  .doc-content { width: 100%; }
}

@media (max-width: 900px) {
  .sidebar {
    position: static;
    width: auto;
    max-height: 22rem;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }
  .main { margin-left: 0; padding-top: 1rem; }
  .lightbox {
    grid-template-columns: 1fr;
    grid-template-rows: 1fr auto;
    padding: 3.75rem .75rem .75rem;
  }
  .lightbox img {
    max-height: calc(100vh - 9rem);
  }
  .lightbox-nav {
    width: 5rem;
    min-height: 2.75rem;
    font-size: 2rem;
  }
  .lightbox-prev,
  .lightbox-next {
    justify-self: center;
  }
  .lightbox figure {
    grid-column: 1;
    grid-row: 1;
  }
  .lightbox-prev {
    grid-row: 2;
    margin-right: 5.5rem;
  }
  .lightbox-next {
    grid-row: 2;
    margin-left: 5.5rem;
    margin-top: -2.75rem;
  }
}