/*
  Scoopy Log — Design system
  Calm, premium, minimal. Accent aligned with app onboarding blue (#00A2EC). System fonts. Dark mode via prefers-color-scheme.
  No copy changes; layout and visual only.
*/

/* --- Font: SF Compact Rounded (same as app onboarding); one file, bold synthesized --- */
@font-face {
  font-family: 'SF Compact Rounded';
  src: local('SF Compact Rounded'),
       local('SFCompactRounded-Regular'),
       url('/assets/font/SF-Compact-Rounded-Regular.otf') format('opentype'),
       url('assets/font/SF-Compact-Rounded-Regular.otf') format('opentype');
  font-weight: 100 900;
  font-style: normal;
  font-display: swap;
}

/* --- Design tokens: Light (default) --- */
:root {
  /* iOS-style system backgrounds (light) */
  --bg-primary: #F2F2F7;
  --bg-secondary: #E5E5EA;
  --bg-card: #FFFFFF;
  --bg-elevated: #FFFFFF;
  --header-bg: rgba(255, 255, 255, 0.72);
  
  --text-primary: #0F172A;
  --text-secondary: #475569;
  --text-muted: #94A3B8;
  
  --accent: #00A2EC;
  --accent-hover: #0086C4;
  --accent-subtle: rgba(0, 162, 236, 0.08);
  
  --border: #E2E8F0;
  --border-light: #F1F5F9;
  
  /* iOS-style: soft, diffuse shadows */
  --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.04);
  --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.06), 0 2px 6px rgba(0, 0, 0, 0.04);
  --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.08), 0 4px 12px rgba(0, 0, 0, 0.04);
  
  /* iOS-style corner radius (softer, larger) */
  --radius-sm: 12px;
  --radius-md: 16px;
  --radius-lg: 22px;
  --radius-xl: 28px;
  
  /* Compact spacing */
  --space-xs: 4px;
  --space-sm: 8px;
  --space-md: 14px;
  --space-lg: 20px;
  --space-xl: 28px;
  --space-xxl: 36px;
  --space-xxxl: 44px;
  
  /* SF Rounded as in app (SF Compact Rounded / SF Pro Rounded) */
  --font-sans: "SF Compact Rounded", -apple-system, BlinkMacSystemFont, "SF Pro Rounded", "Segoe UI Rounded", system-ui, sans-serif;
  --font-display: "SF Compact Rounded", -apple-system, BlinkMacSystemFont, "SF Pro Rounded", "Segoe UI Rounded", system-ui, sans-serif;
  /* Header gradient: loader percentage style (#2B7FFF → #00B8DB) */
  --header-gradient: linear-gradient(90deg, #2B7FFF 0%, #00B8DB 100%);
  --font-size-base: 17px;
  --line-height-base: 1.6;
  --line-height-tight: 1.25;
  
  --container-max: 1100px;
  --container-pad: 24px;
  
  --header-height: 56px;
  --tap-min: 44px;
  
  /* Unified card & icon system */
  --card-padding: var(--space-xl);
  --card-radius: var(--radius-lg);
  --card-shadow: var(--shadow-sm);
  --card-shadow-hover: var(--shadow-md);
  --card-border: 1px solid var(--border-light);
  --icon-size: 48px;
  --icon-size-sm: 24px;
  
  /* Aliases for inline styles (preserve existing var() in HTML) */
  --spacing-xs: var(--space-xs);
  --spacing-sm: var(--space-sm);
  --spacing-md: var(--space-md);
  --spacing-lg: var(--space-lg);
  --spacing-xl: var(--space-xl);
  --spacing-xxl: var(--space-xxl);
  --spacing-xxxl: var(--space-xxxl);
}

