/* ═══════════════════════════════════════════════════════════════════
   CROWORK v3 — SINGLE-SOURCE-OF-TRUTH STYLESHEET
   Every page on crowork.ai links to this file and ONLY this file.
   Never inline tokens or component CSS in individual pages.
   Last design: shadcn/ui neutral + signal-orange accent + Geist fonts.
═══════════════════════════════════════════════════════════════════ */

/* ── Fonts ──────────────────────────────────────────────────────── */
@import url('https://fonts.googleapis.com/css2?family=Geist:wght@300;400;500;600;700;800&family=Geist+Mono:wght@400;500;600&display=swap');


/* ═══════════════════════════════════════════════════════════════════
   DESIGN TOKENS
   These names are canonical — use them everywhere, never override
   with raw hex values inside pages.
═══════════════════════════════════════════════════════════════════ */
:root {
  /* ── Surfaces ──────────────────────────────────────────────── */
  --bg:           #ffffff;
  --bg-tint:      #fafafa;
  --bg-tint-2:    #f4f4f5;
  --bg-dark:      #09090b;
  --bg-dark-2:    #18181b;

  /* ── Borders ────────────────────────────────────────────────── */
  --border:       #e4e4e7;
  --border-2:     #d4d4d8;

  /* ── Ink (light surfaces) ───────────────────────────────────── */
  --ink:          #09090b;
  --ink-2:        #27272a;
  --ink-3:        #52525b;
  --ink-4:        #71717a;

  /* ── Ink (dark surfaces) ────────────────────────────────────── */
  --ink-on-dark:  #fafafa;
  --ink-on-dark-2:#a1a1aa;

  /* ── Accent ─────────────────────────────────────────────────── */
  --accent:        #E8490F;
  --accent-strong: #C2410C;
  --accent-2:     #c93d0c;
  --accent-soft:  #fdede8;

  /* ── Semantic ───────────────────────────────────────────────── */
  --ok:           #16a34a;
  --warn:         #d97706;

  /* ── Radii ──────────────────────────────────────────────────── */
  --r-sm:         8px;
  --r-md:         10px;
  --r-lg:         14px;
  --r-xl:         18px;
  --r-pill:       999px;

  /* ── Shadows ────────────────────────────────────────────────── */
  --shadow-sm:    0 1px 2px rgba(9,9,11,.06);
  --shadow-md:    0 4px 14px rgba(9,9,11,.08);
  --shadow-lg:    0 24px 50px rgba(9,9,11,.12), 0 4px 12px rgba(9,9,11,.05);

  /* ── Layout ─────────────────────────────────────────────────── */
  --maxw:         80rem;
  --pad:          1.5rem;

  /* ── Typography ─────────────────────────────────────────────── */
  --font-sans:    'Geist', ui-sans-serif, system-ui, sans-serif;
  --font-mono:    'Geist Mono', ui-monospace, monospace;
}


/* ═══════════════════════════════════════════════════════════════════
   RESET + BASE
═══════════════════════════════════════════════════════════════════ */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
}

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

body {
  font-family: var(--font-sans);
  font-size: 17px;              /* readable baseline — never go below 15px for body copy */
  line-height: 1.7;
  color: var(--ink-2);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  overflow-x: hidden;
}

img, video, svg { display: block; max-width: 100%; }

a { color: inherit; }

::selection { background: rgba(232,73,15,.14); }

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

::-webkit-scrollbar       { width: 5px; }
::-webkit-scrollbar-track { background: var(--bg-tint); }
::-webkit-scrollbar-thumb { background: var(--border-2); border-radius: 3px; }


/* ═══════════════════════════════════════════════════════════════════
   TYPE UTILITIES
   Use these classes for all text. Never set font-size inline.
═══════════════════════════════════════════════════════════════════ */

/* Page / hero headline — largest display size */
.t-hero {
  font-family: var(--font-sans);
  font-size: clamp(2.8rem, 6vw, 4.5rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.06;
  color: var(--ink);
}

/* Section heading h1 equivalent */
.t-h1 {
  font-family: var(--font-sans);
  font-size: clamp(2.1rem, 4.5vw, 3rem);
  font-weight: 700;
  letter-spacing: -0.025em;
  line-height: 1.08;
  color: var(--ink);
}

/* Section heading h2 equivalent */
.t-h2 {
  font-family: var(--font-sans);
  font-size: clamp(1.6rem, 3.5vw, 2.1rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.15;
  color: var(--ink);
}

/* Sub-heading / card title h3 equivalent */
.t-h3 {
  font-family: var(--font-sans);
  font-size: 1.25rem;
  font-weight: 600;
  letter-spacing: -0.015em;
  line-height: 1.3;
  color: var(--ink);
}

/* Large lead paragraph */
.t-lead {
  font-family: var(--font-sans);
  font-size: 1.18rem;
  line-height: 1.7;
  color: var(--ink-3);
}

/* Standard body — never below 15px rendered */
.t-body {
  font-family: var(--font-sans);
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--ink-2);
}

/* Small / meta text — still legible */
.t-small {
  font-family: var(--font-sans);
  font-size: 0.95rem;
  line-height: 1.6;
  color: var(--ink-3);
}

/* Mono eyebrow label — uppercase, tracked */
.t-label {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-3);
}

