@charset "UTF-8";
/* Flat Field site, mockup. One stylesheet for every page.
   The same system as the Gelato site: same tokens, same parts, same names.

   HOW TO READ THIS FILE
   1 Tokens      every colour, size and space. Change values here, nowhere else.
   2 Base        resets and the content column (.wrap)
   3 Type        .display, h2, h3, .lead, .small, .eyebrow, .mono
   4 Actions     .btn, .link, .actions, .badge
   5 Chrome      .band, .nav, footer
   6 Sections    .s, .hero, .head, .close
   7 Parts       .kicker .shot .duo .feature .product .cols .rows .links
                 .facts .chips .tiles .oneprice .faq .prose
   8 Motion      [data-reveal], [data-scrub]
   9 Looks       [data-look="paper"] and [data-product="…"]

   RULES THAT KEEP THE LAYOUT WHOLE
   - Never write a colour, a font size or a width in a page. Use a part.
   - Never put style="" on anything except --d (reveal order).
   - Everything sits inside .wrap. Nothing else sets side padding.
   - A part that is not in parts.html does not exist. Add it there first. */

/* ---------- 1 Tokens ---------- */
:root {
  color-scheme: dark;
  --bg: #0a0b10;
  --bg-raise: #12141c;
  --fg: #f5f4f0;
  --mid: #c3c4cf;                 /* leads and body beside a heading */
  --mute: #9193a3;                /* small print, captions, states */
  --line: rgba(255, 255, 255, .1);
  --line-strong: rgba(255, 255, 255, .18);
  --focus: #fbd596;
  --gel: #fbd596;                 /* the glow behind pictures */
  --band: linear-gradient(90deg, #ffb020, #ff6090, #a080f0, #40c0e0, #a080f0, #ff6090, #ffb020);

  --sans: -apple-system, BlinkMacSystemFont, "SF Pro Display", "SF Pro Text", "Geist", "Helvetica Neue", Helvetica, Arial, sans-serif;
  --mono: ui-monospace, "SF Mono", SFMono-Regular, Menlo, Consolas, monospace;

  --t-display: clamp(2.75rem, 7.4vw, 5.75rem);
  --t-title: clamp(2.25rem, 5.4vw, 4rem);
  --t-h2: clamp(2rem, 4.6vw, 3.5rem);
  --t-h3: clamp(1.375rem, 2.2vw, 1.75rem);
  --t-lead: clamp(1.125rem, 1.7vw, 1.375rem);
  --t-body: 1.0625rem;
  --t-small: .875rem;

  --gutter: 24px;
  --section: clamp(96px, 15vw, 208px);
  --ease: cubic-bezier(.2, .7, .1, 1);
}

/* ---------- 2 Base ---------- */
*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0;
  background: var(--bg);
  color: var(--fg);
  font: 400 var(--t-body)/1.55 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: clip;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
h1, h2, h3, p, ul, ol, dl, dd, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
:focus-visible { outline: 2px solid var(--focus); outline-offset: 3px; border-radius: 6px; }
.skip { position: absolute; left: 16px; top: -60px; z-index: 40; background: var(--fg); color: var(--bg); padding: 10px 16px; border-radius: 999px; font-weight: 600; }
.skip:focus { top: 12px; }

/* The content column. Everything goes inside one. */
.wrap {
  max-width: 1168px;
  margin-inline: auto;
  padding-left: max(var(--gutter), env(safe-area-inset-left, 0px));
  padding-right: max(var(--gutter), env(safe-area-inset-right, 0px));
}
.wrap.wide { max-width: 1320px; }      /* only for .feature rows with a picture */
@media (max-width: 420px) { :root { --gutter: 16px; } }

/* ---------- 3 Type ---------- */
.display { font-size: var(--t-display); font-weight: 700; letter-spacing: -.04em; line-height: .98; text-wrap: balance; }
h2, .h2 { font-size: var(--t-h2); font-weight: 700; letter-spacing: -.035em; line-height: 1.04; text-wrap: balance; }
h3, .h3 { font-size: var(--t-h3); font-weight: 600; letter-spacing: -.02em; line-height: 1.15; }
.lead { font-size: var(--t-lead); line-height: 1.4; color: var(--mid); max-width: 34em; text-wrap: pretty; }
.small { font-size: var(--t-small); color: var(--mute); }
.eyebrow { font-size: var(--t-small); font-weight: 600; color: var(--mute); letter-spacing: .01em; }
.mono, kbd, code { font-family: var(--mono); font-size: .92em; letter-spacing: -.01em; }
p { text-wrap: pretty; }
/* A link inside a sentence. Never for a call to action: use .link. */
.inline, .prose a, .rows .body p a, .faq a, .cols p a, .small a { text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: .18em; text-decoration-thickness: 1px; }
.inline:hover, .prose a:hover, .rows .body p a:hover, .faq a:hover, .cols p a:hover, .small a:hover { text-decoration-color: currentColor; }

/* ---------- 4 Actions ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  height: 48px; padding: 0 26px;
  border-radius: 999px; border: 0;
  background: var(--fg); color: var(--bg);
  font: 600 1.0625rem/1 var(--sans); letter-spacing: -.01em; white-space: nowrap;
  cursor: pointer;
  transition: transform .18s var(--ease), background .18s;
}
.btn:hover { background: #fff; transform: translateY(-1px); }
.btn:active { transform: scale(.98); }
.btn.sm { height: 34px; padding: 0 16px; font-size: .875rem; }
.btn.quiet { background: rgba(255, 255, 255, .1); color: var(--fg); }
.btn.quiet:hover { background: rgba(255, 255, 255, .16); }
.link { font-weight: 600; color: var(--fg); display: inline-flex; align-items: center; gap: .35em; }
.link::after { content: "\2192"; transition: transform .2s var(--ease); }
.link:hover::after { transform: translateX(4px); }
.actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 28px; }
/* The App Store badge. Apple's artwork, unchanged, 48px high. */
.badge { display: inline-block; border-radius: 9px; }
.badge img { height: 48px; width: auto; }

/* ---------- 5 Chrome ---------- */
/* The band: 3px of light, fixed to the top of every page. */
.band { position: fixed; inset: 0 0 auto; height: 3px; background: var(--band); z-index: 30; }

.nav {
  position: sticky; top: 3px; z-index: 20;
  transition: background .3s, border-color .3s;
  border-bottom: 1px solid transparent;
}
.scrolled .nav { background: rgba(10, 11, 16, .78); -webkit-backdrop-filter: saturate(160%) blur(18px); backdrop-filter: saturate(160%) blur(18px); border-color: var(--line); }
.nav .wrap { display: flex; align-items: center; height: 60px; gap: 28px; }
.brand { display: inline-flex; align-items: center; gap: 10px; font-weight: 700; font-size: 1.125rem; letter-spacing: -.02em; margin-right: auto; }
.brand img { width: 30px; height: 30px; border-radius: 7px; }
/* The Flat Field lockup: the drawn outlines, coloured by the text colour.
   Never retype the name in a font and never use <img> for it. */
.lockup { display: block; height: 22px; aspect-ratio: 677.1 / 100; background: currentColor; -webkit-mask: url(/assets/flatfield-lockup.svg) center / contain no-repeat; mask: url(/assets/flatfield-lockup.svg) center / contain no-repeat; }
.nav a.item { font-size: .9375rem; color: var(--mid); transition: color .15s; white-space: nowrap; }
.nav a.item:hover, .nav a.item[aria-current] { color: var(--fg); }
@media (max-width: 860px) {
  .nav .wrap { gap: 18px; }
  .nav a.item.opt { display: none; }      /* .opt items drop out on a phone */
}

footer { border-top: 1px solid var(--line); padding-block: 44px 56px; font-size: var(--t-small); color: var(--mute); }
footer .row { display: flex; flex-wrap: wrap; align-items: center; gap: 16px 28px; }
footer .row + .row { margin-top: 28px; align-items: baseline; }
footer .brand { color: var(--fg); margin-right: auto; }
footer .lockup { height: 18px; }
footer nav { display: flex; flex-wrap: wrap; gap: 10px 24px; }
footer nav a:hover { color: var(--fg); }
footer .legal { max-width: 46em; line-height: 1.5; margin-right: auto; }

/* ---------- 6 Sections ---------- */
/* .s is one screen. Its padding is the only vertical rhythm on the site. */
.s { padding-block: var(--section); position: relative; }
.s.tight { padding-block: calc(var(--section) * .6); }
.s.ruled { border-top: 1px solid var(--line); }
.stack > * + * { margin-top: 20px; }
.stack > .actions { margin-top: 32px; }
.stack + .cols, .stack + .rows, .stack + .faq { margin-top: clamp(40px, 6vw, 72px); }
.center { text-align: center; }
.center .lead { margin-inline: auto; }
.center .actions { justify-content: center; }

/* Hero: the centred opener of a home or product page. */
.hero { padding-top: clamp(64px, 10vw, 128px); padding-bottom: 0; text-align: center; }
.hero .lead { margin-inline: auto; margin-top: 24px; }
.hero .actions { justify-content: center; margin-top: 36px; }
.hero .small { margin-top: 18px; }
.hero.alone, main > .hero:last-child { padding-bottom: var(--section); }     /* a hero with no picture under it */

/* Head: the left-aligned opener of a plain page (About, Support, Press, legal). */
.head { padding-top: clamp(56px, 9vw, 112px); padding-bottom: clamp(40px, 6vw, 72px); }
.head h1 { font-size: var(--t-title); font-weight: 700; letter-spacing: -.04em; line-height: 1.02; text-wrap: balance; max-width: 16em; }
.head .eyebrow { margin-bottom: 14px; }
.head .lead { margin-top: 20px; }
.head .actions { margin-top: 32px; }
.head .small { margin-top: 16px; }
.head + .s, .head + .wrap { padding-top: 0; }
.plain { padding-bottom: var(--section); }           /* the body of a plain page */

/* Close: the last screen of a product page. One line, one button. */
.close { text-align: center; padding-block: var(--section); position: relative; overflow: clip; }
.close::before { content: ""; position: absolute; left: 50%; bottom: -260px; width: min(1100px, 130vw); height: 520px; translate: -50% 0; background: radial-gradient(closest-side, var(--gel), transparent); opacity: .16; pointer-events: none; }
.close .actions { justify-content: center; margin-top: 36px; }
.close .small { margin-top: 20px; }

/* ---------- 7 Parts ---------- */

/* Kicker: a product's icon and name above a title. */
.kicker { display: flex; align-items: center; gap: 12px; font-size: 1.25rem; font-weight: 700; letter-spacing: -.02em; margin-bottom: 18px; }
.kicker img { width: 40px; height: 40px; border-radius: 9px; }
.hero .kicker { justify-content: center; }
.kicker .state { font-size: var(--t-small); font-weight: 600; color: var(--mute); letter-spacing: 0; }

/* Shot: a real screenshot. The only framed thing on the site. */
.shot { position: relative; margin-top: clamp(56px, 8vw, 104px); perspective: 1800px; }
.shot::before {
  content: ""; position: absolute; inset: 8% 6% 0; z-index: -1;
  background: radial-gradient(60% 60% at 50% 40%, var(--gel), transparent 70%);
  opacity: calc(.12 + var(--p, 1) * .2); filter: blur(60px);
}
.shot img {
  width: 100%; border-radius: clamp(10px, 1.6vw, 22px);
  box-shadow: 0 0 0 1px rgba(255, 255, 255, .08), 0 40px 120px -20px rgba(0, 0, 0, .8);
  transform-origin: 50% 100%;
  transform: rotateX(calc((1 - var(--p, 1)) * 16deg)) scale(calc(.88 + var(--p, 1) * .12));
}
/* .phone: a picture of a device that carries its own frame. */
.shot.phone img { width: min(300px, 62vw); margin-inline: auto; border-radius: 0; box-shadow: none; transform: none; }
.shot.phone::before { inset: 10% 18% 6%; }
/* .screen: a bare phone screen with no device round it. */
.shot.screen img { width: min(290px, 60vw); margin-inline: auto; border-radius: 38px; transform: none; }
.shot.screen::before { inset: 10% 18% 6%; }
figcaption { margin-top: 16px; font-size: var(--t-small); color: var(--mute); text-align: center; }

/* Duo: a phone and a watch side by side, feet on one line. */
.duo { position: relative; display: flex; justify-content: center; align-items: flex-end; gap: clamp(16px, 4vw, 44px); margin-top: clamp(56px, 8vw, 104px); }
.duo::before { content: ""; position: absolute; inset: 12% 20% 4%; z-index: -1; background: radial-gradient(60% 60% at 50% 40%, var(--gel), transparent 70%); opacity: .3; filter: blur(60px); }
.duo img:first-child { width: min(300px, 56vw); }
.duo img + img { width: min(132px, 25vw); margin-bottom: 4%; }

/* Feature: a short text beside one picture. .flip puts the picture first. */
.feature { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: clamp(32px, 6vw, 88px); align-items: center; }
.feature.flip > .text { order: 2; }
.feature h2 { font-size: clamp(1.875rem, 3.6vw, 2.75rem); margin-bottom: 14px; }
.feature p { color: var(--mid); max-width: 24em; }
.feature p + p { margin-top: 12px; }
.feature .actions { margin-top: 28px; }
.feature .shot { margin-top: 0; }
.feature .shot.phone, .feature .shot.screen { justify-self: center; width: 100%; }
/* .even: text and a narrow picture (a phone) share the row half and half. */
.feature.even { grid-template-columns: 1fr 1fr; }
@media (max-width: 860px) {
  .feature, .feature.even { grid-template-columns: 1fr; }
  .feature.flip > .text { order: 0; }
}

/* Product: one product per screen on the studio home. */
.product { border-top: 1px solid var(--line); }

/* Cols: three short points across. .ruled adds a hairline above each. */
.cols { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 44px clamp(28px, 5vw, 72px); }
.cols h3 { font-size: 1.125rem; font-weight: 600; letter-spacing: -.01em; margin-bottom: 6px; }
.cols p { color: var(--mid); font-size: 1rem; }
.cols p + p { margin-top: 8px; }
.cols.ruled > li { border-top: 1px solid var(--line); padding-top: 20px; }
.cols + .small, .cols + .actions { margin-top: 36px; }
@media (max-width: 860px) { .cols { grid-template-columns: 1fr 1fr; } }
@media (max-width: 520px) { .cols { grid-template-columns: 1fr; gap: 28px; } }

/* Rows: a ruled list. Heading on the left, anything on the right.
   The workhorse of every plain page. */
.rows { border-top: 1px solid var(--line); }
.rows > .row { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 8fr); gap: 14px clamp(24px, 5vw, 72px); padding-block: clamp(28px, 4vw, 44px); border-bottom: 1px solid var(--line); align-items: start; }
.rows > .row > :is(h2, h3) { font-size: var(--t-h3); font-weight: 600; letter-spacing: -.02em; line-height: 1.15; }
.rows .body { min-width: 0; }
.rows .body > * + * { margin-top: 14px; }
.rows .body p { color: var(--mid); max-width: 38em; }
.rows .body .small { color: var(--mute); }
.rows + .small { margin-top: 28px; }
@media (max-width: 760px) { .rows > .row { grid-template-columns: 1fr; } }

