/* Field guide for 32x's Roblox tower defense. */
:root {
  color-scheme: dark;
  --bg: #101b1b;
  --surface: #182727;
  --ink: #f4f3e9;
  --muted: #b7c9c4;
  --line: #38504c;
  --gold: #ffc45e;
  --mint: #8fe5c5;
  --night: #0a1515;
  --raised: color-mix(in srgb,var(--mint) 15%,var(--surface));
  --shade: color-mix(in srgb,var(--night) 45%,transparent);
  --fade: color-mix(in srgb,var(--night) 88%,transparent);
  --radius: 14px;
  --space: clamp(18px,4vw,48px);
  --display: "Barlow Condensed","Arial Narrow","Franklin Gothic Medium",Arial,sans-serif;
  --body: Inter,"Segoe UI",Arial,sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  scroll-padding-top: 20px;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font: 16px/1.65 var(--body);
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--mint);
  text-decoration-thickness: 1px;
  text-underline-offset: 4px;
}

a:hover {
  color: var(--gold);
}

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

button,input,textarea,select {
  font: inherit;
}

button,a,select,input,textarea {
  touch-action: manipulation;
}

:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 4px;
}

button {
  cursor: pointer;
}

button:disabled {
  cursor: wait;
}

.wrap {
  width: min(1216px,100%);
  margin-inline: auto;
  padding-inline: var(--space);
}

h1,h2,h3,p,figure,dl {
  margin: 0;
}

h1,h2,h3,.foot-brand,.wordmark {
  font-family: var(--display);
  line-height: 1.07;
  letter-spacing: -.012em;
}

h2 {
  font-size: clamp(1.65rem,3.1vw,2.65rem);
  font-weight: 750;
}

h3 {
  font-size: 1.3rem;
}

p+p {
  margin-top: 1em;
}

.skip {
  position: absolute;
  top: -80px;
  left: 10px;
  z-index: 10;
  background: var(--ink);
  color: var(--night);
  padding: 10px;
}

.skip:focus {
  top: 5px;
}

.mast {
  background: var(--night);
  border-bottom: 1px solid var(--line);
}

.mast-row,.foot-row,.section-heading,.watch-meta,.actions,.wordmark,.site-nav,.foot-row nav {
  display: flex;
  align-items: center;
}

.mast-row,.foot-row,.section-heading,.watch-meta {
  justify-content: space-between;
  gap: 1rem;
}

.mast-row {
  min-height: 68px;
  position: relative;
}

.wordmark {
  color: var(--ink);
  text-decoration: none;
  gap: 11px;
  letter-spacing: .05em;
  font-weight: 800;
  font-size: 17px;
}

.wordmark b {
  display: block;
  color: var(--mint);
  font: 700 12px/1.5 var(--body);
  letter-spacing: .15em;
}

.sigil {
  display: grid;
  place-items: center;
  width: 39px;
  height: 39px;
  transform: skew(-9deg);
  border: 2px solid var(--gold);
  color: var(--gold);
  font: bold italic 31px/1 Arial;
}

.site-nav {
  gap: 26px;
}

.site-nav a,.foot-row nav a,.section-heading a {
  color: var(--muted);
  text-decoration: none;
  font-weight: 600;
  font-size: 14px;
  padding: 10px 0;
}

.site-nav a:hover,.site-nav a[aria-current],.section-heading a {
  color: var(--mint);
}

.nav-toggle {
  display: none;
}

.hero {
  background: radial-gradient(ellipse at 70% 20%,var(--raised) 0%,var(--surface) 50%,var(--bg) 100%);
  border-bottom: 1px solid var(--line);
}

.hero-grid {
  display: grid;
  grid-template-columns: .85fr 1.15fr;
  gap: clamp(25px,5vw,72px);
  align-items: center;
  padding-block: clamp(34px,5.3vw,72px) 38px;
}

.section-tag,.byline,.watch-meta,.metrics span,.metrics small,.contents {
  font-size: 13px;
  letter-spacing: .025em;
}

.section-tag {
  display: flex;
  align-items: center;
  gap: 9px;
  text-transform: uppercase;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: .15em;
  color: var(--mint);
}

.section-tag i {
  width: 17px;
  height: 3px;
  background: var(--mint);
}

.hero h1 {
  font-size: clamp(3.7rem,5.7vw,5.7rem);
  line-height: .99;
  letter-spacing: -.012em;
  font-weight: 700;
  margin: 18px 0;
}

.hero h1 em {
  color: var(--gold);
  font-style: italic;
}

.hero-copy>p {
  max-width: 39ch;
  color: var(--ink);
  font-size: clamp(16px,1.4vw,19px);
}

