/* plotish-site — tokens from ~/Projects/plotish/design/design-tokens.css and Theme.swift */

@font-face { font-family: "Gloock"; src: url("fonts/Gloock-Regular.ttf") format("truetype"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Outfit"; src: url("fonts/Outfit-Regular.ttf") format("truetype"); font-weight: 400; font-display: swap; }
@font-face { font-family: "Outfit"; src: url("fonts/Outfit-Medium.ttf") format("truetype"); font-weight: 500; font-display: swap; }
@font-face { font-family: "Outfit"; src: url("fonts/Outfit-SemiBold.ttf") format("truetype"); font-weight: 600; font-display: swap; }

:root {
  --blush: #ffd1e8;
  --raspberry: #e0457b;
  --tangerine: #ff7a3d;
  --plum: #2e1522;
  --ink: #4a1f33;
  --ink-muted: #8a4a62;
  --cream: #fff1f1;
  --pink: #ffb0c8;
  --accent: #ffb347;
  --green-flag: #3b8a47;

  --display: "Gloock", Georgia, serif;
  --body: "Outfit", system-ui, sans-serif;

  --inset: clamp(16px, 5vw, 56px);
  --measure: 34rem;
  --cover-shadow: 0 18px 40px rgba(74, 31, 51, .35);
  --sticker-shadow: drop-shadow(0 12px 18px rgba(120, 20, 60, .35));
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  background: var(--blush);
  color: var(--ink);
  font: 400 17px/1.5 var(--body);
  overflow-x: hidden;
}
img, svg { display: block; max-width: 100%; }
a { color: inherit; text-underline-offset: .2em; text-decoration-thickness: 1.5px; }
:focus-visible { outline: 2.5px solid currentColor; outline-offset: 3px; border-radius: 4px; }
.skip { position: absolute; left: -999px; }
.skip:focus { left: var(--inset); top: 12px; background: var(--ink); color: var(--cream); padding: 8px 14px; border-radius: 999px; z-index: 10; }

/* One flat colour per band, like one colour per screen in the app. */
.tone-blush     { --bg: var(--blush);     --fg: var(--ink);   --head: var(--raspberry); --muted: var(--ink-muted); }
.tone-raspberry { --bg: var(--raspberry); --fg: var(--cream); --head: var(--blush);     --muted: rgba(255, 241, 241, .85); }
.tone-tangerine { --bg: var(--tangerine); --fg: var(--ink);   --head: var(--blush);     --muted: var(--ink); }
.tone-plum      { --bg: var(--plum);      --fg: var(--cream); --head: var(--pink);      --muted: rgba(255, 241, 241, .75); }
.tone-cream     { --bg: var(--cream);     --fg: var(--ink);   --head: var(--raspberry); --muted: var(--ink-muted); }
[class*="tone-"] { background: var(--bg); color: var(--fg); }

.wrap { max-width: 1120px; margin: 0 auto; padding: 0 var(--inset); }

/* Type */
.display {
  font-family: var(--display);
  font-weight: 400;
  letter-spacing: -.03em;
  line-height: .9;
  text-transform: lowercase;
  color: var(--head);
  margin: 0;
  text-wrap: balance;
}
.display em { font-style: italic; color: var(--fg); }
.kicker {
  font: 600 13px/1.3 var(--body);
  letter-spacing: .14em;
  text-transform: uppercase;
  margin: 0;
}
.lede { font-size: clamp(17px, 1.6vw, 20px); max-width: var(--measure); color: var(--muted); margin: 0; }

.wordmark {
  font-family: var(--display);
  letter-spacing: -.03em;
  color: var(--head);
  text-decoration: none;
  line-height: 1;
}
.wordmark i { color: var(--fg); }

/* Header row: wordmark, links, 2pt ink rule beneath (login screen). */
.masthead { display: flex; align-items: baseline; justify-content: space-between; gap: 16px; padding: 28px 0 14px; border-bottom: 2px solid var(--fg); }
.masthead .wordmark { font-size: 28px; }
.masthead nav { display: flex; gap: 22px; }
.masthead nav a { font: 600 13px/1 var(--body); letter-spacing: .14em; text-transform: uppercase; text-decoration: none; }
.masthead nav a:hover, .masthead nav a[aria-current] { text-decoration: underline; text-decoration-thickness: 2.5px; }

.pill {
  display: inline-flex; align-items: center; justify-content: center;
  min-height: 56px; padding: 0 30px;
  border-radius: 999px;
  background: var(--fg); color: var(--bg);
  font: 600 17px/1 var(--body);
  text-decoration: none;
}
.pill:hover { filter: brightness(1.15); }

.rule { border: 0; border-top: 1.5px solid currentColor; opacity: .35; margin: 0; }

/* ---------- Home: hero ---------- */
.hero { position: relative; overflow: hidden; }
.hero-body { display: grid; gap: 28px; padding: clamp(48px, 9vw, 104px) 0 0; }
.hero h1 { font-size: clamp(64px, 15.5vw, 208px); }
.hero h1 span { display: block; }
.hero .actions { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 22px; }
.hero .actions small { color: var(--muted); font-size: 15px; }

/* The app icon's four spines, standing on the edge where the next band starts. */
.shelf {
  --u: clamp(1.4px, .3vw, 2.8px);
  display: flex; align-items: flex-end; gap: calc(4 * var(--u));
  margin: clamp(40px, 7vw, 72px) 0 0 auto;
  width: max-content;
  padding-right: calc(14 * var(--u));
}
.spine { border-radius: calc(3 * var(--u)) calc(3 * var(--u)) 0 0; }
.spine:nth-child(1) { width: calc(30 * var(--u)); height: calc(118 * var(--u)); background: var(--raspberry); }
.spine:nth-child(2) { width: calc(24 * var(--u)); height: calc(138 * var(--u)); background: var(--ink); }
.spine:nth-child(3) { width: calc(34 * var(--u)); height: calc(100 * var(--u)); background: var(--tangerine); }
.spine:nth-child(4) {
  width: calc(22 * var(--u)); height: calc(126 * var(--u)); background: var(--pink);
  transform-origin: 0 100%; transform: rotate(8deg);
  animation: lean 900ms cubic-bezier(.3, 1.4, .5, 1) 400ms both;
}
@keyframes lean { from { transform: rotate(0deg); } to { transform: rotate(8deg); } }

/* ---------- Home: feature bands ---------- */
.band { padding: clamp(64px, 10vw, 120px) 0; }
.band-grid { display: grid; gap: clamp(36px, 6vw, 72px); align-items: center; }
@media (min-width: 860px) { .band-grid { grid-template-columns: 1fr 1fr; } .band-grid.flip > :first-child { order: 2; } }
.band h2 { font-size: clamp(48px, 7.4vw, 92px); margin: 14px 0 22px; }
.band .kicker { color: var(--fg); }

/* Browse: fit card */
.fit-card { display: grid; grid-template-columns: auto 1fr; gap: 18px 22px; max-width: 460px; }
.cover {
  width: clamp(96px, 22vw, 132px); aspect-ratio: 2 / 3; border-radius: 8px;
  box-shadow: var(--cover-shadow);
  background: linear-gradient(160deg, #6a7f9c, #4b5d78);
}
.fit-card .meta { align-self: end; }
.fit-num { font-family: var(--display); font-size: clamp(64px, 9vw, 96px); line-height: .9; letter-spacing: -.03em; color: var(--cream); }
.fit-card .title { font: 600 17px/1.3 var(--body); margin: 8px 0 0; }
.fit-card .author { font-size: 15px; color: var(--muted); margin: 0; }
.facets { grid-column: 1 / -1; list-style: none; margin: 6px 0 0; padding: 0; border-top: 1.5px solid rgba(255, 241, 241, .35); }
.facets li { display: flex; justify-content: space-between; gap: 12px; padding: 11px 0; border-bottom: 1.5px solid rgba(255, 241, 241, .35); font-size: 15px; }
.facets b { font-weight: 600; }
.mark { font-weight: 500; white-space: nowrap; }
.mark::before { content: ""; display: inline-block; width: 9px; height: 9px; border-radius: 50%; margin-right: 8px; vertical-align: 1px; border: 1.5px solid currentColor; }
.mark.in::before { background: currentColor; }
.mark.near::before { background: linear-gradient(90deg, currentColor 50%, transparent 50%); }

/* Library: shelf list */
.shelves { list-style: none; margin: 0; padding: 0; border-top: 2px solid var(--ink); }
.shelves li { display: grid; grid-template-columns: 1fr auto; align-items: center; gap: 4px 16px; padding: 18px 0; border-bottom: 1.5px solid rgba(74, 31, 51, .35); }
.shelves b { font: 600 20px/1.2 var(--body); }
.shelves span { grid-column: 1; font-size: 15px; }
.shelves .count { font-style: normal; grid-row: 1 / span 2; grid-column: 2; font-family: var(--display); font-size: clamp(40px, 6vw, 56px); color: var(--blush); line-height: 1; }

/* Finish: stickers */
.stickers { display: grid; grid-template-columns: repeat(4, 1fr); gap: 22px 12px; max-width: 460px; }
.stickers figure { margin: 0; text-align: center; font: 500 14px/1.3 var(--body); }
.stickers img { width: clamp(56px, 13vw, 76px); height: auto; margin: 0 auto 8px; filter: var(--sticker-shadow); }
.stickers figure:nth-child(odd) img { transform: rotate(-6deg); }
.stickers figure:nth-child(3n) img { transform: rotate(5deg); }
.stickers .picked img { outline: 2px solid var(--pink); outline-offset: 6px; border-radius: 50%; }

/* You: gradient, reserved for this band only */
.tone-you { --fg: var(--ink); --head: var(--cream); --muted: var(--ink); position: relative; overflow: hidden; color: var(--ink); isolation: isolate; }
.tone-you::before {
  content: ""; position: absolute; inset: -20%; z-index: -1; filter: blur(30px);
  background:
    radial-gradient(ellipse 55% 45% at 20% 15%, #ffb0c8 0%, transparent 70%),
    radial-gradient(ellipse 50% 50% at 85% 30%, #ff4fa0 0%, transparent 70%),
    radial-gradient(ellipse 60% 50% at 30% 85%, #ffb347 0%, transparent 70%),
    linear-gradient(180deg, #ff8f8a, #ff7a66);
}
.tone-you h2 { text-transform: none; }
.week { display: grid; grid-template-columns: repeat(7, 1fr); gap: 8px; align-items: end; height: 220px; max-width: 460px; }
.week div { display: flex; flex-direction: column; justify-content: flex-end; align-items: center; gap: 6px; height: 100%; font: 600 13px/1 var(--body); }
.week i { display: block; width: 100%; background: rgba(255, 241, 241, .7); border-radius: 2px 2px 0 0; }
.week .best i { background: var(--ink); }
.week .none i { height: 3px !important; background: rgba(74, 31, 51, .25); }
.week-caption { font-size: 14px; margin: 12px 0 0; }
.goal { margin-top: 36px; padding-top: 22px; border-top: 1.5px solid rgba(74, 31, 51, .35); max-width: 460px; }
.goal-num { font-family: var(--display); font-size: clamp(72px, 10vw, 104px); line-height: .9; color: var(--cream); letter-spacing: -.03em; }
.goal-num small { font-size: .38em; color: var(--ink); }
.goal p { margin: 10px 0 0; }

/* Closing band + footer */
.closer { text-align: center; }
.closer h2 { margin-left: auto; margin-right: auto; }
.closer .lede { margin: 0 auto 30px; }

.footer { padding-top: 40px; padding-bottom: 48px; border-top: 2px solid var(--fg); }
.footer-row { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 14px 28px; }
.footer .wordmark { font-size: 26px; }
.footer nav { display: flex; gap: 22px; font-size: 15px; font-weight: 500; }
.footer p { margin: 0; color: var(--muted); font-size: 15px; }

/* ---------- Text pages (privacy, support) ---------- */
.page-head { padding: clamp(48px, 9vw, 96px) 0 clamp(36px, 6vw, 56px); }
.page-head h1 { font-size: clamp(56px, 11vw, 132px); margin: 16px 0 22px; }
.prose { max-width: 40rem; padding-bottom: clamp(64px, 10vw, 112px); }
.prose section { padding: 28px 0; border-top: 1.5px solid rgba(74, 31, 51, .35); }
.prose h2 { font-family: var(--display); font-weight: 400; font-size: clamp(28px, 4vw, 36px); line-height: 1; letter-spacing: -.02em; color: var(--head); margin: 0 0 14px; text-transform: lowercase; }
.prose h3 { font: 600 17px/1.35 var(--body); margin: 22px 0 6px; }
.prose p, .prose ul { margin: 0 0 12px; }
.prose ul { padding-left: 1.2em; }
.prose li { margin-bottom: 6px; }
.prose .label { font-weight: 600; }

.contact { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 22px; margin-top: 30px; }

@media (prefers-reduced-motion: reduce) {
  .spine:nth-child(4) { animation: none; }
}
