/* Franconaut website styles. Plain CSS, no build step. */

@font-face {
  font-family: "Nunito";
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
  src: url("/fonts/nunito-latin.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  --navy-950: #070e1f;
  --navy-900: #0b1630;
  --navy-800: #13213f;
  --space: #213043;      /* background of the astronaut illustration */
  --ink: #1b263b;        /* app textPrimary */
  --ink-soft: #415a77;   /* app textSecondary */
  --mist: #f0f4f8;       /* app scaffoldBackground */
  --line: #dbe3ec;
  --fr-blue: #0055a4;
  --fr-red: #ef4135;
  --sky: #8cb8ff;
  --gold: #ffd166;
  --tricolor: linear-gradient(90deg, var(--fr-blue) 0 33.34%, #fff 33.34% 66.67%, var(--fr-red) 66.67%);
  --font: "Nunito", ui-rounded, -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --wrap: 1120px;
  --header-h: 60px;
  --shadow: 0 1px 2px rgba(16, 24, 40, .05), 0 16px 40px -20px rgba(16, 24, 40, .28);
}

/* ---------- Base ---------- */

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

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

body {
  margin: 0;
  font-family: var(--font);
  font-size: 1.0625rem;
  line-height: 1.6;
  color: var(--ink);
  background: var(--mist);
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

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

a {
  color: inherit;
}

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

::selection {
  background: rgba(0, 85, 164, .22);
}

.wrap {
  width: min(100% - 2.5rem, var(--wrap));
  margin-inline: auto;
}

/* Night sky: tiled CSS stars behind the content of dark panels. */
.starry {
  position: relative;
  isolation: isolate;
}

.starry::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    radial-gradient(circle at 6% 12%, rgba(255, 255, 255, .9) 0 1px, transparent 1.6px),
    radial-gradient(circle at 22% 68%, rgba(255, 255, 255, .7) 0 .8px, transparent 1.4px),
    radial-gradient(circle at 34% 28%, rgba(255, 255, 255, .85) 0 1.2px, transparent 1.8px),
    radial-gradient(circle at 47% 84%, rgba(255, 255, 255, .6) 0 .8px, transparent 1.4px),
    radial-gradient(circle at 58% 9%, rgba(255, 255, 255, .75) 0 1px, transparent 1.6px),
    radial-gradient(circle at 66% 52%, rgba(255, 209, 102, .95) 0 1.4px, transparent 2.2px),
    radial-gradient(circle at 78% 22%, rgba(255, 255, 255, .8) 0 .9px, transparent 1.5px),
    radial-gradient(circle at 88% 74%, rgba(255, 255, 255, .7) 0 1.1px, transparent 1.7px),
    radial-gradient(circle at 94% 40%, rgba(255, 255, 255, .6) 0 .8px, transparent 1.4px),
    radial-gradient(circle at 14% 92%, rgba(255, 255, 255, .8) 0 1px, transparent 1.6px),
    radial-gradient(circle at 40% 55%, rgba(255, 255, 255, .5) 0 .7px, transparent 1.2px),
    radial-gradient(circle at 72% 96%, rgba(255, 209, 102, .8) 0 1px, transparent 1.6px);
  background-size: 380px 380px;
  animation: twinkle 7s ease-in-out infinite alternate;
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  color: #fff;
  background: rgba(11, 22, 48, .88);
  -webkit-backdrop-filter: saturate(150%) blur(12px);
  backdrop-filter: saturate(150%) blur(12px);
  box-shadow: 0 1px 0 rgba(255, 255, 255, .07);
}

.site-header::before {
  content: "";
  display: block;
  height: 3px;
  background: var(--tricolor);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  height: var(--header-h);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: .65rem;
  text-decoration: none;
  font-weight: 900;
  font-size: 1rem;
  letter-spacing: .16em;
  text-transform: uppercase;
}

.brand img {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .2);
}

/* "Get the app": one link per platform, the inline script in <head> picks which one shows. */
.get-app {
  display: none;
  align-items: center;
  gap: .4rem;
  padding: .5rem 1rem;
  border-radius: 999px;
  background: #fff;
  color: var(--navy-900);
  font-size: .9rem;
  font-weight: 800;
  line-height: 1.2;
  text-decoration: none;
  white-space: nowrap;
  box-shadow: 0 6px 22px -8px rgba(140, 184, 255, .85);
  transition: transform .15s ease;
}

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

.get-app--other {
  display: inline-flex;
}

[data-platform="ios"] .get-app--other,
[data-platform="android"] .get-app--other {
  display: none;
}

[data-platform="ios"] .get-app--ios,
[data-platform="android"] .get-app--android {
  display: inline-flex;
}

/* ---------- Hero ---------- */

.hero {
  overflow: hidden;
  color: #fff;
  background:
    radial-gradient(80% 60% at 0% 0%, rgba(0, 85, 164, .55), transparent 65%),
    radial-gradient(60% 55% at 100% 10%, rgba(239, 65, 53, .28), transparent 65%),
    linear-gradient(180deg, var(--navy-900), var(--navy-800));
  padding-block: 1.25rem 4.25rem;
}

/* Planet horizon curving into the next section. */
.hero::after {
  content: "";
  position: absolute;
  left: -15%;
  right: -15%;
  bottom: -2px;
  height: 52px;
  background: var(--mist);
  border-radius: 50% 50% 0 0 / 100% 100% 0 0;
  box-shadow: 0 -12px 40px rgba(140, 184, 255, .35);
}

.hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: center;
  gap: 1rem;
  text-align: center;
}

