/* Diwan landing: one stylesheet for the Arabic (RTL) and English (LTR) pages.
   Logical properties only, so direction comes from <html dir>.
   Sections: 1 tokens, 2 base, 3 layout, 4 header, 5 hero, 6 mockups, 7 channels/pillars,
   8 tabs, 9 steps, 10 bands, 11 integrations/arabic, 12 pricing, 13 faq, 14 footer, 15 motion/responsive */

/* 1. Tokens (from control-plane/branding/diwan.brand.json) */
:root {
  color-scheme: only light; /* light only for now; the dark tokens below are switched off (media "not all") */
  --brand: #773D50; --brand-hover: #5E2F3F; --brand-pale: #F3E8EC;
  --bg: #f7f8fa; --surface: #ffffff; --surface-2: #f1f3f5;
  --border: #e4e7eb; --border-strong: #cfd5db;
  --text: #352A32; --muted: #5f6b76;
  --accent-text: #773D50; --on-accent: #ffffff;
  --success: #167a45; --success-pale: #e5f5ec; --warning: #8a5a14; --warning-pale: #fbf2e2;
  --info: #285fbd; --info-pale: #e8effc;
  --shadow-sm: 0 1px 2px rgba(16,24,32,.04), 0 1px 3px rgba(16,24,32,.06);
  --shadow-lg: 0 12px 32px rgba(16,24,32,.12), 0 2px 6px rgba(16,24,32,.06);
  --r-sm: 6px; --r: 10px; --r-lg: 14px; --r-xl: 20px;
  --font: 'IBM Plex Sans Arabic', 'Inter', system-ui, -apple-system, 'Segoe UI', 'Noto Sans Arabic', 'Noto Sans Arabic UI', Tahoma, Roboto, sans-serif;
  --wrap: 1140px; --gut: 24px; --head-h: 72px;
  --h1: clamp(2.375rem, 1.2rem + 4.4vw, 4rem);
  --h2: clamp(1.75rem, 1.2rem + 2vw, 2.5rem);
  --h3: clamp(1.25rem, 1.1rem + .6vw, 1.5rem);
}
@media not all {
  :root {
    --brand: #D9A0B3; --brand-hover: #E8B6C7; --brand-pale: #35232D;
    --bg: #0e1113; --surface: #161a1d; --surface-2: #1e2327;
    --border: #2a3035; --border-strong: #3a4148;
    --text: #E8EBED; --muted: #9aa5af;
    --accent-text: #E8B6C7; --on-accent: #26141D;
    --success: #3dbe74; --success-pale: #12301f; --warning: #e0a43a; --warning-pale: #33270f;
    --info: #5b8ff0; --info-pale: #172540;
    --shadow-sm: 0 1px 2px rgba(0,0,0,.4);
    --shadow-lg: 0 16px 40px rgba(0,0,0,.5), 0 2px 6px rgba(0,0,0,.3);
  }
}

/* 2. Base */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; scroll-padding-block-start: calc(var(--head-h) + 8px); -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--bg); color: var(--text); font-family: var(--font); font-size: 1.0625rem; line-height: 1.7; overflow-x: hidden; }
h1, h2, h3, p, ul, ol, figure { margin: 0; }
h1, h2, h3 { line-height: 1.25; letter-spacing: -.01em; text-wrap: balance; }
ul, ol { padding: 0; list-style: none; }
img, svg { display: block; max-width: 100%; }
a { color: var(--accent-text); }
:focus-visible { outline: 3px solid var(--brand); outline-offset: 2px; border-radius: 4px; }
.skip { position: absolute; inset-inline-start: 8px; inset-block-start: -64px; background: var(--surface); padding: 8px 16px; border-radius: var(--r); z-index: 100; }
.skip:focus { inset-block-start: 8px; }

