/* The Greater Plan, teaser site. Light, quiet, a lot of air. */

:root {
  --ground: #FAFAF9;
  --board: #FFFFFF;
  --ink: #1C1917;
  --muted: #6B6661;
  --faint: #A8A29E;
  --hair: rgba(28, 25, 23, 0.08);
  --curve: cubic-bezier(.22, 1, .36, 1);
  --serif: "Instrument Serif", Georgia, "Times New Roman", serif;
  --sans: Inter, system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  --squircle: polygon(50% 0%, 56.52% .21%, 61.92% .84%, 66.9% 1.89%, 71.53% 3.35%, 75.85% 5.22%, 79.86% 7.47%, 83.54% 10.11%, 86.89% 13.11%, 89.89% 16.46%, 92.53% 20.14%, 94.78% 24.15%, 96.65% 28.47%, 98.11% 33.1%, 99.16% 38.08%, 99.79% 43.48%, 100% 50%, 99.79% 56.52%, 99.16% 61.92%, 98.11% 66.9%, 96.65% 71.53%, 94.78% 75.85%, 92.53% 79.86%, 89.89% 83.54%, 86.89% 86.89%, 83.54% 89.89%, 79.86% 92.53%, 75.85% 94.78%, 71.53% 96.65%, 66.9% 98.11%, 61.92% 99.16%, 56.52% 99.79%, 50% 100%, 43.48% 99.79%, 38.08% 99.16%, 33.1% 98.11%, 28.47% 96.65%, 24.15% 94.78%, 20.14% 92.53%, 16.46% 89.89%, 13.11% 86.89%, 10.11% 83.54%, 7.47% 79.86%, 5.22% 75.85%, 3.35% 71.53%, 1.89% 66.9%, .84% 61.92%, .21% 56.52%, 0% 50%, .21% 43.48%, .84% 38.08%, 1.89% 33.1%, 3.35% 28.47%, 5.22% 24.15%, 7.47% 20.14%, 10.11% 16.46%, 13.11% 13.11%, 16.46% 10.11%, 20.14% 7.47%, 24.15% 5.22%, 28.47% 3.35%, 33.1% 1.89%, 38.08% .84%, 43.48% .21%);
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--ground);
  color: var(--ink);
  font: 400 15px/1.6 var(--sans);
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  
}

a { color: inherit; text-decoration: none; }
:focus-visible { outline: 1.5px solid var(--ink); outline-offset: 4px; border-radius: 8px; }

.skip { position: absolute; left: 16px; top: -60px; z-index: 20; padding: 8px 12px; border-radius: 10px; background: var(--board); }
.skip:focus { top: 12px; }

/* Two languages in one page: Dutch unless the page says English. */
html:not([data-lang="en"]) [data-l="en"],
html[data-lang="en"] [data-l="nl"] { display: none !important; }

.col { width: 100%; max-width: 560px; margin: 0 auto; padding: 0 20px; }

/* The small numbered label, everywhere. */
.label { display: block; font: 500 11px/1.4 var(--sans); letter-spacing: .02em; color: var(--muted); }

/* Links in running text: a hairline, and a firmer line gliding in from the left. */
.line-link {
  background:
    linear-gradient(currentColor, currentColor) 0 100% / 0% 1.5px no-repeat,
    linear-gradient(var(--faint), var(--faint)) 0 100% / 100% 1px no-repeat;
  padding-bottom: 1px;
}
.line-link:hover, .line-link:focus-visible { background-size: 100% 1.5px, 100% 1px; }

/* ---------- Top ---------- */

.top {
  display: flex; align-items: center; justify-content: space-between;
  max-width: 1120px; margin: 0 auto; padding: 18px 20px;
}
.home { display: inline-flex; align-items: center; min-height: 44px; }
.wordmark {
  display: block; height: 15px; aspect-ratio: 624 / 89; background: var(--ink);
  -webkit-mask: url("assets/tgp-wordmark-line.png") no-repeat left center / contain;
          mask: url("assets/tgp-wordmark-line.png") no-repeat left center / contain;
}

