/*
 * Proposition 02 — ÉDITORIAL
 * Version magazine sombre (même famille que 01 et 03) : fond nuit violacé, texte crème,
 * photos N&B en arche (« cortes curvos », manuel p.14), citations en Dirty Three,
 * accents magenta / blush.
 * Le lecteur affiche une onde en direct (analyser Web Audio).
 */
:root {
  --bg: #0a0410;
  --ink: var(--fresca-cream); /* texte principal : crème sur nuit */
  --surface: rgba(254, 253, 228, 0.05);
  --line: rgba(254, 253, 228, 0.14);
  --rule: rgba(254, 253, 228, 0.38); /* filets éditoriaux, plus marqués que --line */
  --muted: rgba(254, 253, 228, 0.66);
  --accent: var(--fresca-magenta);
  --accent-ink: var(--fresca-magenta); /* lisible tel quel sur fond sombre */
  --quote: var(--fresca-blush);
  --violet: var(--fresca-indigo);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);

  --kit-bg: var(--bg);
  --kit-fg: var(--ink);
  --kit-muted: var(--muted);
  --kit-line: var(--line);
  --kit-surface: var(--surface);
}

body {
  color: var(--ink);
  background:
    radial-gradient(1100px 600px at 100% -10%, rgba(107, 48, 161, 0.4), transparent 60%),
    radial-gradient(800px 500px at -10% 60%, rgba(253, 83, 210, 0.1), transparent 60%),
    var(--bg);
  background-attachment: fixed;
  min-height: 100vh;
}

a {
  color: inherit;
}

:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 3px;
}

.wrap {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 clamp(16px, 4vw, 48px);
}

/* ───────── En-tête ───────── */
.masthead {
  border-bottom: 1px solid var(--rule);
}

.masthead .wrap {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding-top: 20px;
  padding-bottom: 20px;
}

.masthead img {
  height: 52px;
  width: auto;
}

.masthead__meta {
  display: flex;
  gap: 24px;
  font-size: 12px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.masthead__meta a {
  text-decoration: none;
}

.masthead__meta a:hover {
  color: var(--accent-ink);
}

.rule {
  height: 6px;
  background: var(--fresca-gradient);
}

/* ───────── Couverture ───────── */
.cover {
  display: grid;
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
  gap: clamp(32px, 6vw, 80px);
  padding: clamp(48px, 8vw, 104px) 0 clamp(48px, 6vw, 80px);
  align-items: end;
}

.eyebrow {
  font-size: 12px;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--accent-ink);
}

.cover h1 {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(64px, 12vw, 168px);
  line-height: 0.88;
  margin: 16px 0 24px;
}

.cover p {
  font-size: clamp(17px, 1.6vw, 20px);
  line-height: 1.65;
  max-width: 44ch;
  margin: 0;
  color: var(--muted);
}

/* Sommaire */
.toc {
  list-style: none;
  margin: 0;
  padding: 0;
  border-top: 1px solid var(--rule);
}

.toc li {
  border-bottom: 1px solid var(--line);
}

.toc a {
  display: grid;
  grid-template-columns: 48px 1fr auto;
  gap: 12px;
  align-items: baseline;
  padding: 16px 0;
  text-decoration: none;
  transition: padding 0.3s var(--ease), color 0.2s;
}

.toc a:hover {
  padding-left: 8px;
  color: var(--accent-ink);
}

.toc .n {
  font-family: var(--font-display);
  font-size: 22px;
  color: var(--accent);
}

.toc .name {
  font-weight: 600;
  font-size: 18px;
}

.toc .role {
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--muted);
}

/* ───────── Article artiste ───────── */
.feature {
  border-top: 1px solid var(--rule);
  padding: clamp(40px, 6vw, 72px) 0 clamp(64px, 8vw, 112px);
  scroll-margin-top: 16px;
}

.feature__head {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 24px;
  align-items: end;
  margin-bottom: clamp(32px, 5vw, 56px);
}

.feature__num {
  font-family: var(--font-display);
  font-size: clamp(72px, 10vw, 136px);
  line-height: 0.8;
  color: var(--accent);
}

.feature__name {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(48px, 7vw, 96px);
  line-height: 0.9;
  margin: 0;
}

.feature__info {
  text-align: right;
  font-size: 13px;
  line-height: 1.7;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
}

.feature__grid {
  display: grid;
  grid-template-columns: minmax(0, 5fr) minmax(0, 7fr);
  gap: clamp(32px, 6vw, 88px);
  align-items: start;
}

.feature:nth-of-type(even) .feature__grid {
  grid-template-columns: minmax(0, 7fr) minmax(0, 5fr);
}

.feature:nth-of-type(even) .feature__photo {
  order: 2;
}

.feature__photo {
  position: sticky;
  top: 24px;
}

/* photo en arche : coins courbes du manuel */
.arch {
  aspect-ratio: 4 / 5;
  border-radius: 999px 999px 0 0;
  overflow: hidden;
  background: var(--surface);
}

.arch img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: grayscale(1) contrast(1.1);
}

