:root {
  color-scheme: light;
  --paper: #f7f3e8;
  --surface: #fffdf7;
  --surface-strong: #ffffff;
  --ink: #17202a;
  --muted: #667085;
  --line: #ded6c7;
  --brand: #b11d2a;
  --brand-dark: #871723;
  --gold: #d6a63d;
  --teal: #1d6f6f;
  --blue: #16324f;
  --shadow: 0 18px 50px rgba(36, 31, 24, 0.12);
  font-family: Inter, "Noto Sans Devanagari", Mangal, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background:
    linear-gradient(180deg, rgba(255, 255, 255, 0.65), rgba(247, 243, 232, 0.9)),
    var(--paper);
  color: var(--ink);
}

a {
  color: inherit;
}

button,
input {
  font: inherit;
}

.site-shell {
  min-height: 100vh;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 14px clamp(18px, 5vw, 72px);
  border-bottom: 1px solid rgba(222, 214, 199, 0.86);
  background: rgba(255, 253, 247, 0.92);
  backdrop-filter: blur(14px);
}

.brand.compact {
  margin-bottom: 0;
  text-decoration: none;
}

.site-nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 4px;
}

.site-nav a {
  display: inline-flex;
  align-items: center;
  min-height: 36px;
  padding: 0 12px;
  border-radius: 8px;
  color: var(--blue);
  font-size: 0.94rem;
  font-weight: 800;
  text-decoration: none;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  background: #f0e8d9;
  color: var(--brand);
}

.menu-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 4px;
  width: 42px;
  height: 42px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-strong);
  cursor: pointer;
  transition: border-color 160ms ease, background-color 160ms ease, box-shadow 160ms ease;
}

.menu-toggle span {
  display: block;
  width: 19px;
  height: 2px;
  border-radius: 999px;
  background: var(--blue);
  transition: transform 180ms ease, opacity 180ms ease, background-color 160ms ease;
}

.menu-toggle:hover {
  border-color: var(--brand);
  background: #fff8ec;
  box-shadow: 0 8px 18px rgba(36, 31, 24, 0.08);
}

.nav-open .menu-toggle {
  border-color: var(--brand);
  background: #fff8ec;
}

.nav-open .menu-toggle span {
  background: var(--brand);
}

.nav-open .menu-toggle span:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.nav-open .menu-toggle span:nth-child(2) {
  opacity: 0;
}

.nav-open .menu-toggle span:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.hero {
  min-height: 68vh;
  display: grid;
  grid-template-columns: minmax(0, 1.08fr) minmax(320px, 0.92fr);
  align-items: center;
  gap: clamp(28px, 5vw, 76px);
  padding: 28px clamp(18px, 5vw, 72px) 36px;
  border-bottom: 1px solid var(--line);
}

.page-hero {
  padding: clamp(54px, 9vw, 108px) clamp(18px, 5vw, 72px) clamp(34px, 6vw, 72px);
  border-bottom: 1px solid var(--line);
}

.page-hero h1 {
  max-width: 980px;
  font-size: clamp(2.8rem, 6vw, 5.7rem);
}

.page-hero p:not(.eyebrow) {
  max-width: 820px;
  margin: 22px 0 0;
  color: #394354;
  font-size: clamp(1.05rem, 2vw, 1.24rem);
  line-height: 1.72;
}

.about-hero {
  min-height: 68vh;
  display: grid;
  grid-template-columns: minmax(0, 1.05fr) minmax(300px, 0.72fr);
  align-items: center;
  gap: clamp(28px, 5vw, 72px);
  padding: clamp(46px, 8vw, 100px) clamp(18px, 5vw, 72px);
  border-bottom: 1px solid var(--line);
}

.about-hero h1 {
  max-width: 920px;
  font-size: clamp(3rem, 7vw, 6.4rem);
}

.about-hero p:not(.eyebrow) {
  max-width: 760px;
  margin: 22px 0 0;
  color: #394354;
  font-size: clamp(1.05rem, 2vw, 1.27rem);
  line-height: 1.72;
}

