/* ==========================================================================
   Cindy Meister — author site
   Plain CSS, no build step. Colors and type live in :root so the whole
   look can be retuned from one place.
   ========================================================================== */

:root {
  --ink: #1e1a2b;          /* deep plum-ink: hero, footer, headings */
  --ink-soft: #2c2640;
  --paper: #fbf8f3;        /* page background */
  --cream: #f3ece1;        /* alternate section background */
  --card: #ffffff;
  --text: #2a2533;
  --muted: #6a6375;
  --line: #e7dfd2;
  --rose: #b8465f;         /* primary accent */
  --rose-dark: #963349;
  --rose-tint: #f6e3e7;
  --gold: #c99a5b;
  --glow-a: rgba(184, 70, 95, 0.45);
  --glow-b: rgba(110, 86, 207, 0.35);

  --font-display: "Fraunces", Georgia, "Times New Roman", serif;
  --font-body: "Inter", system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;

  --radius: 14px;
  --radius-sm: 8px;
  --shadow: 0 1px 2px rgba(30, 26, 43, 0.06), 0 8px 24px rgba(30, 26, 43, 0.08);
  --shadow-lg: 0 24px 60px rgba(20, 14, 35, 0.35);
  --max: 1120px;
  --gutter: clamp(16px, 4vw, 32px);
}

/* ---------- Base ---------- */

*,
*::before,
*::after { box-sizing: border-box; }

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

body {
  margin: 0;
  background: var(--paper);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 1.0625rem;
  line-height: 1.7;
  -webkit-font-smoothing: antialiased;
}

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

a { color: var(--rose); text-underline-offset: 3px; }
a:hover { color: var(--rose-dark); }

h1, h2, h3, h4 {
  font-family: var(--font-display);
  color: var(--ink);
  line-height: 1.15;
  font-weight: 600;
  margin: 0 0 0.5em;
  letter-spacing: -0.01em;
}
h1 { font-size: clamp(2.4rem, 6vw, 4.25rem); }
h2 { font-size: clamp(1.9rem, 4vw, 2.75rem); }
h3 { font-size: 1.35rem; }

p { margin: 0 0 1.1em; }

:focus-visible { outline: 3px solid var(--gold); outline-offset: 3px; border-radius: 4px; }

.skip-link {
  position: absolute; left: 12px; top: -60px; z-index: 100;
  background: var(--ink); color: #fff; padding: 10px 16px; border-radius: var(--radius-sm);
}
.skip-link:focus { top: 12px; color: #fff; }

.container { width: 100%; max-width: var(--max); margin: 0 auto; padding: 0 var(--gutter); }
.narrow { max-width: 760px; }

.eyebrow {
  display: inline-block;
  font-family: var(--font-body);
  font-size: 0.78rem;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--rose);
  margin-bottom: 0.9rem;
}

