/* Cafune — cafunecoloring.com
   Layout idea: a cozy craft table. Pages and books rest on cream paper,
   one live coloring sheet leads every visit, crayons are the controls. */
@font-face { font-family: "Bricolage Grotesque"; src: url("../fonts/bricolage.woff2") format("woff2"); font-weight: 200 800; font-stretch: 75% 100%; font-display: swap; }
@font-face { font-family: "Figtree"; src: url("../fonts/figtree.woff2") format("woff2"); font-weight: 300 900; font-style: normal; font-display: swap; }
@font-face { font-family: "Figtree"; src: url("../fonts/figtree-italic.woff2") format("woff2"); font-weight: 300 900; font-style: italic; font-display: swap; }

:root {
  --cream: #FAF3E8;      /* the table: brand background */
  --paper: #FFFDF8;      /* printed sheets */
  --ink: #3B3230;        /* line-art brown-black */
  --cranberry: #B23A3A;  /* primary action, brand red */
  --pine: #2E5E48;       /* brand green, deep bands */
  --mint: #DDF0E7;       /* logo background, soft panels */
  --honey: #F6CF8E;      /* the bear's fur, highlights */
  --blush: #F4A6A0;
  --sky: #CFE3EF;
  --muted: #6F635B;
  --line: #E7DCCB;
  --font-display: "Bricolage Grotesque", "Arial Rounded MT Bold", "Trebuchet MS", sans-serif;
  --font-body: "Figtree", "Segoe UI", "Helvetica Neue", Arial, sans-serif;
  --radius-sheet: 6px;
  --radius-pill: 999px;
  --shadow-sheet: 0 1px 0 rgba(74, 59, 54, .06), 0 18px 34px -18px rgba(74, 59, 54, .45);
  --wrap: 1180px;
  color-scheme: light;
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }
body {
  margin: 0; background: var(--cream); color: var(--ink);
  font-family: var(--font-body); font-size: 1.125rem; line-height: 1.6;
  font-feature-settings: "ss01";
  -webkit-font-smoothing: antialiased;
}
img, canvas, svg { max-width: 100%; display: block; }
img { height: auto; }
a { color: inherit; }
p { margin: 0 0 1em; }
h1, h2, h3 { font-family: var(--font-display); font-weight: 800; line-height: 1.02; letter-spacing: -0.025em; margin: 0; text-wrap: balance; font-stretch: 92%; }
h1 { font-size: clamp(2.6rem, 6.2vw, 5rem); }
h2 { font-size: clamp(2rem, 4.2vw, 3.3rem); }
h3 { font-size: 1.45rem; letter-spacing: -0.015em; line-height: 1.15; }
.lede { font-size: clamp(1.15rem, 1.6vw, 1.3rem); color: var(--muted); max-width: 34em; }
:focus-visible { outline: 3px solid var(--cranberry); outline-offset: 3px; border-radius: 4px; }
.wrap { width: min(var(--wrap), 100% - 40px); margin-inline: auto; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: 12px; top: -60px; background: var(--ink); color: var(--paper); padding: 10px 14px; border-radius: 8px; z-index: 50; }
.skip:focus { top: 12px; }