.hero-art {
  position: relative;
  width: 92px;
  margin-block: 1rem .4rem;
}

.app-icon {
  display: block;
  width: 100%;
  height: auto;
  aspect-ratio: 1;
  border-radius: 23%;
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, .25),
    0 20px 40px -16px rgba(0, 0, 0, .75),
    0 0 50px -6px rgba(140, 184, 255, .55);
  animation: float 6s ease-in-out infinite;
}

.orbit {
  position: absolute;
  inset: -18%;
  border: 1.5px dashed rgba(255, 255, 255, .22);
  border-radius: 50%;
  animation: spin 40s linear infinite;
}

/* A little gold moon riding the orbit. */
.orbit::before {
  content: "";
  position: absolute;
  top: calc(14.6% - 4.5px);
  left: calc(14.6% - 4.5px);
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: var(--gold);
  box-shadow: 0 0 14px 3px rgba(255, 209, 102, .6);
}

.hero-copy {
  display: grid;
  justify-items: center;
  gap: 1rem;
}

.eyebrow {
  display: inline-flex;
  align-items: center;
  gap: .55rem;
  margin: 0;
  padding: .32rem .85rem .32rem .45rem;
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 999px;
  background: rgba(255, 255, 255, .08);
  color: rgba(255, 255, 255, .9);
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
}

.flag {
  width: 21px;
  height: 14px;
  border-radius: 3px;
  background: var(--tricolor);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .3);
}

.hero h1 {
  margin: 0;
  font-size: clamp(2rem, 1.2rem + 3.8vw, 4.1rem);
  line-height: 1.05;
  font-weight: 900;
  letter-spacing: -.025em;
  text-wrap: balance;
}

/* Tricolour underline under "French". */
.fr {
  position: relative;
  display: inline-block;
}

.fr::after {
  content: "";
  position: absolute;
  left: .04em;
  right: .04em;
  bottom: -.04em;
  height: .12em;
  border-radius: 99px;
  background: var(--tricolor);
}

.lead {
  margin: 0;
  max-width: 33rem;
  font-size: clamp(1.02rem, .95rem + .45vw, 1.3rem);
  line-height: 1.5;
  color: rgba(255, 255, 255, .8);
}

.badges {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: .75rem;
  margin-top: .35rem;
}

.badge {
  display: block;
  border-radius: 10px;
  transition: transform .15s ease;
}

.badge:hover {
  transform: translateY(-2px);
}

.badge img {
  width: auto;
  height: 46px;
}