/* 3. Layout */
.wrap { width: 100%; max-width: calc(var(--wrap) + 2 * var(--gut)); margin-inline: auto; padding-inline: var(--gut); }
section { padding-block: clamp(56px, 7vw, 96px); }
.tint { background: var(--brand-pale); }
.surface { background: var(--surface); border-block: 1px solid var(--border); }
.eyebrow { color: var(--accent-text); font-weight: 600; font-size: .9375rem; margin-block-end: 8px; }
.sec-head { max-width: 680px; margin-block-end: 48px; }
.sec-head.center { margin-inline: auto; text-align: center; }
.sec-head h2 { font-size: var(--h2); }
.sec-head p { color: var(--muted); margin-block-start: 16px; }
.btn { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 48px; padding: 8px 24px; border-radius: var(--r); border: 1px solid transparent; font: inherit; font-weight: 600; text-decoration: none; cursor: pointer; transition: background .15s, border-color .15s; }
.btn-primary { background: var(--brand); color: var(--on-accent); }
.btn-primary:hover { background: var(--brand-hover); }
.btn-ghost { background: var(--surface); color: var(--text); border-color: var(--border-strong); }
.btn-ghost:hover { border-color: var(--brand); }
.btn-sm { min-height: 44px; padding: 4px 16px; font-size: .9375rem; }
.btn-block { width: 100%; }
.btn-light { background: var(--surface); color: var(--brand); }
.btn-light:hover { background: var(--brand-pale); }
.btn-outline-light { color: #fff; border-color: rgba(255,255,255,.5); background: transparent; }
.btn-outline-light:hover { border-color: #fff; }
.icon { width: 20px; height: 20px; flex: none; }
.flip { transform: scaleX(1); }
[dir="rtl"] .flip { transform: scaleX(-1); }

/* 4. Header */
.site-head { position: sticky; inset-block-start: 0; z-index: 50; background: color-mix(in srgb, var(--surface) 92%, transparent); backdrop-filter: blur(10px); border-block-end: 1px solid var(--border); }
.head-in { display: flex; align-items: center; gap: 16px; min-height: var(--head-h); }
.logo { display: inline-flex; align-items: center; min-height: 44px; }
.logo img { height: 32px; width: auto; }
.nav { display: flex; gap: 4px; margin-inline-start: 16px; flex: 1; }
.nav a { display: inline-flex; align-items: center; min-height: 44px; padding-inline: 12px; color: var(--text); text-decoration: none; font-size: .9375rem; border-radius: var(--r); }
.nav a:hover { background: var(--brand-pale); }
.head-actions { display: flex; align-items: center; gap: 8px; }
.lang { display: inline-flex; align-items: center; min-height: 44px; padding-inline: 12px; font-weight: 600; font-size: .9375rem; color: var(--text); text-decoration: none; border-radius: var(--r); }
.lang:hover, .signin:hover { background: var(--brand-pale); }
.signin { display: inline-flex; align-items: center; min-height: 44px; padding-inline: 12px; font-size: .9375rem; color: var(--text); text-decoration: none; border-radius: var(--r); }
.menu-btn { display: none; min-height: 44px; min-width: 44px; align-items: center; justify-content: center; background: transparent; border: 1px solid var(--border-strong); border-radius: var(--r); color: var(--text); cursor: pointer; }

/* 5. Hero */
.hero { overflow-x: clip; padding-block: clamp(40px, 6vw, 80px) clamp(56px, 8vw, 96px); background: radial-gradient(1000px 420px at 50% -10%, var(--brand-pale), transparent 70%); }
.hero-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(0, 3fr); gap: 48px; align-items: center; }
.hero h1 { font-size: var(--h1); font-weight: 700; }
.hero h1 em { font-style: normal; color: var(--accent-text); }
.hero .sub { color: var(--muted); font-size: clamp(1.0625rem, 1rem + .4vw, 1.25rem); margin-block: 24px 32px; max-width: 520px; }
.cta-row { display: flex; flex-wrap: wrap; gap: 16px; }
.hero-meta { color: var(--muted); font-size: .9375rem; margin-block-start: 24px; }
.hero-mock { position: relative; margin: 0; }
.hero-mock .mock { position: relative; zoom: 1.12; box-shadow: 0 2px 4px rgba(16,24,32,.04), 0 12px 24px rgba(16,24,32,.08), 0 32px 64px rgba(119,61,80,.18); }
.hero-mock .blob { position: absolute; inset: -8% -6%; background: radial-gradient(closest-side, color-mix(in srgb, var(--brand) 28%, transparent), transparent); filter: blur(40px); opacity: .7; z-index: 0; }
.hero-mock .inbox { min-height: 500px; grid-template-columns: 210px minmax(0, 1fr); }
.float { position: absolute; z-index: 2; display: flex; align-items: center; gap: 12px; padding: 12px 16px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); box-shadow: var(--shadow-lg); font-size: .875rem; line-height: 1.3; }
.float svg { color: var(--success); width: 24px; height: 24px; }
.float.f2 svg { color: var(--accent-text); }
.float b { display: block; } .float small { color: var(--muted); font-size: .75rem; }
.float.f1 { inset-inline-start: -28px; inset-block-end: 36px; }
.float.f2 { inset-inline-end: -16px; inset-block-start: -20px; }
.caption { color: var(--muted); font-size: .875rem; margin-block-start: 12px; text-align: center; }

