/* ==========================================================================
   Vigilia landing page
   Implemented from the "Vigilia Landing" design canvas.

   The page ships every string in both English and Arabic. Each localised
   block carries data-lang="en" or data-lang="ar"; the rule under "Language
   gate" hides the inactive one. Typographic differences between the two
   scripts (weight, size, line-height, letter-spacing, the mono/Arabic swap
   on labels) live in html[lang="ar"] overrides next to their base rule
   rather than in a duplicated Arabic stylesheet.
   ========================================================================== */

/* --------------------------------------------------------------- tokens -- */

:root {
  --bg: #0b1017;
  --bg-raised: #0f1621;
  --bg-alt: #0d131c;
  --bg-hover: #111826;

  --fg: #e9eef6;
  --fg-muted: #b7c1d3;
  --fg-dim: #9aa6ba;
  --fg-faint: #6b7688;

  --accent: #62e3d3;
  --accent-25: rgba(98, 227, 211, 0.25);
  --accent-35: rgba(98, 227, 211, 0.35);
  --accent-55: rgba(98, 227, 211, 0.55);
  --warn: #f5a524;

  --line: rgba(255, 255, 255, 0.08);
  --line-2: rgba(255, 255, 255, 0.1);
  --line-3: rgba(255, 255, 255, 0.12);
  --line-field: rgba(255, 255, 255, 0.14);
  --line-4: rgba(255, 255, 255, 0.2);
  --rule: rgba(255, 255, 255, 0.22);
  --wash: rgba(255, 255, 255, 0.06);
  --hairline: rgba(255, 255, 255, 0.07);

  --sans-latin: "IBM Plex Sans", system-ui, -apple-system, "Segoe UI", sans-serif;
  --sans-arabic: "IBM Plex Sans Arabic", "IBM Plex Sans", system-ui, sans-serif;
  --mono: "IBM Plex Mono", ui-monospace, SFMono-Regular, Menlo, monospace;
  --sans: var(--sans-latin);

  --shell: 1240px;
  --gutter: clamp(20px, 5vw, 56px);
  --radius: 10px;
  --radius-sm: 6px;

  --section-y: clamp(64px, 8vw, 120px);
  --section-gap: clamp(40px, 5vw, 64px);
}

html[lang="ar"] {
  --sans: var(--sans-arabic);
}

/* ----------------------------------------------------------------- base -- */

*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--sans);
  -webkit-font-smoothing: antialiased;
}

/* Every container on this page spaces its children with flex/grid gap, so
   the default block margins are only ever in the way. */
h1,
h2,
h3,
p,
figure,
blockquote,
dl,
dd,
ol,
ul {
  margin: 0;
}

ol,
ul {
  padding: 0;
}

a {
  color: var(--accent);
}