/* Links: a list of places to go. Name on the left, links on the right. */
.links { border-top: 1px solid var(--line); }
.rows .body > .links:first-child { border-top: 0; }
.rows .body > .links:first-child > li:first-child { padding-top: 0; }
.links > li { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: baseline; gap: 4px 24px; padding: 14px 0; border-bottom: 1px solid var(--line); }
.links > li:last-child { border-bottom: 0; padding-bottom: 0; }
.links b { font-weight: 600; }
.links span { display: flex; flex-wrap: wrap; gap: 4px 20px; color: var(--mid); }
.links a { text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: .18em; }
.links a:hover { text-decoration-color: currentColor; }

/* Facts: name and value pairs. Also the price list. */
.facts > div { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 7fr); gap: 2px 24px; padding: 12px 0; border-bottom: 1px solid var(--line); }
.facts > div:first-child { padding-top: 0; }
.facts > div:last-child { border-bottom: 0; padding-bottom: 0; }
.facts dt { font-weight: 600; }
.facts dd { color: var(--mid); min-width: 0; }
.facts.prices dd { color: var(--fg); font-weight: 600; font-variant-numeric: tabular-nums; }
@media (max-width: 520px) { .facts > div { grid-template-columns: 1fr; } }

/* Chips: short words set in mono. For things you type, say or run on. */
.chips { display: flex; flex-wrap: wrap; gap: 8px; }
.chip { display: inline-block; font-family: var(--mono); font-size: .8125rem; color: var(--mid); padding: 6px 10px; border-radius: 8px; background: rgba(255, 255, 255, .07); white-space: nowrap; }
.platforms { display: flex; justify-content: center; gap: 8px; margin-top: 22px; }

