:root {
  --brand: #fc7b07;
  --brand-light: #ff9a3d;
  --brand-dark: #c45f00;
  --bg: #070b14;
  --bg-deep: #140c06;
  --surface: #111827;
  --surface-elevated: #1c1814;
  --text: #ffffff;
  --text-secondary: #a6b0c1;
  --border: #3a2e24;
  --link: #58a9ff;
  --success: #2ed573;
  --error: #ff4d4f;
  --radius: 14px;
  --max-width: 1120px;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: system-ui, -apple-system, "SF Pro Rounded", "Segoe UI", sans-serif;
  background: linear-gradient(165deg, var(--bg) 0%, var(--bg-deep) 100%);
  background-attachment: fixed;
  color: var(--text);
  line-height: 1.6;
  min-height: 100vh;
}

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

a {
  color: var(--link);
  text-decoration: none;
}

a:hover {
  text-decoration: underline;
}

.container {
  width: min(100% - 2rem, var(--max-width));
  margin-inline: auto;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(7, 11, 20, 0.88);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 0.85rem 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  color: var(--text);
  text-decoration: none;
  font-weight: 700;
  font-size: 1.15rem;
}

.brand:hover {
  text-decoration: none;
}

.brand-logo {
  width: 36px;
  height: 36px;
  border-radius: 8px;
}

.brand-name {
  background: linear-gradient(135deg, var(--brand-light), var(--brand));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.nav-toggle {
  display: none;
  background: none;
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: 8px;
  padding: 0.4rem 0.65rem;
  cursor: pointer;
}

.nav-links {
  display: flex;
  align-items: center;
  gap: 1.5rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.nav-links a {
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.95rem;
}

.nav-links a:hover {
  color: var(--text);
  text-decoration: none;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  padding: 0.7rem 1.25rem;
  border-radius: 999px;
  font-weight: 600;
  font-size: 0.95rem;
  text-decoration: none;
  border: none;
  cursor: pointer;
  transition: transform 0.15s, opacity 0.15s;
}

.btn:hover {
  text-decoration: none;
  transform: translateY(-1px);
}

.btn-primary {
  background: linear-gradient(135deg, var(--brand-light), var(--brand-dark));
  color: var(--text);
  box-shadow: 0 4px 20px rgba(252, 123, 7, 0.25);
}

.btn-secondary {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-sm {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
}

/* Hero */
.hero {
  padding: 4rem 0 3rem;
  text-align: center;
}

.hero-logo {
  width: 120px;
  height: 120px;
  margin: 0 auto 1.5rem;
  border-radius: 24px;
}

.hero h1 {
  font-size: clamp(2.25rem, 5vw, 3.25rem);
  line-height: 1.15;
  margin: 0 0 1rem;
  font-weight: 800;
}

.hero .tagline {
  font-size: clamp(1.1rem, 2.5vw, 1.35rem);
  color: var(--text-secondary);
  margin: 0 0 2rem;
  max-width: 32rem;
  margin-inline: auto;
}

.hero-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  justify-content: center;
}

/* Sections */
section {
  padding: 3.5rem 0;
}

.section-title {
  text-align: center;
  font-size: clamp(1.5rem, 3vw, 2rem);
  margin: 0 0 0.5rem;
}

.section-subtitle {
  text-align: center;
  color: var(--text-secondary);
  margin: 0 0 2.5rem;
  max-width: 36rem;
  margin-inline: auto;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1.25rem;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
}

.card h3 {
  margin: 0 0 0.5rem;
  font-size: 1.1rem;
}

.card p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 0.95rem;
}

.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 1.5rem;
  counter-reset: step;
}

.step {
  text-align: center;
  padding: 1.5rem;
}

.step-num {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--brand-light), var(--brand));
  font-weight: 800;
  margin-bottom: 1rem;
}

.step h3 {
  margin: 0 0 0.5rem;
}

.step p {
  margin: 0;
  color: var(--text-secondary);
  font-size: 0.95rem;
}

