/* BJJ Vision AI — brand tokens from BJJBrandTheme.swift */
:root {
  --bg-app: #090e18;
  --bg-secondary: #0e1626;
  --surface-primary: #141d2e;
  --surface-secondary: #182234;
  --surface-tertiary: #1e2a3f;
  --accent-primary: #2f80ff;
  --accent-secondary: #20d5ff;
  --text-primary: #f5f7fb;
  --text-secondary: #b0bacb;
  --text-muted: #73809a;
  --border-soft: rgba(47, 128, 255, 0.18);
  --radius-card: 22px;
  --radius-button: 14px;
  --max-width: 1080px;
  --legal-max-width: 800px;
  --font-sans: "Inter", system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

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

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-sans);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text-primary);
  background: linear-gradient(
    165deg,
    var(--bg-app) 0%,
    var(--bg-app) 40%,
    rgba(14, 22, 38, 0.85) 70%,
    var(--bg-app) 100%
  );
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
  overflow-wrap: break-word;
}

a {
  color: var(--accent-secondary);
  text-decoration: none;
  transition: color 0.15s ease;
}

a:hover {
  color: var(--text-primary);
}

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

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

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

/* Header */
.site-header {
  padding: 1rem 0;
  border-bottom: 1px solid var(--border-soft);
  backdrop-filter: blur(12px);
  background: rgba(9, 14, 24, 0.72);
  position: sticky;
  top: 0;
  z-index: 10;
}

.site-header .container {
  display: flex;
  align-items: center;
}

.logo {
  font-size: 1.05rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--text-primary);
  flex-shrink: 0;
}

.logo:hover {
  color: var(--accent-secondary);
}

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

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.35rem 0.85rem;
  margin-bottom: 0.75rem;
  font-size: 0.75rem;
  font-weight: 500;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--accent-secondary);
  background: rgba(32, 213, 255, 0.08);
  border: 1px solid rgba(32, 213, 255, 0.22);
  border-radius: 999px;
}

.hero h1 {
  margin: 0 0 0.5rem;
  font-size: clamp(2rem, 6vw, 3.25rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  line-height: 1.1;
  background: linear-gradient(180deg, var(--text-primary) 0%, rgba(245, 247, 251, 0.88) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

.hero-subtitle {
  margin: 0 auto 0.5rem;
  max-width: 32rem;
  font-size: clamp(1.05rem, 2.5vw, 1.35rem);
  font-weight: 500;
  color: var(--accent-secondary);
}

.hero-body {
  margin: 0 auto;
  max-width: 36rem;
  font-size: clamp(0.975rem, 2vw, 1.05rem);
  line-height: 1.6;
  color: var(--text-secondary);
}

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

.section-label {
  margin: 0 0 0.4rem;
  font-size: 0.75rem;
  font-weight: 600;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--accent-secondary);
}

.section-title {
  margin: 0 0 1.5rem;
  font-size: clamp(1.4rem, 3vw, 1.875rem);
  font-weight: 600;
  letter-spacing: -0.02em;
}

/* Feature grid */
.feature-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 1rem;
}

.feature-card {
  padding: 1.5rem;
  border-radius: var(--radius-card);
  background: linear-gradient(
    145deg,
    rgba(24, 34, 52, 0.92) 0%,
    rgba(20, 29, 46, 0.96) 50%,
    rgba(30, 42, 63, 0.9) 100%
  );
  border: 1px solid var(--border-soft);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.24);
}

.feature-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 2.5rem;
  height: 2.5rem;
  margin-bottom: 1rem;
  border-radius: 12px;
  background: rgba(32, 213, 255, 0.1);
  border: 1px solid rgba(32, 213, 255, 0.2);
  color: var(--accent-secondary);
}

.feature-card h3 {
  margin: 0 0 0.5rem;
  font-size: 1.05rem;
  font-weight: 600;
}

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

/* Trust & subscription panels */
.panel {
  padding: 1.75rem;
  border-radius: var(--radius-card);
  background: linear-gradient(
    145deg,
    rgba(30, 42, 63, 0.95) 0%,
    rgba(24, 34, 52, 0.95) 50%,
    rgba(20, 29, 46, 0.92) 100%
  );
  border: 1px solid rgba(32, 213, 255, 0.22);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.24);
}

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

.panel p + p {
  margin-top: 0.75rem;
}

.panel strong {
  color: var(--text-primary);
  font-weight: 600;
}

.panel-secondary {
  font-size: 0.9375rem !important;
  color: var(--text-muted) !important;
}

.panel-note {
  margin-top: 0.75rem !important;
  padding-top: 0.75rem;
  border-top: 1px solid rgba(47, 128, 255, 0.12);
  font-size: 0.9rem !important;
  color: var(--text-muted) !important;
}

/* Screenshot showcase */
#screenshots {
  padding-top: 0.25rem;
  overflow: hidden;
}

.container--screenshots {
  width: min(100% - 2rem, 1020px);
}

#screenshots .section-label {
  margin-bottom: 0.35rem;
}

#screenshots .section-title {
  margin-bottom: 1.5rem;
  text-align: center;
}

.screenshot-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 2.5rem 2rem;
  align-items: start;
  justify-items: center;
  max-width: 960px;
  margin-inline: auto;
}

.screenshot-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  width: 100%;
  max-width: 260px;
  min-width: 0;
  margin: 0;
}

