/* Logged-in home banner (hero-member): greeting row, quick actions, one calm card. Sits outside .wrap, so it sets its own gutters. */
.hm { position: relative; isolation: isolate; overflow: hidden; width: 100%; background: var(--bg); border-bottom: 1px solid var(--line); }
.hm .hb-shade { background: linear-gradient(180deg, color-mix(in srgb, var(--bg) 78%, transparent), color-mix(in srgb, var(--bg) 66%, transparent) 55%, var(--bg)); }
.hm .hg-tctl { z-index: 4; right: max(var(--gutter), calc((100vw - var(--page)) / 2 + var(--gutter))); bottom: var(--s-3); }
.hm-wrap { position: relative; z-index: 3; max-width: var(--page); margin: 0 auto; padding: var(--s-5) var(--gutter) calc(var(--s-5) + var(--s-6)); display: flex; flex-direction: column; gap: var(--s-5); box-sizing: border-box; }

.hm-head { display: flex; flex-wrap: wrap; align-items: flex-end; justify-content: space-between; gap: var(--s-4); }
.hm-hd { min-width: 0; }
.hm-hello { margin: 0; font: 800 clamp(30px, 4.4vw, 48px)/var(--lh-tight) var(--font-display); font-stretch: 80%; letter-spacing: -.02em; color: var(--text-strong); text-wrap: balance; }
.hm-counts { margin: var(--s-1) 0 0; font-size: var(--t-base); color: var(--mute); } .hm-counts:empty { display: none; }
.hm-quick { display: flex; flex-wrap: wrap; gap: var(--s-2); }
.hm-quick .btn, .hm-actions .btn { display: inline-flex; align-items: center; gap: var(--s-2); }

