/* Shared styles for Fstop's public pages (/brand, /ethos). Brand tokens: docs/brand.md.
   Dark by default; follows the browser's light setting. Fonts are self-hosted (no Google calls). */
@font-face { font-family: 'Figtree'; font-weight: 300 900; font-display: swap; src: url('/site/fonts/figtree-latin-wght-normal.woff2') format('woff2-variations');
  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; }
@font-face { font-family: 'Figtree'; font-weight: 300 900; font-display: swap; src: url('/site/fonts/figtree-latin-ext-wght-normal.woff2') format('woff2-variations');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Space Grotesk'; font-weight: 300 700; font-display: swap; src: url('/site/fonts/space-grotesk-latin-wght-normal.woff2') format('woff2-variations');
  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; }
@font-face { font-family: 'Space Grotesk'; font-weight: 300 700; font-display: swap; src: url('/site/fonts/space-grotesk-latin-ext-wght-normal.woff2') format('woff2-variations');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF; }
@font-face { font-family: 'Bricolage Grotesque'; font-weight: 200 800; font-display: swap; src: url('/site/fonts/bricolage-grotesque-latin-wght-normal.woff2') format('woff2-variations'); }
@font-face { font-family: 'Atkinson Hyperlegible Next'; font-weight: 200 800; font-display: swap; src: url('/site/fonts/atkinson-hyperlegible-next-latin-wght-normal.woff2') format('woff2-variations'); }
@font-face { font-family: 'Sora'; font-weight: 100 800; font-display: swap; src: url('/site/fonts/sora-latin-wght-normal.woff2') format('woff2-variations'); }
@font-face { font-family: 'Manrope'; font-weight: 200 800; font-display: swap; src: url('/site/fonts/manrope-latin-wght-normal.woff2') format('woff2-variations'); }

:root {
  color-scheme: dark;
  --canvas: #101212; --surface: #191c1c; --line: #2b3030; --line-strong: #6e7676;
  --ink: #eaefee; --ink-muted: #a0aaa8; --primary: #3dd6c0; --primary-hover: #66e0ce; --on-primary: #052620;
  --link: #5fddcb; --accent: #ff8fb8;
  --heading: 'Figtree', system-ui, sans-serif; --body: 'Figtree', system-ui, sans-serif;
}
/* Light: chosen (data-mode="light"), or Auto (no data-mode) on a device set to light. The switch
   in the top bar of each page (site/mode.js) sets data-mode; Dark is data-mode="dark". */
@media (prefers-color-scheme: light) {
  :root:not([data-mode="dark"]) {
    color-scheme: light;
    --canvas: #f3f6f5; --surface: #ffffff; --line: #dce3e1; --line-strong: #7a8583;
    --ink: #141917; --ink-muted: #505c59; --primary: #0b6e62; --primary-hover: #08584e; --on-primary: #ffffff;
    --link: #0a6559; --accent: #b0306a;
  }
  :root:not([data-mode="dark"]) .logo-dark { display: none !important; }
  :root[data-mode="dark"] .logo-light { display: none !important; }
}
@media (prefers-color-scheme: dark) {
  :root:not([data-mode="light"]) .logo-light { display: none !important; }
  :root[data-mode="light"] .logo-dark { display: none !important; }
}
:root[data-mode="light"] {
  color-scheme: light;
  --canvas: #f3f6f5; --surface: #ffffff; --line: #dce3e1; --line-strong: #7a8583;
  --ink: #141917; --ink-muted: #505c59; --primary: #0b6e62; --primary-hover: #08584e; --on-primary: #ffffff;
  --link: #0a6559; --accent: #b0306a;
}
.mode-switch { display: flex; flex: none; padding: 2px; border: 1px solid var(--line-strong); border-radius: 999px; }
.mode-switch button { display: flex; align-items: center; justify-content: center; width: 34px; height: 34px; padding: 0; border: 0; border-radius: 999px; background: transparent; color: var(--ink-muted); font: 700 .8rem/1 var(--body); cursor: pointer; }
.mode-switch button:hover { color: var(--ink); }
.mode-switch button[aria-pressed="true"] { background: var(--primary); color: var(--on-primary); }

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body { margin: 0; background: var(--canvas); color: var(--ink); font: 18px/1.6 var(--body); }
main { max-width: 46rem; margin: 0 auto; padding: 2rem 1rem 4rem; }
main.wide { max-width: 68rem; }
h1, h2, h3 { font-family: var(--heading); font-weight: 800; letter-spacing: -.02em; line-height: 1.15; text-wrap: balance; }
h1 { font-size: clamp(2rem, 6vw, 2.9rem); margin: 0 0 .75rem; letter-spacing: -0.02em; }
h2 { font-size: 1.55rem; margin: 3rem 0 .5rem; }
h3 { font-size: 1.15rem; margin: 1.5rem 0 .3rem; }
p { margin: .6rem 0; }
.lead { font-size: 1.2rem; }
.muted { color: var(--ink-muted); }
a { color: var(--link); text-underline-offset: 3px; }
a:hover { color: var(--primary-hover); }
:focus-visible { outline: 3px solid var(--primary); outline-offset: 2px; border-radius: 4px; }

