/* =============== Base =============== */
:root {
  /* Brand palette (from logo) */
  --brand-aqua: #5FE8E7;   /* light aqua */
  --brand-teal: #22B6B3;   /* teal primary */
  --brand-teal-dk: #159A97;/* teal hover */
  --brand-navy: #3B5C82;   /* navy circle */
  --brand-lime: #CFE87A;   /* lime accent */

  /* New preferred colors */
  --accent-blue: #45B7D1;   /* from "See prices" button */
  --muted-blue: #A1B6C9;    /* from muted blue background */
  --input-grey: #EDEDED;    /* from input field background */
  --lime-green: #B8E986;    /* from bright green sample */

  /* App tokens derived from brand */
  --text-strong: #0F1B2B;
  --text: #102536;
  --text-muted: #4b5c65;
  --border: #D4DEE4;
  --bg: #F0F4F8;           /* very light blue-grey */
  --bg-soft: #E8EFF5;      /* slightly deeper blue-grey */
  --cta: var(--accent-blue);
  --cta-hover: #369EB7;

  /* UI tokens for mockup vibe */
  --header: #203A52;       /* dark blue header bar */
  --card: #FFFFFF;         /* white cards on blue-grey background */
  --card-border: #D4DEE4;  /* soft border */
  --header-height: 50px;
}

* { box-sizing: border-box; }
html, body {
  margin: 0;
  padding: 0;
  min-height: 100vh;
}

body {
  font-family: Inter, system-ui, -apple-system, Segoe UI, Roboto, "Helvetica Neue", Arial, "Noto Sans", "Apple Color Emoji", "Segoe UI Emoji", "Segoe UI Symbol", sans-serif;
  color: var(--text);
  background: var(--bg);
  line-height: 1.6;
  display: flex;
  flex-direction: column;
}

a { color: var(--cta); text-decoration: none; }
h1, h2, h3 { color: var(--text-strong); margin: 0 0 .4em; }
p { margin: 0 0 1em; }

