/* goapp.net/marketing-agent — "Instrument panel at night" (design-systems/goapp/DESIGN.md) */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --ink-950: #07111d;
  --ink-900: #0b1c33;
  --ink-850: #102540;
  --ink-800: #143052;
  --blue: #1c7fc4;
  --blue-bright: #2e95da;
  --blue-text: #5fb0e8;
  --orange: #fb570f;
  --orange-bright: #ff7a33;
  --text: #f3f1ec;
  --text-2: rgba(243, 241, 236, 0.74);
  --text-3: rgba(243, 241, 236, 0.6);
  --line: rgba(255, 255, 255, 0.06);
  --line-2: rgba(255, 255, 255, 0.12);
  --ease: cubic-bezier(.2, .7, .2, 1);
  --ease-out-expo: cubic-bezier(.16, 1, .3, 1);
  --display: 'Bricolage Grotesque', 'IBM Plex Sans Arabic', system-ui, sans-serif;
  --body: 'Hanken Grotesk', 'IBM Plex Sans Arabic', system-ui, sans-serif;
  --mono: 'JetBrains Mono', ui-monospace, monospace;
}
html[lang="ar"] {
  --display: 'IBM Plex Sans Arabic', 'Bricolage Grotesque', system-ui, sans-serif;
  --body: 'IBM Plex Sans Arabic', 'Hanken Grotesk', system-ui, sans-serif;
  --mono: 'IBM Plex Sans Arabic', 'JetBrains Mono', ui-monospace, monospace;
}

html { -webkit-text-size-adjust: 100%; scrollbar-color: var(--ink-800) var(--ink-950); scroll-behavior: smooth; }
body {
  background: var(--ink-900); color: var(--text);
  font: 400 17px/1.55 var(--body);
  -webkit-font-smoothing: antialiased; text-rendering: optimizeLegibility;
  caret-color: var(--blue-bright);
}
html[lang="ar"] body { line-height: 1.8; }
::selection { background: rgba(46, 149, 218, 0.4); color: var(--text); }
a { color: var(--blue-text); text-underline-offset: 3px; text-decoration-thickness: 1px; }
:focus-visible { outline: 2px solid var(--blue-bright); outline-offset: 3px; border-radius: 8px; }
img, svg { display: block; }
bdi { unicode-bidi: isolate; }
.skip { position: absolute; inset-inline-start: 16px; top: -60px; z-index: 50; padding: 10px 16px; border-radius: 8px; background: var(--ink-850); color: var(--text); text-decoration: none; }
.skip:focus { top: 12px; }

.wrap { max-width: 1280px; margin: 0 auto; padding: 0 32px; }
@media (max-width: 640px) { .wrap { padding: 0 20px; } }

/* Header: /assets/site/site-nav.v1.css (shared goapp.net menu) */
[id] { scroll-margin-top: 80px; }
.lang-ar { font-family: 'IBM Plex Sans Arabic', sans-serif; }

/* ─── Buttons ─── */
.btn {
  display: inline-flex; align-items: center; gap: 10px; min-height: 48px;
  padding: 12px 20px; border-radius: 10px; text-decoration: none;
  font: 600 16px/1.2 var(--body);
  transition: background 150ms var(--ease), border-color 150ms var(--ease), color 150ms var(--ease), transform 150ms var(--ease);
}
.btn svg { width: 18px; height: 18px; flex: none; }
.btn-primary { background: var(--orange); color: var(--ink-950); }
.btn-primary:hover { background: var(--orange-bright); transform: translateY(-1px); }
.btn-secondary { border: 1px solid var(--blue); color: var(--blue-text); }
.btn-secondary:hover { border-color: var(--blue-bright); color: var(--text); }
html[dir="rtl"] .btn .arw { transform: scaleX(-1); }

