/* QORA / qoraguard.com — marketing site styles.
   Brand tokens mirror the console (frontend/ops-dashboard globals.css):
   black #08090c · chrome/white #f5f5f7 · QORA red #e10f1f · Inter.
   Mobile-first: base styles target small screens; media queries scale up. */

:root {
  --bg: #08090c;
  --bg-2: #0d0f14;
  --surface: #111318;
  --surface-2: #161920;
  --fg: #f5f5f7;
  --fg-dim: rgba(245, 245, 247, 0.62);
  --fg-faint: rgba(245, 245, 247, 0.42);
  --accent: #e10f1f;         /* QORA red */
  --accent-2: #ff2b3a;
  --border: #24262d;
  --border-soft: rgba(245, 245, 247, 0.08);
  --radius: 0.75rem;
  --radius-sm: 0.5rem;
  --maxw: 1140px;
  --shadow: 0 10px 40px -12px rgba(0, 0, 0, 0.7);
  --shadow-red: 0 0 0 1px rgba(225, 15, 31, 0.35), 0 8px 30px -8px rgba(225, 15, 31, 0.35);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, sans-serif;
  background: var(--bg);
  color: var(--fg);
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

/* Ambient brand backdrop: a soft red glow + faint scan grid, fixed behind all. */
body::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background:
    radial-gradient(60rem 40rem at 78% -8%, rgba(225, 15, 31, 0.14), transparent 60%),
    radial-gradient(50rem 40rem at 0% 0%, rgba(225, 15, 31, 0.06), transparent 55%),
    var(--bg);
}
body::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -1;
  background-image:
    linear-gradient(rgba(245, 245, 247, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(245, 245, 247, 0.03) 1px, transparent 1px);
  background-size: 44px 44px;
  mask-image: radial-gradient(120% 90% at 50% 0%, #000 20%, transparent 75%);
  -webkit-mask-image: radial-gradient(120% 90% at 50% 0%, #000 20%, transparent 75%);
  pointer-events: none;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }

.wrap { width: 100%; max-width: var(--maxw); margin: 0 auto; padding: 0 20px; }

/* ── Typography ─────────────────────────────────────────── */
h1, h2, h3 { line-height: 1.12; letter-spacing: -0.02em; font-weight: 800; }
.chrome {
  background: linear-gradient(180deg, #ffffff 0%, #cfd2d8 55%, #9aa0ab 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.accent { color: var(--accent); }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-size: 12px; font-weight: 700; letter-spacing: 0.18em; text-transform: uppercase;
  color: var(--fg-dim);
}
.eyebrow::before {
  content: ""; width: 22px; height: 1px; background: var(--accent);
}

/* ── Buttons ────────────────────────────────────────────── */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 8px;
  font-weight: 650; font-size: 15px; line-height: 1;
  padding: 13px 20px; border-radius: var(--radius-sm);
  border: 1px solid transparent; cursor: pointer;
  transition: transform .12s ease, box-shadow .2s ease, background .2s ease, border-color .2s ease;
  white-space: nowrap;
}
.btn:active { transform: translateY(1px); }
.btn-primary { background: var(--accent); color: #fff; box-shadow: var(--shadow-red); }
.btn-primary:hover { background: var(--accent-2); }
.btn-ghost { background: transparent; color: var(--fg); border-color: var(--border); }
.btn-ghost:hover { border-color: rgba(245,245,247,0.4); background: rgba(245,245,247,0.04); }
.btn-sm { padding: 9px 15px; font-size: 14px; }

/* ── Header / nav ───────────────────────────────────────── */
.site-header {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: saturate(140%) blur(12px);
  -webkit-backdrop-filter: saturate(140%) blur(12px);
  background: rgba(8, 9, 12, 0.72);
  border-bottom: 1px solid var(--border-soft);
}
.nav { display: flex; align-items: center; justify-content: space-between; height: 62px; }
.nav-logo img { height: 40px; width: auto; display: block; }
.nav-links { display: none; align-items: center; gap: 28px; }
.nav-links a { color: var(--fg-dim); font-size: 14.5px; font-weight: 550; transition: color .15s; }
.nav-links a:hover { color: var(--fg); }
.nav-cta { display: flex; align-items: center; gap: 10px; }

/* ── Hero ───────────────────────────────────────────────── */
.hero { position: relative; padding: 64px 0 48px; }
.hero-grid { display: grid; grid-template-columns: 1fr; gap: 40px; align-items: center; }
.hero h1 { font-size: clamp(2.1rem, 8vw, 3.6rem); margin: 18px 0 0; }
.hero p.lede { margin-top: 18px; font-size: clamp(1rem, 3.6vw, 1.2rem); color: var(--fg-dim); max-width: 36ch; }
.hero-cta { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 28px; }
.hero-note { margin-top: 16px; font-size: 13px; color: var(--fg-faint); }

/* Viewfinder visual — the QORA scanner motif as a hero panel. */
.viewfinder {
  position: relative; aspect-ratio: 4 / 3; width: 100%;
  border: 1px solid var(--border); border-radius: var(--radius);
  background:
    radial-gradient(80% 60% at 50% 40%, rgba(225,15,31,0.10), transparent 70%),
    linear-gradient(160deg, var(--surface), var(--bg-2));
  overflow: hidden;
  box-shadow: var(--shadow);
}
.viewfinder .vf-logo {
  position: absolute; inset: 0; margin: auto; width: 62%; max-width: 320px;
  opacity: 0.96; filter: drop-shadow(0 6px 24px rgba(0,0,0,0.6));
}
.vf-bracket { position: absolute; width: 34px; height: 34px; border: 2px solid var(--accent); opacity: 0.9; }
.vf-bracket.tl { top: 18px; left: 18px; border-right: 0; border-bottom: 0; }
.vf-bracket.tr { top: 18px; right: 18px; border-left: 0; border-bottom: 0; }
.vf-bracket.bl { bottom: 18px; left: 18px; border-right: 0; border-top: 0; }
.vf-bracket.br { bottom: 18px; right: 18px; border-left: 0; border-top: 0; }
.vf-scan {
  position: absolute; left: 0; right: 0; height: 2px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  box-shadow: 0 0 14px 2px rgba(225,15,31,0.5);
  animation: vf-sweep 3.6s cubic-bezier(.6,.05,.4,.95) infinite;
}
@keyframes vf-sweep { 0% { top: 6%; } 50% { top: 92%; } 100% { top: 6%; } }
.vf-tag {
  position: absolute; left: 16px; bottom: 14px;
  font-size: 11px; letter-spacing: 0.14em; text-transform: uppercase; color: var(--fg-faint);
  display: flex; align-items: center; gap: 7px;
}
.vf-tag .dot { width: 7px; height: 7px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 8px var(--accent); animation: pulse 1.8s ease-in-out infinite; }
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: .3; } }

/* ── Trust strip ────────────────────────────────────────── */
.trust { border-top: 1px solid var(--border-soft); border-bottom: 1px solid var(--border-soft); background: rgba(255,255,255,0.015); }
.trust-row { display: flex; flex-wrap: wrap; gap: 10px 20px; padding: 16px 0; justify-content: center; }
.trust-row span { font-size: 12.5px; font-weight: 600; letter-spacing: 0.06em; color: var(--fg-dim); text-transform: uppercase; display: inline-flex; align-items: center; gap: 8px; }
.trust-row span::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: var(--accent); }

