:root {
  --ink: #172321;
  --muted: #61706c;
  --paper: #f5f4ef;
  --surface: #ffffff;
  --surface-soft: #ebece5;
  --forest: #173b38;
  --forest-2: #24534d;
  --mint: #bde8db;
  --mint-light: #e3f4ee;
  --coral: #ff8066;
  --yellow: #f4cc64;
  --line: #d8ddd7;
  --shadow: 0 20px 60px rgba(24, 53, 49, 0.1);
  --radius-lg: 32px;
  --radius-md: 20px;
  --radius-sm: 12px;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  color-scheme: light;
  scroll-behavior: smooth;
}

body {
  min-width: 320px;
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: "Public Sans Web", "Segoe UI", Arial, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
}

body.nav-open {
  overflow: hidden;
}

button,
input,
summary {
  font: inherit;
}

button,
summary,
a {
  -webkit-tap-highlight-color: transparent;
}

a {
  text-underline-offset: 0.18em;
}

a:hover {
  text-decoration-thickness: 2px;
}

img,
canvas {
  max-width: 100%;
}

:focus-visible {
  outline: 3px solid var(--coral);
  outline-offset: 3px;
}

.visually-hidden {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0, 0, 0, 0) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

.skip-link {
  position: fixed;
  top: 12px;
  left: 12px;
  z-index: 10000002;
  padding: 12px 16px;
  border-radius: 10px;
  background: var(--surface);
  color: var(--ink);
  font-weight: 700;
  transform: translateY(-150%);
  transition: transform 0.15s ease;
}

.skip-link:focus {
  transform: translateY(0);
}

.wrapper {
  min-height: 100vh;
  background: var(--paper);
}

/* Header */
.navi-top {
  position: relative;
  z-index: 1002;
  width: 100%;
  height: auto;
  min-height: 76px;
  padding: 0 24px;
  background: rgba(255, 255, 255, 0.96);
  border: 0;
  border-bottom: 1px solid var(--line);
  box-shadow: none;
  color: var(--ink);
  font-family: "Public Sans Web", "Segoe UI", Arial, sans-serif;
  letter-spacing: normal;
  text-align: left;
}

.site-header-inner {
  width: 100%;
  max-width: 1180px;
  min-height: 76px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 24px;
}

.site-brand,
.site-brand:link,
.site-brand:visited {
  display: inline-flex;
  width: fit-content;
  flex-direction: column;
  gap: 1px;
  color: var(--ink);
  text-decoration: none;
}

.site-brand-name {
  font-size: 1.28rem;
  font-weight: 800;
  line-height: 1.1;
  letter-spacing: -0.045em;
}

.site-brand-name strong {
  color: var(--forest-2);
}

.site-brand-tagline {
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 500;
  line-height: 1.3;
  letter-spacing: 0.025em;
}

.header-search-link,
.header-search-link:link,
.header-search-link:visited {
  min-height: 42px;
  padding: 9px 17px;
  border-radius: 999px;
  background: var(--forest);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.88rem;
  font-weight: 700;
  text-decoration: none;
  transition: background 0.18s ease, transform 0.18s ease;
}

.header-search-link:hover {
  background: var(--forest-2);
  transform: translateY(-1px);
}

.btn-menu {
  display: none;
  position: static;
  width: 44px;
  height: 44px;
  padding: 0;
  border: 1px solid var(--line);
  border-radius: 50%;
  background: var(--surface);
  color: var(--ink);
  align-items: center;
  justify-content: center;
  cursor: pointer;
}

.menu-icon {
  display: grid;
  gap: 4px;
  width: 18px;
}

.menu-icon span {
  display: block;
  width: 100%;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
}

/* Primary navigation */
.navi {
  position: relative;
  z-index: 1001;
  float: none;
  width: 100%;
  min-height: 0;
  height: auto;
  margin: 0;
  padding: 0 24px;
  overflow: visible;
  border-radius: 0;
  border-bottom: 1px solid var(--line);
  background: var(--surface);
  box-shadow: none;
  color: var(--ink);
  font-family: "Public Sans Web", "Segoe UI", Arial, sans-serif;
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.25;
  transition: none;
}

.navi-inner {
  position: relative;
  width: 100%;
  max-width: 1180px;
  min-height: 54px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  gap: 4px;
}

.navi-mobile-header {
  display: none;
}

.nav-link,
.nav-link:link,
.nav-link:visited,
.nav-more > summary {
  min-height: 40px;
  padding: 10px 14px;
  border-radius: 999px;
  color: #33433f;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  cursor: pointer;
  list-style: none;
  transition: color 0.16s ease, background 0.16s ease;
}

.nav-link:hover,
.nav-more > summary:hover {
  background: var(--mint-light);
  color: var(--forest);
  text-decoration: none;
}

.nav-more {
  position: relative;
  margin-left: auto;
}

.nav-more > summary::-webkit-details-marker {
  display: none;
}

.nav-more > summary::after {
  content: "+";
  margin-left: 7px;
  color: var(--muted);
  font-size: 1rem;
  line-height: 1;
}

.nav-more[open] > summary::after {
  content: "−";
}

.nav-more-menu {
  position: absolute;
  top: calc(100% + 7px);
  right: 0;
  width: 220px;
  padding: 8px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
  box-shadow: var(--shadow);
}

.nav-more-menu a,
.nav-more-menu a:link,
.nav-more-menu a:visited {
  display: block;
  padding: 10px 12px;
  border-radius: 10px;
  color: var(--ink);
  text-decoration: none;
}

.nav-more-menu a:hover {
  background: var(--mint-light);
}

.screen-blocker {
  position: fixed;
  inset: 0;
  z-index: 100000;
  display: block;
  width: 100%;
  height: 100%;
  padding: 0;
  border: 0;
  background: rgba(8, 24, 22, 0.56);
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: opacity 0.22s ease, visibility 0.22s ease;
}

/* Main shell */
.middle {
  width: 100%;
  max-width: none;
  min-height: 0;
  margin: 0;
  overflow: visible;
}

.section {
  display: block;
  width: 100%;
  max-width: 1180px;
  min-height: 60vh;
  margin: 0 auto;
  padding: 34px 24px 88px;
  background: transparent;
  box-shadow: none;
}

.section > :first-child {
  margin-top: 0;
}

.section p,
.section li {
  line-height: 1.65;
}

/* Home */
.home-page {
  display: grid;
  gap: 84px;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--forest-2);
  font-size: 0.76rem;
  font-weight: 800;
  line-height: 1.3;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.home-hero {
  position: relative;
  isolation: isolate;
  min-height: 560px;
  padding: clamp(34px, 6vw, 72px);
  overflow: hidden;
  border-radius: var(--radius-lg);
  background: var(--forest);
  color: #fff;
  display: grid;
  grid-template-columns: minmax(0, 1.25fr) minmax(300px, 0.75fr);
  align-items: center;
  gap: clamp(36px, 7vw, 80px);
}

.home-hero::before,
.home-hero::after {
  content: "";
  position: absolute;
  z-index: -1;
  border-radius: 50%;
  pointer-events: none;
}

.home-hero::before {
  width: 420px;
  height: 420px;
  right: -180px;
  top: -210px;
  border: 72px solid rgba(189, 232, 219, 0.13);
}

.home-hero::after {
  width: 180px;
  height: 180px;
  left: 45%;
  bottom: -115px;
  background: var(--coral);
  opacity: 0.9;
}

.home-hero .eyebrow {
  color: var(--mint);
}

.home-hero h1 {
  max-width: 760px;
  margin: 0;
  color: #fff;
  font-size: clamp(2.5rem, 5.6vw, 4.75rem);
  font-weight: 800;
  line-height: 0.98;
  letter-spacing: -0.065em;
}

.home-hero h1 span {
  color: var(--mint);
}

.home-hero-lede {
  max-width: 680px;
  margin: 26px 0 0;
  color: rgba(255, 255, 255, 0.82);
  font-size: clamp(1rem, 1.5vw, 1.18rem);
}

.hero-search-form,
.search-landing-form {
  margin: 32px 0 0;
}

.hero-search-form .input-wrapper,
.search-landing-form .input-wrapper {
  width: 100%;
  max-width: 680px;
  height: 62px;
  margin: 0;
  padding: 5px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.32);
  border-radius: 18px;
  background: var(--surface);
  box-shadow: 0 14px 36px rgba(0, 0, 0, 0.16);
  opacity: 1;
}

.hero-search-form .input-wrapper:focus-within,
.search-landing-form .input-wrapper:focus-within {
  border-color: var(--mint);
  box-shadow: 0 0 0 4px rgba(189, 232, 219, 0.2), 0 14px 36px rgba(0, 0, 0, 0.16);
}

.hero-search-form .input-text-name,
.search-landing-form .input-text-name {
  height: 50px;
  color: var(--ink);
  font-size: 1rem;
}

.hero-search-form .btn-search,
.search-landing-form .btn-search {
  width: auto;
  min-width: 132px;
  height: 50px;
  padding: 0 20px;
  border-radius: 13px;
  background: var(--coral);
  color: #172321;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  font-size: 0.9rem;
  font-weight: 800;
}

.hero-search-form .btn-search:hover,
.search-landing-form .btn-search:hover {
  background: #ff977f;
  box-shadow: none;
  transform: none;
}

.search-suggestions {
  margin-top: 16px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  color: rgba(255, 255, 255, 0.64);
  font-size: 0.8rem;
}

.search-suggestions a,
.search-suggestions a:link,
.search-suggestions a:visited {
  padding: 4px 9px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  color: #fff;
  text-decoration: none;
}

.search-suggestions a:hover {
  border-color: var(--mint);
  background: rgba(189, 232, 219, 0.12);
}