/* 6. Product mockups (HTML/CSS, no images) */
.mock { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); box-shadow: var(--shadow-lg); overflow: hidden; font-size: .875rem; line-height: 1.5; text-align: start; }
.mock-bar { display: flex; align-items: center; gap: 8px; padding: 12px 16px; border-block-end: 1px solid var(--border); background: var(--surface-2); }
.dot { width: 10px; height: 10px; border-radius: 50%; background: var(--border-strong); }
.mock-bar b { margin-inline-start: 8px; font-weight: 600; font-size: .8125rem; }
.inbox { display: grid; grid-template-columns: 200px minmax(0, 1fr); min-height: 440px; }
.convs { border-inline-end: 1px solid var(--border); }
.conv { display: flex; gap: 8px; padding: 12px; border-block-end: 1px solid var(--border); align-items: flex-start; }
.conv.active { background: var(--brand-pale); }
.conv .who { min-width: 0; flex: 1; }
.conv strong { display: block; font-size: .8125rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.conv span.pv { display: block; color: var(--muted); font-size: .75rem; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.av { width: 32px; height: 32px; border-radius: 50%; background: var(--brand-pale); color: var(--accent-text); display: grid; place-items: center; font-weight: 700; font-size: .8125rem; flex: none; border: 1px solid var(--border); }
.conv.active .av { background: var(--surface); }
.ch { width: 14px; height: 14px; color: var(--muted); display: inline-block; vertical-align: -2px; }
.badge { background: var(--brand); color: var(--on-accent); border-radius: 999px; min-width: 20px; height: 20px; display: inline-grid; place-items: center; font-size: .6875rem; font-weight: 700; padding-inline: 6px; }
.chat { display: flex; flex-direction: column; min-width: 0; }
.chat-head { display: flex; align-items: center; gap: 8px; padding: 12px 16px; border-block-end: 1px solid var(--border); font-weight: 600; }
.chat-head small { color: var(--muted); font-weight: 400; margin-inline-start: auto; }
.thread { display: flex; flex-direction: column; gap: 8px; padding: 16px; flex: 1; background: var(--bg); }
.msg { max-width: 82%; padding: 8px 12px; border-radius: 12px; box-shadow: var(--shadow-sm); }
.msg.in { align-self: flex-start; background: var(--surface); border: 1px solid var(--border); border-start-start-radius: 4px; }
.msg.out { align-self: flex-end; background: var(--brand); color: var(--on-accent); border-start-end-radius: 4px; }
.msg time { display: block; font-size: .6875rem; opacity: .7; margin-block-start: 2px; }
.slots { display: flex; flex-wrap: wrap; gap: 8px; margin-block-start: 8px; }
.slot { border: 1px solid var(--border-strong); background: var(--surface); color: var(--text); border-radius: var(--r-sm); padding: 4px 12px; font-size: .8125rem; font-weight: 600; }
.slot.sel { background: var(--brand); border-color: var(--brand); color: var(--on-accent); }
.slot.off { color: var(--muted); text-decoration: line-through; background: var(--surface-2); }
.msg.out .slot { background: transparent; border-color: currentColor; color: var(--on-accent); }
.msg.out .slot.sel { background: var(--on-accent); color: var(--brand); border-color: var(--on-accent); }
.msg.out .slot.off { background: transparent; opacity: .6; }
.card-ok { align-self: flex-end; width: min(82%, 300px); background: var(--success-pale); border: 1px solid var(--success); border-radius: var(--r); padding: 12px; color: var(--text); }
.card-ok .t { display: flex; align-items: center; gap: 8px; font-weight: 700; color: var(--success); }
.card-ok dl { margin: 8px 0 0; display: grid; grid-template-columns: auto 1fr; gap: 0 12px; font-size: .8125rem; }
.card-ok dt { color: var(--muted); } .card-ok dd { margin: 0; font-weight: 600; }
.sys { align-self: center; font-size: .75rem; color: var(--muted); background: var(--surface-2); border-radius: 999px; padding: 4px 12px; }
.chip { display: inline-block; border-radius: 999px; padding: 0 8px; font-size: .6875rem; font-weight: 600; background: var(--info-pale); color: var(--info); }
.chip.g { background: var(--success-pale); color: var(--success); }
.chip.w { background: var(--warning-pale); color: var(--warning); }
.chip.b { background: var(--brand-pale); color: var(--accent-text); }
.note-human { align-self: stretch; display: flex; gap: 8px; align-items: center; background: var(--warning-pale); border: 1px dashed var(--warning); color: var(--text); border-radius: var(--r); padding: 8px 12px; font-size: .8125rem; }
.src { display: inline-flex; gap: 4px; align-items: center; font-size: .6875rem; margin-block-start: 4px; opacity: .85; }
.board { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px; padding: 16px; background: var(--bg); }
.col { background: var(--surface-2); border-radius: var(--r); padding: 8px; display: flex; flex-direction: column; gap: 8px; }
.col h4 { margin: 0; font-size: .75rem; display: flex; justify-content: space-between; color: var(--muted); padding: 4px; }
.deal { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-sm); padding: 8px; box-shadow: var(--shadow-sm); }
.deal strong { display: block; font-size: .8125rem; }
.deal small { display: block; color: var(--muted); font-size: .75rem; margin-block-end: 4px; }
.list-mock .conv { padding: 12px 16px; }
.list-mock .conv strong { font-size: .875rem; }
.list-mock .conv span.pv { font-size: .8125rem; }
.row-end { display: flex; flex-direction: column; align-items: flex-end; gap: 4px; font-size: .6875rem; color: var(--muted); }
.mock-note { color: var(--muted); font-size: .8125rem; margin-block-start: 12px; text-align: center; }

/* 7. Channels and pillars */
.channels { padding-block: 40px; text-align: center; }
.channels p { color: var(--muted); font-weight: 600; margin-block-end: 16px; }
.channel-row { display: flex; flex-wrap: wrap; justify-content: center; gap: 16px; }
.channel { display: inline-flex; align-items: center; gap: 12px; padding: 12px 24px; background: var(--surface); border: 1px solid var(--border); border-radius: 999px; font-weight: 600; box-shadow: var(--shadow-sm); }
.channel svg { width: 24px; height: 24px; color: var(--brand); }
.pillars { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; }
.pillar { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-xl); padding: 32px; box-shadow: var(--shadow-sm); }
.pillar .ic { width: 64px; height: 64px; border-radius: 50%; background: var(--brand-pale); color: var(--accent-text); display: grid; place-items: center; margin-block-end: 24px; }
.pillar .ic svg { width: 28px; height: 28px; }
.pillar { display: flex; flex-direction: column; }
.pillar p { flex: 1; }
.mini { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-block-start: 24px; padding-block-start: 16px; border-block-start: 1px solid var(--border); }
.mini .chip { display: inline-flex; align-items: center; gap: 4px; padding: 2px 10px; font-size: .75rem; background: var(--brand-pale); color: var(--accent-text); }
.mini .chip.w { background: var(--warning-pale); color: var(--warning); }
.mini .chip.g { background: var(--success-pale); color: var(--success); }
.mini .chip .ch { color: currentColor; }
.mini .sep svg { width: 14px; height: 14px; color: var(--muted); }
.pillar h3 { font-size: var(--h3); margin-block-end: 8px; }
.pillar p { color: var(--muted); }

