/* Storypoint Technologies — Linear-inspired dark landing
   Palette derived from brand logo: teal, orange, yellow on near-black */

:root {
  /* Surfaces */
  --bg:          #070809;
  --bg-raised:  #0d0f11;
  --bg-card:    #121417;
  --bg-card-2:  #171a1e;
  --bg-hover:   #1c2025;
  --line:       rgba(255,255,255,0.06);
  --line-2:     rgba(255,255,255,0.1);
  --line-strong: rgba(255,255,255,0.14);

  /* Type */
  --ink:       #f2f3f5;
  --ink-2:     #c8cbd1;
  --ink-3:     #8a8f98;
  --ink-4:     #5a5f68;
  --ink-5:     #3a3e45;

  /* Brand — from the logo */
  --teal:      #2BB3B8;   /* primary arc */
  --teal-hi:   #5CD6DB;
  --teal-lo:   #1a8388;
  --orange:    #E86A3A;   /* secondary arc */
  --orange-hi: #FF8A5C;
  --yellow:    #F4B23F;   /* accent arc */
  --yellow-hi: #FFCB61;

  /* Semantic */
  --red:       #E5484D;
  --green:     #30A46C;
  --blue:      #3E63DD;
  --purple:    #8E4EC6;

  /* Type scale */
  --font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-mono: 'JetBrains Mono', ui-monospace, 'SF Mono', Menlo, monospace;
}

* { box-sizing: border-box; margin: 0; padding: 0; }
html, body {
  background: var(--bg);
  color: var(--ink);
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

a { color: inherit; text-decoration: none; }
button { font-family: inherit; cursor: pointer; border: none; background: none; color: inherit; }

/* ====================== Layout ====================== */
.wrap { max-width: 1240px; margin: 0 auto; padding: 0 32px; }
section { position: relative; }

/* Global ambient glow */
.ambient {
  position: fixed; inset: 0; pointer-events: none; z-index: 0;
  background:
    radial-gradient(800px 500px at 15% -5%, rgba(43,179,184,0.10), transparent 60%),
    radial-gradient(700px 500px at 95% 10%, rgba(232,106,58,0.06), transparent 60%),
    radial-gradient(900px 600px at 50% 110%, rgba(244,178,63,0.04), transparent 60%);
}

/* ====================== Nav ====================== */
.nav {
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(18px) saturate(140%);
  -webkit-backdrop-filter: blur(18px) saturate(140%);
  background: rgba(7,8,9,0.72);
  border-bottom: 1px solid var(--line);
}
.nav-inner {
  display: flex; align-items: center; justify-content: space-between;
  height: 60px;
}
.logo { display: flex; align-items: center; gap: 10px; }
.logo-mark { width: 26px; height: 26px; }
.nav .logo-mark { width: 38px; height: 38px; }
.logo-text {
  font-weight: 600; letter-spacing: -0.01em; font-size: 15px;
}
.logo-text .dim { color: var(--ink-3); font-weight: 400; }

.nav-links { display: flex; gap: 28px; align-items: center; }
.nav-links a {
  font-size: 13.5px; color: var(--ink-3); transition: color .15s;
}
.nav-links a:hover { color: var(--ink); }

.nav-cta { display: flex; gap: 10px; align-items: center; }

/* ====================== Buttons ====================== */
.btn {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 8px 14px; border-radius: 8px; font-size: 13.5px; font-weight: 500;
  transition: all .15s ease; white-space: nowrap;
}
.btn-ghost { color: var(--ink-2); }
.btn-ghost:hover { color: var(--ink); background: var(--bg-hover); }
.btn-line {
  color: var(--ink); border: 1px solid var(--line-2);
}
.btn-line:hover { background: var(--bg-hover); border-color: var(--line-strong); }
.btn-primary {
  color: #061214; background: var(--teal);
  box-shadow: 0 0 0 1px rgba(92,214,219,0.2), 0 8px 24px -10px rgba(43,179,184,0.5);
  font-weight: 600;
}
.btn-primary:hover {
  background: var(--teal-hi);
  box-shadow: 0 0 0 1px rgba(92,214,219,0.4), 0 12px 32px -10px rgba(43,179,184,0.7);
  transform: translateY(-1px);
}
.btn-lg { padding: 12px 20px; font-size: 14.5px; }

/* ====================== Hero ====================== */
.hero { padding: 80px 0 40px; position: relative; z-index: 1; }
.eyebrow {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-mono); font-size: 11.5px; letter-spacing: 0.04em;
  color: var(--teal); text-transform: uppercase;
  padding: 5px 10px; border: 1px solid rgba(43,179,184,0.25);
  background: rgba(43,179,184,0.06); border-radius: 100px;
}
.eyebrow .dot {
  width: 6px; height: 6px; border-radius: 50%; background: var(--teal);
  box-shadow: 0 0 10px var(--teal);
  animation: pulse 2s ease-in-out infinite;
}
@keyframes pulse { 0%,100% { opacity: 1; } 50% { opacity: 0.4; } }