img,
svg {
  max-width: 100%;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* Language gate. !important so it beats the state rules (.contact.is-sent)
   further down, which resolve to the same specificity. */
html[lang="en"] [data-lang="ar"],
html[lang="ar"] [data-lang="en"] {
  display: none !important;
}

.shell {
  max-width: var(--shell);
  margin-inline: auto;
  padding-inline: var(--gutter);
}

.visually-hidden {
  position: absolute;
  width: 1px;
  height: 1px;
  margin: -1px;
  padding: 0;
  overflow: hidden;
  clip-path: inset(50%);
  white-space: nowrap;
}

.skip-link {
  position: absolute;
  inset-inline-start: var(--gutter);
  top: -100px;
  z-index: 50;
  padding: 10px 16px;
  border-radius: var(--radius-sm);
  background: var(--accent);
  color: var(--bg);
  font: 500 14px/1 var(--sans);
  text-decoration: none;
  transition: top 0.15s;
}

.skip-link:focus {
  top: 12px;
}

/* -------------------------------------------------------------- buttons -- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  font-family: inherit;
  font-weight: 500;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.15s, border-color 0.15s, color 0.15s;
}

html[lang="ar"] .btn--primary {
  font-weight: 600;
}

.btn--primary {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--bg);
}

.btn--primary:hover,
.btn--primary:focus-visible {
  background: #fff;
  border-color: #fff;
  color: var(--bg);
}

.btn--ghost {
  background: none;
  border-color: var(--line-4);
  color: var(--fg);
}

.btn--ghost:hover,
.btn--ghost:focus-visible {
  border-color: var(--accent);
  color: var(--accent);
}

/* The design draws filled buttons borderless; the transparent border here
   keeps the filled and outlined variants the same box. */
.btn--sm {
  font-size: 13px;
  padding: 9px 13px;
}

.btn--lg {
  font-size: 15px;
  padding: 14px 21px;
}

/* --------------------------------------------------------------- header -- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(11, 16, 23, 0.86);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
}

.site-header .shell {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px 28px;
  padding-block: 14px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--fg);
  text-decoration: none;
}

.brand__mark {
  direction: ltr;
  font: 600 16px/1 var(--sans-latin);
  letter-spacing: 0.2em;
}

.brand__rule {
  width: 1px;
  height: 14px;
  background: var(--rule);
}

.brand__tag {
  font: 400 12px/1 var(--mono);
  color: var(--fg-dim);
}

html[lang="ar"] .brand__tag {
  font: 500 13px/1 var(--sans-arabic);
}

.nav {
  display: flex;
  flex-wrap: wrap;
  gap: 22px;
  margin-inline-start: auto;
  font-size: 14px;
}

.nav a {
  color: var(--fg-muted);
  text-decoration: none;
  transition: color 0.15s;
}

.nav a:hover,
.nav a:focus-visible {
  color: #fff;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 14px;
}

.lang {
  display: flex;
  direction: ltr;
  border: 1px solid var(--line-field);
  border-radius: var(--radius-sm);
  overflow: hidden;
}

.lang button {
  border: none;
  background: transparent;
  color: var(--fg-dim);
  cursor: pointer;
  font: 500 12px/1 var(--mono);
  padding: 7px 10px;
  transition: background 0.15s, color 0.15s;
}

.lang button[data-set-lang="ar"] {
  font: 500 14px/1 var(--sans-arabic);
  padding: 6px 10px 5px;
}

.lang button[aria-pressed="true"] {
  background: var(--fg);
  color: var(--bg);
}

/* ----------------------------------------------------------------- hero -- */

.hero {
  max-width: var(--shell);
  margin-inline: auto;
  padding: clamp(56px, 8vw, 112px) var(--gutter) clamp(48px, 6vw, 88px);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 420px), 1fr));
  gap: clamp(36px, 5vw, 72px);
  align-items: center;
}

.hero__copy {
  display: flex;
  flex-direction: column;
  gap: 28px;
  min-width: 0;
}

.eyebrow {
  font: 500 12px/1 var(--mono);
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--accent);
}

html[lang="ar"] .eyebrow {
  font: 500 14px/1 var(--sans-arabic);
  letter-spacing: normal;
  text-transform: none;
}

.hero h1 {
  margin: 0;
  font-weight: 500;
  font-size: clamp(38px, 4.6vw, 66px);
  line-height: 1.04;
  letter-spacing: -0.025em;
  text-wrap: pretty;
}

html[lang="ar"] .hero h1 {
  font-weight: 600;
  font-size: clamp(36px, 4.2vw, 60px);
  line-height: 1.3;
  letter-spacing: normal;
}

.hero__lede {
  margin: 0;
  max-width: 56ch;
  font-size: clamp(16px, 1.3vw, 19px);
  line-height: 1.55;
  color: var(--fg-muted);
  text-wrap: pretty;
}

html[lang="ar"] .hero__lede {
  line-height: 1.85;
}

.hero__by {
  margin: 0;
  font-size: 15px;
  line-height: 1.5;
  color: var(--fg);
}

