:root {
  --navy: #0e2338;
  --navy-deep: #091b2b;
  --navy-soft: #173249;
  --ink: #172c3d;
  --ivory: #f7f4ed;
  --paper: #fffdfa;
  --copper: #b68458;
  --copper-light: #d7b38d;
  --burgundy: #672e3b;
  --burgundy-bright: #8b4052;
  --line: #d8d3c8;
  --muted: #56646c;
  --shadow: 0 18px 42px rgba(14, 35, 56, .08);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--ivory);
  color: var(--ink);
  font-family: 'IBM Plex Sans Arabic', system-ui, sans-serif;
  font-size: 17px;
  line-height: 1.85;
  text-rendering: optimizeLegibility;
}
body::before {
  content: "";
  display: block;
  height: 4px;
  background: linear-gradient(90deg, var(--burgundy) 0 24%, var(--copper) 24% 38%, var(--navy) 38% 100%);
}
a { color: inherit; text-decoration: none; }
a:focus-visible, button:focus-visible {
  outline: 3px solid var(--copper-light);
  outline-offset: 4px;
}
.skip-link {
  position: fixed;
  inset: 10px auto auto 10px;
  z-index: 100;
  padding: 9px 14px;
  background: var(--paper);
  color: var(--navy);
  transform: translateY(-160%);
}
.skip-link:focus { transform: translateY(0); }
.wrap { width: min(100% - 10vw, 1280px); margin-inline: auto; }

