/* SouthSea Labs — shared styles. Brand tokens live in :root for reuse across products. */
:root {
  --bg: #070b14;
  --bg-alt: #0a1120;
  --surface: #0e1728;
  --line: rgba(148, 163, 184, 0.14);
  --text: #e6edf7;
  --muted: #9aa8bc;
  --accent: #38bdf8;
  --accent-strong: #7dd3fc;
  --accept: #34d399;
  --marginal: #fbbf24;
  --skip: #fb7185;
  --radius: 14px;
  --container: 1120px;
  --font: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --ease: cubic-bezier(.2, .7, .2, 1);
  color-scheme: dark;
}

*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}
img, svg { display: block; max-width: 100%; }
h1, h2, h3 { line-height: 1.15; letter-spacing: -0.02em; margin: 0 0 .6em; font-weight: 650; }
h1 { font-size: clamp(2.3rem, 6vw, 3.9rem); }
h2 { font-size: clamp(1.75rem, 4vw, 2.6rem); }
h3 { font-size: 1.2rem; letter-spacing: -0.01em; }
p { margin: 0 0 1em; }
a { color: var(--accent-strong); text-underline-offset: 3px; }
ul { margin: 0; padding: 0; list-style: none; }

:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; border-radius: 6px; }
[id] { scroll-margin-top: 84px; }

.container { width: 100%; max-width: var(--container); margin: 0 auto; padding: 0 20px; }
.visually-hidden {
  position: absolute !important; width: 1px; height: 1px; overflow: hidden;
  clip: rect(0 0 0 0); clip-path: inset(50%); white-space: nowrap;
}
.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 100;
  background: var(--accent); color: #04121c; padding: 10px 16px; border-radius: 8px;
  font-weight: 600; text-decoration: none; transition: top .2s;
}
.skip-link:focus { top: 12px; }

.eyebrow {
  color: var(--accent); font-size: .8rem; font-weight: 600;
  letter-spacing: .14em; text-transform: uppercase; margin-bottom: 1rem;
}
.lead { font-size: clamp(1.08rem, 2vw, 1.22rem); color: var(--muted); max-width: 38em; }
.muted { color: var(--muted); }
.accent { color: var(--accent); white-space: nowrap; }

/* Buttons */
.cta-row { display: flex; flex-wrap: wrap; gap: 12px; margin-top: 1.75rem; }
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 48px; padding: 12px 22px; border-radius: 999px;
  font-weight: 600; font-size: .98rem; text-decoration: none;
  border: 1px solid transparent;
  transition: transform .2s var(--ease), background-color .2s, border-color .2s, color .2s;
}
.btn-primary { background: var(--accent); color: #04121c; }
.btn-primary[href]:hover { background: var(--accent-strong); transform: translateY(-1px); }
.btn-ghost { border-color: var(--line); color: var(--text); background: rgba(255, 255, 255, .02); }
.btn-ghost[href]:hover { border-color: rgba(56, 189, 248, .5); transform: translateY(-1px); }
/* Unconfigured ("coming soon") links have no href */
a.btn:not([href]) {
  background: transparent; color: var(--muted);
  border: 1px dashed var(--line); cursor: default;
}

/* Header */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(7, 11, 20, .78);
  -webkit-backdrop-filter: saturate(140%) blur(12px);
  backdrop-filter: saturate(140%) blur(12px);
  border-bottom: 1px solid var(--line);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 68px; }
.brand {
  display: inline-flex; align-items: center; gap: 10px;
  color: var(--text); text-decoration: none; font-size: 1.08rem; letter-spacing: -.01em;
}
.brand strong { font-weight: 650; color: var(--accent); }
.brand-mark { width: 30px; height: 30px; color: var(--text); }