.topbar { display: flex; align-items: center; justify-content: space-between; gap: 1rem; max-width: 68rem; margin: 0 auto; padding: 1rem; }
.topbar img { height: 34px; width: auto; display: block; }
/* A long menu wraps onto a second line (right-aligned) rather than running off the side. */
.topbar nav { display: flex; flex-wrap: wrap; justify-content: flex-end; column-gap: 1.25rem; row-gap: .1rem; font-weight: 600; margin-left: auto; min-width: 0; }
.topbar nav a { color: var(--ink-muted); text-decoration: none; padding: .4rem 0; }
.topbar nav a[aria-current='page'] { color: var(--ink); border-bottom: 3px solid var(--primary); }
.topbar nav a { white-space: nowrap; }
/* Log in: the app's sign-in, last in the menu on every Fstop page. */
.topbar nav a.nav-login { display: inline-flex; align-items: center; align-self: center; height: 2.4rem; background: var(--primary); color: var(--on-primary); border: 2px solid var(--primary); border-radius: 999px; padding: 0 1rem; line-height: 1; }
.topbar nav a.nav-login:hover { background: transparent; color: var(--primary); }
/* Phones: the links go under the logo, each on one line, wrapping onto a second row so none is hidden. */
@media (max-width: 640px) {
  .topbar { flex-wrap: wrap; row-gap: .5rem; padding-bottom: .5rem; }
  .mode-switch { order: 1; }
  .topbar nav { order: 2; margin-left: 0; width: 100%; flex-wrap: wrap; column-gap: 1.1rem; row-gap: .1rem; font-size: 1rem; }
}
footer { border-top: 1px solid var(--line); color: var(--ink-muted); font-size: .95rem; text-align: center; padding: 1.5rem 1rem 2.5rem; }

.card { background: var(--surface); border: 1px solid var(--line); border-radius: 14px; padding: 1.25rem; }
.grid { display: grid; gap: 1rem; grid-template-columns: repeat(auto-fit, minmax(min(100%, 16rem), 1fr)); }
.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 48px; padding: .5rem 1.1rem; border-radius: 10px; font-weight: 600; text-decoration: none; border: 1px solid transparent; }
.btn-primary { background: var(--primary); color: var(--on-primary); }
.btn-primary:hover { background: var(--primary-hover); color: var(--on-primary); }
.btn-secondary { background: var(--surface); color: var(--ink); border-color: var(--line-strong); }
.sign { margin-top: 3rem; font: 700 1.5rem/1.3 var(--heading); }
.sign span { color: var(--primary); }

/* The top-bar logo (inline, from site/mode.js): letters in ink, the aperture in the primary colour.
   Hovering the logo (or focusing the link) lights the rings outside to inside, over and over. */
.logo-anim { display: block; height: 40px; width: auto; color: var(--ink); overflow: visible; }
.logo-anim .ap { color: var(--primary); }
@keyframes fstop-ring { 0% { opacity: .3; } 22% { opacity: 1; } 60%, 100% { opacity: .3; } }
.topbar > a:hover .logo-anim .r, .topbar > a:focus-visible .logo-anim .r { animation: fstop-ring 1.05s cubic-bezier(.45, 0, .55, 1) infinite backwards; }
.topbar > a:hover .logo-anim .r2, .topbar > a:focus-visible .logo-anim .r2 { animation-delay: .23s; }
.topbar > a:hover .logo-anim .r3, .topbar > a:focus-visible .logo-anim .r3 { animation-delay: .47s; }
@media (prefers-reduced-motion: reduce) { .logo-anim .r { animation: none !important; } }