/* ─── Type ─── */
h1, h2, h3 { font-family: var(--display); font-weight: 700; text-wrap: balance; }
h1 { font-size: clamp(2.5rem, 5vw, 4.5rem); line-height: 1.04; letter-spacing: -0.03em; max-width: 13ch; }
h2 { font-size: clamp(2rem, 3.6vw, 3rem); line-height: 1.08; letter-spacing: -0.02em; max-width: 20ch; }
h3 { font-size: 22px; line-height: 1.25; letter-spacing: -0.01em; font-weight: 600; }
html[lang="ar"] h1, html[lang="ar"] h2, html[lang="ar"] h3 { letter-spacing: 0; }
html[lang="ar"] h1 { line-height: 1.35; max-width: 15ch; font-size: clamp(2.25rem, 4.4vw, 4rem); }
html[lang="ar"] h2 { line-height: 1.4; }
html[lang="ar"] h3 { line-height: 1.5; }
.lede { font-size: 19px; line-height: 1.55; color: var(--text-2); max-width: 54ch; }
html[lang="ar"] .lede { line-height: 1.85; }
.sub { margin-top: 20px; color: var(--text-2); max-width: 60ch; }
.tone-blue { color: var(--blue-bright); }

section { padding: 112px 0; border-top: 1px solid var(--line); }
@media (max-width: 768px) { section { padding: 64px 0; } }

/* ─── Hero ─── */
.hero { border-top: 0; padding: 48px 0 112px; }
.hero-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 64px; align-items: start; }
.hero-copy { padding-top: 96px; position: sticky; top: 24px; }
@media (max-width: 1024px) { .hero-copy { padding-top: 24px; position: static; } }
.hero .lede { margin-top: 28px; }
.cta-row { margin-top: 40px; display: flex; flex-wrap: wrap; gap: 12px; }
.fine { margin-top: 20px; font-size: 15px; color: var(--text-3); }
@media (max-width: 1024px) { .hero-grid { grid-template-columns: 1fr; gap: 56px; } }
@media (max-width: 768px) { .hero { padding: 24px 0 64px; } }

/* ─── Phone thread (illustrative) ─── */
.phone {
  position: relative; width: 100%; max-width: 400px; justify-self: end;
  background: var(--ink-950); border: 1px solid var(--line-2); border-radius: 14px;
  overflow: hidden;
}
html[dir="rtl"] .phone { justify-self: start; }
@media (max-width: 1024px) { .phone, html[dir="rtl"] .phone { justify-self: center; } }
.phone-top { display: flex; align-items: center; gap: 12px; padding: 14px 16px; background: var(--ink-850); border-bottom: 1px solid var(--line); }
.avatar { width: 36px; height: 36px; border-radius: 50%; background: var(--ink-900); border: 1px solid var(--line-2); display: grid; place-items: center; flex: none; }
.avatar img { height: 20px; width: auto; }
.phone-top b { display: block; font-weight: 600; font-size: 15px; line-height: 1.3; }
.phone-top small { display: block; font-size: 13px; color: var(--text-3); line-height: 1.3; }
.example-tag { margin-inline-start: auto; font: 500 12px/1 var(--mono); letter-spacing: 0.04em; text-transform: uppercase; color: var(--blue-text); background: rgba(28, 127, 196, 0.14); padding: 6px 8px; border-radius: 8px; white-space: nowrap; }
html[lang="ar"] .example-tag { font-size: 14px; letter-spacing: 0; text-transform: none; }
.thread { padding: 18px 14px 20px; display: flex; flex-direction: column; gap: 10px; }
.msg { max-width: 88%; padding: 10px 12px; border-radius: 10px; font-size: 15px; line-height: 1.5; }
html[lang="ar"] .msg { font-size: 16px; line-height: 1.7; }
.msg.in { align-self: flex-start; background: var(--ink-850); border: 1px solid var(--line); border-start-start-radius: 4px; }
.msg.out { align-self: flex-end; background: rgba(28, 127, 196, 0.26); border-start-end-radius: 4px; }
.msg time { display: block; margin-top: 4px; font: 400 12px/1 var(--mono); color: var(--text-3); text-align: end; }
html[lang="ar"] .msg time { font-family: var(--mono); font-size: 13px; }
.msg .k { color: var(--text-3); }
.summary { list-style: none; margin-top: 8px; display: grid; gap: 6px; }
.summary li { display: grid; grid-template-columns: 92px 1fr; gap: 8px; padding-top: 6px; border-top: 1px solid var(--line); }
html[lang="ar"] .summary li { grid-template-columns: 96px 1fr; }
.summary li span:first-child { font: 500 12px/1.7 var(--mono); letter-spacing: 0.04em; text-transform: uppercase; color: var(--blue-text); }
html[lang="ar"] .summary li span:first-child { font-size: 14px; letter-spacing: 0; text-transform: none; line-height: 1.7; font-weight: 600; }