.about-book {
  display: grid;
  grid-template-columns: 74px minmax(0, 1fr);
  min-height: 420px;
  border: 1px solid rgba(22, 50, 79, 0.14);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.book-spine {
  display: grid;
  place-items: center;
  background: var(--brand);
  color: #fff;
  font-size: 1.8rem;
  font-weight: 900;
  writing-mode: vertical-rl;
  text-orientation: mixed;
}

.book-pages {
  position: relative;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 28px;
  background:
    repeating-linear-gradient(180deg, rgba(214, 166, 61, 0.16) 0 1px, transparent 1px 34px),
    var(--surface-strong);
}

.book-pages span {
  color: var(--brand);
  font-size: 0.86rem;
  font-weight: 900;
  text-transform: uppercase;
}

.book-pages strong {
  display: block;
  margin-top: 12px;
  color: var(--blue);
  font-size: clamp(2.3rem, 5vw, 4.4rem);
  line-height: 1;
}

.book-pages p {
  max-width: 290px;
  margin: 14px 0 0;
  color: #4d5968;
  line-height: 1.65;
}

.book-lines {
  display: grid;
  gap: 9px;
  margin-top: 28px;
}

.book-lines i {
  display: block;
  height: 8px;
  border-radius: 999px;
  background: #e8dfcd;
}

.book-lines i:nth-child(2) {
  width: 78%;
}

.book-lines i:nth-child(3) {
  width: 88%;
}

.book-lines i:nth-child(4) {
  width: 58%;
}

.about-statement {
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(280px, 0.55fr);
  gap: clamp(24px, 5vw, 72px);
  align-items: end;
  padding: clamp(36px, 6vw, 76px) clamp(18px, 5vw, 72px);
  border-bottom: 1px solid var(--line);
  background: var(--surface-strong);
}

.about-statement h2,
.section-heading h2 {
  max-width: 900px;
  margin: 0;
  color: var(--blue);
  font-size: clamp(2.2rem, 4.5vw, 4.2rem);
  line-height: 1.05;
}

.about-statement > p {
  margin: 0;
  color: #4d5968;
  font-size: 1.05rem;
  line-height: 1.75;
}

.open-band {
  background: linear-gradient(180deg, rgba(255, 253, 247, 0.8), rgba(247, 243, 232, 0.98));
}

.section-heading {
  margin-bottom: 26px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 44px;
  color: var(--blue);
  font-weight: 800;
}

.brand img {
  width: 34px;
  height: 34px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--brand);
  font-size: 0.86rem;
  font-weight: 800;
  letter-spacing: 0;
  text-transform: uppercase;
}

h1 {
  max-width: 780px;
  margin: 0;
  color: var(--blue);
  font-size: clamp(3.2rem, 8vw, 7rem);
  line-height: 0.95;
  letter-spacing: 0;
}

.hero-copy {
  max-width: 700px;
  margin: 22px 0 0;
  color: #394354;
  font-size: clamp(1.05rem, 2vw, 1.3rem);
  line-height: 1.65;
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 34px;
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 46px;
  padding: 0 18px;
  border: 1px solid var(--brand);
  border-radius: 8px;
  background: var(--brand);
  color: #fff;
  font-weight: 800;
  text-decoration: none;
}

.button.secondary {
  border-color: var(--line);
  background: var(--surface-strong);
  color: var(--blue);
}

.hero-panel {
  width: 100%;
  max-width: 520px;
  justify-self: end;
  border: 1px solid rgba(22, 50, 79, 0.14);
  border-radius: 8px;
  background: rgba(255, 253, 247, 0.86);
  box-shadow: var(--shadow);
  overflow: hidden;
}

.panel-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 18px;
  border-bottom: 1px solid var(--line);
  background: #fff;
}

.panel-title {
  margin: 0;
  color: var(--blue);
  font-weight: 900;
}

.script-mark {
  display: grid;
  place-items: center;
  width: 42px;
  height: 42px;
  border-radius: 8px;
  background: var(--brand);
  color: #fff;
  font-size: 1.45rem;
  font-weight: 900;
}

.sample-entry {
  padding: 22px;
}