/* Inline mono / code / metrics */
.t-mono {
  font-family: var(--font-mono);
  font-size: 0.875rem;
}

/* Stat / metric numbers */
.t-stat {
  font-family: var(--font-sans);
  font-size: clamp(2rem, 4vw, 2.75rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1;
  color: var(--ink);
}

/* Utility: muted variant */
.t-muted { color: var(--ink-3) !important; }

/* On dark backgrounds */
.t-on-dark   { color: var(--ink-on-dark); }
.t-on-dark-2 { color: var(--ink-on-dark-2); }


/* ═══════════════════════════════════════════════════════════════════
   LAYOUT
═══════════════════════════════════════════════════════════════════ */

.container {
  max-width: var(--maxw);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--pad);
  padding-right: var(--pad);
}

.section {
  padding-top: 6rem;
  padding-bottom: 6rem;
}

@media (max-width: 640px) {
  .section { padding-top: 4rem; padding-bottom: 4rem; }
}

.section-tint {
  background: var(--bg-tint);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
}

.section-dark {
  background: var(--bg-dark);
  color: var(--ink-on-dark);
}

.section-dark .t-h2,
.section-dark .t-h1,
.section-dark .t-hero,
.section-dark .t-h3 { color: var(--ink-on-dark); }

.section-dark .t-lead,
.section-dark .t-body,
.section-dark .t-small { color: var(--ink-on-dark-2); }


/* ═══════════════════════════════════════════════════════════════════
   BUTTONS
   All buttons: height 44px optical (padding-based), radius --r-md.
   Focus ring via :focus-visible above (orange, 2px).
═══════════════════════════════════════════════════════════════════ */

/* Shared base */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  min-height: 44px;
  padding: 0 20px;
  border-radius: var(--r-md);
  font-family: var(--font-sans);
  font-size: 0.9375rem;
  font-weight: 600;
  line-height: 1;
  letter-spacing: -0.01em;
  white-space: nowrap;
  text-decoration: none;
  cursor: pointer;
  border: none;
  transition: background 0.15s, box-shadow 0.15s, transform 0.12s, border-color 0.15s, color 0.15s;
  -webkit-tap-highlight-color: transparent;
}

/* Solid orange */
.btn-primary {
  background: var(--accent-strong);
  color: #fff;
  box-shadow: var(--shadow-sm);
}
.btn-primary:hover {
  background: #a8350a;
  box-shadow: 0 4px 16px rgba(194,65,12,.28);
  transform: translateY(-1px);
}
.btn-primary:active { transform: none; box-shadow: var(--shadow-sm); }

/* 1px border, no fill */
.btn-outline {
  background: transparent;
  color: var(--ink);
  border: 1px solid var(--border);
  padding: 0 19px; /* compensate for border */
}
.btn-outline:hover {
  border-color: rgba(232,73,15,.35);
  background: var(--accent-soft);
  color: var(--accent);
}

/* No border, subtle bg on hover */
.btn-ghost {
  background: transparent;
  color: var(--ink-3);
  padding: 0 14px;
}
.btn-ghost:hover {
  background: var(--bg-tint-2);
  color: var(--ink);
}

/* Compact size modifier */
.btn-sm {
  min-height: 36px;
  padding: 0 14px;
  font-size: 0.875rem;
}


/* ═══════════════════════════════════════════════════════════════════
   CARD
═══════════════════════════════════════════════════════════════════ */

.card {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-sm);
  transition: box-shadow 0.2s, transform 0.2s, border-color 0.2s;
}
.card:hover {
  box-shadow: var(--shadow-md);
  transform: translateY(-2px);
  border-color: var(--border-2);
}
.card-accent:hover {
  border-color: rgba(232,73,15,.3);
  box-shadow: 0 8px 24px rgba(232,73,15,.08), var(--shadow-md);
}

.card-dark {
  background: var(--bg-dark);
  border: 1px solid #27272a;
  border-radius: var(--r-lg);
  box-shadow: var(--shadow-lg);
  color: var(--ink-on-dark);
}


/* ═══════════════════════════════════════════════════════════════════
   BADGE
═══════════════════════════════════════════════════════════════════ */

.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 2px 9px;
  border-radius: var(--r-pill);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  background: var(--bg-tint-2);
  border: 1px solid var(--border);
  color: var(--ink-3);
  white-space: nowrap;
}
.badge-accent {
  background: var(--accent-soft);
  border-color: rgba(232,73,15,.25);
  color: var(--accent-strong);
}
.badge-ok {
  background: rgba(22,163,74,.07);
  border-color: rgba(22,163,74,.25);
  color: #15803d;
}
.badge-warn {
  background: rgba(217,119,6,.07);
  border-color: rgba(217,119,6,.25);
  color: #b45309;
}
.badge-mono {
  background: var(--bg-dark);
  border-color: #27272a;
  color: var(--ink-on-dark-2);
  font-family: var(--font-mono);
}


/* ═══════════════════════════════════════════════════════════════════
   BROWSER FRAME — product screenshot chrome
   Usage:
     <div class="browser-frame">
       <div class="browser-chrome">
         <div class="browser-dots"><span></span><span></span><span></span></div>
         <div class="browser-url">app.crowork.ai/dashboard</div>
       </div>
       <div class="browser-body"><img src="..." alt="..." /></div>
     </div>
═══════════════════════════════════════════════════════════════════ */

