/* Kelly Pickering. World: a 1920s Canadian landscape palette (Georgian Bay shoreline painting): ice-blue sky,
   spruce green, burnt orange, lake blue, pink granite. The real piece stands on the painted shoreline.
   Two grounds: .light (sky) and .dark (spruce). Components read the ground's role tokens (--fg, --line, ...),
   never a raw colour, so a section changes ground with one class.
   Contrast was measured on these exact pairs (2026-11-06); re-run scripts/a11y_contrast.py after any colour edit.
   Cache: bump ?v=N on the link tag in the HTML when you edit this file. */

@font-face { font-family: "KP Display"; src: url("/assets/fonts/anybody.woff2") format("woff2"); font-weight: 800; font-stretch: 75% 100%; font-display: swap; }
@font-face { font-family: "Archivo"; src: url("/assets/fonts/archivo.woff2") format("woff2"); font-weight: 400 600; font-display: swap; }
@font-face { font-family: "Soapstone"; src: url("/assets/fonts/covered-by-your-grace.woff2") format("woff2"); font-weight: 400; font-display: swap; }

:root {
  color-scheme: light;
  /* Palette, sampled from the shoreline painting */
  --sky: #dbe7ec;
  --spruce: #23413a;
  --spruce-deep: #1a302b;
  --ink: #1f3b35;            /* text on sky, 9.6:1 */
  --ink-mute: #3a5750;       /* secondary text on sky, 6.3:1 */
  --cream: #eef2ea;          /* text on spruce, 9.8:1 */
  --cream-mute: #c9d6cc;     /* secondary text on spruce, 7.4:1 */
  --orange: #a9491f;         /* the action colour: buttons, current tab, focus on light. Interactive things only */
  --orange-hover: #8f3c18;
  --on-orange: #fff6ee;      /* 5.4:1 */
  --lake: #2f5d7c;           /* decorative only (the footer fields) */
  --granite: #d99a86;        /* decorative only */
  --pine: #5a7340;           /* decorative only, the wind-bent pine */

  --font-display: "KP Display", "Archivo", system-ui, sans-serif;
  --font-body: "Archivo", system-ui, sans-serif;
  --font-hand: "Soapstone", "Archivo", cursive;

  --gutter: clamp(16px, 4vw, 56px);
  --max: 1240px;
  --radius: 4px;
  --ease: cubic-bezier(.16, 1, .3, 1);
  --header-h: 72px;

  /* Default ground roles (= .light) so anything outside a section still reads */
  --fg: var(--ink); --fg-mute: var(--ink-mute); --line: rgba(31, 59, 53, .55);
  --field-bg: #f4f8f9; --field-line: #5d7a72; --ring: var(--orange); --danger: #9e2a12;

  /* site-kit tab bar: light glass over the page, ink labels, orange current tab */
  --kit-accent: var(--orange-hover);   /* deeper orange: the 12px current-tab label measured 3.9:1 at --orange */
  --kit-accent-hover: var(--orange);
  --kit-on-accent: var(--on-orange);
  --kit-text: var(--ink);
  --kit-mute: var(--ink-mute);
  --kit-line: rgba(31, 59, 53, .18);
  --kit-paper: var(--sky);
  --kit-glass: rgba(219, 231, 236, .94);
  --kit-font: var(--font-body);
  --kit-weight-regular: 400;
  --kit-weight-strong: 600;
}