html[lang="ar"] .hero__by {
  line-height: 1.8;
}

.hero__by strong {
  font-weight: 600;
}

.hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.hero__facts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 20px;
  border-top: 1px solid var(--line-2);
  padding-top: 22px;
  font-size: 13px;
  line-height: 1.5;
  color: var(--fg-dim);
}

html[lang="ar"] .hero__facts {
  font-size: 14px;
  line-height: 1.75;
}

.hero__facts strong {
  display: block;
  color: var(--fg);
  font-weight: 500;
}

html[lang="ar"] .hero__facts strong {
  font-weight: 600;
}

/* ------------------------------------------------------ telemetry panel -- */

.panel {
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding: 22px;
  background: var(--bg-raised);
  border: 1px solid var(--line-2);
  border-radius: var(--radius);
  box-shadow: 0 30px 80px -40px rgba(0, 0, 0, 0.8);
}

.panel__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

.panel__id {
  font: 500 11px/1 var(--mono);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--fg-dim);
}

html[lang="ar"] .panel__id {
  font: 500 12px/1 var(--sans-arabic);
  letter-spacing: normal;
  text-transform: none;
}

.panel__clock {
  display: flex;
  align-items: center;
  gap: 6px;
  font: 400 11px/1 var(--mono);
  color: var(--accent);
}

.panel__clock::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--accent);
}

.panel__body {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr));
  gap: 20px;
}

.score {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.score__label {
  font-size: 13px;
  line-height: 1.3;
  color: var(--fg-dim);
}

html[lang="ar"] .score__label {
  line-height: 1.5;
}

.score__value {
  direction: ltr;
  display: flex;
  align-items: baseline;
  gap: 6px;
}

.score__num {
  font: 500 64px/1 var(--sans-latin);
  letter-spacing: -0.03em;
  font-variant-numeric: tabular-nums;
}

.score__den {
  font: 400 16px/1 var(--mono);
  color: var(--fg-faint);
}

.subscores {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 8px 12px;
  margin: 0;
  font: 400 12px/1.2 var(--mono);
  color: var(--fg-dim);
}

html[lang="ar"] .subscores {
  font-family: var(--sans-arabic);
}

.subscores dt {
  margin: 0;
}

.subscores dd {
  margin: 0;
}

.subscores__bar {
  direction: ltr;
  display: block;
  height: 3px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.08);
  overflow: hidden;
}

.subscores__bar span {
  display: block;
  height: 100%;
  background: var(--accent);
}

.subscores__val {
  color: var(--fg);
  font-variant-numeric: tabular-nums;
}

/* ------------------------------------------------------------ speed trace */

.chart {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 0;
}

.chart__head {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  font: 400 12px/1.3 var(--mono);
  color: var(--fg-dim);
}

html[lang="ar"] .chart__head {
  font-family: var(--sans-arabic);
  font-size: 13px;
}

.chart__legend {
  display: flex;
  gap: 12px;
}

.chart__legend span {
  display: flex;
  align-items: center;
  gap: 5px;
}

.swatch-solid {
  width: 12px;
  height: 2px;
  background: var(--accent);
}

.swatch-dashed {
  width: 12px;
  border-top: 1px dashed var(--fg-dim);
}

.chart__axis {
  direction: ltr;
  display: flex;
  justify-content: space-between;
  font: 400 10px/1 var(--mono);
  color: var(--fg-faint);
}

.trace {
  display: block;
  overflow: visible;
}

@keyframes vg-draw {
  to {
    stroke-dashoffset: 0;
  }
}

@keyframes vg-fade {
  to {
    opacity: 1;
  }
}

/* 560 is the measured length of the speed polyline, rounded up. */
.trace__speed {
  stroke-dasharray: 560;
  stroke-dashoffset: 560;
  animation: vg-draw 2.4s cubic-bezier(0.4, 0, 0.2, 1) 0.2s forwards;
}