/* --- Dark mode --- */
@media (prefers-color-scheme: dark) {
  :root {
    /* iOS-style system backgrounds (dark) */
    --bg-primary: #1C1C1E;
    --bg-secondary: #2C2C2E;
    --bg-card: #2C2C2E;
    --bg-elevated: #3A3A3C;
    --header-bg: rgba(44, 44, 46, 0.72);
    
    --text-primary: #F8FAFC;
    --text-secondary: #CBD5E1;
    --text-muted: #94A3B8;
    
    --accent: #38B8F0;
    --accent-hover: #5EC9F5;
    --accent-subtle: rgba(0, 162, 236, 0.15);
    
    --border: #334155;
    --border-light: #475569;
    
    /* iOS-style: soft shadows in dark mode */
    --shadow-sm: 0 2px 8px rgba(0, 0, 0, 0.2);
    --shadow-md: 0 4px 16px rgba(0, 0, 0, 0.25), 0 2px 6px rgba(0, 0, 0, 0.15);
    --shadow-lg: 0 12px 40px rgba(0, 0, 0, 0.35), 0 4px 12px rgba(0, 0, 0, 0.2);
  }

  .hero {
    background-image: linear-gradient(180deg, rgba(28, 28, 30, 0.75) 0%, rgba(44, 44, 46, 0.75) 100%), url('assets/bg-sky-day.webp');
  }

  .section-alt {
    background-image: linear-gradient(180deg, rgba(28, 28, 30, 0.75) 0%, rgba(44, 44, 46, 0.75) 100%), url('assets/bg-sky-day.webp');
  }

  .cta-section {
    background-image: linear-gradient(180deg, rgba(28, 28, 30, 0.75) 0%, rgba(44, 44, 46, 0.75) 100%), url('assets/bg-sky-day.webp');
  }

  #faq {
    background: #252528;
  }
}

/* --- Reset & base --- */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

/* SF Compact Rounded everywhere: inputs and buttons inherit from html */
input,
textarea,
button,
select {
  font-family: inherit;
}

html {
  scroll-behavior: smooth;
  font-family: "SF Compact Rounded", -apple-system, BlinkMacSystemFont, "SF Pro Rounded", "Segoe UI Rounded", system-ui, sans-serif;
}

body {
  font-family: inherit;
  font-size: var(--font-size-base);
  line-height: var(--line-height-base);
  color: var(--text-primary);
  background-color: var(--bg-primary);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* --- Sticky header (iOS-style frosted glass) --- */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--header-height);
  background: var(--header-bg);
  border-bottom: 1px solid var(--border-light);
  backdrop-filter: saturate(180%) blur(20px);
  -webkit-backdrop-filter: saturate(180%) blur(20px);
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 100%;
}

.site-header .logo {
  font-family: inherit;
  font-size: 1.15rem;
  font-weight: 400;
  color: var(--text-primary);
  text-decoration: none;
  min-height: var(--tap-min);
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  flex-shrink: 0;
}

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

.site-header .logo:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

.site-nav {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  align-items: center;
  gap: 6px;
  padding: 0;
}

.site-nav a {
  font-size: 0.9rem;
  color: var(--text-secondary);
  text-decoration: none;
  padding: 11px 20px;
  border-radius: var(--radius-sm);
  min-height: var(--tap-min);
  display: inline-flex;
  align-items: center;
  white-space: nowrap;
  flex-shrink: 0;
  transition: color 0.2s ease, background 0.2s ease;
}

.site-nav a:hover {
  color: var(--accent);
  background: var(--accent-subtle);
}

.site-nav a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.site-nav a.active {
  color: var(--accent);
  font-weight: 500;
}

@media (max-width: 768px) {
  .site-nav {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    max-width: calc(100vw - var(--container-pad) * 2 - 80px);
  }
  .site-nav::-webkit-scrollbar {
    display: none;
  }
}

/* --- Container --- */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--container-pad);
}

