:root {
  color-scheme: light;
  font-family: "Trebuchet MS", "Avenir Next", "Gill Sans", sans-serif;
  color: #22313f;
  background:
    radial-gradient(circle at 15% 10%, rgba(255, 255, 255, 0.95), transparent 28%),
    radial-gradient(circle at 90% 20%, rgba(255, 222, 173, 0.4), transparent 22%),
    linear-gradient(135deg, #fbf4df 0%, #dff0ec 48%, #dfe6f5 100%);
  --ink: #22313f;
  --soft-ink: #58707e;
  --card: rgba(255, 255, 255, 0.8);
  --line: rgba(34, 49, 63, 0.12);
  --accent: #0f7c90;
  --accent-strong: #0a5f6f;
  --warm: #f6b44f;
  --berry: #e76f51;
  --shadow: 0 24px 60px rgba(57, 53, 41, 0.14);
}

:root[data-theme="dark"] {
  color-scheme: dark;
  color: #ebf0f5;
  background:
    radial-gradient(circle at 15% 10%, rgba(255, 255, 255, 0.08), transparent 28%),
    radial-gradient(circle at 90% 20%, rgba(15, 124, 144, 0.18), transparent 24%),
    linear-gradient(145deg, #0b1620 0%, #102433 44%, #151a2f 100%);
  --ink: #ebf0f5;
  --soft-ink: #b3c3ce;
  --card: rgba(15, 24, 34, 0.78);
  --line: rgba(235, 240, 245, 0.12);
  --accent: #4fc3d7;
  --accent-strong: #79d8e7;
  --warm: #f6c667;
  --berry: #ff8a72;
  --shadow: 0 26px 60px rgba(0, 0, 0, 0.34);
}

* {
  box-sizing: border-box;
}

html,
body {
  margin: 0;
  min-height: 100%;
}

body {
  min-height: 100vh;
}

a {
  color: inherit;
}

.site-shell,
.legal-shell {
  min-height: 100vh;
  padding: 1.5rem;
  display: grid;
  align-content: start;
  gap: 1.5rem;
}

.topbar,
.legal-header,
.hero-panel,
.section-block,
.site-footer,
.legal-card {
  border-radius: 1.6rem;
  border: 1px solid var(--line);
  background: var(--card);
  backdrop-filter: blur(10px);
  box-shadow: var(--shadow);
}

.topbar,
.legal-header {
  padding: 1rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.brand {
  font-size: 1.2rem;
  font-weight: 800;
  text-decoration: none;
  letter-spacing: 0.01em;
}

.topnav,
.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.9rem;
}

.theme-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.72);
  color: var(--ink);
  padding: 0.65rem 0.95rem;
  font: inherit;
  font-weight: 700;
  cursor: pointer;
  transition: transform 120ms ease, background 120ms ease, color 120ms ease;
}

:root[data-theme="dark"] .theme-toggle {
  background: rgba(23, 35, 49, 0.92);
}

.theme-toggle:hover,
.theme-toggle:focus-visible {
  transform: translateY(-1px);
}

.theme-toggle:focus-visible {
  outline: 2px solid rgba(15, 124, 144, 0.4);
  outline-offset: 2px;
}

.theme-toggle-icon {
  font-size: 0.95rem;
  line-height: 1;
}

.language-toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.3rem;
  border-radius: 999px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.72);
}

.language-button {
  border: 0;
  background: transparent;
  color: var(--soft-ink);
  font: inherit;
  font-weight: 800;
  letter-spacing: 0.05em;
  padding: 0.5rem 0.8rem;
  border-radius: 999px;
  cursor: pointer;
}

.language-button.is-active {
  background: var(--accent);
  color: white;
}

.language-button:focus-visible {
  outline: 2px solid rgba(15, 124, 144, 0.35);
  outline-offset: 2px;
}

.topnav a,
.footer-links a {
  text-decoration: none;
  color: var(--soft-ink);
}

.topnav a:hover,
.topnav a:focus-visible,
.footer-links a:hover,
.footer-links a:focus-visible,
.button-primary:hover,
.button-primary:focus-visible,
.button-secondary:hover,
.button-secondary:focus-visible {
  color: var(--ink);
}

.hero-panel {
  padding: 1.75rem;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(18rem, 0.85fr);
  gap: 1.5rem;
  position: relative;
  overflow: hidden;
}

.hero-panel::before,
.hero-panel::after {
  content: "";
  position: absolute;
  border-radius: 999px;
  filter: blur(4px);
  opacity: 0.65;
}

.hero-panel::before {
  width: 14rem;
  height: 14rem;
  right: -2rem;
  top: -2rem;
  background: rgba(246, 180, 79, 0.16);
}

.hero-panel::after {
  width: 11rem;
  height: 11rem;
  left: -2rem;
  bottom: -2rem;
  background: rgba(15, 124, 144, 0.14);
}

.hero-copy-block,
.hero-board {
  position: relative;
  z-index: 1;
}

.eyebrow,
.tool-type,
.board-label {
  margin: 0 0 0.35rem;
  text-transform: uppercase;
  letter-spacing: 0.14em;
  font-size: 0.73rem;
  color: #8b6a2f;
}

.hero-copy-block h1,
.section-heading h2,
.project-card h3,
.story-card h3,
.principle-card h3,
.legal-card h1,
.legal-section h2 {
  margin: 0;
}

