:root {
  --bg: #07111f;
  --bg-soft: #0c1b2e;
  --panel: rgba(10, 21, 37, 0.86);
  --panel-strong: rgba(11, 23, 40, 0.96);
  --text: #f7f1e8;
  --muted: #9fb0c7;
  --line: rgba(255, 255, 255, 0.09);
  --accent: #ff7a45;
  --accent-soft: #ffb36b;
  --good: #89ddb0;
  --warn: #ffd27a;
  --bad: #ff8c8c;
  --chip: rgba(255, 255, 255, 0.06);
  --shadow: 0 24px 80px rgba(0, 0, 0, 0.4);
  --headline: "Bahnschrift SemiCondensed", "Arial Narrow", sans-serif;
  --body: "Aptos", "Segoe UI Variable", "Trebuchet MS", sans-serif;
}

* { box-sizing: border-box; }
html { color-scheme: dark; }
body {
  margin: 0;
  min-height: 100vh;
  font-family: var(--body);
  background: linear-gradient(180deg, #07111f 0%, #0a1426 42%, #0a1520 100%);
  color: var(--text);
  position: relative;
  overflow-x: hidden;
}

.backdrop {
  position: fixed;
  inset: auto;
  pointer-events: none;
  filter: blur(18px);
  opacity: 0.6;
}
.backdrop-one {
  width: 30rem;
  height: 30rem;
  top: -10rem;
  right: -7rem;
  background: radial-gradient(circle, rgba(255, 122, 69, 0.35), transparent 65%);
}
.backdrop-two {
  width: 24rem;
  height: 24rem;
  bottom: -5rem;
  left: -4rem;
  background: radial-gradient(circle, rgba(88, 158, 255, 0.22), transparent 65%);
}

.shell {
  width: min(1360px, calc(100% - 32px));
  margin: 0 auto;
  padding: 32px 0 56px;
  position: relative;
  z-index: 1;
}

.hero {
  display: grid;
  grid-template-columns: 1.6fr 0.9fr;
  gap: 24px;
  align-items: stretch;
}

.hero-copy,
.hero-card,
.toolbar,
.feed-panel,
.side-card,
.detail-sheet {
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: 28px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
}

.hero-copy {
  padding: 34px;
}

.hero-card {
  padding: 28px;
  background: linear-gradient(180deg, rgba(255, 122, 69, 0.16), rgba(11, 23, 40, 0.96));
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--accent-soft);
  text-transform: uppercase;
  letter-spacing: 0.16em;
  font-size: 0.74rem;
}

h1, h2, h3 {
  margin: 0;
  font-family: var(--headline);
  letter-spacing: 0.02em;
}

h1 {
  font-size: clamp(2.6rem, 5vw, 4.4rem);
  line-height: 0.95;
  max-width: 12ch;
}

h2 {
  font-size: clamp(1.45rem, 2vw, 2rem);
}

.hero-text,
.panel-meta,
.feature-list,
.coverage-list,
.source-message,
.meta-line,
.item-note,
.detail-description,
.empty-state p {
  color: var(--muted);
}

.hero-text {
  max-width: 48rem;
  margin: 16px 0 0;
  font-size: 1.05rem;
  line-height: 1.6;
}

.hero-stats {
  margin-top: 26px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.stat-pill,
.time-pill,
.source-badge,
.meta-chip,
.ghost-chip,
.filter-chip,
.price-chip {
  border: 1px solid var(--line);
  background: var(--chip);
  border-radius: 999px;
}

.stat-pill {
  padding: 10px 14px;
  color: var(--text);
  font-size: 0.92rem;
}

.feature-list {
  list-style: none;
  padding: 0;
  margin: 18px 0 0;
  display: grid;
  gap: 14px;
}

.feature-list li {
  position: relative;
  padding-left: 18px;
}

.feature-list li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.58rem;
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--accent-soft);
}

.toolbar {
  margin-top: 22px;
  padding: 18px;
  display: grid;
  gap: 16px;
}

.toolbar-row {
  display: flex;
  gap: 18px;
  justify-content: space-between;
  align-items: flex-start;
  flex-wrap: wrap;
}

.toolbar-row-secondary {
  align-items: end;
}

.toolbar-status {
  margin: 0 0 2px auto;
  padding: 13px 16px;
  border-radius: 18px;
  border: 1px solid rgba(255, 179, 107, 0.22);
  background: rgba(255, 255, 255, 0.03);
  color: var(--muted);
  font-size: 0.95rem;
  line-height: 1.2;
  white-space: nowrap;
}