/* ── Sections ───────────────────────────────────────────── */
section.block { padding: 64px 0; }
.section-head { max-width: 46ch; margin-bottom: 36px; }
.section-head.wide { max-width: none; }
.section-head h2 { font-size: clamp(1.7rem, 6vw, 2.5rem); margin-top: 12px; }
.section-head p { margin-top: 14px; color: var(--fg-dim); font-size: 1.05rem; }

/* Feature cards */
.cards { display: grid; grid-template-columns: 1fr; gap: 16px; }
.card {
  background: linear-gradient(180deg, var(--surface), var(--bg-2));
  border: 1px solid var(--border); border-radius: var(--radius);
  padding: 24px; transition: transform .16s ease, border-color .2s ease, box-shadow .2s ease;
}
.card:hover { transform: translateY(-3px); border-color: rgba(225,15,31,0.4); box-shadow: var(--shadow-red); }
.card .ic {
  width: 42px; height: 42px; border-radius: 10px; display: grid; place-items: center;
  background: rgba(225,15,31,0.12); border: 1px solid rgba(225,15,31,0.3); color: var(--accent);
  margin-bottom: 14px;
}
.card .ic svg { width: 22px; height: 22px; }
.card h3 { font-size: 1.15rem; font-weight: 700; }
.card p { margin-top: 8px; color: var(--fg-dim); font-size: 0.96rem; }

