:root {
  --dust: #c9b79a;
  --shell: #d8cbb4;
  --ink: #1e1a16;
  --muted: #5c5348;
  --live: #e8a317;
  --panel: #1c1c1c;
  --off: #4a4a4a;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: "Libre Franklin", system-ui, sans-serif;
  background: var(--shell);
  color: var(--ink);
  line-height: 1.5;
}
a { color: inherit; }
h1, h2, .mark, .brk b, .volts { font-family: Oswald, sans-serif; font-weight: 600; }

.sitebar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 18px;
  padding: 12px 4vw;
  background: #2a241c;
  color: #f3eadc;
  position: sticky;
  top: 0;
  z-index: 8;
}
.mark { letter-spacing: 0.16em; font-size: 16px; color: var(--live); }
.chip { font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase; opacity: 0.85; }
.chip a { color: #f3eadc; }
.lang { margin-left: auto; display: flex; border: 1px solid rgba(243,234,220,0.3); }
.lang button {
  border: 0; background: transparent; color: #f3eadc;
  padding: 7px 12px; cursor: pointer; font: inherit; font-size: 12px; font-weight: 700;
}
.lang button.active { background: var(--live); color: #1e1a16; }

.shell {
  display: grid;
  grid-template-columns: 1.2fr 0.8fr;
  min-height: 72vh;
}
.wall {
  position: relative;
  background:
    repeating-linear-gradient(90deg, #c4b396 0 18px, #d2c4aa 18px 86px);
  padding: 40px 4vw;
  display: flex;
  align-items: flex-end;
}
.studs {
  position: absolute;
  inset: 0;
  background: repeating-linear-gradient(#0000 0 0, #0000 0);
  pointer-events: none;
  box-shadow: inset 0 0 0 12px rgba(30, 26, 22, 0.15);
}
.rooms {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
  width: 100%;
  position: relative;
  z-index: 1;
}
.room {
  min-height: 140px;
  background: rgba(30, 26, 22, 0.35);
  color: #f3eadc;
  display: grid;
  place-items: center;
  font-family: Oswald, sans-serif;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  transition: background 0.35s, box-shadow 0.35s;
}
body[data-circuit="make"] .r1,
body[data-circuit="wire"] .r2,
body[data-circuit="mach"] .r3,
body[data-circuit="mix"] .r3,
body[data-circuit="eng"] .r4,
body[data-circuit="build"] .r4 {
  background: rgba(232, 163, 23, 0.55);
  box-shadow: 0 0 40px rgba(232, 163, 23, 0.35);
}

.panel {
  background: var(--panel);
  color: #eee;
  padding: 24px 22px;
  display: grid;
  gap: 8px;
  align-content: start;
}
.panel .kicker { color: var(--live); font-size: 11px; letter-spacing: 0.18em; font-weight: 800; }
.volts { font-size: 13px; letter-spacing: 0.12em; color: #9a9a9a; margin-bottom: 8px; }
.brk {
  display: grid;
  grid-template-columns: 28px 36px 1fr;
  gap: 10px;
  align-items: center;
  background: #111;
  border: 1px solid #333;
  color: #ddd;
  padding: 10px 12px;
  cursor: pointer;
  font: inherit;
  text-align: left;
}
.brk i {
  width: 18px;
  height: 28px;
  background: var(--off);
  border-radius: 2px;
  justify-self: center;
}
.brk b { color: var(--live); font-size: 14px; }
.brk.on { border-color: var(--live); }
.brk.on i { background: var(--live); box-shadow: 0 0 10px var(--live); }

.circuit { padding: 32px 4vw; background: #efe6d6; }
.ch { color: #8a5a10; font-size: 12px; letter-spacing: 0.2em; font-weight: 800; margin-bottom: 8px; }
.circuit h1 { font-size: clamp(26px, 3.4vw, 40px); margin-bottom: 12px; max-width: 20ch; }
.circuit p { color: var(--muted); max-width: 64ch; }
.cue { margin-top: 14px; padding-top: 12px; border-top: 1px dashed #c9b79a; color: #8a5a10 !important; }

.copy, .walk, .rules, .order { padding: 40px 4vw; }
.kicker { font-size: 11px; letter-spacing: 0.18em; font-weight: 800; color: #8a5a10; margin-bottom: 10px; }
.copy { background: #2a241c; color: #f3eadc; }
.copy .kicker { color: var(--live); }
.copy h2 { font-size: clamp(26px, 3.2vw, 38px); margin-bottom: 12px; max-width: 20ch; }
.copy p { color: #cfc3b0; max-width: 68ch; }
.copy p + p { margin-top: 12px; }

.walk { background: #efe6d6; }
.walk ol {
  list-style: none;
  display: grid;
  gap: 10px;
  max-width: 760px;
  margin-top: 12px;
}
.walk li {
  background: #fff8ee;
  padding: 14px 16px;
  border-left: 4px solid var(--live);
  color: var(--muted);
}

.rules { background: #e4d8c4; }
.rules ul {
  list-style: none;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 12px;
  margin-top: 12px;
}
.rules li {
  background: #fff8ee;
  padding: 16px;
  border-top: 3px solid #2a241c;
  color: var(--muted);
}

.order {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
  background: #fff8ee;
}
.order h2 { font-size: clamp(24px, 3vw, 34px); margin: 8px 0 12px; }
.order p { color: var(--muted); }
address { font-style: normal; margin-top: 16px; }
address p { margin: 4px 0; }
address a { color: #8a5a10; }
form { display: grid; gap: 10px; }
@media (min-width: 700px) {
  form { grid-template-columns: 1fr 1fr; }
  .wide, form button, .note { grid-column: 1 / -1; }
}
label { display: grid; gap: 4px; font-size: 12px; font-weight: 700; }
input, textarea {
  font: inherit; padding: 10px;
  border: 1px solid #c9b79a;
  background: #efe6d6;
}
button[type="submit"] {
  justify-self: start;
  background: #2a241c; color: var(--live); border: 0;
  padding: 12px 18px; font: inherit; font-weight: 800; cursor: pointer;
}
.note { font-size: 13px; color: var(--muted); }
footer {
  display: flex; justify-content: space-between; gap: 12px; flex-wrap: wrap;
  padding: 16px 4vw 32px;
  background: #2a241c;
  color: #cfc3b0;
  font-size: 13px;
}

@media (max-width: 900px) {
  .shell, .rules ul, .order { grid-template-columns: 1fr; }
  .lang { margin-left: 0; }
  .wall { min-height: 280px; }
}
