/* ========================================
   Protein Note - Shared Styles
   Dark theme matching app design tokens
   ======================================== */

:root {
  --bg: #0A0A0A;
  --surface: #141414;
  --surface-elevated: #1C1C1E;
  --primary: #00F0A0;
  --primary-dim: rgba(0, 240, 160, 0.15);
  --text: #FFFFFF;
  --text-secondary: #8E8E93;
  --text-tertiary: #636366;
  --border: #2C2C2E;
  --protein: #00F0A0;
  --calories: #FF6B6B;
  --fat: #4ECDC4;
  --carbs: #FFD93D;
  --max-width: 960px;
  --content-width: 800px;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  line-height: 1.6;
  color: var(--text);
  background-color: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: opacity 0.2s;
}

a:hover {
  opacity: 0.8;
}

/* ========================================
   Header / Navigation
   ======================================== */

.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(10, 10, 10, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border);
}

.site-header .inner {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 12px 24px;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.site-header .logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 16px;
  color: var(--text);
  text-decoration: none;
}

.site-header .logo img {
  width: 32px;
  height: 32px;
  border-radius: 8px;
}

.site-header nav {
  display: flex;
  gap: 24px;
  font-size: 14px;
}

.site-header nav a {
  color: var(--text-secondary);
}

.site-header nav a:hover {
  color: var(--text);
  opacity: 1;
}

/* ========================================
   Hero Section
   ======================================== */

.hero {
  text-align: center;
  padding: 80px 24px 48px;
  max-width: var(--max-width);
  margin: 0 auto;
}

.hero .app-icon {
  width: 120px;
  height: 120px;
  border-radius: 28px;
  box-shadow: 0 8px 32px rgba(0, 240, 160, 0.2);
  margin-bottom: 32px;
}

.hero h1 {
  font-size: 42px;
  font-weight: 800;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
  background: linear-gradient(135deg, var(--primary), #4ECDC4);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero .tagline {
  font-size: 18px;
  color: var(--text-secondary);
  max-width: 480px;
  margin: 0 auto 40px;
  line-height: 1.8;
}

.hero .store-badge {
  display: inline-block;
  transition: transform 0.2s;
}

.hero .store-badge:hover {
  transform: scale(1.05);
}

.hero .store-badge img {
  height: 54px;
}

.hero-sub {
  margin-top: 16px;
  font-size: 14px;
  color: var(--text-tertiary);
}

/* ========================================
   Stats Bar
   ======================================== */

.stats-bar {
  background: var(--surface);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 32px 24px;
}

.stats-bar .inner {
  max-width: var(--max-width);
  margin: 0 auto;
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  text-align: center;
}

.stat-item {
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.stat-number {
  font-size: 36px;
  font-weight: 800;
  background: linear-gradient(135deg, var(--primary), #4ECDC4);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1.2;
}

.stat-label {
  font-size: 13px;
  color: var(--text-secondary);
}

/* ========================================
   Pain Points Section
   ======================================== */

.pain-points {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 64px 24px 48px;
  text-align: center;
}

.pain-grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 20px;
  margin: 40px 0 32px;
}

.pain-item:nth-child(1) { grid-column: 1 / 3; }
.pain-item:nth-child(2) { grid-column: 3 / 5; }
.pain-item:nth-child(3) { grid-column: 5 / 7; }
.pain-item:nth-child(4) { grid-column: 2 / 4; }
.pain-item:nth-child(5) { grid-column: 4 / 6; }

.pain-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 28px 20px;
}

.pain-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 56px;
  height: 56px;
  border-radius: 16px;
  background: rgba(255, 107, 107, 0.1);
  color: var(--calories);
  margin-bottom: 16px;
}

.pain-icon svg {
  display: block;
}

.pain-item p {
  font-size: 15px;
  color: var(--text-secondary);
  line-height: 1.6;
}

.pain-item strong {
  color: var(--calories);
}

.pain-solution {
  font-size: 20px;
  font-weight: 700;
  color: var(--text);
  margin-top: 8px;
}

.pain-solution strong {
  color: var(--primary);
}

/* ========================================
   Screenshots Gallery
   ======================================== */

.screenshots {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 40px 24px 60px;
  overflow: hidden;
}

.screenshots .section-title {
  text-align: center;
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 32px;
}

