:root {
  --bg: #fbfaf7;
  --surface: #ffffff;
  --tint: #eaf2ec;
  --cream: #fbf2e6;
  --text: #1f2a22;
  --muted: #4a5a50;
  --brand: #2c5a3c;
  --brand-ink: #ffffff;
  --leaf-light: #6f9f7d;
  --petal: #f2c46b;
  --border: #dfe4dc;
  --focus: #1f6b3f;
  --pending-bg: #fff4d6;
  --pending-text: #5c3f00;
  --pending-border: #d9a93a;
  --draft-bg: #1f2a22;
  --draft-text: #ffffff;
  --radius: 16px;
  --wrap: 60rem;
  --prose: 42rem;
  color-scheme: light;
}

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) {
    --bg: #131a15;
    --surface: #1b2620;
    --tint: #1d2e24;
    --cream: #2a2618;
    --text: #e6eee8;
    --muted: #b9c6bd;
    --brand: #8fd0a4;
    --brand-ink: #102015;
    --leaf-light: #5f9a72;
    --petal: #e8b85a;
    --border: #2e3d33;
    --focus: #b7e8c6;
    --pending-bg: #2b2615;
    --pending-text: #ffe3a3;
    --pending-border: #8a6d1f;
    --draft-bg: #e6eee8;
    --draft-text: #131a15;
    color-scheme: dark;
  }
}

:root[data-theme="dark"] {
  --bg: #131a15;
  --surface: #1b2620;
  --tint: #1d2e24;
  --cream: #2a2618;
  --text: #e6eee8;
  --muted: #b9c6bd;
  --brand: #8fd0a4;
  --brand-ink: #102015;
  --leaf-light: #5f9a72;
  --petal: #e8b85a;
  --border: #2e3d33;
  --focus: #b7e8c6;
  --pending-bg: #2b2615;
  --pending-text: #ffe3a3;
  --pending-border: #8a6d1f;
  --draft-bg: #e6eee8;
  --draft-text: #131a15;
  color-scheme: dark;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: ui-rounded, "SF Pro Rounded", system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  font-size: 1.0625rem;
  line-height: 1.6;
  overflow-wrap: break-word;
}

img,
svg {
  max-width: 100%;
}

a {
  color: var(--brand);
  text-decoration-thickness: 0.08em;
  text-underline-offset: 0.18em;
}

a:hover {
  text-decoration-thickness: 0.14em;
}

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
  border-radius: 4px;
}

h1,
h2,
h3 {
  line-height: 1.2;
  letter-spacing: -0.01em;
  margin: 0 0 0.6em;
}

h1 {
  font-size: clamp(2rem, 7vw, 2.9rem);
}

h2 {
  font-size: clamp(1.35rem, 4.5vw, 1.7rem);
  margin-top: 0.2em;
}

h3 {
  font-size: 1.15rem;
}

p,
ul,
ol {
  margin: 0 0 1em;
}

ul,
ol {
  padding-left: 1.3em;
}

li + li {
  margin-top: 0.35em;
}

.skip {
  position: absolute;
  left: 1rem;
  top: -4rem;
  z-index: 10;
  padding: 0.6rem 1rem;
  background: var(--surface);
  color: var(--brand);
  border: 2px solid var(--brand);
  border-radius: 10px;
  font-weight: 700;
}

.skip:focus {
  top: 1rem;
}

.wrap {
  width: 100%;
  max-width: var(--wrap);
  margin: 0 auto;
  padding-left: 1rem;
  padding-right: 1rem;
}

.draft-banner {
  background: var(--draft-bg);
  color: var(--draft-text);
  font-size: 0.9rem;
  text-align: center;
  padding: 0.5rem 1rem;
  margin: 0;
}

.site-header {
  border-bottom: 1px solid var(--border);
  background: var(--bg);
}

.header-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.25rem 1rem;
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 44px;
  color: var(--text);
  text-decoration: none;
  font-weight: 800;
  font-size: 1.3rem;
  letter-spacing: -0.01em;
}

.brand svg {
  width: 32px;
  height: 32px;
  flex: none;
}

.site-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0 0.25rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.site-nav li + li {
  margin-top: 0;
}

.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 0 0.6rem;
  border-radius: 10px;
  color: var(--text);
  text-decoration: none;
  font-weight: 600;
}

.site-nav a:hover {
  background: var(--tint);
}

.site-nav a[aria-current="page"] {
  color: var(--brand);
  text-decoration: underline;
  text-decoration-thickness: 0.14em;
}

.site-nav li:first-child a {
  padding-left: 0;
}

main {
  padding-top: 1.5rem;
  padding-bottom: 3rem;
}

.prose {
  max-width: var(--prose);
}

.hero {
  display: grid;
  gap: 1rem;
  align-items: center;
  background: var(--tint);
  border-radius: var(--radius);
  padding: 1.5rem 1.25rem;
  margin-bottom: 2rem;
}

.hero h1 {
  margin-bottom: 0.2em;
}

.tagline {
  font-size: 1.3rem;
  font-weight: 700;
  color: var(--brand);
  margin-bottom: 0.6em;
}

.lead {
  font-size: 1.15rem;
  max-width: 34rem;
}

.status {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: 0.3rem 0.8rem;
  font-size: 0.95rem;
  font-weight: 600;
}