.nav-toggle {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; background: none; border: 1px solid var(--line);
  border-radius: 10px; color: var(--text); cursor: pointer;
}
.nav-toggle-bar, .nav-toggle-bar::before, .nav-toggle-bar::after {
  display: block; width: 18px; height: 2px; background: currentColor; border-radius: 2px;
  position: relative; transition: transform .25s var(--ease), background-color .25s;
}
.nav-toggle-bar::before, .nav-toggle-bar::after { content: ""; position: absolute; left: 0; }
.nav-toggle-bar::before { top: -6px; }
.nav-toggle-bar::after { top: 6px; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar::before { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bar::after { transform: translateY(-6px) rotate(-45deg); }

.site-nav a {
  display: block; color: var(--text); text-decoration: none;
  padding: 10px 14px; border-radius: 8px; font-size: .97rem;
}
.site-nav a:hover { color: var(--accent-strong); }

/* Mobile nav: hidden behind toggle only when JS is available */
@media (max-width: 759px) {
  .js .site-nav {
    position: absolute; top: 68px; left: 0; right: 0;
    background: var(--bg); border-bottom: 1px solid var(--line);
    padding: 8px 20px 20px; display: none;
  }
  .js .site-nav.is-open { display: block; }
  .site-nav a { padding: 14px 4px; border-bottom: 1px solid var(--line); border-radius: 0; }
  html:not(.js) .nav-toggle { display: none; }
  html:not(.js) .header-inner { height: auto; flex-wrap: wrap; padding-top: 10px; }
  html:not(.js) .site-nav ul { display: flex; flex-wrap: wrap; }
}
@media (min-width: 760px) {
  .nav-toggle { display: none; }
  .site-nav ul { display: flex; align-items: center; gap: 4px; }
  .site-nav .nav-cta { border: 1px solid var(--line); border-radius: 999px; margin-left: 8px; padding: 8px 18px; }
  .site-nav .nav-cta:hover { border-color: rgba(56, 189, 248, .5); }
}

/* Hero */
.hero { position: relative; padding: 56px 0 72px; overflow: hidden; }
.hero::before {
  content: ""; position: absolute; inset: 0; pointer-events: none;
  background-image: linear-gradient(var(--line) 1px, transparent 1px), linear-gradient(90deg, var(--line) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(ellipse at 70% 40%, #000 0%, transparent 65%);
  mask-image: radial-gradient(ellipse at 70% 40%, #000 0%, transparent 65%);
  opacity: .45;
}
.hero-grid { position: relative; display: grid; gap: 40px; align-items: center; }
.hero-visual { max-width: 460px; margin: 0 auto; width: 100%; }
@media (min-width: 900px) {
  .hero { padding: 96px 0 120px; }
  .hero-grid { grid-template-columns: 1.1fr .9fr; gap: 56px; }
}

.network .orbit { fill: none; stroke: var(--line); stroke-dasharray: 2 6; }
.network .links path { fill: none; stroke: rgba(148, 163, 184, .28); stroke-width: 1.2; }
.network .flow path { stroke: var(--accent); stroke-width: 1.6; stroke-dasharray: 6 14; opacity: .8; animation: flow 6s linear infinite; }
.network .nodes circle { fill: var(--bg); stroke: var(--accent-strong); stroke-width: 2; }
.network .core { fill: var(--accent); }
.network .core-ring { fill: none; stroke: var(--accent); stroke-opacity: .45; transform-origin: 240px 190px; animation: pulse 4s var(--ease) infinite; }
.network .waves path { fill: none; stroke: rgba(56, 189, 248, .35); stroke-width: 1.5; stroke-linecap: round; }
.network .waves path + path { stroke: rgba(56, 189, 248, .18); }
@keyframes flow { to { stroke-dashoffset: -200; } }
@keyframes pulse {
  0% { transform: scale(.8); opacity: 1; }
  100% { transform: scale(1.9); opacity: 0; }
}

/* Sections */
.section { padding: 80px 0; border-top: 1px solid var(--line); }
.section-alt { background: var(--bg-alt); }
@media (min-width: 900px) { .section { padding: 112px 0; } }
.two-col { display: grid; gap: 24px; }
@media (min-width: 900px) { .two-col { grid-template-columns: 1fr 1.2fr; gap: 64px; } }
.prose p { color: var(--muted); }
.prose em { color: var(--text); font-style: normal; font-weight: 600; }

/* Products */
.product-list { display: grid; gap: 24px; margin-top: 40px; }
.product {
  display: grid; gap: 32px; padding: 28px;
  background: var(--surface); border: 1px solid var(--line); border-radius: calc(var(--radius) + 6px);
}
@media (min-width: 900px) {
  .product { grid-template-columns: 1.3fr .7fr; padding: 48px; align-items: center; }
}
.product-head { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.product-head h3 { font-size: 1.7rem; margin: 0; }
.tag {
  font-size: .75rem; font-weight: 600; letter-spacing: .06em; text-transform: uppercase;
  color: var(--accent-strong); border: 1px solid rgba(56, 189, 248, .35);
  padding: 3px 10px; border-radius: 999px;
}
.product-summary { color: var(--text); font-weight: 500; margin: .75rem 0 .5rem; }
.product-body > p { color: var(--muted); }
.fine-print { font-size: .85rem; margin-top: 1.5rem; color: var(--muted); }

.verdicts { display: grid; gap: 10px; margin: 1.5rem 0 0; }
.verdicts li { display: flex; align-items: center; gap: 12px; color: var(--muted); font-size: .97rem; }
.verdict {
  flex: none; min-width: 96px; text-align: center;
  font-size: .75rem; font-weight: 700; letter-spacing: .08em;
  padding: 4px 10px; border-radius: 6px; border: 1px solid;
}
.verdict-accept { color: var(--accept); border-color: rgba(52, 211, 153, .4); background: rgba(52, 211, 153, .08); }
.verdict-marginal { color: var(--marginal); border-color: rgba(251, 191, 36, .4); background: rgba(251, 191, 36, .08); }
.verdict-skip { color: var(--skip); border-color: rgba(251, 113, 133, .4); background: rgba(251, 113, 133, .08); }

.product-visual { display: flex; justify-content: center; }
.phone {
  width: 210px; padding: 18px 16px 22px; border-radius: 30px;
  background: linear-gradient(180deg, #0f1a2e, #0a1222);
  border: 1px solid rgba(148, 163, 184, .22);
  box-shadow: 0 30px 60px -30px rgba(56, 189, 248, .35);
}
.phone-notch { width: 60px; height: 6px; border-radius: 6px; background: rgba(148, 163, 184, .25); margin: 0 auto 22px; }
.phone-label { font-size: .75rem; color: var(--muted); letter-spacing: .08em; text-transform: uppercase; margin-bottom: 12px; }
.phone-lines span { display: block; height: 8px; border-radius: 4px; background: rgba(148, 163, 184, .18); margin-bottom: 9px; }
.phone-lines .short { width: 60%; }
.phone-verdict {
  margin: 20px 0 16px; padding: 14px 0; text-align: center; border-radius: 12px;
  font-weight: 700; letter-spacing: .12em; color: var(--accept);
  background: rgba(52, 211, 153, .1); border: 1px solid rgba(52, 211, 153, .4);
}
.phone-chips { display: flex; gap: 8px; justify-content: center; }
.chip { width: 28px; height: 6px; border-radius: 3px; opacity: .8; }
.chip-accept { background: var(--accept); }
.chip-marginal { background: var(--marginal); }
.chip-skip { background: var(--skip); }

/* Approach */
.principles { display: grid; gap: 16px; margin-top: 40px; }
@media (min-width: 640px) { .principles { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .principles { grid-template-columns: repeat(4, 1fr); } }
.principle {
  padding: 28px 24px; border: 1px solid var(--line); border-radius: var(--radius);
  background: linear-gradient(180deg, rgba(255, 255, 255, .02), transparent);
  transition: border-color .25s, transform .25s var(--ease);
}
.principle:hover { border-color: rgba(56, 189, 248, .35); transform: translateY(-2px); }
.principle svg {
  width: 28px; height: 28px; margin-bottom: 20px;
  fill: none; stroke: var(--accent); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round;
}
.principle p { color: var(--muted); font-size: .97rem; margin: 0; }

/* Contact */
.contact { max-width: 760px; text-align: center; }
.contact .lead { margin-left: auto; margin-right: auto; }
.contact-card {
  margin-top: 32px; padding: 28px; border: 1px solid var(--line);
  border-radius: var(--radius); background: var(--surface);
}
.contact-card p { margin: 0; }
.contact-email { display: inline-block; margin-top: 6px; font-size: clamp(1.1rem, 3vw, 1.4rem); font-weight: 600; word-break: break-word; }

/* Footer */
.site-footer { border-top: 1px solid var(--line); padding: 48px 0 40px; font-size: .95rem; }
.footer-inner { display: grid; gap: 28px; }
.footer-brand p { margin: 10px 0 0; }
.footer-links { display: flex; flex-wrap: wrap; gap: 6px 22px; }
.footer-links a { color: var(--text); text-decoration: none; display: inline-block; padding: 4px 0; }
.footer-links a[href]:hover { color: var(--accent-strong); }
.footer-links a:not([href]) { color: var(--muted); }
.footer-links a[href] .soon { display: none; }
.soon { font-size: .85em; }
.footer-legal { font-size: .85rem; margin: 0; padding-top: 24px; border-top: 1px solid var(--line); }
@media (min-width: 760px) {
  .footer-inner { grid-template-columns: 1fr auto; align-items: center; }
  .footer-legal { grid-column: 1 / -1; }
}

/* 404 */
.not-found { min-height: calc(100vh - 69px); display: grid; place-items: center; text-align: center; padding: 64px 0; }
.not-found .code { font-size: clamp(4rem, 16vw, 8rem); font-weight: 700; letter-spacing: -.04em; color: var(--accent); line-height: 1; margin-bottom: .2em; }
.not-found .cta-row { justify-content: center; }

/* Reveal (only added by JS) */
.reveal { opacity: 0; transform: translateY(16px); transition: opacity .7s var(--ease), transform .7s var(--ease); }
.reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; }
}
