:root {
  --ink: #0F1923;
  --ink-2: #1a2534;
  --muted: #525252;
  --muted-2: #737373;
  --muted-3: #a3a3a3;
  --line: #e5e5e5;
  --line-2: #f0f0f0;
  --line-3: #f7f7f7;
  --paper: #ffffff;
  --paper-2: #fafafa;
  --paper-3: #f5f5f5;
  --accent: #B08D57;
  --accent-hover: #8F6F3E;
  --accent-soft: #F7F1E6;
  --accent-soft-2: #FBF7F0;
  --green: #2f7a4d;
  --green-soft: #f0f7f3;
  --green-on-dark: #3FA86A;
  --red: #c94a3e;
  --red-soft: #fbe9e7;
  --blue: #3b5ea5;
  --blue-soft: #eef2f8;
  --finance: #2D5A66;
  --finance-soft: #EEF4F5;
  --ff-body: 'DM Sans', system-ui, -apple-system, Segoe UI, sans-serif;
  --ff-mono: 'DM Sans', ui-sans-serif, system-ui, -apple-system, sans-serif;
  --max-w: 1440px;
  --inner-pad: 32px;
  --ease-smooth: cubic-bezier(0.2, 0.8, 0.2, 1);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --dur-fast: 0.15s;
  --dur-base: 0.3s;
  --dur-slow: 0.7s;
}

/* ============== RESET + BASE ============== */
*, *::before, *::after { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  font-family: var(--ff-body); color: var(--ink); background: var(--paper);
  line-height: 1.5; text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale;
}
a { color: inherit; text-decoration: none; }
button { font-family: inherit; border: 0; background: none; padding: 0; cursor: pointer; }
img, svg { display: block; max-width: 100%; }
ul, ol { margin: 0; padding: 0; list-style: none; }
h1, h2, h3, h4, h5, h6 { margin: 0; line-height: 1.1; font-weight: 600; }
p { margin: 0; }
.visually-hidden { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.wrap { max-width: var(--max-w); margin: 0 auto; padding-left: var(--inner-pad); padding-right: var(--inner-pad); }
main > section { padding: 96px var(--inner-pad); border-bottom: 1px solid var(--line); }
main > section.section-tight   { padding: 80px var(--inner-pad); }

/* ============== TYPE ============== */
.eyebrow { font-size: 15px; font-weight: 500; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent); }
.lede { font-size: 18px; line-height: 1.6; color: var(--muted); }
.h-display { font-size: clamp(48px, 5.2vw, 76px); font-weight: 600; letter-spacing: -0.03em; line-height: 1.05; }
.h-section { font-size: clamp(40px, 4.2vw, 60px); font-weight: 600; letter-spacing: -0.02em; line-height: 1.08; }
.h-section-sm { font-size: clamp(36px, 3.8vw, 52px); font-weight: 600; letter-spacing: -0.02em; line-height: 1.1; }
.h-section-xs { font-size: clamp(32px, 3.4vw, 44px); font-weight: 600; letter-spacing: -0.02em; line-height: 1.12; }
.h-card { font-size: 22px; font-weight: 600; letter-spacing: -0.01em; }
.h-sub { font-size: 20px; font-weight: 600; letter-spacing: -0.01em; }
.mono { font-family: var(--ff-mono); }
.num { font-variant-numeric: tabular-nums; }
em.acc { font-style: normal; color: var(--accent); }