/* Android visitors see Google Play first. */
[data-platform="android"] .badge--play {
  order: -1;
}

.hero-facts {
  margin: .15rem 0 0;
  font-size: .92rem;
  font-weight: 700;
  color: rgba(255, 255, 255, .66);
}

.hero-facts span {
  margin-inline: .4rem;
  color: rgba(255, 255, 255, .35);
}

/* ---------- Sections ---------- */

.section {
  padding-block: clamp(3.5rem, 2rem + 5vw, 5.5rem);
  scroll-margin-top: calc(var(--header-h) + 3px);
}

.section + .section {
  padding-top: 0;
}

.section-head {
  max-width: 40rem;
  margin: 0 auto clamp(2rem, 1.5rem + 2vw, 3rem);
  text-align: center;
}

.section-head h2,
.cta h2 {
  margin: 0 0 .6rem;
  font-size: clamp(1.85rem, 1.3rem + 2.4vw, 2.9rem);
  line-height: 1.1;
  font-weight: 900;
  letter-spacing: -.02em;
}

.section-head p {
  margin: 0;
  font-size: 1.08rem;
  color: var(--ink-soft);
}

.section-head .section-lead {
  margin-bottom: .9rem;
  font-size: clamp(1.12rem, 1rem + .5vw, 1.35rem);
  font-weight: 800;
  color: var(--fr-blue);
}

.stats {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: .75rem;
  max-width: 44rem;
  margin: 0 auto;
  padding: 0;
  list-style: none;
}

.stat {
  padding: 1.1rem .5rem 1rem;
  text-align: center;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 20px;
  box-shadow: var(--shadow);
}

.stat strong {
  display: block;
  font-size: clamp(1.55rem, 1.1rem + 2.4vw, 2.6rem);
  line-height: 1.1;
  font-weight: 900;
  letter-spacing: -.02em;
  color: var(--fr-blue);
}

.stat:nth-child(2) strong {
  color: var(--fr-red);
}

.stat:nth-child(3) strong {
  color: var(--ink);
}

.stat span {
  font-size: .92rem;
  font-weight: 700;
  color: var(--ink-soft);
}

/* ---------- Feature cards ---------- */

.features {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 290px), 1fr));
}

.card {
  display: flex;
  flex-direction: column;
  overflow: hidden;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 24px;
  box-shadow: var(--shadow);
}

.card-media {
  position: relative;
  aspect-ratio: 2 / 1;
  background: #f7efe3;
}

/* Absolutely positioned so every card's art box keeps the same 2:1 shape. */
.card-media img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* The progress art is shown whole, on its own background colour. */
.card-media--progress {
  background: #6187a1;
}

.card-media--progress img {
  object-fit: contain;
}

.card-body {
  padding: 1.35rem 1.5rem 1.6rem;
}

.card h3 {
  margin: 0 0 .35rem;
  font-size: 1.3rem;
  font-weight: 900;
  letter-spacing: -.01em;
}

.card p {
  margin: 0;
  color: var(--ink-soft);
}

/* ---------- Download panel ---------- */

.cta {
  display: grid;
  overflow: hidden;
  color: #fff;
  background: var(--space);
  border-radius: 32px;
  box-shadow: 0 30px 60px -30px rgba(11, 22, 48, .6);
}

.cta-copy {
  position: relative;
  z-index: 1;
  display: grid;
  justify-items: center;
  gap: .9rem;
  padding: 2.75rem 1.5rem 0;
  text-align: center;
}

.cta-copy h2 {
  margin: 0;
}

.cta-copy p {
  margin: 0;
  font-size: 1.1rem;
  color: rgba(255, 255, 255, .78);
}

.cta-art {
  width: 100%;
  margin-top: -8%;
}

/* ---------- Footer ---------- */

.site-footer {
  padding-block: 3rem 2rem;
  font-size: .95rem;
  color: rgba(255, 255, 255, .68);
  background: var(--navy-950);
}

.site-footer a {
  color: #fff;
  text-decoration: none;
}

