/* Frieda landing page. Values follow design_handoff_frieda_landing/README.md (v3). */
:root {
  --ink: #101828;
  --text-2: #475467;
  --text-3: #667085;
  --border: #E4E7EC;
  --border-strong: #D0D5DD;
  --surface: #FFFFFF;
  --surface-2: #F7F8FA;
  --surface-3: #F2F4F7;
  --accent: #3c2caf;
  --accent-hover: #32249a;
  --link-hover: #2a1e86;
  --accent-tint: #EEECFA;
  --band-bg: #F6F4FD;
  --band-border: #E7E3F8;
  --warn-bg: #FFF6E5;
  --warn-text: #93370D;
  --warn-dot: #DC6803;
  --error: #B42318;
  --error-border: #F04438;
  --serif: 'Fraunces', Georgia, serif;
  --sans: 'Geist', system-ui, sans-serif;
  --mono: 'Geist Mono', ui-monospace, monospace;
  --ease: cubic-bezier(.2,.7,.2,1);
  --shadow-cta: 0 1px 2px rgba(16,24,40,.08), 0 4px 12px rgba(60,44,175,.18);
  --shadow-header-btn: 0 1px 2px rgba(16,24,40,.08), inset 0 1px 0 rgba(255,255,255,.12);
}

html { scroll-behavior: smooth; }
body { margin: 0; background: #fff; color: var(--ink); font-family: var(--sans); -webkit-font-smoothing: antialiased; }
*, *::before, *::after { box-sizing: border-box; }
a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--link-hover); }
::selection { background: var(--accent-tint); }
:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 6px; }
img { max-width: 100%; }
[hidden] { display: none !important; }

@keyframes fpulse { 0%,100% { opacity: 1; transform: scale(1); } 50% { opacity: .45; transform: scale(.7); } }
@keyframes fring { 0% { transform: scale(1); opacity: .5; } 100% { transform: scale(2.4); opacity: 0; } }
@keyframes fmodal { from { opacity: 0; transform: translateY(8px) scale(.98); } to { opacity: 1; transform: none; } }
@keyframes ffade { from { opacity: 0; } to { opacity: 1; } }
@keyframes fspin { to { transform: rotate(360deg); } }
@keyframes fdrop { 0% { transform: translateY(-8px) scale(.6); opacity: 0; } 15% { opacity: var(--o,.6); } 70% { opacity: calc(var(--o,.6) * .5); } 100% { transform: translateY(var(--d,70px)) scale(1); opacity: 0; } }
@keyframes fblobA { 0%,100% { transform: translate(0,0) scale(1); } 33% { transform: translate(3vw,10vh) scale(1.08); } 66% { transform: translate(-2vw,20vh) scale(.94); } }
@keyframes fblobB { 0%,100% { transform: translate(0,0) scale(1); } 33% { transform: translate(-3vw,-12vh) scale(1.1); } 66% { transform: translate(2vw,-4vh) scale(.92); } }

