/* NomadLouie TV — Retroma colors, Soap2Day-style compact layout, Tahoma */
:root {
  --bg: #070a1c;
  --bg-panel: #0b0f24;
  --bg-header: #080c20;
  --bg-nav: #0a0e22;
  --bg-table: #10162e;
  --border: #3b4fd8;
  --border-bright: #4a5cff;
  --glow: 0 0 8px rgba(59, 79, 216, 0.45);
  --coral: #ff7b72;
  --coral-dim: #e8746a;
  --gold: #e6c84a;
  --yellow: #d8cf4a;
  --orange: #e8a23c;
  --teal: #2ee6a6;
  --teal-dim: #3fd0b0;
  --text: #c9d1e6;
  --muted: #8b93b0;
  --danger: #ff6b6b;
  --radius: 8px;
  --font: Tahoma, Verdana, "Segoe UI", sans-serif;
  --site-width-px: 1180px;
  --site-width-pct: 100%;
  --site-width: min(var(--site-width-pct), var(--site-width-px));
  --site-gutter: 10px;
  --site-side: max(var(--site-gutter), calc((100% - var(--site-width)) / 2 + var(--site-gutter)));
  --blog-sidebar-width: 280px;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  background: var(--bg);
  color: var(--text);
  font-family: var(--font);
  font-size: 13px;
  line-height: 1.4;
  min-height: 100vh;
}

