:root {
  --bg: #ffffff;
  --bg-soft: #f6f7fb;
  --bg-muted: #f0f1f5;
  --surface: #ffffff;
  --text: #20222b;
  --text-soft: #676b76;
  --text-faint: #9ea3af;
  --line: #ececf2;
  --line-strong: #e0e2ea;
  --accent: #e60000;
  --accent-strong: #ff3b30;
  --shadow-soft: 0 12px 28px rgba(24, 32, 56, 0.06);
  --radius-xl: 24px;
  --radius-lg: 18px;
  --radius-md: 14px;
  --radius-sm: 10px;
  --left-rail: 230px;
  --right-rail: 260px;
  --brand-text: #1c1f29;
  --interactive-text: #12141b;
  --toggle-track: var(--bg-muted);
  --toggle-knob: #ffffff;
  --toggle-shadow: 0 2px 4px rgba(0, 0, 0, 0.12);
  --hero-search-bg: var(--bg-soft);
  --hero-outline: rgba(255, 255, 255, 0.45);
}

[data-theme="dark"] {
  --bg: #0c0f15;
  --bg-soft: #151922;
  --bg-muted: #1b2130;
  --surface: #10141c;
  --text: #edf1f7;
  --text-soft: #a2abbb;
  --text-faint: #70798d;
  --line: #1d2432;
  --line-strong: #273041;
  --accent: #e60000;
  --accent-strong: #ff3b30;
  --shadow-soft: 0 16px 36px rgba(0, 0, 0, 0.32);
  --brand-text: #f3f6fb;
  --interactive-text: #f3f6fb;
  --toggle-track: #2a3345;
  --toggle-knob: #ffffff;
  --toggle-shadow: 0 4px 10px rgba(0, 0, 0, 0.28);
  --hero-search-bg: #151922;
  --hero-outline: rgba(255, 255, 255, 0.2);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: "Segoe UI", Arial, sans-serif;
  color: var(--text);
  background: var(--bg);
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

.layout {
  display: grid;
  grid-template-columns: var(--left-rail) minmax(0, 1fr);
  min-height: 100vh;
}

.left-rail {
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
  padding: 20px 22px 28px;
  border-right: 1px solid var(--line);
  background: var(--surface);
}

/* Desktop rail collapse (toggled by the hamburger; persisted in
   localStorage). The rail's own hamburger disappears with the rail,
   so the topbar hamburger is surfaced as the re-expand affordance.
   Scoped ≥981px — below that the rail is a drawer, not a column. */
@media (min-width: 981px) {
  body.mss-rail-collapsed .layout {
    grid-template-columns: minmax(0, 1fr);
  }

  body.mss-rail-collapsed .left-rail {
    display: none;
  }

  body.mss-rail-collapsed .topbar__menu-toggle {
    display: inline-flex;
  }
}

.brand {
  display: flex;
  align-items: center;
  gap: 14px;
}

.brand--rail {
  margin-bottom: 28px;
}

.brand__link {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  font-weight: 700;
}

.brand__logo {
  height: 20px;
  width: auto;
  display: block;
}

.brand__text {
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.brand__text--strong {
  font-weight: 900;
}

.brand__text--light {
  font-weight: 300;
}

.brand__mark {
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  color: var(--accent);
  font-size: 1.1rem;
}

.brand__mark--triangle {
  transform: scaleX(1.15);
}

.icon-button {
  display: inline-grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border: 0;
  border-radius: 12px;
  background: transparent;
  color: var(--interactive-text);
  cursor: pointer;
}

.icon-button--light:hover {
  background: var(--bg-soft);
}

.cta-button {
  display: inline-flex;
  width: 100%;
  justify-content: center;
  padding: 14px 18px;
  margin-bottom: 22px;
  border-radius: 12px;
  color: #fff;
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  font-weight: 600;
}

/* `[hidden]` MUST win over any element-class `display` (script.js
   toggles `el.hidden = true` on every [data-anonymous-cta] for
   signed-in callers). Without this, classes like `.cta-button`
   that set `display: inline-flex` would override the user-agent's
   default `[hidden] { display: none }`. */
[hidden] {
  display: none !important;
}

/* Pre-paint hide for signed-in callers — left-rail.php sets data-signed-in on
   <html> before the rail renders, so the anonymous CTA never flashes on a
   navigation (script.js still sets `hidden` on load as the authoritative path). */
html[data-signed-in] [data-anonymous-cta] {
  display: none !important;
}

.rail-section {
  margin-top: 18px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

.rail-section__title {
  margin: 0 0 12px;
  color: var(--text-faint);
  font-size: 0.9rem;
}

.rail-creators {
  display: grid;
  gap: 14px;
}

.rail-creator {
  display: flex;
  align-items: center;
  gap: 12px;
  color: var(--text);
}

.rail-creator__avatar {
  display: inline-grid;
  place-items: center;
  width: 40px;
  height: 40px;
  flex-shrink: 0;
  border-radius: 50%;
  overflow: hidden;
  background: var(--bg-muted);
  color: var(--text);
  font-weight: 600;
  font-size: 0.9rem;
}

.rail-creator__avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.rail-creator__meta {
  min-width: 0;
  display: grid;
  gap: 2px;
}

.rail-creator__name {
  font-size: 0.92rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.rail-creator__sub {
  font-size: 0.8rem;
  color: var(--text-soft);
}

.rail-nav {
  display: grid;
  gap: 4px;
}

.rail-nav__item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 10px 4px;
  color: var(--text);
}

.rail-nav__item--active,
.rail-nav__item:hover {
  color: var(--interactive-text);
}

.rail-nav__icon {
  width: 22px;
  text-align: center;
  color: var(--text-soft);
}

.setting-list {
  display: grid;
  gap: 14px;
}

.setting-list__item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: var(--text);
}

.setting-dot,
.theme-swatch,
.toggle-switch {
  display: inline-block;
  flex-shrink: 0;
}

.setting-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--text-faint);
}

.theme-swatch {
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--accent);
}

.toggle-switch {
  width: 34px;
  height: 20px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: var(--toggle-track);
  position: relative;
  cursor: pointer;
}

.toggle-switch::after {
  content: "";
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: var(--toggle-knob);
  box-shadow: var(--toggle-shadow);
  transition: transform 160ms ease;
}

.toggle-switch[aria-pressed="true"] {
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
}

.toggle-switch[aria-pressed="true"]::after {
  transform: translateX(14px);
}

.rail-footer {
  display: grid;
  gap: 8px;
  margin-top: 26px;
  color: var(--text-soft);
  font-size: 0.94rem;
}

.rail-footer small {
  margin-top: 8px;
  color: var(--text-faint);
}

.rail-footer a:hover {
  color: var(--text);
  text-decoration: underline;
}

.main-stage {
  min-width: 0;
}

.topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  padding: 8px 22px 0;
}

.topbar--light {
  background: var(--surface);
}

/* Injected client-side by script.js into every .topbar. Hidden on
   wide viewports where the left-rail handles branding; shown ≤980px
   (fold view) as the first flex item, before topbar__nav. */
.topbar__logo {
  display: none;
  align-items: center;
  flex-shrink: 0;
}

.topbar__logo img {
  display: block;
  height: 32px;
  width: auto;
}

/* Injected by script.js as the first child of every .topbar. The
   rail's own toggle is unreachable on ≤980px (it lives inside the
   off-screen drawer), so this is the only way to open the nav on
   mobile. Hidden ≥981px where the rail is always visible. */
.topbar__menu-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  padding: 0;
  margin-right: 2px;
  border: 0;
  border-radius: 10px;
  background: transparent;
  color: var(--text);
  cursor: pointer;
  flex-shrink: 0;
}

.topbar__menu-toggle:hover,
.topbar__menu-toggle:focus-visible {
  background: var(--bg-soft);
  outline: 0;
}

.topbar__menu-toggle svg {
  width: 22px;
  height: 22px;
}

/* Injected by script.js at the end of every .topbar__nav. Hidden on
   wide viewports (the search is inline there); shown ≤980px where
   the search is collapsed by default and toggled by this button. */
.topbar__search-toggle {
  display: none;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  margin-left: 4px;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--text-soft);
  cursor: pointer;
}

.topbar__search-toggle:hover,
.topbar__search-toggle:focus-visible {
  color: var(--text);
  background: rgba(255, 255, 255, 0.08);
  outline: 0;
}

.topbar__search-toggle svg {
  width: 20px;
  height: 20px;
}

.topbar__nav {
  display: flex;
  align-items: center;
  gap: 6px;
}

.topbar__nav-item {
  padding: 8px 16px;
  border-radius: 999px;
  color: var(--text-soft);
  font-size: 0.95rem;
  white-space: nowrap;
  transition: background 140ms ease, color 140ms ease;
}

.topbar__nav-item:hover {
  color: var(--text);
}

.topbar__nav-item--active {
  background: #ffffff2e;
  color: #fff;
}

.topbar__actions {
  display: flex;
  align-items: center;
  gap: 18px;
}

.topbar__actions--compact {
  justify-content: flex-end;
  min-width: 180px;
}

.account-avatar {
  display: inline-grid;
  place-items: center;
  width: 36px;
  height: 36px;
  border-radius: 50%;
  overflow: hidden;
  background: linear-gradient(135deg, #3b3f49, #0f1218);
  color: #fff;
  font-size: 0.82rem;
  text-decoration: none;
}

.account-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.text-link {
  color: var(--interactive-text);
}

.search {
  display: flex;
  align-items: center;
  gap: 12px;
  width: min(100%, 460px);
  padding: 0 14px;
  border-radius: 12px;
}

.search--light {
  min-height: 42px;
  background: var(--hero-search-bg);
}

.search__icon {
  color: var(--text-soft);
}

.search__input {
  width: 100%;
  border: 0;
  outline: 0;
  background: transparent;
}

.search__input--light {
  color: var(--text);
}

.button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid transparent;
  border-radius: 999px;
  cursor: pointer;
}

/* `display: inline-flex` above otherwise overrides the HTML5 `hidden`
   attribute, so the channels-page Edit button (which starts `hidden` and
   is unhidden by channels.js only when the viewer is the owner) would
   keep rendering for non-owners and signed-out viewers. Same pattern as
   `.auth-form[hidden]`, `.channel-modal[hidden]`, `.channel-panel[hidden]`. */
.button[hidden] {
  display: none;
}

/* "Following" state for the follow toggle button on /page/watch and
   /page/channels — overrides the .button--primary gradient with a flat
   ghost so the user has a visual cue (in addition to text) that they're
   currently following. Inverts on hover to telegraph the unfollow action. */
.watch-follow-btn--active,
.channel-follow-btn--active {
  background: var(--bg-soft);
  color: var(--text);
  border-color: var(--line);
}

.watch-follow-btn--active:hover,
.channel-follow-btn--active:hover {
  background: rgba(255, 88, 96, 0.14);
  color: #ff8e92;
  border-color: rgba(255, 88, 96, 0.3);
}

/* Saved-page empty + error states (also reused by future list pages) */
.channel-empty {
  text-align: center;
  padding: 48px 16px;
  color: var(--text-soft);
}

.channel-empty h3 {
  margin: 0 0 8px;
  color: var(--text);
  font-weight: 700;
}

.channel-empty p {
  margin: 0 0 16px;
  line-height: 1.5;
}

.channel-empty--error {
  color: #ff8e92;
}

.button--primary {
  padding: 12px 20px;
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  color: #fff;
}

.button--small {
  padding: 10px 16px;
}

.button--outline {
  padding: 12px 20px;
  border-color: var(--hero-outline);
  color: #fff;
}

.button--white {
  padding: 12px 20px;
  background: var(--surface);
  border-color: var(--line);
  color: var(--text);
}

/* Destructive ghost variant for the "Clear history" button on /history.
   Soft red surface + red text by default; fills in on hover so the
   destructive action is clearly visible. */
[data-history-clear] {
  background: rgba(255, 88, 96, 0.12);
  border-color: rgba(255, 88, 96, 0.32);
  color: #ff5860;
}

[data-history-clear]:hover,
[data-history-clear]:focus-visible {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  outline: 0;
}

.content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) var(--right-rail);
  gap: 26px;
  padding: 18px 22px 36px;
}

.content-grid--solo {
  grid-template-columns: minmax(0, 1fr);
}

.content-column {
  min-width: 0;
}

.page-title,
.section-title {
  margin: 0 0 16px;
}

.page-title {
  font-size: 2.1rem;
  font-weight: 700;
}

.section-title {
  font-size: 1.05rem;
  font-weight: 700;
}

.section-title::before {
  content: "";
  display: inline-block;
  width: 1.5rem;
  height: 1.5rem;
  margin-right: 6px;
  vertical-align: middle;
  background: url("https://cdn-mystreamspace.b-cdn.net/msslogo.png") no-repeat center / contain;
}

.section-title__link {
  color: inherit;
  text-decoration: none;
}

.section-title__link:hover,
.section-title__link:focus-visible {
  text-decoration: underline;
  text-underline-offset: 4px;
  outline: 0;
}

.section-heading--stack {
  align-items: flex-start;
}

.section-heading--row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 16px;
}

.catalog-section {
  margin-top: 30px;
}

.catalog-section--shorts {
  margin-top: 10px;
}

.discover-hero {
  margin-top: 30px;
}

.feature-card__media {
  position: relative;
  min-height: 560px;
  border-radius: var(--radius-xl);
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.05), rgba(0, 0, 0, 0.68)),
    radial-gradient(circle at top center, rgba(103, 176, 255, 0.2), transparent 40%),
    linear-gradient(120deg, #08101c 0%, #0d2231 28%, #10151d 55%, #030406 100%);
}

.feature-card__media::before,
.media-card__thumb::before,
.poster-card__art::before,
.list-item__thumb::before,
.feed-card__thumb::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 50% 20%, rgba(255, 255, 255, 0.18), transparent 18%),
    linear-gradient(180deg, transparent 25%, rgba(0, 0, 0, 0.35) 100%);
}

.feature-card__overlay {
  position: absolute;
  left: 30px;
  right: 90px;
  bottom: 30px;
  z-index: 1;
  color: #fff;
}

.feature-card__overlay h2 {
  max-width: 10ch;
  margin: 0;
  font-size: clamp(2.6rem, 4vw, 4rem);
  line-height: 0.98;
}

.feature-card__overlay p {
  margin: 14px 0 0;
  color: rgba(255, 255, 255, 0.86);
}

.feature-card__actions {
  display: flex;
  gap: 14px;
  margin-top: 24px;
}

.feature-card__dots {
  position: absolute;
  top: 50%;
  right: 18px;
  z-index: 1;
  display: grid;
  gap: 12px;
  transform: translateY(-50%);
}

.feature-card__dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.5);
}

.feature-card__dot--active {
  background: #fff;
}

/* Billboard — admin-controlled sponsored banner. Shares the
   `.feature-card__media` chrome (gradient + radius + min-height) with
   the legacy hero, but `.billboard` modes paint their own media on
   top via absolute fills. See views/assets/js/billboard.js. */
.billboard {
  position: relative;
}

.billboard__media {
  position: relative;
  overflow: hidden;
  background: #08101c;
}

/* Drop the inherited .feature-card__media gradient + ::before overlay —
   the billboard empty state is a flat solid surface. */
.billboard__media::before {
  display: none;
}

.billboard__media > .billboard__image,
.billboard__media > .billboard__poster,
.billboard__media > .billboard__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: inherit;
  background: #08101c;
}

.billboard__video {
  z-index: 1;
}

.billboard__poster {
  z-index: 0;
}

.billboard__pill {
  position: absolute;
  top: 16px;
  right: 16px;
  z-index: 2;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 12px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.billboard__pill--sponsored {
  background: rgba(0, 0, 0, 0.55);
  color: #fff;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
}

.billboard__pill--live {
  background: #e0224a;
  color: #fff;
}

.billboard__pill--live::before {
  content: "";
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #fff;
}

.billboard__actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-top: 14px;
  margin-bottom: 4px;
}

