:root {
  --bg: #efe4d4;
  --bg-deep: #eadbc7;
  --paper: #fffaf2;
  --paper-soft: rgba(255, 250, 242, 0.76);
  --paper-strong: #fffdf8;
  --ink: #162325;
  --ink-soft: #53676a;
  --line: rgba(77, 66, 49, 0.14);
  --line-strong: rgba(22, 35, 37, 0.16);
  --teal: #0f726d;
  --teal-dark: #0a5653;
  --rust: #c86d44;
  --gold: #d7a14b;
  --shadow: 0 30px 80px rgba(28, 35, 34, 0.12);
  --shadow-soft: 0 18px 42px rgba(28, 35, 34, 0.08);
  --radius-xl: 32px;
  --radius-lg: 24px;
  --radius-md: 18px;
  --radius-sm: 14px;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: auto;
}

body {
  margin: 0;
  position: relative;
  isolation: isolate;
  font-family: "Sora", sans-serif;
  color: var(--ink);
  line-height: 1.65;
  overflow-x: hidden;
  background:
    radial-gradient(circle at top left, rgba(215, 161, 75, 0.18), transparent 24%),
    radial-gradient(circle at right 12%, rgba(15, 114, 109, 0.12), transparent 22%),
    linear-gradient(180deg, #f0e4d3 0%, #efe5d8 35%, #f7f1e8 100%);
}

body::before {
  content: "";
  position: absolute;
  inset: 0 0 auto 0;
  height: min(820px, 80vw);
  pointer-events: none;
  z-index: -1;
  opacity: 0.42;
  background:
    linear-gradient(180deg, rgba(255, 253, 248, 0.1) 0%, rgba(239, 228, 212, 0.46) 42%, rgba(239, 228, 212, 0.96) 100%),
    radial-gradient(circle at 16% 26%, rgba(255, 253, 248, 0.62), transparent 24%),
    url("alexandria_overview.webp") center top / cover no-repeat;
  filter: saturate(0.84) contrast(0.94);
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.92), rgba(0, 0, 0, 0.62) 70%, transparent 100%);
}

body.is-scrolled .topbar-inner {
  background: rgba(255, 250, 242, 0.88);
  box-shadow: 0 20px 50px rgba(21, 30, 30, 0.12);
}

img {
  max-width: 100%;
}

a,
button,
select {
  transition:
    color 160ms ease,
    background-color 160ms ease,
    border-color 160ms ease,
    box-shadow 160ms ease,
    transform 160ms ease;
}

.bg-grid {
  position: fixed;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  opacity: 0.34;
  background-image:
    linear-gradient(rgba(22, 35, 37, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(22, 35, 37, 0.03) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: linear-gradient(180deg, rgba(0, 0, 0, 0.75), transparent 78%);
}

.bg-blur {
  position: fixed;
  width: 420px;
  height: 420px;
  border-radius: 50%;
  filter: blur(88px);
  z-index: -1;
  pointer-events: none;
}

.bg-blur-a {
  top: -160px;
  left: -110px;
  background: rgba(200, 109, 68, 0.22);
}

.bg-blur-b {
  right: -140px;
  bottom: -180px;
  background: rgba(15, 114, 109, 0.2);
}

.container {
  width: min(1180px, calc(100% - 2.5rem));
  margin: 0 auto;
}

.topbar {
  position: sticky;
  top: 0;
  z-index: 20;
  padding-top: 1rem;
}

.topbar-inner {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 1rem;
  min-height: 76px;
  padding: 0.85rem 1rem;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.62);
  background: rgba(255, 250, 242, 0.72);
  backdrop-filter: blur(18px);
  box-shadow: 0 12px 36px rgba(21, 30, 30, 0.08);
}

.topbar-menu {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-left: auto;
  min-width: 0;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  min-width: 0;
  text-decoration: none;
  color: var(--ink);
  font-weight: 800;
  letter-spacing: -0.02em;
}

.brand span {
  min-width: 0;
}

.brand-logo {
  width: 38px;
  height: 38px;
  object-fit: contain;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.78);
  border: 1px solid rgba(255, 255, 255, 0.74);
  box-shadow: inset 0 -2px 5px rgba(15, 114, 109, 0.12);
}