.browser-frame {
  border-radius: var(--r-xl);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg), 0 20px 48px rgba(0,0,0,.06);
  overflow: hidden;
  background: var(--bg-tint);
}
.browser-chrome {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 14px;
  background: var(--bg-tint-2);
  border-bottom: 1px solid var(--border);
}
.browser-dots {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-shrink: 0;
}
.browser-dots span {
  display: block;
  width: 10px;
  height: 10px;
  border-radius: 50%;
}
.browser-dots span:nth-child(1) { background: #f87171; }
.browser-dots span:nth-child(2) { background: #fbbf24; }
.browser-dots span:nth-child(3) { background: #4ade80; }

.browser-url {
  flex: 1;
  display: flex;
  align-items: center;
  justify-content: center;
  max-width: 280px;
  margin: 0 auto;
  padding: 4px 12px;
  border-radius: var(--r-md);
  background: var(--bg);
  border: 1px solid var(--border);
  font-family: var(--font-mono);
  font-size: 0.7rem;
  color: var(--ink-3);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.browser-body {
  background: var(--bg-tint);
  min-height: 220px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.browser-body img {
  width: 100%;
  display: block;
  height: auto;
}


/* ═══════════════════════════════════════════════════════════════════
   TABS (segmented control, data-tabs scoped)
═══════════════════════════════════════════════════════════════════ */

[data-tabs] {}

.tabs-list {
  display: inline-flex;
  gap: 2px;
  padding: 3px;
  border-radius: var(--r-lg);
  background: var(--bg-tint-2);
  border: 1px solid var(--border);
  flex-wrap: wrap;
}
.tab-trigger {
  padding: 8px 16px;
  min-height: 36px;
  border-radius: calc(var(--r-lg) - 2px);
  font-family: var(--font-sans);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--ink-3);
  background: transparent;
  border: none;
  cursor: pointer;
  transition: background 0.15s, color 0.15s, box-shadow 0.15s;
  white-space: nowrap;
}
.tab-trigger:hover:not([aria-selected="true"]) { color: var(--ink); }
.tab-trigger[aria-selected="true"],
.tab-trigger.active {
  background: var(--bg);
  color: var(--ink);
  box-shadow: var(--shadow-sm);
}
.tab-panel { display: none; }
.tab-panel.active,
.tab-panel[aria-hidden="false"] { display: block; }


/* ═══════════════════════════════════════════════════════════════════
   ACCORDION
═══════════════════════════════════════════════════════════════════ */

.accordion {}

.accordion-item {
  border-bottom: 1px solid var(--border);
}
.accordion-item:first-child { border-top: 1px solid var(--border); }

.accordion-trigger {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 0;
  background: none;
  border: none;
  cursor: pointer;
  text-align: left;
  font-family: var(--font-sans);
  font-size: 1.0625rem;
  font-weight: 500;
  color: var(--ink);
  transition: color 0.15s;
}
.accordion-trigger:hover { color: var(--accent); }

.accordion-chevron {
  width: 16px;
  height: 16px;
  flex-shrink: 0;
  color: var(--ink-4);
  transition: transform 0.25s cubic-bezier(0.4,0,.2,1), color 0.15s;
}
.accordion-item.open .accordion-chevron,
.accordion-item[aria-expanded="true"] .accordion-chevron {
  transform: rotate(180deg);
  color: var(--accent);
}

.accordion-content {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.32s cubic-bezier(0.4,0,.2,1);
}
.accordion-content.open,
.accordion-content[aria-hidden="false"] { max-height: 400px; }

.accordion-body {
  padding-bottom: 18px;
  font-size: 1.0625rem;
  line-height: 1.7;
  color: var(--ink-3);
}


/* ═══════════════════════════════════════════════════════════════════
   FORM INPUTS
═══════════════════════════════════════════════════════════════════ */

.input,
.textarea,
.select {
  width: 100%;
  padding: 10px 14px;
  border-radius: var(--r-md);
  border: 1px solid var(--border);
  background: var(--bg);
  font-family: var(--font-sans);
  font-size: 1rem;
  color: var(--ink);
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
  appearance: none;
  -webkit-appearance: none;
}
.input::placeholder,
.textarea::placeholder { color: var(--ink-4); }
.input:focus,
.textarea:focus,
.select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(232,73,15,.12);
}
.textarea { resize: vertical; line-height: 1.65; min-height: 100px; }
.select {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2371717a' stroke-width='2'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 12px center;
  padding-right: 38px;
}


/* ═══════════════════════════════════════════════════════════════════
   SEPARATOR
═══════════════════════════════════════════════════════════════════ */

.separator {
  height: 1px;
  background: var(--border);
  border: none;
  margin: 0;
}
.separator-accent {
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent 0%,
    rgba(232,73,15,.28) 35%,
    rgba(232,73,15,.28) 65%,
    transparent 100%
  );
  border: none;
}


/* ═══════════════════════════════════════════════════════════════════
   PULSE DOT — live/human-signal indicator (teal/green)
═══════════════════════════════════════════════════════════════════ */

.pulse-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: #22c55e;
  flex-shrink: 0;
  box-shadow: 0 0 0 0 rgba(34,197,94,.4);
  animation: pulse-ring 2.2s ease-in-out infinite;
}
@keyframes pulse-ring {
  0%   { box-shadow: 0 0 0 0   rgba(34,197,94,.4); }
  70%  { box-shadow: 0 0 0 7px rgba(34,197,94,0);  }
  100% { box-shadow: 0 0 0 0   rgba(34,197,94,0);  }
}


/* ═══════════════════════════════════════════════════════════════════
   CHECK ITEM — feature / deliverable list row
═══════════════════════════════════════════════════════════════════ */

.check-item {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  font-size: 1.0625rem;
  color: var(--ink-2);
  line-height: 1.6;
}
.check-mark {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  flex-shrink: 0;
  margin-top: 2px;
  background: var(--accent-soft);
  border: 1px solid rgba(232,73,15,.3);
  color: var(--accent);
}
.check-mark svg { width: 11px; height: 11px; }


/* ═══════════════════════════════════════════════════════════════════
   STACK STRIP — "Powered by" logo row
   Two variants:
     .stack-item       → has an <img> logo + <span> label
     .stack-item--text → text-only wordmark (no logo file needed)
═══════════════════════════════════════════════════════════════════ */

.stack-strip {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 20px;
  padding: 16px 0;
}

.stack-item {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  text-decoration: none;
  opacity: 0.62;
  filter: grayscale(1);
  transition: opacity 0.2s, filter 0.2s;
}
.stack-item:hover {
  opacity: 1;
  filter: none;
}
.stack-item img {
  height: 22px;
  width: auto;
  display: block;
}
.stack-item span {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  font-weight: 500;
  letter-spacing: 0.06em;
  color: var(--ink-3);
  white-space: nowrap;
}

/* Text-only variant: styled mono wordmark, no logo */
.stack-item--text {
  display: inline-flex;
  align-items: center;
  opacity: 0.62;
  filter: grayscale(1);
  transition: opacity 0.2s, filter 0.2s;
  text-decoration: none;
}
.stack-item--text:hover {
  opacity: 1;
  filter: none;
}
.stack-item--text span {
  font-family: var(--font-mono);
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  color: var(--ink-3);
  white-space: nowrap;
}


/* ═══════════════════════════════════════════════════════════════════
   TRUST ROW — compliance / security badges
═══════════════════════════════════════════════════════════════════ */

.trust-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
}
.trust-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 4px 10px;
  border-radius: var(--r-pill);
  border: 1px solid var(--border);
  background: var(--bg-tint);
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--ink-3);
  white-space: nowrap;
}
.trust-badge svg {
  width: 11px;
  height: 11px;
  flex-shrink: 0;
  color: var(--ok);
}