.billboard__actions[hidden] {
  display: none;
}

.billboard__boost {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 16px;
  border: 0;
  border-radius: 18px;
  background: #f8f7fb;
  color: #05050a;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0.01em;
  cursor: pointer;
  transition: transform 120ms ease, background 120ms ease;
}

.billboard__boost:hover {
  background: #ecebf2;
}

.billboard__boost:active {
  transform: scale(0.97);
}

.billboard__boost-icon {
  font-size: 13px;
  line-height: 1;
}

.billboard__actions-right {
  display: flex;
  align-items: center;
  gap: 8px;
}

.billboard__icon {
  width: 36px;
  height: 36px;
  border: 0;
  border-radius: 50%;
  background: #1a1a1f;
  color: #fff;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 16px;
  line-height: 1;
  transition: background 120ms ease, transform 120ms ease;
}

.billboard__icon:hover {
  background: #2a2a32;
}

.billboard__icon:active {
  transform: scale(0.94);
}

.billboard__icon[disabled] {
  opacity: 0.45;
  cursor: not-allowed;
}

.billboard__icon > i {
  font-size: 14px;
  line-height: 1;
  pointer-events: none;
}

/* Live-comments bottom sheet (opened from `live_tv` mode's comment
   bubble). Hidden by default; `MssBillboardComments.open()` removes
   the [hidden] attribute and slides the panel up. */
.bb-sheet {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
}

.bb-sheet[hidden] {
  display: none;
}

.bb-sheet__scrim {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.55);
  cursor: pointer;
}

.bb-sheet__panel {
  position: relative;
  width: 100%;
  max-width: 520px;
  margin: 0 auto;
  max-height: 78vh;
  min-height: 360px;
  background: #ffffff;
  color: #0e0e14;
  border-top-left-radius: 22px;
  border-top-right-radius: 22px;
  display: flex;
  flex-direction: column;
  transform: translateY(100%);
  animation: bb-sheet-up 220ms ease forwards;
  box-shadow: 0 -12px 40px rgba(0, 0, 0, 0.18);
}

@keyframes bb-sheet-up {
  to { transform: translateY(0); }
}

.bb-sheet__head {
  position: relative;
  padding: 12px 18px 8px;
  border-bottom: 1px solid rgba(0, 0, 0, 0.08);
}

.bb-sheet__handle {
  display: block;
  width: 40px;
  height: 4px;
  border-radius: 2px;
  background: rgba(0, 0, 0, 0.16);
  margin: 0 auto 10px;
}

.bb-sheet__title {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
  color: #0e0e14;
}

.bb-sheet__close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 30px;
  height: 30px;
  border: 0;
  border-radius: 50%;
  background: transparent;
  color: rgba(0, 0, 0, 0.55);
  font-size: 22px;
  line-height: 1;
  cursor: pointer;
}

.bb-sheet__close:hover {
  color: #0e0e14;
  background: rgba(0, 0, 0, 0.05);
}

.bb-sheet__body {
  position: relative;
  flex: 1;
  overflow: hidden;
  display: flex;
  flex-direction: column;
}

.bb-sheet__loading,
.bb-sheet__empty {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 24px 32px;
  color: rgba(0, 0, 0, 0.55);
}

.bb-sheet__empty[hidden],
.bb-sheet__loading[hidden] {
  display: none;
}

.bb-sheet__empty-title {
  margin: 0 0 4px;
  color: #0e0e14;
  font-weight: 600;
  font-size: 15px;
}

.bb-sheet__spinner {
  width: 26px;
  height: 26px;
  border: 2.5px solid rgba(0, 0, 0, 0.12);
  border-top-color: #0e0e14;
  border-radius: 50%;
  animation: bb-sheet-spin 800ms linear infinite;
}

@keyframes bb-sheet-spin {
  to { transform: rotate(360deg); }
}

.bb-sheet__list {
  list-style: none;
  margin: 0;
  padding: 14px 18px 12px;
  overflow-y: auto;
  display: flex;
  flex-direction: column-reverse;
  gap: 12px;
  flex: 1;
}

.bb-sheet__row {
  display: flex;
  align-items: flex-start;
  gap: 10px;
}

.bb-sheet__avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 13px;
  font-weight: 700;
  flex-shrink: 0;
}

.bb-sheet__row-meta {
  flex: 1;
  min-width: 0;
}

.bb-sheet__row-name {
  font-size: 13px;
  font-weight: 700;
  color: #0e0e14;
}

.bb-sheet__row-handle {
  font-weight: 400;
  color: rgba(0, 0, 0, 0.5);
  margin-left: 4px;
}

.bb-sheet__row-body {
  font-size: 14px;
  color: rgba(14, 14, 20, 0.92);
  margin-top: 2px;
  word-wrap: break-word;
}

.bb-sheet__compose {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 14px;
  border-top: 1px solid rgba(0, 0, 0, 0.08);
}

.bb-sheet__input {
  flex: 1;
  background: rgba(0, 0, 0, 0.04);
  color: #0e0e14;
  border: 0;
  border-radius: 22px;
  padding: 10px 14px;
  font-size: 14px;
  outline: none;
}

.bb-sheet__input::placeholder {
  color: rgba(0, 0, 0, 0.42);
}

.bb-sheet__input:focus {
  background: rgba(0, 0, 0, 0.07);
}

.bb-sheet__send {
  width: 40px;
  height: 40px;
  border: 0;
  border-radius: 50%;
  background: var(--color-accent, #6a80e0);
  color: #fff;
  font-size: 16px;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.bb-sheet__send::before {
  content: "➤";
}

.bb-sheet__send[disabled] {
  background: rgba(0, 0, 0, 0.12);
  color: rgba(255, 255, 255, 0.85);
  cursor: not-allowed;
}

.bb-sheet__error {
  margin: 0;
  padding: 8px 18px 12px;
  color: #c93636;
  font-size: 12px;
  text-align: center;
}

.bb-sheet__error[hidden] {
  display: none;
}

@media (max-width: 768px) {
  .billboard__media {
    min-height: 320px;
  }
  .feature-card__media.billboard__media {
    min-height: 320px;
  }
  .bb-sheet__panel {
    max-width: 100%;
    max-height: 85vh;
    border-top-left-radius: 18px;
    border-top-right-radius: 18px;
  }
}

.video-row,
.poster-row,
.feed-grid {
  display: grid;
  gap: 16px;
}

.video-row {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.media-card__thumb,
.poster-card__art,
.list-item__thumb,
.feed-card__thumb {
  position: relative;
  display: block;
  overflow: hidden;
}

.media-card__thumb {
  height: 258px;
  border-radius: 18px;
}

.media-card__thumb--music-one {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.08), rgba(0, 0, 0, 0.4)),
    linear-gradient(130deg, #38444f, #1f2b2f 50%, #010103);
}

.media-card__thumb--music-two {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.08), rgba(0, 0, 0, 0.4)),
    linear-gradient(130deg, #f7caef, #f39dd9 40%, #bfa1ff);
}

.media-card__thumb--music-three {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.08), rgba(0, 0, 0, 0.4)),
    linear-gradient(130deg, #7b5f49, #d7c8b7 45%, #b4904e);
}

.media-card__info,
.feed-card__meta {
  display: flex;
  gap: 12px;
  padding-top: 12px;
}

.avatar {
  display: inline-grid;
  place-items: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  object-fit: cover;
  background: #1f232b;
  color: #fff;
  font-size: 0.82rem;
  flex-shrink: 0;
}

.avatar--mono {
  background: linear-gradient(135deg, #3b3f49, #0f1218);
}

.media-card h3,
.poster-card h3,
.list-item h3,
.feed-card h3 {
  margin: 0;
  font-size: 0.98rem;
  line-height: 1.35;
}

.media-card p,
.poster-card p,
.list-item p,
.feed-card p {
  margin: 6px 0 0;
  color: var(--text-soft);
}

.media-card small,
.poster-card small,
.list-item small,
.feed-card small {
  display: block;
  margin-top: 6px;
  color: var(--text-faint);
}

.poster-row {
  grid-template-columns: repeat(6, minmax(0, 1fr));
}

.shorts-shelf {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 16px;
}

.shorts-shelf--scroll {
  grid-template-columns: none;
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.shorts-shelf--scroll::-webkit-scrollbar {
  display: none;
}

.shorts-card--skeleton .shorts-card__art {
  height: 420px;
  border-radius: 22px;
}

.skeleton-line {
  border-radius: 6px;
  margin-top: 10px;
}

.skeleton-line--title {
  height: 14px;
  width: 80%;
}

.skeleton-line--sub {
  height: 12px;
  width: 50%;
}

.skeleton-line--meta {
  height: 10px;
  width: 35%;
}

/* Doubled class → specificity (0,2,0): the solid fill outranks per-card
   gradient classes (.feed-card__thumb--*, .avatar--mono) without
   !important; ::before kills the inherited gradient overlays. */
.skeleton-pulse.skeleton-pulse {
  background: var(--bg-muted);
  animation: skeleton-pulse 1.4s ease-in-out infinite;
}

.skeleton-pulse.skeleton-pulse::before {
  display: none;
}

@keyframes skeleton-pulse {
  0%, 100% { opacity: 1; }
  50%      { opacity: 0.5; }
}

.shorts-shelf--scroll > .shorts-card {
  flex: 0 0 280px;
  scroll-snap-align: start;
}

.live-chip {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 10px;
  border-radius: 999px;
  background: #e60000;
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
}

/* Stream-ended variant — set by live_stream.js when the broadcast concludes. */
.live-chip--ended {
  background: #6b7280;
}

/* Gift-stars sheet — opened by send_stars.js (web SendStarsSheet). */
.gift-sheet {
  position: fixed;
  inset: 0;
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(0, 0, 0, 0.55);
}

.gift-sheet__panel {
  position: relative;
  width: 100%;
  max-width: 380px;
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-soft);
  padding: 24px;
}

.gift-sheet__close {
  position: absolute;
  top: 12px;
  right: 14px;
  border: 0;
  background: transparent;
  color: var(--text-soft);
  font-size: 1.4rem;
  line-height: 1;
  cursor: pointer;
}

.gift-sheet__title {
  margin: 0 0 4px;
  font-size: 1.2rem;
  text-align: center;
}

.gift-sheet__fee-note {
  margin: 0 0 16px;
  text-align: center;
  color: var(--text-soft);
  font-size: 0.85rem;
  min-height: 1.2em;
}

/* Gift tier grid — 6 cards (2 rows of 3), mirrors the mobile sheet. */
.gift-sheet__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin-bottom: 16px;
}

.gift-sheet__card {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 14px 6px;
  border: 1px solid var(--line);
  border-radius: var(--radius-md);
  background: var(--bg);
  color: var(--text);
  cursor: pointer;
  transition: border-color 0.15s, background 0.15s;
}

.gift-sheet__card--on {
  border-color: var(--accent);
  background: var(--bg-soft);
}

.gift-sheet__card--disabled {
  opacity: 0.45;
  cursor: not-allowed;
}

.gift-sheet__card-icon {
  font-size: 1.9rem;
  line-height: 1;
}

.gift-sheet__card-img {
  width: 32px;
  height: 32px;
  object-fit: contain;
}

.gift-sheet__card-count {
  font-weight: 600;
  font-size: 0.85rem;
}

.gift-sheet__card-price {
  color: var(--text-faint);
  font-size: 0.78rem;
}

.gift-sheet__card-send {
  margin-top: 6px;
  padding: 5px 14px;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  color: #fff;
  font-size: 0.8rem;
  font-weight: 600;
}

.gift-sheet__policy {
  margin: 0 0 14px;
  text-align: center;
  color: var(--text-faint);
  font-size: 0.75rem;
}

.gift-sheet__cancel {
  display: block;
  width: 100%;
  padding: 10px 0;
  border: 0;
  background: transparent;
  color: var(--text-soft);
  font-weight: 600;
  cursor: pointer;
}

/* In-panel dialog states: low-balance, sent, error. */
.gift-sheet__dialog {
  text-align: center;
  padding: 8px 0;
}

.gift-sheet__dialog-icon {
  width: 56px;
  height: 56px;
  margin: 0 auto 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  font-size: 1.8rem;
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  color: #fff;
}

.gift-sheet__dialog-icon--ok {
  background: linear-gradient(135deg, #d2479b, #7b4ad8);
}

.gift-sheet__dialog-title {
  margin: 0 0 8px;
  font-size: 1.15rem;
}

.gift-sheet__dialog-msg {
  margin: 0 0 18px;
  color: var(--text-soft);
  font-size: 0.9rem;
}

.gift-sheet__dialog-actions {
  display: flex;
  gap: 10px;
  justify-content: center;
}

.gift-sheet__btn {
  flex: 1;
  padding: 11px 0;
  border: 0;
  border-radius: var(--radius-sm);
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  color: #fff;
  font-weight: 600;
  cursor: pointer;
}

.gift-sheet__btn--secondary {
  background: var(--bg-muted);
  color: var(--text);
}

.shorts-card__art--live-one {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0.42)),
    linear-gradient(145deg, #7c3540, #23161b 55%, #0e0f14);
}

.shorts-card__art--live-two {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0.42)),
    linear-gradient(145deg, #2a416c, #181d2a 55%, #090c12);
}

.shorts-card__art--live-three {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0.42)),
    linear-gradient(145deg, #5c4a35, #1f1915 55%, #0c0c0e);
}

.shorts-card__art--live-four {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0.42)),
    linear-gradient(145deg, #74455a, #26181d 55%, #0d0d10);
}

.shorts-card__art--live-five {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0.42)),
    linear-gradient(145deg, #3b4a6b, #161a28 55%, #0a0c14);
}

.shorts-card__art--live-six {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0.42)),
    linear-gradient(145deg, #2d5c4a, #121f1a 55%, #0a0e0c);
}

.shorts-card {
  min-width: 0;
}

.shorts-card__art {
  position: relative;
  display: block;
  height: 420px;
  overflow: hidden;
  border-radius: 22px;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0.36)),
    linear-gradient(145deg, #1e445b, #0b1821 70%, #f1792a);
}

.shorts-card__art::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 50% 18%, rgba(255, 255, 255, 0.14), transparent 16%),
    linear-gradient(180deg, transparent 30%, rgba(0, 0, 0, 0.3) 100%);
}

.shorts-card__art--one {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0.36)),
    linear-gradient(145deg, #1e445b, #0b1821 70%, #f1792a);
}

.shorts-card__art--two {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0.36)),
    linear-gradient(145deg, #6bc4d7, #0d2233 45%, #051018);
}

.shorts-card__art--three {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0.36)),
    linear-gradient(145deg, #71c0d9, #3c6c73 45%, #0d1720);
}

.shorts-card__art--four {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0.36)),
    linear-gradient(145deg, #cbb6a0, #7d8c97 45%, #d7c9bc);
}

.shorts-card__art--five {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0.36)),
    linear-gradient(145deg, #031019, #1d3652 45%, #0d1017);
}

.shorts-card__art--six {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.04), rgba(0, 0, 0, 0.36)),
    linear-gradient(145deg, #4e7381, #b6c8cc 45%, #c7271b);
}

.shorts-card h3 {
  margin: 12px 0 0;
  font-size: 0.98rem;
  line-height: 1.3;
}

.shorts-card p,
.shorts-card small {
  display: block;
  margin-top: 6px;
  color: var(--text-soft);
}

.shorts-card p {
  margin-bottom: 1px;
}

/* Upcoming Events shelf — horizontally scrollable landscape cards,
   mirrors the .shorts-shelf--scroll pattern but with wider, shorter
   cards suited to event covers. */
.events-shelf {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
}

.events-shelf::-webkit-scrollbar {
  display: none;
}