/* --- Typography (SF Rounded, heavy 800, loader-style gradient as in app) --- */
h1, h2, h3, h4, h5, h6 {
  font-family: inherit;
  font-weight: 800; /* heavy */
  line-height: var(--line-height-tight);
  background: var(--header-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

h1 {
  font-size: clamp(2rem, 5vw, 3rem);
  letter-spacing: -0.03em;
  margin-bottom: var(--space-md);
}

h2 {
  font-size: clamp(1.5rem, 3.5vw, 2.25rem);
  letter-spacing: -0.02em;
  margin-bottom: var(--space-lg);
}

h3 {
  font-size: 1.25rem;
  margin-bottom: var(--space-xs);
}

p {
  margin-bottom: var(--space-md);
  color: var(--text-secondary);
}

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

a:hover {
  color: var(--accent-hover);
}

a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
  border-radius: var(--radius-sm);
}

/* --- Sections --- */
.section {
  padding: var(--space-xxxl) 0;
}

.faq-list {
  display: flex;
  flex-direction: column;
  gap: var(--space-lg);
}

.faq-item p:first-child {
  margin: 0 0 var(--space-xs) 0;
}

.faq-item p:last-child {
  margin: 0;
  color: var(--text-secondary);
  font-size: 0.95rem;
  line-height: 1.55;
}

/* --- Reviews (App Store quotes) --- */
.reviews-intro {
  margin-bottom: var(--space-lg);
  color: var(--text-secondary);
  font-size: 1rem;
}

.reviews-intro a {
  color: var(--accent);
  text-decoration: none;
}

.reviews-intro a:hover {
  text-decoration: underline;
}

.reviews-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--space-lg);
  max-width: 720px;
}