header {
  background: var(--navy);
  color: #fff;
  border-bottom: 1px solid #ffffff24;
}
.head {
  min-height: 92px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 15px;
  flex: none;
}
.monogram {
  width: 46px;
  height: 46px;
  display: grid;
  place-items: center;
  border: 1px solid var(--copper);
  color: var(--copper-light);
  font: 400 25px/1 Georgia, serif;
}
.brand strong {
  display: block;
  font: 600 17px/1.45 'Noto Kufi Arabic', sans-serif;
}
.brand small {
  display: block;
  color: var(--copper-light);
  font: 600 11px/1.5 Arial, sans-serif;
  letter-spacing: .18em;
}
header nav {
  display: flex;
  align-items: center;
  gap: 7px 20px;
  flex-wrap: wrap;
  font-size: 14px;
}
header nav a {
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  border-bottom: 1px solid transparent;
}
header nav a:hover { color: #e0b687; border-color: #e0b687; }
.language {
  min-height: 34px;
  padding: 4px 12px;
  border: 1px solid #ffffff50;
  font: 600 12px/1 Arial, sans-serif;
  letter-spacing: .08em;
}

.site-nav {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--navy-soft);
  color: white;
  border-bottom: 1px solid #ffffff26;
  box-shadow: 0 8px 22px rgba(9, 27, 43, .12);
}
.site-nav .wrap {
  display: flex;
  align-items: stretch;
  gap: 4px;
  overflow-x: auto;
  scrollbar-width: none;
}
.site-nav .wrap::-webkit-scrollbar { display: none; }
.site-nav a {
  min-height: 49px;
  padding: 0 14px;
  display: inline-flex;
  align-items: center;
  flex: 0 0 auto;
  border-bottom: 3px solid transparent;
  font-size: 14px;
  white-space: nowrap;
}
.site-nav a:hover { background: #ffffff0b; color: #f1c89d; }
.site-nav a[aria-current="page"] {
  background: #ffffff0d;
  border-color: var(--copper-light);
  color: #fff;
  font-weight: 700;
}

.hero {
  position: relative;
  overflow: hidden;
  background: var(--navy);
  color: #fff;
}
.hero::after, .page-hero::after {
  content: "";
  position: absolute;
  inset: 0 48% 0 0;
  background: repeating-linear-gradient(90deg, transparent 0 47px, #ffffff08 48px 49px), linear-gradient(140deg, transparent 50%, #b6845814);
  pointer-events: none;
}
.hero-inner {
  min-height: 560px;
  padding-block: 96px 106px;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(260px, .8fr);
  gap: 8%;
  align-items: center;
  position: relative;
  z-index: 1;
}
.eyebrow, .kicker {
  color: var(--burgundy);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .045em;
}
.eyebrow { color: var(--copper-light); }
.hero h1 {
  max-width: 820px;
  margin: 22px 0 18px;
  font: 700 clamp(38px, 5.3vw, 76px)/1.36 'Noto Kufi Arabic', sans-serif;
  letter-spacing: -.055em;
}
.hero p {
  max-width: 680px;
  margin: 0;
  color: #dbe0e2;
  font-size: clamp(18px, 2vw, 23px);
}
.actions { display: flex; gap: 13px; flex-wrap: wrap; margin-top: 40px; }
.button {
  min-height: 50px;
  padding: 11px 25px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--copper);
  background: var(--copper);
  color: #122438;
  font-weight: 700;
  text-align: center;
}
.button:hover { filter: brightness(1.06); box-shadow: 0 8px 24px #0002; }
.button.alt { background: transparent; color: var(--ivory); border-color: #8193a2; }
.button-dark { background: var(--navy); border-color: var(--navy); color: #fff; }
.button-outline { background: transparent; color: var(--navy); border-color: var(--navy); }
.button-disabled { background: #e7e1d7; border-color: var(--line); color: #667078; cursor: not-allowed; }
.hero-aside { border-inline-start: 1px solid #b6845870; padding-inline-start: 28px; color: #d2d9dd; }
.hero-aside .num { display: block; color: var(--copper-light); font: 400 68px/1 Georgia, serif; }
.hero-aside p { font-size: 16px; line-height: 2; }

.section { padding-block: 88px; }
.section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 30px;
  margin-bottom: 34px;
}
.section h2, .conversion-next h2 {
  margin: 8px 0 0;
  font: 700 clamp(27px, 3vw, 41px)/1.5 'Noto Kufi Arabic', sans-serif;
  letter-spacing: -.035em;
}
.section-intro { max-width: 660px; margin: 0; color: var(--muted); }
.topic-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-block-start: 1px solid var(--line);
  border-inline-start: 1px solid var(--line);
}
.topic {
  min-height: 188px;
  padding: 30px 28px 34px;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  border-block-end: 1px solid var(--line);
  border-inline-end: 1px solid var(--line);
  transition: background .2s, transform .2s;
}
.topic:hover { background: #ebe5d9; transform: translateY(-2px); }
.topic span { color: var(--copper); font: 400 16px Georgia, serif; }
.topic h3 { margin: 26px 0 0; font: 600 20px/1.6 'Noto Kufi Arabic', sans-serif; }
.feature { background: #e8e2d7; }
.feature-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8%; align-items: start; }
.feature blockquote {
  margin: 0;
  color: var(--navy);
  font: 600 clamp(29px, 3.5vw, 47px)/1.55 'Noto Kufi Arabic', sans-serif;
  letter-spacing: -.045em;
}
.feature p { margin: 14px 0 0; color: #45525a; }
.feature .line { width: 80px; height: 3px; margin-bottom: 28px; background: var(--burgundy); }
.pillars { background: var(--navy); color: #f8f7f2; }
.pillars .kicker { color: var(--copper-light); }
.pillar-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 24px; margin-top: 38px; }
.pillar { padding-top: 25px; border-top: 2px solid var(--copper); }
.pillar h3 { margin: 0 0 12px; font: 600 21px/1.5 'Noto Kufi Arabic', sans-serif; }
.pillar p { margin: 0; color: #bbc8d0; }
.about { display: grid; grid-template-columns: .7fr 1.3fr; gap: 8%; align-items: start; }
.about p { max-width: 710px; margin: 0 0 22px; }
.en { background: #eae6dd; }
.en .wrap { display: flex; gap: 50px; align-items: baseline; }
.en strong { color: var(--navy); font: 600 20px Georgia, serif; white-space: nowrap; }
.en p { margin: 0; color: #45525a; font: 16px/1.7 Arial, sans-serif; }

.page-hero {
  position: relative;
  overflow: hidden;
  padding-block: 70px 76px;
  background: var(--navy);
  color: #fff;
}
.page-hero .wrap { position: relative; z-index: 1; }
.page-hero .kicker { color: var(--copper-light); }
.page-hero h1 {
  max-width: 920px;
  margin: 8px 0 14px;
  font: 700 clamp(32px, 4vw, 55px)/1.45 'Noto Kufi Arabic', sans-serif;
  letter-spacing: -.045em;
}
.page-hero p { max-width: 760px; margin: 0; color: #d2dce1; font-size: 20px; }
.crumb { margin-bottom: 24px; color: #b8c8d1; font-size: 14px; }
.crumb a { text-decoration: underline; text-underline-offset: 5px; }
.product-mark {
  max-width: 100%;
  display: inline-flex;
  margin-bottom: 22px;
  padding: 7px 11px;
  border: 1px solid #ffffff42;
  color: #f0d0ad;
  font: 700 12px/1.2 Arial, sans-serif;
  letter-spacing: .1em;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}
.content { padding-block: 68px 94px; }
.prose { max-width: 800px; }
.prose h2 { margin: 0 0 15px; font: 700 28px/1.5 'Noto Kufi Arabic', sans-serif; }
.prose h2:not(:first-child) { margin-top: 34px; }
.prose p { margin: 0 0 20px; }
.cards { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px; margin-top: 35px; }
.card {
  min-height: 205px;
  padding: 28px;
  display: flex;
  flex-direction: column;
  border: 1px solid var(--line);
  background: var(--paper);
  box-shadow: 0 1px 0 rgba(14, 35, 56, .03);
  transition: border-color .2s, background .2s, transform .2s, box-shadow .2s;
}
.card h2, .card h3 { margin: 0 0 12px; font: 600 21px/1.5 'Noto Kufi Arabic', sans-serif; }
.card p { margin: 0; color: var(--muted); }
.card:hover { border-color: var(--copper); background: #fff; transform: translateY(-3px); box-shadow: var(--shadow); }
.label { display: block; margin-bottom: 16px; color: var(--burgundy); font-size: 13px; font-weight: 700; }
.notice, .repository-empty {
  max-width: 820px;
  margin-block: 32px;
  padding: 23px 26px;
  border-inline-start: 3px solid var(--copper);
  background: #eee9df;
}
.notice p, .repository-empty p { margin: 0; }
.repository-empty {
  display: grid;
  grid-template-columns: 170px 1fr;
  gap: 26px;
  align-items: center;
}
.status-tag {
  color: var(--burgundy);
  font-size: 13px;
  font-weight: 700;
  letter-spacing: .025em;
}
.list { max-width: 820px; margin-top: 32px; border-top: 1px solid var(--line); }
.list-item { padding: 21px 0; border-bottom: 1px solid var(--line); }
.list-item h3 { margin: 0 0 6px; font: 600 19px/1.5 'Noto Kufi Arabic', sans-serif; }
.list-item p { margin: 0; color: var(--muted); }
.back {
  min-height: 44px;
  margin-top: 36px;
  display: inline-flex;
  align-items: center;
  color: var(--burgundy);
  border-bottom: 1px solid var(--burgundy);
  font-weight: 700;
}
.knowledge-page .content { position: relative; }
.knowledge-page .content::before {
  content: "RESEARCH LIBRARY  /  SOURCE · CONTEXT · EFFECT";
  display: block;
  margin-bottom: 32px;
  padding-bottom: 13px;
  border-bottom: 1px solid var(--line);
  color: #6b747a;
  font: 700 11px/1.4 Arial, sans-serif;
  letter-spacing: .12em;
  direction: ltr;
  text-align: left;
}
.topics-index .cards { counter-reset: topic; }
.topics-index .card::before {
  counter-increment: topic;
  content: counter(topic, decimal-leading-zero);
  margin-bottom: auto;
  padding-bottom: 28px;
  color: var(--copper);
  font: 400 16px/1 Georgia, serif;
}
.topic-hub .page-hero::before {
  content: "TOPIC HUB";
  position: absolute;
  inset: auto auto 20px 5vw;
  z-index: 1;
  color: #ffffff54;
  font: 700 11px/1 Arial, sans-serif;
  letter-spacing: .18em;
}

.record-section { margin-block: 38px 8px; }
.record-heading { padding-bottom: 15px; border-bottom: 1px solid var(--line); }
.record-heading h2 { margin: 4px 0 0; font: 700 27px/1.5 'Noto Kufi Arabic', sans-serif; }
.record-grid { margin-top: 20px; }
.record-card { min-height: 235px; }
.record-card h3 { overflow-wrap: anywhere; }
.record-source {
  display: block;
  margin-top: auto;
  padding-top: 20px;
  color: #667078;
  font-size: 13px;
}
.featured-content { background: #ece8df; }
.featured-content .record-section { margin-top: 10px; }
.featured-content .record-heading { display: none; }
.record-detail {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(240px, 300px);
  gap: clamp(36px, 6vw, 84px);
  align-items: start;
}
.record-main { max-width: 820px; min-width: 0; }
.record-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 22px;
  padding-bottom: 26px;
  border-bottom: 1px solid var(--line);
  color: var(--muted);
  font-size: 14px;
}
.detail-section { padding-block: 28px; border-bottom: 1px solid var(--line); }
.detail-section h2 { margin: 0 0 14px; font: 700 25px/1.5 'Noto Kufi Arabic', sans-serif; }
.detail-section p { margin: 0; }
.detail-section ul { margin: 0; padding-inline-start: 24px; }
.detail-section li + li { margin-top: 10px; }
.related-list a { color: var(--burgundy); border-bottom: 1px solid currentColor; }
.transcript { white-space: pre-wrap; overflow-wrap: anywhere; }
.record-aside {
  position: sticky;
  top: 74px;
  padding: 25px;
  border-top: 3px solid var(--copper);
  background: #eee9df;
}
.record-aside h2 { margin: 28px 0 12px; font: 600 17px/1.5 'Noto Kufi Arabic', sans-serif; }
.source-button {
  display: block;
  margin-top: 15px;
  padding: 10px 14px;
  background: var(--navy);
  color: #fff;
  font-weight: 700;
  text-align: center;
  overflow-wrap: anywhere;
}
.source-button.secondary { background: transparent; color: var(--navy); border: 1px solid var(--navy); }
.topic-tags { display: flex; flex-wrap: wrap; gap: 8px; }
.topic-tags a { padding: 5px 10px; border: 1px solid #cbbfb0; font-size: 13px; }
.topic-tags a:hover { border-color: var(--burgundy); color: var(--burgundy); }

/* Research records keep the reading path distinct from the general content cards. */
.research-hero { padding-block: 46px 52px; }
.research-hero h1 { max-width: 1050px; font-size: clamp(31px, 3.4vw, 46px); }
.record-detail-page .content { padding-block: 42px 84px; }
.research-attribution {
  margin: 24px 0 0;
  padding: 15px 19px;
  border-inline-start: 3px solid var(--burgundy);
  background: #f0ece4;
  color: #394a54;
  font-size: 15px;
}
.section-overline { color: var(--burgundy); font-size: 13px; font-weight: 700; letter-spacing: .04em; }
.research-map .attribution, .graph-section .attribution, #institutions .attribution { margin: 0 0 18px; color: var(--muted); font-size: 15px; }
.map-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; margin-top: 22px; }
.map-card { min-width: 0; padding: 21px; background: var(--paper); border: 1px solid var(--line); border-top: 3px solid var(--copper); }
.map-card h3, .entity-groups h3 { margin: 0 0 9px; font: 700 17px/1.65 'Noto Kufi Arabic', sans-serif; }
.map-card p { margin: 0 0 17px; font-size: 15px; line-height: 1.8; }
.entity-links { display: flex; flex-wrap: wrap; gap: 8px; }
.entity-links a { display: inline-block; padding: 5px 10px; border: 1px solid #c9c0b4; background: #f8f5ee; color: var(--burgundy); font-size: 13px; line-height: 1.65; overflow-wrap: anywhere; }
.entity-links a:hover { border-color: var(--burgundy); text-decoration: underline; }
.entity-groups { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.entity-groups ul { list-style: none; padding: 0; }
.entity-groups li { padding: 8px 0; border-bottom: 1px solid var(--line); font-size: 15px; scroll-margin-top: 100px; }
.entity-groups li:target { background: #f0e6da; color: var(--burgundy); }
.research-toc { display: grid; gap: 3px; margin-top: 10px; }
.research-toc a { display: block; padding: 7px 0; border-bottom: 1px solid #d6cbbd; color: var(--navy); font-size: 14px; }
.research-toc a:hover { color: var(--burgundy); text-decoration: underline; }
.source-actions { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 20px; }
.source-actions .source-button { margin: 0; }
.original-source { scroll-margin-top: 60px; }

.conversion-next {
  max-width: 1000px;
  margin-top: 54px;
  padding: 30px 32px;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 28px;
  align-items: center;
  border: 1px solid var(--line);
  border-top: 3px solid var(--burgundy);
  background: var(--paper);
}
.conversion-next h2 { margin: 4px 0 8px; font-size: clamp(22px, 2.4vw, 31px); }
.conversion-next p { margin: 0; color: var(--muted); }
.conversion-actions { display: flex; gap: 10px; flex-wrap: wrap; justify-content: flex-end; }
.journey-grid .card { position: relative; }
.journey-grid .card:not(:last-child)::after {
  content: "←";
  position: absolute;
  inset-inline-end: -15px;
  top: 50%;
  z-index: 2;
  width: 28px;
  height: 28px;
  display: grid;
  place-items: center;
  border-radius: 50%;
  background: var(--burgundy);
  color: #fff;
  font: 700 15px/1 Arial, sans-serif;
}

.product-consumer { --product-accent: var(--burgundy-bright); }
.product-consumer .page-hero {
  background: linear-gradient(130deg, #4f2230 0%, var(--burgundy) 46%, var(--navy) 100%);
}
.product-consumer .list { border-top-color: #b58d97; }
.product-consumer .list-item { padding-inline: 20px; border-color: #dac9cd; }
.product-consumer .list-item:nth-child(odd) { background: #f1e7e7; }
.product-institutional .page-hero {
  background: linear-gradient(120deg, #071522 0%, var(--navy) 70%, #26445a 100%);
}
.product-institutional .page-hero::after {
  inset: 0;
  background: repeating-linear-gradient(90deg, transparent 0 79px, #ffffff07 80px 81px);
}
.product-institutional .notice { background: #e4e8e9; border-color: var(--navy-soft); }
.audience-strip {
  max-width: 820px;
  margin: -1px 0 34px;
  padding: 15px 20px;
  border: 1px solid var(--line);
  background: var(--paper);
  color: var(--muted);
  font-size: 15px;
}

html[lang="en"] body { font-family: Arial, sans-serif; line-height: 1.72; }
html[lang="en"] .page-hero h1, html[lang="en"] .prose h2 { font-family: Georgia, serif; letter-spacing: -.02em; }
html[lang="en"] .back { color: var(--burgundy); }

footer { padding-block: 38px; background: var(--navy-deep); color: #c7d0d5; }
.foot { display: grid; grid-template-columns: auto 1fr auto; gap: 28px; align-items: center; }
footer strong { color: #fff; font: 600 15px/1.5 'Noto Kufi Arabic', sans-serif; }
footer small { font-size: 13px; }
.footer-nav { display: flex; justify-content: center; gap: 8px 20px; flex-wrap: wrap; }
.footer-nav a { min-height: 44px; display: inline-flex; align-items: center; font-size: 13px; }
.footer-nav a:hover { color: var(--copper-light); }

@media (max-width: 980px) {
  .wrap { width: min(100% - 56px, 1280px); }
  .head { padding-block: 18px 12px; flex-wrap: wrap; }
  header nav { width: 100%; flex-wrap: nowrap; overflow-x: auto; scrollbar-width: none; }
  header nav::-webkit-scrollbar { display: none; }
  .hero-inner { min-height: auto; grid-template-columns: 1fr; padding-block: 74px 80px; }
  .hero-aside { max-width: 620px; }
  .topic-grid, .pillar-grid { grid-template-columns: repeat(2, 1fr); }
  .feature-grid, .about { grid-template-columns: 1fr; gap: 36px; }
  .cards { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .foot { grid-template-columns: 1fr auto; }
  .footer-nav { grid-column: 1 / -1; grid-row: 2; justify-content: flex-start; }
  .record-detail { grid-template-columns: 1fr; }
  .record-aside { position: static; max-width: 820px; }
  .record-detail { gap: 26px; }
}

@media (max-width: 680px) {
  .wrap { width: calc(100% - 40px); }
  body { font-size: 16px; line-height: 1.8; }
  body::before { height: 3px; }
  .head { gap: 14px; padding-block: 15px 10px; }
  .brand { gap: 11px; }
  .monogram { width: 40px; height: 40px; font-size: 22px; }
  .brand strong { font-size: 15px; }
  header nav { gap: 0 16px; }
  header nav a { min-height: 40px; font-size: 13px; }
  .site-nav a { min-height: 46px; padding-inline: 11px; font-size: 13px; }
  .hero-inner { padding-block: 55px 62px; }
  .hero h1 { margin-top: 18px; font-size: clamp(34px, 11vw, 45px); }
  .hero-aside { display: none; }
  .actions { margin-top: 30px; }
  .actions .button { width: 100%; }
  .section { padding-block: 58px; }
  .section-head { display: block; }
  .section-intro { margin-top: 13px; }
  .topic-grid, .pillar-grid, .cards { grid-template-columns: 1fr; }
  .topic { min-height: 135px; }
  .en .wrap { display: block; }
  .en p { margin-top: 12px; }
  .feature blockquote { font-size: 29px; }
  .page-hero { padding-block: 48px 52px; }
  .page-hero h1 { font-size: 34px; }
  .page-hero p { font-size: 18px; }
  .content { padding-block: 49px 66px; }
  .record-detail-page .content { padding-block: 26px 60px; }
  .research-hero { padding-block: 32px 38px; }
  .research-hero h1 { font-size: clamp(27px, 7vw, 36px); }
  .map-grid, .entity-groups { grid-template-columns: 1fr; }
  .map-card { padding: 17px; }
  .source-actions .source-button { width: 100%; }
  .card { min-height: 176px; padding: 23px; }
  .repository-empty { grid-template-columns: 1fr; gap: 8px; }
  .conversion-next { grid-template-columns: 1fr; margin-top: 42px; padding: 24px 22px; }
  .conversion-actions { justify-content: flex-start; }
  .conversion-actions .button { width: 100%; }
  .journey-grid .card::after { display: none; }
  .foot { grid-template-columns: 1fr; gap: 8px; }
  .footer-nav { grid-column: auto; grid-row: auto; justify-content: flex-start; gap: 0 18px; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; }
}