.events-shelf > .event-card {
  flex: 0 0 300px;
  scroll-snap-align: start;
}

.event-card {
  min-width: 0;
}

.event-card__cover {
  position: relative;
  display: block;
  height: 180px;
  border-radius: 16px;
  overflow: hidden;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.08), rgba(0, 0, 0, 0.4)),
    linear-gradient(130deg, #38444f, #1f2b2f 50%, #010103);
}

.event-card__badge {
  position: absolute;
  top: 12px;
  left: 12px;
  z-index: 1;
  padding: 5px 10px;
  border-radius: 10px;
  background: rgba(0, 0, 0, 0.78);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  line-height: 1.1;
  text-align: center;
}

.event-card__badge--live {
  background: #e60000;
}

.event-card__body {
  padding-top: 12px;
}

.event-card__body h3 {
  margin: 0;
  font-size: 0.98rem;
  line-height: 1.3;
}

.event-card__body p {
  margin: 6px 0 0;
  color: var(--text-soft);
  font-size: 0.85rem;
}

.event-card__body small {
  display: block;
  margin-top: 6px;
  color: var(--text-faint);
}

.event-card__title-link {
  color: inherit;
  text-decoration: none;
}

.event-card__title-link:hover {
  color: var(--accent);
}

/* ── Events page filter tabs (/events) ──────────────────────────────── */
.events-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin: 2px 0 22px;
}

.events-tab {
  display: inline-flex;
  align-items: center;
  padding: 9px 18px;
  border: 0;
  border-radius: 999px;
  background: var(--bg-muted);
  color: var(--text-soft);
  font-weight: 600;
  font-size: 0.92rem;
  cursor: pointer;
  transition: background 140ms ease, color 140ms ease;
}

.events-tab:not(.events-tab--active):hover {
  color: var(--text);
}

.events-tab--active {
  background: var(--text);
  color: var(--bg);
}

.events-tab__dot {
  width: 7px;
  height: 7px;
  margin-left: 7px;
  border-radius: 50%;
  background: #ff5a5f;
}

.events-empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 64px 16px;
  color: var(--text-soft);
}

.events-empty__icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 60px;
  height: 60px;
  margin: 0 auto 18px;
  border-radius: var(--radius-lg);
  background: var(--bg-soft);
  color: var(--text-faint);
}

.events-empty h3 {
  margin: 0 0 6px;
  color: var(--text);
  font-weight: 700;
  font-size: 1.05rem;
}

.events-empty p {
  margin: 0;
}

/* ── Event detail page (/events/<id>) ───────────────────────────────── */
.event-detail {
  max-width: 920px;
  margin: 0 auto;
  padding-bottom: 48px;
}

.event-detail__cover {
  display: block;
  height: clamp(220px, 38vw, 420px);
  border-radius: var(--radius-xl);
  overflow: hidden;
  background: linear-gradient(130deg, #38444f, #1f2b2f 50%, #010103);
}

.event-detail__title {
  margin: 26px 0 0;
  font-size: clamp(1.7rem, 3.4vw, 2.4rem);
  font-weight: 800;
  line-height: 1.15;
}

.event-detail__organizer {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  margin-top: 14px;
  color: var(--text-soft);
  text-decoration: none;
  font-size: 0.95rem;
}

.event-detail__organizer:hover {
  color: var(--text);
}

.event-detail__organizer-avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  background: var(--bg-muted);
  color: #fff;
  font-size: 0.72rem;
  font-weight: 700;
  overflow: hidden;
}

.event-detail__meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
  margin-top: 24px;
}

.event-detail__meta-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px 18px;
  border-radius: var(--radius-lg);
  background: var(--bg-soft);
}

.event-detail__meta-icon {
  display: inline-flex;
  color: var(--text-soft);
}

.event-detail__meta-copy {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.event-detail__meta-copy strong {
  font-size: 1rem;
  font-weight: 700;
}

.event-detail__meta-copy small {
  margin-top: 2px;
  color: var(--text-soft);
  font-size: 0.82rem;
}

.event-detail__actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 20px;
}

.event-detail__rsvp {
  flex: 0 0 auto;
  min-width: 188px;
  padding: 15px 28px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(90deg, #a24784, #cb5d97);
  color: #fff;
  font-size: 0.98rem;
  font-weight: 700;
  cursor: pointer;
  transition: filter 0.15s ease, opacity 0.15s ease;
}

.event-detail__rsvp:hover {
  filter: brightness(1.06);
}

.event-detail__rsvp:disabled {
  opacity: 0.6;
  cursor: default;
}

.event-detail__rsvp--on {
  background: linear-gradient(90deg, #6a375c, #8a4670);
}

.event-detail__icon-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  border: 0;
  border-radius: 50%;
  background: var(--bg-soft);
  color: var(--text-soft);
  cursor: pointer;
  transition: background 0.15s ease, color 0.15s ease;
}

.event-detail__icon-btn:hover {
  background: var(--bg-muted);
  color: var(--text);
}

.event-detail__rule {
  margin: 26px 0;
  border: 0;
  border-top: 1px solid var(--bg-muted);
}

.event-detail__section-title {
  margin: 0 0 12px;
  font-size: 1.08rem;
  font-weight: 700;
}

.event-detail__about {
  margin: 0;
  color: var(--text-soft);
  line-height: 1.6;
  white-space: pre-line;
}

.event-detail__attendees {
  display: flex;
  align-items: center;
  gap: 14px;
}

.event-detail__avatars {
  display: flex;
}

.event-detail__avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  margin-left: -10px;
  border: 2px solid var(--bg);
  color: #fff;
  font-size: 0.74rem;
  font-weight: 700;
  overflow: hidden;
}

.event-detail__avatar:first-child {
  margin-left: 0;
}

.event-detail__attendees-text {
  margin: 0;
  color: var(--text-soft);
  font-size: 0.92rem;
}

.event-detail__attendees-text strong {
  color: var(--text);
  font-weight: 700;
}

@media (max-width: 560px) {
  .event-detail__meta {
    grid-template-columns: 1fr;
  }

  .event-detail__rsvp {
    flex: 1;
    min-width: 0;
  }
}

.poster-card__art {
  height: 458px;
  border-radius: 18px;
  margin-bottom: 10px;
}

