:root {
  color-scheme: light;
  --bg-top: #e7cfa3;
  --bg-mid: #efe1c5;
  --bg-bottom: #f7f1e5;
  --wood: #6e4120;
  --wood-deep: #462311;
  --wood-soft: #946039;
  --brass: #cf9f56;
  --brass-soft: #ecd39d;
  --parchment: #f8ecd4;
  --parchment-deep: #f1dfbe;
  --paper: #fff7e9;
  --text: #24150d;
  --muted: #685444;
  --line: rgba(87, 54, 31, 0.16);
  --accent: #c4632d;
  --accent-deep: #6d3115;
  --accent-soft: #efc68d;
  --shadow: 0 24px 60px rgba(54, 31, 16, 0.16);
  --radius: 28px;
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  font-family: "Space Grotesk", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 50% -10%, rgba(246, 204, 124, 0.28), transparent 25%),
    linear-gradient(180deg, var(--bg-top) 0%, var(--bg-mid) 36%, var(--bg-bottom) 100%);
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    radial-gradient(180px 110px at 16% 8%, rgba(93, 57, 30, 0.08) 0 60%, transparent 61%),
    radial-gradient(180px 110px at 50% 8%, rgba(93, 57, 30, 0.06) 0 60%, transparent 61%),
    radial-gradient(180px 110px at 84% 8%, rgba(93, 57, 30, 0.08) 0 60%, transparent 61%),
    linear-gradient(180deg, rgba(67, 36, 19, 0.12), transparent 160px);
  background-repeat: no-repeat;
}

body::after {
  content: "";
  position: fixed;
  inset: 0;
  pointer-events: none;
  background:
    repeating-linear-gradient(
      90deg,
      rgba(87, 54, 31, 0.022) 0,
      rgba(87, 54, 31, 0.022) 2px,
      transparent 2px,
      transparent 120px
    ),
    radial-gradient(circle at center, transparent 42%, rgba(87, 54, 31, 0.045) 100%);
  opacity: 0.65;
}

.shell {
  width: min(100%, 1080px);
  margin: 0 auto;
  padding: 14px 14px 64px;
}

.hero-panel {
  display: grid;
  gap: 12px;
  margin-bottom: 14px;
}

.signboard {
  position: relative;
  padding: 18px 16px 16px;
  border: 1px solid rgba(64, 35, 18, 0.32);
  border-radius: 26px;
  background:
    linear-gradient(180deg, rgba(111, 65, 33, 0.97), rgba(70, 35, 17, 0.98));
  box-shadow:
    inset 0 0 0 2px rgba(207, 159, 86, 0.18),
    0 22px 38px rgba(55, 29, 15, 0.22);
}

.signboard::before {
  content: "";
  position: absolute;
  inset: 10px;
  border: 1px solid rgba(234, 206, 151, 0.18);
  border-radius: 18px;
  pointer-events: none;
}

.signboard-crest {
  display: inline-grid;
  place-items: center;
  width: 54px;
  height: 54px;
  margin-bottom: 12px;
  border: 1px solid rgba(240, 217, 173, 0.26);
  border-radius: 16px;
  background: radial-gradient(circle at 32% 28%, #d58d4b, #8a431e);
  box-shadow: inset 0 0 0 2px rgba(255, 243, 220, 0.08);
  color: #fff0dc;
  font-family: "Instrument Serif", serif;
  font-size: 1.45rem;
  letter-spacing: 0.08em;
}

.hero-copy {
  position: relative;
  z-index: 1;
}

.hero-actions {
  display: grid;
  gap: 10px;
  position: relative;
  z-index: 1;
}

.role-lock {
  display: grid;
  gap: 7px;
  padding: 12px 12px;
  border: 1px solid rgba(222, 191, 132, 0.18);
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(250, 239, 216, 0.12), rgba(250, 239, 216, 0.06));
}