.phone-frame {
  width: 100%;
  padding: 0.5rem;
  border-radius: 2.25rem;
  background: linear-gradient(
    155deg,
    rgba(30, 42, 63, 0.65) 0%,
    rgba(20, 29, 46, 0.5) 50%,
    rgba(24, 34, 52, 0.6) 100%
  );
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(32, 213, 255, 0.28);
  box-shadow:
    0 10px 36px rgba(0, 0, 0, 0.4),
    0 0 28px rgba(32, 213, 255, 0.12),
    0 0 56px rgba(47, 128, 255, 0.06),
    inset 0 1px 0 rgba(255, 255, 255, 0.05);
  transition: transform 0.3s ease, box-shadow 0.3s ease, border-color 0.3s ease;
}

.phone-screen {
  aspect-ratio: 358 / 780;
  width: 100%;
  border-radius: 1.75rem;
  overflow: hidden;
  background: var(--bg-app);
  line-height: 0;
}

.phone-screen img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: top center;
}

.screenshot-caption {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  margin-top: 1.25rem;
  padding: 0 0.5rem;
  text-align: center;
  width: 100%;
}

.screenshot-label {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-primary);
}

.screenshot-desc {
  margin: 0;
  font-size: 0.9rem;
  line-height: 1.55;
  color: var(--text-secondary);
}

@media (hover: hover) and (pointer: fine) {
  .screenshot-card:hover .phone-frame {
    transform: translateY(-5px);
    border-color: rgba(32, 213, 255, 0.42);
    box-shadow:
      0 16px 44px rgba(0, 0, 0, 0.45),
      0 0 36px rgba(32, 213, 255, 0.18),
      0 0 72px rgba(47, 128, 255, 0.08),
      inset 0 1px 0 rgba(255, 255, 255, 0.07);
  }
}

/* FAQ */
.faq-list {
  display: flex;
  flex-direction: column;
  gap: 0.65rem;
}

.faq-item {
  border-radius: var(--radius-card);
  background: linear-gradient(
    145deg,
    rgba(24, 34, 52, 0.92) 0%,
    rgba(20, 29, 46, 0.96) 50%,
    rgba(30, 42, 63, 0.9) 100%
  );
  border: 1px solid var(--border-soft);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.24);
  overflow: hidden;
}

.faq-item summary {
  padding: 1.15rem 1.35rem;
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
  cursor: pointer;
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

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

.faq-item summary::marker {
  display: none;
  content: "";
}

.faq-item summary::after {
  content: "+";
  flex-shrink: 0;
  width: 1.5rem;
  height: 1.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.25rem;
  font-weight: 400;
  line-height: 1;
  color: var(--accent-secondary);
  transition: transform 0.2s ease;
}

.faq-item[open] summary::after {
  transform: rotate(45deg);
}

.faq-item[open] summary {
  padding-bottom: 0.5rem;
}

.faq-answer {
  margin: 0;
  padding: 0 1.35rem 1.15rem;
  font-size: 0.9375rem;
  line-height: 1.65;
  color: var(--text-secondary);
}

/* Disclaimer */
.disclaimer {
  padding: 1.75rem 0 0;
}

.disclaimer-text {
  margin: 0;
  padding: 1.25rem 1.5rem;
  font-size: 0.9rem;
  line-height: 1.65;
  text-align: center;
  color: var(--text-muted);
  border-radius: var(--radius-card);
  border: 1px solid var(--border-soft);
  background: rgba(20, 29, 46, 0.5);
}

/* Legal pages */
.legal-page {
  padding: 2.5rem 0 3rem;
}

.legal-page h1 {
  margin: 0 0 0.5rem;
  font-size: clamp(1.75rem, 4vw, 2.25rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.2;
}

.legal-meta {
  margin: 0 0 2rem;
  font-size: 0.875rem;
  color: var(--text-muted);
}

.legal-content h2 {
  margin: 2rem 0 0.75rem;
  font-size: 1.2rem;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.35;
}

.legal-content h2:first-child {
  margin-top: 0;
}

.legal-content h3 {
  margin: 1.5rem 0 0.65rem;
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text-primary);
  line-height: 1.35;
}

.legal-content p {
  margin: 0 0 1rem;
  color: var(--text-secondary);
  font-size: 0.975rem;
  line-height: 1.75;
}

.legal-content li {
  color: var(--text-secondary);
  font-size: 0.975rem;
  line-height: 1.7;
}

.legal-content ul {
  margin: 0.5rem 0 1.25rem;
  padding-left: 1.25rem;
}

.legal-content li + li {
  margin-top: 0.5rem;
}

.legal-content a {
  word-break: break-word;
}

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

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

.footer-brand {
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--text-primary);
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.5rem;
  font-size: 0.875rem;
}

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

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

.footer-copy {
  width: 100%;
  margin: 0.5rem 0 0;
  font-size: 0.8125rem;
  color: var(--text-muted);
}

/* Responsive */
@media (max-width: 640px) {
  .hero {
    padding: 2rem 0 0.25rem;
  }

  section {
    padding: 1.75rem 0;
  }

  .footer-inner {
    flex-direction: column;
    align-items: flex-start;
  }

  .footer-links {
    flex-direction: column;
    gap: 0.65rem;
  }

  .screenshot-grid {
    grid-template-columns: 1fr;
    gap: 2.5rem;
    max-width: 280px;
  }

  .screenshot-card {
    max-width: 260px;
  }

  .screenshot-caption {
    margin-top: 1rem;
    padding: 0 0.25rem;
  }

  .panel {
    padding: 1.35rem;
  }

  .faq-item summary {
    padding: 1rem 1.15rem;
    font-size: 0.9375rem;
  }

  .faq-answer {
    padding: 0 1.15rem 1rem;
  }
}

@media (min-width: 768px) and (max-width: 959px) {
  .screenshot-grid {
    gap: 2rem 1.25rem;
  }

  .screenshot-card {
    max-width: 220px;
  }
}

@media (min-width: 960px) {
  .screenshot-card {
    max-width: 260px;
  }
}