.hero-report-preview {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 360px;
  margin-left: auto;
  padding: 28px;
  border: 1px solid rgba(255, 255, 255, 0.7);
  border-radius: 26px;
  background: #fbfaf6;
  color: var(--ink);
  box-shadow: 18px 24px 0 rgba(189, 232, 219, 0.18);
  transform: rotate(1.5deg);
}

.preview-topline {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.preview-status {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.preview-status i {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: #4fa58f;
}

.preview-name {
  margin: 32px 0 0;
  color: var(--forest);
  font-size: 3.15rem;
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.065em;
}

.preview-pronunciation {
  margin: 6px 0 24px;
  color: var(--muted);
  font-size: 0.88rem;
}

.preview-insights {
  display: grid;
  gap: 0;
  border-top: 1px solid var(--line);
}

.preview-insights > div {
  padding: 14px 0;
  border-bottom: 1px solid var(--line);
  display: grid;
  grid-template-columns: 74px 1fr;
  gap: 10px;
}

.preview-insights span {
  color: var(--muted);
  font-size: 0.74rem;
}

.preview-insights strong {
  font-size: 0.82rem;
  font-weight: 700;
}

.preview-caption {
  margin: 14px 0 0;
  color: var(--muted);
  font-size: 0.7rem;
}

.trust-strip {
  margin-top: -56px;
  padding: 0 30px;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0;
}

.trust-strip > div {
  padding: 22px 28px;
  border-right: 1px solid var(--line);
  background: var(--surface);
  display: grid;
  gap: 3px;
}

.trust-strip > div:first-child {
  border-radius: 18px 0 0 18px;
}

.trust-strip > div:last-child {
  border-right: 0;
  border-radius: 0 18px 18px 0;
}

.trust-strip strong {
  color: var(--forest);
  font-size: 1rem;
  font-weight: 800;
}

.trust-strip span {
  color: var(--muted);
  font-size: 0.76rem;
}

.home-section {
  display: grid;
  gap: 34px;
}

.section-heading {
  max-width: 670px;
}

.section-heading.compact {
  max-width: 560px;
}

.section-heading h2,
.source-note h2,
.home-cta h2 {
  margin: 0;
  color: var(--ink);
  font-size: clamp(2rem, 4vw, 3.2rem);
  font-weight: 800;
  line-height: 1.05;
  letter-spacing: -0.055em;
}

.section-heading > p:last-child {
  margin: 16px 0 0;
  color: var(--muted);
  font-size: 1rem;
}

.browse-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.browse-card,
.browse-card:link,
.browse-card:visited {
  min-height: 190px;
  padding: 26px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
  color: var(--ink);
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: start;
  gap: 20px;
  text-decoration: none;
  transition: border-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.browse-card:hover {
  border-color: #9ab9ae;
  box-shadow: var(--shadow);
  transform: translateY(-3px);
}

.browse-card-featured {
  background: var(--mint-light);
}

.browse-card-generation,
.browse-card-generation:link,
.browse-card-generation:visited {
  grid-column: 1 / -1;
  min-height: 174px;
  border-color: #b8d3c9;
  background:
    radial-gradient(circle at 88% 18%, rgba(103, 170, 146, 0.2), transparent 30%),
    linear-gradient(135deg, #e7f3ed 0%, #f5f7ef 100%);
}

.browse-card-generation h3 {
  max-width: 720px;
  font-size: clamp(1.45rem, 3vw, 2rem);
  letter-spacing: -0.035em;
}

.browse-card-generation p:not(.browse-kicker) {
  max-width: 720px;
}

.browse-card .browse-kicker {
  margin: 0 0 9px;
  color: var(--forest-2);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.browse-number {
  color: var(--forest-2);
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.browse-card h3 {
  margin: 0 0 10px;
  color: var(--ink);
  font-size: 1.22rem;
  font-weight: 800;
  line-height: 1.2;
}

.browse-card p {
  margin: 0;
  color: var(--muted);
  font-size: 0.88rem;
}

.card-arrow {
  width: 34px;
  height: 34px;
  border: 1px solid var(--line);
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: background 0.18s ease, color 0.18s ease;
}

.browse-card:hover .card-arrow {
  background: var(--forest);
  color: #fff;
}

.value-section {
  grid-template-columns: minmax(250px, 0.72fr) minmax(0, 1.28fr);
  align-items: start;
  gap: clamp(34px, 8vw, 100px);
}

.value-grid {
  display: grid;
  gap: 0;
  border-top: 1px solid var(--line);
}

.value-grid article {
  padding: 24px 0;
  border-bottom: 1px solid var(--line);
  display: grid;
  grid-template-columns: 44px minmax(160px, 0.7fr) 1fr;
  gap: 18px;
  align-items: start;
}

.value-mark {
  width: 32px;
  height: 32px;
  border-radius: 10px;
  background: var(--yellow);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.74rem;
  font-weight: 800;
}

.value-grid h3 {
  margin: 2px 0 0;
  font-size: 1rem;
  font-weight: 800;
  line-height: 1.35;
}

.value-grid p {
  margin: 0;
  color: var(--muted);
  font-size: 0.86rem;
}

.source-note {
  padding: clamp(30px, 5vw, 54px);
  border-radius: var(--radius-lg);
  background: #e8e6df;
  display: grid;
  grid-template-columns: minmax(220px, 0.85fr) minmax(0, 1.15fr);
  gap: clamp(32px, 8vw, 100px);
  align-items: end;
}

.source-note h2 {
  font-size: clamp(1.8rem, 3vw, 2.65rem);
}

.source-note p {
  margin: 0 0 16px;
  color: #44514e;
}

.source-note a,
.source-note a:link,
.source-note a:visited {
  color: var(--forest);
  font-size: 0.88rem;
  font-weight: 800;
}

.home-cta {
  padding: clamp(36px, 6vw, 68px);
  border-radius: var(--radius-lg);
  background: var(--coral);
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 36px;
}

.home-cta h2 {
  max-width: 700px;
}

.primary-cta,
.primary-cta:link,
.primary-cta:visited {
  min-height: 52px;
  padding: 14px 20px;
  border-radius: 999px;
  background: var(--forest);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  flex: 0 0 auto;
  font-size: 0.9rem;
  font-weight: 800;
  text-decoration: none;
}

/* Search landing */
.search-landing {
  max-width: 980px;
  margin: 0 auto;
  display: grid;
  gap: 64px;
}

.search-landing-hero {
  padding: clamp(38px, 7vw, 76px);
  border-radius: var(--radius-lg);
  background: var(--forest);
  color: #fff;
  text-align: center;
}

.search-landing-hero .eyebrow {
  color: var(--mint);
}

.search-landing-hero h1 {
  margin: 0;
  color: #fff;
  font-size: clamp(2.45rem, 6vw, 4.6rem);
  font-weight: 800;
  line-height: 1;
  letter-spacing: -0.06em;
}

.search-landing-hero > p:not(.eyebrow) {
  max-width: 700px;
  margin: 22px auto 0;
  color: rgba(255, 255, 255, 0.78);
}

.search-landing-form {
  max-width: 680px;
  margin: 30px auto 0;
}

.search-landing-form .input-wrapper {
  margin: 0 auto;
}

.search-landing-hero .search-suggestions {
  justify-content: center;
}

.report-outline {
  display: grid;
  grid-template-columns: minmax(220px, 0.8fr) minmax(0, 1.2fr);
  gap: clamp(36px, 7vw, 82px);
  align-items: start;
}

.report-outline ol {
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--line);
  list-style: none;
}

.report-outline li {
  padding: 22px 0;
  border-bottom: 1px solid var(--line);
  display: grid;
  grid-template-columns: 44px 1fr;
  gap: 18px;
}

.report-outline li > span {
  color: var(--forest-2);
  font-size: 0.72rem;
  font-weight: 800;
}

.report-outline h3 {
  margin: 0 0 5px;
  font-size: 1rem;
  font-weight: 800;
}

.report-outline li p {
  margin: 0;
  color: var(--muted);
  font-size: 0.86rem;
}

.search-data-note {
  padding: 24px 28px;
  border: 1px solid #c9d9d3;
  border-radius: var(--radius-md);
  background: var(--mint-light);
  display: grid;
  grid-template-columns: 150px 1fr auto;
  gap: 22px;
  align-items: center;
}

.search-data-note strong {
  color: var(--forest);
  font-size: 0.9rem;
}

.search-data-note p {
  margin: 0;
  color: #42534e;
  font-size: 0.82rem;
}

.search-data-note a {
  color: var(--forest);
  font-size: 0.8rem;
  font-weight: 800;
  white-space: nowrap;
}

/* Existing result and ranking views */
.main-section {
  margin: 0 0 28px;
  padding: clamp(28px, 5vw, 50px);
  border-radius: var(--radius-lg);
  background: var(--forest);
  color: #fff;
  text-align: left;
}

.main-section h1,
.main-section h2,
.main-section h3 {
  color: #fff;
}

.main-section h1,
.main-section h2 {
  margin: 0;
  font-size: clamp(2rem, 5vw, 3.4rem);
  line-height: 1.06;
  letter-spacing: -0.05em;
  text-align: left;
}

.main-section h2::after {
  display: none;
}

.main-section h2 span {
  padding: 0;
  background: transparent;
  line-height: inherit;
}

.main-section > .eyebrow {
  margin: 0 0 12px;
  color: var(--mint);
}

.main-section > p:last-child {
  max-width: 720px;
  margin: 16px 0 0;
  color: rgba(255, 255, 255, 0.76);
  font-size: 0.96rem;
}

.main-section .desc {
  max-width: 760px;
  margin: 18px 0 0;
  color: rgba(255, 255, 255, 0.78);
  font-family: inherit;
}

.generation-ranking-page {
  display: grid;
  gap: 24px;
}

.generation-ranking-hero {
  margin-bottom: 0;
}

.generation-ranking-hero .eyebrow {
  margin-bottom: 12px;
  color: #bde8db;
}

.generation-ranking-hero > p:last-child {
  max-width: 720px;
  margin: 18px 0 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 1rem;
}

.generation-switcher {
  padding: clamp(20px, 3.5vw, 32px);
  overflow: hidden;
  border: 1px solid #d7ded9;
  border-radius: var(--radius-md);
  background: var(--surface);
  box-shadow: 0 12px 38px rgba(18, 52, 48, 0.06);
}

.generation-switcher-heading {
  margin-bottom: 20px;
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(260px, 0.55fr);
  align-items: end;
  gap: 28px;
}

.generation-switcher-heading .eyebrow {
  margin: 0 0 7px;
}

.generation-switcher-heading h2 {
  margin: 0;
  color: var(--ink);
  font-size: clamp(1.4rem, 3vw, 2rem);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.generation-switcher-heading > p {
  margin: 0;
  color: var(--muted);
  font-size: 0.88rem;
}

.generation-list {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 9px;
}

.generation-link,
.generation-link:link,
.generation-link:visited {
  min-width: 0;
  min-height: 82px;
  padding: 13px 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #f7f8f4;
  color: var(--ink);
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  gap: 9px;
  text-decoration: none;
  transition: border-color 0.18s ease, background 0.18s ease, color 0.18s ease, transform 0.18s ease;
}

.generation-link strong {
  overflow-wrap: anywhere;
  font-size: 0.83rem;
  line-height: 1.25;
}

.generation-link span {
  color: var(--muted);
  font-size: 0.7rem;
  font-variant-numeric: tabular-nums;
  letter-spacing: 0.04em;
}

.generation-link:hover {
  border-color: #9ab9ae;
  background: var(--mint-light);
  transform: translateY(-2px);
}

.generation-link.active,
.generation-link.active:link,
.generation-link.active:visited {
  border-color: var(--forest);
  background: var(--forest);
  color: #fff;
}

.generation-link.active span {
  color: rgba(255, 255, 255, 0.72);
}

.generational-rankings.generation-ranking-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  align-items: start;
}

.generational-rankings.generation-ranking-grid > .generation-ranking-card {
  width: 100%;
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
}

.generation-ranking-card > header {
  display: flex;
  min-height: 82px;
  padding: 18px 20px;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  border-bottom: 1px solid var(--line);
  background: var(--mint-light);
}

.generation-ranking-card > header p {
  margin: 0 0 3px;
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  line-height: 1.2;
  text-transform: uppercase;
}

.generation-ranking-card > header h2 {
  margin: 0;
  color: var(--forest);
  font-size: 1.35rem;
  line-height: 1.15;
  letter-spacing: -0.025em;
}

.generation-ranking-card > header > span {
  flex: 0 0 auto;
  padding: 6px 9px;
  border: 1px solid #c9d9d3;
  border-radius: 999px;
  background: #fff;
  color: var(--muted);
  font-size: 0.72rem;
  font-weight: 800;
  white-space: nowrap;
}

.section .generation-ranking-table {
  width: 100%;
  min-width: 0;
  table-layout: fixed;
  border: 0;
  border-collapse: collapse;
}

.section .generation-ranking-table th {
  padding: 11px 14px;
  background: var(--forest) !important;
  color: #fff;
  font-size: 0.72rem;
  line-height: 1.25;
  text-align: left;
}

.section .generation-ranking-table th:first-child {
  width: 74px;
  text-align: center;
}

.section .generation-ranking-table th:last-child {
  width: 128px;
  text-align: right;
}

.section .generation-ranking-table td {
  min-width: 0;
  padding: 11px 14px;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  font-size: 0.9rem;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.section .generation-ranking-table tbody tr:nth-child(even) {
  background: #f7f9f6;
}

.section .generation-ranking-table tbody tr:last-child td {
  border-bottom: 0;
}

.section .generation-ranking-table td:first-child {
  color: var(--muted);
  font-variant-numeric: tabular-nums;
  font-weight: 800;
  text-align: center;
}

.section .generation-ranking-table td:nth-child(2) a {
  color: var(--forest);
  font-weight: 800;
  text-decoration: none;
}

.section .generation-ranking-table td:nth-child(2) a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.section .generation-ranking-table td:last-child {
  font-variant-numeric: tabular-nums;
  text-align: right;
}

@media (max-width: 960px) {
  .generation-switcher-heading {
    grid-template-columns: minmax(0, 1fr);
    gap: 10px;
  }

  .generation-list {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .generational-rankings.generation-ranking-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

.section .name-visual-header {
  margin: 0 0 24px !important;
  padding: clamp(28px, 5vw, 48px) !important;
  border-radius: var(--radius-lg) !important;
  background: var(--forest) !important;
  box-shadow: none !important;
}

.section .name-visual-header::before {
  display: none !important;
}

.section h1.name-display,
.section .name-display {
  font-size: clamp(2.8rem, 7vw, 5.25rem) !important;
  line-height: 0.95 !important;
  letter-spacing: -0.065em !important;
  text-shadow: none !important;
}

.section .name-subtitle {
  margin-top: 10px !important;
  color: rgba(255, 255, 255, 0.74) !important;
  font-size: 1rem !important;
}

.section .name-stats-grid {
  grid-template-columns: repeat(4, minmax(0, 1fr)) !important;
  gap: 10px !important;
  margin-top: 26px !important;
}

.section .stat-card {
  min-width: 0;
  padding: 16px 12px !important;
  border: 1px solid rgba(255, 255, 255, 0.16) !important;
  border-radius: 14px !important;
  background: rgba(255, 255, 255, 0.08) !important;
  backdrop-filter: none !important;
}

.section .stat-card:hover {
  transform: none !important;
}

.section .stat-number {
  overflow: hidden;
  color: #fff !important;
  font-size: clamp(1.2rem, 3vw, 1.8rem) !important;
  text-overflow: ellipsis;
}

.section .name-visual-header .stat-label {
  color: rgba(255, 255, 255, 0.72) !important;
}

.section .name-search {
  max-width: 660px;
  margin: 0 auto 34px;
}

.section .name-search .input-wrapper {
  height: 58px;
  padding: 5px;
  border: 1px solid #c9d2cd;
  border-radius: 18px;
  background: var(--surface);
  box-shadow: 0 12px 30px rgba(23, 59, 56, 0.08);
  opacity: 1;
}

.section .name-search .input-text-name {
  height: 46px;
  color: var(--ink);
  font-size: 1rem;
}

.section .name-search .btn-search {
  width: auto;
  min-width: 104px;
  height: 46px;
  padding: 0 18px;
  border-radius: 13px;
  background: var(--coral);
  color: var(--ink);
  box-shadow: none;
}

.section .name-search .btn-search:hover {
  background: #ff977f;
  box-shadow: none;
  transform: none;
}

.section .bookmark-section {
  margin: 22px 0 34px !important;
  padding: 18px !important;
  border: 1px solid var(--line) !important;
  border-radius: var(--radius-md) !important;
  background: var(--surface) !important;
  box-shadow: none !important;
}

.section .bookmark-section h3 {
  color: var(--ink) !important;
  font-size: 0.84rem !important;
  text-align: left !important;
}

.section .bookmark-grid {
  gap: 8px !important;
  scrollbar-width: none;
}

.section .bookmark-grid::-webkit-scrollbar {
  display: none;
}

.section .bookmark-item {
  min-width: 0 !important;
  padding: 9px 12px !important;
  border: 1px solid var(--line) !important;
  border-radius: 999px !important;
  background: #f8f8f5 !important;
  color: var(--ink) !important;
  box-shadow: none !important;
}

.section .bookmark-icon {
  font-size: 0.9rem !important;
}

.section article > header,
.section article > section,
.section .additional-visualizations {
  margin: 18px 0 !important;
  padding: clamp(22px, 4vw, 34px) !important;
  border: 1px solid var(--line) !important;
  border-radius: var(--radius-md) !important;
  background: var(--surface) !important;
  box-shadow: none !important;
}

.section article > header > h2:first-child,
.section article > section > h2:first-child,
.section article > section > h3:first-child {
  margin-top: 0 !important;
}

.section article h2 {
  color: var(--ink) !important;
  font-size: clamp(1.35rem, 3vw, 1.9rem) !important;
  line-height: 1.2 !important;
  letter-spacing: -0.025em !important;
  text-align: left !important;
  text-shadow: none !important;
}

.section article h3 {
  color: var(--ink);
}

.section .name-etymology {
  padding: clamp(22px, 4vw, 34px) !important;
  border: 1px solid var(--line) !important;
  border-radius: var(--radius-md) !important;
  background: var(--surface) !important;
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  gap: 12px !important;
  box-shadow: none !important;
}

.section .name-etymology > h2 {
  grid-column: 1 / -1;
  margin: 0 0 8px !important;
}

.section .info-card {
  min-width: 0;
  margin: 0 !important;
  padding: 18px !important;
  border: 1px solid var(--line) !important;
  border-left: 1px solid var(--line) !important;
  border-radius: 14px !important;
  background: #f9faf7 !important;
  box-shadow: none !important;
}

.section .info-card:hover {
  transform: none !important;
  box-shadow: none !important;
}

.section .info-icon {
  width: 38px !important;
  min-width: 38px !important;
  height: 38px !important;
  margin-right: 12px !important;
  padding: 0 !important;
  border-radius: 10px !important;
  background: var(--mint-light) !important;
  color: var(--forest) !important;
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  font-size: 1rem !important;
  box-shadow: none !important;
}

.section .info-content h3 {
  margin: 0 0 6px !important;
  padding: 0 !important;
  border: 0 !important;
  color: var(--ink) !important;
  font-size: 0.92rem !important;
}

.section .info-content p {
  color: var(--muted) !important;
  font-size: 0.84rem !important;
}

.section .trend-cards-container,
.section .meaning-cards-grid {
  gap: 12px !important;
}

.section .trend-card,
.section .meaning-card {
  border: 1px solid var(--line) !important;
  background: #f9faf7 !important;
  box-shadow: none !important;
}

.section .meaning-card {
  padding: 22px !important;
  text-align: left !important;
}

.section .meaning-card::before {
  display: none !important;
}

.section .meaning-card:hover {
  transform: none !important;
}

.section .meaning-card .meaning-icon {
  margin-bottom: 14px !important;
  font-size: 1.8rem !important;
  animation: none !important;
}

.section .meaning-card h3 {
  margin: 0 0 8px !important;
  color: var(--ink) !important;
  font-size: 1.02rem !important;
  text-shadow: none !important;
}

.section .meaning-card p {
  margin: 0 !important;
  color: var(--muted) !important;
  font-size: 0.84rem !important;
  line-height: 1.55 !important;
}

.section .similar-names-description p + p,
.section .similar-names-footer {
  display: none;
}

.section .similar-name-link {
  border: 1px solid var(--line) !important;
  border-radius: 999px !important;
  background: var(--mint-light) !important;
  color: var(--forest) !important;
  box-shadow: none !important;
}

.section .table-container {
  width: 100%;
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 14px;
  -webkit-overflow-scrolling: touch;
}

.section table {
  width: 100%;
  min-width: 0;
}

.section .t3d th,
.section table th {
  background: var(--forest) !important;
  color: #fff !important;
}

.section .rank-generation td {
  padding: 10px !important;
  border-color: var(--line) !important;
}

.section .btn-visual,
.section .standard-btn {
  padding: 10px 15px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--mint-light);
  color: var(--forest);
  box-shadow: none;
  font-weight: 700;
}

/* Shared discovery, ranking and trend views */
.section .generational-rankings {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 24px;
  align-items: start;
}

.section .generational-rankings > div {
  width: 100%;
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
}

.section .generational-rankings > table {
  grid-column: 1 / -1;
}

.section .generational-rankings > div > h3 {
  margin: 0;
  padding: 17px 20px;
  border: 0;
  border-bottom: 1px solid var(--line);
  border-radius: 0;
  background: var(--mint-light);
  box-shadow: none;
  color: var(--forest);
  font-size: 1.05rem;
  letter-spacing: -0.015em;
  text-align: left;
}

.section .generational-rankings table {
  width: 100%;
  min-width: 0;
  table-layout: fixed;
  overflow: hidden;
  border: 1px solid var(--line);
  border-collapse: separate;
  border-spacing: 0;
  border-radius: 16px;
  background: var(--surface);
  box-shadow: none;
}

.section .generational-rankings > div > table {
  border: 0;
  border-radius: 0;
}

.section .generational-rankings th {
  padding: 11px 12px;
  border: 0;
  background: var(--forest) !important;
  color: #fff !important;
  font-size: 0.75rem;
  font-weight: 800;
  line-height: 1.25;
  letter-spacing: 0.015em;
}

.section .generational-rankings td {
  min-width: 0;
  padding: 10px 12px;
  border: 0;
  border-bottom: 1px solid var(--line);
  color: var(--ink);
  font-size: 0.88rem;
  line-height: 1.35;
  overflow-wrap: anywhere;
}

.section .generational-rankings tbody tr:nth-child(even) {
  background: #f7f9f6;
}

.section .generational-rankings tbody tr:last-child td {
  border-bottom: 0;
}

.section .generational-rankings td a {
  color: var(--forest);
  font-weight: 800;
  text-decoration: none;
}

.section .generational-rankings td a:hover {
  text-decoration: underline;
}

.section .generational-rankings > .message {
  grid-column: 1 / -1;
  width: 100% !important;
  min-height: 150px;
  padding: 30px;
  border: 1px dashed #b8c9c3;
  border-radius: var(--radius-md);
  background: var(--surface);
  color: var(--muted);
  display: grid;
  place-items: center;
  font-weight: 750;
  text-align: center;
}

.section .hidden_number_total {
  margin-left: 4px;
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 600;
}

.section .states-list {
  width: 100%;
  margin: 0 0 24px;
}

.section .states-list ul {
  margin: 0;
  padding: 2px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.section .states-list a {
  color: inherit;
  text-decoration: none;
}

.section .states-list li {
  margin: 0;
  padding: 8px 13px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  box-shadow: none;
  color: #40514c;
  font-size: 0.82rem;
  font-weight: 700;
  line-height: 1.35;
  transform: none;
}

.section .states-list li:hover {
  border-color: #adcac1;
  background: var(--mint-light);
  color: var(--forest);
  box-shadow: none;
  transform: none;
}

.section .states-list li.active {
  border-color: var(--forest);
  background: var(--forest);
  box-shadow: none;
  color: #fff;
  transform: none;
}

.section .year-nav {
  margin: 0 0 18px;
  padding: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
}

.section .year-nav .year-list {
  margin: 0;
  padding: 10px;
  gap: 7px;
  overflow-x: auto;
  scrollbar-width: none;
}

.section .year-nav .year-list::-webkit-scrollbar {
  display: none;
}

.section .year-nav .year-list .year-link {
  margin: 0;
  padding: 8px 13px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: transparent;
  box-shadow: none;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 750;
  transform: none;
}

.section .year-nav .year-list .year-link:hover {
  border-color: var(--line);
  background: var(--mint-light);
  box-shadow: none;
  color: var(--forest);
  transform: none;
}

.section .year-nav .year-list .year-link.active {
  border-color: var(--forest);
  background: var(--forest);
  box-shadow: none;
  color: #fff;
  transform: none;
}

.section .pagination {
  width: 100%;
  margin: 24px 0 0;
  padding: 0 !important;
  display: grid !important;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.section .pagination .page {
  min-width: 0;
  height: auto !important;
  margin: 0 !important;
  padding: 0 !important;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--surface) !important;
  color: var(--forest) !important;
  font-size: 0.9rem !important;
  line-height: 1.3 !important;
}

.section .pagination .page a {
  min-height: 46px;
  padding: 11px 16px;
  color: inherit;
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

.section .mode-selector {
  margin: 0 0 18px !important;
  padding: 5px !important;
  display: inline-flex !important;
  gap: 4px !important;
  border: 1px solid var(--line) !important;
  border-radius: 999px !important;
  background: var(--surface) !important;
}

.section .mode-btn {
  margin: 0 !important;
  padding: 9px 15px !important;
  border: 0 !important;
  border-radius: 999px !important;
  background: transparent !important;
  box-shadow: none !important;
  color: var(--muted) !important;
  font-size: 0.84rem !important;
  font-weight: 800 !important;
  text-decoration: none !important;
  transform: none !important;
}

.section .mode-btn.active {
  background: var(--forest) !important;
  color: #fff !important;
}

.section > .desc {
  margin: 0 0 20px !important;
  padding: 18px 20px !important;
  border: 1px solid #c9d9d3 !important;
  border-left: 1px solid #c9d9d3 !important;
  border-radius: 16px !important;
  background: var(--mint-light) !important;
  color: #40514c !important;
  box-shadow: none !important;
  font-size: 0.9rem !important;
}

.section #unisex-table th,
.section #unisex-table td {
  padding: 11px 10px !important;
}

.section #unisex-table th:first-child {
  width: 28%;
}

.section #unisex-table th:nth-child(2) {
  width: 16%;
}

.section #unisex-table .sortable-header {
  padding-right: 24px !important;
  border-radius: 0 !important;
  color: #fff !important;
}

.section #unisex-table .sort-icon {
  right: 8px !important;
  color: rgba(255, 255, 255, 0.7) !important;
}

.section #unisex-table .sortable-header:hover,
.section #unisex-table .sortable-header.active {
  background: var(--forest-2) !important;
  box-shadow: none !important;
  color: #fff !important;
}

.section .table-4-skippable {
  table-layout: fixed;
}

.section .table-4-skippable th:first-child {
  width: 24%;
}

.section .table-4-skippable th:nth-child(2) {
  width: 12%;
}

.section details.distortion-explanation,
.section details.pronunciation-algorithm-explanation,
.section details.copyright-warning {
  width: 100%;
  margin: 0 0 12px !important;
  padding: 0 !important;
  overflow: hidden;
  border: 1px solid var(--line) !important;
  border-radius: 16px !important;
  background: var(--surface) !important;
  box-shadow: none !important;
}

.section details.copyright-warning {
  margin-top: 24px !important;
  border-color: #e1d3ac !important;
  background: #fffdf7 !important;
}

.section details.distortion-explanation > summary,
.section details.pronunciation-algorithm-explanation > summary,
.section details.copyright-warning > summary {
  min-height: 52px;
  padding: 14px 18px;
  color: var(--forest);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
  cursor: pointer;
  font-size: 0.9rem;
  font-weight: 800;
  list-style: none;
}

.section details.distortion-explanation > summary::-webkit-details-marker,
.section details.pronunciation-algorithm-explanation > summary::-webkit-details-marker,
.section details.copyright-warning > summary::-webkit-details-marker {
  display: none;
}

.section details.distortion-explanation > summary::after,
.section details.pronunciation-algorithm-explanation > summary::after,
.section details.copyright-warning > summary::after {
  content: "+";
  width: 26px;
  height: 26px;
  flex: 0 0 26px;
  border: 1px solid var(--line);
  border-radius: 50%;
  color: var(--forest);
  display: grid;
  place-items: center;
  font-size: 1rem;
  line-height: 1;
}

.section details[open].distortion-explanation > summary,
.section details[open].pronunciation-algorithm-explanation > summary,
.section details[open].copyright-warning > summary {
  border-bottom: 1px solid var(--line);
  background: var(--mint-light);
}

.section details[open].distortion-explanation > summary::after,
.section details[open].pronunciation-algorithm-explanation > summary::after,
.section details[open].copyright-warning > summary::after {
  content: "−";
}

.section details.distortion-explanation .explanation-content,
.section details.pronunciation-algorithm-explanation .explanation-content,
.section details.copyright-warning .warning-content {
  margin: 0 !important;
  padding: 20px !important;
  border: 0 !important;
  border-radius: 0 !important;
  background: transparent !important;
  box-shadow: none !important;
}

.section details.distortion-explanation .explanation-content > h4:first-child,
.section details.pronunciation-algorithm-explanation .explanation-content > h4:first-child,
.section details.copyright-warning .warning-content > h4:first-child {
  display: none;
}

.section details.distortion-explanation p,
.section details.pronunciation-algorithm-explanation p,
.section details.copyright-warning p,
.section details.copyright-warning li {
  color: #40514c !important;
  font-size: 0.84rem !important;
  line-height: 1.6 !important;
}

@media (max-width: 900px) {
  .section .generational-rankings {
    grid-template-columns: minmax(0, 1fr);
    gap: 18px;
  }
}

.analysis-drilldowns {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.analysis-drilldown,
.analysis-drilldown:link,
.analysis-drilldown:visited {
  min-height: 130px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--mint-light);
  color: var(--ink);
  display: grid;
  align-content: space-between;
  gap: 18px;
  text-decoration: none;
}

.analysis-drilldown strong {
  font-size: 1rem;
}

.analysis-drilldown span {
  color: var(--muted);
  font-size: 0.82rem;
}

.analysis-drilldown b {
  color: var(--forest);
  font-size: 0.8rem;
}

/* Focused state and region pages */
.analysis-page-header {
  margin: 0 0 24px;
  padding: clamp(28px, 5vw, 48px);
  border-radius: var(--radius-lg);
  background: var(--forest);
  color: #fff;
}

.analysis-page-header h1 {
  margin: 0;
  color: #fff;
  font-size: clamp(2rem, 5vw, 3.6rem);
  font-weight: 800;
  line-height: 1.02;
  letter-spacing: -0.055em;
}

.analysis-page-header p {
  max-width: 720px;
  margin: 16px 0 0;
  color: rgba(255, 255, 255, 0.76);
}

.analysis-summary {
  margin: 0 0 20px;
  padding: 20px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 14px;
}

.analysis-summary > div {
  padding: 4px 14px;
  border-right: 1px solid var(--line);
}

.analysis-summary > div:last-child {
  border-right: 0;
}

.analysis-summary span {
  color: var(--muted);
  display: block;
  font-size: 0.72rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.analysis-summary strong {
  display: block;
  margin-top: 4px;
  color: var(--forest);
  font-size: 1rem;
}

.analysis-chart-card {
  margin: 0 0 18px;
  padding: clamp(18px, 4vw, 30px);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
}

.analysis-chart-card h2 {
  margin: 0 0 8px;
  color: var(--ink);
  font-size: clamp(1.25rem, 3vw, 1.7rem);
  line-height: 1.2;
}

.analysis-chart-card > p {
  margin: 0 0 18px;
  color: var(--muted);
  font-size: 0.86rem;
}

.slidecontainer {
  padding: 14px 0;
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
}

.slidecontainer .slider {
  flex: 1 1 260px;
}

.slidecontainer button {
  min-height: 42px;
  padding: 9px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--forest);
  font-weight: 700;
  cursor: pointer;
}

.method-note {
  margin: 18px 0 0;
  padding: 16px 18px;
  border-radius: 14px;
  background: var(--mint-light);
  color: #40514c;
  font-size: 0.82rem;
}

/* Footer */
.footer {
  width: 100%;
  padding: 44px 24px;
  border: 0;
  background: #102b29;
  box-shadow: none;
  color: rgba(255, 255, 255, 0.74);
  font-family: "Public Sans Web", "Segoe UI", Arial, sans-serif;
  font-size: 0.82rem;
  font-weight: 400;
  letter-spacing: normal;
  text-align: left;
}

.footer-inner {
  max-width: 1180px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: 0.7fr 1.3fr;
  gap: 48px;
}

.footer-brand,
.footer-brand:link,
.footer-brand:visited {
  color: #fff;
  font-size: 1.08rem;
  font-weight: 800;
  text-decoration: none;
}

.footer p {
  max-width: 680px;
  margin: 7px 0 0;
  line-height: 1.55;
}

.footer-meta {
  justify-self: end;
}

.footer a {
  color: var(--mint);
}

@media (max-width: 960px) {
  .home-hero {
    grid-template-columns: minmax(0, 1fr) 300px;
    gap: 34px;
  }

  .hero-report-preview {
    padding: 22px;
  }

  .value-section,
  .source-note,
  .report-outline {
    grid-template-columns: 1fr;
  }

  .value-grid article {
    grid-template-columns: 44px minmax(160px, 0.7fr) 1fr;
  }
}

@media (max-width: 860px) {
  .navi-top {
    position: sticky;
    top: 0;
    min-height: 66px;
    padding: 0 16px;
  }

  .site-header-inner {
    min-height: 66px;
    grid-template-columns: 44px 1fr auto;
    gap: 12px;
  }

  .btn-menu {
    display: inline-flex;
  }

  .site-brand {
    justify-self: center;
  }

  .site-brand-tagline {
    display: none;
  }

  .header-search-link {
    min-height: 40px;
    padding: 8px 13px;
    font-size: 0.76rem;
  }

  .navi {
    position: fixed;
    top: 0;
    bottom: 0;
    left: 0;
    z-index: 10000001;
    width: min(86vw, 340px);
    height: 100vh;
    margin: 0;
    padding: 18px;
    overflow-y: auto;
    border: 0;
    border-radius: 0 22px 22px 0;
    background: var(--forest);
    transform: translateX(-105%);
    transition: transform 0.24s ease;
  }

  body.nav-open .navi {
    transform: translateX(0);
  }

  body.nav-open .screen-blocker {
    opacity: 1;
    visibility: visible;
  }

  .navi-inner {
    min-height: 100%;
    display: grid;
    align-content: start;
    gap: 5px;
  }

  .navi-mobile-header {
    min-height: 60px;
    margin-bottom: 10px;
    padding-bottom: 14px;
    border-bottom: 1px solid rgba(255, 255, 255, 0.14);
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
  }

  .site-brand-light,
  .site-brand-light:link,
  .site-brand-light:visited,
  .site-brand-light .site-brand-name,
  .site-brand-light .site-brand-name strong {
    color: #fff;
  }

  .navi-top-close {
    width: auto;
    min-height: 40px;
    padding: 8px 12px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    border-radius: 999px;
    background: transparent;
    color: #fff;
    font-size: 0.76rem;
    cursor: pointer;
  }

  .nav-link,
  .nav-link:link,
  .nav-link:visited,
  .nav-more > summary {
    width: 100%;
    min-height: 48px;
    padding: 12px 14px;
    border-radius: 12px;
    color: rgba(255, 255, 255, 0.9);
    justify-content: flex-start;
  }

  .nav-link:hover,
  .nav-more > summary:hover {
    background: rgba(255, 255, 255, 0.1);
    color: #fff;
  }

  .nav-more {
    margin: 0;
  }

  .nav-more > summary::after {
    margin-left: auto;
    color: rgba(255, 255, 255, 0.72);
  }

  .nav-more-menu {
    position: static;
    width: 100%;
    margin: 4px 0 0;
    padding: 4px 0 4px 14px;
    border: 0;
    background: transparent;
    box-shadow: none;
  }

  .nav-more-menu a,
  .nav-more-menu a:link,
  .nav-more-menu a:visited {
    color: rgba(255, 255, 255, 0.74);
  }

  .nav-more-menu a:hover {
    background: rgba(255, 255, 255, 0.08);
    color: #fff;
  }

  .section {
    width: 100%;
    margin: 0;
    padding: 22px 16px 68px;
  }

  .home-page {
    gap: 64px;
  }

  .home-hero {
    min-height: 0;
    grid-template-columns: 1fr;
  }

  .hero-report-preview {
    max-width: 540px;
    margin: 0;
    transform: none;
  }

  .trust-strip {
    margin-top: -42px;
    padding: 0 18px;
  }

  .trust-strip > div {
    padding: 18px;
  }

  .home-cta {
    align-items: flex-start;
    flex-direction: column;
  }

  .footer-inner {
    grid-template-columns: 1fr;
    gap: 26px;
  }

  .footer-meta {
    justify-self: start;
  }
}

@media (max-width: 640px) {
  .header-search-link,
  .header-search-link:link,
  .header-search-link:visited {
    position: relative;
    width: 40px;
    height: 40px;
    min-width: 40px;
    padding: 0;
    font-size: 0;
  }

  .header-search-link::before {
    content: "";
    width: 13px;
    height: 13px;
    border: 2px solid currentColor;
    border-radius: 50%;
  }

  .header-search-link::after {
    content: "";
    position: absolute;
    width: 7px;
    height: 2px;
    right: 10px;
    bottom: 10px;
    border-radius: 999px;
    background: currentColor;
    transform: rotate(45deg);
  }

  .home-page {
    gap: 52px;
  }

  .home-hero {
    padding: 34px 22px;
    border-radius: 24px;
  }

  .home-hero h1 {
    font-size: clamp(2.45rem, 13vw, 3.7rem);
  }

  .home-hero-lede {
    margin-top: 20px;
  }

  .hero-search-form .input-wrapper,
  .search-landing-form .input-wrapper {
    height: auto;
    padding: 5px;
    border-radius: 16px;
    align-items: stretch;
  }

  .hero-search-form .input-wrapper-text,
  .search-landing-form .input-wrapper-text {
    min-width: 0;
    padding: 0 10px;
  }

  .hero-search-form .input-text-name,
  .search-landing-form .input-text-name {
    min-width: 0;
    font-size: 16px;
  }

  .hero-search-form .btn-search,
  .search-landing-form .btn-search {
    min-width: 54px;
    width: 54px;
    padding: 0;
    font-size: 1.1rem;
  }

  .hero-search-form .btn-search span:first-child,
  .search-landing-form .btn-search span:first-child {
    display: none;
  }

  .hero-report-preview {
    padding: 22px;
    box-shadow: 10px 12px 0 rgba(189, 232, 219, 0.16);
  }

  .preview-name {
    font-size: 2.6rem;
  }

  .trust-strip {
    margin-top: -28px;
    padding: 0 10px;
    grid-template-columns: 1fr;
  }

  .trust-strip > div {
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .trust-strip > div:first-child {
    border-radius: 16px 16px 0 0;
  }

  .trust-strip > div:last-child {
    border-bottom: 0;
    border-radius: 0 0 16px 16px;
  }

  .browse-grid {
    grid-template-columns: 1fr;
  }

  .browse-card {
    min-height: 0;
    padding: 22px 18px;
    gap: 13px;
  }

  .browse-card-generation {
    min-height: 0;
  }

  .value-grid article {
    grid-template-columns: 38px 1fr;
    gap: 12px;
  }

  .value-grid article p {
    grid-column: 2;
  }

  .source-note,
  .home-cta {
    border-radius: 24px;
  }

  .search-landing {
    gap: 46px;
  }

  .search-landing-hero {
    padding: 38px 20px;
    border-radius: 24px;
  }

  .search-data-note {
    grid-template-columns: 1fr;
    gap: 8px;
  }

  .main-section {
    padding: 28px 22px;
    border-radius: 24px;
  }

  .main-section h1,
  .main-section h2 {
    font-size: clamp(1.75rem, 9vw, 2.35rem);
  }

  .section .name-search {
    margin-bottom: 26px;
  }

  .section .name-search .input-wrapper {
    height: 54px;
    padding: 4px;
    border-radius: 16px;
  }

  .section .name-search .input-wrapper-text {
    min-width: 0;
    padding: 0 12px;
  }

  .section .name-search .input-text-name {
    min-width: 0;
    height: 44px;
    font-size: 16px;
  }

  .section .name-search .btn-search {
    width: 46px;
    min-width: 46px;
    height: 44px;
    padding: 0;
    overflow: hidden;
    color: transparent;
    font-size: 0;
  }

  .section .name-search .btn-search::before {
    content: "→";
    color: var(--ink);
    font-size: 1rem;
  }

  .section .states-list {
    margin-bottom: 18px;
    overflow-x: auto;
    scrollbar-width: none;
    -webkit-overflow-scrolling: touch;
  }

  .section .states-list::-webkit-scrollbar {
    display: none;
  }

  .section .states-list ul {
    width: max-content;
    min-width: 100%;
    padding-bottom: 4px;
    flex-wrap: nowrap;
  }

  .section .states-list li {
    padding: 8px 12px;
    white-space: nowrap;
  }

  .section .generational-rankings {
    gap: 14px;
  }

  .section .generational-rankings > div {
    border-radius: 16px;
  }

  .section .generational-rankings > div > h3 {
    padding: 14px;
  }

  .section .generational-rankings th,
  .section .generational-rankings td {
    padding: 9px 7px;
    font-size: 0.76rem;
  }

  .section .generational-rankings > table,
  .section .generational-rankings > div > table {
    min-width: 0;
  }

  .section #unisex-table th,
  .section #unisex-table td {
    padding: 9px 5px !important;
    font-size: 0.72rem !important;
  }

  .section #unisex-table th:first-child {
    width: 27%;
  }

  .section #unisex-table th:nth-child(2) {
    width: 17%;
  }

  .section #unisex-table .sortable-header {
    padding-right: 15px !important;
    line-height: 1.2 !important;
  }

  .section #unisex-table .sort-icon {
    right: 4px !important;
    font-size: 0.7rem !important;
  }

  .section .table-4-skippable th,
  .section .table-4-skippable td {
    padding-right: 4px;
    padding-left: 4px;
    font-size: 0.68rem;
    white-space: nowrap;
  }

  .section .table-4-skippable th:first-child {
    width: 27%;
  }

  .section .table-4-skippable th:nth-child(2) {
    width: 13%;
  }

  .section .mode-selector {
    width: 100%;
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .section .mode-btn {
    padding: 9px 8px !important;
    text-align: center;
  }

  .generation-ranking-page {
    gap: 16px;
  }

  .generation-switcher {
    padding: 18px 14px;
    border-radius: 16px;
  }

  .generation-switcher-heading {
    margin-bottom: 15px;
  }

  .generation-switcher-heading > p {
    font-size: 0.82rem;
  }

  .generation-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 7px;
  }

  .generation-link,
  .generation-link:link,
  .generation-link:visited {
    min-height: 78px;
    padding: 12px;
  }

  .generation-ranking-hero > p:last-child {
    font-size: 0.9rem;
  }

  .generational-rankings.generation-ranking-grid {
    gap: 16px;
  }

  .generation-ranking-card {
    border-radius: 16px !important;
  }

  .generation-ranking-card > header {
    min-height: 72px;
    padding: 15px 14px;
  }

  .generation-ranking-card > header h2 {
    font-size: 1.2rem;
  }

  .section .generation-ranking-table th,
  .section .generation-ranking-table td {
    padding: 10px 8px;
  }

  .section .generation-ranking-table th:first-child {
    width: 54px;
  }

  .section .generation-ranking-table th:last-child {
    width: 96px;
  }

  .section .name-visual-header {
    border-radius: 24px !important;
  }

  .section .name-stats-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr)) !important;
  }

  .section .name-etymology {
    grid-template-columns: 1fr !important;
  }

  .section .info-card {
    flex-direction: row !important;
    align-items: flex-start !important;
  }

  .section .bookmark-grid {
    display: flex !important;
    padding-bottom: 4px;
    overflow-x: auto;
    flex-wrap: nowrap !important;
    -webkit-overflow-scrolling: touch;
  }

  .section .bookmark-item {
    flex: 0 0 auto;
  }

  .analysis-drilldowns,
  .analysis-summary {
    grid-template-columns: 1fr;
  }

  .analysis-summary > div {
    padding: 10px 4px;
    border-right: 0;
    border-bottom: 1px solid var(--line);
  }

  .analysis-summary > div:last-child {
    border-bottom: 0;
  }

  .analysis-chart-card canvas,
  .section #chart-annual,
  .section #chart-annual-rank {
    height: 300px !important;
  }

  .section .generational-analysis .table-container {
    overflow: visible;
    border: 0;
    border-radius: 0;
  }

  .section .rank-generation {
    display: block;
    width: 100%;
    min-width: 0;
    border: 0 !important;
    background: transparent;
  }

  .section .rank-generation thead {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    clip-path: inset(50%);
    white-space: nowrap;
    border: 0;
  }

  .section .rank-generation tbody {
    display: grid;
    gap: 12px;
  }

  .section .rank-generation tr {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    overflow: hidden;
    border: 1px solid var(--line);
    border-radius: 14px;
    background: #fff;
  }

  .section .rank-generation td {
    display: flex;
    min-width: 0;
    padding: 11px 12px !important;
    flex-direction: column;
    align-items: flex-start;
    gap: 3px;
    border: 0 !important;
    border-right: 1px solid var(--line) !important;
    color: var(--ink);
    font-size: 0.9rem;
    line-height: 1.35 !important;
    text-align: left !important;
    overflow-wrap: anywhere;
  }

  .section .rank-generation td:first-child {
    grid-column: 1 / -1;
    border-right: 0 !important;
    border-bottom: 1px solid var(--line) !important;
    background: var(--mint-light);
    color: var(--forest);
    font-weight: 800;
  }

  .section .rank-generation td:last-child {
    border-right: 0 !important;
  }

  .section .rank-generation td::before {
    content: attr(data-label);
    color: var(--muted);
    font-size: 0.64rem;
    font-weight: 800;
    letter-spacing: 0.055em;
    line-height: 1.2;
    text-transform: uppercase;
  }

  .footer {
    padding: 36px 20px;
  }
}

