/* FitCheck AI — marketing site */
:root {
  --teal-deep: #103c3f;
  --teal-dark: #0c292d;
  --near-black: #0e1117;
  --olive-black: #151d12;
  --teal-bright: #12878c;
  --teal-mid: #0f5c61;
  --off-white: #f8f4ec;
  --muted: #9ca8aa;
  --white: #ffffff;
  --text: #1a2224;
  --text-soft: #4a585b;
  --border: rgba(16, 60, 63, 0.12);
  --focus: #12878c;
  --shadow-soft: 0 12px 40px rgba(14, 17, 23, 0.12);
  --shadow-device: 0 28px 60px rgba(14, 17, 23, 0.28);
  --radius-sm: 10px;
  --radius-md: 16px;
  --radius-lg: 24px;
  --radius-pill: 999px;
  --space-1: 0.25rem;
  --space-2: 0.5rem;
  --space-3: 0.75rem;
  --space-4: 1rem;
  --space-5: 1.25rem;
  --space-6: 1.5rem;
  --space-7: 2rem;
  --space-8: 2.5rem;
  --font-display: "Iowan Old Style", "Palatino Linotype", Palatino, "Book Antiqua", Georgia, "Times New Roman", serif;
  --font-sans: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  --text-xs: clamp(0.72rem, 0.68rem + 0.15vw, 0.8125rem);
  --text-sm: clamp(0.8125rem, 0.78rem + 0.2vw, 0.9375rem);
  --text-base: clamp(0.9375rem, 0.9rem + 0.25vw, 1.0625rem);
  --text-lg: clamp(1.05rem, 1rem + 0.35vw, 1.25rem);
  --text-xl: clamp(1.35rem, 1.15rem + 0.9vw, 2rem);
  --text-2xl: clamp(1.75rem, 1.4rem + 1.4vw, 2.75rem);
  --page-pad: clamp(1rem, 2.5vw, 2.5rem);
  --max: 1120px;
  --phone-w: clamp(168px, 18vw, 236px);
  --screen-ratio: 1206 / 2622;
}

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

html {
  scroll-behavior: smooth;
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
  }
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--font-sans);
  font-size: var(--text-base);
  line-height: 1.55;
  color: var(--text);
  background:
    radial-gradient(120% 80% at 100% 0%, rgba(18, 135, 140, 0.08), transparent 55%),
    radial-gradient(90% 60% at 0% 100%, rgba(16, 60, 63, 0.06), transparent 50%),
    linear-gradient(165deg, var(--off-white) 0%, #f3eee4 48%, #eef2f0 100%);
  -webkit-font-smoothing: antialiased;
}

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

a {
  color: var(--teal-bright);
  text-decoration-thickness: 1px;
  text-underline-offset: 0.15em;
}

a:hover {
  color: var(--teal-deep);
}

:focus-visible {
  outline: 3px solid var(--focus);
  outline-offset: 3px;
}

.skip-link {
  position: absolute;
  left: var(--space-4);
  top: -100px;
  z-index: 1000;
  padding: var(--space-3) var(--space-4);
  background: var(--near-black);
  color: var(--white);
  border-radius: var(--radius-sm);
  font-weight: 600;
  text-decoration: none;
}

.skip-link:focus {
  top: var(--space-4);
}

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-4);
  max-width: var(--max);
  margin: 0 auto;
  padding: var(--space-4) var(--page-pad) var(--space-2);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  color: inherit;
  text-decoration: none;
  min-height: 44px;
}

.brand__logo {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  box-shadow: 0 4px 14px rgba(14, 17, 23, 0.15);
  object-fit: contain;
  background: var(--near-black);
}

.brand__name {
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--teal-deep);
}

.header-nav {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2) var(--space-4);
  font-size: var(--text-sm);
}

.header-nav a {
  color: var(--text-soft);
  text-decoration: none;
  font-weight: 500;
  min-height: 44px;
  display: inline-flex;
  align-items: center;
}

.header-nav a:hover {
  color: var(--teal-deep);
}

/* —— Homepage —— */
.page-home {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.page-home .site-header {
  padding-bottom: 0;
}

.hero {
  flex: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  gap: clamp(1.25rem, 3vw, 3rem);
  align-items: center;
  max-width: var(--max);
  width: 100%;
  margin: 0 auto;
  padding: clamp(0.5rem, 1.5vh, 1.25rem) var(--page-pad) clamp(0.75rem, 1.5vh, 1.25rem);
}

.hero__copy {
  min-width: 0;
}

.eyebrow {
  margin: 0 0 var(--space-3);
  font-size: var(--text-xs);
  font-weight: 650;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--teal-bright);
}

.hero h1 {
  margin: 0 0 var(--space-4);
  font-family: var(--font-display);
  font-size: var(--text-2xl);
  font-weight: 600;
  line-height: 1.12;
  letter-spacing: -0.025em;
  color: var(--near-black);
  max-width: 16ch;
}