.menu-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  width: auto;
  min-width: 0;
  height: 2.9rem;
  padding: 0 0.88rem;
  border: 1px solid rgba(15, 114, 109, 0.16);
  border-radius: 16px;
  background: rgba(15, 114, 109, 0.08);
  color: var(--teal-dark);
  cursor: pointer;
  box-shadow: 0 10px 24px rgba(22, 35, 37, 0.08);
}

.menu-toggle-label {
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.menu-toggle-icon {
  display: inline-flex;
  flex-direction: column;
  gap: 0.24rem;
}

.menu-toggle-icon span {
  width: 1rem;
  height: 2px;
  border-radius: 999px;
  background: currentColor;
  transform-origin: center;
  transition: transform 160ms ease, opacity 160ms ease;
}

.nav {
  display: flex;
  align-items: center;
  gap: 0.2rem;
}

.topbar-actions {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  flex-wrap: nowrap;
}

.nav a {
  padding: 0.45rem 0.75rem;
  text-decoration: none;
  border-radius: 999px;
  color: var(--ink-soft);
  font-size: 0.92rem;
  font-weight: 600;
}

.nav a:hover,
.nav a.is-active {
  color: var(--ink);
  background: rgba(15, 114, 109, 0.09);
}

.top-cta {
  text-decoration: none;
  color: var(--paper-strong);
  background: linear-gradient(135deg, var(--teal), var(--teal-dark));
  padding: 0.7rem 1rem;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 700;
  box-shadow: 0 10px 24px rgba(15, 114, 109, 0.2);
}

.top-cta-label-short {
  display: none;
}

.top-cta:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 28px rgba(15, 114, 109, 0.24);
}

.top-cta-secondary {
  color: var(--ink);
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.72);
  box-shadow: none;
}

.top-cta-secondary:hover {
  box-shadow: 0 10px 22px rgba(22, 35, 37, 0.08);
}

.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.18fr) minmax(340px, 0.82fr);
  gap: 1.25rem;
  padding: 4.3rem 0 2rem;
  align-items: stretch;
}

.hero-copy,
.hero-card,
.signal-card,
.panel,
.sample-viewer,
.resource-card,
.team-shell,
.citation-wrap {
  box-shadow: var(--shadow-soft);
}

.hero-copy {
  position: relative;
  overflow: hidden;
  padding: clamp(1.45rem, 3vw, 2.5rem);
  border-radius: var(--radius-xl);
  border: 1px solid rgba(255, 255, 255, 0.72);
  background:
    radial-gradient(circle at top right, rgba(215, 161, 75, 0.16), transparent 28%),
    linear-gradient(145deg, rgba(255, 253, 248, 0.95), rgba(249, 240, 229, 0.88));
}

.hero-copy::after {
  content: "";
  position: absolute;
  inset: auto auto -90px -70px;
  width: 210px;
  height: 210px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(15, 114, 109, 0.12), transparent 70%);
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  padding: 0.42rem 0.78rem;
  border-radius: 999px;
  font-size: 0.74rem;
  font-weight: 700;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--teal-dark);
  background: rgba(15, 114, 109, 0.08);
  border: 1px solid rgba(15, 114, 109, 0.15);
  margin: 0 0 1rem;
}

h1,
h2,
h3,
.stat-value,
.signal-index {
  font-family: "Fraunces", serif;
}

.hero h1 {
  margin: 0;
  max-width: 11ch;
  font-size: clamp(2.35rem, 6.5vw, 5rem);
  line-height: 0.96;
  letter-spacing: -0.04em;
}

.lead {
  margin: 1.35rem 0 0;
  max-width: 60ch;
  color: var(--ink-soft);
  font-size: 1.02rem;
}

.hero-actions {
  margin-top: 1.8rem;
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
}

