:root {
  --bg: #f5f6f8;
  --card: #ffffff;
  --border: #e0e0e0;
  --text-primary: #1a1a2e;
  --text-secondary: #4a4a68;
  --nav-primary: #7b2ff7;
  --accent: #ffd60a;
  --status-live: #00b894;
  --status-replay: #ff8c42;
  --status-error: #e63946;
  --tag-film: #e63946;
  --tag-drama: #f4a261;
  --tag-variety: #2a9d8f;
  --tag-doc: #264653;
  --tag-sports: #e76f51;
  --live-start: #ff6b35;
  --live-end: #ff2e63;
  --replay-start: #1a2a6c;
  --replay-end: #00c6ff;
  --grad-live: linear-gradient(135deg, #ff6b35, #ff2e63);
  --grad-replay: linear-gradient(135deg, #1a2a6c, #00c6ff);
  --grad-nav: linear-gradient(135deg, #7b2ff7, #1a2a6c);
  --radius: 20px;
  --shadow-card: 0 4px 14px rgba(26, 26, 46, .06);
}

*, *::before, *::after {
  box-sizing: border-box;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text-primary);
  font-family: "PingFang SC", "Microsoft YaHei", "Inter", system-ui, -apple-system, "Segoe UI", sans-serif;
  line-height: 1.6;
}

#main-content {
  outline: none;
  min-height: 60vh;
  scroll-margin-top: 18px;
}

img {
  max-width: 100%;
  display: block;
}

a {
  color: var(--nav-primary);
  text-decoration-thickness: 1px;
  text-underline-offset: 2px;
}

a:hover {
  color: var(--live-end);
}

button, input {
  font: inherit;
}

button {
  cursor: pointer;
}

:focus-visible {
  outline: 3px solid var(--accent);
  outline-offset: 2px;
}

.page-wrap {
  width: min(1180px, calc(100% - 32px));
  margin-inline: auto;
}

.breadcrumb {
  list-style: none;
  margin: 16px 0 8px;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  font-size: .82rem;
  color: var(--text-secondary);
}

.breadcrumb a {
  color: var(--nav-primary);
  font-weight: 700;
  text-decoration: none;
}

.breadcrumb li + li::before {
  content: "/";
  margin-right: 8px;
  color: var(--border);
}

.page-head {
  margin-bottom: 24px;
}

.page-kicker {
  margin: 0 0 4px;
  font-size: .8rem;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--nav-primary);
}

.page-title {
  margin: 0 0 8px;
  font-size: clamp(1.8rem, 4vw, 2.8rem);
  font-weight: 900;
  letter-spacing: -0.01em;
  line-height: 1.1;
}

.page-intro {
  max-width: 70ch;
  margin: 0;
  color: var(--text-secondary);
}

.section {
  margin: 36px 0;
}

.section-head {
  display: flex;
  align-items: baseline;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.section-kicker {
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .1em;
  text-transform: uppercase;
  color: var(--status-replay);
  background: rgba(255, 140, 66, .15);
  padding: .15rem .6rem;
  border-radius: 6px;
}

.section-title {
  margin: 0;
  font-size: clamp(1.2rem, 2.4vw, 1.8rem);
  font-weight: 900;
}

.section-link {
  margin-left: auto;
  font-size: .85rem;
  font-weight: 700;
  color: var(--nav-primary);
  text-decoration: none;
}

.skip-link {
  position: absolute;
  top: -4rem;
  left: 1rem;
  z-index: 300;
  background: var(--accent);
  color: var(--text-primary);
  padding: .6rem 1rem;
  font-weight: 800;
  border-radius: 999px;
  text-decoration: none;
}

.skip-link:focus {
  top: 1rem;
}

.site-header {
  position: relative;
  color: #fff;
  background: var(--text-primary);
}

.read-progress {
  position: fixed;
  top: 0;
  left: 0;
  z-index: 400;
  height: 4px;
  width: 0;
  background: linear-gradient(90deg, var(--accent), var(--live-end), var(--nav-primary));
  pointer-events: none;
}

.header-top {
  background: #101028;
  border-bottom: 3px solid var(--accent);
}

.header-inner {
  width: min(1180px, calc(100% - 32px));
  margin-inline: auto;
}

.header-inner-top {
  display: flex;
  align-items: center;
  gap: 20px;
  min-height: 76px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 12px;
  color: #fff;
  text-decoration: none;
}

.brand:hover {
  color: #fff;
}

.brand:hover .brand-mark {
  transform: rotate(-8deg);
}

.brand-mark {
  display: grid;
  place-items: center;
  width: 44px;
  height: 44px;
  border-radius: 16px 16px 16px 4px;
  background: var(--grad-live);
  color: #fff;
  font-weight: 900;
  font-size: 1.2rem;
  box-shadow: 0 6px 18px rgba(255, 46, 99, .35);
  transition: transform .2s ease;
}

.brand-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
}