/* ---------- buttons ---------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: .5em;
  font: 700 1.02rem/1 var(--font-body); text-decoration: none; cursor: pointer;
  padding: 1em 1.5em; border-radius: var(--radius-pill); border: 2px solid var(--ink);
  background: var(--cranberry); border-color: var(--cranberry); color: var(--paper);
  transition: transform .15s ease, background-color .15s ease, box-shadow .15s ease;
  box-shadow: 0 3px 0 #7d2626;
}
.btn:hover { transform: translateY(-1px); box-shadow: 0 4px 0 #7d2626; }
.btn:active { transform: translateY(2px); box-shadow: 0 1px 0 #7d2626; }
.btn-ghost { background: transparent; color: var(--ink); border-color: var(--ink); box-shadow: 0 3px 0 var(--ink); }
.btn-ghost:hover { background: var(--paper); box-shadow: 0 4px 0 var(--ink); }
.btn-ghost:active { box-shadow: 0 1px 0 var(--ink); }
.btn-pine { background: var(--pine); border-color: var(--pine); box-shadow: 0 3px 0 #1c3b2d; }
.btn-pine:hover { box-shadow: 0 4px 0 #1c3b2d; }
.btn-light { background: var(--paper); border-color: var(--paper); color: var(--pine); box-shadow: 0 3px 0 rgba(0,0,0,.25); }
.btn-small { padding: .7em 1.1em; font-size: .95rem; }
.btn[aria-disabled="true"] { opacity: .55; pointer-events: none; box-shadow: none; }
.link { font-weight: 700; color: var(--cranberry); text-underline-offset: .2em; text-decoration-thickness: 2px; }

/* ---------- header ---------- */
.top { position: sticky; top: 0; z-index: 20; background: color-mix(in srgb, var(--cream) 92%, transparent); backdrop-filter: blur(8px); border-bottom: 1px solid transparent; transition: border-color .2s; }
.top.scrolled { border-bottom-color: var(--line); }
.top .wrap { display: flex; align-items: center; gap: 28px; height: 76px; }
.brand { display: flex; align-items: center; gap: 10px; text-decoration: none; margin-right: auto; }
.brand img { width: 46px; height: 46px; }
.brand span { font: 800 1.7rem/1 var(--font-display); letter-spacing: -0.04em; color: var(--cranberry); font-stretch: 88%; }
.nav { display: flex; gap: 26px; }
.nav a { text-decoration: none; font-weight: 600; font-size: 1rem; padding: 6px 0; border-bottom: 2.5px solid transparent; }
.nav a:hover { border-bottom-color: var(--honey); }
.nav a[aria-current="page"] { border-bottom-color: var(--cranberry); }
.menu-btn { display: none; background: none; border: 2px solid var(--ink); border-radius: var(--radius-pill); font: 700 .95rem var(--font-body); padding: .5em 1em; color: var(--ink); cursor: pointer; }
@media (max-width: 860px) {
  .top .wrap { gap: 12px; height: 66px; }
  .brand img { width: 40px; height: 40px; }
  .brand span { font-size: 1.5rem; }
  .menu-btn { display: inline-block; }
  .top .etsy-top { display: none; }
  .nav { display: none; position: absolute; left: 0; right: 0; top: 100%; flex-direction: column; gap: 0; background: var(--cream); border-bottom: 1px solid var(--line); padding: 8px 20px 18px; }
  .nav.open { display: flex; }
  .nav a { padding: 14px 0; font-size: 1.15rem; border-bottom: 1px solid var(--line); }
  .nav a[aria-current="page"] { color: var(--cranberry); border-bottom-color: var(--line); }
}