/* Steps */
.steps { display: grid; grid-template-columns: 1fr; gap: 16px; counter-reset: step; }
.step { position: relative; padding: 22px 24px; border: 1px solid var(--border); border-radius: var(--radius); background: rgba(255,255,255,0.015); }
.step::before {
  counter-increment: step; content: counter(step, decimal-leading-zero);
  font-weight: 800; font-size: 13px; color: var(--accent); letter-spacing: 0.1em;
}
.step h3 { margin-top: 6px; font-size: 1.1rem; }
.step p { margin-top: 6px; color: var(--fg-dim); font-size: 0.96rem; }

/* Split feature (edge / privacy) */
.split { display: grid; grid-template-columns: 1fr; gap: 28px; align-items: center; }
.split ul { list-style: none; margin-top: 18px; display: grid; gap: 12px; }
.split li { display: flex; gap: 12px; color: var(--fg-dim); font-size: 0.98rem; }
.split li svg { flex: 0 0 auto; width: 20px; height: 20px; color: var(--accent); margin-top: 2px; }
.split li strong { color: var(--fg); font-weight: 650; }
.panel {
  border: 1px solid var(--border); border-radius: var(--radius); padding: 26px;
  background: linear-gradient(180deg, var(--surface), var(--bg-2)); box-shadow: var(--shadow);
}
.panel .kpi { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.panel .kpi div { padding: 16px; border: 1px solid var(--border); border-radius: var(--radius-sm); background: var(--bg); }
.panel .kpi b { display: block; font-size: 1.6rem; font-weight: 800; }
.panel .kpi span { font-size: 12.5px; color: var(--fg-dim); }

/* CTA band */
.cta-band {
  border: 1px solid rgba(225,15,31,0.3); border-radius: var(--radius);
  background:
    radial-gradient(60% 120% at 80% 0%, rgba(225,15,31,0.16), transparent 60%),
    linear-gradient(180deg, var(--surface), var(--bg-2));
  padding: 40px 24px; text-align: center;
}
.cta-band h2 { font-size: clamp(1.6rem, 6vw, 2.3rem); }
.cta-band p { margin-top: 12px; color: var(--fg-dim); }
.cta-band .hero-cta { justify-content: center; }

/* ── Footer ─────────────────────────────────────────────── */
.site-footer { border-top: 1px solid var(--border-soft); padding: 44px 0 34px; margin-top: 24px; background: rgba(0,0,0,0.3); }
.foot-grid { display: grid; grid-template-columns: 1fr; gap: 28px; }
.foot-brand img { height: 34px; width: auto; display: block; margin-bottom: 14px; }
.foot-brand p { color: var(--fg-faint); font-size: 13px; max-width: 34ch; }
.foot-col h4 { font-size: 12px; letter-spacing: 0.12em; text-transform: uppercase; color: var(--fg-faint); margin-bottom: 12px; }
.foot-col a { display: block; color: var(--fg-dim); font-size: 14px; padding: 4px 0; transition: color .15s; }
.foot-col a:hover { color: var(--fg); }
.foot-bottom {
  margin-top: 30px; padding-top: 20px; border-top: 1px solid var(--border-soft);
  display: flex; flex-wrap: wrap; gap: 12px; justify-content: space-between; align-items: center;
  font-size: 13px; color: var(--fg-faint);
}
.foot-bottom a { color: var(--fg-dim); }
.foot-bottom a:hover { color: var(--fg); }
.powered a { color: var(--fg); font-weight: 600; border-bottom: 1px solid rgba(225,15,31,0.5); }

/* ── Legal / compliance pages ───────────────────────────── */
.legal { padding: 48px 0 40px; }
.legal-wrap { max-width: 760px; }
.legal h1 { font-size: clamp(1.9rem, 6vw, 2.6rem); }
.legal .updated { color: var(--fg-faint); font-size: 13px; margin-top: 10px; }
.legal h2 { font-size: 1.35rem; margin-top: 36px; }
.legal h3 { font-size: 1.08rem; margin-top: 22px; }
.legal p, .legal li { color: var(--fg-dim); margin-top: 12px; }
.legal ul, .legal ol { margin-top: 12px; padding-left: 22px; }
.legal li { margin-top: 8px; }
.legal a { color: var(--fg); border-bottom: 1px solid rgba(225,15,31,0.5); }
.legal strong { color: var(--fg); }
.legal .toc { border: 1px solid var(--border); border-radius: var(--radius); padding: 18px 22px; margin: 24px 0 8px; background: rgba(255,255,255,0.015); }
.legal .toc a { display: block; padding: 4px 0; border: 0; color: var(--fg-dim); }
.legal .toc a:hover { color: var(--accent); }

.skip-link { position: absolute; left: -999px; top: 0; background: var(--accent); color: #fff; padding: 10px 14px; border-radius: 0 0 8px 0; z-index: 100; }
.skip-link:focus { left: 0; }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 3px; }

/* ── Breakpoints ────────────────────────────────────────── */
@media (min-width: 720px) {
  .cards { grid-template-columns: repeat(2, 1fr); }
  .steps { grid-template-columns: repeat(3, 1fr); }
  .foot-grid { grid-template-columns: 1.6fr 1fr 1fr 1fr; }
  .nav-links { display: flex; }
}
@media (min-width: 940px) {
  .hero { padding: 92px 0 64px; }
  .hero-grid { grid-template-columns: 1.05fr 0.95fr; gap: 56px; }
  .hero p.lede { font-size: 1.22rem; }
  .cards { grid-template-columns: repeat(3, 1fr); }
  .split { grid-template-columns: 1fr 1fr; gap: 48px; }
  section.block { padding: 84px 0; }
}

@media (prefers-reduced-motion: reduce) {
  * { animation-duration: 0.001ms !important; animation-iteration-count: 1 !important; scroll-behavior: auto !important; }
}

/* ── Contact page ───────────────────────────────────────── */
.contact-grid { display: grid; grid-template-columns: 1fr; gap: 32px; align-items: start; }
.contact-intro h1 { font-size: clamp(1.9rem, 7vw, 3rem); }
.contact-intro p { margin-top: 14px; color: var(--fg-dim); font-size: 1.05rem; max-width: 42ch; }
.contact-intro ul { list-style: none; margin-top: 22px; display: grid; gap: 12px; }
.contact-intro li { display: flex; gap: 12px; color: var(--fg-dim); }
.contact-intro li svg { flex: 0 0 auto; width: 20px; height: 20px; color: var(--accent); margin-top: 2px; }
.contact-alt { margin-top: 22px; font-size: 14px; color: var(--fg-faint); }
.contact-alt a { color: var(--fg-dim); border-bottom: 1px solid rgba(225,15,31,0.4); }

.form-card {
  border: 1px solid var(--border); border-radius: var(--radius);
  background: linear-gradient(180deg, var(--surface), var(--bg-2));
  padding: 26px; box-shadow: var(--shadow);
}
.field { margin-bottom: 16px; }
.field label { display: block; font-size: 12px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--fg-dim); margin-bottom: 7px; }
.field input, .field textarea, .field select {
  width: 100%; background: var(--bg); color: var(--fg);
  border: 1px solid var(--border); border-radius: var(--radius-sm);
  padding: 12px 14px; font: inherit; font-size: 15px;
}
.field textarea { min-height: 110px; resize: vertical; }
.field input::placeholder, .field textarea::placeholder { color: var(--fg-faint); }
.field input:focus, .field textarea:focus, .field select:focus { border-color: var(--accent); outline: none; box-shadow: 0 0 0 3px rgba(225,15,31,0.18); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-msg { margin-top: 6px; font-size: 14px; min-height: 20px; }
.form-msg.ok { color: #35d07f; }
.form-msg.err { color: var(--accent); }
.btn-block { width: 100%; }
.ts-slot { margin: 4px 0 14px; }

/* ── Chatbot ────────────────────────────────────────────── */
.qg-chat-launch {
  position: fixed; right: 20px; bottom: 20px; z-index: 80;
  display: inline-flex; align-items: center; gap: 10px;
  background: var(--accent); color: #fff; border: 0; cursor: pointer;
  padding: 12px 18px 12px 12px; border-radius: 999px; font: inherit; font-weight: 650; font-size: 15px;
  box-shadow: var(--shadow-red);
  transition: transform .12s ease, background .2s ease;
}
.qg-chat-launch:hover { background: var(--accent-2); }
.qg-chat-launch:active { transform: translateY(1px); }
.qg-chat-launch img { width: 26px; height: 26px; border-radius: 50%; background: #08090c; padding: 3px; }
.qg-chat-launch.hidden { display: none; }

.qg-chat {
  position: fixed; right: 20px; bottom: 20px; z-index: 90;
  width: min(390px, calc(100vw - 32px)); height: min(600px, calc(100vh - 40px));
  display: none; flex-direction: column;
  background: var(--surface); border: 1px solid var(--border); border-radius: 16px;
  box-shadow: 0 24px 70px -20px rgba(0,0,0,0.85); overflow: hidden;
}
.qg-chat.open { display: flex; }
.qg-chat-head { display: flex; align-items: center; gap: 11px; padding: 14px 16px; border-bottom: 1px solid var(--border); background: linear-gradient(180deg, #14161c, var(--surface)); }
.qg-chat-head img { width: 34px; height: 34px; border-radius: 50%; background: #08090c; padding: 4px; }
.qg-chat-head .t { font-weight: 700; font-size: 15px; line-height: 1.1; }
.qg-chat-head .s { font-size: 11.5px; color: var(--fg-faint); display: flex; align-items: center; gap: 6px; }
.qg-chat-head .s::before { content: ""; width: 7px; height: 7px; border-radius: 50%; background: #35d07f; box-shadow: 0 0 7px #35d07f; }
.qg-chat-head .x { margin-left: auto; background: transparent; border: 0; color: var(--fg-dim); cursor: pointer; font-size: 22px; line-height: 1; padding: 4px 8px; border-radius: 8px; }
.qg-chat-head .x:hover { background: rgba(255,255,255,0.06); color: var(--fg); }

.qg-msgs { flex: 1; overflow-y: auto; padding: 16px; display: flex; flex-direction: column; gap: 10px; }
.qg-b, .qg-u { max-width: 82%; padding: 10px 13px; border-radius: 14px; font-size: 14.5px; line-height: 1.45; }
.qg-b { align-self: flex-start; background: var(--surface-2); border: 1px solid var(--border); border-bottom-left-radius: 4px; }
.qg-u { align-self: flex-end; background: var(--accent); color: #fff; border-bottom-right-radius: 4px; }
.qg-opts { display: flex; flex-wrap: wrap; gap: 8px; padding: 2px 0 4px; }
.qg-opt {
  background: var(--bg); border: 1px solid var(--border); color: var(--fg);
  border-radius: 999px; padding: 8px 14px; font: inherit; font-size: 13.5px; cursor: pointer;
  transition: border-color .15s, background .15s;
}
.qg-opt:hover { border-color: var(--accent); background: rgba(225,15,31,0.08); }
.qg-opt.sel { background: var(--accent); border-color: var(--accent); color: #fff; }
.qg-inputrow { display: flex; gap: 8px; padding: 12px; border-top: 1px solid var(--border); background: var(--bg-2); }
.qg-inputrow input { flex: 1; background: var(--bg); color: var(--fg); border: 1px solid var(--border); border-radius: 10px; padding: 10px 12px; font: inherit; font-size: 14.5px; }
.qg-inputrow input:focus { outline: none; border-color: var(--accent); }
.qg-inputrow button { background: var(--accent); color: #fff; border: 0; border-radius: 10px; padding: 0 14px; cursor: pointer; font-weight: 700; }
.qg-inputrow button:disabled { opacity: .5; cursor: default; }
.qg-typing { display: inline-flex; gap: 4px; align-items: center; }
.qg-typing span { width: 6px; height: 6px; border-radius: 50%; background: var(--fg-faint); animation: qgblink 1.2s infinite; }
.qg-typing span:nth-child(2){ animation-delay:.2s } .qg-typing span:nth-child(3){ animation-delay:.4s }
@keyframes qgblink { 0%,60%,100%{opacity:.25} 30%{opacity:1} }
.qg-ts { padding: 8px 12px; }

@media (min-width: 860px) {
  .contact-grid { grid-template-columns: 0.95fr 1.05fr; gap: 48px; }
}