.toolbar-group {
  display: grid;
  gap: 8px;
}

.toolbar-group.compact {
  min-width: 18rem;
}

.toolbar-label,
.search-wrap span,
.select-wrap span,
.hero-card-label {
  color: var(--muted);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.12em;
}

.chip-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
}

.filter-chip,
.price-chip,
.ghost-button,
.link-button,
.cta-button,
.detail-close,
.back-button {
  cursor: pointer;
  transition: transform 180ms ease, border-color 180ms ease, background 180ms ease, color 180ms ease;
}

.filter-chip,
.price-chip {
  padding: 10px 16px;
  color: var(--text);
  font: inherit;
  border: 1px solid var(--line);
  background: transparent;
}

.filter-chip.active,
.price-chip.active,
.filter-chip:hover,
.price-chip:hover {
  background: rgba(255, 122, 69, 0.14);
  border-color: rgba(255, 179, 107, 0.45);
  transform: translateY(-1px);
}

.search-wrap,
.select-wrap {
  display: grid;
  gap: 8px;
}

.search-wrap input,
.select-wrap select {
  min-width: 16rem;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid var(--line);
  background: rgba(255, 255, 255, 0.03);
  color: var(--text);
  font: inherit;
}

.content-grid {
  margin-top: 22px;
  display: grid;
  grid-template-columns: 1.7fr 0.95fr;
  gap: 22px;
  align-items: start;
}

.feed-panel,
.side-card {
  padding: 24px;
}

.panel-head {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 16px;
  margin-bottom: 18px;
}

.compact-head {
  margin-bottom: 14px;
}

.feed-list,
.source-list,
.coverage-list {
  display: grid;
  gap: 16px;
}

.showtime-card {
  display: grid;
  grid-template-columns: 132px 1fr;
  gap: 18px;
  padding: 16px;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.poster-wrap {
  aspect-ratio: 3 / 4;
  border-radius: 20px;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(255, 122, 69, 0.26), rgba(255, 255, 255, 0.04));
}

.poster {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.showtime-body { display: grid; gap: 12px; }
.showtime-headline {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 16px;
}

.time-pill {
  display: inline-flex;
  padding: 8px 12px;
  margin-bottom: 8px;
  color: var(--accent-soft);
  background: rgba(255, 179, 107, 0.08);
}

.showtime-title {
  font-size: clamp(1.25rem, 2vw, 1.7rem);
}

.link-button,
.back-button,
.ghost-button {
  border: 1px solid var(--line);
  background: transparent;
  color: var(--text);
  border-radius: 999px;
  padding: 10px 14px;
  font: inherit;
}

.link-button:hover,
.back-button:hover,
.ghost-button:hover {
  border-color: rgba(255, 179, 107, 0.45);
  background: rgba(255, 122, 69, 0.1);
}

.meta-line {
  font-size: 0.98rem;
  line-height: 1.45;
}

.badge-row {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.meta-chip,
.source-badge,
.ghost-chip {
  padding: 8px 11px;
  font-size: 0.85rem;
}

.source-badge.good { color: var(--good); }
.source-badge.warn { color: var(--warn); }
.source-badge.bad { color: var(--bad); }

.showtime-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  flex-wrap: wrap;
}

.price-block {
  font-size: 1.05rem;
  font-weight: 700;
}

.cta-button {
  text-decoration: none;
  color: #11161f;
  background: linear-gradient(135deg, var(--accent-soft), var(--accent));
  padding: 12px 18px;
  border-radius: 999px;
  font-weight: 700;
}

.cta-button:hover { transform: translateY(-1px); }

.source-item,
.coverage-item {
  padding: 16px;
  border-radius: 22px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.05);
  display: grid;
  gap: 10px;
}

.source-top {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: start;
}

.source-name,
.coverage-title {
  font-size: 1rem;
  font-weight: 700;
}

.source-meta,
.coverage-meta,
.detail-meta,
.detail-subhead {
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.5;
}

.empty-state {
  padding: 32px;
  border-radius: 24px;
  border: 1px dashed rgba(255, 255, 255, 0.12);
  text-align: center;
}

.hidden { display: none !important; }

.detail-overlay {
  position: fixed;
  inset: 0;
  z-index: 10;
}

.detail-backdrop {
  position: absolute;
  inset: 0;
  background: rgba(5, 10, 18, 0.7);
  backdrop-filter: blur(10px);
}