.trace__limit,
.trace__area,
.trace__event {
  opacity: 0;
  animation: vg-fade 0.6s ease-out forwards;
}

.trace__limit {
  animation-delay: 0.1s;
}

.trace__area {
  animation-delay: 1.8s;
}

.trace__event {
  animation-delay: 2.3s;
}

.events {
  display: flex;
  flex-direction: column;
  gap: 8px;
  border-top: 1px solid var(--line);
  padding-top: 12px;
  margin: 0;
  list-style: none;
  font: 400 12px/1.4 var(--mono);
}

html[lang="ar"] .events {
  font-family: var(--sans-arabic);
  font-size: 13px;
}

/* The panel column is narrow at desktop width; wrapping keeps the timestamp
   and the clip link on a clean second line instead of breaking mid-label. */
.event {
  display: flex;
  align-items: baseline;
  flex-wrap: wrap;
  gap: 4px 10px;
}

.event__dot {
  color: var(--fg-dim);
}

.event--alert .event__dot {
  color: var(--warn);
}

.event__name {
  color: var(--fg);
}

.event__meta {
  color: var(--fg-faint);
}

.event__tail {
  margin-inline-start: auto;
  color: var(--fg-faint);
}

.event--alert .event__tail {
  color: var(--accent);
}

/* ------------------------------------------------------------- sections -- */

.section {
  border-top: 1px solid var(--line);
}

.section--alt {
  background: var(--bg-alt);
}

.section__inner {
  max-width: var(--shell);
  margin-inline: auto;
  padding: var(--section-y) var(--gutter);
  display: flex;
  flex-direction: column;
  gap: var(--section-gap);
}

.section__head {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 380px), 1fr));
  gap: 32px 64px;
  align-items: end;
}

.section__title {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.section h2 {
  margin: 0;
  font-weight: 500;
  font-size: clamp(32px, 3.6vw, 52px);
  line-height: 1.08;
  letter-spacing: -0.02em;
  text-wrap: pretty;
}

html[lang="ar"] .section h2 {
  font-weight: 600;
  font-size: clamp(30px, 3.4vw, 48px);
  line-height: 1.35;
  letter-spacing: normal;
}

.section__intro {
  margin: 0;
  max-width: 52ch;
  font-size: 17px;
  line-height: 1.6;
  color: var(--fg-muted);
  text-wrap: pretty;
}

html[lang="ar"] .section__intro {
  line-height: 1.9;
}

.label {
  font: 500 12px/1.6 var(--mono);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--fg-dim);
}

html[lang="ar"] .label {
  font: 500 13px/1.8 var(--sans-arabic);
  letter-spacing: normal;
  text-transform: none;
}

/* -------------------------------------------------------------- product -- */

.product {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 340px), 1fr));
  gap: 48px 64px;
  align-items: start;
}

.unit {
  display: flex;
  flex-direction: column;
}

.unit > .label {
  padding-bottom: 16px;
}

.unit__card {
  background: var(--bg-raised);
  border: 1px solid var(--line-3);
  border-radius: var(--radius);
  overflow: hidden;
}

.unit__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
  padding: 18px 20px;
  border-bottom: 1px solid var(--line-2);
}

.unit__title {
  margin: 0;
  font-weight: 500;
  font-size: 14px;
  line-height: 1;
}

html[lang="ar"] .unit__title {
  font-weight: 600;
}

.unit__note {
  font: 400 11px/1 var(--mono);
  color: var(--accent);
}

html[lang="ar"] .unit__note {
  font: 400 12px/1 var(--sans-arabic);
}

.unit__rows {
  display: grid;
  grid-template-columns: auto 1fr;
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
}

html[lang="ar"] .unit__rows {
  line-height: 1.8;
}