.adcard { max-width: 92%; padding: 0; overflow: hidden; }
.ad-art { position: relative; aspect-ratio: 18 / 25; background: #f6e8d2; }
.ad-art img { width: 100%; height: 100%; object-fit: cover; object-position: 50% 50%; }
.adthumb { display: grid; grid-template-columns: 64px 1fr; gap: 12px; align-items: center; }
.adthumb img { width: 64px; height: auto; aspect-ratio: 18 / 25; object-fit: cover; border-radius: 6px; }
.ad-meta { padding: 10px 12px 12px; display: grid; gap: 4px; }
.ad-meta p { font-size: 14px; line-height: 1.5; }
html[lang="ar"] .ad-meta p { font-size: 15px; line-height: 1.7; }
.ad-actions { display: flex; gap: 8px; margin-top: 8px; }
.ad-actions span { flex: 1; text-align: center; padding: 7px 8px; border: 1px solid var(--line-2); border-radius: 8px; font-size: 14px; font-weight: 600; color: var(--blue-text); }
.check { font-weight: 600; }
.check svg { display: inline-block; width: 16px; height: 16px; vertical-align: -3px; margin-inline-end: 4px; color: var(--blue-text); }

/* ─── The working week (lead section) ─── */
.week-head { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 64px; align-items: end; }
.week-head .sub { margin-top: 0; }
@media (max-width: 1024px) { .week-head { grid-template-columns: 1fr; gap: 24px; } }
.board { margin-top: 64px; border: 1px solid var(--line-2); border-radius: 14px; background: var(--ink-950); overflow: hidden; }
.board-row { display: grid; grid-template-columns: 220px minmax(0, 1fr) 280px; gap: 32px; align-items: center; padding: 28px 32px; border-top: 1px solid var(--line); }
.board-row:first-child { border-top: 0; }
.cadence { font: 500 13px/1.4 var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--blue-text); }
html[lang="ar"] .cadence { font-size: 17px; font-weight: 600; letter-spacing: 0; text-transform: none; }
.board-row h3 { font-size: 20px; }
.board-row p { margin-top: 6px; color: var(--text-2); max-width: 58ch; }
.track { display: grid; grid-template-columns: repeat(7, 1fr); gap: 6px; }
.track i { height: 28px; border-radius: 8px; background: var(--ink-850); border: 1px solid var(--line); position: relative; }
.track i.on::after { content: ''; position: absolute; inset: 9px calc(50% - 5px); border-radius: 50%; background: var(--blue-bright); }
.track i.block { background: rgba(28, 127, 196, 0.32); border-color: rgba(46, 149, 218, 0.5); }
.track.reply { grid-template-columns: 1fr; }
.track.reply i { background: transparent; border-style: dashed; border-color: rgba(46, 149, 218, 0.45); display: grid; place-items: center; }
.board-note { padding: 18px 32px; border-top: 1px solid var(--line-2); background: var(--ink-850); font-size: 15px; color: var(--text-2); display: flex; gap: 10px; align-items: center; }
.board-note svg { width: 18px; height: 18px; color: var(--blue-text); flex: none; }
@media (max-width: 1024px) {
  .board-row { grid-template-columns: 1fr; gap: 14px; padding: 24px; }
  .track { max-width: 320px; }
  .board-note { padding: 16px 24px; }
}

/* ─── What it does (editorial list) ─── */
.does { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 64px; }
.does-list { list-style: none; display: grid; grid-template-columns: 1fr 1fr; column-gap: 48px; }
.does-list li { padding: 28px 0; border-top: 1px solid var(--line-2); display: grid; grid-template-columns: 32px 1fr; gap: 16px; }
.does-list svg { width: 26px; height: 26px; color: var(--blue-bright); margin-top: 2px; }
.does-list p { margin-top: 6px; color: var(--text-2); }
.does-list h3 { font-size: 20px; }
.does-intro { align-self: start; position: sticky; top: 32px; }
@media (max-width: 1024px) { .does { grid-template-columns: 1fr; gap: 32px; } .does-intro { position: static; } }
@media (max-width: 768px) { .does-list { grid-template-columns: 1fr; } }