.screenshots-track {
  display: flex;
  gap: 20px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 20px;
  scrollbar-width: none;
}

.screenshots-track::-webkit-scrollbar {
  display: none;
}

.screenshots-track img {
  flex-shrink: 0;
  width: 240px;
  height: auto;
  border-radius: 16px;
  scroll-snap-align: center;
  box-shadow: 0 4px 24px rgba(0, 0, 0, 0.4);
  transition: transform 0.2s;
}

.screenshots-track img:hover {
  transform: scale(1.03);
}

.screenshots-dots {
  display: flex;
  justify-content: center;
  gap: 8px;
  margin-top: 4px;
}

.screenshots-dots button {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  border: none;
  background: var(--text-tertiary);
  padding: 0;
  cursor: pointer;
  transition: background 0.2s, transform 0.2s;
}

.screenshots-dots button.active {
  background: var(--primary);
  transform: scale(1.3);
}

/* ========================================
   Features Section
   ======================================== */

.features {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 40px 24px 64px;
}

.features .section-title,
.section-title {
  text-align: center;
  font-size: 28px;
  font-weight: 700;
  margin-bottom: 48px;
}

.features-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.feature-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 28px 24px;
  transition: transform 0.2s, border-color 0.2s;
}

.feature-card:hover {
  transform: translateY(-4px);
  border-color: var(--primary);
}

.feature-card .icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  border-radius: 14px;
  margin-bottom: 16px;
  color: var(--primary);
  background: var(--primary-dim);
}

.feature-card .icon svg {
  display: block;
}

.feature-card.accent-protein .icon {
  color: var(--protein);
  background: rgba(0, 240, 160, 0.1);
}

.feature-card.accent-calories .icon {
  color: var(--calories);
  background: rgba(255, 107, 107, 0.1);
}

.feature-card.accent-fat .icon {
  color: var(--fat);
  background: rgba(78, 205, 196, 0.1);
}

.feature-card.accent-carbs .icon {
  color: var(--carbs);
  background: rgba(255, 217, 61, 0.1);
}

.feature-card h3 {
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 8px;
}

.feature-card p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* Nutrient color accents */
.feature-card.accent-protein { border-top: 3px solid var(--protein); }
.feature-card.accent-calories { border-top: 3px solid var(--calories); }
.feature-card.accent-fat { border-top: 3px solid var(--fat); }
.feature-card.accent-carbs { border-top: 3px solid var(--carbs); }
.feature-card.accent-primary { border-top: 3px solid var(--primary); }

/* ========================================
   Use Cases Section
   ======================================== */

.use-cases {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 64px 24px;
}

.use-cases-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
}

.use-case-card {
  background: var(--surface-elevated);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 36px 24px;
  text-align: center;
  transition: transform 0.2s;
}

.use-case-card:hover {
  transform: translateY(-4px);
}

.use-case-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 64px;
  height: 64px;
  border-radius: 18px;
  background: var(--primary-dim);
  color: var(--primary);
  margin-bottom: 20px;
}

.use-case-icon svg {
  display: block;
}

.use-case-card h3 {
  font-size: 17px;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--primary);
}

