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

:root {
  --green-deep: #0a6e1a;
  --green-main: #1a9e2c;
  --green-light: #2cc940;
  --gold: #f5c518;
  --gold-dark: #d4a80e;
  --white: #ffffff;
  --off-white: #f0f5f1;
  --dark: #0d1f11;
  --gray: #6b7c6f;
}

html { scroll-behavior: smooth; }

body {
  font-family: 'DM Sans', sans-serif;
  background: var(--dark);
  color: var(--white);
  overflow-x: hidden;
  min-height: 100vh;
}

/* ═══════ BACKGROUND ═══════ */
.bg-layer {
  position: fixed;
  inset: 0;
  z-index: 0;
  background: 
    radial-gradient(ellipse 80% 60% at 50% 0%, rgba(26,158,44,0.25) 0%, transparent 60%),
    radial-gradient(ellipse 60% 50% at 80% 100%, rgba(245,197,24,0.1) 0%, transparent 50%),
    radial-gradient(ellipse 40% 40% at 10% 80%, rgba(26,158,44,0.08) 0%, transparent 50%),
    linear-gradient(180deg, #0a1a0d 0%, #0d1f11 40%, #0f2514 100%);
}

/* noise overlay */
.bg-layer::after {
  content: '';
  position: absolute;
  inset: 0;
  opacity: 0.03;
  background-image: url("data:image/svg+xml,%3Csvg viewBox='0 0 256 256' xmlns='http://www.w3.org/2000/svg'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='4' stitchTiles='stitch'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 256px 256px;
}

/* ═══════ APP ENTRY ═══════ */
.app-entry-button {
  position: absolute;
  top: 50px;
  right: 50px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 13px 17px;
  border: 1px solid #91C8BE;
  border-radius: 16px;
  background: transparent;
  color: #F5F5F5;
  text-decoration: none;
  white-space: nowrap;
  font-family: "SF Pro Display", -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  font-weight: 700;
  font-size: 18px;
  line-height: 1.1;
  letter-spacing: 0;
  cursor: pointer;
}

.app-entry-icon {
  display: block;
  width: 20px;
  height: 20px;
  flex: 0 0 20px;
}

.app-entry-arrow-icon { display: none; }
.app-entry-button--authenticated .app-entry-user-icon { display: none; }
.app-entry-button--authenticated .app-entry-arrow-icon { display: block; }

.app-entry-button:focus-visible {
  outline: 2px solid #F5F5F5;
  outline-offset: 3px;
}

/* ═══════ MAIN CONTAINER ═══════ */
.container {
  position: relative;
  z-index: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  padding: 60px 24px 40px;
}

/* ═══════ FLOATING PARTICLES ═══════ */
.particles {
  position: fixed;
  inset: 0;
  z-index: 0;
  pointer-events: none;
}
.particle {
  position: absolute;
  width: 4px;
  height: 4px;
  background: var(--gold);
  border-radius: 50%;
  opacity: 0;
  animation: floatUp 6s ease-in-out infinite;
}
.particle:nth-child(1) { left: 10%; animation-delay: 0s; animation-duration: 7s; }
.particle:nth-child(2) { left: 25%; animation-delay: 1.2s; animation-duration: 5.5s; }
.particle:nth-child(3) { left: 45%; animation-delay: 2.4s; animation-duration: 6.5s; }
.particle:nth-child(4) { left: 65%; animation-delay: 0.8s; animation-duration: 8s; }
.particle:nth-child(5) { left: 80%; animation-delay: 3s; animation-duration: 6s; }
.particle:nth-child(6) { left: 90%; animation-delay: 1.8s; animation-duration: 7.5s; }
.particle:nth-child(7) { left: 35%; animation-delay: 4s; animation-duration: 5s; }
.particle:nth-child(8) { left: 55%; animation-delay: 2s; animation-duration: 9s; }

@keyframes floatUp {
  0% { transform: translateY(100vh) scale(0); opacity: 0; }
  15% { opacity: 0.6; }
  85% { opacity: 0.3; }
  100% { transform: translateY(-10vh) scale(1.2); opacity: 0; }
}

/* ═══════ LOGO ═══════ */
.logo-wrap {
  position: relative;
  margin-bottom: 32px;
  animation: logoEntry 1s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.logo-glow {
  position: absolute;
  inset: -30px;
  background: radial-gradient(circle, rgba(245,197,24,0.25) 0%, transparent 70%);
  border-radius: 50%;
  filter: blur(20px);
  animation: pulseGlow 3s ease-in-out infinite alternate;
}

.logo-img {
  width: 160px;
  height: 160px;
  border-radius: 36px;
  position: relative;
  box-shadow: 
    0 20px 60px rgba(0,0,0,0.5),
    0 0 0 1px rgba(255,255,255,0.05),
    inset 0 1px 0 rgba(255,255,255,0.1);
}

@keyframes logoEntry {
  from { opacity: 0; transform: translateY(30px) scale(0.8); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes pulseGlow {
  from { opacity: 0.5; transform: scale(0.95); }
  to { opacity: 1; transform: scale(1.05); }
}

/* ═══════ TITLE ═══════ */
.title {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-weight: 800;
  font-size: clamp(2.8rem, 7vw, 4.5rem);
  letter-spacing: -0.02em;
  text-align: center;
  margin-bottom: 12px;
  animation: fadeUp 0.8s 0.15s cubic-bezier(0.22, 1, 0.36, 1) both;
  background: linear-gradient(135deg, var(--white) 30%, var(--gold) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.subtitle {
  font-size: clamp(1rem, 2.5vw, 1.25rem);
  color: rgba(255,255,255,0.6);
  text-align: center;
  max-width: 440px;
  line-height: 1.6;
  margin-bottom: 48px;
  animation: fadeUp 0.8s 0.3s cubic-bezier(0.22, 1, 0.36, 1) both;
  font-weight: 400;
}

@keyframes fadeUp {
  from { opacity: 0; transform: translateY(24px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ═══════ RATING BADGE ═══════ */
.rating-badge {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  margin-top: 36px;
  animation: fadeUp 0.8s 0.55s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.laurel {
  width: 36px;
  height: 90px;
  color: var(--gold);
  flex-shrink: 0;
  opacity: 0.7;
}

.rating-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  padding: 0 4px;
}

.rating-number {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-weight: 800;
  font-size: 2.2rem;
  letter-spacing: -0.02em;
  background: linear-gradient(135deg, var(--gold) 0%, var(--gold-dark) 100%);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  line-height: 1;
}

.rating-stars {
  font-size: 0.85rem;
  letter-spacing: 2px;
  color: var(--gold);
  line-height: 1;
}

.rating-label {
  font-size: 0.65rem;
  color: rgba(255,255,255,0.3);
  text-transform: uppercase;
  letter-spacing: 0.1em;
  font-weight: 500;
  margin-top: 2px;
}

/* ═══════ BUTTONS ═══════ */
.buttons {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  justify-content: center;
  animation: fadeUp 0.8s 0.45s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.btn-download {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 16px 28px;
  border-radius: 16px;
  text-decoration: none;
  font-family: 'DM Sans', sans-serif;
  font-weight: 600;
  font-size: 1rem;
  transition: all 0.3s cubic-bezier(0.22, 1, 0.36, 1);
  cursor: pointer;
  border: none;
  position: relative;
  overflow: hidden;
}

.btn-download::before {
  content: '';
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.3s;
}

.btn-download:hover::before { opacity: 1; }

.buttons.buttons--onboarding { width: 100%; max-width: 440px; }
.btn-continue {
  width: 100%;
  min-height: 60px;
  justify-content: center;
  background: var(--white);
  color: var(--dark);
  font-size: 1.15rem;
  font-weight: 700;
  box-shadow: 0 8px 32px rgba(0,0,0,0.3);
}
.btn-continue:hover { transform: translateY(-3px); }
.btn-continue:focus-visible { outline: 2px solid var(--white); outline-offset: 4px; }

/* Apple */
.btn-apple {
  background: var(--white);
  color: var(--dark);
  box-shadow: 
    0 8px 32px rgba(0,0,0,0.3),
    0 0 0 1px rgba(255,255,255,0.1);
}
.btn-apple::before {
  background: linear-gradient(135deg, rgba(245,197,24,0.1), rgba(26,158,44,0.05));
}
.btn-apple:hover {
  transform: translateY(-3px);
  box-shadow: 
    0 12px 40px rgba(0,0,0,0.4),
    0 0 0 1px rgba(255,255,255,0.15),
    0 0 30px rgba(245,197,24,0.15);
}

/* Google */
.btn-google {
  background: var(--white);
  color: var(--dark);
  box-shadow: 
    0 8px 32px rgba(0,0,0,0.3),
    0 0 0 1px rgba(255,255,255,0.1);
}
.btn-google::before {
  background: linear-gradient(135deg, rgba(245,197,24,0.1), rgba(26,158,44,0.05));
}
.btn-google:hover {
  transform: translateY(-3px);
  box-shadow: 
    0 12px 40px rgba(0,0,0,0.4),
    0 0 0 1px rgba(255,255,255,0.15),
    0 0 30px rgba(245,197,24,0.15);
}

.btn-icon {
  width: 28px;
  height: 28px;
  flex-shrink: 0;
}

.btn-text {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  line-height: 1.2;
}

.btn-text small {
  font-size: 0.7rem;
  font-weight: 400;
  opacity: 0.7;
  letter-spacing: 0.02em;
}

.btn-text span {
  font-size: 1.05rem;
  font-weight: 700;
  letter-spacing: -0.01em;
}

/* ═══════ FEATURES STRIP ═══════ */
.features {
  display: flex;
  gap: 32px;
  margin-top: 56px;
  flex-wrap: wrap;
  justify-content: center;
  animation: fadeUp 0.8s 0.6s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.feature {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 0.9rem;
  color: rgba(255,255,255,0.45);
  font-weight: 500;
}

.feature-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--green-light);
  box-shadow: 0 0 12px rgba(44,201,64,0.4);
}

/* ═══════ FOOTER ═══════ */
.footer {
  width: 100%;
  max-width: 600px;
  margin-top: 32px;
  padding-top: 12px;
  text-align: center;
  font-size: 0.8rem;
  color: rgba(255,255,255,0.25);
  animation: fadeUp 0.8s 0.75s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: center;
  gap: 8px 28px;
}

.footer-links a {
  display: inline-flex;
  align-items: center;
  min-height: 44px;
  padding: 10px 0;
  color: rgba(255,255,255,0.25);
  font-weight: 500;
  text-decoration: underline;
  text-decoration-color: rgba(255,255,255,0.15);
  text-underline-offset: 5px;
  border-radius: 4px;
  transition: color 0.25s, text-decoration-color 0.25s;
}

.footer-links a:hover,
.footer-links a:focus-visible {
  color: rgba(255,255,255,0.4);
  text-decoration-color: rgba(255,255,255,0.4);
}

.footer-links a:focus-visible {
  outline: 2px solid rgba(255,255,255,0.4);
  outline-offset: 4px;
}

.footer-company {
  margin-top: 12px;
  color: rgba(255,255,255,0.25);
  font-weight: 500;
  letter-spacing: 0.03em;
}

.footer-copyright {
  margin-top: 12px;
  font-size: 0.72rem;
  color: rgba(255,255,255,0.25);
}

/* ═══════ MODAL OVERLAY ═══════ */
.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 1000;
  background: rgba(0,0,0,0.7);
  backdrop-filter: blur(12px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  opacity: 0;
  visibility: hidden;
  transition: all 0.35s cubic-bezier(0.22, 1, 0.36, 1);
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal {
  background: linear-gradient(170deg, #152018 0%, #0d1a10 100%);
  border: 1px solid rgba(255,255,255,0.08);
  border-radius: 24px;
  padding: 48px 36px;
  max-width: 440px;
  width: 100%;
  text-align: center;
  transform: translateY(20px) scale(0.96);
  transition: transform 0.35s cubic-bezier(0.22, 1, 0.36, 1);
  box-shadow: 
    0 40px 80px rgba(0,0,0,0.5),
    0 0 0 1px rgba(255,255,255,0.04);
  position: relative;
  overflow: hidden;
}

.modal::before {
  content: '';
  position: absolute;
  top: -50%;
  left: -50%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle at 60% 30%, rgba(44,201,64,0.06) 0%, transparent 50%);
  pointer-events: none;
}

.modal-overlay.active .modal {
  transform: translateY(0) scale(1);
}

.modal-close {
  position: absolute;
  top: 16px;
  right: 16px;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: none;
  background: rgba(255,255,255,0.06);
  color: rgba(255,255,255,0.5);
  font-size: 1.2rem;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  z-index: 2;
}
.modal-close:hover {
  background: rgba(255,255,255,0.12);
  color: var(--white);
}

.modal-icon {
  width: 64px;
  height: 64px;
  margin: 0 auto 20px;
  background: linear-gradient(135deg, var(--green-main), var(--green-light));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  position: relative;
}

.modal-icon svg {
  width: 28px;
  height: 28px;
  fill: var(--white);
}

.modal h2 {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-size: 1.6rem;
  font-weight: 800;
  margin-bottom: 10px;
  position: relative;
}

.modal p {
  color: rgba(255,255,255,0.55);
  font-size: 0.95rem;
  line-height: 1.6;
  margin-bottom: 28px;
  position: relative;
}

.modal-input {
  width: 100%;
  padding: 16px 20px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,0.1);
  background: rgba(255,255,255,0.04);
  color: var(--white);
  font-family: 'DM Sans', sans-serif;
  font-size: 1rem;
  outline: none;
  transition: all 0.25s;
  margin-bottom: 14px;
  position: relative;
}

.modal-input::placeholder {
  color: rgba(255,255,255,0.25);
}

.modal-input:focus {
  border-color: var(--green-light);
  background: rgba(44,201,64,0.04);
  box-shadow: 0 0 0 3px rgba(44,201,64,0.1);
}

.modal-submit {
  width: 100%;
  padding: 16px;
  border-radius: 14px;
  border: none;
  background: linear-gradient(135deg, var(--green-main) 0%, var(--green-light) 100%);
  color: var(--white);
  font-family: 'DM Sans', sans-serif;
  font-weight: 700;
  font-size: 1.05rem;
  cursor: pointer;
  transition: all 0.3s;
  position: relative;
  overflow: hidden;
}

.modal-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(44,201,64,0.3);
}

.modal-submit:active {
  transform: translateY(0);
}

.modal-submit.success {
  background: linear-gradient(135deg, var(--gold-dark), var(--gold));
  color: var(--dark);
}

/* ═══════ CHECKBOX ═══════ */
.modal-checkbox {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
  cursor: pointer;
  position: relative;
  user-select: none;
}

.modal-checkbox input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}

.checkmark {
  width: 16px;
  height: 16px;
  min-width: 16px;
  border-radius: 4px;
  border: 1.5px solid rgba(255,255,255,0.2);
  background: rgba(255,255,255,0.04);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.25s;
}

.checkmark::after {
  content: '';
  width: 10px;
  height: 10px;
  background: url("data:image/svg+xml,%3Csvg viewBox='0 0 12 12' fill='none' xmlns='http://www.w3.org/2000/svg'%3E%3Cpath d='M2 6l3 3 5-6' stroke='white' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E") center/contain no-repeat;
  opacity: 0;
  transform: scale(0.5);
  transition: all 0.2s;
}

.modal-checkbox input:checked ~ .checkmark {
  background: var(--green-main);
  border-color: var(--green-light);
  box-shadow: 0 0 12px rgba(44,201,64,0.25);
}

.modal-checkbox input:checked ~ .checkmark::after {
  opacity: 1;
  transform: scale(1);
}

.checkbox-label {
  font-size: 0.72rem;
  color: rgba(255,255,255,0.3);
  line-height: 1.4;
  text-align: left;
}

/* ═══════ SEO FAQ ACCORDION ═══════ */
.seo-section {
  margin-top: 64px;
  padding-top: 48px;
  border-top: 1px solid rgba(255,255,255,0.05);
  max-width: 600px;
  width: 100%;
  text-align: left;
  animation: fadeUp 0.8s 0.9s cubic-bezier(0.22, 1, 0.36, 1) both;
}

.seo-heading {
  font-family: 'Bricolage Grotesque', sans-serif;
  font-size: 1.05rem;
  font-weight: 700;
  color: rgba(255,255,255,0.2);
  margin-bottom: 16px;
  text-align: center;
}

.faq-item {
  border-bottom: 1px solid rgba(255,255,255,0.04);
}

.faq-question {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 0;
  font-size: 0.82rem;
  font-weight: 500;
  color: rgba(255,255,255,0.25);
  cursor: pointer;
  list-style: none;
  transition: color 0.25s;
  user-select: none;
}

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

.faq-question::after {
  content: '+';
  font-size: 1rem;
  font-weight: 300;
  color: rgba(255,255,255,0.15);
  transition: transform 0.3s, color 0.3s;
  flex-shrink: 0;
  margin-left: 12px;
}

details[open] .faq-question::after {
  content: '−';
  color: var(--green-light);
}

.faq-question:hover {
  color: rgba(255,255,255,0.4);
}

details[open] .faq-question {
  color: rgba(255,255,255,0.35);
}

.faq-answer {
  padding: 0 0 14px 0;
  animation: faqOpen 0.3s ease-out;
}

.faq-answer p {
  font-size: 0.8rem;
  color: rgba(255,255,255,0.4);
  line-height: 1.7;
}

@keyframes faqOpen {
  from { opacity: 0; transform: translateY(-4px); }
  to { opacity: 1; transform: translateY(0); }
}

/* ═══════ MOBILE ═══════ */
@media (max-width: 600px) {
  .app-entry-button {
    right: 32px;
  }

  .container {
    /* Keep the fixed Sign in / Go to App control clear of the hero on narrow screens. */
    padding: 120px 20px 32px;
  }

  .logo-img {
    width: 120px;
    height: 120px;
    border-radius: 28px;
  }

  .logo-glow { inset: -20px; }

  .logo-wrap { margin-bottom: 24px; }

  .subtitle { margin-bottom: 36px; }

  .buttons {
    flex-direction: column;
    width: 100%;
    max-width: 320px;
    gap: 12px;
  }

  .btn-download {
    width: 100%;
    justify-content: center;
    padding: 14px 24px;
  }

  .features {
    gap: 20px;
    margin-top: 40px;
  }

  .feature {
    font-size: 0.82rem;
  }

  .modal {
    padding: 36px 24px;
    border-radius: 20px;
  }

  .modal h2 { font-size: 1.35rem; }
}

@media (max-width: 380px) {
  .title { font-size: 2.2rem; }
  .logo-img {
    width: 100px;
    height: 100px;
    border-radius: 24px;
  }
}