/* ═══════════════════════════════════════════════════════════════════
   QUOTE / MULTI-STEP WIZARD
   .quote-step         → one wizard step wrapper
   .quote-progress     → progress bar at top
   .quote-option       → selectable card
   .quote-option.selected / :has(input:checked) → checked state
═══════════════════════════════════════════════════════════════════ */

.quote-step {
  display: none;
}
.quote-step.active {
  display: block;
}

/* Thin progress bar */
.quote-progress {
  height: 4px;
  border-radius: var(--r-pill);
  background: var(--bg-tint-2);
  overflow: hidden;
  margin-bottom: 2rem;
}
.quote-progress-fill {
  height: 100%;
  background: var(--accent);
  border-radius: var(--r-pill);
  transition: width 0.35s cubic-bezier(0.4,0,.2,1);
}

/* Selectable option card */
.quote-option {
  position: relative;
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 16px 18px;
  border: 1.5px solid var(--border);
  border-radius: var(--r-lg);
  background: var(--bg);
  cursor: pointer;
  transition: border-color 0.15s, box-shadow 0.15s, background 0.15s;
  user-select: none;
}
.quote-option:hover {
  border-color: rgba(232,73,15,.35);
  background: var(--accent-soft);
}
.quote-option:focus-within {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(232,73,15,.22);
}
/* checked state — works with :has OR .selected class fallback */
.quote-option.selected,
.quote-option:has(input:checked) {
  border-color: var(--accent);
  background: var(--accent-soft);
  box-shadow: 0 0 0 3px rgba(232,73,15,.1);
}
.quote-option input[type="radio"],
.quote-option input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
/* Visual indicator dot */
.quote-option-indicator {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  border-radius: 50%;
  border: 1.5px solid var(--border-2);
  background: var(--bg);
  margin-top: 2px;
  transition: border-color 0.15s, background 0.15s;
  display: flex;
  align-items: center;
  justify-content: center;
}
.quote-option.selected .quote-option-indicator,
.quote-option:has(input:checked) .quote-option-indicator {
  border-color: var(--accent);
  background: var(--accent);
}
.quote-option.selected .quote-option-indicator::after,
.quote-option:has(input:checked) .quote-option-indicator::after {
  content: '';
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #fff;
  display: block;
}


/* ═══════════════════════════════════════════════════════════════════
   BYOK TOGGLE — segmented "Bring your own keys / We manage keys"
═══════════════════════════════════════════════════════════════════ */