.btn {
  border: 0;
  cursor: pointer;
  text-decoration: none;
  border-radius: 999px;
  padding: 0.85rem 1.2rem;
  font-weight: 700;
  font-size: 0.92rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.btn-primary {
  color: var(--paper-strong);
  background: linear-gradient(135deg, var(--rust), #b85838);
  box-shadow: 0 12px 24px rgba(200, 109, 68, 0.2);
}

.btn-primary:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 28px rgba(200, 109, 68, 0.24);
}

.btn-ghost {
  color: var(--ink);
  border: 1px solid rgba(77, 66, 49, 0.14);
  background: rgba(255, 255, 255, 0.62);
}

.btn-ghost:hover {
  background: rgba(255, 255, 255, 0.88);
}

.hero-pillars {
  margin: 1.9rem 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.8rem;
}

.hero-pillars div {
  display: grid;
  gap: 0.3rem;
  padding: 0.95rem;
  border-radius: var(--radius-md);
  background: rgba(255, 255, 255, 0.6);
  border: 1px solid rgba(255, 255, 255, 0.68);
}

.hero-pillars dt {
  margin: 0;
  font-size: 0.95rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--ink);
}

.hero-pillars dd {
  margin: 0;
  font-size: 0.82rem;
  color: var(--ink-soft);
}

.hero-stack {
  display: grid;
  gap: 1rem;
  align-content: start;
}

.hero-card {
  overflow: hidden;
  border-radius: var(--radius-xl);
}

.hero-card-primary {
  padding: 1.55rem;
  color: #f8f1e8;
  background:
    radial-gradient(circle at top right, rgba(215, 161, 75, 0.2), transparent 28%),
    linear-gradient(155deg, #163335, #0f6360 70%, #114847);
}

.hero-card-primary h2 {
  margin: 0;
  font-size: clamp(1.5rem, 2.4vw, 2rem);
  line-height: 1.08;
  max-width: 12ch;
}

.card-kicker {
  margin: 0 0 0.7rem;
  color: rgba(248, 241, 232, 0.76);
  text-transform: uppercase;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.14em;
}

.hero-card-secondary .card-kicker {
  color: var(--teal-dark);
}

.hero-metrics {
  margin: 1.25rem 0 0;
  padding: 0;
  display: grid;
  gap: 0.8rem;
}

.hero-metrics div {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: baseline;
  padding-bottom: 0.8rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.14);
}

.hero-metrics div:last-child {
  padding-bottom: 0;
  border-bottom: 0;
}

.hero-metrics dt {
  margin: 0;
  color: rgba(248, 241, 232, 0.86);
  font-size: 0.92rem;
  font-weight: 600;
}

.hero-metrics dd {
  margin: 0;
  color: var(--paper-strong);
  font-family: "Fraunces", serif;
  font-size: 1.18rem;
  font-weight: 700;
  text-align: right;
  line-height: 1.25;
  max-width: 18ch;
}

.hero-card-secondary {
  padding: 1.35rem;
  border: 1px solid rgba(255, 255, 255, 0.72);
  background:
    radial-gradient(circle at top right, rgba(200, 109, 68, 0.09), transparent 30%),
    linear-gradient(180deg, rgba(255, 253, 248, 0.96), rgba(248, 239, 227, 0.88));
}

.hero-notes {
  margin: 0;
  padding-left: 1rem;
  display: grid;
  gap: 0.65rem;
  color: var(--ink-soft);
  font-size: 0.92rem;
}

.hero-notes li::marker {
  color: var(--teal);
}

.signal-strip {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
  padding-bottom: 2rem;
}

.signal-card {
  position: relative;
  padding: 1.15rem;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 255, 255, 0.72);
  background: linear-gradient(180deg, rgba(255, 253, 248, 0.88), rgba(248, 239, 227, 0.82));
}

.signal-index {
  display: inline-block;
  margin-bottom: 1rem;
  color: var(--rust);
  font-size: 1.2rem;
  line-height: 1;
}

.signal-card h3 {
  margin: 0 0 0.4rem;
  font-size: 1.08rem;
}

.signal-card p {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.88rem;
}

.section {
  padding: 2rem 0 5rem;
}

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

.section-heading-split {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(280px, 430px);
  gap: 1rem 1.5rem;
  align-items: end;
}

.section-heading-split > :only-child {
  grid-column: 1 / -1;
}

.section-heading h2 {
  margin: 0;
  font-size: clamp(2rem, 3.5vw, 3rem);
  line-height: 1.02;
  letter-spacing: -0.03em;
}

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

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