.detail-sheet {
  position: relative;
  width: min(1100px, calc(100% - 24px));
  max-height: calc(100vh - 24px);
  margin: 12px auto;
  overflow: auto;
  padding: 24px;
  background: var(--panel-strong);
}

.detail-head {
  display: grid;
  grid-template-columns: 220px 1fr;
  gap: 24px;
}

.detail-poster {
  width: 100%;
  aspect-ratio: 3 / 4;
  object-fit: cover;
  border-radius: 24px;
  background: rgba(255, 255, 255, 0.04);
}

.detail-actions {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: start;
  margin-bottom: 18px;
}

.detail-groups {
  margin-top: 24px;
  display: grid;
  gap: 20px;
}

.session-group {
  border: 1px solid var(--line);
  border-radius: 22px;
  padding: 18px;
  background: rgba(255, 255, 255, 0.02);
}

.session-grid {
  display: grid;
  gap: 12px;
}

.session-item {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  align-items: center;
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.03);
}

.session-left {
  display: grid;
  gap: 4px;
}

.session-time {
  font-size: 1.1rem;
  font-weight: 700;
}

@media (max-width: 1100px) {
  .hero,
  .content-grid,
  .detail-head {
    grid-template-columns: 1fr;
  }

  .side-panel {
    display: grid;
    gap: 22px;
  }
}

@media (max-width: 760px) {
  .shell { width: min(100% - 20px, 100%); padding-top: 16px; }
  .hero-copy,
  .hero-card,
  .toolbar,
  .feed-panel,
  .side-card,
  .detail-sheet { border-radius: 22px; }
  .hero-copy,
  .hero-card,
  .feed-panel,
  .side-card,
  .detail-sheet { padding: 18px; }
  .showtime-card { grid-template-columns: 92px 1fr; gap: 14px; }
  .showtime-headline,
  .showtime-footer,
  .source-top,
  .panel-head,
  .detail-actions,
  .session-item { flex-direction: column; align-items: stretch; }
  .search-wrap input,
  .select-wrap select { min-width: 0; width: 100%; }
}

body.modal-open {
  overflow: hidden;
}

.ghost-button,
.cta-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
}

.purchase-overlay {
  position: fixed;
  inset: 0;
  z-index: 20;
}

.purchase-sheet {
  position: relative;
  width: min(1240px, calc(100% - 24px));
  max-height: calc(100vh - 24px);
  margin: 12px auto;
  overflow: auto;
  padding: 24px;
  background: var(--panel-strong);
  border: 1px solid var(--line);
  border-radius: 28px;
  box-shadow: var(--shadow);
  backdrop-filter: blur(14px);
}

.purchase-head {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 16px;
}

.purchase-meta,
.purchase-note {
  color: var(--muted);
}

.purchase-meta {
  margin: 10px 0 0;
}

.purchase-note {
  margin: 16px 0 0;
  line-height: 1.5;
}

.purchase-status {
  margin-top: 14px;
  padding: 12px 14px;
  border-radius: 16px;
  border: 1px solid var(--line);
  font-size: 0.95rem;
  line-height: 1.5;
}

.purchase-status.is-loading {
  color: var(--accent-soft);
  background: rgba(255, 179, 107, 0.08);
}

.purchase-status.is-ready {
  color: var(--muted);
  background: rgba(255, 255, 255, 0.04);
}

.purchase-status.is-error {
  color: var(--warn);
  background: rgba(255, 210, 122, 0.1);
  border-color: rgba(255, 210, 122, 0.22);
}

.purchase-frame-wrap {
  position: relative;
  margin-top: 18px;
  border-radius: 24px;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(0, 0, 0, 0.28);
  min-height: 16rem;
}

.purchase-frame-state {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 24px;
  text-align: center;
  color: var(--text);
  background: linear-gradient(180deg, rgba(7, 17, 31, 0.68), rgba(12, 27, 46, 0.78));
  transition: opacity 180ms ease;
}

.purchase-frame-wrap.is-ready .purchase-frame-state {
  opacity: 0;
  pointer-events: none;
}

.purchase-frame-wrap.is-error .purchase-frame-state {
  color: var(--warn);
}

.purchase-frame {
  width: 100%;
  height: min(78vh, 860px);
  border: 0;
  display: block;
  background: #fff;
}

.purchase-frame-wrap.is-loading .purchase-frame,
.purchase-frame-wrap.is-error .purchase-frame {
  opacity: 0.22;
}

.purchase-frame-wrap.is-ready .purchase-frame {
  opacity: 1;
}

