/* CueView — site styles */

:root {
  --bg: #000;
  --bg-elev: #0a0a0a;
  --bg-card: #111;
  --border: #1f1f1f;
  --fg: #fff;
  --fg-muted: #b3b3b3;
  --fg-dim: #8a8a8a;
  --green: #34c759;
  --amber: #ff9500;
  --red: #ff3b30;
  --link: #5ac8fa;
  --link-hover: #82d8fc;
  --radius: 14px;
  --radius-sm: 8px;
  --maxw: 1080px;
  --pad: clamp(20px, 4vw, 40px);
  --font-display: "SF Pro Rounded", -apple-system, BlinkMacSystemFont, "Nunito",
    "Quicksand", system-ui, sans-serif;
  --font-body: -apple-system, BlinkMacSystemFont, system-ui, "Segoe UI", Roboto,
    "Helvetica Neue", Arial, sans-serif;
}

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

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

body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font-family: var(--font-body);
  font-size: 17px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

h1, h2, h3, h4 {
  font-family: var(--font-display);
  font-weight: 600;
  letter-spacing: -0.01em;
  line-height: 1.2;
  margin: 0 0 0.5em;
}

h1 { font-size: clamp(2rem, 5.5vw, 3.25rem); letter-spacing: -0.02em; }
h2 { font-size: clamp(1.5rem, 3.5vw, 2.1rem); margin-top: 2em; }
h3 { font-size: 1.2rem; margin-top: 1.8em; }

p { margin: 0 0 1em; color: var(--fg-muted); }
p.lead { color: var(--fg); font-size: 1.1rem; }

a {
  color: var(--link);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
}
a:hover { color: var(--link-hover); }
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--link);
  outline-offset: 3px;
  border-radius: 4px;
}

ul, ol { padding-left: 1.4em; margin: 0 0 1em; color: var(--fg-muted); }
li { margin-bottom: 0.4em; }

code, pre, kbd {
  font-family: ui-monospace, SFMono-Regular, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.95em;
}
code {
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 0.1em 0.4em;
  border-radius: 5px;
  color: var(--fg);
}
pre {
  background: var(--bg-card);
  border: 1px solid var(--border);
  padding: 1em 1.2em;
  border-radius: var(--radius-sm);
  overflow-x: auto;
  line-height: 1.5;
}
pre code { background: none; border: none; padding: 0; }

hr {
  border: 0;
  border-top: 1px solid var(--border);
  margin: 3em 0;
}

img { max-width: 100%; height: auto; display: block; }

/* Layout primitives */
.container {
  max-width: var(--maxw);
  margin: 0 auto;
  padding-left: var(--pad);
  padding-right: var(--pad);
}

.section { padding: clamp(48px, 7vw, 88px) 0; }
.section--tight { padding: clamp(32px, 5vw, 56px) 0; }

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: rgba(0, 0, 0, 0.78);
  backdrop-filter: saturate(140%) blur(14px);
  -webkit-backdrop-filter: saturate(140%) blur(14px);
  border-bottom: 1px solid var(--border);
}
.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  height: 60px;
}
.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--fg);
  text-decoration: none;
  font-size: 1rem;
  letter-spacing: -0.01em;
}
.brand-mark { width: 24px; height: 24px; display: block; }
.brand-name { white-space: nowrap; }
@media (max-width: 380px) {
  .brand-name { display: none; }
}

.site-nav {
  display: flex;
  gap: 6px;
  font-family: var(--font-display);
  font-size: 0.95rem;
}
.site-nav a {
  color: var(--fg-muted);
  text-decoration: none;
  padding: 8px 12px;
  border-radius: 8px;
}
.site-nav a:hover { color: var(--fg); background: var(--bg-elev); }
.site-nav a[aria-current="page"] { color: var(--fg); }