.actions {
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 24px;
}

.button,button:not(.watch-trigger):not(.copy-code) {
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 12px;
  min-height: 44px;
  padding: 9px 17px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--surface);
  color: var(--ink);
  font-weight: 700;
  text-decoration: none;
  transition: background .15s,transform .15s;
}

.button.primary {
  background: var(--gold);
  border-color: var(--gold);
  color: var(--night);
}

.button:hover,button:hover {
  transform: translateY(-1px);
}

.button.secondary {
  border-color: var(--line);
}

.button span {
  font-size: 18px;
}

.watch-card {
  overflow: hidden;
  border: 1px solid var(--line);
  background: var(--bg);
  border-radius: var(--radius);
  box-shadow: 0 20px 48px var(--shade);
}

.watch-stage {
  aspect-ratio: 16/9;
  position: relative;
  background: var(--night);
}

.watch-trigger {
  border: 0;
  padding: 0;
  background: transparent;
  color: white;
  width: 100%;
  height: 100%;
  position: relative;
  display: block;
}

.watch-trigger::after {
  content: "";
  position: absolute;
  inset: 30% 0 0;
  background: linear-gradient(transparent,var(--fade));
}

.watch-trigger img,.watch-stage iframe {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border: 0;
}

.play-disc,.watch-title {
  position: absolute;
  z-index: 1;
}

.play-disc {
  left: 50%;
  top: 48%;
  transform: translate(-50%,-50%);
  display: grid;
  place-items: center;
  padding-left: 4px;
  background: var(--gold);
  border: 3px solid var(--ink);
  border-radius: 50%;
  width: 61px;
  height: 61px;
  color: var(--night);
  font-size: 21px;
  box-shadow: 0 3px 25px var(--shade);
}

.watch-title {
  left: 19px;
  bottom: 13px;
  font: 700 clamp(16px,2vw,25px) var(--display);
}

.watch-meta {
  padding: 7px 17px;
  color: var(--muted);
}

.watch-meta a {
  padding: 4px 0;
}

.loading {
  position: absolute;
  inset: 0;
  display: grid;
  place-content: center;
  color: var(--gold);
  background: var(--surface);
}

.loading:before {
  content: "";
  margin: 0 auto 10px;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  border: 3px solid var(--line);
  border-top-color: var(--gold);
  animation: spin .7s linear infinite;
}

@keyframes spin {
  to {
    transform: rotate(1turn);
  }
}

.metrics {
  display: grid;
  grid-template-columns: repeat(4,1fr);
  border-top: 1px solid var(--line);
  padding: 22px 0 24px;
}

.metrics>div {
  display: flex;
  flex-flow: column;
  min-width: 0;
  padding-left: 22px;
  border-left: 1px solid var(--line);
}

.metrics>div:first-child {
  border: 0;
  padding: 0;
}

.metrics span {
  color: var(--mint);
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .12em;
}

.metrics strong {
  font: 750 clamp(26px,3vw,40px)/1.2 var(--display);
  font-variant-numeric: tabular-nums;
}

.metrics small,.byline,.watch-meta,.crumbs,.contents,.guide-tile small {
  color: var(--muted);
}

.browse {
  padding-block: clamp(32px,5vw,60px);
}

.section-heading {
  margin-bottom: 20px;
}

.guide-grid {
  display: grid;
  grid-template-columns: repeat(3,1fr);
  gap: 12px;
}

.guide-tile,.unit-row {
  color: var(--ink);
  text-decoration: none;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 10px;
  display: flex;
  gap: 14px;
  align-items: center;
  min-width: 0;
  transition: border-color .16s,background .16s;
}

.guide-tile {
  min-height: 94px;
  overflow: hidden;
  padding: 0 14px 0 0;
}

.guide-tile img {
  width: 78px;
  height: 90px;
  object-fit: cover;
  background: var(--surface);
}

.guide-tile strong {
  font: 700 22px var(--display);
}

.guide-tile small,.unit-row small {
  display: block;
  font-size: 12px;
  line-height: 1.4;
}

.guide-tile b,.unit-row b {
  margin-left: auto;
  color: var(--gold);
}

.guide-tile:hover,.unit-row:hover {
  border-color: var(--mint);
  background: var(--surface);
}

.reading-grid {
  display: grid;
  grid-template-columns: minmax(130px,195px) minmax(0,760px);
  gap: clamp(25px,6vw,90px);
  padding-bottom: 60px;
}

.contents {
  align-self: start;
  border-top: 2px solid var(--gold);
  padding-top: 13px;
}

