:root {
  --bg: #f5f2e8;
  --panel: rgba(255, 255, 255, 0.86);
  --panel-strong: #ffffff;
  --text: #102118;
  --muted: #5f6a62;
  --line: rgba(16, 33, 24, 0.1);
  --accent: #d9a441;
  --accent-2: #1f5e48;
  --urgent-bg: #ffe2d7;
  --urgent-text: #9b2b15;
  --high-bg: #fff0d5;
  --high-text: #8d5800;
  --normal-bg: #e5efff;
  --normal-text: #224379;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: "Iowan Old Style", "Palatino Linotype", "Book Antiqua", serif;
  color: var(--text);
  background:
    radial-gradient(circle at top left, rgba(255, 208, 96, 0.3), transparent 22%),
    radial-gradient(circle at top right, rgba(31, 94, 72, 0.11), transparent 24%),
    linear-gradient(180deg, var(--bg) 0%, #faf8f3 34%, #ffffff 100%);
}

a { color: inherit; text-decoration: none; }

.site-header,
.site-footer,
main {
  width: min(1200px, calc(100% - 40px));
  margin: 0 auto;
}

.site-header,
.site-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 24px 0;
}

.nav,
.site-footer div {
  display: flex;
  gap: 20px;
  color: var(--muted);
}

.brand {
  font-size: 1.05rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.hero-shell,
.split-section,
.grid-section,
.stack-grid,
.demo-grid {
  display: grid;
  gap: 24px;
}

.hero-shell {
  grid-template-columns: 1.2fr 0.8fr;
  align-items: center;
  min-height: 76vh;
}

.hero-copy h1,
.page-hero h1 {
  font-size: clamp(3rem, 7vw, 5.6rem);
  line-height: 0.95;
  margin: 12px 0;
  max-width: 10ch;
}

.lede {
  font-size: 1.35rem;
  max-width: 26rem;
}

.support,
.page-hero p,
.story-card p,
.flow-node p,
.detail-panel,
.mini-window__body,
.queue-item p {
  color: var(--muted);
  line-height: 1.6;
}

.hero-actions {
  display: flex;
  gap: 14px;
  margin-top: 28px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 999px;
  padding: 14px 20px;
  border: 1px solid var(--line);
  font-size: 0.95rem;
}

.button-primary {
  background: var(--accent-2);
  color: #f8f8f2;
  border-color: transparent;
}

.button-secondary {
  background: rgba(255,255,255,0.7);
}

.hero-panel,
.story-card,
.flow-node,
.mini-window,
.demo-toolbar {
  border: 1px solid var(--line);
  background: var(--panel);
  backdrop-filter: blur(12px);
}

.story-card,
.flow-node,
.page-hero,
.demo-toolbar {
  border-radius: 28px;
  padding: 28px;
}

.mini-window {
  border-radius: 30px;
  overflow: hidden;
}

.mini-window__header {
  padding: 16px 20px;
  background: #13261f;
  color: #f7f4ed;
}

.mini-window__body {
  padding: 20px;
}

.mini-metric {
  display: flex;
  justify-content: space-between;
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
}

.mini-queue {
  display: grid;
  gap: 12px;
  margin-top: 18px;
}

.eyebrow {
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.78rem;
  color: #6a7a6d;
}

.grid-section {
  grid-template-columns: repeat(3, minmax(0, 1fr));
  margin: 40px 0 24px;
}

.narrative {
  margin: 72px 0;
}

.flow-strip,
.architecture-flow {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
  margin-top: 24px;
}

.split-section,
.stack-grid,
.demo-grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin-bottom: 64px;
}

.page-shell {
  padding-bottom: 40px;
}

.page-hero {
  margin: 24px 0;
}

.demo-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 24px;
}

.demo-metrics {
  display: flex;
  gap: 18px;
  flex-wrap: wrap;
}

.queue-list {
  display: grid;
  gap: 12px;
}

.queue-item {
  padding: 18px;
  border-radius: 20px;
  border: 1px solid var(--line);
  background: var(--panel-strong);
  cursor: pointer;
}

.queue-item.is-active {
  border-color: var(--accent-2);
  box-shadow: 0 0 0 2px rgba(31, 94, 72, 0.12);
}

.pill {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.78rem;
  margin-right: 8px;
}

.pill-urgent { background: var(--urgent-bg); color: var(--urgent-text); }
.pill-high { background: var(--high-bg); color: var(--high-text); }
.pill-normal { background: var(--normal-bg); color: var(--normal-text); }

.decision-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px;
}

.decision-buttons button {
  padding: 10px 14px;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: var(--panel-strong);
  cursor: pointer;
}

@media (max-width: 900px) {
  .hero-shell,
  .grid-section,
  .split-section,
  .stack-grid,
  .demo-grid,
  .flow-strip,
  .architecture-flow {
    grid-template-columns: 1fr;
  }

  .demo-toolbar,
  .site-header,
  .site-footer {
    flex-direction: column;
    align-items: flex-start;
    gap: 16px;
  }
}
