:root { color-scheme: light; --bg: #f5f7fa; --sidebar: #dceffa; --panel: #ffffff; --line: #d8dfe6; --ink: #202b35; --muted: #697580; --accent: #137cab; --bad: #b73f52; }
.accessMode > .sidebar, .accessMode > .topbar, .accessMode > .portal, .accessMode > .menuShade { display: none; }
.accessGate { min-height: 100svh; padding: 32px 24px; }
.accessBrand { display: inline-flex; align-items: center; gap: 12px; font-size: 24px; font-weight: 600; }
.accessBrand svg { width: 26px; height: 26px; color: var(--accent); }
.accessBody { width: 100%; max-width: 390px; margin: 64px auto 0; }
.accessBody h1 { font-size: 25px; margin-bottom: 24px; }
.accessTabs { display: flex; gap: 8px; border-bottom: 1px solid var(--line); margin-bottom: 24px; overflow-x: auto; }
.accessTabs button { background: transparent; padding: 10px 12px; color: var(--muted); border-bottom: 2px solid transparent; white-space: nowrap; }
.accessTabs button[aria-selected="true"], .accessTabs button[aria-current] { border-bottom-color: var(--accent); color: var(--ink); }
.accountForm { display: grid; gap: 18px; }
.accountForm label { display: grid; gap: 7px; color: var(--muted); font-size: 13px; min-width: 0; }
.accountForm input, .accountForm select, .accountForm textarea, .adminToolbar input, .adminToolbar select { border: 1px solid #b8c6d1; background: #ffffff; border-radius: 4px; padding: 10px 12px; min-width: 0; width: 100%; color: var(--ink); font: inherit; }
.accountForm textarea { resize: vertical; }
.accountForm .playButton { justify-self: start; }
.accountMessage { min-height: 21px; margin: 14px 0; overflow-wrap: anywhere; color: var(--muted); }
.accountMessage.error, .danger { color: var(--bad); }
.accountEmail { margin: 12px 0 24px; overflow-wrap: anywhere; color: var(--muted); }
.accountActions { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; margin-top: 24px; }
.textButton { background: transparent; padding: 8px 0; text-decoration: underline; text-underline-offset: 4px; }
.planSummary { padding: 20px 0; border-block: 1px solid var(--line); }
.planSummary h2 { font-size: 20px; margin-bottom: 10px; }
.planSummary p { margin-top: 8px; overflow-wrap: anywhere; }
.accountDialog { position: relative; width: min(460px, calc(100% - 32px)); max-height: calc(100svh - 32px); padding: 28px; border: 1px solid #b8c6d1; border-radius: 6px; color: var(--ink); background: var(--bg); overflow-y: auto; }
.accountDialog::backdrop { background: #000a; }
.accountDialog h2 { font-size: 21px; padding-right: 25px; overflow-wrap: anywhere; }
.accountDialog h3 { font-size: 15px; }
.accountDialog > p { margin-block: 10px; overflow-wrap: anywhere; }
.accountDialog .accountForm { margin-top: 24px; padding-top: 20px; border-top: 1px solid var(--line); }
.adminHeading { display: flex; align-items: center; justify-content: space-between; margin-bottom: 18px; }
.adminHeading h1 { font-size: 23px; }
.adminToolbar { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; margin: 12px 0 18px; }
.adminToolbar > input { max-width: 300px; flex: 1; }
.adminToolbar > select { max-width: 440px; flex: 1 1 200px; }
.adminToolbar label { display: flex; align-items: center; gap: 6px; color: var(--muted); }
.adminToolbar label input { width: 72px; padding-inline: 8px; }
.adminToolbar span { color: var(--muted); font-size: 12px; }
.tableScroll { overflow-x: auto; width: 100%; }
.adminTable { width: 100%; border-collapse: collapse; text-align: left; font-size: 13px; }
.adminTable th { padding: 12px 14px; background: #e9edf2; color: var(--muted); font-weight: 500; white-space: nowrap; }
.adminTable td { padding: 12px 14px; border-bottom: 1px solid var(--line); vertical-align: middle; }
.adminTable td:first-child { max-width: 280px; overflow-wrap: anywhere; }
.adminTable td:last-child { white-space: nowrap; }
.good { color: var(--accent); }
.muted { color: var(--muted); }
#adminButton { padding-inline: 12px; gap: 8px; font-size: 12px; }
.planForm { max-width: 600px; }
.formColumns { display: grid; grid-template-columns: 2fr 1fr 1fr; gap: 12px; }
@media (max-width: 760px) {
  .accessGate { padding: 24px 20px; }
  .accessBody { margin-top: 42px; }
  .adminHeading h1 { font-size: 20px; }
  .adminTable { min-width: 630px; }
  .adminWorkspace .accessTabs { gap: 0; }
  .adminWorkspace .accessTabs button { padding-inline: 8px; font-size: 12px; }
  .formColumns { grid-template-columns: 1fr 1fr; }
  .formColumns label:first-child { grid-column: 1 / -1; }
  .accountDialog { padding: 24px 20px; }
}
* { box-sizing: border-box; }
[hidden] { display: none !important; }
body { margin: 0; background: var(--bg); color: var(--ink); font: 14px/1.5 -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, sans-serif; letter-spacing: 0; }
body.modalOpen { overflow: hidden; }
body.menuOpen { overflow: hidden; }
button, input, select, a { font: inherit; color: inherit; letter-spacing: 0; }
button { cursor: pointer; border: 0; }
button:disabled { opacity: .5; cursor: wait; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible { outline: 2px solid var(--accent); outline-offset: 3px; }
a { text-decoration: none; }
h1, h2, h3, p { margin: 0; }
svg { width: 18px; height: 18px; flex-shrink: 0; }
.sidebar { width: 188px; position: fixed; inset: 0 auto 0 0; z-index: 30; background: var(--sidebar); padding: 18px 0; display: flex; flex-direction: column; border-right: 1px solid #bbd5e5; }
.brand { display: flex; align-items: center; gap: 10px; padding: 0 18px; height: 30px; margin-bottom: 30px; font-size: 21px; }
.brandMark { width: 29px; height: 29px; border: 1px solid #6f9db8; border-radius: 50%; display: grid; place-items: center; }
.brandMark svg { width: 17px; height: 17px; }
.navLabel { padding: 0 20px; font-size: 10px; text-transform: uppercase; color: #5f7c8e; margin-bottom: 10px; }
.personalLabel { margin-top: 30px; }
.nav { display: grid; }
.navItem { background: transparent; padding: 11px 20px; display: flex; align-items: center; gap: 11px; text-align: left; color: #354f62; font-size: 13px; min-height: 42px; border-left: 3px solid transparent; }
.navItem svg { width: 16px; height: 16px; }
.navItem:hover { background: #cae5f5; color: white; }
.navItem.active { background: #c1e5fa; border-left-color: var(--accent); color: var(--accent); }
.navItem span { margin-left: auto; color: #49697e; font-size: 11px; }
.sideFoot { margin-top: auto; padding: 20px 23px 2px; display: flex; align-items: center; gap: 8px; color: #638295; font-size: 11px; }
.statusDot { width: 6px; height: 6px; border-radius: 50%; background: #638295; }
.statusDot.ready { background: var(--accent); }
.statusDot.error { background: var(--bad); }
.topbar { margin-left: 188px; height: 64px; background: #c9e8f8; border-bottom: 1px solid #d5dfe7; display: flex; align-items: center; gap: 15px; padding: 0 25px; }
.searchWrap { display: flex; background: #ffffff; width: 520px; max-width: calc(100% - 52px); height: 35px; border: 1px solid #adcfdf; border-radius: 3px; }
.searchWrap input { width: 100%; min-width: 0; padding: 7px 11px; border: 0; background: transparent; font-size: 12px; }
.searchWrap input::placeholder { color: #6a7e8d; }
.searchButton { width: 40px; flex: 0 0 40px; background: transparent; color: #416479; display: grid; place-items: center; }
.searchButton:hover { color: var(--accent); }
.iconButton { width: 36px; height: 36px; display: inline-flex; flex: 0 0 36px; align-items: center; justify-content: center; border-radius: 4px; background: transparent; color: #426478; }
.iconButton:hover { background: #d1e8f5; color: white; }
.accountButton { margin-left: auto; border: 1px solid #83b6d0; border-radius: 50%; width: 31px; height: 31px; flex-basis: 31px; }
.mobileBrand, .menuButton, .menuShade { display: none; }
.portal { margin-left: 188px; padding: 23px 25px 16px; }
.shelf { margin-bottom: 27px; }
.sectionHead { display: flex; align-items: center; gap: 15px; margin-bottom: 13px; min-height: 30px; }
.sectionHead h2 { font-size: 21px; font-weight: 500; }
.sectionHead .shelfActions { display: flex; gap: 4px; margin-left: auto; }
.sectionHead .iconButton { width: 27px; height: 27px; flex-basis: 27px; background: #e9eef3; color: #657987; }
.posterGrid { display: grid; grid-template-columns: repeat(7, minmax(0, 1fr)); gap: 21px 14px; }
.posterRail { display: grid; grid-auto-flow: column; grid-auto-columns: calc((100% - 84px) / 7); gap: 14px; overflow-x: auto; padding: 2px 2px 8px; margin: -2px; scrollbar-width: none; scroll-snap-type: x mandatory; }
.posterRail::-webkit-scrollbar { display: none; }
.movieCard { min-width: 0; position: relative; scroll-snap-align: start; }
.posterButton { padding: 0; display: block; position: relative; width: 100%; aspect-ratio: 2 / 3; background: #e6ebf0; border-radius: 3px; overflow: hidden; }
.posterButton img { width: 100%; height: 100%; display: block; object-fit: cover; transition: opacity .15s; }
.posterFallback { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 13px; padding: 15px; color: #5f7381; }
.posterFallback svg { width: 31px; height: 31px; }
.posterFallback span { font-size: 13px; text-align: center; overflow-wrap: anywhere; }
.posterButton img + .posterFallback, .detailPoster img + .posterFallback { display: none; }
.posterButton.failed img, .detailPoster.failed img { display: none; }
.posterButton.failed .posterFallback, .detailPoster.failed .posterFallback { display: flex; }
.posterButton::after { content: ''; position: absolute; inset: 0; background: #050608; opacity: 0; transition: opacity .15s; }
.posterButton:hover::after, .posterButton:focus-visible::after { opacity: .4; }
.posterPlay { position: absolute; z-index: 2; inset: 0; display: grid; place-items: center; opacity: 0; transition: opacity .15s; }
.posterPlay svg { width: 38px; height: 38px; fill: white; stroke-width: 1.2; }
.posterButton:hover .posterPlay, .posterButton:focus-visible .posterPlay { opacity: 1; }
.cardBookmark { position: absolute; z-index: 3; right: 6px; top: 6px; width: 28px; height: 28px; background: #12141be6; border-radius: 3px; opacity: 0; }
.movieCard:hover .cardBookmark, .movieCard:focus-within .cardBookmark, .cardBookmark.saved { opacity: 1; }
.saved { color: #dcc67a !important; }
.rating { position: absolute; top: 6px; left: 6px; z-index: 2; color: #fff; background: #5d8146ee; border-radius: 2px; padding: 1px 5px; font-size: 10px; line-height: 18px; font-weight: 600; }
.movieTitle { margin-top: 8px; display: block; background: transparent; padding: 0; font-size: 12px; font-weight: 500; text-align: left; width: 100%; line-height: 1.4; }
.movieTitle span { display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 34px; overflow-wrap: anywhere; }
.movieTitle:hover { color: var(--accent); }
.cardMeta { color: #627585; font-size: 10px; margin-top: 3px; display: flex; gap: 6px; min-height: 16px; white-space: nowrap; overflow: hidden; }
.cardMeta span:last-child { overflow: hidden; text-overflow: ellipsis; }
.pageHead { display: flex; align-items: center; gap: 14px; margin-bottom: 18px; }
.pageHead h1 { font-size: 23px; font-weight: 500; overflow-wrap: anywhere; min-width: 0; }
.pageHead span { color: var(--muted); font-size: 12px; white-space: nowrap; }
.filters { display: flex; flex-wrap: wrap; gap: 9px; margin-bottom: 23px; padding-bottom: 17px; border-bottom: 1px solid var(--line); }
.filters select { min-height: 35px; min-width: 145px; background: #e4ebf1; padding: 6px 27px 6px 11px; border: 1px solid #c8d5de; border-radius: 3px; font-size: 12px; }
.notice { border-left: 2px solid #cbbd79; padding: 10px 14px; margin-bottom: 20px; color: #cbbd79; background: #e8edf1; }
.notice.error { color: var(--bad); border-left-color: var(--bad); }
.empty { padding: 85px 15px; color: var(--muted); text-align: center; }
.empty svg { width: 34px; height: 34px; margin-bottom: 12px; }
.empty p { font-size: 14px; }
.loadMore { display: block; margin: 27px auto; padding: 9px 24px; border: 1px solid #c2d2dc; border-radius: 3px; background: #e4edf3; font-size: 12px; }
.loadMore:hover { background: #cbdce8; }
.footer { margin-top: 30px; padding-top: 14px; border-top: 1px solid #d5dfe7; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 10px; font-size: 10px; color: #718594; }
.footer a:hover { color: #4a6578; }
.skeletonPoster { aspect-ratio: 2 / 3; background: #e7edf2; border-radius: 3px; animation: pulse 1.5s infinite alternate; }
.skeletonLine { height: 9px; width: 70%; margin: 12px 0 7px; background: #d5dfe7; }
@keyframes pulse { to { opacity: .5; } }
.movieDialog { position: fixed; width: min(940px, calc(100% - 48px)); max-height: calc(100dvh - 48px); padding: 32px; border: 1px solid #bcd0de; border-radius: 6px; background: #ffffff; color: var(--ink); overflow-y: auto; }
.movieDialog::backdrop { background: #08090de0; }
.dialogClose { position: absolute; right: 10px; top: 10px; z-index: 5; }
.movieDetail { display: grid; grid-template-columns: 185px minmax(0, 1fr); gap: 28px; }
.detailPoster { position: relative; aspect-ratio: 2 / 3; background: #e7edf2; border-radius: 3px; overflow: hidden; align-self: start; }
.detailPoster img { width: 100%; height: 100%; object-fit: cover; }
.detailInfo { padding-right: 15px; }
.detailInfo h2 { font-size: 25px; font-weight: 500; line-height: 1.3; overflow-wrap: anywhere; margin-bottom: 6px; }
.originalTitle { font-size: 13px; color: #647b8b; margin-bottom: 14px; }
.movieFacts { display: flex; flex-wrap: wrap; gap: 6px 13px; font-size: 12px; color: #426276; margin-bottom: 18px; }
.movieFacts .factRating { color: #c0e8fa; }
.description { font-size: 13px; line-height: 1.75; color: #506b7d; max-height: 160px; overflow-y: auto; margin-bottom: 22px; overflow-wrap: anywhere; }
.detailActions { display: flex; gap: 12px; align-items: center; }
.playButton { display: inline-flex; align-items: center; justify-content: center; gap: 9px; height: 37px; padding: 0 23px; background: var(--accent); color: #ffffff; border-radius: 3px; font-size: 13px; }
.playButton:hover { background: #10658c; }
.playButton svg { width: 15px; height: 15px; fill: currentColor; }
.playerSection { margin-top: 25px; }
.playerStage { position: relative; width: 100%; aspect-ratio: 16 / 9; max-height: max(160px, calc(100dvh - 210px)); background: #08090b; }
.playerSection video { display: block; width: 100%; height: 100%; object-fit: contain; background: #08090b; }
.playerStatus { position: absolute; inset: 0; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 12px; background: #08090bbf; pointer-events: none; padding: 25px; text-align: center; font-size: 13px; color: #d4d8df; }
.playerStatus svg { display: none; width: 26px; height: 26px; color: var(--accent); }
.playerStatus.loading svg { display: block; animation: player-spin 1.2s linear infinite; }
@keyframes player-spin { to { transform: rotate(360deg); } }
.playerMeta { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-top: 9px; font-size: 12px; color: #526f82; }
.playerMeta span { flex: 1; min-width: 160px; }
.playerMeta select { background: #ffffff; border: 1px solid #b1c8d7; border-radius: 3px; max-width: 200px; padding: 6px; }
.movieDialog.playing .movieDetail { grid-template-columns: minmax(0, 1fr); }
.movieDialog.playing { width: min(1120px, calc(100% - 40px)); padding: 20px; }
.movieDialog.playing .detailPoster, .movieDialog.playing .description, .movieDialog.playing .originalTitle, .movieDialog.playing .detailActions { display: none; }
.movieDialog.playing .movieFacts { margin: 6px 0 0; font-size: 11px; }
.movieDialog.playing .detailInfo h2 { font-size: 17px; padding-right: 24px; margin: 0; }
.movieDialog.playing .playerSection { margin-top: 14px; }
.playbackControls { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 16px; padding-top: 12px; border-top: 1px solid var(--line); }
.movieDialog.playing .playbackControls { margin-top: 0; padding-top: 10px; border-top: none; }
.playbackField { display: flex; align-items: center; gap: 7px; min-width: 0; flex: 0 1 120px; }
.playbackField span { color: var(--muted); font-size: 11px; }
.playbackField select, #videoFile { width: 100%; min-width: 0; height: 34px; border: 1px solid #d6e7f1; border-radius: 3px; background: #e7edf2; padding: 5px 25px 5px 9px; font-size: 12px; text-overflow: ellipsis; }
#videoFile { width: auto; max-width: 180px; }
#reloadPlayer { margin-left: auto; }
.episodeField { flex: 1 1 220px; }
.audioField { flex: 1 1 190px; max-width: 330px; }
.audioField svg { width: 16px; height: 16px; color: var(--muted); }
.episodeSteps { display: flex; gap: 2px; height: 36px; }
@media (max-width: 480px) { .playbackField { flex-basis: 105px; } .episodeField { flex: 1 1 150px; } .audioField { flex: 1 1 150px; max-width: none; } .episodeSteps { margin-left: auto; } .movieDialog.playing { width: calc(100% - 20px); padding: 18px 12px 12px; } .playerStage { max-height: max(160px, calc(100dvh - 290px)); } }
@media (min-width: 1500px) { .posterGrid { grid-template-columns: repeat(9, minmax(0, 1fr)); } .posterRail { grid-auto-columns: calc((100% - 112px) / 9); } }
@media (max-width: 1100px) { .sidebar { width: 165px; } .portal, .topbar { margin-left: 165px; } .brand { font-size: 19px; } .navItem { padding-left: 15px; } .posterGrid { grid-template-columns: repeat(5, minmax(0, 1fr)); } .posterRail { grid-auto-columns: calc((100% - 56px) / 5); } }
@media (max-width: 760px) {
  .sidebar { transform: translateX(-100%); transition: transform .15s; width: 210px; padding-top: 22px; pointer-events: none; }
  .sidebar.open { transform: none; pointer-events: auto; }
  .menuShade { display: block; position: fixed; inset: 0; background: #06070ca6; z-index: 25; }
  .topbar { margin-left: 0; height: 58px; padding: 0 15px; gap: 10px; }
  .menuButton { display: inline-flex; flex-basis: 26px; width: 26px; }
  .mobileBrand { display: block; font-weight: 700; font-size: 17px; }
  .searchWrap { margin-left: auto; width: 330px; max-width: 100%; min-width: 0; }
  .accountButton { display: inline-flex; margin-left: auto; }
  .portal { margin-left: 0; padding: 20px 16px 14px; }
  .posterGrid { grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 20px 12px; }
  .posterRail { grid-auto-columns: calc((100% - 36px) / 4); gap: 12px; }
  .sectionHead h2 { font-size: 19px; }
  .cardBookmark { opacity: 1; }
  .filters select { min-width: 0; flex: 1 1 120px; }
  .movieDialog { padding: 30px 21px 20px; width: calc(100% - 28px); max-height: calc(100dvh - 28px); }
  .movieDetail { grid-template-columns: 125px minmax(0, 1fr); gap: 19px; }
  .detailInfo { padding-right: 0; }
  .detailInfo h2 { font-size: 20px; padding-right: 10px; }
  .description { font-size: 12px; max-height: 150px; }
}
@media (max-width: 480px) {
  .topbar { flex-wrap: wrap; height: auto; min-height: 100px; padding: 12px 16px; gap: 9px; }
  .searchWrap { order: 3; width: 100%; height: 33px; }
  .mobileBrand { margin-left: 3px; }
  .portal { padding-top: 17px; }
  .posterGrid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 18px 10px; }
  .posterRail { grid-auto-columns: calc((100% - 26px) / 3.15); gap: 10px; }
  .movieTitle { font-size: 11px; }
  .sectionHead h2 { font-size: 18px; }
  .sectionHead { gap: 8px; }
  .sectionHead .shelfActions { gap: 3px; }
  .cardMeta { font-size: 9px; }
  .filters select { flex-basis: 100px; }
  .pageHead h1 { font-size: 21px; }
  .movieDetail { grid-template-columns: 95px minmax(0, 1fr); gap: 14px; }
  .detailInfo h2 { font-size: 18px; }
  .originalTitle { font-size: 11px; }
  .movieFacts { font-size: 11px; gap: 4px 8px; margin-bottom: 12px; }
  .description { font-size: 12px; max-height: 190px; }
  .playButton { padding: 0 13px; font-size: 12px; }
  .detailActions { gap: 5px; }
  .movieDialog { padding: 34px 16px 18px; }
  .playerMeta { font-size: 11px; }
}
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { animation: none !important; transition: none !important; scroll-behavior: auto !important; } }

.brand { font-size: 18px; }
.navItem:hover, .iconButton:hover { color: #14618c; }
.good, .statusDot.ready { color: #277653; }
.movieFacts .factRating { color: #887020; }
@media (min-width: 761px) and (max-width: 1100px) { .sidebar { width: 188px; } .portal, .topbar { margin-left: 188px; } .brand { font-size: 18px; } }