.hero__lede {
  margin: 0 0 var(--space-3);
  max-width: 38rem;
  color: var(--text-soft);
  font-size: var(--text-sm);
  line-height: 1.55;
}

.hero__tag {
  margin: 0 0 var(--space-5);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--teal-deep);
}

.cta-row {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-3);
  margin-bottom: var(--space-5);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0.7rem 1.35rem;
  border-radius: var(--radius-pill);
  font-size: var(--text-sm);
  font-weight: 650;
  text-decoration: none;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform 0.15s ease, box-shadow 0.15s ease, background 0.15s ease;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn--primary {
  background: linear-gradient(145deg, var(--teal-bright), var(--teal-mid));
  color: var(--white);
  box-shadow: 0 8px 22px rgba(18, 135, 140, 0.35);
}

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

.btn--secondary {
  background: var(--white);
  color: var(--teal-deep);
  border-color: rgba(16, 60, 63, 0.18);
  box-shadow: 0 4px 14px rgba(14, 17, 23, 0.06);
}

.btn--secondary:hover {
  color: var(--teal-deep);
  border-color: var(--teal-bright);
}

.features {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: var(--space-3);
  margin: 0 0 var(--space-5);
  padding: 0;
  list-style: none;
}

.feature {
  padding: var(--space-3) var(--space-3);
  background: rgba(255, 255, 255, 0.72);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  box-shadow: 0 6px 18px rgba(14, 17, 23, 0.04);
}

.feature h2 {
  margin: 0 0 var(--space-1);
  font-size: var(--text-xs);
  font-weight: 700;
  letter-spacing: 0.01em;
  color: var(--teal-deep);
  font-family: var(--font-sans);
}

.feature p {
  margin: 0;
  font-size: var(--text-xs);
  line-height: 1.45;
  color: var(--text-soft);
}

.download-block {
  scroll-margin-top: 1rem;
}

.download-block h2 {
  margin: 0 0 var(--space-2);
  font-family: var(--font-display);
  font-size: var(--text-lg);
  font-weight: 600;
  color: var(--near-black);
}

.download-block > p {
  margin: 0 0 var(--space-3);
  font-size: var(--text-sm);
  color: var(--text-soft);
  max-width: 36rem;
}

.store-badges {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: var(--space-3);
}

.store-badges a {
  display: inline-flex;
  border-radius: 8px;
  transition: opacity 0.15s ease, transform 0.15s ease;
}

.store-badges a:hover {
  opacity: 0.9;
  transform: translateY(-1px);
}

.store-badges img {
  height: clamp(40px, 5.2vh, 48px);
  width: auto;
  object-fit: contain;
}

/* Phone mockup */
.hero__device {
  display: flex;
  justify-content: center;
  align-items: center;
  min-width: 0;
  scroll-margin-top: 1rem;
}

.phone {
  --bezel: 10px;
  width: var(--phone-w);
  max-width: 100%;
  border-radius: 2.15rem;
  padding: var(--bezel);
  background:
    linear-gradient(145deg, #3a3d42 0%, #1a1c1f 28%, #0a0b0d 70%, #2c2f34 100%);
  box-shadow:
    var(--shadow-device),
    inset 0 1px 1px rgba(255, 255, 255, 0.22),
    inset 0 -1px 1px rgba(0, 0, 0, 0.45);
  position: relative;
}

.phone::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  pointer-events: none;
  box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.12);
}

.phone__screen {
  position: relative;
  border-radius: calc(2.15rem - 6px);
  overflow: hidden;
  background: var(--near-black);
  aspect-ratio: var(--screen-ratio);
  isolation: isolate;
}

.phone__island {
  position: absolute;
  z-index: 2;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  width: 34%;
  height: 18px;
  background: #000;
  border-radius: 999px;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, 0.06);
}

.phone__screenshot {
  width: 100%;
  height: 100%;
  object-fit: contain;
  object-position: center top;
  background: #0e1117;
}

.site-footer {
  max-width: var(--max);
  margin: 0 auto;
  padding: var(--space-3) var(--page-pad) var(--space-5);
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: var(--space-3);
  border-top: 1px solid var(--border);
  font-size: var(--text-xs);
  color: var(--text-soft);
}

.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-2) var(--space-4);
}

.footer-nav a {
  color: var(--text-soft);
  text-decoration: none;
  font-weight: 500;
  min-height: 40px;
  display: inline-flex;
  align-items: center;
}

.footer-nav a:hover {
  color: var(--teal-deep);
}

.site-footer__copy {
  margin: 0;
}