.poster-card__art--one {
  background: linear-gradient(145deg, #1e445b, #0b1821 70%, #f1792a);
}

.poster-card__art--two {
  background: linear-gradient(145deg, #6bc4d7, #0d2233 45%, #051018);
}

.poster-card__art--three {
  background: linear-gradient(145deg, #71c0d9, #3c6c73 45%, #0d1720);
}

.poster-card__art--four {
  background: linear-gradient(145deg, #cbb6a0, #7d8c97 45%, #d7c9bc);
}

.poster-card__art--five {
  background: linear-gradient(145deg, #031019, #1d3652 45%, #0d1017);
}

.poster-card__art--six {
  background: linear-gradient(145deg, #4e7381, #b6c8cc 45%, #c7271b);
}

.list-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 28px;
}

.list-column {
  display: grid;
  gap: 16px;
}

.list-item {
  display: grid;
  grid-template-columns: 62px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
}

.list-item__thumb {
  width: 62px;
  height: 62px;
  border-radius: 12px;
}

.list-item__thumb--a {
  background: linear-gradient(145deg, #d5c6b8, #734634 45%, #1b223f);
}

.list-item__thumb--b {
  background: linear-gradient(145deg, #c9a48f, #8e694d 45%, #1d2128);
}

.list-item__thumb--c {
  background: linear-gradient(145deg, #72a4bf, #264f5d 45%, #07161b);
}

.list-item__thumb--d {
  background: linear-gradient(145deg, #5b4123, #d59f35 45%, #130f0b);
}

.list-item__thumb--e {
  background: linear-gradient(145deg, #d5d0af, #5b5d42 45%, #1d2128);
}

.list-item__thumb--f {
  background: linear-gradient(145deg, #afb9b0, #5c655d 45%, #1d2128);
}

.feed-grid {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.feed-card__thumb {
  height: 298px;
  border-radius: 18px;
}

.feed-card__thumb--one {
  background: linear-gradient(145deg, #43718b, #112332 72%, #f47d2d);
}

.feed-card__thumb--two {
  background: linear-gradient(145deg, #5cbcd2, #12303c 45%, #0a1218);
}

.feed-card__thumb--three {
  background: linear-gradient(145deg, #486b6c, #203432 45%, #0f1517);
}

.feed-card__thumb--four {
  background: linear-gradient(145deg, #d4c5b7, #9f8a7e 45%, #b0a395);
}

.feed-card__thumb--five {
  background: linear-gradient(145deg, #0e1318, #264165 45%, #1d2027);
}

.feed-card__thumb--six {
  background: linear-gradient(145deg, #a1bcc5, #24404a 45%, #ce3624);
}

.time-pill {
  position: absolute;
  right: 10px;
  bottom: 10px;
  z-index: 1;
  padding: 4px 7px;
  border-radius: 8px;
  background: rgba(0, 0, 0, 0.84);
  color: #fff;
  font-size: 0.78rem;
}

.earn-pill {
  position: absolute;
  left: 10px;
  top: 10px;
  z-index: 1;
  padding: 3px 8px;
  border-radius: 999px;
  background: linear-gradient(135deg, #f59e0b, #f97316);
  color: #fff;
  font-size: 0.68rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.25);
  pointer-events: none;
}

/* Watch & Earn card on /watch — see project.wallet.md "Watch & Earn on /watch" */
.watch-earn {
  display: flex;
  flex-direction: column;
  gap: 10px;
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}

.watch-earn__top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.watch-earn__label {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text);
}

.watch-earn__count {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  white-space: nowrap;
  font-size: 0.85rem;
  font-weight: 700;
  color: var(--text-soft);
}

.watch-earn__star {
  color: #f59e0b;
}

.watch-earn__track {
  height: 8px;
  overflow: hidden;
  border-radius: 999px;
  background: var(--line);
}

.watch-earn__fill {
  height: 100%;
  width: 0;
  border-radius: 999px;
  background: linear-gradient(135deg, #f59e0b, #f97316);
  transition: width 0.3s ease;
}

.watch-earn__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  font-size: 0.8rem;
  color: var(--text-soft);
}

.watch-earn__row-value {
  font-weight: 600;
}

.genre-bar {
  margin-top: 1rem;
  padding: 14px 22px 0;
}

.genre-bar__track {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  scrollbar-width: none;
}

.genre-bar__track::-webkit-scrollbar {
  display: none;
}

.genre-pill {
  flex: 0 0 auto;
  padding: 10px 20px;
  border-radius: 999px;
  background: var(--bg-muted);
  color: var(--text-soft);
  font-weight: 600;
  font-size: 0.95rem;
  white-space: nowrap;
  transition: background 140ms ease, color 140ms ease;
}

.genre-pill:not(.genre-pill--active):hover {
  color: var(--text);
}

.genre-pill--active {
  background: var(--text);
  color: var(--bg);
}

.fan-list {
  display: grid;
  gap: 14px;
}

.fan-item {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) auto;
  gap: 12px;
  align-items: center;
}

.fan-rank {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: #777;
  color: #fff;
  font-weight: 700;
  background-size: cover;
  background-position: center;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.5);
  overflow: hidden;
}

.fan-item p {
  margin: 4px 0 0;
  color: var(--text-soft);
}

.follow-button {
  padding: 8px 14px;
  border: 1px solid var(--accent);
  border-radius: 999px;
  color: var(--accent);
  font-size: 0.88rem;
}

.button:hover,
.cta-button:hover,
.follow-button:hover,
.rail-nav__item:hover,
.text-link:hover {
  opacity: 0.9;
}

.button:focus-visible,
.cta-button:focus-visible,
.follow-button:focus-visible,
.icon-button:focus-visible,
.search__input:focus-visible,
.rail-nav__item:focus-visible,
.text-link:focus-visible {
  outline: 2px solid rgba(255, 106, 0, 0.5);
  outline-offset: 2px;
}

[data-theme="dark"] {
  color-scheme: dark;
}

[data-theme="dark"] .left-rail,
[data-theme="dark"] .topbar--light,
[data-theme="dark"] .main-stage {
  background: var(--surface);
}

[data-theme="dark"] .search__input::placeholder {
  color: var(--text-faint);
}

[data-theme="dark"] .time-pill {
  background: rgba(0, 0, 0, 0.72);
}

[data-theme="dark"] .fan-rank {
  background: #2f3746;
}

@media (max-width: 1500px) {
  .content-grid {
    grid-template-columns: minmax(0, 1fr);
  }
}

@media (max-width: 1280px) {
  .poster-row {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .shorts-shelf {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .video-row,
  .feed-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 980px) {
  .layout {
    grid-template-columns: 1fr;
  }

  .left-rail {
    position: fixed;
    inset: 0 auto 0 0;
    z-index: 10;
    width: min(82vw, 280px);
    transform: translateX(-100%);
    transition: transform 160ms ease;
  }

  .left-rail.is-open {
    transform: translateX(0);
  }

  /* Scrim behind the open drawer — sits below the rail (z-index 10)
     but above page content. Clicking it closes the drawer via the
     document click-outside handler in script.js. */
  body.mss-rail-open::after {
    content: "";
    position: fixed;
    inset: 0;
    z-index: 9;
    background: rgba(0, 0, 0, 0.5);
    animation: mss-modal-fade 140ms ease-out;
  }

  .topbar {
    padding-top: 12px;
    justify-content: flex-start;
    flex-wrap: wrap;
  }

  .topbar__menu-toggle {
    display: inline-flex;
  }

  .topbar__logo {
    display: inline-flex;
  }

  /* Order so the row reads `[logo] [nav] [actions]` and the search
     drops to its own full-width row below. Without this, the search
     sat between nav and actions in fold view and pushed the Sign up
     button onto a wrapped row. */
  .topbar__nav     { order: 1; }
  .topbar__actions { order: 2; margin-left: auto; }
  .search          { order: 3; flex-basis: 100%; width: 100%; }

  /* Show the search-toggle icon at the end of the nav, hide the
     inline search by default, and reveal it as a full-width row
     when the toggle has been activated. */
  .topbar__search-toggle               { display: inline-flex; }
  .search                              { display: none; }
  .topbar--search-open .search         { display: flex; }

  /* Anonymous topbar shows both "Login" (text-link) and "Sign up"
     (primary button). On fold/mobile only the Sign up button is
     surfaced — the Login link hides. Authed state (Logout / My
     Channel / bell) is untouched. */
  [data-account-actions] > .text-link {
    display: none;
  }

  .topbar__actions--compact {
    min-width: auto;
  }
}

@media (max-width: 760px) {
  .topbar {
    flex-wrap: wrap;
    gap: 14px;
    padding: 12px 16px 0;
  }

  .search {
    order: 3;
    width: 100%;
  }

  .content-grid {
    padding: 18px 16px 28px;
  }

  .genre-bar {
    padding: 14px 16px 0;
  }

  .feature-card__media {
    min-height: 380px;
  }

  .feature-card__overlay {
    left: 20px;
    right: 54px;
    bottom: 20px;
  }

  .feature-card__overlay h2 {
    font-size: 2.2rem;
  }

  .video-row,
  .poster-row,
  .shorts-shelf,
  .feed-grid,
  .list-grid {
    grid-template-columns: 1fr;
  }
}

/* Small phones (~412px Pixel / Galaxy and below). The topbar's
   first row — `[logo][nav][Sign up]` — needs ~436px of content
   width to fit; below this breakpoint the nav has to give up an
   item or the Sign up button wraps. Hiding Clips keeps the row
   single-line. The /clips entry is still reachable from the
   left-rail drawer and the homepage Clips shelf. */
@media (max-width: 412px) {
  /* On small phones, drop both Clips and Home from the topbar nav.
     The injected topbar__logo is an <a href="/">, so it already
     covers "go home" — a separate Home nav item is redundant here
     and the freed space keeps the row single-line. */
  .topbar__nav [href="/clips"],
  .topbar__nav [href="/"] {
    display: none;
  }

  /* On small phones, the toggle-to-search pattern is friction —
     drop the icon and just show the search input inline as a
     full-width row below the nav. The existing ≤980px rules
     already give it `order: 3; flex-basis: 100%; width: 100%`. */
  .topbar__search-toggle {
    display: none;
  }
  .search {
    display: flex;
  }
}

.watch-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 24px;
  padding: 18px 22px 36px;
}

.watch-main,
.watch-sidebar {
  min-width: 0;
}

.watch-main {
  display: grid;
  gap: 18px;
}

.watch-player__media {
  position: relative;
  min-height: 620px;
  overflow: hidden;
  border-radius: 24px;
  background: #08101c;
}

/* "Tap to unmute" affordance — only visible while the autoplayed
   video is still muted. Sits above the <video> (z-index:3) so it
   captures clicks before the native controls underneath. */
.watch-player__unmute {
  position: absolute;
  top: 16px;
  left: 16px;
  z-index: 3;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 8px 14px;
  border: 0;
  border-radius: 999px;
  background: rgba(10, 10, 14, 0.7);
  color: #fff;
  font: inherit;
  font-size: 0.92rem;
  cursor: pointer;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  transition: background 140ms ease, transform 140ms ease;
}

.watch-player__unmute:hover,
.watch-player__unmute:focus-visible {
  background: rgba(10, 10, 14, 0.85);
  transform: scale(1.02);
  outline: 0;
}

.watch-player__unmute[hidden] {
  display: none;
}

.watch-player__unmute svg {
  width: 18px;
  height: 18px;
}

.watch-related-card__thumb::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 50% 18%, rgba(255, 255, 255, 0.18), transparent 16%),
    linear-gradient(180deg, transparent 22%, rgba(0, 0, 0, 0.3) 100%);
}

.watch-player__play {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 1;
  display: inline-grid;
  place-items: center;
  width: 82px;
  height: 82px;
  border: 0;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  font-size: 1.5rem;
  backdrop-filter: blur(12px);
  cursor: pointer;
}

.watch-player__timeline {
  position: absolute;
  left: 18px;
  right: 18px;
  bottom: 18px;
  z-index: 1;
  height: 5px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.22);
}

.watch-player__progress {
  display: block;
  width: 36%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
}

.watch-header {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
}

.watch-header__eyebrow {
  margin: 0 0 10px;
  color: var(--text-faint);
  font-size: 0.78rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.watch-title {
  margin: 0;
  font-size: 1.2rem;
  line-height: 1.2;
}

.watch-stats {
  margin: 10px 0 0;
  color: var(--text-soft);
  font-size: 14px;
}

.watch-actions {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  gap: 10px;
}

.watch-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 11px 16px;
  border: 1px solid var(--line);
  border-radius: 999px;
  color: var(--text);
  background: var(--bg-soft);
}

.watch-pill--icon {
  gap: 8px;
}

.watch-pill__icon {
  display: inline-grid;
  place-items: center;
  width: 18px;
  height: 18px;
  font-size: 0.95rem;
  line-height: 1;
}

.watch-pill__text {
  line-height: 1;
}

.watch-pill--strong {
  border-color: transparent;
  background: linear-gradient(135deg, var(--accent), var(--accent-strong));
  color: #fff;
}

.watch-channel-card,
.watch-description,
.watch-comments,
.watch-sidebar__panel {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}

.watch-channel-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.watch-channel-card__main,
.watch-channel-card__actions,
.comment-card,
.comment-card__author,
.watch-section-head,
.watch-related-card {
  display: flex;
}

.watch-channel-card__main,
.comment-card,
.watch-related-card {
  gap: 14px;
}

.avatar--channel {
  width: 54px;
  height: 54px;
  font-size: 1rem;
}

.watch-channel-card__text h2,
.watch-section-head h2,
.watch-related-card__body h3 {
  margin: 0;
}

.watch-channel-card__text h2,
.watch-section-head h2 {
  font-size: 1.2rem;
  line-height: 1.2;
}

.watch-channel-card__text p,
.watch-related-card__body p,
.watch-related-card__body small,
.comment-card__author span {
  color: var(--text-soft);
}

.watch-channel-card__actions {
  align-items: center;
  gap: 10px;
}

.watch-description p,
.comment-card__body p {
  margin: 0;
  line-height: 1.7;
}

.watch-description__tags {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 14px;
}

.watch-description__tags a {
  color: var(--accent);
}

.watch-section-head {
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 16px;
}

.watch-section-head span {
  color: var(--text-soft);
}

.watch-comments {
  display: grid;
  gap: 16px;
}

.comment-card__body {
  display: grid;
  gap: 10px;
}

.comment-card__author {
  align-items: center;
  gap: 10px;
}

.comment-card__actions {
  display: flex;
  gap: 16px;
}

.comment-card__actions a {
  color: var(--accent);
}

.comment-composer {
  display: flex;
  gap: 14px;
}

.comment-composer__body {
  flex: 1;
  display: grid;
  gap: 10px;
}

.comment-composer__input {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--bg);
  color: var(--text);
  outline: 0;
  font: inherit;
  resize: vertical;
  min-height: 60px;
}

.comment-composer__actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 10px;
}

.comment-composer__cancel {
  border: 0;
  background: transparent;
  color: var(--text-soft);
  cursor: pointer;
  font: inherit;
  font-weight: 600;
}

.comment-composer__error {
  color: #c0392b;
  font-size: 0.88rem;
  font-weight: 500;
}

.comment-composer--reply .comment-composer__input {
  min-height: 44px;
}

.comment-signin {
  margin: 0;
  color: var(--text-soft);
}

.comment-card__creator-badge {
  background: var(--accent);
  color: #fff;
  padding: 2px 8px;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
  letter-spacing: 0.5px;
  text-transform: uppercase;
}

.comment-card__edited {
  color: var(--text-soft);
  font-size: 0.85rem;
  font-style: italic;
}

.comment-replies {
  margin-top: 12px;
  padding-left: 22px;
  border-left: 2px solid var(--line);
  display: grid;
  gap: 12px;
}

.watch-sidebar__panel {
  display: grid;
  gap: 18px;
  padding: 0;
  border: 0;
  border-radius: 0;
  background: transparent;
  box-shadow: none;
}

.watch-sidebar__panel > [data-watch-related] {
  display: grid;
  gap: 28px;
}

.watch-related-card {
  align-items: flex-start;
  gap: 16px;
}

/* "More Live Channels" — clamp the channel description to 2 lines. */
[data-stream-channels] .watch-related-card__body p {
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.watch-related-card__thumb {
  position: relative;
  display: block;
  width: 168px;
  min-width: 168px;
  height: 94px;
  overflow: hidden;
  border-radius: 22px;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.36)),
    linear-gradient(135deg, #244356 0%, #101823 100%);
}

.watch-related-card__thumb--one {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.36)),
    linear-gradient(135deg, #37475e 0%, #111722 100%);
}

.watch-related-card__thumb--two {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.36)),
    linear-gradient(135deg, #6d6656 0%, #181818 100%);
}

.watch-related-card__thumb--three {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.36)),
    linear-gradient(135deg, #51412b 0%, #141414 100%);
}

.watch-related-card__thumb--four {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.36)),
    linear-gradient(135deg, #29404a 0%, #0d1318 100%);
}

.watch-related-card__thumb--five {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.36)),
    linear-gradient(135deg, #132034 0%, #090d15 100%);
}

.watch-related-card__body {
  display: grid;
  gap: 6px;
  padding-top: 2px;
}

.watch-related-card__body h3 {
  font-size: 0.98rem;
  line-height: 1.25;
}

.watch-related-card__body p {
  margin-top: 3px;
  margin-bottom: 0px;
  font-size: 14px;
}

.watch-related-card__body small {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
}

.watch-verified {
  color: #888d98;
  font-size: 0.78rem;
  vertical-align: middle;
}

.watch-meta-icon {
  color: #c2c6cf;
  font-size: 0.78rem;
}

.watch-meta-sep {
  color: var(--text-faint);
}

@media (max-width: 1280px) {
  .watch-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .watch-layout {
    padding: 18px 16px 28px;
  }

  .watch-player__media {
    min-height: 280px;
  }

  .watch-header,
  .watch-channel-card {
    flex-direction: column;
    align-items: stretch;
  }

  .watch-actions {
    justify-content: flex-start;
  }

  .watch-related-card {
    flex-direction: column;
  }

  .watch-related-card__thumb {
    width: 100%;
    min-width: 0;
    height: 190px;
  }
}

.auth-page {
  min-height: 100vh;
  padding: 22px;
  background:
    radial-gradient(circle at top left, rgba(255, 106, 0, 0.12), transparent 24%),
    radial-gradient(circle at bottom right, rgba(255, 126, 31, 0.1), transparent 22%),
    var(--bg);
}

.auth-topbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  max-width: 1320px;
  margin: 0 auto 22px;
}

.auth-topbar__actions {
  display: flex;
  align-items: center;
  gap: 12px;
}

.auth-topbar__text,
.auth-footnote,
.auth-card__header p,
.auth-showcase__copy,
.auth-feature p {
  color: var(--text-soft);
}

.auth-layout {
  display: grid;
  grid-template-columns: 1.05fr minmax(420px, 0.85fr);
  gap: 28px;
  max-width: 1320px;
  margin: 0 auto;
}

/* Single-column variant for pages that don't carry a showcase
   (e.g. /page/interests). The card centers itself in the layout. */
.auth-layout--solo {
  grid-template-columns: minmax(420px, 720px);
  justify-content: center;
}

/* Wider card variant — needed by the interests-grid which renders 12+
   chips and would feel cramped at the default 420px min. */
.auth-card--wide {
  width: 100%;
  max-width: 720px;
  padding: 32px;
  display: grid;
  gap: 24px;
}

.auth-showcase,
.auth-card {
  border: 1px solid var(--line);
  border-radius: 28px;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}

.auth-showcase {
  position: relative;
  overflow: hidden;
  padding: 40px;
  background:
    radial-gradient(circle at top left, rgba(255, 126, 31, 0.12), transparent 22%),
    linear-gradient(135deg, var(--surface) 0%, var(--bg-soft) 100%);
}

.auth-showcase::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    linear-gradient(180deg, rgba(9, 12, 18, 0.34), rgba(9, 12, 18, 0.72)),
    linear-gradient(90deg, rgba(9, 12, 18, 0.5), rgba(9, 12, 18, 0.14));
  pointer-events: none;
}

.auth-showcase--login {
  background: url("../images/login-hero.jpg") center / cover no-repeat;
}

.auth-showcase--signup {
  background: url("../images/signup-hero.jpg") center / cover no-repeat;
}

.auth-showcase > * {
  position: relative;
  z-index: 1;
}

.auth-showcase__eyebrow,
.auth-card__eyebrow {
  margin: 0 0 12px;
  color: var(--text-faint);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.auth-showcase h1,
.auth-card h2 {
  margin: 0;
  line-height: 1.05;
}

.auth-showcase h1,
.auth-showcase__copy,
.auth-showcase__eyebrow,
.auth-feature strong,
.auth-feature p {
  color: #ffffff;
}

.auth-showcase h1 {
  max-width: 12ch;
  font-size: clamp(2.4rem, 4vw, 4.4rem);
}

.auth-showcase__copy {
  max-width: 58ch;
  margin: 18px 0 0;
  line-height: 1.7;
}

.auth-showcase__feature-list {
  display: grid;
  gap: 18px;
  margin-top: 36px;
}

.auth-feature {
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr);
  gap: 14px;
  align-items: start;
}

.auth-feature__icon {
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.14);
  color: #ffffff;
  box-shadow: none;
  backdrop-filter: blur(12px);
}

.auth-feature strong {
  display: block;
  margin-bottom: 4px;
}

.auth-interest-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 28px;
}

.auth-chip {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 10px 14px;
  border: 1px solid rgba(255, 255, 255, 0.22);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  color: #ffffff;
  backdrop-filter: blur(10px);
}

.auth-card {
  padding: 34px;
}

.auth-card__header {
  margin-bottom: 24px;
}

.auth-card__header h2 {
  font-size: 2rem;
}

.auth-card__header p {
  margin: 12px 0 0;
  line-height: 1.6;
}

.auth-socials {
  display: grid;
  gap: 12px;
}

.auth-social-kc {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 12px 18px;
  border: 0;
  border-radius: 999px;
  background: #2f6fed;
  color: #fff;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
}

.auth-social-kc:hover {
  background: #2a63d4;
}

.auth-social-kc[disabled] {
  opacity: 0.6;
  cursor: default;
}

.auth-social {
  display: flex;
  align-items: center;
  gap: 12px;
  justify-content: center;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 16px;
  background: var(--bg);
  font-weight: 600;
}

.auth-social__icon {
  display: inline-grid;
  place-items: center;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  font-size: 1rem;
  font-weight: 700;
}

.auth-social--google .auth-social__icon {
  background: #fff1e8;
  color: #ea4335;
}

.auth-social--facebook .auth-social__icon {
  background: #edf3ff;
  color: #1877f2;
}

.auth-divider {
  position: relative;
  margin: 24px 0;
  text-align: center;
}

.auth-divider::before {
  content: "";
  position: absolute;
  top: 50%;
  left: 0;
  right: 0;
  border-top: 1px solid var(--line);
}

.auth-divider span {
  position: relative;
  padding: 0 14px;
  background: var(--surface);
  color: var(--text-faint);
}

.auth-form {
  display: grid;
  gap: 16px;
}

/* `display: grid` above otherwise overrides the HTML5 `hidden` attribute,
   so the two-step forgot-password flow needs this explicit rule to keep
   the inactive step out of view. Same pattern as `.channel-modal[hidden]`. */
.auth-form[hidden] {
  display: none;
}

.auth-form__split {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.auth-field {
  display: grid;
  gap: 8px;
}

.auth-field span {
  font-size: 0.95rem;
  font-weight: 600;
}

.auth-field input {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--bg);
  color: var(--text);
  outline: 0;
}

.auth-password-wrap {
  position: relative;
}

.auth-password-wrap input {
  /* Reserve space on the right edge so the toggle button never sits on
     top of the cursor / characters. */
  padding-right: 48px;
}

.auth-password-toggle {
  position: absolute;
  right: 6px;
  top: 50%;
  transform: translateY(-50%);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  border-radius: 999px;
  background: transparent;
  color: var(--text-soft);
  cursor: pointer;
}

.auth-password-toggle:hover,
.auth-password-toggle:focus-visible {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text);
  outline: 0;
}

.auth-password-toggle svg {
  width: 20px;
  height: 20px;
  display: block;
}

.auth-password-toggle [data-password-eye-off] {
  display: none;
}

.auth-password-toggle.is-visible [data-password-eye] {
  display: none;
}

.auth-password-toggle.is-visible [data-password-eye-off] {
  display: block;
}

/* ── OTP code input (single field, large monospace, letter-spaced) ─── */

.otp-input {
  font-size: 1.75rem;
  font-weight: 700;
  letter-spacing: 12px;
  text-align: center;
  font-variant-numeric: tabular-nums;
}

/* ── Onboarding interests page ─────────────────────────────────────── */

.interests-status {
  margin: 0;
  color: var(--text-soft);
  font-size: 0.95rem;
}

.interests-status--error {
  color: #ff8f8f;
}

.interests-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.interest-chip {
  border: 1px solid var(--line);
  border-radius: 999px;
  padding: 10px 18px;
  background: var(--bg);
  color: var(--text);
  font: inherit;
  font-weight: 500;
  cursor: pointer;
  transition: background 120ms ease, border-color 120ms ease, color 120ms ease;
}

.interest-chip:hover {
  border-color: rgba(255, 255, 255, 0.18);
}

.interest-chip.is-selected {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
}

.interests-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.interests-counter {
  color: var(--text-soft);
  font-size: 0.9rem;
}

.interests-counter--warn {
  color: #ffb648;
  transition: color 120ms ease;
}

.auth-form__row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
}