.panel {
  position: relative;
  overflow: hidden;
  padding: 1.3rem 1.25rem 1.35rem;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 255, 255, 0.72);
  background:
    radial-gradient(circle at top right, rgba(15, 114, 109, 0.08), transparent 28%),
    linear-gradient(180deg, rgba(255, 253, 248, 0.92), rgba(248, 239, 227, 0.84));
}

.panel::before {
  content: "";
  position: absolute;
  inset: 0 auto auto 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, rgba(15, 114, 109, 0.94), rgba(215, 161, 75, 0.85));
}

.panel h3 {
  margin: 0 0 0.45rem;
  font-size: 1.08rem;
}

.panel p {
  margin: 0;
  color: var(--ink-soft);
}

.section-stats {
  position: relative;
  overflow: hidden;
  padding: 4.6rem 0;
  color: #f8f1e8;
  background:
    radial-gradient(circle at 10% 18%, rgba(215, 161, 75, 0.14), transparent 24%),
    radial-gradient(circle at 86% 12%, rgba(15, 114, 109, 0.26), transparent 22%),
    linear-gradient(180deg, #132a2d, #173638 70%, #1a3435);
}

.section-stats .eyebrow {
  color: rgba(248, 241, 232, 0.9);
  background: rgba(255, 255, 255, 0.08);
  border-color: rgba(255, 255, 255, 0.14);
}

.section-stats .section-heading h2 {
  color: #f8f1e8;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
}

.stat-card {
  padding: 1.2rem;
  border-radius: var(--radius-md);
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(10px);
}

.stat-value {
  margin: 0;
  color: #f8f1e8;
  font-size: 2rem;
  line-height: 1;
}

.stat-label {
  margin: 0.45rem 0 0;
  color: rgba(248, 241, 232, 0.78);
  font-size: 0.92rem;
}

.stats-table-hint {
  display: none;
}

.stats-table-wrap {
  margin-top: 1.35rem;
  overflow-x: auto;
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 24px;
  background: rgba(255, 251, 246, 0.96);
  box-shadow: var(--shadow);
}

.stats-table {
  width: max-content;
  min-width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  color: var(--ink);
  font-size: 0.9rem;
}

.stats-table th,
.stats-table td {
  padding: 0.72rem 0.76rem;
  border-bottom: 1px solid rgba(77, 66, 49, 0.11);
  text-align: center;
  white-space: nowrap;
}

.stats-table thead th {
  background: rgba(215, 161, 75, 0.16);
  color: var(--ink);
  font-weight: 800;
  border-bottom: 1px solid rgba(77, 66, 49, 0.18);
}

.stats-table thead tr:first-child th:nth-child(3),
.stats-table thead tr:first-child th:nth-child(4),
.stats-table thead tr:first-child th:nth-child(5),
.stats-table thead tr:nth-child(2) th:nth-child(5),
.stats-table thead tr:nth-child(2) th:nth-child(8),
.stats-table thead tr:nth-child(2) th:nth-child(10),
.stats-table tbody td:nth-child(6),
.stats-table tbody td:nth-child(9),
.stats-table tbody td:nth-child(11),
.stats-table tfoot td:nth-child(6),
.stats-table tfoot td:nth-child(9),
.stats-table tfoot td:nth-child(11) {
  border-left: 2px solid rgba(22, 35, 37, 0.14);
}

.stats-table tbody tr:nth-child(even) {
  background: rgba(248, 239, 227, 0.6);
}

.stats-table tbody th,
.stats-table tfoot th {
  position: sticky;
  left: 0;
  text-align: left;
  background: rgba(255, 251, 246, 0.98);
  font-weight: 700;
  z-index: 1;
}

.stats-table tfoot th,
.stats-table tfoot td {
  font-weight: 800;
  background: rgba(215, 161, 75, 0.16);
  border-top: 2px solid rgba(22, 35, 37, 0.2);
}

.stats-table tfoot th {
  z-index: 2;
}

.sample-viewer {
  padding: 1.2rem;
  border-radius: var(--radius-xl);
  border: 1px solid rgba(255, 255, 255, 0.72);
  background:
    radial-gradient(circle at top right, rgba(15, 114, 109, 0.08), transparent 28%),
    linear-gradient(180deg, rgba(255, 253, 248, 0.94), rgba(248, 239, 227, 0.84));
}

.sample-controls {
  display: grid;
  grid-template-columns: 1fr 1fr auto;
  gap: 0.8rem;
  align-items: end;
  padding: 1rem;
  border-radius: 22px;
  background: rgba(15, 114, 109, 0.06);
  border: 1px solid rgba(15, 114, 109, 0.12);
}

.control-field {
  display: grid;
  gap: 0.4rem;
  color: var(--ink-soft);
  font-size: 0.84rem;
  font-weight: 700;
}

.control-field select {
  width: 100%;
  padding: 0.7rem 0.8rem;
  border-radius: 14px;
  border: 1px solid rgba(77, 66, 49, 0.14);
  background: var(--paper-strong);
  color: var(--ink);
  font-family: "Sora", sans-serif;
  font-size: 0.92rem;
}

.control-field select:focus {
  outline: 2px solid rgba(15, 114, 109, 0.28);
  outline-offset: 1px;
}

.sample-cards {
  margin-top: 1rem;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 0.95rem;
  align-items: start;
}

.sample-card {
  border: 1px solid rgba(77, 66, 49, 0.12);
  border-radius: 22px;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.94), rgba(248, 239, 227, 0.88));
  padding: 0.95rem;
  display: flex;
  flex-direction: column;
  gap: 0.8rem;
  align-self: start;
}