.unit__rows dt {
  direction: ltr;
  padding-block: 14px;
  padding-inline: 20px;
  border-bottom: 1px solid var(--hairline);
  font: 400 11px/1.5 var(--mono);
  color: var(--fg-faint);
}

.unit__rows dd {
  margin: 0;
  padding-block: 14px;
  padding-inline: 0 20px;
  border-bottom: 1px solid var(--hairline);
}

.unit__rows dt:last-of-type,
.unit__rows dd:last-of-type {
  border-bottom: none;
}

.unit__rows b {
  font-weight: inherit;
  color: var(--fg);
}

.unit__rows span {
  color: var(--fg-dim);
}

.unit__foot {
  padding-top: 16px;
  margin: 0;
  font-size: 13px;
  line-height: 1.55;
  color: var(--fg-dim);
  text-wrap: pretty;
}

html[lang="ar"] .unit__foot {
  font-size: 14px;
  line-height: 1.8;
}

.capabilities {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 240px), 1fr));
  gap: 28px 32px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.capability {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.capability__num {
  font: 500 12px/1 var(--mono);
  color: var(--accent);
}

.capability h3 {
  margin: 0;
  font-weight: 500;
  font-size: 20px;
  line-height: 1.3;
}

html[lang="ar"] .capability h3 {
  font-weight: 600;
  line-height: 1.5;
}

.capability p {
  margin: 0;
  font-size: 15px;
  line-height: 1.55;
  color: var(--fg-dim);
  text-wrap: pretty;
}

html[lang="ar"] .capability p {
  line-height: 1.85;
}

.capability__out {
  font: 400 12px/1.5 var(--mono);
  color: var(--fg-faint);
}

html[lang="ar"] .capability__out {
  font: 400 13px/1.7 var(--sans-arabic);
}

.built-for {
  display: grid;
  grid-template-columns: 1fr;
  gap: 20px 32px;
  align-items: baseline;
  border-top: 1px solid var(--line-2);
  padding-top: 24px;
}

@media (min-width: 760px) {
  .built-for {
    grid-template-columns: minmax(180px, 220px) 1fr;
  }
}

.built-for__list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px 28px;
  margin: 0;
  padding: 0;
  list-style: none;
  font-size: 15px;
  line-height: 1.5;
  color: var(--fg);
}

html[lang="ar"] .built-for__list {
  line-height: 1.8;
}

/* -------------------------------------------------------------- privacy -- */

.commitments {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  gap: 1px;
  margin: 0;
  padding: 0;
  list-style: none;
  background: var(--line);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.commitment {
  display: flex;
  flex-direction: column;
  gap: 14px;
  padding: 28px 26px;
  background: var(--bg-alt);
  transition: background 0.15s;
}

.commitment:hover {
  background: var(--bg-hover);
}

.commitment__num {
  font: 500 13px/1 var(--mono);
  color: var(--accent);
}

.commitment h3 {
  margin: 0;
  font-weight: 500;
  font-size: 20px;
  line-height: 1.3;
  text-wrap: pretty;
}

html[lang="ar"] .commitment h3 {
  font-weight: 600;
  line-height: 1.5;
}

.commitment p {
  margin: 0;
  font-size: 15px;
  line-height: 1.55;
  color: var(--fg-dim);
  text-wrap: pretty;
}

html[lang="ar"] .commitment p {
  line-height: 1.85;
}

.retention {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 380px), 1fr));
  gap: 32px 64px;
  align-items: start;
}

.retention__figure {
  display: flex;
  flex-direction: column;
  gap: 12px;
  margin: 0;
}

.retention__bar,
.retention__key {
  direction: ltr;
  display: grid;
  grid-template-columns: 3fr 1fr 2fr 3fr;
  gap: 3px;
}

.retention__bar {
  height: 34px;
}

.retention__bar i {
  background: var(--wash);
}

.retention__bar i:first-child {
  border-radius: 4px 0 0 4px;
}

