* {
  box-sizing: border-box;
}

:root {
  --accent: #dd8808;
  --accent-dark: #a86005;
  --bg: #111116;
  --panel: #1d1d1d;
  --panel-soft: #242424;
  --line: #303030;
  --text: #ffffff;
  --muted: #b9b9b9;
  --dim: #8f8f8f;
}

html {
  background: var(--bg);
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: Arial, Helvetica, sans-serif;
  line-height: 1.45;
}

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

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

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

.sr-only {
  clip: rect(0, 0, 0, 0);
  border: 0;
  height: 1px;
  margin: -1px;
  overflow: hidden;
  padding: 0;
  position: absolute;
  white-space: nowrap;
  width: 1px;
}

.site-wrap {
  width: min(1250px, calc(100% - 32px));
  margin: 0 auto;
}

.site-header {
  background: #151515;
  border-bottom: 1px solid #292929;
}

.header-main {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 22px;
  min-height: 78px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  color: #fff;
  font-size: 28px;
  font-weight: 800;
  line-height: 1;
}

.brand img {
  width: 46px;
  height: 46px;
  border-radius: 6px;
}

.search-form {
  display: flex;
  width: min(480px, 100%);
  background: #0d0d0f;
  border: 1px solid #333;
  border-radius: 4px;
  overflow: hidden;
}

.search-form input {
  flex: 1;
  min-width: 0;
  background: transparent;
  border: 0;
  color: #fff;
  font-size: 14px;
  outline: 0;
  padding: 12px 14px;
}

.search-form button,
.button {
  background: var(--accent);
  border: 0;
  border-radius: 4px;
  color: #fff;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: 700;
  min-height: 38px;
  padding: 0 16px;
}

.search-form button {
  border-radius: 0;
}

.button:hover,
.search-form button:hover {
  background: var(--accent-dark);
  color: #fff;
}

.main-nav {
  background: var(--accent);
}

.main-nav .site-wrap {
  display: flex;
  align-items: center;
  gap: 4px;
  min-height: 46px;
  overflow-x: auto;
}

.main-nav a {
  color: #fff;
  flex: 0 0 auto;
  font-size: 14px;
  font-weight: 700;
  padding: 14px 16px;
}

.main-nav a:hover,
.main-nav a.active {
  background: rgba(0, 0, 0, .18);
  color: #fff;
}

.layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 330px;
  gap: 22px;
  padding: 22px 0 30px;
}

.layout.full-layout {
  grid-template-columns: 1fr;
}

.main-column,
.side-column {
  min-width: 0;
}

.bixbox {
  background: var(--panel);
  border: 1px solid #282828;
  border-radius: 4px;
  margin-bottom: 22px;
  overflow: hidden;
}

.home-hero {
  align-items: center;
  background: linear-gradient(135deg, #202020 0%, #191919 58%, #251900 100%);
  border: 1px solid #313131;
  border-radius: 4px;
  display: grid;
  gap: 18px;
  grid-template-columns: minmax(0, 1fr) auto;
  margin-bottom: 22px;
  padding: 24px;
}

.home-hero .eyebrow {
  color: var(--accent);
  display: block;
  font-size: 13px;
  font-weight: 700;
  letter-spacing: 0;
  margin-bottom: 8px;
}

.home-hero h1 {
  color: #fff;
  font-size: 34px;
  line-height: 1.12;
  margin: 0 0 10px;
}

.home-hero p {
  color: #d4d4d4;
  line-height: 1.65;
  margin: 0;
  max-width: 760px;
}

.home-hero-stats {
  display: grid;
  gap: 10px;
  min-width: 190px;
}

.home-hero-stats span {
  background: rgba(255, 255, 255, .07);
  border: 1px solid rgba(255, 255, 255, .09);
  border-radius: 4px;
  color: #d9d9d9;
  padding: 10px 12px;
}

.home-hero-stats strong {
  color: #fff;
  display: block;
  font-size: 22px;
  line-height: 1.05;
}

.box-head {
  align-items: center;
  background: var(--accent);
  color: #fff;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  min-height: 46px;
  padding: 0 16px;
}

.box-head.dark {
  background: #202020;
  border-bottom: 1px solid var(--line);
}

.box-head h1,
.box-head h2,
.box-head h3 {
  font-size: 20px;
  line-height: 1.2;
  margin: 0;
}

.box-body {
  padding: 18px;
}

.page-note {
  color: var(--muted);
  margin: 0 0 16px;
}

.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 24px 18px;
  align-items: start;
}

.poster-card {
  color: #fff;
  display: block;
  min-width: 0;
  overflow: hidden;
}

.poster-box {
  aspect-ratio: 7 / 10;
  background: #101010;
  border-radius: 2px;
  display: block;
  overflow: hidden;
  position: relative;
  width: 100%;
}