/* Hero */
.hero {
  padding: clamp(48px, 8vw, 96px) 0 clamp(40px, 6vw, 72px);
  position: relative;
  overflow: hidden;
}
.hero::after {
  content: "";
  position: absolute;
  inset: -30% -10% auto -10%;
  height: 60%;
  background: radial-gradient(
    ellipse at 50% 0%,
    rgba(52, 199, 89, 0.06),
    transparent 60%
  );
  pointer-events: none;
  z-index: 0;
}
.hero .container {
  position: relative;
  z-index: 1;
  display: grid;
  gap: clamp(32px, 5vw, 56px);
  grid-template-columns: 1fr;
  align-items: center;
}
@media (min-width: 820px) {
  .hero .container { grid-template-columns: 1.05fr 0.95fr; }
}
.hero-eyebrow {
  display: inline-block;
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--fg-dim);
  margin-bottom: 12px;
}
.hero h1 { margin-bottom: 16px; }
.hero-tagline {
  font-size: clamp(1.1rem, 1.8vw, 1.25rem);
  color: var(--fg-muted);
  max-width: 38ch;
  margin: 0 0 28px;
}
.cta-row {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 16px 20px;
}
.appstore-link {
  display: inline-flex;
  flex-direction: column;
  gap: 6px;
  text-decoration: none;
}
.appstore-badge {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: #fff;
  color: #000;
  padding: 10px 18px;
  border-radius: 10px;
  font-family: var(--font-display);
  font-weight: 600;
  text-decoration: none;
  font-size: 0.95rem;
  transition: transform 120ms ease;
}
.appstore-badge:hover { transform: translateY(-1px); }
.appstore-badge svg { width: 22px; height: 22px; }
.appstore-badge .badge-prefix {
  font-size: 0.7rem;
  font-weight: 400;
  letter-spacing: 0.02em;
  opacity: 0.7;
  display: block;
  line-height: 1;
  margin-bottom: 2px;
}
.appstore-badge .badge-name {
  display: block;
  line-height: 1.05;
}
.appstore-caption {
  font-size: 0.85rem;
  color: var(--fg-dim);
  margin: 0;
}
.btn-secondary {
  display: inline-block;
  padding: 12px 18px;
  background: var(--bg-elev);
  color: var(--fg);
  border: 1px solid #3a3a3a;
  border-radius: 10px;
  font-family: var(--font-display);
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  transition: border-color 120ms ease, background 120ms ease, transform 120ms ease;
}
.btn-secondary:hover { border-color: #555; background: #1a1a1a; color: var(--fg); transform: translateY(-1px); }

.hero-visual {
  display: flex;
  justify-content: center;
}
.hero-visual img {
  max-width: 320px;
  width: 100%;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  box-shadow:
    0 8px 30px rgba(0, 0, 0, 0.5),
    0 0 0 1px rgba(255, 255, 255, 0.02) inset;
}
.hero-stack {
  display: grid;
  grid-template: 1fr / 1fr;
  max-width: 320px;
  width: 100%;
}
.hero-stack img { grid-area: 1 / 1; }
.hero-stack .hero-img--alt {
  opacity: 0;
  animation: hero-crossfade 4s ease-in-out infinite;
}
@keyframes hero-crossfade {
  0%, 45%   { opacity: 0; }
  50%, 95%  { opacity: 1; }
  100%      { opacity: 0; }
}
@media (prefers-reduced-motion: reduce) {
  .hero-stack .hero-img--alt { animation: none; }
}

/* "What it does" */
.prose { max-width: 70ch; }
.prose p { font-size: 1.05rem; color: var(--fg-muted); }

/* Feature strip */
.features {
  display: grid;
  gap: 24px;
  grid-template-columns: 1fr;
}
@media (min-width: 720px) {
  .features { grid-template-columns: repeat(3, 1fr); }
}
.feature {
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 24px;
}
.feature-icon {
  width: 28px;
  height: 28px;
  color: var(--green);
  margin-bottom: 14px;
}
.feature h3 {
  font-size: 1.05rem;
  margin: 0 0 6px;
  color: var(--fg);
}
.feature p { margin: 0; font-size: 0.95rem; }

/* How it works */
.steps {
  counter-reset: step;
  display: grid;
  gap: 18px;
  grid-template-columns: 1fr;
  margin: 0;
  padding: 0;
  list-style: none;
}
@media (min-width: 720px) {
  .steps { grid-template-columns: repeat(3, 1fr); }
}
.steps li {
  counter-increment: step;
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 22px 22px 22px 64px;
  position: relative;
  color: var(--fg-muted);
  margin: 0;
}
.steps li::before {
  content: counter(step);
  position: absolute;
  top: 22px;
  left: 22px;
  width: 30px;
  height: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #1a1a1a;
  color: var(--green);
  font-family: var(--font-display);
  font-weight: 700;
  border-radius: 8px;
  font-size: 0.95rem;
}

/* Price block */
.price-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: clamp(24px, 4vw, 36px);
  max-width: 70ch;
}
.price-card h2 {
  margin-top: 0;
  font-size: 1.15rem;
  color: var(--fg-dim);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}