.hero-generation-links {
  margin-top: 18px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 7px;
}

.hero-generation-links a,
.hero-generation-links a:link,
.hero-generation-links a:visited {
  padding: 7px 10px;
  border: 1px solid rgba(255, 255, 255, 0.17);
  border-radius: 999px;
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.7rem;
  font-weight: 700;
  text-decoration: none;
}

.hero-generation-links a:hover {
  border-color: rgba(255, 255, 255, 0.42);
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.hero-generation-links .hero-generation-label {
  border-color: var(--mint);
  background: var(--mint);
  color: var(--forest);
}

.generation-hub,
.trend-hub {
  display: grid;
  gap: 24px;
}

.generation-hub-hero,
.trend-hub-hero {
  margin-bottom: 0;
}

.generation-timeline,
.trend-overview,
.trend-paths {
  padding: clamp(24px, 4vw, 42px);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
}

.generation-timeline-heading,
.trend-overview-heading {
  margin-bottom: 24px;
  display: grid;
  grid-template-columns: minmax(0, 0.9fr) minmax(280px, 0.55fr);
  align-items: end;
  gap: 32px;
}

.generation-timeline-heading .eyebrow,
.trend-overview-heading .eyebrow {
  margin: 0 0 8px;
}

.generation-timeline-heading h2,
.trend-overview-heading h2,
.generation-method h2 {
  margin: 0;
  color: var(--ink);
  font-size: clamp(1.55rem, 3vw, 2.35rem);
  font-weight: 800;
  line-height: 1.08;
  letter-spacing: -0.045em;
}

.generation-timeline-heading > p,
.trend-overview-heading > p,
.generation-method > p {
  margin: 0;
  color: var(--muted);
  font-size: 0.9rem;
}

.generation-hub-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.generation-hub-card,
.generation-hub-card:link,
.generation-hub-card:visited {
  min-width: 0;
  min-height: 178px;
  padding: 22px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #f7f8f4;
  color: var(--ink);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: start;
  gap: 16px;
  text-decoration: none;
  transition: border-color 0.18s ease, background 0.18s ease, transform 0.18s ease;
}

.generation-hub-card:hover {
  border-color: #9ab9ae;
  background: var(--mint-light);
  transform: translateY(-2px);
}

.generation-hub-index {
  color: var(--forest-2);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.generation-hub-card p {
  margin: 0 0 7px;
  color: var(--forest-2);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.06em;
}

.generation-hub-card h3 {
  margin: 0 0 10px;
  color: var(--ink);
  font-size: 1.14rem;
  line-height: 1.2;
}

.generation-hub-card div > span {
  color: var(--muted);
  font-size: 0.82rem;
  line-height: 1.55;
}

.generation-hub-card > b {
  color: var(--forest);
  font-size: 1rem;
}

.generation-method {
  padding: clamp(24px, 4vw, 38px);
  border-radius: var(--radius-md);
  background: var(--mint-light);
  display: grid;
  grid-template-columns: minmax(0, 0.8fr) minmax(280px, 0.65fr);
  align-items: center;
  gap: 34px;
}

.trend-overview-grid,
.trend-path-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.trend-list-card {
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #f8f9f5;
}

.trend-list-card > header {
  padding: 18px 20px;
  border-bottom: 1px solid var(--line);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 14px;
}

.trend-list-card > header span {
  padding: 6px 9px;
  border-radius: 999px;
  background: var(--mint-light);
  color: var(--forest);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.trend-list-card.declining > header span {
  background: #f5e9e4;
  color: #8b4b3b;
}

.trend-list-card > header strong {
  color: var(--muted);
  font-size: 0.76rem;
}

.trend-list-card ol {
  margin: 0;
  padding: 0;
  list-style: none;
}

.trend-list-card li {
  min-height: 52px;
  padding: 11px 18px;
  border-bottom: 1px solid var(--line);
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto 48px;
  align-items: center;
  gap: 10px;
  counter-increment: trend-item;
}

.trend-list-card li:last-child {
  border-bottom: 0;
}

.trend-list-card li a {
  color: var(--forest);
  font-weight: 800;
  text-decoration: none;
}

.trend-list-card li span {
  color: var(--muted);
  font-size: 0.72rem;
}

.trend-list-card li b {
  color: #27785e;
  font-size: 0.76rem;
  text-align: right;
}

.trend-list-card.declining li b {
  color: #a4513c;
}

.trend-path-grid > article {
  min-width: 0;
  padding: clamp(20px, 3vw, 30px);
  border: 1px solid var(--line);
  border-radius: 18px;
  background: #f8f9f5;
}

.trend-path-grid > article > p {
  margin: 0 0 6px;
  color: var(--forest-2);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.trend-path-grid h3 {
  margin: 0 0 8px;
  color: var(--ink);
  font-size: 1.35rem;
}

.trend-path-grid > article > span {
  color: var(--muted);
  font-size: 0.84rem;
}

.state-picker {
  margin-top: 18px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #fff;
}

.state-picker > summary {
  min-height: 48px;
  padding: 12px 14px;
  color: var(--forest);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.82rem;
  font-weight: 800;
  cursor: pointer;
  list-style: none;
}

.state-picker > summary::-webkit-details-marker {
  display: none;
}

.state-picker > summary::after {
  content: "+";
  font-size: 1rem;
}

.state-picker[open] > summary::after {
  content: "−";
}

.state-picker > label {
  padding: 0 12px 12px;
  display: block;
}

.state-picker input,
.rank-search input {
  width: 100%;
  min-height: 44px;
  padding: 10px 13px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 0.82rem;
}

.state-picker input:focus,
.rank-search input:focus {
  border-color: var(--forest-2);
  outline: 3px solid rgba(62, 132, 109, 0.14);
}

.state-picker-grid {
  max-height: 340px;
  padding: 0 12px 12px;
  overflow-y: auto;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 6px;
}

.state-picker-grid a,
.state-picker-grid a:link,
.state-picker-grid a:visited {
  min-width: 0;
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 10px;
  background: #f8f9f5;
  color: #40514c;
  font-size: 0.72rem;
  font-weight: 700;
  text-decoration: none;
  overflow-wrap: anywhere;
}

.state-picker-grid a:hover,
.state-picker-grid a.active {
  border-color: var(--forest);
  background: var(--forest);
  color: #fff;
}

.state-picker-compact {
  margin: 0 0 18px;
}

.state-picker-compact > summary {
  min-height: 58px;
  padding: 13px 18px;
}

.state-picker-compact > summary strong {
  margin-left: auto;
  color: var(--muted);
  font-size: 0.76rem;
}

.region-path nav {
  margin-top: 18px;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 7px;
}

.region-path nav a {
  padding: 13px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: #fff;
  color: var(--forest);
  display: flex;
  justify-content: space-between;
  gap: 10px;
  font-size: 0.78rem;
  font-weight: 800;
  text-decoration: none;
}

.trend-method {
  padding: 20px 24px;
  border: 1px solid #bcd6cd;
  border-radius: 18px;
  background: var(--mint-light);
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  align-items: start;
  gap: 22px;
}

.trend-method strong {
  color: var(--forest);
}

.trend-method p {
  margin: 0;
  color: #40514c;
  font-size: 0.84rem;
}

.rank-explorer {
  padding: clamp(20px, 3vw, 30px);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
}

.ranking-story {
  padding: clamp(18px, 3vw, 26px);
  border: 1px solid #bfd7cf;
  border-radius: 18px;
  background: var(--mint-light);
  display: grid;
  grid-template-columns: minmax(160px, 0.46fr) minmax(160px, 0.46fr) minmax(260px, 1fr);
  align-items: center;
  gap: 0;
}

.ranking-story > div {
  min-width: 0;
  padding: 4px 22px 4px 0;
  border-right: 1px solid rgba(23, 59, 56, 0.13);
}

.ranking-story > div + div {
  padding-left: 22px;
}

.ranking-story span {
  color: var(--forest-2);
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.ranking-story strong {
  margin-top: 5px;
  color: var(--ink);
  display: block;
  font-size: 1.12rem;
}

.ranking-story div p {
  margin: 3px 0 0;
  color: var(--muted);
  font-size: 0.72rem;
}

.ranking-story > p {
  margin: 0;
  padding-left: 24px;
  color: #40514c;
  font-size: 0.8rem;
}

.rank-explorer-heading,
.generation-rank-tools {
  margin-bottom: 18px;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(230px, 0.42fr);
  align-items: end;
  gap: 24px;
}

.rank-explorer-heading .eyebrow {
  margin: 0 0 7px;
}

.rank-explorer-heading h2 {
  margin: 0;
  color: var(--ink);
  font-size: clamp(1.3rem, 2.4vw, 1.85rem);
  line-height: 1.12;
  letter-spacing: -0.035em;
}

.rank-gender-tabs {
  margin: 0 0 16px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 13px;
  background: #f3f5f1;
  display: inline-grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 4px;
}

.rank-gender-tabs button {
  min-height: 40px;
  padding: 8px 16px;
  border: 0;
  border-radius: 9px;
  background: transparent;
  color: var(--muted);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 800;
  cursor: pointer;
}

.rank-gender-tabs button.active {
  background: var(--forest);
  color: #fff;
}

.generation-rank-tools {
  margin: 0;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
}

.generation-rank-tools .rank-gender-tabs {
  margin: 0;
}

.rank-more {
  width: calc(100% - 28px);
  min-height: 44px;
  margin: 14px;
  border: 1px solid #b8d0c7;
  border-radius: 12px;
  background: var(--mint-light);
  color: var(--forest);
  font: inherit;
  font-size: 0.78rem;
  font-weight: 800;
  cursor: pointer;
}

.rank-more:hover {
  border-color: var(--forest);
  background: #d8ebe4;
}

.generation-name-overview {
  margin: 24px 0;
  padding: clamp(22px, 4vw, 34px);
  border: 1px solid #bcd6cd;
  border-radius: var(--radius-md);
  background:
    radial-gradient(circle at 92% 10%, rgba(103, 170, 146, 0.18), transparent 31%),
    var(--mint-light);
}

.generation-name-overview-heading {
  margin-bottom: 18px;
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
}

.generation-name-overview-heading .eyebrow {
  margin: 0 0 7px;
}

.generation-name-overview-heading h2 {
  max-width: 720px;
  margin: 0;
  color: var(--ink);
  font-size: clamp(1.45rem, 3vw, 2.15rem);
  line-height: 1.08;
  letter-spacing: -0.04em;
}

.generation-name-overview-heading > a {
  color: var(--forest);
  font-size: 0.78rem;
  font-weight: 800;
  text-decoration: none;
  white-space: nowrap;
}

.generation-name-summary {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 9px;
}

.generation-name-summary article {
  min-width: 0;
  min-height: 130px;
  padding: 17px;
  border: 1px solid rgba(23, 59, 56, 0.12);
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.74);
}

.generation-name-summary article > span {
  color: var(--forest-2);
  font-size: 0.66rem;
  font-weight: 800;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

.generation-name-summary strong {
  margin-top: 14px;
  color: var(--ink);
  display: block;
  font-size: 0.98rem;
  line-height: 1.3;
}

.generation-name-summary p {
  margin: 7px 0 0;
  color: var(--muted);
  font-size: 0.74rem;
  line-height: 1.5;
}

.name-detail-block,
.generation-detail-block {
  margin: 24px 0;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
  overflow: hidden;
}

.name-detail-block > summary,
.generation-detail-block > summary {
  min-height: 74px;
  padding: 18px 22px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  color: var(--ink);
  font-size: 1.05rem;
  font-weight: 800;
  cursor: pointer;
  list-style: none;
}

.name-detail-block > summary::-webkit-details-marker,
.generation-detail-block > summary::-webkit-details-marker {
  display: none;
}

.name-detail-block > summary::after,
.generation-detail-block > summary::after {
  content: "+";
  width: 32px;
  height: 32px;
  border: 1px solid var(--line);
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex: 0 0 auto;
  color: var(--forest);
}

.name-detail-block[open] > summary::after,
.generation-detail-block[open] > summary::after {
  content: "−";
}

.name-detail-block > summary small,
.generation-detail-block > summary small {
  margin-left: auto;
  color: var(--muted);
  font-size: 0.74rem;
  font-weight: 600;
}

.section .name-detail-block .name-etymology {
  margin: 0 !important;
  border: 0 !important;
  border-top: 1px solid var(--line) !important;
  border-radius: 0 !important;
}

.generation-detail-block .table-container {
  margin: 0 22px 22px;
}

.section .info-icon,
.section .trend-icon,
.section .meaning-icon {
  display: none !important;
}

.section .bookmark-icon {
  color: var(--forest-2) !important;
  font-size: 0.62rem !important;
  font-weight: 800;
  letter-spacing: 0.05em;
}

@media (max-width: 900px) {
  .generation-timeline-heading,
  .trend-overview-heading,
  .generation-method,
  .rank-explorer-heading,
  .generation-rank-tools {
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
  }

  .generation-hub-grid,
  .trend-overview-grid,
  .trend-path-grid {
    grid-template-columns: minmax(0, 1fr);
  }

  .rank-gender-tabs {
    width: 100%;
  }

  .rank-panels [data-rank-gender-panel]:not(.active),
  .generation-ranking-grid [data-rank-gender-panel]:not(.active) {
    display: none;
  }

  .generation-name-summary {
    grid-template-columns: minmax(0, 1fr);
  }

  .generation-name-summary article {
    min-height: 0;
  }

  .ranking-story {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .ranking-story > p {
    grid-column: 1 / -1;
    margin-top: 18px;
    padding: 16px 0 0;
    border-top: 1px solid rgba(23, 59, 56, 0.13);
  }
}

@media (max-width: 640px) {
  .hero-generation-links {
    margin-top: 16px;
    flex-wrap: nowrap;
    overflow-x: auto;
    scrollbar-width: none;
  }

  .hero-generation-links::-webkit-scrollbar {
    display: none;
  }

  .hero-generation-links a {
    flex: 0 0 auto;
  }

  .generation-timeline,
  .trend-overview,
  .trend-paths,
  .rank-explorer {
    padding: 18px 14px;
    border-radius: 16px;
  }

  .generation-hub-card {
    min-height: 0;
    padding: 17px 14px;
    gap: 11px;
  }

  .generation-method,
  .trend-method {
    padding: 20px 18px;
    grid-template-columns: minmax(0, 1fr);
    gap: 12px;
  }

  .trend-list-card li {
    padding: 10px 13px;
    grid-template-columns: minmax(0, 1fr) auto 42px;
  }

  .state-picker-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .region-path nav {
    grid-template-columns: minmax(0, 1fr);
  }

  .rank-explorer-heading,
  .generation-rank-tools {
    margin-bottom: 14px;
  }

  .ranking-story {
    padding: 18px 14px;
    border-radius: 16px;
  }

  .ranking-story > div {
    padding: 0 10px 0 0;
  }

  .ranking-story > div + div {
    padding: 0 0 0 10px;
    border-right: 0;
  }

  .generation-rank-tools {
    padding: 14px;
  }

  .generation-name-overview {
    padding: 20px 14px;
    border-radius: 16px;
  }

  .generation-name-overview-heading {
    align-items: flex-start;
    flex-direction: column;
    gap: 11px;
  }

  .name-detail-block > summary,
  .generation-detail-block > summary {
    min-height: 64px;
    padding: 15px 14px;
    font-size: 0.92rem;
  }

  .name-detail-block > summary small,
  .generation-detail-block > summary small {
    display: none;
  }

  .generation-detail-block .table-container {
    margin: 0 12px 14px;
  }

  .section .bookmark-grid {
    display: grid !important;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    overflow: visible;
  }

  .section .bookmark-item {
    width: 100%;
    white-space: normal;
  }
}

html {
  scroll-padding-top: 88px;
}

main [id] {
  scroll-margin-top: 88px;
}

.rank-context-card,
.rank-empty-state {
  padding: clamp(20px, 3vw, 28px);
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--surface);
}

.rank-context-card h2,
.rank-empty-state h2 {
  margin: 5px 0 0;
  color: var(--ink);
  font-size: clamp(1.25rem, 2.2vw, 1.75rem);
}

.rank-context-card .eyebrow,
.rank-empty-state .eyebrow {
  margin: 0;
}

.rank-context-card.region-path nav a {
  align-items: center;
}

.rank-context-card.region-path nav a span {
  flex: 0 0 auto;
}

.rank-context-card.region-path nav a small {
  color: var(--muted);
  font-size: 0.68rem;
  font-weight: 600;
  text-align: right;
}

.rank-context-card.region-path nav a.active {
  border-color: var(--forest);
  background: var(--forest);
  color: #fff;
}

.rank-context-card.region-path nav a.active small {
  color: rgba(255, 255, 255, 0.74);
}

.rank-empty-state {
  min-height: 190px;
  display: grid;
  place-content: center;
  text-align: center;
}

.rank-empty-state p:last-child {
  max-width: 620px;
  margin: 12px auto 0;
  color: var(--muted);
}

.ranking-story-single {
  grid-template-columns: minmax(200px, 0.55fr) minmax(280px, 1fr);
}

.mode-selector {
  padding: 6px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: #f1f4ef;
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px;
}

.mode-selector .mode-btn,
.mode-selector .mode-btn:link,
.mode-selector .mode-btn:visited {
  min-height: 44px;
  padding: 10px 14px;
  border-radius: 10px;
  color: var(--muted);
  display: grid;
  place-items: center;
  font-size: 0.78rem;
  font-weight: 800;
  text-decoration: none;
}

.mode-selector .mode-btn:hover,
.mode-selector .mode-btn.active {
  background: var(--forest);
  color: #fff;
}

.unisex-method {
  margin-top: 0;
}

.sort-controls {
  margin: 18px 0 4px;
  display: flex;
  flex-wrap: wrap;
  gap: 7px;
}

.sort-controls a,
.sort-controls a:link,
.sort-controls a:visited {
  padding: 8px 11px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #f8f9f5;
  color: var(--muted);
  font-size: 0.7rem;
  font-weight: 750;
  text-decoration: none;
}

.sort-controls a:hover,
.sort-controls a.active {
  border-color: var(--forest);
  background: var(--forest);
  color: #fff;
}

.balance-score {
  color: var(--forest-2);
}

.pronunciation-notes {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
}

.pronunciation-notes details,
.usage-note {
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--surface);
}

.pronunciation-notes summary,
.usage-note summary {
  min-height: 56px;
  padding: 14px 18px;
  color: var(--forest);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.82rem;
  font-weight: 800;
  cursor: pointer;
  list-style: none;
}

.pronunciation-notes summary::-webkit-details-marker,
.usage-note summary::-webkit-details-marker {
  display: none;
}

.pronunciation-notes summary::after,
.usage-note summary::after {
  content: "+";
  font-size: 1rem;
}

.pronunciation-notes details[open] summary::after,
.usage-note[open] summary::after {
  content: "−";
}

.pronunciation-notes details > div,
.usage-note > p {
  margin: 0;
  padding: 0 18px 18px;
  color: var(--muted);
  font-size: 0.8rem;
  line-height: 1.65;
}

.pronunciation-notes p,
.pronunciation-notes ul {
  margin-top: 0;
}

.pronunciation-notes ul {
  margin-bottom: 0;
  padding-left: 18px;
}

.pronunciation-main-name {
  color: var(--ink);
  display: inline-flex;
  align-items: baseline;
  gap: 5px;
  font-weight: 850;
  text-decoration: none;
}

.pronunciation-main-name small,
.pronunciation-variants small {
  color: var(--muted);
  font-size: 0.62rem;
  font-weight: 650;
}

.pronunciation-variants {
  margin-top: 6px;
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
}

.pronunciation-variants a {
  padding: 4px 7px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: #f8f9f5;
  color: var(--forest);
  display: inline-flex;
  gap: 4px;
  font-size: 0.66rem;
  font-weight: 750;
  text-decoration: none;
}

.pronunciation-rank strong,
.pronunciation-rank small {
  display: block;
}

.pronunciation-rank small {
  margin-top: 3px;
  color: var(--muted);
  font-size: 0.62rem;
}

.distortion-badge {
  min-width: 44px;
  padding: 5px 7px;
  border-radius: 999px;
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 850;
  text-align: center;
}

.distortion-badge.low {
  background: #dff2e7;
  color: #1f694f;
}

.distortion-badge.medium {
  background: #fff0cf;
  color: #8a5b04;
}

.distortion-badge.high {
  background: #ffe1db;
  color: #a53e32;
}

.distortion-badge.unknown {
  background: #eef0ec;
  color: var(--muted);
}

.usage-note {
  margin-top: 0;
}

@media (max-width: 640px) {
  .ranking-story-single,
  .pronunciation-notes {
    grid-template-columns: 1fr;
  }

  .ranking-story-single > div {
    padding-right: 0;
    border-right: 0;
  }

  .rank-context-card.region-path nav {
    grid-template-columns: 1fr;
  }

  .unisex-method {
    grid-template-columns: 1fr;
    gap: 7px;
  }

  .pronunciation-table th,
  .pronunciation-table td,
  .unisex-table th,
  .unisex-table td {
    padding-right: 6px;
    padding-left: 6px;
    font-size: 0.67rem;
  }

  .generation-detail-block th {
    white-space: normal;
    overflow-wrap: anywhere;
  }
}

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
  }
}
