/* ============================================================
   6 Degrees — Website Stylesheet
   Northvale Pixel Labs
   ============================================================ */

/* ---- Design tokens ---- */
:root {
  --bg: #040D22;
  --surface: #0B1730;
  --surface-2: #101E3A;
  --accent: #35C2FF;
  --accent-dim: #1a7aab;
  --text: #F4F7FB;
  --text-secondary: #A9B4C6;
  --text-muted: #8390A6;
  --border: #18284A;
  --radius: 14px;
  --radius-sm: 10px;
  --max-width: 920px;
  --header-height: 64px;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-mono: "SF Mono", "Fira Code", "Fira Mono", "Roboto Mono", monospace;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
body {
  font-family: var(--font-sans);
  background: var(--bg);
  color: var(--text);
  line-height: 1.65;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }

.container { width: 100%; max-width: var(--max-width); margin: 0 auto; padding: 0 20px; }
main { flex: 1 0 auto; }

.site-header {
  position: sticky; top: 0; z-index: 100; height: var(--header-height);
  background: rgba(4, 13, 34, 0.92);
  backdrop-filter: blur(12px); -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}
.header-inner { display: flex; align-items: center; justify-content: space-between; height: 100%; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; font-weight: 700; font-size: 1.2rem; color: var(--text); }
.brand-logo {
  display: inline-flex; align-items: center; justify-content: center;
  width: 38px; height: 38px; border-radius: 10px;
  background: linear-gradient(145deg, var(--accent), #1a8ec7);
  color: #040D22; font-size: 1.5rem; font-weight: 800; line-height: 1;
  box-shadow: 0 0 18px rgba(53, 194, 255, 0.35), inset 0 1px 0 rgba(255,255,255,0.3);
  text-shadow: 0 1px 2px rgba(0,0,0,0.2);
}
.brand-name { letter-spacing: -0.02em; }

.site-nav { display: flex; align-items: center; gap: 4px; }
.site-nav a {
  color: var(--text-secondary); font-size: 0.9rem; font-weight: 500;
  padding: 8px 12px; border-radius: 8px; transition: color 0.15s, background 0.15s; text-decoration: none;
}
.site-nav a:hover { color: var(--text); background: var(--surface-2); text-decoration: none; }
.site-nav a.active { color: var(--accent); background: rgba(53, 194, 255, 0.08); }
.nav-toggle {
  display: none; flex-direction: column; justify-content: center; gap: 5px;
  width: 40px; height: 40px; background: none; border: 1px solid var(--border); border-radius: 8px; cursor: pointer;
}
.nav-toggle span { display: block; width: 18px; height: 2px; margin: 0 auto; background: var(--text); border-radius: 2px; transition: transform 0.2s, opacity 0.2s; }
.nav-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
.nav-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

.site-footer { flex-shrink: 0; background: var(--surface); border-top: 1px solid var(--border); padding: 32px 0; margin-top: 48px; }
.footer-inner { display: flex; flex-direction: column; gap: 16px; align-items: center; text-align: center; }
.footer-nav { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px 4px; }
.footer-nav a { color: var(--text-muted); font-size: 0.85rem; padding: 6px 10px; border-radius: 6px; text-decoration: none; transition: color 0.15s; }
.footer-nav a:hover { color: var(--text-secondary); text-decoration: none; }
.copyright { color: var(--text-muted); font-size: 0.82rem; }

h1, h2, h3, h4 { line-height: 1.25; letter-spacing: -0.02em; font-weight: 700; }
h1 { font-size: clamp(1.9rem, 5vw, 3rem); }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.1rem); margin-bottom: 16px; }
h3 { font-size: 1.2rem; margin-bottom: 10px; }
p { margin-bottom: 14px; color: var(--text-secondary); }
.lead { font-size: 1.15rem; color: var(--text-secondary); margin-bottom: 24px; }
.section { padding: 56px 0; }
.eyebrow { display: inline-block; font-size: 0.78rem; font-weight: 600; letter-spacing: 0.08em; text-transform: uppercase; color: var(--accent); margin-bottom: 12px; }