/* —— Legal / support pages —— */
.page-legal {
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.legal-main {
  flex: 1;
  width: 100%;
  max-width: 42rem;
  margin: 0 auto;
  padding: var(--space-6) var(--page-pad) var(--space-8);
}

.legal-main h1 {
  margin: 0 0 var(--space-3);
  font-family: var(--font-display);
  font-size: var(--text-xl);
  font-weight: 600;
  letter-spacing: -0.02em;
  color: var(--near-black);
  line-height: 1.2;
}

.legal-meta {
  margin: 0 0 var(--space-6);
  font-size: var(--text-sm);
  color: var(--muted);
}

.owner-note {
  margin: 0 0 var(--space-6);
  padding: var(--space-4);
  background: rgba(18, 135, 140, 0.08);
  border: 1px solid rgba(18, 135, 140, 0.25);
  border-left: 4px solid var(--teal-bright);
  border-radius: var(--radius-sm);
  font-size: var(--text-sm);
  color: var(--teal-deep);
}

.legal-main h2 {
  margin: var(--space-7) 0 var(--space-3);
  font-size: var(--text-lg);
  font-family: var(--font-display);
  font-weight: 600;
  color: var(--teal-deep);
}

.legal-main h3 {
  margin: var(--space-5) 0 var(--space-2);
  font-size: var(--text-base);
  font-weight: 700;
  color: var(--near-black);
}

.legal-main p,
.legal-main li {
  color: var(--text-soft);
  font-size: var(--text-sm);
}

.legal-main ul {
  padding-left: 1.25rem;
  margin: 0 0 var(--space-4);
}

.legal-main li + li {
  margin-top: var(--space-2);
}

.legal-main p {
  margin: 0 0 var(--space-4);
}

.support-list {
  list-style: none;
  padding: 0;
  margin: 0 0 var(--space-6);
}

.support-list li {
  margin: 0 0 var(--space-3);
  padding: var(--space-4);
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
}

.support-list h2 {
  margin: 0 0 var(--space-2);
  font-size: var(--text-base);
  font-family: var(--font-sans);
}

.support-list p {
  margin: 0;
}

.contact-cta {
  margin-top: var(--space-6);
  padding: var(--space-5);
  background: linear-gradient(145deg, var(--teal-dark), var(--near-black));
  color: var(--off-white);
  border-radius: var(--radius-lg);
  text-align: center;
}

.contact-cta p {
  color: rgba(248, 244, 236, 0.85);
  margin-bottom: var(--space-4);
}

.contact-cta .btn--primary {
  background: var(--white);
  color: var(--teal-deep);
  box-shadow: none;
}

.contact-cta .btn--primary:hover {
  color: var(--teal-deep);
}

.back-home {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  margin-bottom: var(--space-5);
  font-size: var(--text-sm);
  font-weight: 600;
  color: var(--teal-deep);
  text-decoration: none;
  min-height: 44px;
}

.back-home:hover {
  color: var(--teal-bright);
}

/* —— Responsive —— */
@media (max-width: 1024px) {
  .hero {
    grid-template-columns: 1fr 0.9fr;
    gap: var(--space-5);
  }

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

  .feature {
    display: grid;
    grid-template-columns: auto 1fr;
    gap: var(--space-2) var(--space-3);
    align-items: baseline;
  }

  .feature h2 {
    margin: 0;
  }
}

@media (max-width: 860px) {
  .hero {
    grid-template-columns: 1fr;
    text-align: center;
    padding-top: var(--space-4);
  }

  .hero h1 {
    max-width: none;
    margin-left: auto;
    margin-right: auto;
  }

  .hero__lede,
  .hero__tag,
  .download-block > p {
    margin-left: auto;
    margin-right: auto;
  }

  .cta-row {
    justify-content: center;
  }

  .cta-row .btn {
    flex: 1 1 100%;
    max-width: 22rem;
  }

  .features {
    text-align: left;
  }

  .store-badges {
    justify-content: center;
  }

  .hero__device {
    order: -1;
    margin-bottom: var(--space-2);
  }

  .phone {
    --phone-w: clamp(150px, 42vw, 200px);
    width: var(--phone-w);
  }

  .site-header {
    flex-direction: column;
    align-items: center;
  }

  .site-footer {
    flex-direction: column;
    text-align: center;
    justify-content: center;
  }

  .footer-nav {
    justify-content: center;
  }
}

@media (max-width: 480px) {
  .header-nav {
    justify-content: center;
  }

  .brand__name {
    font-size: 1.1rem;
  }
}

/* Tall desktop: keep homepage compact within one viewport when practical */
@media (min-width: 1100px) and (min-height: 820px) {
  .page-home {
    min-height: 100vh;
  }

  .hero {
    padding-top: 0.35rem;
    padding-bottom: 0.5rem;
  }

  .hero h1 {
    font-size: clamp(1.85rem, 1.5rem + 1.1vw, 2.55rem);
  }

  .features {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .feature {
    display: block;
  }

  .phone {
    width: clamp(168px, 17vw, 220px);
  }
}

@media (min-width: 1100px) and (max-height: 819px) {
  .page-home {
    height: auto;
    overflow: visible;
  }

  .phone {
    width: clamp(150px, 16vw, 200px);
  }
}