.light { background: var(--sky); color: var(--ink); --fg: var(--ink); --fg-mute: var(--ink-mute); --line: rgba(31, 59, 53, .55); --field-bg: #f4f8f9; --field-line: #5d7a72; --ring: var(--orange); --danger: #9e2a12; }
.dark { background: var(--spruce); color: var(--cream); --fg: var(--cream); --fg-mute: var(--cream-mute); --line: rgba(238, 242, 234, .5); --field-bg: var(--spruce-deep); --field-line: #8fa79c; --ring: var(--cream); --danger: #ffb4a6; }

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-padding-top: 16px; scrollbar-color: var(--ink-mute) var(--sky); }
@media (prefers-reduced-motion: no-preference) { html { scroll-behavior: smooth; } }
body { margin: 0; color: var(--ink); background: var(--sky); font: 400 1.0625rem/1.6 var(--font-body); -webkit-font-smoothing: antialiased; }
img { max-width: 100%; display: block; }
a { color: inherit; text-underline-offset: .22em; text-decoration-thickness: 1px; }
::selection { background: var(--orange); color: var(--on-orange); }
:focus-visible { outline: 2px solid var(--ring); outline-offset: 3px; border-radius: 2px; }
input, textarea, select { caret-color: var(--orange); }
.skip { position: absolute; left: 12px; top: -60px; z-index: 100; background: var(--orange); color: var(--on-orange); padding: 10px 14px; border-radius: var(--radius); font-weight: 600; }
.skip:focus { top: 12px; }
.wrap { max-width: var(--max); margin-inline: auto; padding-inline: var(--gutter); }

h1, h2, h3 { font-family: var(--font-display); font-weight: 800; font-stretch: 78%; text-transform: uppercase; line-height: .95; letter-spacing: -.02em; text-wrap: balance; margin: 0; color: var(--fg); }
h1 { font-size: clamp(2.75rem, 6.4vw, 5.75rem); }
h2 { font-size: clamp(2.2rem, 4.6vw, 3.6rem); }
h3 { font-size: clamp(1.5rem, 2.4vw, 2rem); line-height: 1; }
p { margin: 0; max-width: 62ch; }
.lead { font-size: clamp(1.125rem, 1.6vw, 1.3rem); color: var(--fg-mute); max-width: 34ch; text-wrap: pretty; }
.hand { font-family: var(--font-hand); font-weight: 400; letter-spacing: .01em; }

.btn { display: inline-flex; align-items: center; justify-content: center; min-height: 52px; padding: 0 24px; border-radius: var(--radius); font: 600 1rem/1 var(--font-body); text-decoration: none; border: 0; cursor: pointer; transition: background-color .18s var(--ease), transform .18s var(--ease); }
.btn-primary { background: var(--orange); color: var(--on-orange); }
.btn-primary:active { transform: translateY(1px); }
.link-quiet { font-weight: 600; color: var(--fg); text-decoration: underline; text-decoration-style: dashed; text-decoration-color: var(--line); text-underline-offset: .3em; padding: 14px 0; }
@media (hover: hover) and (pointer: fine) {
  .btn-primary:hover { background: var(--orange-hover); }
  .link-quiet:hover { text-decoration-color: var(--fg); }
}

.site-header { position: absolute; inset: 0 0 auto 0; z-index: 20; color: var(--ink); }
.site-header .wrap { display: flex; align-items: center; justify-content: space-between; height: var(--header-h); }
.wordmark { font: 800 1.375rem/1 var(--font-display); font-stretch: 80%; text-transform: uppercase; letter-spacing: -.01em; text-decoration: none; display: inline-flex; align-items: center; min-height: 44px; }
.site-links { display: flex; gap: clamp(18px, 2.4vw, 34px); }
.site-links a { font-weight: 600; font-size: .95rem; text-decoration: none; padding: 10px 2px; min-width: 44px; text-align: center; color: var(--ink-mute); }
.site-links a[aria-current="page"] { color: var(--ink); }
@media (hover: hover) and (pointer: fine) { .site-links a:hover { color: var(--ink); } }
@media (max-width: 859.98px) { .site-links { display: none; } }

/* The hero is a shelf: the piece stands on the dashed top edge of the painted shoreline band.
   --base is the piece's base height inside its box (piece.js frames the splat to match). */
.hero { position: relative; --band-h: 28svh; --piece-h: min(62svh, 600px); --base: .07; --shift: 12%; min-height: 100svh; overflow: hidden; }
.hero-grid { position: relative; z-index: 2; display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(0, .9fr); align-items: end; gap: 24px; min-height: 100svh; padding-top: var(--header-h); }
.hero-copy { display: grid; gap: 22px; align-content: center; align-self: stretch; padding-bottom: calc(var(--band-h) + 3svh); }
.hero-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 22px; margin-top: 6px; }
.shoreline { position: absolute; left: 0; right: 0; bottom: 0; height: var(--band-h); z-index: 1; background: url("/assets/img/shoreline.webp") center 78% / cover; border-top: 1.5px dashed var(--line); }

