:root,
[data-theme="light"] {
  --bg: #f6f7fb;
  --bg-alt: #ffffff;
  --bg-card: #eef0f5;
  --bg-soft: #f0f2f8;
  --text: #1e2433;
  --text-secondary: #5a6478;
  --text-muted: #8b93a7;
  --text-heading: #0f1420;
  --border: #e8ebf2;
  --border-strong: #dde1ec;
  --border-mid: #d0d5e2;
  --accent: #5b6cff;
  --accent-hover: #4553e6;
  --accent-soft: #eef0ff;
  --logo: #c2185b;
  --logo-star: #ec407a;
  --logo-sub: #7c3aed;
  --logo-sub-i: #a78bfa;
  --heart: #f43f5e;
  --footer: #64748b;
  --footer-note: #94a3b8;
  --footer-link: #5b6cff;
  --badge-photo-bg: linear-gradient(135deg, #5b6cff, #7c3aed);
  --badge-photo-text: #ffffff;
  --badge-video-bg: linear-gradient(135deg, #a855f7, #ec4899);
  --badge-video-text: #ffffff;
  --tag-bg: #eef0ff;
  --tag-color: #4553e6;
  --tag-hover: #dce0ff;
  --side-title: #f59e0b;
  --side-btn: #f59e0b;
  --rand-photo: #5b6cff;
  --rand-video: #a855f7;
  --rand-photo-bg: #eef0ff;
  --rand-photo-border: #c7cdff;
  --rand-video-bg: #f5e9ff;
  --rand-video-border: #e9d5ff;
  --nav-bg: rgba(255,255,255,0.82);
  --shadow: rgba(15, 20, 40, 0.06);
  --shadow-hover: rgba(15, 20, 40, 0.14);
  --info-value: #5b6cff;
  --collapse-head-bg: #f3f4f9;
  --cmt-border: #e8ebf2;
  --overlay: rgba(15, 20, 40, 0.45);
  --radius: 16px;
  --radius-sm: 10px;
  --glass: rgba(255,255,255,0.72);
}

[data-theme="dark"] {
  --bg: #0b0d14;
  --bg-alt: #12151f;
  --bg-card: #1a1e2b;
  --bg-soft: #161922;
  --text: #e8eaf2;
  --text-secondary: #a8b0c4;
  --text-muted: #6f7890;
  --text-heading: #f5f7ff;
  --border: #1e2333;
  --border-strong: #2a3145;
  --border-mid: #323a52;
  --accent: #8b9cff;
  --accent-hover: #a8b4ff;
  --accent-soft: #1a1f3a;
  --logo: #f472b6;
  --logo-star: #fb7185;
  --logo-sub: #c4b5fd;
  --logo-sub-i: #a78bfa;
  --heart: #fb7185;
  --footer: #94a3b8;
  --footer-note: #64748b;
  --footer-link: #8b9cff;
  --badge-photo-bg: linear-gradient(135deg, #5b6cff, #7c3aed);
  --badge-photo-text: #fff;
  --badge-video-bg: linear-gradient(135deg, #a855f7, #ec4899);
  --badge-video-text: #fff;
  --tag-bg: #1a1f3a;
  --tag-color: #a8b4ff;
  --tag-hover: #252b4a;
  --side-title: #fbbf24;
  --side-btn: #f59e0b;
  --rand-photo: #8b9cff;
  --rand-video: #d8b4fe;
  --rand-photo-bg: #1a1f3a;
  --rand-photo-border: #3b4280;
  --rand-video-bg: #2a1a3a;
  --rand-video-border: #6b3a8a;
  --nav-bg: rgba(18, 21, 31, 0.88);
  --shadow: rgba(0,0,0,0.4);
  --shadow-hover: rgba(0,0,0,0.55);
  --info-value: #8b9cff;
  --collapse-head-bg: #161922;
  --cmt-border: #2a3145;
  --overlay: rgba(0,0,0,0.65);
  --radius: 16px;
  --radius-sm: 10px;
  --glass: rgba(18, 21, 31, 0.75);
}

* { margin: 0; padding: 0; box-sizing: border-box; }
html { scroll-behavior: smooth; }
body {
  font-family: 'Roboto Condensed', system-ui, -apple-system, sans-serif;
  background: #ffffff;
  color: #333;
  line-height: 1.5;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}
body > .main-content,
body > .list-layout,
body > .detail-page,
body > main {
  flex: 1 0 auto;
}
body > .footer,
body > footer.footer {
  margin-top: auto;
  flex-shrink: 0;
}

.top-header {
  text-align: center;
  padding: 20px 16px 10px;
}
.logo {
  font-size: 1.85rem;
  font-weight: 700;
  color: #1e88e5;
  letter-spacing: 1.5px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}
.logo i.fa-star,
.logo .star-icon {
  color: #42a5f5;
  font-size: 0.9em;
}
.logo-sub {
  margin-top: 4px;
  font-size: 0.88rem;
  color: #8e24aa;
  font-weight: 500;
}
.logo-sub i { font-size: 0.85em; color: #ab47bc; }

.main-nav {
  border-top: 1px solid #f0f0f0;
  border-bottom: 1px solid #f0f0f0;
  background: #fafafa;
}
.nav-inner {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 2px 4px;
  padding: 10px 12px;
}
.nav-item {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 6px 11px;
  font-size: 0.78rem;
  font-weight: 500;
  color: #666;
  text-decoration: none;
  border-radius: 6px;
  white-space: nowrap;
  transition: color 0.15s, background 0.15s;
}
.nav-item:hover,
.nav-item.active {
  color: #1e88e5;
  background: #e3f2fd;
}
.nav-item i { font-size: 0.9em; }

.main-content {
  max-width: 1200px;
  margin: 0 auto;
  padding: 28px 16px 20px;
}

.section {
  margin-bottom: 36px;
}
.section-title {
  text-align: center;
  font-size: 1rem;
  font-weight: 500;
  color: #555;
  margin-bottom: 22px;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
}
.section-title::before,
.section-title::after {
  content: "";
  flex: 1;
  max-width: 160px;
  height: 1px;
  background: #e0e0e0;
}
.section-title i.fa-heart {
  color: #e91e63;
  font-size: 0.9em;
}

.grid {
  display: grid;
  grid-template-columns: repeat(6, 1fr);
  gap: 14px;
}

.card {
  display: block;
  border-radius: 10px;
  overflow: hidden;
  background: #e8e8e8;
  aspect-ratio: 3 / 4;
  position: relative;
  text-decoration: none;
  box-shadow: 0 1px 4px rgba(0, 0, 0, 0.06);
  transition: transform 0.2s, box-shadow 0.2s;
}
.card:hover {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.card img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
  vertical-align: middle;
  background: #e8e8e8;
  transition: opacity 0.25s ease;
}
.card img:not([src]),
.card img[src=""] {
  opacity: 0;
}

.card.placeholder {
  background: #e0e0e0;
  display: flex;
  align-items: center;
  justify-content: center;
}
.card.placeholder::after {
  content: "";
  width: 32px;
  height: 28px;
  opacity: 0.45;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='%23999'%3E%3Cpath d='M21 19V5c0-1.1-.9-2-2-2H5c-1.1 0-2 .9-2 2v14c0 1.1.9 2 2 2h14c1.1 0 2-.9 2-2zM8.5 13.5l2.5 3.01L14.5 12l4.5 6H5l3.5-4.5z'/%3E%3C/svg%3E") center/contain no-repeat;
}

.loading-msg {
  grid-column: 1 / -1;
  text-align: center;
  padding: 40px 20px;
  color: #999;
  font-size: 0.95rem;
}

.footer {
  text-align: center;
  padding: 18px 16px 22px;
  border-top: 1px solid #eee;
  color: #81c784;
  font-size: 0.8rem;
}
.footer-note {
  margin-top: 2px;
  font-size: 0.75rem;
  color: #a5d6a7;
}
.footer a {
  color: #66bb6a;
  text-decoration: none;
}

@media (max-width: 900px) {
  .grid { grid-template-columns: repeat(3, 1fr); gap: 10px; }
}
@media (max-width: 520px) {
  .grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  .logo { font-size: 1.4rem; }
  .nav-item { font-size: 0.7rem; padding: 5px 8px; }
}

body.page-scroll { overflow: auto; }
.detail-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  max-width: 1200px;
  margin: 0 auto;
  padding: 14px 16px;
  border-bottom: 1px solid #eee;
}
.detail-header .logo {
  font-size: 1.25rem;
  text-decoration: none;
}
.detail-page {
  max-width: 1200px;
  margin: 0 auto;
  padding: 28px 16px 48px;
}
.detail-layout {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 28px;
  align-items: start;
}
@media (max-width: 768px) {
  .detail-layout { grid-template-columns: 1fr; }
}
.detail-image {
  position: relative;
  border-radius: 12px;
  overflow: hidden;
  background: #f0f0f0;
  box-shadow: 0 2px 12px rgba(0,0,0,0.08);
  aspect-ratio: 3 / 4;
  max-height: 70vh;
}
.detail-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center top;
  display: block;
  user-select: none;
  -webkit-user-drag: none;
}
.detail-badge {
  position: absolute;
  top: 12px;
  left: 12px;
  background: #1e88e5;
  color: #fff;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 4px 12px;
  border-radius: 6px;
}
.detail-info h1 { font-size: 1.4rem; margin-bottom: 6px; color: #222; }
.detail-id { font-size: 0.85rem; color: #888; margin-bottom: 10px; }
.detail-id code {
  background: #f0f0f0;
  padding: 2px 6px;
  border-radius: 4px;
  font-size: 0.8rem;
}
.detail-desc { color: #666; margin-bottom: 16px; font-size: 0.95rem; }
.detail-meta {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
  margin-bottom: 14px;
}
.meta-item {
  background: #f7f7f7;
  border-radius: 8px;
  padding: 10px 12px;
}
.meta-label { display: block; font-size: 0.72rem; color: #999; margin-bottom: 2px; }
.meta-value { font-weight: 600; font-size: 0.95rem; }
.detail-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 20px; }
.tag {
  background: #e3f2fd;
  color: #1565c0;
  font-size: 0.8rem;
  padding: 3px 10px;
  border-radius: 14px;
}
.detail-actions { display: flex; flex-direction: column; gap: 10px; margin-bottom: 20px; }
.btn-download-lg {
  background: #1e88e5;
  color: #fff;
  border: none;
  padding: 14px 20px;
  border-radius: 10px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  transition: background 0.2s;
}
.btn-download-lg:hover:not(:disabled) { background: #1565c0; }
.btn-download-lg:disabled { opacity: 0.7; cursor: wait; }
.btn-back {
  text-align: center;
  color: #666;
  text-decoration: none;
  padding: 10px;
  border-radius: 8px;
  border: 1px solid #ddd;
  font-weight: 500;
}
.btn-back:hover { border-color: #1e88e5; color: #1e88e5; }
.security-note {
  background: #fafafa;
  border: 1px solid #eee;
  border-radius: 10px;
  padding: 14px 16px;
  font-size: 0.85rem;
  color: #777;
}
.security-note strong { color: #444; display: block; margin-bottom: 6px; }
.security-note ul { margin: 0; padding-left: 18px; }
.security-note li { margin-bottom: 3px; }
.detail-loading, .empty-state {
  text-align: center;
  padding: 60px 20px;
  color: #999;
}

.dl-page {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: linear-gradient(160deg, #e3f2fd 0%, #fff 45%, #f5f5f5 100%);
}
.dl-box {
  background: #fff;
  border-radius: 20px;
  padding: 40px 36px;
  max-width: 420px;
  width: 100%;
  text-align: center;
  box-shadow: 0 8px 40px rgba(0,0,0,0.08);
  border: 1px solid #eee;
}
.dl-box .logo { font-size: 1.3rem; margin-bottom: 8px; }
.dl-title { font-size: 1.15rem; margin: 12px 0 6px; color: #222; }
.dl-sub { color: #888; font-size: 0.9rem; margin-bottom: 24px; }
.dl-countdown {
  width: 100px;
  height: 100px;
  border-radius: 50%;
  border: 4px solid #e3f2fd;
  border-top-color: #1e88e5;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 20px;
  font-size: 2.2rem;
  font-weight: 700;
  color: #1e88e5;
  animation: spin-border 1s linear infinite;
}
@keyframes spin-border {
  to { transform: rotate(360deg); }
}
.dl-countdown.done {
  animation: none;
  border-color: #1e88e5;
  background: #e3f2fd;
}
.dl-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: #1e88e5;
  color: #fff;
  border: none;
  padding: 14px 28px;
  border-radius: 12px;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  text-decoration: none;
  transition: background 0.2s, opacity 0.2s;
}
.dl-btn:hover { background: #1565c0; }
.dl-btn.disabled {
  opacity: 0.45;
  pointer-events: none;
  cursor: not-allowed;
}
.dl-error { color: #c62828; margin-top: 12px; font-size: 0.9rem; }
.dl-meta { margin-top: 16px; font-size: 0.8rem; color: #aaa; }

.info-box {
  background: #fafafa;
  border: 1px solid #eee;
  border-radius: 10px;
  padding: 0;
  margin: 16px 0 18px;
  overflow: hidden;
}
.info-box-title {
  text-align: center;
  font-size: 0.95rem;
  font-weight: 600;
  color: #666;
  padding: 10px 16px;
  border-bottom: 1px solid #eee;
  margin: 0;
}
.info-box-title i { margin-right: 6px; color: #999; }
.info-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 10px 20px;
  border-bottom: 1px solid #f0f0f0;
  gap: 16px;
}
.info-row:last-child { border-bottom: none; }
.info-label {
  color: #888;
  font-size: 0.9rem;
  flex-shrink: 0;
}
.info-value {
  color: #1565c0;
  font-weight: 600;
  font-size: 0.95rem;
  text-align: right;
  word-break: break-word;
}

.site-notes {
  margin-top: 8px;
  padding: 14px 4px 0;
  color: #999;
  font-size: 0.88rem;
  line-height: 1.7;
}
.site-notes p { margin: 0 0 6px; }

.detail-tags .tag {
  text-decoration: none;
  cursor: pointer;
}
.detail-tags .tag:hover {
  background: #bbdefb;
}
.tag-banner {
  text-align: center;
  padding: 10px 16px;
  margin-bottom: 12px;
  background: #e3f2fd;
  color: #1565c0;
  border-radius: 8px;
  font-size: 0.9rem;
}
.tag-banner a { color: #0d47a1; font-weight: 600; }

.note-box {
  margin-top: 16px;
  background: #fafafa;
  border: 1px solid #eee;
  border-radius: 10px;
  overflow: hidden;
}
.note-box-title {
  text-align: left;
  font-size: 0.95rem;
  font-weight: 600;
  color: #666;
  padding: 10px 16px;
  border-bottom: none;
  background: #f5f5f5;
}
.collapse-box.is-open > .collapse-head.note-box-title,
.collapse-box.is-open > .collapse-head {
  border-bottom: 1px solid var(--border);
}
.note-box-title i {
  margin-right: 6px;
  color: #f9a825;
}
.note-box .site-notes {
  margin: 0;
  padding: 12px 16px 14px;
  color: #999;
  font-size: 0.88rem;
  line-height: 1.7;
}
.note-box .site-notes p {
  margin: 0 0 6px;
}
.note-box .site-notes p:last-child {
  margin-bottom: 0;
}

.logo {
  color: #c2185b !important;
}
.logo i.fa-star {
  color: #ec407a !important;
}
.logo-sub {
  color: #8e24aa !important;
}
.logo-sub i {
  color: #ab47bc !important;
}

.list-layout {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 28px;
  align-items: start;
  max-width: 1200px;
  margin: 0 auto;
  padding: 24px 16px 40px;
  overflow: visible;
}
.list-main { min-width: 0; }
.list-grid {
  margin-top: 12px;
}
.pagination {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 8px;
  margin: 20px 0 8px;
  padding: 12px 8px;
}
.page-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 38px;
  height: 38px;
  padding: 0 12px;
  border-radius: 10px;
  border: 1px solid var(--border-mid, #e0e0e0);
  background: var(--bg, #fff);
  color: var(--text-secondary, #555);
  font-size: 0.88rem;
  text-decoration: none;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  box-shadow: 0 1px 3px var(--shadow, rgba(0,0,0,0.04));
  transition:
    background 0.2s ease,
    color 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease,
    box-shadow 0.2s ease;
}
.page-btn:hover:not(.active):not(.disabled):not(.dots) {
  border-color: var(--accent, #1e88e5);
  color: var(--accent, #1e88e5);
  background: var(--accent-soft, #e3f2fd);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px var(--shadow, rgba(30,136,229,0.15));
}
.page-btn.active {
  background: linear-gradient(135deg, var(--accent, #1e88e5), var(--accent-hover, #1565c0));
  color: #fff !important;
  border-color: transparent;
  box-shadow: 0 4px 14px rgba(30, 136, 229, 0.35);
  transform: scale(1.05);
  pointer-events: none;
}
.page-btn.disabled {
  opacity: 0.35;
  pointer-events: none;
  box-shadow: none;
}
.page-btn.dots {
  border: none;
  background: transparent;
  box-shadow: none;
  min-width: 28px;
  color: var(--text-muted, #999);
  cursor: default;
  padding: 0 4px;
}
.page-btn.page-nav {
  min-width: 42px;
  font-size: 1.05rem;
}
[data-theme="dark"] .page-btn {
  background: #1e1e1e;
  border-color: #3a3a3a;
  color: #ddd;
  box-shadow: 0 1px 4px rgba(0,0,0,0.25);
}
[data-theme="dark"] .page-btn:hover:not(.active):not(.disabled):not(.dots) {
  background: #1a3a5c;
  border-color: #64b5f6;
  color: #90caf9;
  box-shadow: 0 4px 14px rgba(0,0,0,0.35);
}
[data-theme="dark"] .page-btn.active {
  background: linear-gradient(135deg, #42a5f5, #1565c0);
  box-shadow: 0 4px 16px rgba(66, 165, 245, 0.3);
}
[data-theme="dark"] .page-btn.dots {
  color: #777;
}

@keyframes pageGridIn {
  from {
    opacity: 0;
    transform: translateY(14px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.list-grid.page-anim,
#listGrid.page-anim {
  animation: pageGridIn 0.4s ease both;
}
.pagination.page-anim {
  animation: pageGridIn 0.45s ease 0.05s both;
}

.list-sidebar,
.detail-sidebar {
  position: sticky;
  top: 72px;
  align-self: start;
  max-height: calc(100vh - 88px);
  overflow-y: auto;
  z-index: 5;
}
.side-block {
  margin-bottom: 24px;
}
.side-title {
  font-size: 0.95rem;
  font-weight: 700;
  color: #e65100;
  margin: 0 0 10px;
  padding-bottom: 6px;
  border-bottom: 2px solid #e65100;
  display: flex;
  align-items: center;
  gap: 6px;
}
.side-search {
  display: flex;
  border: 1px solid #ddd;
  border-radius: 4px;
  overflow: hidden;
}
.side-search input {
  flex: 1;
  border: none;
  padding: 10px 12px;
  font-size: 0.9rem;
  outline: none;
  font-family: inherit;
}
.side-search button {
  background: #ef6c00;
  color: #fff;
  border: none;
  padding: 0 14px;
  cursor: pointer;
}
.random-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.random-list li {
  margin-bottom: 0;
  padding: 10px 0;
  border-bottom: 1px solid #f0f0f0;
  font-size: 0.9rem;
  line-height: 1.45;
}
.random-list li:last-child {
  border-bottom: none;
}
.random-list a {
  color: #555;
  text-decoration: none;
  transition: color 0.15s;
  display: block;
}
.random-list a:hover {
  color: #e65100;
  text-decoration: none;
}

@media (max-width: 860px) {
  .list-layout {
    grid-template-columns: 1fr;
  }
  .list-main {
    order: 1;
  }
  .list-sidebar,
  .list-cosplayer-mode .list-sidebar,
  .detail-sidebar {
    position: static !important;
    order: 2;
    max-height: none !important;
    overflow: visible !important;
    top: auto !important;
    z-index: auto;
    margin-top: 8px;
  }
}

.list-grid {
  grid-template-columns: repeat(4, 1fr) !important;
  gap: 16px !important;
}

@media (max-width: 900px) {
  .list-grid { grid-template-columns: repeat(3, 1fr) !important; }
}
@media (max-width: 600px) {
  .list-grid { grid-template-columns: repeat(2, 1fr) !important; }
}

@keyframes bounceInUp {
  0% {
    opacity: 0;
    transform: translateY(40px) scale(0.96);
  }
  60% {
    opacity: 1;
    transform: translateY(-8px) scale(1.02);
  }
  80% {
    transform: translateY(4px) scale(0.99);
  }
  100% {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}
.card-animate {
  animation: bounceInUp 0.7s ease both;
}

.card {
  position: relative;
  overflow: hidden;
}
.card .card-title,
#photoGrid .card-title,
#videoGrid .card-title,
.list-grid .card-title {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 2;
  margin: 0;
  padding: 22px 8px 10px;
  background: linear-gradient(to top, rgba(0, 0, 0, 0.78) 0%, rgba(0, 0, 0, 0.35) 55%, transparent 100%);
  color: #fff;
  font-size: 0.82rem;
  font-weight: 600;
  line-height: 1.3;
  text-align: center;
  overflow: hidden;
  pointer-events: none;
  opacity: 0;
  visibility: hidden;
  transform: translateY(100%);
  transition: opacity 0.28s ease, transform 0.32s ease, visibility 0.28s;
}
.card .card-title-inner,
#photoGrid .card-title-inner,
#videoGrid .card-title-inner,
.list-grid .card-title-inner {
  display: block;
  width: 100%;
  text-align: center;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.card:hover .card-title,
#photoGrid .card:hover .card-title,
#videoGrid .card:hover .card-title,
.list-grid .card:hover .card-title {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

.random-list a {
  display: flex;
  align-items: flex-start;
  gap: 8px;
}
.random-list a i {
  color: #ef6c00;
  margin-top: 3px;
  flex-shrink: 0;
  font-size: 0.85em;
  transition: transform 0.15s;
}
.random-list a:hover i {
  transform: translateX(3px);
}
.random-list a span {
  flex: 1;
  min-width: 0;
}

.list-cosplayer-mode {
  max-width: 1200px;
  margin: 0 auto;
}
.list-cosplayer-mode .list-main {
  max-width: 100%;
}
.list-cosplayer-mode #listTitle {
  margin-bottom: 8px;
}

.cp-panel {
  background: #fff;
  border: 1px solid #eceff3;
  border-radius: 16px;
  box-shadow: 0 8px 28px rgba(30, 40, 60, 0.06);
  overflow: hidden;
  margin-top: 8px;
}
.cp-panel-head {
  padding: 14px 18px;
  background: linear-gradient(135deg, #fafbff 0%, #f3f6fb 100%);
  border-bottom: 1px solid #eef1f6;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}
.cp-panel-head .cp-count {
  font-size: 0.8rem;
  color: #8892a4;
  font-weight: 500;
}
.cp-list {
  display: block !important;
  background: transparent;
  border: none;
  margin: 0;
  padding: 6px 0;
}
.cp-row {
  text-align: center;
  border-bottom: 1px solid #f0f2f5;
  padding: 0;
  margin: 0 12px;
  transition: background 0.15s ease;
}
.cp-row:last-child {
  border-bottom: none;
}
.cp-row:hover {
  background: #f7f9fc;
  border-radius: 10px;
}
.cp-link {
  display: block;
  padding: 13px 16px;
  color: #3b5998;
  text-decoration: none !important;
  font-size: 1.05rem;
  line-height: 1.45;
  letter-spacing: 0.01em;
  transition: color 0.15s ease, transform 0.15s ease;
}
.cp-link:hover,
.cp-link:focus {
  color: #e65100;
  text-decoration: none !important;
}
.cp-link b {
  font-weight: 600;
}
.cp-empty {
  text-align: center;
  color: #9aa3b2;
  padding: 36px 16px;
  font-size: 0.95rem;
}

.cosplayer-page {
  max-width: 1200px !important;
  width: 100%;
}
.cosplayer-toolbar {
  display: flex;
  justify-content: center;
  margin-bottom: 16px;
}
.search-input {
  width: min(320px, 100%);
  padding: 10px 14px;
  border: 1px solid #e0e4ea;
  border-radius: 10px;
  font-family: inherit;
  font-size: 0.95rem;
  outline: none;
  transition: border-color 0.15s, box-shadow 0.15s;
}
.search-input:focus {
  border-color: #90caf9;
  box-shadow: 0 0 0 3px rgba(33, 150, 243, 0.12);
}

.random-list a.rand-photo { color: #1565c0 !important; }
.random-list a.rand-photo:hover { color: #0d47a1 !important; }
.random-list a.rand-video { color: #7b1fa2 !important; }
.random-list a.rand-video:hover { color: #4a148c !important; }

.random-list .rand-badge {
  display: inline-block;
  font-size: 0.68rem;
  font-weight: 700;
  line-height: 1.2;
  padding: 2px 7px;
  border-radius: 4px;
  margin-right: 8px;
  vertical-align: middle;
  white-space: nowrap;
  letter-spacing: 0.03em;
  flex-shrink: 0;
}
.random-list .rand-badge.photo {
  background: #e3f2fd;
  color: #1565c0;
  border: 1px solid #bbdefb;
}
.random-list .rand-badge.video {
  background: #f3e5f5;
  color: #7b1fa2;
  border: 1px solid #e1bee7;
}
.random-list a span.rand-text {
  flex: 1;
  min-width: 0;
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 4px 0;
}

.random-list {
  list-style: none;
  margin: 0;
  padding: 0;
}
.random-list li {
  margin: 0;
  padding: 8px 0;
  border-bottom: 1px solid #f0f0f0;
}
.random-list li:last-child {
  border-bottom: none;
}
.random-list a {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: nowrap !important;
  align-items: center !important;
  gap: 6px !important;
  text-decoration: none !important;
  min-width: 0;
  width: 100%;
  line-height: 1.35;
}
.random-list a i.fa-angle-right {
  flex: 0 0 auto;
  color: #ef6c00;
  font-size: 0.85em;
  margin: 0 !important;
}
.random-list .rand-badge {
  flex: 0 0 auto !important;
  display: inline-block !important;
  font-size: 0.65rem !important;
  font-weight: 700;
  line-height: 1;
  padding: 3px 6px;
  border-radius: 4px;
  white-space: nowrap !important;
  margin: 0 !important;
  letter-spacing: 0.02em;
}
.random-list .rand-badge.photo {
  background: #e3f2fd;
  color: #1565c0;
  border: 1px solid #bbdefb;
}
.random-list .rand-badge.video {
  background: #f3e5f5;
  color: #7b1fa2;
  border: 1px solid #e1bee7;
}
.random-list .rand-text {
  flex: 1 1 auto !important;
  min-width: 0 !important;
  display: block !important;
  overflow: hidden !important;
  text-overflow: ellipsis !important;
  white-space: nowrap !important;
  font-size: 0.88rem;
  margin: 0 !important;
  padding: 0 !important;
}
.random-list a.rand-photo { color: #1565c0 !important; }
.random-list a.rand-photo:hover { color: #0d47a1 !important; }
.random-list a.rand-video { color: #7b1fa2 !important; }
.random-list a.rand-video:hover { color: #4a148c !important; }

.list-cosplayer-mode {
  overflow: visible;
}
.list-cosplayer-mode .list-sidebar {
  position: sticky;
  top: 72px;
  align-self: start;
}
@media (max-width: 860px) {
  .list-cosplayer-mode .list-sidebar {
    position: static !important;
    order: 2;
    max-height: none !important;
    overflow: visible !important;
  }
  .list-cosplayer-mode .list-main {
    order: 1;
  }
}

body {
  background: var(--bg) !important;
  color: var(--text) !important;
}
.main-nav {
  border-top-color: var(--border) !important;
  border-bottom-color: var(--border) !important;
  background: var(--nav-bg) !important;
}
.nav-item { color: var(--text-secondary) !important; }
.nav-item:hover, .nav-item.active {
  color: var(--accent) !important;
  background: var(--accent-soft) !important;
}
.section-title { color: var(--text-secondary) !important; }
.section-title::before, .section-title::after { background: var(--border-mid) !important; }
.section-title i.fa-heart, .section-title .far.fa-heart { color: var(--heart) !important; }
.card { background: var(--bg-card) !important; box-shadow: 0 1px 4px var(--shadow) !important; }
.card:hover { box-shadow: 0 6px 16px var(--shadow-hover) !important; }
.footer {
  border-top-color: var(--border-strong) !important;
  color: var(--footer) !important;
}
.footer-note { color: var(--footer-note) !important; }
.footer a { color: var(--footer-link) !important; }
.logo { color: var(--logo) !important; }
.logo i.fa-star, .logo .far.fa-star { color: var(--logo-star) !important; }
.logo-sub { color: var(--logo-sub) !important; }
.logo-sub i { color: var(--logo-sub-i) !important; }

.detail-info h1 { color: var(--text-heading) !important; }
.detail-desc { color: var(--text-secondary) !important; }
.info-box, .note-box, .collapse-box {
  background: var(--bg-alt) !important;
  border-color: var(--border-strong) !important;
}
.info-box-title, .note-box-title, .collapse-head {
  color: var(--text-secondary) !important;
  border-bottom-color: var(--border-strong) !important;
  background: var(--collapse-head-bg) !important;
}
.info-row { border-bottom-color: var(--border) !important; }
.info-label { color: var(--text-muted) !important; }
.info-value { color: var(--info-value) !important; }
.tag {
  background: var(--tag-bg) !important;
  color: var(--tag-color) !important;
}
.detail-tags .tag:hover { background: var(--tag-hover) !important; }
.btn-download-lg {
  background: var(--accent) !important;
  color: #fff !important;
}
.btn-download-lg:hover:not(:disabled) { background: var(--accent-hover) !important; }
.detail-badge { background: var(--badge-photo-bg) !important; color: var(--badge-photo-text) !important; }
.detail-badge.badge-video { background: var(--badge-video-bg) !important; color: var(--badge-video-text) !important; }
.side-title {
  color: var(--side-title) !important;
  border-bottom-color: var(--side-title) !important;
}
.side-search { border-color: var(--border-mid) !important; }
.side-search input {
  background: var(--bg) !important;
  color: var(--text) !important;
}
.side-search button { background: var(--side-btn) !important; }
.random-list li { border-bottom-color: var(--border) !important; }
.random-list a { color: var(--text-secondary) !important; }
.random-list a:hover { color: var(--side-title) !important; }
.random-list .rand-badge.photo {
  background: var(--rand-photo-bg) !important;
  color: var(--rand-photo) !important;
  border-color: var(--rand-photo-border) !important;
}
.random-list .rand-badge.video {
  background: var(--rand-video-bg) !important;
  color: var(--rand-video) !important;
  border-color: var(--rand-video-border) !important;
}
.random-list a.rand-photo { color: var(--rand-photo) !important; }
.random-list a.rand-video { color: var(--rand-video) !important; }
.page-btn {
  background: var(--bg) !important;
  color: var(--text-secondary) !important;
  border-color: var(--border-mid) !important;
}
.page-btn.active {
  background: var(--text-heading) !important;
  color: var(--bg) !important;
  border-color: var(--text-heading) !important;
}
.cp-panel {
  background: var(--bg) !important;
  border-color: var(--border-strong) !important;
  box-shadow: 0 8px 28px var(--shadow) !important;
}
.cp-panel-head {
  background: var(--bg-alt) !important;
  border-bottom-color: var(--border) !important;
}
.cp-row { border-bottom-color: var(--border) !important; }
.cp-row:hover { background: var(--bg-soft) !important; }
.cp-link { color: var(--accent) !important; }
.cp-link:hover { color: var(--side-title) !important; }
.cp-empty { color: var(--text-muted) !important; }
.search-input {
  background: var(--bg) !important;
  color: var(--text) !important;
  border-color: var(--border-mid) !important;
}
.tag-banner {
  background: var(--accent-soft) !important;
  color: var(--tag-color) !important;
}
.loading-msg { color: var(--text-muted) !important; }
.site-notes { color: var(--text-muted) !important; }
.detail-image { background: var(--bg-card) !important; }

.collapse-box {
  margin-top: 12px;
  border-radius: 10px;
  overflow: hidden;
  border: 1px solid var(--border-strong);
}
.collapse-head {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 10px 16px;
  border: none;
  cursor: pointer;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  text-align: left;
  transition: background 0.15s;
}
.collapse-head:hover { filter: brightness(0.97); }
.collapse-icon {
  transition: transform 0.25s ease;
  font-size: 0.85em;
  opacity: 0.7;
}
.collapse-box.is-open .collapse-icon {
  transform: rotate(180deg);
}
.collapse-body {
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  padding: 0 16px !important;
  border-top: 0 solid transparent !important;
  margin: 0;
  transition:
    max-height 0.35s ease,
    opacity 0.28s ease,
    padding 0.3s ease,
    border-color 0.3s ease;
}
.collapse-box.is-open .collapse-body {
  max-height: 1200px;
  opacity: 1;
  padding: 12px 16px 14px !important;
  border-top: 1px solid var(--border) !important;
}
.collapse-body .detail-tags {
  margin-bottom: 0;
}
.collapse-body .site-notes {
  margin: 0;
  padding: 0;
}

.comment-form {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 14px;
}
.comment-form input,
.comment-form textarea {
  font-family: inherit;
  font-size: 0.9rem;
  padding: 10px 12px;
  border: 1px solid var(--border-mid);
  border-radius: 8px;
  background: var(--bg);
  color: var(--text);
  outline: none;
  resize: vertical;
}
.comment-form input:focus,
.comment-form textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(30,136,229,0.12);
}
.btn-comment {
  align-self: flex-start;
  background: var(--accent);
  color: #fff;
  border: none;
  padding: 10px 18px;
  border-radius: 8px;
  font-family: inherit;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.btn-comment:hover:not(:disabled) { background: var(--accent-hover); }
.btn-comment:disabled { opacity: 0.7; cursor: wait; }
.comment-list { max-height: 360px; overflow-y: auto; }
.cmt-item {
  padding: 10px 0;
  border-bottom: 1px solid var(--cmt-border);
}
.cmt-item:last-child { border-bottom: none; }
.cmt-head {
  display: flex;
  justify-content: space-between;
  align-items: baseline;
  gap: 8px;
  margin-bottom: 4px;
}
.cmt-head strong, .cmt-head .cmt-name { color: var(--text-heading); font-size: 0.9rem; margin: 0; }
.cmt-time { font-size: 0.75rem; color: var(--text-muted); }
.cmt-body { font-size: 0.88rem; color: var(--text-secondary); line-height: 1.5; margin: 0; white-space: pre-wrap; word-break: break-word; }
.cmt-empty, .cmt-loading { color: var(--text-muted); font-size: 0.88rem; text-align: center; padding: 12px; }

.detail-with-sidebar {
  display: grid;
  grid-template-columns: 1fr 260px;
  gap: 24px;
  align-items: start;
  max-width: 1200px;
  margin: 0 auto;
}
.detail-main-col { min-width: 0; }
.detail-page {
  max-width: 1200px !important;
}
@media (max-width: 860px) {
  .detail-with-sidebar {
    grid-template-columns: 1fr;
  }
  .detail-sidebar {
    position: static !important;
    order: 1;
  }
}

.theme-toggle {
  position: absolute;
  top: 50%;
  right: 16px;
  transform: translateY(-50%);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  border: 1px solid var(--border-mid);
  background: var(--bg-alt);
  color: var(--text-secondary);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  transition: background 0.15s, color 0.15s;
  z-index: 20;
}
.theme-toggle:hover {
  background: var(--accent-soft);
  color: var(--accent);
}

.nav-toggle {
  display: none;
  position: absolute;
  top: 50%;
  left: 12px;
  transform: translateY(-50%);
  width: 40px;
  height: 40px;
  border: none;
  background: transparent;
  color: var(--text);
  font-size: 1.35rem;
  cursor: pointer;
  z-index: 30;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
}
.nav-toggle:hover { background: var(--accent-soft); color: var(--accent); }
.nav-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: var(--overlay);
  z-index: 40;
}
body.nav-open .nav-overlay { display: block; }

@media (max-width: 720px) {
  .nav-toggle { display: flex; }
  .top-header {
    position: relative;
    padding-left: 52px;
    padding-right: 52px;
  }
  .main-nav {
    position: fixed;
    top: 0;
    left: 0;
    bottom: 0;
    width: min(280px, 82vw);
    z-index: 50;
    transform: translateX(-105%);
    transition: transform 0.28s ease;
    border: none;
    border-right: 1px solid var(--border);
    background: var(--bg);
    box-shadow: 4px 0 24px var(--shadow);
    overflow-y: auto;
    padding-top: 56px;
  }
  body.nav-open .main-nav {
    transform: translateX(0);
  }
  .main-nav .nav-inner {
    flex-direction: column;
    align-items: stretch;
    padding: 12px;
    gap: 2px;
  }
  .main-nav .nav-item {
    padding: 12px 14px;
    font-size: 0.9rem;
    border-radius: 8px;
  }
}

.cp-row {
  margin: 0 8px !important;
}
.cp-link {
  padding: 8px 12px !important;
  font-size: 0.85rem !important;
  line-height: 1.35 !important;
}
.cp-panel-head {
  padding: 10px 14px !important;
}
.cp-list {
  padding: 2px 0 !important;
}

body.home-page {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  overflow: hidden;
}
body.home-page .main-content {
  flex: 1;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 12px 16px 8px;
  max-width: 1200px;
}
body.home-page .section {
  margin-bottom: 16px;
}
body.home-page .section-title {
  font-size: 1.15rem;
  margin-bottom: 12px;
  font-weight: 600;
}
body.home-page .grid {
  grid-template-columns: repeat(6, 1fr);
  gap: 12px;
}
body.home-page .footer {
  margin-top: auto;
  padding: 10px 16px 14px;
  flex-shrink: 0;
}
@media (max-width: 900px) {
  body.home-page { overflow: auto; }
  body.home-page .grid { grid-template-columns: repeat(3, 1fr); }
}
@media (max-width: 520px) {
  body.home-page .grid { grid-template-columns: repeat(2, 1fr); gap: 8px; }
  body.home-page .section-title { font-size: 0.95rem; }
}

img[loading="lazy"] {
  content-visibility: auto;
}

.info-label i {
  margin-right: 6px;
  width: 1.1em;
  text-align: center;
  opacity: 0.75;
  color: var(--accent);
}

@keyframes pageFadeIn {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}
.main-content,
.detail-page,
.list-layout {
  animation: pageFadeIn 0.45s ease both;
}
.card-animate {
  animation: bounceInUp 0.7s ease both;
}

[data-theme="dark"] .btn-download-lg {
  background: linear-gradient(135deg, #1a3a5c 0%, #1565a0 45%, #0d47a1 100%) !important;
  color: #e3f2fd !important;
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.4);
  border: 1px solid rgba(100, 150, 200, 0.25);
}
[data-theme="dark"] .btn-download-lg:hover:not(:disabled) {
  background: linear-gradient(135deg, #1e4a6e 0%, #1976d2 50%, #1565c0 100%) !important;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.5);
  color: #fff !important;
}
[data-theme="dark"] .btn-comment {
  background: #42a5f5 !important;
}
[data-theme="dark"] .btn-comment:hover:not(:disabled) {
  background: #64b5f6 !important;
}

body.home-page .section {
  margin-bottom: 28px !important;
}
body.home-page .section + .section {
  margin-top: 8px;
}
body.home-page #video-cosplay {
  margin-top: 12px;
}
@media (max-width: 900px) {
  body.home-page .section {
    margin-bottom: 24px !important;
  }
}

.collapse-box:not(.is-open) .collapse-body {
  max-height: 0 !important;
  opacity: 0 !important;
  padding-top: 0 !important;
  padding-bottom: 0 !important;
  border-top-width: 0 !important;
  overflow: hidden !important;
  pointer-events: none;
}
.collapse-box .collapse-head {
  border-radius: 10px;
}
.collapse-box.is-open .collapse-head {
  border-radius: 10px 10px 0 0;
}
.note-box.collapse-box .note-box-title {
  border-bottom: none;
}

.scroll-float {
  position: fixed;
  right: 16px;
  bottom: 20px;
  z-index: 90;
  display: flex;
  flex-direction: column;
  gap: 8px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s ease;
}
.scroll-float.is-visible {
  opacity: 1;
  pointer-events: auto;
}
.scroll-float-btn {
  width: 42px;
  height: 42px;
  border-radius: 50%;
  border: 1px solid var(--border-mid, #ddd);
  background: var(--bg, #fff);
  color: var(--text-secondary, #555);
  box-shadow: 0 4px 14px var(--shadow, rgba(0,0,0,0.12));
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  transition: background 0.15s, color 0.15s, transform 0.15s;
}
.scroll-float-btn:hover {
  background: var(--accent, #1e88e5);
  color: #fff;
  border-color: var(--accent, #1e88e5);
  transform: translateY(-1px);
}
#scrollTopBtn { opacity: 0.35; pointer-events: none; }
#scrollBottomBtn { opacity: 0.35; pointer-events: none; }
.scroll-float.show-top #scrollTopBtn,
.scroll-float.show-bottom #scrollBottomBtn {
  opacity: 1;
  pointer-events: auto;
}
[data-theme="dark"] .scroll-float-btn {
  background: #1e1e1e;
  border-color: #3a3a3a;
  color: #e0e0e0;
}
@media (max-width: 520px) {
  .scroll-float { right: 12px; bottom: 14px; }
  .scroll-float-btn { width: 38px; height: 38px; }
}

.nav-theme-btn {
  border: none;
  background: transparent;
  cursor: pointer;
  font-family: inherit;
}
.nav-theme-btn:hover {
  color: var(--accent) !important;
  background: var(--accent-soft) !important;
}
.top-header > .theme-toggle {
  display: none !important;
}

body.page-scroll {
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}
body.page-scroll > .list-layout,
body.page-scroll > .detail-page,
body.page-scroll > main {
  flex: 1 0 auto;
}
body.page-scroll > .footer {
  margin-top: auto;
  flex-shrink: 0;
}

:root {
  --page-max: 1200px;
}
.nav-inner,
.main-content,
.list-layout,
.detail-page,
.detail-with-sidebar,
.list-cosplayer-mode,
.cosplayer-page,
body.home-page .main-content {
  width: 100% !important;
  max-width: var(--page-max) !important;
  margin-left: auto !important;
  margin-right: auto !important;
  box-sizing: border-box;
}
.list-layout.main-content {
  padding-left: 16px;
  padding-right: 16px;
}
.list-cosplayer-mode .list-main,
.list-cosplayer-mode .cp-panel {
  width: 100% !important;
  max-width: 100% !important;
}
.detail-page.main-content {
  padding-left: 16px;
  padding-right: 16px;
}

.detail-info h1.detail-title,
.detail-title {
  text-align: center !important;
  width: 100%;
}

.nav-search-form {
  display: none;
  width: 100%;
  padding: 8px 4px 12px;
  gap: 0;
  align-items: stretch;
}
.nav-search-input {
  flex: 1;
  min-width: 0;
  padding: 10px 12px;
  border: 1px solid var(--border-mid, #ddd);
  border-right: none;
  border-radius: 8px 0 0 8px;
  font-family: inherit;
  font-size: 0.9rem;
  background: var(--bg, #fff);
  color: var(--text, #333);
  outline: none;
}
.nav-search-btn {
  padding: 0 14px;
  border: 1px solid var(--border-mid, #ddd);
  border-radius: 0 8px 8px 0;
  background: var(--accent, #1e88e5);
  color: #fff;
  cursor: pointer;
  font-size: 0.95rem;
}
@media (max-width: 720px) {
  .nav-search-form {
    display: flex;
  }
}

.card img,
.detail-image img {
  content-visibility: auto;
  background: var(--bg-card, #e8e8e8);
}
.card {
  content-visibility: auto;
  contain-intrinsic-size: 200px 267px;
}

html {
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}
body {
  font-family: "Roboto Condensed", system-ui, -apple-system, sans-serif !important;
  background:
    radial-gradient(1200px 600px at 10% -10%, rgba(91, 108, 255, 0.08), transparent 55%),
    radial-gradient(900px 500px at 90% 0%, rgba(236, 72, 153, 0.06), transparent 50%),
    var(--bg) !important;
  color: var(--text) !important;
  letter-spacing: 0.01em;
}

.top-header {
  padding: 28px 16px 14px !important;
  position: relative;
}
.logo {
  font-size: 2rem !important;
  font-weight: 800 !important;
  letter-spacing: 0.08em !important;
  background: linear-gradient(120deg, var(--logo) 0%, #7c3aed 50%, var(--logo-star) 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent !important;
  filter: none;
}
.logo i, .logo .far {
  background: none !important;
  -webkit-background-clip: unset !important;
  color: var(--logo-star) !important;
  filter: none;
}
.logo-sub {
  font-size: 0.92rem !important;
  font-weight: 500 !important;
  letter-spacing: 0.04em;
  opacity: 0.95;
}

.main-nav {
  background: var(--nav-bg) !important;
  backdrop-filter: blur(16px) saturate(1.2);
  -webkit-backdrop-filter: blur(16px) saturate(1.2);
  border-top: 1px solid var(--border) !important;
  border-bottom: 1px solid var(--border) !important;
  position: sticky;
  top: 0;
  z-index: 40;
  box-shadow: 0 4px 24px var(--shadow);
}
.nav-inner {
  gap: 4px 6px !important;
  padding: 12px 16px !important;
}
.nav-item {
  padding: 8px 14px !important;
  font-size: 0.8rem !important;
  font-weight: 600 !important;
  letter-spacing: 0.03em;
  border-radius: 999px !important;
  color: var(--text-secondary) !important;
  transition: all 0.22s cubic-bezier(0.22, 1, 0.36, 1) !important;
}
.nav-item:hover,
.nav-item.active {
  color: var(--accent) !important;
  background: var(--accent-soft) !important;
  transform: translateY(-1px);
  box-shadow: 0 4px 14px var(--shadow);
}

.section-title {
  font-size: 1.15rem !important;
  font-weight: 700 !important;
  letter-spacing: 0.06em;
  color: var(--text-heading) !important;
  margin-bottom: 28px !important;
  gap: 14px !important;
}
.section-title::before,
.section-title::after {
  height: 1px !important;
  background: linear-gradient(90deg, transparent, var(--border-mid), transparent) !important;
  max-width: 180px !important;
}
.section-title i.fa-heart,
.section-title .far.fa-heart {
  color: var(--heart) !important;
  filter: drop-shadow(0 2px 6px rgba(244, 63, 94, 0.35));
}

.grid {
  gap: 16px !important;
}
.card {
  border-radius: var(--radius) !important;
  background: var(--bg-card) !important;
  box-shadow:
    0 2px 8px var(--shadow),
    0 0 0 1px var(--border) !important;
  overflow: hidden !important;
  transition:
    transform 0.35s cubic-bezier(0.22, 1, 0.36, 1),
    box-shadow 0.35s ease !important;
}
.card:hover {
  transform: none !important;
  box-shadow:
    0 16px 40px var(--shadow-hover),
    0 0 0 1px var(--border-strong) !important;
}
.card img {
  transition: transform 0.5s cubic-bezier(0.22, 1, 0.36, 1) !important;
}
.card:hover img {
  transform: none !important;
}
.card .card-title {
  background: linear-gradient(to top, rgba(8,10,18,0.88) 0%, rgba(8,10,18,0.35) 55%, transparent 100%) !important;
  font-size: 0.84rem !important;
  font-weight: 600 !important;
  letter-spacing: 0.02em;
  padding: 28px 10px 12px !important;
}

.footer {
  border-top: 1px solid var(--border) !important;
  padding: 22px 16px 28px !important;
  color: var(--footer) !important;
  font-size: 0.82rem !important;
  letter-spacing: 0.04em;
  background: transparent !important;
}

.detail-image {
  border-radius: calc(var(--radius) + 2px) !important;
  box-shadow:
    0 12px 40px var(--shadow-hover),
    0 0 0 1px var(--border) !important;
  overflow: hidden !important;
}
.detail-badge {
  background: var(--badge-photo-bg) !important;
  color: var(--badge-photo-text) !important;
  font-size: 0.7rem !important;
  font-weight: 800 !important;
  letter-spacing: 0.08em !important;
  padding: 6px 12px !important;
  border-radius: 8px !important;
  box-shadow: 0 4px 14px rgba(91, 108, 255, 0.35);
  backdrop-filter: blur(8px);
}
.detail-badge.badge-video {
  background: var(--badge-video-bg) !important;
  box-shadow: 0 4px 14px rgba(168, 85, 247, 0.35);
}
.detail-info h1,
.detail-title {
  font-weight: 800 !important;
  letter-spacing: 0.02em;
  line-height: 1.25 !important;
  color: var(--text-heading) !important;
}
.info-box,
.collapse-box,
.note-box,
.cp-panel {
  background: var(--bg-alt) !important;
  border: 1px solid var(--border-strong) !important;
  border-radius: var(--radius) !important;
  box-shadow: 0 8px 28px var(--shadow) !important;
  overflow: hidden !important;
}
.info-box-title,
.collapse-head,
.note-box-title {
  background: var(--collapse-head-bg) !important;
  font-weight: 700 !important;
  letter-spacing: 0.03em;
}
.btn-download-lg {
  background: linear-gradient(135deg, #5b6cff 0%, #7c3aed 55%, #ec4899 100%) !important;
  border: none !important;
  border-radius: 14px !important;
  padding: 16px 22px !important;
  font-weight: 700 !important;
  letter-spacing: 0.03em;
  box-shadow: 0 10px 28px rgba(91, 108, 255, 0.35) !important;
  transition: transform 0.25s ease, box-shadow 0.25s ease, filter 0.25s ease !important;
}
.btn-download-lg:hover:not(:disabled) {
  transform: translateY(-2px) !important;
  filter: brightness(1.05);
  box-shadow: 0 14px 36px rgba(124, 58, 237, 0.4) !important;
  background: linear-gradient(135deg, #6b7aff 0%, #8b5cf6 55%, #f472b6 100%) !important;
}
[data-theme="dark"] .btn-download-lg {
  background: linear-gradient(135deg, #3d4db8 0%, #6d28d9 50%, #9d174d 100%) !important;
  box-shadow: 0 8px 24px rgba(0,0,0,0.45) !important;
}

.tag {
  border-radius: 999px !important;
  padding: 5px 12px !important;
  font-weight: 600 !important;
  transition: transform 0.2s ease, background 0.2s ease !important;
}
.tag:hover {
  transform: translateY(-1px);
}

.side-title {
  font-weight: 800 !important;
  letter-spacing: 0.05em;
  border-bottom-width: 2px !important;
}
.side-search {
  border-radius: 12px !important;
  overflow: hidden !important;
  border: 1px solid var(--border-mid) !important;
  box-shadow: 0 2px 10px var(--shadow);
}
.side-search button {
  background: linear-gradient(135deg, #f59e0b, #f97316) !important;
}

.random-list .rand-badge {
  border-radius: 6px !important;
  font-weight: 800 !important;
  letter-spacing: 0.04em !important;
}

.scroll-float-btn {
  border-radius: 14px !important;
  backdrop-filter: blur(12px);
  box-shadow: 0 8px 24px var(--shadow-hover) !important;
  border: 1px solid var(--border-strong) !important;
}
.scroll-float-btn:hover {
  background: linear-gradient(135deg, #5b6cff, #7c3aed) !important;
  color: #fff !important;
  border-color: transparent !important;
}

.page-btn.active {
  background: linear-gradient(135deg, #5b6cff, #7c3aed) !important;
  box-shadow: 0 6px 18px rgba(91, 108, 255, 0.4) !important;
}

.comment-form input,
.comment-form textarea {
  border-radius: 12px !important;
  border: 1px solid var(--border-mid) !important;
  background: var(--bg) !important;
  transition: border-color 0.2s, box-shadow 0.2s !important;
}
.comment-form input:focus,
.comment-form textarea:focus {
  border-color: var(--accent) !important;
  box-shadow: 0 0 0 4px rgba(91, 108, 255, 0.15) !important;
}
.btn-comment {
  border-radius: 12px !important;
  background: linear-gradient(135deg, #5b6cff, #7c3aed) !important;
  font-weight: 700 !important;
  box-shadow: 0 6px 18px rgba(91, 108, 255, 0.3) !important;
}

.cp-link {
  transition: color 0.2s, transform 0.2s !important;
}
.cp-row:hover {
  background: var(--bg-soft) !important;
  border-radius: 12px !important;
}
.cp-row:hover .cp-link {
  transform: translateX(2px);
}

@media (max-width: 720px) {
  .nav-toggle {
    display: flex !important;
  }
  .top-header {
    position: relative !important;
    padding-left: 52px !important;
    padding-right: 16px !important;
    padding-top: 16px !important;
    padding-bottom: 10px !important;
  }
  .logo {
    font-size: 1.35rem !important;
    letter-spacing: 0.04em !important;
  }
  .logo-sub {
    font-size: 0.78rem !important;
  }
  .main-nav {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: auto !important;
    bottom: 0 !important;
    width: min(300px, 86vw) !important;
    max-width: 300px !important;
    height: 100% !important;
    height: 100dvh !important;
    z-index: 50 !important;
    transform: translateX(-105%) !important;
    transition: transform 0.28s cubic-bezier(0.22, 1, 0.36, 1) !important;
    border: none !important;
    border-right: 1px solid var(--border) !important;
    background: var(--bg-alt) !important;
    box-shadow: 8px 0 40px var(--shadow-hover) !important;
    overflow-y: auto !important;
    overflow-x: hidden !important;
    padding-top: max(56px, env(safe-area-inset-top, 0px)) !important;
    padding-bottom: env(safe-area-inset-bottom, 0px) !important;
    backdrop-filter: none !important;
    -webkit-backdrop-filter: none !important;
  }
  body.nav-open .main-nav {
    transform: translateX(0) !important;
  }
  body.nav-open {
    overflow: hidden !important;
    touch-action: none;
  }
  .main-nav .nav-inner {
    flex-direction: column !important;
    align-items: stretch !important;
    flex-wrap: nowrap !important;
    padding: 12px !important;
    gap: 2px !important;
    max-width: none !important;
    width: 100% !important;
  }
  .main-nav .nav-item {
    border-radius: 12px !important;
    padding: 12px 14px !important;
    font-size: 0.9rem !important;
    width: 100%;
    justify-content: flex-start;
    text-align: left;
  }
  .nav-search-form {
    display: flex !important;
    width: 100% !important;
    order: -1;
    margin-bottom: 8px;
  }
  .nav-overlay {
    z-index: 45 !important;
  }
  body.home-page {
    overflow: auto !important;
  }
  body.home-page .main-content {
    justify-content: flex-start !important;
    padding-top: 16px !important;
  }
  .detail-page,
  .detail-page.main-content {
    padding: 16px 12px 40px !important;
  }
  .detail-image {
    max-height: 55vh !important;
    aspect-ratio: 3 / 4;
    margin-left: auto !important;
    margin-right: auto !important;
    width: 100%;
    max-width: 420px;
  }
  .detail-layout {
    justify-items: center;
  }
  .detail-main-col .detail-layout {
    display: flex;
    flex-direction: column;
    align-items: center;
  }
  .detail-info {
    width: 100%;
  }
  .detail-info h1.detail-title,
  .detail-title {
    font-size: 1.15rem !important;
  }
  .btn-download-lg {
    width: 100% !important;
    justify-content: center !important;
    box-sizing: border-box;
  }
  .info-row {
    flex-wrap: wrap;
    gap: 4px 8px;
  }
  .info-label {
    flex: 0 0 auto;
  }
  .info-value {
    text-align: left;
  }
  .scroll-float {
    right: max(12px, env(safe-area-inset-right, 0px));
    bottom: max(14px, env(safe-area-inset-bottom, 0px));
  }
}

::selection {
  background: rgba(91, 108, 255, 0.25);
  color: var(--text-heading);
}

.toast-host {
  position: fixed;
  top: 16px;
  right: 16px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 10px;
  max-width: min(360px, calc(100vw - 24px));
  pointer-events: none;
}
.toast {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  padding: 12px 14px;
  border-radius: 12px;
  background: var(--bg-alt, #fff);
  color: var(--text, #222);
  box-shadow: 0 8px 28px rgba(0, 0, 0, 0.16);
  border: 1px solid var(--border, #e5e5e5);
  font-size: 0.9rem;
  line-height: 1.4;
  opacity: 0;
  transform: translateY(-10px);
  transition: opacity 0.25s ease, transform 0.25s ease;
  pointer-events: auto;
}
.toast.toast-in {
  opacity: 1;
  transform: translateY(0);
}
.toast.toast-out {
  opacity: 0;
  transform: translateY(-8px);
}
.toast i {
  margin-top: 2px;
  flex-shrink: 0;
}
.toast-msg {
  flex: 1;
  min-width: 0;
  word-break: break-word;
}
.toast-close {
  border: none;
  background: transparent;
  color: inherit;
  opacity: 0.55;
  cursor: pointer;
  font-size: 1.15rem;
  line-height: 1;
  padding: 0 2px;
}
.toast-close:hover { opacity: 1; }
.toast-success { border-left: 4px solid #2e7d32; }
.toast-success i { color: #2e7d32; }
.toast-error { border-left: 4px solid #c62828; }
.toast-error i { color: #c62828; }
.toast-warn { border-left: 4px solid #ef6c00; }
.toast-warn i { color: #ef6c00; }
.toast-info { border-left: 4px solid #1565c0; }
.toast-info i { color: #1565c0; }
[data-theme="dark"] .toast {
  background: #1a1d27;
  border-color: #2a2f3d;
  color: #e8eaf0;
}
@media (max-width: 520px) {
  .toast-host {
    top: auto;
    bottom: 16px;
    right: 12px;
    left: 12px;
    max-width: none;
  }
}

.cmt-actions {
  margin-top: 6px;
  display: flex;
  gap: 8px;
  align-items: center;
}
.cmt-report {
  border: none;
  background: transparent;
  color: var(--text-muted, #999);
  font-size: 0.75rem;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 4px;
  font-family: inherit;
}
.cmt-report:hover {
  color: #c62828;
  background: rgba(198, 40, 40, 0.08);
}
.cmt-report:disabled {
  opacity: 0.5;
  cursor: default;
}

.logo {
  background-image: linear-gradient(
    270deg,
    #14f927,
    #6b3177,
    #f6c14d,
    #b388d7,
    #446fe3,
    #55b9cb,
    #c9ebbb
  ) !important;
  background-size: 1200% 1200% !important;
  animation: xk01 30s ease infinite !important;
  color: transparent !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  font-weight: 900 !important;
  -webkit-text-fill-color: transparent;
  filter: none !important;
  text-decoration: none !important;
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
  line-height: 1.15;
  padding-bottom: 0.05em;
}
.logo i,
.logo .far {
  background: none !important;
  -webkit-background-clip: unset !important;
  background-clip: unset !important;
  -webkit-text-fill-color: initial !important;
  color: var(--logo-star, #42a5f5) !important;
  filter: none !important;
  animation: none !important;
}

@-webkit-keyframes xk01 {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}
@-moz-keyframes xk01 {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}
@keyframes xk01 {
  0% { background-position: 0% 50%; }
  50% { background-position: 100% 50%; }
  100% { background-position: 0% 50%; }
}

.logo-sub {
  background: repeating-linear-gradient(to right, red 0, #00f 50%, red 100%) !important;
  background-size: 200% auto !important;
  animation: xk02 2s linear infinite forwards !important;
  color: transparent !important;
  -webkit-background-clip: text !important;
  background-clip: text !important;
  -webkit-text-fill-color: transparent;
  font-weight: 600 !important;
  filter: none !important;
  text-decoration: none !important;
  line-height: 1.2;
  padding-bottom: 0.05em;
}
.logo-sub i {
  background: none !important;
  -webkit-background-clip: unset !important;
  -webkit-text-fill-color: initial !important;
  color: #ab47bc !important;
  animation: none !important;
}

@keyframes xk02 {
  0% { background-position: 0% 0%; }
  100% { background-position: -200% 0%; }
}

body {
  cursor: url(https://github.com/nokiapro/xuankenpro/raw/refs/heads/main/cursor/shubiao2.cur), default;
}
a:hover,
button:hover,
.nav-item:hover,
.card:hover,
.side-btn:hover {
  cursor: url(https://github.com/nokiapro/xuankenpro/raw/refs/heads/main/cursor/shubiao.cur), pointer;
}

.cmt-item {
  padding: 12px 0;
  border-bottom: 1px solid var(--border, #eee);
}
.cmt-item.cmt-reply {
  margin-left: 28px;
  padding-left: 12px;
  border-left: 2px solid var(--accent-soft, #e3e7ff);
}
.cmt-head {
  display: flex;
  flex-wrap: nowrap;
  align-items: center;
  gap: 6px;
  margin-bottom: 4px;
  justify-content: flex-start;
}
.cmt-head .cmt-time {
  margin-left: auto;
  flex-shrink: 0;
}
.cmt-avatar {
  width: 26px;
  height: 26px;
  border-radius: 50%;
  background: var(--accent-soft, #e8ecff);
  color: var(--accent, #5b6cff);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-size: 0.8rem;
  flex-shrink: 0;
  margin: 0;
}
.cmt-avatar.is-admin {
  background: linear-gradient(135deg, #5b6cff, #7c3aed);
  color: #fff;
}
.cmt-name {
  font-weight: 700;
  color: var(--text-heading, #222);
  font-size: 0.9rem;
  margin: 0;
  padding: 0;
  line-height: 1.2;
}
.cmt-badge {
  font-size: 0.62rem;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 999px;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  flex-shrink: 0;
  margin: 0;
  line-height: 1.2;
}
.cmt-badge-guest {
  background: #eceff1;
  color: #607d8b;
}
.cmt-badge-admin {
  background: linear-gradient(135deg, #5b6cff, #7c3aed);
  color: #fff;
}
[data-theme="dark"] .cmt-badge-guest {
  background: #2a2f3d;
  color: #aab;
}
.cmt-reply-to {
  font-size: 0.8rem;
  color: var(--text-muted, #888);
  margin: 0 0 4px;
}
.cmt-reply-to strong {
  color: var(--accent, #5b6cff);
}
.cmt-body .cmt-mention {
  color: var(--accent, #5b6cff);
  font-weight: 600;
}
.cmt-actions {
  margin-top: 6px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
.cmt-reply-btn {
  border: none;
  background: transparent;
  color: var(--text-muted, #888);
  font-size: 0.75rem;
  cursor: pointer;
  padding: 2px 6px;
  border-radius: 4px;
  font-family: inherit;
}
.cmt-reply-btn:hover {
  color: var(--accent, #5b6cff);
  background: var(--accent-soft, rgba(91,108,255,0.1));
}
.cmt-reply-bar {
  display: none;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  padding: 8px 10px;
  background: var(--bg-soft, #f5f6fa);
  border-radius: 8px;
  font-size: 0.85rem;
  color: var(--text-secondary, #555);
}
.cmt-reply-bar.is-on {
  display: flex;
}
.cmt-reply-bar button {
  border: none;
  background: transparent;
  color: #c62828;
  cursor: pointer;
  margin-left: auto;
  font-size: 0.85rem;
}