.site-footer a:hover {
  text-decoration: underline;
  text-underline-offset: 3px;
}

.footer-grid {
  display: grid;
  gap: 2rem;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 200px), 1fr));
}

.footer-company {
  margin: .85rem 0 0;
}

.footer-title {
  margin: 0 0 .55rem;
  font-size: .8rem;
  font-weight: 800;
  letter-spacing: .14em;
  text-transform: uppercase;
  color: #fff;
}

.footer-links {
  display: grid;
  gap: .4rem;
  margin: 0;
  padding: 0;
  list-style: none;
}

.footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: .5rem 1.5rem;
  margin-top: 2.25rem;
  padding-top: 1.25rem;
  border-top: 1px solid rgba(255, 255, 255, .1);
  font-size: .85rem;
  color: rgba(255, 255, 255, .5);
}

.footer-bottom p {
  margin: 0;
}

/* Website version, bumped by deploy.sh on every live deploy. */
.site-version {
  font-variant-numeric: tabular-nums;
}

/* ---------- Legal documents ---------- */

.doc-page {
  padding-block: clamp(1.5rem, 4vw, 3.5rem) clamp(3rem, 6vw, 5rem);
}

.doc {
  max-width: 760px;
  margin-inline: auto;
  padding: clamp(1.5rem, 1rem + 3vw, 3.25rem);
  line-height: 1.7;
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 28px;
  box-shadow: var(--shadow);
  overflow-wrap: break-word;
}

.doc h1 {
  margin: 0 0 .6rem;
  font-size: clamp(2rem, 1.5rem + 2vw, 2.75rem);
  line-height: 1.15;
  font-weight: 900;
  letter-spacing: -.02em;
}

.doc h2 {
  margin: 2.25rem 0 .6rem;
  font-size: 1.35rem;
  line-height: 1.3;
  font-weight: 900;
}

.doc h3 {
  margin: 1.5rem 0 .4rem;
  font-size: 1.1rem;
  font-weight: 800;
}

.doc p,
.doc ul {
  margin: 0 0 1rem;
  color: #2d3a50;
}

.doc ul {
  padding-left: 1.25rem;
}

.doc li {
  margin-bottom: .5rem;
}

.doc li::marker {
  color: var(--fr-blue);
}

.doc a {
  color: var(--fr-blue);
  text-underline-offset: 2px;
}

.doc .effective-date {
  display: inline-block;
  padding: .25rem .8rem;
  border-radius: 999px;
  background: var(--mist);
  font-size: .9rem;
  font-weight: 700;
  color: var(--ink-soft);
}

.doc .contact {
  margin-top: 2.25rem;
  padding: 1.25rem 1.5rem;
  background: var(--mist);
  border: 1px solid var(--line);
  border-radius: 18px;
}

.doc .contact h2 {
  margin-top: 0;
}

.doc .contact p:last-child {
  margin-bottom: 0;
}

/* ---------- 404 ---------- */

.lost {
  padding-block: clamp(4rem, 3rem + 8vw, 8rem);
  text-align: center;
  color: #fff;
  background:
    radial-gradient(80% 60% at 0% 0%, rgba(0, 85, 164, .5), transparent 65%),
    radial-gradient(60% 55% at 100% 10%, rgba(239, 65, 53, .25), transparent 65%),
    linear-gradient(180deg, var(--navy-900), var(--navy-800));
}

.lost .app-icon {
  width: 96px;
  margin: 0 auto 1.5rem;
}

.lost h1 {
  margin: 0 0 .5rem;
  font-size: clamp(2.2rem, 1.6rem + 3vw, 3.5rem);
  line-height: 1.1;
  font-weight: 900;
  letter-spacing: -.02em;
}

.lost p {
  margin: 0 auto 1.75rem;
  max-width: 28rem;
  color: rgba(255, 255, 255, .78);
}

.button {
  display: inline-flex;
  padding: .8rem 1.5rem;
  border-radius: 999px;
  background: #fff;
  color: var(--navy-900);
  font-weight: 800;
  text-decoration: none;
}