.brand-name {
  font-size: 1.25rem;
  font-weight: 900;
  letter-spacing: .02em;
}

.brand-desc {
  font-size: .72rem;
  font-weight: 600;
  letter-spacing: .08em;
  text-transform: uppercase;
  color: #b9c0ff;
}

.nav-toggle {
  display: none;
  align-items: center;
  gap: 10px;
  margin-left: auto;
  background: rgba(255, 255, 255, .08);
  border: 1px solid rgba(255, 255, 255, .35);
  color: #fff;
  border-radius: 14px;
  padding: .6rem .9rem;
  line-height: 1;
}

.nav-toggle-icon {
  display: block;
  width: 20px;
  height: 2px;
  background: #fff;
  box-shadow: 0 -6px 0 #fff, 0 6px 0 #fff;
}

.nav-toggle-text {
  font-size: .8rem;
  font-weight: 700;
}

.header-search {
  display: flex;
  align-items: center;
  flex: 1;
  max-width: 320px;
  margin-left: auto;
  background: #23234f;
  border: 1px solid rgba(255, 255, 255, .14);
  border-radius: 999px;
  padding: 4px;
}

.search-input {
  border: 0;
  background: transparent;
  color: #fff;
  padding: .55rem .9rem;
  width: 100%;
  min-width: 180px;
  outline: none;
  font-size: .9rem;
}

.search-input::placeholder {
  color: #9aa0e0;
}

.search-button {
  background: var(--accent);
  color: #1a1a2e;
  border: 0;
  border-radius: 999px;
  padding: .45rem .85rem;
  font-weight: 800;
  font-size: .8rem;
  white-space: nowrap;
}

.header-nav {
  background: var(--grad-nav);
  color: #fff;
}

.header-nav .header-inner {
  display: flex;
  align-items: center;
  gap: 24px;
  min-height: 52px;
}

.site-nav {
  flex: 1;
}

.nav-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}

.nav-list a {
  display: block;
  color: #fff;
  text-decoration: none;
  padding: .5rem .9rem;
  border-radius: 999px;
  font-weight: 700;
  font-size: .9rem;
}

.nav-list a:hover {
  background: rgba(255, 255, 255, .14);
  color: var(--accent);
}

.nav-list a[aria-current="page"] {
  background: rgba(255, 255, 255, .18);
  color: #fff;
  box-shadow: inset 0 0 0 2px rgba(255, 214, 10, .55);
}

.header-status {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .78rem;
  font-weight: 700;
  padding: .3rem .7rem;
  background: rgba(0, 0, 0, .18);
  border-radius: 999px;
  white-space: nowrap;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--status-live);
  box-shadow: 0 0 0 4px rgba(0, 184, 148, .22);
}

.status-dot.status-live {
  background: var(--status-live);
}

.site-footer {
  margin-top: 72px;
  background: #101028;
  color: #c6c9f2;
}

.footer-bar {
  height: 6px;
  background: linear-gradient(90deg, var(--live-start), var(--replay-start), var(--accent));
}

.footer-inner {
  width: min(1180px, calc(100% - 32px));
  margin-inline: auto;
  display: grid;
  grid-template-columns: 1.6fr 1fr;
  gap: 40px;
  padding: 44px 0 36px;
}

.footer-brand .brand {
  color: #fff;
}

.footer-brand .brand-desc {
  color: #9aa0e0;
}

.footer-links {
  list-style: none;
  margin: 20px 0 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(3, auto);
  gap: 8px 20px;
  justify-content: start;
}

.footer-links a {
  color: #cbd0ff;
  text-decoration: none;
  font-size: .86rem;
  font-weight: 600;
}

.footer-links a:hover {
  color: var(--accent);
}