.hero { text-align: center; padding: 64px 0 48px; }
.hero-logo {
  display: inline-flex; align-items: center; justify-content: center;
  width: 96px; height: 96px; border-radius: 24px;
  background: linear-gradient(160deg, var(--surface-2), var(--surface));
  border: 1px solid var(--border);
  box-shadow: 0 0 40px rgba(53, 194, 255, 0.18), inset 0 1px 0 rgba(255,255,255,0.05);
  margin-bottom: 28px; font-size: 3.8rem; font-weight: 800; line-height: 1;
  color: var(--accent); text-shadow: 0 0 24px rgba(53, 194, 255, 0.6), 0 2px 4px rgba(0,0,0,0.3);
}
.hero h1 { margin-bottom: 16px; }
.hero .lead { max-width: 600px; margin-left: auto; margin-right: auto; }

.store-buttons { display: flex; flex-wrap: wrap; justify-content: center; gap: 14px; margin: 32px 0; }
.store-btn {
  display: inline-flex; align-items: center; gap: 12px; padding: 12px 24px;
  background: var(--surface-2); border: 1px solid var(--border); border-radius: 12px;
  color: var(--text); text-decoration: none; transition: border-color 0.15s, background 0.15s, transform 0.1s; min-width: 200px;
}
.store-btn:hover { border-color: var(--accent-dim); background: var(--surface); text-decoration: none; transform: translateY(-1px); }
.store-btn:active { transform: translateY(0); }
.store-btn svg { width: 26px; height: 26px; flex-shrink: 0; }
.store-btn-text { display: flex; flex-direction: column; line-height: 1.2; text-align: left; }
.store-btn-text .small { font-size: 0.72rem; color: var(--text-muted); }
.store-btn-text .big { font-size: 1.05rem; font-weight: 600; color: var(--text); }

.word-chain {
  display: flex; flex-wrap: wrap; align-items: center; justify-content: center;
  gap: 8px 6px; padding: 32px 20px; background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); margin: 28px 0;
}
.word-chain .word {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 72px; padding: 12px 18px; border-radius: var(--radius-sm);
  font-weight: 700; font-size: 1.05rem; letter-spacing: 0.03em;
  background: var(--surface-2); border: 1px solid var(--border); color: var(--text);
}
.word-chain .word.revealed { background: rgba(53, 194, 255, 0.1); border-color: var(--accent-dim); color: var(--accent); }
.word-chain .word.hidden { color: var(--text-muted); background: var(--surface); border-style: dashed; }
.word-chain .arrow { color: var(--text-muted); font-size: 1.1rem; user-select: none; }

.card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 24px; }

.feature-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(240px, 1fr)); gap: 16px; margin: 28px 0; }
.feature { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 22px; transition: border-color 0.15s; }
.feature:hover { border-color: var(--accent-dim); }
.feature .icon { display: inline-flex; align-items: center; justify-content: center; width: 40px; height: 40px; border-radius: 10px; background: rgba(53, 194, 255, 0.1); color: var(--accent); margin-bottom: 14px; font-size: 1.3rem; }
.feature h3 { margin-bottom: 6px; color: var(--text); }
.feature p { font-size: 0.92rem; margin-bottom: 0; color: var(--text-secondary); }

.screenshot-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 16px; margin: 28px 0; }
.screenshot {
  aspect-ratio: 9 / 19; background: var(--surface); border: 1px solid var(--border); border-radius: 18px;
  display: flex; align-items: center; justify-content: center; color: var(--text-muted); font-size: 0.82rem; text-align: center; padding: 20px; position: relative; overflow: hidden;
}
.screenshot::before { content: ""; position: absolute; inset: 0; background: linear-gradient(180deg, transparent 60%, rgba(53, 194, 255, 0.04)); pointer-events: none; }