.sample-head {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  padding-bottom: 0.9rem;
  border-bottom: 1px solid rgba(77, 66, 49, 0.1);
}

.sample-meta,
.turn-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
}

.sample-meta {
  align-items: flex-start;
}

.sample-participant-chips {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.6rem;
}

.sample-badge,
.participant-chip,
.turn-number,
.turn-speaker,
.turn-gender {
  display: inline-flex;
  align-items: center;
  gap: 0.28rem;
  padding: 0.24rem 0.56rem;
  border-radius: 999px;
  border: 1px solid rgba(77, 66, 49, 0.12);
  background: rgba(255, 255, 255, 0.76);
  color: var(--ink-soft);
  font-size: 0.72rem;
  font-weight: 700;
}

.sample-badge {
  min-height: 2.1rem;
  padding: 0.36rem 0.72rem;
  font-size: 0.75rem;
}

.sample-badge-dialect {
  max-width: 100%;
  border-radius: 16px;
  line-height: 1.35;
  white-space: normal;
}

.sample-badge-dialect,
.participant-gender,
.turn-gender {
  background: rgba(15, 114, 109, 0.08);
  border-color: rgba(15, 114, 109, 0.2);
  color: var(--teal-dark);
}

.participant-chip {
  width: 100%;
  justify-content: space-between;
  min-height: 3.25rem;
  padding: 0.68rem 0.82rem;
  border-radius: 16px;
  background: rgba(255, 255, 255, 0.9);
  font-size: 0.84rem;
}

.participant-chip > span:first-child {
  min-width: 0;
  overflow-wrap: anywhere;
}

.participant-gender {
  padding: 0.06rem 0.3rem;
  font-size: 0.9rem;
  line-height: 1;
}