.lead { font-size: 1.2rem; color: var(--muted); }

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 0.5em;
  padding: 0.85em 1.5em;
  border-radius: 999px;
  border: 2px solid transparent;
  font: 600 0.95rem/1.2 var(--font-body);
  text-decoration: none;
  cursor: pointer;
  transition: background 0.2s, color 0.2s, border-color 0.2s, transform 0.2s;
}
.btn:hover { transform: translateY(-1px); }
.btn-primary { background: var(--rose); color: #fff; }
.btn-primary:hover { background: var(--rose-dark); color: #fff; }
.btn-outline { border-color: currentColor; color: var(--ink); background: transparent; }
.btn-outline:hover { background: var(--ink); color: #fff; border-color: var(--ink); }
.on-dark .btn-outline { color: #fff; }
.on-dark .btn-outline:hover { background: #fff; color: var(--ink); border-color: #fff; }
.btn-row { display: flex; flex-wrap: wrap; gap: 12px; }

/* ---------- Header / nav ---------- */

.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(251, 248, 243, 0.92);
  backdrop-filter: saturate(150%) blur(10px);
  -webkit-backdrop-filter: saturate(150%) blur(10px);
  border-bottom: 1px solid var(--line);
}
.site-header .container {
  display: flex; align-items: center; justify-content: space-between;
  min-height: 68px;
}
.brand {
  font-family: var(--font-display);
  font-size: 1.35rem;
  font-weight: 600;
  color: var(--ink);
  text-decoration: none;
  letter-spacing: -0.01em;
}
.brand:hover { color: var(--ink); }

.nav-toggle {
  display: none;
  background: none; border: 0; padding: 10px; margin-right: -10px; cursor: pointer; color: var(--ink);
}
.nav-toggle svg { width: 26px; height: 26px; }

.site-nav ul { list-style: none; margin: 0; padding: 0; display: flex; align-items: center; gap: 4px; }
.site-nav a {
  display: block; padding: 8px 14px; border-radius: 999px;
  color: var(--text); text-decoration: none; font-weight: 500; font-size: 0.95rem;
}
.site-nav a:hover { background: var(--cream); color: var(--ink); }
.site-nav a[aria-current="page"] { color: var(--rose); }
.site-nav .nav-cta a { background: var(--ink); color: #fff; margin-left: 8px; }
.site-nav .nav-cta a:hover { background: var(--rose); color: #fff; }

@media (max-width: 820px) {
  .nav-toggle { display: inline-flex; }
  .site-nav {
    position: absolute; left: 0; right: 0; top: 100%;
    background: var(--paper);
    border-bottom: 1px solid var(--line);
    box-shadow: 0 12px 24px rgba(30, 26, 43, 0.08);
    display: none;
  }
  .site-nav.is-open { display: block; }
  .site-nav ul { flex-direction: column; align-items: stretch; padding: 8px var(--gutter) 16px; gap: 2px; }
  .site-nav a { padding: 12px 14px; border-radius: var(--radius-sm); }
  .site-nav .nav-cta a { margin: 8px 0 0; text-align: center; }
}

/* ---------- Sections ---------- */

.section { padding: clamp(64px, 10vw, 112px) 0; }
.section-alt { background: var(--cream); }
.section-head { max-width: 680px; margin: 0 auto clamp(36px, 5vw, 56px); text-align: center; }
.section-head p { color: var(--muted); font-size: 1.1rem; }

.on-dark { background: var(--ink); color: #e9e4f0; }
.on-dark h1, .on-dark h2, .on-dark h3 { color: #fff; }
.on-dark .eyebrow { color: #f0a8b8; }
.on-dark .lead, .on-dark .section-head p { color: #c6bfd3; }
.on-dark a:not(.btn) { color: #f0a8b8; }

/* ---------- Hero ---------- */

.hero { position: relative; overflow: hidden; padding: clamp(56px, 9vw, 120px) 0; }
.hero::before,
.hero::after {
  content: ""; position: absolute; border-radius: 50%; filter: blur(80px); pointer-events: none;
}
.hero::before { width: 520px; height: 520px; background: var(--glow-a); top: -160px; right: -120px; }
.hero::after { width: 460px; height: 460px; background: var(--glow-b); bottom: -200px; left: -140px; }
.hero .container {
  position: relative; z-index: 1;
  display: grid; grid-template-columns: 1.1fr 0.9fr; gap: clamp(32px, 6vw, 80px); align-items: center;
}
.hero h1 { margin-bottom: 0.3em; }
.hero h1 em { font-style: italic; font-weight: 400; color: #f4c3ce; }
.hero .byline { font-size: 1.15rem; color: #d8d1e3; margin-bottom: 1.5rem; }
.hero .lead { max-width: 34em; margin-bottom: 2rem; }
.hero-cover { display: flex; justify-content: center; }

@media (max-width: 820px) {
  .hero .container { grid-template-columns: 1fr; text-align: center; }
  .hero .btn-row { justify-content: center; }
  .hero .lead { margin-left: auto; margin-right: auto; }
  .hero-cover { order: -1; }
}

/* ---------- Book cover ----------
   A typographic stand-in until the real cover art is ready.
   To use the real cover, replace the .book-cover div with:
   <img class="book-cover-img" src="images/book-cover.jpg" alt="The Idea of You by Cindy Meister — book cover">
*/

.book-cover,
.book-cover-img {
  width: min(300px, 70vw);
  aspect-ratio: 2 / 3;
  border-radius: 4px 10px 10px 4px;
  box-shadow: var(--shadow-lg), inset 6px 0 10px -6px rgba(0, 0, 0, 0.5);
  transform: perspective(1200px) rotateY(-8deg);
  transition: transform 0.4s ease;
}
.book-cover:hover,
.book-cover-img:hover { transform: perspective(1200px) rotateY(0deg); }
.book-cover-img { object-fit: cover; }

.book-cover {
  position: relative; overflow: hidden;
  display: flex; flex-direction: column; justify-content: space-between;
  padding: 34px 26px 28px;
  color: #fff; text-align: center;
  background:
    radial-gradient(circle at 30% 30%, rgba(244, 195, 206, 0.55), transparent 55%),
    radial-gradient(circle at 75% 70%, rgba(130, 110, 230, 0.55), transparent 55%),
    linear-gradient(160deg, #2c2148 0%, #171326 100%);
}
.book-cover::before {
  /* faint "circuit" grid — a nod to the AI theme */
  content: ""; position: absolute; inset: 0;
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.06) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.06) 1px, transparent 1px);
  background-size: 22px 22px;
  mask-image: linear-gradient(to bottom, transparent, #000 40%, #000 60%, transparent);
  -webkit-mask-image: linear-gradient(to bottom, transparent, #000 40%, #000 60%, transparent);
}
.book-cover > * { position: relative; }
.book-cover .bc-top { font-size: 0.7rem; letter-spacing: 0.3em; text-transform: uppercase; opacity: 0.8; }
.book-cover .bc-title { font-family: var(--font-display); font-size: 2.6rem; line-height: 1; font-weight: 600; }
.book-cover .bc-title span { display: block; font-style: italic; font-weight: 400; font-size: 0.55em; margin-bottom: 6px; opacity: 0.9; }
.book-cover .bc-heart { width: 54px; height: 54px; margin: 0 auto; opacity: 0.9; }
.book-cover .bc-author { font-size: 0.85rem; letter-spacing: 0.32em; text-transform: uppercase; }

/* ---------- Grids & cards ---------- */

.grid { display: grid; gap: clamp(20px, 3vw, 28px); }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
@media (max-width: 900px) { .grid-3 { grid-template-columns: 1fr; } }
@media (max-width: 720px) { .grid-2 { grid-template-columns: 1fr; } }

.card {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(24px, 3vw, 32px);
  box-shadow: var(--shadow);
}
.card h3 { margin-bottom: 0.4em; }
.card p:last-child { margin-bottom: 0; }

.icon-badge {
  width: 48px; height: 48px; border-radius: 12px;
  display: grid; place-items: center;
  background: var(--rose-tint); color: var(--rose);
  margin-bottom: 18px;
}
.icon-badge svg { width: 24px; height: 24px; }

/* ---------- Split layout (text + image) ---------- */

.split { display: grid; grid-template-columns: 1fr 1.2fr; gap: clamp(32px, 6vw, 72px); align-items: center; }
.split.reverse { grid-template-columns: 1.2fr 1fr; }
.split.reverse > :first-child { order: 2; }
@media (max-width: 820px) {
  .split, .split.reverse { grid-template-columns: 1fr; }
  .split.reverse > :first-child { order: 0; }
}

.portrait {
  position: relative; max-width: 380px; margin: 0 auto;
}
.portrait img {
  width: 100%; aspect-ratio: 4 / 5; object-fit: cover; object-position: center 20%;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}
.portrait::before {
  content: ""; position: absolute; inset: 18px -18px -18px 18px; z-index: -1;
  border: 2px solid var(--gold); border-radius: var(--radius);
}

/* ---------- Synopsis / prose ---------- */

.prose p { font-size: 1.12rem; }
.prose p:first-of-type::first-letter {
  float: left; font-family: var(--font-display); font-size: 3.6em; line-height: 0.85;
  padding: 6px 10px 0 0; color: var(--rose);
}

.fact-list { list-style: none; padding: 0; margin: 28px 0 0; display: flex; flex-wrap: wrap; gap: 10px; }
.fact-list li {
  background: var(--card); border: 1px solid var(--line); border-radius: 999px;
  padding: 6px 14px; font-size: 0.9rem; color: var(--muted);
}
.fact-list strong { color: var(--ink); font-weight: 600; }

/* ---------- Quote / praise ---------- */

.pull-quote {
  font-family: var(--font-display);
  font-size: clamp(1.5rem, 3vw, 2.1rem);
  line-height: 1.35;
  font-style: italic;
  color: var(--ink);
  text-align: center;
  max-width: 820px; margin: 0 auto;
}
.pull-quote cite { display: block; margin-top: 1rem; font: 500 0.95rem var(--font-body); font-style: normal; color: var(--muted); }

.praise-card { display: flex; flex-direction: column; }
.praise-card blockquote { margin: 0 0 1.2rem; font-family: var(--font-display); font-size: 1.2rem; line-height: 1.5; color: var(--ink); }
.praise-card .who { margin-top: auto; font-size: 0.92rem; color: var(--muted); }
.stars { color: var(--gold); letter-spacing: 2px; margin-bottom: 0.6rem; }

.empty-state {
  text-align: center; border: 2px dashed var(--line); border-radius: var(--radius);
  padding: clamp(28px, 5vw, 48px); background: rgba(255, 255, 255, 0.5);
}
.empty-state p { color: var(--muted); max-width: 520px; margin-left: auto; margin-right: auto; }

/* ---------- Retailers ---------- */

.retailers { display: flex; flex-wrap: wrap; justify-content: center; gap: 12px; }
.retailers .btn { min-width: 170px; }

/* ---------- Events ---------- */

.event-list { display: grid; gap: 16px; }
.event {
  display: grid; grid-template-columns: 84px 1fr auto; gap: 20px; align-items: center;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 18px 22px;
}
.event-date { text-align: center; border-right: 1px solid var(--line); padding-right: 18px; }
.event-date .m { display: block; font-size: 0.75rem; letter-spacing: 0.14em; text-transform: uppercase; color: var(--rose); font-weight: 600; }
.event-date .d { display: block; font-family: var(--font-display); font-size: 2rem; line-height: 1; color: var(--ink); }
.event h3 { font-size: 1.15rem; margin-bottom: 0.2em; }
.event p { margin: 0; color: var(--muted); font-size: 0.95rem; }
@media (max-width: 640px) {
  .event { grid-template-columns: 64px 1fr; }
  .event .btn { grid-column: 1 / -1; }
}

/* ---------- Forms ---------- */

.form { display: grid; gap: 18px; }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
@media (max-width: 640px) { .form-row { grid-template-columns: 1fr; } }
.field label { display: block; font-weight: 600; font-size: 0.92rem; color: var(--ink); margin-bottom: 6px; }
.field .hint { font-weight: 400; color: var(--muted); }
.field input,
.field select,
.field textarea {
  width: 100%;
  font: inherit; font-size: 1rem; color: var(--text);
  background: #fff;
  border: 1.5px solid var(--line);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  transition: border-color 0.2s, box-shadow 0.2s;
}
.field textarea { min-height: 170px; resize: vertical; }
.field input:focus,
.field select:focus,
.field textarea:focus { outline: none; border-color: var(--rose); box-shadow: 0 0 0 4px var(--rose-tint); }
.check { display: flex; gap: 10px; align-items: flex-start; font-size: 0.95rem; color: var(--muted); }
.check input { margin-top: 5px; accent-color: var(--rose); width: 18px; height: 18px; flex: none; }
.hidden { display: none !important; }

.newsletter { display: flex; gap: 10px; max-width: 520px; margin: 0 auto; }
.newsletter input {
  flex: 1; min-width: 0;
  font: inherit; padding: 14px 18px; border-radius: 999px;
  border: 1.5px solid rgba(255, 255, 255, 0.25); background: rgba(255, 255, 255, 0.08); color: #fff;
}
.newsletter input::placeholder { color: #b9b1c8; }
.newsletter input:focus { outline: none; border-color: #f0a8b8; }
@media (max-width: 520px) { .newsletter { flex-direction: column; } }
.fine-print { font-size: 0.85rem; color: #a9a1b8; margin-top: 14px; text-align: center; }

/* ---------- Q&A / accordion ---------- */

.faq { display: grid; gap: 12px; }
.faq details {
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); padding: 0 22px;
}
.faq summary {
  cursor: pointer; list-style: none; padding: 18px 0; font-weight: 600; color: var(--ink);
  display: flex; justify-content: space-between; gap: 16px;
}
.faq summary::-webkit-details-marker { display: none; }
.faq summary::after { content: "+"; font-size: 1.4rem; line-height: 1; color: var(--rose); transition: transform 0.2s; }
.faq details[open] summary::after { transform: rotate(45deg); }
.faq details > div { padding-bottom: 18px; color: var(--muted); }

.question-list { counter-reset: q; list-style: none; padding: 0; margin: 0; display: grid; gap: 14px; }
.question-list li {
  counter-increment: q; position: relative;
  background: var(--card); border: 1px solid var(--line); border-radius: var(--radius);
  padding: 18px 22px 18px 70px;
}
.question-list li::before {
  content: counter(q);
  position: absolute; left: 20px; top: 16px;
  width: 34px; height: 34px; border-radius: 50%;
  display: grid; place-items: center;
  background: var(--rose-tint); color: var(--rose); font-weight: 700; font-size: 0.95rem;
}

/* ---------- Page header (inner pages) ---------- */

.page-hero { padding: clamp(56px, 8vw, 96px) 0 clamp(40px, 6vw, 64px); text-align: center; position: relative; overflow: hidden; }
.page-hero::before {
  content: ""; position: absolute; width: 480px; height: 480px; border-radius: 50%;
  background: var(--glow-a); filter: blur(90px); top: -260px; left: 50%; transform: translateX(-50%);
}
.page-hero .container { position: relative; }
.page-hero p { max-width: 620px; margin: 0 auto; }

/* ---------- Footer ---------- */

.site-footer { background: var(--ink); color: #b9b1c8; padding: 56px 0 32px; font-size: 0.95rem; }
.site-footer a { color: #e9e4f0; text-decoration: none; }
.site-footer a:hover { color: #f0a8b8; }
.footer-grid { display: grid; grid-template-columns: 1.4fr 1fr 1fr; gap: 32px; }
@media (max-width: 720px) { .footer-grid { grid-template-columns: 1fr; } }
.site-footer .brand { color: #fff; display: inline-block; margin-bottom: 8px; }
.site-footer h4 { font-family: var(--font-body); color: #fff; font-size: 0.8rem; letter-spacing: 0.14em; text-transform: uppercase; margin-bottom: 14px; }
.site-footer ul { list-style: none; margin: 0; padding: 0; display: grid; gap: 8px; }
.social { display: flex; gap: 10px; margin-top: 16px; }
.social a {
  width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center;
  background: rgba(255, 255, 255, 0.08);
}
.social a:hover { background: var(--rose); color: #fff; }
.social svg { width: 18px; height: 18px; }
.footer-bottom { border-top: 1px solid rgba(255, 255, 255, 0.1); margin-top: 40px; padding-top: 24px; font-size: 0.85rem; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 8px; }

/* ---------- Utilities ---------- */

.text-center { text-align: center; }
.mt-lg { margin-top: clamp(32px, 5vw, 48px); }
.sr-only {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

/* Gentle fade-in as sections scroll into view (JS adds .reveal-ready). */
.reveal-ready .reveal { opacity: 0; transform: translateY(18px); transition: opacity 0.7s ease, transform 0.7s ease; }
.reveal-ready .reveal.is-visible { opacity: 1; transform: none; }

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { transition: none !important; animation: none !important; }
  .reveal-ready .reveal { opacity: 1; transform: none; }
  .book-cover, .book-cover-img { transform: none; }
}

@media print {
  .site-header, .site-footer, .no-print { display: none !important; }
  body { background: #fff; }
  .question-list li { break-inside: avoid; border-color: #ccc; }
}