.sample-word {
  margin: 0 0 8px;
  color: var(--blue);
  font-size: clamp(2.7rem, 6vw, 4.8rem);
  line-height: 1.05;
}

.sample-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
}

.chip {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #fff;
  color: var(--blue);
  font-size: 0.86rem;
  font-weight: 800;
}

.sample-entry p {
  margin: 0;
  color: #394354;
  font-size: 1.05rem;
  line-height: 1.75;
}

.stats {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  border-bottom: 1px solid var(--line);
  background: var(--surface-strong);
}

.stat {
  padding: 22px clamp(18px, 4vw, 48px);
  border-right: 1px solid var(--line);
}

.stat:last-child {
  border-right: 0;
}

.stat strong {
  display: block;
  color: var(--blue);
  font-size: clamp(1.45rem, 3vw, 2.15rem);
}

.stat span {
  color: var(--muted);
  font-size: 0.92rem;
}

.dictionary {
  padding: clamp(28px, 5vw, 64px) clamp(18px, 5vw, 72px) 72px;
}

.dictionary-header {
  display: grid;
  grid-template-columns: minmax(0, 0.75fr) minmax(280px, 0.25fr);
  gap: 24px;
  align-items: end;
  margin-bottom: 24px;
}

.dictionary-header h2 {
  margin: 0 0 10px;
  color: var(--blue);
  font-size: clamp(2rem, 4vw, 3.4rem);
  line-height: 1.05;
}

.dictionary-header p {
  max-width: 760px;
  margin: 0;
  color: #4d5968;
  line-height: 1.7;
}

.status {
  justify-self: end;
  color: var(--teal);
  font-weight: 800;
}

.search-wrap {
  position: sticky;
  top: 0;
  z-index: 5;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  padding: 14px 0;
  background: rgba(247, 243, 232, 0.92);
  backdrop-filter: blur(12px);
}

.search-input {
  width: 100%;
  min-height: 58px;
  padding: 0 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-strong);
  color: var(--ink);
  font-size: 1.08rem;
  outline: none;
}

.search-input:focus {
  border-color: var(--teal);
  box-shadow: 0 0 0 4px rgba(29, 111, 111, 0.13);
}

.clear-button {
  min-width: 92px;
  min-height: 58px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-strong);
  color: var(--blue);
  cursor: pointer;
  font-weight: 800;
}

.clear-button:hover {
  border-color: var(--blue);
}

.results-meta {
  min-height: 28px;
  margin: 4px 0 18px;
  color: var(--muted);
}

.results {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
}

.entry-card {
  min-width: 0;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-strong);
  box-shadow: 0 10px 24px rgba(36, 31, 24, 0.06);
}

.entry-card header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 18px 12px;
  border-bottom: 1px solid #eee6d8;
}

.entry-card h3 {
  margin: 0;
  color: var(--blue);
  font-size: clamp(1.7rem, 3vw, 2.35rem);
  line-height: 1.2;
  overflow-wrap: anywhere;
}

.entry-count {
  flex: 0 0 auto;
  color: var(--muted);
  font-size: 0.86rem;
  font-weight: 800;
}

.definition {
  padding: 16px 18px 18px;
}

.definition + .definition {
  border-top: 1px solid #eee6d8;
}

.definition-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 10px;
}

.definition ol {
  display: grid;
  gap: 8px;
  margin: 0;
  padding-left: 1.35rem;
  color: #344054;
  line-height: 1.72;
}

.empty {
  grid-column: 1 / -1;
  padding: 42px;
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.58);
  color: var(--muted);
  text-align: center;
}

.content-band {
  padding: clamp(28px, 5vw, 64px) clamp(18px, 5vw, 72px);
  border-bottom: 1px solid var(--line);
}

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

.info-panel {
  min-width: 0;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-strong);
}

.info-panel.prominent {
  border-top: 4px solid var(--brand);
}

.feature-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(300px, 0.55fr);
  gap: clamp(18px, 4vw, 48px);
  align-items: center;
}