.footer-meta {
  border-left: 1px solid rgba(255, 255, 255, .15);
  padding-left: 30px;
}

.footer-meta p {
  margin: .5rem 0;
}

.footer-contact {
  color: #eef0ff;
  font-weight: 700;
  font-size: .9rem;
}

.footer-address {
  color: #aeb0e0;
  font-size: .86rem;
}

.footer-icp {
  display: inline-block;
  margin-top: 10px;
  background: rgba(255, 214, 10, .12);
  border: 1px solid rgba(255, 214, 10, .3);
  color: #ffe45c;
  padding: .2rem .6rem;
  border-radius: 6px;
  font-size: .78rem;
  font-weight: 700;
}

.footer-copy {
  color: #8d90c0;
  font-size: .78rem;
  margin-top: 14px;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 18px;
}

.card {
  display: flex;
  flex-direction: column;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  padding-bottom: 16px;
  box-shadow: var(--shadow-card);
  transition: transform .2s ease, box-shadow .2s ease;
}

.card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 24px rgba(26, 26, 46, .1);
}

.card-media {
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
  aspect-ratio: 16 / 9;
  background: var(--grad-replay);
  padding: 10px;
}

.card-media.is-live {
  background: var(--grad-live);
}

.card-media.is-replay {
  background: var(--grad-replay);
}

.card-media.is-dark {
  background: linear-gradient(135deg, #23234f, #12122a);
}

.card-tag {
  position: absolute;
  top: 10px;
  left: 10px;
  background: rgba(255, 255, 255, .92);
  color: var(--text-primary);
  border-radius: 6px;
  padding: .15rem .5rem;
  font-size: .72rem;
  font-weight: 800;
}

.card-status {
  position: absolute;
  right: 10px;
  bottom: 10px;
}

.card-content {
  display: flex;
  flex-direction: column;
  gap: 6px;
  padding: 12px 16px 0;
}

.card-title {
  margin: 0;
  font-size: 1.05rem;
  font-weight: 900;
}

.card-meta {
  margin: 0;
  font-size: .8rem;
  color: var(--text-secondary);
}

.card-action {
  margin-top: 12px;
  padding: 0 16px;
  font-size: .8rem;
  font-weight: 800;
  color: var(--nav-primary);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

.magnet-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 14px;
}

.magnet {
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  min-height: 110px;
  padding: 18px 16px;
  border-radius: var(--radius);
  color: #fff;
  background: var(--nav-primary);
  position: relative;
  overflow: hidden;
  text-decoration: none;
}

.magnet::after {
  content: "";
  position: absolute;
  right: -18px;
  bottom: -18px;
  width: 70px;
  height: 70px;
  border-radius: 50%;
  background: rgba(255, 255, 255, .2);
}

.magnet--live {
  background: var(--grad-live);
}

.magnet--replay {
  background: var(--grad-replay);
}

.magnet--violet {
  background: var(--grad-nav);
}

.magnet-title {
  position: relative;
  z-index: 1;
  font-size: 1rem;
  font-weight: 900;
  line-height: 1.25;
}

.magnet-count {
  position: relative;
  z-index: 1;
  font-size: .76rem;
  font-weight: 700;
  opacity: .92;
}

.item-list {
  display: flex;
  flex-direction: column;
  border-top: 2px solid var(--border);
}

.item-row {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  gap: 12px;
  align-items: center;
  padding: 12px 8px;
  border-bottom: 1px solid var(--border);
  background: var(--card);
  transition: background .15s ease;
}

.item-row:hover {
  background: #fbf5e9;
}

.item-index {
  padding: .25rem 0;
  text-align: center;
  font-size: .85rem;
  font-weight: 900;
  color: var(--nav-primary);
  background: #f0edff;
  border-radius: 10px;
}

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

.item-title {
  margin: 0;
  font-size: .95rem;
  font-weight: 800;
}

.item-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: .1rem 0 0;
  font-size: .78rem;
  color: var(--text-secondary);
}

.item-extra {
  font-size: .8rem;
  font-weight: 800;
  text-align: right;
  color: var(--status-replay);
  white-space: nowrap;
}

.tag-group {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 10px 0;
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: .35rem .8rem;
  font-size: .78rem;
  font-weight: 700;
  color: var(--text-secondary);
  cursor: pointer;
  text-decoration: none;
}

