/* Colour a Deity landing page (/colouringbook/).
   Mood: a well-thumbed picture book. Warm paper with a little grain, the paintings
   themselves filling the screen, soft edges and round corners, nothing hard or
   architectural. Fixed palette, no dark mode.
   Fonts are shared with the app in /colouringbook/app/fonts/: Onest for everything,
   Caveat for the small handwritten notes. */

@font-face { font-family: "Onest"; src: url("/colouringbook/app/fonts/onest-latin-400-normal.woff2") format("woff2");
  font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Onest"; src: url("/colouringbook/app/fonts/onest-latin-500-normal.woff2") format("woff2");
  font-weight: 500; font-style: normal; font-display: swap; }
@font-face { font-family: "Onest"; src: url("/colouringbook/app/fonts/onest-latin-600-normal.woff2") format("woff2");
  font-weight: 600; font-style: normal; font-display: swap; }
@font-face { font-family: "Bebas Neue"; src: url("/colouringbook/app/fonts/bebas-neue-latin-400-normal.woff2") format("woff2");
  font-weight: 400; font-style: normal; font-display: swap; }
@font-face { font-family: "Caveat"; src: url("/colouringbook/app/fonts/caveat-latin-500-normal.woff2") format("woff2");
  font-weight: 500; font-style: normal; font-display: swap; }

:root {
  --paper: #F3E9D6;
  --paper-2: #EADDC3;
  --card: #FBF5E9;
  --ink: #33291F;
  --muted: #7C6B56;
  --line: #D9C9AA;
  --red: #A6392F;
  --red-deep: #7E2A22;
  --gold: #D4A348;
  --green: #4E8A5E;
  --navy: #243352;
  --navy-deep: #1B2740;
  --night-ink: #F3E9D6;
  --hand: "Caveat", "Segoe Print", "Bradley Hand", cursive;
  --display: "Bebas Neue", "Oswald", "Arial Narrow", Impact, sans-serif;
  --r: 22px;
  --grain: url("data:image/svg+xml;utf8,<svg xmlns='http://www.w3.org/2000/svg' width='220' height='220'><filter id='n'><feTurbulence type='fractalNoise' baseFrequency='.85' numOctaves='3' stitchTiles='stitch'/><feColorMatrix values='0 0 0 0 0  0 0 0 0 0  0 0 0 0 0  0 0 0 .55 0'/></filter><rect width='100%' height='100%' filter='url(%23n)'/></svg>");
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--paper); color: var(--ink);
  font-family: "Onest", system-ui, -apple-system, "Segoe UI", sans-serif;
  font-size: 18px; line-height: 1.6; overflow-x: hidden;
}
/* paper grain over everything */
body::after {
  content: ""; position: fixed; inset: 0; pointer-events: none; z-index: 50;
  background: var(--grain); opacity: .32; mix-blend-mode: multiply;
}
img { max-width: 100%; height: auto; display: block; }
a { color: var(--red); }
a:hover { color: var(--ink); }
h1, h2, h3 { margin: 0; font-family: var(--display); font-weight: 400; text-transform: uppercase; letter-spacing: .01em; }
h2 { font-size: clamp(44px, 5.6vw, 72px); line-height: .95; }
h3 { font-size: 30px; line-height: 1.05; letter-spacing: .04em; }
p { margin: 0; }

.t-wrap { max-width: 1160px; margin: 0 auto; padding: 0 24px; position: relative; }
.t-eyebrow {
  font-family: var(--hand); font-size: 26px; line-height: 1; color: var(--red);
  transform: rotate(-1.5deg); transform-origin: left bottom; display: inline-block;
}
.t-fine { font-size: 15px; color: var(--muted); }
.t-head { display: flex; flex-direction: column; gap: 14px; max-width: 620px; }
.t-head p:last-child:not(.t-eyebrow) { color: var(--muted); font-size: 19px; }