.feature-split h2 {
  max-width: 780px;
  margin: 0;
  color: var(--blue);
  font-size: clamp(2.1rem, 4vw, 4rem);
  line-height: 1.05;
}

.feature-split p:not(.eyebrow),
.credit-panel p {
  color: #4d5968;
  line-height: 1.72;
}

.credit-panel {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-strong);
  box-shadow: var(--shadow);
}

.credit-panel p:last-child {
  margin-bottom: 0;
}

.credit-panel span {
  color: var(--brand);
  font-weight: 900;
}

.credit-panel a {
  color: var(--blue);
  font-weight: 900;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

.info-panel h2,
.docs-content h2 {
  margin: 0 0 12px;
  color: var(--blue);
  font-size: clamp(1.35rem, 2vw, 1.8rem);
  line-height: 1.2;
}

.info-panel p,
.docs-content p {
  margin: 0 0 14px;
  color: #4d5968;
  line-height: 1.72;
}

.metric-list {
  display: grid;
  gap: 10px;
  margin: 18px 0 0;
}

.metric-list div {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 14px;
  padding-bottom: 10px;
  border-bottom: 1px solid #eee6d8;
}

.metric-list div:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.metric-list dt {
  color: var(--muted);
  font-weight: 700;
}

.metric-list dd {
  margin: 0;
  color: var(--blue);
  font-weight: 900;
}

.text-link {
  color: var(--brand);
  font-weight: 900;
  text-decoration-thickness: 2px;
  text-underline-offset: 3px;
}

.principles {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  border-bottom: 1px solid var(--line);
  background: var(--surface-strong);
}

.identity-band {
  display: grid;
  grid-template-columns: minmax(0, 0.95fr) minmax(300px, 0.55fr);
  gap: clamp(22px, 5vw, 64px);
  align-items: center;
  padding: clamp(34px, 6vw, 76px) clamp(18px, 5vw, 72px);
  border-bottom: 1px solid var(--line);
  background:
    linear-gradient(180deg, rgba(255, 253, 247, 0.86), rgba(247, 243, 232, 0.98));
}

.identity-copy h2 {
  max-width: 860px;
  margin: 0;
  color: var(--blue);
  font-size: clamp(2.2rem, 4.7vw, 4.4rem);
  line-height: 1.05;
}

.identity-copy p:not(.eyebrow) {
  max-width: 740px;
  margin: 18px 0 0;
  color: #4d5968;
  font-size: 1.05rem;
  line-height: 1.75;
}

.support-panel {
  padding: 26px;
  border: 1px solid rgba(22, 50, 79, 0.14);
  border-radius: 8px;
  background: var(--surface-strong);
  box-shadow: var(--shadow);
}

.support-panel span {
  color: var(--brand);
  font-size: 0.8rem;
  font-weight: 900;
  text-transform: uppercase;
}

.support-panel strong {
  display: block;
  margin-top: 12px;
  color: var(--blue);
  font-size: clamp(2.2rem, 5vw, 4rem);
  line-height: 1;
}

.support-panel strong a {
  color: inherit;
  text-decoration: none;
}

.support-panel strong a:hover {
  color: var(--brand);
}

.support-panel p {
  margin: 16px 0 0;
  color: #4d5968;
  line-height: 1.72;
}

.principle {
  min-width: 0;
  padding: clamp(24px, 4vw, 48px);
  border-right: 1px solid var(--line);
}

.principle:last-child {
  border-right: 0;
}

.principle span {
  color: var(--brand);
  font-weight: 900;
}

.principle h2 {
  margin: 14px 0 10px;
  color: var(--blue);
  font-size: clamp(1.7rem, 3vw, 2.6rem);
}

.principle p {
  margin: 0;
  color: #4d5968;
  line-height: 1.7;
}

.explore-shell {
  padding: clamp(24px, 5vw, 56px) clamp(18px, 5vw, 72px) 76px;
}

.explore-tools {
  position: sticky;
  top: 65px;
  z-index: 10;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 12px;
  padding: 14px 0;
  background: rgba(247, 243, 232, 0.94);
  backdrop-filter: blur(12px);
}

.letter-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 10px 0 22px;
}

