:root {
  --bg-deep: #061821;
  --bg-mid: #0d3a52;
  --bg-elev: #102a3a;
  --text-primary: #e8f1f5;
  --text-muted: #8aa9b8;
  --accent: #5ab8d8;
  --accent-hover: #7dccea;
  --border-subtle: rgba(255, 255, 255, 0.08);

  --max-w: 1100px;
  --radius: 8px;
  --shadow-soft: 0 4px 20px rgba(0, 0, 0, 0.35);
}

* { box-sizing: border-box; }

html, body {
  margin: 0;
  padding: 0;
  background: var(--bg-deep);
  color: var(--text-primary);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

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

a { color: var(--accent); text-decoration: none; }
a:hover { color: var(--accent-hover); text-decoration: underline; }

h1, h2, h3 {
  line-height: 1.2;
  margin: 0 0 0.75rem;
  color: var(--text-primary);
}

h1 { font-size: clamp(1.75rem, 4vw, 2.75rem); }
h2 { font-size: clamp(1.5rem, 3vw, 2.1rem); margin-bottom: 1.5rem; }
h3 { font-size: 1.15rem; }

p { margin: 0 0 1rem; }

.container {
  width: 100%;
  max-width: var(--max-w);
  margin: 0 auto;
  padding: 0 1.5rem;
}
.container.narrow { max-width: 760px; }

.btn {
  display: inline-block;
  padding: 1rem 2rem;
  border-radius: var(--radius);
  font-weight: 600;
  text-decoration: none;
  transition: transform 0.12s ease, background-color 0.15s ease, filter 0.15s ease;
  letter-spacing: 0.01em;
}
.btn-primary {
  background: var(--accent);
  color: var(--bg-deep);
}
.btn-primary:hover {
  background: var(--accent-hover);
  color: var(--bg-deep);
  text-decoration: none;
  transform: translateY(-1px);
  filter: brightness(1.05);
}

/* ---------- Hero ---------- */
.hero {
  background-image:
    linear-gradient(180deg, rgba(6, 24, 33, 0.55) 0%, rgba(6, 24, 33, 0.85) 100%), url('public/hero-bg.jpg');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  min-height: 80vh;
  display: flex;
  align-items: center;
  padding: 4rem 0;
}
@media (min-width: 720px) {
  .hero { min-height: 100vh; }
}
.hero-inner {
  text-align: center;
}
.hero-logo {
  max-width: 240px;
  margin: 0 auto 2rem;
  border-radius: var(--radius);
  opacity: 0.95;
}
.hero-sub {
  font-size: 1.15rem;
  color: var(--text-muted);
  max-width: 38rem;
  margin: 0 auto 2rem;
}
.hero-cta-row { margin: 0 0 1rem; }
.hero-secondary {
  font-size: 0.95rem;
  color: var(--text-muted);
  margin: 0;
}
.hero-secondary a { color: var(--accent); }

/* ---------- Section base ---------- */
.section {
  padding: 4rem 0;
  border-top: 1px solid var(--border-subtle);
}
.section-alt {
  background: var(--bg-elev);
}

@media (max-width: 720px) {
  .section { padding: 2.5rem 0; }
}

/* ---------- Feature grid ---------- */
.feature-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}
@media (min-width: 720px) {
  .feature-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1024px) {
  .feature-grid { grid-template-columns: repeat(3, 1fr); }
}
.tile {
  background: var(--bg-deep);
  border: 1px solid var(--border-subtle);
  border-radius: var(--radius);
  padding: 1.5rem;
}
.tile-icon {
  font-size: 1.75rem;
  display: block;
  margin-bottom: 0.5rem;
}
.tile h3 { margin-bottom: 0.5rem; }
.tile p { color: var(--text-muted); margin: 0; }

/* ---------- Steps ---------- */
.steps {
  list-style: none;
  counter-reset: step;
  margin: 0;
  padding: 0;
}
.steps > li {
  counter-increment: step;
  position: relative;
  padding-left: 3.5rem;
  margin-bottom: 1.75rem;
}
.steps > li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: 0;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  background: var(--accent);
  color: var(--bg-deep);
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}
.steps h3 { margin-bottom: 0.25rem; }
.steps p { color: var(--text-muted); margin: 0; }

.protip {
  margin-top: 1.5rem;
  padding: 1rem 1.25rem;
  background: rgba(90, 184, 216, 0.08);
  border-left: 3px solid var(--accent);
  border-radius: 0 var(--radius) var(--radius) 0;
  color: var(--text-primary);
}

/* ---------- Screenshots ---------- */
.screenshot-grid {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.25rem;
}
@media (min-width: 720px) {
  .screenshot-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (min-width: 1024px) {
  .screenshot-grid { grid-template-columns: repeat(3, 1fr); }
}
.screenshot {
  position: relative;
  display: block;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-deep);
  border: 1px solid var(--border-subtle);
  aspect-ratio: 16 / 10;
  transition: transform 0.12s ease, box-shadow 0.15s ease;
}
.screenshot:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-soft);
  text-decoration: none;
}
.screenshot img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}
.screenshot-caption {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 1rem;
  background: rgba(6, 24, 33, 0.65);
  color: var(--text-primary);
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.9rem;
  line-height: 1.4;
}

/* ---------- Support band ---------- */
.section-support {
  background: #04111a;
  text-align: center;
}
.support-cta-row { margin: 1.5rem 0 0.75rem; }
.support-fineprint {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin: 0;
}

/* ---------- Footer ---------- */
.footer {
  padding: 1.5rem 0;
  border-top: 1px solid var(--border-subtle);
  background: var(--bg-deep);
  color: var(--text-muted);
  font-size: 0.9rem;
}
.footer-inner {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  align-items: flex-start;
  justify-content: space-between;
}
@media (min-width: 720px) {
  .footer-inner { flex-direction: row; align-items: center; }
}
.footer-left { margin: 0; }
.footer-links { display: flex; gap: 1.25rem; flex-wrap: wrap; }
.footer-links a { color: var(--text-muted); }
.footer-links a:hover { color: var(--accent-hover); }

/* ---------- Lightbox ---------- */
.lightbox {
  position: fixed;
  inset: 0;
  background: rgba(4, 17, 26, 0.92);
  display: none;
  align-items: center;
  justify-content: center;
  padding: 2rem;
  z-index: 1000;
}
.lightbox.lightbox-open { display: flex; }
.lightbox img {
  max-width: 100%;
  max-height: 100%;
  border-radius: var(--radius);
  box-shadow: var(--shadow-soft);
}
.lightbox-close {
  position: absolute;
  top: 1rem;
  right: 1rem;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  border: 1px solid var(--border-subtle);
  background: var(--bg-deep);
  color: var(--text-primary);
  font-size: 1.5rem;
  line-height: 1;
  cursor: pointer;
}
.lightbox-close:hover { background: var(--bg-mid); }

.hero-logo { display: none; }