.hero-copy-block h1 {
  max-width: 12ch;
  font-size: clamp(2.2rem, 6vw, 4.9rem);
  line-height: 0.95;
}

.hero-copy,
.section-heading p,
.project-card p,
.story-card p,
.principle-card p,
.footer-copy,
.legal-card p {
  color: var(--soft-ink);
}

.hero-copy {
  margin: 1rem 0 0;
  max-width: 42rem;
  font-size: 1.08rem;
}

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

.button-primary,
.button-secondary,
.tool-link,
.project-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.9rem 1.15rem;
  border-radius: 999px;
  font-weight: 700;
  text-decoration: none;
}

.button-primary,
.tool-link,
.project-button {
  background: var(--accent);
  color: white;
}

.button-primary:hover,
.tool-link:hover,
.project-button:hover,
.button-primary:focus-visible,
.tool-link:focus-visible,
.project-button:focus-visible {
  background: var(--accent-strong);
  color: white;
}

.button-secondary {
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.72);
}

:root[data-theme="dark"] .button-secondary {
  background: rgba(23, 35, 49, 0.9);
}

.hero-points {
  margin: 1.2rem 0 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.hero-points li,
.status-pill {
  padding: 0.48rem 0.75rem;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.8);
  border: 1px solid var(--line);
  font-size: 0.92rem;
}

:root[data-theme="dark"] .hero-points li,
:root[data-theme="dark"] .status-pill {
  background: rgba(23, 35, 49, 0.92);
}

.hero-board {
  display: grid;
  gap: 0.9rem;
  align-content: start;
}

.board-photo,
.board-note {
  border-radius: 1.25rem;
  border: 1px dashed rgba(34, 49, 63, 0.16);
  transform: rotate(-1deg);
}

.board-photo {
  min-height: 13rem;
  overflow: hidden;
  padding: 0;
  background:
    radial-gradient(circle at top left, rgba(255, 255, 255, 0.8), transparent 44%),
    linear-gradient(135deg, rgba(255, 255, 255, 0.6), rgba(245, 245, 245, 0.92));
}

.board-photo img {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 13rem;
  object-fit: cover;
}

.board-note {
  padding: 1rem;
}

.board-note {
  box-shadow: 0 14px 28px rgba(57, 53, 41, 0.08);
}

.board-note-yellow {
  background: rgba(255, 245, 202, 0.94);
}

.board-note-blue {
  transform: rotate(1.2deg);
  background: rgba(217, 241, 247, 0.94);
}

:root[data-theme="dark"] .board-note-yellow {
  background: rgba(106, 88, 33, 0.92);
}

:root[data-theme="dark"] .board-note-blue {
  background: rgba(26, 73, 88, 0.94);
}

.board-title,
.footer-title {
  margin: 0;
  font-weight: 800;
}

.section-block,
.legal-card {
  padding: 1.5rem;
}

.section-heading {
  margin-bottom: 1rem;
}

.project-grid,
.story-grid,
.principles-grid {
  display: grid;
  gap: 1rem;
}

.project-grid {
  grid-template-columns: minmax(0, 1.2fr) minmax(18rem, 0.8fr);
}

.story-grid,
.principles-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.project-card,
.story-card,
.principle-card {
  border-radius: 1.3rem;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.72);
  padding: 1.25rem;
}

:root[data-theme="dark"] .project-card,
:root[data-theme="dark"] .story-card,
:root[data-theme="dark"] .principle-card {
  background: rgba(19, 30, 43, 0.8);
}

.project-card-featured {
  background:
    radial-gradient(circle at top right, rgba(255, 255, 255, 0.75), transparent 34%),
    linear-gradient(135deg, rgba(255, 243, 212, 0.95), rgba(223, 240, 236, 0.82));
}

:root[data-theme="dark"] .project-card-featured {
  background:
    radial-gradient(circle at top right, rgba(255, 255, 255, 0.08), transparent 34%),
    linear-gradient(145deg, rgba(48, 56, 29, 0.94), rgba(18, 53, 62, 0.88));
}

.project-card-placeholder {
  display: grid;
  align-content: center;
  min-height: 100%;
}

.project-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.35rem;
}

.project-facts {
  margin: 1rem 0 0;
  padding-left: 1.1rem;
  color: var(--soft-ink);
}

.project-button {
  margin-top: 1rem;
}

.site-footer {
  padding: 1.25rem 1.5rem;
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: flex-start;
}

.legal-card {
  max-width: 54rem;
}

.legal-warning {
  margin-top: 0.9rem;
  padding: 0.9rem 1rem;
  border-radius: 1rem;
  background: rgba(231, 111, 81, 0.12);
  border: 1px solid rgba(231, 111, 81, 0.24);
}

.legal-section + .legal-section {
  margin-top: 1.5rem;
}

.legal-section p {
  margin: 0.55rem 0 0;
}

@media (max-width: 980px) {
  .hero-panel,
  .project-grid,
  .story-grid,
  .principles-grid,
  .site-footer {
    grid-template-columns: 1fr;
  }

  .site-footer {
    display: grid;
  }
}

@media (max-width: 720px) {
  .site-shell,
  .legal-shell {
    padding: 1rem;
  }

  .topbar,
  .legal-header {
    display: grid;
    justify-content: stretch;
  }

  .topnav,
  .footer-links {
    gap: 0.75rem;
  }

  .hero-copy-block h1 {
    max-width: none;
  }
}
