/* ==========================================================================
   Blue Peter — Landing Page Styles
   ========================================================================== */

/* ---------- Custom Properties ---------- */
:root {
  --primary: #0077B6;
  --primary-dark: #023E8A;
  --primary-light: #90E0EF;
  --accent: #00B4D8;
  --bg: #FAFAFA;
  --bg-alt: #F0F4F8;
  --text: #1A1A2E;
  --text-light: #6B7280;
  --white: #FFFFFF;
  --border: #E5E7EB;
  --success: #059669;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.12);
  --transition: 0.3s ease;
  --font-stack: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Oxygen,
    Ubuntu, Cantarell, "Fira Sans", "Droid Sans", "Helvetica Neue", Arial,
    sans-serif;
}

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

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
}

body {
  font-family: var(--font-stack);
  font-size: 16px;
  line-height: 1.6;
  color: var(--text);
  background-color: var(--bg);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

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

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

ul {
  list-style: none;
}

/* Screen reader only utility */
.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

/* ---------- Container ---------- */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 24px;
}

/* ---------- Buttons ---------- */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-stack);
  font-size: 1rem;
  font-weight: 600;
  padding: 12px 28px;
  border: none;
  border-radius: var(--radius-sm);
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
  line-height: 1.4;
}

.btn-primary {
  background-color: var(--accent);
  color: var(--white);
}