/* 8. Tabs (all panels visible without JS; .js hides inactive ones) */
.tabs-list { display: none; gap: 8px; flex-wrap: wrap; margin-block-end: 32px; padding: 8px; background: var(--surface-2); border-radius: var(--r-lg); width: fit-content; max-width: 100%; }
.js .tabs-list { display: flex; }
.tab { min-height: 44px; padding: 4px 24px; border-radius: var(--r); border: 0; background: transparent; color: var(--muted); font: inherit; font-weight: 600; cursor: pointer; }
.tab:hover { color: var(--text); }
.tab:hover { background: var(--surface); }
.tab[aria-selected="true"] { background: var(--brand); color: var(--on-accent); box-shadow: var(--shadow-sm); }
.panel { display: grid; grid-template-columns: minmax(0, 9fr) minmax(0, 11fr); gap: 48px; align-items: center; padding-block: 24px; }
.panel + .panel { border-block-start: 1px solid var(--border); margin-block-start: 24px; padding-block-start: 48px; }
.js .panel + .panel { border: 0; margin: 0; padding-block-start: 24px; }
.js .panel[hidden] { display: none; }
.panel .mock { zoom: 1.2; }
.panel h3 { font-size: var(--h3); margin-block-end: 24px; }
.ticks li { position: relative; padding-inline-start: 32px; margin-block-end: 16px; }
.ticks li::before { content: ""; position: absolute; inset-inline-start: 0; inset-block-start: .4em; width: 20px; height: 20px; border-radius: 50%; background: var(--brand-pale) url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5.5 10.5l3 3 6-6.5' fill='none' stroke='%23773D50' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/20px no-repeat; }

/* 9. Steps */
.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; counter-reset: s; }
.step { position: relative; padding: 32px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-xl); }
.step::before { counter-increment: s; content: counter(s); display: grid; place-items: center; width: 40px; height: 40px; border-radius: 50%; background: var(--brand); color: var(--on-accent); font-weight: 700; margin-block-end: 24px; }
.step h3 { font-size: var(--h3); margin-block-end: 8px; }
.step p { color: var(--muted); }