.review-card {
  margin: 0;
  padding: var(--card-padding);
  background: var(--bg-card);
  border-radius: var(--card-radius);
  box-shadow: var(--card-shadow);
  border: var(--card-border);
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.review-card:hover {
  box-shadow: var(--card-shadow-hover);
  transform: translateY(-2px);
}

.review-stars {
  display: block;
  color: var(--accent);
  font-size: 1rem;
  letter-spacing: 0.1em;
  margin-bottom: var(--space-sm);
}

.review-text {
  font-size: 1rem;
  line-height: 1.55;
  color: var(--text-primary);
  margin: 0 0 var(--space-sm) 0;
  font-style: normal;
}

.review-cite {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-style: normal;
}

.section-alt {
  background-image:
    linear-gradient(180deg, transparent 0%, transparent 45%, rgba(242, 242, 247, 0.6) 80%, var(--bg-primary) 100%),
    linear-gradient(180deg, rgba(242, 242, 247, 0.6) 0%, rgba(229, 229, 234, 0.6) 100%),
    url('assets/bg-sky-day.webp');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

/* --- Hero --- */
.hero {
  padding: var(--space-xxl) 0;
  background-image:
    linear-gradient(180deg, transparent 0%, transparent 38%, rgba(255, 255, 255, 0.5) 72%, rgba(242, 242, 247, 0.98) 86%, var(--bg-primary) 100%),
    linear-gradient(180deg, rgba(242, 242, 247, 0.6) 0%, rgba(229, 229, 234, 0.6) 100%),
    url('assets/bg-sky-day.webp');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.hero-content {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: var(--space-xl);
  align-items: center;
}

.hero-text h1 {
  margin-bottom: var(--space-md);
}

.hero-tagline {
  font-family: inherit;
  font-size: 1.35rem;
  font-weight: 800;
  margin-bottom: var(--space-md);
  line-height: 1.35;
  background: var(--header-gradient);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero-description {
  font-size: 1.05rem;
  color: var(--text-secondary);
  margin-bottom: var(--space-xl);
  max-width: 480px;
}

.hero-cta {
  display: flex;
  flex-direction: column;
  gap: var(--space-md);
  align-items: flex-start;
}

.hero-rating {
  display: flex;
  align-items: center;
  gap: var(--space-sm);
  font-size: 0.95rem;
  color: var(--text-secondary);
  margin: 0;
}

.hero-rating a {
  color: var(--accent);
  text-decoration: none;
  letter-spacing: 0.1em;
}

.hero-rating a:hover {
  text-decoration: underline;
}

.hero-rating-value {
  font-weight: 600;
  margin-left: 0.15em;
}

.hero-rating-label {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.hero-image {
  display: flex;
  justify-content: center;
  align-items: center;
}

.hero-device {
  width: 280px;
  border-radius: 36px;
  overflow: hidden;
  box-shadow: var(--shadow-lg), 0 0 0 3px var(--border);
  background: var(--bg-card);
}

.hero-device img {
  display: block;
  width: 100%;
  height: auto;
  vertical-align: middle;
}

/* --- Buttons (iOS-style: rounded, tap-friendly) --- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-sm);
  padding: var(--space-md) var(--space-xl);
  min-height: var(--tap-min);
  border-radius: var(--radius-lg);
  font-weight: 600;
  font-size: 1rem;
  transition: transform 0.2s ease, box-shadow 0.2s ease, opacity 0.2s ease;
  border: none;
  cursor: pointer;
  -webkit-tap-highlight-color: transparent;
}

.btn-app-store {
  background: var(--accent);
  color: #FFFFFF;
  border-radius: 999px;
}

.btn-app-store:hover {
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn-app-store:active {
  opacity: 0.9;
}

.btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

@media (prefers-color-scheme: dark) {
  .btn-app-store {
    background: var(--accent);
    color: #FFFFFF;
  }
}

.btn-large {
  padding: var(--space-lg) var(--space-xl);
  font-size: 1.1rem;
}

/* --- Feature cards (How it works) --- */
.features-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-lg);
  margin-top: var(--space-xl);
}

.feature-card {
  padding: var(--card-padding);
  background: var(--bg-card);
  border-radius: var(--card-radius);
  border: var(--card-border);
  box-shadow: var(--card-shadow);
  transition: box-shadow 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
  display: flex;
  align-items: flex-start;
  gap: var(--space-lg);
}

.feature-card:hover {
  box-shadow: var(--card-shadow-hover);
  border-color: var(--border);
  transform: translateY(-2px);
}

.feature-icon {
  flex-shrink: 0;
  width: var(--icon-size);
  height: var(--icon-size);
  display: flex;
  align-items: center;
  justify-content: center;
}

.feature-icon img {
  width: var(--icon-size-sm);
  height: var(--icon-size-sm);
  object-fit: contain;
}

.feature-content {
  flex: 1;
}

.feature-card h3 {
  font-size: 1.2rem;
  font-weight: 800;
  margin-bottom: var(--space-xs);
}

.feature-card[data-tracker="sleep"] h3 { color: #1572FF; }
.feature-card[data-tracker="feeding"] h3 { color: #E85D04; }
.feature-card[data-tracker="diapers"] h3 { color: #059669; }
.feature-card[data-tracker="growth"] h3 { color: var(--accent); }

.feature-card ul {
  margin: 0;
  padding-left: var(--space-md);
  font-size: 0.9rem;
  line-height: 1.6;
  color: var(--text-secondary);
}

/* --- Benefit cards (Why parents choose, Explore features) --- */
.benefits-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-lg);
  margin-top: var(--space-xl);
}

.benefits-grid--narrow {
  max-width: 880px;
  margin-left: auto;
  margin-right: auto;
}

.benefit-card {
  display: flex;
  gap: var(--space-lg);
  padding: var(--card-padding);
  background: var(--bg-card);
  border-radius: var(--card-radius);
  border: var(--card-border);
  box-shadow: var(--card-shadow);
  min-height: 100px;
  transition: box-shadow 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.benefit-card:hover {
  box-shadow: var(--card-shadow-hover);
  border-color: var(--border);
  transform: translateY(-2px);
}

.benefit-icon {
  flex-shrink: 0;
  width: var(--icon-size);
  height: var(--icon-size);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
}

.benefit-icon img,
.benefit-icon svg {
  width: var(--icon-size);
  height: var(--icon-size);
  object-fit: contain;
}

/* Explore features: same icon size as How it works (smaller, not oversized) */
#explore-features .benefit-icon img,
#explore-features .benefit-icon svg {
  width: var(--icon-size-sm);
  height: var(--icon-size-sm);
}

.benefit-content h3 {
  font-weight: 800;
  margin-bottom: var(--space-xs);
}

.benefit-content p {
  font-size: 0.95rem;
  margin-bottom: 0;
}

/* --- Screenshots (Simple by design) — carousel --- */
.screenshots-carousel {
  position: relative;
  margin-top: var(--space-xl);
}

.screenshots-track {
  display: flex;
  gap: var(--space-lg);
  overflow-x: auto;
  overflow-y: hidden;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  padding: var(--space-sm) 0 var(--space-md);
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

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

.screenshot-item {
  flex: 0 0 auto;
  width: 240px;
  scroll-snap-align: start;
  text-align: center;
}

.screenshot-placeholder {
  background: var(--bg-card);
  border: var(--card-border);
  border-radius: var(--card-radius);
  padding: 0;
  margin-bottom: var(--space-md);
  margin-left: auto;
  margin-right: auto;
  max-width: 220px;
  box-shadow: var(--card-shadow);
  aspect-ratio: 9 / 19.5;
  overflow: hidden;
  display: block;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.screenshot-placeholder:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}

.screenshot-placeholder img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
  vertical-align: top;
}

.screenshot-item h3 {
  font-size: 1.05rem;
  font-weight: 800;
  margin-top: var(--space-sm);
  margin-bottom: var(--space-xs);
}

.screenshot-item p {
  font-size: 0.875rem;
  margin-bottom: 0;
  line-height: 1.5;
}

.carousel-nav {
  display: flex;
  justify-content: center;
  gap: var(--space-md);
  margin-top: var(--space-md);
}

.carousel-btn {
  width: 44px;
  height: 44px;
  min-width: 44px;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: none;
  border-radius: 50%;
  background: var(--bg-card);
  color: var(--text-primary);
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
  -webkit-tap-highlight-color: transparent;
}

.carousel-btn:hover {
  background: var(--accent-subtle);
  color: var(--accent);
  box-shadow: var(--shadow-md);
  transform: scale(1.05);
}

.carousel-btn:active {
  transform: scale(0.98);
}

.carousel-btn:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* --- Captain's Log --- */
.captains-log-content {
  display: flex;
  flex-direction: column;
  gap: var(--space-xl);
  align-items: stretch;
}

.captains-log-title {
  font-weight: 800;
  margin: 0 0 var(--space-md) 0;
}

.captains-log-row {
  display: grid;
  grid-template-columns: auto 1fr;
  gap: var(--space-xl);
  align-items: start;
}

.captains-log-text p {
  margin-bottom: var(--space-md);
}

.captains-log-text p:last-child {
  margin-bottom: 0;
}

.captains-log-preview {
  display: flex;
  justify-content: center;
  align-items: center;
}

.pdf-preview {
  background: var(--bg-card);
  border: var(--card-border);
  border-radius: var(--card-radius);
  padding: var(--card-padding);
  box-shadow: var(--card-shadow);
  text-align: center;
  min-width: 200px;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.pdf-preview:hover {
  box-shadow: var(--shadow-lg);
  transform: translateY(-2px);
}

.pdf-icon {
  width: var(--icon-size);
  height: var(--icon-size);
  margin: 0 auto var(--space-md);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
}

.pdf-icon svg {
  width: var(--icon-size);
  height: var(--icon-size);
}

.pdf-title {
  font-weight: 600;
  font-size: 1.1rem;
  color: var(--text-primary);
}

.pdf-subtitle {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

/* --- Pricing --- */
.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: var(--space-xl);
  margin-top: var(--space-xl);
  max-width: 720px;
  margin-left: auto;
  margin-right: auto;
}

.pricing-card {
  background: var(--bg-card);
  border: var(--card-border);
  border-radius: var(--card-radius);
  padding: var(--card-padding);
  box-shadow: var(--card-shadow);
  position: relative;
  transition: box-shadow 0.2s ease, transform 0.2s ease, border-color 0.2s ease;
}

.pricing-card:hover {
  box-shadow: var(--card-shadow-hover);
  transform: translateY(-2px);
}

.pricing-card-featured {
  border-color: var(--accent);
  box-shadow: var(--card-shadow-hover);
}

.pricing-card-featured:hover {
  box-shadow: var(--shadow-lg);
}

.pricing-card h3 {
  font-weight: 800;
  margin-top: 0;
  margin-bottom: var(--space-md);
}

.pricing-amount {
  font-size: 2rem;
  font-weight: 600;
  color: var(--text-primary);
  margin-bottom: var(--space-lg);
}

.pricing-period {
  font-size: 1rem;
  font-weight: 400;
  color: var(--text-secondary);
}

.pricing-features {
  list-style: none;
  padding: 0;
  margin: 0;
}

.pricing-features li {
  display: flex;
  align-items: flex-start;
  gap: var(--space-sm);
  margin-bottom: var(--space-md);
  color: var(--text-secondary);
  min-height: 24px;
}

.pricing-features li svg {
  flex-shrink: 0;
  margin-top: 2px;
  color: var(--accent);
}

/* --- CTA section --- */
.cta-section {
  text-align: center;
  background-image: linear-gradient(180deg, rgba(242, 242, 247, 0.6) 0%, rgba(229, 229, 234, 0.6) 100%), url('assets/bg-sky-day.webp');
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.cta-section h2 {
  font-weight: 800;
  margin-bottom: var(--space-lg);
}

.cta-section .btn {
  min-height: var(--tap-min);
}

/* --- Privacy --- */
.privacy-content {
  max-width: 640px;
  margin: 0 auto;
  text-align: center;
}

.privacy-icon {
  width: var(--icon-size);
  height: var(--icon-size);
  margin: 0 auto var(--space-lg);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
}

.privacy-icon svg {
  width: var(--icon-size);
  height: var(--icon-size);
}

.privacy-content h2 {
  font-weight: 800;
  margin-bottom: var(--space-md);
}

.privacy-content p,
.privacy-content ul {
  font-size: 1rem;
  margin-bottom: var(--space-md);
}

.privacy-content ul {
  list-style: none;
  padding: 0;
}

.privacy-content li {
  margin-bottom: var(--space-sm);
}

/* --- FAQ --- */
#faq {
  background: #FAFAFC;
}

#faq .container {
  max-width: 640px;
}

#faq p {
  margin-bottom: var(--space-lg);
}

/* --- Contact --- */
#contact {
  text-align: center;
}

.contact-email {
  font-size: 1.1rem;
  font-weight: 500;
  color: var(--accent);
  min-height: var(--tap-min);
  display: inline-flex;
  align-items: center;
}

/* --- Footer --- */
.footer {
  background: var(--bg-secondary);
  padding: var(--space-xl) 0;
  border-top: 1px solid var(--border);
}

.footer-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--space-lg);
}