/* Videos: the drop-down in the top menu and the player (site/videos.js). */
.nav-videos { position: relative; }
.nav-videos > summary { list-style: none; cursor: pointer; color: var(--ink-muted); padding: .4rem 0; white-space: nowrap; }
.nav-videos > summary::-webkit-details-marker { display: none; }
.nav-videos > summary::after { content: ""; display: inline-block; width: .38em; height: .38em; margin: 0 .15em .2em .45em; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(45deg); transition: transform .2s; }
.nav-videos[open] > summary { color: var(--ink); }
.nav-videos[open] > summary::after { transform: translateY(.2em) rotate(-135deg); }
.nav-videos-list { position: absolute; z-index: 50; top: calc(100% + .35rem); left: 0; min-width: 17rem; display: grid; padding: .4rem; background: var(--surface); border: 1px solid var(--line-strong); border-radius: 12px; box-shadow: 0 18px 40px rgba(0,0,0,.28); }
.topbar nav .nav-videos-list a { display: flex; align-items: center; padding: .55rem .6rem; border-radius: 8px; color: var(--ink); }
.topbar nav .nav-videos-list a:hover { background: var(--canvas); }
.nav-videos-list small { margin-left: auto; padding-left: 1rem; color: var(--ink-muted); font-weight: 500; }
.nav-videos-sub > summary { list-style: none; cursor: pointer; display: flex; align-items: center; padding: .6rem; border-radius: 8px; font-weight: 800; font-size: .8rem; letter-spacing: .08em; text-transform: uppercase; color: var(--ink); }
.nav-videos-sub > summary::-webkit-details-marker { display: none; }
.nav-videos-sub > summary:hover { background: var(--canvas); }
.nav-videos-sub > summary small { margin-left: .5rem; padding-left: 0; letter-spacing: 0; }
.nav-videos-sub > summary::after { content: ""; width: .5em; height: .5em; margin-left: auto; margin-right: .3em; border-right: 2px solid currentColor; border-bottom: 2px solid currentColor; transform: rotate(-45deg); transition: transform .2s; }
.nav-videos-sub[open] > summary::after { transform: rotate(45deg); }
.nav-videos-sub + .nav-videos-sub { border-top: 1px solid var(--line-strong); margin-top: .2rem; padding-top: .2rem; }
.topbar nav .nav-videos-sub a { padding-left: 1.1rem; }
@media (max-width: 640px) { .nav-videos-list { position: fixed; left: 1rem; right: 1rem; top: auto; min-width: 0; max-height: calc(100vh - 6rem); overflow-y: auto; } }
.play-ico { display: inline-grid; place-items: center; width: 1.6em; height: 1.6em; margin-right: .35em; border-radius: 50%; background: var(--primary); color: var(--on-primary, #062521); font-size: .8em; }
.overview { position: fixed; inset: 0; z-index: 100; display: grid; place-items: center; padding: 1rem; background: rgba(6, 8, 8, 0); backdrop-filter: blur(0); transition: background .45s ease, backdrop-filter .45s ease; }
.overview[hidden] { display: none; }
.overview.open { background: rgba(6, 8, 8, .86); backdrop-filter: blur(6px); }
.overview .frame16 { position: relative; width: min(100%, 1280px, calc((100vh - 6rem) * 16 / 9)); aspect-ratio: 16 / 9; border-radius: 14px; overflow: hidden; background: #000; box-shadow: 0 40px 120px rgba(0,0,0,.6); transform-origin: 0 0; }
.overview video { display: block; width: 100%; height: 100%; background: #000; }
.overview .close { position: absolute; top: .75rem; right: .75rem; z-index: 1; min-height: 0; width: 2.75rem; height: 2.75rem; padding: 0; border-radius: 50%; font-size: 1.4rem; line-height: 1; background: rgba(16, 18, 18, .8); color: #fff; border: 1px solid rgba(255,255,255,.25); cursor: pointer; }
.overview .close:hover { background: rgba(16, 18, 18, .95); }

/* Play icons (.play-ico in buttons and the Videos menu, .big-play on video covers): the triangle is drawn
   here rather than with the "▶" character, whose position varies by font, and sits a little right of
   centre so it looks centred in its circle. */
.play-ico, .big-play { position: relative; overflow: hidden; color: transparent !important; flex: none; }
.play-ico::before, .big-play::before {
  content: ""; position: absolute; left: 50%; top: 50%; width: 36%; height: 42%;
  transform: translate(-36%, -50%); clip-path: polygon(0 0, 100% 50%, 0 100%);
}
.play-ico::before { background: var(--on-primary, #fff); }
.big-play::before { background: #fff; }

/* Phone app store badges (Apple's and Google's official artwork, unchanged). Both link to their store listings (Google Play live
   since 2026-11-25, the App Store since 2026-11-26). .soon fades a badge whose store isn't live.
   Google's PNG has clear space built in, so it is drawn taller with negative margins to match Apple's 40 px badge. */
.stores { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem; margin-top: 1.3rem; padding-top: 1.1rem; border-top: 1px solid var(--line); }
.stores.center { justify-content: center; border-top: 0; padding-top: 0; margin-top: 1.6rem; }
.stores-note { flex-basis: 100%; margin: 0 0 .15rem; font-size: .92rem; color: var(--ink-muted); }
.stores-note strong { color: var(--ink); }
.stores img { display: block; }
.stores .badge-link { display: block; border-radius: 8px; }
.stores .badge-link:hover { filter: brightness(1.08); }
.stores .soon { opacity: .5; }
.stores .badge-apple { height: 40px; width: auto; }
.stores .badge-google { height: 60px; width: auto; margin: -10px -10px -10px -10px; }