.caption {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  font-size: 12px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted);
  padding-top: 12px;
  border-top: 1px solid var(--rule);
  margin-top: 16px;
}

.pull {
  font-family: var(--font-display);
  font-weight: 400;
  font-size: clamp(30px, 3.6vw, 48px);
  line-height: 1.05;
  color: var(--quote);
  margin: 0 0 40px;
}

.pull::before {
  content: "“";
  color: var(--accent);
}

.pull::after {
  content: "”";
  color: var(--accent);
}

.qa {
  margin: 0;
  display: grid;
  gap: 28px;
}

.qa dt {
  font-size: 13px;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  font-weight: 700;
  display: flex;
  gap: 12px;
}

.qa dt::before {
  content: "Q";
  color: var(--accent-ink);
}

.qa dd {
  margin: 8px 0 0;
  font-size: 18px;
  line-height: 1.75;
}

/* tags */
.tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 0 0 32px;
  padding: 0;
  list-style: none;
}

.tag {
  font-size: 12px;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  border: 1px solid var(--rule);
  border-radius: 999px;
  padding: 6px 12px;
}

.tag--fill {
  background: var(--ink);
  color: var(--bg);
}

/* ───────── Lecteur ───────── */
.listen {
  margin-top: 48px;
  padding-top: 24px;
  border-top: 1px solid var(--rule);
  display: grid;
  gap: 16px;
}

.player {
  --progress: 0;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 16px;
  align-items: center;
}

.play {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  border: 0;
  background: var(--ink);
  color: var(--bg);
  display: grid;
  place-items: center;
  cursor: pointer;
  position: relative;
  transition: transform 0.25s var(--ease), background 0.25s;
}

.play:hover {
  transform: scale(1.05);
  background: var(--fresca-blush);
}

.is-playing .play {
  background: var(--accent);
  color: var(--bg);
}

.play svg {
  width: 24px;
  height: 24px;
}

.play .i-pause,
.is-playing .play .i-play {
  display: none;
}

.is-playing .play .i-pause {
  display: block;
}

.wave {
  position: relative;
  height: 64px;
}

.wave canvas {
  width: 100%;
  height: 100%;
  display: block;
}

.wave::after {
  /* progression sous l'onde */
  content: "";
  position: absolute;
  left: 0;
  bottom: 0;
  height: 2px;
  width: calc(var(--progress) * 100%);
  background: var(--accent);
}

.player__time {
  font-variant-numeric: tabular-nums;
  font-size: 14px;
  color: var(--muted);
  min-width: 84px;
  text-align: right;
}

.player__time .js-time {
  color: var(--ink);
  font-weight: 600;
}

.listen__row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
  font-size: 12px;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  color: var(--muted);
}

.link-arrow {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 14px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  text-decoration: none;
  color: var(--ink);
  padding-bottom: 4px;
  background: linear-gradient(var(--accent), var(--accent)) left bottom / 100% 2px no-repeat;
  transition: background-size 0.3s var(--ease), gap 0.3s var(--ease);
}

.link-arrow:hover {
  gap: 16px;
  background-size: 100% 100%;
  color: var(--bg);
}

.link-arrow svg {
  width: 18px;
  height: 18px;
}

/* bouton plein (usage secondaire) */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  min-height: 48px;
  padding: 0 24px;
  border-radius: 999px;
  border: 1px solid var(--rule);
  font: 700 13px/1 var(--font-body);
  letter-spacing: 0.12em;
  text-transform: uppercase;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.2s, color 0.2s;
}

.btn--ink {
  background: var(--ink);
  color: var(--bg);
}

.btn--ink:hover {
  background: var(--accent);
  border-color: var(--accent);
}

.btn--line {
  background: transparent;
  color: var(--ink);
}

.btn--line:hover {
  background: var(--ink);
  color: var(--bg);
}

/* ───────── Pied de page ───────── */
.colophon {
  background: rgba(0, 0, 0, 0.35);
  border-top: 1px solid var(--line);
  color: var(--fresca-cream);
}

.colophon .wrap {
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 40px;
  align-items: center;
  padding-top: 56px;
  padding-bottom: 56px;
}

.colophon img {
  width: 88px;
  height: auto;
}

.colophon p {
  margin: 0;
  max-width: 56ch;
  line-height: 1.7;
  font-size: 15px;
  color: rgba(254, 253, 228, 0.72);
}

.colophon .btn {
  border-color: var(--fresca-cream);
  color: var(--fresca-cream);
}

.colophon .btn:hover {
  background: var(--fresca-cream);
  color: var(--bg);
}

@media (max-width: 860px) {
  .cover,
  .feature__grid,
  .feature:nth-of-type(even) .feature__grid {
    grid-template-columns: 1fr;
  }

  .feature:nth-of-type(even) .feature__photo {
    order: 0;
  }

  .feature__photo {
    position: static;
    max-width: 420px;
  }

  .feature__head {
    grid-template-columns: auto 1fr;
  }

  .feature__info {
    grid-column: 1 / -1;
    text-align: left;
  }

  .masthead__meta .hide-sm {
    display: none;
  }

  .colophon .wrap {
    grid-template-columns: 1fr;
  }
}
