/* Cool Source Cards — shared styles
   Calm, editorial, image-led. */

@font-face {
  font-family: "CoolSourceCaps";
  src: url("fonts/CoolSourceCaps-Bold.woff2?v=3") format("woff2"),
       url("fonts/CoolSourceCaps-Bold.woff?v=3") format("woff");
  font-weight: 400 700;
  font-style: normal;
  font-display: swap;
}

:root {
  --bg: #fbfaf7;
  --ink: #1c1b18;
  --muted: #726d63;
  --line: #e8e3d9;
  --ph-bg: #f1ede4;
  --ph-border: #d8d2c4;
  --ph-label: #8b8474;
  --ph-file: #aaa394;
  --rule: #c9c2b4;
  --maxw: 1180px;
  --gap: clamp(0.9rem, 2.2vw, 1.6rem);
}

* { box-sizing: border-box; }

html { -webkit-text-size-adjust: 100%; scroll-behavior: smooth; }

body {
  margin: 0;
  background: var(--bg);
  color: var(--ink);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: clamp(1rem, 0.96rem + 0.2vw, 1.075rem);
  line-height: 1.62;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img { max-width: 100%; display: block; }

.wrap {
  max-width: var(--maxw);
  margin: 0 auto;
  padding: 0 clamp(1.25rem, 5vw, 3rem);
}

/* Display type */
h1, h2 {
  font-family: "CoolSourceCaps", "Helvetica Neue", Arial, sans-serif;
  font-weight: 400;
  letter-spacing: -0.012em;
  margin: 0;
}

/* Header */
.site-head { padding: clamp(2.5rem, 7vw, 5.5rem) 0 clamp(2.25rem, 6vw, 4rem); }

.hero {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: clamp(1.25rem, 1rem + 4vw, 4rem);
}
.hero-art {
  flex: 0 0 auto;
  width: clamp(210px, 31vw, 340px);
}
.site-mark {
  display: block;
  width: 100%;
  height: auto;
  margin: 0;
}
.hero-text { flex: 1 1 330px; min-width: 0; }

.kicker {
  margin: 0 0 1.1rem;
  font-size: 0.78rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}

.site-head h1 {
  font-size: clamp(2.7rem, 1.5rem + 5.6vw, 5.5rem);
  line-height: 0.9;
  letter-spacing: 0;
}

.site-head .standfirst {
  color: var(--muted);
  font-size: clamp(1.05rem, 1rem + 0.4vw, 1.22rem);
  line-height: 1.55;
  max-width: 50ch;
  margin: 1rem 0 0;
}

/* Sections */
.section { padding: clamp(2.75rem, 6vw, 5rem) 0; }
.section + .section { border-top: 1px solid var(--line); }

.section-head { max-width: 60ch; margin: 0 0 clamp(1.5rem, 3.2vw, 2.3rem); }

.section-head h2 {
  font-size: clamp(1.5rem, 1.2rem + 1.5vw, 2.15rem);
  line-height: 1.12;
}

.caption {
  color: var(--muted);
  margin: 0.6rem 0 0;
  font-size: clamp(1rem, 0.97rem + 0.25vw, 1.1rem);
  max-width: 54ch;
}

/* Per-book blocks (within the children's books section) */
.book + .book { margin-top: clamp(2.25rem, 4.5vw, 3.5rem); }
.book-head { max-width: 60ch; margin: 0 0 clamp(1rem, 2.4vw, 1.5rem); }
.book-title {
  font-family: "CoolSourceCaps", "Helvetica Neue", Arial, sans-serif;
  font-weight: 500;
  letter-spacing: -0.01em;
  font-size: clamp(1.2rem, 1.05rem + 0.8vw, 1.5rem);
  line-height: 1.15;
  margin: 0 0 0.4rem;
}
.book-blurb { color: var(--muted); margin: 0; max-width: 56ch; }
/* Placeholder copy, to be replaced */
.ph-text { font-style: italic; color: var(--ph-label); }

/* Grids */
.grid {
  display: grid;
  gap: var(--gap);
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 300px), 1fr));
}
.grid--small {
  grid-template-columns: repeat(auto-fill, minmax(min(100%, 220px), 1fr));
}

/* Cells: each holds a placeholder now, or an <img> later */
.cell {
  margin: 0;
  border-radius: 10px;
  overflow: hidden;
  background: var(--ph-bg);
}
.cell img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

/* Aspect ratios per section */
.ar-card   { aspect-ratio: 5 / 7; }
.ar-book   { aspect-ratio: 4 / 3; }
.ar-char   { aspect-ratio: 4 / 5; }
.ar-square { aspect-ratio: 1 / 1; }

/* Placeholder appearance */
.ph {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.4rem;
  text-align: center;
  padding: 1rem;
  border: 1px dashed var(--ph-border);
  border-radius: 10px;
  color: var(--ph-label);
}
.ph-label {
  font-weight: 600;
  font-size: 0.95rem;
  letter-spacing: 0.01em;
}
.ph-file {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 0.76rem;
  color: var(--ph-file);
}