.tag:hover,
.tag[aria-pressed="true"] {
  background: var(--nav-primary);
  color: #fff;
  border-color: var(--nav-primary);
}

.tag--film {
  background: rgba(230, 57, 70, .1);
  color: #a22532;
  border-color: rgba(230, 57, 70, .3);
}

.tag--drama {
  background: rgba(244, 162, 97, .15);
  color: #b2501f;
  border-color: rgba(244, 162, 97, .4);
}

.tag--variety {
  background: rgba(42, 157, 143, .12);
  color: #17746a;
  border-color: rgba(42, 157, 143, .3);
}

.tag--doc {
  background: rgba(38, 70, 83, .12);
  color: #1c3b4a;
  border-color: rgba(38, 70, 83, .3);
}

.tag--sports {
  background: rgba(231, 111, 81, .15);
  color: #b3442b;
  border-color: rgba(231, 111, 81, .35);
}

.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 999px;
  padding: .15rem .55rem;
  font-size: .72rem;
  font-weight: 800;
}

.status-badge::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: currentColor;
}

.status-badge--live {
  color: var(--status-live);
  background: rgba(0, 184, 148, .1);
  border-color: rgba(0, 184, 148, .25);
}

.status-badge--replay {
  color: var(--status-replay);
  background: rgba(255, 140, 66, .12);
  border-color: rgba(255, 140, 66, .3);
}

.status-badge--error {
  color: var(--status-error);
  background: rgba(230, 57, 70, .1);
  border-color: rgba(230, 57, 70, .25);
}

.metric-row {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 6px;
  font-size: .8rem;
  margin: 6px 0;
}

.metric-label {
  color: var(--text-secondary);
  font-weight: 700;
}

.metric-value {
  font-weight: 900;
}

.metric-bar {
  grid-column: 1 / -1;
  height: 6px;
  background: #eceef4;
  border-radius: 999px;
  overflow: hidden;
}

.metric-fill {
  display: block;
  height: 100%;
  width: var(--w, 80%);
  background: linear-gradient(90deg, var(--live-start), var(--live-end));
  border-radius: inherit;
}

.index-rail {
  display: flex;
  gap: 4px;
  overflow-x: auto;
  padding: 6px 2px;
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  margin: 18px 0;
}

.index-rail-link {
  flex: 0 0 auto;
  min-width: 36px;
  text-align: center;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: .35rem .6rem;
  font-size: .78rem;
  font-weight: 800;
  color: var(--text-secondary);
  text-decoration: none;
}

.index-rail-link:hover,
.index-rail-link[aria-current="true"] {
  background: var(--nav-primary);
  color: #fff;
  border-color: var(--nav-primary);
}

.scroller {
  display: flex;
  gap: 14px;
  overflow-x: auto;
  padding: 4px 4px 14px;
  scroll-snap-type: x mandatory;
}

.scroller > * {
  scroll-snap-align: start;
  flex: 0 0 78%;
}

.schedule-grid {
  display: grid;
  grid-template-columns: 88px repeat(6, 1fr);
  min-width: 760px;
  border: 1px solid var(--border);
  border-radius: 18px;
  overflow: hidden;
  background: var(--card);
}

.schedule-grid > * {
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  padding: 10px;
  min-height: 76px;
}

.schedule-grid > :nth-child(6n) {
  border-right: 0;
}

.schedule-head {
  display: flex;
  align-items: center;
  justify-content: center;
  background: #f0edff;
  font-weight: 900;
  font-size: .82rem;
}

.schedule-time {
  background: var(--bg);
  font-weight: 800;
  color: var(--text-secondary);
}

.schedule-cell {
  position: relative;
  font-size: .8rem;
}

.schedule-title {
  margin: 0 0 4px;
  font-weight: 800;
}

.schedule-status {
  font-size: .68rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: .04em;
}

.schedule-status.is-live {
  color: var(--status-live);
}

.schedule-status.is-replay {
  color: var(--status-replay);
}

.schedule-status.is-empty {
  color: var(--text-secondary);
}

.compare-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 18px;
}

.compare-card {
  position: relative;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 18px;
  overflow: hidden;
}

.compare-card::before {
  content: "";
  display: block;
  width: 56px;
  height: 6px;
  background: var(--grad-live);
  border-radius: 999px;
  margin-bottom: 12px;
}