.auth-check {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: var(--text-soft);
}

.auth-check--stacked {
  align-items: flex-start;
  line-height: 1.55;
}

.auth-link {
  color: var(--accent);
  background: transparent;
  border: 0;
  padding: 0;
  font: inherit;
  cursor: pointer;
  text-decoration: none;
}

.auth-submit {
  width: 100%;
  min-height: 50px;
}

.auth-outline {
  border: 1px solid var(--line);
  background: var(--surface);
}

.auth-footnote {
  margin: 18px 0 0;
  font-size: 0.92rem;
  line-height: 1.6;
}

.channel-modal[hidden] {
  display: none;
}

.channel-modal {
  position: fixed;
  inset: 0;
  z-index: 60;
}

.channel-modal__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(17, 20, 28, 0.42);
}

.channel-modal__dialog {
  position: relative;
  width: min(calc(100% - 24px), 900px);
  margin: min(36px, 5vh) auto;
  border-radius: 22px;
  background: #ffffff;
  color: #20222b;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.22);
  overflow: hidden;
}

.channel-modal__header {
  padding: 28px 32px 0;
}

.channel-modal__header h2 {
  margin: 0;
  font-size: clamp(2rem, 3vw, 2.7rem);
  line-height: 1.05;
}

.channel-modal__body {
  display: grid;
  justify-items: center;
  gap: 22px;
  padding: 28px 32px 24px;
}

.channel-modal__picture {
  display: grid;
  justify-items: center;
  gap: 12px;
  border: 0;
  background: transparent;
  color: #2563eb;
  cursor: pointer;
}

.channel-modal__cover {
  width: min(100%, 570px);
  height: 140px;
  padding: 0;
  border: 2px dashed #dde1ea;
  border-radius: 14px;
  background: #f6f7fa;
  background-size: cover;
  background-position: center;
  color: #4a5568;
  cursor: pointer;
  display: grid;
  place-items: center;
  overflow: hidden;
  font: inherit;
}

.channel-modal__cover-hint {
  background: rgba(255, 255, 255, 0.88);
  padding: 6px 14px;
  border-radius: 999px;
  font-size: 0.92rem;
  font-weight: 600;
}

.channel-modal__picture-icon {
  display: inline-grid;
  place-items: center;
  width: 154px;
  height: 154px;
  border-radius: 50%;
  background: linear-gradient(180deg, #9bbcff, #4e73df);
  color: rgba(35, 70, 180, 0.85);
  font-size: 4.2rem;
}

.channel-modal__picture-preview {
  width: 154px;
  height: 154px;
  border-radius: 50%;
  object-fit: cover;
}

.channel-modal__picture-label {
  font-weight: 600;
}

.channel-modal__form {
  display: grid;
  gap: 16px;
  width: min(100%, 570px);
}

.channel-modal__form .auth-field input {
  background: #ffffff;
  border-color: #dde1ea;
  color: #20222b;
}

.channel-modal__note {
  width: min(100%, 570px);
  margin: 0;
  color: #6b7280;
  font-size: 0.95rem;
  line-height: 1.65;
}

.channel-modal__footer {
  display: flex;
  justify-content: flex-end;
  gap: 18px;
  padding: 0 32px 24px;
}

.channel-modal__text-button,
.channel-modal__primary {
  border: 0;
  background: transparent;
  cursor: pointer;
  font: inherit;
}

.channel-modal__text-button {
  color: #20222b;
  font-weight: 600;
}

.channel-modal__primary {
  color: #2563eb;
  font-weight: 700;
}

.channel-modal__primary[disabled],
.channel-modal__text-button[disabled] {
  opacity: 0.55;
  cursor: not-allowed;
}

.channel-modal__form textarea {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid #dde1ea;
  border-radius: 14px;
  background: #ffffff;
  color: #20222b;
  outline: 0;
  font: inherit;
  resize: vertical;
  min-height: 92px;
}

.channel-settings-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 0;
  background: transparent;
  color: #6b7280;
  cursor: pointer;
  font-size: 50px;
  line-height: 1;
}

.channel-settings-btn:hover {
  color: #20222b;
}

.channel-modal__dialog--compact {
  max-width: 420px;
}

.channel-modal__option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 16px 4px;
  border: 0;
  border-bottom: 1px solid #eef0f4;
  background: transparent;
  cursor: pointer;
  font: inherit;
  text-align: left;
}

.channel-modal__option:last-child {
  border-bottom: 0;
}

.channel-modal__option:hover {
  background: #f7f8fb;
}

.channel-modal__option-label {
  font-weight: 600;
  color: #20222b;
}

.channel-modal__option-arrow {
  color: #98a0ac;
  font-size: 20px;
}

.channel-modal__option--danger .channel-modal__option-label {
  color: #c5302a;
}

.channel-modal__warning {
  margin: 0 0 18px;
  padding: 14px 16px;
  border-radius: 12px;
  background: #fdecec;
  color: #7a1f1b;
  font-size: 14px;
  line-height: 1.5;
}

.channel-modal__primary--danger {
  color: #c5302a;
}

.edit-field-error {
  color: #c0392b;
  font-size: 0.88rem;
  font-weight: 500;
}

@media (max-width: 980px) {
  .auth-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  .auth-page {
    padding: 16px;
  }

  .auth-topbar {
    flex-direction: column;
    align-items: stretch;
  }

  .auth-topbar__actions,
  .auth-form__row {
    flex-direction: column;
    align-items: stretch;
  }

  .auth-showcase,
  .auth-card {
    padding: 24px;
  }

  .auth-form__split {
    grid-template-columns: 1fr;
  }

  .auth-card__header h2 {
    font-size: 1.65rem;
  }

  .auth-showcase h1 {
    font-size: 2.4rem;
  }

  .channel-modal__header,
  .channel-modal__body,
  .channel-modal__footer {
    padding-left: 20px;
    padding-right: 20px;
  }

  .channel-modal__footer {
    justify-content: space-between;
  }
}

.channel-page {
  padding: 18px 22px 36px;
}

.channel-cover {
  height: clamp(140px, 22vw, 240px);
  border-radius: 18px;
  margin-bottom: 22px;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.32)),
    linear-gradient(135deg, #2c3445, #1a1f2c);
  background-size: cover;
  background-position: center;
}

.channel-hero {
  display: grid;
  grid-template-columns: 160px minmax(0, 1fr);
  gap: 30px;
  align-items: center;
}

/* Avatar-less variant used on /saved (and pages like /likes, /history,
   /manage-videos that have no avatar). Drops the reserved 160px
   avatar column so the title + subtitle get the full row width, and
   pins both to a single line — overflow clips with an ellipsis on
   very narrow phones rather than horizontally scrolling. */
.channel-hero--simple {
  grid-template-columns: minmax(0, 1fr);
}

.channel-hero--simple .channel-profile__header h1,
.channel-hero--simple .channel-profile__header p {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: none;
}

.channel-hero--simple .channel-profile__header h1 {
  font-size: 2rem;
}

.channel-hero--simple .channel-profile__header p {
  margin-top: 0;
  margin-bottom: 5px;
}

.channel-avatar {
  width: 160px;
  height: 160px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  color: #fff;
  font-size: 3.4rem;
  font-weight: 700;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.2)),
    linear-gradient(135deg, #5c6571, #20242d);
  background-size: cover;
  background-position: center;
}

.channel-profile {
  display: grid;
  gap: 18px;
}

.channel-profile__header h1 {
  margin: 0;
  font-size: clamp(2rem, 3vw, 3rem);
}

.channel-profile__header p {
  max-width: 72ch;
  margin: 12px 0 0;
  color: var(--text-soft);
  line-height: 1.65;
}

.channel-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 12px;
}

.channel-stat-button,
.channel-icon-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  height: 40px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--surface);
  color: var(--text);
}

.channel-stat-button {
  padding: 0 14px;
}

.channel-stat-button__icon {
  color: var(--text-faint);
}

.channel-icon-link {
  width: 40px;
  padding: 0;
}

.channel-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 28px;
  margin-top: 26px;
  border-bottom: 1px solid var(--line);
}

.channel-tabs__item {
  position: relative;
  display: inline-flex;
  gap: 6px;
  padding: 0 0 14px;
  border: 0;
  background: transparent;
  padding: 0 0 14px;
  color: var(--text);
  cursor: pointer;
}

.channel-tabs__item span {
  color: var(--accent);
}

.channel-tabs__item--active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 2px;
  background: var(--text);
}

.channel-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 22px 18px;
  padding-top: 22px;
}

.channel-grid--compact {
  grid-template-columns: repeat(1, minmax(0, 320px));
}

.channel-panel[hidden] {
  display: none;
}

.people-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 20px;
  padding-top: 22px;
}

.person-card {
  display: grid;
  justify-items: start;
  gap: 12px;
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}

.person-card__avatar {
  width: 84px;
  height: 84px;
  border-radius: 50%;
  overflow: hidden;
  display: grid;
  place-items: center;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.2)),
    linear-gradient(135deg, #5c6571, #20242d);
  background-size: cover;
  background-position: center;
}

.person-card__avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.person-card h3 {
  margin: 0;
  font-size: 1rem;
}

.person-card p {
  margin: 0;
  color: var(--text-soft);
  line-height: 1.55;
}

.channel-card {
  min-width: 0;
}

.channel-card__thumb {
  position: relative;
  display: block;
  height: 224px;
  overflow: hidden;
  border-radius: 18px;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.36)),
    linear-gradient(135deg, #244356 0%, #101823 100%);
}

.channel-card__thumb::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 50% 18%, rgba(255, 255, 255, 0.16), transparent 16%),
    linear-gradient(180deg, transparent 25%, rgba(0, 0, 0, 0.28) 100%);
}

.channel-card__thumb--one {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.36)),
    linear-gradient(135deg, #43718b 0%, #112332 100%);
}

.channel-card__thumb--two {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.36)),
    linear-gradient(135deg, #5cbcd2 0%, #12303c 100%);
}

.channel-card__thumb--three {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.36)),
    linear-gradient(135deg, #486b6c 0%, #203432 100%);
}

.channel-card__thumb--four {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.36)),
    linear-gradient(135deg, #d4c5b7 0%, #9f8a7e 100%);
}

.channel-card__thumb--five {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.36)),
    linear-gradient(135deg, #0e1318 0%, #264165 100%);
}

.channel-card__thumb--six {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.36)),
    linear-gradient(135deg, #a1bcc5 0%, #ce3624 100%);
}

.channel-card__thumb--seven {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.36)),
    linear-gradient(135deg, #ae8a67 0%, #2a1f24 100%);
}

.channel-card__thumb--eight {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.36)),
    linear-gradient(135deg, #b9ae90 0%, #354046 100%);
}

.channel-card__thumb--nine {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.36)),
    linear-gradient(135deg, #d8a47f 0%, #63718a 100%);
}

.channel-card__thumb--ten {
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.36)),
    linear-gradient(135deg, #8f856d 0%, #5e6877 100%);
}

.channel-card__play {
  position: absolute;
  top: 50%;
  left: 50%;
  z-index: 1;
  display: inline-grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  transform: translate(-50%, -50%);
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
  backdrop-filter: blur(10px);
}

.channel-card h3 {
  margin: 12px 0 0;
  font-size: 0.98rem;
  line-height: 1.3;
}

.channel-card p,
.channel-card small {
  display: block;
  margin-top: 6px;
  color: var(--text-soft);
}

.channel-card small {
  display: flex;
  align-items: center;
  gap: 8px;
}

@media (max-width: 1280px) {
  .channel-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .people-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 980px) {
  .channel-hero {
    grid-template-columns: 1fr;
  }

  .channel-avatar {
    width: 132px;
    height: 132px;
  }

  .channel-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .people-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .channel-page {
    padding: 18px 16px 28px;
  }

  .channel-tabs {
    gap: 18px;
  }

  .channel-grid {
    grid-template-columns: 1fr;
  }

  .people-grid {
    grid-template-columns: 1fr;
  }
}

.stream-page {
  padding: 18px 22px 36px;
}

.stream-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 360px;
  gap: 24px;
}

.stream-main,
.stream-sidebar {
  min-width: 0;
}

.stream-main {
  display: grid;
  gap: 18px;
}

.stream-player {
  position: relative;
  min-height: 620px;
  overflow: hidden;
  border-radius: 24px;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.55)),
    linear-gradient(135deg, #40222c 0%, #141820 50%, #08090f 100%);
}

.stream-player__video {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  z-index: 0;
  object-fit: contain;
  background: #000;
}

/* When a real stream is playing, kill the placeholder radial overlay so
   it doesn't sit on top of the video frame. The top/bottom overlay bars
   still render above (they carry z-index: 1) so the LIVE chip and
   "now playing" caption remain visible. */
.stream-player--active::before {
  display: none;
}

.stream-player::before,
.stream-creator-card__avatar::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 50% 18%, rgba(255, 255, 255, 0.16), transparent 16%),
    linear-gradient(180deg, transparent 22%, rgba(0, 0, 0, 0.3) 100%);
}

/* /live-stream — Agora playback variant. Solo column (no chat
   sidebar for v1), the Agora SDK injects its <video> into
   .live-stream-player__remote which mimics .stream-player__video. */
.stream-layout--solo {
  grid-template-columns: minmax(0, 1fr);
}

.live-stream-player {
  background: #000;
}

.live-stream-player::before {
  display: none;
}

.live-stream-player__remote {
  position: absolute;
  inset: 0;
  z-index: 0;
  background: #000;
}

.live-stream-player__remote video,
.live-stream-player__remote .agora_video_player {
  width: 100% !important;
  height: 100% !important;
  object-fit: contain !important;
}

.live-stream-player__status {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 32px;
  color: #fff;
  text-align: center;
  font-size: 1.05rem;
  font-weight: 600;
  background: linear-gradient(135deg, rgba(20, 20, 28, 0.78), rgba(8, 9, 15, 0.78));
}

.live-stream-player__status[hidden] {
  display: none;
}

/* Action row below the stream box — like + gift. The hearts container
   stays inside the player (non-interactive) and hosts the floating ♥
   animation triggered on like. */
.live-stream-actions {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 14px;
}

.live-stream-player__like {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border: 0;
  border-radius: 999px;
  background: rgba(10, 10, 14, 0.6);
  color: #fff;
  font: inherit;
  font-size: 0.92rem;
  font-weight: 700;
  cursor: pointer;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  transition: transform 140ms ease, background 140ms ease;
}

.live-stream-player__like[hidden] { display: none; }

.live-stream-player__like:hover,
.live-stream-player__like:focus-visible {
  background: rgba(10, 10, 14, 0.82);
  outline: 0;
  transform: scale(1.03);
}

.live-stream-player__like-icon {
  width: 18px;
  height: 18px;
  fill: none;
  stroke: #fff;
  stroke-width: 2;
  transition: fill 160ms ease, stroke 160ms ease, transform 160ms ease;
}

.live-stream-player__like--on .live-stream-player__like-icon {
  fill: #ff5860;
  stroke: #ff5860;
  transform: scale(1.08);
}

.live-stream-player__gift {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 8px 14px;
  border: 0;
  border-radius: 999px;
  background: rgba(10, 10, 14, 0.6);
  color: #fff;
  font: inherit;
  font-size: 0.92rem;
  font-weight: 700;
  cursor: pointer;
  backdrop-filter: blur(6px);
  -webkit-backdrop-filter: blur(6px);
  transition: transform 140ms ease, background 140ms ease;
}

.live-stream-player__gift[hidden] { display: none; }