.retention__bar i:nth-child(2) {
  background: var(--accent-35);
  border-radius: 2px;
}

.retention__bar i:nth-child(3) {
  background: var(--accent);
  border-radius: 2px;
}

.retention__bar i:last-child {
  border-radius: 0 4px 4px 0;
}

.retention__key {
  font: 400 11px/1.4 var(--mono);
  color: var(--fg-dim);
}

html[lang="ar"] .retention__key {
  font: 400 12px/1.6 var(--sans-arabic);
}

html[lang="ar"] .retention__key > span {
  direction: rtl;
}

.retention__key > span:nth-child(2) {
  color: var(--accent);
}

.retention__key > span:nth-child(3) {
  color: var(--fg);
}

.pullquote {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin: 0;
  border-inline-start: 2px solid var(--accent);
  padding-inline-start: 20px;
}

.pullquote__lead {
  font-weight: 500;
  font-size: 18px;
  line-height: 1.35;
  text-wrap: pretty;
}

html[lang="ar"] .pullquote__lead {
  font-weight: 600;
  line-height: 1.6;
}

.pullquote p {
  margin: 0;
  font-size: 15px;
  line-height: 1.55;
  color: var(--fg-dim);
  text-wrap: pretty;
}

html[lang="ar"] .pullquote p {
  line-height: 1.85;
}

/* -------------------------------------------------------------- roadmap -- */

.timeline {
  display: flex;
  flex-direction: column;
}

.timeline__scale,
.timeline__track {
  direction: ltr;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
}

.timeline__scale {
  padding-bottom: 10px;
  font: 400 11px/1 var(--mono);
  color: var(--fg-faint);
}

html[lang="ar"] .timeline__scale {
  font: 400 12px/1 var(--sans-arabic);
}

.timeline__scale > span:last-child {
  display: flex;
  justify-content: space-between;
}

.timeline__track {
  gap: 4px;
  height: 4px;
}

.timeline__track i {
  border-radius: 2px;
}

.timeline__track i:nth-child(1) {
  background: var(--accent);
}

.timeline__track i:nth-child(2) {
  background: var(--accent-55);
}

.timeline__track i:nth-child(3) {
  background: var(--accent-25);
}

/* The Arabic list stays LTR so the phases still read oldest-to-newest;
   each item flips back to RTL for its own copy. */
.phases {
  direction: ltr;
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 300px), 1fr));
  gap: 36px;
  margin: 0;
  padding: 28px 0 0;
  list-style: none;
}

.phase {
  display: flex;
  flex-direction: column;
  gap: 16px;
  min-width: 0;
}

html[lang="ar"] .phase {
  direction: rtl;
}

.phase__meta {
  display: flex;
  align-items: baseline;
  gap: 12px;
}

.phase__num {
  font: 500 13px/1 var(--mono);
  color: var(--accent);
}

.phase__when {
  font: 400 12px/1 var(--mono);
  color: var(--fg-faint);
}

html[lang="ar"] .phase__when {
  font: 400 13px/1 var(--sans-arabic);
}

.phase h3 {
  margin: 0;
  font-weight: 500;
  font-size: 24px;
  line-height: 1.25;
  letter-spacing: -0.01em;
  text-wrap: pretty;
}

html[lang="ar"] .phase h3 {
  font-weight: 600;
  font-size: 23px;
  line-height: 1.5;
  letter-spacing: normal;
}

.phase p {
  margin: 0;
  font-size: 15px;
  line-height: 1.55;
  color: var(--fg-muted);
  text-wrap: pretty;
}

html[lang="ar"] .phase p {
  line-height: 1.85;
}

.phase__why {
  border-top: 1px solid var(--line-2);
  padding-top: 12px;
  font: 400 12px/1.5 var(--mono);
  color: var(--fg-dim);
}

html[lang="ar"] .phase__why {
  font: 400 13px/1.8 var(--sans-arabic);
}