.contents strong,.contents a {
  display: block;
  margin: 7px 0;
}

.contents a {
  color: var(--muted);
  padding: 5px 0;
  text-decoration: none;
}

.reading,.article-body,.prose,.roster {
  min-width: 0;
}

.prose {
  color: var(--ink);
}

.prose h2,.prose h3,.faq-section h2,.discussion h2,.article-body section>h2 {
  color: var(--ink);
  margin: 1.35em 0 .45em;
}

.prose>h2:first-child {
  margin-top: 0;
}

.prose p,.prose ul,.prose ol,.code-index p,.tier p {
  margin: 0 0 1.1em;
}

.prose li+li {
  margin-top: .38em;
}

.prose blockquote,.callout {
  margin: 20px 0;
  padding: 14px 18px;
  background: var(--surface);
  border-left: 3px solid var(--gold);
}

.prose blockquote p {
  margin: 0;
}

.faq {
  border-top: 1px solid var(--line);
  padding: 8px 0;
}

.faq summary {
  font-weight: 700;
  cursor: pointer;
  padding: 7px 2px;
}

.faq p {
  color: var(--muted);
  margin: 7px 0 14px;
}

.faq-links {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 20px;
  margin-bottom: 12px;
}

.discussion {
  margin: 36px 0;
}

.discussion form {
  margin-top: 22px;
  display: grid;
  gap: 13px;
}

.discussion form button {
  justify-self: start;
}

.discussion label,.filters label {
  display: grid;
  gap: 5px;
  font-size: 14px;
  color: var(--muted);
}

input,select,textarea {
  border: 1px solid var(--line);
  border-radius: 5px;
  color: var(--ink);
  background: var(--bg);
  padding: 9px 11px;
  min-width: 0;
}

.discussion textarea {
  resize: vertical;
}

.article-wrap {
  max-width: 1030px;
  padding-block: 20px 65px;
}

.crumbs {
  display: flex;
  gap: 10px;
  font-size: 13px;
  margin: 0 0 24px;
}

.crumbs a {
  padding: 3px 0;
}

.page-head {
  border-bottom: 1px solid var(--line);
  padding: 13px 0 25px;
  margin-bottom: 28px;
}

.page-head h1 {
  font-size: clamp(36px,5.8vw,66px);
  margin: 12px 0;
}

.lede {
  color: var(--muted);
  max-width: 68ch;
}

.byline {
  margin-top: 12px;
}

.unit-head {
  display: grid;
  grid-template-columns: 1fr minmax(100px,174px);
  align-items: center;
  gap: 20px;
}

.portrait {
  aspect-ratio: 1;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: repeating-linear-gradient(135deg,var(--raised),var(--raised) 11px,var(--surface) 11px,var(--surface) 12px);
  overflow: hidden;
}

.portrait img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.portrait-pending {
  display: grid;
  text-align: center;
  place-content: center;
  padding: 10px;
  height: 100%;
  color: var(--muted);
  font-size: 12px;
}

.article-body {
  max-width: 850px;
}

.stats-sheet dl {
  display: grid;
  grid-template-columns: repeat(2,minmax(0,1fr));
  margin: 13px 0 30px;
  border: 1px solid var(--line);
  border-radius: 8px;
  overflow: hidden;
}

.stats-sheet dl div {
  padding: 10px 15px;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
}

.stats-sheet dt,.unit-row small {
  color: var(--muted);
  font-size: 12px;
}

.stats-sheet dd {
  margin: 0;
  font-weight: 650;
}

.table-scroll {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  margin: 14px 0 28px;
  border: 1px solid var(--line);
  border-radius: 7px;
}

.table-scroll table {
  margin: 0;
}

.prose table,table {
  width: 100%;
  border-collapse: collapse;
  min-width: 640px;
  font-size: 14px;
  font-variant-numeric: tabular-nums;
}

th,td {
  text-align: left;
  vertical-align: top;
  padding: 10px 13px;
  border-bottom: 1px solid var(--line);
}

th {
  color: var(--mint);
  background: var(--surface);
  font-size: 12px;
}

tr:nth-child(even) td {
  background: var(--surface);
}

.copy-code {
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 4px;
  color: var(--gold);
  background: var(--night);
  font: 600 13px monospace;
}

.filters {
  display: flex;
  align-items: end;
  flex-wrap: wrap;
  gap: 14px;
  margin: 16px 0;
}

.filters output {
  padding: 8px;
  color: var(--muted);
}

.roster-list {
  display: grid;
  gap: 5px;
}