.footer-brand {
  display: flex;
  flex-direction: column;
  gap: var(--space-xs);
}

.footer-logo {
  font-family: inherit;
  font-weight: 400;
  font-size: 1.1rem;
  color: var(--text-primary);
}

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

.footer-nav {
  display: flex;
  gap: var(--space-lg);
}

.footer-nav a {
  font-size: 0.9rem;
  color: var(--text-secondary);
  min-height: var(--tap-min);
  display: inline-flex;
  align-items: center;
  padding: var(--space-sm) var(--space-md);
  border-radius: var(--radius-sm);
  transition: color 0.2s ease, background 0.2s ease;
}

.footer-nav a:hover {
  color: var(--accent);
  background: var(--accent-subtle);
}

.footer-nav a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* --- Legal pages (Privacy, Terms) — same iOS style as main site --- */
.legal-main {
  padding: var(--space-xxxl) 0;
  min-height: calc(100vh - 200px);
}

.legal-container {
  max-width: 720px;
  margin: 0 auto;
}

.legal-article h1 {
  font-weight: 800;
  margin-bottom: var(--space-md);
}

.legal-article h2 {
  font-weight: 800;
  margin-top: var(--space-xl);
  margin-bottom: var(--space-md);
}

.legal-article section {
  margin-bottom: var(--space-xl);
}