.phase__why b {
  font-weight: inherit;
  color: var(--accent);
}

.beyond {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 380px), 1fr));
  gap: 24px 64px;
  border-top: 1px solid var(--line-2);
  padding-top: 28px;
}

.beyond p {
  margin: 0;
  font-size: 17px;
  line-height: 1.55;
  color: var(--fg);
  text-wrap: pretty;
}

html[lang="ar"] .beyond p {
  line-height: 1.9;
}

/* ------------------------------------------------------------- founders -- */

/* Explicit columns rather than auto-fit + span: with three cards the card
   track needs roughly two and a half times the intro, and a span that
   outgrows an auto-fit track creates an implicit column that overflows. */
.founders {
  max-width: var(--shell);
  margin-inline: auto;
  padding: var(--section-y) var(--gutter);
  display: grid;
  grid-template-columns: 1fr;
  gap: clamp(36px, 5vw, 64px);
  align-items: start;
}

@media (min-width: 1000px) {
  .founders {
    grid-template-columns: minmax(280px, 1fr) 2.6fr;
  }
}

.founders__intro {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.founders__intro p {
  margin: 0;
  max-width: 40ch;
  font-size: 16px;
  line-height: 1.6;
  color: var(--fg-muted);
  text-wrap: pretty;
}

html[lang="ar"] .founders__intro p {
  line-height: 1.9;
}

.founders__cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
  gap: 24px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.founder {
  display: flex;
  flex-direction: column;
  gap: 18px;
  padding: 20px;
  background: var(--bg-raised);
  border: 1px solid var(--line-2);
  border-radius: var(--radius);
}

.founder__head {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.founder__name {
  font-weight: 500;
  font-size: 20px;
  line-height: 1.25;
}

html[lang="ar"] .founder__name {
  font-weight: 600;
  line-height: 1.4;
}

.founder__role {
  font: 400 12px/1.5 var(--mono);
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--accent);
}

html[lang="ar"] .founder__role {
  font: 500 13px/1.6 var(--sans-arabic);
  letter-spacing: normal;
  text-transform: none;
}

/* margin-block-start:auto keeps the address rules aligned when one name
   wraps to two lines and the other does not. */
.founder__mail {
  direction: ltr;
  margin-block-start: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  border-top: 1px solid var(--line-2);
  padding-top: 14px;
  font: 400 13px/1.4 var(--mono);
  color: var(--fg-muted);
  text-decoration: none;
  transition: color 0.15s;
}

.founder__mail:hover,
.founder__mail:focus-visible {
  color: var(--accent);
}

/* Wrap at the <wbr> before the @ rather than truncating: the address is
   the point of the card. */
.founder__mail span:first-child {
  min-width: 0;
  overflow-wrap: break-word;
}

/* -------------------------------------------------------------- contact -- */

.contact {
  max-width: var(--shell);
  margin-inline: auto;
  padding: var(--section-y) var(--gutter);
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 380px), 1fr));
  gap: clamp(36px, 5vw, 72px);
  align-items: start;
}

.contact__intro {
  display: flex;
  flex-direction: column;
  gap: 18px;
}

.contact__intro p {
  margin: 0;
  max-width: 44ch;
  font-size: 16px;
  line-height: 1.6;
  color: var(--fg-muted);
  text-wrap: pretty;
}

html[lang="ar"] .contact__intro p {
  line-height: 1.9;
}

.contact__where {
  font: 400 13px/1.6 var(--mono);
  color: var(--fg-dim);
}

html[lang="ar"] .contact__where {
  font: 400 14px/1.8 var(--sans-arabic);
}

.form {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 220px), 1fr));
  gap: 16px;
  padding: 24px;
  background: var(--bg-raised);
  border: 1px solid var(--line-2);
  border-radius: var(--radius);
}

.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
  font: 400 12px/1 var(--mono);
  color: var(--fg-dim);
}