/* 10. Call-to-action bands */
.band { position: relative; overflow: hidden; background: var(--brand); color: #fff; text-align: center; padding-block: clamp(48px, 6vw, 80px); background-image: radial-gradient(rgba(255,255,255,.14) 1px, transparent 1.5px), radial-gradient(circle at 12% 0%, rgba(255,255,255,.16), transparent 45%); background-size: 24px 24px, auto; }
.band .wrap { position: relative; }
.band-mark { position: absolute; inset-inline-end: 4%; inset-block-end: -20%; width: 340px; height: 340px; color: #fff; opacity: .1; }
@media not all { .band { background: #5E2F3F; } }
.band h2 { font-size: var(--h2); max-width: 720px; margin-inline: auto; }
.band p { margin: 16px auto 32px; max-width: 560px; opacity: .92; }
.band .cta-row { justify-content: center; }

/* 11. Integrations and Arabic section */
.int-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 24px; }
.vis { margin-block-start: auto; min-height: 232px; background: var(--bg); border: 1px solid var(--border); border-radius: var(--r); padding: 16px; font-size: .875rem; }
.cal .hr { display: grid; grid-template-columns: 48px 1fr; align-items: stretch; min-height: 48px; border-block-end: 1px solid var(--border); gap: 8px; }
.cal .hr:last-child { border: 0; }
.cal .hr span { color: var(--muted); font-size: .75rem; padding-block-start: 4px; }
.cal i { font-style: normal; margin-block: 4px; padding: 4px 12px; border-radius: var(--r-sm); font-weight: 600; font-size: .8125rem; display: flex; align-items: center; }
.cal i.ev { background: var(--brand); color: var(--on-accent); }
.cal i.busy { background: repeating-linear-gradient(135deg, var(--surface-2), var(--surface-2) 6px, var(--border) 6px, var(--border) 12px); color: var(--muted); font-weight: 400; }
.sheet .tr { display: grid; grid-template-columns: 1.3fr 1.2fr 1fr; gap: 8px; padding: 8px 4px; border-block-end: 1px solid var(--border); }
.sheet .tr:last-child { border: 0; }
.sheet .tr.h { font-weight: 700; color: var(--accent-text); background: var(--brand-pale); border-radius: var(--r-sm); padding-inline: 8px; border: 0; }
.sheet span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.int { display: flex; flex-direction: column; gap: 24px; padding: 32px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-xl); }
.int-head { display: flex; gap: 24px; }
.int .ic { width: 56px; height: 56px; flex: none; border-radius: var(--r); background: var(--brand-pale); color: var(--accent-text); display: grid; place-items: center; }
.int .ic svg { width: 28px; height: 28px; }
.int h3 { font-size: 1.25rem; margin-block-end: 4px; }
.int p { color: var(--muted); }
.ar-grid { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); gap: 56px; align-items: center; }
.ar-grid .sec-head { margin: 0; }
.rtl-pair { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 16px; }
.mini-card { box-shadow: var(--shadow-sm); }
.mini-card .thread { gap: 8px; align-items: flex-start; }
.mini-card .msg { max-width: 100%; }
.mini-card .lbl { padding: 8px 16px; border-block-start: 1px solid var(--border); color: var(--muted); font-size: .75rem; text-align: center; }

/* 12. Pricing */
.plans { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 24px; align-items: stretch; }
.plan { position: relative; display: flex; flex-direction: column; background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-xl); padding: 32px; box-shadow: var(--shadow-sm); }
.plan.rec { border: 2px solid var(--brand); box-shadow: var(--shadow-lg); }
.plan .flag { position: absolute; inset-block-start: -14px; inset-inline-start: 24px; background: var(--brand); color: var(--on-accent); font-size: .8125rem; font-weight: 600; padding: 2px 16px; border-radius: 999px; }
.plan h3 { font-size: 1.375rem; }
.plan .for { color: var(--muted); font-size: .9375rem; margin-block-start: 4px; min-height: 3.2em; }
.price { margin-block: 24px; padding: 16px; min-height: 80px; display: flex; align-items: center; justify-content: center; text-align: center; border-radius: var(--r); background: var(--brand-pale); border: 1px dashed var(--brand); color: var(--accent-text); font-weight: 600; }
.price.set { background: transparent; border: 0; justify-content: flex-start; padding: 0; font-size: 2rem; color: var(--text); }
.price.set small { font-size: 1rem; color: var(--muted); margin-inline-start: 8px; font-weight: 400; }
.plan .ticks { margin-block-end: 32px; flex: 1; }
.plan .ticks li { margin-block-end: 8px; font-size: .9375rem; }
.fine { color: var(--muted); font-size: .9375rem; text-align: center; margin-block-start: 32px; }