.poster-box img {
  height: 100%;
  object-fit: cover;
  width: 100%;
}

.poster-box:after {
  background: linear-gradient(to top, rgba(0, 0, 0, .78), rgba(0, 0, 0, .05) 58%);
  content: "";
  inset: 0;
  position: absolute;
}

.poster-card:hover .poster-box img {
  filter: brightness(.72);
}

.badge,
.ep-label,
.lang-label {
  border-radius: 4px;
  color: #fff;
  font-size: 12px;
  font-weight: 700;
  line-height: 1;
  padding: 6px 7px;
  position: absolute;
  z-index: 2;
}

.badge {
  background: #0d6bdc;
  right: 8px;
  top: 8px;
}

.ep-label {
  bottom: 8px;
  left: 8px;
}

.lang-label {
  background: #f0a000;
  bottom: 8px;
  right: 8px;
}

.lang-label.dub {
  background: #e52622;
}

.poster-title {
  color: #fff;
  display: -webkit-box;
  font-size: 15px;
  line-height: 1.25;
  margin: 9px 0 0;
  min-height: 38px;
  overflow: hidden;
  text-align: center;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 2;
  word-break: break-word;
}

.detail-hero {
  display: grid;
  grid-template-columns: 210px minmax(0, 1fr);
  gap: 22px;
}

.detail-hero .poster-box {
  aspect-ratio: 2 / 3;
}

.detail-title {
  font-size: 30px;
  line-height: 1.15;
  margin: 0 0 10px;
}

.meta-list {
  display: grid;
  gap: 8px;
  margin: 15px 0;
}

.meta-list div {
  color: var(--muted);
}

.meta-list strong {
  color: #fff;
}

.tag-row {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin: 14px 0;
}

.tag-row a,
.tag-row span {
  background: #303030;
  border-radius: 4px;
  color: #fff;
  font-size: 13px;
  padding: 7px 10px;
}

.tag-row a:hover {
  background: var(--accent);
  color: #fff;
}

.player {
  background: #000;
  min-height: 420px;
  position: relative;
}

.player-backdrop {
  filter: brightness(.58);
  height: 100%;
  inset: 0;
  object-fit: cover;
  position: absolute;
  width: 100%;
}

.player-center {
  align-items: center;
  display: flex;
  flex-direction: column;
  gap: 14px;
  inset: 0;
  justify-content: center;
  padding: 22px;
  position: absolute;
  text-align: center;
  z-index: 2;
}

.play-ring {
  align-items: center;
  background: rgba(221, 136, 8, .95);
  border-radius: 50%;
  display: flex;
  height: 74px;
  justify-content: center;
  width: 74px;
}

.play-ring:before {
  border-bottom: 15px solid transparent;
  border-left: 23px solid #fff;
  border-top: 15px solid transparent;
  content: "";
  margin-left: 5px;
}

.player-title {
  font-size: 28px;
  font-weight: 800;
  line-height: 1.18;
  margin: 0;
}

.watch-heading {
  background: var(--panel);
  border: 1px solid #292929;
  border-radius: 4px;
  margin-bottom: 22px;
  padding: 18px 22px;
}

.watch-heading h1 {
  color: #fff;
  font-size: 25px;
  line-height: 1.25;
  margin: 0 0 8px;
}

.watch-meta {
  align-items: center;
  color: var(--muted);
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  font-size: 15px;
}

.watch-sub {
  background: #ffb000;
  border-radius: 4px;
  color: #000;
  font-size: 12px;
  font-weight: 700;
  padding: 4px 7px;
}

.watch-series-link {
  color: #fff;
  font-weight: 700;
}

.episode-nav {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 10px;
  margin: 14px 0 22px;
}

.episode-nav a {
  background: #1c1c1c;
  border-radius: 4px;
  color: #fff;
  display: block;
  font-weight: 700;
  padding: 16px;
  text-align: center;
}

.episode-nav a:nth-child(2) {
  background: #ffd982;
  color: #fff;
}

.watch-copy {
  background: var(--panel);
  border: 1px solid #292929;
  border-radius: 4px;
  color: #e9e9e9;
  font-size: 16px;
  line-height: 1.7;
  margin-bottom: 28px;
  padding: 20px 22px;
}

.watch-copy strong {
  color: #fff;
}

.series-info {
  align-items: start;
  display: grid;
  gap: 22px;
  grid-template-columns: 225px minmax(0, 1fr) 160px;
}

.series-poster {
  background: #101010;
  aspect-ratio: 2 / 3;
  overflow: hidden;
}

.series-poster img {
  height: 100%;
  object-fit: cover;
  width: 100%;
}

.series-copy h2 {
  color: #fff;
  font-size: 24px;
  margin: 0 0 8px;
}