html[lang="ar"] .field {
  font: 400 13px/1 var(--sans-arabic);
}

.field--wide {
  grid-column: 1 / -1;
}

.form input,
.form select,
.form textarea {
  padding: 12px;
  background: var(--bg);
  border: 1px solid var(--line-field);
  border-radius: var(--radius-sm);
  color: var(--fg);
  font-family: var(--sans);
  font-size: 15px;
  line-height: 1.2;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}

html[lang="ar"] .form input,
html[lang="ar"] .form select,
html[lang="ar"] .form textarea {
  line-height: 1.4;
}

.form input[type="email"] {
  direction: ltr;
  font-family: var(--sans-latin);
}

.form textarea {
  line-height: 1.4;
  resize: vertical;
}

.form :is(input, select, textarea):focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(98, 227, 211, 0.18);
}

.form__foot {
  grid-column: 1 / -1;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 16px;
}

.form__error {
  margin-inline-end: auto;
  font: 400 12px/1.5 var(--mono);
  color: var(--warn);
}

html[lang="ar"] .form__error {
  font: 400 13px/1.7 var(--sans-arabic);
}

.sent {
  display: flex;
  flex-direction: column;
  gap: 12px;
  padding: 32px 24px;
  background: var(--bg-raised);
  border: 1px solid rgba(98, 227, 211, 0.4);
  border-radius: var(--radius);
}

.contact .sent {
  display: none;
}

.contact.is-sent .form {
  display: none;
}

.contact.is-sent .sent {
  display: flex;
}

.sent__tag {
  font: 500 13px/1 var(--mono);
  color: var(--accent);
}

html[lang="ar"] .sent__tag {
  font: 500 13px/1 var(--sans-arabic);
}

.sent__head {
  font-weight: 500;
  font-size: 22px;
  line-height: 1.3;
}

html[lang="ar"] .sent__head {
  font-weight: 600;
  line-height: 1.5;
}

.sent p {
  margin: 0;
  font-size: 15px;
  line-height: 1.55;
  color: var(--fg-dim);
}

html[lang="ar"] .sent p {
  line-height: 1.85;
}

.btn--quiet {
  align-self: flex-start;
  margin-top: 8px;
  background: none;
  border-color: var(--line-4);
  color: var(--fg-muted);
  font: 400 13px/1 var(--mono);
  padding: 10px 14px;
}

html[lang="ar"] .btn--quiet {
  font: 400 13px/1 var(--sans-arabic);
}

.btn--quiet:hover,
.btn--quiet:focus-visible {
  border-color: var(--accent);
  color: var(--accent);
}

/* --------------------------------------------------------------- footer -- */

.site-footer {
  border-top: 1px solid var(--line);
}

.site-footer .shell {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 20px 40px;
  padding-block: 36px;
  font-size: 13px;
  color: var(--fg-dim);
}

.site-footer__brand {
  display: flex;
  align-items: center;
  gap: 12px;
}

.site-footer__mark {
  direction: ltr;
  font: 600 14px/1 var(--sans-latin);
  letter-spacing: 0.2em;
  color: var(--fg);
}

.site-footer__brand b {
  font-weight: inherit;
  color: var(--fg);
}

.site-footer__links {
  display: flex;
  flex-wrap: wrap;
  gap: 22px;
}

.site-footer__links a {
  color: var(--fg-dim);
  text-decoration: none;
  transition: color 0.15s;
}

.site-footer__links a:hover,
.site-footer__links a:focus-visible {
  color: #fff;
}

/* ------------------------------------------------------ reduced motion -- */

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .trace__speed {
    stroke-dasharray: none;
    stroke-dashoffset: 0;
  }

  .trace__speed,
  .trace__limit,
  .trace__area,
  .trace__event {
    opacity: 1;
    animation: none;
  }

  *,
  *::before,
  *::after {
    transition-duration: 0.01ms !important;
  }
}