.turn-grid-head {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.6rem;
  padding: 0 0.25rem;
  color: var(--ink-soft);
  font-size: 0.66rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.sample-turns {
  margin: 0;
  padding: 0;
  list-style: none;
  display: flex;
  flex-direction: column;
  gap: 0.68rem;
}

.sample-turn {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 0.62rem;
  border-radius: 16px;
  border: 1px solid rgba(77, 66, 49, 0.12);
  background: rgba(255, 255, 255, 0.68);
}

.turn-meta {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
}

.turn-speaker {
  min-width: 0;
}

.turn-parallel {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.55rem;
  align-items: stretch;
}

.turn-source,
.turn-target {
  margin: 0;
  min-width: 0;
  height: 100%;
  padding: 0.62rem 0.68rem;
  border-radius: 12px;
  border: 1px solid rgba(77, 66, 49, 0.11);
  background: var(--paper-strong);
  font-size: 0.84rem;
}

.turn-source {
  color: #40575b;
}

.turn-target {
  font-family: "Noto Sans Arabic", sans-serif;
  color: var(--ink);
  text-align: right;
  background: rgba(15, 114, 109, 0.04);
}

.sample-empty {
  margin: 0;
  padding: 0.8rem 0;
  color: var(--ink-soft);
}

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

.resource-card {
  padding: 1.25rem;
  border-radius: var(--radius-lg);
  border: 1px solid rgba(255, 255, 255, 0.72);
  background:
    radial-gradient(circle at top right, rgba(200, 109, 68, 0.08), transparent 28%),
    linear-gradient(180deg, rgba(255, 253, 248, 0.95), rgba(248, 239, 227, 0.86));
  display: flex;
  flex-direction: column;
  min-height: 210px;
}

.resource-status {
  align-self: flex-start;
  padding: 0.24rem 0.58rem;
  border-radius: 999px;
  background: rgba(15, 114, 109, 0.1);
  color: var(--teal-dark);
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.resource-status-soon {
  background: rgba(215, 161, 75, 0.14);
  color: #7f5a18;
}

.resource-card h3 {
  margin: 0.9rem 0 0;
  font-size: 1.2rem;
}

.resource-card p {
  margin: 0.55rem 0 1.1rem;
  color: var(--ink-soft);
  flex: 1;
}

.resource-card a {
  align-self: flex-start;
  text-decoration: none;
  color: var(--paper-strong);
  background: linear-gradient(135deg, var(--teal), var(--teal-dark));
  padding: 0.72rem 0.92rem;
  border-radius: 999px;
  font-size: 0.88rem;
  font-weight: 700;
  box-shadow: 0 10px 24px rgba(15, 114, 109, 0.18);
}

.resource-card a:hover {
  transform: translateY(-1px);
  box-shadow: 0 14px 28px rgba(15, 114, 109, 0.24);
}

.team-shell {
  padding: 1rem;
  border-radius: var(--radius-xl);
  border: 1px solid rgba(255, 255, 255, 0.72);
  background:
    radial-gradient(circle at top right, rgba(15, 114, 109, 0.08), transparent 26%),
    linear-gradient(180deg, rgba(255, 253, 248, 0.95), rgba(248, 239, 227, 0.86));
}

.contributors-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 1rem;
}

.contributor-card {
  position: relative;
  overflow: hidden;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  padding: 1rem;
  min-height: 0;
  height: 100%;
  border-radius: 22px;
  border: 1px solid rgba(77, 66, 49, 0.12);
  background:
    radial-gradient(circle at top right, rgba(200, 109, 68, 0.08), transparent 24%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(249, 242, 232, 0.9));
  box-shadow: 0 12px 28px rgba(24, 35, 34, 0.08);
}

.contributor-card::before {
  content: "";
  position: absolute;
  inset: 0 auto auto 0;
  width: 100%;
  height: 4px;
  background: linear-gradient(90deg, rgba(15, 114, 109, 0.92), rgba(215, 161, 75, 0.82));
}

.contributor-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 18px 34px rgba(24, 35, 34, 0.12);
}

.contributor-header {
  display: flex;
  align-items: flex-start;
  gap: 0.8rem;
}

.contributor-photo {
  width: 68px;
  height: 68px;
  border-radius: 22px;
  object-fit: cover;
  background: rgba(255, 255, 255, 0.88);
  border: 3px solid rgba(255, 255, 255, 0.88);
  box-shadow: 0 0 0 1px rgba(15, 114, 109, 0.16);
  flex: 0 0 auto;
}

.contributor-photo.fallback {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 0.92rem;
  color: var(--teal-dark);
  background:
    radial-gradient(circle at 26% 22%, rgba(215, 161, 75, 0.56), transparent 42%),
    linear-gradient(145deg, rgba(15, 114, 109, 0.18), rgba(200, 109, 68, 0.16)),
    var(--paper-strong);
}

.contributor-meta {
  display: grid;
  gap: 0.25rem;
  min-width: 0;
  padding-right: 2.4rem;
}

.contributor-name {
  margin: 0;
  font-size: 1.04rem;
  line-height: 1.22;
}