.letter-button {
  display: grid;
  place-items: center;
  min-width: 62px;
  min-height: 58px;
  padding: 6px 10px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-strong);
  color: var(--blue);
  cursor: pointer;
}

.letter-button span {
  font-size: 1.45rem;
  font-weight: 900;
  line-height: 1;
}

.letter-button small {
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 800;
}

.letter-button:hover,
.letter-button.active {
  border-color: var(--brand);
  background: var(--brand);
  color: #fff;
}

.letter-button:hover small,
.letter-button.active small {
  color: rgba(255, 255, 255, 0.78);
}

.explore-layout {
  display: grid;
  grid-template-columns: minmax(280px, 0.34fr) minmax(0, 0.66fr);
  gap: 18px;
  align-items: start;
}

.word-browser,
.entry-viewer {
  min-width: 0;
}

.word-browser {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-strong);
  overflow: hidden;
}

.browser-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  padding: 16px;
  border-bottom: 1px solid var(--line);
}

.browser-head h2 {
  margin: 0;
  color: var(--blue);
  font-size: 1.35rem;
}

.browser-head p,
.browser-head span {
  margin: 4px 0 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.browser-head span {
  flex: 0 0 auto;
  font-weight: 800;
}

.word-list {
  display: grid;
  max-height: 650px;
  overflow: auto;
}

.word-button {
  min-height: 44px;
  padding: 8px 16px;
  border: 0;
  border-bottom: 1px solid #eee6d8;
  background: transparent;
  color: var(--blue);
  cursor: pointer;
  font-size: 1.05rem;
  font-weight: 800;
  text-align: left;
}

.word-button:hover {
  background: #f8f0e2;
  color: var(--brand);
}

.selected-entry {
  box-shadow: var(--shadow);
}

.compact-empty {
  padding: 22px;
}

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

.endpoint {
  display: grid;
  gap: 8px;
  min-height: 132px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface-strong);
  color: inherit;
  text-decoration: none;
}

.endpoint:hover {
  border-color: var(--teal);
  box-shadow: 0 10px 24px rgba(36, 31, 24, 0.08);
}

.endpoint span {
  color: var(--brand);
  font-family: "Consolas", "SFMono-Regular", monospace;
  font-size: 0.92rem;
  overflow-wrap: anywhere;
}

.endpoint strong {
  color: var(--blue);
  font-size: 1.05rem;
  line-height: 1.4;
}

.docs-layout {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr);
  gap: clamp(20px, 4vw, 42px);
  padding: clamp(28px, 5vw, 64px) clamp(18px, 5vw, 72px) 76px;
}

.docs-sidebar {
  position: sticky;
  top: 86px;
  align-self: start;
  display: grid;
  gap: 6px;
}

.docs-sidebar a {
  padding: 10px 12px;
  border-radius: 8px;
  color: var(--blue);
  font-weight: 800;
  text-decoration: none;
}

.docs-sidebar a:hover {
  background: #f0e8d9;
  color: var(--brand);
}

.docs-content {
  display: grid;
  gap: 34px;
  min-width: 0;
}

.docs-content section {
  min-width: 0;
}

pre {
  margin: 14px 0 0;
  padding: 18px;
  border: 1px solid #d9deea;
  border-radius: 8px;
  background: #101828;
  color: #eef4ff;
  overflow-x: auto;
}

code {
  font-family: "Consolas", "SFMono-Regular", monospace;
  font-size: 0.94rem;
  line-height: 1.65;
}

.footer {
  position: relative;
  padding: 0 clamp(18px, 5vw, 72px);
  border-top: 1px solid var(--line);
  background:
    linear-gradient(180deg, #17385c, var(--blue));
  color: #fff;
}

.footer::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 4px;
  background: linear-gradient(90deg, var(--brand), var(--gold), var(--teal));
}

.footer-main {
  display: grid;
  grid-template-columns: minmax(240px, 0.9fr) minmax(360px, 1.1fr);
  gap: clamp(28px, 6vw, 86px);
  padding: clamp(34px, 6vw, 64px) 0 30px;
}