.role-lock-label {
  color: #f6dfbf;
  font-size: 0.76rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

.role-options {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
}

.role-pill {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 38px;
  padding: 0 10px;
  gap: 8px;
  border: 1px solid rgba(221, 190, 131, 0.16);
  border-radius: 999px;
  background: rgba(255, 246, 229, 0.08);
  color: #f8ecd8;
  font: inherit;
  cursor: pointer;
  transition: transform 180ms ease, background 180ms ease, box-shadow 180ms ease;
}

.role-pill span {
  font-size: 0.91rem;
  font-weight: 600;
}

.role-pill span::before {
  content: "";
  display: inline-grid;
  place-items: center;
  width: 16px;
  height: 16px;
  margin-right: 8px;
  border: 1.5px solid rgba(244, 223, 187, 0.3);
  border-radius: 50%;
  background: rgba(255, 247, 231, 0.12);
  box-sizing: border-box;
  vertical-align: -2px;
}

.role-pill.is-active {
  background: linear-gradient(135deg, #d58c3f, #bf5a26);
  color: #fff7ef;
  box-shadow:
    inset 0 0 0 1px rgba(103, 52, 24, 0.24),
    0 10px 20px rgba(82, 42, 20, 0.18);
}

.role-pill.is-active span::before {
  content: "✓";
  border-color: rgba(255, 247, 239, 0.78);
  background: rgba(255, 247, 239, 0.18);
  color: #fff7ef;
  font-size: 0.72rem;
  font-weight: 700;
}

.role-checkbox {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.role-pill:hover,
.refresh-button:hover,
.submit-button:hover,
.vote-button:hover {
  transform: translateY(-1px);
}

.eyebrow {
  margin: 0 0 10px;
  color: inherit;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.16em;
  text-transform: uppercase;
}

h1,
h2,
h3,
h4,
p {
  margin: 0;
}

h1,
h2,
h3 {
  line-height: 0.98;
}

h1 {
  max-width: 11ch;
  color: #fff2de;
  font-family: "Instrument Serif", serif;
  font-size: clamp(2.3rem, 8.2vw, 5rem);
  font-weight: 400;
}

h2 {
  font-family: "Instrument Serif", serif;
  font-size: clamp(2.5rem, 8.8vw, 4.2rem);
  font-weight: 400;
}

h3 {
  font-size: clamp(1.3rem, 4.9vw, 1.86rem);
}

.lede {
  max-width: 54ch;
  margin-top: 12px;
  color: rgba(255, 236, 208, 0.84);
  font-size: 0.96rem;
  line-height: 1.42;
}

.refresh-button,
.submit-button,
.vote-button {
  appearance: none;
  border: 0;
  border-radius: 999px;
  font: inherit;
  cursor: pointer;
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease;
}

.refresh-button,
.submit-button {
  min-height: 46px;
  padding: 0 16px;
  background: linear-gradient(180deg, #f0cf8c, #d58e3b);
  color: #492311;
  font-weight: 700;
  box-shadow:
    inset 0 0 0 1px rgba(101, 58, 28, 0.16),
    0 14px 26px rgba(52, 28, 12, 0.18);
}

.card {
  position: relative;
  overflow: hidden;
  margin-top: 18px;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(250, 241, 223, 0.98), rgba(244, 230, 207, 0.95));
  box-shadow: var(--shadow);
}

.card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: 10px;
  background: linear-gradient(180deg, rgba(102, 60, 31, 0.22), rgba(102, 60, 31, 0));
}

.card::after {
  content: "";
  position: absolute;
  inset: auto -22% -56% auto;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(191, 99, 45, 0.18), transparent 70%);
}

.spotlight {
  display: grid;
}

.spotlight-media {
  min-height: 220px;
  padding: 20px 20px 0;
}

.hero-frame {
  padding: 10px;
  border: 1px solid rgba(115, 71, 37, 0.24);
  border-radius: 24px;
  background:
    linear-gradient(180deg, rgba(119, 73, 40, 0.16), rgba(255, 248, 232, 0.46));
  box-shadow: inset 0 0 0 1px rgba(255, 246, 224, 0.34);
}

.hero-image {
  display: block;
  width: 100%;
  max-width: 420px;
  margin: 0 auto;
  border-radius: 18px;
  object-fit: cover;
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.16);
}

.spotlight-copy,
.build-card,
.comments-card {
  padding: 22px;
}

.hero-meta {
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 0.94rem;
}