/* the card */
.hm-card { background: color-mix(in srgb, var(--surface-1) 90%, transparent); border: 1px solid var(--line); border-radius: var(--r-xl); padding: var(--card-pad); }
.hm-card[hidden] { display: none; }
.hm-stage { display: grid; min-height: 280px; outline: none; border-radius: var(--r-lg); }
.hm-stage:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.hm-slide { grid-area: 1 / 1; opacity: 0; visibility: hidden; transition: opacity var(--med) var(--ease), visibility 0s var(--med); min-width: 0; }
.hm-slide.on { opacity: 1; visibility: visible; transition: opacity var(--med) var(--ease), visibility 0s; }
.hm-in { display: flex; align-items: center; gap: var(--s-6); height: 100%; }
.hm-copy { min-width: 0; flex: 1; display: flex; flex-direction: column; align-items: flex-start; gap: var(--s-3); }
.hm-kicker { font: 600 var(--t-sm)/1.2 var(--font-body); color: var(--accent-hi); }
.hm-title { margin: 0; font: 800 clamp(28px, 3.6vw, 44px)/var(--lh-tight) var(--font-display); font-stretch: 80%; letter-spacing: -.02em; color: var(--text-strong); text-wrap: balance;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.hm-sub { margin: 0; color: var(--text); font-size: var(--t-base); line-height: var(--lh-body); max-width: 52ch; }
.hm-sub.clamp { display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; }
.hm-meta { margin: 0; color: var(--mute); font-size: var(--t-base); }
.hm-chips { display: flex; flex-wrap: wrap; gap: var(--s-2); }
.hm-chip { display: inline-flex; align-items: center; gap: var(--s-1); padding: var(--s-1) var(--s-3); font-size: var(--t-sm); font-weight: 600; border-radius: var(--r-pill); background: var(--surface-2); border: 1px solid var(--line); color: var(--text); }
.hm-chip.svc { background: var(--accent-soft); border-color: var(--accent-line); color: var(--accent-hi); }
.hm-actions { display: flex; flex-wrap: wrap; gap: var(--s-2); margin-top: var(--s-2); }
.hm-actions .btn.done { opacity: .7; }

/* art */
.hm-art { flex: none; }
.hm-pl { display: block; border-radius: var(--r-poster); }
.hm-pl:focus-visible { outline: 2px solid var(--accent); outline-offset: 4px; }
.hm-poster { width: 180px; aspect-ratio: 2 / 3; border-radius: var(--r-poster); overflow: hidden; box-shadow: var(--shadow-2); }
.hm-poster .poster { width: 100%; height: 100%; border-radius: 0; font-size: var(--t-base); }
.hm-viz { flex: 0 1 420px; min-width: 0; }

/* countdown, hype, progress */
.hm-cdlab { font-size: var(--t-sm); color: var(--mute); font-weight: 600; }
.hm-cd { display: flex; gap: var(--s-2); }
.hm-cell { min-width: 64px; padding: var(--s-2) var(--s-2) var(--s-1); text-align: center; border-radius: var(--r-md); background: var(--surface-2); border: 1px solid var(--line); }
.hm-cell b { display: block; font: 800 28px/1 var(--font-display); font-stretch: 80%; font-variant-numeric: tabular-nums; color: var(--text-strong); }
.hm-cell span { font-size: var(--t-xs); color: var(--mute); }
.hm-now { display: inline-flex; align-items: center; gap: var(--s-2); font: 700 var(--t-lg) var(--font-display); color: var(--text-strong); }
.hm-hype { display: flex; align-items: center; gap: var(--s-2); color: var(--mute); font-size: var(--t-sm); width: min(320px, 100%); }
.hm-hype b { color: var(--text-strong); font-variant-numeric: tabular-nums; }
.hm-bar { flex: 1; height: 6px; border-radius: var(--r-pill); background: var(--surface-3); overflow: hidden; }
.hm-bar i { display: block; height: 100%; width: 100%; transform-origin: left; transform: scaleX(var(--v, 0)); border-radius: var(--r-pill); background: var(--accent); }
.hm-eps { display: flex; gap: var(--s-1); }
.hm-eps i { width: 22px; height: 6px; border-radius: var(--r-pill); background: var(--surface-3); }
.hm-eps i.on { background: var(--accent); }

/* friends */
.hm-feed { list-style: none; margin: 0; padding: 0; display: flex; flex-direction: column; width: min(520px, 100%); }
.hm-feed li { display: flex; align-items: center; gap: var(--s-3); padding: var(--s-2) 0; border-top: 1px solid var(--line); }
.hm-feed li:first-child { border-top: 0; }
.hm-fav { flex: none; display: grid; place-items: center; width: 34px; height: 34px; border-radius: 50%; overflow: hidden; }
.hm-ft { flex: 1; min-width: 0; font-size: var(--t-base); color: var(--text); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; } .hm-ft b { color: var(--text-strong); font-weight: 650; }
.hm-ft a { color: var(--accent-hi); text-decoration: none; } .hm-ft a:hover { text-decoration: underline; }
.hm-feed time { flex: none; color: var(--mute); font-size: var(--t-xs); }

/* stats */
.hm-tiles { display: flex; flex-wrap: wrap; gap: var(--s-2) var(--s-6); }
.hm-tile b { display: block; font: 800 34px/1 var(--font-display); font-stretch: 80%; font-variant-numeric: tabular-nums; color: var(--text-strong); }
.hm-tile span { font-size: var(--t-sm); color: var(--mute); }
.hm-mile { display: flex; align-items: center; gap: var(--s-2); font-size: var(--t-sm); color: var(--mute); width: min(420px, 100%); flex-wrap: wrap; }
.hm-mile .hm-bar { flex-basis: 100%; }
.hm-months { margin: 0; padding: var(--s-4); border-radius: var(--r-lg); background: var(--surface-2); border: 1px solid var(--line); }
.hm-bars-row { display: flex; align-items: flex-end; gap: var(--s-1); height: 150px; }
.hm-mo { flex: 1; min-width: 0; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: flex-end; gap: var(--s-1); }
.hm-mo em { font-style: normal; font-size: var(--t-xs); color: var(--mute); font-variant-numeric: tabular-nums; min-height: 1em; line-height: 1; }
.hm-mo i { display: block; width: 100%; max-width: 28px; height: calc(var(--v, 0) * 96px); min-height: 3px; border-radius: var(--r-xs) var(--r-xs) 0 0; background: var(--accent); }
.hm-mo i.z { background: var(--surface-3); }
.hm-mo span { font-size: var(--t-xs); color: var(--mute); }
.hm-months figcaption { margin-top: var(--s-3); font-size: var(--t-xs); color: var(--mute); }

/* controls */
.hm-foot { display: flex; align-items: center; gap: var(--s-2); margin-top: var(--s-4); padding-top: var(--s-3); border-top: 1px solid var(--line); }
.hm-card.single .hm-foot, .hm-card.loading .hm-foot { display: none; }
.hm-pips { display: flex; flex: 1; align-items: center; margin-left: var(--s-2); min-width: 0; }
.hm-pip { height: var(--ctl); width: 28px; padding: 0; border: 0; background: transparent; cursor: pointer; display: flex; align-items: center; justify-content: center; border-radius: var(--r-sm); }
.hm-pip i { display: block; width: 8px; height: 8px; border-radius: var(--r-pill); background: var(--line-strong); transition: width var(--fast) var(--ease), background var(--fast); }
.hm-pip:hover i { background: var(--mute); }
.hm-pip.on i { width: 22px; background: var(--accent); }
.hm-pip:focus-visible, .hm-nav:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.hm-nav { display: grid; place-items: center; flex: none; width: var(--ctl); height: var(--ctl); padding: 0; border-radius: var(--r-md); border: 1px solid var(--line); background: var(--surface-2); color: var(--text); cursor: pointer; }
.hm-nav:hover { background: var(--surface-3); }
.hm-bars { display: inline-flex; gap: 3px; } .hm-bars i { width: 3px; height: 12px; background: currentColor; border-radius: 1px; }
.hm-live { position: absolute; width: 1px; height: 1px; overflow: hidden; clip-path: inset(50%); }

/* skeleton: same footprint as a slide */
.hm-sk { grid-area: 1 / 1; display: flex; align-items: center; gap: var(--s-6); }
.hm-sk-art { flex: none; width: 180px; aspect-ratio: 2 / 3; border-radius: var(--r-poster); background: var(--skeleton); }
.hm-sk-copy { flex: 1; display: flex; flex-direction: column; gap: var(--s-3); }
.hm-sk-copy i { display: block; height: 14px; border-radius: var(--r-xs); background: var(--skeleton); }
.hm-sk-copy i.big { height: 40px; } .hm-sk-copy i.btn { height: var(--ctl); border-radius: var(--r-md); border: 0; }

@media (max-width: 760px) {
  .hm-wrap { padding-top: var(--s-4); gap: var(--s-4); }
  .hm-quick { width: 100%; } .hm-quick .btn { flex: 1 1 0; justify-content: center; padding-inline: var(--s-2); }
  .hm-stage { min-height: 0; }
  .hm-in { display: grid; grid-template-columns: 88px minmax(0, 1fr); gap: var(--s-3) var(--s-4); align-items: start; }
  .hm-copy { display: contents; }
  .hm-copy > * { grid-column: 1 / -1; }
  .hm-copy > .hm-kicker, .hm-copy > .hm-title, .hm-copy > .hm-meta { grid-column: 2; }
  .hm-slide.noart .hm-copy > * { grid-column: 1 / -1; }
  .hm-art { grid-column: 1; grid-row: 1 / span 3; }
  .hm-poster { width: 88px; }
  .hm-title { font-size: clamp(24px, 7vw, 32px); }
  .hm-viz { grid-column: 1 / -1; flex: none; }
  .hm-actions { width: 100%; } .hm-actions .btn.primary { flex: 1 1 100%; justify-content: center; }
  .hm-cell { min-width: 0; flex: 1; }
  .hm-bars-row { height: 120px; } .hm-mo i { height: calc(var(--v, 0) * 70px); }
  .hm-pip { width: 24px; }
  .hm-sk { gap: var(--s-4); align-items: flex-start; } .hm-sk-art { width: 88px; }
}
@media (prefers-reduced-motion: reduce) {
  .hm-slide, .hm-slide.on, .hm-pip i { transition: none; }
}