/* =============== Header =============== */
header.sticky-header {
  position: sticky;
  top: 0;
  z-index: 1000;
  background: var(--header);
  border-bottom: 1px solid rgba(0,0,0,.06);
  box-shadow: 0 1px 0 rgba(0,0,0,.04);
}
.nav {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  max-width: 1180px;
  margin: 0 auto;
  min-height: var(--header-height);
  padding: 0 16px; /* keeps banner slim */
}
.logo { font-weight: 800; font-size: 1.4rem; letter-spacing: .5px; color: #fff; text-transform: lowercase; }
.logo img {
  height: calc(var(--header-height) - 6px); /* big logo in a small bar */
  max-height: 46px;
  width: auto;
  display: block;
}
.social-icons { display: flex; gap: 12px; align-items: center; }
.social-icons a {
  color: #fff;
  opacity: .9;
  transition: .2s ease;
  display: flex;
  align-items: center;
}
.social-icons a:hover, .social-icons a:focus { color: var(--brand-aqua); opacity: 1; transform: translateY(-1px); outline: none; }
.social-icons svg {
  display: block;
}

.nav nav a { margin-left: 1.5em; color: #fff; opacity: .9; font-weight: 600; transition: color .2s ease, opacity .2s ease, box-shadow .2s ease; font-size: .95rem; }
.nav nav a:hover, .nav nav a:focus { color: var(--brand-aqua); opacity: 1; box-shadow: inset 0 -2px 0 var(--brand-aqua); outline: none; }

/* Accessible focus treatment */
.nav nav a:focus-visible, .cta-button:focus-visible {
  outline: 2px solid var(--brand-aqua);
  outline-offset: 2px;
}
/* Subtle underline animation for nav links */
.nav nav a {
  position: relative;
}
.nav nav a::after {
  content: "";
  position: absolute;
  left: 0; right: 0; bottom: -6px; height: 2px;
  background: currentColor; opacity: 0; transform: scaleX(.3);
  transition: opacity .2s ease, transform .2s ease;
}
.nav nav a:hover::after, .nav nav a:focus-visible::after { opacity: 1; transform: scaleX(1); }

/* =============== Hero =============== */
.hero {
  padding: 4.25em 1.25em 2.75em; /* slightly shorter banner */
  text-align: center;
  background: linear-gradient(180deg, var(--bg-soft) 0%, var(--bg) 100%);
}
.hero h1 { font-size: clamp(2.2rem, 4vw, 3rem); }
.hero p { font-size: 1.125rem; color: var(--text-muted); margin-bottom: 2em; }

/* Constrain hero content width without extra markup */
.hero h1, .hero p, .hero .cta-button {
  max-width: 880px;
  margin-left: auto;
  margin-right: auto;
}
.hero h1 { line-height: 1.18; letter-spacing: -0.015em; }

.cta-button {
  display: inline-block; padding: .75em 1.5em; background: var(--cta); color: #fff; border: 2px solid transparent;
  border-radius: 12px; font-weight: 700; box-shadow: 0 6px 14px rgba(34,182,179,.25);
  transition: transform .15s ease, box-shadow .15s ease, background-color .15s ease;
}
.cta-button:hover, .cta-button:focus { background: var(--cta-hover); box-shadow: 0 8px 18px rgba(21,154,151,.28); transform: translateY(-1px); outline: none; }
.cta-button:active { transform: translateY(0); box-shadow: 0 4px 10px rgba(21,154,151,.22); }
.cta-button.sm { padding: .4em 1em; font-size: .875rem; }

/* Secondary/outlined option (if needed) */
.cta-button.secondary { background: transparent; color: var(--cta); border: 2px solid var(--cta); }
.cta-button.secondary:hover { background: var(--cta); color: #fff; }

/* Muted CTA (Contact section) */
.cta-button.muted { background: #e5e7eb; color: #1f2937; border-color: transparent; box-shadow: none; }
.cta-button.muted:hover, .cta-button.muted:focus { background: #d1d5db; color: #111827; transform: translateY(-1px); }

/* =============== App Store Badges =============== */
.app-badges {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 1em;
  margin-top: 1.5em;
}

.app-badge {
  height: 44px;
  width: auto;
}

.app-badge-link {
  display: inline-flex;
  transition: transform 0.15s ease, opacity 0.15s ease;
}

.app-badge-link:hover {
  transform: translateY(-1px);
  opacity: 0.9;
}

.app-badge-coming-soon {
  position: relative;
  display: inline-flex;
  align-items: center;
}

.app-badge-coming-soon .app-badge {
  opacity: 0.35;
  filter: grayscale(100%);
}

.app-badge-coming-soon span {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.75rem;
  font-weight: 700;
  color: var(--text-strong);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

/* =============== Sections =============== */
.content {
  width: 100%;
  padding: 1.5em 1.25em;
  max-width: 1100px;
  margin: 0 auto;
}

/* =============== Steps =============== */
.steps {
    display: flex;
    justify-content: center;
    align-items: stretch;
    flex-wrap: nowrap;       /* keep them side-by-side */
    gap: 1.25em;
    margin-top: 1em;
  }

  .step {
    flex: 1;
    max-width: 340px;
    padding: 1.75em;
    background: linear-gradient(180deg, var(--card) 0%, #ffffff 100%);
    border: 1px solid var(--card-border);
    border-radius: 14px;
    box-shadow: 0 2px 6px rgba(0,0,0,.06), 0 4px 12px rgba(0,0,0,.04);
    transition: transform .2s ease, box-shadow .2s ease;
    text-align: center;
  }

  .step:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0,0,0,.08), 0 12px 24px rgba(0,0,0,.06);
  }

  /* Mobile responsive: stack them only on smaller screens */
  @media (max-width: 768px) {
    .steps {
      flex-direction: column;
    }
    .step {
      max-width: none;
    }
  }

/* =============== Team =============== */
.team-container { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px,1fr)); gap: 16px; }
.profile img { width: 120px; height: 120px; border-radius: 50%; object-fit: cover; display: block; margin: 0 auto 8px; }
.profile p { text-align: center; margin: 0; }

/* =============== Footer =============== */
footer {
  text-align: center;
  padding: 1em;
  font-size: .9em;
  color: #6b7280;
  border-top: 1px solid var(--card-border);
  background: #fff;
  margin-top: auto;
}

footer .app-badges {
  margin: 1em 0 0.5em;
}

footer .app-badge {
  height: 36px;
}

/* =============== Responsive =============== */
@media (max-width: 768px) {
  .steps { flex-direction: column; gap: 16px; }
  .step { min-width: 0; }
  .nav nav a { margin-left: .75em; }
  .app-badges { flex-wrap: wrap; }
}

/* =============== Dark mode =============== */
@media (prefers-color-scheme: dark) {
  :root {
    --bg: #07151A;          /* very dark teal */
    --bg-soft: #0C1F25;     /* dark soft teal */
    --text-strong: #EAF7F7;
    --text: #EAF7F7;
    --text-muted: #CFE7E7;
    --border: #173A44;
    --cta: #45B7D1;         /* accent blue for CTA */
    --cta-hover: #369EB7;   /* slightly darker accent blue */
  }
  header.sticky-header { background: #102336; border-bottom-color: var(--border); box-shadow: none; }
  .logo, .nav nav a, .social-icons a { color: var(--text); opacity: .9; }
  .nav nav a:hover, .social-icons a:hover { color: var(--cta); }
  .hero { background: linear-gradient(180deg, var(--bg) 0%, var(--bg-soft) 65%); }
  .social-icons a { color: var(--text-muted); }
  .social-icons svg { filter: brightness(0) invert(1); opacity: .9; }
  .social-icons svg:hover { opacity: 1; }
  .step {
    background: #0b1220;
    color: var(--text-muted);
    border-color: var(--border);
    box-shadow: none;
  }
  footer { background: #0b1220; color: var(--text-muted); border-top-color: var(--border); }
  .app-badge-coming-soon span { color: var(--text); }

  /* Form inputs - soft teal tint for dark mode harmony */
  .input,
  .textarea {
    background: rgba(34, 182, 179, 0.08); /* Soft teal tint */
    color: var(--text);
    border-color: rgba(34, 182, 179, 0.2);
  }

  .input:focus,
  .textarea:focus {
    background: rgba(34, 182, 179, 0.12);
    border-color: var(--cta);
    box-shadow: 0 0 0 3px rgba(69, 183, 209, 0.15);
  }

  .input::placeholder,
  .textarea::placeholder {
    color: var(--text-muted);
    opacity: 0.6;
  }
}

/* Subtle header shadow to separate from page */
header.sticky-header { box-shadow: 0 1px 0 rgba(0,0,0,.05), 0 8px 20px rgba(0,0,0,.04); }

/* =============== Form Styling =============== */
.page-intro {
  font-size: 1.05rem;
  color: var(--text-muted);
  margin-bottom: 2em;
}

.waitlist-form {
  max-width: 100%;
}

.form-section {
  margin-bottom: 2.5em;
  padding-bottom: 2em;
  border-bottom: 1px solid var(--card-border);
}

.form-section:last-child {
  border-bottom: none;
}

.fieldset {
  border: none;
  padding: 0;
  margin: 0 0 1.5em 0;
}

.fieldset legend {
  font-weight: 600;
  font-size: 1.05rem;
  color: var(--text-strong);
  margin-bottom: 0.75em;
  padding: 0;
}

.choice-row {
  display: flex;
  gap: 1.5em;
  flex-wrap: wrap;
}

.choice {
  display: inline-flex;
  align-items: center;
  gap: 0.5em;
  font-size: 1rem;
  color: var(--text);
  cursor: pointer;
  padding: 0.5em 0;
}

.choice input[type="radio"],
.choice input[type="checkbox"] {
  width: 18px;
  height: 18px;
  cursor: pointer;
  accent-color: var(--cta);
}

.grid-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1.25em;
  margin-bottom: 1.25em;
}

@media (max-width: 640px) {
  .grid-2 {
    grid-template-columns: 1fr;
  }
}

.grid-2 label {
  display: block;
  font-weight: 600;
  font-size: 0.95rem;
  color: var(--text-strong);
  margin-bottom: 0.5em;
}

.grid-2 .required label::after {
  content: " *";
  color: #dc2626;
}

.input,
.textarea {
  width: 100%;
  padding: 0.75em 1em;
  font-size: 1rem;
  font-family: inherit;
  color: var(--text);
  background: rgba(95, 232, 231, 0.08); /* Soft aqua tint */
  border: 2px solid rgba(34, 182, 179, 0.15);
  border-radius: 8px;
  transition: all 0.2s ease;
}

.input:focus,
.textarea:focus {
  outline: none;
  background: rgba(95, 232, 231, 0.12);
  border-color: var(--cta);
  box-shadow: 0 0 0 3px rgba(69, 183, 209, 0.1);
}

.input::placeholder,
.textarea::placeholder {
  color: var(--text-muted);
  opacity: 0.7;
}

/* Only show validation styling after user has blurred the field */
.input.touched:invalid,
.textarea.touched:invalid {
  border-color: #dc2626;
}

.input.touched:valid:not(:placeholder-shown),
.textarea.touched:valid:not(:placeholder-shown) {
  border-color: #10b981;
}

.textarea {
  resize: vertical;
  min-height: 100px;
  line-height: 1.5;
}

.checkbox {
  display: block;
  font-size: 0.95rem;
  color: var(--text);
  margin: 1.5em 0;
  line-height: 1.5;
  max-width: 100%;
  overflow: hidden; /* Clear the float */
}

.checkbox input[type="checkbox"] {
  float: left;
  margin-top: 0.25em;
  margin-right: 0.75em;
  width: 18px;
  height: 18px;
  cursor: pointer;
  accent-color: var(--cta);
}

.checkbox.small {
  font-size: 0.9rem;
  color: var(--text-muted);
}

.checkbox a {
  color: var(--cta);
  text-decoration: underline;
}

.checkbox a:hover {
  color: var(--cta-hover);
}

.actions {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.75em;
  margin-top: 2em;
}

.actions .cta-button {
  min-width: 200px;
  text-align: center;
}

.caption {
  font-size: 0.85rem;
  color: var(--text-muted);
  font-style: italic;
}

/* Mobile nav toggle button */
.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: #fff;
  cursor: pointer;
  padding: 0.5em;
  margin-right: -0.5em;
}

@media (max-width: 768px) {
  .nav-toggle {
    display: block;
  }

  .nav nav {
    position: fixed;
    top: var(--header-height);
    right: 0;
    bottom: 0;
    width: 280px;
    background: var(--header);
    transform: translateX(100%);
    transition: transform 0.3s ease;
    padding: 2em 1.5em;
    box-shadow: -4px 0 12px rgba(0,0,0,0.15);
    z-index: 999;
  }

  .nav nav.open {
    transform: translateX(0);
  }

  .nav nav a {
    display: block;
    margin: 0 0 1.5em 0;
    padding: 0.5em 0;
    border-bottom: 1px solid rgba(255,255,255,0.1);
  }

  .nav nav a::after {
    display: none;
  }
}

/* Flash messages */
.flash-messages {
  position: fixed;
  top: calc(var(--header-height) + 1em);
  left: 50%;
  transform: translateX(-50%);
  z-index: 1001;
  width: 90%;
  max-width: 600px;
}

.flash-message {
  padding: 1em 1.5em;
  margin-bottom: 0.75em;
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  animation: slideDown 0.3s ease;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1em;
}

@keyframes slideDown {
  from {
    opacity: 0;
    transform: translateY(-1em);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.flash-message.notice {
  background: #10b981;
  color: #fff;
}

.flash-message.alert {
  background: #dc2626;
  color: #fff;
}

.flash-message button {
  background: none;
  border: none;
  color: inherit;
  font-size: 1.5em;
  line-height: 1;
  cursor: pointer;
  opacity: 0.8;
  padding: 0;
  width: 24px;
  height: 24px;
}

.flash-message button:hover {
  opacity: 1;
}

/* Smooth scroll */
html {
  scroll-behavior: smooth;
}

/* Legal Document Content Styling - Typography for legal documents */
.legal-content {
  max-width: 800px;
  margin: 0 auto;
  color: var(--text-strong);
  line-height: 1.75;
  font-size: 1rem;
}

.legal-content > * + * {
  margin-top: 1.25em;
}

.legal-content h1 {
  font-size: 2.25em;
  font-weight: 700;
  line-height: 1.2;
  margin-top: 0;
  margin-bottom: 0.8888889em;
  color: var(--text-strong);
}

.legal-content h2 {
  font-size: 1.5em;
  font-weight: 700;
  line-height: 1.3333333;
  margin-top: 2em;
  margin-bottom: 1em;
  color: var(--text-strong);
}

.legal-content h3 {
  font-size: 1.25em;
  font-weight: 600;
  line-height: 1.6;
  margin-top: 1.6em;
  margin-bottom: 0.6em;
  color: var(--text-strong);
}

.legal-content h4 {
  font-size: 1.125em;
  font-weight: 600;
  line-height: 1.5555556;
  margin-top: 1.5555556em;
  margin-bottom: 0.4444444em;
  color: var(--text-strong);
}

.legal-content p {
  margin-top: 1.25em;
  margin-bottom: 1.25em;
}

.legal-content strong {
  font-weight: 600;
  color: var(--text-strong);
}

.legal-content em {
  font-style: italic;
}

.legal-content ul,
.legal-content ol {
  margin-top: 1.25em;
  margin-bottom: 1.25em;
  padding-left: 1.625em;
}

.legal-content ul {
  list-style-type: disc;
}

.legal-content ol {
  list-style-type: decimal;
}

.legal-content li {
  margin-top: 0.5em;
  margin-bottom: 0.5em;
}

.legal-content li > p {
  margin-top: 0.75em;
  margin-bottom: 0.75em;
}

.legal-content ul > li::marker {
  color: var(--text-muted);
}

.legal-content ol > li::marker {
  color: var(--text-muted);
}

.legal-content ul ul,
.legal-content ul ol,
.legal-content ol ul,
.legal-content ol ol {
  margin-top: 0.75em;
  margin-bottom: 0.75em;
}

.legal-content blockquote {
  font-style: italic;
  border-left: 0.25rem solid var(--border);
  padding-left: 1em;
  margin-top: 1.6em;
  margin-bottom: 1.6em;
  color: var(--text-muted);
}

.legal-content code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.875em;
  background-color: var(--input-grey);
  padding: 0.2em 0.4em;
  border-radius: 0.25rem;
  color: var(--text-strong);
}

.legal-content pre {
  font-family: ui-monospace, SFMono-Regular, Menlo, Monaco, Consolas, monospace;
  font-size: 0.875em;
  line-height: 1.7142857;
  margin-top: 1.7142857em;
  margin-bottom: 1.7142857em;
  border-radius: 0.375rem;
  padding: 0.8571429em 1.1428571em;
  overflow-x: auto;
  background-color: var(--text-strong);
  color: var(--bg);
}

.legal-content pre code {
  background-color: transparent;
  border-width: 0;
  border-radius: 0;
  padding: 0;
  font-weight: inherit;
  color: inherit;
  font-size: inherit;
  font-family: inherit;
  line-height: inherit;
}

.legal-content a {
  color: var(--cta);
  text-decoration: underline;
  font-weight: 500;
}

.legal-content a:hover {
  color: var(--cta-hover);
}

.legal-content hr {
  border-color: var(--border);
  margin-top: 3em;
  margin-bottom: 3em;
}

.legal-content table {
  width: 100%;
  table-layout: auto;
  text-align: left;
  margin-top: 2em;
  margin-bottom: 2em;
  font-size: 0.875em;
  line-height: 1.7142857;
}

.legal-content thead {
  border-bottom-width: 1px;
  border-bottom-color: var(--border);
}

.legal-content thead th {
  font-weight: 600;
  vertical-align: bottom;
  padding-bottom: 0.5714286em;
  padding-left: 0.5714286em;
  padding-right: 0.5714286em;
  color: var(--text-strong);
}

.legal-content tbody tr {
  border-bottom-width: 1px;
  border-bottom-color: var(--border);
}

.legal-content tbody tr:last-child {
  border-bottom-width: 0;
}

.legal-content tbody td {
  vertical-align: baseline;
  padding: 0.5714286em;
}

/* Legal Document Metadata */
.legal-metadata {
  color: var(--text-muted);
  font-size: 0.9em;
  margin-bottom: 2em;
  padding-bottom: 1em;
  border-bottom: 1px solid var(--border);
}

.legal-draft-badge {
  color: #854d0e;
  font-weight: 700;
  background-color: #fef08a;
  padding: 0.25em 0.5em;
  border-radius: 0.25rem;
  font-size: 0.875em;
  display: inline-block;
  margin-left: 0.5em;
}
