:root {
  --bg: #070707;
  --panel: #0e0e0e;
  --panel-2: #161616;
  --accent: #ffffff;
  --accent-soft: #d9d9d9;
  --accent-deep: #ffffff;
  --text: #f2f2f2;
  --muted: #838383;
  --line: rgba(255, 255, 255, .07);
  --line-strong: rgba(255, 255, 255, .18);
  --radius: 12px;
}

* { box-sizing: border-box; }

html, body { margin: 0; padding: 0; }

body {
  background: var(--bg);
  color: var(--text);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; }

.site-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 22px 24px;
  border-bottom: 1px solid var(--line);
}

.brand {
  text-decoration: none;
  font-weight: 600;
  letter-spacing: .3px;
  font-size: 1rem;
}

.brand-dot { color: var(--muted); font-weight: 400; }

.brand-sub {
  color: var(--muted);
  font-size: .72rem;
  text-transform: uppercase;
  letter-spacing: 2.5px;
}

main {
  flex: 1;
  width: 100%;
  max-width: 940px;
  margin: 0 auto;
  padding: 48px 24px 64px;
}

.hero { text-align: center; margin-bottom: 44px; }

.hero h1 {
  margin: 0;
  font-size: clamp(1.6rem, 4.5vw, 2.4rem);
  font-weight: 500;
  letter-spacing: 3px;
}

.hero h1::after {
  content: "";
  display: block;
  width: 32px;
  height: 1px;
  margin: 20px auto 0;
  background: var(--line-strong);
}

.hero-sub { color: var(--muted); margin: 18px 0 0; font-size: .95rem; }
.hero-sub b { color: var(--text); font-weight: 600; }

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

.card {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  padding: 18px 16px;
  min-height: 130px;
  background: var(--panel);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  color: var(--text);
  font: inherit;
  text-align: left;
  cursor: pointer;
  transition: border-color .18s ease, background .18s ease;
}

.card:hover {
  border-color: var(--line-strong);
  background: var(--panel-2);
}

.card.movie {
  background: rgba(255, 255, 255, .06);
  border-color: rgba(255, 255, 255, .26);
}

.card .num {
  font-size: 1.6rem;
  font-weight: 500;
  color: var(--text);
  line-height: 1;
  letter-spacing: 1px;
  font-variant-numeric: tabular-nums;
}

.card.movie .num { color: var(--accent); }

.card .name {
  font-size: .9rem;
  font-weight: 500;
}

.badge {
  margin-top: auto;
  font-size: .64rem;
  text-transform: uppercase;
  letter-spacing: 1.2px;
  color: var(--muted);
}

.badge.ok { color: var(--accent-soft); }
.badge.soon { color: var(--muted); opacity: .7; }

#player-view h2 {
  margin: 22px 0 18px;
  font-size: 1.15rem;
  font-weight: 500;
  letter-spacing: 1px;
}

.ghost {
  background: transparent;
  border: 1px solid var(--line-strong);
  color: var(--text);
  padding: 8px 14px;
  border-radius: 999px;
  font: inherit;
  font-size: .88rem;
  cursor: pointer;
  transition: border-color .18s ease, color .18s ease;
}

.ghost:hover:not(:disabled) { border-color: var(--accent); color: var(--accent-deep); }
.ghost:disabled { opacity: .35; cursor: default; }

.player-box {
  background: #050505;
  border: 1px solid var(--line);
  border-radius: var(--radius);
  overflow: hidden;
}

.player-box iframe {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 9;
  border: 0;
  background: #060606;
}

@font-face {
  font-family: "Lucide";
  src: url("assets/Lucide.ttf") format("truetype");
  font-display: block;
}

.player {
  position: relative;
  display: grid;
  grid-template-columns: 100%;
  aspect-ratio: 16 / 9;
  background: #050505;
  container-type: inline-size;

  --u: .078125cqw;
  --osc-accent: #fff;
  --osc-hover: #fafafa;
  --osc-track: #d9d9d9;
}

.player video {
  grid-area: 1 / 1;
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  background: #050505;
  cursor: pointer;
}

.player:fullscreen { aspect-ratio: auto; height: 100%; }
.player:fullscreen video { height: 100%; }

.player[data-playing="true"]:has(.osc--hidden),
.player[data-playing="true"]:has(.osc--hidden) video { cursor: none; }