.price-card p { color: var(--fg-muted); }
.price-card p:last-child { margin-bottom: 0; }

/* Screenshots */
.screenshots {
  display: grid;
  gap: 24px;
  grid-template-columns: 1fr;
  justify-items: center;
}
@media (min-width: 720px) {
  .screenshots { grid-template-columns: repeat(3, 1fr); align-items: end; }
}
.screenshot {
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: var(--bg-elev);
  padding: 12px;
  max-width: 360px;
  width: 100%;
}
.screenshot img { border-radius: 10px; }

/* Setup page */
.toc {
  background: var(--bg-elev);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 16px 20px;
  margin-bottom: 2.5em;
  font-family: var(--font-display);
}
.toc h2 {
  font-size: 0.85rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--fg-dim);
  margin: 0 0 8px;
}
.toc ol { padding-left: 1.2em; margin: 0; }
.toc a { text-decoration: none; }
.toc a:hover { text-decoration: underline; }

.section-heading {
  scroll-margin-top: 80px;
  display: flex;
  align-items: baseline;
  gap: 14px;
  margin-top: 2.4em;
}
.section-heading .num {
  color: var(--green);
  font-family: var(--font-display);
  font-size: 0.95rem;
  letter-spacing: 0.04em;
}

.callout {
  background: var(--bg-elev);
  border-left: 3px solid var(--green);
  border-radius: var(--radius-sm);
  padding: 14px 18px;
  margin: 1.2em 0;
  color: var(--fg-muted);
  font-size: 0.97rem;
}
.callout strong { color: var(--fg); }

.status-key {
  list-style: none;
  padding: 0;
  margin: 0.8em 0;
  display: grid;
  gap: 10px;
}
.status-key li {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 0;
}
.dot {
  display: inline-block;
  width: 12px;
  height: 12px;
  border-radius: 50%;
  flex-shrink: 0;
  box-shadow: 0 0 8px currentColor;
}
.dot.green { background: var(--green); color: var(--green); }
.dot.amber { background: var(--amber); color: var(--amber); }
.dot.red { background: var(--red); color: var(--red); }

.download-btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: var(--green);
  color: #001b08;
  font-family: var(--font-display);
  font-weight: 700;
  padding: 12px 18px;
  border-radius: 10px;
  text-decoration: none;
  margin: 0.4em 0 0.8em;
}
.download-btn:hover { background: #2eb850; color: #001b08; }
.download-btn svg { width: 18px; height: 18px; }

.trouble dt {
  color: var(--fg);
  font-family: var(--font-display);
  font-weight: 600;
  margin-top: 1.2em;
}
.trouble dd {
  margin: 0.3em 0 0;
  color: var(--fg-muted);
}

/* Privacy page */
.doc h2 { margin-top: 2.2em; }
.doc hr { margin: 2.4em 0; }

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 40px 0 56px;
  color: var(--fg-dim);
  font-size: 0.92rem;
}
.site-footer .container {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 24px;
  align-items: center;
  justify-content: space-between;
}
.site-footer a { color: var(--fg-muted); text-decoration: none; }
.site-footer a:hover { color: var(--fg); text-decoration: underline; }
.footer-links { display: flex; gap: 18px; flex-wrap: wrap; }

/* Utility */
.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;
}

/* Skip link */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--fg);
  color: var(--bg);
  padding: 10px 14px;
  border-radius: 8px;
  font-family: var(--font-display);
  font-weight: 600;
  z-index: 100;
}
.skip-link:focus { left: 12px; top: 12px; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; }
}
