/* Past-service pages; colours, type and the language switch come from viewer.css. */
.archive-shell {
  width: min(100%, 760px); min-height: 100dvh; margin: 0 auto;
  padding: max(16px, env(safe-area-inset-top)) max(16px, env(safe-area-inset-right)) max(32px, env(safe-area-inset-bottom)) max(16px, env(safe-area-inset-left));
}
.archive-shell .viewer-modes { margin: 14px 0 8px; }
.archive-header { display: flex; align-items: center; justify-content: space-between; gap: 10px; min-height: 44px; }
.archive-title { min-width: 0; margin: 0; color: #fff; font-size: 1.125rem; font-weight: 700; line-height: 1.3; }
a { color: inherit; -webkit-tap-highlight-color: transparent; }
.archive-live-link, .archive-back {
  flex: none; display: inline-flex; align-items: center; gap: 6px; min-height: 44px; border-radius: 999px; padding: 0 14px;
  background: var(--chip); color: var(--dim); font-size: .875rem; font-weight: 700; text-decoration: none; white-space: nowrap;
}
.archive-back { padding-left: 10px; }
.archive-back svg { width: 16px; height: 16px; }
.archive-live-link .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--faint); }
.archive-live-link[data-live="true"] { color: #fecaca; background: rgb(220 38 38 / .2); }
.archive-live-link[data-live="true"] .dot { background: var(--live); animation: viewer-pulse 1.6s ease-in-out infinite; }
.archive-live-link:focus-visible, .archive-back:focus-visible, .archive-item:focus-visible, .archive-live-note:focus-visible { outline: 3px solid var(--accent); outline-offset: 3px; }
.archive-status { margin: 24px 4px; color: var(--dim); font-size: 1rem; line-height: 1.5; }

/* ── List ── */
.archive-day { margin-top: 18px; }
.archive-day-title { margin: 0 4px 8px; color: var(--faint); font-size: .8125rem; font-weight: 700; letter-spacing: .02em; }
.archive-items { display: grid; gap: 8px; margin: 0; padding: 0; list-style: none; }
.archive-item {
  display: grid; gap: 4px; border: 1px solid var(--line); border-radius: 16px; padding: 14px 16px;
  background: rgb(148 163 184 / .06); text-decoration: none; transition: background-color .15s, transform .25s var(--spring);
}
.archive-item:active { transform: scale(.98); background: rgb(125 211 252 / .08); }
.archive-item-top { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 10px; }
.archive-item-kind { color: var(--accent); font-size: .9375rem; font-weight: 700; }
.archive-item-time { color: var(--dim); font-size: .875rem; font-variant-numeric: tabular-nums; }
.archive-badge { border-radius: 999px; padding: 2px 8px; background: rgb(220 38 38 / .2); color: #fecaca; font-size: .75rem; font-weight: 750; }
.archive-item-title { color: #fff; font-size: 1.0625rem; font-weight: 650; line-height: 1.4; overflow-wrap: anywhere; }
.archive-item-scripture, .archive-item-count { color: var(--dim); font-size: .8125rem; line-height: 1.4; }

/* ── One service ── */
.archive-service-head { margin-top: 12px; }
.archive-kind { margin: 0; color: var(--accent); font-size: .875rem; font-weight: 700; line-height: 1.4; }
.archive-service-title { margin: 4px 0 0; color: #fff; font-size: 1.375rem; font-weight: 700; line-height: 1.35; overflow-wrap: anywhere; }
.archive-meta { margin: 6px 0 0; color: var(--dim); font-size: .875rem; line-height: 1.4; }
.archive-live-note {
  display: block; margin-top: 12px; border-radius: 14px; padding: 12px 14px; background: rgb(220 38 38 / .16);
  color: #fecaca; font-size: .9375rem; font-weight: 650; line-height: 1.45; text-decoration: none;
}
.archive-captions { margin-top: 6px; }
.archive-caption { padding: 16px 4px; border-bottom: 1px solid var(--line); }
.archive-caption:last-child { border-bottom: 0; }