.lang { position: relative; display: inline-flex; gap: 2px; padding: 3px; border-radius: 999px; background: var(--board); box-shadow: inset 0 0 0 1px var(--hair); }
.lang a {
  position: relative; z-index: 1; width: 40px; height: 30px;
  display: inline-flex; align-items: center; justify-content: center; border-radius: 999px;
  font: 600 11px/1 var(--sans); letter-spacing: .04em; color: var(--muted);
}
.lang a[aria-current="true"] { color: #FFFFFF; }
/* One ink shape that glides between the two words, like the app's bar. */
.lang::before { content: ""; position: absolute; top: 3px; left: 3px; width: 40px; height: 30px; border-radius: 999px; background: var(--ink); }
html[data-lang="en"] .lang::before { transform: translateX(42px); }

/* Paper grain, shared by every card. */
.paper { position: relative; overflow: hidden; }
.paper::before, .paper::after { content: ""; position: absolute; inset: 0; pointer-events: none; border-radius: inherit; }
.paper::before {
  background-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='160' height='160'%3E%3Cfilter id='n'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='0.9' numOctaves='3' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23n)'/%3E%3C/svg%3E");
  background-size: 140px 140px; opacity: .5; mix-blend-mode: overlay;
}
.paper::after {
  background-image: url("data:image/svg+xml;utf8,%3Csvg xmlns='http://www.w3.org/2000/svg' width='180' height='180'%3E%3Cfilter id='s'%3E%3CfeTurbulence type='fractalNoise' baseFrequency='1.4' numOctaves='2' stitchTiles='stitch'/%3E%3CfeColorMatrix type='saturate' values='0'/%3E%3CfeComponentTransfer%3E%3CfeFuncR type='discrete' tableValues='0 0 1'/%3E%3CfeFuncG type='discrete' tableValues='0 0 1'/%3E%3CfeFuncB type='discrete' tableValues='0 0 1'/%3E%3C/feComponentTransfer%3E%3C/filter%3E%3Crect width='100%25' height='100%25' filter='url(%23s)'/%3E%3C/svg%3E");
  background-size: 180px 180px; opacity: .16; mix-blend-mode: multiply;
}
.orange { --bg: #FF5900; background: linear-gradient(180deg, color-mix(in srgb, var(--bg) 90%, #FCFBF9) 0%, var(--bg) 40%); }

/* ---------- The card ---------- */


.card {
  --c-soft: rgba(28,25,23,.68);
  --c-track: rgba(28,25,23,.16);
  position: relative; flex: none; width: 340px; height: 300px; padding: 18px 20px 0;
  border-radius: 24px; color: var(--ink);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.55), inset 0 0 0 1px rgba(28,25,23,.05), 0 1px 2px rgba(0,0,0,.05), 0 10px 24px -6px rgba(0,0,0,.14), 0 40px 80px -30px rgba(0,0,0,.18);
  transform: rotate(-1.5deg);
}
.card .edge { position: absolute; inset: 0; border-radius: inherit; box-shadow: inset 0 0 46px rgba(0,0,0,.14); pointer-events: none; }
.card > * { position: relative; z-index: 1; }
.card h2 { margin: 0; height: 62px; padding-right: 56px; font: 400 30px/31px var(--serif); letter-spacing: -0.02em; -webkit-text-stroke: .5px currentColor; }
.card .gm { position: absolute; top: 18px; right: 20px; width: 36px; height: 36px; }
.card .status { display: flex; align-items: center; height: 18px; margin-top: 8px; font: 700 12px/1 var(--sans); color: var(--c-soft); }
.card .status b { width: 57px; flex: none; }
.card .dashes { display: flex; gap: 4px; width: 170px; }
.card .dashes i { flex: 1; height: 6px; border-radius: 2px; background: var(--c-track); }
.card .dashes i.on { background: var(--ink); }
.card .count { margin-left: 10px; font-weight: 600; }
.card ul { list-style: none; margin: 10px 0 0; padding: 0; }
.card li { display: flex; align-items: center; gap: 8px; height: 48px; border-top: 1px solid var(--c-track); font: 500 16px/1.2 var(--sans); letter-spacing: -0.01em; }
.card li .m { width: 40px; flex: none; display: flex; justify-content: center; }
.card li .m svg { width: 26px; height: 26px; display: block; }
.card li .rule { width: 1px; height: 22px; background: var(--c-track); flex: none; }
.card li .t { white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.card li .soft { color: var(--c-soft); }
.card .sign {
  position: absolute; right: 20px; bottom: 12px; height: 15px; aspect-ratio: 624 / 89; background: var(--ink); opacity: .72;
  -webkit-mask: url("assets/tgp-wordmark-line.png") no-repeat center / contain;
          mask: url("assets/tgp-wordmark-line.png") no-repeat center / contain;
}

/* ---------- The story ---------- */

.story-stage { display: flex; flex-direction: column; align-items: center; }
.beat { display: flex; flex-direction: column; align-items: center; justify-content: center; text-align: center; padding: 12vh 24px; }
.say { margin: 0; max-width: 15em; font: 400 clamp(28px, 3.6vw, 42px)/1.12 var(--serif); letter-spacing: -0.015em; -webkit-text-stroke: .3px currentColor; text-wrap: balance; }
.say.dim, .say .dim { color: rgba(28, 25, 23, .5); }
p.say.dim { margin-top: 12px; font-size: clamp(22px, 2.8vw, 30px); }
.beat-mark { width: 30px; height: 30px; margin-bottom: 22px; }
.beat-logo { width: 44px; height: 44px; margin-bottom: 28px; }
.formula { display: flex; align-items: center; gap: 14px; margin-bottom: 28px; }
.formula svg { width: 40px; height: 40px; }
.formula span { font: 500 22px/1 var(--sans); color: rgba(28, 25, 23, .4); }

/* ---------- The card, built step by step ---------- */

.build-stage { display: flex; flex-direction: column; align-items: center; padding: 8vh 16px 0; }
.visual { --k: 1; position: relative; width: 340px; height: 300px; flex: none; }
.visual .card-wrap { position: absolute; left: 0; top: 0; }
.fan, .tiles, .pieces, .logo { display: none; }
.caps { width: 100%; max-width: 420px; margin-top: 36px; text-align: center; }
.cap + .cap { margin-top: 36px; }
.cap-t { margin: 0; font: 400 clamp(23px, 2.4vw, 28px)/1.15 var(--serif); letter-spacing: -0.01em; -webkit-text-stroke: .25px currentColor; text-wrap: balance; }
.cap-b { margin: 8px auto 0; max-width: 24em; font-size: 14.5px; line-height: 1.55; color: var(--muted); text-wrap: balance; }

/* With motion: one line at a time, on a stage that stays put. */
.motion .story { height: calc(100vh + 8 * 66vh); }
/* A drum of lines: the one in front upright, the others leaning away. */
.motion .story-stage { position: sticky; top: 0; height: 100vh; height: 100svh; display: block; overflow: hidden; perspective: 900px; }
.motion .beat { position: absolute; left: 0; right: 0; top: 50%; padding: 0 24px; opacity: 0; transform: translateY(-50%); will-change: opacity, transform; backface-visibility: hidden; }
.motion .beat:first-child { opacity: 1; }
.cap-last .cap-t { font-size: clamp(30px, 3.4vw, 40px); }

.motion .build { height: calc(100vh + 3.6 * 136vh); }
.build, .story { overflow-x: clip; }
.motion .build-stage { position: sticky; top: 0; height: 100vh; height: 100svh; justify-content: center; padding: 24px 16px 48px; }
.motion .visual { height: 390px; transform: scale(var(--k)); transform-origin: top center; margin-bottom: calc(390px * (var(--k) - 1)); }
.motion .visual .card-wrap { top: 90px; will-change: opacity, transform; }
.motion .fan, .motion .tiles, .motion .pieces, .motion .logo { display: block; }
.motion .caps { position: relative; height: 128px; margin-top: 28px; }
.motion .cap { position: absolute; left: 0; right: 0; top: 0; margin: 0; opacity: 0; will-change: opacity, transform; }
.motion .cap:first-child { opacity: 1; }
.motion .card .status, .motion .card li.part-people, .motion .card li.part-res { opacity: 0; }

/* The faces of the community, fanned above the card's left shoulder. */
.fan { position: absolute; left: -6px; top: 6px; width: 172px; height: 84px; opacity: 0; }
.fan .f { position: absolute; top: var(--y); left: var(--x); width: 58px; height: 58px; transform: rotate(var(--a)); filter: drop-shadow(0 6px 9px rgba(0,0,0,.16)); }
.fan .f > span { display: block; width: 100%; height: 100%; padding: 3px; clip-path: var(--squircle); background: #FFFFFF; }
.fan .f > span > span { display: flex; width: 100%; height: 100%; align-items: center; justify-content: center; clip-path: var(--squircle); background: linear-gradient(160deg, var(--g), var(--t)); font: 400 24px/1 var(--serif); color: var(--i); }
.fan .f:nth-child(1) { --x: 0;     --y: 18px; --a: -9deg; --g: #FAF0E8; --t: #D9BFAC; --i: #5A3626; }
.fan .f:nth-child(2) { --x: 38px;  --y: 6px;  --a: -3deg; --g: #F4F7EA; --t: #C8D0AE; --i: #414A2C; z-index: 2; }
.fan .f:nth-child(3) { --x: 76px;  --y: 4px;  --a: 4deg;  --g: #F1F5F8; --t: #C2CDD5; --i: #33424C; z-index: 3; }
.fan .f:nth-child(4) { --x: 114px; --y: 16px; --a: 10deg; --g: #F6EEF3; --t: #CDBEC8; --i: #4B3A46; z-index: 1; }

/* Three things from the shelf, above the right shoulder. */
.tiles { position: absolute; right: -10px; top: 0; width: 216px; height: 90px; opacity: 0; }
.tile {
  position: absolute; left: var(--x); top: var(--y); width: 76px; height: 76px; padding: 9px; border-radius: 16px;
  display: flex; align-items: center; justify-content: center; color: var(--ink);
  background: linear-gradient(165deg, var(--g) 0%, var(--s) 72%); transform: rotate(var(--r));
  box-shadow: inset 0 1px 0 rgba(255,255,255,.55), 0 1px 2px rgba(0,0,0,.06), 0 10px 20px -8px rgba(0,0,0,.22);
}
.tile svg { width: 26px; height: 26px; }
.tile b { font: 600 9.5px/1.15 var(--sans); hyphens: manual; }
.tile.zand  { --g: #FDF8EB; --s: #F0E4C7; }
.tile.steen { --g: #F7F4EF; --s: #E7E2D9; }
.tile.olijf { --g: #F4F7EA; --s: #E2E7CE; }

/* The marks that fly out, and the mark they become. */
.pieces { position: absolute; inset: 0; pointer-events: none; }
.pc { position: absolute; left: 0; top: 0; width: 26px; height: 26px; color: var(--ink); opacity: 0; transform-origin: 0 0; will-change: transform, opacity; }
.pc svg { display: block; width: 100%; height: 100%; }
.logo { position: absolute; left: 134px; top: 296px; width: 72px; height: 72px; opacity: 0; }
.logo svg { display: block; width: 100%; height: 100%; }

@media (max-width: 440px) {
  .visual { --k: .84; }
  .motion .caps { height: 140px; }
}
@media (max-width: 400px) and (max-height: 700px) {
  .visual { --k: .74; }
}

/* ---------- The end: one quiet row ---------- */

.foot-row {
  max-width: 1120px; margin: 0 auto; padding: 72px 20px calc(28px + env(safe-area-inset-bottom));
  display: flex; justify-content: space-between; align-items: flex-end; gap: 12px 24px;
  font-size: 12.5px; color: var(--muted);
}
.foot-left p { margin: 0; color: var(--ink); }
.foot-left .small { margin-top: 4px; font-size: 11.5px; color: var(--muted); }
.foot-right { display: flex; gap: 20px; }
.foot-right a { display: inline-flex; align-items: center; min-height: 44px; color: var(--ink); background-position: 0 75%, 0 75%; }
@media (max-width: 560px) {
  .foot-row { flex-direction: column; align-items: flex-start; }
}

.top-over { position: absolute; left: 0; right: 0; top: 0; z-index: 5; }
.lang-foot { margin: 56px 0 0; font-size: 12.5px; }
.lang-foot a { color: var(--muted); }

/* ---------- Legal pages ---------- */

.legal { padding-top: clamp(40px, 9vh, 96px); counter-reset: sec; }
.legal h1 { margin: 12px 0 0; font: 400 clamp(34px, 4.4vw, 46px)/1.05 var(--serif); letter-spacing: -0.02em; -webkit-text-stroke: .3px currentColor; }
.legal .meta { margin: 10px 0 0; font-size: 12px; color: var(--muted); }
.legal .intro { margin: 28px 0 0; font-size: 16px; }
.legal h2 { margin: 52px 0 10px; font: 600 15px/1.4 var(--sans); letter-spacing: -0.005em; counter-increment: sec; }
.legal h2::before { content: "(" counter(sec, decimal-leading-zero) ")"; display: block; margin-bottom: 6px; font: 500 11px/1.4 var(--sans); letter-spacing: .02em; color: var(--muted); }
.legal p, .legal li { font-size: 14.5px; line-height: 1.7; }
.legal p { margin: 0 0 12px; }
.legal ul { margin: 0 0 12px; padding-left: 18px; }
.legal li { margin: 4px 0; }
.legal a { background: linear-gradient(currentColor, currentColor) 0 100% / 0% 1.5px no-repeat, linear-gradient(var(--faint), var(--faint)) 0 100% / 100% 1px no-repeat; padding-bottom: 1px; }
.legal a:hover, .legal a:focus-visible { background-size: 100% 1.5px, 100% 1px; }
.legal .ph { background: rgba(255, 89, 0, .14); border-radius: 4px; padding: 0 3px; font-weight: 500; }
.legal table { width: 100%; border-collapse: collapse; margin: 6px 0 16px; font-size: 13px; line-height: 1.55; }
.legal th, .legal td { text-align: left; vertical-align: top; padding: 10px 12px 10px 0; border-bottom: 1px solid var(--hair); }
.legal th { font-weight: 500; font-size: 11px; color: var(--muted); }
.legal td:first-child { white-space: nowrap; font-weight: 500; }
@media (max-width: 560px) {
  .legal table, .legal tbody, .legal tr, .legal td { display: block; }
  .legal thead { display: none; }
  .legal tr { padding: 10px 0; border-bottom: 1px solid var(--hair); }
  .legal td { border: 0; padding: 1px 0; white-space: normal !important; }
  .legal td:last-child { color: var(--muted); font-size: 12px; }
}

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

@media (prefers-reduced-motion: no-preference) {
  .lang::before, .lang a { transition: transform .45s var(--curve), color .45s var(--curve); }
  .line-link, .legal a, .details a { transition: background-size .5s var(--curve); }
  .legal > * { animation: tgp-page .55s var(--curve) both; }
}
@keyframes tgp-page { from { opacity: 0; transform: translateX(18px); } to { opacity: 1; transform: none; } }

/* The only words above the board: a quiet "Coming soon". */
.soon-min { margin: clamp(40px, 9vh, 88px) auto 0; padding: 0 16px; font: 500 12px/1 Inter, system-ui, sans-serif; letter-spacing: .14em; text-transform: uppercase; color: rgba(28, 25, 23, .45); text-align: center; }