.legal-article section:last-of-type {
  margin-bottom: 0;
}

.effective-date {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin-bottom: var(--space-xl);
  padding-bottom: var(--space-lg);
  border-bottom: 1px solid var(--border-light);
}

.legal-article ul,
.legal-article ol {
  padding-left: var(--space-xl);
  margin-bottom: var(--space-md);
  color: var(--text-secondary);
}

.legal-article li {
  margin-bottom: var(--space-sm);
}

.legal-article .small {
  font-size: 0.9rem;
  color: var(--text-muted);
  margin-top: var(--space-sm);
}

.back-link {
  margin-top: var(--space-xxxl);
  padding-top: var(--space-xl);
  border-top: 1px solid var(--border-light);
}

.back-link a {
  display: inline-flex;
  align-items: center;
  gap: var(--space-sm);
  font-weight: 500;
  color: var(--accent);
  min-height: var(--tap-min);
  border-radius: var(--radius-sm);
  padding: var(--space-sm) 0;
}

.back-link a:hover {
  color: var(--accent-hover);
}

.back-link a:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

@media (max-width: 768px) {
  .legal-main {
    padding: var(--space-xxl) 0;
  }
}

/* --- Cookie consent banner --- */
.cookie-consent-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 9999;
  padding: var(--space-md) var(--container-pad);
  background: var(--bg-elevated);
  border-top: 1px solid var(--border);
  box-shadow: 0 -4px 20px rgba(0, 0, 0, 0.08);
}