.live-stream-player__gift:hover,
.live-stream-player__gift:focus-visible {
  background: rgba(10, 10, 14, 0.82);
  outline: 0;
  transform: scale(1.03);
}

.live-stream-player__gift[disabled] {
  opacity: 0.45;
  cursor: default;
  pointer-events: none;
}

.live-stream-player__gift .fa-gift { color: #f5b301; }

.live-stream-player__hearts {
  position: absolute;
  inset: 0;
  z-index: 1;
  pointer-events: none;
  overflow: hidden;
}

.live-stream-player__heart {
  position: absolute;
  bottom: 60px;
  color: #ff5860;
  font-size: 22px;
  opacity: 0;
  animation: live-heart-rise 1300ms ease-out forwards;
  text-shadow: 0 2px 6px rgba(0, 0, 0, 0.35);
}

@keyframes live-heart-rise {
  0%   { transform: translate(0, 0) scale(0.6); opacity: 0; }
  20%  { opacity: 1; }
  100% { transform: translate(var(--drift, -8px), -180px) scale(1.1); opacity: 0; }
}

.stream-player__top,
.stream-player__bottom {
  position: absolute;
  left: 18px;
  right: 18px;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  color: #fff;
}

.stream-player__top {
  top: 18px;
}

.stream-player__bottom {
  bottom: 18px;
}

.stream-player__meta {
  padding: 6px 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.14);
  backdrop-filter: blur(10px);
}

.stream-player__center {
  position: absolute;
  inset: 0;
  display: grid;
  place-items: center;
}

.stream-player__play {
  display: inline-grid;
  place-items: center;
  width: 82px;
  height: 82px;
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.14);
  color: #fff;
  font-size: 1.5rem;
  backdrop-filter: blur(12px);
  cursor: pointer;
}

.stream-header,
.stream-creator-card {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
}

.stream-header__copy h1,
.stream-creator-card__main h2 {
  margin: 0;
}

.stream-header__copy p {
  margin: 10px 0 0;
  color: var(--text-soft);
  line-height: 1.65;
}

.stream-header__actions,
.stream-creator-card__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.stream-header__actions .watch-pill {
  border: 0;
}

.watch-pill__meta {
  color: inherit;
  opacity: 0.78;
}

.stream-creator-card,
.stream-gifts,
.stream-comments,
.stream-sidebar__panel {
  padding: 18px;
  border: 1px solid var(--line);
  border-radius: 20px;
  background: var(--surface);
  box-shadow: var(--shadow-soft);
}

/* Channel list inside the "More Live Channels" panel — stack the
   cards vertically with breathing room. Without this they butt
   against each other because they're sibling anchors with no margin. */
.stream-sidebar__panel [data-stream-channels] {
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.stream-creator-card__main {
  display: flex;
  align-items: center;
  gap: 14px;
}

.stream-creator-card__avatar {
  position: relative;
  width: 64px;
  height: 64px;
  overflow: hidden;
  border-radius: 50%;
  background:
    linear-gradient(180deg, rgba(0, 0, 0, 0.06), rgba(0, 0, 0, 0.24)),
    linear-gradient(135deg, #5c6571, #20242d);
  background-size: cover;
  background-position: center;
}

.stream-creator-card__main p {
  margin: 6px 0 0;
  color: var(--text-soft);
}

.stream-gifts__grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 14px;
}

.gift-card {
  display: grid;
  justify-items: center;
  gap: 8px;
  padding: 16px 12px;
  border: 1px solid var(--line);
  border-radius: 18px;
  background: var(--bg-soft);
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
  cursor: pointer;
}

.gift-card:hover,
.gift-card:focus-visible {
  transform: translateY(-2px);
  border-color: rgba(230, 0, 0, 0.22);
  box-shadow: 0 12px 24px rgba(230, 0, 0, 0.08);
}

.gift-card.is-selected {
  border-color: var(--accent);
  background: rgba(230, 0, 0, 0.06);
  box-shadow: 0 16px 30px rgba(230, 0, 0, 0.12);
}

.gift-card__icon {
  font-size: 1.6rem;
  letter-spacing: 0.1em;
  color: #f5b301;
}

.gift-card small {
  color: var(--text-soft);
}

.stream-gifts__status {
  margin: 14px 0 0;
  color: var(--text-soft);
}

.stream-comments {
  display: grid;
  gap: 14px;
}

.stream-comments__list {
  display: grid;
  gap: 14px;
}

.stream-comment {
  display: flex;
  gap: 12px;
  align-items: flex-start;
}

.stream-comment p {
  margin: 6px 0 0;
  color: var(--text-soft);
  line-height: 1.6;
}

.stream-comment-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.stream-comment-form input {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--bg);
  color: var(--text);
}

.stream-sidebar {
  display: grid;
  align-content: start;
  gap: 18px;
}

.stream-sidebar__panel {
  display: grid;
  gap: 14px;
}

.stream-chat {
  display: grid;
  gap: 10px;
  max-height: 300px;
  overflow: auto;
}

.stream-chat__signin {
  margin: 0;
  color: var(--text-soft);
  font-size: 0.9rem;
}

.stream-chat__signin a {
  color: var(--accent);
  text-decoration: underline;
}

.stream-chat__message {
  padding: 10px 12px;
  border-radius: 14px;
  background: var(--bg-soft);
  line-height: 1.5;
}

/* Special gift bubble — brand-purple tint with the gift PNG appended inline,
   aligning with the mobile LivestreamScreen gift bubble. */
.stream-chat__message--gift {
  background: rgba(123, 74, 216, 0.12);
  border: 1px solid rgba(123, 74, 216, 0.35);
}

.stream-chat__gift-icon {
  width: 22px;
  height: 22px;
  object-fit: contain;
  vertical-align: middle;
  margin-left: 6px;
}

/* "{name} joined" system notice — subtle, italic. */
.stream-chat__message--join {
  background: transparent;
  padding-top: 4px;
  padding-bottom: 4px;
  font-style: italic;
  font-size: 0.85em;
  opacity: 0.7;
}

.stream-chat__form {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 10px;
}

.stream-chat__form input {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 14px;
  background: var(--bg);
  color: var(--text);
}