.btn-primary:hover {
  background-color: #0096b7;
  color: var(--white);
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.btn-primary:active {
  transform: translateY(0);
}

.btn-lg {
  font-size: 1.125rem;
  padding: 16px 36px;
  border-radius: var(--radius);
}

/* ---------- Section Shared ---------- */
.section {
  padding: 80px 0;
}

.section-title {
  font-size: 2rem;
  font-weight: 700;
  text-align: center;
  margin-bottom: 12px;
  color: var(--text);
  letter-spacing: -0.02em;
}

.section-subtitle {
  font-size: 1.125rem;
  text-align: center;
  color: var(--text-light);
  margin-bottom: 48px;
  max-width: 600px;
  margin-left: auto;
  margin-right: auto;
}

/* ---------- Header ---------- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1000;
  background: rgba(255, 255, 255, 0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--primary-dark);
  text-decoration: none;
}

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

.logo-icon {
  color: var(--primary);
}

.main-nav {
  display: flex;
  align-items: center;
  gap: 28px;
}

.main-nav a {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-light);
  transition: color var(--transition);
}

.main-nav a:hover {
  color: var(--primary);
}

.main-nav .nav-cta {
  background-color: var(--primary);
  color: var(--white);
  padding: 8px 20px;
  border-radius: var(--radius-sm);
  font-weight: 600;
}

.main-nav .nav-cta:hover {
  background-color: var(--primary-dark);
  color: var(--white);
}

/* ---------- 1. Hero ---------- */
.hero {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  color: var(--white);
  text-align: center;
  padding: 120px 24px 80px;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: "";
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(
    ellipse at 30% 50%,
    rgba(0, 180, 216, 0.15) 0%,
    transparent 60%
  );
  pointer-events: none;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 800px;
}

.hero-title {
  font-size: 3.25rem;
  font-weight: 800;
  line-height: 1.15;
  letter-spacing: -0.03em;
  margin-bottom: 20px;
}

.hero-subtitle {
  font-size: 1.25rem;
  font-weight: 400;
  opacity: 0.9;
  margin-bottom: 36px;
  line-height: 1.6;
}

.hero-tagline {
  margin-top: 32px;
  font-size: 0.95rem;
  opacity: 0.7;
  font-weight: 400;
}

/* ---------- 2. Steps ---------- */
.steps-section {
  background-color: var(--white);
}

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

.step-card {
  text-align: center;
  padding: 40px 24px;
  border-radius: var(--radius);
  background: var(--bg);
  border: 1px solid var(--border);
  transition: transform var(--transition), box-shadow var(--transition);
  position: relative;
}

.step-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.step-number {
  position: absolute;
  top: 16px;
  left: 20px;
  font-size: 0.8rem;
  font-weight: 700;
  color: var(--accent);
  background: rgba(0, 180, 216, 0.1);
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

.step-icon {
  color: var(--primary);
  margin-bottom: 20px;
  display: flex;
  justify-content: center;
}

.step-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 10px;
  color: var(--text);
}

.step-desc {
  font-size: 0.95rem;
  color: var(--text-light);
  line-height: 1.6;
}

/* ---------- 3. Demo ---------- */
.demo-section {
  background-color: var(--bg-alt);
}

.demo-placeholder {
  max-width: 800px;
  margin: 0 auto;
  aspect-ratio: 16 / 9;
  background: linear-gradient(135deg, #d1d5db 0%, #9ca3af 100%);
  border-radius: var(--radius);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  color: var(--white);
  gap: 16px;
}

.demo-play-icon {
  opacity: 0.8;
}

.demo-text {
  font-size: 1.25rem;
  font-weight: 600;
}

.demo-subtext {
  font-size: 0.9rem;
  opacity: 0.8;
}

/* ---------- 4. Features ---------- */
.features-section {
  background-color: var(--white);
}

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

.feature-card {
  padding: 32px;
  border-radius: var(--radius);
  background: var(--bg);
  border: 1px solid var(--border);
  transition: transform var(--transition), box-shadow var(--transition);
}

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

.feature-icon {
  color: var(--primary);
  margin-bottom: 16px;
}

.feature-title {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 8px;
  color: var(--text);
}

.feature-desc {
  font-size: 0.95rem;
  color: var(--text-light);
  line-height: 1.6;
}

/* ---------- 5. Compatibility ---------- */
.compatibility-section {
  background-color: var(--bg-alt);
}

.compatibility-list {
  max-width: 500px;
  margin: 0 auto;
  text-align: center;
}

.compatibility-list ul {
  text-align: left;
  display: inline-block;
}

.compatibility-list li {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 0;
  font-size: 1.05rem;
  font-weight: 500;
  color: var(--text);
  border-bottom: 1px solid var(--border);
}

.compatibility-list li:last-child {
  border-bottom: none;
}

.check-icon {
  color: var(--success);
  flex-shrink: 0;
}

.compatibility-note {
  margin-top: 24px;
  font-size: 0.95rem;
  color: var(--text-light);
  font-style: italic;
}

/* ---------- 6. Waitlist ---------- */
.waitlist-section {
  background: linear-gradient(135deg, var(--primary-dark) 0%, var(--primary) 100%);
  color: var(--white);
}

.waitlist-section .section-title {
  color: var(--white);
}

.waitlist-section .section-subtitle {
  color: rgba(255, 255, 255, 0.8);
}

.waitlist-form-wrapper {
  max-width: 560px;
  margin: 0 auto;
}

.waitlist-form .form-group {
  display: flex;
  gap: 12px;
}

.waitlist-form input[type="email"] {
  flex: 1;
  padding: 14px 18px;
  font-size: 1rem;
  font-family: var(--font-stack);
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-radius: var(--radius-sm);
  background: rgba(255, 255, 255, 0.1);
  color: var(--white);
  outline: none;
  transition: border-color var(--transition), background var(--transition);
}

.waitlist-form input[type="email"]::placeholder {
  color: rgba(255, 255, 255, 0.5);
}

.waitlist-form input[type="email"]:focus {
  border-color: var(--accent);
  background: rgba(255, 255, 255, 0.15);
}

.waitlist-form .btn-primary {
  background-color: var(--accent);
  white-space: nowrap;
}

.waitlist-form .btn-primary:hover {
  background-color: #0096b7;
}

.form-checkbox {
  margin-top: 16px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.form-checkbox input[type="checkbox"] {
  margin-top: 3px;
  width: 18px;
  height: 18px;
  accent-color: var(--accent);
  flex-shrink: 0;
  cursor: pointer;
}

.form-checkbox label {
  font-size: 0.9rem;
  color: rgba(255, 255, 255, 0.85);
  cursor: pointer;
  line-height: 1.5;
}

.waitlist-success {
  text-align: center;
  padding: 24px;
  color: var(--white);
}

.waitlist-success svg {
  color: var(--primary-light);
  margin-bottom: 16px;
}

.waitlist-success .success-title {
  font-size: 1.35rem;
  font-weight: 700;
  margin-bottom: 8px;
}

.waitlist-success .success-subtitle {
  font-size: 0.95rem;
  opacity: 0.8;
}

/* ---------- 7. FAQ ---------- */
.faq-section {
  background-color: var(--white);
}

.faq-list {
  max-width: 720px;
  margin: 0 auto;
}

.faq-item {
  border-bottom: 1px solid var(--border);
}

.faq-item:first-child {
  border-top: 1px solid var(--border);
}

.faq-question {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 20px 0;
  background: none;
  border: none;
  font-family: var(--font-stack);
  font-size: 1.05rem;
  font-weight: 600;
  color: var(--text);
  cursor: pointer;
  text-align: left;
  transition: color var(--transition);
  gap: 16px;
}

.faq-question:hover {
  color: var(--primary);
}

.faq-toggle {
  font-size: 1.5rem;
  font-weight: 300;
  color: var(--text-light);
  transition: transform var(--transition), color var(--transition);
  flex-shrink: 0;
  width: 24px;
  text-align: center;
  line-height: 1;
}

.faq-item.active .faq-toggle {
  transform: rotate(45deg);
  color: var(--primary);
}

.faq-answer {
  overflow: hidden;
  transition: max-height 0.4s ease, opacity 0.3s ease;
  max-height: 0;
  opacity: 0;
}

.faq-answer[hidden] {
  display: block;
  max-height: 0;
  opacity: 0;
}

.faq-answer:not([hidden]) {
  max-height: 300px;
  opacity: 1;
}

.faq-answer p {
  padding: 0 0 20px;
  font-size: 0.95rem;
  color: var(--text-light);
  line-height: 1.7;
}

/* ---------- Footer ---------- */
.site-footer {
  background-color: var(--text);
  color: rgba(255, 255, 255, 0.6);
  padding: 40px 0;
  text-align: center;
}

.footer-inner p {
  font-size: 0.9rem;
}

.footer-tagline {
  margin-top: 8px;
  font-style: italic;
  font-size: 0.85rem;
  opacity: 0.7;
}

/* ---------- Fade-in Animation ---------- */
.fade-in {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.6s ease-out, transform 0.6s ease-out;
}

.fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Hero fade-in should not start offset (already in viewport) */
.hero .fade-in {
  opacity: 0;
  transform: translateY(16px);
}

.hero .fade-in.visible {
  opacity: 1;
  transform: translateY(0);
}

/* ---------- Responsive ---------- */

/* Tablet */
@media (max-width: 900px) {
  .main-nav {
    gap: 16px;
  }

  .main-nav a {
    font-size: 0.85rem;
  }

  .hero-title {
    font-size: 2.5rem;
  }

  .steps-grid {
    grid-template-columns: 1fr;
    max-width: 480px;
    margin: 0 auto;
  }

  .features-grid {
    grid-template-columns: 1fr;
    max-width: 500px;
    margin: 0 auto;
  }
}

/* Mobile */
@media (max-width: 640px) {
  .site-header {
    position: static;
    backdrop-filter: none;
  }

  .main-nav {
    display: none;
  }

  .hero {
    min-height: auto;
    padding: 80px 20px 60px;
  }

  .hero-title {
    font-size: 2rem;
  }

  .hero-subtitle {
    font-size: 1.05rem;
  }

  .section {
    padding: 56px 0;
  }

  .section-title {
    font-size: 1.6rem;
  }

  .section-subtitle {
    font-size: 1rem;
    margin-bottom: 32px;
  }

  .waitlist-form .form-group {
    flex-direction: column;
  }

  .waitlist-form .btn-primary {
    width: 100%;
  }

  .faq-question {
    font-size: 0.95rem;
    padding: 16px 0;
  }
}

/* ---------- Print ---------- */
@media print {
  .site-header,
  .waitlist-section,
  .demo-section {
    display: none;
  }

  .hero {
    min-height: auto;
    padding: 40px 0;
    background: none;
    color: var(--text);
  }
}