.use-case-card p {
  font-size: 14px;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ========================================
   Mid CTA Section
   ======================================== */

.mid-cta {
  text-align: center;
  padding: 48px 24px;
  max-width: var(--max-width);
  margin: 0 auto;
}

.mid-cta p {
  font-size: 18px;
  color: var(--text-secondary);
  margin-bottom: 24px;
}

.mid-cta .store-badge {
  display: inline-block;
  transition: transform 0.2s;
}

.mid-cta .store-badge:hover {
  transform: scale(1.05);
}

.mid-cta .store-badge img {
  height: 54px;
}

/* ========================================
   CTA Section
   ======================================== */

.cta-section {
  text-align: center;
  padding: 80px 24px;
  background: linear-gradient(180deg, var(--surface) 0%, var(--bg) 100%);
  border-top: 1px solid var(--border);
}

.cta-section h2 {
  font-size: 32px;
  font-weight: 800;
  margin-bottom: 16px;
  background: linear-gradient(135deg, var(--primary), #4ECDC4);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.cta-section p {
  font-size: 16px;
  color: var(--text-secondary);
  margin-bottom: 32px;
  line-height: 1.7;
}

.cta-section .store-badge {
  display: inline-block;
  transition: transform 0.2s;
}

.cta-section .store-badge:hover {
  transform: scale(1.05);
}

.cta-section .store-badge img {
  height: 54px;
}

.cta-free {
  margin-top: 16px;
  font-size: 14px;
  color: var(--text-tertiary) !important;
}

/* ========================================
   Footer
   ======================================== */

.site-footer {
  border-top: 1px solid var(--border);
  padding: 40px 24px;
  text-align: center;
}

.site-footer .inner {
  max-width: var(--max-width);
  margin: 0 auto;
}

.site-footer nav {
  display: flex;
  justify-content: center;
  gap: 32px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.site-footer nav a {
  color: var(--text-secondary);
  font-size: 14px;
}

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

.site-footer .copyright {
  color: var(--text-tertiary);
  font-size: 13px;
}

/* ========================================
   Sub-page Styles (Privacy, Support, etc.)
   ======================================== */

.page-content {
  max-width: var(--content-width);
  margin: 0 auto;
  padding: 40px 24px 80px;
}

.page-content h1 {
  font-size: 32px;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--primary);
}

.page-content .last-updated {
  color: var(--text-tertiary);
  font-size: 14px;
  margin-bottom: 40px;
}

.page-content h2 {
  font-size: 20px;
  font-weight: 700;
  margin-top: 40px;
  margin-bottom: 12px;
  padding-bottom: 8px;
  border-bottom: 1px solid var(--border);
}

.page-content h3 {
  font-size: 17px;
  font-weight: 600;
  margin-top: 24px;
  margin-bottom: 8px;
  color: var(--text);
}

.page-content p {
  color: var(--text-secondary);
  margin-bottom: 12px;
}

.page-content ul {
  color: var(--text-secondary);
  padding-left: 24px;
  margin-bottom: 12px;
}

.page-content li {
  margin-bottom: 6px;
}

.page-content strong {
  color: var(--text);
}

.page-content a {
  color: var(--primary);
}

/* Support page specifics */
.support-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 32px;
  margin: 24px 0;
  text-align: center;
}

.support-card h2 {
  border-bottom: none;
  margin-top: 0;
  text-align: center;
}

.btn-primary {
  display: inline-block;
  background: var(--primary);
  color: #000 !important;
  font-weight: 700;
  font-size: 15px;
  padding: 14px 32px;
  border-radius: 12px;
  margin-top: 16px;
  transition: transform 0.2s, box-shadow 0.2s;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 4px 16px rgba(0, 240, 160, 0.3);
  opacity: 1;
}

.support-note {
  color: var(--text-tertiary) !important;
  font-size: 13px;
  margin-top: 12px;
}

/* ========================================
   Responsive
   ======================================== */

@media (max-width: 768px) {
  .hero {
    padding: 60px 20px 40px;
  }

  .hero h1 {
    font-size: 32px;
  }

  .hero .tagline {
    font-size: 16px;
  }

  .hero .app-icon {
    width: 96px;
    height: 96px;
    border-radius: 22px;
  }

  .stats-bar .inner {
    grid-template-columns: repeat(2, 1fr);
    gap: 24px;
  }

  .stat-number {
    font-size: 28px;
  }

  .pain-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .pain-item:nth-child(1),
  .pain-item:nth-child(2),
  .pain-item:nth-child(3),
  .pain-item:nth-child(4),
  .pain-item:nth-child(5) {
    grid-column: auto;
  }

  .features-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .use-cases-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .features .section-title,
  .section-title,
  .screenshots .section-title {
    font-size: 24px;
  }

  .screenshots-track img {
    width: 200px;
  }

  .site-header .inner {
    padding: 10px 16px;
  }

  .site-header nav {
    gap: 16px;
    font-size: 13px;
  }

  .site-footer nav {
    gap: 20px;
  }

  .page-content {
    padding: 32px 20px 60px;
  }

  .page-content h1 {
    font-size: 26px;
  }

  .cta-section h2 {
    font-size: 26px;
  }

  .cta-section p {
    font-size: 15px;
  }

  .pain-solution {
    font-size: 18px;
  }
}

@media (max-width: 480px) {
  .hero h1 {
    font-size: 28px;
  }

  .site-header nav {
    gap: 12px;
  }

  .stats-bar .inner {
    grid-template-columns: repeat(2, 1fr);
    gap: 16px;
  }
}
