/* ============================================================
   Vootlabs: homepage only (loaded after site.css on / and /ar/).
   Reuses the site.css tokens: --bg --surface --ink --ink-2 --ink-3 --line
   --dark --on-dark --accent --accent-dot --font. Dark sections re-point
   the ink/line tokens, so components below flip without dark variants.
   One typeface: every label here is Switzer (IBM Plex Sans Arabic on /ar/)
   in sentence case. No mono, no uppercase, no letter-spaced kickers.
   ============================================================ */

:root {
  --risk: #B3361E;                 /* warning marks only; 6.3:1 on white */
  --risk-soft: rgba(179,54,30,0.06);
  --narrow: 1040px;
}

/* ---------- helpers ---------- */
[hidden] { display: none !important; }
.sprite { position: absolute; width: 0; height: 0; overflow: hidden; }
svg.ico { width: 20px; height: 20px; flex: none; fill: none; stroke: currentColor; stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.textlink svg.ico { width: 16px; height: 16px; }
section[id] { scroll-margin-top: 64px; }
.section--white { background: var(--surface); }
.mobile-menu { overflow-y: auto; }
.form-err { color: #c0392b; font-size: 13px; }

/* ---------- section heads: centred, plain sans, two tones (heading, then a soft grey line) ---------- */
.section-head { max-width: 780px; margin: 0 auto 60px; text-align: center; }
.section-head h2 {
  font-size: clamp(28px, 3.5vw, 44px); font-weight: 500;
  letter-spacing: -0.032em; line-height: 1.12; text-wrap: balance;
}
.section-head p {
  max-width: 500px; margin: 16px auto 0;
  font-size: clamp(17px, 1.4vw, 19px); line-height: 1.5; color: var(--ink-3); text-wrap: balance;
}
.section-head p span { display: block; }
@media (max-width: 700px) { .section-head { margin-bottom: 40px; } }

.footnote { margin-top: 22px; text-align: center; font-size: 13.5px; color: var(--ink-3); }

/* ============================================================
   1. Hero
   ============================================================ */
.hero.section--dark { padding: 150px 0 112px; overflow: hidden; isolation: isolate; }
.hero.section--dark::before {
  content: ''; position: absolute; inset: 0; z-index: -1; pointer-events: none;
  background:
    radial-gradient(44% 56% at 78% 46%, rgba(47,179,107,0.17), transparent 72%),
    radial-gradient(rgba(243,242,238,0.085) 1px, transparent 1.3px) 0 0 / 26px 26px;
  -webkit-mask-image: radial-gradient(85% 95% at 68% 42%, #000 28%, transparent 86%);
          mask-image: radial-gradient(85% 95% at 68% 42%, #000 28%, transparent 86%);
}
.hero-grid { grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: clamp(36px, 5vw, 80px); }
.hero h1 {
  font-size: clamp(36px, 4.7vw, 64px); line-height: 1.04; letter-spacing: -0.045em;
  text-wrap: balance;
}
.hero-actions { margin-top: 40px; }

/* chat card (light card on the dark hero) */
.hero-visual { position: relative; width: 100%; max-width: 540px; margin-inline-start: auto; }
.chat {
  --ink: #141412; --ink-2: #55534B; --ink-3: #6B695F;
  --line: rgba(20,20,18,0.12); --line-2: rgba(20,20,18,0.07);
  background: #F6F5F1; color: var(--ink); border-radius: 22px; overflow: hidden;
  box-shadow: 0 0 0 1px rgba(243,242,238,0.1), 0 44px 90px -30px rgba(0,0,0,0.75), 0 0 140px -30px rgba(47,179,107,0.28);
}
.chat-bar {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  padding: 15px 22px; background: #fff; border-bottom: 1px solid var(--line);
}
.chat-status { display: inline-flex; align-items: center; gap: 10px; font-size: 14px; font-weight: 500; color: var(--ink); }
/* The pulse ring is a scaled, fading copy of the dot (transform + opacity run on the compositor).
   It used to animate box-shadow, which repainted this part of the hero, and the big card shadows around it, every frame. */
.chat-dot { position: relative; width: 8px; height: 8px; border-radius: 50%; background: var(--accent-dot); }
.chat-dot::before {
  content: ''; position: absolute; inset: 0; border-radius: 50%; background: var(--accent-dot);
  opacity: 0; animation: dotPulse 2.4s ease-out infinite;
}
@keyframes dotPulse {
  0%   { transform: scale(1);   opacity: 0.45; }
  70%  { transform: scale(2.5); opacity: 0; }
  100% { transform: scale(2.5); opacity: 0; }
}
.tag-illus {
  padding: 3px 10px; border-radius: 999px; background: #F1F0EB; white-space: nowrap;
  font-size: 12px; font-weight: 500; color: var(--ink-3);
}
.chat-body { display: flex; flex-direction: column; gap: 18px; padding: 22px; }
.chat-msg { display: flex; flex-direction: column; min-width: 0; }
.chat-msg--user { align-items: flex-end; }
.chat-bubble {
  max-width: 90%; padding: 12px 18px; border-radius: 18px; border-end-end-radius: 5px;
  background: #141412; color: #F3F2EE; font-size: 15px; line-height: 1.5; text-wrap: balance;
}
.answer { background: #fff; border: 1px solid var(--line); border-radius: 16px; padding: 18px 20px 16px; }
.answer-title { margin-bottom: 8px; font-size: 15px; font-weight: 500; letter-spacing: -0.01em; color: var(--ink); }
.answer-table { width: 100%; border-collapse: collapse; font-size: 14px; }
.answer-table th {
  padding: 6px 12px 8px 0; text-align: start; font-size: 12.5px; font-weight: 500; color: var(--ink-3);
  border-bottom: 1px solid var(--line);
}
.answer-table td { padding: 11px 12px 11px 0; border-bottom: 1px solid var(--line-2); color: var(--ink); line-height: 1.35; }
.answer-table tbody tr:last-child td { border-bottom: 0; }
.answer-table .num { text-align: end; padding-inline: 0; font-variant-numeric: tabular-nums; }
.answer-table td.num { font-weight: 500; }
.answer-sources { margin-top: 4px; padding-top: 13px; border-top: 1px solid var(--line); font-size: 13px; line-height: 1.4; color: var(--ink-3); }
.answer-label { color: var(--ink-2); font-weight: 500; }
.chat-sched {
  position: absolute; inset-inline-start: -34px; bottom: -26px; z-index: 2;
  display: inline-flex; align-items: center; gap: 9px; padding: 11px 18px;
  background: #fff; color: #141412; border-radius: 999px;
  font-size: 14px; font-weight: 500; letter-spacing: -0.005em;
  box-shadow: 0 22px 44px -14px rgba(0,0,0,0.7), 0 0 0 1px rgba(20,20,18,0.06);
  animation: chipFloat 6s ease-in-out infinite;
}
.chat-sched svg.ico { width: 17px; height: 17px; color: var(--accent); }
@keyframes chipFloat { 0%, 100% { transform: translateY(0); } 50% { transform: translateY(-7px); } }

@media (max-width: 920px) {
  .hero.section--dark { padding: 128px 0 80px; }
  .hero-grid { grid-template-columns: minmax(0, 1fr); gap: 52px; }
  .hero-visual { margin-inline: 0; max-width: 560px; }
  .chat-sched { position: static; display: flex; width: fit-content; margin-top: 14px; animation: none; }
}
@media (max-width: 560px) {
  .chat-bar { padding: 13px 18px; }
  .chat-body { padding: 16px; }
  .answer { padding: 16px 16px 14px; }
  .answer-table { font-size: 13.5px; }
  .answer-table th, .answer-table td { padding-inline-end: 8px; }
  .answer-table th { white-space: nowrap; }
}

/* ============================================================
   2. Product: the flow graph
   Geometry is fixed on desktop so the SVG connectors line up with the
   cards without JS: 5 rows of 84px with 14px gaps fill 476px on both sides,
   so card centres sit at 42 / 140 / 238 / 336 / 434 and the connector SVGs
   are drawn 1:1 in pixels. The 5 lines on each side meet the panel edge at
   184 / 211 / 238 / 265 / 292.
   ============================================================ */
.flow { --flow-h: 476px; --conn-w: 64px; }
.flow-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) var(--conn-w) minmax(300px, 380px) var(--conn-w) minmax(0, 1fr);
  grid-template-rows: auto var(--flow-h);
  align-items: start;
}
.flow-label { grid-row: 1; margin: 0 0 20px; text-align: center; line-height: 1; font-size: 14.5px; font-weight: 500; color: var(--ink-3); }
.flow-label--src { grid-column: 1; }
.flow-label--out { grid-column: 5; }
.flow-sources, .flow-consumers { list-style: none; display: grid; gap: 14px; height: var(--flow-h); min-width: 0; grid-template-rows: repeat(5, minmax(0, 1fr)); }
.flow-sources   { grid-row: 2; grid-column: 1; }
.flow-consumers { grid-row: 2; grid-column: 5; }
.flow-link--in  { grid-row: 2; grid-column: 2; }
.flow-panel     { grid-row: 2; grid-column: 3; }
.flow-link--out { grid-row: 2; grid-column: 4; }

/* cards */
.flow-card {
  display: flex; flex-direction: column; justify-content: center; gap: 8px; min-width: 0;
  padding: 12px 20px; background: var(--surface);
  border: 1px solid var(--line); border-radius: 14px;
  box-shadow: 0 1px 0 rgba(20,20,18,0.03), 0 10px 26px -18px rgba(20,20,18,0.3);
}
.flow-cat { display: flex; align-items: center; gap: 8px; line-height: 1.2; font-size: 13.5px; font-weight: 500; color: var(--ink-3); }
.flow-cat svg.ico { width: 18px; height: 18px; color: var(--ink-2); }
.flow-name { font-size: clamp(15px, 1.25vw, 16.5px); font-weight: 500; letter-spacing: -0.012em; line-height: 1.3; color: var(--ink); }
.flow-card--out { flex-direction: row; align-items: center; justify-content: flex-start; gap: 14px; }
.flow-ic { width: 40px; height: 40px; flex: none; border-radius: 11px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); }
.flow-card--out .flow-name { font-size: clamp(16px, 1.35vw, 17.5px); }
/* a list of systems (some names are long) wraps into even lines instead of leaving one word alone */
.flow-sources .flow-name { text-wrap: balance; }

/* connectors */
/* will-change: the animated dashes and packets get their own small layer, so each frame repaints only
   the 64px connector strip instead of the cards and shadows beside it. */
.flow-link { position: relative; z-index: 2; height: var(--flow-h); will-change: transform; }
.flow-h { position: absolute; top: 0; left: 0; width: var(--conn-w); height: var(--flow-h); overflow: visible; }
.flow-v { display: none; }
.flow-line {
  fill: none; stroke-width: 1.5; stroke-linecap: round; stroke-dasharray: 2 6;
  vector-effect: non-scaling-stroke; animation: flow 1s linear infinite;
}
.flow-link--in .flow-line { stroke: var(--ink-3); }
.flow-link--out .flow-line { stroke: var(--accent); }
@keyframes flow { to { stroke-dashoffset: -8; } }
.flow-node { fill: var(--bg); stroke: var(--ink-3); stroke-width: 1.5; vector-effect: non-scaling-stroke; }
.flow-node--on { fill: var(--accent-dot); stroke: var(--bg); }

/* glowing packets travel panel -> AI (right side only); paths repeat three of the connector paths above */
.flow-packet {
  position: absolute; left: 0; top: 0; width: 8px; height: 8px; border-radius: 50%;
  background: var(--accent-dot); opacity: 0; pointer-events: none;
  box-shadow: 0 0 0 3px rgba(47,179,107,0.2), 0 0 12px 2px rgba(47,179,107,0.6);
  offset-rotate: 0deg; animation: packet 3.4s linear infinite;
}
.flow-packet--1 { offset-path: path('M0 184H12A8 8 0 0 0 20 176V50A8 8 0 0 1 28 42H64'); animation-duration: 3.2s; }
.flow-packet--2 { offset-path: path('M0 265H28A8 8 0 0 1 36 273V328A8 8 0 0 0 44 336H64'); animation-duration: 2.6s; animation-delay: -1.1s; }
.flow-packet--3 { offset-path: path('M0 292H12A8 8 0 0 1 20 300V426A8 8 0 0 0 28 434H64'); animation-duration: 3.8s; animation-delay: -2.2s; }
@keyframes packet {
  0%   { offset-distance: 0%; opacity: 0; }
  12%  { opacity: 1; }
  88%  { opacity: 1; }
  100% { offset-distance: 100%; opacity: 0; }
}
/* home.js adds .is-paused to .hero-visual, .flow and .sec-stage while they are off screen */
.is-paused *, .is-paused *::before, .is-paused *::after { animation-play-state: paused !important; }

/* the dark Vootlabs panel */
.flow-panel {
  position: relative; height: var(--flow-h); padding: 74px 18px 18px;
  border-radius: 24px; color: var(--on-dark);
  background: linear-gradient(180deg, #1B1A17 0%, #121210 55%);
  box-shadow: 0 0 0 1px rgba(20,20,18,0.5), 0 40px 70px -34px rgba(20,20,18,0.55);
}
.flow-tab {
  position: absolute; top: 0; left: 50%; transform: translateX(-50%);
  display: flex; align-items: center; gap: 10px; padding: 11px 24px 13px;
  background: var(--bg); color: var(--ink); border-radius: 0 0 18px 18px;
  font-size: 20px; font-weight: 600; letter-spacing: -0.03em; line-height: 1;
}
.flow-tab .brand-mark { width: 24px; height: 24px; }
.flow-layers { list-style: none; display: flex; flex-direction: column; gap: 12px; height: 100%; }
.flow-layer {
  position: relative; flex: 1; min-height: 0;
  display: grid; grid-template-columns: 34px minmax(0, 1fr); column-gap: 16px; align-items: center;
  padding: 14px 18px; border-radius: 14px;
  background: rgba(243,242,238,0.055); border: 1px solid rgba(243,242,238,0.1);
}
.flow-layer:not(:last-child)::after {
  content: ''; position: absolute; inset-inline-start: 35px; bottom: -13px; width: 0; height: 12px;
  border-inline-start: 1.5px dotted rgba(47,179,107,0.7);
}
.flow-num {
  width: 34px; height: 34px; border-radius: 50%; display: grid; place-items: center;
  background: var(--accent-dot); color: #0A1F13; font-size: 15px; font-weight: 600;
  font-variant-numeric: tabular-nums;
}
.flow-layer h3 { font-size: 19px; font-weight: 500; letter-spacing: -0.02em; line-height: 1.25; color: var(--on-dark); }
.flow-layer p { margin-top: 4px; font-size: 14.5px; line-height: 1.4; color: var(--on-dark-2); }

@media (max-width: 1100px) {
  .flow-grid { grid-template-columns: minmax(0, 1fr) var(--conn-w) minmax(270px, 300px) var(--conn-w) minmax(0, 1fr); }
  .flow-panel { padding-inline: 14px; }
  .flow-layer { padding: 12px 14px; column-gap: 13px; grid-template-columns: 32px minmax(0, 1fr); }
  .flow-num { width: 32px; height: 32px; }
  .flow-layer:not(:last-child)::after { inset-inline-start: 31px; }
  .flow-card { padding: 8px 14px; gap: 6px; }
  .flow-name { font-size: 14.5px; }
  .flow-layer h3 { font-size: 17.5px; }
  .flow-layer p { font-size: 14px; }
}

/* narrowest three-column widths: the side cards are about 175px wide, so the system names get a touch smaller */
@media (min-width: 901px) and (max-width: 1000px) {
  .flow-sources .flow-name { font-size: 13.5px; }
  .flow-card { padding-inline: 12px; }
}

/* ---- stacked: sources -> connector -> panel -> connector -> AI ---- */
@media (max-width: 900px) {
  .flow-grid { display: flex; flex-direction: column; align-items: stretch; }
  .flow-label { margin-bottom: 14px; }
  .flow-label--out { margin-top: 10px; }
  .flow-sources, .flow-consumers { height: auto; grid-template-columns: repeat(2, minmax(0, 1fr)); grid-template-rows: none; gap: 10px; }
  .flow-sources .flow-card:last-child:nth-child(odd),
  .flow-consumers .flow-card:last-child:nth-child(odd) { grid-column: 1 / -1; }
  .flow-card { min-height: 84px; }
  .flow-card--out { min-height: 72px; }
  .flow-link { height: 60px; display: grid; place-items: center; }
  .flow-h, .flow-packet { display: none; }
  .flow-v { display: block; width: 8px; height: 56px; overflow: visible; }
  .flow-panel { height: auto; padding: 76px 14px 14px; }
  .flow-layers { height: auto; }
  .flow-layer { flex: none; padding: 16px 14px; }
}
@media (max-width: 420px) {
  .flow-card--out { gap: 11px; padding-inline: 12px; }
  .flow-ic { width: 36px; height: 36px; }
}

/* ============================================================
   3. Problem
   ============================================================ */
.problem-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; }
.problem-card { padding: 32px; border-radius: 20px; background: var(--bg); border: 1px solid var(--line); }
.problem-ico { display: block; margin-bottom: 40px; color: var(--ink); }
.problem-ico svg.ico { width: 28px; height: 28px; }
.problem-card h3 { font-size: 21px; font-weight: 500; letter-spacing: -0.025em; line-height: 1.25; margin-bottom: 10px; }
.problem-card p { font-size: 16.5px; line-height: 1.55; color: var(--ink-2); }
@media (max-width: 900px) { .problem-grid { grid-template-columns: 1fr; } .problem-ico { margin-bottom: 26px; } }

/* ============================================================
   4. Use cases (tabs)
   ============================================================ */
.uc { max-width: var(--narrow); margin-inline: auto; }
.uc-tabs { display: flex; flex-wrap: wrap; justify-content: center; gap: 8px; margin-bottom: 22px; }
.uc-tab, .sec-tab {
  min-height: 44px; padding: 10px 20px; border-radius: 999px;
  font-size: 15px; font-weight: 500; letter-spacing: -0.005em; color: var(--ink-2);
  transition: background .2s, color .2s, border-color .2s;
}
.uc-tab { border: 1px solid var(--line); }
.uc-tab:hover { color: var(--ink); border-color: var(--ink-2); }
.uc-tab[aria-selected="true"] { background: var(--ink); border-color: var(--ink); color: var(--bg); }
.uc-panel {
  display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 20px;
  padding: 24px; background: var(--surface); border: 1px solid var(--line); border-radius: 20px;
}
.uc-panel:not([hidden]), .sec-panel:not([hidden]) { animation: panelIn .35s cubic-bezier(.2,.7,.2,1); }
@keyframes panelIn { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.uc-h { display: flex; align-items: center; gap: 10px; margin-bottom: 14px; font-size: 15px; font-weight: 500; color: var(--ink-3); }
.uc-h svg.ico { width: 18px; height: 18px; color: var(--accent); }
.uc-qs { list-style: none; display: grid; gap: 12px; }
.uc-qs li {
  padding: 15px 18px; background: var(--bg); border: 1px solid var(--line);
  border-radius: 16px; border-end-start-radius: 5px; font-size: 16.5px; line-height: 1.45; letter-spacing: -0.005em;
}
.uc-side { display: flex; flex-direction: column; gap: 12px; }
.uc-card { flex: 1; padding: 20px 22px; background: var(--bg); border: 1px solid var(--line); border-radius: 14px; }
.uc-card p { font-size: 16.5px; line-height: 1.5; color: var(--ink); }
.uc-card--approve { border-color: rgba(15,122,67,0.34); background: linear-gradient(180deg, var(--accent-soft), var(--bg) 70%); }
@media (max-width: 900px) { .uc-panel { grid-template-columns: minmax(0, 1fr); padding: 18px; } }

/* ============================================================
   5. Security (toggle + control cards)
   ============================================================ */
.sec-stage { max-width: var(--narrow); margin: 0 auto 28px; text-align: center; }
.sec-toggle { display: inline-flex; gap: 4px; padding: 5px; background: var(--surface); border: 1px solid var(--line); border-radius: 999px; max-width: 100%; }
.sec-tab:hover { color: var(--ink); }
.sec-tab[aria-selected="true"] { background: var(--ink); color: var(--bg); }
#sec-tab-with[aria-selected="true"] { background: var(--accent); color: #fff; }
.sec-panel {
  margin-top: 18px; padding: 30px; border: 1px solid; border-radius: 20px; text-align: start;
  display: grid; grid-template-columns: minmax(0, 360px) minmax(0, 1fr); gap: clamp(24px, 4vw, 52px); align-items: center;
}
.sec-diagram { width: 100%; height: auto; overflow: visible; will-change: transform; }
.sd-node rect { fill: var(--surface); stroke: var(--line); stroke-width: 1; }
.sd-node text { font-family: var(--font); font-size: 13.5px; font-weight: 500; fill: var(--ink); letter-spacing: -0.005em; }
.sd-node--gate rect { fill: var(--accent); stroke: var(--accent); }
.sd-node--gate text { fill: #fff; }
.sd-zone { fill: rgba(15,122,67,0.06); stroke: var(--accent); stroke-width: 1.2; stroke-dasharray: 4 4; }
.sd-wire { fill: none; stroke-width: 1.5; stroke-linecap: round; stroke-dasharray: 2 6; animation: flow 1s linear infinite; }
.sec-panel--risk .sd-wire { stroke: var(--risk); }
.sec-panel--safe .sd-wire { stroke: var(--accent); }
.sec-panel--risk { background: var(--risk-soft); border-color: rgba(179,54,30,0.24); }
.sec-panel--safe { background: var(--accent-soft); border-color: rgba(15,122,67,0.3); }
.sec-tags { list-style: none; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.sec-tags li {
  display: flex; align-items: flex-start; gap: 12px; padding: 16px 18px;
  background: var(--surface); border: 1px solid var(--line); border-radius: 12px;
  font-size: 16.5px; line-height: 1.4;
}
.sec-tags svg.ico { width: 20px; height: 20px; margin-top: 1px; stroke-width: 2; }
.sec-panel--risk .sec-tags svg.ico { color: var(--risk); }
.sec-panel--safe .sec-tags svg.ico { color: var(--accent); }

.ctrl-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 20px; max-width: var(--narrow); margin-inline: auto; }
.ctrl-card { padding: 28px; background: var(--surface); border: 1px solid var(--line); border-radius: 18px; }
.ctrl-ico { width: 44px; height: 44px; margin-bottom: 20px; border-radius: 11px; display: grid; place-items: center; background: var(--accent-soft); color: var(--accent); }
.ctrl-card h3 { font-size: 19px; font-weight: 500; letter-spacing: -0.02em; line-height: 1.25; margin-bottom: 8px; }
.ctrl-card p { font-size: 16px; line-height: 1.5; color: var(--ink-2); }
@media (max-width: 900px) { .sec-panel { grid-template-columns: minmax(0, 1fr); } .sec-diagram { max-width: 380px; } }
@media (max-width: 800px) { .ctrl-grid { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 640px) {
  .sec-tags { grid-template-columns: minmax(0, 1fr); }
  .sec-panel { padding: 18px; }
  .sec-toggle { display: flex; }
  .sec-tab { flex: 1; padding-inline: 10px; }
}

/* ============================================================
   6. FAQ: centred heading, list below (white from site.css)
   ============================================================ */
#faq .wrap { display: block; }
#faq .section-head { position: static; margin: 0 auto 48px; }
#faq .section-head .btn { margin-top: 28px; }
#faq .faq-list { max-width: 820px; margin-inline: auto; }

/* ============================================================
   7. Design-partner CTA (dark)
   ============================================================ */
.dp-card { max-width: 480px; margin: 0 auto 72px; background: var(--surface); border: 1px solid var(--line); border-radius: 20px; padding: 32px; }
.dp-title { font-size: 22px; font-weight: 500; letter-spacing: -0.025em; margin-bottom: 20px; }
.dp-form { display: flex; flex-direction: column; gap: 16px; }
.dp-field label { display: block; margin-bottom: 7px; font-size: 13.5px; font-weight: 500; color: var(--ink-2); }
.dp-form input[type="email"], .dp-form input[type="text"]:not(.hp) {
  width: 100%; min-height: 50px; padding: 13px 16px;
  background: var(--bg); color: var(--ink); font: inherit; font-size: 16px;
  border: 1px solid var(--line); border-radius: var(--radius-sm);
  transition: border-color .2s, box-shadow .2s;
}
.dp-form input::placeholder { color: var(--ink-3); }
.dp-form input:focus { border-color: var(--accent-dot); box-shadow: 0 0 0 3px rgba(47,179,107,0.22); }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; opacity: 0; pointer-events: none; }
.dp-form .btn { width: 100%; margin-top: 4px; }
.dp-form .btn:disabled { opacity: 0.7; cursor: default; transform: none; }
.dp-err { color: #FF9C8E; font-size: 14px; line-height: 1.45; }
.dp-note { font-size: 13px; line-height: 1.5; color: var(--ink-3); }
.dp-note a { color: var(--ink-2); text-decoration: underline; text-underline-offset: 3px; }
.dp-note a:hover { color: var(--on-dark); }
.dp-ok { padding: 28px 0; text-align: center; outline: none; }
.dp-ok .check { width: 52px; height: 52px; margin: 0 auto 18px; border-radius: 50%; display: grid; place-items: center; background: var(--accent); color: #fff; }
.dp-ok .check svg.ico { width: 24px; height: 24px; stroke-width: 2.2; }
.dp-ok h3 { font-size: 22px; font-weight: 500; letter-spacing: -0.025em; }
.dp-ok p { margin-top: 8px; color: var(--ink-2); }

#contact .contact-head-row {
  flex-direction: column; justify-content: center; gap: 24px; margin-bottom: 36px;
  padding-top: 56px; border-top: 1px solid var(--line); text-align: center;
}
#contact .contact-head-row .section-head { margin-bottom: 0; }
#contact .contact-head-row .section-head h2.alt-h { font-size: clamp(24px, 3vw, 32px); }
#contact .contact-head-row .section-head p { margin-top: 12px; }
#contact .contact-head-row .contact-cards { margin-inline: auto; }
@media (max-width: 900px) { .dp-card { margin-bottom: 56px; } #contact .contact-head-row { padding-top: 44px; } }
@media (max-width: 560px) { .dp-card { padding: 24px 20px; } }

.footer small { font-family: var(--font); font-size: 13px; letter-spacing: 0; text-transform: none; }

/* site.css right-aligns the footer copyright on phones (a later rule beats its own mobile override) */
@media (max-width: 820px) { .footer small { justify-self: start; } }

/* ============================================================
   Reduced motion
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  .flow-line, .sd-wire, .chat-sched, .chat-dot::before { animation: none; }
  .flow-packet { display: none; }
  .uc-panel:not([hidden]), .sec-panel:not([hidden]) { animation: none; }
  .uc-tab, .sec-tab { transition: none; }
}

/* ============================================================
   Right-to-left (the Arabic homepage /ar/ reuses this file). Logical
   properties above already mirror most of the layout; what is left is
   the pieces drawn with physical coordinates (the connector SVGs and the
   hero glow), a little more line height for Arabic, and slightly larger
   small text, since Arabic reads smaller at the same pixel size.
   ============================================================ */
html[dir="rtl"] .flow-link { transform: scaleX(-1); }
/* the honeypot is parked off screen with left:-9999px; in RTL that is scrollable overflow (10,000px of sideways scroll) */
html[dir="rtl"] .hp { left: auto; right: -9999px; }

html[dir="rtl"] .hero.section--dark::before {
  background:
    radial-gradient(44% 56% at 22% 46%, rgba(47,179,107,0.17), transparent 72%),
    radial-gradient(rgba(243,242,238,0.085) 1px, transparent 1.3px) 0 0 / 26px 26px;
  -webkit-mask-image: radial-gradient(85% 95% at 32% 42%, #000 28%, transparent 86%);
          mask-image: radial-gradient(85% 95% at 32% 42%, #000 28%, transparent 86%);
}
html[dir="rtl"] .answer-table th, html[dir="rtl"] .answer-table td { padding-right: 0; padding-left: 12px; }
html[dir="rtl"] .answer-table .num { padding-left: 0; }
@media (max-width: 560px) {
  html[dir="rtl"] .answer-table th, html[dir="rtl"] .answer-table td { padding-right: 0; padding-left: 8px; }
  html[dir="rtl"] .answer-table .num { padding-left: 0; }
}
/* the Latin "WhatsApp" pill and brand names inside Arabic lines stay readable */
html[dir="rtl"] .chat-sched { font-size: 14.5px; }

/* ---------- Arabic needs more leading than the Latin body copy ---------- */
html[dir="rtl"] .section-head p,
html[dir="rtl"] .problem-card p,
html[dir="rtl"] .flow-layer p,
html[dir="rtl"] .ctrl-card p,
html[dir="rtl"] .uc-card p,
html[dir="rtl"] .uc-qs li,
html[dir="rtl"] .sec-tags li,
html[dir="rtl"] .answer-title,
html[dir="rtl"] .answer-table td,
html[dir="rtl"] .chat-bubble,
html[dir="rtl"] .dp-note,
html[dir="rtl"] .dp-err,
html[dir="rtl"] .dp-ok p { line-height: 1.75; }
html[dir="rtl"] .flow-name,
html[dir="rtl"] .flow-cat { line-height: 1.55; }
/* the source cards hold Latin system names, and two lines of them must fit the fixed 84px card */
html[dir="rtl"] .flow-sources .flow-name { direction: ltr; text-align: right; line-height: 1.3; }
html[dir="rtl"] .flow-sources .flow-cat { line-height: 1.4; }
html[dir="rtl"] .flow-cat, html[dir="rtl"] .uc-h, html[dir="rtl"] .flow-label, html[dir="rtl"] .footnote { font-size: 14.5px; }
html[dir="rtl"] .answer-table th, html[dir="rtl"] .answer-sources, html[dir="rtl"] .tag-illus { font-size: 13px; }
html[dir="rtl"] .chat-bubble { font-size: 16px; }
html[dir="rtl"] .uc-qs li { font-size: 17px; }
html[dir="rtl"] .footer small { font-size: 13.5px; }