/* Plain link row (Etsy) */
.link-row { margin: clamp(1.6rem, 3.2vw, 2.25rem) 0 0; }
.link-row a {
  color: var(--ink);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-thickness: 1px;
  text-decoration-color: var(--rule);
}
.link-row a:hover { text-decoration-color: var(--ink); }

/* Footer */
.site-foot {
  padding: clamp(3rem, 7vw, 5rem) 0;
  border-top: 1px solid var(--line);
  color: var(--muted);
  font-size: 0.95rem;
}
.site-foot p { margin: 0.2rem 0; }

/* Root landing page */
.landing-page {
  position: relative;
  min-height: 100svh;
  display: flex;
  flex-direction: column;
  text-align: center;
}
.landing-head {
  position: relative;
  z-index: 1;
  padding: clamp(1.75rem, 4vw, 2.75rem) 1.25rem 0;
}
.logo {
  font-family: "CoolSourceCaps", "Helvetica Neue", Arial, sans-serif;
  font-size: clamp(1.3rem, 1.05rem + 1vw, 1.75rem);
  letter-spacing: 0.005em;
  margin: 0;
}
.landing-main {
  position: relative;
  z-index: 1;
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: clamp(1.1rem, 2.4vw, 1.6rem);
  padding: clamp(2rem, 6vw, 4rem) clamp(1.25rem, 5vw, 3rem);
}
.landing-title {
  font-size: clamp(2.4rem, 1.3rem + 5vw, 4.75rem);
  line-height: 0.95;
  margin: 0;
  max-width: 18ch;
}
.landing-blurb {
  color: var(--muted);
  font-size: clamp(1.05rem, 1rem + 0.45vw, 1.25rem);
  line-height: 1.55;
  max-width: 46ch;
  margin: 0;
}
.btn-row {
  display: flex;
  flex-wrap: wrap;
  gap: 0.8rem;
  justify-content: center;
  margin-top: 0.4rem;
}
.btn {
  display: inline-block;
  padding: 0.8rem 1.6rem;
  border-radius: 999px;
  border: 1.5px solid var(--ink);
  background: var(--ink);
  color: var(--bg);
  font-weight: 500;
  font-size: 1rem;
  text-decoration: none;
  transition: transform .15s ease, background-color .15s ease, color .15s ease;
}
.btn:hover { transform: translateY(-2px); }
.btn--alt { background: transparent; color: var(--ink); }
.btn--alt:hover { background: var(--ink); color: var(--bg); }
.landing-foot {
  position: relative;
  z-index: 1;
  padding: clamp(1.75rem, 4vw, 2.75rem) 1.25rem;
  color: var(--muted);
  font-size: 0.92rem;
}
.landing-foot p { margin: 0; }
.landing-foot a {
  color: var(--muted);
  text-decoration: underline;
  text-underline-offset: 3px;
  text-decoration-color: var(--rule);
}
.landing-foot a:hover { color: var(--ink); text-decoration-color: var(--ink); }

/* Accolades / reviews */
.accolades {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: clamp(1rem, 3vw, 2rem) clamp(1.25rem, 5vw, 3rem) clamp(2.5rem, 6vw, 4.5rem);
}
.accolades-title {
  text-align: center;
  font-size: clamp(1.35rem, 1.1rem + 1vw, 1.95rem);
  margin: 0 0 clamp(1.75rem, 4vw, 2.75rem);
}
.accolades-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(min(100%, 330px), 1fr));
  gap: clamp(1.75rem, 4vw, 3rem) clamp(0.75rem, 2.5vw, 1.75rem);
}
.accolade {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: clamp(0.1rem, 0.5vw, 0.4rem);
  color: var(--ink);
  width: 100%;
}
.laurel {
  flex: 0 0 auto;
  height: clamp(112px, 13.5vw, 150px);
  width: auto;
  aspect-ratio: 35 / 59;
}
.accolade-body { flex: 0 1 13ch; min-width: 0; text-align: center; }
.stars {
  display: flex;
  justify-content: center;
  gap: 3px;
  margin: 0 0 0.55rem;
}
.star { width: 15px; height: 15px; display: block; }
.quote {
  font-family: "CoolSourceCaps", "Helvetica Neue", Arial, sans-serif;
  font-size: clamp(0.98rem, 0.9rem + 0.3vw, 1.14rem);
  line-height: 1.16;
  letter-spacing: 0.01em;
  margin: 0 0 0.6rem;
}
.attribution {
  margin: 0;
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.01em;
}

/* Decorative scatter layer (character SVGs) */
.scatter {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}
.scatter img {
  position: absolute;
  height: auto;
  display: block;
  pointer-events: none;
  user-select: none;
}
@media (max-width: 760px) {
  .scatter .s-mid { display: none; }
}

/* Print: clean PDF / printout for assessors */
@media print {
  :root { --bg: #fff; }
  body { font-size: 11pt; }
  .ph { border-color: #bbb; color: #555; }
  .section + .section { border-color: #ccc; }
  a { color: #000; }
}