.unit-row {
  padding: 7px 13px;
  display: grid;
  grid-template-columns: 48px minmax(120px,1.8fr) 1fr 1fr 16px;
}

.unit-row img,.blank-thumb {
  width: 48px;
  height: 48px;
  object-fit: contain;
  border-radius: 6px;
  background: var(--surface);
}

.unit-row>span {
  font-size: 13px;
}

.no-results {
  padding: 20px;
}

.site-footer {
  background: var(--night);
  border-top: 1px solid var(--line);
  padding: 32px 0;
}

.foot-brand {
  font-weight: 700;
  text-decoration: none;
  color: var(--ink);
  font-size: 21px;
}

.foot-row p {
  color: var(--muted);
  font-size: 13px;
  margin-top: 8px;
}

.foot-row nav {
  gap: 16px;
  flex-wrap: wrap;
}

[hidden] {
  display: none!important;
}

button.nav-toggle:not(.watch-trigger) {
  display: none;
}

@media(max-width:850px) {
  .hero-grid {
    gap: 24px;
  }
  .guide-grid {
    grid-template-columns: repeat(2,1fr);
  }
  .site-nav {
    gap: 15px;
  }
  .reading-grid {
    grid-template-columns: minmax(0,1fr);
  }
  .contents {
    display: none;
  }
}

@media(max-width:680px) {
  .mast-row {
    min-height: 58px;
  }
  .hero-grid {
    grid-template-columns: 1fr;
    padding-top: 28px;
    gap: 22px;
  }
  .hero h1 {
    font-size: clamp(3rem,12vw,4.5rem);
    margin: 12px 0;
  }
  .hero h1 br {
    display: none;
  }
  .hero h1 br::after {
    content: " ";
  }
  .actions {
    margin-top: 18px;
  }
  .hero-copy>p {
    font-size: 16px;
  }
  .metrics {
    grid-template-columns: repeat(2,1fr);
    gap: 14px;
    padding: 18px 0;
  }
  .metrics>div:nth-child(3) {
    border: 0;
    padding: 0;
  }
  .guide-grid {
    grid-template-columns: 1fr;
  }
  .guide-tile {
    min-height: 68px;
  }
  .guide-tile img {
    height: 70px;
    width: 70px;
  }
  .section-heading {
    align-items: baseline;
  }
  .foot-row {
    align-items: start;
    flex-direction: column;
  }
  .unit-head {
    grid-template-columns: 1fr 100px;
    gap: 10px;
  }
  .unit-head h1 {
    font-size: clamp(29px,7.2vw,44px);
  }
  .unit-row {
    grid-template-columns: 40px minmax(0,1fr) auto 12px;
    gap: 2px 10px;
  }
  .unit-row img,.blank-thumb {
    width: 40px;
    height: 40px;
  }
  .unit-row>:first-child {
    grid-column: 1;
    grid-row: 1 / span 2;
  }
  .unit-row>strong {
    grid-column: 2;
    grid-row: 1 / span 2;
  }
  .unit-row>span:nth-child(3) {
    grid-column: 3;
    grid-row: 1;
  }
  .unit-row>span:nth-child(4) {
    grid-column: 3;
    grid-row: 2;
    color: var(--muted);
    font-size: 12px;
  }
  .unit-row>b {
    grid-column: 4;
    grid-row: 1 / span 2;
  }
  .site-nav {
    display: none;
    position: absolute;
    top: 100%;
    z-index: 3;
    left: 0;
    right: 0;
    background: var(--night);
    padding: 12px var(--space);
    border-bottom: 1px solid var(--line);
    flex-wrap: wrap;
  }
  .site-nav.is-open,button.nav-toggle:not(.watch-trigger) {
    display: flex;
  }
  .site-nav a {
    min-height: 44px;
  }
  .metrics small {
    font-size: 12px;
  }
  .page-head {
    padding-top: 0;
  }
  .filters label {
    flex: 1 1 120px;
    min-width: 0;
  }
  .filters input,.filters select {
    width: 100%;
  }
}

.release-summary {
  margin: 1.5rem 0;
  padding: 1.25rem 1.5rem;
  border: 1px solid var(--line);
  border-inline-start: 4px solid var(--gold);
  border-radius: var(--radius);
  background: var(--surface);
}
.release-summary h2 { margin: 0; }
.release-summary p { margin: .35rem 0 .75rem; color: var(--muted); }
.release-summary ul { margin: 0; padding-inline-start: 1.25rem; }
@media(prefers-reduced-motion:reduce) {
  *,*::before,*::after {
    scroll-behavior: auto!important;
    animation-duration: .001ms!important;
    transition: none!important;
  }
}
