:root {
  font-family: "DM Sans", system-ui, sans-serif;
  color: #e5eee7;
  background: #0c2025;
  font-synthesis: none;
  --muted: #9cb8b2;
  --gold: #f3cd82;
  --coral: #ef9b80;
  --line: #375657;
}
* {
  box-sizing: border-box;
}
body {
  margin: 0;
  background:
    radial-gradient(ellipse at 15% 0, #254e4b 0, transparent 48%), #0c2025;
}
button,
input,
select {
  font: inherit;
}
button,
select {
  min-height: 44px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #1d3d42;
  color: inherit;
  padding: 10px 14px;
  cursor: pointer;
}
button:hover {
  border-color: var(--gold);
}
button:focus-visible,
select:focus-visible,
input:focus-visible {
  outline: 3px solid var(--gold);
  outline-offset: 3px;
}
button:disabled {
  opacity: 0.42;
  cursor: default;
}
.primary,
button.active {
  background: var(--gold);
  color: #183338;
  border-color: var(--gold);
}
input {
  min-height: 44px;
  background: #102c31;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px;
  color: inherit;
  width: 100%;
}
select {
  width: 100%;
}
a {
  color: var(--gold);
}
.shell {
  max-width: 1240px;
  margin: auto;
  padding: 32px 34px 70px;
}
.top {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: center;
  margin-bottom: 28px;
}
.wordmark {
  font-size: 24px;
  letter-spacing: -1px;
  font-weight: 700;
}
.wordmark span {
  color: var(--gold);
}
.eyebrow {
  text-transform: uppercase;
  font-size: 10px;
  letter-spacing: 2px;
  font-weight: 700;
  color: var(--gold);
}
.badge {
  border: 1px solid var(--line);
  border-radius: 100px;
  padding: 8px 13px;
  font-size: 11px;
  color: var(--muted);
}
h1,
h2,
h3,
p {
  margin: 0;
}
h1 {
  font-family: Fraunces, Georgia, serif;
  font-size: clamp(32px, 4.7vw, 57px);
  font-weight: 600;
  line-height: 1.08;
  max-width: 690px;
  margin: 11px 0 14px;
  letter-spacing: -1.5px;
}
h2 {
  font-family: Fraunces, Georgia, serif;
  font-size: 27px;
  margin-bottom: 12px;
}
h3 {
  font-size: 15px;
}
.intro {
  max-width: 670px;
  color: var(--muted);
  line-height: 1.65;
  font-size: 14px;
}
.nav {
  display: flex;
  gap: 6px;
  margin: 27px 0 22px;
  border-bottom: 1px solid var(--line);
  padding-bottom: 12px;
}
.nav button {
  background: transparent;
  border-color: transparent;
  color: var(--muted);
}
.nav button.active {
  background: #254449;
  color: #fff;
  border-color: #54706b;
}
.layout {
  display: grid;
  grid-template-columns: minmax(330px, 1.22fr) minmax(290px, 1fr);
  gap: 24px;
  align-items: start;
}
.panel {
  background: #122f34;
  border: 1px solid var(--line);
  border-radius: 17px;
  padding: 22px;
}
.board-panel {
  padding: 19px;
  background: linear-gradient(145deg, #1b4145, #102b30);
}
.board-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 13px;
}
.phase {
  font-size: 11px;
  color: var(--gold);
  letter-spacing: 1px;
  text-transform: uppercase;
}
.stats {
  display: flex;
  gap: 18px;
}
.stat strong {
  display: block;
  font-size: 22px;
  font-weight: 600;
}
.stat span {
  font-size: 10px;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 1px;
}
.board-wrap {
  position: relative;
  border: 1px solid #527574;
  border-radius: 12px;
  overflow: hidden;
  background: #163c43;
}
canvas#board {
  display: block;
  width: 100%;
  height: auto;
  touch-action: manipulation;
}
.board-access {
  position: absolute;
  inset: 0 0 10.17%;
  display: grid;
  grid-template-columns: repeat(7, 1fr);
  grid-template-rows: repeat(9, 1fr);
}
.board-access button {
  padding: 0;
  min-height: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
}
.board-access button:hover {
  background: #f3cd8219;
}
.board-access button:focus-visible {
  outline-offset: -4px;
}
.board-access button:disabled {
  opacity: 1;
}
.board-footer {
  display: flex;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
  margin-top: 13px;
}
.board-footer button {
  padding: 8px 12px;
}
.speed {
  display: flex;
  gap: 5px;
}
.hint {
  display: flex;
  gap: 11px;
  background: #234448;
  border-left: 3px solid var(--gold);
  padding: 13px 15px;
  margin-top: 15px;
  font-size: 12px;
  line-height: 1.55;
  color: #cfe0d8;
}
.hint strong {
  color: var(--gold);
}
.side {
  display: grid;
  gap: 16px;
}
.panel-label {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  margin-bottom: 14px;
}
.small {
  font-size: 12px;
  color: var(--muted);
  line-height: 1.6;
}
.family-tabs {
  display: flex;
  gap: 5px;
  margin: 14px 0;
}
.family-tabs button {
  flex: 1;
  padding: 8px 5px;
  font-size: 12px;
}
.tower-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 7px;
  max-height: 254px;
  overflow: auto;
  padding: 2px;
}
.tower-card {
  display: flex;
  gap: 8px;
  align-items: center;
  text-align: left;
  padding: 8px;
  min-height: 69px;
}
.tower-card canvas {
  width: 42px;
  height: 42px;
  flex: none;
}
.tower-card strong {
  display: block;
  font-size: 11px;
  line-height: 1.35;
}
.tower-card small {
  font-size: 10px;
  opacity: 0.7;
}
.tower-detail {
  border-top: 1px solid var(--line);
  margin-top: 15px;
  padding-top: 15px;
  min-height: 120px;
}
.tower-detail h3 {
  color: var(--gold);
  margin-bottom: 6px;
}
.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 10px 0;
}
.chip {
  font-size: 10px;
  padding: 5px 7px;
  border: 1px solid var(--line);
  border-radius: 5px;
  color: #c7d7cc;
}
.actions {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}
.actions button {
  flex: 1;
}
.grid-two {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}
.field {
  display: grid;
  gap: 6px;
  font-size: 11px;
  color: var(--muted);
}
.notice {
  font-size: 11px;
  color: var(--coral);
  line-height: 1.6;
  margin-top: 12px;
}
.status {
  min-height: 22px;
  margin-top: 10px;
  font-size: 12px;
  color: var(--gold);
}
.metrics {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin: 18px 0;
}
.metric {
  padding: 17px;
  background: #1a3b40;
  border: 1px solid var(--line);
  border-radius: 9px;
}
.metric strong {
  font-size: 26px;
  display: block;
  color: var(--gold);
}
.metric span {
  font-size: 11px;
  color: var(--muted);
}
table {
  width: 100%;
  border-collapse: collapse;
  font-size: 12px;
  text-align: left;
}
td,
th {
  padding: 13px 9px;
  border-bottom: 1px solid var(--line);
}
th {
  font-size: 10px;
  text-transform: uppercase;
  color: var(--muted);
}
.flow {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 15px;
  margin-top: 20px;
}
.flow article {
  border: 1px solid var(--line);
  border-radius: 12px;
  padding: 20px;
  background: #1a3b40;
}
.flow .number {
  color: var(--gold);
  font-family: Georgia, serif;
  font-size: 34px;
  margin-bottom: 17px;
}
.flow h3 {
  margin-bottom: 9px;
}
.art-roster {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 18px 0;
}
.art-roster canvas {
  width: 74px;
  height: 74px;
  background: #1b4146;
  border-radius: 12px;
}
.hidden {
  display: none !important;
}
.footer {
  margin-top: 26px;
  color: #7f9e99;
  font-size: 11px;
  line-height: 1.8;
}
.checklist {
  padding-left: 18px;
  color: var(--muted);
  font-size: 13px;
  line-height: 1.9;
}
.result-banner {
  padding: 16px;
  border: 1px solid var(--gold);
  border-radius: 10px;
  margin: 12px 0;
  color: var(--gold);
}
@media (max-width: 760px) {
  .shell {
    padding: 20px 14px 40px;
  }
  .top {
    margin-bottom: 23px;
  }
  .badge {
    max-width: 148px;
    font-size: 9px;
    line-height: 1.4;
  }
  .layout {
    grid-template-columns: 1fr;
    gap: 15px;
  }
  h1 {
    font-size: 38px;
    max-width: 370px;
  }
  .intro {
    font-size: 13px;
  }
  .nav {
    margin-top: 20px;
  }
  .nav button {
    padding: 8px 11px;
    font-size: 12px;
  }
  .panel {
    padding: 17px;
  }
  .board-panel {
    padding: 13px;
  }
  .flow {
    grid-template-columns: 1fr;
  }
  .metrics {
    grid-template-columns: 1fr 1fr;
  }
  .tower-list {
    max-height: 230px;
  }
  .board-footer {
    flex-wrap: wrap;
  }
  .board-footer > .primary {
    flex: 1;
  }
  .wordmark {
    font-size: 22px;
  }
}
@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto !important;
  }
}