.page { position: relative; min-height: 100vh; background: #fff; color: var(--ink); }

/* Effects (decorative) */
.fx-blobs { position: fixed; inset: 0; overflow: hidden; pointer-events: none; z-index: 0; }
.blob { position: absolute; border-radius: 50%; filter: blur(70px); }
.blob-a { width: 22vw; height: 22vw; left: -11vw; top: 18vh; background: #E4DFFB; opacity: .45; animation: fblobA 38s ease-in-out infinite; }
.blob-b { width: 18vw; height: 18vw; right: -9vw; top: 52vh; background: #DCE8FD; opacity: .4; animation: fblobB 44s ease-in-out infinite; }
.fx-drops { position: absolute; left: 0; right: 0; top: 0; height: 140px; overflow: hidden; pointer-events: none; z-index: 0;
  -webkit-mask-image: linear-gradient(#000 40%, transparent); mask-image: linear-gradient(#000 40%, transparent); }
.fx-drops span { position: absolute; top: 0; border-radius: 999px; opacity: 0; }

/* Pulse dot */
.pulse { position: relative; display: inline-flex; width: 8px; height: 8px; flex: none; }
.pulse-ring { position: absolute; inset: 0; border-radius: 999px; background: var(--accent); animation: fring 1.8s ease-out infinite; }
.pulse-core { position: relative; width: 8px; height: 8px; border-radius: 999px; background: var(--accent); animation: fpulse 1.8s ease-in-out infinite; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  [data-fx] *, .pulse-ring, .pulse-core { animation: none !important; }
  .pulse-ring { display: none; }
}

/* Buttons */
.btn { font-family: inherit; font-weight: 500; border-radius: 12px; cursor: pointer; display: inline-flex; align-items: center; justify-content: center; gap: 10px; }
.btn-primary { color: #fff; background: var(--accent); border: 0; }
.btn-primary:hover { background: var(--accent-hover); color: #fff; }
.btn-header { font-size: 14px; padding: 10px 16px; white-space: nowrap; box-shadow: var(--shadow-header-btn); }
.btn-lg { font-size: 15px; padding: 13px 20px; box-shadow: var(--shadow-cta); }
.btn-ghost { color: var(--ink); background: #fff; border: 1px solid var(--border); padding: 12px 20px; box-shadow: none; }
.btn-ghost:hover { background: var(--surface-2); color: var(--ink); }
.btn-secondary { font-size: 15px; color: var(--ink); background: #fff; border: 1px solid var(--border); padding: 12px 16px; }
.btn-secondary:hover { background: var(--surface-2); }
.btn-block { width: 100%; }

/* Header */
.site-header { position: sticky; top: 0; z-index: 40; height: 64px; background: rgba(255,255,255,.92);
  -webkit-backdrop-filter: saturate(180%) blur(12px); backdrop-filter: saturate(180%) blur(12px); border-bottom: 1px solid var(--border); }
.header-inner { max-width: 1400px; height: 100%; margin: 0 auto; padding: 0 20px; display: flex; align-items: center; justify-content: space-between; gap: 16px; }
.header-logo { display: flex; align-items: center; flex: 1 1 0; }
.header-logo img { height: 24px; width: auto; display: block; }
.header-nav { display: flex; gap: 32px; font-size: 14px; font-weight: 500; }
.header-nav a { color: var(--text-2); }
.header-nav a:hover { color: var(--ink); }
.header-actions { flex: 1 1 0; display: flex; align-items: center; justify-content: flex-end; gap: 20px; }
@media (max-width: 859px) {
  .header-nav { display: none; }
  .btn-header { min-height: 44px; }
}

/* Step progress: top bar below 1600px, left rail from 1600px. Shown only while #agents is in view. */
.topbar { display: none; position: fixed; top: 64px; left: 0; right: 0; z-index: 35; background: rgba(255,255,255,.96);
  -webkit-backdrop-filter: blur(12px); backdrop-filter: blur(12px); border-bottom: 1px solid var(--border); }
.topbar-inner { max-width: 1400px; margin: 0 auto; padding: 10px 20px; display: flex; align-items: center; gap: 12px; font-size: 13px; }
.topbar-num { font-family: var(--mono); color: var(--accent); font-weight: 500; white-space: nowrap; }
.topbar-label { color: var(--ink); font-weight: 500; }
.topbar-agent { color: var(--text-3); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-width: 0; }
.topbar-track { height: 2px; background: var(--surface-3); }
.topbar-fill { height: 2px; background: var(--accent); width: 16.6667%; transition: width .4s ease; }
.rail { display: none; position: fixed; left: 28px; top: 50%; transform: translateY(-50%); z-index: 30; flex-direction: column; gap: 4px; }
.rail a { display: flex; align-items: center; gap: 10px; padding: 6px 8px; border-radius: 8px; color: var(--text-3); font-size: 13px; font-weight: 500; transition: color .25s ease; }
.rail a:hover { color: var(--ink); }
.rail-dot { width: 8px; height: 8px; border-radius: 999px; background: var(--border-strong); box-shadow: 0 0 0 0 var(--accent-tint); transition: all .25s ease; }
.rail-num { font-family: var(--mono); font-size: 12px; }
.rail-label { display: none; }
.rail a.is-passed .rail-dot { background: #9E95DD; }
.rail a[aria-current="step"] { color: var(--accent); }
.rail a[aria-current="step"] .rail-dot { background: var(--accent); box-shadow: 0 0 0 4px var(--accent-tint); }
@media (max-width: 1599px) { .in-agents .topbar { display: block; } }
@media (min-width: 1600px) { .in-agents .rail { display: flex; } }
@media (min-width: 1820px) { .rail-label { display: inline; } }

/* Main */
.site-main { position: relative; z-index: 1; }
.hero { position: relative; padding: clamp(48px,9vw,96px) 20px 0; }
.hero-inner { position: relative; z-index: 1; max-width: 1120px; margin: 0 auto; display: flex; flex-direction: column; align-items: center; text-align: center; }
.eyebrow-pill { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px 6px 10px; border: 1px solid var(--border); background: #fff; border-radius: 999px;
  font-size: 13px; font-weight: 500; color: var(--text-2); box-shadow: 0 1px 2px rgba(16,24,40,.04); }
.hero-title { margin: clamp(20px,4vw,28px) 0 0; max-width: 980px; font-family: var(--serif); font-weight: 400; font-size: clamp(40px,6.4vw,84px);
  line-height: 1.02; letter-spacing: -0.03em; color: var(--ink); text-wrap: balance; }
.hero-sub { margin: 28px 0 0; max-width: 640px; font-size: clamp(17px,1.6vw,19px); line-height: 1.55; color: var(--text-2); text-wrap: pretty; }
.hero-ctas { margin-top: 36px; display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; }
.hero-anim { margin-top: 24px; width: 100%; aspect-ratio: 16/9; overflow: hidden; position: relative; }
.hero-anim iframe, .step-anim iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; background: transparent; }

/* Agent steps */
.agents { margin-top: clamp(56px,10vw,120px); }
.step { scroll-margin-top: 96px; padding: clamp(64px,10vw,112px) 20px; border-top: 1px solid var(--border); }
.step-row { max-width: 1360px; margin: 0 auto; display: flex; flex-wrap: wrap; justify-content: center; gap: clamp(28px,6vw,96px); align-items: center; }
.step--reverse .step-row { flex-direction: row-reverse; }
.step-anim { flex: 0 1 620px; min-width: 0; aspect-ratio: 1/1; overflow: hidden; position: relative; }
.step-text { flex: 1 1 320px; max-width: 520px; min-width: 0; display: flex; flex-direction: column; gap: 20px; }
.step-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 12px; }
.step-eyebrow { font-family: var(--mono); font-size: 13px; color: var(--text-3); }
.agent-chip { display: inline-flex; align-items: center; gap: 6px; padding: 4px 10px; border-radius: 999px; background: var(--accent-tint); color: var(--accent); font-size: 13px; font-weight: 500; }
.h2 { margin: 0; font-family: var(--serif); font-weight: 400; font-size: clamp(32px,3.6vw,46px); line-height: 1.08; letter-spacing: -0.025em; text-wrap: balance; }
.step-body { margin: 0; font-size: 17px; line-height: 1.6; color: var(--text-2); text-wrap: pretty; }
.checklist { list-style: none; margin: 4px 0 0; padding: 0; display: flex; flex-direction: column; gap: 12px; }
.checklist li { display: flex; gap: 12px; font-size: 15px; line-height: 1.5; color: var(--ink); }
.checklist svg { width: 18px; height: 18px; flex: none; margin-top: 2px; fill: none; stroke: var(--accent); stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.handoff { margin-top: 8px; padding-top: 16px; border-top: 1px solid var(--border); display: flex; align-items: center; gap: 10px; font-size: 14px; line-height: 1.45; color: var(--text-2); }
.handoff strong { font-weight: 600; color: var(--ink); }
.handoff-label { flex: none; font-family: var(--mono); font-size: 11px; font-weight: 500; letter-spacing: .04em; color: var(--accent); background: var(--accent-tint); padding: 3px 8px; border-radius: 999px; }
/* On narrow screens the row wraps. The animation is first in the DOM, so it always sits above the text. */

/* Control band */
.control { scroll-margin-top: 64px; padding: clamp(64px,9vw,104px) 20px; background: var(--band-bg); border-top: 1px solid var(--band-border); border-bottom: 1px solid var(--band-border); }
.control-inner { max-width: 1360px; margin: 0 auto; display: flex; flex-direction: column; gap: clamp(32px,5vw,48px); }
.control-title { max-width: 720px; }
.cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%,280px), 1fr)); gap: 16px; }
.card { background: #fff; border: 1px solid var(--border); border-radius: 12px; padding: 28px; display: flex; flex-direction: column; gap: 12px; box-shadow: 0 1px 2px rgba(16,24,40,.03); }
.card h3 { margin: 0; font-size: 17px; font-weight: 600; letter-spacing: -0.01em; }
.card p { margin: 0; font-size: 15px; line-height: 1.55; color: var(--text-2); }
.modes { margin-top: 8px; display: flex; flex-wrap: wrap; gap: 6px; }
.mode { font-family: inherit; font-size: 12px; font-weight: 500; padding: 5px 10px; border-radius: 999px; cursor: pointer; border: 1px solid var(--border); background: #fff; color: var(--text-2); transition: all .2s ease; }
.mode[aria-checked="true"] { border-color: #C9C3F0; background: var(--accent-tint); color: var(--accent); }
.card-pill { margin-top: 8px; display: flex; }
.status-pill { display: inline-flex; align-items: center; gap: 6px; padding: 5px 10px; border-radius: 999px; font-size: 12px; font-weight: 500; }
.status-pill--warn { background: var(--warn-bg); color: var(--warn-text); }
.status-pill--warn .status-dot { width: 6px; height: 6px; border-radius: 999px; background: var(--warn-dot); }
.status-pill--working { background: var(--accent-tint); color: var(--accent); }
.stats { margin: 0; display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%,200px),1fr)); gap: clamp(20px,4vw,32px); padding-top: clamp(28px,5vw,40px); border-top: 1px solid var(--border); }
.stats > div { display: flex; flex-direction: column; gap: 6px; }
.stats dt { font-family: var(--serif); font-size: 44px; font-weight: 400; letter-spacing: -0.03em; line-height: 1; color: var(--ink); }
.stats dd { margin: 0; font-size: 15px; color: var(--text-2); }

/* Closing CTA */
.cta { padding: clamp(80px,12vw,144px) 20px; }
.cta-inner { max-width: 760px; margin: 0 auto; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 20px; }
.cta-title { margin: 0; font-family: var(--serif); font-weight: 400; font-size: clamp(36px,4.6vw,60px); line-height: 1.04; letter-spacing: -0.03em; text-wrap: balance; }
.cta-sub { margin: 0; font-size: 18px; line-height: 1.55; color: var(--text-2); }
.btn-cta { margin-top: 12px; padding: 13px 22px; }

/* Footer */
.site-footer { position: relative; z-index: 1; border-top: 1px solid var(--border); padding: clamp(48px,8vw,64px) 20px 40px; }
.footer-inner { max-width: 1360px; margin: 0 auto; display: flex; flex-direction: column; gap: 48px; }
.footer-top { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 40px; }
.footer-logo { height: 22px; width: auto; display: block; }
.footer-cols { display: flex; flex-wrap: wrap; gap: clamp(32px,7vw,64px); font-size: 14px; }
.footer-col { display: flex; flex-direction: column; gap: 10px; }
.footer-col a { color: var(--text-2); }
.footer-col a:hover { color: var(--ink); }
.footer-head { font-weight: 500; color: var(--ink); }
.footer-bottom { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 16px; padding-top: 24px; border-top: 1px solid var(--border); font-size: 13px; color: var(--text-3); }
.badges { display: flex; gap: 8px; }
.badge { padding: 4px 10px; border: 1px dashed var(--border-strong); border-radius: 999px; font-family: var(--mono); font-size: 12px; color: var(--text-2); }

/* Request-a-demo modal */
.modal-backdrop { position: fixed; inset: 0; z-index: 100; background: rgba(16,24,40,.4); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px);
  display: flex; align-items: center; justify-content: center; padding: 20px; animation: ffade .2s ease; }
.modal { position: relative; width: 100%; max-width: 440px; max-height: calc(100vh - 40px); overflow-y: auto; background: #fff; border-radius: 16px;
  padding: clamp(24px,6vw,32px); box-shadow: 0 24px 48px -12px rgba(16,24,40,.25); animation: fmodal .25s var(--ease); }
.modal-close { position: absolute; top: 16px; right: 16px; width: 32px; height: 32px; border: 0; border-radius: 8px; background: transparent; color: var(--text-3); cursor: pointer;
  display: flex; align-items: center; justify-content: center; }
.modal-close:hover { background: var(--surface-3); color: var(--ink); }
.modal-close svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; }
.modal-title { margin: 0; font-family: var(--serif); font-weight: 400; font-size: 28px; letter-spacing: -0.02em; }
.modal-sub { margin: 8px 0 0; font-size: 15px; line-height: 1.5; color: var(--text-2); }
.demo-form { margin-top: 24px; display: flex; flex-direction: column; gap: 16px; }
.field { display: flex; flex-direction: column; gap: 6px; font-size: 14px; font-weight: 500; color: var(--ink); }
.field input { font-family: inherit; font-size: 15px; font-weight: 400; color: var(--ink); padding: 11px 12px; border-radius: 10px; border: 1px solid var(--border-strong);
  outline: none; box-shadow: 0 1px 2px rgba(16,24,40,.04); }
.field input:focus { border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-tint); }
.field input[aria-invalid="true"] { border-color: var(--error-border); }
.field-error { font-size: 13px; font-weight: 400; color: var(--error); }
.hp { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }
.btn-submit { margin-top: 8px; width: 100%; font-size: 15px; padding: 13px 16px; }
.btn-submit[disabled] { opacity: .85; cursor: default; }
.spinner { width: 14px; height: 14px; border-radius: 999px; border: 2px solid rgba(255,255,255,.4); border-top-color: #fff; animation: fspin .7s linear infinite; }
.form-error { margin: 0; font-size: 13px; line-height: 1.45; color: var(--error); }
.form-note { margin: 0; font-size: 12px; line-height: 1.5; color: var(--text-3); }
.form-note a { color: var(--text-2); text-decoration: underline; }
.success { display: flex; flex-direction: column; gap: 16px; padding-top: 4px; }
.success-icon { width: 40px; height: 40px; border-radius: 999px; background: var(--accent-tint); color: var(--accent); display: flex; align-items: center; justify-content: center; }
.success-icon svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-width: 2; stroke-linecap: round; stroke-linejoin: round; }
.success-text { margin: 0; font-size: 15px; line-height: 1.55; color: var(--text-2); }
.success .btn-secondary { margin-top: 8px; }

/* Legal pages */
.legal-header { position: sticky; top: 0; z-index: 40; height: 64px; background: rgba(255,255,255,.92); -webkit-backdrop-filter: saturate(180%) blur(12px);
  backdrop-filter: saturate(180%) blur(12px); border-bottom: 1px solid var(--border); }
.legal-main { position: relative; z-index: 1; max-width: 760px; margin: 0 auto; padding: clamp(40px,8vw,72px) 20px clamp(64px,10vw,112px); display: flex; flex-direction: column; gap: 22px; }
.legal-title { margin: 0; font-family: var(--serif); font-weight: 400; font-size: clamp(32px,4vw,44px); letter-spacing: -0.02em; line-height: 1.1; }
.legal-date { font-family: var(--mono); font-size: 12px; color: var(--text-3); }
.legal-tabs { display: flex; flex-wrap: wrap; gap: 4px; border-bottom: 1px solid var(--border); }
.legal-tabs a { font-size: 14px; font-weight: 500; padding: 10px 12px; color: var(--text-3); border-bottom: 2px solid transparent; margin-bottom: -1px; }
.legal-tabs a:hover { color: var(--ink); }
.legal-tabs a[aria-current="page"] { color: var(--accent); border-bottom-color: var(--accent); }
.legal-notice { padding: 10px 12px; border-radius: 10px; background: var(--warn-bg); color: var(--warn-text); font-size: 13px; line-height: 1.45; }
.legal-main p, .legal-main li { font-size: 15px; line-height: 1.65; color: var(--text-2); text-wrap: pretty; }
.legal-main p { margin: 0; }
.legal-main section { display: flex; flex-direction: column; gap: 10px; }
.legal-main h2 { margin: 0; font-size: 16px; font-weight: 600; color: var(--ink); letter-spacing: -0.01em; }
.legal-main ul { margin: 0; padding-left: 20px; display: flex; flex-direction: column; gap: 6px; }
.legal-main dl { margin: 0; display: grid; grid-template-columns: max-content 1fr; gap: 8px 20px; font-size: 15px; line-height: 1.6; }
.legal-main dt { color: var(--text-3); }
.legal-main dd { margin: 0; color: var(--ink); }
@media (max-width: 559px) { .legal-main dl { grid-template-columns: 1fr; gap: 2px; } .legal-main dd { margin-bottom: 10px; } }

/* 404 */
.notfound { position: relative; z-index: 1; min-height: calc(100vh - 64px); display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; gap: 20px; padding: 40px 20px; }