.piece { position: relative; width: 100%; margin-top: 0; margin-inline: 0; height: var(--piece-h); margin-bottom: calc(var(--band-h) - var(--base) * var(--piece-h)); touch-action: pan-y; user-select: none; -webkit-user-select: none; }
.piece canvas { position: absolute; inset: 0; width: 100%; height: 100%; display: block; outline: none; cursor: grab; touch-action: pan-y; }
.piece canvas:active { cursor: grabbing; }
.piece canvas:focus-visible { outline: 2px solid var(--ring); outline-offset: -2px; }
/* Contact shadow, tinted spruce: the piece turns about its vertical axis, so a flat ellipse stays right at every angle. */
.piece::before { content: ""; position: absolute; left: calc(50% + var(--shift)); bottom: calc(var(--base) * 100% - 12px); width: calc(var(--piece-h) * .4); height: 30px; transform: translateX(-50%); background: radial-gradient(closest-side, rgba(24, 46, 40, .5), rgba(24, 46, 40, .2) 55%, transparent); pointer-events: none; }
.piece .poster { position: absolute; left: calc(50% + var(--shift)); bottom: calc(var(--base) * 100%); height: 82%; width: auto; max-width: none; transform: translateX(-50%); transition: opacity .6s var(--ease); pointer-events: none; }
.piece[data-state="live"] .poster { opacity: 0; }
.piece .callouts { position: absolute; inset: 0; width: 100%; height: 100%; overflow: visible; pointer-events: none; }
.piece .callouts line { stroke: var(--fg); stroke-width: 1.4; stroke-dasharray: 5 5; stroke-linecap: round; transition: opacity .3s var(--ease); }
.piece .callouts circle { fill: var(--fg); transition: opacity .3s var(--ease); }
.piece .callout { position: absolute; left: 0; top: 0; font-size: 1.45rem; line-height: 1; white-space: nowrap; color: var(--fg); pointer-events: none; opacity: 0; transition: opacity .5s var(--ease); }
.piece[data-state="live"] .callout { opacity: 1; }
.piece .hint { position: absolute; right: 0; top: 2%; text-align: right; font-size: 1.25rem; color: var(--fg-mute); pointer-events: none; }
.piece:not([data-state="live"]) .hint { visibility: hidden; }

@media (max-width: 859.98px) {
  /* Phone: copy, then the whole piece standing on the band, all inside the first 844px screen. */
  .hero { --band-h: 12svh; --piece-h: clamp(300px, 44svh, 460px); --shift: 15%; }  /* 15%: room for the callout column left of the turning piece (measured 2026-11-06) */
  .hero-actions { gap: 10px 18px; }
  .hero-actions .btn { padding: 0 18px; }
  .hero-grid { grid-template-columns: 1fr; align-items: start; padding-top: calc(var(--header-h) + 4px); gap: 8px; }
  .hero-copy { padding-bottom: 0; gap: 14px; }
  .piece .callout { font-size: 1.25rem; }
}

.section { padding-block: clamp(80px, 12vw, 160px); }
.section-head { display: grid; gap: 14px; margin-bottom: clamp(36px, 5vw, 64px); }

/* Work: the featured piece; its photo sits on a patch of sky, so it reads the same on either ground. */
.feature { display: grid; grid-template-columns: minmax(0, .9fr) minmax(0, 1.1fr); gap: clamp(28px, 5vw, 80px); align-items: center; }
.feature-media { position: relative; display: block; aspect-ratio: 4 / 5; border-radius: var(--radius); overflow: hidden; background: radial-gradient(ellipse 60% 14% at 50% 92%, rgba(24, 46, 40, .45), transparent 70%), var(--sky); text-decoration: none; }
.feature-media img { position: absolute; left: 50%; bottom: 6%; height: 86%; width: auto; max-width: none; transform: translateX(-50%); transition: transform .25s var(--ease); }
@media (hover: hover) and (pointer: fine) { .feature-media:hover img { transform: translateX(-50%) translateY(-6px); } }
.feature-body { display: grid; gap: 20px; }
/* More pieces: a grid of cards under the featured one (home) and under "More work" (piece pages). Posters only:
   one live 3D piece per page keeps a phone fast. Cards reuse the sky tile so the work reads the same everywhere. */