a { color: var(--teal); text-decoration: underline; text-underline-offset: 2px; }
a:hover { color: #7ffff0; }
img { max-width: 100%; height: auto; border: 0; }
button, input, select, textarea { font-family: inherit; font-size: 13px; }

/* Header / logo */
.top {
  background: var(--bg-header);
  padding: 0 16px;
  border-bottom: 1px solid transparent;
  display: flex;
  align-items: center;
  line-height: 0;
}
.logo {
  font-size: 28px;
  font-weight: bold;
  color: var(--teal-dim);
  text-decoration: none;
  letter-spacing: 0.5px;
  text-shadow: 0 0 12px rgba(63, 208, 176, 0.35);
}
.logo:hover { color: var(--teal); text-decoration: none; }
.logo span { color: var(--gold); }

/* Nav */
.nav {
  background: var(--bg-nav);
  border-top: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  box-shadow: var(--glow);
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 12px;
  flex-wrap: wrap;
}
.nav-links { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; flex: 1; }
.nav-links a, .nav-links .drop > span {
  color: var(--text);
  text-decoration: none;
  padding: 4px 10px;
  border: 1px solid var(--teal);
  border-radius: 10px;
  display: inline-block;
}
.nav-links a:hover, .nav-links .drop:hover > span { color: var(--teal); background: rgba(59,79,216,0.15); border-color: var(--teal); }
.nav-links a.active { color: var(--gold); border-color: var(--teal); }
.nav-links a.nav-wiki {
  border-color: var(--teal);
}

.drop { position: relative; }
.drop > span { cursor: default; }
.drop-menu {
  display: none;
  position: absolute;
  left: 0; top: 100%;
  z-index: 40;
  background: var(--bg-panel);
  border: 1px solid var(--border-bright);
  border-radius: var(--radius);
  box-shadow: var(--glow);
  min-width: 160px;
  padding: 6px 0;
  max-height: 320px;
  overflow: auto;
}
.drop:hover .drop-menu, .drop:focus-within .drop-menu { display: block; }
.drop-menu a {
  display: block;
  padding: 4px 12px;
  color: var(--text);
  text-decoration: none;
  white-space: nowrap;
}
.drop-menu a:hover { background: rgba(59,79,216,0.2); color: var(--teal); }

.search-form {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-left: auto;
}
.search-form input[type="text"] {
  background: #070a1c;
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 4px 8px;
  width: 180px;
  outline: none;
}
.search-form input[type="text"]:focus { border-color: var(--border-bright); box-shadow: var(--glow); }
.btn {
  display: inline-block;
  background: var(--bg-panel);
  color: var(--text);
  border: 1px solid var(--border-bright);
  border-radius: 5px;
  padding: 4px 10px;
  cursor: pointer;
  text-decoration: none;
  box-shadow: var(--glow);
  line-height: 1.3;
}
.btn:hover { color: var(--teal); text-decoration: none; }
.btn-primary { border-color: var(--teal-dim); color: var(--teal); }
.btn-danger { border-color: var(--coral-dim); color: var(--coral); }
.btn-gold { border-color: var(--gold); color: var(--gold); }
.icon-btn {
  width: 28px; height: 28px;
  padding: 0;
  border-radius: 6px;
  text-align: center;
  line-height: 26px;
  font-size: 13px;
}

.nav-right { display: flex; align-items: center; gap: 8px; margin-left: 8px; }
.nav-right a.login-link { color: var(--gold); text-decoration: none; padding: 4px 8px; }
.nav-right a.login-link:hover { color: var(--teal); }
.nav-util { display: flex; align-items: center; gap: 8px; margin-left: auto; flex: 0 1 auto; min-width: 0; }
.nav-auth { display: flex; align-items: center; gap: 6px; flex: 0 0 auto; }
.nav-logout { display: inline; margin: 0; }
.btn-auth, a.btn-auth, .nav-auth .btn-auth {
  border-color: #d4a94a;
  color: #d4a94a;
  box-shadow: none;
}
.btn-auth:hover, a.btn-auth:hover, .nav-auth .btn-auth:hover { color: var(--teal); border-color: var(--teal); }
/* v91: single Admin shortcut in the auth cluster (public pages). Old wrapping .nav-admin row is gone. */
.nav-auth .btn-admin, a.btn-auth.btn-admin {
  border-color: #3b4fd8;
  color: #9db0ff;
  box-shadow: none;
}
.nav-auth .btn-admin:hover, a.btn-auth.btn-admin:hover { color: var(--teal); border-color: var(--teal); }
.nav-admin { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.nav-admin .btn { border-color: #3b4fd8; color: #9db0ff; }
.nav-admin .btn:hover { color: var(--teal); }

/* Breadcrumb */
.crumb {
  background: #080c1e;
  border-bottom: 1px solid rgba(59,79,216,0.45);
  padding: 4px var(--site-side);
  color: var(--muted);
  font-size: 12px;
}
.crumb b { color: var(--gold); font-weight: normal; }

/* Layout */
.wrap { max-width: var(--site-width); margin: 0 auto; padding: 10px var(--site-gutter) 24px; }
.layout { display: flex; gap: 10px; align-items: flex-start; }
.panel {
  background: var(--bg-panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  box-shadow: var(--glow);
  padding: 10px 12px 14px;
}
main.panel { flex: 1; min-width: 0; }
.side-stack { width: var(--blog-sidebar-width); flex: 0 0 var(--blog-sidebar-width); display: flex; flex-direction: column; gap: 10px; }

.cat-chips { display: flex; flex-wrap: wrap; gap: 6px; margin: 0 0 6px; min-height: 0; }
.cat-chips .chip { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border: 1px solid var(--border); border-radius: 10px; font-size: 13px; background: rgba(127,127,127,0.08); }
.cat-chips .chip button { border: 0; background: transparent; color: var(--muted); cursor: pointer; padding: 0 0 0 2px; font-size: 14px; line-height: 1; }
.cat-chips .chip button:hover { color: var(--coral); }
.admin-table .prod-cell { text-align: center; width: 5.5em; }

aside.panel { width: 100%; padding: 8px 10px 12px; }

h1, h2, h3 { margin: 0 0 8px; font-weight: bold; }
h1, .panel-title, main.panel > h2 { color: var(--coral); font-size: 16px; }
h3, .subhead { color: var(--gold); font-size: 13px; }
.muted { color: var(--muted); }

/* Filters */
.filters {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px 14px;
  margin: 0 0 10px;
  padding: 7px 8px;
  border: 1px solid var(--coral-dim);
  border-radius: 6px;
  background: rgba(232, 116, 106, 0.05);
  font-size: 12px;
}
.filters label { color: var(--muted); }
.filters select {
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 2px 4px;
}
.sorts { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; margin-left: auto; }
.sorts .lbl { color: var(--muted); margin-right: 2px; }
.pill {
  display: inline-block;
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 1px 8px;
  color: var(--text);
  text-decoration: none;
  font-size: 12px;
}
.pill:hover { color: var(--teal); text-decoration: none; border-color: var(--teal-dim); }
.pill.active {
  border-color: var(--gold);
  color: var(--gold);
  background: rgba(230, 200, 74, 0.08);
  box-shadow: 0 0 6px rgba(230, 200, 74, 0.25);
}

/* Poster grid */
.grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 10px 8px;
}
.card { text-decoration: none; color: var(--text); display: block; }
.card:hover { text-decoration: none; color: var(--teal); }
.card .poster-wrap { position: relative; }
.card .poster {
  aspect-ratio: 2 / 3;
  background: #080c1e;
  border: 1px solid var(--border);
  border-radius: 6px;
  overflow: hidden;
  box-shadow: var(--glow);
}
.card .poster img, .card .poster .ph {
  width: 100%; height: 100%; object-fit: cover; display: block;
}
.card .poster .ph {
  display: flex; align-items: center; justify-content: center;
  color: var(--gold); font-size: 22px; font-weight: bold;
  background: linear-gradient(160deg, #12183a 0%, #070a1c 100%);
}
.card .year {
  position: absolute;
  top: 5px; right: 5px;
  background: #070a1c;
  border: 1px solid var(--border-bright);
  color: var(--gold);
  font-size: 11px;
  padding: 0 5px;
  border-radius: 8px;
  line-height: 16px;
}
.card .ctitle {
  text-align: center;
  font-size: 12px;
  margin-top: 5px;
  line-height: 1.25;
  max-height: 2.5em;
  overflow: hidden;
}
.card:hover .poster { border-color: var(--teal-dim); }

.empty {
  padding: 18px 8px;
  text-align: center;
  color: var(--muted);
  border: 1px dashed var(--border);
  border-radius: 6px;
}

/* Pagination */
.pages { margin-top: 12px; text-align: center; }
.pages a, .pages span {
  display: inline-block;
  min-width: 22px;
  padding: 2px 6px;
  margin: 0 2px;
  border: 1px solid var(--border);
  border-radius: 4px;
  text-decoration: none;
  color: var(--text);
}
.pages a:hover { color: var(--teal); }
.pages .here { color: var(--gold); border-color: var(--gold); }

/* Sidebar */
aside.panel h2 { color: var(--coral); font-size: 14px; margin-bottom: 8px; }
.side-sub { color: var(--gold); font-size: 11px; margin: -6px 0 8px; }
.fav-panel { border-color: var(--coral-dim); box-shadow: 0 0 8px rgba(255,123,114,0.28); }
.fav-panel h2 { color: var(--coral); }
.fav-panel h3 { color: var(--gold); font-size: 12px; margin: 8px 0 4px; padding-bottom: 3px; border-bottom: 1px solid var(--orange); }
.fav-list { list-style: none; margin: 0; padding: 0; }
.fav-list li { margin: 0 0 4px; }
.fav-list a { display: flex; align-items: center; gap: 6px; text-decoration: none; color: var(--teal-dim); font-size: 12px; line-height: 1.25; }
.fav-list a:hover { color: var(--teal); text-decoration: underline; }
.fav-list img { width: 22px; height: 33px; object-fit: cover; border: 1px solid var(--border); border-radius: 3px; flex: 0 0 22px; }
.fav-all { margin: 8px 0 0; font-size: 12px; }
.side-cols { display: flex; gap: 8px; }
.side-col { flex: 1; min-width: 0; }
.side-col h3 {
  color: var(--gold);
  font-size: 12px;
  margin: 0 0 6px;
  padding-bottom: 3px;
  border-bottom: 1px solid var(--orange);
}
.side-col ol, .side-col ul { margin: 0; padding: 0 0 0 16px; }
.side-col li { margin: 0 0 4px; line-height: 1.25; }
.side-col a { font-size: 12px; text-decoration: none; color: var(--teal-dim); }
.side-col a:hover { text-decoration: underline; color: var(--teal); }
.side-col .yr { color: var(--muted); font-size: 11px; }

/* Video page */
.player-box {
  background: #000;
  border: 1px solid var(--border);
  border-radius: 6px;
  overflow: hidden;
  box-shadow: var(--glow);
  margin-bottom: 10px;
}
.player-box video, .player-box iframe {
  width: 100%;
  display: block;
  aspect-ratio: 16 / 9;
  background: #000;
  border: 0;
}
.meta { margin: 0 0 10px; color: var(--muted); font-size: 12px; }
.meta a { text-decoration: none; }
.desc {
  border: 1px solid var(--yellow);
  border-radius: 6px;
  padding: 8px 10px;
  margin: 8px 0 12px;
  white-space: pre-wrap;
}
.desc.foldable {
  white-space: normal;
  min-height: 0;
}
.desc .fold-text {
  margin: 0;
  padding: 0;
  white-space: pre-wrap;
  overflow: hidden;
}
.desc.foldable.is-clamped:not(.is-open) .fold-text {
  display: block;
  max-height: calc(1.4em * 6);
  overflow: hidden;
  min-height: 0;
  -webkit-box-pack: start;
}
.fold-toggle {
  display: inline-block;
  margin-top: 6px;
  padding: 0;
  border: 0;
  background: none;
  color: var(--teal);
  cursor: pointer;
  font-size: 12px;
}
.fold-toggle[hidden] { display: none !important; }
.fold-toggle:hover { color: #7ffff0; }
.fav-form { margin: 0 0 8px; }
.fav-btn {
  background: transparent;
  color: var(--gold);
  border: 1px solid var(--gold);
  border-radius: 5px;
  padding: 2px 8px;
  font-size: 12px;
  cursor: pointer;
}
.fav-btn.on { background: rgba(230,200,74,0.12); box-shadow: 0 0 6px rgba(230,200,74,0.25); }
.fav-btn:hover { color: #ffe37a; }
.tags { display: flex; flex-wrap: wrap; gap: 4px; margin: 6px 0; }
.tag {
  border: 1px solid var(--border-bright);
  border-radius: 10px;
  padding: 0 8px;
  font-size: 11px;
  color: var(--teal);
  text-decoration: none;
}
.tag:hover { border-color: var(--teal); text-decoration: none; }

.related { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; }

/* Series seasons */
.season {
  border: 1px solid var(--orange);
  border-radius: 6px;
  padding: 8px 10px;
  margin-bottom: 10px;
}
.season h3 { margin-bottom: 6px; }
.ep-list { width: 100%; border-collapse: collapse; }
.ep-list th {
  text-align: left;
  background: var(--bg-table);
  color: var(--gold);
  font-weight: normal;
  padding: 4px 6px;
  border-bottom: 1px solid var(--border);
}
.ep-list td { padding: 4px 6px; border-bottom: 1px solid rgba(59,79,216,0.25); }
.ep-list tr:hover td { background: rgba(59,79,216,0.1); }

/* Forms / admin */
.form-grid { display: grid; grid-template-columns: 140px 1fr; gap: 7px 10px; align-items: start; }
.form-grid label { padding-top: 4px; color: var(--muted); }
.form-grid .full { grid-column: 1 / -1; }
input[type="text"], input[type="password"], input[type="number"], input[type="url"], input[type="email"],
input[type="file"], select, textarea {
  background: #070a1c;
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 5px 8px;
  width: 100%;
  outline: none;
}
textarea { min-height: 90px; resize: vertical; }
input:focus, select:focus, textarea:focus {
  border-color: var(--border-bright);
  box-shadow: var(--glow);
}
.checks { display: flex; flex-wrap: wrap; gap: 6px 12px; }
.checks label { color: var(--text); padding-top: 0; }
.row-actions { margin-top: 12px; display: flex; gap: 8px; flex-wrap: wrap; }
.error {
  border: 1px solid var(--coral-dim);
  background: rgba(232, 116, 106, 0.08);
  color: var(--coral);
  padding: 8px 10px;
  border-radius: 6px;
  margin: 0 0 10px;
}
.ok {
  border: 1px solid var(--teal-dim);
  background: rgba(46, 230, 166, 0.08);
  color: var(--teal);
  padding: 8px 10px;
  border-radius: 6px;
  margin: 0 0 10px;
}
.login-box { max-width: 360px; margin: 24px auto; }
.login-box h2 { text-align: center; }
.admin-table { width: 100%; border-collapse: collapse; }
.admin-table th {
  text-align: left;
  background: var(--bg-table);
  color: var(--gold);
  font-weight: normal;
  padding: 5px 6px;
  border-bottom: 1px solid var(--border);
}
.admin-table td { padding: 5px 6px; border-bottom: 1px solid rgba(59,79,216,0.25); vertical-align: middle; }
.admin-bar { display: flex; flex-wrap: wrap; gap: 8px; margin: 0 0 12px; }
.progress {
  height: 8px;
  background: #070a1c;
  border: 1px solid var(--border);
  border-radius: 6px;
  overflow: hidden;
  margin-top: 6px;
  display: none;
}
.progress > span { display: block; height: 100%; width: 0; background: var(--teal); }

footer.site {
  text-align: center;
  color: var(--muted);
  font-size: 11px;
  padding: 8px var(--site-side) 16px;
}
footer.site .tmdb-home-attr {
  display: block;
  margin: 0 0 8px;
  color: var(--muted);
  font-size: 11px;
}
footer.site .site-links { display: block; }
footer.site .site-links a { color: var(--teal); text-decoration: none; }
footer.site .site-links a:hover { color: #7ffff0; text-decoration: underline; }
footer.site .foot-sep { color: var(--muted); }

@media (max-width: 1000px) {
  .grid { grid-template-columns: repeat(4, 1fr); }
  .related { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 800px) {
  .layout { display: block; }
  .side-stack, aside.panel { width: auto; flex: none; margin-top: 10px; }
  .grid { grid-template-columns: repeat(3, 1fr); }
  .search-form { margin-left: 0; width: 100%; }
  .search-form input[type="text"] { flex: 1; width: auto; }
  .form-grid { grid-template-columns: 1fr; }
  .logo { font-size: 22px; }
  .related { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 480px) {
  .grid { grid-template-columns: repeat(2, 1fr); }
  .nav { padding: 6px; }
}

/* TMDb catalog additions */
.section-head { margin-top: 16px; }
.watch-badge {
  position: absolute;
  left: 5px; bottom: 5px;
  background: #07140f;
  border: 1px solid var(--teal);
  color: var(--teal);
  font-size: 10px;
  padding: 1px 6px;
  border-radius: 8px;
  letter-spacing: 0.02em;
  box-shadow: 0 0 6px rgba(46,230,166,0.35);
}
.btn-watch {
  display: inline-block;
  background: #0b1c18;
  color: var(--teal);
  border: 1px solid var(--teal);
  border-radius: 6px;
  padding: 7px 16px;
  text-decoration: none;
  font-weight: bold;
  letter-spacing: 0.03em;
  box-shadow: 0 0 10px rgba(46,230,166,0.35);
  margin: 8px 0;
}
.btn-watch:hover { color: #7ffff0; text-decoration: none; }
.btn-watch-sm { padding: 2px 8px; font-size: 11px; margin: 0 0 0 8px; font-weight: normal; }
.lib-toggle { color: var(--muted); display: flex; align-items: center; gap: 4px; }

.title-hero { position: relative; margin: -10px -12px 12px; padding: 12px; overflow: visible; border-radius: var(--radius) var(--radius) 0 0; }
.backdrop {
  position: absolute; inset: 0;
  background-size: cover; background-position: center top;
  opacity: 0.28; filter: saturate(0.9);
  pointer-events: none;
  overflow: hidden;
  border-radius: var(--radius) var(--radius) 0 0;
}
.backdrop::after {
  content: ""; position: absolute; inset: 0;
  background: linear-gradient(180deg, rgba(11,15,36,0.2), var(--bg-panel) 90%);
}
.title-row {
  position: relative;
  display: flex;
  gap: 12px;
  align-items: stretch;
  flex-wrap: nowrap;
}
.title-poster { flex: 0 0 92px; width: 92px; }
.title-poster img, .title-poster .ph {
  width: 92px; aspect-ratio: 2/3; object-fit: cover; display: block;
  border: 1px solid var(--border); border-radius: 6px; box-shadow: var(--glow);
}
.title-poster .ph {
  display: flex; align-items: center; justify-content: center;
  text-align: center; font-size: 10px; color: var(--gold);
  background: linear-gradient(160deg, #12183a 0%, #070a1c 100%);
  overflow: hidden; padding: 4px;
  height: auto;
}
.title-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
  align-items: flex-start;
  gap: 4px;
}
.title-heading {
  display: flex;
  align-items: flex-start;
  gap: 8px;
  width: 100%;
}
.title-info h2 {
  color: var(--coral);
  font-size: clamp(13px, 1.5vw, 18px);
  line-height: 1.2;
  margin: 0;
  flex: 1;
  min-width: 0;
  overflow-wrap: break-word;
}
.title-info .meta { margin: 0; }
.title-info .tags { margin: 0; }
.title-info .fav-form { margin: 0; flex: 0 0 auto; }
.title-info .title-watch { margin: 0; }
.title-info .btn-watch { margin: 0; padding: 4px 10px; font-size: 12px; }

.card .csub {
  text-align: center;
  font-size: 11px;
  color: var(--muted);
  margin-top: 2px;
  line-height: 1.25;
  max-height: 2.5em;
  overflow: hidden;
}
.cast-more, .bio-more { margin: 8px 0 12px; }
.cast-more > summary, .bio-more > summary {
  cursor: pointer;
  color: var(--teal);
  font-size: 12px;
  list-style: none;
}
.cast-more > summary::-webkit-details-marker,
.bio-more > summary::-webkit-details-marker { display: none; }
.cast-more .grid { margin-top: 8px; }

.person-photo { flex: 0 0 120px; width: 120px; }
.person-photo img, .person-photo .ph {
  width: 120px; aspect-ratio: 2/3; object-fit: cover; display: block;
  border: 1px solid var(--border); border-radius: 6px; box-shadow: var(--glow);
}
.person-photo .ph {
  display: flex; align-items: center; justify-content: center;
  text-align: center; font-size: 14px; color: var(--gold);
  background: linear-gradient(160deg, #12183a 0%, #070a1c 100%);
  overflow: hidden; padding: 6px;
}
.person-hero { margin-bottom: 8px; }

.ep-row { display: flex; gap: 10px; padding: 7px 0; border-bottom: 1px solid rgba(59,79,216,0.25); }
.ep-still { width: 120px; height: 68px; object-fit: cover; border: 1px solid var(--border); border-radius: 4px; flex: 0 0 120px; }
.ep-body { flex: 1; min-width: 0; }

.tmdb-attr { display: block; margin-top: 6px; color: var(--muted); }
.tmdb-logo { height: 14px; vertical-align: middle; margin-right: 6px; }

.tmdb-box {
  border: 1px solid var(--orange);
  border-radius: 6px;
  padding: 8px 10px;
  margin: 0 0 12px;
}
.tmdb-results { margin-top: 8px; }
.tmdb-hit {
  display: flex; gap: 8px; align-items: flex-start;
  padding: 6px; border-bottom: 1px solid rgba(59,79,216,0.25);
  cursor: pointer; text-align: left; width: 100%;
  background: transparent; color: inherit; border-left: 0; border-right: 0; border-top: 0;
  border-radius: 0;
}
.tmdb-hit:hover { background: rgba(59,79,216,0.15); }
.tmdb-hit img { width: 40px; height: 60px; object-fit: cover; border-radius: 3px; border: 1px solid var(--border); }
.tmdb-hit .meta { font-size: 11px; }

@media (max-width: 800px) {
  .title-row { flex-direction: row; flex-wrap: nowrap; align-items: stretch; gap: 10px; }
  .title-poster, .title-poster img, .title-poster .ph { width: 110px; flex: 0 0 110px; }
  .person-photo, .person-photo img, .person-photo .ph { width: 110px; flex: 0 0 110px; }
  .title-info h2 { font-size: 15px; }
  .ep-still { width: 96px; height: 54px; flex-basis: 96px; }
}

.user-create { max-width: 420px; margin-bottom: 16px; }
.user-create input[type="text"], .user-create input[type="password"],
.account-box input[type="text"], .account-box input[type="password"],
.login-box input[type="text"], .login-box input[type="password"], .login-box input[type="email"] {
  width: 100%;
  max-width: 320px;
  background: #070a1c;
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 4px 8px;
}
.signup-box { max-width: 440px; }
.signup-box .hp, .login-box .hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.signup-code { font-size: 26px; letter-spacing: .14em; font-weight: bold; color: var(--teal); background: #10162e; border: 1px dashed var(--border); border-radius: 10px; padding: 14px 16px; text-align: center; margin: 12px 0; }
.signup-wait { color: var(--muted); }
.signup-ok { color: var(--teal); font-weight: bold; }
.admin-table-wrap { overflow-x: auto; }


.pill.processing {
  background: #3a3420;
  color: #e8d48b;
  border: 1px solid #6a5a20;
}
.pill.warn {
  background: #3a2a18;
  color: #f0b36a;
  border: 1px solid #6a4a18;
}
.pill.danger {
  background: #3a1818;
  color: #f08a8a;
  border: 1px solid #6a2020;
}
.player-note {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 200px;
  padding: 24px 16px;
  text-align: center;
  color: var(--text);
}
.player-note p {
  margin: 8px 0 0;
  max-width: 36em;
  color: var(--muted);
}
.player-note-warn strong { color: #f0b36a; }
.admin-status-msg {
  max-width: 22em;
  font-size: 12px;
  margin-top: 4px;
}


/* Where to Watch (TMDb / JustWatch providers) */
.where-watch {
  margin: 14px 0 16px;
  padding: 12px 14px 10px;
  background: linear-gradient(180deg, rgba(59,79,216,0.10), rgba(11,15,36,0.6));
  border: 1px solid var(--border);
  border-radius: 10px;
  box-shadow: var(--glow);
  max-width: 100%;
  min-width: 0;
}
.ww-head { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; margin-bottom: 8px; }
.ww-title { margin: 0; font-size: 15px; color: var(--gold); font-weight: bold; min-width: 0; }
.ww-title .ww-name { color: var(--text); }
.ww-region {
  flex: none; font-size: 10px; letter-spacing: .06em; color: var(--muted);
  border: 1px solid rgba(139,147,176,0.5); border-radius: 4px; padding: 1px 5px;
}
.watch-row {
  display: flex;
  gap: 8px 12px;
  align-items: flex-start;
  padding: 8px 0;
  border-top: 1px solid rgba(59,79,216,0.25);
}
.watch-row:first-of-type { border-top: 0; }
.watch-label { flex: 0 0 120px; padding-top: 14px; }
.ww-chip {
  display: inline-block; font-size: 11px; font-weight: bold; white-space: nowrap;
  padding: 3px 8px; border-radius: 999px;
  color: var(--teal); background: rgba(46,230,166,0.10); border: 1px solid rgba(46,230,166,0.45);
}
.ww-free_ads .ww-chip { color: var(--gold); background: rgba(230,200,74,0.10); border-color: rgba(230,200,74,0.45); }
.ww-free .ww-chip { color: var(--gold); background: rgba(230,200,74,0.10); border-color: rgba(230,200,74,0.45); }
.ww-rent .ww-chip { color: var(--orange); background: rgba(232,162,60,0.10); border-color: rgba(232,162,60,0.45); }
.ww-buy .ww-chip { color: var(--coral); background: rgba(255,123,114,0.10); border-color: rgba(255,123,114,0.45); }
.ww-chip.ww-net { color: var(--muted); background: rgba(139,147,176,0.08); border-color: rgba(139,147,176,0.4); }
.watch-logos { display: flex; flex-wrap: wrap; gap: 10px 12px; min-width: 0; }
.watch-provider {
  display: inline-flex;
  flex-direction: column;
  align-items: center;
  width: 64px;
  text-decoration: none;
  color: var(--text);
  font-size: 10px;
  text-align: center;
  line-height: 1.2;
}
a.watch-provider:hover { text-decoration: none; }
.ww-logo {
  display: flex; align-items: center; justify-content: center;
  width: 48px; height: 48px; border-radius: 11px; overflow: hidden;
  background: #161c3a; border: 1px solid rgba(74,92,255,0.6);
  transition: transform .12s ease, box-shadow .12s ease, border-color .12s ease;
}
.ww-logo img { width: 100%; height: 100%; object-fit: cover; display: block; }
.ww-logo-net { background: #fff; padding: 5px; }
.ww-logo-net img { object-fit: contain; }
.ww-fallback { font-size: 9px; padding: 2px; color: var(--text); overflow: hidden; }
a.watch-provider:hover .ww-logo, a.watch-provider:focus .ww-logo {
  transform: translateY(-2px); border-color: var(--teal); box-shadow: 0 0 10px rgba(46,230,166,0.45);
}
a.watch-provider:hover .watch-name { color: var(--teal); }
.watch-name {
  display: block;
  margin-top: 4px;
  color: var(--muted);
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  max-width: 64px;
}
.watch-empty {
  margin: 2px 0 4px; padding: 10px 12px; border-radius: 8px;
  background: rgba(139,147,176,0.08); color: var(--muted); font-size: 13px;
}
.ww-empty-icon { color: var(--orange); margin-right: 4px; }
.ww-foot {
  display: flex; justify-content: space-between; align-items: center; gap: 10px; flex-wrap: wrap;
  margin-top: 6px; padding-top: 7px; border-top: 1px solid rgba(59,79,216,0.25);
}
.justwatch-attr { font-size: 11px; color: var(--muted); margin: 0; }
.justwatch-attr a { color: var(--teal-dim); }
.ww-all { font-size: 12px; color: var(--teal); text-decoration: none; white-space: nowrap; }
.ww-all:hover { text-decoration: underline; }
@media (max-width: 480px) {
  .where-watch { padding: 10px 10px 8px; }
  .watch-row { flex-direction: column; gap: 7px; }
  .watch-label { flex: none; padding-top: 0; }
  .watch-logos { gap: 8px 8px; }
  .watch-provider, .watch-name { width: 56px; max-width: 56px; }
  .ww-logo { width: 44px; height: 44px; border-radius: 10px; }
}


/* Traffic + Files */
.traffic-stats {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(140px, 1fr));
  gap: 8px;
  margin: 10px 0 14px;
}
.traffic-stats .stat { margin: 0; text-align: center; }
.traffic-stats .stat strong { display: block; font-size: 22px; color: var(--teal); margin-top: 2px; }
.traffic-cols { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 16px; }
.traffic-ol { margin: 0; padding: 0 0 0 18px; }
.traffic-ol li { margin: 0 0 4px; overflow-wrap: anywhere; }
.traffic-filters input[type="text"], .traffic-filters input[type="date"] {
  background: var(--bg);
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 2px 6px;
  margin-left: 4px;
}
.traffic-filters .chk { color: var(--text); }
.admin-table tr.is-admin td { background: rgba(230, 200, 74, 0.06); }
.ua { font-size: 11px; overflow-wrap: anywhere; }

.file-crumbs { margin: 0 0 10px; font-size: 13px; }
.file-crumbs .sep { color: var(--muted); margin: 0 6px; }
.file-crumbs .here { color: var(--gold); }
.file-table .file-icon.sm {
  display: inline-flex;
  width: 34px; height: 24px;
  align-items: center; justify-content: center;
  font-size: 9px; font-weight: bold;
  border-radius: 4px;
  background: var(--bg-table);
  border: 1px solid var(--border);
  color: var(--gold);
}
.file-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
  gap: 10px;
}
.file-card {
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 10px 8px 8px;
  background: var(--bg-panel);
  min-width: 0;
}
.file-card .file-icon {
  width: 44px; height: 44px;
  display: flex; align-items: center; justify-content: center;
  border-radius: 8px;
  margin: 0 auto 8px;
  font-size: 11px; font-weight: bold;
  color: #fff;
  background: linear-gradient(135deg, var(--border), #1a2150);
}
.file-card.kind-folder .file-icon { background: linear-gradient(135deg, #7c6cff, #3b4fd8); }
.file-card.kind-image .file-icon { background: linear-gradient(135deg, #ec4899, #9d174d); }
.file-card.kind-audio .file-icon { background: linear-gradient(135deg, #7c6cff, #4c1d95); }
.file-card.kind-video .file-icon { background: linear-gradient(135deg, #f97316, #9a3412); }
.file-card.kind-doc .file-icon { background: linear-gradient(135deg, #3ec6ff, #0369a1); }
.file-card.kind-archive .file-icon { background: linear-gradient(135deg, #eab308, #854d0e); }
.file-card.kind-code .file-icon { background: linear-gradient(135deg, #22c55e, #166534); }
.file-name {
  font-weight: bold;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  margin-bottom: 2px;
}
.file-actions { margin-top: 6px; font-size: 12px; }

.file-table { width: 100%; table-layout: auto; }
.file-table .file-col-name {
  min-width: 0;
}
.file-table .file-col-name .file-name,
.file-table .file-col-name a.file-name {
  display: block;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}
.file-table .file-col-action { white-space: nowrap; }

@media (max-width: 600px) {
  .file-table {
    width: 100%;
    table-layout: fixed;
  }
  .file-table .file-col-type,
  .file-table .file-col-size,
  .file-table .file-col-date {
    display: none;
  }
  .file-table .file-col-icon { width: 40px; }
  .file-table .file-col-action {
    width: 4.8em;
    text-align: right;
    white-space: nowrap;
    padding-right: 8px;
  }
  .file-table .file-col-name {
    min-width: 0;
    overflow: hidden;
  }
}

@media (max-width: 800px) {
  .traffic-cols { grid-template-columns: 1fr; }
}


.nowrap { white-space: nowrap; }
.top-titles { list-style: none; margin: 0; padding: 0; }
.top-title { display: flex; align-items: center; gap: 8px; margin: 6px 0; min-width: 0; }
.trail-list { list-style: none; margin: 0; padding: 0; }
.trail-item { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-bottom: 1px solid rgba(59,79,216,0.25); min-width: 0; }
.trail-poster {
  width: 40px; height: 60px;
  object-fit: cover;
  border-radius: 3px;
  background: var(--bg-table);
  flex: 0 0 40px;
}
.trail-poster.sm { width: 28px; height: 42px; flex-basis: 28px; vertical-align: middle; }
.trail-poster.placeholder { display: inline-block; }
.trail-body { min-width: 0; }
.trail-title { font-weight: bold; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.trail-meta { font-size: 12px; }
.reset-traffic { margin-top: 28px; padding-top: 16px; border-top: 1px solid var(--border); display: flex; flex-wrap: wrap; gap: 10px; align-items: center; }
.bots-table .sample-paths { font-size: 12px; max-width: 280px; }
.sample-paths div { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.flash { color: var(--teal); }
p.error { color: #f87171; }

/* Blog */
.blog-search-form { display: flex; gap: 4px; }
.blog-search-form input[type="text"] {
  flex: 1;
  min-width: 0;
  background: #070a1c;
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 4px 8px;
  outline: none;
}
.blog-search-form input[type="text"]:focus { border-color: var(--border-bright); box-shadow: var(--glow); }
.blog-recent, .blog-archives, .blog-rcomments, .blog-products, .blog-cats, .tv-rcomments { list-style: none; margin: 0; padding: 0; }
.blog-recent li, .blog-archives li { margin: 0 0 8px; line-height: 1.3; }
.blog-recent a, .blog-archives a { text-decoration: none; color: var(--teal-dim); font-size: 12px; }
.blog-recent a:hover, .blog-archives a:hover { color: var(--teal); text-decoration: underline; }
.blog-recent .blog-date { display: block; color: var(--muted); font-size: 11px; margin-top: 1px; }
.tag-cloud { display: flex; flex-wrap: wrap; gap: 6px 8px; align-items: center; }
.tag-cloud .tag { line-height: 1.4; }
.tag-cloud .tw1 { font-size: 11px; }
.tag-cloud .tw2 { font-size: 12px; }
.tag-cloud .tw3 { font-size: 13px; }
.tag-cloud .tw4 { font-size: 15px; }
.tag-cloud .tw5 { font-size: 16px; font-weight: bold; }

.blog-list { display: flex; flex-direction: column; gap: 14px; }
.blog-teaser {
  display: flex;
  gap: 12px;
  padding-bottom: 14px;
  border-bottom: 1px solid rgba(59,79,216,0.28);
  align-items: flex-start;
}
.blog-teaser:last-child { border-bottom: 0; padding-bottom: 0; }
.blog-thumb {
  flex: 0 0 160px;
  width: 160px;
  text-decoration: none;
}
.blog-thumb img {
  display: block;
  width: 100%;
  height: 100px;
  object-fit: cover;
  border: 1px solid var(--border);
  border-radius: 6px;
  box-shadow: var(--glow);
  background: #080c1e;
}
.blog-teaser-body { min-width: 0; flex: 1; }
.blog-teaser-body h3 { margin: 0 0 4px; font-size: 15px; color: var(--coral); }
.blog-teaser-body h3 a { color: var(--coral); text-decoration: none; }
.blog-teaser-body h3 a:hover { color: var(--teal); }
.blog-meta { color: var(--muted); font-size: 12px; margin: 0 0 6px; }
.blog-meta a { text-decoration: none; }
.blog-excerpt { margin: 0 0 6px; color: var(--text); }

.blog-post { min-width: 0; }
.blog-body { margin-top: 10px; line-height: 1.55; }
.blog-body h1, .blog-body h2, .blog-body h3, .blog-body h4 {
  color: var(--gold);
  margin: 16px 0 8px;
}
.blog-body h1 { font-size: 18px; color: var(--coral); }
.blog-body h2 { font-size: 16px; color: var(--coral); }
.blog-body h3 { font-size: 14px; }
.blog-body p { margin: 0 0 10px; }
.blog-body a { color: var(--teal); }
.blog-body ul, .blog-body ol { margin: 0 0 10px; padding: 0 0 0 22px; }
.blog-body li { margin: 0 0 4px; }
.blog-body blockquote {
  margin: 0 0 12px;
  padding: 6px 10px;
  border-left: 3px solid var(--gold);
  background: rgba(230, 200, 74, 0.06);
  color: var(--text);
}
.blog-body blockquote p:last-child { margin-bottom: 0; }
.blog-body pre {
  background: #070a1c;
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 8px 10px;
  overflow-x: auto;
  margin: 0 0 12px;
  font-size: 12px;
  line-height: 1.45;
}
.blog-body code {
  font-family: ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
  font-size: 12px;
  background: #070a1c;
  border: 1px solid rgba(59,79,216,0.35);
  border-radius: 3px;
  padding: 0 4px;
}
.blog-body pre code { border: 0; padding: 0; background: transparent; }
.blog-body hr {
  border: 0;
  border-top: 1px solid var(--border);
  margin: 16px 0;
}
.blog-body img {
  /* Do not set width here: Obsidian ![[img|300]] / ![alt|300](url) emit
     an inline width (and height when given). max-width keeps them inside
     the column or the post body. height:auto is for width-only sizes;
     an explicit inline height overrides it. */
  max-width: 100%;
  height: auto;
  border: 1px solid var(--border);
  border-radius: 6px;
  box-shadow: var(--glow);
  margin: 6px 0 12px;
  background: #080c1e;
}
.blog-body audio,
.blog-body audio.blog-audio {
  display: block;
  width: 100%;
  max-width: 100%;
  margin: 6px 0 12px;
}
.blog-cols {
  display: flex;
  gap: 16px;
  align-items: flex-start;
  margin: 0 0 12px;
}
.blog-col {
  min-width: 0;
  flex: 1 1 var(--col-left, 50%);
}
.blog-col-left { flex-basis: var(--col-left, 50%); max-width: var(--col-left, 50%); }
.blog-col-right { flex-basis: var(--col-right, 50%); max-width: var(--col-right, 50%); }
.blog-cols-multi .blog-col {
  flex: 1 1 var(--col-w, 50%);
  max-width: var(--col-w, 50%);
}
.blog-cols .blog-col img { max-width: 100%; height: auto; /* no width: so |300 inline/attr can apply */ }
.blog-cols .blog-col audio { width: 100%; max-width: 100%; }
.blog-cols .blog-col > :first-child { margin-top: 0; }
.blog-cols .blog-col > :last-child { margin-bottom: 0; }
@media (max-width: 640px) {
  .blog-cols { flex-direction: column; }
  .blog-col-left, .blog-col-right { flex-basis: auto; max-width: 100%; }
  .blog-cols.has-img-right:not(.has-img-left) .blog-col-right { order: -1; }
  /* New multi-column form stacks in source order (no image-first reordering). */
  .blog-cols-multi .blog-col { flex-basis: auto; max-width: 100%; order: 0; }
}
.blog-embed {
  position: relative;
  width: 100%;
  max-width: 100%;
  aspect-ratio: 16 / 9;
  margin: 0 0 12px;
  background: #080c1e;
}
.blog-embed iframe {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  border: 0;
}
.blog-body table {
  width: 100%;
  border-collapse: collapse;
  margin: 0 0 12px;
}
.blog-body th {
  text-align: left;
  background: var(--bg-table);
  color: var(--gold);
  font-weight: normal;
  padding: 5px 6px;
  border-bottom: 1px solid var(--border);
}
.blog-body td { padding: 5px 6px; border-bottom: 1px solid rgba(59,79,216,0.25); }

.blog-nav {
  display: flex;
  justify-content: space-between;
  gap: 12px;
  margin-top: 18px;
  padding-top: 12px;
  border-top: 1px solid rgba(59,79,216,0.35);
  font-size: 12px;
}
.blog-nav a { text-decoration: none; max-width: 48%; }
.blog-next { text-align: right; margin-left: auto; }

@media (max-width: 800px) {
  .blog-teaser { flex-direction: column; }
  .blog-thumb, .blog-thumb img { width: 100%; flex-basis: auto; height: auto; max-height: 200px; }
}

/* Contact */
.contact-box { max-width: 560px; margin: 8px auto 16px; }
.contact-box h2 { text-align: left; }
.contact-form p { margin: 0 0 10px; }
.contact-form label { display: block; color: var(--muted); margin-bottom: 3px; }
.contact-form input[type="text"],
.contact-form input[type="email"],
.contact-form textarea {
  width: 100%;
  max-width: 100%;
  background: #070a1c;
  color: var(--text);
  border: 1px solid var(--border);
  border-radius: 4px;
  padding: 6px 8px;
  outline: none;
}
.contact-form textarea { min-height: 140px; resize: vertical; font-family: inherit; }
.contact-form input:focus, .contact-form textarea:focus {
  border-color: var(--border-bright);
  box-shadow: var(--glow);
}
.hp-field {
  position: absolute;
  left: -10000px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}
.contact-admin-body {
  white-space: pre-wrap;
  color: var(--text);
  font-size: 12px;
  padding-top: 0 !important;
  padding-bottom: 12px !important;
  border-bottom: 1px solid var(--border);
}

/* ---------------- Bookmarks manager ---------------- */
.layout:has(#bm-app) .side-stack { display: none; }
.bm-app { font-size: 12px; }
.bm-head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 8px; }
.bm-head h2 { margin: 0; flex: 1; color: var(--coral); font-size: 16px; }
.bm-total { font-size: 11px; font-weight: normal; }
.bm-head-actions { display: flex; gap: 6px; flex-wrap: wrap; }
.bm-app .btn { padding: 3px 9px; font-size: 12px; }
.bm-app input[type="text"], .bm-app input[type="search"], .bm-app select {
  background: var(--bg-table); color: var(--text); border: 1px solid var(--border);
  border-radius: 5px; padding: 4px 7px; font-size: 12px; outline: none; min-width: 0;
}
.bm-app input:focus, .bm-app select:focus { border-color: var(--border-bright); box-shadow: var(--glow); }
.bm-addform { display: flex; gap: 6px; flex-wrap: wrap; padding: 8px; margin-bottom: 8px;
  border: 1px dashed var(--teal-dim); border-radius: 6px; background: rgba(46,230,166,0.04); }
.bm-addform input[name="url"] { flex: 2 1 220px; }
.bm-addform input[name="title"] { flex: 2 1 200px; }
.bm-addform select { flex: 1 1 140px; max-width: 220px; }
.bm-body { display: flex; gap: 10px; align-items: flex-start; }
.bm-side { width: 230px; flex: 0 0 230px; position: sticky; top: 6px; }
.bm-side-toggle { display: none; width: 100%; }
.bm-tree { max-height: calc(100vh - 40px); overflow: auto; border: 1px solid rgba(59,79,216,0.5);
  border-radius: 6px; background: var(--bg-table); padding: 4px 0; }
.bm-node { display: flex; align-items: center; gap: 3px; padding: 3px 6px; cursor: pointer;
  white-space: nowrap; border-left: 2px solid transparent; user-select: none; }
.bm-node:hover { background: rgba(59,79,216,0.15); }
.bm-node.active { background: rgba(59,79,216,0.28); border-left-color: var(--gold); color: var(--gold); }
.bm-node.over { background: rgba(46,230,166,0.22); outline: 1px dashed var(--teal); }
.bm-node .tw { width: 12px; flex: 0 0 12px; color: var(--muted); font-size: 10px; text-align: center; }
.bm-node .tw:hover { color: var(--teal); }
.bm-node .nm { flex: 1; overflow: hidden; text-overflow: ellipsis; }
.bm-node .ct { color: var(--muted); font-size: 10px; background: rgba(59,79,216,0.18);
  border-radius: 8px; padding: 0 6px; }
.bm-main { flex: 1; min-width: 0; }
.bm-toolbar { display: flex; gap: 6px; margin-bottom: 6px; flex-wrap: wrap; }
.bm-toolbar input[type="search"] { flex: 1 1 200px; }
.bm-folderbar { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; padding: 4px 2px 6px; color: var(--gold); }
.bm-folderbar .lbl { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bm-folderbar .fb-btns { display: flex; gap: 5px; }
.bm-bulk { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; padding: 5px 8px; margin-bottom: 6px;
  border: 1px solid var(--gold); border-radius: 6px; background: rgba(230,200,74,0.07); position: sticky; top: 0; z-index: 5; }
.bm-bulk b { color: var(--gold); }
.bm-bulk select { max-width: 200px; }
.bm-table { width: 100%; border-collapse: collapse; table-layout: fixed; }
.bm-table th { text-align: left; color: var(--gold); font-weight: normal; font-size: 11px; padding: 4px 5px;
  border-bottom: 1px solid var(--border); background: var(--bg-table); white-space: nowrap; }
.bm-table th[data-sort] { cursor: pointer; }
.bm-table th[data-sort]:hover { color: var(--teal); }
.bm-table th.sorted::after { content: " " attr(data-dir); font-size: 9px; }
.bm-table td { padding: 3px 5px; border-bottom: 1px solid rgba(59,79,216,0.18); vertical-align: middle;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bm-table tr[data-id]:hover td { background: rgba(59,79,216,0.10); }
.bm-table tr.sel td { background: rgba(230,200,74,0.09); }
.bm-table .c { width: 26px; text-align: center; }
.bm-table .ic { width: 28px; }
.bm-table .dm { width: 150px; color: var(--muted); }
.bm-table .fd { width: 140px; }
.bm-table .dt { width: 80px; color: var(--muted); font-size: 11px; }
.bm-table .ac { width: 52px; text-align: right; }
.bm-table td.ti a { color: var(--text); text-decoration: none; }
.bm-table td.ti a:hover { color: var(--teal); text-decoration: underline; }
.bm-table td.ti .sub { display: none; color: var(--muted); font-size: 10px; overflow: hidden; text-overflow: ellipsis; }
.bm-table .fl { color: var(--teal-dim); cursor: pointer; }
.bm-table .fl:hover { text-decoration: underline; }
.bm-table tr.grp td { background: rgba(59,79,216,0.16); color: var(--gold); font-size: 11px; padding: 4px 6px; }
.bm-table input[type="checkbox"] { accent-color: var(--teal-dim); margin: 0; cursor: pointer; }
.bm-bdg { position: relative; display: inline-block; width: 18px; height: 18px; border-radius: 4px; color: #fff;
  font-size: 10px; font-weight: bold; line-height: 18px; text-align: center; overflow: hidden; vertical-align: middle; }
.bm-bdg img { position: absolute; inset: 0; width: 18px; height: 18px; object-fit: contain; background: #e9ecf5; }
.bm-ib { background: none; border: 0; color: var(--muted); cursor: pointer; padding: 1px 4px; font-size: 12px; border-radius: 4px; }
.bm-ib:hover { color: var(--teal); background: rgba(59,79,216,0.2); }
.bm-ib.del:hover { color: var(--coral); }
.bm-table tr[data-id] .bm-ib { opacity: 0.35; }
.bm-table tr[data-id]:hover .bm-ib, .bm-ib:focus { opacity: 1; }
.bm-edit { display: flex; gap: 5px; flex-wrap: wrap; white-space: normal; }
.bm-edit input[name="title"] { flex: 2 1 160px; }
.bm-edit input[name="url"] { flex: 2 1 180px; }
.bm-edit select { flex: 1 1 120px; max-width: 200px; }
.bm-empty { text-align: center; color: var(--muted); padding: 18px !important; }
.bm-more { text-align: center; padding: 8px; }
.bm-toast { position: fixed; left: 50%; bottom: 18px; transform: translateX(-50%); z-index: 50;
  background: var(--bg-panel); border: 1px solid var(--teal-dim); color: var(--teal); padding: 7px 14px;
  border-radius: 6px; box-shadow: var(--glow); max-width: 90vw; }
.bm-toast.bad { border-color: var(--coral); color: var(--coral); }
body.bm-dragging .bm-node.drop { outline: 1px dotted rgba(46,230,166,0.35); }
@media (max-width: 800px) {
  .bm-body { display: block; }
  .bm-side { width: auto; position: static; margin-bottom: 8px; }
  .bm-side-toggle { display: block; }
  .bm-tree { display: none; margin-top: 6px; max-height: 50vh; }
  .bm-side.open .bm-tree { display: block; }
  .bm-table .dm, .bm-table .fd, .bm-table .dt { display: none; }
  .bm-table td.ti .sub { display: block; }
  .bm-table td.ti { white-space: normal; }
  .bm-table td.ti a { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
  .bm-table tr[data-id] .bm-ib { opacity: 0.8; }
  .bm-toolbar select { flex: 1 1 45%; }
  .bm-head h2 { flex-basis: 100%; }
}
.bm-app [hidden] { display: none !important; }
.bm-app select { width: auto; }
.bm-toolbar select { flex: 0 0 auto; }
@media (max-width: 800px) {
  .bm-table { table-layout: auto; }
  .bm-table td.ti { width: 100%; max-width: 0; }
  .bm-toolbar select { flex: 1 1 45%; }
  .bm-addform select, .bm-addform input { flex: 1 1 100% !important; max-width: none !important; }
}
@media (max-width: 800px) {
  .bm-table, .bm-table thead, .bm-table tbody { display: block; width: 100%; }
  .bm-table tr { display: flex; align-items: center; width: 100%; }
  .bm-table tr.grp td, .bm-table td.bm-empty { flex: 1; }
  .bm-table th.ti, .bm-table td.ti { flex: 1 1 auto; min-width: 0; max-width: none; width: auto; }
  .bm-table td.c, .bm-table th.c { flex: 0 0 26px; }
  .bm-table td.ic, .bm-table th.ic { flex: 0 0 28px; }
  .bm-table td.ac, .bm-table th.ac { flex: 0 0 78px; }
  .bm-table td.ti .sub { white-space: nowrap; }
  .bm-table tr.editing td[colspan] { flex: 1; min-width: 0; }
}

/* ---------------- Reader ---------------- */
.layout:has(#rd-app) .side-stack { display: none; }
.rd-settings { display: flex; flex-wrap: wrap; gap: 8px 14px; align-items: center; padding: 8px; margin-bottom: 8px;
  border: 1px dashed var(--border-bright); border-radius: 6px; background: rgba(59,79,216,0.06); }
.rd-settings label { color: var(--muted); display: flex; align-items: center; gap: 5px; }
.rd-settings .rd-opml { display: flex; gap: 6px; }
.rd-addhint, .rd-note { font-size: 11px; }
.rd-newfolder { margin-top: 6px; width: 100%; }
.rd-hint { padding: 6px 10px; font-size: 11px; }
.rd-sep { margin-top: 4px; border-top: 1px solid rgba(59,79,216,0.3); font-size: 10px; }
.rd-err { color: var(--orange); font-size: 11px; margin-left: 3px; }
.bm-node .bm-bdg { width: 16px; height: 16px; line-height: 16px; font-size: 9px; margin-right: 4px; flex: 0 0 16px; }
.bm-node .bm-bdg img { width: 16px; height: 16px; }
.rd-list { border-top: 1px solid var(--border); }
.rd-item { border-bottom: 1px solid rgba(59,79,216,0.18); }
.rd-item.cur { background: rgba(59,79,216,0.08); box-shadow: inset 2px 0 0 var(--gold); }
.rd-row { display: flex; align-items: center; gap: 7px; padding: 5px 6px; cursor: pointer; min-width: 0; }
.rd-row:hover { background: rgba(59,79,216,0.10); }
.rd-star { background: none; border: 0; color: var(--muted); cursor: pointer; font-size: 14px; padding: 0 2px; line-height: 1; }
.rd-star.on, .rd-star:hover { color: var(--gold); }
.rd-main { flex: 1; min-width: 0; display: flex; align-items: baseline; gap: 8px; }
.rd-title { color: var(--text); font-weight: bold; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; flex: 0 1 auto; max-width: 70%; }
.rd-item.read .rd-title { font-weight: normal; color: var(--muted); }
.rd-meta { color: var(--muted); font-size: 11px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; flex: 0 1 auto; }
.rd-src { color: var(--teal-dim); }
.rd-sn { display: none; }
.rd-thumb { display: none; }
.rd-time { color: var(--muted); font-size: 11px; flex: 0 0 auto; margin-left: auto; }
.rd-main .rd-meta { display: none; }
.rd-main::after { content: ""; }
.rd-list:not(.cards) .rd-main { display: grid; grid-template-columns: minmax(0, 1fr) auto; }
.rd-list:not(.cards) .rd-main .rd-meta { display: block; max-width: 220px; }
.rd-list:not(.cards) .rd-title { max-width: none; }
/* card view */
.rd-list.cards .rd-row { align-items: flex-start; padding: 8px 6px; }
.rd-list.cards .rd-main { display: block; }
.rd-list.cards .rd-title { white-space: normal; max-width: none; font-size: 13px; }
.rd-list.cards .rd-meta { display: block; margin: 2px 0; }
.rd-list.cards .rd-sn { display: block; color: var(--muted); font-size: 12px; overflow: hidden; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; }
.rd-list.cards .rd-thumb { display: block; flex: 0 0 120px; height: 72px; border-radius: 5px; overflow: hidden; background: var(--bg-table); }
.rd-list.cards .rd-thumb img { width: 120px; height: 72px; object-fit: cover; display: block; }
.rd-list.cards .rd-time { display: none; }
/* expanded article */
.rd-body { padding: 4px 12px 14px 34px; }
.rd-actions { display: flex; gap: 6px; flex-wrap: wrap; margin: 2px 0 10px; }
.rd-content { font-size: 14px; line-height: 1.6; color: var(--text); max-width: 760px; overflow-wrap: anywhere; }
.rd-content img { max-width: 100%; height: auto; border-radius: 5px; display: block; margin: 8px 0; }
.rd-content a { color: var(--teal); }
.rd-content h4 { color: var(--gold); font-size: 15px; margin: 14px 0 6px; }
.rd-content pre { background: var(--bg-table); padding: 8px; border-radius: 5px; overflow-x: auto; font-size: 12px; }
.rd-content blockquote { border-left: 3px solid var(--border-bright); margin: 8px 0; padding: 2px 12px; color: var(--muted); }
.rd-content table { border-collapse: collapse; max-width: 100%; display: block; overflow-x: auto; }
.rd-content td, .rd-content th { border: 1px solid rgba(59,79,216,0.4); padding: 3px 6px; }
.rd-content figure { margin: 8px 0; }
.rd-content figcaption { color: var(--muted); font-size: 11px; }
.rd-empty { padding: 24px; text-align: center; }
.rd-keys { font-size: 10px; text-align: center; padding: 8px 0 0; }
.rd-keys b { color: var(--gold); font-weight: normal; }
@media (max-width: 800px) {
  .rd-list:not(.cards) .rd-main { display: block; }
  .rd-list:not(.cards) .rd-main .rd-meta { max-width: none; }
  .rd-list:not(.cards) .rd-time { display: none; }
  .rd-title { white-space: normal; }
  .rd-list.cards .rd-thumb { flex-basis: 84px; height: 60px; }
  .rd-list.cards .rd-thumb img { width: 84px; height: 60px; }
  .rd-body { padding: 4px 6px 12px; }
  .rd-content { font-size: 15px; }
  .rd-keys { display: none; }
  .rd-settings label { flex: 1 1 45%; }
}
.rd-time { display: none !important; }
@media (max-width: 800px) { .rd-newfolder { display: none; } .bm-side.open .rd-newfolder { display: block; } }

/* ---------------- Public bookmarks + up button ---------------- */
.layout:has(#bp-app) .side-stack { display: none; }
.bm-up { padding: 2px 6px !important; line-height: 0; color: var(--gold); }
.bm-up:disabled { opacity: 0.35; cursor: default; color: var(--muted); }
.bm-pub { font-size: 10px; margin-left: 4px; opacity: 0.85; }
.bp-list { border-top: 1px solid var(--border); }
.bp-grp { color: var(--gold); font-size: 11px; padding: 5px 6px; background: rgba(59,79,216,0.16); }
.bp-row { display: flex; align-items: center; gap: 8px; padding: 4px 6px; border-bottom: 1px solid rgba(59,79,216,0.18);
  color: var(--text); text-decoration: none; min-width: 0; }
.bp-row:hover { background: rgba(59,79,216,0.12); color: var(--teal); text-decoration: none; }
.bp-t { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bp-d { color: var(--muted); font-size: 11px; flex: 0 0 auto; max-width: 40%; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bp-foot { text-align: center; color: var(--muted); font-size: 11px; margin: 14px 0 2px; opacity: 0.8; }
.bp-app .bm-toolbar select { flex: 0 0 auto; }

/* ---- reader: public button, nested folders, public feeds page ---- */
.rd-pub { background: none; border: 1px solid rgba(59,79,216,0.45); border-radius: 3px; color: var(--muted); cursor: pointer;
  font-size: 10px; line-height: 1; padding: 2px 4px; margin-right: 2px; flex: 0 0 auto; }
.rd-pub:hover { color: var(--teal); border-color: var(--teal); }
.rd-pub.on { color: #06101a; background: var(--teal); border-color: var(--teal); }
.rd-item[draggable="true"] { cursor: default; }
.rd-app .bm-folderbar select { max-width: 180px; }
.layout:has(#rp-app) .side-stack { display: none; }
.rp-list { border-top: 1px solid var(--border); }
.rp-item { display: flex; align-items: flex-start; gap: 8px; padding: 6px; border-bottom: 1px solid rgba(59,79,216,0.18); }
.rp-item:hover { background: rgba(59,79,216,0.10); }
.rp-item .bm-bdg { margin-top: 2px; }
.rp-main { flex: 1; min-width: 0; }
.rp-title { font-weight: bold; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rp-title a { color: inherit; }
.rp-title a:hover { color: var(--teal); }
.rp-sn { color: var(--muted); font-size: 12px; margin-top: 2px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.rp-open { flex: 0 0 auto; font-size: 11px; padding: 2px 8px; align-self: center; }
@media (max-width: 800px) { .rp-open { display: none; } .rp-title { white-space: normal; } }

/* ---- admin traffic charts + TV tab ---- */
.seg { display: inline-flex; flex-wrap: wrap; gap: 6px; }
.tc-wrap { margin: 8px 0 18px; }
.tc-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px; }
.tc-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; }
.tc-card { margin: 0; min-width: 0; }
.tc-card h4 { margin: 0 0 8px; font-size: 14px; color: var(--text); display: flex; flex-wrap: wrap; gap: 6px 14px; align-items: center; }
.tc-wide { grid-column: 1 / -1; }
.tc-chart svg { display: block; max-height: 260px; }
.tc-key { font-weight: normal; font-size: 12px; color: var(--muted); }
.tc-key i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin: 0 4px 0 8px; vertical-align: -1px; }
.tc-key .k-h { background: var(--teal); } .tc-key .k-b { background: var(--coral); } .tc-key .k-v { background: var(--gold); }
.tc-donut { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.tc-donut svg { width: 150px; flex: 0 0 150px; }
.tc-legend { list-style: none; margin: 0; padding: 0; flex: 1 1 140px; min-width: 0; font-size: 13px; }
.tc-legend li { display: flex; align-items: center; gap: 6px; margin: 3px 0; }
.tc-legend i { width: 10px; height: 10px; border-radius: 2px; flex: 0 0 10px; }
.tc-legend span { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tc-legend b, .tc-hbars b { color: var(--muted); font-weight: normal; white-space: nowrap; }
.tc-hbars { list-style: none; margin: 0; padding: 0; font-size: 13px; }
.tc-hbars li { display: grid; grid-template-columns: minmax(90px, 38%) 1fr auto; gap: 8px; align-items: center; margin: 4px 0; }
.tc-lab { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tc-track { height: 10px; background: var(--bg-table); border-radius: 5px; overflow: hidden; }
.tc-fill { display: block; height: 100%; background: linear-gradient(90deg, var(--border), var(--teal)); border-radius: 5px; }
.tc-empty { margin: 8px 0; }
.tc-note { font-size: 12px; margin-top: 8px; }
.tv-top td { vertical-align: middle; }
.tv-top .num { text-align: right; white-space: nowrap; position: relative; }
.tv-bar { display: inline-block; width: calc(var(--w) * 0.6px); max-width: 60px; height: 6px; margin-right: 6px; border-radius: 3px; background: var(--teal); vertical-align: middle; opacity: .7; }
@media (max-width: 720px) { .tc-grid { grid-template-columns: 1fr; } .tv-top th:nth-child(6), .tv-top td:nth-child(6), .tv-top th:nth-child(8), .tv-top td:nth-child(8) { display: none; } }
.tc-botchk { margin-left: 6px; font-size: 13px; color: var(--muted); align-self: center; }
.tc-nobots .kb { display: none; }

/* ---- feeds: View button + 3-line snippets ---- */
.rd-row { align-items: flex-start; }
.rd-btns { display: flex; flex-direction: column; align-items: flex-start; gap: 4px; flex: 0 0 auto; padding-top: 1px; }
.rd-btnrow { display: flex; align-items: center; gap: 2px; }
.rd-view { display: inline-block; font-size: 10px; line-height: 1; padding: 3px 5px; border: 1px solid rgba(46,230,166,0.55); border-radius: 3px;
  color: var(--teal); text-decoration: none; white-space: nowrap; }
.rd-view:hover { background: var(--teal); color: #06101a; text-decoration: none; }
.rd-row > .bm-bdg { margin-top: 2px; }
.rd-list .rd-sn { display: -webkit-box; -webkit-line-clamp: 3; line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
  color: var(--muted); font-size: 12px; line-height: 1.4; margin-top: 2px; white-space: normal; overflow-wrap: anywhere; }
.rd-list:not(.cards) .rd-main .rd-sn { grid-column: 1 / -1; }
.rd-list.cards .rd-sn { -webkit-line-clamp: 3; line-clamp: 3; }
.rd-item.read .rd-sn { opacity: 0.8; }
.rp-item .rp-view { flex: 0 0 auto; margin-top: 2px; }
.rp-sn { -webkit-line-clamp: 3; line-clamp: 3; line-height: 1.4; }
.rp-open { display: none; }

.blog-teaser-head { display: flex; align-items: flex-start; gap: 8px; }
.blog-teaser-head h3 { flex: 1; min-width: 0; margin: 0 0 4px; }
.blog-teaser-head .fav-form { margin: 0; flex: 0 0 auto; }
.blog-post-head { display: flex; align-items: flex-start; gap: 10px; margin: 0 0 6px; }
.blog-post-head h2 { flex: 1; min-width: 0; margin: 0; }
.blog-post-head .fav-form { margin: 0; flex: 0 0 auto; }
.fav-form-compact .fav-btn { padding: 1px 7px; min-width: 28px; line-height: 1.4; }
.fav-links { list-style: none; margin: 0 0 16px; padding: 0; display: flex; flex-direction: column; gap: 6px; }
.fav-links li { margin: 0; }
.fav-links a {
  display: flex; align-items: flex-start; gap: 10px;
  text-decoration: none; color: var(--teal-dim);
  padding: 7px 8px; border: 1px solid var(--border); border-radius: 6px;
}
.fav-links a:hover { color: var(--teal); border-color: var(--border-bright); background: rgba(59,79,216,0.12); }
.fav-links .fav-ico { width: 18px; height: 18px; object-fit: cover; border-radius: 3px; flex: 0 0 18px; margin-top: 2px; }
.fav-links .fav-body { min-width: 0; flex: 1; display: flex; flex-direction: column; }
.fav-links .fav-title { font-size: 14px; color: var(--coral); line-height: 1.3; }
.fav-links a:hover .fav-title { color: var(--teal); }
.fav-links .fav-sub {
  font-size: 11px; color: var(--muted); margin-top: 2px; overflow: hidden;
  display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical;
}
.bm-ib.bm-star { color: var(--muted); font-size: 14px; }
.bm-ib.bm-star.on, .bm-ib.bm-star:hover { color: var(--gold); }
.bm-table tr[data-id] .bm-ib.bm-star.on { opacity: 1; }

.fav-head { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin: 0 0 10px; }
.fav-head h2 { margin: 0; flex: 1; }
.fav-grid-wrap .grid { grid-template-columns: repeat(auto-fill, minmax(70px, 1fr)); gap: 8px 6px; }
.fav-grid-wrap .card .ctitle { font-size: 11px; margin-top: 3px; }
.fav-grid-wrap .card .year { font-size: 9px; padding: 0 4px; }
.fav-grid-wrap .card .watch-badge { font-size: 9px; }
.exp { margin: 0 0 6px; border: 1px solid var(--border); border-radius: 6px; overflow: hidden; background: rgba(8,12,30,0.35); }
.exp > .exp-toggle {
  display: flex; align-items: center; gap: 8px; width: 100%;
  background: rgba(59,79,216,0.10); border: 0; color: var(--coral);
  text-align: left; padding: 8px 10px; cursor: pointer; font: inherit;
}
.exp > .exp-toggle:hover { background: rgba(59,79,216,0.18); color: var(--teal); }
.exp > .exp-toggle .exp-chev { color: var(--muted); width: 1em; flex: 0 0 auto; }
.exp > .exp-body { padding: 6px 8px 8px 14px; border-top: 1px solid var(--border); }
.exp .exp { margin: 6px 0 0; }
.exp .fav-links { margin-bottom: 0; }
.bm-node .rd-flags { margin-left: 4px; display: flex; align-items: center; gap: 2px; flex: 0 0 auto; }
.bm-node .rd-pub { font-size: 9px; padding: 0 4px; line-height: 1.4; }
.bm-node .rd-star { opacity: 0.7; }
.bm-node:hover .rd-star, .bm-node .rd-star.on, .bm-node .rd-pub.on { opacity: 1; }

/* ===== Blog: 3-column layout (2 columns of cards + one boxed sidebar) ===== */
.blog-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; align-items: stretch; }
.blog-card {
  display: flex; flex-direction: column; min-width: 0; overflow: hidden;
  border: 1px solid var(--border); border-radius: var(--radius); background: var(--bg-table);
}
.blog-card .blog-thumb { display: block; flex: none; width: 100%; }
.blog-card .blog-thumb img {
  display: block; width: 100%; height: 150px; object-fit: cover; border: 0; border-radius: 0;
  border-bottom: 1px solid var(--border); box-shadow: none;
}
.blog-card-body { padding: 8px 10px 10px; min-width: 0; flex: 1; display: flex; flex-direction: column; }
.blog-card-body h3 { margin: 0 0 4px; font-size: 15px; overflow-wrap: anywhere; }
.blog-card-body h3 a { color: var(--coral); text-decoration: none; }
.blog-card-body h3 a:hover { color: var(--teal); }
.blog-card-body .blog-excerpt { flex: 1; }
.blog-card-body .tags { margin: 6px 0 0; }
.blog-sidebar { padding: 0; overflow: hidden; }
.blog-sidebar .bs-sec { padding: 10px 12px 12px; border-top: 1px solid var(--border); }
.blog-sidebar .bs-sec:first-child { border-top: 0; }
.blog-sidebar h2 { margin: 0 0 8px; font-size: 14px; color: var(--coral); }
.blog-sidebar .blog-recent li { margin: 0 0 9px; }
.blog-sidebar .blog-recent a { font-size: 13px; overflow-wrap: anywhere; }
.blog-sidebar .blog-date { display: block; color: var(--muted); font-size: 11px; margin-top: 1px; }
.blog-sidebar .tag-cloud { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; }
.blog-sidebar .tag-cloud .tag {
  display: inline-block; line-height: 1.5; padding: 1px 9px; border: 1px solid var(--border-bright);
  border-radius: 999px; white-space: nowrap;
}
.blog-sidebar .tag-cloud .tag:hover { background: rgba(127,127,127,0.12); }
.blog-sidebar .tag-cloud .tc { color: var(--muted); font-size: 0.8em; margin-left: 2px; }
.blog-sidebar .tag-cloud .tw1 { font-size: 11px; }
.blog-sidebar .tag-cloud .tw2 { font-size: 12.5px; }
.blog-sidebar .tag-cloud .tw3 { font-size: 14px; }
.blog-sidebar .tag-cloud .tw4 { font-size: 16px; }
.blog-sidebar .tag-cloud .tw5 { font-size: 18px; font-weight: bold; }
@media (max-width: 640px) {
  .blog-grid { grid-template-columns: 1fr; }
  .blog-card .blog-thumb img { height: auto; max-height: 220px; }
}

/* ===== Header extras (logo, tagline), footer text, maintenance ===== */
.logo { display: inline-flex; align-items: center; gap: 10px; }
.logo-img { max-height: 44px; width: auto; display: block; }
.tagline { color: var(--muted); font-size: 12px; margin-top: 2px; padding-left: 2px; }
footer.site .footer-text { margin: 0 0 6px; white-space: pre-line; color: var(--muted); }
.maint-box { max-width: 560px; margin: 24px auto; text-align: center; }

/* ===== Admin: settings + posts ===== */
.set-wrap { display: flex; gap: 14px; align-items: flex-start; }
.set-tabs { flex: 0 0 170px; display: flex; flex-direction: column; gap: 4px; position: sticky; top: 8px; }
.set-tabs button {
  text-align: left; background: transparent; color: var(--text); border: 1px solid var(--border);
  border-radius: 6px; padding: 7px 10px; cursor: pointer;
}
.set-tabs button.on { border-color: var(--teal); color: var(--teal); background: rgba(127,127,127,0.1); }
.set-body { flex: 1; min-width: 0; }
.set-sec { display: none; }
.set-sec.on { display: block; }
.set-sec h3 { margin-top: 0; font-size: 15px; }
.set-field { margin: 0 0 14px; }
.set-field > label, .set-field > .lbl { display: block; font-weight: bold; color: var(--text); margin-bottom: 3px; }
.set-field input[type=text], .set-field input[type=number], .set-field input[type=url], .set-field input[type=date],
.set-field textarea, .set-field select { width: 100%; max-width: 640px; padding: 5px 8px; border: 1px solid var(--border); border-radius: 4px; background: var(--bg-table); color: var(--text); }
.set-field textarea { min-height: 90px; font-family: inherit; }
.set-field textarea.mono, textarea.mono { font-family: ui-monospace, Menlo, Consolas, monospace; font-size: 12.5px; }
.help { color: var(--muted); font-size: 12px; margin: 3px 0 0; max-width: 640px; }
.chk { display: flex; gap: 6px; align-items: center; }
.set-save {
  position: sticky; bottom: 0; background: var(--bg-panel); border-top: 1px solid var(--border);
  padding: 10px 0; margin-top: 16px; display: flex; gap: 10px; align-items: center; flex-wrap: wrap;
}
.rows { display: flex; flex-direction: column; gap: 6px; max-width: 760px; }
.row-item { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; border: 1px solid var(--border); border-radius: 6px; padding: 5px 8px; background: var(--bg-table); }
.row-item input[type=text] { flex: 1 1 140px; min-width: 100px; width: auto; max-width: none; }
.row-item .url { flex: 2 1 200px; }
.row-item .ro { color: var(--muted); flex: 2 1 200px; font-size: 12px; overflow-wrap: anywhere; }
.row-item .btn { padding: 2px 8px; }
.theme-grid { display: flex; flex-wrap: wrap; gap: 10px; margin-bottom: 10px; }
.theme-card { border: 2px solid var(--border); border-radius: 8px; padding: 6px; cursor: pointer; width: 150px; display: block; font-weight: normal; }
.theme-card input { display: none; }
.theme-card.on { border-color: var(--teal); }
.theme-swatch { height: 46px; border-radius: 5px; border: 1px solid; padding: 5px; font-size: 11px; display: flex; gap: 4px; align-items: flex-end; }
.theme-swatch i { display: inline-block; width: 18px; height: 10px; border-radius: 5px; }
.color-row { display: flex; gap: 10px; flex-wrap: wrap; }
.color-row label { display: flex; align-items: center; gap: 6px; font-weight: normal !important; margin: 0 !important; }
.color-row input[type=color] { width: 38px; height: 28px; padding: 0; border: 1px solid var(--border); background: transparent; }
.live-preview { border: 1px solid; border-radius: 8px; padding: 10px 12px; max-width: 640px; }
.live-preview h4 { margin: 0 0 6px; font-size: 15px; }
.live-preview .pill { display: inline-block; border: 1px solid; border-radius: 999px; padding: 0 9px; font-size: 11px; margin-right: 4px; }
.md-split { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.md-split .md-prev { border: 1px solid var(--border); border-radius: 6px; padding: 8px 10px; overflow: auto; max-height: 460px; background: var(--bg-table); }
.md-split textarea { max-width: none; width: 100%; min-height: 360px; }
.hist-table td, .hist-table th { font-size: 12px; }
.pill-st { display: inline-block; border: 1px solid var(--border-bright); border-radius: 999px; padding: 0 8px; font-size: 11px; }
.pill-st.draft { border-color: var(--orange); color: var(--orange); }
.pill-st.pub { border-color: var(--teal); color: var(--teal); }
.tag-chip { cursor: pointer; background: transparent; font-size: 11px; color: var(--teal); }
.flash { border: 1px solid var(--teal-dim); color: var(--teal); border-radius: 6px; padding: 6px 10px; }
@media (max-width: 800px) {
  .set-wrap { display: block; }
  .set-tabs { position: static; flex-direction: row; flex-wrap: wrap; margin-bottom: 10px; }
  .md-split { grid-template-columns: 1fr; }
}

/* ===== v32: announcement banner, Markdown homepage cards, section settings, single-view traffic ===== */
.announce { text-align: center; padding: 6px 12px; border-bottom: 1px solid var(--teal); color: var(--teal); background: var(--bg-header); font-size: 13px; }
.announce a { color: var(--teal); }
.home-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 14px; margin-top: 14px; align-items: stretch; }
.home-card { border: 1px solid var(--teal); border-radius: 10px; }
.home-card .home-card-img { display: block; width: 100%; height: 140px; object-fit: cover; border: 0; border-bottom: 1px solid var(--teal); }
.home-card .blog-card-body h3 { margin: 0 0 6px; }
.home-card-text { flex: 1; }
.home-card-text p { margin: 0 0 6px; }
.home-card .tags { margin-top: 8px; }
@media (max-width: 900px) { .home-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .home-grid { grid-template-columns: 1fr; } }
.sec-box { border: 1px solid var(--border); border-radius: 10px; padding: 6px 10px; margin: 0 0 8px; background: var(--bg-table); }
.sec-box summary { cursor: pointer; padding: 3px 0; }
.sec-box[open] summary { margin-bottom: 8px; }
.sec-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 4px 14px; }
.sec-grid .sec-wide { grid-column: 1 / -1; }
.sec-grid textarea { width: 100%; max-width: none; }
.swatch { display: inline-block; width: 18px; height: 18px; border-radius: 4px; vertical-align: middle; border: 1px solid var(--border); }
.single-view .ua-cell { max-width: 320px; overflow-wrap: anywhere; font-size: 12px; }
.single-view .ua-text { font-size: 11px; }
.bulk-bar { align-items: center; gap: 8px; flex-wrap: wrap; }
@media (max-width: 700px) { .sec-grid { grid-template-columns: 1fr; } }

/* ===== v33: blog comments ===== */
.comments { margin-top: 18px; }
.comments h3 { margin: 0 0 8px; }
.comment { border: 1px solid var(--teal); border-radius: 10px; padding: 8px 10px; margin: 0 0 8px; background: var(--bg-table); }
.comment-head { margin-bottom: 4px; }
.comment-body { white-space: pre-wrap; overflow-wrap: anywhere; }
.comment-form { border: 1px solid var(--teal); border-radius: 10px; padding: 10px; display: flex; flex-direction: column; gap: 8px; max-width: 760px; }
.comment-form label { display: flex; flex-direction: column; gap: 3px; }
.comment-form textarea { width: 100%; max-width: none; }
.comment-who { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.comment-form .hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.comment-form .btn { align-self: flex-start; }
.comment-pill { color: var(--teal); border-color: var(--teal); }
.comments-admin .comment-body { max-width: 380px; font-size: 12px; }
@media (max-width: 600px) { .comment-who { grid-template-columns: 1fr; } }

/* ===== v34: live chat ===== */
.chat-wrap { display: grid; grid-template-columns: minmax(0, 1fr) 220px; gap: 12px; }
.chat-main, .chat-side { border: 1px solid var(--teal); border-radius: 10px; padding: 8px 10px; background: var(--bg-table); min-width: 0; }
.chat-log { height: 56vh; min-height: 260px; overflow-y: auto; padding: 4px 2px; margin: 6px 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.chat-msg { padding: 3px 0; line-height: 1.4; overflow-wrap: anywhere; }
.chat-msg.is-admin .chat-name { color: var(--gold); }
.chat-time { color: var(--muted); font-size: 11px; }
.chat-name { color: var(--teal); }
.chat-body { white-space: pre-wrap; overflow-wrap: anywhere; }
.chat-tools { margin-left: 6px; }
.chat-tools .chat-mod { padding: 0 6px; font-size: 11px; }
.chat-notice { font-style: italic; font-size: 12px; padding: 2px 0; }
.chat-form, .alias-form { display: flex; gap: 6px; }
.chat-form input, .alias-form input { flex: 1; min-width: 0; max-width: none; }
.chat-side h3 { margin: 0 0 6px; }
.chat-users { list-style: none; margin: 0 0 10px; padding: 0; max-height: 40vh; overflow-y: auto; }
.chat-users li { padding: 2px 8px; margin: 0 0 4px; border: 1px solid var(--teal); border-radius: 10px; color: var(--teal); font-size: 12px; overflow-wrap: anywhere; }
.chat-users li.is-admin { color: var(--gold); }
.chat-me { font-size: 12px; }
.chat-me .small { font-size: 11px; }
.chat-admin-msgs .chat-body { max-width: 380px; font-size: 12px; }
@media (max-width: 700px) {
  .chat-wrap { grid-template-columns: 1fr; }
  .chat-side { order: -1; }
  .chat-users { display: flex; flex-wrap: wrap; gap: 4px; max-height: none; }
  .chat-users li { margin: 0; }
  .chat-log { height: 50vh; }
}
/* IP names + whitelist buttons (admin) */
.ipc .ip-alias { font-weight: 600; color: var(--accent, #4aa3ff); }
.ipm-btn { font-size: .72em; padding: 0 .4em; margin-left: .2em; border: 1px solid currentColor; border-radius: 4px; background: transparent; color: inherit; opacity: .65; cursor: pointer; }
.ipm-btn:hover { opacity: 1; }
.pill.ok { background: #2e7d32; color: #fff; }
/* chat images */
.chat-thumb { max-width: 160px; max-height: 120px; border-radius: 6px; vertical-align: middle; cursor: zoom-in; display: inline-block; }
.chat-attach { cursor: pointer; padding-left: .6em; padding-right: .6em; }
.chat-lightbox { position: fixed; inset: 0; background: rgba(0,0,0,.85); z-index: 9999; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: .6em; cursor: zoom-out; }
.chat-lightbox img { max-width: 94vw; max-height: 86vh; border-radius: 6px; }
.chat-lightbox a { color: #fff; }
/* FAQ page (Markdown at /var/www/html/faq.md) */
.faq-page h1 { margin-bottom: .3em; }
.faq-sec { border: 2px solid #2e9e5b; border-radius: 14px; padding: 14px 18px; margin: 18px 0; }
.faq-sec > h3 { margin: 0 0 8px; color: #2e9e5b; }
.faq-q { border: 1px solid rgba(46,158,91,.55); border-radius: 10px; margin: 8px 0; padding: 0 14px; }
.faq-q > summary { cursor: pointer; padding: 10px 0; font-weight: 600; list-style-position: inside; }
.faq-q[open] > summary { border-bottom: 1px solid rgba(46,158,91,.35); margin-bottom: 8px; }
.faq-a { padding-bottom: 10px; }
.faq-a p:first-child { margin-top: 0; }


/* Phones stay full width even if the site-width setting is under 100%. */
@media (max-width: 800px) {
  :root { --site-width: 100%; }
}

/* Traffic admin: contain wide tables on phones so panels stay viewport-width */
html, body { max-width: 100%; overflow-x: hidden; }
.wrap { width: 100%; }
.layout, main.panel, .tc-wrap, .tc-grid, .tc-card, .tmdb-box {
  max-width: 100%;
  min-width: 0;
}
.tmdb-box { overflow-wrap: anywhere; }
.table-wrap {
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  max-width: 100%;
  width: 100%;
}
.table-wrap .admin-table { margin: 0; }
.traffic-sessions th,
.traffic-sessions td,
.traffic-sessions .ipc,
.traffic-sessions .pill,
.table-wrap .admin-table th,
.table-wrap .ipc,
.table-wrap .pill {
  white-space: nowrap;
}
.single-view .ua-cell,
.bots-table .ua,
.bots-table .sample-paths {
  overflow-wrap: normal;
  word-break: normal;
  max-width: 14em;
  overflow: hidden;
  text-overflow: ellipsis;
}

.filters, .traffic-filters, .admin-bar, .bulk-bar, .reset-traffic {
  max-width: 100%;
  min-width: 0;
}
.filters input[type="text"],
.filters input[type="date"],
.traffic-filters input[type="text"],
.traffic-filters input[type="date"] {
  max-width: 100%;
  min-width: 0;
}
.tc-chart, .tc-chart svg { max-width: 100%; }

@media (max-width: 720px) {
  .traffic-stats { grid-template-columns: repeat(auto-fill, minmax(120px, 1fr)); }
  .table-wrap .admin-table { font-size: 11px; }
  .table-wrap .admin-table th,
  .table-wrap .admin-table td { padding: 3px 4px; }
  .table-wrap .btn { padding: 2px 6px; font-size: 11px; }
  .table-wrap .pill { padding: 0 5px; font-size: 10px; }
  .table-wrap .ipm-btn { font-size: 10px; padding: 0 .28em; margin-left: .1em; }
  .filters label, .traffic-filters label {
    min-width: 0;
    max-width: 100%;
  }
  .tc-hbars li { grid-template-columns: minmax(0, 38%) 1fr auto; }
  .bots-table .sample-paths { max-width: none; }
}
@media (max-width: 480px) {
  .table-wrap .admin-table { font-size: 8px; }
  .table-wrap .admin-table th,
  .table-wrap .admin-table td { padding: 1px 2px; }
  .table-wrap .btn { padding: 1px 4px; font-size: 8px; }
  .table-wrap .pill { padding: 0 3px; font-size: 8px; }
  .table-wrap .ipm-btn { font-size: 8px; padding: 0 .2em; }
}

/* Main Sessions table is narrower now — keep a comfortable mobile size.
   Leave Single-view (.single-view) and Bots (other .admin-table) on the tighter 8px sizing. */
@media (max-width: 720px) {
  .table-wrap .traffic-sessions:not(.single-view) { font-size: 12px; }
  .table-wrap .traffic-sessions:not(.single-view) th,
  .table-wrap .traffic-sessions:not(.single-view) td { padding: 4px 5px; }
  .table-wrap .traffic-sessions:not(.single-view) .btn { padding: 2px 8px; font-size: 12px; }
}
@media (max-width: 480px) {
  .table-wrap .traffic-sessions:not(.single-view) { font-size: 11px; }
  .table-wrap .traffic-sessions:not(.single-view) th,
  .table-wrap .traffic-sessions:not(.single-view) td { padding: 3px 4px; }
  .table-wrap .traffic-sessions:not(.single-view) .btn { padding: 2px 6px; font-size: 11px; }
}

/* Whitelisted IP + alias on the main Sessions table and Trail page */
.ip-wl { color: var(--teal); font-weight: 600; }

.trail-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-top: 10px;
}
.trail-actions form {
  display: inline-flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  margin: 0;
}
.trail-actions input[type="text"] {
  width: 14em;
  max-width: 100%;
  min-width: 0;
}

/* ---- Auto-built list pages (/lists, /new-on-*, /trending ...) ---- */
.tvl-head { margin-bottom: 10px; }
.tvl-head h1 { font-size: 20px; margin-bottom: 6px; }
.tvl-intro { margin: 0 0 6px; line-height: 1.5; max-width: 900px; }
.tvl-updated { color: var(--muted); font-size: 12px; }
.tvl-chips { display: flex; gap: 6px; overflow-x: auto; padding: 4px 0 10px; margin-bottom: 6px; scrollbar-width: thin; -webkit-overflow-scrolling: touch; }
.tvl-chips a { flex: 0 0 auto; white-space: nowrap; font-size: 12px; padding: 4px 10px; border: 1px solid var(--border); border-radius: 12px; color: var(--text); text-decoration: none; background: var(--bg-table); }
.tvl-chips a:hover { border-color: var(--teal); color: var(--teal); }
.tvl-chips a.on { border-color: var(--gold); color: var(--gold); }
.home-lists { margin: 0 0 6px; }
.tvl-tiles { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 10px; margin: 6px 0 14px; }
.tvl-tile { display: flex; align-items: center; gap: 10px; padding: 10px 12px; background: var(--bg-table); border: 1px solid var(--border); border-radius: var(--radius); color: var(--text); text-decoration: none; box-shadow: var(--glow); }
.tvl-tile:hover { border-color: var(--teal); color: var(--teal); text-decoration: none; }
.tvl-tile-text { display: flex; flex-direction: column; min-width: 0; }
.tvl-tile-text b { color: var(--gold); font-size: 14px; }
.tvl-tile-text span { font-size: 12px; color: var(--muted); line-height: 1.35; }
.tvl-logo { width: 40px; height: 40px; border-radius: 8px; flex: 0 0 40px; }
.tvl-ico { width: 40px; height: 40px; flex: 0 0 40px; border-radius: 8px; display: flex; align-items: center; justify-content: center; color: var(--gold); border: 1px solid var(--border-bright); font-size: 18px; }
.tvl-sec { margin-top: 14px; }
.tvl-h2 { display: flex; align-items: center; gap: 8px; }
.tvl-logo-sm { width: 24px; height: 24px; border-radius: 5px; }
.tvl-count { font-size: 11px; color: var(--muted); font-weight: normal; border: 1px solid var(--border); border-radius: 8px; padding: 0 6px; }
.tvl-rank { position: absolute; top: 5px; left: 5px; background: rgba(7,10,28,0.85); border: 1px solid var(--teal-dim); color: var(--teal); font-size: 11px; line-height: 16px; min-width: 18px; text-align: center; padding: 0 4px; border-radius: 8px; }
.tvl-more { margin: 8px 0 0; text-align: right; font-size: 13px; }
.tvl-attr { margin-top: 16px; color: var(--muted); font-size: 12px; }
@media (max-width: 800px) {
  .tvl-tiles { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 480px) {
  .tvl-head h1 { font-size: 17px; }
  .tvl-intro { font-size: 13px; }
  .tvl-tiles { grid-template-columns: 1fr; }
}

/* ---- Nomad Games (games.nomadlouie.com) ---- */
.gm-card .poster { aspect-ratio: 3 / 4; }
.gm-score { position: absolute; left: 5px; bottom: 5px; background: rgba(7,10,28,0.88); border: 1px solid var(--teal-dim); color: var(--teal); font-size: 11px; font-weight: bold; line-height: 16px; min-width: 20px; text-align: center; padding: 0 5px; border-radius: 8px; }
.gm-free { position: absolute; top: 5px; left: 5px; background: rgba(7,28,18,0.92); border: 1px solid var(--teal); color: var(--teal); font-size: 10px; font-weight: bold; letter-spacing: 0.04em; line-height: 16px; padding: 0 5px; border-radius: 8px; }
.gm-pill-free { border-color: var(--teal); color: var(--teal); font-weight: bold; letter-spacing: 0.04em; }
.gm-getfree { margin: 8px 0 0; }
.gm-free-btn { display: inline-flex; align-items: center; font-size: 13px; font-weight: bold; line-height: 1; padding: 7px 12px; border-radius: 8px; border: 1px solid var(--teal); background: var(--teal); color: #08131a; text-decoration: none; }
.gm-free-btn:hover { filter: brightness(1.08); }
.gm-note { margin: -2px 0 8px; color: var(--muted); font-size: 12px; }
.gm-genres .tag.on { border-color: var(--gold); color: var(--gold); }
.gm-pager { display: flex; justify-content: center; align-items: center; gap: 12px; margin: 16px 0 4px; }
.gm-attr a { color: inherit; text-decoration: underline; }
.gm-hero { min-height: 150px; }
.gm-hero .backdrop { opacity: 0.38; background-position: center 30%; }
.gm-cover, .gm-cover img, .gm-cover .ph { flex-basis: 132px; width: 132px; }
.gm-cover img, .gm-cover .ph { aspect-ratio: 3 / 4; }
.gm-h1 { color: var(--coral); font-size: clamp(17px, 2.2vw, 26px); line-height: 1.2; margin: 0; overflow-wrap: break-word; }
.gm-h1 .muted { font-weight: normal; }
.title-info .gm-scores { display: flex; flex-wrap: wrap; gap: 6px; }
.gm-pill { display: inline-flex; align-items: baseline; gap: 2px; font-size: 12px; padding: 3px 9px; border: 1px solid var(--border); border-radius: 12px; background: rgba(16,22,46,0.85); color: var(--text); white-space: nowrap; }
.gm-pill-score { border-color: var(--teal-dim); color: var(--teal); font-weight: bold; }
.gm-pill small { font-size: 10px; color: var(--muted); font-weight: normal; }
.gm-body { display: grid; grid-template-columns: minmax(0, 1fr) 270px; gap: 16px; align-items: start; }
.gm-main { min-width: 0; }
.gm-block { margin-top: 14px; }
.gm-h2 { font-size: 15px; color: var(--gold); margin: 0 0 8px; display: flex; align-items: center; gap: 8px; }
.gm-video { position: relative; aspect-ratio: 16 / 9; border: 1px solid var(--border); border-radius: var(--radius); overflow: hidden; box-shadow: var(--glow); background: #000; }
.gm-video iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.gm-shots { display: flex; gap: 8px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 6px; scrollbar-width: thin; -webkit-overflow-scrolling: touch; }
.gm-shot { flex: 0 0 auto; width: min(360px, 78vw); aspect-ratio: 16 / 9; scroll-snap-align: start; border: 1px solid var(--border); border-radius: 6px; overflow: hidden; background: #080c1e; }
.gm-shot:hover { border-color: var(--teal); }
.gm-shot img { width: 100%; height: 100%; object-fit: cover; display: block; }
.gm-facts { background: var(--bg-table); border: 1px solid var(--border); border-radius: var(--radius); padding: 12px; box-shadow: var(--glow); margin-top: 6px; }
.gm-facts dl { margin: 0; display: grid; grid-template-columns: auto 1fr; gap: 6px 10px; font-size: 13px; }
.gm-facts dt { color: var(--muted); white-space: nowrap; }
.gm-facts dd { margin: 0; min-width: 0; overflow-wrap: anywhere; }
.gm-plats { display: flex; flex-wrap: wrap; gap: 4px; }
.gm-plat { font-size: 11px; padding: 1px 7px; border: 1px solid var(--border-bright); border-radius: 10px; color: var(--text); text-decoration: none; white-space: nowrap; }
a.gm-plat:hover { border-color: var(--teal); color: var(--teal); text-decoration: none; }
.gm-soon { text-align: center; max-width: 640px; margin: 30px auto 40px; padding: 10px; }
.gm-soon h1 { color: var(--coral); font-size: 24px; margin: 8px 0 12px; }
.gm-soon p { line-height: 1.55; }
.gm-soon-badge { font-size: 46px; }
.gm-btn, .gm-btn-alt { display: inline-block; margin: 4px; }
@media (max-width: 800px) {
  .gm-body { grid-template-columns: minmax(0, 1fr); }
  .gm-facts { margin-top: 12px; }
}
@media (max-width: 480px) {
  .gm-cover, .gm-cover img, .gm-cover .ph { flex-basis: 100px; width: 100px; }
  .gm-hero { min-height: 0; }
  .gm-pill { font-size: 11px; padding: 2px 7px; }
  .gm-soon h1 { font-size: 20px; }
  .gm-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 8px 6px; }
  .gm-grid .ctitle { font-size: 11px; }
}

/* ---- Homepage hub (nomadlouie.com/, Nov 2026) ---- */
.nh { display: flex; flex-direction: column; gap: 18px; min-width: 0; }
.nh a { text-decoration: none; }
.nh-hero { position: relative; overflow: hidden; border: 1px solid var(--border); border-radius: 14px; min-height: 300px;
  background: radial-gradient(120% 140% at 0% 0%, rgba(74,92,255,.35), transparent 55%), radial-gradient(90% 120% at 100% 100%, rgba(255,123,114,.25), transparent 60%), #070a1c;
  display: flex; align-items: center; box-shadow: var(--glow); }
.nh-hero-bg { position: absolute; inset: 0; background-size: cover; background-position: center 30%; opacity: .28; filter: saturate(1.1); }
.nh-mosaic { position: absolute; inset: -20px -20px -20px 40%; display: grid; grid-template-columns: repeat(6, 1fr); gap: 8px; transform: rotate(-8deg); opacity: .55; }
.nh-mosaic img { width: 100%; aspect-ratio: 2/3; object-fit: cover; border-radius: 6px; }
.nh-hero::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, #070a1c 18%, rgba(7,10,28,.85) 45%, rgba(7,10,28,.15)); }
.nh-hero-in { position: relative; z-index: 1; padding: 34px 32px; max-width: 640px; }
.nh-kicker { margin: 0 0 6px; color: var(--teal); font-size: 12px; letter-spacing: .12em; text-transform: uppercase; }
.nh-title { margin: 0; font-size: clamp(38px, 7vw, 68px); line-height: 1; color: #fff; letter-spacing: -.02em; text-shadow: 0 4px 24px rgba(74,92,255,.5); }
.nh-title span { color: var(--coral); }
.nh-tag { margin: 12px 0 20px; color: var(--text); font-size: 16px; line-height: 1.5; }
.nh-ctas { display: flex; flex-wrap: wrap; gap: 8px; }
.nh-btn { display: inline-block; padding: 9px 16px; border-radius: 999px; border: 1px solid var(--border-bright); color: #fff !important; background: rgba(16,22,46,.85); font-size: 14px; white-space: nowrap; transition: background .15s, transform .15s; }
.nh-btn:hover { background: #18204a; transform: translateY(-1px); }
.nh-btn-main { background: linear-gradient(135deg, var(--coral), #ff9a5a); border-color: transparent; color: #140a10 !important; font-weight: bold; }
.nh-btn-main:hover { background: linear-gradient(135deg, #ff8f86, #ffb07a); }
.nh-sec { border: 1px solid var(--border); border-radius: 14px; padding: 18px; background: linear-gradient(180deg, #0d1230, #0b0f24); min-width: 0; }
.nh-sec-lists { border-color: var(--coral); box-shadow: 0 0 18px rgba(255,123,114,.18); background: linear-gradient(180deg, #1a1030, #0b0f24 70%); }
.nh-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 12px; margin-bottom: 14px; }
.nh-head h2 { margin: 0 0 4px; color: #fff; font-size: 24px; }
.nh-sec-lists .nh-head h2 { font-size: 28px; color: var(--coral); }
.nh-head p { margin: 0; color: var(--muted); font-size: 14px; }
.nh-ltiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 12px; }
.nh-ltile { display: flex; flex-direction: column; border: 1px solid #2a3480; border-radius: 10px; overflow: hidden; background: #10162e; transition: transform .15s, border-color .15s; }
.nh-ltile:hover { transform: translateY(-3px); border-color: var(--coral); }
.nh-lposters { display: grid; grid-template-columns: repeat(3, 1fr); gap: 2px; background: #070a1c; aspect-ratio: 2/1; overflow: hidden; }
.nh-lposters img { width: 100%; height: 100%; object-fit: cover; }
.nh-ph { grid-column: 1 / -1; display: flex; align-items: center; justify-content: center; color: var(--muted); }
.nh-lmeta { display: flex; align-items: center; gap: 10px; padding: 10px; }
.nh-logo { width: 34px; height: 34px; border-radius: 8px; flex: none; }
.nh-lmeta strong { display: block; color: #fff; font-size: 14px; }
.nh-lmeta small { display: block; color: var(--muted); font-size: 12px; margin-top: 2px; }
.nh-strip { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 8px; scrollbar-width: thin; }
.nh-pcard { flex: 0 0 140px; width: 140px; min-width: 0; scroll-snap-align: start; display: flex; flex-direction: column; color: var(--text); }
.nh-pcard img { width: 140px; aspect-ratio: 2/3; object-fit: cover; border-radius: 8px; border: 1px solid #2a3480; transition: transform .15s, border-color .15s; background: #10162e; }
.nh-pcard:hover img { transform: scale(1.03); border-color: var(--teal); }
.nh-pt { margin-top: 6px; font-size: 13px; color: #fff; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.nh-ps { font-size: 12px; color: var(--muted); }
.nh-posts { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; }
.nh-post { display: flex; flex-direction: column; border: 1px solid #2a3480; border-radius: 10px; overflow: hidden; background: #10162e; transition: transform .15s, border-color .15s; }
.nh-post:hover { transform: translateY(-3px); border-color: var(--teal); }
.nh-post img, .nh-post-ph { width: 100%; aspect-ratio: 16/9; object-fit: cover; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, #1b2360, #3a1a3a); color: var(--muted); }
.nh-post-b { padding: 10px; }
.nh-post-b strong { display: block; color: #fff; font-size: 14px; line-height: 1.35; }
.nh-post-b small { display: block; color: var(--teal-dim); font-size: 12px; margin-top: 4px; }
.nh-empty { color: var(--muted); margin: 0; }
.nh-more h2 { margin: 0 0 8px; color: #fff; font-size: 18px; }
.nh-intro { color: var(--text); font-size: 14px; }
.nh-intro p { margin: 0 0 10px; }
.nh-mlinks { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; }
.nh-mlink { display: flex; flex-direction: column; padding: 0; overflow: hidden; border: 1px solid #2a3480; border-radius: 12px; background: #10162e; color: inherit; text-decoration: none !important; transition: transform .15s, border-color .15s; }
.nh-mlink:hover { transform: translateY(-3px); border-color: var(--teal); }
.nh-mthumb { position: relative; display: block; height: 248px; overflow: hidden; }
.nh-mprev-rss .nh-mthumb { background: linear-gradient(145deg, #3a1408 0%, #a34412 55%, #e8a23c 100%); }
.nh-mprev-favs .nh-mthumb { background: linear-gradient(145deg, #05241c 0%, #0b5340 55%, #2ee6a6 100%); }
.nh-mprev-files .nh-mthumb { background: linear-gradient(145deg, #10164a 0%, #2a3480 55%, #4a5cff 100%); }
.nh-mprev-contact .nh-mthumb { background: linear-gradient(145deg, #1a1030 0%, #4a1a68 55%, #c47cff 100%); }
.nh-mprev-other .nh-mthumb { background: linear-gradient(145deg, #10162e, #1b2360); }
.nh-micon { position: absolute; top: 8px; right: 8px; width: 28px; height: 28px; border-radius: 8px; background: rgba(0,0,0,.38); box-shadow: 0 0 0 1px rgba(255,255,255,.14); display: grid; place-items: center; color: #fff; font-size: 14px; line-height: 1; }
.nh-mprev-rss .nh-micon::before { content: "◎"; }
.nh-mprev-favs .nh-micon::before { content: "★"; }
.nh-mprev-files .nh-micon::before { content: "▣"; }
.nh-mprev-contact .nh-micon::before { content: "✉"; }
.nh-mprev-favorites .nh-micon::before { content: "♥"; }
.nh-mprev-other .nh-micon::before { content: "▸"; }
.nh-mprev-favorites .nh-mthumb { background: linear-gradient(145deg, #2a1020 0%, #6a1a38 55%, #ff7aa2 100%); }
.nh-mmock { position: absolute; left: 10px; right: 44px; top: 34px; display: flex; flex-direction: column; gap: 4px; }
.nh-mline { display: block; font-size: 11px; line-height: 1.25; color: #fff; background: rgba(7,10,28,.48); border-radius: 4px; padding: 3px 6px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.nh-mbar { height: 10px; padding: 0; background: rgba(255,255,255,.22); }
.nh-mbar-s { width: 54%; }
.nh-mbar-m { width: 76%; }
.nh-mprev-contact .nh-mbar { width: 42%; height: 8px; }
.nh-mprev-contact .nh-mbar-s { width: 58%; }
.nh-mprev-contact .nh-mbar-m { width: 100%; height: 28px; }
.nh-more-login { margin: 0 0 14px; color: var(--muted); font-size: 15px; }
.nh-more-login a { color: var(--teal); font-weight: 650; }
.nh-mlink { display: block; text-decoration: none; color: inherit; }
.nh-mlink-title { display: block; text-decoration: none; color: inherit; }
.nh-mlink strong { display: block; color: var(--teal); font-size: 14px; padding: 10px 12px 0; }
.nh-mmeta { display: block; font-style: normal; color: var(--teal-dim); font-size: 11px; padding: 2px 12px 0; letter-spacing: .01em; }
.nh-mlink small { display: block; color: var(--muted); font-size: 12px; margin: 2px 0 12px; padding: 0 12px; }
.nh-mlink small p { margin: 0; }
a.nh-mline { text-decoration: none; color: #fff; }
a.nh-mline:hover { background: rgba(7,10,28,.72); }
.nh-mline-img { display: flex; align-items: center; gap: 6px; }
.nh-mline-img img { width: 22px; height: 32px; object-fit: cover; border-radius: 3px; flex: 0 0 auto; background: rgba(0,0,0,.25); }
@media (max-width: 900px) { .nh-mlinks { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; } }
@media (max-width: 420px) { .nh-mlinks { grid-template-columns: 1fr; } }
@media (max-width: 900px) { .nh-posts { grid-template-columns: repeat(2, 1fr); } .nh-mosaic { left: 25%; } }
@media (max-width: 600px) {
  .nh { gap: 12px; }
  .nh-hero { min-height: 0; border-radius: 12px; }
  .nh-hero::after { background: linear-gradient(180deg, rgba(7,10,28,.55), #070a1c 85%); }
  .nh-mosaic { inset: -10px; grid-template-columns: repeat(4, 1fr); opacity: .35; }
  .nh-hero-in { padding: 26px 16px; }
  .nh-tag { font-size: 14px; }
  .nh-btn { padding: 8px 13px; font-size: 13px; }
  .nh-sec { padding: 12px; border-radius: 12px; }
  .nh-head { flex-direction: column; align-items: flex-start; }
  .nh-head h2, .nh-sec-lists .nh-head h2 { font-size: 21px; }
  .nh-ltiles { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; }
  .nh-lmeta { padding: 8px; gap: 6px; }
  .nh-logo { width: 26px; height: 26px; }
  .nh-lmeta strong { font-size: 12.5px; }
  .nh-lmeta small { display: none; }
  .nh-pcard { flex-basis: 112px; width: 112px; }
  .nh-pcard img { width: 112px; }
  .nh-posts { grid-template-columns: 1fr 1fr; gap: 8px; }
  .nh-post-b strong { font-size: 13px; }
}
.nh-sr { position:absolute; width:1px; height:1px; padding:0; margin:-1px; overflow:hidden; clip:rect(0,0,0,0); white-space:nowrap; border:0; }

/* ---- Nomad Games: Play (GamePix browser games) ---- */
.tvl-chips a.gm-playchip { border-color: var(--teal); color: #08131a; background: linear-gradient(135deg, var(--teal), #6ff3c4); font-weight: bold; }
.tvl-chips a.gm-playchip:hover, .tvl-chips a.gm-playchip.on { color: #08131a; border-color: var(--gold); box-shadow: 0 0 10px rgba(46,230,166,.45); }
.pl-btn { display: inline-block; padding: 8px 15px; border-radius: 999px; background: linear-gradient(135deg, var(--teal), #6ff3c4); color: #08131a !important; font-weight: bold; font-size: 13px; white-space: nowrap; text-decoration: none !important; box-shadow: 0 0 10px rgba(46,230,166,.35); }
.pl-btn:hover { filter: brightness(1.08); }
.pl-hero { position: relative; overflow: hidden; border: 1px solid var(--border); border-radius: 14px; margin: 2px 0 12px; box-shadow: var(--glow); background: #0a0f26; }
.pl-hero-bg { position: absolute; inset: -20px; background-size: cover; background-position: center; filter: blur(18px) saturate(1.2); opacity: .35; }
.pl-hero-in { position: relative; display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); gap: 20px; align-items: center; padding: 22px; background: linear-gradient(90deg, rgba(7,10,28,.92), rgba(7,10,28,.55)); }
.pl-kicker { display: inline-block; font-size: 12px; letter-spacing: .06em; text-transform: uppercase; color: var(--teal); font-weight: bold; margin-bottom: 6px; }
.pl-hero h1 { margin: 0 0 8px; color: var(--coral); font-size: clamp(24px, 3.4vw, 38px); line-height: 1.1; }
.pl-hero .tvl-intro { margin: 0 0 12px; }
.pl-search { display: flex; gap: 6px; max-width: 460px; margin: 8px 0 4px; }
.pl-search input { flex: 1 1 auto; min-width: 0; padding: 8px 12px; border-radius: 999px; border: 1px solid var(--border); background: rgba(16,22,46,.9); color: var(--text); font-size: 14px; }
.pl-search .btn { border-radius: 999px; }
.pl-feat { position: relative; display: block; border-radius: 12px; overflow: hidden; border: 1px solid var(--border-bright); aspect-ratio: 16 / 10; background: #10162e; }
.pl-feat img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .25s; }
.pl-feat:hover img { transform: scale(1.04); }
.pl-feat-cap { position: absolute; left: 0; right: 0; bottom: 0; padding: 30px 14px 12px; display: flex; flex-wrap: wrap; align-items: flex-end; gap: 4px 10px; background: linear-gradient(transparent, rgba(5,8,22,.92)); color: #fff; }
.pl-feat-cap small { flex: 1 0 100%; color: var(--gold); font-size: 11px; text-transform: uppercase; letter-spacing: .06em; }
.pl-feat-cap strong { font-size: 18px; margin-right: auto; }
.pl-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(170px, 1fr)); gap: 14px 12px; }
.pl-card { display: flex; flex-direction: column; min-width: 0; color: var(--text); text-decoration: none !important; }
.pl-thumb { position: relative; display: block; aspect-ratio: 16 / 10; border-radius: 10px; overflow: hidden; border: 1px solid #2a3480; background: #10162e; }
.pl-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .2s; }
.pl-play { position: absolute; left: 50%; top: 50%; width: 44px; height: 44px; margin: -22px 0 0 -22px; border-radius: 50%; display: flex; align-items: center; justify-content: center; padding-left: 3px; box-sizing: border-box; font-size: 17px; color: #08131a; background: var(--teal); opacity: 0; transform: scale(.8); transition: opacity .2s, transform .2s; box-shadow: 0 0 14px rgba(46,230,166,.6); }
.pl-card:hover .pl-thumb { border-color: var(--teal); }
.pl-card:hover .pl-thumb img { transform: scale(1.05); }
.pl-card:hover .pl-play { opacity: 1; transform: scale(1); }
.pl-ct { margin-top: 6px; font-size: 13px; color: #fff; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pl-cs { font-size: 11px; color: var(--muted); }
.pl-more { margin-left: auto; font-size: 12px; font-weight: normal; }
.pl-sec .section-head { display: flex; align-items: center; gap: 8px; }
.pl-cats .tag small { color: var(--muted); }
.pl-attr { margin: 18px 0 4px; font-size: 12px; color: var(--muted); text-align: center; }
.pl-attr a { color: inherit; text-decoration: underline; }
.pl-promo { border: 1px solid var(--teal-dim, #1d8f6a); border-radius: 14px; padding: 14px; margin: 4px 0 14px; background: linear-gradient(135deg, rgba(46,230,166,.10), rgba(59,79,216,.12)); box-shadow: 0 0 12px rgba(46,230,166,.15); }
.pl-promo-head { display: flex; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 10px; }
.pl-promo-head h2 { margin: 0; color: var(--teal); font-size: 18px; }
.pl-promo-head p { margin: 2px 0 0; font-size: 13px; color: var(--muted); }
.pl-strip { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; padding-bottom: 6px; scrollbar-width: thin; -webkit-overflow-scrolling: touch; }
.pl-strip .pl-card { flex: 0 0 180px; width: 180px; scroll-snap-align: start; }
/* game page */
.pl-ghead { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 8px 14px; margin: 4px 0 10px; }
.pl-gmeta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.pl-gmeta .tag { margin: 0; }
.pl-stage { background: radial-gradient(ellipse at center, rgba(59,79,216,.25), rgba(7,10,28,0) 70%); border-radius: 14px; padding: 4px 0 2px; }
.pl-player { position: relative; width: 100%; margin: 0 auto; background: #000; border: 1px solid var(--border-bright); border-radius: 12px; overflow: hidden; box-shadow: 0 0 22px rgba(59,79,216,.45); }
.pl-player iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; display: block; background: #000; }
.pl-player:fullscreen { max-width: none !important; width: 100vw; height: 100vh; aspect-ratio: auto !important; border: 0; border-radius: 0; }
.pl-player:-webkit-full-screen { max-width: none !important; width: 100vw; height: 100vh; border: 0; border-radius: 0; }
.pl-start { position: absolute; inset: 0; width: 100%; height: 100%; padding: 0; margin: 0; border: 0; cursor: pointer; background: #070a1c; color: #fff; font: inherit; overflow: hidden; }
.pl-start-bg { position: absolute; inset: -30px; background-size: cover; background-position: center; filter: blur(20px) brightness(.55); }
.pl-start-in { position: relative; height: 100%; display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 10px; padding: 16px; box-sizing: border-box; }
.pl-start-in img { width: min(320px, 70%); aspect-ratio: 16 / 10; object-fit: cover; border-radius: 10px; border: 1px solid rgba(255,255,255,.25); box-shadow: 0 8px 30px rgba(0,0,0,.5); }
.pl-bigplay { width: 74px; height: 74px; border-radius: 50%; display: flex; align-items: center; justify-content: center; padding-left: 6px; box-sizing: border-box; font-size: 30px; color: #08131a; background: var(--teal); box-shadow: 0 0 0 8px rgba(46,230,166,.25), 0 0 30px rgba(46,230,166,.6); transition: transform .15s; }
.pl-start:hover .pl-bigplay { transform: scale(1.08); }
.pl-start-in strong { font-size: 18px; text-shadow: 0 2px 8px #000; }
.pl-start-in small { color: #cfd6ee; font-size: 12px; }
.pl-tools { display: flex; justify-content: center; flex-wrap: wrap; gap: 8px; margin: 10px 0 4px; }
.pl-how { font-size: 13px; color: var(--muted); }
/* homepage games-strip Play tile */
.nh-playtile { position: relative; }
.nh-playimgs { position: relative; display: grid; grid-template-rows: repeat(4, 1fr); width: 140px; aspect-ratio: 2/3; border-radius: 8px; overflow: hidden; border: 1px solid var(--teal); box-shadow: 0 0 12px rgba(46,230,166,.35); background: #10162e; }
.nh-playimgs img { width: 140px; height: 100%; aspect-ratio: auto; object-fit: cover; border: 0; border-radius: 0; display: block; min-height: 0; }
.nh-pcard.nh-playtile:hover img { transform: none; }
.nh-playbadge { position: absolute; left: 50%; top: 105px; width: 52px; height: 52px; margin: -26px 0 0 -26px; border-radius: 50%; display: flex; align-items: center; justify-content: center; padding-left: 4px; box-sizing: border-box; font-size: 22px; color: #08131a; background: var(--teal); box-shadow: 0 0 0 6px rgba(46,230,166,.3), 0 0 20px rgba(0,0,0,.6); }
.nh-playtile .nh-pt { color: var(--teal); font-weight: bold; }
@media (max-width: 760px) {
  .pl-hero-in { grid-template-columns: minmax(0, 1fr); gap: 12px; padding: 14px; }
  .pl-feat { order: -1; }
  .pl-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px 8px; }
  .pl-ct { font-size: 12px; }
  .pl-strip .pl-card { flex-basis: 150px; width: 150px; }
  .pl-promo-head { flex-wrap: wrap; }
  .pl-player { max-width: 100% !important; }
  .pl-player.pl-portrait { max-width: min(100%, 420px) !important; }
  .pl-bigplay { width: 60px; height: 60px; font-size: 24px; }
  .pl-start-in strong { font-size: 15px; }
}

/* Slim logo bar; mobile nav wraps (home-v3, 2026-11-24) */
.logo { line-height: 1; }
.tagline { line-height: 1.3; }
@media (max-width: 800px) {
  .nav {
    flex-direction: column;
    align-items: stretch;
    gap: 8px;
    padding: 8px 10px;
  }
  .nav-links {
    flex: 0 0 auto;
    width: 100%;
    min-width: 0;
    flex-wrap: wrap;
    overflow-x: visible;
    -webkit-overflow-scrolling: auto;
    order: 1;
  }
  .nav-links a,
  .nav-links .drop > span {
    flex: 0 0 auto;
    white-space: nowrap;
  }
  .nav-util {
    order: 2;
    margin-left: 0;
    width: 100%;
    display: flex;
    flex-wrap: nowrap;
    align-items: center;
    gap: 8px;
  }
  .search-form {
    flex: 1 1 auto;
    min-width: 0;
    margin-left: 0;
    order: 0;
  }
  .search-form input[type="text"] {
    width: 100%;
    min-width: 0;
    flex: 1;
  }
  .nav-auth { flex: 0 0 auto; }
  .nav-admin {
    order: 3;
    width: 100%;
    margin-left: 0;
  }
}

/* Where-to-Watch dedicated pages */
.ww-free .ww-chip { color: var(--gold); background: rgba(230,200,74,0.10); border-color: rgba(230,200,74,0.45); }
.ww-title a { color: inherit; text-decoration: none; }
.ww-title a:hover { text-decoration: underline; }
.ww-logo { position: relative; }
.ww-badge {
  position: absolute; left: 0; right: 0; bottom: 0;
  font-size: 8px; font-weight: bold; letter-spacing: .04em;
  color: #1a1400; background: var(--gold); padding: 1px 0; line-height: 1.2;
}
.ad-slot { display: block; width: 100%; margin: 16px 0; }
.ad-slot-wtw { min-height: 90px; }
.ad-slot-wtw-mid { min-height: 250px; }
.wtw-page { max-width: 100%; }
.wtw-hero { display: flex; gap: 18px; align-items: flex-start; margin: 0 0 8px; }
.wtw-poster { flex: 0 0 120px; display: block; border-radius: 8px; overflow: hidden; border: 1px solid var(--border); }
.wtw-poster img { display: block; width: 120px; height: auto; }
.wtw-hero-body { min-width: 0; flex: 1; }
.wtw-kicker { margin: 0 0 6px; font-size: 13px; color: var(--muted); }
.wtw-kicker a { color: var(--teal); text-decoration: none; }
.wtw-kicker a:hover { text-decoration: underline; }
.wtw-h1 { margin: 0 0 8px; font-size: 26px; line-height: 1.2; color: var(--gold); }
.wtw-intro { margin: 10px 0 8px; font-size: 15px; line-height: 1.55; max-width: 46em; }
.wtw-back { margin: 0; }
.wtw-back a { color: var(--teal); text-decoration: none; }
.wtw-back a:hover { text-decoration: underline; }
.wtw-full { margin-top: 8px; }
.wtw-faq, .wtw-related { margin: 22px 0 10px; }
.wtw-faq h2, .wtw-related h2 { margin: 0 0 10px; font-size: 18px; color: var(--gold); }
.wtw-faq-item { border: 1px solid var(--border); border-radius: 8px; padding: 8px 12px; margin: 0 0 8px; background: rgba(11,15,36,0.45); }
.wtw-faq-item summary { cursor: pointer; font-weight: bold; color: var(--text); }
.wtw-faq-item p { margin: 8px 0 4px; line-height: 1.5; }
.wtw-card-link { display: inline-block; margin: 4px 0 8px 2px; font-size: 12px; color: var(--teal); text-decoration: none; }
.wtw-card-link:hover { text-decoration: underline; }
@media (max-width: 480px) {
  .wtw-hero { flex-direction: column; }
  .wtw-poster, .wtw-poster img { width: 96px; }
  .wtw-h1 { font-size: 22px; }
  .ad-slot-wtw-mid { min-height: 120px; }
}

/* New-on / Recently-left availability pages */
.avail-page { max-width: 100%; }
.avail-head { margin: 0 0 14px; }
.avail-kicker { margin: 0 0 6px; font-size: 13px; color: var(--muted); }
.avail-kicker a { color: var(--teal); text-decoration: none; }
.avail-kicker a:hover { text-decoration: underline; }
.avail-head h1 { margin: 0 0 8px; font-size: 26px; line-height: 1.2; color: var(--gold); }
.avail-intro { margin: 8px 0; font-size: 15px; line-height: 1.55; max-width: 46em; }
.avail-note, .avail-attr, .avail-empty { font-size: 13px; color: var(--muted); line-height: 1.5; max-width: 46em; }
.avail-sec { margin: 18px 0; }
.avail-sec h2 { margin: 0 0 10px; font-size: 18px; color: var(--gold); }
.avail-sec h3 { margin: 12px 0 8px; font-size: 15px; }
.avail-count { font-size: 13px; color: var(--muted); font-weight: normal; }
.avail-archive { margin: 22px 0 10px; }
.avail-archive h2 { font-size: 16px; color: var(--gold); }
.avail-archive ul { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px 14px; }
.avail-archive a { color: var(--teal); text-decoration: none; }
.avail-archive a:hover { text-decoration: underline; }
.avail-archive .is-current a { color: var(--text); font-weight: bold; }
.avail-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 10px; margin: 12px 0 18px; }
.avail-tile { display: flex; flex-direction: column; gap: 4px; padding: 12px 14px; border: 1px solid var(--border); border-radius: 10px; text-decoration: none; color: var(--text); background: rgba(11,15,36,0.45); }
.avail-tile b { color: var(--gold); }
.avail-tile span { font-size: 13px; color: var(--muted); }
.avail-tile:hover { border-color: var(--teal); }
.wtw-avail { margin: 10px 0 16px; font-size: 13px; line-height: 1.5; }
.wtw-avail a { color: var(--teal); text-decoration: none; }
.wtw-avail a:hover { text-decoration: underline; }
.avail-foot { margin-top: 8px; }
@media (max-width: 480px) {
  .avail-head h1 { font-size: 22px; }
}

/* Amazon Associates disclosure + merch/buy pages */
.amazon-disclosure { font-size: 12px; color: var(--muted); margin: 10px auto 8px; line-height: 1.45; text-align: center; width: 100%; }
.amz-disclosure, .amz-trial { font-size: 13px; color: var(--muted); line-height: 1.5; margin: 8px 0 0; max-width: 46em; }
.amz-trial a, .amz-disclosure a { color: var(--teal); }
.ww-amz { margin-top: 10px; }
.buy-facts { list-style: none; padding: 0; margin: 8px 0; display: flex; flex-wrap: wrap; gap: 6px 18px; font-size: 14px; }
.buy-facts span { color: var(--muted); margin-right: 6px; }
.buy-facts a { color: var(--teal); text-decoration: none; }
.buy-facts a:hover { text-decoration: underline; }
.buy-shop { margin: 18px 0; }
.buy-shop h2, .buy-cast h2 { margin: 0 0 8px; font-size: 18px; color: var(--gold); }
.buy-shop-intro { font-size: 14px; color: var(--muted); max-width: 46em; }
.buy-links { list-style: none; padding: 0; margin: 12px 0; display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 12px; }
.buy-link-card { border: 1px solid var(--border); border-radius: 10px; padding: 12px 14px; background: rgba(11,15,36,0.45); }
.buy-link { display: inline-block; font-weight: bold; color: var(--gold); text-decoration: none; margin-bottom: 4px; }
.buy-link:hover { text-decoration: underline; }
.buy-link-card p { margin: 4px 0 0; font-size: 13px; color: var(--muted); line-height: 1.45; }
.buy-extra a { color: var(--teal); text-decoration: none; }
.buy-extra a:hover { text-decoration: underline; }
.title-buy, .wtw-buy { margin: 8px 0 0; font-size: 14px; }
.title-buy a, .wtw-buy a, .ww-buy { color: var(--teal); text-decoration: none; }
.title-buy a:hover, .wtw-buy a:hover, .ww-buy:hover { text-decoration: underline; }
.buy-watch { margin-bottom: 18px; }

/* Free-with-ads genre list pages */
.free-head { margin: 0 0 16px; }
.free-kicker { font-size: 13px; color: var(--muted); margin: 0 0 6px; }
.free-kicker a { color: var(--teal); text-decoration: none; }
.free-kicker a:hover { text-decoration: underline; }
.free-head h1 { margin: 0 0 8px; font-size: 28px; line-height: 1.2; }
.free-intro { max-width: 48em; font-size: 15px; line-height: 1.55; color: var(--text); margin: 0 0 8px; }
.free-switch, .free-attr, .free-top-svcs { font-size: 14px; color: var(--muted); margin: 8px 0 0; max-width: 48em; }
.free-switch a, .free-attr a { color: var(--teal); text-decoration: none; }
.free-switch a:hover, .free-attr a:hover { text-decoration: underline; }
.free-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 10px; margin: 16px 0 22px; }
.free-tile { display: block; border: 1px solid var(--border); border-radius: 10px; padding: 12px 14px; text-decoration: none; background: rgba(11,15,36,0.45); }
.free-tile b { display: block; color: var(--gold); margin-bottom: 4px; }
.free-tile span { font-size: 13px; color: var(--muted); }
.free-tile:hover { border-color: var(--teal); }
.free-featured h2, .free-other h2 { margin: 18px 0 10px; font-size: 18px; color: var(--gold); }
.free-svcs { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0 4px; }
.free-svc { display: inline-flex; align-items: center; gap: 4px; font-size: 11px; color: var(--teal); text-decoration: none; border: 1px solid var(--border); border-radius: 999px; padding: 2px 7px; }
.free-svc img { border-radius: 3px; }
.free-svc:hover { text-decoration: underline; }
.free-other ul { list-style: none; padding: 0; margin: 0; display: flex; flex-wrap: wrap; gap: 8px 16px; }
.free-other a { color: var(--teal); text-decoration: none; }
.free-other a:hover { text-decoration: underline; }
.browse-free, .title-free { margin: 8px 0 0; font-size: 14px; }
.browse-free a, .title-free a { color: var(--teal); text-decoration: none; }
.browse-free a:hover, .title-free a:hover { text-decoration: underline; }
.ww-free { color: var(--teal); text-decoration: none; margin-left: 8px; }
.ww-free:hover { text-decoration: underline; }


/* Games Like pages */
.like-kicker { font-size: 13px; color: var(--muted); margin: 0 0 6px; }
.like-kicker a, .like-switch a, .like-attr a, .like-store a { color: var(--teal); text-decoration: none; }
.like-kicker a:hover, .like-switch a:hover, .like-attr a:hover, .like-store a:hover { text-decoration: underline; }
.like-switch, .like-attr { font-size: 14px; color: var(--muted); margin: 8px 0 0; max-width: 48em; }
.like-sec { margin: 18px 0 22px; }
.like-sec h2 { margin: 0 0 10px; font-size: 18px; color: var(--gold); }
.like-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 10px; }
.like-tile { display: block; border: 1px solid var(--border); border-radius: 10px; padding: 10px 12px; text-decoration: none; background: rgba(11,15,36,0.45); overflow: hidden; }
.like-tile img { width: 100%; height: 90px; object-fit: cover; border-radius: 6px; margin-bottom: 6px; }
.like-tile b { display: block; color: var(--gold); margin-bottom: 3px; }
.like-tile span { font-size: 12px; color: var(--muted); }
.like-tile:hover { border-color: var(--teal); }
.like-store { margin: 4px 0 0; font-size: 12px; }
.gm-like, .title-like, .pl-like { margin: 8px 0 0; font-size: 14px; }
.gm-like a, .title-like a, .pl-like a { color: var(--teal); text-decoration: none; }
.gm-like a:hover, .title-like a:hover, .pl-like a:hover { text-decoration: underline; }

/* Filmography pages — keep selectors under .filmo / .person-filmo */
.person-filmo { margin: 8px 0 0; font-size: 14px; }
.person-filmo a { color: var(--teal); text-decoration: none; }
.person-filmo a:hover { text-decoration: underline; }
.filmo { max-width: 52em; }
.filmo-head { display: flex; gap: 16px; align-items: flex-start; margin-bottom: 8px; }
.filmo-photo { width: 92px; height: auto; border-radius: 8px; flex: 0 0 auto; background: var(--bg-table); }
.filmo-kicker { font-size: 13px; color: var(--muted); margin: 0 0 6px; }
.filmo-kicker a { color: var(--teal); text-decoration: none; }
.filmo-kicker a:hover { text-decoration: underline; }
.filmo-head h1 { margin: 0 0 8px; font-size: 26px; }
.filmo-tab { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }
.filmo-nav { display: flex; flex-wrap: wrap; gap: 8px; margin: 14px 0 18px; }
.filmo-nav label { cursor: pointer; border: 1px solid var(--border); border-radius: 999px; padding: 5px 12px; font-size: 14px; color: var(--coral); }
.filmo-nav label span { color: var(--muted); font-size: 12px; margin-left: 4px; }
.filmo-nav label:hover { border-color: var(--teal); }
#filmo-tab-all:checked ~ .filmo-nav label[for="filmo-tab-all"],
#filmo-tab-movies:checked ~ .filmo-nav label[for="filmo-tab-movies"],
#filmo-tab-tv:checked ~ .filmo-nav label[for="filmo-tab-tv"],
#filmo-tab-upcoming:checked ~ .filmo-nav label[for="filmo-tab-upcoming"] { border-color: var(--teal); background: rgba(59,79,216,0.18); }
#filmo-tab-movies:checked ~ .filmo-panels .filmo-tv,
#filmo-tab-movies:checked ~ .filmo-panels .filmo-upcoming,
#filmo-tab-tv:checked ~ .filmo-panels .filmo-movies,
#filmo-tab-tv:checked ~ .filmo-panels .filmo-upcoming,
#filmo-tab-upcoming:checked ~ .filmo-panels .filmo-movies,
#filmo-tab-upcoming:checked ~ .filmo-panels .filmo-tv { display: none; }
.filmo-sec { margin: 0 0 22px; }
.filmo-sec h2 { margin: 0 0 8px; font-size: 18px; color: var(--gold); }
.filmo-note, .filmo-attr { font-size: 13px; color: var(--muted); margin: 0 0 10px; max-width: 48em; }
.filmo-list { list-style: none; margin: 0; padding: 0; }
.filmo-row { display: flex; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--border); align-items: flex-start; }
.filmo-poster { flex: 0 0 70px; width: 70px; height: 105px; display: block; background: var(--bg-table); border-radius: 6px; overflow: hidden; }
.filmo-poster img { width: 70px; height: 105px; object-fit: cover; display: block; }
.filmo-poster .ph { display: flex; align-items: center; justify-content: center; width: 70px; height: 105px; font-size: 11px; color: var(--muted); text-align: center; padding: 4px; }
.filmo-title { color: var(--gold); text-decoration: none; font-weight: 650; }
.filmo-title:hover { text-decoration: underline; }
.filmo-meta { margin: 4px 0; font-size: 13px; color: var(--muted); }
.filmo-year { color: var(--coral); margin-right: 6px; }
.filmo-kind { margin-right: 6px; }
.filmo-wtw { color: var(--teal); text-decoration: none; font-size: 13px; }
.filmo-wtw:hover { text-decoration: underline; }
@media (max-width: 520px) {
  .filmo-head { flex-direction: row; }
  .filmo-photo { width: 72px; }
  .filmo-head h1 { font-size: 22px; }
}

/* Wikipedia / Wikidata facts on person and title pages */
.wiki-facts { margin: 18px 0 20px; max-width: 52em; }
.wiki-facts-title { margin: 0 0 10px; font-size: 18px; color: var(--gold); }
.wiki-facts-list { margin: 0; display: grid; gap: 6px 16px; }
.wiki-facts-list > div { display: grid; grid-template-columns: 8em 1fr; gap: 8px; align-items: baseline; }
.wiki-facts-list dt { margin: 0; font-weight: 650; color: var(--muted); font-size: 13px; }
.wiki-facts-list dd { margin: 0; }
.wiki-awards-title { margin: 14px 0 6px; font-size: 15px; color: var(--gold); }
.wiki-awards { margin: 0 0 8px; padding: 0 0 0 1.15em; }
.wiki-awards li { margin: 0 0 4px; }
.wiki-year { color: var(--coral); font-variant-numeric: tabular-nums; }
.wiki-summary { margin: 12px 0 8px; }
.wiki-summary p { margin: 0; max-width: 48em; }
.wiki-attr { font-size: 13px; color: var(--muted); margin: 10px 0 0; max-width: 48em; }
.wiki-attr a { color: var(--teal); text-decoration: none; }
.wiki-attr a:hover { text-decoration: underline; }
@media (max-width: 520px) {
  .wiki-facts-list > div { grid-template-columns: 6.2em 1fr; }
}

/* Is <Title> on <Service>? pages */
.on-kicker { margin: 0 0 6px; font-size: 14px; }
.on-kicker a { color: var(--gold); text-decoration: none; }
.on-kicker a:hover { text-decoration: underline; }
.on-answer { margin: 12px 0 0; max-width: 46em; font-size: 17px; line-height: 1.45; }
.on-yesno { display: inline-block; font-weight: 750; margin-right: 6px; padding: 1px 8px; border-radius: 999px; }
.on-answer-yes .on-yesno { background: #1f6f4a; color: #fff; }
.on-answer-no .on-yesno { background: var(--coral, #c45c4a); color: #fff; }
.on-watch { margin: 12px 0 0; }
.on-body { margin: 8px 0 20px; max-width: 52em; }
.on-intro { margin: 0 0 8px; }
.on-alts, .on-services { margin: 0 0 12px; padding: 0 0 0 1.15em; }
.on-services { display: flex; flex-wrap: wrap; gap: 6px 14px; list-style: none; padding: 0; }
.on-services a { color: var(--teal); text-decoration: none; }
.on-services a:hover, .on-services a.active { text-decoration: underline; }
.on-services a.on-yes { font-weight: 650; }
.on-internal { margin: 10px 0 0; font-size: 14px; }
.on-inline { margin: 10px 0 0; font-size: 14px; max-width: 52em; }
.on-inline a { color: var(--teal); text-decoration: none; }
.on-inline a:hover { text-decoration: underline; }

/* Coming soon / release date countdowns */
.cd-hub h1 { margin: 0 0 8px; }
.cd-intro { margin: 0 0 8px; max-width: 52em; }
.cd-sub { margin: 0 0 16px; }
.cd-list { list-style: none; margin: 0 0 22px; padding: 0; }
.cd-row { display: flex; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--border); align-items: flex-start; }
.cd-poster { flex: 0 0 70px; width: 70px; height: 105px; display: block; background: var(--bg-table, #222); border-radius: 6px; overflow: hidden; }
.cd-poster img { width: 70px; height: 105px; object-fit: cover; display: block; }
.cd-poster .ph { display: flex; align-items: center; justify-content: center; width: 70px; height: 105px; font-size: 11px; color: var(--muted); text-align: center; padding: 4px; }
.cd-title { color: var(--gold); text-decoration: none; font-weight: 650; }
.cd-title:hover { text-decoration: underline; }
.cd-phrase { margin: 4px 0; }
.cd-links, .cd-internal, .cd-kicker { font-size: 14px; margin: 6px 0 0; }
.cd-kicker a, .cd-links a, .cd-internal a { color: var(--teal); text-decoration: none; }
.cd-kicker a:hover, .cd-links a:hover, .cd-internal a:hover { text-decoration: underline; }
.cd-answer { margin: 10px 0 0; font-size: 18px; }
.cd-days { font-weight: 750; color: var(--gold); }
.cd-season { margin: 0; color: var(--muted); }
.cd-attr { margin: 8px 0 16px; max-width: 48em; }
.cd-others { margin: 0 0 12px; padding: 0 0 0 1.15em; }
.title-coming { margin: 8px 0 0; }
.title-coming a { color: var(--teal); }

/* Cast of <Title> pages */
.cast-intro { max-width: 52em; margin: 8px 0 16px; }
.cast-full { list-style: none; margin: 0 0 16px; padding: 0; }
.cast-row { display: flex; gap: 12px; padding: 8px 0; border-bottom: 1px solid var(--border); align-items: flex-start; }
.cast-photo { flex: 0 0 70px; width: 70px; height: 105px; display: block; background: var(--bg-table, #222); border-radius: 6px; overflow: hidden; }
.cast-photo img { width: 70px; height: 105px; object-fit: cover; display: block; }
.cast-photo .ph { display: flex; align-items: center; justify-content: center; width: 70px; height: 105px; font-size: 11px; color: var(--muted); text-align: center; padding: 4px; }
.cast-name { color: var(--gold); font-weight: 650; text-decoration: none; }
.cast-name:hover { text-decoration: underline; }
.cast-filmo, .cast-all, .title-cast-link a { color: var(--teal); text-decoration: none; font-size: 13px; }
.cast-filmo:hover, .cast-all:hover, .title-cast-link a:hover { text-decoration: underline; }
.cast-dirs a { color: var(--gold); text-decoration: none; }
.cast-dirs a:hover { text-decoration: underline; }
.cast-all { font-weight: 500; font-size: 14px; margin-left: 8px; }

.cast-ep { color: var(--muted); font-size: 13px; }
/* Favorites export (CSS ?v=88) */
.favx-intro { max-width: 52em; }
.favx-all { display: inline-block; margin: 6px 0 10px; cursor: pointer; }
.favx-list { list-style: none; margin: 0 0 14px; padding: 0; max-width: 52em; }
.favx-item { padding: 10px 12px; margin: 0 0 8px; border: 1px solid var(--border); border-radius: 8px; }
.favx-item label { cursor: pointer; display: flex; gap: 8px; align-items: baseline; flex-wrap: wrap; }
.favx-name { color: var(--gold); font-weight: 650; }
.favx-count { font-size: 13px; }
.favx-meta { font-size: 13px; margin: 4px 0 0 26px; line-height: 1.5; }
.favx-meta code { color: var(--teal); }
.favx .btn:disabled { opacity: .5; cursor: not-allowed; }
.cast-section { margin: 24px 0 16px; }
.cast-section h2 { margin: 0 0 8px; font-size: 18px; color: var(--gold); }
.cast-more-wrap { margin: 8px 0 20px; }
.cast-full .is-more { display: none; }
.cast-full .is-more.is-shown { display: flex; }
.cast-row.is-more { padding: 6px 0; }


/* How to Play pages (CSS ?v=67) */
.htp-page .htp-kicker { margin: 0 0 6px; font-size: 13px; }
.htp-page .htp-kicker a { color: var(--teal); text-decoration: none; }
.htp-page .htp-kicker a:hover { text-decoration: underline; }
.htp-page .htp-meta { margin: 8px 0 0; display: flex; flex-wrap: wrap; gap: 8px; align-items: center; }
.htp-hero { display: flex; flex-wrap: wrap; gap: 16px; align-items: center; margin: 8px 0 16px; }
.htp-thumb img { display: block; width: 200px; height: auto; border-radius: 8px; }
.htp-cta .btn { display: inline-block; }
.htp-sec { margin: 0 0 18px; }
.htp-sec h2 { font-size: 1.15rem; margin: 0 0 8px; }
.htp-sec p { margin: 0 0 8px; line-height: 1.55; }
.htp-more { font-size: 14px; }

/* Weekly trending pages (CSS ?v=68) */
.wt-page .wt-kicker { margin: 0 0 6px; font-size: 13px; }
.wt-page .wt-kicker a { color: var(--teal); text-decoration: none; }
.wt-page .wt-kicker a:hover { text-decoration: underline; }
.wt-nav { margin: 0 0 16px; }
.wt-list { list-style: none; padding: 0; }
.wt-list .cd-row { display: flex; gap: 12px; align-items: flex-start; }
.wt-rank { flex: 0 0 2rem; font-weight: 700; color: var(--gold, #c9a227); text-align: right; padding-top: 8px; }
.wt-archive { margin-top: 28px; }
.wt-weeks { margin: 8px 0 0; padding-left: 1.2em; }
.wt-also { margin-top: 24px; }

/* Wikipedia search / article pages (CSS ?v=69) */
.wk-page { max-width: 100%; }
.wk-kicker { margin: 0 0 6px; font-size: 13px; }
.wk-kicker a, .wk-credit a, .wk-attr a, .wk-related a { color: var(--teal); text-decoration: none; }
.wk-kicker a:hover, .wk-credit a:hover, .wk-attr a:hover, .wk-related a:hover { text-decoration: underline; }
.wk-intro, .wk-credit { margin: 0 0 14px; line-height: 1.55; }
.wk-form { display: flex; gap: 8px; margin: 0 0 8px; }
.wk-form input[type="search"] { flex: 1; min-width: 0; padding: 8px 10px; }
.wk-recent { margin: 0 0 12px; }
.wk-recent h2 { margin: 0 0 4px; font-size: 1.05rem; }
.wk-recent ul, .wk-history { margin: 0; padding-left: 1.2em; }
.wk-recent li, .wk-history li { margin: 0 0 3px; }
.wk-pager { display: flex; gap: 12px; align-items: center; margin: 16px 0; }
.wk-pager a { color: var(--teal); text-decoration: none; }
.wk-pager a:hover { text-decoration: underline; }
.wk-results { list-style: none; padding: 0; margin: 0 0 18px; }
.wk-results li { margin: 0 0 14px; }
.wk-rtitle { font-weight: 650; color: var(--teal); text-decoration: none; }
.wk-rtitle:hover { text-decoration: underline; }
.wk-snip { margin: 4px 0 0; font-size: 14px; line-height: 1.5; }
.wk-body { line-height: 1.6; }
.wk-body h2, .wk-body h3 { margin: 1.4em 0 0.5em; }
.wk-body p { margin: 0 0 0.85em; }
.wk-body img { max-width: 100%; height: auto; }
.wk-body table { max-width: 100%; overflow-x: auto; display: block; margin: 0 0 1em; }
.wk-related { margin-top: 28px; }
.wk-related ul { margin: 0 0 12px; padding-left: 1.2em; }
.wk-attr, .wk-limited { margin-top: 20px; font-size: 13px; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); border: 0; }

/* Admin remove control on wiki Recent Searches and history (visible to admin only). */
.wk-sitem { }
.wk-rm-form { display: inline; margin: 0 0 0 6px; padding: 0; }
.wk-rm {
  display: inline-block;
  border: 0;
  background: transparent;
  color: #8a8a8a;
  cursor: pointer;
  font-size: 14px;
  line-height: 1;
  padding: 0 3px;
  vertical-align: middle;
}
.wk-rm:hover, .wk-rm:focus { color: var(--coral); }
.wk-admin-form { display: inline-flex; align-items: center; gap: 8px; margin: 0; flex-wrap: wrap; }
.wk-del-opt { font-size: 13px; font-weight: 400; }
.wk-admin-hidden td { opacity: 0.75; }

/* ===== Blog: grid columns (admin setting), no-sidebar, new sidebar boxes ===== */
.blog-grid.cols-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.blog-grid.cols-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.blog-grid.cols-3 .blog-card .blog-thumb img, .blog-grid.cols-4 .blog-card .blog-thumb img { height: 130px; }
.blog-grid.cols-4 .blog-card-body h3 { font-size: 14px; }
@media (max-width: 1100px) {
  .blog-grid.cols-4.has-side { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 900px) {
  .blog-grid.cols-3, .blog-grid.cols-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media (max-width: 640px) {
  .blog-grid.cols-2, .blog-grid.cols-3, .blog-grid.cols-4 { grid-template-columns: 1fr; }
  .blog-grid.cols-3 .blog-card .blog-thumb img, .blog-grid.cols-4 .blog-card .blog-thumb img { height: auto; max-height: 220px; }
}
.blog-sidebar .blog-rcomments li, .blog-sidebar .blog-products li, .blog-sidebar .blog-cats li { margin: 0 0 9px; font-size: 13px; overflow-wrap: anywhere; }
.blog-sidebar .blog-rcomments .bc-name { color: var(--text); }
.blog-sidebar .blog-rcomments .bc-excerpt { display: block; color: var(--muted); font-size: 12px; margin-top: 1px; font-style: italic; }
.tv-rcomments li { margin: 0 0 9px; font-size: 13px; overflow-wrap: anywhere; }
.tv-rcomments .bc-name { color: var(--text); }
.tv-rcomments .bc-excerpt { display: block; color: var(--muted); font-size: 12px; margin-top: 1px; font-style: italic; }
.tvl-rcomments-box { margin: 8px 0 14px; }
.rc-panel h2, .tvl-rcomments-box h2 { margin: 0 0 8px; }
.blog-meta .blog-cat { color: var(--teal); text-decoration: none; }
.blog-meta .blog-cat:hover { text-decoration: underline; }

/* Admin > Pages (v89) */
.site-page .blog-post-head { display: flex; align-items: center; gap: 10px; justify-content: space-between; }
.site-page-edit { font-size: 12px; }
.pg-slug-row { display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.pg-box { border: 1px solid var(--border, #3b4fd8); border-radius: 6px; padding: 8px 12px 4px; margin: 12px 0; }
.pg-box legend { padding: 0 6px; font-weight: bold; }
.pg-menu-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 0 14px; transition: opacity .15s; }
.pg-upload { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 6px 0 2px; }
.row-item.row-page .ro { font-size: 12px; }
.row-item .nav-tab, .row-item .nav-ord { white-space: nowrap; font-size: 12px; }

/* ===== Admin sidebar (v90, still current in v91). Only exists on admin pages: every rule is scoped to body.adm-on / .adm-* ===== */
body.adm-on { --adm-w: 224px; --adm-rail: 52px; --adm-cur: var(--adm-w); padding-left: var(--adm-cur); transition: padding-left .15s ease; }
html.adm-collapsed body.adm-on { --adm-cur: var(--adm-rail); }
body.adm-on .nav-admin { display: none; }
.adm-side {
  position: fixed; top: 0; left: 0; bottom: 0; width: var(--adm-cur); z-index: 900;
  display: flex; flex-direction: column; background: var(--bg-nav);
  border-right: 1px solid var(--border); transition: width .15s ease, transform .2s ease; overflow: hidden;
}
.adm-mbar, .adm-backdrop { display: none; }
.adm-ic { width: 18px; height: 18px; flex: 0 0 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.adm-site, .adm-link, .adm-collapse {
  display: flex; align-items: center; gap: 10px; width: 100%; padding: 9px 15px;
  color: #9db0ff; text-decoration: none; font-size: 13px; line-height: 1.2; background: none; border: 0;
  border-left: 3px solid transparent; cursor: pointer; text-align: left; position: relative;
}
.adm-site { padding-top: 12px; padding-bottom: 12px; color: var(--teal-dim); font-weight: bold; border-bottom: 1px solid var(--border); }
.adm-site .adm-lbl { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.adm-link:hover, .adm-site:hover, .adm-collapse:hover { background: rgba(59, 79, 216, .2); color: var(--teal); }
.adm-item.is-active > .adm-link, .adm-item.is-open > .adm-link { background: rgba(46, 230, 166, .1); color: var(--teal); border-left-color: var(--teal); font-weight: bold; }
.adm-nav { flex: 1 1 auto; overflow-y: auto; overflow-x: hidden; padding: 4px 0 8px; scrollbar-width: thin; }
.adm-gh { padding: 14px 18px 4px; font-size: 10px; letter-spacing: .08em; text-transform: uppercase; color: var(--muted); white-space: nowrap; }
.adm-sub { padding: 2px 0 6px; background: rgba(0, 0, 0, .18); }
.adm-sublink { display: block; padding: 6px 14px 6px 46px; color: var(--muted); text-decoration: none; font-size: 12px; }
.adm-sublink:hover { color: var(--teal); }
.adm-sublink.is-active { color: var(--teal); font-weight: bold; }
.adm-badge { margin-left: auto; background: var(--coral); color: #0b0f24; border-radius: 10px; padding: 1px 7px; font-size: 11px; font-weight: bold; }
.adm-collapse { border-top: 1px solid var(--border); padding-top: 11px; padding-bottom: 11px; flex: 0 0 auto; }
.adm-collapse .adm-ic { transition: transform .15s ease; }
.adm-side a:focus-visible, .adm-side button:focus-visible, .adm-burger:focus-visible { outline: 2px solid var(--teal); outline-offset: -2px; }

@media (min-width: 901px) {
  html.adm-collapsed .adm-lbl, html.adm-collapsed .adm-sub { display: none; }
  html.adm-collapsed .adm-gh { padding: 8px 0 0; border-top: 1px solid rgba(59, 79, 216, .35); margin: 6px 10px 0; height: 1px; overflow: hidden; }
  html.adm-collapsed .adm-group:first-child .adm-gh { display: none; }
  html.adm-collapsed .adm-link, html.adm-collapsed .adm-site, html.adm-collapsed .adm-collapse { padding-left: 14px; padding-right: 14px; }
  html.adm-collapsed .adm-badge { position: absolute; top: 3px; right: 5px; margin: 0; padding: 0 4px; font-size: 9px; }
  html.adm-collapsed .adm-collapse .adm-ic { transform: rotate(180deg); }
}

@media (max-width: 900px) {
  body.adm-on { padding-left: 0; padding-top: 44px; }
  .adm-mbar {
    display: flex; align-items: center; gap: 10px; position: fixed; top: 0; left: 0; right: 0; height: 44px; z-index: 850;
    background: var(--bg-nav); border-bottom: 1px solid var(--border); padding: 0 8px;
  }
  .adm-burger { display: inline-flex; align-items: center; justify-content: center; width: 36px; height: 34px; background: var(--bg-table); color: #9db0ff; border: 1px solid var(--border); border-radius: 6px; cursor: pointer; }
  .adm-mtitle { color: var(--teal-dim); font-weight: bold; }
  .adm-side { width: 264px; max-width: 86vw; transform: translateX(-100%); z-index: 1001; box-shadow: none; }
  body.adm-open .adm-side { transform: none; box-shadow: 4px 0 18px rgba(0, 0, 0, .55); }
  .adm-backdrop { position: fixed; inset: 0; background: rgba(0, 0, 0, .55); z-index: 1000; }
  body.adm-open .adm-backdrop { display: block; }
  .adm-collapse { display: none; }
  .adm-link, .adm-site { padding-top: 11px; padding-bottom: 11px; }
}

/* ===== Admin dashboard widgets (v92, masonry v93, library card v94). Only on /admin: every rule is scoped to .dash / .dw ===== */
.dash-top { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.dash-top h2 { margin: 0; }
.dash-actions { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.dash-help { display: none; margin: 8px 0 0; }
.dash.editing .dash-help { display: block; }
.dash-reset { display: none; }
.dash.editing .dash-reset { display: inline-block; }
.dash-status { font-size: 12px; min-height: 1em; }
.dash-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(min(100%, 340px), 1fr)); gap: 12px; margin-top: 12px; align-items: start; }
/* Masonry (v93): dashboard.js adds .masonry, uses 1px rows and sets each card's row span to its height + gutter,
   so every card is only as tall as its content and the next card sits one gutter below it. No JS = plain grid. */
.dash-grid.masonry { grid-auto-rows: 1px; row-gap: 0; grid-auto-flow: row dense; }
.dash-grid.masonry > .dw { align-self: start; }
.dw { background: var(--bg-table); border: 1px solid var(--border); border-radius: var(--radius); min-width: 0; }
.dw-wide { grid-column: 1 / -1; }
.dw-head { display: flex; align-items: center; gap: 8px; padding: 8px 10px; border-bottom: 1px solid rgba(59, 79, 216, .45); }
.dw-head h3 { margin: 0; font-size: 14px; color: var(--gold); flex: 1 1 auto; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.dw-ic { width: 16px; height: 16px; flex: 0 0 16px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; color: #9db0ff; vertical-align: -3px; }
.dw-open { font-size: 12px; white-space: nowrap; }
.dw-grip { display: none; width: 14px; height: 18px; color: var(--muted); cursor: grab; }
.dw-grip svg { width: 14px; height: 18px; fill: currentColor; }
.dw-tools { display: none; gap: 4px; }
.dw-tools .btn { padding: 2px 7px; font-size: 12px; box-shadow: none; }
.dw-body { padding: 10px 12px 12px; overflow-wrap: anywhere; }
.dw-body > :first-child { margin-top: 0; }
.dw-body > :last-child { margin-bottom: 0; }
.dash.editing .dw-tools, .dash.editing .dw-grip { display: inline-flex; }
.dash.editing .dw { border-style: dashed; }
.dash.editing .dw-head { cursor: grab; }
.dash.editing .dw.is-dragging { opacity: .45; }
.dw.is-hidden { display: none; }
.dash.editing .dw.is-hidden { display: block; opacity: .6; }
.dash.editing .dw.is-hidden .dw-toggle { border-color: var(--teal-dim); color: var(--teal); }
.dw-list { list-style: none; margin: 0; padding: 0; }
.dw-list > li { padding: 6px 0; border-top: 1px solid rgba(59, 79, 216, .25); }
.dw-list > li:first-child { border-top: 0; }
.dw-ol { list-style: decimal; padding-left: 20px; }
.dw-when, .dw-small { font-size: 11px; }
.dw-ex { color: var(--muted); font-size: 12px; margin-top: 2px; }
.dw-sub { margin: 0 0 6px; font-size: 12px; }
.dw-h4 { margin: 10px 0 4px; font-size: 12px; color: var(--muted); text-transform: uppercase; letter-spacing: .06em; }
.dw-big { margin: 0 0 6px; font-size: 13px; }
.dw-big b { font-size: 22px; color: var(--coral); }
.dw-warn { color: var(--coral); }
.dw-more { margin: 8px 0 0; }
.dw-chips { display: flex; flex-wrap: wrap; gap: 4px; margin: 0 0 6px; }
.dw-stats { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin-bottom: 8px; }
.dw-stats > div { border: 1px solid rgba(59, 79, 216, .45); border-radius: 6px; padding: 6px; text-align: center; }
.dw-stats b { display: block; font-size: 20px; color: var(--teal); }
.dw-stats span { font-size: 11px; color: var(--muted); }
.dw-kv > li { display: flex; justify-content: space-between; gap: 10px; }
.dw-kv > li > span { color: var(--muted); }
.dw-kv > li > b { font-weight: normal; text-align: right; }
.dw-disk { margin-bottom: 10px; }
.dw-disk-l { font-size: 12px; margin-bottom: 4px; }
.dw-bar { height: 8px; border-radius: 4px; background: rgba(59, 79, 216, .25); overflow: hidden; }
.dw-bar > span { display: block; height: 100%; background: var(--teal-dim); }
.dw-bar.is-high > span { background: var(--coral); }
.dw-links { display: flex; flex-wrap: wrap; gap: 6px; }
.dw-links .btn { display: inline-flex; align-items: center; gap: 6px; box-shadow: none; }
.dw-scroll { overflow-x: auto; max-width: 100%; }
.dw .admin-table { font-size: 12px; width: max-content; min-width: 100%; }
.dw .admin-table th, .dw .admin-table td { padding: 4px 7px; white-space: nowrap; }
.dq-form .dq-row { display: grid; grid-template-columns: 110px minmax(0, 1fr); gap: 8px; align-items: center; margin: 0 0 8px; }
.dq-form .dq-row label { color: var(--muted); font-size: 12px; }
.dq-form input[type="text"], .dq-form input[type="number"], .dq-form select { width: 100%; max-width: 100%; }
.dq-form .dq-file { display: flex; gap: 6px; align-items: center; flex-wrap: wrap; min-width: 0; }
.dq-form .dq-file input[type="file"] { max-width: 100%; min-width: 0; }
.dq-form .dq-se { display: flex; gap: 6px; }
.dq-form .dq-se input { width: 70px; }
.dq-form .progress { margin: 0 0 6px; }
.dq-status { min-height: 1em; margin: 0 0 6px; font-size: 12px; }
.dq-foot { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin: 6px 0 4px; }
.dq-note { font-size: 11px; margin: 0; }
@media (max-width: 700px) { .dash-grid { grid-template-columns: minmax(0, 1fr); } }
@media (max-width: 520px) {
  .dw-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dq-form .dq-row { grid-template-columns: minmax(0, 1fr); gap: 3px; }
  .dw-head { flex-wrap: wrap; }
  .dash.editing .dw-tools { width: 100%; justify-content: flex-end; }
}

/* ===== Admin look v95: collapsible sidebar groups, View Blog, settings in the sidebar, collapsible
   dashboard cards, password eye + match indicator. Admin rules are scoped to .adm-* / .dw / .set-*;
   .pw-* only touches password inputs. ===== */
button.adm-gh { display: flex; align-items: center; gap: 6px; width: 100%; background: none; border: 0; cursor: pointer; text-align: left; font-family: inherit; }
button.adm-gh:hover { color: var(--teal); }
.adm-chev { width: 12px; height: 12px; margin-left: auto; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; transition: transform .15s ease; }
.adm-group.is-closed .adm-chev { transform: rotate(-90deg); }
.adm-group.is-closed > .adm-gitems { display: none; }
.adm-site2 { padding-top: 9px; padding-bottom: 9px; font-weight: normal; }
.adm-site:has(+ .adm-site2) { border-bottom: 0; padding-bottom: 6px; }
@media (min-width: 901px) {
  html.adm-collapsed .adm-group.is-closed > .adm-gitems { display: block; }
  html.adm-collapsed .adm-chev { display: none; }
  html.adm-collapsed button.adm-gh { cursor: default; pointer-events: none; }
}
.set-wrap > .set-body { flex: 1 1 auto; min-width: 0; }
.dw-fold { display: inline-flex; align-items: center; justify-content: center; width: 22px; height: 22px; flex: 0 0 22px; padding: 0; margin: -2px 0; background: none; border: 1px solid transparent; border-radius: 4px; color: var(--muted); cursor: pointer; }
.dw-fold:hover, .dw-fold:focus-visible { color: var(--teal); border-color: rgba(59, 79, 216, .6); }
.dw-fold svg { width: 14px; height: 14px; fill: none; stroke: currentColor; stroke-width: 2.2; stroke-linecap: round; stroke-linejoin: round; transition: transform .15s ease; }
.dw.is-folded .dw-fold svg { transform: rotate(-90deg); }
.dw.is-folded > .dw-body { display: none; }
.dw.is-folded > .dw-head { border-bottom-color: transparent; }
.pw-wrap { position: relative; display: inline-block; max-width: 100%; vertical-align: middle; }
.pw-wrap > input[type][type] { padding-right: 34px; max-width: 100%; box-sizing: border-box; }
.login-box .pw-wrap, .account-box .pw-wrap, .user-create .pw-wrap { display: block; max-width: 320px; }
.login-box .pw-wrap > input[type][type], .account-box .pw-wrap > input[type][type], .user-create .pw-wrap > input[type][type] { width: 100%; max-width: 100%; }
.login-box .pw-match, .account-box .pw-match, .user-create .pw-match { margin: 4px 0 0; }
.pw-eye { position: absolute; top: 50%; right: 3px; transform: translateY(-50%); width: 28px; height: 26px; padding: 0; display: inline-flex; align-items: center; justify-content: center; background: none; border: 0; border-radius: 4px; color: var(--muted); cursor: pointer; }
.pw-eye:hover, .pw-eye[aria-pressed="true"] { color: var(--teal); }
.pw-eye:focus-visible { outline: 2px solid var(--teal); outline-offset: -2px; }
.pw-eye svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; stroke-linecap: round; stroke-linejoin: round; }
.pw-match { display: inline-flex; align-items: center; gap: 4px; margin-left: 8px; font-size: 12px; font-weight: bold; vertical-align: middle; }
.pw-match svg { width: 16px; height: 16px; fill: none; stroke: currentColor; stroke-width: 2.6; stroke-linecap: round; stroke-linejoin: round; }
.pw-match.is-ok { color: #2ee66b; }
.pw-match.is-bad { color: #ff4d4d; }

/* ---- v96: payment + license portal (/shop, /admin/shop) ---- */
.shop-test { background: #3a2a00; border: 1px solid #b8860b; color: #ffe8a3; border-radius: 8px; padding: 10px 14px; margin: 0 0 16px; }
.shop-test b { color: #ffd257; letter-spacing: .04em; }
.shop-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); gap: 14px; margin: 10px 0 22px; }
.shop-card { background: var(--card, rgba(255,255,255,.04)); border: 1px solid rgba(255,255,255,.12); border-radius: 10px; padding: 14px 16px; }
.shop-card h3 { margin: 0 0 6px; }
.shop-card.shop-wide { max-width: 980px; margin-bottom: 12px; }
.shop-price { font-size: 1.15em; font-weight: 600; }
.shop-form { max-width: 520px; display: grid; gap: 12px; }
.shop-form input[type=email] { width: 100%; }
.shop-form fieldset { border: 1px solid rgba(255,255,255,.14); border-radius: 8px; padding: 8px 12px; }
.shop-method { display: block; padding: 4px 0; }
.shop-method.off { opacity: .55; }
.shop-key { border: 1px solid var(--teal, #2bb3a3); border-radius: 10px; padding: 12px 16px; margin: 12px 0; }
.shop-key code { font-size: 1.1em; word-break: break-all; user-select: all; }
.shop-wait { border: 1px dashed rgba(255,255,255,.25); border-radius: 10px; padding: 12px 16px; margin: 12px 0; }
.shop-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin: 6px 0 14px; }
.shop-inline { display: inline-flex; flex-wrap: wrap; gap: 6px; align-items: center; margin: 2px 6px 2px 0; }
.shop-inline.shop-block { display: block; }
.shop-inline.shop-block label { display: inline-block; margin: 0 8px 6px 0; }
.shop-status { margin: 0 0 12px; }
.shop-issue { margin: 0 0 12px; }
.shop .flash { padding: 8px 12px; border-radius: 8px; background: rgba(43,179,163,.15); margin: 8px 0; }
.shop .flash.err { background: rgba(200,60,60,.18); }
.btn.danger { border-color: #c44; color: #f88; }

/* ---- v97: portal admin lists (Orders, Invoices, Licenses) ---- */
.shop .filters { margin: 0 0 12px; }
.shop .filters input[type="text"] { min-width: 16em; }
.shop tr.is-test td { background: rgba(230, 200, 74, 0.06); }
.shop .pill.warn { font-weight: 700; letter-spacing: .04em; }
.shop .empty { max-width: 52em; margin: 0 auto 12px; text-align: left; padding: 16px 18px; }
.shop .empty a { font-weight: 600; }
.shop .shop-count { margin: 0 0 8px; }