/* ============== BUTTONS ============== */
.btn {
  font-family: inherit; font-size: 16px; font-weight: 500;
  padding: 13px 22px; border: 1px solid transparent; border-radius: 0;
  cursor: pointer; display: inline-flex; align-items: center; justify-content: center;
  gap: 8px; white-space: nowrap; text-decoration: none;
  transition: background var(--dur-fast) var(--ease-smooth),
              color var(--dur-fast) var(--ease-smooth),
              border-color var(--dur-fast) var(--ease-smooth),
              transform var(--dur-fast) var(--ease-smooth),
              box-shadow var(--dur-base) var(--ease-smooth);
}
.btn:hover  { transform: translateY(-1px); }
.btn:active { transform: translateY(0); transition-duration: 0s; }
.btn-accent { background: var(--accent); color: #fff; }
.btn-accent:hover { background: var(--accent-hover); box-shadow: 0 10px 28px -10px rgba(176, 141, 87, 0.55); }
.btn-ink { background: var(--ink); color: #fff; }
.btn-ink:hover { background: var(--ink-2); box-shadow: 0 10px 28px -10px rgba(15, 25, 35, 0.5); }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn-ghost:hover { border-color: var(--ink); background: var(--paper-2); }
.btn-ghost-inv { background: transparent; color: #fff; border-color: rgba(255,255,255,0.25); }
.btn-ghost-inv:hover { border-color: rgba(255,255,255,0.6); background: rgba(255,255,255,0.04); }
.btn-lg { padding: 16px 26px; font-size: 17px; font-weight: 600; }
.link-arrow {
  font-size: 16px; font-weight: 500; color: var(--accent);
  display: inline-flex; align-items: center; gap: 6px;
  transition: gap var(--dur-fast) var(--ease-smooth); text-decoration: none;
}
.link-arrow:hover { gap: 10px; }

/* ============== HEADER (shared chrome) ============== */
.site-header { position: sticky; top: 0; z-index: 100; background: var(--paper); border-bottom: 1px solid var(--line); }
.pulse-dot { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); animation: pulse 2s ease-in-out infinite; flex: none; }
.site-nav { background: var(--paper); }
.site-nav-inner { max-width: var(--max-w); margin: 0 auto; padding: 14px var(--inner-pad); display: flex; align-items: center; justify-content: space-between; }
.site-nav-left { display: flex; align-items: center; gap: 44px; }
.site-nav-right { display: flex; align-items: center; gap: 10px; }
.nav-list { display: flex; align-items: center; gap: 22px; list-style: none; padding: 0; margin: 0; }
.nav-link { font-size: 16.5px; font-weight: 500; color: var(--ink); padding: 8px 4px; transition: color var(--dur-fast); text-decoration: none; }
.nav-link:hover { color: var(--accent); }
.nav-link.is-active { color: var(--accent); }
.nav-signin { font-size: 16px; padding: 8px 12px; color: var(--ink); text-decoration: none; }
.nav-signin:hover { color: var(--accent); }
.nav-cta { padding: 10px 18px; }
.nav-hamburger { display: none; width: 36px; height: 36px; flex-direction: column; justify-content: center; align-items: center; gap: 5px; padding: 0; background: none; border: 0; cursor: pointer; }
.nav-hamburger span { display: block; width: 20px; height: 2px; background: var(--ink); }
.edma-logo { display: inline-flex; align-items: center; gap: 8px; color: var(--ink); font-weight: 700; font-size: 22px; letter-spacing: -0.01em; text-decoration: none; }
.edma-logo .phoenix { height: 34px; width: auto; display: block; max-width: 100%; }

/* ============== SUBNAV (Atlas product nav) ============== */
.subnav { position: sticky; top: 71px; z-index: 90; background: var(--paper); border-bottom: 1px solid var(--line); }
.subnav-inner {
  max-width: var(--max-w); margin: 0 auto; padding: 0 var(--inner-pad);
  display: flex; align-items: center; justify-content: space-between; gap: 24px;
  height: 52px;
}
.subnav-brand { display: flex; align-items: center; gap: 12px; font-family: var(--ff-mono); font-size: 14px; color: var(--muted-2); letter-spacing: 0.06em; text-transform: uppercase; }
.subnav-brand .crumb-mark {
  width: 22px; height: 22px; display: grid; place-items: center;
  background: var(--accent-soft); color: var(--accent); border: 1px solid rgba(176,141,87,0.3);
  font-family: var(--ff-mono); font-size: 14px; font-weight: 500;
}
.subnav-brand .crumb-sep { color: var(--muted-3); }
.subnav-brand .crumb-cur { color: var(--ink); font-weight: 500; }
.subnav-links { display: flex; align-items: center; gap: 4px; font-family: var(--ff-mono); font-size: 14px; }
.subnav-links a { padding: 8px 10px; color: var(--muted-2); letter-spacing: 0.02em; transition: color var(--dur-fast); }
.subnav-links a:hover { color: var(--ink); }
.subnav-links a.is-active { color: var(--accent); }
.subnav-cta { font-size: 15px; color: var(--accent); font-weight: 500; display: inline-flex; align-items: center; gap: 6px; }

/* ============== HERO ============== */
.s-hero { padding-top: 88px; padding-bottom: 56px; }
.s-hero-inner { max-width: 1180px; margin: 0 auto; display: grid; grid-template-columns: 1.15fr 1fr; gap: 80px; align-items: center; }
.s-hero-left .eyebrow { display: inline-block; margin-bottom: 24px; }
.s-hero h1 { margin-bottom: 24px; }
.s-hero .lede { max-width: 560px; margin-bottom: 32px; }
.cta-row { display: inline-flex; gap: 12px; flex-wrap: wrap; }
.s-hero .cta-row { display: flex; }

/* hero side mini-card  */
.hero-card {
  border: 1px solid var(--line);
  background: var(--paper);
  padding: 22px 22px 18px;
  display: flex; flex-direction: column; gap: 14px;
}
.hero-card-top { display: flex; align-items: center; justify-content: space-between; }
.hero-card-channel { display: flex; align-items: center; gap: 10px; font-family: var(--ff-mono); font-size: 13.5px; color: var(--muted-2); letter-spacing: 0.04em; }
.hero-card-channel .ch-glyph { width: 22px; height: 22px; display: grid; place-items: center; background: var(--green-soft); color: var(--green); font-size: 13px; font-family: var(--ff-mono); border: 1px solid rgba(47,122,77,0.18); }
.hero-card-stamp { font-family: var(--ff-mono); font-size: 13px; color: var(--accent); }
.hero-card-thread { display: flex; flex-direction: column; gap: 10px; }

/* hero card — Bot Studio mini prompt/agent */
.hc-prompt {
  border: 1px solid var(--line);
  background: var(--paper-2);
  padding: 12px 14px;
  display: flex; flex-direction: column; gap: 8px;
  position: relative;
}
.hc-prompt::before {
  content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 2px; background: var(--accent);
}
.hc-prompt-label { font-family: var(--ff-mono); font-size: 12.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--muted-2); }
.hc-prompt-body { font-size: 15.5px; line-height: 1.55; color: var(--ink); font-family: var(--ff-mono); }
.hc-acc { color: var(--accent); }
.hc-caret {
  display: inline-block; width: 7px; height: 14px; background: var(--accent);
  margin-left: 3px; vertical-align: -2px; animation: hc-blink 1s steps(2) infinite;
}
@keyframes hc-blink { 50% { opacity: 0; } }
.hc-arrow {
  font-family: var(--ff-mono); font-size: 12.5px; letter-spacing: 0.1em;
  color: var(--accent); text-align: center; padding: 2px 0;
}
.hc-agent {
  border: 1px solid var(--ink); background: var(--ink); color: #fff;
  padding: 12px 14px;
  display: flex; flex-direction: column; gap: 8px;
}
.hc-agent-row { display: flex; align-items: center; gap: 10px; }
.hc-agent-dot { width: 8px; height: 8px; border-radius: 50%; background: var(--green-on-dark); box-shadow: 0 0 0 3px rgba(63,168,106,0.18); flex: none; }
.hc-agent-name { font-size: 15.5px; font-weight: 600; letter-spacing: -0.005em; color: #fff; }
.hc-agent-meta { display: flex; gap: 14px; font-family: var(--ff-mono); font-size: 12.5px; color: rgba(255,255,255,0.55); letter-spacing: 0.04em; }
.hc-agent-ok { color: var(--accent); }

.bubble { padding: 10px 12px; font-size: 15px; line-height: 1.45; max-width: 92%; }
.bubble.from-them { background: var(--paper-2); border: 1px solid var(--line); color: var(--ink); align-self: flex-start; }
.bubble.from-me { background: var(--accent); color: #fff; align-self: flex-end; border: 1px solid var(--accent); }
.bubble.from-atlas { background: var(--ink); color: #fff; align-self: flex-end; border: 1px solid var(--ink); }
.bubble .bubble-meta { display: block; font-family: var(--ff-mono); font-size: 12px; opacity: 0.65; margin-bottom: 4px; letter-spacing: 0.02em; }
.bubble .bubble-meta.dark { color: rgba(255,255,255,0.7); }
.hero-card-foot { display: flex; justify-content: space-between; align-items: center; padding-top: 10px; border-top: 1px dashed var(--line); font-family: var(--ff-mono); font-size: 13px; color: var(--muted-2); }
.hero-card-foot .ok { color: var(--green); }

/* KPI strip */
.kpi-strip {
  max-width: var(--max-w); margin: 64px auto 0;
  display: grid; grid-template-columns: repeat(4, 1fr);
  border-top: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
}
.kpi-cell {
  padding: 22px 22px;
  display: flex; flex-direction: column; gap: 6px; align-items: flex-start;
  text-align: left;
  border-right: 1px solid var(--line);
}
.kpi-cell:last-child { border-right: 0; }
.kpi-label { font-size: 13px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted-2); }
.kpi-val { font-family: var(--ff-mono); font-size: 22px; color: var(--ink); font-weight: 500; letter-spacing: -0.01em; line-height: 1.2; }
.kpi-val .accent { color: var(--accent); }
.kpi-sub { font-family: var(--ff-mono); font-size: 13px; color: var(--muted-2); }

/* ============== CENTERPIECE — PHONE + ANNOTATIONS ============== */
.s-center { background: var(--ink); color: #fff; border-bottom: 0; padding: 96px var(--inner-pad); }
.s-center .s-head { max-width: 1080px; margin: 0 auto 56px; text-align: center; }
.s-center .eyebrow { color: var(--accent); }
.s-center h2 { color: #fff; margin: 16px 0 18px; }
.s-center .lede { color: rgba(255,255,255,0.65); max-width: 760px; margin: 0 auto; }

.cockpit {
  max-width: 1280px; margin: 0 auto;
  display: grid; grid-template-columns: 1.05fr 1fr;
  gap: 56px; align-items: center;
}
.cockpit-left { display: flex; justify-content: center; }
.cockpit-right { display: flex; flex-direction: column; gap: 14px; }

/* Phone frame */
.phone {
  width: 380px; max-width: 100%;
  background: #0a121b;
  border: 1px solid rgba(255,255,255,0.10);
  padding: 14px 14px 18px;
  position: relative;
  display: flex; flex-direction: column;
  box-shadow: 0 30px 80px -30px rgba(0,0,0,0.65),
              0 10px 28px -10px rgba(176,141,87,0.18);
}
.phone-notch {
  width: 100px; height: 6px; background: #000;
  border-radius: 999px;
  margin: 0 auto 12px;
}
.phone-status {
  display: flex; justify-content: space-between; align-items: center;
  font-family: var(--ff-mono); font-size: 12.5px; color: rgba(255,255,255,0.6);
  padding: 0 6px 10px;
  letter-spacing: 0.02em;
}
.phone-status .right { display: flex; gap: 6px; align-items: center; }
.phone-status .signal { display: inline-flex; gap: 2px; align-items: flex-end; }
.phone-status .signal span { display: block; width: 3px; background: rgba(255,255,255,0.55); }
.phone-status .signal span:nth-child(1) { height: 4px; }
.phone-status .signal span:nth-child(2) { height: 6px; }
.phone-status .signal span:nth-child(3) { height: 8px; }
.phone-status .signal span:nth-child(4) { height: 10px; }
.phone-status .batt { width: 18px; height: 9px; border: 1px solid rgba(255,255,255,0.55); position: relative; }
.phone-status .batt::after { content: ''; position: absolute; right: -3px; top: 2px; width: 2px; height: 3px; background: rgba(255,255,255,0.55); }
.phone-status .batt::before { content: ''; position: absolute; left: 1px; top: 1px; bottom: 1px; width: 11px; background: var(--green-on-dark); }

/* Chat header */
.chat-header {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 8px 14px;
  border-bottom: 1px solid rgba(255,255,255,0.08);
}
.chat-avatar {
  width: 36px; height: 36px;
  background: var(--accent-soft); color: var(--accent);
  border: 1px solid rgba(176,141,87,0.3);
  display: grid; place-items: center;
  font-family: var(--ff-mono); font-weight: 500; font-size: 16px;
  flex: none;
}
.chat-id { display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.chat-name { font-size: 15.5px; color: #fff; font-weight: 600; letter-spacing: -0.005em; }
.chat-sub { font-family: var(--ff-mono); font-size: 12.5px; color: rgba(255,255,255,0.5); letter-spacing: 0.02em; }
.chat-meta {
  margin-left: auto; display: flex; align-items: center; gap: 8px;
  font-family: var(--ff-mono); font-size: 12px; color: rgba(255,255,255,0.5);
}
.chat-meta .ch-pill {
  background: rgba(47,122,77,0.18); color: var(--green-on-dark);
  border: 1px solid rgba(47,122,77,0.35);
  padding: 2px 6px; letter-spacing: 0.06em;
}

/* Messages */
.chat-thread {
  display: flex; flex-direction: column; gap: 12px;
  padding: 16px 8px 6px;
  background:
    repeating-linear-gradient(0deg, rgba(255,255,255,0.012) 0 1px, transparent 1px 16px),
    repeating-linear-gradient(90deg, rgba(255,255,255,0.012) 0 1px, transparent 1px 16px);
  min-height: 380px;
}
.msg { max-width: 84%; display: flex; flex-direction: column; gap: 4px; position: relative; }
.msg.them { align-self: flex-start; }
.msg.me   { align-self: flex-end; }
.msg-bubble {
  padding: 10px 12px;
  font-size: 15px; line-height: 1.5;
  border: 1px solid rgba(255,255,255,0.08);
}
.msg.them .msg-bubble { background: rgba(255,255,255,0.05); color: rgba(255,255,255,0.92); }
.msg.me .msg-bubble { background: var(--accent); color: #fff; border-color: var(--accent); }
.msg.me.is-atlas .msg-bubble { background: rgba(176,141,87,0.10); border: 1px solid rgba(176,141,87,0.45); color: #fff; }
.msg-sender { font-family: var(--ff-mono); font-size: 12px; letter-spacing: 0.06em; color: rgba(255,255,255,0.5); display: flex; gap: 8px; align-items: center; }
.msg-sender .me-tag { color: var(--accent); }
.msg .lang-tag {
  font-family: var(--ff-mono); font-size: 12px;
  padding: 2px 6px; background: rgba(255,255,255,0.06);
  border: 1px solid rgba(255,255,255,0.10); color: rgba(255,255,255,0.6);
  letter-spacing: 0.06em; align-self: flex-start;
}
.msg-translation {
  font-size: 14px; line-height: 1.5; color: rgba(255,255,255,0.62);
  padding: 0 2px;
}
.msg-translation::before { content: '↳ '; color: var(--accent); }

.msg-time { font-family: var(--ff-mono); font-size: 11.5px; color: rgba(255,255,255,0.35); padding: 0 2px; }
.msg.me .msg-time { align-self: flex-end; }
.msg.me .msg-time .seen { color: var(--green-on-dark); }

.atlas-card {
  background: rgba(176,141,87,0.10);
  border: 1px solid rgba(176,141,87,0.4);
  padding: 12px;
  display: flex; flex-direction: column; gap: 8px;
}
.atlas-card-head {
  display: flex; align-items: center; justify-content: space-between;
  font-family: var(--ff-mono); font-size: 12px; color: var(--accent);
  letter-spacing: 0.1em;
}
.atlas-card-head .draft { color: rgba(255,255,255,0.55); }
.atlas-card-body { font-size: 15px; line-height: 1.55; color: #fff; }
.atlas-card-tr { font-size: 14px; line-height: 1.55; color: rgba(255,255,255,0.65); padding-top: 6px; border-top: 1px dashed rgba(255,255,255,0.12); }
.atlas-card-actions {
  display: flex; gap: 6px; padding-top: 8px;
}
.atlas-action {
  font-family: var(--ff-mono); font-size: 12.5px;
  padding: 5px 10px; flex: 1; text-align: center;
  letter-spacing: 0.04em;
  border: 1px solid rgba(255,255,255,0.14);
  background: rgba(0,0,0,0.25); color: rgba(255,255,255,0.85);
}
.atlas-action.is-primary { background: var(--accent); color: #fff; border-color: var(--accent); }

/* Composer */
.chat-composer {
  margin-top: 10px;
  display: flex; align-items: center; gap: 8px;
  border: 1px solid rgba(255,255,255,0.10);
  background: rgba(255,255,255,0.03);
  padding: 8px 10px;
}
.chat-composer .ic { width: 18px; height: 18px; border: 1px solid rgba(255,255,255,0.18); }
.chat-composer .input { flex: 1; font-family: var(--ff-mono); font-size: 13px; color: rgba(255,255,255,0.4); }
.chat-composer .send { width: 28px; height: 28px; background: var(--accent); display: grid; place-items: center; color: #fff; font-family: var(--ff-mono); font-size: 13px; }
.phone-bar { width: 100px; height: 4px; background: rgba(255,255,255,0.18); margin: 12px auto 0; border-radius: 999px; }

/* Annotations panel */
.annots { display: flex; flex-direction: column; gap: 12px; }
.annot {
  display: grid; grid-template-columns: 36px 1fr; gap: 16px;
  padding: 18px 20px;
  background: rgba(255,255,255,0.025);
  border: 1px solid rgba(255,255,255,0.08);
  align-items: flex-start;
}
.annot-num {
  font-family: var(--ff-mono); font-size: 13px;
  color: var(--accent); letter-spacing: 0.06em;
  border: 1px solid rgba(176,141,87,0.4);
  width: 32px; height: 32px;
  display: grid; place-items: center;
}
.annot-body { display: flex; flex-direction: column; gap: 6px; }
.annot-title { font-size: 16.5px; font-weight: 600; color: #fff; letter-spacing: -0.005em; }
.annot-desc { font-size: 15px; line-height: 1.55; color: rgba(255,255,255,0.62); }
.annot-desc code { font-family: var(--ff-mono); font-size: 13.5px; color: var(--accent); background: rgba(176,141,87,0.08); padding: 1px 5px; }

/* ========== STUDIO (Bot Studio 3-frame centerpiece) ========== */
.studio { max-width: 1320px; margin: 0 auto; display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 0; }
.studio-col { display: flex; flex-direction: column; gap: 16px; padding: 0 18px; position: relative; }
.studio-col + .studio-col::before {
  content: '→'; position: absolute; left: -10px; top: 30px;
  font-family: var(--ff-mono); font-size: 17px; color: var(--accent);
  width: 20px; height: 20px; display: grid; place-items: center; line-height: 1;
}
.studio-step { font-family: var(--ff-mono); font-size: 13px; letter-spacing: 0.16em; color: var(--accent); display: flex; align-items: center; gap: 12px; padding-bottom: 4px; }
.studio-step .num { width: 26px; height: 26px; border: 1px solid rgba(176,141,87,0.55); display: grid; place-items: center; letter-spacing: 0; }
.studio-card {
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.10);
  padding: 18px; display: flex; flex-direction: column; gap: 14px; flex: 1;
}
.studio-card-head {
  display: flex; align-items: center; justify-content: space-between;
  font-family: var(--ff-mono); font-size: 12.5px; letter-spacing: 0.10em; color: rgba(255,255,255,0.55);
  padding-bottom: 12px; border-bottom: 1px solid rgba(255,255,255,0.08);
}
.studio-card-head .ok { color: var(--green-on-dark); }
.studio-card-head .draft { color: var(--accent); }
.studio-caption { font-family: var(--ff-mono); font-size: 13.5px; color: rgba(255,255,255,0.5); letter-spacing: 0.02em; }

/* DESCRIBE */
.sd-input { background: rgba(0,0,0,0.25); border: 1px solid rgba(176,141,87,0.35); padding: 14px; min-height: 196px; display: flex; flex-direction: column; gap: 12px; position: relative; }
.sd-input::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 2px; background: var(--accent); }
.sd-input-label { font-family: var(--ff-mono); font-size: 12.5px; letter-spacing: 0.08em; color: var(--accent); text-transform: uppercase; }
.sd-input-body { font-size: 16px; line-height: 1.6; color: rgba(255,255,255,0.92); font-family: var(--ff-mono); }
.sd-input-body .em { color: var(--accent); }
.sd-caret { display: inline-block; width: 7px; height: 14px; background: var(--accent); vertical-align: -2px; margin-left: 3px; animation: hc-blink 1s steps(2) infinite; }
.sd-tools { display: flex; gap: 6px; flex-wrap: wrap; }
.sd-tool { font-family: var(--ff-mono); font-size: 12.5px; padding: 5px 9px; border: 1px solid rgba(255,255,255,0.12); color: rgba(255,255,255,0.7); background: rgba(255,255,255,0.02); }
.sd-build { margin-top: auto; background: var(--accent); color: #fff; padding: 12px 14px; font-size: 15px; font-weight: 600; letter-spacing: 0.02em; display: flex; align-items: center; justify-content: space-between; }
.sd-build .ks { font-family: var(--ff-mono); font-size: 12.5px; opacity: 0.7; font-weight: 400; }

/* CONFIGURE */
.sc-title { font-size: 16px; font-weight: 600; color: #fff; letter-spacing: -0.005em; }
.sc-rows { display: flex; flex-direction: column; }
.sc-row { display: grid; grid-template-columns: 78px 1fr; padding: 9px 0; gap: 12px; border-bottom: 1px dashed rgba(255,255,255,0.08); align-items: baseline; }
.sc-row:last-child { border-bottom: 0; padding-bottom: 0; }
.sc-row:first-child { padding-top: 0; }
.sc-key { font-family: var(--ff-mono); font-size: 12px; letter-spacing: 0.14em; color: var(--accent); text-transform: uppercase; padding-top: 3px; }
.sc-val { font-size: 15px; line-height: 1.5; color: rgba(255,255,255,0.92); display: flex; flex-direction: column; gap: 5px; }
.sc-val .src { font-family: var(--ff-mono); font-size: 12.5px; color: rgba(255,255,255,0.4); letter-spacing: 0.02em; }
.sc-val .src .lbl { color: var(--accent); }
.sc-chips { display: flex; flex-wrap: wrap; gap: 4px; margin-top: 2px; }
.sc-chip { font-family: var(--ff-mono); font-size: 12.5px; padding: 3px 7px; border: 1px solid rgba(255,255,255,0.14); color: rgba(255,255,255,0.78); background: rgba(0,0,0,0.18); }

/* DEPLOY */
.sp-head { display: flex; align-items: center; gap: 10px; }
.sp-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--green-on-dark); box-shadow: 0 0 0 4px rgba(63,168,106,0.18); flex: none; animation: pulse 2s ease-in-out infinite; }
.sp-name { font-size: 16px; font-weight: 600; color: #fff; letter-spacing: -0.005em; flex: 1; }
.sp-meta { display: grid; grid-template-columns: 1fr 1fr; gap: 0; padding: 8px 0 12px; border-bottom: 1px dashed rgba(255,255,255,0.08); }
.sp-meta > div { display: flex; flex-direction: column; gap: 4px; padding-right: 12px; border-right: 1px dashed rgba(255,255,255,0.08); }
.sp-meta > div:last-child { border-right: 0; padding-left: 12px; padding-right: 0; }
.sp-meta .lbl { font-family: var(--ff-mono); font-size: 11.5px; letter-spacing: 0.12em; color: rgba(255,255,255,0.45); }
.sp-meta .v { font-family: var(--ff-mono); font-size: 16px; color: #fff; letter-spacing: -0.005em; }
.sp-log-title { font-family: var(--ff-mono); font-size: 12px; letter-spacing: 0.14em; color: rgba(255,255,255,0.45); padding-top: 2px; }
.sp-log { display: flex; flex-direction: column; gap: 8px; }
.sp-log-row { font-family: var(--ff-mono); font-size: 13.5px; color: rgba(255,255,255,0.85); display: grid; grid-template-columns: 64px 1fr 48px; gap: 8px; align-items: baseline; }
.sp-log-row .ts { color: rgba(255,255,255,0.4); }
.sp-log-row .tag { font-size: 12px; letter-spacing: 0.10em; text-transform: uppercase; color: var(--accent); text-align: right; }
.sp-log-row .tag.ok { color: var(--green-on-dark); }
.sp-log-row.is-quiet { opacity: 0.55; }
.sp-audit { margin-top: auto; display: flex; justify-content: space-between; align-items: center; padding-top: 12px; border-top: 1px solid rgba(255,255,255,0.08); font-family: var(--ff-mono); font-size: 12.5px; color: rgba(255,255,255,0.5); }
.sp-audit .export { color: var(--accent); }

.studio-tag { max-width: 880px; margin: 40px auto 0; text-align: center; font-family: var(--ff-mono); font-size: 14px; letter-spacing: 0.04em; color: rgba(255,255,255,0.55); }
.studio-tag em { font-style: normal; color: var(--accent); }

@media (max-width: 1180px) {
  .studio { grid-template-columns: 1fr; gap: 28px; }
  .studio-col { padding: 0; }
  .studio-col + .studio-col::before { display: none; }
}

/* ============== PROBLEMS ============== */
.s-problems .s-head { max-width: var(--max-w); margin: 0 auto 56px; }
.s-problems .s-head h2 { max-width: 920px; margin-bottom: 14px; }
.s-problems .s-head .lede { max-width: 760px; }
.prob-grid { max-width: var(--max-w); margin: 0 auto; display: grid; grid-template-columns: repeat(3, 1fr); gap: 0; border: 1px solid var(--line); }
.prob-card { padding: 32px; border-right: 1px solid var(--line); background: var(--paper); display: flex; flex-direction: column; gap: 14px; }
.prob-card:last-child { border-right: 0; }
.prob-num { font-family: var(--ff-mono); font-size: 13px; color: var(--muted-2); letter-spacing: 0.14em; }
.prob-h { font-size: 22px; font-weight: 600; color: var(--ink); letter-spacing: -0.01em; line-height: 1.25; }
.prob-card p { font-size: 16.5px; line-height: 1.65; color: var(--muted); }
.prob-cost {
  margin-top: auto; padding-top: 16px; border-top: 1px dashed var(--line);
  display: flex; align-items: baseline; justify-content: space-between;
}
.prob-cost-val { font-family: var(--ff-mono); font-size: 21px; color: var(--ink); font-weight: 500; letter-spacing: -0.01em; }
.prob-cost-lbl { font-family: var(--ff-mono); font-size: 13px; color: var(--muted-2); letter-spacing: 0.12em; text-transform: uppercase; }

/* ============== PATTERNS (5) ============== */
.s-patterns { background: var(--paper-2); }
.s-patterns .s-head { max-width: var(--max-w); margin: 0 auto 56px; }
.s-patterns .s-head h2 { max-width: 880px; margin-bottom: 14px; }
.patt-grid {
  max-width: var(--max-w); margin: 0 auto;
  display: grid; grid-template-columns: repeat(6, 1fr); gap: 0;
  border: 1px solid var(--line); background: var(--paper);
}
/* row 1: 3 cards spanning 2 each. row 2: 2 cards spanning 3 each */
.patt-card { padding: 32px; border-right: 1px solid var(--line); border-bottom: 1px solid var(--line); display: flex; flex-direction: column; gap: 14px; }
.patt-card:nth-child(1), .patt-card:nth-child(2), .patt-card:nth-child(3) { grid-column: span 2; }
.patt-card:nth-child(4), .patt-card:nth-child(5) { grid-column: span 3; border-bottom: 0; }
.patt-card:nth-child(3) { border-right: 0; }
.patt-card:nth-child(5) { border-right: 0; }
.patt-mark {
  width: 40px; height: 40px;
  display: grid; place-items: center;
  background: var(--accent-soft); color: var(--accent);
  border: 1px solid rgba(176,141,87,0.3);
  font-family: var(--ff-mono); font-size: 17px; font-weight: 500;
}
.patt-h { font-size: 21px; font-weight: 600; color: var(--ink); letter-spacing: -0.01em; }
.patt-card p { font-size: 16.5px; line-height: 1.6; color: var(--muted); }
.patt-card p strong { color: var(--ink); font-weight: 600; }
.patt-eg {
  margin-top: auto;
  font-family: var(--ff-mono); font-size: 13.5px; color: var(--muted-2);
  background: var(--paper-2); border: 1px solid var(--line);
  padding: 10px 12px;
}
.patt-eg .you { color: var(--accent); }
.patt-eg .atlas { color: var(--ink); }

/* ============== MOAT GRAPH ============== */
.s-moat-atlas { background: var(--ink); color: #fff; border-bottom: 0; }
.s-moat-atlas .s-head { max-width: 1080px; margin: 0 auto 48px; text-align: center; }
.s-moat-atlas .eyebrow { color: var(--accent); }
.s-moat-atlas h2 { color: #fff; margin: 16px 0 18px; }
.s-moat-atlas .lede { color: rgba(255,255,255,0.65); max-width: 760px; margin: 0 auto; }

.moat-frame {
  max-width: 1180px; margin: 0 auto;
  border: 1px solid rgba(255,255,255,0.08);
  padding: 32px;
  display: grid; grid-template-columns: 1.4fr 1fr; gap: 32px;
}
.moat-canvas {
  height: 460px; position: relative;
  border: 1px dashed rgba(255,255,255,0.08);
  background:
    radial-gradient(circle at 50% 50%, rgba(176,141,87,0.10) 0%, rgba(176,141,87,0) 50%),
    repeating-linear-gradient(0deg, rgba(255,255,255,0.025) 0 1px, transparent 1px 56px),
    repeating-linear-gradient(90deg, rgba(255,255,255,0.025) 0 1px, transparent 1px 56px);
}
.moat-svg { position: absolute; inset: 0; width: 100%; height: 100%; }
.moat-core {
  position: absolute; top: 50%; left: 50%; transform: translate(-50%,-50%);
  width: 150px; height: 150px;
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  background: radial-gradient(circle at 50% 50%, rgba(176,141,87,0.25), rgba(176,141,87,0) 65%);
  text-align: center; pointer-events: none;
}
.moat-core-inner {
  width: 110px; height: 110px;
  border: 1px solid rgba(176,141,87,0.6);
  background: rgba(176,141,87,0.10);
  display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 2px;
}
.moat-core-inner .e { font-size: 11px; letter-spacing: 0.18em; color: var(--accent); font-weight: 600; }
.moat-core-inner .t { font-family: var(--ff-mono); font-size: 17px; color: #fff; letter-spacing: 0.02em; }
.moat-core-inner .s { font-family: var(--ff-mono); font-size: 11.5px; color: rgba(255,255,255,0.5); margin-top: 3px; }
.moat-node {
  position: absolute;
  display: inline-flex; align-items: center; gap: 8px;
  padding: 7px 11px;
  background: rgba(15,25,35,0.92);
  border: 1px solid rgba(255,255,255,0.14);
  font-family: var(--ff-mono); font-size: 13px;
  color: #fff; letter-spacing: 0.02em;
  white-space: nowrap;
}
.moat-node .nd { width: 6px; height: 6px; border-radius: 50%; background: var(--accent); flex: none; }
.moat-node .nc { color: rgba(255,255,255,0.5); font-size: 12.5px; }

.moat-cards { display: flex; flex-direction: column; gap: 12px; }
.moat-explainer {
  background: rgba(255,255,255,0.02);
  border: 1px solid rgba(255,255,255,0.08);
  padding: 18px 20px;
  display: flex; flex-direction: column; gap: 8px;
}
.moat-explainer h4 { font-size: 16px; font-weight: 600; color: #fff; letter-spacing: -0.005em; display: flex; align-items: center; gap: 10px; }
.moat-explainer h4::before { content: ''; width: 6px; height: 6px; background: var(--accent); flex: none; }
.moat-explainer p { font-size: 15px; line-height: 1.55; color: rgba(255,255,255,0.65); }
.moat-explainer p strong { color: #fff; font-weight: 600; }

/* ========== MOAT TRIO (Bot Studio comparison) ========== */
.moat-trio { display: grid; grid-template-columns: 1fr 1fr 1fr; gap: 0; max-width: 1180px; margin: 0 auto; border: 1px solid rgba(255,255,255,0.08); }
.trio-card {
  padding: 30px 28px;
  border-right: 1px solid rgba(255,255,255,0.08);
  display: flex; flex-direction: column; gap: 16px;
  background: rgba(255,255,255,0.015);
  position: relative;
}
.trio-card:last-child { border-right: 0; }
.trio-card.is-edma { background: rgba(176,141,87,0.06); }
.trio-card.is-edma::before {
  content: ''; position: absolute; left: 0; right: 0; top: -1px; height: 2px; background: var(--accent);
}
.trio-label { font-family: var(--ff-mono); font-size: 12.5px; letter-spacing: 0.14em; color: rgba(255,255,255,0.5); text-transform: uppercase; }
.trio-card.is-edma .trio-label { color: var(--accent); }
.trio-stat { display: flex; flex-direction: column; gap: 4px; padding: 0 0 16px; border-bottom: 1px solid rgba(255,255,255,0.08); }
.trio-stat-val { font-family: var(--ff-mono); font-size: 30px; color: #fff; letter-spacing: -0.01em; font-weight: 500; line-height: 1; }
.trio-card.is-edma .trio-stat-val { color: var(--accent); }
.trio-stat-lbl { font-family: var(--ff-mono); font-size: 12.5px; letter-spacing: 0.12em; color: rgba(255,255,255,0.4); text-transform: uppercase; }
.trio-title { font-size: 20px; font-weight: 600; color: #fff; letter-spacing: -0.01em; line-height: 1.3; }
.trio-list { display: flex; flex-direction: column; gap: 10px; }
.trio-row { display: grid; grid-template-columns: 16px 1fr; gap: 10px; font-size: 15.5px; line-height: 1.55; color: rgba(255,255,255,0.78); align-items: baseline; }
.trio-row .mk { font-family: var(--ff-mono); font-size: 15px; color: rgba(255,255,255,0.3); line-height: 1; text-align: center; }
.trio-row.is-yes .mk { color: var(--accent); }
.trio-row strong { color: #fff; font-weight: 600; }
.trio-foot { margin-top: auto; padding-top: 16px; border-top: 1px dashed rgba(255,255,255,0.10); font-family: var(--ff-mono); font-size: 13px; color: rgba(255,255,255,0.55); letter-spacing: 0.02em; }
.trio-card.is-edma .trio-foot { color: var(--accent); }

@media (max-width: 980px) {
  .moat-trio { grid-template-columns: 1fr; }
  .trio-card { border-right: 0; border-bottom: 1px solid rgba(255,255,255,0.08); }
  .trio-card:last-child { border-bottom: 0; }
}

/* ============== GALLERY ============== */
.s-gallery .s-head { max-width: var(--max-w); margin: 0 auto 48px; }
.s-gallery .s-head h2 { max-width: 880px; margin-bottom: 14px; }
.gallery-grid { max-width: var(--max-w); margin: 0 auto; display: grid; grid-template-columns: repeat(4, 1fr); gap: 0; border: 1px solid var(--line); }
.gal-card {
  padding: 24px;
  background: var(--paper);
  border-right: 1px solid var(--line);
  border-bottom: 1px solid var(--line);
  display: flex; flex-direction: column; gap: 14px;
}
.gal-card:nth-child(4n) { border-right: 0; }
.gal-card:nth-last-child(-n+4) { border-bottom: 0; }
.gal-chan {
  display: flex; align-items: center; justify-content: space-between;
  font-family: var(--ff-mono); font-size: 12.5px; letter-spacing: 0.12em;
  text-transform: uppercase; color: var(--muted-2);
}
.gal-chan .lang { color: var(--accent); }
.gal-q { font-size: 16px; font-weight: 600; line-height: 1.5; color: var(--ink); letter-spacing: -0.005em; }
.gal-q::before { content: '"'; color: var(--muted-3); }
.gal-q::after { content: '"'; color: var(--muted-3); }
.gal-arrow { font-family: var(--ff-mono); font-size: 13px; color: var(--accent); letter-spacing: 0.06em; }
.gal-a {
  font-family: var(--ff-mono); font-size: 14px; line-height: 1.55;
  color: var(--ink); padding: 10px 12px;
  background: var(--paper-2); border: 1px solid var(--line);
  position: relative;
}
.gal-a .acc { color: var(--accent); }
.gal-a .ok { color: var(--green); }
.gal-a .warn { color: var(--red); }
.gal-foot { font-family: var(--ff-mono); font-size: 12.5px; color: var(--muted-3); display: flex; justify-content: space-between; padding-top: 4px; margin-top: auto; border-top: 1px dashed var(--line); padding-top: 10px; }

/* ========== AGENT GALLERY (Bot Studio sample agents) ========== */
.agent-grid { max-width: var(--max-w); margin: 0 auto; display: grid; grid-template-columns: repeat(5, 1fr); gap: 0; border: 1px solid var(--line); background: var(--paper); }
.agent-card { padding: 26px 22px; border-right: 1px solid var(--line); display: flex; flex-direction: column; gap: 14px; min-height: 360px; }
.agent-card:last-child { border-right: 0; }
.agent-card-head { display: flex; align-items: center; justify-content: space-between; gap: 8px; }
.agent-stat-dot { display: flex; align-items: center; gap: 7px; font-family: var(--ff-mono); font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--green); }
.agent-stat-dot .d { width: 7px; height: 7px; border-radius: 50%; background: var(--green); animation: pulse 2s ease-in-out infinite; flex: none; }
.agent-id { font-family: var(--ff-mono); font-size: 12px; letter-spacing: 0.08em; color: var(--muted-3); }
.agent-name { font-size: 17px; font-weight: 600; color: var(--ink); letter-spacing: -0.01em; line-height: 1.3; }
.agent-desc { font-size: 15px; line-height: 1.55; color: var(--muted); font-family: var(--ff-mono); padding: 10px 12px; background: var(--paper-2); border: 1px solid var(--line); position: relative; }
.agent-desc::before { content: ''; position: absolute; left: 0; top: 0; bottom: 0; width: 2px; background: var(--accent); }
.agent-desc .em { color: var(--accent); }
.agent-meta { display: flex; flex-direction: column; gap: 8px; font-family: var(--ff-mono); font-size: 13px; color: var(--muted-2); }
.agent-meta-row { display: flex; justify-content: space-between; align-items: baseline; gap: 8px; }
.agent-meta-row .lbl { color: var(--muted-3); letter-spacing: 0.06em; text-transform: uppercase; font-size: 12px; }
.agent-meta-row .v { color: var(--ink); }
.agent-foot { margin-top: auto; padding-top: 14px; border-top: 1px dashed var(--line); display: flex; flex-direction: column; gap: 6px; }
.agent-usage { font-family: var(--ff-mono); font-size: 14px; display: flex; align-items: baseline; gap: 8px; }
.agent-usage .pct { color: var(--accent); font-size: 19px; font-weight: 500; letter-spacing: -0.005em; }
.agent-usage .lbl { color: var(--muted-2); font-size: 13.5px; }
.agent-deploy { font-family: var(--ff-mono); font-size: 13px; color: var(--accent); letter-spacing: 0.04em; }

@media (max-width: 1180px) {
  .agent-grid { grid-template-columns: repeat(2, 1fr); }
  .agent-card { border-bottom: 1px solid var(--line); }
  .agent-card:nth-child(2n) { border-right: 0; }
  .agent-card:nth-last-child(-n+2):nth-child(odd) { border-bottom: 0; }
  .agent-card:nth-last-child(1) { grid-column: 1 / -1; }
  .agent-card:nth-last-child(1) { border-right: 0; border-bottom: 0; }
}
@media (max-width: 720px) {
  .agent-grid { grid-template-columns: 1fr; }
  .agent-card { border-right: 0; }
  .agent-card:nth-last-child(1) { grid-column: auto; }
}

/* ============== CHANNEL MATRIX ============== */
.s-channels { background: var(--paper-2); }
.s-channels .s-head { max-width: var(--max-w); margin: 0 auto 48px; }
.s-channels .s-head h2 { max-width: 880px; margin-bottom: 14px; }
.ch-grid { max-width: var(--max-w); margin: 0 auto; border: 1px solid var(--line); background: var(--paper); }
.ch-row {
  display: grid; grid-template-columns: 180px 1fr 1.2fr 200px;
  border-bottom: 1px solid var(--line);
  align-items: stretch;
}
.ch-row:last-child { border-bottom: 0; }
.ch-row.is-head { background: var(--paper-2); }
.ch-cell { padding: 18px 22px; border-right: 1px solid var(--line); display: flex; flex-direction: column; gap: 4px; }
.ch-cell:last-child { border-right: 0; }
.ch-row.is-head .ch-cell { padding: 16px 22px; font-family: var(--ff-mono); font-size: 13px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted-2); }
.ch-name { display: flex; align-items: center; gap: 12px; font-weight: 600; font-size: 17px; color: var(--ink); letter-spacing: -0.005em; }
.ch-glyph {
  width: 28px; height: 28px; display: grid; place-items: center;
  background: var(--paper-2); border: 1px solid var(--line);
  font-family: var(--ff-mono); font-size: 13px; color: var(--muted);
  flex: none;
}
.ch-row.is-wa .ch-glyph { background: var(--green-soft); color: var(--green); border-color: rgba(47,122,77,0.2); }
.ch-row.is-tg .ch-glyph { background: var(--blue-soft); color: var(--blue); border-color: rgba(59,94,165,0.2); }
.ch-row.is-em .ch-glyph { background: var(--accent-soft); color: var(--accent); border-color: rgba(176,141,87,0.3); }
.ch-row.is-sl .ch-glyph { background: #f0eef5; color: #5b4d9b; border-color: rgba(91,77,155,0.2); }
.ch-row.is-os .ch-glyph { background: var(--ink); color: var(--accent); border-color: var(--ink); }
.ch-trigger { font-family: var(--ff-mono); font-size: 15px; color: var(--ink); }
.ch-response { font-size: 15.5px; line-height: 1.5; color: var(--muted); }
.ch-status { display: flex; align-items: center; gap: 8px; font-family: var(--ff-mono); font-size: 14px; color: var(--green); }
.ch-status .dot { width: 6px; height: 6px; border-radius: 50%; background: var(--green); }
.ch-status.beta { color: var(--accent); }
.ch-status.beta .dot { background: var(--accent); }

/* ========== LIBRARY BAND (Automation library connection) ========== */
.lib-band { max-width: var(--max-w); margin: 0 auto; display: grid; grid-template-columns: 1.6fr 1fr; gap: 0; border: 1px solid var(--line); background: var(--paper); }
.lib-cats { padding: 32px; display: grid; grid-template-columns: 1fr 1fr; gap: 28px; border-right: 1px solid var(--line); }
.lib-cat { display: flex; flex-direction: column; gap: 12px; }
.lib-cat-h { font-family: var(--ff-mono); font-size: 12.5px; letter-spacing: 0.14em; color: var(--muted-2); text-transform: uppercase; font-weight: 500; }
.lib-chips { display: flex; flex-wrap: wrap; gap: 6px; }
.lib-chip { font-size: 14.5px; padding: 6px 10px; border: 1px solid var(--line); color: var(--ink); background: var(--paper-2); font-family: var(--ff-mono); }
.lib-chip.is-more { color: var(--muted-2); background: transparent; }
.lib-cta { padding: 36px 32px; display: flex; flex-direction: column; gap: 14px; justify-content: center; background: var(--accent-soft-2); }
.lib-cta-num { font-family: var(--ff-mono); font-size: 56px; font-weight: 500; letter-spacing: -0.02em; color: var(--ink); line-height: 1; }
.lib-cta-num .acc { color: var(--accent); }
.lib-cta-lbl { font-family: var(--ff-mono); font-size: 13px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted-2); margin-bottom: 4px; }
.lib-cta-note { font-size: 14px; color: var(--muted); font-family: var(--ff-mono); }
.lib-cta .btn { align-self: flex-start; }

@media (max-width: 1180px) {
  .lib-band { grid-template-columns: 1fr; }
  .lib-cats { border-right: 0; border-bottom: 1px solid var(--line); }
}
@media (max-width: 720px) {
  .lib-cats { grid-template-columns: 1fr; }
}

/* arch-grid override for 3-column guardrails layout */
.arch-grid.is-three { grid-template-columns: repeat(3, 1fr); }
.arch-grid.is-three .arch-cell { padding: 28px; gap: 14px; }
.arch-h-trio { font-size: 19px; font-weight: 600; color: #fff; letter-spacing: -0.005em; }
.arch-cell .ard-list { display: flex; flex-direction: column; gap: 6px; padding-top: 8px; border-top: 1px dashed rgba(255,255,255,0.08); margin-top: 4px; }
.arch-cell .ard-list span { font-family: var(--ff-mono); font-size: 13.5px; color: rgba(255,255,255,0.65); display: flex; gap: 8px; align-items: baseline; }
.arch-cell .ard-list span::before { content: '·'; color: var(--accent); }

@media (max-width: 980px) {
  .arch-grid.is-three { grid-template-columns: 1fr; }
}

/* ============== ARCHITECTURE STRIP ============== */
.s-arch { background: var(--ink); color: #fff; border-bottom: 0; }
.s-arch .s-head { max-width: 1080px; margin: 0 auto 48px; }
.s-arch .eyebrow { color: var(--accent); }
.s-arch h2 { color: #fff; margin: 16px 0 18px; max-width: 720px; }
.s-arch .lede { color: rgba(255,255,255,0.65); max-width: 720px; }
.arch-grid { max-width: var(--max-w); margin: 0 auto; display: grid; grid-template-columns: repeat(5, 1fr); gap: 0; border: 1px solid rgba(255,255,255,0.08); }
.arch-cell {
  padding: 22px;
  border-right: 1px solid rgba(255,255,255,0.08);
  display: flex; flex-direction: column; gap: 12px;
  background: rgba(255,255,255,0.015);
}
.arch-cell:last-child { border-right: 0; }
.arch-num { font-family: var(--ff-mono); font-size: 12.5px; color: var(--accent); letter-spacing: 0.12em; }
.arch-h { font-size: 17px; font-weight: 600; color: #fff; letter-spacing: -0.005em; }
.arch-cell p { font-size: 15px; line-height: 1.55; color: rgba(255,255,255,0.65); }
.arch-cell p strong { color: #fff; font-weight: 600; }
.arch-cell .mono { color: var(--accent); }

/* ============== COMPARE ============== */
.s-compare .s-head { max-width: var(--max-w); margin: 0 auto 48px; }
.s-compare .s-head h2 { max-width: 900px; margin-bottom: 14px; }
.cmp-wrap { max-width: var(--max-w); margin: 0 auto; overflow-x: auto; border: 1px solid var(--line); }
.cmp-table { width: 100%; border-collapse: collapse; font-size: 16px; min-width: 1000px; }
.cmp-table thead th {
  text-align: left; padding: 18px 16px;
  border-bottom: 1px solid var(--line);
  font-size: 13.5px; font-weight: 600; letter-spacing: 0.1em;
  text-transform: uppercase; color: var(--muted-2);
  background: var(--paper-2); vertical-align: bottom;
  white-space: nowrap;
}
.cmp-table thead th.is-edma { color: var(--accent); background: var(--accent-soft); border-bottom-color: var(--accent); }
.cmp-table tbody td { padding: 16px; border-bottom: 1px solid var(--line-2); vertical-align: middle; text-align: center; }
.cmp-table tbody td.cmp-cap { text-align: left; font-weight: 500; color: var(--ink); }
.cmp-table tbody tr:last-child td { border-bottom: 0; }
.cmp-table tbody td.is-edma { border-left: 2px solid var(--accent); background: var(--accent-soft-2); }
.cmp-yes { color: var(--accent); font-weight: 600; }
.cmp-partial { color: var(--muted); font-style: italic; font-size: 14px; }
.cmp-no { color: var(--muted-3); }

/* ============== FAQ ============== */
.s-faq { background: var(--paper-2); }
.s-faq-inner { max-width: var(--max-w); margin: 0 auto; display: grid; grid-template-columns: 1fr 1.6fr; gap: 80px; align-items: start; }
.s-faq h2 { margin-bottom: 16px; }
.s-faq .lede { max-width: 360px; }
.faq-item { padding: 24px 0; border-bottom: 1px solid var(--line-2); }
.faq-item:first-child { padding-top: 0; }
.faq-item:last-child { border-bottom: 0; }
.faq-q { font-size: 20px; font-weight: 600; color: var(--ink); margin-bottom: 12px; letter-spacing: -0.01em; }
.faq-a { font-size: 17.5px; line-height: 1.7; color: var(--muted); }
.faq-a a { color: var(--accent); border-bottom: 1px solid rgba(176,141,87,0.35); }
.faq-a strong { color: var(--ink); font-weight: 600; }

/* ============== CTA ============== */
.s-cta { background: var(--ink); color: #fff; border-bottom: 0; }
.s-cta-inner { max-width: 920px; margin: 0 auto; text-align: center; }
.s-cta h2 { color: #fff; margin-bottom: 18px; }
.s-cta p { color: rgba(255,255,255,0.7); font-size: 18px; line-height: 1.6; margin-bottom: 32px; }
.s-cta .cta-row { justify-content: center; }
.s-cta .link-arrow { color: var(--accent); margin-top: 22px; display: inline-flex; }

/* ============== RELATED ============== */
.s-related-inner { max-width: var(--max-w); margin: 0 auto; }
.s-related h3 { margin-bottom: 32px; font-size: 15px; font-weight: 500; letter-spacing: 0.12em; text-transform: uppercase; color: var(--muted-2); }
.related-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.related-card { background: var(--paper); border: 1px solid var(--line); padding: 28px; transition: border-color var(--dur-base) var(--ease-smooth), transform var(--dur-base) var(--ease-smooth); display: flex; flex-direction: column; gap: 12px; }
.related-card:hover { border-color: var(--ink); transform: translateY(-2px); }
.related-card-eyebrow { font-size: 13px; font-weight: 600; letter-spacing: 0.12em; text-transform: uppercase; color: var(--accent); }
.related-card-title { font-size: 22px; font-weight: 600; letter-spacing: -0.01em; color: var(--ink); }
.related-card-desc { font-size: 16px; color: var(--muted); line-height: 1.55; }
.related-card-link { color: var(--accent); font-size: 15.5px; font-weight: 500; margin-top: auto; padding-top: 8px; }

/* ============== FOOTER ============== */
.site-footer { background: var(--ink); color: #fff; }
.footer-top { border-bottom: 1px solid rgba(255,255,255,0.08); }
.footer-top-inner { max-width: var(--max-w); margin: 0 auto; padding: 48px var(--inner-pad); display: grid; grid-template-columns: 1.4fr 1fr; gap: 64px; align-items: start; }
.edma-logo--footer .phoenix { height: 40px; }
.edma-logo--footer .edma-wordmark { font-size: 26px; color: #fff; }
.edma-logo--footer { color: #fff; }
.footer-brand-tag { color: rgba(255,255,255,0.55); font-size: 16px; line-height: 1.55; margin-top: 14px; max-width: 480px; }
.footer-newsletter-title { color: #fff; font-size: 15px; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; margin-bottom: 6px; }
.footer-newsletter-sub { color: rgba(255,255,255,0.55); font-size: 15px; margin-bottom: 14px; }
.footer-newsletter { display: flex; gap: 8px; }
.footer-newsletter input { flex: 1; padding: 12px 14px; background: rgba(255,255,255,0.04); border: 1px solid rgba(255,255,255,0.12); color: #fff; font-family: inherit; font-size: 15px; outline: none; }
.footer-newsletter input::placeholder { color: rgba(255,255,255,0.35); }
.footer-newsletter input:focus { border-color: var(--accent); }
.footer-newsletter button { padding: 12px 18px; background: var(--accent); color: #fff; font-family: inherit; font-size: 15px; font-weight: 500; border: 0; cursor: pointer; }
.footer-newsletter button:hover { background: var(--accent-hover); }
.footer-links { max-width: var(--max-w); margin: 0 auto; padding: 56px var(--inner-pad); display: grid; grid-template-columns: repeat(6, 1fr); gap: 32px; border-bottom: 1px solid rgba(255,255,255,0.08); }
.footer-col-title { font-size: 14px; font-weight: 600; letter-spacing: 0.1em; text-transform: uppercase; color: var(--accent); margin-bottom: 16px; }
.footer-link-list li { padding: 4px 0; }
.footer-link-list a { font-size: 15px; color: rgba(255,255,255,0.65); transition: color var(--dur-fast); }
.footer-link-list a:hover { color: #fff; }
.footer-legal-inner { max-width: var(--max-w); margin: 0 auto; padding: 18px var(--inner-pad); display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; font-size: 14px; color: rgba(255,255,255,0.45); }
.footer-legal-inner .links { display: flex; gap: 18px; flex-wrap: wrap; }
.footer-legal-inner .links a:hover { color: #fff; }
.footer-legal-inner .status-ok { color: var(--green-on-dark); }

/* ============== RESPONSIVE ============== */
@media (max-width: 1180px) {
  .s-hero-inner { grid-template-columns: 1fr; gap: 48px; }
  .gallery-grid { grid-template-columns: repeat(2, 1fr); }
  .gal-card:nth-child(4n) { border-right: 1px solid var(--line); }
  .gal-card:nth-child(2n) { border-right: 0; }
  .gal-card:nth-last-child(-n+4) { border-bottom: 1px solid var(--line); }
  .gal-card:nth-last-child(-n+2) { border-bottom: 0; }
  .cockpit { grid-template-columns: 1fr; gap: 32px; }
  .moat-frame { grid-template-columns: 1fr; }
  .arch-grid { grid-template-columns: repeat(2, 1fr); }
  .arch-cell { border-bottom: 1px solid rgba(255,255,255,0.08); }
  .arch-cell:nth-child(2n) { border-right: 0; }
  .arch-cell:last-child { border-bottom: 0; }
}
@media (max-width: 980px) {
  .s-faq-inner { grid-template-columns: 1fr; gap: 32px; }
  .prob-grid { grid-template-columns: 1fr; }
  .prob-card { border-right: 0; border-bottom: 1px solid var(--line); }
  .prob-card:last-child { border-bottom: 0; }
  .patt-grid { grid-template-columns: 1fr; }
  .patt-card { grid-column: span 1 !important; border-right: 0 !important; border-bottom: 1px solid var(--line) !important; }
  .patt-card:last-child { border-bottom: 0 !important; }
  .related-grid { grid-template-columns: 1fr; }
  .footer-links { grid-template-columns: repeat(3, 1fr); }
  .footer-top-inner { grid-template-columns: 1fr; gap: 32px; }
  .ch-row { grid-template-columns: 140px 1fr 1.2fr 130px; }
}
@media (max-width: 768px) {
  :root { --inner-pad: 20px; }
  main > section { padding: 56px 20px; }
  .nav-list, .nav-signin, .nav-link-pricing { display: none; }
  .nav-cta { display: inline-flex; font-size: 14px; padding: 8px 14px; }
  .nav-hamburger { display: flex; }
  .subnav-links { display: none; }
  .kpi-strip { grid-template-columns: repeat(2, 1fr); }
  .kpi-cell:nth-child(2n) { border-right: 0; }
  .kpi-cell { border-bottom: 1px solid var(--line); }
  .kpi-cell:nth-last-child(-n+1) { border-bottom: 0; }
  .gallery-grid { grid-template-columns: 1fr; }
  .gal-card { border-right: 0; }
  .ch-row { grid-template-columns: 1fr; }
  .ch-cell { border-right: 0; border-bottom: 1px dashed var(--line); }
  .ch-row.is-head { display: none; }
  .arch-grid { grid-template-columns: 1fr; }
  .arch-cell { border-right: 0; }
  .h-display { font-size: 38px; }
  .h-section { font-size: 32px; }
  .h-section-sm { font-size: 28px; }
  .h-section-xs { font-size: 24px; }
  .moat-canvas { height: 380px; }
  .moat-frame { padding: 18px; }
  .footer-links { grid-template-columns: repeat(2, 1fr); }
}
/* ============================================================
   MOBILE FIXES — propagated from Atlas pattern (2026-05-27)
   ============================================================ */
@media (max-width: 768px) {
  /* COMPARE TABLE: add visible scroll-hint right-edge fade + "swipe" hint */
  .cmp-wrap {
    position: relative;
    -webkit-overflow-scrolling: touch;
  }
  .cmp-wrap::after {
    content: '';
    position: absolute;
    top: 0; right: 0; bottom: 0;
    width: 32px;
    background: linear-gradient(to left, var(--paper, #fff), rgba(255,255,255,0));
    pointer-events: none;
  }
  .cmp-table { min-width: 720px; font-size: 14px; }
  .cmp-table thead th, .cmp-table tbody td { padding: 12px 10px; }
  .s-compare .s-head::after {
    content: '\2190 swipe to compare all tools \2192';
    display: block;
    margin-top: 14px;
    font-size: 12px; letter-spacing: 0.08em; text-transform: uppercase;
    color: var(--muted-2); font-family: var(--ff-mono, monospace);
  }

  /* DT-GRID: allow columns to shrink below content min-width so 4-col collapses correctly on mobile */
  .dt-grid { grid-template-columns: 1fr !important; }
  .dt-cell { min-width: 0; }

  /* CK-TABS: horizontal scroll so tabs don't push page width */
  .ck-tabs { overflow-x: auto !important; -webkit-overflow-scrolling: touch; }
  .ck-tabs .ck-action { flex: none; }

  /* CTA row mobile equal-widths (in addition to globals.css universal pattern) */
  .s-hero .cta-row,
  .s-cta .cta-row {
    flex-direction: column !important;
    align-items: stretch !important;
    gap: 12px !important;
  }
  .s-hero .cta-row > .btn,
  .s-cta .cta-row > .btn {
    width: 100% !important;
    justify-content: center !important;
  }
}