.work-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 260px), 1fr)); gap: clamp(28px, 3.5vw, 44px) clamp(20px, 3vw, 36px); margin-top: clamp(48px, 6vw, 80px); }
.section-head + .work-grid { margin-top: 0; }
.card { display: grid; gap: 8px; align-content: start; color: var(--fg); text-decoration: none; }
.card .feature-media { margin-bottom: 8px; }
.card-meta { color: var(--fg-mute); font-size: .95rem; }
@media (hover: hover) and (pointer: fine) {
  .card:hover .feature-media img { transform: translateX(-50%) translateY(-6px); }
  .card:hover h3 { text-decoration: underline dashed var(--line); text-underline-offset: .15em; text-decoration-thickness: 1.5px; }
}
.pager { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 4px 24px; margin-top: clamp(32px, 4vw, 56px); padding-top: 8px; border-top: 1.5px dashed var(--line); }
.specs { display: grid; grid-template-columns: max-content 1fr; gap: 10px 28px; margin: 4px 0 0; padding: 18px 0 0; border-top: 1.5px dashed var(--line); }
/* Labels read like a stamped maker's plate: the display face, small, tracked caps. The hand is for the 3D callouts and hint only. */
.specs dt, .field label { font: 800 .8rem/1.5 var(--font-display); font-stretch: 100%; text-transform: uppercase; letter-spacing: .08em; color: var(--fg-mute); }
.specs dt { padding-top: 3px; }
.specs dd { margin: 0; line-height: 1.5; padding-top: 2px; }
.note { color: var(--fg-mute); font-size: .95rem; }

.band { height: clamp(260px, 42vw, 520px); background: url("/assets/img/shoreline.webp") center 60% / cover; }
.about { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(28px, 5vw, 80px); align-items: start; }
.about p + p { margin-top: 16px; }

.contact { display: grid; grid-template-columns: minmax(0, .8fr) minmax(0, 1.2fr); gap: clamp(28px, 5vw, 80px); align-items: start; }
.contact-intro { display: grid; gap: 16px; align-content: start; }
.contact-intro .specs { margin: 6px 0 4px; }
.form { display: grid; gap: 20px; }
.field { display: grid; gap: 8px; }
.field input, .field select, .field textarea { width: 100%; font: 400 1rem/1.4 var(--font-body); color: var(--fg); background: var(--field-bg); border: 1.5px solid var(--field-line); border-radius: var(--radius); padding: 14px; min-height: 52px; }
.field textarea { min-height: 150px; resize: vertical; }
.field select { appearance: none; background-image: linear-gradient(45deg, transparent 50%, var(--fg) 50%), linear-gradient(135deg, var(--fg) 50%, transparent 50%); background-position: calc(100% - 22px) 50%, calc(100% - 16px) 50%; background-size: 6px 6px; background-repeat: no-repeat; padding-right: 44px; }
.field input:focus-visible, .field select:focus-visible, .field textarea:focus-visible { outline: 2px solid var(--ring); outline-offset: 1px; border-color: var(--ring); }
.field [aria-invalid="true"] { border-color: var(--danger); }
.form-row { display: flex; flex-wrap: wrap; align-items: center; gap: 14px 20px; }
.form-status { font-size: 1rem; min-height: 1.6em; }
.form-status[data-kind="error"] { color: var(--danger); }
.btn[disabled] { opacity: .7; cursor: progress; }
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

/* Footer: the painting's five colour fields as a stripe, then spruce. The one place the whole palette shows at once. */
.site-footer { position: relative; padding-block: 52px 48px; background: var(--spruce-deep); color: var(--cream-mute); font-size: .95rem; }
.site-footer::before { content: ""; position: absolute; inset: 0 0 auto 0; height: 12px; background: linear-gradient(90deg, var(--lake) 0 25%, var(--pine) 25% 50%, var(--granite) 50% 75%, var(--orange) 75%); }
.site-footer .wrap { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 12px 24px; }

.crumbs { font-size: .95rem; color: var(--fg-mute); }
.crumbs a { color: var(--fg-mute); display: inline-block; padding-block: 12px; }

@media (max-width: 859.98px) {
  .feature, .about, .contact { grid-template-columns: 1fr; }
  .feature-media { aspect-ratio: 1 / 1; }
  .site-footer { padding-bottom: calc(48px + var(--kit-tabbar-h, 62px)); }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition-duration: .01ms !important; animation-duration: .01ms !important; }
}