.contributor-affiliation {
  margin: 0;
  color: var(--ink-soft);
  font-size: 0.88rem;
  line-height: 1.45;
  overflow-wrap: anywhere;
}

.contributor-country {
  position: absolute;
  top: 0.9rem;
  right: 0.9rem;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.1rem;
  height: 1.78rem;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid rgba(77, 66, 49, 0.1);
  box-shadow: inset 0 -1px 0 rgba(77, 66, 49, 0.08);
}

.country-flag {
  font-size: 1rem;
  line-height: 1;
}

.citation-wrap {
  display: grid;
  grid-template-columns: minmax(240px, 300px) minmax(0, 1fr);
  gap: 1rem;
  padding: 1rem;
  border-radius: var(--radius-xl);
  background:
    radial-gradient(circle at top right, rgba(215, 161, 75, 0.14), transparent 28%),
    linear-gradient(180deg, #122729, #173436);
  color: #f8f1e8;
}

.citation-meta {
  display: grid;
  align-content: start;
  gap: 1rem;
  padding: 0.35rem;
}

.citation-note {
  margin: 0;
  color: rgba(248, 241, 232, 0.84);
}

.citation-box {
  margin: 0;
  overflow-x: auto;
  padding: 1.2rem;
  border-radius: 22px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(10, 18, 20, 0.72);
  color: #eef5f2;
  font-size: 0.84rem;
  line-height: 1.58;
}

.citation-box code {
  font-family: "Noto Sans Arabic", "SFMono-Regular", "Courier New", monospace;
}

#copy-bibtex {
  justify-self: start;
}

.footer {
  padding: 1.2rem 0 1.6rem;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.8rem;
  padding: 1rem 1.2rem;
  border-radius: 24px;
  border: 1px solid rgba(255, 255, 255, 0.62);
  background: rgba(255, 250, 242, 0.72);
  color: var(--ink-soft);
  font-size: 0.88rem;
}

.footer-inner p {
  margin: 0;
}

.footer-partner {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
}

.footer-partner img {
  width: auto;
  height: 28px;
  object-fit: contain;
}

@media (max-width: 1100px) {
  .brand {
    width: 100%;
    overflow: hidden;
  }

  .brand span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .topbar-inner {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto auto;
    align-items: center;
    column-gap: 0.5rem;
    row-gap: 0.85rem;
    border-radius: 28px;
  }

  .topbar-menu {
    display: none;
    grid-column: 1 / -1;
    width: 100%;
    margin-left: 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0.75rem;
    padding-top: 0.2rem;
  }

  .topbar-inner.is-menu-open .topbar-menu {
    display: flex;
  }

  .menu-toggle {
    display: inline-flex;
    grid-column: 3;
    justify-self: end;
    margin-left: 0;
    padding: 0 0.88rem;
  }

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

  .topbar-inner.is-menu-open .menu-toggle-icon span:nth-child(2) {
    transform: scaleX(0.3);
    opacity: 0;
  }

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

  .topbar-actions {
    grid-column: 2;
    justify-self: end;
    gap: 0.45rem;
  }

  .top-cta {
    padding: 0.62rem 0.82rem;
    font-size: 0.8rem;
    box-shadow: none;
  }

  .nav {
    width: 100%;
    display: grid;
    gap: 0.35rem;
    white-space: normal;
    overflow: visible;
    padding-bottom: 0;
  }

  .nav a {
    width: 100%;
    padding: 0.78rem 0.92rem;
    border: 1px solid rgba(77, 66, 49, 0.08);
    background: rgba(255, 255, 255, 0.62);
  }

  .hero {
    grid-template-columns: 1fr;
  }

  .signal-strip,
  .insights-grid,
  .contributors-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .resources-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .section-heading-split,
  .citation-wrap {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 960px) {
  body::before {
    height: min(640px, 100vw);
    opacity: 0.34;
  }

  .bg-blur {
    width: 320px;
    height: 320px;
    filter: blur(72px);
  }

  .hero {
    padding-top: 2.9rem;
  }

  .hero-pillars,
  .stats-grid,
  .overview-grid {
    grid-template-columns: 1fr;
  }

  .sample-controls {
    grid-template-columns: 1fr 1fr;
  }

  .sample-controls .btn {
    grid-column: 1 / -1;
    justify-self: start;
  }

  .stats-table-hint {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.5rem 0.72rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.12);
  }

  .turn-parallel {
    grid-template-columns: 1fr;
  }

  .turn-meta {
    display: flex;
    flex-wrap: wrap;
  }

  .turn-grid-head {
    display: none;
  }
}

