/* Le Petit Critique — lepetitcritique.app
   Design tokens mirror the app (constants/theme.ts). */

:root {
  --parchment: #f6f1e7;
  --surface: #fbf8f1;
  --ink: #26201a;
  --muted: #8a7e6e;
  --red: #a6231e;
  --red-dark: #8a1b17;
  --gold: #c2a05c;
  --border: #e3dac8;
  --on-red: #fbf6ec;
  --serif: "Playfair Display", Georgia, serif;
  --sans: "Inter", -apple-system, "Segoe UI", sans-serif;
  --r: 14px;
  --r-sm: 8px;
}

* { box-sizing: border-box; margin: 0; padding: 0; }

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

body {
  background: var(--parchment);
  color: var(--ink);
  font-family: var(--sans);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: var(--red); }
a:focus-visible, button:focus-visible, input:focus-visible {
  outline: 2px solid var(--red);
  outline-offset: 3px;
}

.wrap { max-width: 1060px; margin: 0 auto; padding: 0 24px; }

/* ---------- shared type ---------- */

.eyebrow {
  font-family: var(--sans);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: var(--muted);
}

.fleur { color: var(--red); font-size: 1.1em; }

h1, h2, h3 { font-family: var(--serif); font-weight: 600; line-height: 1.15; }

/* ---------- header ---------- */

.site-header {
  border-bottom: 1px solid var(--border);
  padding: 18px 0;
}
.site-header .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}
.nameplate {
  font-family: var(--serif);
  font-weight: 800;
  font-size: 20px;
  letter-spacing: 0.04em;
  color: var(--ink);
  text-decoration: none;
  display: flex;
  align-items: center;
  gap: 10px;
}
.header-cta {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--on-red);
  background: var(--red);
  padding: 10px 18px;
  border-radius: var(--r-sm);
  transition: background 0.15s;
}
.header-cta:hover { background: var(--red-dark); }

/* ---------- hero ---------- */

.hero { padding: 72px 0 64px; }
.hero .wrap {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 56px;
  align-items: center;
}

.masthead {
  font-family: var(--serif);
  font-weight: 800;
  font-size: clamp(44px, 6vw, 64px);
  line-height: 1.02;
  letter-spacing: 0.01em;
}
.masthead .rule {
  display: block;
  width: 56px;
  height: 2px;
  background: var(--red);
  margin: 18px 0;
}
.hero-tagline {
  font-size: 17px;
  color: var(--ink);
  max-width: 40ch;
  margin-bottom: 8px;
}
.hero-motto {
  font-family: var(--serif);
  font-style: italic;
  font-weight: 500;
  color: var(--muted);
  font-size: 16px;
  margin-bottom: 28px;
}
.hero-actions { display: flex; align-items: center; gap: 18px; flex-wrap: wrap; }
.btn-primary {
  display: inline-block;
  background: var(--red);
  color: var(--on-red);
  text-decoration: none;
  font-weight: 600;
  font-size: 13px;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  padding: 16px 30px;
  border-radius: var(--r-sm);
  transition: background 0.15s, transform 0.1s;
}
.btn-primary:hover { background: var(--red-dark); }
.btn-primary:active { transform: scale(0.98); }
.hero-note { font-size: 13px; color: var(--muted); }

/* ---------- the demo (signature) ---------- */

.demo { display: flex; flex-direction: column; gap: 18px; }

.critique-card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 26px;
  position: relative;
}
.card-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 18px;
}
.card-title { font-family: var(--serif); font-size: 20px; }
.tone-chip {
  font-size: 10px;
  font-weight: 600;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  padding: 5px 10px;
  border-radius: 4px;
  background: #efe7d2;
  color: var(--ink);
  transition: background 0.25s, color 0.25s;
  white-space: nowrap;
}
.tone-chip.savage { background: var(--red); color: var(--on-red); }

.score-row { display: flex; align-items: center; gap: 16px; margin-bottom: 18px; }
.score-rule { flex: 1; height: 1px; background: var(--border); }
.score-value { font-family: var(--serif); font-weight: 800; font-size: 28px; color: var(--ink); }
.score-value small { font-family: var(--serif); font-weight: 600; font-size: 15px; color: var(--muted); }

.bubble-row { display: flex; gap: 18px; align-items: flex-end; margin-bottom: 20px; }
.bubble-row img { height: 118px; flex: none; transform: scaleX(-1); /* artwork faces left; face the bubble */ }
.bubble {
  background: var(--parchment);
  border: 1px solid var(--border);
  border-radius: var(--r) var(--r) var(--r) 4px;
  padding: 16px 18px;
  font-size: 15px;
  min-height: 116px;
}

