/* P08.1: client-requested mobile composition and complete agency phase descriptions. */
/* P08.1.1: layout spans must inherit the routine heading's original white,
   rather than the generic h2 span green rule in refinement.css. */
.routine h2 .mobile-copy-line { color:inherit; }
.phase-panel p { padding-bottom:28px; }
@media (max-width:640px) {
  .health h2 > span,
  .routine h2 .mobile-copy-line,
  .routine-message .constancy .mobile-copy-line {
    display: block;
    white-space: nowrap;
  }
  .benefit-photo { align-self: center; margin: 0; }
  .routine-message .constancy { font-size: clamp(18px,calc(5vw + .5px),23px); }
  /* Original panorama: product/utensil group center is ~369/2048 px, not canvas center.
     Scale its full 75..661 px extent into the viewport; retain the existing source. */
  .closing { --closing-photo-height: max(260px,76.12vw); }
  .closing::before {
    height: var(--closing-photo-height);
    background-size: auto var(--closing-photo-height);
    background-position: min(0px,calc(50vw - 171px)) top;
  }
  .closing > .section-inner { padding-top: calc(var(--closing-photo-height) + 20px); }
}
@media (max-width:375px) {
  /* Keep the seal readable rather than shrinking it beside three forced text lines. */
  .routine-message { grid-template-columns:minmax(0,1fr); row-gap:12px; justify-items:center; }
  .month-badge { width:76px; grid-column:1; grid-row:1; }
  .routine-message .constancy { grid-column:1; grid-row:2; text-align:center; font-size:clamp(21px,6.667vw,23px); }
  .routine-message .duration { grid-column:1; grid-row:3; }
}
@media (min-width:641px) and (max-width:1250px) {
  .phase-panel { height:auto; }
}
@media (min-width:1024px) {
  .phase-panel { min-height:638px; }
  .phases > .section-inner { height:calc(920px + var(--phase-extra-height,0px)); }
}
@media (min-width:1251px) {
  /* Keep the original first-column overlay; grow only for a longer selected description. */
  .phase-panel { height:auto; min-height:626px; }
}