h1.hero-title {
  font-size: clamp(44px, 6.2vw, 84px);
  line-height: 1.02; letter-spacing: -0.035em; font-weight: 600;
  margin: 22px 0 22px; max-width: 900px;
  text-wrap: balance;
}
h1.hero-title .grad {
  background: linear-gradient(92deg, var(--teal) 0%, var(--yellow) 55%, var(--orange) 100%);
  -webkit-background-clip: text; background-clip: text; color: transparent;
}
.hero-sub {
  font-size: 19px; color: var(--ink-3); max-width: 640px; line-height: 1.55;
  margin-bottom: 32px;
}
.hero-ctas { display: flex; gap: 12px; align-items: center; }
.hero-meta {
  display: flex; gap: 24px; margin-top: 48px; color: var(--ink-4); font-size: 12.5px;
  font-family: var(--font-mono);
}
.hero-meta span { display: flex; align-items: center; gap: 8px; }
.hero-meta .tick { color: var(--teal); }

/* ====================== Section headers ====================== */
.section-head { max-width: 780px; margin: 0 auto 56px; text-align: center; }
.section-eyebrow {
  font-family: var(--font-mono); font-size: 11.5px; letter-spacing: 0.1em;
  color: var(--ink-3); text-transform: uppercase;
}
.section-head h2 {
  font-size: clamp(32px, 4vw, 48px); line-height: 1.08; letter-spacing: -0.025em;
  font-weight: 600; margin: 12px 0 16px; text-wrap: balance;
}
.section-head p { color: var(--ink-3); font-size: 17px; text-wrap: pretty; }

/* ====================== Spacing rhythm ====================== */
.s-pad { padding: 120px 0; }
.s-pad-sm { padding: 80px 0; }

/* Divider */
.rule {
  height: 1px; background: linear-gradient(90deg, transparent, var(--line-strong), transparent);
}

/* ====================== Board demo shell ====================== */
.demo-shell {
  border: 1px solid var(--line-2);
  background: linear-gradient(180deg, var(--bg-card) 0%, var(--bg-raised) 100%);
  border-radius: 14px; overflow: hidden;
  box-shadow:
    0 0 0 1px rgba(255,255,255,0.02) inset,
    0 30px 80px -30px rgba(0,0,0,0.8),
    0 0 60px -20px rgba(43,179,184,0.12);
  position: relative;
}
.demo-chrome {
  display: flex; align-items: center; gap: 12px;
  padding: 10px 14px; border-bottom: 1px solid var(--line);
  background: rgba(255,255,255,0.015);
}
.chrome-dots { display: flex; gap: 6px; }
.chrome-dots span {
  width: 10px; height: 10px; border-radius: 50%;
  background: var(--ink-5);
}
.chrome-title {
  font-family: var(--font-mono); font-size: 11.5px; color: var(--ink-4);
  letter-spacing: 0.02em;
}

/* ====================== Footer ====================== */
footer {
  border-top: 1px solid var(--line);
  padding: 56px 0 40px; margin-top: 60px;
  color: var(--ink-4); font-size: 13px;
}
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 48px; margin-bottom: 40px; }
.footer-col h4 { font-size: 13px; color: var(--ink-2); margin-bottom: 14px; font-weight: 500; }
.footer-col a { display: block; padding: 4px 0; color: var(--ink-4); }
.footer-col a:hover { color: var(--ink-2); }
.footer-bottom { display: flex; justify-content: space-between; padding-top: 24px; border-top: 1px solid var(--line); font-family: var(--font-mono); font-size: 11.5px; }

/* ====================== Noise overlay ====================== */
.noise {
  position: fixed; inset: 0; pointer-events: none; z-index: 100;
  opacity: 0.015; mix-blend-mode: overlay;
  background-image: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='160' height='160'><filter id='n'><feTurbulence baseFrequency='0.9' numOctaves='2'/></filter><rect width='100%25' height='100%25' filter='url(%23n)'/></svg>");
}

/* ====================== Tweaks Panel ====================== */
.tweaks-panel {
  position: fixed; bottom: 20px; right: 20px; z-index: 200;
  width: 280px;
  background: rgba(13,15,17,0.96);
  backdrop-filter: blur(20px);
  border: 1px solid var(--line-strong);
  border-radius: 12px; padding: 16px;
  box-shadow: 0 20px 60px -20px rgba(0,0,0,0.8);
  display: none;
}
.tweaks-panel.active { display: block; }
.tweaks-header { display: flex; justify-content: space-between; align-items: center; margin-bottom: 14px; }
.tweaks-header h4 { font-size: 12px; color: var(--ink-3); font-family: var(--font-mono); letter-spacing: 0.08em; text-transform: uppercase; font-weight: 500; }
.tweak-group { margin-bottom: 14px; }
.tweak-label { font-size: 11px; color: var(--ink-4); margin-bottom: 6px; font-family: var(--font-mono); text-transform: uppercase; letter-spacing: 0.06em; }
.tweak-swatches { display: flex; gap: 6px; }
.tweak-swatch { width: 28px; height: 28px; border-radius: 6px; border: 2px solid transparent; cursor: pointer; transition: all .15s; }
.tweak-swatch.active { border-color: var(--ink); }
.tweak-options { display: flex; gap: 4px; flex-wrap: wrap; }
.tweak-opt { padding: 5px 10px; font-size: 11px; border-radius: 5px; border: 1px solid var(--line-2); color: var(--ink-3); cursor: pointer; transition: all .15s; }
.tweak-opt.active { background: var(--teal); color: #061214; border-color: var(--teal); }

/* Responsive */
@media (max-width: 900px) {
  .nav-links { display: none; }
  .footer-grid { grid-template-columns: 1fr 1fr; gap: 32px; }
  .hero-meta { flex-wrap: wrap; }
}