/* 13. FAQ */
.faq { max-width: 820px; margin-inline: auto; display: grid; gap: 16px; }
.faq details { background: var(--surface); border: 1px solid var(--border); border-radius: var(--r-lg); }
.faq summary { cursor: pointer; list-style: none; display: flex; justify-content: space-between; align-items: center; gap: 16px; min-height: 56px; padding: 12px 24px; font-weight: 600; border-radius: var(--r-lg); }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: ""; width: 20px; height: 20px; flex: none; background: currentColor; color: var(--accent-text); -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 8l5 5 5-5' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/contain no-repeat; mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 20 20'%3E%3Cpath d='M5 8l5 5 5-5' fill='none' stroke='black' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/contain no-repeat; transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(180deg); }
.faq details p { padding: 0 24px 24px; color: var(--muted); }

/* 14. Footer */
.site-foot { background: var(--surface); border-block-start: 1px solid var(--border); padding-block: 48px 32px; font-size: .9375rem; }
.foot-in { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 32px; }
.foot-nav { display: flex; flex-wrap: wrap; gap: 4px 16px; }
.foot-nav a { display: inline-flex; align-items: center; min-height: 44px; color: var(--text); text-decoration: none; }
.foot-nav a:hover { color: var(--accent-text); text-decoration: underline; }
.foot-bottom { margin-block-start: 24px; padding-block-start: 24px; border-block-start: 1px solid var(--border); display: flex; flex-wrap: wrap; gap: 8px 24px; justify-content: space-between; color: var(--muted); }
.foot-bottom a { color: var(--muted); display: inline-flex; align-items: center; min-height: 44px; }