.screenshot-placeholder {
  background: var(--surface-elevated);
  border: 1px dashed var(--border);
  border-radius: var(--radius);
  aspect-ratio: 9 / 19.5;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-secondary);
  font-size: 0.875rem;
  text-align: center;
  padding: 1rem;
}

.screenshot-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 1.25rem;
}

.cta-band {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2.5rem 2rem;
  text-align: center;
  margin: 2rem 0;
}

.cta-band h2 {
  margin: 0 0 0.75rem;
}

.cta-band p {
  color: var(--text-secondary);
  margin: 0 0 1.5rem;
}

/* Page content (legal, faq, support) */
.page-hero {
  padding: 3rem 0 2rem;
  text-align: center;
}

.page-hero h1 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.75rem, 4vw, 2.5rem);
}

.page-hero p {
  color: var(--text-secondary);
  margin: 0;
}

.prose {
  max-width: 720px;
  margin: 0 auto;
  padding-bottom: 3rem;
}

.prose h2 {
  font-size: 1.25rem;
  margin: 2rem 0 0.75rem;
}

.prose h3 {
  font-size: 1.05rem;
  margin: 1.5rem 0 0.5rem;
}

.prose p,
.prose li {
  color: var(--text-secondary);
}

.prose ul {
  padding-left: 1.25rem;
}

.prose .updated {
  font-size: 0.875rem;
  color: var(--text-secondary);
  margin-bottom: 2rem;
}

/* FAQ accordion */
.faq-list {
  max-width: 720px;
  margin: 0 auto 3rem;
}

.faq-item {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  margin-bottom: 0.75rem;
  background: var(--surface);
  overflow: hidden;
}

.faq-item summary {
  padding: 1rem 1.25rem;
  cursor: pointer;
  font-weight: 600;
  list-style: none;
}

.faq-item summary::-webkit-details-marker {
  display: none;
}

.faq-item summary::after {
  content: "+";
  float: right;
  color: var(--brand);
  font-weight: 700;
}

.faq-item[open] summary::after {
  content: "−";
}

.faq-answer {
  padding: 0 1.25rem 1rem;
  color: var(--text-secondary);
  font-size: 0.95rem;
}

/* Join page */
.join-card {
  max-width: 480px;
  margin: 2rem auto 3rem;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 2rem;
  text-align: center;
}

.join-code {
  font-size: 2rem;
  font-weight: 800;
  letter-spacing: 0.2em;
  color: var(--brand-light);
  margin: 1rem 0;
  font-family: ui-monospace, monospace;
}

.join-error {
  color: var(--error);
  margin: 1rem 0;
}

.join-instructions {
  color: var(--text-secondary);
  font-size: 0.95rem;
  text-align: left;
  margin-top: 1.5rem;
}

.join-instructions ol {
  padding-left: 1.25rem;
}

.copy-feedback {
  color: var(--success);
  font-size: 0.875rem;
  min-height: 1.25rem;
  margin-top: 0.5rem;
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 2.5rem 0;
  margin-top: auto;
}

.footer-inner {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 1.5rem;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1.25rem;
  list-style: none;
  margin: 0;
  padding: 0;
}

.footer-links a {
  color: var(--text-secondary);
  font-size: 0.9rem;
  text-decoration: none;
}

.footer-links a:hover {
  color: var(--text);
}

.footer-copy {
  color: var(--text-secondary);
  font-size: 0.875rem;
  margin: 0;
}

.app-store-badge {
  height: 44px;
  width: auto;
}

@media (max-width: 768px) {
  .nav-toggle {
    display: block;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    flex-direction: column;
    background: var(--bg);
    border-bottom: 1px solid var(--border);
    padding: 1rem;
    gap: 1rem;
  }

  .nav-links.is-open {
    display: flex;
  }

  .site-header {
    position: relative;
  }

  .header-inner {
    position: relative;
  }

  .header-inner .btn-primary {
    display: none;
  }
}