.series-copy p {
  color: var(--muted);
  font-size: 16px;
  margin: 0 0 15px;
}

.series-facts {
  display: grid;
  gap: 10px 28px;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  margin: 18px 0;
}

.series-facts div {
  color: var(--muted);
  font-size: 15px;
  font-weight: 700;
}

.series-facts strong {
  color: #fff;
}

.series-facts div:before {
  background: #ffd982;
  border-radius: 3px;
  content: "";
  display: inline-block;
  height: 10px;
  margin-right: 8px;
  width: 10px;
}

.rating-box {
  background: #101010;
  border-radius: 6px;
  color: #fff;
  font-weight: 700;
  padding: 14px;
  text-align: center;
}

.rating-stars {
  color: #777;
  display: block;
  font-size: 22px;
  letter-spacing: 0;
  margin-top: 4px;
}

.hide-bar {
  background: #333;
  border: 1px solid #4b4b4b;
  color: #bdbdbd;
  margin-top: 14px;
  padding: 5px;
  text-align: center;
}

.watch-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  padding: 14px 18px 18px;
}

.episode-list {
  display: grid;
  gap: 8px;
}

.episode-row {
  align-items: center;
  background: #252525;
  border: 1px solid #333;
  border-radius: 4px;
  color: #fff;
  display: flex;
  gap: 12px;
  justify-content: space-between;
  padding: 11px 12px;
}

.episode-row:hover,
.episode-row.active {
  background: var(--accent);
  color: #fff;
}

.rank-list,
.link-list,
.schedule-list {
  display: grid;
  gap: 0;
}

.rank-item {
  align-items: center;
  border-bottom: 1px solid #303030;
  display: grid;
  grid-template-columns: 34px 62px minmax(0, 1fr);
  gap: 12px;
  padding: 12px 0;
}

.rank-item:first-child {
  padding-top: 0;
}

.rank-item:last-child {
  border-bottom: 0;
  padding-bottom: 0;
}

.rank-no {
  border: 1px solid #555;
  border-radius: 4px;
  color: var(--muted);
  padding: 5px 0;
  text-align: center;
}

.rank-item img {
  aspect-ratio: 2 / 3;
  object-fit: cover;
  width: 62px;
}

.rank-title {
  color: #fff;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.25;
  margin: 0 0 5px;
}

.rank-meta {
  color: var(--muted);
  font-size: 12px;
}

.link-list a,
.schedule-row {
  border-bottom: 1px solid #303030;
  color: #fff;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  padding: 11px 0;
}

.link-list a:last-child,
.schedule-row:last-child {
  border-bottom: 0;
}

.schedule-row span {
  color: var(--muted);
}

.az-strip {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-bottom: 18px;
}

.az-strip a {
  background: #2d2d2d;
  border-radius: 4px;
  color: #fff;
  font-weight: 700;
  min-width: 34px;
  padding: 8px 10px;
  text-align: center;
}

.az-strip a:hover {
  background: var(--accent);
}

.article-body {
  color: var(--muted);
  font-size: 15px;
}

.article-body h2,
.article-body h3 {
  color: #fff;
  margin: 20px 0 8px;
}

.article-body p {
  margin: 0 0 12px;
}

.seo-copy {
  color: #c9c9c9;
  font-size: 16px;
  line-height: 1.72;
  max-width: 980px;
}

.seo-copy p:last-child {
  margin-bottom: 0;
}

.footer {
  background: #0d0d0f;
  border-top: 1px solid #292929;
  color: var(--dim);
  font-size: 13px;
  padding: 26px 0;
}

.footer .site-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  justify-content: space-between;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
}

.empty-state {
  background: #252525;
  border: 1px dashed #444;
  border-radius: 4px;
  color: var(--muted);
  padding: 18px;
}

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

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

  .side-column .bixbox {
    margin-bottom: 0;
  }
}

@media (max-width: 720px) {
  .site-wrap {
    width: min(100% - 20px, 1250px);
  }

  .header-main {
    align-items: stretch;
    flex-direction: column;
    padding: 14px 0;
  }

  .brand {
    font-size: 24px;
  }

  .home-hero {
    grid-template-columns: 1fr;
    padding: 18px;
  }

  .home-hero h1 {
    font-size: 28px;
  }

  .home-hero-stats {
    min-width: 0;
  }

  .detail-hero {
    grid-template-columns: 120px minmax(0, 1fr);
    gap: 14px;
  }

  .detail-title,
  .player-title {
    font-size: 22px;
  }

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

  .side-column {
    grid-template-columns: 1fr;
  }

  .player {
    min-height: 270px;
  }

  .episode-nav,
  .series-info,
  .series-facts {
    grid-template-columns: 1fr;
  }

  .watch-heading h1 {
    font-size: 21px;
  }
}