.status-dot {
  width: 0.6rem;
  height: 0.6rem;
  border-radius: 50%;
  background: var(--petal);
  flex: none;
}

.hero-art {
  justify-self: center;
  width: min(11rem, 55%);
}

.two-col {
  display: grid;
  gap: 1rem;
}

.hero-art svg {
  display: block;
  width: 100%;
  height: auto;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-top: 1.25rem;
  margin-bottom: 0;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 48px;
  padding: 0.6rem 1.2rem;
  border-radius: 999px;
  background: var(--brand);
  color: var(--brand-ink);
  font-weight: 700;
  text-decoration: none;
  border: 2px solid var(--brand);
}

.button:hover {
  text-decoration: underline;
}

.button-quiet {
  background: transparent;
  color: var(--brand);
}

.section {
  margin: 0 0 2.25rem;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.25rem;
}

.play-kinds {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  list-style: none;
  padding: 0;
  margin: 1rem 0 1.25rem;
}

.play-kinds li {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  margin: 0;
  padding: 0.75rem 0.9rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  font-weight: 700;
}

.play-kinds svg {
  width: 28px;
  height: 28px;
  flex: none;
}

.steps {
  counter-reset: step;
  list-style: none;
  padding: 0;
}

.steps li {
  counter-increment: step;
  position: relative;
  padding-left: 2.75rem;
  min-height: 2.1rem;
  margin: 0 0 0.9rem;
}

.steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0;
  width: 2rem;
  height: 2rem;
  border-radius: 50%;
  background: var(--brand);
  color: var(--brand-ink);
  font-weight: 800;
  display: flex;
  align-items: center;
  justify-content: center;
}

.checks {
  list-style: none;
  padding: 0;
}

.checks li {
  position: relative;
  padding-left: 1.8rem;
}

.checks li::before {
  content: "";
  position: absolute;
  left: 0.2rem;
  top: 0.45em;
  width: 0.55rem;
  height: 0.9rem;
  border: solid var(--brand);
  border-width: 0 3px 3px 0;
  transform: rotate(45deg);
}

.band {
  background: var(--cream);
  border-radius: var(--radius);
  padding: 1.25rem;
  text-align: center;
  font-size: 1.15rem;
  font-weight: 700;
}

.band p {
  margin: 0;
}

.legal-draft {
  background: var(--pending-bg);
  color: var(--pending-text);
  border: 2px solid var(--pending-border);
  border-radius: 12px;
  padding: 0.75rem 1rem;
  font-weight: 700;
}

.pending {
  background: var(--pending-bg);
  color: var(--pending-text);
  border-left: 5px solid var(--pending-border);
  border-radius: 8px;
  padding: 0.6rem 0.9rem;
}

.pending-label {
  display: block;
  font-size: 0.8rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.meta {
  color: var(--muted);
}

.summary {
  background: var(--tint);
  border-radius: var(--radius);
  padding: 1rem 1.25rem;
  margin-bottom: 1.5rem;
}

.summary h2 {
  font-size: 1.2rem;
}

.summary ul {
  margin-bottom: 0;
}

.toc {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1rem 1.25rem;
  margin-bottom: 2rem;
  background: var(--surface);
}

.toc h2 {
  font-size: 1.05rem;
}

.toc ol {
  margin: 0;
}

.legal h2 {
  font-size: 1.3rem;
  margin-top: 2rem;
  scroll-margin-top: 1rem;
}

.site-footer {
  border-top: 1px solid var(--border);
  padding: 1.5rem 0 2rem;
  font-size: 0.95rem;
  color: var(--muted);
}

.site-footer p {
  margin: 0 0 0.5rem;
}

.footer-nav ul {
  display: flex;
  flex-wrap: wrap;
  gap: 0 1rem;
  list-style: none;
  padding: 0;
  margin: 0 0 0.75rem;
}

.footer-nav li + li {
  margin-top: 0;
}

.footer-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  font-weight: 600;
}

.mark-stem {
  stroke: var(--brand);
}

.mark-leaf {
  fill: var(--brand);
}

.mark-leaf-light {
  fill: var(--leaf-light);
}

.art-ground {
  fill: var(--surface);
}

.art-stem {
  stroke: var(--brand);
}

.art-leaf {
  fill: var(--brand);
}

.art-leaf-light {
  fill: var(--leaf-light);
}

.art-petal {
  fill: var(--petal);
}

.art-center {
  fill: var(--brand);
}

.icon {
  fill: none;
  stroke: var(--brand);
  stroke-width: 2.2;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.notfound {
  text-align: center;
  padding: 2rem 0;
}

.notfound .actions {
  justify-content: center;
}

@media (min-width: 40rem) {
  .hero {
    grid-template-columns: 1.4fr 1fr;
    padding: 2.5rem 2rem;
  }

  .hero-art {
    width: 100%;
  }

  .play-kinds {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }

  .two-col {
    grid-template-columns: 1fr 1fr;
    gap: 1.5rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  * {
    scroll-behavior: auto;
  }
}

@media print {
  .site-header,
  .site-footer,
  .skip,
  .draft-banner {
    display: none;
  }
}

.notfound {
  margin: 0 auto;
}

.toc a {
  display: block;
  padding: 0.15rem 0;
}

.site-footer a,
.standalone-link a {
  display: inline-block;
  padding: 0.15rem 0;
  min-height: 24px;
}