.t-btn {
  display: inline-block; padding: 16px 30px; border-radius: 999px;
  background: var(--red); color: #FFF7EC; font-weight: 600; text-decoration: none;
  box-shadow: 0 10px 24px -12px rgba(126, 42, 34, .7);
  transition: transform .15s ease, background .15s ease;
}
.t-btn:hover { background: var(--red-deep); color: #FFF7EC; transform: translateY(-1px); }
.t-btn-quiet { background: transparent; color: var(--red); box-shadow: inset 0 0 0 2px var(--red); }
.t-btn-quiet:hover { background: var(--red); color: #FFF7EC; }
.t-soon {
  display: inline-block; font-family: var(--hand); font-size: 24px; color: var(--muted);
  transform: rotate(-2deg);
}

/* soft wavy edges between bands */
.t-wave { display: block; width: 100%; height: 56px; }
.t-wave-paper { fill: var(--paper); }
.t-wave-navy { fill: var(--navy); }
.t-wave-paper2 { fill: var(--paper-2); }

/* ---------- hero: copy on paper, the painting bleeding off the right ---------- */
.t-hero {
  position: relative; min-height: 100svh; display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: stretch;
  background: var(--paper);
}
.t-hero-copy {
  display: flex; flex-direction: column; justify-content: center; gap: 22px;
  padding: clamp(40px, 7vw, 96px) clamp(24px, 6vw, 80px) clamp(40px, 7vw, 96px) max(24px, calc((100vw - 1160px) / 2 + 24px));
  position: relative; z-index: 2;
}
.t-hero h1 { font-size: clamp(72px, 10vw, 136px); line-height: .9; }
.t-lead { font-size: clamp(19px, 1.6vw, 22px); color: var(--muted); max-width: 440px; text-wrap: balance; }
.t-meta { font-size: 15px; color: var(--muted); }
.t-hero-art { position: relative; overflow: hidden; }
.t-hero-art img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 20%;
}
/* feather the painting into the paper on its left edge */
.t-hero-art::before {
  content: ""; position: absolute; inset: 0 auto 0 0; width: 58%; z-index: 1;
  background: linear-gradient(90deg, var(--paper) 0%, var(--paper) 22%, rgba(243, 233, 214, .97) 32%,
    rgba(243, 233, 214, .88) 44%, rgba(243, 233, 214, .7) 58%, rgba(243, 233, 214, .45) 72%,
    rgba(243, 233, 214, .2) 86%, rgba(243, 233, 214, 0) 100%);
}
.t-hero-art::after { content: none; }

/* ---------- how: a line-art page becoming a painting ---------- */
.t-how { padding: 40px 24px 96px; display: grid; grid-template-columns: 1fr 1fr; gap: 56px; align-items: center; }
.t-how-art { position: relative; height: 560px; }
.t-how-art img {
  position: absolute; width: 56%; border-radius: var(--r); box-shadow: 0 24px 48px -26px rgba(51, 41, 31, .55);
}
.t-how-art img:first-child { left: 0; top: 0; transform: rotate(-4deg); }
.t-how-art img:last-child { right: 0; bottom: 0; transform: rotate(3deg); }
.t-how-copy { display: flex; flex-direction: column; gap: 18px; }
.t-how-copy > p { color: var(--muted); font-size: 19px; }

/* ---------- gallery: the paintings on paper ---------- */
.t-gallery { background: var(--paper-2); padding: 72px 0 96px; }
.t-gallery .t-head { margin-bottom: 40px; }
.t-grid {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 36px 28px;
}
.t-piece { margin: 0; }
.t-piece img {
  border-radius: var(--r); box-shadow: 0 18px 36px -22px rgba(51, 41, 31, .6);
  transition: transform .25s ease;
}
.t-piece:hover img { transform: rotate(-1.2deg) translateY(-3px); }
.t-piece:nth-child(even):hover img { transform: rotate(1.2deg) translateY(-3px); }
.t-label { padding: 14px 4px 0; display: flex; flex-direction: column; gap: 2px; }
.t-label strong { font-size: 18px; }
.t-label span { font-size: 15px; color: var(--muted); line-height: 1.45; }

/* ---------- meaning: a navy page, like the mantra pages in the book ---------- */
.t-meaning { background: var(--navy); color: var(--night-ink); position: relative; overflow: hidden; }
.t-meaning > .t-wave { position: absolute; top: 0; left: 0; z-index: 3; }
/* the navy laps up over the bottom of the hero painting */
.t-hero + .t-meaning { margin-top: -56px; background: transparent; }
.t-hero + .t-meaning::before { content: ""; position: absolute; inset: 54px 0 0 0; background: var(--navy); z-index: 0; }
.t-hero + .t-meaning > .t-wave { transform: scaleY(-1); }
.t-hero + .t-meaning .t-wave-paper { fill: var(--navy); }
.t-hero + .t-meaning .t-meaning-grid { position: relative; z-index: 1; }
.t-meaning-grid {
  display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1fr); align-items: stretch; min-height: 92svh;
}
.t-meaning-copy {
  display: flex; flex-direction: column; justify-content: center; gap: 22px; z-index: 2; position: relative;
  padding: clamp(48px, 8vw, 110px) clamp(24px, 6vw, 80px) clamp(48px, 8vw, 110px) max(24px, calc((100vw - 1160px) / 2 + 24px));
}
.t-meaning .t-eyebrow { color: var(--gold); }
.t-meaning h2 { color: #FFF7EC; }
.t-meaning-copy > p { color: rgba(243, 233, 214, .82); font-size: 19px; max-width: 480px; }
.t-meaning-art { position: relative; overflow: hidden; }
/* the line-art and painted cards, sitting on the navy */
.t-meaning-art.t-how-art { height: auto; min-height: 640px; overflow: visible; padding: 120px 24px 96px 0; }
.t-meaning-art.t-how-art img { position: absolute; inset: auto; width: 48%; height: auto; object-fit: unset;
  border-radius: var(--r); box-shadow: 0 30px 60px -28px rgba(0, 0, 0, .7); }
.t-meaning-art.t-how-art img:first-child { left: 2%; top: 120px; transform: rotate(-4deg); }
.t-meaning-art.t-how-art img:last-child { right: 8%; bottom: 96px; transform: rotate(3deg); }
.t-meaning-art.t-how-art::before, .t-meaning-art.t-how-art::after { display: none; }
.t-meaning-art img {
  position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; object-position: 50% 15%;
}
.t-meaning-art::before {
  content: ""; position: absolute; inset: 0 auto 0 0; width: 55%; z-index: 1;
  background: linear-gradient(90deg, var(--navy) 0%, var(--navy) 10%, rgba(36, 51, 82, .96) 25%,
    rgba(36, 51, 82, .8) 45%, rgba(36, 51, 82, .5) 65%, rgba(36, 51, 82, .2) 85%, rgba(36, 51, 82, 0) 100%);
}
.t-meaning-art::after {
  content: ""; position: absolute; inset: 0; z-index: 1;
  background:
    linear-gradient(0deg, rgba(36, 51, 82, .6), rgba(36, 51, 82, 0) 35%),
    linear-gradient(180deg, var(--navy) 0%, rgba(36, 51, 82, .85) 8%, rgba(36, 51, 82, .4) 22%, rgba(36, 51, 82, 0) 40%);
}
.t-swatches { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 22px 20px; max-width: 520px; margin-top: 12px; justify-content: start; }
.t-swatch { display: flex; flex-direction: column; gap: 8px; max-width: 150px; }
.t-dab {
  width: 54px; height: 50px; background: var(--c);
  border-radius: 58% 42% 55% 45% / 48% 55% 45% 52%;
  box-shadow: inset -6px -8px 0 rgba(0, 0, 0, .14), inset 6px 6px 0 rgba(255, 255, 255, .18);
}
.t-swatch:nth-child(2n) .t-dab { border-radius: 45% 55% 42% 58% / 55% 45% 55% 45%; transform: rotate(8deg); }
.t-swatch strong { font-size: 17px; color: #FFF7EC; }
.t-swatch p { font-size: 14.5px; line-height: 1.4; color: rgba(243, 233, 214, .78); }
.t-swatch .t-fine { color: rgba(243, 233, 214, .5); font-size: 13px; }

/* ---------- on paper ---------- */
.t-paper { padding: 80px 0 100px; }
.t-paper .t-head { margin-bottom: 40px; }
.t-cards { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; max-width: 820px; }
.t-card {
  background: var(--card); border-radius: var(--r); padding: 30px 30px 32px;
  display: flex; flex-direction: column; gap: 14px;
  box-shadow: 0 18px 40px -28px rgba(51, 41, 31, .5);
}
.t-card p { color: var(--muted); font-size: 17px; }
.t-card .t-btn, .t-card .t-soon { margin-top: auto; align-self: flex-start; }
.t-card-btns { margin-top: auto; display: flex; flex-wrap: wrap; gap: 12px; }
.t-card-btns .t-btn, .t-card-btns .t-soon { margin-top: 0; }
.t-card-note { background: transparent; box-shadow: none; border: 2px dashed var(--line); }
.t-card-note p { font-size: 16px; }

/* ---------- end ---------- */
.t-end { background: var(--paper-2); padding: 88px 0 56px; text-align: center; }
.t-end-inner { display: flex; flex-direction: column; align-items: center; gap: 18px; }
.t-end p { color: var(--muted); }
.t-small { font-size: 15px; }
.t-foot { font-size: 14px; color: var(--muted); margin-top: 40px; }

/* ---------- small screens ---------- */
@media (max-width: 900px) {
  .t-hero { grid-template-columns: 1fr; min-height: 0; }
  .t-hero-art { height: 62svh; min-height: 380px; order: -1; }
  .t-hero-art img { object-position: 50% 12%; }
  .t-hero-art::before { display: none; }
  .t-hero-art::after { content: ""; position: absolute; inset: auto 0 0 0; height: 30%; z-index: 1;
    background: linear-gradient(0deg, var(--paper), rgba(243, 233, 214, 0)); }
  .t-hero-copy { padding: 8px 24px 88px; }
  .t-hero h1 { font-size: clamp(60px, 17vw, 96px); }
  .t-how { grid-template-columns: 1fr; gap: 36px; padding-top: 16px; }
  .t-how-art { height: 72vw; max-height: 480px; max-width: 480px; margin: 0 auto; width: 100%; }
  .t-grid { grid-template-columns: repeat(2, 1fr); gap: 28px 18px; }
  .t-meaning-grid { grid-template-columns: 1fr; min-height: 0; }
  .t-meaning-art { height: 58svh; min-height: 360px; order: -1; }
  .t-meaning-art::before { display: none; }
  .t-meaning-art::after { background:
    linear-gradient(0deg, var(--navy), rgba(36, 51, 82, 0) 40%),
    linear-gradient(180deg, var(--navy) 0%, rgba(36, 51, 82, .7) 10%, rgba(36, 51, 82, 0) 30%); }
  .t-meaning-copy { padding: 0 24px 64px; }
  .t-meaning-copy:first-child { padding-top: 96px; }
  .t-meaning-art.t-how-art { order: 1; min-height: 0; height: 90vw; max-height: 520px; max-width: 420px;
    margin: 0 auto 72px; width: calc(100% - 48px); padding: 0; }
  .t-meaning-art.t-how-art img { width: 58%; }
  .t-meaning-art.t-how-art img:first-child { left: 0; top: 0; }
  .t-meaning-art.t-how-art img:last-child { right: 0; bottom: 0; }
  .t-swatches { grid-template-columns: repeat(3, 1fr); }
  .t-cards { grid-template-columns: 1fr; }
}
@media (max-width: 480px) {
  body { font-size: 17px; }
  .t-swatches { grid-template-columns: repeat(2, 1fr); }
  .t-label strong { font-size: 16px; }
  .t-label span { font-size: 14px; }
}
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .t-piece img, .t-btn { transition: none; }
}