.suggestion {
  margin-top: 14px;
  max-width: 54ch;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1.55;
}

.vote-strip {
  display: flex;
  gap: 12px;
  align-items: center;
  flex-wrap: wrap;
  margin-top: 20px;
}

.vote-button {
  display: grid;
  place-items: center;
  width: 52px;
  height: 52px;
  background: var(--paper);
  box-shadow: inset 0 0 0 1px var(--line);
  font-size: 1.3rem;
}

.vote-button.is-active {
  background: var(--accent-soft);
  box-shadow: inset 0 0 0 1px rgba(191, 99, 45, 0.24);
}

.vote-stats {
  display: flex;
  flex-direction: column;
  gap: 2px;
  color: var(--muted);
  font-size: 0.92rem;
}

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

.section-note {
  margin-top: 8px;
  max-width: 44ch;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.42;
}

.core-build {
  display: grid;
  gap: 12px;
  margin-bottom: 16px;
}

.loadout-intro {
  margin: 6px 0 14px;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.4;
}

.core-build-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.core-slot {
  display: grid;
  gap: 8px;
  padding: 10px;
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(112, 70, 37, 0.1), rgba(255, 249, 236, 0.92));
  box-shadow:
    inset 0 0 0 1px rgba(92, 57, 31, 0.12),
    0 8px 18px rgba(62, 35, 18, 0.08);
  text-align: center;
}

.core-slot-label {
  color: var(--accent-deep);
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.core-slot img {
  width: 100%;
  max-width: 88px;
  aspect-ratio: 1;
  margin: 0 auto;
  border-radius: 16px;
}

.core-slot strong {
  font-size: 0.92rem;
  line-height: 1.24;
}

.build-stages {
  display: grid;
  gap: 14px;
}

.stage {
  padding: 16px;
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(255, 248, 233, 0.84), rgba(247, 236, 214, 0.84));
  box-shadow: inset 0 0 0 1px rgba(86, 53, 29, 0.08);
}

.stage h4 {
  margin: 0 0 12px;
  font-size: 1rem;
}

.item-row {
  display: grid;
  gap: 10px;
}

.item-card {
  display: grid;
  grid-template-columns: 64px 1fr;
  gap: 12px;
  align-items: center;
  padding: 8px;
  border-radius: 18px;
  background: linear-gradient(180deg, rgba(255, 250, 239, 0.92), rgba(245, 233, 212, 0.92));
}

.item-card img {
  width: 64px;
  height: 64px;
  border-radius: 14px;
}

.item-card p {
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.4;
}

.comment-form textarea {
  width: 100%;
  min-height: 96px;
  resize: vertical;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: rgba(255, 252, 245, 0.82);
  color: var(--text);
  font: inherit;
}

.comment-form textarea:focus {
  outline: 2px solid rgba(191, 99, 45, 0.2);
  border-color: rgba(191, 99, 45, 0.32);
}

.comment-actions {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin-top: 12px;
}

.comment-status {
  min-height: 1.2em;
  color: var(--muted);
  font-size: 0.92rem;
}

.comments-list {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.comment {
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(255, 251, 244, 0.72);
}

.comment time {
  display: block;
  margin-bottom: 6px;
  color: var(--muted);
  font-size: 0.8rem;
}

.comment p {
  line-height: 1.5;
}

.house-note {
  margin-top: 16px;
  color: var(--muted);
  font-size: 0.88rem;
  line-height: 1.45;
}

.empty-state {
  padding: 18px;
  border-radius: 18px;
  color: var(--muted);
  background: rgba(255, 251, 243, 0.6);
}

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

@media (min-width: 760px) {
  .shell {
    padding: 34px 24px 74px;
  }

  .hero-panel {
    grid-template-columns: auto 1fr auto;
    gap: 18px;
    align-items: end;
  }

  .signboard-crest {
    margin-bottom: 0;
    align-self: start;
  }

  .hero-actions {
    width: min(288px, 100%);
  }

  .spotlight {
    grid-template-columns: minmax(0, 380px) 1fr;
    align-items: center;
  }

  .spotlight-media {
    padding: 28px;
  }

  .build-stages {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .core-build-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }
}
