:root {
  --sidebar: 220px;
  font-family: Inter, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--ink);
  font-size: 14px
}
* {
  box-sizing: border-box
}
body {
  margin: 0;
  background: var(--bg)
}
a {
  color: inherit;
  text-decoration: none
}
button,
input,
select {
  font: inherit
}
button {
  cursor: pointer
}
button:disabled {
  opacity: .55;
  cursor: wait
}
button,
.pill {
  border-radius: 8px
}
button {
  border: 0;
  padding: 11px 17px;
  font-weight: 600;
  transition: background .15s
}
.primary {
  color: #fff
}
.secondary {
  border: 1px solid #dce0e6;
  background: white;
  color: #424b59
}
.secondary:hover {
  background: #f8f8fc
}
.ghost {
  background: transparent;
  color: #626b79
}
.small,
small {
  font-size: 12px
}
.muted {
  color: var(--muted)
}
.hidden {
  display: none !important
}
.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  width: var(--sidebar);
  background: #fff;
  border-right: 1px solid var(--line);
  padding: 32px 20px;
  display: flex;
  flex-direction: column
}
.brand {
  font-size: 23px;
  font-weight: 750;
  letter-spacing: -1px;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 8px
}
.brand-icon {
  display: inline-grid;
  place-items: center;
  background: var(--accent);
  color: #fff;
  border-radius: 9px;
  width: 32px;
  height: 32px;
  font-size: 25px
}
.brand-sub {
  display: block;
  width: 100%;
  padding-left: 41px;
  font-size: 9px;
  letter-spacing: 3px;
  color: #89909d;
  margin-top: -7px
}
.nav-label {
  font-size: 9px;
  font-weight: 700;
  letter-spacing: 1.4px;
  color: #a0a7b2;
  margin: 52px 10px 15px
}
.nav {
  background: transparent;
  text-align: left;
  display: flex;
  gap: 13px;
  align-items: center;
  margin-bottom: 7px;
  font-size: 17px;
  color: #777f8d
}
.nav span {
  font-size: 13px
}
.nav.active {
  background: var(--accent-bg);
  color: var(--accent)
}
.sidebar-bottom {
  margin-top: auto;
  display: flex;
  gap: 10px;
  align-items: center;
  font-size: 12px;
  font-weight: 600;
  border-top: 1px solid var(--line);
  padding-top: 23px
}
.sidebar-bottom small {
  display: block;
  color: #9299a5;
  font-weight: 400;
  margin-top: 5px;
  font-size: 10px
}
.server-dot {
  background: #30ba8e;
  width: 8px;
  height: 8px;
  border-radius: 100%;
  box-shadow: 0 0 0 4px #e9f8f2
}
.workspace {
  margin-left: var(--sidebar)
}
header {
  height: 76px;
  background: #ffffffc7;
  border-bottom: 1px solid var(--line);
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 42px;
  font-size: 12px
}
.breadcrumb {
  color: #89919d
}
.slash {
  margin: 0 16px;
  color: #b2b9c3
}
main {
  max-width: 1480px;
  margin: auto;
  padding: 38px 42px 24px
}
.page-heading {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 25px;
  margin-bottom: 27px
}
.page-heading>button {
  flex-shrink: 0
}
h1 {
  font-size: 29px;
  letter-spacing: -1px;
  line-height: 1.25;
  margin: 8px 0 10px;
  font-weight: 650
}
h2 {
  font-size: 16px;
  letter-spacing: -.2px;
  margin: 0;
  font-weight: 650
}
p {
  line-height: 1.6;
  margin: 6px 0
}
.eyebrow {
  font-size: 9px;
  font-weight: 750;
  letter-spacing: 2px;
  margin: 0
}
.stats {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 16px;
  margin-bottom: 25px
}
.stats article {
  border: 1px solid var(--line);
  border-radius: 12px;
  background: white;
  padding: 20px 23px
}
.stat-label {
  font-size: 9px;
  letter-spacing: 1.1px;
  font-weight: 650;
  color: #8a91a0
}
.stats strong {
  display: block;
  font-size: 28px;
  letter-spacing: -1px;
  font-weight: 600;
  margin: 14px 0 6px
}
.stats small {
  font-size: 11px;
  color: #8f97a4
}
.card {
  background: #fff;
  border: 1px solid var(--line);
  border-radius: 12px;
  margin-bottom: 24px
}
.section-head {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 20px;
  padding: 23px 25px;
  border-bottom: 1px solid #f0f1f5
}
.pill {
  font-size: 10px;
  color: #7c6baf;
  background: #f5f2fd;
  padding: 7px 10px;
  white-space: nowrap
}
.upload-grid {
  display: grid;
  grid-template-columns: 1fr 1.13fr;
  gap: 27px;
  padding: 25px
}
.dropzone {
  border: 1.5px dashed #cfc8ed;
  background: #fbfaff;
  border-radius: 10px;
  min-height: 228px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-direction: column;
  gap: 10px;
  cursor: pointer;
  transition: background .2s
}
.dropzone.drag {
  background: #ede6ff;
  border-color: var(--accent)
}
.dropzone input {
  display: none
}
.dropzone strong {
  font-size: 14px;
  font-weight: 600
}
.dropzone>span.muted {
  font-size: 12px
}
.dropzone small {
  color: #a0a5b0;
  margin-top: 12px;
  font-size: 10px
}
.upload-symbol {
  width: 43px;
  height: 43px;
  border: 1px solid #e7e0ff;
  background: #f3eeff;
  border-radius: 12px;
  color: var(--accent);
  font-size: 27px;
  display: grid;
  place-items: center;
  margin-bottom: 3px
}
.destination {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px
}
.destination>label {
  display: flex;
  align-items: center;
  flex: 1
}
.destination strong {
  font-size: 12px
}
.destination small {
  white-space: nowrap
}
.host-logo {
  height: 27px;
  width: 27px;
  display: inline-grid;
  place-items: center;
  border-radius: 7px;
  font-size: 12px;
  font-weight: 750;
  flex-shrink: 0
}
.vidara {
  background: #f0eaff;
  color: #8753dd
}
.byse {
  background: #e8f4ff;
  color: #2c82cf
}
.content {
  background: #f1f7dc;
  color: #759c11
}
.streamcash {
  background: #fff0e5;
  color: #d28a3c
}
.host-check {
  accent-color: var(--accent);
  width: 15px;
  height: 15px
}
.destination select {
  font-size: 11px;
  padding: 8px 9px;
  width: 145px;
  border: 1px solid #e2e5ec;
  border-radius: 6px;
  color: #5e6675;
  background: #fff
}
.destinations>p {
  margin-top: 12px;
  font-size: 10px
}
.upload-progress {
  margin: 0 25px 23px
}
.upload-progress>div {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  gap: 20px
}
.upload-progress strong {
  overflow-wrap: anywhere
}
progress {
  width: 100%;
  height: 7px;
  border: 0;
  border-radius: 7px;
  margin-top: 13px;
  accent-color: var(--accent)
}
progress::-webkit-progress-bar {
  background: #efedf8;
  border-radius: 7px
}
progress::-webkit-progress-value {
  background: var(--accent);
  border-radius: 7px
}
.count {
  background: #f2f3f6;
  border-radius: 5px;
  padding: 3px 7px;
  margin-left: 6px;
  font-size: 11px;
  color: #868d99
}
.search,
input,
select {
  outline: none
}
.search {
  width: 200px;
  font-size: 12px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: #fcfcfd
}
input:focus,
select:focus {
  border-color: #a18cec;
  box-shadow: 0 0 0 3px #7259e811
}
.empty {
  padding: 48px 20px;
  text-align: center;
  color: #9299a6;
  font-size: 13px
}
.empty strong {
  display: block;
  color: #5e6674;
  margin: 10px
}
.file {
  padding: 22px 25px;
  border-bottom: 1px solid var(--line)
}
.file:last-child {
  border: 0
}
.file-head {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: flex-start
}
.file-title {
  display: flex;
  gap: 13px;
  min-width: 0
}
.file-icon {
  display: grid;
  place-items: center;
  width: 35px;
  height: 41px;
  background: #f5f2fd;
  border: 1px solid #e8e2f7;
  border-radius: 7px;
  color: #9176cf;
  flex-shrink: 0
}
.file-name {
  font-size: 13px;
  font-weight: 600;
  overflow-wrap: anywhere
}
.file-meta {
  font-size: 10px;
  color: #949ca8;
  margin-top: 6px
}
.file-actions {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
  justify-content: flex-end;
  flex-shrink: 0
}
.file-actions button {
  font-size: 10px;
  padding: 7px 9px;
  background: #fafafa;
  border: 1px solid var(--line);
  color: #737b88
}
.file-actions button.danger {
  color: #c46e6e
}
.jobs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 18px;
  padding-left: 48px
}
.job {
  border: 1px solid var(--line);
  border-radius: 7px;
  padding: 11px 13px
}
.job-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 9px;
  font-size: 11px
}
.job-title {
  display: flex;
  align-items: center;
  gap: 7px
}
.job-title strong {
  font-size: 11px
}
.badge {
  padding: 4px 7px;
  border-radius: 5px;
  font-size: 9px;
  background: #f0f1f4;
  color: #87909e;
  white-space: nowrap
}
.badge.ready {
  background: #eaf7f0;
  color: #27946e
}
.badge.uploading,
.badge.processing {
  background: #f0ecfe;
  color: #8b71d9
}
.badge.failed,
.badge.interrupted {
  background: #fff0ee;
  color: #c87568
}
.job-bottom {
  font-size: 10px;
  color: #9aa0ac;
  margin-top: 9px;
  display: flex;
  justify-content: space-between;
  gap: 8px
}
.job button {
  font-size: 10px;
  padding: 3px 5px;
  background: transparent
}
.job progress {
  height: 3px;
  margin-top: 10px
}
.job-error {
  color: #bd766d;
  font-size: 10px;
  margin-top: 7px;
  overflow-wrap: anywhere
}
.footnote {
  color: #9da4af;
  font-size: 10px;
  max-width: 720px
}
footer {
  display: flex;
  justify-content: space-between;
  padding: 15px 42px 25px;
  font-size: 10px;
  color: #a1a7b0;
  max-width: 1480px;
  margin: auto
}
.settings-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  padding: 25px
}
.settings-grid label,
.host-setting-fields label,
.password-card label,
.login-card label {
  display: flex;
  flex-direction: column;
  gap: 9px;
  font-size: 12px;
  color: #505a6a;
  font-weight: 550
}
.settings-grid small {
  font-size: 10px;
  color: #929aa6;
  line-height: 1.5;
  font-weight: 400
}
input:not([type=checkbox]):not([type=file]) {
  border: 1px solid #e0e4ea;
  border-radius: 7px;
  background: #fff;
  padding: 11px 12px;
  color: #323b48;
  width: 100%
}
.host-setting {
  padding: 22px 25px;
  border-bottom: 1px solid var(--line)
}
.host-setting-title {
  display: flex;
  gap: 10px;
  align-items: center;
  margin-bottom: 15px
}
.host-setting-title strong {
  font-size: 13px
}
.host-setting-fields {
  display: grid;
  grid-template-columns: 2fr 1fr auto;
  align-items: end;
  gap: 18px
}
.host-setting-fields .secondary {
  height: 40px;
  font-size: 12px
}
.settings-view .card>p {
  padding: 0 25px
}
.password-card {
  margin-top: 30px;
  padding: 25px
}
.password-card form {
  display: flex;
  align-items: end;
  gap: 15px;
  margin-top: 20px
}
.password-card label {
  width: 350px
}
.warning {
  background: #fff3df;
  color: #946e2d;
  padding: 14px 18px;
  border: 1px solid #f3deb4;
  border-radius: 8px;
  margin-bottom: 20px;
  font-size: 12px
}
#toast {
  position: fixed;
  right: 25px;
  bottom: 25px;
  z-index: 10;
  max-width: 480px;
  background: #252b39;
  color: #fff;
  padding: 15px 22px;
  border-radius: 9px;
  box-shadow: 0 8px 35px #0002;
  font-size: 13px
}
#toast.error {
  background: #a94242
}
.login-page {
  min-height: 100vh;
  display: grid;
  place-items: center;
  background: radial-gradient(ellipse at 10% 15%, #eee9ff, transparent 60%), #f7f8fa
}
.login-card {
  width: 440px;
  padding: 40px;
  background: white;
  border: 1px solid #e9e5f3;
  border-radius: 16px;
  box-shadow: 0 20px 80px #4534770c
}
.login-card .brand {
  font-size: 24px;
  margin-bottom: 45px
}
.login-card .brand>.muted {
  font-size: 16px;
  font-weight: 400
}
.login-card h1 {
  font-size: 32px;
  margin: 12px 0 16px
}
.login-card form {
  margin-top: 28px
}
.login-card label {
  margin-bottom: 17px
}
.full {
  width: 100%;
  display: flex;
  justify-content: space-between;
  margin-top: 24px
}
.login-card>p.small {
  margin-top: 30px
}
.error {
  color: #bf5454
}
@media (min-width:1500px) {
  main {
    padding-top: 48px
  }
  .upload-grid {
    gap: 40px
  }
  .dropzone {
    min-height: 250px
  }
}
@media (max-width:1150px) {
  :root {
    --sidebar: 180px
  }
  main {
    padding: 28px 24px
  }
  .sidebar {
    padding: 28px 14px
  }
  .page-heading h1 {
    font-size: 25px
  }
  .upload-grid {
    grid-template-columns: 1fr
  }
  .dropzone {
    min-height: 180px
  }
  .destination select {
    width: 180px
  }
  .stats article {
    padding: 18px 15px
  }
  .jobs {
    padding-left: 0
  }
  .settings-grid {
    grid-template-columns: 1fr
  }
  .host-setting-fields {
    grid-template-columns: 2fr 1fr
  }
  .host-setting-fields button {
    grid-column: 1/-1
  }
  .brand {
    font-size: 21px
  }
}
@media (max-width:720px) {
  :root {
    --sidebar: 0px
  }
  .sidebar {
    position: static;
    width: auto;
    padding: 16px 20px;
    flex-direction: row;
    gap: 15px;
    align-items: center;
    border-bottom: 1px solid var(--line)
  }
  .sidebar .brand {
    margin-right: auto;
    font-size: 20px
  }
  .brand-sub,
  .nav-label,
  .sidebar-bottom {
    display: none
  }
  .nav {
    margin: 0;
    padding: 9px
  }
  .nav span {
    font-size: 11px
  }
  .workspace {
    margin: 0
  }
  header {
    height: 52px;
    padding: 0 20px
  }
  main {
    padding: 24px 16px
  }
  .page-heading {
    align-items: start;
    flex-direction: column;
    gap: 15px
  }
  h1,
  .page-heading h1 {
    font-size: 24px
  }
  .stats {
    grid-template-columns: 1fr 1fr;
    gap: 10px
  }
  .stats article {
    padding: 16px
  }
  .stats strong {
    font-size: 26px
  }
  .section-head {
    padding: 18px;
    gap: 12px
  }
  .pill {
    font-size: 9px
  }
  .upload-grid {
    padding: 18px;
    gap: 18px
  }
  .destination {
    gap: 8px
  }
  .destination strong {
    font-size: 11px
  }
  .destination select {
    width: 132px;
    font-size: 10px
  }
  .host-state {
    display: none
  }
  .search {
    width: 135px
  }
  .file {
    padding: 18px
  }
  .file-head {
    flex-direction: column
  }
  .file-actions {
    padding-left: 48px
  }
  .jobs {
    grid-template-columns: 1fr
  }
  .host-setting-fields {
    grid-template-columns: 1fr
  }
  .host-setting {
    padding: 18px
  }
  .settings-grid {
    padding: 18px
  }
  .password-card form {
    align-items: stretch;
    flex-direction: column
  }
  .password-card label {
    width: 100%
  }
  footer {
    padding: 12px 18px 25px
  }
  .login-card {
    width: calc(100% - 32px);
    padding: 30px
  }
  .login-card h1 {
    font-size: 29px
  }
}
.badge.reconciling {
  background: #f0ecfe;
  color: #8b71d9
}
.job-notice {
  font-size: 11px;
  color: #77718c;
  line-height: 1.5;
  margin: 10px 0 4px
}
.job-check-time {
  font-size: 9px;
  color: #9a9fac;
  margin-top: 9px;
  overflow-wrap: anywhere
}
.job-check-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 8px
}
.job-check-actions button {
  font-size: 10px;
  background: #f7f5fd;
  padding: 5px 8px
}
.badge.missing {
  background: #fff0ee;
  color: #c87568
}
.library-tab {
  background: transparent;
  color: #7d8591
}
.library-tab.active {
  background: #f1edff;
  color: #7259e8
}
.file-actions button.secondary {
  background: #f6f4fd;
  border: 1px solid #ece7fb;
  color: #6f5abb
}
.jobs-collapsed {
  display: none !important
}
.shinden-form {
  padding: 22px 25px;
  display: grid;
  gap: 16px
}
.shinden-form label,
.shinden-fields label {
  display: flex;
  flex-direction: column;
  gap: 8px;
  font-size: 12px;
  color: #505a6a;
  font-weight: 550
}
.shinden-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap
}
.shinden-dialog {
  width: min(760px, calc(100% - 24px));
  max-height: 90vh;
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 24px;
  background: #fff;
  color: var(--ink);
  box-shadow: 0 20px 70px #16122b40
}
.shinden-dialog::backdrop {
  background: #10152280;
  backdrop-filter: blur(2px)
}
.shinden-modal-head {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  align-items: flex-start;
  border-bottom: 1px solid var(--line);
  padding-bottom: 15px;
  margin-bottom: 18px
}
.shinden-modal-head h2 {
  margin: 3px 0
}
.shinden-fields {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px
}
.shinden-fields>button,
.shinden-feedback,
.shinden-results,
.shinden-submit-row {
  grid-column: 1/-1
}
.shinden-results {
  display: grid;
  gap: 7px;
  max-height: 170px;
  overflow: auto
}
.shinden-results button {
  text-align: left;
  background: #f7f5fd;
  color: #514576;
  padding: 10px 12px
}
.shinden-results button:hover {
  background: #eee9ff
}
.shinden-submit-row {
  display: flex;
  align-items: center;
  gap: 15px;
  flex-wrap: wrap
}
.shinden-add {
  font-size: 10px;
  color: #7259e8;
  background: #f4f0ff;
  padding: 7px 9px;
  margin-top: 8px
}
.shinden-dialog textarea {
  width: 100%;
  border: 1px solid #e0e4ea;
  border-radius: 7px;
  padding: 10px;
  resize: vertical;
  font: inherit
}
.shinden-dialog label input,
.shinden-dialog label select {
  width: 100%;
  border: 1px solid #e0e4ea;
  border-radius: 7px;
  padding: 10px;
  background: #fff;
  color: #323b48
}
.shinden-form input:not([type=checkbox]) {
  width: 100%
}
.republish-hosts,
.shinden-links {
  display: grid
}
.republish-host,
.shinden-link-option {
  display: flex;
  align-items: center;
  gap: 12px;
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 12px
}
.republish-host>span,
.shinden-link-option>span {
  display: grid;
  gap: 4px;
  flex: 1
}
.republish-host small,
.shinden-link-option small {
  color: var(--muted)
}
.republish-host select {
  width: auto
}
.republish-host.unavailable {
  color: var(--muted)
}
.shinden-series-preview {
  grid-column: 1/-1
}
.shinden-series-preview>a {
  display: flex;
  gap: 14px;
  align-items: center;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 10px;
  color: inherit;
  text-decoration: none
}
.shinden-series-preview img,
.history-cover img {
  width: 72px;
  height: 96px;
  object-fit: cover;
  border-radius: 6px
}
.shinden-series-preview span {
  display: grid;
  gap: 7px
}
.shinden-series-preview small {
  color: #7259e8
}
.shinden-links-field {
  grid-column: 1/-1;
  display: grid;
  gap: 9px
}
.shinden-history-actions {
  display: flex;
  gap: 10px;
  flex-wrap: wrap
}
.shinden-history-list {
  display: grid;
  gap: 12px
}
.shinden-history-item {
  display: flex;
  gap: 15px;
  padding: 16px
}
.history-cover {
  flex: none
}
.shinden-history-main {
  flex: 1;
  min-width: 0;
  display: grid;
  gap: 8px
}
.shinden-history-top {
  display: flex;
  justify-content: space-between;
  gap: 10px
}
.shinden-history-links {
  display: flex;
  gap: 8px;
  flex-wrap: wrap
}
@media (max-width:650px) {
  .shinden-fields {
    grid-template-columns: 1fr
  }
  .shinden-history-item {
    padding: 11px
  }
  .republish-host {
    flex-wrap: wrap
  }
}
#shinden-feedback.shinden-feedback {
  display: block;
  grid-column: 1/-1;
  padding: 14px 16px;
  border: 1px solid #cfd8e8;
  border-left: 5px solid #64748b;
  border-radius: 9px;
  background: #f3f6fb;
  color: #273449;
  font-size: 14px;
  font-weight: 650;
  line-height: 1.55;
  box-shadow: 0 4px 15px #1a27400d;
  white-space: pre-wrap
}
#shinden-feedback.is-warning {
  background: #fff3d6;
  border-color: #e8a82f;
  color: #754600;
  border-left-color: #d18400;
  font-size: 15px
}
#shinden-feedback.is-error {
  background: #fff0ef;
  border-color: #df9b96;
  color: #8c2925;
  border-left-color: #c43f37
}
#shinden-feedback.is-info {
  background: #f0edff;
  border-color: #c9bef5;
  color: #49369b;
  border-left-color: #7259e8
}
.shinden-profile-link {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-weight: 650;
  text-decoration: none !important
}
.shinden-profile-link span {
  display: grid;
  place-items: center;
  width: 23px;
  height: 23px;
  border-radius: 6px;
  background: var(--accent-bg);
  color: var(--accent)
}
.shinden-history-actions .secondary {
  min-height: 42px
}
.history-title-links {
  display: flex;
  flex-direction: column;
  gap: 7px;
  min-width: 0
}
.shinden-series-title {
  font-size: 15px;
  font-weight: 700;
  line-height: 1.35
}
.shinden-series-title:hover,
.shinden-history-links a:hover {
  text-decoration: underline
}
.episode-link {
  display: inline-flex;
  align-self: flex-start;
  padding: 5px 9px;
  border: 1px solid var(--line);
  border-radius: 6px;
  background: var(--accent-bg);
  color: var(--accent);
  font-size: 11px;
  font-weight: 650
}
.shinden-history-top {
  align-items: flex-start
}
.theme-dark .login-card {
  box-shadow: 0 20px 80px #0005
}
@media (max-width:720px) {
  .shinden-history-actions {
    width: 100%
  }
  .shinden-history-actions>* {
    flex: 1;
    text-align: center;
    justify-content: center
  }
}
.republish-dialog {
  width: min(680px, calc(100% - 24px));
  padding: 20px
}
.republish-hosts {
  gap: 8px
}
.republish-host:not(.unavailable) {
  display: grid;
  grid-template-columns: 22px minmax(0, 1fr) minmax(155px, 205px);
  align-items: center;
  gap: 11px;
  padding: 10px 12px;
  min-height: 60px
}
.republish-host:not(.unavailable)>input[type=checkbox] {
  width: 16px;
  height: 16px;
  margin: 0;
  justify-self: center;
  accent-color: var(--accent)
}
.republish-host:not(.unavailable)>span {
  display: flex;
  flex-direction: column;
  gap: 3px;
  min-width: 0
}
.republish-host:not(.unavailable)>span strong {
  font-size: 13px
}
.republish-host:not(.unavailable)>span small {
  font-size: 11px;
  line-height: 1.35
}
.republish-host:not(.unavailable) select {
  width: 100%;
  min-width: 0;
  padding: 9px 11px
}
.republish-host.unavailable {
  display: flex;
  justify-content: space-between;
  min-height: 48px;
  padding: 8px 12px
}
.republish-host.unavailable>small {
  color: var(--muted)
}
.theme-dark .republish-host,
.theme-dark .shinden-link-option,
.theme-dark .shinden-series-preview>a {
  background: #202e43;
  border-color: #4a5d76
}
.theme-dark .muted,
.theme-dark .file-meta,
.theme-dark .stats small,
.theme-dark .stat-label,
.theme-dark .settings-grid small,
.theme-dark .republish-host small,
.theme-dark .shinden-link-option small,
.theme-dark .destination small {
  color: #bac6d6
}
.theme-dark .file-name,
.theme-dark .job-title strong,
.theme-dark .destination strong,
.theme-dark h1,
.theme-dark h2 {
  color: #f1f5fb
}
.theme-dark .destination select,
.theme-dark input:not([type=checkbox]):not([type=file]),
.theme-dark select,
.theme-dark textarea,
.theme-dark .search,
.theme-dark .shinden-dialog label input,
.theme-dark .shinden-dialog label select {
  background: #111b2a;
  color: #edf3fa;
  border-color: #52647c
}
.theme-dark .job-error {
  color: #ffaaa5
}
.theme-dark .job-notice {
  color: #d0c6f4
}
@media (max-width:650px) {
  .republish-dialog {
    padding: 16px
  }
  .republish-host:not(.unavailable) {
    grid-template-columns: 22px minmax(0, 1fr);
    gap: 8px
  }
  .republish-host:not(.unavailable)>input[type=checkbox] {
    grid-row: 1 / span 2
  }
  .republish-host:not(.unavailable)>span {
    grid-column: 2
  }
  .republish-host:not(.unavailable) select {
    grid-column: 2
  }
}
/* High contrast, inspired by Anime-Odcinki's original dark skin. */
:root {
  --bg: #f3f5f7;
  --ink: #20242b;
  --muted: #68717d;
  --line: #dfe3e8;
  --accent: #3478d4;
  --accent-bg: #eaf2fc;
  --green: #16845e;
  --surface: #fff;
  color-scheme: light
}
.primary {
  background: var(--accent);
  box-shadow: none
}
.primary:hover {
  background: #2868bc
}
.eyebrow,
.job button,
.shinden-series-title {
  color: var(--accent)
}
.destinations-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 7px
}
.destinations-head>strong {
  font-size: 12px
}
.select-all-hosts {
  padding: 6px 9px;
  font-size: 11px;
  border-radius: 6px;
  color: var(--accent)
}
.destination {
  padding: 7px 0
}
.destination>label {
  gap: 8px
}
.destination strong {
  min-width: 0
}
.destination small {
  font-size: 10px
}
.theme-setting {
  display: grid;
  gap: 10px;
  max-width: 460px
}
.theme-label {
  font-size: 12px;
  font-weight: 600
}
.theme-picker {
  display: flex;
  gap: 4px;
  padding: 4px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #e9edf2;
  width: max-content;
  max-width: 100%
}
.theme-option {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 12px;
  border-radius: 6px;
  background: transparent;
  color: #515965;
  font-size: 12px;
  white-space: nowrap
}
.theme-option>span {
  font-size: 15px;
  line-height: 1
}
.theme-option[aria-checked=true] {
  background: #fff;
  color: #20242b;
  box-shadow: 0 1px 4px #17233324
}
.theme-setting>small {
  font-size: 11px;
  color: var(--muted)
}
.shinden-links {
  gap: 6px
}
.shinden-fields .shinden-link-option {
  display: grid;
  grid-template-columns: 18px minmax(0, 1fr);
  align-items: center;
  gap: 9px;
  min-height: 48px;
  padding: 7px 11px;
  border-radius: 7px;
  background: #fff
}
.shinden-fields .shinden-link-option>input[type=checkbox] {
  grid-column: 1;
  grid-row: 1;
  width: 15px;
  height: 15px;
  margin: 0;
  accent-color: var(--accent)
}
.shinden-fields .shinden-link-option>span {
  grid-column: 2;
  grid-row: 1;
  display: flex;
  flex-direction: row;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  min-width: 0
}
.shinden-fields .shinden-link-option>span strong {
  font-size: 12px;
  color: var(--ink)
}
.shinden-fields .shinden-link-option>span small {
  max-width: 65%;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 10px;
  color: var(--muted)
}
.theme-dark {
  --bg: #111;
  --ink: #f3f4f6;
  --muted: #aeb4bd;
  --line: #34363a;
  --accent: #60a5fa;
  --accent-bg: #202a38;
  --green: #55c49b;
  --surface: #1a1b1e;
  color-scheme: dark
}
.theme-dark body {
  background: #111;
  color: #f3f4f6
}
.theme-dark .sidebar,
.theme-dark .card,
.theme-dark .stats article,
.theme-dark .shinden-dialog,
.theme-dark .login-card {
  background: #1a1b1e;
  color: #f3f4f6;
  border-color: #34363a
}
.theme-dark header {
  background: #111e;
  border-color: #34363a
}
.theme-dark .section-head,
.theme-dark .host-setting,
.theme-dark .file {
  border-color: #34363a
}
.theme-dark .nav {
  color: #c2c6cc
}
.theme-dark .nav.active {
  background: #242d39;
  color: #9bc7ff
}
.theme-dark .secondary,
.theme-dark .file-actions button {
  background: #24262a;
  color: #e8eaed;
  border-color: #41444a
}
.theme-dark .secondary:hover,
.theme-dark .file-actions button:hover {
  background: #303238;
  border-color: #5a5e65
}
.theme-dark .ghost {
  color: #c5c9cf
}
.theme-dark input:not([type=checkbox]):not([type=file]),
.theme-dark select,
.theme-dark textarea,
.theme-dark .search,
.theme-dark .shinden-dialog label input,
.theme-dark .shinden-dialog label select {
  background: #151619;
  color: #f3f4f6;
  border-color: #45484e
}
.theme-dark .dropzone {
  background: #191c21;
  border-color: #596d84;
  color: #f3f4f6
}
.theme-dark .job,
.theme-dark .republish-host,
.theme-dark .shinden-fields .shinden-link-option,
.theme-dark .shinden-series-preview>a {
  background: #222428;
  border-color: #45484e
}
.theme-dark .shinden-fields .shinden-link-option>span strong {
  color: #f3f4f6
}
.theme-dark .count,
.theme-dark .badge {
  background: #303237;
  color: #d6d9de
}
.theme-dark .badge.ready {
  background: #17372d;
  color: #8fe0bd
}
.theme-dark .badge.failed,
.theme-dark .badge.interrupted {
  background: #452729;
  color: #ffaaa5
}
.theme-dark .badge.processing,
.theme-dark .badge.uploading,
.theme-dark .badge.reconciling {
  background: #26364b;
  color: #a9ceff
}
.theme-dark .warning {
  background: #392f1c;
  color: #f3d38a;
  border-color: #6b5526
}
.theme-dark .shinden-results button,
.theme-dark .job-check-actions button {
  background: #242c37;
  color: #b9d6ff
}
.theme-dark #shinden-feedback.is-warning {
  background: #382d19;
  color: #ffd27d;
  border-color: #795d25
}
.theme-dark #shinden-feedback.is-error {
  background: #3b2224;
  color: #ffaaa5;
  border-color: #754043
}
.theme-dark #shinden-feedback.is-info {
  background: #222d3b;
  color: #b8d7ff;
  border-color: #3b5877
}
.theme-dark .login-page {
  background: #111
}
.theme-dark .shinden-dialog::backdrop {
  background: #000c
}
.theme-dark #toast {
  background: #f0f2f5;
  color: #181a1d
}
.theme-dark #toast.error {
  background: #a83232;
  color: white
}
.theme-dark .theme-picker {
  background: #121315;
  border-color: #41444a
}
.theme-dark .theme-option {
  color: #c2c6cc
}
.theme-dark .theme-option[aria-checked=true] {
  background: #34373d;
  color: #fff;
  box-shadow: 0 1px 4px #0008
}
.theme-dark .republish-host:not(.unavailable) {
  background: #222428;
  border-color: #45484e
}
.theme-dark .shinden-series-title {
  color: #8fc1ff
}
.theme-dark .episode-link {
  background: #242c37;
  border-color: #466181;
  color: #abd1ff
}
.theme-dark .shinden-profile-link span {
  background: #253448;
  color: #abd1ff
}
.theme-dark .primary {
  background: #3478d4;
  color: #fff
}
.theme-dark .primary:hover {
  background: #4789e3
}
@media (max-width:650px) {
  .theme-picker {
    width: 100%
  }
  .theme-option {
    flex: 1;
    justify-content: center;
    padding: 8px 6px;
    font-size: 11px
  }
  .shinden-fields .shinden-link-option>span {
    align-items: flex-start;
    flex-direction: column;
    gap: 2px
  }
  .shinden-fields .shinden-link-option>span small {
    max-width: 100%
  }
}
/* Shinden dialog: keep its filename visible while the form scrolls. */
#shinden-modal .shinden-modal-head,
#anime-settings-modal .shinden-modal-head,
#anime-detail-modal .shinden-modal-head {
  position: sticky;
  top: -24px;
  z-index: 20;
  margin: -24px -24px 14px;
  padding: 20px 24px 13px;
  background: inherit;
  border-bottom: 1px solid var(--line)
}
#shinden-file-name {
  margin: 6px 0 0;
  font-size: 12px;
  font-weight: 600;
  line-height: 1.4;
  overflow-wrap: anywhere;
  color: var(--muted)
}
.shinden-profile-link {
  border: 1px solid var(--line);
  border-radius: 9px;
  padding: 9px 13px;
  min-height: 42px;
  background: var(--surface, #fff);
  box-shadow: 0 1px 3px #18223012;
  transition: background .15s, border-color .15s, transform .15s
}
.shinden-profile-link:hover {
  background: var(--accent-bg);
  border-color: var(--accent);
  transform: translateY(-1px)
}
.shinden-notice {
  position: fixed;
  z-index: 2147483647;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  width: min(560px, calc(100vw - 32px));
  padding: 19px 24px;
  border: 1px solid;
  border-left-width: 6px;
  border-radius: 12px;
  box-shadow: 0 22px 90px #0009;
  text-align: center;
  font-size: 15px;
  font-weight: 700;
  line-height: 1.55;
  white-space: pre-wrap
}
.shinden-notice.hidden {
  display: none !important
}
.shinden-notice.success {
  background: #e8f7ee;
  color: #155b35;
  border-color: #79bd91
}
.shinden-notice.warning {
  background: #fff4dc;
  color: #754600;
  border-color: #e5a634
}
.shinden-notice.error {
  background: #fff0ef;
  color: #8c2925;
  border-color: #d87870
}
.theme-dark .shinden-notice.success {
  background: #173b29;
  color: #c1f1d0;
  border-color: #39845a
}
.theme-dark .shinden-notice.warning {
  background: #493719;
  color: #ffe3a3;
  border-color: #ad7928
}
.theme-dark .shinden-notice.error {
  background: #482426;
  color: #ffd0cc;
  border-color: #a94d4a
}
@media (max-width:650px) {
  #shinden-modal .shinden-modal-head {
    top: -16px;
    margin: -16px -16px 12px;
    padding: 14px 16px 11px
  }
  .shinden-notice {
    padding: 16px 18px;
    font-size: 14px
  }
}
/* AnimeSchedule token configuration. */
.animeschedule-card {
  max-width: 920px
}
.animeschedule-card .section-head {
  align-items: flex-start;
  padding-bottom: 16px;
  margin-bottom: 18px
}
.animeschedule-card .section-head h2 {
  margin: 2px 0 5px;
  font-size: 17px
}
.animeschedule-card .section-head .eyebrow {
  margin: 0;
  font-size: 10px;
  letter-spacing: .13em
}
.animeschedule-card .section-head p {
  margin: 0
}
.animeschedule-card #animeschedule-form {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 8px;
  max-width: 680px
}
.animeschedule-card #animeschedule-form>label {
  font-size: 12px;
  font-weight: 650;
  color: var(--ink)
}
.animeschedule-card #animeschedule-token {
  width: 100%;
  min-height: 42px;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--surface, #fff);
  color: var(--ink);
  font-size: 13px
}
.animeschedule-card #animeschedule-help {
  max-width: 620px;
  color: var(--muted);
  line-height: 1.5
}
.animeschedule-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
  margin-top: 8px
}
.animeschedule-actions button {
  min-height: 38px;
  padding: 9px 15px
}
.animeschedule-actions>a {
  font-size: 12px;
  font-weight: 600;
  color: var(--accent);
  text-decoration: none
}
.animeschedule-actions>a:hover {
  text-decoration: underline
}
.theme-dark .animeschedule-card #animeschedule-token {
  background: #151619;
  color: #f3f4f6;
  border-color: #45484e
}
#toast[popover] {
  position: fixed;
  inset: auto 25px 25px auto;
  margin: 0;
  max-width: min(480px, calc(100vw - 32px));
  border: 0;
  z-index: 2147483647
}
#toast:popover-open {
  display: block
}
.shinden-history-item.history-panel-entry {
  border-color: #4d91e8;
  box-shadow: 0 0 0 1px rgba(77, 145, 232, .18)
}
.shinden-history-item.history-shinden-entry {
  border-color: var(--line);
  box-shadow: 0 0 0 1px rgba(130, 140, 155, .08)
}
.workspace>header {
  position: sticky;
  top: 0;
  z-index: 1000;
  backdrop-filter: blur(12px)
}
.theme-dark .notification-panel,
.theme-dark .notification-bell {
  background: #1a1b1e;
  color: #f3f4f6;
  border-color: #45484e
}
.topbar-actions {
  display: flex;
  align-items: center;
  gap: 10px
}
.notification-wrap {
  position: relative
}
.notification-bell {
  position: relative;
  display: grid;
  place-items: center;
  width: 38px;
  height: 38px;
  padding: 0;
  border: 1px solid var(--line);
  background: var(--surface, #fff);
  color: var(--ink);
  font-size: 20px
}
.notification-bell:hover {
  border-color: var(--accent);
  background: var(--accent-bg)
}
.notification-count {
  position: absolute;
  right: -6px;
  top: -6px;
  min-width: 18px;
  height: 18px;
  padding: 0 5px;
  border-radius: 99px;
  background: #d94343;
  color: white;
  font-size: 10px;
  font-weight: 750;
  line-height: 18px;
  text-align: center
}
.notification-panel {
  position: absolute;
  right: 0;
  top: 46px;
  width: min(390px, calc(100vw - 24px));
  max-height: min(70vh, 560px);
  overflow: auto;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface, #fff);
  color: var(--ink);
  box-shadow: 0 16px 50px #0003
}
.notification-panel-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 2px 2px 9px;
  border-bottom: 1px solid var(--line)
}
.notification-item {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: start;
  gap: 10px;
  padding: 11px 2px;
  border-bottom: 1px solid var(--line)
}
.notification-item:last-child {
  border-bottom: 0
}
.notification-item p {
  margin: 3px 0;
  font-size: 12px;
  line-height: 1.45
}
.notification-item small {
  color: var(--muted);
  font-size: 10px
}
.notification-item.read {
  opacity: .62
}
.notification-item>button {
  width: 30px;
  height: 30px;
  padding: 0
}
.notification-empty {
  padding: 8px 2px
}
.upload-queue {
  display: grid;
  gap: .65rem;
  margin: 1rem 0
}
.upload-queue h2 {
  font-size: 1rem;
  margin: 0
}
.upload-queue-item {
  display: grid;
  gap: .35rem;
  padding: .75rem;
  border: 1px solid var(--line);
  border-radius: .65rem;
  background: #fff
}
.upload-queue-item>div {
  display: grid;
  gap: .2rem;
  min-width: 0;
  overflow-wrap: anywhere
}
.upload-queue-item progress {
  width: 100%;
  height: .55rem
}
.theme-dark .upload-queue-item {
  background: #1b2028
}
.library-tab {
  border: 1px solid var(--line);
  border-radius: 7px
}
.library-tab.active {
  border-color: var(--accent)
}
.theme-dark .library-tab {
  color: var(--muted);
  background: transparent;
  border-color: var(--line)
}
.theme-dark .library-tab.active {
  color: var(--accent);
  background: var(--accent-bg);
  border-color: var(--accent)
}
#file-list .file-publication-status {
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 11px;
  font-weight: 650
}
#file-list .file-publication-status[data-state=success] {
  border-color: #3a986d;
  color: #23794e
}
#file-list .file-publication-status[data-state=partial],
#file-list .file-publication-status[data-state=pending] {
  border-color: #bd8737;
  color: #996619
}
#file-list .file-publication-status[data-state=error] {
  border-color: #c95353;
  color: #ad3737
}
#file-list .job.shinden-link-success {
  border-color: #3a986d
}
#file-list .job.shinden-link-pending {
  border-color: #bd8737
}
#file-list .job.shinden-link-error {
  border-color: #c95353
}
#file-list .job .badge.ready {
  background: #e7ebf0;
  color: #54606e
}
#file-list .job-publication-status {
  font-size: 11px;
  font-weight: 650;
  color: var(--muted)
}
#file-list .job-publication-status[data-state=success] {
  color: #23794e
}
#file-list .job-publication-status[data-state=pending] {
  color: #996619
}
#file-list .job-publication-status[data-state=error] {
  color: #ad3737
}
.theme-dark #file-list .file-publication-status {
  background: #191b1f
}
.theme-dark #file-list .job .badge.ready {
  background: #30343a;
  color: #d0d5dd
}
.theme-dark #file-list .file-publication-status[data-state=success],
.theme-dark #file-list .job-publication-status[data-state=success] {
  color: #75d4a0
}
.theme-dark #file-list .file-publication-status[data-state=partial],
.theme-dark #file-list .file-publication-status[data-state=pending],
.theme-dark #file-list .job-publication-status[data-state=pending] {
  color: #f0c36e
}
.theme-dark #file-list .file-publication-status[data-state=error],
.theme-dark #file-list .job-publication-status[data-state=error] {
  color: #ff9e9a
}
/* Library header: tabs wrap as whole buttons instead of being squeezed beside the search box. */
.library-head {
  flex-wrap: wrap;
  align-items: flex-start
}
.library-head>div:first-child {
  flex: 1 1 420px;
  min-width: 0
}
.library-head .search {
  flex: 0 1 280px;
  width: 280px;
  max-width: 100%
}
.library-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 16px
}
.library-tab {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  white-space: nowrap;
  padding: 8px 14px;
  font-size: 12px;
  line-height: 1.2
}
.library-tab .count {
  margin-left: 0
}
/* Shared numbered pager and list toolbars (filters + sorting) */
.pager {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  justify-content: center;
  margin: 14px 0 4px
}
.pager button {
  min-width: 34px;
  padding: 6px 10px;
  font-size: 12px
}
.pager .pager-page {
  background: transparent;
  border: 1px solid var(--line);
  border-radius: 7px;
  color: var(--text, inherit)
}
.pager .pager-page.is-current {
  background: var(--accent-bg, rgba(76, 110, 245, .12));
  border-color: var(--accent, #4c6ef5);
  color: var(--accent, #4c6ef5);
  font-weight: 700
}
.pager .pager-gap {
  color: var(--muted);
  padding: 0 2px
}
.pager-total {
  flex-basis: 100%;
  text-align: center;
  font-size: 11px;
  color: var(--muted)
}
.pager button:disabled {
  opacity: .45;
  cursor: default
}
.list-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  padding: 12px 25px;
  border-bottom: 1px solid var(--line)
}
.list-toolbar select,
.list-toolbar input[type=search] {
  font-size: 12px;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--surface, transparent);
  color: inherit;
  max-width: 100%
}
.list-toolbar label {
  display: inline-flex;
  flex-direction: column;
  gap: 3px;
  font-size: 10px;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: var(--muted)
}
.list-toolbar .toolbar-spacer {
  flex: 1
}
.list-toolbar .toolbar-count {
  font-size: 12px;
  color: var(--muted)
}
.shinden-history-players {
  display: flex;
  flex-direction: column;
  gap: 6px;
  margin: 6px 0
}
.shinden-history-player {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center
}
.history-panel-entry .shinden-history-main>button {
  width: auto;
  justify-self: start;
  align-self: flex-start
}
.attention-card {
  margin-bottom: 18px
}
.attention-list {
  display: grid;
  gap: 8px;
  padding: 12px 25px 18px
}
.attention-item {
  display: flex;
  gap: 14px;
  align-items: center;
  border: 1px solid var(--line);
  border-left: 4px solid var(--line);
  border-radius: 10px;
  padding: 10px 14px
}
.attention-item.is-error {
  border-left-color: #c0392b
}
.attention-item.is-warn {
  border-left-color: #c58d37
}
.attention-item.is-info {
  border-left-color: var(--accent, #4c6ef5)
}
.attention-text {
  flex: 1;
  min-width: 0;
  display: grid;
  gap: 2px
}
.attention-text strong {
  font-size: 13px
}
.attention-item .scan-status {
  flex: none
}
@media (max-width:640px) {
  .attention-item {
    flex-wrap: wrap
  }
  .attention-list {
    padding: 10px 14px 14px
  }
}
.notify-form {
  display: grid;
  gap: 12px;
  padding: 14px 25px 20px
}
.notify-form label {
  display: grid;
  gap: 4px;
  font-size: 12px
}
.notify-form input:not([type=checkbox]) {
  padding: 9px 10px;
  border: 1px solid var(--line);
  border-radius: 7px;
  background: var(--surface, transparent);
  color: inherit
}
.notify-form fieldset {
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 10px 14px;
  display: grid;
  gap: 6px
}
.notify-form legend {
  font-size: 11px;
  color: var(--muted);
  padding: 0 6px
}
#notify-settings .section-head {
  align-items: flex-start
}
/* UX-05: whole tiles are tinted by their state (not just their border), dropdowns follow the dark theme, attention entries are clickable. */
select option,
select optgroup {
  background-color: #fff;
  color: #18202c
}
.theme-dark select option,
.theme-dark select optgroup {
  background-color: #1c1f24;
  color: #f3f4f6
}
.theme-dark select:disabled,
.theme-dark option:disabled {
  color: #7d838c
}
.list-toolbar select,
.list-toolbar input[type=search],
.list-toolbar input:not([type=checkbox]) {
  background-color: var(--surface, #fff)
}
.theme-dark .list-toolbar select,
.theme-dark .list-toolbar input:not([type=checkbox]) {
  background-color: #151619;
  color: #f3f4f6;
  border-color: #45484e
}
.list-toolbar select {
  color-scheme: light
}
.theme-dark .list-toolbar select {
  color-scheme: dark
}
#file-list .file {
  border-radius: 14px;
  padding: 16px 18px;
  margin: 0 0 14px;
  border: 1px solid var(--line);
  background: var(--surface, #fff);
  transition: background .2s, border-color .2s
}
#file-list .file.shinden-file-success {
  background: linear-gradient(135deg, rgba(58, 152, 109, .16), rgba(58, 152, 109, .06));
  border-color: rgba(58, 152, 109, .55);
  box-shadow: none
}
#file-list .file.shinden-file-partial,
#file-list .file.shinden-file-pending {
  background: linear-gradient(135deg, rgba(189, 135, 55, .18), rgba(189, 135, 55, .06));
  border-color: rgba(189, 135, 55, .55);
  box-shadow: none
}
#file-list .file.shinden-file-error {
  background: linear-gradient(135deg, rgba(201, 83, 83, .2), rgba(201, 83, 83, .07));
  border-color: rgba(201, 83, 83, .6);
  box-shadow: none
}
.theme-dark #file-list .file.shinden-file-success {
  background: linear-gradient(135deg, rgba(85, 196, 155, .2), rgba(85, 196, 155, .07));
  border-color: rgba(85, 196, 155, .5)
}
.theme-dark #file-list .file.shinden-file-partial,
.theme-dark #file-list .file.shinden-file-pending {
  background: linear-gradient(135deg, rgba(240, 195, 110, .2), rgba(240, 195, 110, .07));
  border-color: rgba(240, 195, 110, .5)
}
.theme-dark #file-list .file.shinden-file-error {
  background: linear-gradient(135deg, rgba(255, 120, 115, .22), rgba(255, 120, 115, .08));
  border-color: rgba(255, 120, 115, .55)
}
#file-list .file-publication-status {
  border: 0;
  border-radius: 999px;
  display: inline-block;
  padding: 4px 11px;
  background: rgba(120, 130, 150, .16)
}
#file-list .file-publication-status[data-state=success] {
  background: rgba(58, 152, 109, .2)
}
#file-list .file-publication-status[data-state=partial],
#file-list .file-publication-status[data-state=pending] {
  background: rgba(189, 135, 55, .22)
}
#file-list .file-publication-status[data-state=error] {
  background: rgba(201, 83, 83, .22)
}
#file-list .job {
  border: 0;
  border-radius: 11px;
  background: rgba(120, 130, 150, .1)
}
#file-list .job.shinden-link-success {
  background: rgba(58, 152, 109, .16)
}
#file-list .job.shinden-link-pending {
  background: rgba(189, 135, 55, .18)
}
#file-list .job.shinden-link-error {
  background: rgba(201, 83, 83, .2)
}
.theme-dark #file-list .job {
  background: rgba(255, 255, 255, .05)
}
.theme-dark #file-list .job.shinden-link-success {
  background: rgba(85, 196, 155, .16)
}
.theme-dark #file-list .job.shinden-link-pending {
  background: rgba(240, 195, 110, .16)
}
.theme-dark #file-list .job.shinden-link-error {
  background: rgba(255, 120, 115, .18)
}
.shinden-history-item {
  border-radius: 14px;
  border: 1px solid var(--line)
}
.shinden-history-item.history-panel-entry.tone-ready {
  background: linear-gradient(135deg, rgba(58, 152, 109, .15), rgba(58, 152, 109, .05));
  border-color: rgba(58, 152, 109, .5);
  box-shadow: none
}
.shinden-history-item.history-panel-entry.tone-failed {
  background: linear-gradient(135deg, rgba(201, 83, 83, .2), rgba(201, 83, 83, .07));
  border-color: rgba(201, 83, 83, .55);
  box-shadow: none
}
.shinden-history-item.history-panel-entry.tone-processing {
  background: linear-gradient(135deg, rgba(189, 135, 55, .17), rgba(189, 135, 55, .06));
  border-color: rgba(189, 135, 55, .5);
  box-shadow: none
}
.shinden-history-item.history-shinden-entry {
  background: rgba(120, 130, 150, .08)
}
.theme-dark .shinden-history-item.history-panel-entry.tone-ready {
  background: linear-gradient(135deg, rgba(85, 196, 155, .2), rgba(85, 196, 155, .06));
  border-color: rgba(85, 196, 155, .45)
}
.theme-dark .shinden-history-item.history-panel-entry.tone-failed {
  background: linear-gradient(135deg, rgba(255, 120, 115, .22), rgba(255, 120, 115, .07));
  border-color: rgba(255, 120, 115, .5)
}
.theme-dark .shinden-history-item.history-panel-entry.tone-processing {
  background: linear-gradient(135deg, rgba(240, 195, 110, .2), rgba(240, 195, 110, .06));
  border-color: rgba(240, 195, 110, .45)
}
.theme-dark .shinden-history-item.history-shinden-entry {
  background: rgba(255, 255, 255, .04)
}
.attention-entries {
  list-style: none;
  margin: 8px 0 0;
  padding: 0;
  display: grid;
  gap: 5px
}
.attention-entry {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 12px;
  align-items: baseline;
  width: 100%;
  text-align: left;
  padding: 7px 11px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(120, 130, 150, .08);
  color: inherit;
  cursor: pointer;
  font: inherit
}
.attention-entry:hover:not(:disabled) {
  border-color: var(--accent, #4c6ef5);
  background: var(--accent-bg, rgba(76, 110, 245, .12))
}
.attention-entry:disabled {
  cursor: default;
  opacity: .7
}
.attention-entry span {
  font-weight: 650;
  font-size: 12px
}
.attention-entry small {
  color: var(--muted);
  font-size: 11px
}
/* Shinden history: the decision buttons of one entry sit in one row and wrap on narrow screens. */
.history-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px
}
.history-actions>button {
  width: auto;
  margin: 0
}
/* Daily summary settings: switch, hour and "send now" in one row; the preview shows the exact message. */
.notify-summary {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px
}
.notify-summary>p {
  flex: 1 1 100%;
  margin: 0
}
.notify-summary select {
  width: auto
}
.notify-summary-preview {
  flex: 1 1 100%;
  margin: 4px 0 0;
  padding: 12px;
  border: 1px solid var(--line);
  border-radius: 8px;
  white-space: pre-wrap;
  font: 12px/1.6 inherit;
  font-family: inherit
}
/* Statistics view. Single-series bars in the accent colour; text stays in ink colours, values live in tooltips and tables. */
.stats-periods {
  display: flex;
  gap: 6px;
  margin: 0 0 16px;
  flex-wrap: wrap
}
.stats-periods button {
  padding: 8px 14px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: transparent;
  color: var(--muted);
  font-weight: 650
}
.stats-periods button.active {
  border-color: var(--accent);
  color: var(--accent);
  background: var(--accent-bg)
}
.stat-tiles {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 12px;
  margin-bottom: 16px
}
.stat-tile {
  display: grid;
  gap: 6px;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface, #fff)
}
.stat-tile .stat-label {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .04em;
  text-transform: uppercase;
  color: var(--muted)
}
.stat-tile strong {
  font-size: 24px;
  color: var(--ink)
}
.stat-tile small {
  color: var(--muted)
}
.stat-tile.is-warn {
  border-left: 4px solid #c58d37
}
.stats-published {
  margin: 0 0 16px;
  padding: 10px 14px;
  border: 1px solid var(--line);
  border-radius: 10px
}
.stats-published summary,
.stats-daily summary {
  cursor: pointer;
  font-weight: 650
}
.stats-charts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
  gap: 12px;
  margin-bottom: 16px
}
.stats-chart {
  margin: 0;
  padding: 16px;
  border: 1px solid var(--line);
  border-radius: 12px;
  background: var(--surface, #fff)
}
.stats-chart figcaption {
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--ink)
}
.stats-bars {
  display: flex;
  align-items: flex-end;
  gap: 2px;
  height: 140px;
  border-bottom: 1px solid var(--line)
}
.stats-bar {
  position: relative;
  flex: 1 1 0;
  height: 100%;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  outline: none
}
.stats-bar span {
  display: block;
  width: min(100%, 22px);
  background: var(--accent);
  border-radius: 4px 4px 0 0
}
.stats-bar b {
  position: absolute;
  top: -2px;
  font-size: 11px;
  color: var(--ink)
}
.stats-bar:hover span,
.stats-bar:focus-visible span {
  filter: brightness(1.2)
}
.stats-bar:hover::after,
.stats-bar:focus-visible::after {
  content: attr(data-tip);
  position: absolute;
  bottom: calc(100% + 4px);
  left: 50%;
  transform: translateX(-50%);
  z-index: 3;
  padding: 4px 8px;
  border-radius: 6px;
  background: var(--ink);
  color: var(--bg);
  font-size: 11px;
  white-space: nowrap;
  pointer-events: none
}
.stats-axis {
  display: flex;
  justify-content: space-between;
  margin-top: 6px;
  font-size: 11px;
  color: var(--muted)
}
.stats-hosts {
  margin-bottom: 16px
}
.stats-table-wrap {
  overflow-x: auto
}
.stats-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px
}
.stats-table th,
.stats-table td {
  padding: 9px 14px;
  border-top: 1px solid var(--line);
  text-align: left
}
.stats-table thead th {
  border-top: 0;
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: .04em;
  color: var(--muted)
}
.stats-table td {
  font-variant-numeric: tabular-nums
}
.stats-rate.is-warn {
  color: #b17819;
  font-weight: 700
}
.stats-daily {
  margin-bottom: 16px
}