.fixes { list-style: none; display: flex; flex-direction: column; gap: 12px; }
.fixes li { display: flex; gap: 12px; font-size: 14px; }
.fixes .n {
  flex: none;
  width: 22px;
  height: 22px;
  border: 1.5px solid var(--red);
  border-radius: 50%;
  color: var(--red);
  font-size: 11px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-top: 2px;
}
.fixes strong { display: block; font-weight: 600; }
.fixes span { color: var(--muted); }

.tone-control { padding: 0 6px; }
.tone-control input[type="range"] {
  width: 100%;
  appearance: none;
  -webkit-appearance: none;
  height: 3px;
  border-radius: 2px;
  background: linear-gradient(to right, var(--red) var(--fill, 15%), var(--border) var(--fill, 15%));
  cursor: pointer;
}
.tone-control input[type="range"]::-webkit-slider-thumb {
  appearance: none;
  -webkit-appearance: none;
  width: 22px;
  height: 22px;
  border-radius: 50%;
  background: var(--red);
  border: 3px solid var(--surface);
  box-shadow: 0 1px 4px rgba(38, 32, 26, 0.25);
}
.tone-control input[type="range"]::-moz-range-thumb {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--red);
  border: 3px solid var(--surface);
  box-shadow: 0 1px 4px rgba(38, 32, 26, 0.25);
}
.tone-labels {
  display: flex;
  justify-content: space-between;
  margin-top: 10px;
}
.demo-hint { text-align: center; font-size: 13px; color: var(--muted); font-style: italic; font-family: var(--serif); }

/* ---------- sections ---------- */

.section { padding: 72px 0; border-top: 1px solid var(--border); }
.section-head { text-align: center; max-width: 56ch; margin: 0 auto 48px; }
.section-head h2 { font-size: clamp(28px, 4vw, 38px); margin: 10px 0 14px; }
.section-head p { color: var(--muted); }

.steps { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.step {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--r);
  padding: 28px 24px;
}
.step .n {
  width: 30px;
  height: 30px;
  border: 1.5px solid var(--red);
  border-radius: 50%;
  color: var(--red);
  font-weight: 600;
  font-size: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 16px;
}
.step h3 { font-size: 20px; margin-bottom: 8px; }
.step p { font-size: 14px; color: var(--muted); }

.pillars { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
.pillar { text-align: center; padding: 8px 16px; }
.pillar .mark { color: var(--gold); font-size: 22px; margin-bottom: 10px; }
.pillar h3 { font-size: 19px; margin-bottom: 8px; }
.pillar p { font-size: 14px; color: var(--muted); }

/* ---------- closing cta ---------- */

.closing { text-align: center; padding: 84px 0; border-top: 1px solid var(--border); }
.closing img { height: 130px; margin-bottom: 22px; }
.closing h2 { font-size: clamp(30px, 4.5vw, 42px); margin-bottom: 12px; }
.closing p { color: var(--muted); margin-bottom: 30px; }

/* ---------- footer ---------- */

.site-footer {
  border-top: 1px solid var(--border);
  padding: 30px 0;
  font-size: 13px;
  color: var(--muted);
}
.site-footer .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}
.site-footer nav { display: flex; gap: 20px; }
.site-footer a { color: var(--muted); text-decoration: none; }
.site-footer a:hover { color: var(--red); }

/* ---------- legal / plain pages ---------- */

.page { max-width: 720px; margin: 0 auto; padding: 56px 24px 80px; }
.page h1 { font-size: 34px; margin-bottom: 8px; }
.page .updated { color: var(--muted); font-size: 13px; margin-bottom: 36px; }
.page h2 { font-size: 21px; margin: 32px 0 10px; }
.page p, .page li { font-size: 15px; color: var(--ink); margin-bottom: 10px; }
.page ul { padding-left: 22px; }
.draft {
  background: var(--surface);
  border: 1px dashed var(--gold);
  border-radius: var(--r-sm);
  padding: 12px 16px;
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 32px;
}

/* ---------- responsive ---------- */

@media (max-width: 860px) {
  .hero { padding: 48px 0 40px; }
  .hero .wrap { grid-template-columns: 1fr; gap: 40px; }
  .steps, .pillars { grid-template-columns: 1fr; }
  .section { padding: 56px 0; }
}