.layout > * {
  min-width: 0;
}
.board-view-control {
  display: flex;
  gap: 10px;
  align-items: center;
  justify-content: space-between;
  margin: 0 0 10px;
}
.board-view-control button {
  font-size: 11px;
  flex-shrink: 0;
  padding: 8px 10px;
}
.board-view-control .small {
  font-size: 10px;
}
.board-scroll {
  width: 100%;
  overflow-x: auto;
  border-radius: 12px;
  overscroll-behavior-x: contain;
  scrollbar-color: #6a9389 #173e45;
}
.touch-targets .board-wrap {
  min-width: 310px;
}
.board-access {
  bottom: auto;
  height: 87.3786408%;
}
.concept-gallery {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 15px;
  margin-top: 24px;
}
.concept-card {
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  border-radius: 12px;
  overflow: hidden;
  text-decoration: none;
  background: #1a3b40;
}
.concept-card img {
  width: 100%;
  height: 240px;
  object-fit: contain;
  background: #e5dcc6;
}
.concept-card strong {
  font-size: 14px;
  padding: 14px 14px 5px;
  text-transform: capitalize;
}
.concept-card span {
  padding: 0 14px 14px;
  font-size: 10px;
  color: var(--muted);
}
.concept-card:hover {
  border-color: var(--gold);
}
@media (max-width: 760px) {
  .concept-gallery {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 10px;
  }
  .concept-card img {
    height: 190px;
  }
  .concept-card strong {
    font-size: 12px;
  }
}