.footer-intro p {
  max-width: 560px;
  margin: 10px 0 0;
  color: rgba(255, 255, 255, 0.78);
  line-height: 1.6;
}

.footer-links {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: clamp(18px, 4vw, 46px);
}

.footer-links div {
  display: grid;
  align-content: start;
  gap: 10px;
}

.footer-links span {
  color: rgba(255, 255, 255, 0.58);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
}

.footer-links a {
  color: #fff;
  font-weight: 800;
  text-decoration: none;
}

.footer-links a:hover {
  color: #f2ca66;
}

.footer-brand {
  display: inline-flex;
  color: #fff;
  font-size: clamp(1.7rem, 3vw, 2.4rem);
  font-weight: 900;
  line-height: 1;
  text-decoration: none;
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 18px 0 22px;
  border-top: 1px solid rgba(255, 255, 255, 0.14);
  color: rgba(255, 255, 255, 0.68);
  font-size: 0.9rem;
}

.scroll-toggle {
  position: fixed;
  right: clamp(16px, 3vw, 28px);
  bottom: clamp(16px, 3vw, 28px);
  z-index: 30;
  display: grid;
  place-items: center;
  width: 48px;
  height: 48px;
  border: 1px solid rgba(255, 255, 255, 0.26);
  border-radius: 999px;
  background: var(--brand);
  box-shadow: 0 18px 38px rgba(36, 31, 24, 0.22);
  cursor: pointer;
  transition: transform 160ms ease, background-color 160ms ease, box-shadow 160ms ease;
}

.scroll-toggle:hover {
  background: var(--brand-dark);
  box-shadow: 0 22px 46px rgba(36, 31, 24, 0.28);
  transform: translateY(-2px);
}

.scroll-toggle span {
  width: 13px;
  height: 13px;
  border-right: 3px solid #fff;
  border-bottom: 3px solid #fff;
  transform: translateY(-3px) rotate(45deg);
  transition: transform 180ms ease;
}

.scroll-toggle.is-up span {
  transform: translateY(3px) rotate(225deg);
}

@media (max-width: 920px) {
  .hero {
    grid-template-columns: 1fr;
    min-height: auto;
  }

  .hero-panel {
    justify-self: stretch;
    max-width: none;
  }

  .about-hero,
  .about-statement,
  .principles,
  .identity-band {
    grid-template-columns: 1fr;
  }

  .about-book {
    min-height: 340px;
  }

  .stats,
  .results,
  .content-grid,
  .endpoint-grid,
  .feature-split,
  .explore-layout {
    grid-template-columns: 1fr 1fr;
  }

  .dictionary-header {
    grid-template-columns: 1fr;
  }

  .status {
    justify-self: start;
  }

  .docs-layout,
  .footer-main,
  .feature-split,
  .explore-layout {
    grid-template-columns: 1fr;
  }

  .docs-sidebar {
    position: static;
    display: flex;
    flex-wrap: wrap;
  }

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

@media (max-width: 620px) {
  .site-header {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
  }

  .menu-toggle {
    display: grid;
  }

  .site-nav {
    grid-column: 1 / -1;
    display: none;
    width: 100%;
    padding-top: 8px;
    border-top: 1px solid var(--line);
  }

  .nav-open .site-nav {
    display: grid;
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .site-nav a {
    justify-content: flex-start;
    min-height: 44px;
    padding: 0 10px;
  }

  .stats,
  .results,
  .search-wrap,
  .explore-tools,
  .content-grid,
  .endpoint-grid,
  .footer-links {
    grid-template-columns: 1fr;
  }

  .footer-bottom {
    align-items: flex-start;
    flex-direction: column;
  }

  .stat {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .stat:last-child {
    border-bottom: 0;
  }

  .about-book {
    grid-template-columns: 54px minmax(0, 1fr);
    min-height: 300px;
  }

  .book-spine {
    font-size: 1.35rem;
  }

  .clear-button {
    min-height: 48px;
  }

  .scroll-toggle {
    width: 44px;
    height: 44px;
  }
}