.player-big {
  position: absolute;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  display: grid;
  place-items: center;
  padding: 0;
  width: calc(88 * var(--u));
  height: calc(88 * var(--u));
  font-size: calc(34 * var(--u));
  border: 0;
  border-radius: 50%;
  background: rgba(255, 255, 255, .92);
  color: #080808;
  cursor: pointer;
  transition: opacity .18s ease, background .18s ease;
}

.player-big .osc-ico { font-size: inherit; }
.player-big:hover { background: #dcdcdc; }
.player[data-playing="true"] .player-big { opacity: 0; pointer-events: none; }

.osc {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  height: calc(145 * var(--u));
  background: linear-gradient(to top,
      rgba(0, 0, 0, .82),
      rgba(0, 0, 0, .45) 45%,
      rgba(0, 0, 0, 0));
  font-family: inherit;
  opacity: 1;
  transition: opacity .2s ease;
  user-select: none;
  -webkit-user-select: none;
}

.osc--hidden { opacity: 0; pointer-events: none; }

.osc-title {
  position: absolute;
  left: calc(25 * var(--u));
  bottom: calc(100 * var(--u));
  max-width: calc(100cqw - 50 * var(--u));
  font-size: calc(24 * var(--u));
  line-height: 1;
  color: #fff;
  white-space: nowrap;
  overflow: hidden;
}

.osc-time {
  position: absolute;
  right: calc(25 * var(--u));
  bottom: calc(99 * var(--u));
  height: calc(18 * var(--u));
  display: flex;
  align-items: center;
  padding: 0;
  border: 0;
  background: none;
  color: #fff;
  font: inherit;
  font-size: calc(18 * var(--u));
  line-height: 1;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  cursor: pointer;
}

.osc-seek {
  position: absolute;
  left: calc(22.5 * var(--u));
  right: calc(22.5 * var(--u));
  bottom: calc(73 * var(--u));
  height: calc(18 * var(--u));
  cursor: pointer;
  touch-action: none;
  outline: none;
}

.osc-seek-track {
  position: absolute;
  left: 0;
  right: 0;
  top: calc(7 * var(--u));
  height: calc(4 * var(--u));
  border-radius: calc(2 * var(--u));
  background: rgba(217, 217, 217, .4);
}

.osc-seek-buffer,
.osc-seek-played,
.osc-seek-hover {
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  width: 0;
  border-radius: calc(2 * var(--u));
}

.osc-seek-buffer,
.osc-seek-hover { background: rgba(217, 217, 217, .4); }
.osc-seek-played { background: var(--osc-accent); }

.osc-seek-tip {
  position: absolute;
  bottom: calc(87 * var(--u));
  transform: translateX(-50%);
  padding: calc(4 * var(--u));
  border-radius: calc(4 * var(--u));
  background: rgba(0, 0, 0, .5);
  color: #fff;
  font-size: calc(18 * var(--u));
  line-height: 1;
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
  pointer-events: none;
}

.osc-seek-tip[hidden],
.osc-tip[hidden] { display: none; }

.osc-btns {
  position: absolute;
  bottom: calc(14 * var(--u));
  display: flex;
  align-items: center;

  gap: calc(7 * var(--u));
}

.osc-btns-left { left: calc(26 * var(--u)); }
.osc-btns-right { right: calc(26 * var(--u)); }

.osc-btn {
  position: relative;
  width: calc(48 * var(--u));
  height: calc(48 * var(--u));
  display: grid;
  place-items: center;
  padding: 0;
  border: 0;
  background: none;
  color: #fff;
  font: inherit;
  font-size: calc(24 * var(--u));
  line-height: 1;
  cursor: pointer;
  outline: none;
}

.osc-btn::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: calc(6 * var(--u));
  background: var(--osc-hover);
  opacity: 0;
  transition: opacity .12s ease;
}

.osc-btn:hover::before,
.osc-btn:focus-visible::before { opacity: .8; }

.osc-ico {
  position: relative;
  font-family: "Lucide";
  font-style: normal;
  line-height: 1;
}

.osc-vol {
  position: relative;
  width: calc(95 * var(--u));
  height: calc(8 * var(--u));

  margin-left: calc(-3 * var(--u));
  display: flex;
  align-items: center;
  cursor: pointer;
  touch-action: none;
  outline: none;
}