.purchase-actions {
  margin-top: 16px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

@media (max-width: 760px) {
  .purchase-sheet {
    padding: 18px;
    border-radius: 22px;
  }

  .purchase-head,
  .purchase-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .purchase-frame {
    height: 72vh;
  }
}


.hero {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.88fr);
  gap: 24px;
  align-items: stretch;
}

.hero-copy-wide {
  padding: 38px 40px;
}

.hero-copy-wide h1 {
  max-width: 12ch;
}

.hero-art {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100%;
  padding: 22px;
  overflow: hidden;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.05), rgba(11, 23, 40, 0.96));
}

.hero-art-image {
  display: block;
  width: min(100%, 420px);
  height: auto;
  object-fit: contain;
  filter: drop-shadow(0 18px 36px rgba(0, 0, 0, 0.28));
}

.toolbar-group-wide {
  width: 100%;
}

.toolbar-group-wide .chip-row {
  width: 100%;
}

.search-wrap {
  flex: 1 1 26rem;
}

.select-wrap-styled {
  min-width: 18rem;
}

.sort-dropdown {
  position: relative;
}

.sort-trigger {
  position: relative;
  width: 100%;
  min-width: 16rem;
  padding: 13px 46px 13px 16px;
  border-radius: 18px;
  border: 1px solid rgba(255, 179, 107, 0.26);
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.04), rgba(255, 255, 255, 0.02));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.04);
  color: var(--text);
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: border-color 180ms ease, box-shadow 180ms ease, transform 180ms ease, background 180ms ease;
}

.sort-trigger::after {
  content: "";
  position: absolute;
  right: 16px;
  top: 50%;
  width: 10px;
  height: 10px;
  border-right: 2px solid var(--accent-soft);
  border-bottom: 2px solid var(--accent-soft);
  transform: translateY(-65%) rotate(45deg);
  transition: transform 180ms ease;
  pointer-events: none;
}

.sort-dropdown.open .sort-trigger {
  border-color: rgba(255, 179, 107, 0.5);
  box-shadow: 0 0 0 3px rgba(255, 122, 69, 0.12);
  background: linear-gradient(180deg, rgba(255, 122, 69, 0.08), rgba(255, 255, 255, 0.03));
}

.sort-dropdown.open .sort-trigger::after {
  transform: translateY(-20%) rotate(225deg);
}

.sort-trigger:hover {
  border-color: rgba(255, 179, 107, 0.42);
}

.sort-trigger:focus-visible {
  outline: none;
  border-color: rgba(255, 179, 107, 0.5);
  box-shadow: 0 0 0 3px rgba(255, 122, 69, 0.12);
}

.sort-menu {
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  right: 0;
  z-index: 5;
  display: grid;
  gap: 6px;
  padding: 10px;
  border-radius: 22px;
  border: 1px solid rgba(255, 179, 107, 0.2);
  background: linear-gradient(180deg, rgba(11, 23, 40, 0.98), rgba(7, 17, 31, 0.98));
  box-shadow: 0 24px 50px rgba(0, 0, 0, 0.38);
  backdrop-filter: blur(16px);
}

.sort-option {
  width: 100%;
  padding: 12px 14px;
  border: 1px solid transparent;
  border-radius: 16px;
  background: transparent;
  color: var(--text);
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: background 180ms ease, border-color 180ms ease, color 180ms ease, transform 180ms ease;
}

.sort-option:hover {
  background: rgba(255, 255, 255, 0.05);
  border-color: rgba(255, 255, 255, 0.06);
}

.sort-option.active {
  background: rgba(255, 122, 69, 0.14);
  border-color: rgba(255, 179, 107, 0.28);
  color: var(--accent-soft);
}

.sort-option:focus-visible {
  outline: none;
  border-color: rgba(255, 179, 107, 0.5);
  box-shadow: 0 0 0 3px rgba(255, 122, 69, 0.12);
}

.content-grid-single {
  margin-top: 22px;
  display: block;
}

.content-grid-single .feed-panel {
  width: 100%;
}

@media (max-width: 760px) {
  .hero {
    grid-template-columns: 1fr;
  }

  .hero-copy-wide {
    padding: 24px 20px;
  }

  .hero-art {
    padding: 16px;
  }

  .hero-art-image {
    width: min(100%, 320px);
  }

  .select-wrap-styled,
  .search-wrap {
    min-width: 0;
    width: 100%;
  }

  .toolbar-status {
    width: 100%;
    margin-left: 0;
    white-space: normal;
  }

  .sort-trigger {
    min-width: 0;
  }

  .sort-menu {
    position: static;
    margin-top: 10px;
  }
}



