:root {
  --ink: #151412;
  --muted: #57544d;
  --paper: #f6efdc;
  --card: #fffdf3;
  --line: #1c1a16;
  --blue: #1457b8;
  --red: #d74732;
  --yellow: #ffd84d;
  --green: #087a54;
  --violet: #6f4cb1;
  --shadow: 5px 5px 0 rgba(21, 20, 18, 0.22);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  color: var(--ink);
  background:
    linear-gradient(90deg, rgba(21, 20, 18, 0.05) 1px, transparent 1px) 0 0 / 26px 26px,
    linear-gradient(0deg, rgba(21, 20, 18, 0.05) 1px, transparent 1px) 0 0 / 26px 26px,
    radial-gradient(circle at 12% 7%, #fff3a1, transparent 24%),
    linear-gradient(135deg, #f9ecd2, #d8efe9 52%, #ddd6f5);
}

a {
  color: inherit;
}

.page {
  width: min(1180px, calc(100% - 24px));
  margin: 0 auto;
  padding: 24px 0 44px;
}

.hero,
.notice,
.dashboard div,
.section,
.role,
.mission-grid div,
.wanda-note {
  background: var(--card);
  border: 2px solid var(--line);
  box-shadow: var(--shadow);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 16px;
  padding: 18px;
}

.kicker {
  margin: 0 0 8px;
  color: var(--red);
  font-family: "Courier New", monospace;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1 {
  max-width: 800px;
  margin-bottom: 12px;
  font-size: clamp(2.8rem, 8vw, 6.5rem);
  line-height: 0.9;
  letter-spacing: 0;
}

h2 {
  margin-bottom: 8px;
  font-size: clamp(1.6rem, 4vw, 3rem);
  line-height: 1;
}

h3 {
  margin-bottom: 8px;
  font-size: 1.35rem;
}

.lede {
  max-width: 760px;
  color: var(--muted);
  font-size: 1.12rem;
  line-height: 1.55;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 18px;
}

.button {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  padding: 10px 13px;
  background: #fff;
  border: 2px solid var(--line);
  box-shadow: 4px 4px 0 rgba(21, 20, 18, 0.2);
  font-weight: 800;
  text-decoration: none;
}

.button--primary {
  color: white;
  background: var(--blue);
}

.leader-card {
  padding: 16px;
  color: #fff;
  background:
    linear-gradient(135deg, rgba(255,255,255,0.1), transparent),
    var(--violet);
  border: 2px solid var(--line);
}

.leader-card__label,
.role span {
  display: block;
  margin-bottom: 6px;
  font-family: "Courier New", monospace;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.leader-card strong {
  display: block;
  margin-bottom: 8px;
  font-size: 3rem;
  line-height: 1;
}

.leader-card p {
  line-height: 1.45;
}

.leader-card small {
  color: #efe8ff;
  line-height: 1.35;
}

.notice {
  display: grid;
  grid-template-columns: 180px 1fr;
  gap: 10px;
  margin-top: 12px;
  padding: 12px;
  background: #fff9bf;
}

.dashboard {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.dashboard div {
  padding: 11px;
}

.dashboard span,
.mission-grid span {
  display: block;
  color: var(--muted);
  line-height: 1.35;
}

.dashboard span {
  font-family: "Courier New", monospace;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
}

.section {
  margin-top: 12px;
  padding: 16px;
}

.section__head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 12px;
}

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

.script-grid,
.memory-grid,
.standards-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.script-grid div,
.memory-grid div,
.standards-grid div {
  min-height: 150px;
  padding: 12px;
  background: #fff;
  border: 2px solid var(--line);
  box-shadow: 3px 3px 0 rgba(21, 20, 18, 0.18);
}

.script-grid strong,
.memory-grid strong,
.standards-grid strong {
  display: block;
  margin-bottom: 6px;
  font-size: 1.05rem;
}

.script-grid span,
.memory-grid span,
.standards-grid span {
  display: block;
  color: var(--muted);
  line-height: 1.42;
}

.script-grid code {
  font-family: "Courier New", monospace;
  font-size: 0.9em;
  overflow-wrap: anywhere;
}

.nouns-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 12px;
}

.nouns-configurator,
.nouns-stamp {
  padding: 14px;
  background: #fff;
  border: 2px solid var(--line);
  box-shadow: 3px 3px 0 rgba(21, 20, 18, 0.18);
}

.nouns-field {
  display: grid;
  gap: 6px;
  margin-bottom: 12px;
  color: var(--muted);
  font-family: "Courier New", monospace;
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
}

.nouns-field input {
  width: 100%;
  min-height: 42px;
  padding: 9px 10px;
  color: var(--ink);
  background: #fffdf3;
  border: 2px solid var(--line);
  font: 700 1rem Inter, ui-sans-serif, system-ui, sans-serif;
  text-transform: none;
}

.nouns-choices {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.nouns-choice {
  min-height: 38px;
  padding: 8px 10px;
  color: var(--ink);
  background: #fff9bf;
  border: 2px solid var(--line);
  box-shadow: 3px 3px 0 rgba(21, 20, 18, 0.16);
  cursor: pointer;
  font-weight: 800;
}

.nouns-choice.is-active {
  color: #fff;
  background: var(--green);
}

.nouns-actions,
.nouns-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 14px;
}

.nouns-actions .button {
  cursor: pointer;
}

.nouns-status {
  min-height: 22px;
  margin: 12px 0 0;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.4;
}

.nouns-status[data-kind="ok"] {
  color: var(--green);
}

.nouns-status[data-kind="warn"] {
  color: var(--red);
}

.nouns-stamp {
  background:
    linear-gradient(90deg, rgba(21, 20, 18, 0.06) 1px, transparent 1px) 0 0 / 12px 12px,
    #fffdf3;
}

.nouns-stamp__label {
  display: block;
  margin-bottom: 8px;
  color: var(--red);
  font-family: "Courier New", monospace;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.nouns-stamp strong {
  display: block;
  margin-bottom: 8px;
  font-size: 1.5rem;
  line-height: 1.05;
}

.nouns-stamp p {
  color: var(--muted);
  line-height: 1.45;
}

.nouns-stamp dl {
  margin: 14px 0 0;
  display: grid;
  gap: 8px;
}

.nouns-stamp div {
  padding: 8px;
  background: #fff;
  border: 1px solid rgba(21, 20, 18, 0.28);
}

.nouns-stamp dt {
  color: var(--muted);
  font-family: "Courier New", monospace;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
}

.nouns-stamp dd {
  margin: 3px 0 0;
  font-weight: 800;
}

.nouns-links a {
  color: var(--blue);
  font-weight: 800;
}

.role {
  min-height: 260px;
  padding: 13px;
  box-shadow: 3px 3px 0 rgba(21, 20, 18, 0.18);
}

.role span {
  color: var(--blue);
}

.role p {
  color: var(--muted);
  line-height: 1.45;
}

.role ul,
.split ol {
  margin-bottom: 0;
  padding-left: 20px;
}

.role li,
.split li {
  margin-bottom: 6px;
}

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

.mission-grid div {
  padding: 12px;
}

.mission-grid strong {
  display: block;
  margin-bottom: 5px;
}

.split {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 16px;
}

.wanda-note {
  align-self: start;
  padding: 14px;
  background: var(--yellow);
  box-shadow: 3px 3px 0 rgba(21, 20, 18, 0.18);
}

.wanda-note strong {
  font-size: 1.2rem;
}

.cta {
  text-align: center;
}

.cta p {
  color: var(--muted);
}

@media (max-width: 960px) {
  .hero,
  .nouns-layout,
  .split {
    grid-template-columns: 1fr;
  }

  .dashboard,
  .script-grid,
  .memory-grid,
  .standards-grid,
  .mission-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

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

@media (max-width: 640px) {
  .page {
    width: min(100% - 16px, 1180px);
    padding-top: 8px;
  }

  .notice,
  .dashboard,
  .script-grid,
  .memory-grid,
  .standards-grid,
  .role-grid,
  .mission-grid {
    grid-template-columns: 1fr;
  }

  .section__head {
    display: block;
  }
}
