/* Cymruera Fix Your Life v5 — approved complete balanced editorial layout.
   v4 remains immutable; this layer only styles v5 wrappers and poster media. */

.fixlife-v5 .podcast-chapter { --poster-accent: var(--unun-orange); }
.fixlife-v5 .podcast-chapter--1,
.fixlife-v5 .podcast-chapter--4,
.fixlife-v5 .podcast-chapter--7 { --poster-accent: var(--unun-purple); }
.fixlife-v5 .podcast-chapter--2,
.fixlife-v5 .podcast-chapter--5 { --poster-accent: var(--unun-yellow); }
.fixlife-v5 .podcast-chapter--3,
.fixlife-v5 .podcast-chapter--6 { --poster-accent: var(--unun-orange); }

.fixlife-v5 .podcast-beat {
  display: grid;
  grid-template-columns: minmax(0, 430px) minmax(0, 1fr);
  align-items: start;
  gap: clamp(2rem, 4vw, 4.5rem);
  width: 100%;
  margin: clamp(3rem, 5vw, 4.75rem) 0;
}
.fixlife-v5 .podcast-beat--reverse {
  grid-template-columns: minmax(0, 1fr) minmax(0, 430px);
}
.fixlife-v5 .podcast-beat--reverse > .podcast-poster,
.fixlife-v5 .podcast-beat--reverse > .podcast-poster-pair { order: 2; }
.fixlife-v5 .podcast-beat--reverse > .podcast-copy { justify-self: end; }

.fixlife-v5 .podcast-beat--short {
  grid-template-columns: minmax(0, 340px) minmax(0, 1fr);
  align-items: center;
  margin-block: clamp(2.4rem, 4vw, 3.6rem);
}
.fixlife-v5 .podcast-beat--medium {
  grid-template-columns: minmax(0, 390px) minmax(0, 1fr);
  align-items: center;
  margin-block: clamp(2.7rem, 4.5vw, 4.1rem);
}
.fixlife-v5 .podcast-beat--reverse.podcast-beat--short {
  grid-template-columns: minmax(0, 1fr) minmax(0, 340px);
}
.fixlife-v5 .podcast-beat--reverse.podcast-beat--medium {
  grid-template-columns: minmax(0, 1fr) minmax(0, 390px);
}
.fixlife-v5 .podcast-beat--short .podcast-poster { max-width: 340px; }
.fixlife-v5 .podcast-beat--medium .podcast-poster { max-width: 390px; }
.fixlife-v5 .podcast-beat--short .podcast-copy,
.fixlife-v5 .podcast-beat--medium .podcast-copy { align-self: center; }