.compare-card--replay::before {
  background: var(--grad-replay);
}

.compare-card--help::before {
  background: var(--grad-nav);
}

.compare-card h3 {
  margin: 0 0 6px;
  font-size: 1rem;
  font-weight: 900;
}

.compare-card p {
  margin: 0;
  font-size: .84rem;
  color: var(--text-secondary);
}

.snapshot {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100px;
  background: linear-gradient(135deg, #e8e9f2, #cfd2e6);
  border: 1px dashed #c2c5d8;
  border-radius: 18px;
  color: #5a5d7a;
  font-size: .8rem;
  font-weight: 700;
}

.snapshot.is-live {
  background: linear-gradient(135deg, rgba(255, 107, 53, .16), rgba(255, 46, 99, .12));
  color: #b13b5e;
  border-color: rgba(255, 46, 99, .3);
}

.snapshot.is-replay {
  background: linear-gradient(135deg, rgba(26, 42, 108, .12), rgba(0, 198, 255, .12));
  color: #1a2a6c;
  border-color: rgba(26, 42, 108, .3);
}

.snapshot.is-dark {
  background: linear-gradient(135deg, #20204f, #141430);
  color: #cbd0ff;
  border-color: #44447c;
}

.zone-live {
  background: var(--grad-live);
  color: #fff;
  border-radius: 24px;
  padding: 24px;
}

.zone-replay {
  background: var(--grad-replay);
  color: #fff;
  border-radius: 24px;
  padding: 24px;
}

.zone-violet {
  background: var(--grad-nav);
  color: #fff;
  border-radius: 24px;
  padding: 24px;
}

.batch-list {
  list-style: none;
  margin: 0;
  padding: 0;
  border-left: 3px solid var(--nav-primary);
}

.batch-item {
  position: relative;
  margin: 0 0 14px 14px;
  padding: 16px 20px;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 16px;
}

.batch-item::before {
  content: "";
  position: absolute;
  left: -9px;
  top: 22px;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--accent);
  border: 3px solid var(--bg);
}

.batch-badge {
  display: inline-block;
  margin-left: 8px;
  background: var(--nav-primary);
  color: #fff;
  font-size: .72rem;
  font-weight: 900;
  padding: .15rem .6rem;
  border-radius: 999px;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--nav-primary);
  color: #fff;
  border: 0;
  border-radius: 14px;
  padding: .65rem 1.1rem;
  font-weight: 800;
  font-size: .85rem;
  text-decoration: none;
}

.btn:hover {
  color: #fff;
  filter: brightness(1.08);
}

.btn-secondary {
  background: var(--card);
  color: var(--nav-primary);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  color: var(--nav-primary);
  filter: none;
  border-color: var(--nav-primary);
}

@media (max-width: 900px) {
  .nav-toggle {
    display: flex;
  }

  .header-inner-top {
    flex-wrap: wrap;
    padding-block: 10px;
  }

  .header-search {
    order: 3;
    flex: 0 0 100%;
    max-width: none;
    margin-left: 0;
  }

  .header-nav .header-inner {
    flex-wrap: wrap;
    gap: 10px;
    padding-block: 8px;
  }

  .site-nav {
    display: none;
    order: 2;
    flex: 0 0 100%;
    width: 100%;
    background: rgba(0, 0, 0, .25);
    border-radius: 16px;
    padding: 4px;
    margin-top: 8px;
  }

  .site-nav[data-open] {
    display: block;
  }

  .nav-list {
    flex-direction: column;
  }

  .header-status {
    order: 1;
    margin-left: auto;
  }

  .footer-inner {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .footer-meta {
    border-left: 0;
    padding-left: 0;
  }
}

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

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

  .item-row {
    grid-template-columns: 36px 1fr;
    gap: 8px;
  }

  .item-extra {
    grid-column: 2;
    text-align: left;
  }

  .footer-links {
    grid-template-columns: repeat(2, 1fr);
  }

  .scroller > * {
    flex-basis: 88%;
  }

  .brand-desc {
    display: none;
  }

  .header-status {
    font-size: .7rem;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *, *::before, *::after {
    animation: none !important;
    transition: none !important;
  }

  .card:hover {
    transform: none;
  }

  .read-progress {
    display: none !important;
  }
}