.byok-toggle {
  display: inline-flex;
  gap: 2px;
  padding: 3px;
  border-radius: var(--r-lg);
  background: var(--bg-tint-2);
  border: 1px solid var(--border);
}
.byok-toggle input[type="radio"] {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}
.byok-option {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 16px;
  border-radius: calc(var(--r-lg) - 2px);
  font-family: var(--font-sans);
  font-size: 0.875rem;
  font-weight: 500;
  color: var(--ink-3);
  cursor: pointer;
  transition: background 0.15s, color 0.15s, box-shadow 0.15s;
  white-space: nowrap;
}
.byok-option:hover:not(.active) { color: var(--ink); }
.byok-option.active,
.byok-toggle input[type="radio"]:checked + .byok-option {
  background: var(--bg);
  color: var(--ink);
  box-shadow: var(--shadow-sm);
}
.byok-option svg {
  width: 14px;
  height: 14px;
  flex-shrink: 0;
}


/* ═══════════════════════════════════════════════════════════════════
   NAV (shared with header partial — styles scoped to #main-nav)
═══════════════════════════════════════════════════════════════════ */

#main-nav {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 100;
  transition: background 0.3s, border-color 0.3s, box-shadow 0.3s;
  border-bottom: 1px solid transparent;
}
#main-nav.scrolled {
  background: rgba(255,255,255,.94);
  backdrop-filter: blur(18px);
  -webkit-backdrop-filter: blur(18px);
  border-bottom-color: var(--border);
  box-shadow: 0 1px 0 rgba(0,0,0,.04);
}
.nav-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 var(--pad);
  height: 62px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}
.nav-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  flex-shrink: 0;
}
.nav-logo img {
  width: 34px;
  height: 34px;
  border-radius: 8px;
  display: block;
}
.nav-logo-word {
  font-family: var(--font-sans);
  font-size: 1.15rem;
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--ink);
}
.nav-links {
  display: flex;
  align-items: center;
  gap: 2px;
  list-style: none;
  padding: 0;
  margin: 0;
}
.nav-link {
  display: block;
  font-family: var(--font-sans);
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--ink-3);
  padding: 6px 11px;
  border-radius: var(--r-md);
  text-decoration: none;
  transition: color 0.15s, background 0.15s;
}
.nav-link:hover  { color: var(--ink); background: var(--bg-tint-2); }
.nav-link.active { color: var(--ink); }

.nav-cta { flex-shrink: 0; }

/* Hamburger button */
.nav-hamburger {
  display: none;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: var(--r-md);
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--ink-3);
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
  flex-shrink: 0;
}
.nav-hamburger:hover { background: var(--bg-tint-2); color: var(--ink); }

/* Mobile drawer */
#nav-drawer {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  left: var(--pad);
  right: var(--pad);
  border-radius: var(--r-xl);
  border: 1px solid var(--border);
  background: rgba(255,255,255,.97);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: 0 8px 30px rgba(0,0,0,.09);
  padding: 10px;
  opacity: 0;
  transform: translateY(-6px);
  transition: opacity 0.2s, transform 0.2s;
}
#nav-drawer.open {
  opacity: 1;
  transform: translateY(0);
}
.drawer-link {
  display: block;
  padding: 11px 14px;
  border-radius: var(--r-md);
  font-family: var(--font-sans);
  font-size: 1rem;
  font-weight: 500;
  color: var(--ink-3);
  text-decoration: none;
  transition: background 0.15s, color 0.15s;
}
.drawer-link:hover { background: var(--bg-tint-2); color: var(--ink); }
.drawer-sep {
  height: 1px;
  background: var(--border);
  margin: 8px 0;
}

@media (max-width: 768px) {
  .nav-links { display: none; }
  .nav-cta   { display: none; }
  .nav-hamburger { display: flex; }
  #nav-drawer    { display: block; }
}


/* ═══════════════════════════════════════════════════════════════════
   FOOTER
═══════════════════════════════════════════════════════════════════ */

#site-footer {
  border-top: 1px solid var(--border);
  background: var(--bg-tint);
}
.footer-inner {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 4rem var(--pad) 2rem;
}
.footer-grid {
  display: grid;
  grid-template-columns: 1.6fr 1fr 1fr 1fr;
  gap: 2.5rem;
  margin-bottom: 3rem;
}
@media (max-width: 900px) {
  .footer-grid {
    grid-template-columns: 1fr 1fr;
  }
  .footer-brand { grid-column: 1 / -1; }
}
@media (max-width: 540px) {
  .footer-grid { grid-template-columns: 1fr; }
}

.footer-col-label {
  font-family: var(--font-mono);
  font-size: 0.68rem;
  font-weight: 600;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--ink-3);
  margin-bottom: 14px;
}
.footer-links {
  list-style: none;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 9px;
}
.footer-links a {
  font-size: 0.9375rem;
  color: var(--ink-3);
  text-decoration: none;
  transition: color 0.15s;
}
.footer-links a:hover { color: var(--ink); }