/* 15. Motion and responsive */
@keyframes rise { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: none; } }
.hero-mock { animation: rise .7s ease-out both; }
.hero-mock .thread > * { animation: rise .5s ease-out both; }
.hero-mock .thread > :nth-child(1) { animation-delay: .3s; } .hero-mock .thread > :nth-child(2) { animation-delay: .6s; }
.hero-mock .thread > :nth-child(3) { animation-delay: .9s; } .hero-mock .thread > :nth-child(4) { animation-delay: 1.2s; }
.hero-mock .thread > :nth-child(5) { animation-delay: 1.5s; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; }
}
@media (max-width: 960px) {
  .hero-grid, .panel, .ar-grid { grid-template-columns: minmax(0, 1fr); gap: 40px; }
  .hero-mock .mock { zoom: 1; } .float.f1 { inset-inline-start: 0; } .float.f2 { inset-inline-end: 0; }
  .panel .mock { zoom: 1; }
  .pillars, .steps, .plans { grid-template-columns: minmax(0, 1fr); }
  .plans { max-width: 480px; margin-inline: auto; }
  .int-grid { grid-template-columns: minmax(0, 1fr); }
  .nav { display: none; }
  .menu-btn { display: inline-flex; }
  .js .nav.open { display: flex; flex-direction: column; position: absolute; inset-inline: 0; inset-block-start: 100%; margin: 0; padding: 8px var(--gut) 16px; background: var(--surface); border-block-end: 1px solid var(--border); box-shadow: var(--shadow-lg); }
  html:not(.js) .nav { display: flex; flex-wrap: wrap; order: 3; width: 100%; margin: 0; }
  html:not(.js) .head-in { flex-wrap: wrap; }
  html:not(.js) .menu-btn { display: none; }
}
@media (max-width: 640px) {
  :root { --gut: 16px; --head-h: 64px; }
  .signin { display: none; }
  .logo img { height: 28px; }
  .inbox { grid-template-columns: minmax(0, 1fr); min-height: 0; }
  .convs { display: none; }
  .btn-hero, .cta-row .btn { width: 100%; }
  .pillar, .step, .int, .plan { padding: 24px; }
  .int-head { flex-direction: column; gap: 16px; }
  .float { display: none; }
  .hero-mock .mock, .panel .mock { zoom: 1; }
  .rtl-pair { grid-template-columns: minmax(0, 1fr); }
  .board { grid-template-columns: minmax(0, 1fr); }
  .tabs-list { width: 100%; }
  .tab { flex: 1 1 40%; padding-inline: 8px; }
  .msg { max-width: 92%; }
  .head-actions .btn-sm { padding-inline: 12px; }
}

/* Tabs: keep the section height steady when switching panels (desktop) */
@media (min-width: 961px) { .js .panel { min-height: 520px; } }
.src .ch { color: currentColor; }

@media (max-width: 640px) {
  .chat-head { flex-wrap: nowrap; white-space: nowrap; }
  .chat-head small { white-space: nowrap; }
  .card-ok { width: min(94%, 320px); }
}
@media (max-width: 640px) { .hero-mock .inbox { grid-template-columns: minmax(0, 1fr); min-height: 0; } }