@media (max-width: 1280px) {
  .stream-layout {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 980px) {
  .stream-gifts__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 760px) {
  .stream-page {
    padding: 18px 16px 28px;
  }

  .stream-player {
    min-height: 300px;
  }

  .stream-header,
  .stream-creator-card {
    flex-direction: column;
    align-items: stretch;
  }

  .stream-chat__form {
    grid-template-columns: 1fr;
  }

  .stream-comment-form {
    grid-template-columns: 1fr;
  }

  .stream-gifts__grid {
    grid-template-columns: 1fr 1fr;
  }
}

/* ── Custom modal helper (replaces SweetAlert) ───────────────────────
   Backed by `views/assets/js/modal.js`. One root container is appended
   to <body> on first use; backdrop + dialog are recreated per fire().
   ──────────────────────────────────────────────────────────────────── */

.mss-modal-root {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 9000;
}

.mss-modal-root--open {
  pointer-events: auto;
}

.mss-modal-backdrop {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  background: rgba(5, 5, 12, 0.66);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  animation: mss-modal-fade 140ms ease-out;
}

.mss-modal-dialog {
  width: min(100%, 420px);
  border-radius: 20px;
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: 0 32px 80px rgba(0, 0, 0, 0.5);
  padding: 28px 24px 24px;
  text-align: center;
  display: grid;
  gap: 14px;
  justify-items: center;
  color: var(--text);
  animation: mss-modal-pop 160ms cubic-bezier(0.2, 0.85, 0.4, 1.05);
}

@keyframes mss-modal-fade {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes mss-modal-pop {
  from { opacity: 0; transform: scale(0.94); }
  to   { opacity: 1; transform: scale(1); }
}

.mss-modal-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin-top: 4px;
}

.mss-modal-icon svg {
  width: 34px;
  height: 34px;
}

.mss-modal-icon--success { background: rgba(46, 204, 113, 0.18); color: #6fe3a4; }
.mss-modal-icon--error   { background: rgba(255, 88, 96, 0.18);  color: #ff8e92; }
.mss-modal-icon--warning { background: rgba(255, 182, 72, 0.18); color: #ffb648; }
.mss-modal-icon--info    { background: rgba(91, 135, 255, 0.18); color: #8aa9ff; }

.mss-modal-title {
  margin: 0;
  font-size: 1.25rem;
  font-weight: 700;
  line-height: 1.25;
}

.mss-modal-text {
  margin: 0;
  color: var(--text-soft);
  font-size: 0.96rem;
  line-height: 1.5;
}

.mss-modal-confirm {
  margin-top: 6px;
  min-width: 120px;
  padding: 12px 22px;
  border: 0;
  border-radius: 999px;
  font: inherit;
  font-weight: 700;
  color: #fff;
  background: linear-gradient(90deg, #b8568e 0%, #d367a5 100%);
  cursor: pointer;
}

.mss-modal-confirm:hover,
.mss-modal-confirm:focus-visible {
  filter: brightness(1.06);
  outline: 0;
}

/* Spinner used by Modal.loading() — replaces SweetAlert's built-in loader */

.mss-modal-spinner {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  border: 4px solid rgba(255, 255, 255, 0.12);
  border-top-color: var(--accent);
  animation: mss-modal-spin 0.8s linear infinite;
}

@keyframes mss-modal-spin {
  to { transform: rotate(360deg); }
}

/* ─────────────────────────────────────────────────────────────────────
   Video card kebab + popover menu + report-reason picker.
   Used by views/assets/js/video_actions.js on the Trending / Watch &
   Earn / Feed cards on the discover home; mirrors mobile's
   VideoReportModal flow.
   ───────────────────────────────────────────────────────────────────── */

.media-card,
.feed-card,
.watch-related-card {
  position: relative;
}

.watch-related-card .video-menu-toggle {
  top: 6px;
  right: 6px;
  width: 28px;
  height: 28px;
}

.watch-related-card .video-menu-toggle svg {
  width: 16px;
  height: 16px;
}

.video-menu-toggle {
  position: absolute;
  top: 8px;
  right: 8px;
  width: 32px;
  height: 32px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0;
  border: 0;
  border-radius: 50%;
  background: rgba(10, 10, 14, 0.55);
  color: #fff;
  cursor: pointer;
  z-index: 3;
  opacity: 0.9;
  transition: background 140ms ease, opacity 140ms ease, transform 140ms ease;
}

.video-menu-toggle:hover,
.video-menu-toggle:focus-visible {
  background: rgba(10, 10, 14, 0.85);
  opacity: 1;
  outline: 0;
  transform: scale(1.04);
}

.video-menu-toggle svg {
  width: 18px;
  height: 18px;
}

/* Pill variant — drops the absolute-position styling so the kebab can
   live inline in the /watch action row alongside Like / Save / Share. */
.video-menu-toggle.video-menu-toggle--pill {
  position: static;
  width: auto;
  height: auto;
  border-radius: 999px;
  background: var(--bg-soft);
  color: var(--text);
  opacity: 1;
  transform: none;
  z-index: auto;
}

.video-menu-toggle.video-menu-toggle--pill:hover,
.video-menu-toggle.video-menu-toggle--pill:focus-visible {
  background: var(--bg-soft);
  transform: none;
  filter: brightness(1.08);
}

.video-menu-toggle.video-menu-toggle--pill .watch-pill__icon svg {
  width: 18px;
  height: 18px;
}

.video-menu-popover {
  position: absolute;
  z-index: 9100;
  min-width: 168px;
  padding: 6px;
  border-radius: 12px;
  background: var(--surface);
  border: 1px solid var(--line);
  box-shadow: 0 16px 40px rgba(0, 0, 0, 0.45);
  display: flex;
  flex-direction: column;
  gap: 2px;
  animation: mss-modal-pop 120ms ease-out;
}

.video-menu-popover__item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 12px;
  border: 0;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 0.94rem;
  border-radius: 8px;
  cursor: pointer;
  text-align: left;
  width: 100%;
}

.video-menu-popover__item:hover,
.video-menu-popover__item:focus-visible {
  background: rgba(255, 255, 255, 0.06);
  outline: 0;
}

.video-menu-popover__icon {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
  color: var(--text-soft);
}

.video-report-dialog {
  width: min(100%, 380px);
  padding: 22px 18px 18px;
  text-align: left;
  justify-items: stretch;
  gap: 10px;
}

.video-report-dialog .mss-modal-title {
  text-align: center;
}

.video-report-list {
  list-style: none;
  padding: 0;
  margin: 6px 0 4px;
  display: flex;
  flex-direction: column;
}

.video-report-list__row {
  width: 100%;
  padding: 14px 12px;
  border: 0;
  background: transparent;
  color: var(--text);
  font: inherit;
  font-size: 0.98rem;
  text-align: left;
  cursor: pointer;
  border-radius: 10px;
  border-bottom: 1px solid var(--line);
}

.video-report-list li:last-child .video-report-list__row {
  border-bottom: 0;
}

.video-report-list__row:hover,
.video-report-list__row:focus-visible {
  background: rgba(255, 255, 255, 0.06);
  outline: 0;
}

.video-report-dialog__cancel {
  margin-top: 4px;
  padding: 10px;
  border: 0;
  background: transparent;
  color: var(--text-soft);
  font: inherit;
  font-size: 0.95rem;
  cursor: pointer;
  border-radius: 8px;
}

.video-report-dialog__cancel:hover,
.video-report-dialog__cancel:focus-visible {
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
  outline: 0;
}

/* ─────────────────────────────────────────────────────────────────────
   Share bottom sheet — mirrors mobile src/components/ShareSheet.js.
   Opened by views/assets/js/share.js::openVideoShareSheet().
   ───────────────────────────────────────────────────────────────────── */

.mss-share-root {
  position: fixed;
  inset: 0;
  z-index: 9050;
  pointer-events: none;
}

.mss-share-root--open {
  pointer-events: auto;
}

.mss-share-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(5, 5, 12, 0.6);
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  animation: mss-modal-fade 140ms ease-out;
}

.mss-share-panel {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  max-width: 520px;
  margin: 0 auto;
  padding: 14px 18px 18px;
  border-radius: 20px 20px 0 0;
  background: var(--surface);
  border-top: 1px solid var(--line);
  box-shadow: 0 -16px 40px rgba(0, 0, 0, 0.45);
  color: var(--text);
  animation: mss-share-slide-up 200ms cubic-bezier(0.2, 0.85, 0.4, 1.05);
}

@keyframes mss-share-slide-up {
  from { transform: translateY(100%); opacity: 0; }
  to   { transform: translateY(0);    opacity: 1; }
}

.mss-share-handle {
  display: block;
  width: 44px;
  height: 4px;
  border-radius: 2px;
  background: rgba(255, 255, 255, 0.18);
  margin: 4px auto 14px;
}

.mss-share-title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 700;
}

.mss-share-subtitle {
  margin: 4px 0 14px;
  color: var(--text-soft);
  font-size: 0.92rem;
}

.mss-share-tiles {
  display: flex;
  gap: 16px;
  overflow-x: auto;
  padding: 4px 0 14px;
  scrollbar-width: none;
}

.mss-share-tiles::-webkit-scrollbar { display: none; }

.mss-share-tile {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  padding: 0;
  border: 0;
  background: transparent;
  color: var(--text);
  cursor: pointer;
  min-width: 64px;
  font: inherit;
}

.mss-share-tile__icon {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 50%;
  color: #fff;
  transition: transform 120ms ease, filter 120ms ease;
}

.mss-share-tile__icon svg {
  width: 28px;
  height: 28px;
}

.mss-share-tile:hover .mss-share-tile__icon,
.mss-share-tile:focus-visible .mss-share-tile__icon {
  transform: scale(1.04);
  filter: brightness(1.06);
  outline: 0;
}

.mss-share-tile__label {
  font-size: 0.86rem;
  color: var(--text-soft);
}

.mss-share-rows {
  display: flex;
  flex-direction: column;
  gap: 2px;
  border-top: 1px solid var(--line);
  padding-top: 8px;
  margin-top: 4px;
}

.mss-share-row {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 12px 8px;
  border: 0;
  background: transparent;
  color: var(--text);
  font: inherit;
  border-radius: 10px;
  cursor: pointer;
  text-align: left;
}

.mss-share-row:hover,
.mss-share-row:focus-visible {
  background: rgba(255, 255, 255, 0.06);
  outline: 0;
}

.mss-share-row__icon {
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.07);
  color: var(--accent);
  flex-shrink: 0;
}

.mss-share-row__icon svg {
  width: 20px;
  height: 20px;
}

.mss-share-row__text {
  display: flex;
  flex-direction: column;
  gap: 2px;
}

.mss-share-row__title {
  font-weight: 600;
}

.mss-share-row__sub {
  font-size: 0.86rem;
  color: var(--text-soft);
}

.mss-share-cancel {
  display: block;
  width: 100%;
  margin-top: 10px;
  padding: 12px;
  border: 0;
  background: transparent;
  color: var(--text-soft);
  font: inherit;
  cursor: pointer;
  border-radius: 10px;
}

.mss-share-cancel:hover,
.mss-share-cancel:focus-visible {
  color: var(--text);
  background: rgba(255, 255, 255, 0.04);
  outline: 0;
}

/* Welcome / value-prop screen — mirror of mobile WelcomeScreen.js. */

.welcome-layout {
  width: 100%;
  max-width: 560px;
  margin: 0 auto;
  padding: 32px 24px 48px;
  box-sizing: border-box;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.welcome-hero {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  margin-bottom: 24px;
}

.welcome-logo {
  width: 84px;
  height: 84px;
  object-fit: contain;
}

.welcome-title {
  margin: 0;
  font-size: 30px;
  line-height: 1.15;
  font-weight: 800;
  color: #20222b;
}

.welcome-subtitle {
  margin: 0;
  max-width: 460px;
  font-size: 15px;
  line-height: 1.5;
  color: #505563;
}

.welcome-features {
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 14px;
  margin: 8px 0 24px;
}

.welcome-feature {
  display: flex;
  align-items: flex-start;
  gap: 14px;
  padding: 16px 18px;
  border: 1px solid #eef0f4;
  border-radius: 14px;
  background: #ffffff;
  text-align: left;
}

.welcome-feature__icon {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  background: rgba(195, 93, 152, 0.12);
  color: #c45d98;
  font-size: 22px;
  line-height: 1;
}

.welcome-feature__copy {
  flex: 1 1 auto;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.welcome-feature__title {
  margin: 0;
  font-size: 16px;
  font-weight: 700;
  color: #20222b;
}

.welcome-feature__desc {
  margin: 0;
  font-size: 14px;
  line-height: 1.5;
  color: #5b6172;
}

.welcome-cta {
  width: 100%;
  margin: 8px 0 18px;
  padding: 16px 24px;
  border: 0;
  border-radius: 999px;
  background: linear-gradient(90deg, #b8568e 0%, #c45d98 50%, #d367a5 100%);
  color: #ffffff;
  font-size: 16px;
  font-weight: 700;
  cursor: pointer;
}

.welcome-cta:hover {
  filter: brightness(1.05);
}

.welcome-terms {
  margin: 0;
  max-width: 420px;
  font-size: 12px;
  line-height: 1.5;
  color: #767c8a;
}

.welcome-terms__link {
  color: #c45d98;
  text-decoration: none;
}

.welcome-terms__link:hover {
  text-decoration: underline;
}

/* Topbar notifications bell — only rendered for signed-in users by the
   auth-aware swap in script.js. The badge is pre-positioned for a
   future unread-count fetch (project.align.md priority #1). */

.topbar-bell {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 36px;
  height: 36px;
  padding: 0;
  border: 0;
  background: transparent;
  color: #20222b;
  cursor: pointer;
  line-height: 1;
}

.topbar-bell:hover {
  color: #c45d98;
}

.topbar-bell__icon {
  width: 22px;
  height: 22px;
  display: block;
}

.topbar-bell__badge {
  position: absolute;
  top: 4px;
  right: 4px;
  min-width: 16px;
  height: 16px;
  padding: 0 4px;
  border-radius: 999px;
  background: #c5302a;
  color: #ffffff;
  font-size: 10px;
  font-weight: 700;
  line-height: 16px;
  text-align: center;
  box-sizing: border-box;
}

/* Right-anchored notifications drawer — opened by the topbar bell. */

.notifications-drawer {
  position: fixed;
  inset: 0;
  z-index: 60;
  pointer-events: none;
}

.notifications-drawer.is-open {
  pointer-events: auto;
}

.notifications-drawer__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(15, 18, 26, 0.45);
  opacity: 0;
  transition: opacity 0.2s ease;
}

.notifications-drawer.is-open .notifications-drawer__backdrop {
  opacity: 1;
}

.notifications-drawer__panel {
  position: absolute;
  top: 0;
  right: 0;
  display: flex;
  flex-direction: column;
  width: 380px;
  max-width: 90vw;
  height: 100%;
  background: #ffffff;
  box-shadow: -10px 0 30px rgba(15, 18, 26, 0.18);
  transform: translateX(100%);
  transition: transform 0.25s ease;
}

.notifications-drawer.is-open .notifications-drawer__panel {
  transform: translateX(0);
}

.notifications-drawer__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px;
  border-bottom: 1px solid #eef0f4;
}

.notifications-drawer__header h2 {
  margin: 0;
  font-size: 17px;
  font-weight: 700;
  color: #20222b;
}

.notifications-drawer__close {
  width: 32px;
  height: 32px;
  border: 0;
  background: transparent;
  font-size: 22px;
  line-height: 1;
  color: #5b6172;
  cursor: pointer;
}

.notifications-drawer__close:hover {
  color: #20222b;
}

.notifications-drawer__body {
  flex: 1 1 auto;
  overflow-y: auto;
  padding: 20px;
}

.notifications-drawer__empty {
  margin: 60px 0;
  text-align: center;
  color: #767c8a;
  font-size: 14px;
}

.notifications-drawer__status {
  margin: 30px 0;
  text-align: center;
  color: #767c8a;
  font-size: 13px;
}

.notifications-drawer__header-actions {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.notifications-drawer__action {
  border: 0;
  background: transparent;
  color: #c45d98;
  font-size: 13px;
  font-weight: 600;
  padding: 4px 8px;
  cursor: pointer;
}

.notifications-drawer__action:hover {
  text-decoration: underline;
}

.notifications-drawer__footer {
  border-top: 1px solid #eef0f4;
  padding: 12px 20px;
  text-align: center;
}

.notifications-drawer__footer-link {
  color: #c45d98;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
}

.notifications-drawer__footer-link:hover {
  text-decoration: underline;
}

/* Shared row styles — used by the topbar drawer and the dedicated
   /notifications page. Variants only differ in container padding. */

.notifications-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.notification-row {
  position: relative;
  border-radius: 10px;
  background: transparent;
  transition: background 0.15s ease;
}

.notification-row--unread {
  background: rgba(196, 93, 152, 0.06);
}

.notification-row:hover {
  background: rgba(15, 18, 26, 0.04);
}

.notification-row__link {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 12px;
  text-decoration: none;
  color: inherit;
}

.notification-row__avatar {
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  border-radius: 999px;
  object-fit: cover;
  background: #eef0f4;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: #20222b;
  font-weight: 700;
  font-size: 15px;
}

.notification-row__avatar--placeholder {
  background: #e7d5e3;
  color: #803b6a;
}

.notification-row__copy {
  flex: 1 1 auto;
  min-width: 0;
}

.notification-row__title {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  color: #20222b;
  line-height: 1.35;
}

.notification-row__sub {
  margin: 4px 0 0 0;
  font-size: 13px;
  color: #5b6172;
  line-height: 1.4;
  overflow: hidden;
  text-overflow: ellipsis;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}

.notification-row__time {
  display: block;
  margin-top: 6px;
  font-size: 12px;
  color: #8b91a0;
}

.notification-row__dot {
  flex: 0 0 auto;
  align-self: center;
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: #c45d98;
}

/* Dedicated /notifications page wrapper — mirrors `.channel-page`'s
   width, then overrides padding so notification rows can sit edge-to-
   edge inside the panel like a feed. */

.notifications-page-header {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 8px;
}

.notifications-page-header h1 {
  margin: 0;
}

.notifications-page-header__actions {
  display: inline-flex;
  align-items: center;
  gap: 12px;
}

.notifications-page-action {
  border: 1px solid #d6d9e0;
  background: #ffffff;
  color: #20222b;
  font-size: 13px;
  font-weight: 600;
  padding: 6px 14px;
  border-radius: 999px;
  cursor: pointer;
}

.notifications-page-action:hover {
  border-color: #c45d98;
  color: #c45d98;
}

.notifications-page-action[disabled] {
  opacity: 0.5;
  cursor: default;
}

.notifications-page-list .notification-row {
  border-bottom: 1px solid #f0f1f5;
  border-radius: 0;
}

.notifications-page-list .notification-row:last-child {
  border-bottom: 0;
}

.notifications-page-loadmore {
  display: block;
  margin: 24px auto 0;
}

.notifications-page-status {
  text-align: center;
  color: #767c8a;
  font-size: 14px;
  padding: 24px 0;
}

.notifications-tabs {
  display: flex;
  align-items: center;
  gap: 6px;
  border-bottom: 1px solid #eef0f4;
  margin: 4px 0 12px;
  padding: 0 0 0 4px;
  overflow-x: auto;
}

.notifications-tab {
  position: relative;
  border: 0;
  background: transparent;
  color: #5b6172;
  font-size: 14px;
  font-weight: 600;
  padding: 10px 14px;
  cursor: pointer;
  white-space: nowrap;
  transition: color 0.15s ease;
}

.notifications-tab:hover {
  color: #20222b;
}

.notifications-tab--active {
  color: #c45d98;
}

.notifications-tab--active::after {
  content: "";
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: -1px;
  height: 2px;
  background: #c45d98;
  border-radius: 2px;
}

/* ── Sectioned search results (discover page) ── */

.search-results__head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 8px;
}

.search-results__head .section-title {
  margin: 0;
}

.search-results__clear {
  border: 0;
  background: transparent;
  color: #c45d98;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  padding: 4px 8px;
}

.search-results__clear:hover {
  text-decoration: underline;
}

.search-tabs {
  display: flex;
  align-items: center;
  gap: 6px;
  border-bottom: 1px solid var(--card-border, #eef0f4);
  margin: 4px 0 16px;
  padding: 0 0 0 4px;
  overflow-x: auto;
}

.search-tab {
  position: relative;
  border: 0;
  background: transparent;
  color: var(--text-soft, #5b6172);
  font-size: 14px;
  font-weight: 600;
  padding: 10px 14px;
  cursor: pointer;
  white-space: nowrap;
  transition: color 0.15s ease;
}

.search-tab:hover {
  color: var(--text-primary, #20222b);
}

.search-tab--active {
  color: #c45d98;
}

.search-tab--active::after {
  content: "";
  position: absolute;
  left: 12px;
  right: 12px;
  bottom: -1px;
  height: 2px;
  background: #c45d98;
  border-radius: 2px;
}

.search-results__status {
  text-align: center;
  color: var(--text-soft, #767c8a);
  font-size: 14px;
  padding: 16px 0;
}

.search-section {
  margin: 0 0 28px 0;
}

.search-section__title {
  margin: 0 0 12px 0;
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-primary, #20222b);
}

/* ── Creator-card grid (used by search results) ── */

.creator-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 14px;
}

.creator-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
  border-radius: 14px;
  background: var(--card-bg, #ffffff);
  border: 1px solid var(--card-border, #eef0f4);
  text-decoration: none;
  color: inherit;
  transition: border-color 0.15s ease, transform 0.15s ease;
}

.creator-card:hover {
  border-color: #c45d98;
  transform: translateY(-1px);
}

.creator-card__avatar {
  width: 48px;
  height: 48px;
  border-radius: 50%;
  object-fit: cover;
  flex: 0 0 auto;
  background: #eef0f4;
  display: inline-grid;
  place-items: center;
  font-weight: 700;
  font-size: 18px;
  color: #20222b;
}

.creator-card__avatar--mono {
  background: linear-gradient(135deg, #3b3f49, #0f1218);
  color: #ffffff;
}

.creator-card__body {
  flex: 1 1 auto;
  min-width: 0;
}

.creator-card__body h3 {
  margin: 0;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-primary, #20222b);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.creator-card__body p {
  margin: 2px 0 0 0;
  font-size: 13px;
  color: var(--text-soft, #5b6172);
}

.creator-card__body small {
  display: block;
  margin-top: 4px;
  font-size: 12px;
  color: var(--text-soft, #8b91a0);
}

.creator-card__verified {
  display: inline-block;
  margin-left: 6px;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #1f8ce0;
  color: #ffffff;
  font-size: 11px;
  font-weight: 700;
  text-align: center;
  line-height: 16px;
  vertical-align: middle;
}

/* ── Wallet page (/wallet) ── */

.wallet-cards {
  display: grid;
  grid-template-columns: minmax(0, 1.75fr) minmax(0, 1fr);
  gap: 24px;
  margin: 0 0 28px;
}

@media (max-width: 760px) {
  .wallet-cards {
    grid-template-columns: minmax(0, 1fr);
  }
}

.wallet-balance-card,
.wallet-cashout-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 18px;
  color: var(--text);
}

.wallet-balance-card {
  padding: 26px 28px 0;
  overflow: hidden;
}

.wallet-balance-card__label,
.wallet-cashout-card__label {
  margin: 0;
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 1.5px;
  color: var(--text-faint);
}

.wallet-balance-card__value {
  margin: 10px 0 6px;
  font-size: 42px;
  font-weight: 700;
  line-height: 1;
}

.wallet-balance-card__hint {
  margin: 0;
  font-size: 14px;
  color: var(--text-soft);
}

.wallet-balance-card__divider {
  height: 1px;
  background: var(--line);
  margin: 24px 0;
}

.wallet-balance-card__stats {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 18px;
}

.wallet-balance-card__stat {
  min-width: 0;
}

.wallet-balance-card__stat-label {
  margin: 0;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 1.2px;
  color: var(--text-faint);
}

.wallet-balance-card__stat-value {
  margin: 6px 0 3px;
  font-size: 24px;
  font-weight: 700;
  color: var(--text);
}

.wallet-balance-card__stat-sub {
  margin: 0;
  font-size: 12px;
  color: var(--text-faint);
}

.wallet-balance-card__rate {
  margin: 24px -28px 0;
  padding: 14px 28px;
  text-align: center;
  font-size: 13px;
  color: var(--text-faint);
  background: var(--bg-muted);
  border-top: 1px solid var(--line);
}

.wallet-cashout-card {
  padding: 26px 28px;
  display: flex;
  flex-direction: column;
}

.wallet-cashout-card__title {
  margin: 10px 0;
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text);
}

.wallet-cashout-card__copy {
  margin: 0;
  font-size: 14px;
  line-height: 1.55;
  color: var(--text-soft);
}

.wallet-cashout-card__btn {
  margin-top: auto;
  align-self: stretch;
  border: 0;
  border-radius: 999px;
  padding: 15px 24px;
  font-size: 15px;
  font-weight: 700;
  color: #ffffff;
  cursor: pointer;
  background: linear-gradient(135deg, #9d4382 0%, #d987bb 100%);
  box-shadow: 0 10px 24px rgba(157, 67, 130, 0.35);
  transition: transform 0.12s ease, box-shadow 0.12s ease;
}

.wallet-cashout-card__btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 12px 28px rgba(157, 67, 130, 0.45);
}

.wallet-cashout-card__btn:active {
  transform: translateY(0);
}

.wallet-balance-card__btn {
  margin-top: 16px;
  width: 100%;
  border: 0;
  border-radius: 999px;
  padding: 14px 24px;
  font-size: 15px;
  font-weight: 700;
  color: #ffffff;
  cursor: pointer;
  background: linear-gradient(135deg, #9d4382 0%, #d987bb 100%);
}

.star-icon {
  color: #9d4382;
}

/* Load-wallet modal — payment UI only; no payment is processed. */
.loadwallet-modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.loadwallet-modal[hidden] {
  display: none;
}

.loadwallet-modal__scrim {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.62);
}

.loadwallet-modal__dialog {
  position: relative;
  width: min(100%, 420px);
  max-height: 90vh;
  overflow-y: auto;
  padding: 26px;
  border-radius: 22px;
  background: var(--surface);
  border: 1px solid var(--line);
}

.loadwallet-modal__close {
  position: absolute;
  top: 14px;
  right: 16px;
  border: 0;
  background: transparent;
  color: var(--text-soft);
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
}

.loadwallet-modal__title {
  margin: 0;
  font-size: 1.4rem;
}

.loadwallet-modal__subtitle {
  margin: 6px 0 0;
  color: var(--text-soft);
  font-size: 0.92rem;
}

.loadwallet-modal__label {
  margin: 22px 0 10px;
  color: var(--text-faint);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.loadwallet-amounts {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
}

.loadwallet-amount {
  padding: 12px 0;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--bg-muted);
  color: var(--text);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
}

.loadwallet-amount--active {
  border-color: var(--accent);
  background: var(--accent);
  color: #ffffff;
}

.loadwallet-input,
.loadwallet-select {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--bg-muted);
  color: var(--text);
  font-size: 0.95rem;
}

.loadwallet-card__element {
  padding: 13px 14px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--bg-muted);
}

.loadwallet-summary {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: 22px;
  padding: 14px 16px;
  border-radius: 12px;
  background: var(--bg-muted);
}

.loadwallet-summary__fiat {
  font-weight: 700;
  font-size: 1.05rem;
}

.loadwallet-modal__status {
  margin: 14px 0 0;
  font-size: 0.88rem;
  color: var(--text-soft);
}

.loadwallet-modal__status--error {
  color: #e0567f;
}

.loadwallet-pay {
  width: 100%;
  margin-top: 16px;
  border: 0;
  border-radius: 999px;
  padding: 15px 24px;
  font-size: 15px;
  font-weight: 700;
  color: #ffffff;
  cursor: pointer;
  background: linear-gradient(135deg, #9d4382 0%, #d987bb 100%);
}

.loadwallet-pay[disabled] {
  opacity: 0.6;
  cursor: progress;
}

.loadwallet-cancel {
  width: 100%;
  margin-top: 10px;
  padding: 8px;
  border: 0;
  background: transparent;
  color: var(--text-soft);
  font-size: 0.92rem;
  cursor: pointer;
}

.wallet-transactions {
  margin: 0;
}

.wallet-tabs {
  display: flex;
  align-items: stretch;
  border-bottom: 1px solid var(--line);
  margin: 0 0 8px;
}

.wallet-tab {
  position: relative;
  flex: 1 1 0;
  border: 0;
  background: transparent;
  color: var(--text-soft);
  font-size: 15px;
  font-weight: 600;
  padding: 14px 10px;
  cursor: pointer;
  text-align: center;
  white-space: nowrap;
  transition: color 0.15s ease;
}

.wallet-tab:hover {
  color: var(--text);
}

.wallet-tab--active {
  color: var(--text);
}

.wallet-tab--active::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -1px;
  height: 2px;
  background: #d06bab;
}

.wallet-transactions__status {
  text-align: center;
  color: var(--text-soft);
  font-size: 14px;
  padding: 24px 0;
}

.wallet-tx-list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.wallet-tx-row {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 18px 4px;
  border-bottom: 1px solid var(--line);
}

.wallet-tx-row:last-child {
  border-bottom: 0;
}

.wallet-tx-row__icon {
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: inline-grid;
  place-items: center;
  background: rgba(208, 107, 171, 0.16);
  color: #d06bab;
}

.wallet-tx-row__icon svg {
  width: 18px;
  height: 18px;
}

.wallet-tx-row__icon--pending {
  background: var(--bg-muted);
  color: var(--text-soft);
}

.wallet-tx-row__icon--rejected {
  background: rgba(255, 122, 122, 0.14);
  color: #ff8e92;
}

.wallet-tx-row__icon--gift-received,
.wallet-tx-row__icon--purchase,
.wallet-tx-row__icon--withdrawal-reversal,
.wallet-tx-row__icon--watch {
  background: rgba(46, 204, 113, 0.18);
  color: #6fe3a4;
}

.wallet-tx-row__copy {
  flex: 1 1 auto;
  min-width: 0;
}

.wallet-tx-row__title {
  margin: 0;
  font-size: 15px;
  font-weight: 700;
  color: var(--text);
}

.wallet-tx-row__sub {
  margin: 3px 0 0;
  font-size: 13px;
  color: var(--text-soft);
}

.wallet-tx-row__time {
  display: block;
  margin-top: 4px;
  font-size: 12px;
  color: var(--text-faint);
}

.wallet-tx-row__meta {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 4px;
}

.wallet-tx-row__amount {
  font-size: 16px;
  font-weight: 700;
  color: var(--text);
  font-variant-numeric: tabular-nums;
}

.wallet-tx-row--debit .wallet-tx-row__amount {
  color: var(--text-soft);
}

.wallet-tx-badge {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 9px;
  border-radius: 6px;
  text-transform: lowercase;
}

.wallet-tx-badge--available,
.wallet-tx-badge--validated {
  color: #e58cc0;
  background: rgba(208, 107, 171, 0.16);
}

.wallet-tx-badge--pending,
.wallet-tx-badge--neutral {
  color: var(--text-soft);
  background: var(--bg-muted);
}

.wallet-tx-badge--rejected {
  color: #ff8e92;
  background: rgba(255, 122, 122, 0.14);
}

.wallet-tx-loadmore {
  display: block;
  margin: 24px auto 0;
}

/* Static legal pages (Privacy Policy, etc.) */
.legal-page {
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
}

.legal-layout {
  max-width: 1080px;
  margin: 0 auto;
  padding: 32px 20px 80px;
  display: grid;
  grid-template-columns: 232px minmax(0, 1fr);
  gap: 28px;
  align-items: start;
}

.legal-nav {
  position: sticky;
  top: 24px;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 18px 16px;
  box-shadow: var(--shadow-soft);
}

.legal-nav__title {
  margin: 0 0 12px;
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--text-faint);
}

.legal-nav__list {
  list-style: none;
  margin: 0;
  padding: 0;
}

.legal-nav__list li {
  margin: 0;
}

.legal-nav__link {
  display: block;
  padding: 9px 12px;
  border-radius: 10px;
  color: var(--text-soft);
  text-decoration: none;
  font-size: 0.95rem;
}

.legal-nav__link:hover {
  background: var(--bg);
  color: var(--text);
}

.legal-nav__link.is-active {
  background: var(--accent);
  color: #fff;
  font-weight: 600;
}

@media (max-width: 760px) {
  .legal-layout {
    grid-template-columns: 1fr;
    gap: 18px;
  }

  .legal-nav {
    position: static;
  }
}

.legal-doc {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 36px clamp(20px, 5vw, 48px);
  box-shadow: var(--shadow-soft);
  line-height: 1.7;
  color: var(--text-soft);
}

.legal-title {
  margin: 0;
  font-size: 1.9rem;
  color: var(--text);
}

.legal-updated {
  margin: 6px 0 24px;
  color: var(--text-faint);
  font-size: 0.9rem;
}

.legal-h2 {
  margin: 30px 0 10px;
  font-size: 1.18rem;
  color: var(--text);
}

.legal-h3 {
  margin: 20px 0 8px;
  font-size: 1rem;
  color: var(--text);
}

.legal-doc p {
  margin: 0 0 14px;
}

.legal-doc strong {
  color: var(--text);
}

.legal-list {
  margin: 0 0 14px;
  padding-left: 22px;
}

.legal-list li {
  margin-bottom: 8px;
}

.legal-link {
  color: var(--accent);
  text-decoration: none;
}

.legal-link:hover {
  text-decoration: underline;
}

.legal-back {
  margin-top: 28px;
  padding-top: 18px;
  border-top: 1px solid var(--line);
}

/* Withdrawal modal — Espees cash-out flow on /wallet (withdraw_wallet.js). */
.withdraw-modal {
  position: fixed;
  inset: 0;
  z-index: 200;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
}
.withdraw-modal[hidden] { display: none; }
.withdraw-modal__scrim {
  position: absolute;
  inset: 0;
  background: rgba(0, 0, 0, 0.62);
}
.withdraw-modal__dialog {
  position: relative;
  width: min(100%, 440px);
  max-height: 90vh;
  overflow-y: auto;
  padding: 26px;
  border-radius: 22px;
  background: var(--surface);
  border: 1px solid var(--line);
}
.withdraw-modal__close {
  position: absolute;
  top: 14px;
  right: 16px;
  border: 0;
  background: transparent;
  color: var(--text-soft);
  font-size: 26px;
  line-height: 1;
  cursor: pointer;
}
.withdraw-modal__title { margin: 0 0 18px; font-size: 1.4rem; }
.withdraw-modal__section-label {
  margin: 22px 0 10px;
  color: var(--text-faint);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.withdraw-modal__label {
  margin: 0 0 10px;
  color: var(--text-faint);
  font-size: 0.78rem;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}
.withdraw-modal__error { margin: 0 0 10px; color: #e0556e; font-size: 0.85rem; }
.withdraw-modal__status { margin: 12px 0 0; color: var(--text-soft); font-size: 0.9rem; }
.withdraw-modal__status--error { color: #e0556e; }

.withdraw-balance { padding: 16px; border-radius: 14px; background: var(--bg-muted); }
.withdraw-balance__label { margin: 0 0 6px; color: var(--text-faint); font-size: 0.72rem; letter-spacing: 0.08em; }
.withdraw-balance__value { margin: 0; font-size: 1.6rem; font-weight: 800; }

.withdraw-hint, .withdraw-muted { margin: 0 0 10px; color: var(--text-soft); font-size: 0.9rem; }
.withdraw-add {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 1px dashed var(--line);
  border-radius: 12px;
  background: transparent;
  color: var(--accent);
  font-size: 0.92rem;
  font-weight: 700;
  padding: 11px 14px;
  cursor: pointer;
}
.withdraw-method {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 12px 14px;
  border: 1px solid var(--accent);
  border-radius: 12px;
  background: var(--bg-muted);
}
.withdraw-method__body { flex: 1; display: flex; flex-direction: column; gap: 2px; min-width: 0; }
.withdraw-method__label { font-weight: 600; font-size: 0.95rem; }
.withdraw-method__addr { color: var(--text-soft); font-size: 0.8rem; }
.withdraw-method__edit { border: 0; background: transparent; color: var(--text-soft); font-size: 0.85rem; font-weight: 600; cursor: pointer; }
.withdraw-method__remove { border: 0; background: transparent; color: var(--text-faint); font-size: 20px; line-height: 1; cursor: pointer; }

.withdraw-walletform { margin-top: 12px; padding: 14px; border-radius: 12px; border: 1px solid var(--line); background: var(--bg-muted); }
.withdraw-input {
  width: 100%;
  padding: 12px 14px;
  margin-bottom: 10px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface);
  color: var(--text);
  font-size: 0.95rem;
}
.withdraw-walletform__actions { display: flex; justify-content: flex-end; gap: 10px; }
.withdraw-btn-secondary {
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--text);
  font-weight: 600;
  padding: 10px 18px;
  cursor: pointer;
}
.withdraw-btn-primary {
  border: 0;
  border-radius: 999px;
  background: linear-gradient(135deg, #9d4382 0%, #d987bb 100%);
  color: #fff;
  font-weight: 700;
  padding: 10px 18px;
  cursor: pointer;
}

.withdraw-banner {
  margin: 0 0 10px;
  padding: 11px 14px;
  border-radius: 12px;
  background: rgba(224, 162, 59, 0.14);
  color: #c7872b;
  font-size: 0.85rem;
  line-height: 1.4;
}
.withdraw-summary { padding: 16px; border-radius: 14px; background: var(--bg-muted); }
.withdraw-summary__row { display: flex; justify-content: space-between; align-items: center; padding: 4px 0; font-size: 0.92rem; color: var(--text-soft); }
.withdraw-summary__val { color: var(--text); font-weight: 600; }
.withdraw-summary__fee { color: #e0556e; font-weight: 600; }
.withdraw-summary__divider { height: 1px; background: var(--line); margin: 8px 0; }
.withdraw-summary__row--net span:first-child { color: var(--text); font-weight: 700; font-size: 0.98rem; }
.withdraw-summary__net { color: var(--accent); font-weight: 800; font-size: 0.98rem; }

.withdraw-submit {
  width: 100%;
  margin-top: 16px;
  border: 0;
  border-radius: 999px;
  padding: 14px 24px;
  font-size: 15px;
  font-weight: 700;
  color: #fff;
  cursor: pointer;
  background: linear-gradient(135deg, #9d4382 0%, #d987bb 100%);
}
.withdraw-submit:disabled { opacity: 0.5; cursor: not-allowed; }
.withdraw-footnote { margin: 12px 0 0; color: var(--text-faint); font-size: 0.78rem; line-height: 1.5; }

.withdraw-history { margin-top: 8px; }
.withdraw-hist { display: flex; align-items: center; gap: 10px; padding: 12px 0; border-top: 1px solid var(--line); }
.withdraw-hist__body { flex: 1; display: flex; flex-direction: column; gap: 2px; }
.withdraw-hist__amount { font-weight: 600; font-size: 0.9rem; }
.withdraw-hist__date { color: var(--text-faint); font-size: 0.78rem; }
.withdraw-hist__reason { color: #e0556e; font-size: 0.78rem; }
.withdraw-hist__status { font-size: 0.82rem; font-weight: 700; }
.withdraw-hist__status.is-done { color: #3ba55d; }
.withdraw-hist__status.is-cancelled { color: #e0556e; }
.withdraw-hist__status.is-pending { color: #c7872b; }

/* Livestream gift tray Lottie (live_gift.js) + gift celebration float (live_stream.js). */
.gift-sheet__card-iconwrap {
  position: relative;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}
.gift-sheet__card-lottie {
  position: absolute;
  inset: 0;
  display: block;
}
.gift-sheet__card-lottie svg { width: 100% !important; height: 100% !important; }

.live-stream-gift-celebration {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 20%;
  display: flex;
  justify-content: center;
  pointer-events: none;
  z-index: 6;
}
.live-stream-gift-celebration__inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  animation: mss-gift-float 2600ms cubic-bezier(0.22, 1, 0.36, 1) forwards;
}
.live-stream-gift-celebration__icon {
  width: 120px;
  height: 120px;
  display: flex;
  align-items: center;
  justify-content: center;
}
.live-stream-gift-celebration__icon img,
.live-stream-gift-celebration__icon svg { width: 100%; height: 100%; object-fit: contain; }
.live-stream-gift-celebration__star { font-size: 92px; line-height: 1; color: #ffd25f; }
.live-stream-gift-celebration__caption {
  margin: 8px 0 0;
  padding: 6px 14px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.58);
  color: #fff;
  font-size: 0.9rem;
  font-weight: 600;
  white-space: nowrap;
}
@keyframes mss-gift-float {
  0%   { opacity: 0; transform: translateY(40px) scale(0.6); }
  12%  { opacity: 1; transform: translateY(24px) scale(1); }
  70%  { opacity: 1; transform: translateY(-80px) scale(1); }
  100% { opacity: 0; transform: translateY(-150px) scale(1); }
}