/* ---------- hero ---------- */
.hero { padding: clamp(28px, 5vw, 64px) 0 clamp(40px, 6vw, 80px); }
.hero .wrap { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(28px, 5vw, 72px); align-items: center; }
.hero h1 { max-width: 9.5em; }
.hero .lede { margin: 22px 0 30px; }
.hero-actions { display: flex; flex-wrap: wrap; gap: 14px; }
.facts { display: flex; flex-wrap: wrap; gap: 10px 22px; list-style: none; padding: 0; margin: 30px 0 0; font-size: .98rem; font-weight: 600; }
.facts li { display: flex; align-items: center; gap: 8px; }
.facts svg { width: 22px; height: 22px; flex: none; }
.easel { position: relative; }
.sheet {
  background: var(--paper); border-radius: var(--radius-sheet); box-shadow: var(--shadow-sheet);
  padding: clamp(14px, 2.2vw, 26px);
}
.easel .sheet { transform: rotate(-1.6deg); max-width: 560px; margin-inline: auto; }
.easel canvas { width: 100%; height: auto; aspect-ratio: 1000 / 1106; cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='40' height='40' viewBox='0 0 40 40'%3E%3Cg transform='rotate(45 20 20)'%3E%3Cpath d='M16 4h8v24h-8z' fill='%23B23A3A' stroke='%233B3230' stroke-width='2'/%3E%3Cpath d='M16 28h8l-4 9z' fill='%23F6CF8E' stroke='%233B3230' stroke-width='2' stroke-linejoin='round'/%3E%3Cpath d='M16 10h8M16 22h8' stroke='%23FFFDF8' stroke-width='2'/%3E%3C/g%3E%3C/svg%3E") 6 34, crosshair; touch-action: pan-y; border-radius: 2px; }
.easel-note { display: flex; align-items: center; justify-content: center; gap: 10px; margin: 22px auto 0; font-weight: 600; color: var(--muted); text-align: center; min-height: 2.6em; }
.easel-note svg { width: 34px; height: 34px; flex: none; color: var(--cranberry); }
.easel-note a { color: var(--cranberry); }
.easel-reset { position: absolute; right: 8px; top: -6px; z-index: 2; }
.easel-reset[hidden] { display: none; }
.tag-free { position: absolute; left: -6px; top: 18px; transform: rotate(-8deg); background: var(--honey); color: var(--ink); font: 800 .95rem/1.1 var(--font-display); padding: 10px 14px; border-radius: 6px; box-shadow: 0 6px 14px -8px rgba(74,59,54,.6); z-index: 2; max-width: 9.5em; text-align: center; }
@media (max-width: 860px) {
  .hero .wrap { grid-template-columns: 1fr; }
  .easel .sheet { max-width: 440px; }
  .tag-free { left: 0; top: -8px; }
}

/* ---------- section scaffolding ---------- */
.section { padding: clamp(56px, 8vw, 110px) 0; }
.section-head { display: grid; gap: 14px; margin-bottom: clamp(30px, 4vw, 52px); max-width: 44rem; }
.section-head p { margin: 0; color: var(--muted); font-size: 1.15rem; }

/* ---------- the word ---------- */
.word { background: var(--paper); border-block: 1px solid var(--line); }
.word .wrap { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: clamp(28px, 5vw, 70px); align-items: center; }
.entry-head { display: flex; flex-wrap: wrap; align-items: baseline; gap: 6px 22px; }
.entry-word { font: 800 clamp(3.6rem, 9vw, 7rem)/0.9 var(--font-display); letter-spacing: -0.045em; color: var(--cranberry); font-stretch: 85%; }
.entry-pron { font-size: 1.15rem; color: var(--muted); }
.entry-pron i { font-style: italic; }
.entry-def { font-size: clamp(1.35rem, 2.4vw, 1.9rem); line-height: 1.4; margin: 22px 0 18px; max-width: 26em; }
.entry-def b { font-weight: 700; }
.entry-use { font: 700 clamp(1.2rem, 2vw, 1.5rem)/1.3 var(--font-display); color: var(--pine); letter-spacing: -0.01em; margin: 0; }
.word figure { margin: 0; }
.word figure .sheet { transform: rotate(2deg); max-width: 330px; margin-left: auto; }
.word figcaption { font-size: .95rem; color: var(--muted); margin-top: 16px; text-align: right; }
@media (max-width: 760px) { .word .wrap { grid-template-columns: 1fr; } .word figure .sheet { margin: 0 auto; max-width: 260px; } .word figcaption { text-align: center; } }

/* ---------- products ---------- */
.products { display: grid; grid-template-columns: repeat(12, minmax(0, 1fr)); gap: clamp(30px, 3.6vw, 52px) clamp(20px, 2.4vw, 32px); }
.product { grid-column: span 3; display: flex; flex-direction: column; }
.product.featured { grid-column: 1 / -1; display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 5fr); gap: clamp(22px, 4vw, 60px); align-items: center; padding-bottom: clamp(10px, 2vw, 24px); border-bottom: 3px dashed var(--line); }
.product .shot { display: block; border-radius: 10px; overflow: hidden; background: var(--cream); }
.product .shot img { width: 100%; aspect-ratio: 4 / 3; object-fit: cover; transition: transform .35s ease; }
.product .shot:hover img { transform: scale(1.025); }
.product-body { display: flex; flex-direction: column; gap: 8px; padding-top: 14px; flex: 1; }
.product.featured .product-body { padding-top: 0; gap: 14px; }
.product h3 a { text-decoration: none; }
.product.featured h3 { font-size: clamp(2rem, 3.4vw, 3rem); }
.product p { margin: 0; color: var(--muted); font-size: 1.02rem; }
.product.featured p { font-size: 1.2rem; }
.product .meta { display: flex; flex-wrap: wrap; gap: 6px; list-style: none; padding: 0; margin: 4px 0 0; }
.product .meta li.hl { background: var(--honey); border-color: var(--honey); }
.product .meta li { font-size: .85rem; font-weight: 700; padding: 3px 10px; border-radius: var(--radius-pill); background: var(--paper); border: 1px solid var(--line); }
.buy { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 12px; margin-top: auto; padding-top: 12px; }
.product.featured .buy { margin-top: 10px; justify-content: flex-start; gap: 22px; }
.product.featured .price { font-size: 2rem; }
.price { font: 800 1.45rem/1 var(--font-display); letter-spacing: -0.02em; font-variant-numeric: tabular-nums; }
.price small { font: 600 .85rem var(--font-body); color: var(--muted); margin-left: 6px; letter-spacing: 0; }
.save { display: inline-block; font: 800 .85rem/1 var(--font-body); background: var(--honey); padding: 5px 9px; border-radius: 5px; transform: rotate(-3deg); margin-left: 8px; vertical-align: 3px; }
.badge { align-self: flex-start; font: 800 .9rem/1 var(--font-body); color: var(--paper); background: var(--cranberry); padding: 7px 12px; border-radius: 5px; transform: rotate(-2deg); }
@media (max-width: 1100px) { .product { grid-column: span 6; } }
@media (max-width: 760px) {
  .products { grid-template-columns: 1fr; }
  .product, .product.featured { grid-column: auto; }
  .product.featured { grid-template-columns: 1fr; }
}