/* ─── Once Meta is connected ─── */
.meta-grid { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 64px; align-items: start; }
.meta-steps { list-style: none; border: 1px solid var(--line-2); border-radius: 14px; background: var(--ink-850); }
.meta-steps li { padding: 24px 28px; border-top: 1px solid var(--line); }
.meta-steps li:first-child { border-top: 0; }
.meta-steps p { margin-top: 6px; color: var(--text-2); }
.meta-steps h3 { font-size: 20px; }
.integrations { margin-top: 40px; display: grid; gap: 20px; }
.int-label { font: 500 13px/1.4 var(--mono); letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-3); margin-bottom: 10px; font-weight: 500; }
html[lang="ar"] .int-label { font-size: 15px; letter-spacing: 0; text-transform: none; font-weight: 600; }
.chips { display: flex; flex-wrap: wrap; gap: 8px; list-style: none; }
.chips li { padding: 8px 12px; border-radius: 8px; border: 1px solid var(--line-2); font-size: 15px; font-weight: 500; }
.chips.live li { border-color: rgba(46, 149, 218, 0.55); background: rgba(28, 127, 196, 0.14); }
.chips.soon li { color: var(--text-2); border-style: dashed; }
@media (max-width: 1024px) { .meta-grid { grid-template-columns: 1fr; gap: 40px; } }

/* ─── How to start ─── */
.steps { margin-top: 56px; list-style: none; display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; counter-reset: s; border-top: 1px solid var(--line-2); }
.steps li { padding: 32px 0 8px; padding-inline-end: 32px; position: relative; }
.steps li + li { padding-inline-start: 32px; border-inline-start: 1px solid var(--line); }
.steps .n { font: 500 14px/1 var(--mono); color: var(--blue-text); }
.steps h3 { margin-top: 18px; }
.steps p { margin-top: 8px; color: var(--text-2); max-width: 34ch; }
.steps-note { margin-top: 40px; font-size: 18px; color: var(--text); }
@media (max-width: 768px) {
  .steps { grid-template-columns: 1fr; }
  .steps li, .steps li + li { padding: 24px 0; border-inline-start: 0; border-top: 1px solid var(--line); }
  .steps li:first-child { border-top: 0; }
}

/* ─── Closing CTA ─── */
.close { background: var(--ink-950); }
.close-in { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: 64px; align-items: end; }
.close .contact { display: grid; gap: 16px; justify-items: start; }
.close .contact p { color: var(--text-2); font-size: 15px; }
@media (max-width: 1024px) { .close-in { grid-template-columns: 1fr; gap: 32px; } }

/* ─── Footer ─── */
.foot { border-top: 1px solid var(--line); background: var(--ink-950); }
.foot-in { max-width: 1280px; margin: 0 auto; padding: 28px 32px 36px; display: flex; flex-wrap: wrap; gap: 12px 32px; justify-content: space-between; font-size: 14px; color: var(--text-3); }
.foot a { color: var(--text-2); }
.foot a:hover { color: var(--text); }

/* ─── Reveal (one authored moment: the thread arrives) ─── */
@media (prefers-reduced-motion: no-preference) {
  .js .thread .msg { opacity: 0; transform: translateY(10px); transition: opacity 450ms var(--ease-out-expo), transform 450ms var(--ease-out-expo); }
  .js .thread.live .msg { opacity: 1; transform: none; }
  .js .thread.live .msg:nth-child(2) { transition-delay: 350ms; }
  .js .thread.live .msg:nth-child(3) { transition-delay: 900ms; }
  .js .thread.live .msg:nth-child(4) { transition-delay: 1300ms; }
  .js .thread.live .msg:nth-child(5) { transition-delay: 1650ms; }
  .js .thread.live .msg:nth-child(6) { transition-delay: 2000ms; }
}