.fixlife-v5 .podcast-density-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(3rem, 5vw, 4.5rem) clamp(1.6rem, 3.4vw, 2.75rem);
  width: 100%;
  margin: clamp(3rem, 5vw, 4.75rem) 0;
}
.fixlife-v5 .podcast-density-grid > .podcast-beat {
  display: flex;
  flex-direction: column;
  gap: 1.15rem;
  min-width: 0;
  margin: 0;
}
.fixlife-v5 .podcast-density-grid > .podcast-beat > .podcast-poster {
  order: 0;
  width: 100%;
  max-width: none;
}
.fixlife-v5 .podcast-density-grid > .podcast-beat > .podcast-copy {
  align-self: stretch;
  justify-self: stretch;
  width: 100%;
  max-width: none;
  margin: 0;
  padding-top: 0;
}
.fixlife-v5 .podcast-density-grid .podcast-copy p,
.fixlife-v5 .podcast-density-grid .podcast-copy li {
  font-size: clamp(1rem, 1.15vw, 1.08rem);
  line-height: 1.68;
}
@media (min-width: 1101px) {
  .fixlife-v5 .podcast-density-grid--3 {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.fixlife-v5 .podcast-copy {
  min-width: 0;
  max-width: 650px;
  padding-top: clamp(.25rem, 1.3vw, 1rem);
}
.fixlife-v5 .podcast-copy > :first-child { margin-top: 0; }
.fixlife-v5 .podcast-copy > :last-child { margin-bottom: 0; }
.fixlife-v5 .podcast-copy p,
.fixlife-v5 .podcast-copy li {
  font-size: clamp(1.03rem, 1.35vw, 1.14rem);
  line-height: 1.78;
}
.fixlife-v5 .podcast-copy blockquote { margin-top: 0; }
.fixlife-v5 .podcast-copy ol,
.fixlife-v5 .podcast-copy ul { margin-block: 1.2rem; }

.fixlife-v5 .podcast-poster {
  position: relative;
  z-index: 0;
  width: 100%;
  margin: 0;
  padding: 9px;
  border: 1px solid color-mix(in srgb, var(--poster-accent) 36%, var(--line));
  border-radius: 32px;
  background: var(--card);
  box-shadow: 0 17px 48px rgba(9, 16, 26, .11), 0 4px 14px rgba(53, 38, 23, .08);
}
.fixlife-v5 .podcast-poster::after {
  position: absolute;
  z-index: -1;
  inset: 18px -13px -13px 18px;
  border-radius: 32px;
  background: color-mix(in srgb, var(--poster-accent) 20%, transparent);
  content: "";
}
.fixlife-v5 .podcast-poster picture,
.fixlife-v5 .podcast-poster img {
  display: block;
  width: 100%;
}
.fixlife-v5 .podcast-poster img {
  height: auto;
  aspect-ratio: 3 / 4;
  border-radius: 23px;
  background: #f3e6d5;
  object-fit: cover;
}

.fixlife-v5 .podcast-reading-bridge {
  width: min(100%, 820px);
  margin: clamp(2.6rem, 6vw, 5.2rem) auto;
}
.fixlife-v5 .podcast-reading-bridge > :first-child { margin-top: 0; }
.fixlife-v5 .podcast-reading-bridge > :last-child { margin-bottom: 0; }
.fixlife-v5 .podcast-reading-bridge > h3,
.fixlife-v5 .podcast-chapter > h3 {
  scroll-margin-top: calc(var(--article-header-height) + 1.5rem);
}
.fixlife-v5 .podcast-intro-outro {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: .85rem;
  width: 100%;
  max-width: none;
  padding: clamp(1.4rem, 3.6vw, 2.8rem);
  border: 1px solid var(--line);
  border-radius: 30px;
  background: linear-gradient(135deg, var(--card), color-mix(in srgb, var(--unun-purple) 8%, var(--card)));
  box-shadow: var(--shadow);
}
.fixlife-v5 .podcast-intro-outro > p { margin: 0; }
.fixlife-v5 .podcast-intro-outro > p:first-child,
.fixlife-v5 .podcast-intro-outro > p:nth-last-child(-n+2) { grid-column: 1 / -1; }
.fixlife-v5 .podcast-intro-outro > p:nth-child(2),
.fixlife-v5 .podcast-intro-outro > p:nth-child(3),
.fixlife-v5 .podcast-intro-outro > p:nth-child(4) {
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: 19px;
  background: var(--bg);
  font-family: var(--sans);
  font-size: .94rem;
  font-weight: 850;
  line-height: 1.5;
}
.fixlife-v5 .podcast-intro-outro > p:last-child {
  color: var(--unun-orange-action);
  font-family: var(--sans);
  font-size: clamp(1.55rem, 3vw, 2.3rem);
  font-weight: 950;
}
.fixlife-v5 .podcast-chapter-outro {
  padding-top: 2rem;
  border-top: 1px solid var(--line);
}

.fixlife-v5 .podcast-concept-deck {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(1.2rem, 3vw, 2.2rem);
  width: 100%;
  margin: clamp(3rem, 5vw, 4.75rem) 0;
}
.fixlife-v5 .podcast-beat--compare { grid-template-columns: 1fr; }
.fixlife-v5 .podcast-beat--compare > .podcast-poster-pair { order: 0; }
.fixlife-v5 .podcast-beat--compare .podcast-copy {
  justify-self: center;
  width: min(100%, 820px);
  max-width: none;
  margin-inline: auto;
}
.fixlife-v5 .podcast-poster-pair {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: clamp(1.2rem, 3vw, 2.2rem);
  min-width: 0;
}

/* The complete poster sits outside the question panel. */
.fixlife-v5 .worksheet-visual-phase {
  display: grid;
  grid-template-columns: minmax(0, 430px) minmax(0, 1fr);
  align-items: stretch;
  gap: clamp(1.6rem, 3.4vw, 3rem);
  margin: clamp(2.4rem, 4.5vw, 4rem) 0;
}
.fixlife-v5 .worksheet-visual-phase > .podcast-poster {
  --poster-accent: var(--unun-orange);
  align-self: start;
  width: 100%;
  max-width: 430px;
}
.fixlife-v5 .worksheet-question-panel {
  display: flex;
  flex-direction: column;
  min-width: 0;
  min-height: 0;
  padding: clamp(1rem, 2vw, 1.4rem);
  border: 1px solid color-mix(in srgb, var(--poster-accent) 25%, var(--line));
  border-radius: 28px;
  background: color-mix(in srgb, var(--poster-accent) 5%, var(--bg));
}
.fixlife-v5 .worksheet-question-panel > .groupTitle {
  margin: 0 0 1rem;
  color: var(--ink);
  font-size: clamp(1.05rem, 1.8vw, 1.42rem);
  font-weight: 950;
  letter-spacing: -.015em;
  line-height: 1.3;
  text-transform: none;
}
.fixlife-v5 .worksheet-question-stack {
  flex: 1;
  min-width: 0;
  min-height: 0;
}
.fixlife-v5 .worksheet-question-stack > div {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  align-items: start;
  gap: .72rem;
}
.fixlife-v5 .worksheet-question-stack .qcard {
  display: flex;
  flex-direction: column;
  min-height: 0;
  margin: 0;
}
.fixlife-v5 .worksheet-question-stack .qhead { padding: .58rem .68rem; }
.fixlife-v5 .worksheet-question-stack .qtext {
  font-size: clamp(.82rem, 1.05vw, .93rem);
  line-height: 1.42;
}
.fixlife-v5 .worksheet-question-stack .qcard textarea {
  flex: 1;
  min-height: 2.7rem;
  padding: .52rem .68rem;
  font-size: .88rem;
}
.fixlife-v5 .worksheet-visual-phase--3 .qcard:last-child { grid-column: 1 / -1; }

@media (prefers-color-scheme: dark) {
  :root:not([data-theme="light"]) { --bg: #000000; }
  :root:not([data-theme="light"]) .fixlife-v5 .podcast-poster {
    box-shadow: 0 18px 52px rgba(0, 0, 0, .32), 0 4px 16px rgba(0, 0, 0, .2);
  }
}
:root[data-theme="dark"] { --bg: #000000; }
:root[data-theme="dark"] .fixlife-v5 .podcast-poster {
  box-shadow: 0 18px 52px rgba(0, 0, 0, .32), 0 4px 16px rgba(0, 0, 0, .2);
}

@media (max-width: 1050px) and (min-width: 821px) {
  .fixlife-v5 .worksheet-visual-phase {
    grid-template-columns: minmax(0, 350px) minmax(0, 1fr);
    gap: 1.5rem;
  }
  .fixlife-v5 .worksheet-visual-phase > .podcast-poster { max-width: 350px; }
  .fixlife-v5 .worksheet-question-stack > div { grid-template-columns: minmax(0, 1fr); }
  .fixlife-v5 .worksheet-visual-phase--3 .qcard:last-child { grid-column: auto; }
}

@media (max-width: 820px) {
  .fixlife-v5 .podcast-density-grid { grid-template-columns: minmax(0, 1fr); }
  .fixlife-v5 .podcast-beat,
  .fixlife-v5 .podcast-beat--reverse,
  .fixlife-v5 .podcast-beat--short,
  .fixlife-v5 .podcast-beat--medium,
  .fixlife-v5 .podcast-beat--reverse.podcast-beat--short,
  .fixlife-v5 .podcast-beat--reverse.podcast-beat--medium {
    grid-template-columns: minmax(0, 1fr);
    gap: 1.2rem;
    margin: 2.8rem 0 3.6rem;
  }
  .fixlife-v5 .podcast-density-grid {
    gap: 3.8rem;
    margin-block: 3rem 4rem;
  }
  .fixlife-v5 .podcast-density-grid > .podcast-beat { gap: 1.1rem; margin: 0; }
  .fixlife-v5 .podcast-beat--reverse > .podcast-poster,
  .fixlife-v5 .podcast-beat--reverse > .podcast-poster-pair { order: 0; }
  .fixlife-v5 .podcast-beat--reverse > .podcast-copy { justify-self: stretch; }
  .fixlife-v5 .podcast-beat--short .podcast-poster,
  .fixlife-v5 .podcast-beat--medium .podcast-poster { max-width: 540px; }
  .fixlife-v5 .podcast-poster {
    width: min(100%, 540px);
    margin-inline: auto;
    padding: 7px;
    border-radius: 27px;
  }
  .fixlife-v5 .podcast-poster::after {
    inset: 13px -8px -8px 13px;
    border-radius: 27px;
  }
  .fixlife-v5 .podcast-poster img { border-radius: 20px; }
  .fixlife-v5 .podcast-copy {
    width: min(100%, 680px);
    max-width: none;
    margin-inline: auto;
    padding-top: 0;
  }
  .fixlife-v5 .podcast-concept-deck,
  .fixlife-v5 .podcast-poster-pair { grid-template-columns: minmax(0, 1fr); }
  .fixlife-v5 .worksheet-visual-phase {
    grid-template-columns: minmax(0, 1fr);
    gap: 1.35rem;
  }
  .fixlife-v5 .worksheet-visual-phase > .podcast-poster {
    width: min(100%, 540px);
    max-width: 540px;
    margin-inline: auto;
  }
  .fixlife-v5 .worksheet-question-panel { min-height: 0; padding: .9rem; }
  .fixlife-v5 .worksheet-question-stack > div { grid-template-columns: minmax(0, 1fr); }
  .fixlife-v5 .worksheet-visual-phase--3 .qcard:last-child { grid-column: auto; }
  .fixlife-v5 .worksheet-question-stack .qtext { font-size: .95rem; }
  .fixlife-v5 .worksheet-question-stack .qcard textarea {
    min-height: 3.4rem;
    font-size: .95rem;
  }
  .fixlife-v5 .podcast-intro-outro { grid-template-columns: minmax(0, 1fr); }
  .fixlife-v5 .podcast-intro-outro > p,
  .fixlife-v5 .podcast-intro-outro > p:first-child,
  .fixlife-v5 .podcast-intro-outro > p:nth-last-child(-n+2) { grid-column: auto; }
}

@media (max-width: 520px) {
  .fixlife-v5 .podcast-beat,
  .fixlife-v5 .podcast-beat--reverse,
  .fixlife-v5 .podcast-beat--short,
  .fixlife-v5 .podcast-beat--medium,
  .fixlife-v5 .podcast-beat--reverse.podcast-beat--short,
  .fixlife-v5 .podcast-beat--reverse.podcast-beat--medium {
    margin-block: 2.5rem 3.25rem;
  }
  .fixlife-v5 .podcast-density-grid > .podcast-beat { margin: 0; }
  .fixlife-v5 .podcast-reading-bridge { margin-block: 2.6rem; }
  .fixlife-v5 .podcast-intro-outro { padding: 1rem; border-radius: 23px; }
}

@media print {
  .fixlife-v5 .podcast-density-grid,
  .fixlife-v5 .podcast-beat,
  .fixlife-v5 .podcast-concept-deck,
  .fixlife-v5 .podcast-poster-pair,
  .fixlife-v5 .worksheet-visual-phase { break-inside: avoid; }
  .fixlife-v5 .podcast-poster { box-shadow: none; }
  .fixlife-v5 .podcast-poster::after { display: none; }
}


/* Approved balanced layout: every argument remains an alternating editorial spread. */
.fixlife-v5 .podcast-density-grid { display: contents; }
.fixlife-v5 .podcast-density-grid > .podcast-beat {
  display: grid;
  align-items: center;
  gap: clamp(2.2rem, 4.2vw, 4.7rem);
  width: 100%;
}
.fixlife-v5 .podcast-density-grid > .podcast-beat--short {
  grid-template-columns: minmax(0, 360px) minmax(0, 1fr);
  margin: clamp(2.6rem, 4vw, 3.8rem) 0;
}
.fixlife-v5 .podcast-density-grid > .podcast-beat--medium {
  grid-template-columns: minmax(0, 400px) minmax(0, 1fr);
  margin: clamp(3rem, 4.6vw, 4.3rem) 0;
}
.fixlife-v5 .podcast-density-grid > .podcast-beat--reverse.podcast-beat--short {
  grid-template-columns: minmax(0, 1fr) minmax(0, 360px);
}
.fixlife-v5 .podcast-density-grid > .podcast-beat--reverse.podcast-beat--medium {
  grid-template-columns: minmax(0, 1fr) minmax(0, 400px);
}
.fixlife-v5 .podcast-beat--short,
.fixlife-v5 .podcast-density-grid > .podcast-beat--short {
  grid-template-columns: minmax(0, 360px) minmax(0, 1fr);
}
.fixlife-v5 .podcast-beat--medium,
.fixlife-v5 .podcast-density-grid > .podcast-beat--medium {
  grid-template-columns: minmax(0, 400px) minmax(0, 1fr);
}
.fixlife-v5 .podcast-beat--reverse.podcast-beat--short,
.fixlife-v5 .podcast-density-grid > .podcast-beat--reverse.podcast-beat--short {
  grid-template-columns: minmax(0, 1fr) minmax(0, 360px);
}
.fixlife-v5 .podcast-beat--reverse.podcast-beat--medium,
.fixlife-v5 .podcast-density-grid > .podcast-beat--reverse.podcast-beat--medium {
  grid-template-columns: minmax(0, 1fr) minmax(0, 400px);
}
.fixlife-v5 .podcast-beat--short .podcast-poster,
.fixlife-v5 .podcast-density-grid > .podcast-beat--short > .podcast-poster { max-width: 360px; }
.fixlife-v5 .podcast-beat--medium .podcast-poster,
.fixlife-v5 .podcast-density-grid > .podcast-beat--medium > .podcast-poster { max-width: 400px; }
.fixlife-v5 .podcast-density-grid > .podcast-beat--reverse > .podcast-poster,
.fixlife-v5 .podcast-density-grid > .podcast-beat--reverse > .podcast-poster-pair { order: 2; }
.fixlife-v5 .podcast-density-grid > .podcast-beat > .podcast-copy {
  align-self: center;
  width: auto;
  max-width: 650px;
  padding-top: 0;
}
.fixlife-v5 .podcast-density-grid > .podcast-beat--reverse > .podcast-copy {
  justify-self: end;
}
.fixlife-v5 .podcast-density-grid .podcast-copy p,
.fixlife-v5 .podcast-density-grid .podcast-copy li {
  font-size: clamp(1.03rem, 1.35vw, 1.14rem);
  line-height: 1.78;
}

/* Chapter VI has much more copy than artwork: let the copy flow beneath the poster. */
@media (min-width: 821px) {
  .fixlife-v5 .podcast-chapter--6 > .podcast-beat:first-of-type {
    display: flow-root;
  }
  .fixlife-v5 .podcast-chapter--6 > .podcast-beat:first-of-type > .podcast-poster {
    float: left;
    width: 430px;
    margin: 0 clamp(2rem, 4vw, 4.5rem) 1.5rem 0;
  }
  .fixlife-v5 .podcast-chapter--6 > .podcast-beat:first-of-type > .podcast-copy {
    width: auto;
    max-width: none;
  }
  .fixlife-v5 .podcast-chapter--6 > .podcast-beat:first-of-type > .podcast-copy > blockquote {
    overflow: hidden;
  }
  .fixlife-v5 .podcast-chapter--6 > .podcast-reading-bridge {
    margin-inline: 0 auto;
  }
}

/* A keeps a calmer single question column except for the seven-question phase. */
.fixlife-v5 .worksheet-visual-phase--4 .worksheet-question-stack > div,
.fixlife-v5 .worksheet-visual-phase--3 .worksheet-question-stack > div {
  grid-template-columns: minmax(0, 1fr);
}
.fixlife-v5 .worksheet-visual-phase--3 .qcard:last-child { grid-column: auto; }

@media (max-width: 820px) {
  .fixlife-v5 .podcast-density-grid { display: contents; }
  .fixlife-v5 .podcast-beat,
  .fixlife-v5 .podcast-beat--reverse,
  .fixlife-v5 .podcast-beat--short,
  .fixlife-v5 .podcast-beat--medium,
  .fixlife-v5 .podcast-beat--long,
  .fixlife-v5 .podcast-beat--reverse.podcast-beat--short,
  .fixlife-v5 .podcast-beat--reverse.podcast-beat--medium,
  .fixlife-v5 .podcast-density-grid > .podcast-beat,
  .fixlife-v5 .podcast-density-grid > .podcast-beat--short,
  .fixlife-v5 .podcast-density-grid > .podcast-beat--medium,
  .fixlife-v5 .podcast-density-grid > .podcast-beat--reverse.podcast-beat--short,
  .fixlife-v5 .podcast-density-grid > .podcast-beat--reverse.podcast-beat--medium {
    display: grid;
    grid-template-columns: minmax(0, 1fr);
    gap: 1.2rem;
    width: 100%;
    margin: 2.8rem 0 3.6rem;
  }
  .fixlife-v5 .podcast-beat--reverse > .podcast-poster,
  .fixlife-v5 .podcast-beat--reverse > .podcast-poster-pair,
  .fixlife-v5 .podcast-density-grid > .podcast-beat--reverse > .podcast-poster,
  .fixlife-v5 .podcast-density-grid > .podcast-beat--reverse > .podcast-poster-pair {
    order: 0;
  }
  .fixlife-v5 .podcast-beat--reverse > .podcast-copy,
  .fixlife-v5 .podcast-density-grid > .podcast-beat--reverse > .podcast-copy {
    justify-self: stretch;
  }
  .fixlife-v5 .podcast-beat > .podcast-copy,
  .fixlife-v5 .podcast-density-grid > .podcast-beat > .podcast-copy {
    grid-column: 1;
    width: min(calc(100% - 18px), 522px);
    max-width: none;
    margin-inline: auto;
  }
  .fixlife-v5 .podcast-beat > .podcast-poster,
  .fixlife-v5 .podcast-beat--short .podcast-poster,
  .fixlife-v5 .podcast-beat--medium .podcast-poster,
  .fixlife-v5 .podcast-density-grid > .podcast-beat > .podcast-poster,
  .fixlife-v5 .podcast-density-grid > .podcast-beat--short > .podcast-poster,
  .fixlife-v5 .podcast-density-grid > .podcast-beat--medium > .podcast-poster {
    float: none;
    grid-column: 1;
    width: min(100%, 540px);
    max-width: 540px;
    margin-inline: auto;
  }
  .fixlife-v5 .podcast-poster-pair { grid-template-columns: minmax(0, 1fr); }
  .fixlife-v5 .worksheet-question-stack > div { grid-template-columns: minmax(0, 1fr); }
}