/* ---------- App link (/app, /app-ios) ---------- */

/* The 404's starry panel, filling the screen. It shows only when the jump to a store didn't happen,
   or after coming back from the store. */
.app-link {
  display: grid;
  align-content: center;
  min-height: 100vh;
  min-height: 100dvh;
  padding-block: 2.5rem;
}

.app-link .app-icon {
  width: 84px;
  margin-bottom: 1.25rem;
}

.app-link h1 {
  font-size: clamp(1.9rem, 1.3rem + 3vw, 3rem);
  text-wrap: balance;
}

.app-link .badges {
  margin-top: 0;
}

/* Phones see only their own store; unknown devices (or no JavaScript) see both. */
[data-platform="ios"] .app-link .badge--play,
[data-platform="android"] .app-link .badge--apple {
  display: none;
}

.app-link .help {
  margin: 1.25rem auto;
  max-width: 22rem;
  font-size: .9rem;
  color: rgba(255, 255, 255, .7);
}

.app-link .site-link {
  display: inline-block;
  margin-top: 1.5rem;
  font-size: .95rem;
  font-weight: 700;
  color: rgba(255, 255, 255, .85);
}

/* Short in-app browser windows (Instagram's can be ~360x512): everything still fits without scrolling. */
@media (max-height: 560px) {
  .app-link {
    padding-block: 1.1rem;
  }

  .app-link .app-icon {
    width: 64px;
    margin-bottom: .9rem;
  }
}

/* ---------- Small phones ---------- */

@media (max-width: 400px) {
  .header-inner {
    gap: .5rem;
  }

  .brand {
    gap: .5rem;
    font-size: .9rem;
    letter-spacing: .1em;
  }

  .brand img {
    width: 30px;
    height: 30px;
    border-radius: 9px;
  }

  .get-app {
    padding: .45rem .8rem;
    font-size: .85rem;
  }

  .cta-copy {
    padding-inline: 1.25rem;
  }

  .cta .badges {
    gap: .6rem;
  }

  .cta .badge img {
    height: 44px;
  }
}

/* Very narrow screens: icon-only brand, smaller art and badges so both stay on one row above the fold. */
@media (max-width: 340px) {
  .site-header .brand span {
    display: none;
  }

  .hero-art {
    width: 76px;
    margin-block: .75rem .25rem;
  }

  .badges {
    gap: .5rem;
  }

  .badge img {
    height: 40px;
  }
}

/* ---------- Larger screens ---------- */

@media (min-width: 900px) {
  .hero {
    padding-block: 4.5rem 7rem;
  }

  .hero::after {
    height: 90px;
  }

  .hero-inner {
    grid-template-columns: 1.15fr .85fr;
    grid-template-areas: "copy art";
    align-items: center;
    justify-items: start;
    gap: 3rem;
    text-align: left;
  }

  .hero-copy {
    grid-area: copy;
    justify-items: start;
    gap: 1.25rem;
  }

  .hero-art {
    grid-area: art;
    justify-self: center;
    width: min(300px, 100%);
    margin: 0;
  }

  .badges {
    justify-content: flex-start;
  }

  .badge img {
    height: 54px;
  }

  .cta {
    grid-template-columns: 1fr 1fr;
    align-items: center;
  }

  .cta-copy {
    justify-items: start;
    padding: 3.5rem 0 3.5rem 3.5rem;
    text-align: left;
  }

  /* Anchor the art bottom-right and fade its left edge into the panel. */
  .cta-art {
    align-self: end;
    justify-self: end;
    max-width: 480px;
    margin: 0;
    -webkit-mask-image: linear-gradient(90deg, transparent, #000 25%);
    mask-image: linear-gradient(90deg, transparent, #000 25%);
  }
}

/* ---------- Motion ---------- */

@keyframes float {
  50% {
    transform: translateY(-8px);
  }
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

@keyframes twinkle {
  from {
    opacity: .55;
  }

  to {
    opacity: 1;
  }
}

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

  *,
  *::before,
  *::after {
    animation: none !important;
    transition: none !important;
  }
}