/* Tiles: files to download, each shown on a swatch. Press page only. */
.tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(150px, 1fr)); gap: 28px 20px; }
.tiles .sw { position: relative; aspect-ratio: 4 / 3; border-radius: 14px; background: var(--bg-raise); overflow: hidden; }
.tiles .sw.ink { background: #141414; color: #f6f4ef; }
.tiles .sw > * { position: absolute; inset: 16%; width: 68%; height: 68%; object-fit: contain; }
.tiles .sw.full > * { inset: 0; width: 100%; height: 100%; object-fit: cover; }
.tiles .sw .lockup { aspect-ratio: auto; }
.tiles .sw .mark { background: currentColor; -webkit-mask: url(/assets/flatfield-mark.svg) center / contain no-repeat; mask: url(/assets/flatfield-mark.svg) center / contain no-repeat; }
.tiles b { display: block; margin-top: 12px; font-weight: 600; font-size: 1rem; }
.tiles span { display: flex; gap: 14px; font-size: var(--t-small); color: var(--mute); }
.tiles a { text-decoration: underline; text-decoration-color: var(--line-strong); text-underline-offset: .18em; }

/* One price: a single number, centred. For an app with no plans. */
.oneprice { text-align: center; }
.price { margin-top: 32px; display: flex; align-items: baseline; justify-content: center; gap: 10px; }
.price b { font-size: clamp(3.25rem, 7vw, 5rem); font-weight: 700; letter-spacing: -.05em; line-height: 1; }
.price span { color: var(--mute); }
.oneprice .lead { margin: 20px auto 0; }
.oneprice .actions { justify-content: center; margin-top: 32px; }
.oneprice .small { margin-top: 18px; }

/* Questions: native details, hairlines between. */
.faq { max-width: 760px; margin: clamp(40px, 6vw, 72px) auto 0; text-align: left; }
.faq details { border-top: 1px solid var(--line); }
.faq details:last-child { border-bottom: 1px solid var(--line); }
.faq summary { list-style: none; cursor: pointer; padding: 22px 40px 22px 0; font-size: 1.1875rem; font-weight: 600; letter-spacing: -.01em; position: relative; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; position: absolute; right: 4px; top: 50%; translate: 0 -54%; font-size: 1.5rem; font-weight: 400; color: var(--mute); transition: rotate .25s var(--ease); }
.faq details[open] summary::after { rotate: 45deg; }
.faq details p { color: var(--mid); padding: 0 40px 24px 0; max-width: 38em; }

/* Prose: long reading text. Terms, Privacy, Refunds, Help. */
.prose { max-width: 42em; }
.prose > * + * { margin-top: 16px; }
.prose h2 { font-size: var(--t-h3); font-weight: 600; letter-spacing: -.02em; line-height: 1.15; margin-top: 56px; }
.prose h3 { font-size: 1.125rem; font-weight: 600; letter-spacing: -.01em; margin-top: 32px; }
.prose p, .prose li { color: var(--mid); }
.prose ul { list-style: disc; padding-left: 1.2em; }
.prose ol { list-style: decimal; padding-left: 1.4em; }
.prose li + li { margin-top: 6px; }
.prose .links, .prose .facts { margin-top: 20px; }
.prose .small { margin-top: 56px; color: var(--mute); }

/* ---------- 8 Motion ----------
   Everything is complete at rest. Motion is added only when script is
   running and the reader has not asked for less. */
@media (prefers-reduced-motion: no-preference) {
  .js [data-reveal] { opacity: 0; transform: translateY(28px); transition: opacity .8s var(--ease), transform .9s var(--ease); transition-delay: calc(var(--d, 0) * 90ms); }
  .js [data-reveal].in { opacity: 1; transform: none; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition-duration: .01ms !important; animation: none !important; }
  .shot img { transform: none; }
}

/* ---------- 9 Looks ---------- */
/* Paper: the studio's own pages. Set data-look="paper" on <html>.
   Light only. Product pages stay dark. Screenshots stay dark on both. */
[data-look="paper"] {
  color-scheme: light;
  --bg: #f6f4ef;
  --bg-raise: #efece5;
  --fg: #141414;
  --mid: #45423c;
  --mute: #6b675f;
  --line: #dcd8cf;
  --line-strong: #c2bdb1;
  --focus: #8a5a1c;
  --gel: #c9b48a;
}
[data-look="paper"] .btn:hover { background: #000; }
[data-look="paper"] .btn.quiet { background: rgba(20, 20, 20, .07); color: var(--fg); }
[data-look="paper"] .btn.quiet:hover { background: rgba(20, 20, 20, .12); }
[data-look="paper"].scrolled .nav { background: rgba(246, 244, 239, .82); }
[data-look="paper"] .chip { background: rgba(20, 20, 20, .06); }
[data-look="paper"] .shot img { box-shadow: 0 0 0 1px rgba(20, 20, 20, .1), 0 40px 90px -30px rgba(20, 20, 20, .45); }
[data-look="paper"] .shot.phone img { box-shadow: none; }
[data-look="paper"] .shot::before, [data-look="paper"] .duo::before { opacity: .5; }

/* Products: one light each. Set data-product on <html> for a product's own
   page (dark), or on one .product section of the studio home (the glow
   behind its picture follows). Add a product by adding one line here. */
[data-product="gelato"]     { --band: linear-gradient(90deg, #40c0e0, #a080f0, #ff6090, #ffb020, #ff6090, #a080f0, #40c0e0); --gel: #a9c8ff; }
[data-product="focus-mate"] { --band: linear-gradient(90deg, #ff7448, #f0789a, #ff6b7a, #ffb020, #ff6b7a, #f0789a, #ff7448); --gel: #ff7448; }
[data-product="exeunt"]     { --band: linear-gradient(90deg, #6a7282, #b9a274, #e9c785, #f8e6b8, #e9c785, #b9a274, #6a7282); --gel: #e9c785; }
html[data-product="gelato"]     { --focus: #40c0e0; }
html[data-product="focus-mate"] { --focus: #ff7448; }
html[data-product="exeunt"]     { --focus: #e9c785; }