@media (max-width: 860px) {
  .top-cta-label-full {
    display: none;
  }

  .top-cta-label-short {
    display: inline;
  }
}

@media (max-width: 720px) {
  body::before {
    height: min(500px, 100vw);
    opacity: 0.26;
  }

  .bg-grid {
    background-size: 36px 36px;
    opacity: 0.22;
  }

  .container {
    width: min(1180px, calc(100% - 1.2rem));
  }

  .topbar {
    padding-top: 0.7rem;
  }

  .topbar-inner {
    min-height: 68px;
    padding: 0.8rem;
  }

  .brand {
    gap: 0.55rem;
  }

  .brand-logo {
    width: 34px;
    height: 34px;
  }

  .menu-toggle {
    width: 2.9rem;
    padding: 0;
  }

  .menu-toggle-label {
    display: none;
  }

  .topbar-actions {
    gap: 0.28rem;
  }

  .top-cta {
    padding: 0.5rem 0.58rem;
    font-size: 0.72rem;
  }

  .hero {
    padding-top: 2.4rem;
  }

  .hero h1 {
    max-width: none;
  }

  .hero-card-primary h2,
  .hero-metrics dd {
    max-width: none;
  }

  .signal-strip,
  .resources-grid,
  .contributors-grid,
  .sample-controls,
  .sample-participant-chips {
    grid-template-columns: 1fr;
  }

  .sample-cards {
    grid-template-columns: 1fr;
  }

  .section,
  .section-stats {
    padding: 3.4rem 0;
  }
}

@media (max-width: 520px) {
  .topbar-inner {
    grid-template-columns: minmax(0, 1fr) auto auto;
    column-gap: 0.24rem;
    padding: 0.7rem;
  }

  .brand {
    gap: 0.45rem;
  }

  .brand-logo {
    width: 30px;
    height: 30px;
  }

  .brand span {
    font-size: 0.84rem;
  }

  .topbar-actions {
    gap: 0.24rem;
  }

  .top-cta {
    padding: 0.4rem 0.42rem;
    font-size: 0.62rem;
  }

  .menu-toggle {
    width: 2.4rem;
    height: 2.4rem;
    border-radius: 14px;
  }

  .menu-toggle-icon span {
    width: 0.82rem;
  }

  .top-cta-label-full {
    display: none;
  }

  .top-cta-label-short {
    display: inline;
  }

  .hero-copy,
  .hero-card-primary,
  .hero-card-secondary,
  .sample-viewer,
  .team-shell,
  .citation-wrap {
    padding: 1rem;
  }

  .hero-pillars div,
  .sample-controls {
    padding: 0.85rem;
  }

  .hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .hero-actions .btn {
    width: 100%;
  }

  .hero-metrics div {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.35rem;
  }

  .hero-metrics dd {
    text-align: left;
  }

  .sample-controls .btn {
    width: 100%;
  }

  .sample-card,
  .resource-card,
  .contributor-card {
    padding: 0.85rem;
    border-radius: 18px;
  }

  .turn-source,
  .turn-target,
  .citation-box {
    font-size: 0.8rem;
  }

  .turn-source,
  .turn-target {
    padding: 0.56rem 0.6rem;
  }

  .citation-box {
    padding: 0.95rem;
  }

.footer-inner {
  justify-content: center;
  text-align: center;
}
}

@media (max-width: 460px) {
  .topbar-inner {
    padding: 0.64rem;
  }

  .brand-logo {
    width: 28px;
    height: 28px;
  }

  .brand span {
    font-size: 0.8rem;
  }

  .top-cta {
    padding: 0.34rem 0.38rem;
    font-size: 0.58rem;
  }

  .menu-toggle {
    width: 2.15rem;
    height: 2.15rem;
  }

  .menu-toggle-icon span {
    width: 0.74rem;
  }
}