/* Player sources ("Źródła"): one card per site, status colour on the left edge, reviewable checks inside. */
.source-totals,
.source-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin: 0 0 14px
}
.source-chip {
  padding: 3px 10px;
  border: 1px solid var(--line);
  border-radius: 999px;
  font-size: 12px;
  color: var(--muted)
}
.source-chip.is-ok {
  color: #2f8f62
}
.source-chip.is-warn {
  color: #b17819
}
.source-chip.is-error {
  color: #c94343
}
.source-list {
  display: grid;
  gap: 12px
}
.source-site {
  padding: 16px 18px;
  border: 1px solid var(--line);
  border-left: 4px solid var(--line);
  border-radius: 12px;
  background: var(--surface, #fff)
}
.source-site.is-ok {
  border-left-color: #3a986d
}
.source-site.is-warn {
  border-left-color: #c58d37
}
.source-site.is-error {
  border-left-color: #c95353
}
.source-site-head {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 10px
}
.source-site-head h2 {
  margin: 0 0 4px;
  font-size: 16px
}
.source-status {
  margin: 0 0 4px
}
.source-site-actions {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap
}
.source-site-actions select {
  width: auto
}
.source-details>summary {
  cursor: pointer;
  font-weight: 650;
  margin: 4px 0 10px
}
.source-sample {
  display: flex;
  align-items: center;
  gap: 8px;
  margin: 0 0 8px;
  flex-wrap: wrap;
  font-size: 12px;
  color: var(--muted)
}
.source-sample input {
  flex: 1 1 280px;
  min-width: 0
}
.source-check {
  margin: 10px 0 0;
  padding: 10px 12px;
  border: 1px solid var(--line);
  border-radius: 10px
}
.source-check-head {
  display: flex;
  gap: 10px;
  align-items: baseline;
  flex-wrap: wrap
}
.source-verdict {
  font-size: 11px;
  font-weight: 700;
  color: var(--muted)
}
.source-verdict.is-ok {
  color: #2f8f62
}
.source-verdict.is-error {
  color: #c94343
}
.source-log {
  margin: 6px 0;
  padding: 10px;
  border-radius: 8px;
  background: var(--bg);
  white-space: pre-wrap;
  overflow-wrap: anywhere;
  font: 12px/1.6 ui-monospace, Consolas, monospace
}
.source-review {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-top: 8px
}
.source-review input {
  flex: 1 1 240px;
  min-width: 0
}
.source-review button {
  width: auto
}
.danger-text {
  color: #c94343
}