.btn { display: inline-flex; align-items: center; gap: 8px; padding: 12px 24px; border-radius: 10px; font-weight: 600; font-size: 0.95rem; border: none; cursor: pointer; text-decoration: none; transition: background 0.15s, transform 0.1s; }
.btn-primary { background: var(--accent); color: #040D22; }
.btn-primary:hover { background: #5ad0ff; text-decoration: none; transform: translateY(-1px); }
.btn-secondary { background: var(--surface-2); color: var(--text); border: 1px solid var(--border); }
.btn-secondary:hover { border-color: var(--accent-dim); text-decoration: none; }

.faq-item { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius-sm); margin-bottom: 12px; overflow: hidden; }
.faq-item summary { padding: 16px 20px; font-weight: 600; color: var(--text); cursor: pointer; list-style: none; display: flex; align-items: center; justify-content: space-between; gap: 12px; transition: background 0.15s; }
.faq-item summary::-webkit-details-marker { display: none; }
.faq-item summary::after { content: "+"; font-size: 1.3rem; color: var(--accent); flex-shrink: 0; transition: transform 0.2s; }
.faq-item[open] summary::after { transform: rotate(45deg); }
.faq-item summary:hover { background: var(--surface-2); }
.faq-item .answer { padding: 0 20px 16px; color: var(--text-secondary); font-size: 0.95rem; }

.prose { max-width: 760px; margin: 0 auto; }
.prose h1 { margin-bottom: 8px; }
.prose .meta { color: var(--text-muted); font-size: 0.88rem; margin-bottom: 28px; }
.prose h2 { font-size: 1.3rem; margin-top: 36px; margin-bottom: 12px; color: var(--text); }
.prose h3 { font-size: 1.05rem; margin-top: 22px; margin-bottom: 8px; color: var(--text); }
.prose p, .prose li { color: var(--text-secondary); font-size: 0.96rem; margin-bottom: 12px; }
.prose ul, .prose ol { padding-left: 22px; margin-bottom: 14px; }
.prose li { margin-bottom: 8px; }
.prose a { color: var(--accent); }
.prose .callout { background: var(--surface-2); border: 1px solid var(--border); border-left: 3px solid var(--accent); border-radius: 0 var(--radius-sm) var(--radius-sm) 0; padding: 16px 20px; margin: 20px 0; }
.prose .callout p { margin-bottom: 0; }

.contact-card { background: var(--surface); border: 1px solid var(--border); border-radius: var(--radius); padding: 32px; text-align: center; margin: 24px 0; }
.contact-card .email-link { display: inline-flex; align-items: center; gap: 10px; font-size: 1.2rem; font-weight: 600; color: var(--accent); margin: 12px 0; word-break: break-all; }

.page-header { text-align: center; padding: 48px 0 24px; }
.page-header h1 { margin-bottom: 12px; }
.page-header .lead { max-width: 580px; margin: 0 auto; }

.error-page { text-align: center; padding: 80px 20px; }
.error-page .code { font-size: 5rem; font-weight: 800; color: var(--accent); text-shadow: 0 0 30px rgba(53, 194, 255, 0.3); line-height: 1; margin-bottom: 16px; }

.text-center { text-align: center; }
.muted { color: var(--text-muted); }
.divider { height: 1px; background: var(--border); margin: 36px 0; border: none; }

@media (max-width: 720px) {
  .nav-toggle { display: flex; }
  .site-nav {
    position: fixed; top: var(--header-height); left: 0; right: 0; flex-direction: column; align-items: stretch; gap: 0;
    background: var(--surface); border-bottom: 1px solid var(--border); padding: 12px 20px 20px;
    transform: translateY(-120%); transition: transform 0.25s ease; box-shadow: 0 12px 24px rgba(0,0,0,0.3);
  }
  .site-nav.open { transform: translateY(0); }
  .site-nav a { padding: 14px 12px; font-size: 1rem; border-radius: 8px; }
  .hero { padding: 48px 0 36px; }
  .section { padding: 40px 0; }
  .word-chain { gap: 6px 4px; padding: 24px 14px; }
  .word-chain .word { min-width: 60px; padding: 10px 12px; font-size: 0.95rem; }
  .footer-inner { gap: 12px; }
}
@media (max-width: 420px) {
  .word-chain .word { min-width: 52px; padding: 8px 10px; font-size: 0.85rem; }
  .word-chain .arrow { font-size: 0.9rem; }
  .store-btn { min-width: unset; flex: 1; justify-content: center; }
}

:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; border-radius: 4px; }
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation-duration: 0.01ms !important; transition-duration: 0.01ms !important; scroll-behavior: auto !important; }
}
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