.osc-vol-track {
  position: relative;
  width: 100%;
  height: calc(2 * var(--u));
  border-radius: calc(1 * var(--u));
  background: rgba(217, 217, 217, .5);
}

.osc-vol-fill {
  position: absolute;
  left: 0;
  top: 0;
  height: 100%;
  background: var(--osc-accent);
  border-radius: inherit;
}

.osc-menu {
  position: absolute;
  right: calc(20 * var(--u));
  bottom: calc(72 * var(--u));
  min-width: calc(150 * var(--u));
  padding: calc(4 * var(--u));
  border-radius: calc(4 * var(--u));
  background: rgba(0, 0, 0, .5);
  font-size: calc(18 * var(--u));
  line-height: 1;
}

.osc-menu[hidden] { display: none; }

.osc-menu-item {
  display: block;
  width: 100%;
  padding: calc(8 * var(--u)) calc(10 * var(--u));
  border: 0;
  border-radius: calc(4 * var(--u));
  background: none;
  color: #fff;
  font: inherit;
  text-align: left;
  white-space: nowrap;
  cursor: pointer;
}

.osc-menu-item:hover,
.osc-menu-item:focus-visible { background: var(--osc-hover); color: #000; outline: none; }

.osc-menu-item[aria-current="true"] { font-weight: 600; }
.osc-menu-item[aria-current="true"]::before { content: "• "; }

.osc-tip {
  position: absolute;
  bottom: calc(46 * var(--u));
  transform: translateX(-50%);
  padding: calc(4 * var(--u));
  border-radius: calc(4 * var(--u));
  background: rgba(0, 0, 0, .5);
  color: #fff;
  font-size: calc(18 * var(--u));
  line-height: 1;
  white-space: nowrap;
  pointer-events: none;
}

.player.no-seek .osc-seek { cursor: default; }

.player.no-seek .osc-seek-hover { display: none; }
.player.no-seek .osc-seek-played { background: rgba(255, 255, 255, .45); }

.big-play {
  position: relative;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 16px;
  aspect-ratio: 16 / 9;
  text-decoration: none;
  background-size: cover;
  background-position: center;
  isolation: isolate;
}

.big-play::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(7, 7, 7, .62);
  z-index: -1;
  transition: background .18s ease;
}

.big-play:hover::before { background: rgba(7, 7, 7, .45); }

.play-circle {
  width: 66px;
  height: 66px;
  display: grid;
  place-items: center;
  font-size: 1.4rem;
  padding-left: 4px;
  color: #080808;
  background: var(--accent);
  border-radius: 50%;
  transition: transform .18s ease;
}

.big-play:hover .play-circle { transform: scale(1.06); }

.play-caption {
  font-weight: 500;
  letter-spacing: 1px;
  color: #fff;
  text-shadow: 0 2px 8px rgba(0, 0, 0, .6);
}

.hint {
  margin: 14px 2px 0;
  color: var(--muted);
  font-size: .82rem;
  line-height: 1.6;
}

.hint a { color: var(--accent-deep); }

.placeholder {
  padding: 60px 20px;
  text-align: center;
  background: var(--panel-2);
}

.placeholder p { margin: 0 0 8px; }
.placeholder .muted { color: var(--muted); font-size: .88rem; }

.player-nav {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 22px;
}

.site-footer {
  border-top: 1px solid var(--line);
  padding: 36px 24px 44px;
  text-align: center;
}

.site-footer img {
  height: 54px;
  width: auto;
  border-radius: 10px;
  transition: opacity .18s ease;
}

.site-footer a:hover img { opacity: .85; }

.site-footer p {
  margin: 16px 0 0;
  color: var(--muted);
  font-size: .78rem;
  letter-spacing: .5px;
}

.site-footer p a { text-decoration: none; }
.site-footer p a:hover { color: var(--accent-deep); }

@media (max-width: 480px) {
  main { padding: 32px 16px 48px; }
  .grid { grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); }
  .card { min-height: 112px; padding: 14px 12px; }

  .player-big { width: calc(160 * var(--u)); height: calc(160 * var(--u)); }
}

@container (max-width: 750px) {
  .osc-vol { display: none; }
}

@container (max-width: 500px) {
  .osc-btn[data-act="pip"] { display: none; }
}
