/* Offlift site: the fonts, the palette and the page CSS on top of the taste-skill kit
   (system.css, ui/cards.css, motion/motion.css, backgrounds/backgrounds.css, layout/layout.css).
   Everything is served from /assets: no third-party requests. */

/* Funnel Display and Funnel Sans (SIL Open Font License 1.1), self-hosted, latin and latin-ext */
@font-face { font-family: "Funnel Display"; font-style: normal; font-weight: 400 700; font-display: swap; src: url("/assets/fonts/funnel-display-latin-ext.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, 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: "Funnel Display"; font-style: normal; font-weight: 400 700; font-display: swap; src: url("/assets/fonts/funnel-display-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; }
@font-face { font-family: "Funnel Sans"; font-style: normal; font-weight: 400 600; font-display: swap; src: url("/assets/fonts/funnel-sans-latin-ext.woff2") format("woff2"); unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, 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: "Funnel Sans"; font-style: normal; font-weight: 400 600; font-display: swap; src: url("/assets/fonts/funnel-sans-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; }

/* the palette as start.mjs brand printed it (the app's dark ground and its orange) */
:root {
  --p-bg: #0e0d0c; --p-surface: #1a1816; --p-ink: #f4f1ec; --p-muted: #a39d94;
  --p-accent: #ff662e; --p-accent-ink: #0e0d0c; --p-action: #ff662e; --p-action-ink: #0e0d0c;
  --p-inv-bg: #f4f1ec; --p-inv-surface: #e1dfda; --p-inv-ink: #0e0d0c; --p-inv-muted: #5a5956;
  --p-inv-accent: #0e0d0c; --p-inv-accent-ink: #f4f1ec; --p-inv-action: #0e0d0c; --p-inv-action-ink: #f4f1ec;
  --font-display: "Funnel Display", system-ui, sans-serif;
  --font-text: "Funnel Sans", system-ui, sans-serif;
  --font-mono: ui-monospace, "SFMono-Regular", Menlo, Consolas, monospace;
  --display-weight: 400;
  --display-tracking: -0.03em;
  --display-tracking-xl: -0.04em;
  --ly-scale: 0.98;
  /* the lit ground behind the screenshots: the warm glow of the app's own header, not the kit's sand */
  --ground-bg: #241a14; --ground-surface: #3a2619; --ground-ink: #f4f1ec; --ground-muted: #b9ab9c; --ground-accent: #ff662e;
}

/* ---------------------------------------------------------------- logo */
.logo-icon { width: 28px; height: 28px; border-radius: 7px; flex: none; }
.nav__logo { display: inline-flex; align-items: center; gap: var(--s-3); }

/* ---------------------------------------------------------------- devices (page CSS: .device, system.md) */
/* an iPhone screenshot in a thin bezel; the frame it sits in crops it */
.device {
  position: relative; aspect-ratio: 720 / 1561; border-radius: 13.5% / 6.2%; overflow: hidden; background: #000;
  box-shadow: 0 0 0 5px #2b2622, 0 0 0 6px color-mix(in oklab, var(--ink) 14%, transparent);
}
.device > img { display: block; width: 100%; height: 100%; object-fit: cover; }
/* an Apple Watch screenshot: the rounded screen alone */
.watch { aspect-ratio: 368 / 448; border-radius: 22%; overflow: hidden; background: #000;
  box-shadow: 0 0 0 5px #2b2622, 0 0 0 6px color-mix(in oklab, var(--ink) 14%, transparent); }
.watch > img { display: block; width: 100%; height: 100%; }

/* the stage a phone stands on: the app's warm glow on the lit ground, the phone cut by the bottom edge */
.shot-stage, .hero-stage, .watch-stage {
  background:
    radial-gradient(70% 55% at 50% 0%, color-mix(in oklab, var(--ground-accent) 30%, transparent), transparent 70%),
    var(--ground-bg);
}

/* ---------------------------------------------------------------- hero */
.hero-stage > .stage { position: absolute; inset: 0; --fade-h: 120px; }
.hero-stage .device { top: var(--s-7); left: 50%; translate: -50% 0; width: min(62%, 380px); }
@media (max-width: 1023px) { .hero-stage .device { width: min(66%, 300px); top: var(--s-5); } }

/* ---------------------------------------------------------------- logging (pinned-chapters) */
[data-moment="pinned-chapters"] .mo-pc__visual.shot-stage { display: flex; justify-content: center; overflow: hidden; }
[data-moment="pinned-chapters"] .shot-stage .device { flex: none; height: 150%; width: auto; margin-top: 7%; }
[data-moment="pinned-chapters"]:not(.is-live) .mo-pc__visual.shot-stage { height: 30svh; aspect-ratio: auto; }
[data-moment="pinned-chapters"].is-live .mo-pc__visuals.shot-stage { border: 1px solid var(--line); border-radius: var(--r-lg); }
[data-moment="pinned-chapters"].is-live .mo-pc__visual.shot-stage { background: transparent; }

/* ---------------------------------------------------------------- analysis: four screenshots cut by their panels */
.shots-grid .shot-panel { --p-h: 352px; height: var(--p-h); margin-top: var(--s-5); border-radius: var(--r-lg); overflow: hidden; border: 1px solid var(--line); display: flex; justify-content: center; padding-top: var(--s-6);
  -webkit-mask: linear-gradient(to bottom, #000 calc(100% - 64px), transparent calc(100% - 4px));
          mask: linear-gradient(to bottom, #000 calc(100% - 64px), transparent calc(100% - 4px)); }
.shots-grid > .shot-col { display: flex; flex-direction: column; }
.shots-grid > .shot-col > h3 { font: 500 var(--t-card)/1.3 var(--font-text); letter-spacing: 0; }
.shots-grid > .shot-col > p { margin-top: var(--s-2); }

.shots-grid > .shot-col > p { min-height: calc(3 * 1.5em); }
.shots-grid .shot-panel > img { position: relative; z-index: 1; width: 72%; height: auto; align-self: flex-start; border-radius: 18px 18px 0 0; }
.shots-grid .shot-panel.shot-panel--corner { justify-content: flex-start; padding: var(--s-6) 0 0 var(--s-6); }
.shots-grid .shot-panel.shot-panel--corner > img { width: 96%; border-radius: 18px 0 0 0; }
@media (min-width: 640px) and (max-width: 1023px) { .shots-grid > .span-3 { grid-column: span 6; } .shots-grid .shot-panel { --p-h: 250px; } }
@media (max-width: 639px) { .shots-grid > .span-3 { grid-column: span 6; } .shots-grid .shot-panel { --p-h: 168px; } .shots-grid .shot-panel.shot-panel--corner { padding: var(--s-4) 0 0 var(--s-4); } .shots-grid > .shot-col > p { display: none; } }

/* ---------------------------------------------------------------- splits: text left, the picture right */
.split-text > * + * { margin-top: var(--s-5); }
.split-text > h2 + * { margin-top: var(--s-6); }
.plain-list { padding: 0; list-style: none; display: grid; margin-bottom: 0; }
.plain-list > li { padding: var(--s-3) 0; border-bottom: 1px solid var(--line); }
.plain-list > li:first-child { border-top: 1px solid var(--line); }

.watch-row { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: var(--s-5); align-items: center; width: 100%; }
.shot-stage--cut { align-items: flex-start; padding-bottom: 0; }
.shot-stage--cut .device { width: min(52%, 320px); margin-top: var(--s-6); margin-bottom: -40%; }
@media (max-width: 1023px) {
  .split-text { margin-bottom: var(--s-7); }
  .watch-row { gap: var(--s-4); }
  .shot-stage--cut { max-height: 420px; }
}

/* ---------------------------------------------------------------- privacy statement */
.statement-label { font: 500 var(--t-small)/1.4 var(--font-text); letter-spacing: 0; color: var(--muted); margin-bottom: var(--s-6); }
.facts { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: var(--gutter); margin: var(--s-8) 0 0; }
.facts > div { display: grid; gap: var(--s-1); padding-top: var(--s-4); border-top: 1px solid var(--line); }
.facts dt { font-size: var(--t-small); color: var(--muted); }
.facts dd { margin: 0; font-weight: 500; }
@media (max-width: 1023px) { .facts { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ---------------------------------------------------------------- what's new (filled by scripts/build.py) */
.updates .rows { list-style: none; margin: 0; padding: 0; }
.updates .rows > li { padding: var(--s-5) 0; border-bottom: 1px solid var(--line); font-size: var(--t-lead); line-height: 1.5; }
.updates .rows > li:first-child { padding-top: 0; }

/* ---------------------------------------------------------------- the menu card's screenshot */
.menu-card .panel { display: flex; justify-content: center; padding-top: var(--s-4); }
.menu-card .menu-shot { position: relative; z-index: 1; inset: auto; width: 46%; height: auto; border-radius: 12px 12px 0 0; object-fit: contain; }

/* ---------------------------------------------------------------- the close's name: room for Funnel's ascenders */
.close__word { line-height: 1.05; }

/* ---------------------------------------------------------------- logging at rest on a phone: two whole screens */
@media (max-width: 639px) {
  main > #logging[data-moment]:not(.is-live) { min-height: calc(2 * 100lvh); }
  [data-moment="pinned-chapters"]:not(.is-live) .mo-pc__visual.shot-stage { height: 33svh; }
  #updates, #support { --hm: 2; }
}

/* ---------------------------------------------------------------- the app's What's new sheet (build.py) */
.sheet-stage { padding: var(--s-7); }
.sheet { width: 100%; max-width: 480px; background: var(--p-surface); border: 1px solid var(--line); border-radius: 24px; padding: var(--s-6); display: grid; gap: var(--s-5); }
.sheet__head { display: flex; align-items: center; gap: var(--s-4); }
.sheet__icon { width: 44px; height: 44px; border-radius: 11px; }
.sheet__title { font: 500 var(--t-lead)/1.3 var(--font-text); }
.sheet__sub { font-size: var(--t-small); color: var(--muted); }
.sheet__list { list-style: none; margin: 0; padding: 0; display: grid; gap: var(--s-4); }
.sheet__list > li { position: relative; padding-left: var(--s-5); }
.sheet__list > li::before { content: ""; position: absolute; left: 0; top: .62em; width: 7px; height: 7px; border-radius: 50%; background: var(--accent); }
@media (max-width: 639px) { .sheet-stage { padding: var(--s-4); } .sheet { padding: var(--s-5); } }

/* ---------------------------------------------------------------- support: the app icon and the backup note */
.support-card { flex-direction: column; align-items: flex-start; justify-content: flex-start; gap: var(--s-5); padding: var(--s-6); }
.support-card::before { display: none; }
.support-card__icon { width: 96px; height: 96px; border-radius: 22px; }
.support-card > p { color: var(--ink); max-width: 44ch; }

/* ---------------------------------------------------------------- the text pages: privacy, licenses, impressum, changelog, 404 */
.doc { padding-top: calc(var(--nav) + var(--s-9)); padding-bottom: var(--s-9); }
.doc > * { max-width: 720px; }
.doc > h1 { font-size: clamp(40px, 3.4vw + 16px, 64px); line-height: 1.04; letter-spacing: var(--display-tracking-xl); margin-bottom: var(--s-5); }
.doc > h2, .doc .release h2 { font-size: var(--t-h3); line-height: 1.25; }
.doc > h2 { margin-top: var(--s-8); margin-bottom: var(--s-4); }
.doc > h3 { font: 500 var(--t-card)/1.35 var(--font-text); letter-spacing: 0; margin-top: var(--s-6); margin-bottom: var(--s-3); }
.doc > p, .doc li, .doc address { line-height: 1.7; }
.doc > p + p, .doc > p + ul, .doc > ul + p { margin-top: var(--s-4); }
.doc ul { padding-left: 1.25em; }
.doc li + li { margin-top: var(--s-2); }
.doc address { font-style: normal; }
.doc a:not(.btn) { text-decoration: underline; text-decoration-color: var(--accent); text-decoration-thickness: 1px; text-underline-offset: 3px; }
.doc a:not(.btn):hover { text-decoration-thickness: 2px; }
.doc .muted { color: var(--muted); }
.doc .small { font-size: var(--t-small); }
.doc pre.license { margin-top: var(--s-4); font: 13px/1.6 var(--font-mono); white-space: pre-wrap; background: var(--p-surface); border: 1px solid var(--line); border-radius: var(--r-md); padding: var(--s-5); overflow-x: auto; }
/* the changelog: each version a row that opens on a tap, the newest open */
.doc .release { border-bottom: 1px solid var(--line); }
.doc .release:first-of-type { margin-top: var(--s-7); border-top: 1px solid var(--line); }
.doc .release > summary { list-style: none; cursor: pointer; padding: var(--s-5) 0; }
.doc .release > summary::-webkit-details-marker { display: none; }
.doc .release h2 { display: flex; flex-wrap: wrap; align-items: baseline; gap: var(--s-3); }
.doc .release h2 time { margin-left: auto; font: 400 var(--t-small)/1.4 var(--font-text); color: var(--muted); }
.doc .release > ul { padding-bottom: var(--s-6); }
.doc .badge { font: 500 var(--t-label)/1 var(--font-text); color: var(--accent-ink); background: var(--accent); border-radius: 999px; padding: 5px 10px; align-self: center; }
.doc-footer { border-top: 1px solid var(--line); padding: var(--s-8) 0 var(--s-7); }
@media (max-width: 400px) { .doc-body .nav__actions .btn { display: none; } }
.doc ul { list-style: disc; }