.footer-bottom {
  border-top: 1px solid var(--border);
  padding-top: 20px;
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  align-items: center;
  justify-content: space-between;
}
.footer-copy {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--ink-3);
  letter-spacing: 0.04em;
}
.footer-legal {
  display: flex;
  gap: 16px;
}
.footer-legal a {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: var(--ink-3);
  text-decoration: none;
  transition: color 0.15s;
}
.footer-legal a:hover { color: var(--ink); }
.footer-social {
  display: flex;
  gap: 12px;
  margin-top: 16px;
}
.footer-social a {
  color: var(--ink-4);
  text-decoration: none;
  transition: color 0.15s;
}
.footer-social a:hover { color: var(--ink); }


/* ═══════════════════════════════════════════════════════════════════
   MISC UTILITIES
═══════════════════════════════════════════════════════════════════ */

/* Code block */
.code-block {
  background: var(--bg-dark);
  border: 1px solid #27272a;
  border-radius: var(--r-lg);
  padding: 20px 22px;
  font-family: var(--font-mono);
  font-size: 0.8125rem;
  line-height: 1.75;
  color: var(--ink-on-dark-2);
  overflow-x: auto;
}
.code-block .c-kw   { color: var(--accent); }
.code-block .c-str  { color: #86efac; }
.code-block .c-name { color: #93c5fd; }
.code-block .c-cmt  { color: #3f3f46; }
.code-block .c-ok   { color: #4ade80; }

/* Screenshot placeholder (when no real image exists) */
.screenshot-placeholder {
  width: 100%;
  aspect-ratio: 16/10;
  background: var(--bg-dark);
  background-image:
    linear-gradient(rgba(255,255,255,.025) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.025) 1px, transparent 1px);
  background-size: 32px 32px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.screenshot-placeholder span {
  font-family: var(--font-mono);
  font-size: 0.72rem;
  color: #3f3f46;
  letter-spacing: 0.08em;
}

/* Ticker / scrolling capabilities strip */
.ticker-wrap {
  overflow: hidden;
  position: relative;
}
.ticker-wrap::before,
.ticker-wrap::after {
  content: '';
  position: absolute;
  top: 0; bottom: 0;
  width: 72px;
  z-index: 2;
  pointer-events: none;
}
.ticker-wrap::before { left:  0; background: linear-gradient(to right, var(--bg-tint-2), transparent); }
.ticker-wrap::after  { right: 0; background: linear-gradient(to left,  var(--bg-tint-2), transparent); }
.ticker-track {
  display: flex;
  gap: 40px;
  white-space: nowrap;
  animation: ticker-scroll 38s linear infinite;
}
@keyframes ticker-scroll {
  from { transform: translateX(0); }
  to   { transform: translateX(-50%); }
}
.ticker-item {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-mono);
  font-size: 0.7rem;
  font-weight: 500;
  color: var(--ink-4);
  letter-spacing: 0.1em;
  text-transform: uppercase;
}
.ticker-dot {
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: var(--accent);
  opacity: 0.5;
  flex-shrink: 0;
}

/* Typed cursor */
.typed-cursor {
  display: inline-block;
  width: 2px;
  height: 0.8em;
  background: var(--accent);
  margin-left: 2px;
  vertical-align: middle;
  border-radius: 1px;
  animation: blink 0.9s step-end infinite;
}
@keyframes blink { 0%, 100% { opacity: 1; } 50% { opacity: 0; } }


/* ═══════════════════════════════════════════════════════════════════
   SCROLL REVEAL
   JS adds .in to [data-reveal] elements when they enter viewport.
   No JS fallback: reduced-motion overrides force visible.
═══════════════════════════════════════════════════════════════════ */

[data-reveal] {
  opacity: 0;
  transform: translateY(14px);
  transition: opacity .6s cubic-bezier(0.4,0,.2,1),
              transform .6s cubic-bezier(0.4,0,.2,1);
}
[data-reveal].in { opacity: 1; transform: none; }

[data-reveal][data-d="1"] { transition-delay: .08s; }
[data-reveal][data-d="2"] { transition-delay: .16s; }
[data-reveal][data-d="3"] { transition-delay: .24s; }
[data-reveal][data-d="4"] { transition-delay: .32s; }
[data-reveal][data-d="5"] { transition-delay: .40s; }


/* ═══════════════════════════════════════════════════════════════════
   GRID-3 — 3-col desktop → 2-col tablet → 1-col mobile
═══════════════════════════════════════════════════════════════════ */

.grid-3 {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(3, minmax(0, 1fr));
}
@media (max-width: 900px) {
  .grid-3 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 600px) {
  .grid-3 { grid-template-columns: 1fr; }
}

/* 2-col grid for 4-item sections (never 3+1 orphan) */
.grid-2 {
  display: grid;
  gap: 20px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
}
@media (max-width: 600px) { .grid-2 { grid-template-columns: 1fr; } }

/* Work gallery: equal-height cards, footer pinned, consistent thumbnail aspect */
.work-grid > article.card { display: flex; flex-direction: column; height: 100%; }
.work-grid > article.card > .browser-frame { flex-shrink: 0; }
.work-grid > article.card > div:last-child { display: flex; flex-direction: column; flex: 1 1 auto; }
.work-grid > article.card > div:last-child > div:last-child { margin-top: auto; }
.work-grid .browser-body { aspect-ratio: 16 / 10; }
.work-grid .browser-body img { width: 100%; height: 100%; object-fit: cover; object-position: top; display: block; }

/* ── Live "AI workforce → human gate → shipped" flow diagram ───────────── */
.wf-diagram{background:linear-gradient(160deg,#101014,#0b0b0e);border:1px solid #26262b;border-radius:var(--r-xl);padding:30px 22px;display:flex;align-items:stretch;justify-content:space-between;gap:6px;min-height:280px}
.wf-stage{display:flex;flex-direction:column;align-items:center;justify-content:center;gap:14px;flex:0 0 auto;text-align:center}
.wf-stage-label{font-family:var(--font-mono);font-size:.6rem;text-transform:uppercase;letter-spacing:.12em;color:var(--ink-on-dark-2)}
.wf-tasks{display:flex;flex-direction:column;gap:7px}
.wf-chip{font-size:.72rem;color:var(--ink-on-dark);background:#1c1c21;border:1px solid #34343a;border-radius:7px;padding:5px 11px;opacity:.5}
.wf-chip:nth-child(1){animation:wf-chip 4.2s infinite}
.wf-chip:nth-child(2){animation:wf-chip 4.2s infinite 1.4s}
.wf-chip:nth-child(3){animation:wf-chip 4.2s infinite 2.8s}
@keyframes wf-chip{0%,100%{opacity:.5;transform:translateX(0)}12%{opacity:1;border-color:var(--accent)}22%{opacity:.5}}
.wf-agents{display:flex;gap:8px}
.wf-agent{width:34px;height:34px;border-radius:9px;background:#1c1c21;border:1px solid #34343a;display:flex;align-items:center;justify-content:center}
.wf-agent::after{content:"";width:11px;height:11px;border-radius:3px;background:var(--accent);opacity:.35}
.wf-agent:nth-child(1){animation:wf-work 1.8s ease-in-out infinite}
.wf-agent:nth-child(2){animation:wf-work 1.8s ease-in-out infinite .35s}
.wf-agent:nth-child(3){animation:wf-work 1.8s ease-in-out infinite .7s}
@keyframes wf-work{0%,100%{box-shadow:0 0 0 0 rgba(232,73,15,0);border-color:#34343a}50%{box-shadow:0 0 0 4px rgba(232,73,15,.16);border-color:var(--accent)}}
.wf-gate{width:54px;height:54px;border-radius:50%;background:rgba(13,148,136,.12);border:1px solid #0d9488;display:flex;align-items:center;justify-content:center;color:#2dd4bf;animation:wf-gate 4.2s infinite}
.wf-gate svg{width:24px;height:24px}
@keyframes wf-gate{0%,55%,100%{box-shadow:0 0 0 0 rgba(45,212,191,0)}65%{box-shadow:0 0 0 6px rgba(45,212,191,.22)}}
.wf-gate-sub{font-family:var(--font-mono);font-size:.55rem;color:#2dd4bf;letter-spacing:.08em}
.wf-shipped{width:46px;height:46px;border-radius:11px;background:rgba(34,197,94,.1);border:1px solid #22c55e;display:flex;align-items:center;justify-content:center;color:#4ade80}
.wf-shipped svg{width:22px;height:22px}
.wf-flow{flex:1 1 auto;align-self:center;height:2px;background:#26262b;position:relative;min-width:20px;border-radius:2px}
.wf-flow::before{content:"";position:absolute;top:50%;width:7px;height:7px;border-radius:50%;background:var(--accent);box-shadow:0 0 9px var(--accent);transform:translate(-50%,-50%);animation:wf-travel 4.2s linear infinite}
.wf-flow.f2::before{animation-delay:1.4s}
.wf-flow.f3::before{animation-delay:2.8s}
@keyframes wf-travel{0%{left:0;opacity:0}8%{opacity:1}42%{left:100%;opacity:1}46%,100%{left:100%;opacity:0}}
@media (max-width:560px){ .wf-diagram{flex-direction:column;gap:14px;min-height:0;padding:24px} .wf-flow{width:2px;height:24px;min-width:0} .wf-flow::before{animation:none;top:auto;bottom:0} }
@media (prefers-reduced-motion: reduce){ .wf-chip,.wf-agent,.wf-gate,.wf-flow::before{animation:none!important} .wf-chip{opacity:1} }

/* ── Live Telegram chat (messages appear on a loop) ───────────────────── */
.tg-feed{padding:18px;display:flex;flex-direction:column;gap:11px;min-height:280px;justify-content:flex-end}
.tg-msg{max-width:84%;padding:10px 14px;opacity:0;transform:translateY(10px) scale(.97);animation:tg-in .34s ease forwards}
.tg-msg.bot{align-self:flex-start;background:var(--bg-tint-2);border:1px solid var(--border);border-radius:2px var(--r-lg) var(--r-lg) var(--r-lg)}
.tg-msg.user{align-self:flex-end;background:var(--accent-strong);border-radius:var(--r-lg) 2px var(--r-lg) var(--r-lg)}
.tg-msg.user .t-small{color:#fff}
@keyframes tg-in{to{opacity:1;transform:none}}
.tg-chips{display:flex;gap:6px;margin-top:10px;flex-wrap:wrap}
.tg-chip{padding:4px 10px;border:1px solid var(--border);border-radius:var(--r-pill);font-size:.76rem;color:var(--ink-3)}
.tg-approve{margin-top:9px;display:inline-flex;align-items:center;gap:7px;background:rgba(13,148,136,.1);border:1px solid #0d9488;color:#0f766e;border-radius:8px;padding:5px 11px;font-size:.76rem;font-weight:600}
.tg-typing{align-self:flex-start;display:inline-flex;gap:4px;background:var(--bg-tint-2);border:1px solid var(--border);border-radius:2px var(--r-lg) var(--r-lg) var(--r-lg);padding:12px 14px}
.tg-typing span{width:6px;height:6px;border-radius:50%;background:var(--ink-4);animation:tg-bounce 1.3s infinite}
.tg-typing span:nth-child(2){animation-delay:.18s}
.tg-typing span:nth-child(3){animation-delay:.36s}
@keyframes tg-bounce{0%,65%,100%{transform:translateY(0);opacity:.45}32%{transform:translateY(-4px);opacity:1}}
.tg-live{width:7px;height:7px;border-radius:50%;background:var(--ok);box-shadow:0 0 0 0 rgba(22,163,74,.5);animation:tg-live 2s infinite}
@keyframes tg-live{0%,100%{box-shadow:0 0 0 0 rgba(22,163,74,.5)}50%{box-shadow:0 0 0 5px rgba(22,163,74,0)}}
@media (prefers-reduced-motion: reduce){ .tg-msg{opacity:1!important;animation:none!important} .tg-typing span,.tg-live{animation:none} }

/* ── Case-study layout: content + sticky sidebar (no dead column) ──────── */
.cs-grid{display:grid;gap:48px;grid-template-columns:1fr}
.cs-grid > aside{display:none}
@media (min-width:900px){
  .cs-grid{grid-template-columns:minmax(0,1fr) 300px}
  .cs-grid > aside{display:block}
}


/* ═══════════════════════════════════════════════════════════════════
   LOGO CHIP — raven icon container, readable on any background
═══════════════════════════════════════════════════════════════════ */

.logo-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 5px;
  border-radius: 10px;
  background: var(--bg-tint);
  border: 1px solid var(--border);
  flex-shrink: 0;
}
.logo-chip img {
  width: 30px;
  height: 30px;
  display: block;
  border-radius: 6px;
}
/* On dark backgrounds: white chip so dark raven art pops */
.logo-chip.on-dark {
  background: #fafafa;
  border-color: transparent;
  box-shadow: 0 2px 8px rgba(0,0,0,.25);
}


/* ═══════════════════════════════════════════════════════════════════
   BRAND VISUAL — frame for dark Codex line-art on light pages
═══════════════════════════════════════════════════════════════════ */

.brand-visual {
  border-radius: var(--r-xl);
  border: 1px solid var(--border);
  overflow: hidden;
  background: var(--bg-dark);
  min-height: 200px;
}
.brand-visual img {
  display: block;
  width: 100%;
  height: auto;
}


/* ═══════════════════════════════════════════════════════════════════
   SKIP LINK — keyboard accessibility
═══════════════════════════════════════════════════════════════════ */

.skip-link {
  position: absolute;
  left: -9999px;
  top: auto;
  z-index: 999;
  text-decoration: none;
}
.skip-link:focus {
  left: 12px;
  top: 12px;
  z-index: 200;
  background: var(--ink);
  color: #fff;
  padding: 10px 14px;
  border-radius: var(--r-md);
  font-family: var(--font-sans);
  font-size: 0.9rem;
  font-weight: 600;
  outline: none;
}


/* ═══════════════════════════════════════════════════════════════════
   COOKIE BANNER — GDPR consent notice
═══════════════════════════════════════════════════════════════════ */

.cookie-banner {
  position: fixed;
  bottom: 18px;
  left: 50%;
  transform: translateX(-50%);
  width: calc(100% - 36px);
  max-width: 540px;
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 14px;
  box-shadow: var(--shadow-lg);
  padding: 18px 20px;
  z-index: 120;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.cookie-banner.hidden {
  display: none;
}
.cookie-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}


/* ═══════════════════════════════════════════════════════════════════
   A11Y — focus-visible ring + body text contrast
   :focus-visible already set above; this reinforces element scope
   and ensures --ink-4 is never used for paragraph copy.
═══════════════════════════════════════════════════════════════════ */

/* ═══════════════════════════════════════════════════════════════════
   CONTACT / QUOTE FORM — responsive two-column grid
═══════════════════════════════════════════════════════════════════ */

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}
@media (max-width: 560px) {
  .contact-grid { grid-template-columns: 1fr; }
}


a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible,
summary:focus-visible,
[tabindex]:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
  border-radius: var(--r-sm);
}

/* Orange text links in body content: use accent-strong for WCAG AA at small size */
a[style*="color:var(--accent)"],
a[style*="color: var(--accent)"] {
  color: var(--accent-strong) !important;
  text-decoration: underline;
}


/* ═══════════════════════════════════════════════════════════════════
   REDUCED MOTION — override ALL animation/transition
═══════════════════════════════════════════════════════════════════ */

@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
  [data-reveal] {
    opacity: 1 !important;
    transform: none !important;
    transition: none !important;
  }
  .ticker-track { animation: none !important; }
}