/* filter chips (shop) */
.chips { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 34px; padding: 0; list-style: none; }
.chip { font: 700 1rem var(--font-body); padding: .6em 1.1em; border-radius: var(--radius-pill); border: 2px solid var(--ink); background: transparent; color: var(--ink); cursor: pointer; }
.chip[aria-pressed="true"] { background: var(--ink); color: var(--paper); }
.product[hidden] { display: none; }

/* ---------- color online teaser ---------- */
.band { background: var(--pine); color: var(--paper); }
.band .lede { color: #d6e6dc; }
.studio-tease .wrap { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(30px, 5vw, 70px); align-items: center; }
.studio-tease h2 { margin-bottom: 18px; }
.studio-tease .lede { margin-bottom: 30px; }
.fan { position: relative; height: clamp(300px, 34vw, 420px); }
.fan .sheet { position: absolute; width: 44%; padding: 10px; }
.fan .sheet:nth-child(1) { left: 4%; top: 12%; transform: rotate(-9deg); }
.fan .sheet:nth-child(2) { left: 28%; top: 2%; transform: rotate(1deg); z-index: 2; }
.fan .sheet:nth-child(3) { left: 52%; top: 14%; transform: rotate(8deg); }
.crayon-row { position: absolute; left: 6%; right: 6%; bottom: 0; display: flex; justify-content: center; gap: 8px; z-index: 3; }
@media (max-width: 860px) { .studio-tease .wrap { grid-template-columns: 1fr; } }

/* crayons (used as decoration and as controls) */
.crayon {
  --c: var(--cranberry);
  position: relative; width: 30px; height: 96px; flex: none; border: 0; padding: 0; cursor: pointer;
  background: var(--c); border-radius: 3px 3px 4px 4px;
  clip-path: polygon(35% 0, 65% 0, 100% 20%, 100% 100%, 0 100%, 0 20%);
  transition: transform .15s ease;
}
.crayon::before { content: ""; position: absolute; left: 0; right: 0; top: 34%; height: 46%; background: linear-gradient(to bottom, rgba(255,255,255,.0) 0 14%, rgba(255,255,255,.55) 14% 18%, rgba(255,255,255,0) 18% 82%, rgba(255,255,255,.55) 82% 86%, rgba(255,255,255,0) 86%), color-mix(in srgb, var(--c) 82%, #000); }
.crayon-row .crayon { width: 26px; height: 84px; }
.crayon-row .crayon:nth-child(odd) { transform: translateY(10px); }

/* ---------- steps ---------- */
.steps { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: clamp(22px, 3vw, 44px); list-style: none; padding: 0; margin: 0; counter-reset: step; }
.steps li { counter-increment: step; display: grid; gap: 10px; align-content: start; padding-top: 18px; border-top: 3px dashed var(--line); }
.steps li::before { content: counter(step); font: 800 4rem/0.9 var(--font-display); color: var(--cranberry); letter-spacing: -0.05em; }
.steps li:nth-child(2)::before { color: var(--pine); }
.steps p { color: var(--muted); margin: 0; }
@media (max-width: 760px) { .steps { grid-template-columns: 1fr; } }

/* ---------- friends ---------- */
.friends { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: clamp(18px, 2.4vw, 32px); list-style: none; padding: 0; margin: 0; }
.friend { display: grid; gap: 14px; justify-items: center; text-align: center; }
.friend .disc { --bg: var(--honey); width: 100%; aspect-ratio: 1; border-radius: 50%; background: var(--bg); display: grid; place-items: center; overflow: hidden; }
.friend .disc img { width: 70%; height: 80%; object-fit: contain; transform: translateY(6%); }
.friend h3 { font-size: 1.3rem; }
.friend p { margin: 0; color: var(--muted); font-size: 1rem; max-width: 15em; }
@media (max-width: 760px) { .friends { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ---------- paperbacks ---------- */
.paperbacks .wrap { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(30px, 5vw, 70px); align-items: center; }
.books { display: flex; gap: clamp(18px, 3vw, 34px); justify-content: center; align-items: flex-end; }
.book { width: min(46%, 250px); }
.book img { width: 100%; height: auto; border-radius: 3px 8px 8px 3px; box-shadow: inset 6px 0 8px -6px rgba(0,0,0,.35), var(--shadow-sheet); }
.book:first-child { transform: rotate(-3deg); }
.book:last-child { transform: rotate(2.5deg) translateY(-10px); }
.status { display: inline-flex; align-items: center; gap: 8px; font-weight: 700; font-size: .95rem; background: var(--mint); color: var(--pine); padding: 6px 12px; border-radius: var(--radius-pill); margin-bottom: 18px; }
.status::before { content: ""; width: 9px; height: 9px; border-radius: 50%; background: var(--pine); }
.spec { list-style: none; padding: 0; margin: 22px 0 28px; display: grid; gap: 8px; }
.spec li { display: flex; gap: 10px; }
.spec li::before { content: ""; flex: none; width: 10px; height: 10px; margin-top: .55em; border-radius: 2px; background: var(--honey); transform: rotate(45deg); }
@media (max-width: 860px) { .paperbacks .wrap { grid-template-columns: 1fr; } .paperbacks .books { order: -1; } }

/* ---------- free page (tear-off) ---------- */
.tear { position: relative; background: var(--pine); color: var(--paper); margin-top: 26px; }
.tear::before { /* perforation */
  content: ""; position: absolute; left: 0; right: 0; top: -9px; height: 18px;
  background: radial-gradient(circle at 9px 9px, var(--cream) 5px, transparent 5.5px) 0 0 / 22px 18px repeat-x;
}
.tear .scissors { position: absolute; top: -17px; left: clamp(16px, 4vw, 48px); width: 34px; height: 34px; color: var(--pine); background: var(--cream); border-radius: 50%; padding: 4px; }
.tear .wrap { display: grid; grid-template-columns: minmax(0, 4fr) minmax(0, 6fr); gap: clamp(30px, 6vw, 80px); align-items: center; padding-block: clamp(60px, 8vw, 100px); }
.tear .sheet { max-width: 330px; transform: rotate(-3deg); margin-inline: auto; padding: 12px; }
.tear .lede { color: #d6e6dc; margin: 16px 0 26px; }
.form { display: flex; flex-wrap: wrap; gap: 12px; max-width: 34rem; }
.form label { flex-basis: 100%; font-weight: 700; font-size: 1rem; }
.form input[type="email"] { flex: 1 1 15rem; min-width: 0; font: 500 1.1rem var(--font-body); padding: .9em 1.1em; border-radius: var(--radius-pill); border: 2px solid var(--paper); background: var(--paper); color: var(--ink); }
.form input[type="email"]:focus-visible { outline-color: var(--honey); }
.form .hp { position: absolute; left: -5000px; }
.form-note { font-size: .92rem; color: #c9dccf; margin-top: 12px; }
.form-msg { margin-top: 14px; font-weight: 700; min-height: 1.6em; }
.form-msg .btn { margin: 10px 10px 0 0; }
.form-msg.error { color: var(--honey); }
@media (max-width: 760px) { .tear .wrap { grid-template-columns: 1fr; } .tear .sheet { max-width: 240px; } }

/* ---------- footer ---------- */
.foot { padding: 64px 0 40px; font-size: 1rem; }
.foot .wrap { display: grid; grid-template-columns: minmax(0, 2fr) repeat(3, minmax(0, 1fr)); gap: 30px; }
.foot h2 { font: 800 1.05rem var(--font-display); letter-spacing: 0; margin-bottom: 10px; }
.foot ul { list-style: none; padding: 0; margin: 0; display: grid; gap: 6px; }
.foot a { text-decoration: none; }
.foot a:hover { text-decoration: underline; text-underline-offset: .2em; }
.foot .brand { margin-bottom: 12px; }
.foot p { color: var(--muted); max-width: 22em; }
.small-print { grid-column: 1 / -1; border-top: 1px solid var(--line); padding-top: 22px; margin-top: 10px; color: var(--muted); font-size: .9rem; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; }
@media (max-width: 760px) { .foot .wrap { grid-template-columns: 1fr 1fr; } .foot .wrap > div:first-child { grid-column: 1 / -1; } }

/* ---------- inner pages ---------- */
.page-head { padding: clamp(36px, 6vw, 80px) 0 clamp(24px, 3vw, 40px); }
.page-head .lede { margin-top: 18px; }
.faq { display: grid; gap: 0; max-width: 50rem; }
.faq details { border-top: 2px dashed var(--line); padding: 18px 0; }
.faq details:last-child { border-bottom: 2px dashed var(--line); }
.faq summary { font: 800 1.25rem/1.3 var(--font-display); cursor: pointer; list-style: none; display: flex; justify-content: space-between; gap: 16px; letter-spacing: -0.01em; }
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 1.6rem; line-height: 1; color: var(--cranberry); transition: transform .2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details p { margin: 12px 0 0; color: var(--muted); max-width: 40em; }

.prose { max-width: 40rem; }
.prose h2 { font-size: clamp(1.7rem, 3vw, 2.3rem); margin: 56px 0 16px; }
.prose p { font-size: 1.15rem; }
.about-hero { display: grid; grid-template-columns: minmax(0, 6fr) minmax(0, 4fr); gap: clamp(30px, 5vw, 70px); align-items: center; }
.about-hero .sheet { transform: rotate(2.5deg); max-width: 380px; margin-inline: auto; }
.about-grid { display: grid; grid-template-columns: minmax(0, 7fr) minmax(0, 4fr); gap: clamp(30px, 5vw, 70px); }
.about-aside { align-self: start; position: sticky; top: 100px; display: grid; gap: 22px; }
.about-aside img { border-radius: 10px; }
@media (max-width: 860px) { .about-hero, .about-grid { grid-template-columns: 1fr; } .about-aside { position: static; } }

.free-layout { display: grid; grid-template-columns: minmax(0, 5fr) minmax(0, 6fr); gap: clamp(30px, 6vw, 80px); align-items: start; }
.free-layout .sheet { transform: rotate(-2deg); max-width: 460px; margin-inline: auto; }
.free-panel { background: var(--pine); color: var(--paper); border-radius: 18px; padding: clamp(24px, 4vw, 44px); }
.free-panel .lede { color: #d6e6dc; margin: 14px 0 24px; }
.free-list { padding: 0; margin: 30px 0 0; list-style: none; display: grid; gap: 10px; }
.free-list li { display: flex; gap: 12px; }
.free-list li::before { content: ""; flex: none; width: 12px; height: 12px; margin-top: .5em; border-radius: 50%; background: var(--honey); }
@media (max-width: 860px) { .free-layout { grid-template-columns: 1fr; } .free-layout .sheet { max-width: 320px; } }

.notfound { text-align: center; padding: 90px 0 120px; }
.notfound img { width: min(320px, 70%); margin: 0 auto 30px; }
.notfound .hero-actions { justify-content: center; margin-top: 28px; }

/* ---------- coloring studio ---------- */
.studio { padding: 10px 0 80px; }
.studio-grid { display: grid; grid-template-columns: minmax(0, 1fr) 360px; gap: clamp(24px, 3vw, 44px); align-items: start; }
.canvas-wrap { position: relative; }
.canvas-wrap .sheet { padding: clamp(10px, 1.6vw, 20px); }
#studio-canvas { width: 100%; height: auto; max-height: calc(100vh - 140px); object-fit: contain; margin-inline: auto; cursor: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='36' height='36' viewBox='0 0 36 36'%3E%3Cpath d='M6 20 16 10l10 10-8 8a4 4 0 0 1-6 0z' fill='%23FFFDF8' stroke='%233B3230' stroke-width='2' stroke-linejoin='round'/%3E%3Cpath d='M16 10 21 5' stroke='%233B3230' stroke-width='2' stroke-linecap='round'/%3E%3Cpath d='M28 22c0 3-2 5-2 7a2 2 0 0 0 4 0c0-2-2-4-2-7z' fill='%23B23A3A' stroke='%233B3230' stroke-width='1.5'/%3E%3C/svg%3E") 26 30, pointer; touch-action: manipulation; }
.canvas-status { position: absolute; inset: 0; display: grid; place-items: center; font-weight: 700; color: var(--muted); pointer-events: none; }
.canvas-status[hidden] { display: none; }
.panel { display: grid; gap: 26px; }
.panel h2 { font: 800 1.1rem var(--font-display); letter-spacing: 0; margin-bottom: 12px; }
.box { background: var(--pine); border-radius: 14px; padding: 18px 16px 16px; position: relative; }
.box-crayons { display: grid; grid-template-columns: repeat(8, 30px); justify-content: space-between; row-gap: 10px; }
.box .crayon { transform: translateY(16px); height: 86px; }
.box .crayon:hover { transform: translateY(8px); }
.box .crayon[aria-pressed="true"] { transform: translateY(-4px); filter: drop-shadow(0 0 0 #fff); }
.box-label { display: flex; justify-content: space-between; align-items: center; color: var(--paper); margin-top: 14px; font-weight: 700; font-size: .95rem; position: relative; z-index: 1; }
.box-label output { font: 800 1.05rem var(--font-display); }
.swatch-current { width: 22px; height: 22px; border-radius: 50%; border: 2px solid var(--paper); display: inline-block; vertical-align: -5px; margin-right: 8px; }
.custom-color { display: flex; align-items: center; gap: 10px; font-weight: 600; font-size: .98rem; margin-top: 12px; color: var(--paper); }
.custom-color input { width: 44px; height: 34px; padding: 0; border: 2px solid var(--paper); border-radius: 8px; background: none; cursor: pointer; }
.tools { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.tool { display: flex; align-items: center; justify-content: center; gap: 8px; font: 700 .98rem var(--font-body); padding: .75em .9em; border-radius: 12px; border: 2px solid var(--ink); background: var(--paper); color: var(--ink); cursor: pointer; }
.tool:hover { background: var(--mint); }
.tool:disabled { opacity: .4; cursor: default; background: var(--paper); }
.tool svg { width: 18px; height: 18px; flex: none; }
.tool.primary { background: var(--cranberry); border-color: var(--cranberry); color: var(--paper); grid-column: 1 / -1; }
.tool.primary:hover { background: #9a3030; }
.tool.magic { grid-column: 1 / -1; background: var(--honey); border-color: var(--honey); }
.tool.magic:hover { background: #f1c06c; }
.pages { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; list-style: none; padding: 0; margin: 0; }
.pages button { width: 100%; padding: 6px; border-radius: 8px; border: 2px solid var(--line); background: var(--paper); cursor: pointer; display: grid; gap: 4px; font: 600 .78rem/1.2 var(--font-body); color: var(--ink); text-align: center; }
.pages button img { width: 100%; aspect-ratio: 3 / 4; object-fit: contain; }
.pages button[aria-pressed="true"] { border-color: var(--cranberry); box-shadow: 0 0 0 2px var(--cranberry); }
.from-book { font-size: 1rem; color: var(--muted); margin: 16px 0 0; text-align: center; }
.hint-line { color: var(--muted); font-size: 1rem; margin: 0; }
.toast { position: fixed; left: 50%; bottom: 24px; transform: translate(-50%, 30px); opacity: 0; visibility: hidden; transition: transform .25s ease, opacity .25s ease, visibility .25s; background: var(--ink); color: var(--paper); padding: 12px 18px; border-radius: 12px; font-weight: 600; z-index: 40; max-width: calc(100% - 32px); }
.toast.show { transform: translate(-50%, 0); opacity: 1; visibility: visible; }
@media (max-width: 980px) {
  .studio-grid { grid-template-columns: 1fr; }
  #studio-canvas { max-height: 72vh; }
  .panel { grid-template-columns: 1fr 1fr; align-items: start; }
  .panel > .pages-block { grid-column: 1 / -1; }
  .pages { grid-template-columns: repeat(5, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .panel { grid-template-columns: 1fr; }
  .box-crayons { grid-template-columns: repeat(8, minmax(0, 30px)); }
  .pages { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}

#print-area { display: none; }
@media print {
  body > *:not(#print-area) { display: none !important; }
  #print-area { display: block; }
  #print-area img { width: 100%; height: auto; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { transition: none !important; animation: none !important; scroll-behavior: auto !important; }
}