.cookie-consent-inner {
  max-width: var(--container-max);
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-md);
}

.cookie-consent-text {
  flex: 1;
  min-width: 200px;
  margin: 0;
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.45;
}

.cookie-consent-actions {
  display: flex;
  gap: var(--space-sm);
  flex-shrink: 0;
}

.cookie-consent-btn {
  padding: var(--space-sm) var(--space-lg);
  border-radius: var(--radius-lg);
  font-weight: 600;
  font-size: 0.95rem;
  cursor: pointer;
  border: none;
  font-family: inherit;
  min-height: var(--tap-min);
  transition: background 0.2s ease, color 0.2s ease;
}

.cookie-consent-accept {
  background: var(--accent);
  color: #fff;
}

.cookie-consent-accept:hover {
  background: var(--accent-hover);
}

.cookie-consent-decline {
  background: var(--bg-secondary);
  color: var(--text-primary);
}

.cookie-consent-decline:hover {
  background: var(--border);
}

/* --- Inline overrides (preserve existing inline styles where used) --- */
/* Sections that use inline margin/padding/color keep working; tokens above provide fallbacks. */

/* --- Responsive --- */
@media (max-width: 768px) {
  :root {
    --container-pad: 20px;
  }
  
  .hero-content {
    grid-template-columns: 1fr;
    gap: var(--space-xl);
  }
  
  .hero-image {
    order: -1;
  }
  
  .features-grid {
    grid-template-columns: 1fr;
  }
  
  .benefits-grid {
    grid-template-columns: 1fr;
  }
  
  .captains-log-row {
    grid-template-columns: 1fr;
  }
  
  .pricing-grid {
    grid-template-columns: 1fr;
  }
  
  .section {
    padding: var(--space-xxl) 0;
  }
  
  .hero {
    padding: var(--space-xxl) 0;
  }
  
  .footer-content {
    flex-direction: column;
    text-align: center;
  }
}

@media (max-width: 480px) {
  :root {
    --container-pad: 16px;
  }
  
  h1 {
    font-size: 1.75rem;
  }
  
  h2 {
    font-size: 1.5rem;
  }
  
  .hero-tagline {
    font-size: 1.15rem;
  }
  
  .hero-description {
    font-size: 1rem;
  }
}
