/* Spark Prompts — styles (暖雾青绿 · 低饱和舒适) */
:root {
  --bg: #f5f4f1;
  --surface: #fffcf8;
  --surface-2: #eeeae3;
  --text: #1c2128;
  --text-2: #5a6570;
  --text-3: #8b949e;
  --accent: #3d7a8c;
  --accent-hover: #2f6575;
  --accent-soft: rgba(61, 122, 140, 0.12);
  --pink: #a8878e;
  --violet: #6d7fa8;
  --cyan: #4a9aad;
  --border: rgba(45, 55, 65, 0.09);
  --shadow-sm: 0 2px 10px rgba(40, 48, 55, 0.05);
  --shadow-md: 0 12px 30px rgba(40, 48, 55, 0.07);
  --shadow-lg: 0 22px 44px rgba(40, 48, 55, 0.1);
  --radius: 16px;
  --radius-sm: 12px;
  --header-h: 64px;
  --font: "Inter", "Noto Sans SC", "PingFang SC", "Microsoft YaHei", system-ui, sans-serif;
  --display: "ZCOOL KuaiLe", "Noto Sans SC", "PingFang SC", system-ui, sans-serif;
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

[data-theme="dark"] {
  --bg: #12151a;
  --surface: #1a1f26;
  --surface-2: #242b34;
  --text: #e8edf2;
  --text-2: #a8b2bc;
  --text-3: #7b8794;
  --accent: #6eb6c5;
  --accent-hover: #8bc9d5;
  --accent-soft: rgba(110, 182, 197, 0.14);
  --pink: #b89aa1;
  --violet: #8fa0c4;
  --cyan: #6eb6c5;
  --border: rgba(180, 200, 215, 0.1);
  --shadow-sm: 0 2px 10px rgba(0, 0, 0, 0.28);
  --shadow-md: 0 12px 30px rgba(0, 0, 0, 0.36);
  --shadow-lg: 0 22px 44px rgba(0, 0, 0, 0.45);
}

*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: var(--font);
  background: var(--bg);
  color: var(--text);
  line-height: 1.55;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
  overflow-x: hidden;
  position: relative;
}

.skip-link {
  position: fixed;
  top: 10px;
  left: 10px;
  z-index: 500;
  padding: 10px 14px;
  border-radius: 10px;
  background: var(--text);
  color: var(--bg);
  font-weight: 700;
  transform: translateY(-150%);
  transition: transform 0.18s var(--ease);
}

.skip-link:focus {
  transform: translateY(0);
}

:where(a, button, input, select, [tabindex]):focus-visible {
  outline: 3px solid color-mix(in srgb, var(--accent) 58%, transparent);
  outline-offset: 3px;
}

/* 樱词风背景层 */
.bg-layer {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.site-header,
.hero,
.gallery,
.howto,
.site-footer,
.modal-backdrop,
.back-top,
.toast {
  position: relative;
  z-index: 1;
}

.site-header {
  z-index: 100;
}

.modal-backdrop {
  z-index: 200;
}

.toast {
  z-index: 300;
}

.orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(56px);
  opacity: 0.28;
  animation: floaty 18s ease-in-out infinite;
}

.orb-a {
  width: 320px;
  height: 320px;
  left: -80px;
  top: 60px;
  background: var(--pink);
}

.orb-b {
  width: 280px;
  height: 280px;
  right: -60px;
  top: 200px;
  background: var(--violet);
  animation-delay: -4s;
}

.orb-c {
  width: 240px;
  height: 240px;
  left: 42%;
  bottom: 6%;
  background: var(--cyan);
  animation-delay: -7s;
  opacity: 0.22;
}

.grid-glow {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(61, 122, 140, 0.03) 1px, transparent 1px),
    linear-gradient(90deg, rgba(61, 122, 140, 0.03) 1px, transparent 1px);
  background-size: 48px 48px;
  mask-image: radial-gradient(circle at center, black 18%, transparent 78%);
  opacity: 0.35;
}

[data-theme="dark"] .grid-glow {
  background-image:
    linear-gradient(rgba(255, 255, 255, 0.035) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, 0.035) 1px, transparent 1px);
}

.sakura-field {
  position: absolute;
  inset: 0;
}

.petal {
  position: absolute;
  top: -24px;
  width: 9px;
  height: 12px;
  background: linear-gradient(135deg, #d5e8ec, #6eb6c5);
  border-radius: 80% 0 80% 0;
  opacity: 0.32;
  animation: fall linear infinite;
  filter: drop-shadow(0 0 4px rgba(61, 122, 140, 0.15));
  --drift: 0px;
}

.petal-b {
  width: 7px;
  height: 10px;
  background: linear-gradient(135deg, #e4e8f0, #8fa0c4);
  border-radius: 70% 0 70% 20%;
}

.petal-c {
  width: 10px;
  height: 9px;
  background: linear-gradient(120deg, #e8f0e8, #8bb89a 70%);
  border-radius: 50% 0 50% 50%;
}

.starfield {
  position: absolute;
  inset: 0;
}

.twinkle {
  position: absolute;
  width: 3px;
  height: 3px;
  border-radius: 50%;
  background: #fff;
  box-shadow: 0 0 8px 2px rgba(255, 182, 220, 0.85);
  animation: twinkle ease-in-out infinite;
  opacity: 0.7;
}

[data-theme="light"] .twinkle {
  background: #f9a8d4;
  box-shadow: 0 0 8px 2px rgba(236, 72, 153, 0.45);
}

@keyframes floaty {
  0%,
  100% {
    transform: translateY(0) scale(1);
  }
  50% {
    transform: translateY(-28px) scale(1.05);
  }
}

@keyframes fall {
  0% {
    transform: translate3d(0, -10vh, 0) rotate(0deg);
  }
  100% {
    transform: translate3d(var(--drift), 110vh, 0) rotate(420deg);
  }
}

@keyframes twinkle {
  0%,
  100% {
    opacity: 0.25;
    transform: scale(0.8);
  }
  50% {
    opacity: 1;
    transform: scale(1.35);
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }

  .orb,
  .petal,
  .twinkle,
  .deco-float,
  .card-shine,
  .loading-spinner {
    animation: none !important;
  }
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input {
  font: inherit;
}

img {
  max-width: 100%;
  display: block;
}

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--header-h);
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0 clamp(16px, 4vw, 40px);
  background: color-mix(in srgb, var(--bg) 82%, transparent);
  backdrop-filter: saturate(180%) blur(16px);
  border-bottom: 1px solid var(--border);
}

.logo {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  font-size: 1.05rem;
  letter-spacing: -0.02em;
}

.logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1.15;
  gap: 2px;
}

.logo-text strong {
  font-family: var(--display);
  font-weight: 400;
  font-size: 1.12rem;
  letter-spacing: 0.02em;
}

.logo-text small {
  font-size: 0.68rem;
  font-weight: 500;
  color: var(--text-3);
  letter-spacing: 0.04em;
}

.logo-mark {
  width: 40px;
  height: 40px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  flex-shrink: 0;
  overflow: hidden;
  box-shadow: 0 4px 14px rgba(61, 122, 140, 0.2);
  background: transparent;
  border: none;
  padding: 0;
  transition: transform 0.2s var(--ease), box-shadow 0.2s var(--ease);
}

.logo-mark img,
.logo-mark svg {
  width: 100%;
  height: 100%;
  display: block;
}

.logo:hover .logo-mark {
  transform: translateY(-1px);
  box-shadow: 0 6px 18px rgba(61, 122, 140, 0.28);
}

.logo-text strong {
  letter-spacing: 0.02em;
}

.header-nav {
  display: flex;
  align-items: center;
  gap: 18px;
  margin-left: auto;
  margin-right: 12px;
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-2);
}

.header-nav a {
  position: relative;
  padding: 4px 2px;
  transition: color 0.15s;
}

.header-nav a:hover {
  color: var(--accent);
}

.header-nav a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -4px;
  height: 2px;
  border-radius: 2px;
  background: linear-gradient(90deg, #3d7a8c, #6d7fa8);
  transform: scaleX(0);
  transition: transform 0.2s var(--ease);
}

.header-nav a:hover::after {
  transform: scaleX(1);
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.icon-btn {
  width: 40px;
  height: 40px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
  display: grid;
  place-items: center;
  transition: background 0.2s var(--ease), transform 0.2s var(--ease);
}

.icon-btn:hover {
  background: var(--surface-2);
  transform: translateY(-1px);
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 12px 22px;
  border-radius: 999px;
  border: none;
  cursor: pointer;
  font-weight: 600;
  font-size: 0.95rem;
  transition: transform 0.2s var(--ease), background 0.2s, box-shadow 0.2s;
}

.btn:hover {
  transform: translateY(-1px);
}

.btn:active {
  transform: translateY(0);
}

.btn-primary {
  background: linear-gradient(135deg, #5a9fad, #3d7a8c 50%, #4a7088);
  color: #fff;
  box-shadow: 0 8px 20px rgba(61, 122, 140, 0.24);
  text-shadow: none;
}

.btn-primary:hover {
  filter: brightness(1.04);
  background: linear-gradient(135deg, #67aab7, #458796 50%, #547e94);
}

.btn-secondary {
  background: var(--surface);
  color: var(--text);
  border: 1px solid var(--border);
}

.btn-secondary:hover {
  background: var(--surface-2);
}

.btn-ghost {
  background: transparent;
  color: var(--text-2);
  border: 1px solid transparent;
}

.btn-ghost:hover {
  background: var(--surface-2);
  color: var(--text);
}

/* Hero */
.hero {
  position: relative;
  text-align: center;
  padding: clamp(40px, 8vw, 80px) 20px 36px;
  max-width: 920px;
  margin: 0 auto;
}

.hero-glow {
  position: absolute;
  inset: -20% -10% auto;
  height: 70%;
  background:
    radial-gradient(ellipse 50% 60% at 50% 0%, rgba(61, 122, 140, 0.16), transparent 70%),
    radial-gradient(ellipse 40% 50% at 80% 20%, rgba(109, 127, 168, 0.12), transparent 65%),
    radial-gradient(ellipse 35% 45% at 15% 30%, rgba(74, 154, 173, 0.1), transparent 60%);
  pointer-events: none;
  z-index: -1;
}

[data-theme="dark"] .hero-glow {
  background:
    radial-gradient(ellipse 50% 60% at 50% 0%, rgba(110, 182, 197, 0.14), transparent 70%),
    radial-gradient(ellipse 40% 50% at 80% 20%, rgba(143, 160, 196, 0.1), transparent 65%),
    radial-gradient(ellipse 35% 45% at 15% 30%, rgba(110, 182, 197, 0.08), transparent 60%);
}

.hero-deco {
  position: absolute;
  inset: 0;
  pointer-events: none;
  overflow: hidden;
}

.deco-float {
  position: absolute;
  font-size: 1.1rem;
  opacity: 0.55;
  color: var(--accent);
  animation: bob 5s ease-in-out infinite;
  text-shadow: 0 0 12px rgba(244, 114, 182, 0.45);
}

.deco-float.d1 { left: 6%; top: 18%; animation-delay: 0s; opacity: 0.45; }
.deco-float.d2 { right: 10%; top: 22%; animation-delay: -1s; color: var(--cyan); opacity: 0.4; }
.deco-float.d3 { left: 14%; bottom: 28%; animation-delay: -2s; opacity: 0.35; }
.deco-float.d4 { right: 8%; bottom: 32%; animation-delay: -1.5s; color: var(--violet); opacity: 0.4; }
.deco-float.d5 { left: 48%; top: 8%; animation-delay: -0.5s; font-size: 0.9rem; opacity: 0.35; }

@keyframes bob {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-10px); }
}

.hero-kicker {
  font-family: var(--display);
  font-size: 0.95rem;
  color: var(--text-2);
  letter-spacing: 0.12em;
  margin-bottom: 10px;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 14px 6px 8px;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 20px;
}

.hero-badge-logo {
  width: 20px;
  height: 20px;
  border-radius: 6px;
  display: block;
  box-shadow: 0 2px 6px rgba(61, 122, 140, 0.2);
}

.hero h1,
.hero-title {
  font-family: var(--display);
  font-size: clamp(2.3rem, 6.2vw, 3.7rem);
  line-height: 1.18;
  letter-spacing: 0.02em;
  font-weight: 400;
  margin-bottom: 16px;
}

.hero h1 span,
.hero-title span {
  background: linear-gradient(120deg, #3d7a8c, #4a9aad, #6d7fa8);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

[data-theme="dark"] .hero h1 span,
[data-theme="dark"] .hero-title span {
  background: linear-gradient(120deg, #6eb6c5, #8bc9d5, #a8b8d8);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.hero code {
  font-size: 0.9em;
  padding: 1px 6px;
  border-radius: 6px;
  background: var(--accent-soft);
  color: var(--accent);
}

.hero p,
.hero-lead {
  color: var(--text-2);
  font-size: clamp(1rem, 2.2vw, 1.15rem);
  max-width: 560px;
  margin: 0 auto 28px;
}

.bubble-stat {
  position: relative;
  padding: 10px 16px 12px;
  border-radius: 16px;
  background: color-mix(in srgb, var(--surface) 92%, var(--accent));
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  min-width: 88px;
}

.bubble-stat::after {
  content: "";
  position: absolute;
  left: 14px;
  bottom: -6px;
  width: 10px;
  height: 10px;
  background: inherit;
  border-right: 1px solid var(--border);
  border-bottom: 1px solid var(--border);
  transform: rotate(45deg);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  justify-content: center;
}

/* —— 滚动播报 —— */
.hero-ticker {
  display: flex;
  align-items: center;
  gap: 10px;
  margin: 28px auto 0;
  max-width: 860px;
  padding: 0 4px;
}

.hero-ticker-b {
  margin-top: 10px;
}

.ticker-label {
  flex: 0 0 auto;
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  color: var(--accent);
  padding: 6px 10px;
  border-radius: 999px;
  background: var(--accent-soft);
  border: 1px solid var(--border);
}

.ticker-viewport {
  flex: 1;
  min-width: 0;
  overflow: hidden;
  mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
  -webkit-mask-image: linear-gradient(90deg, transparent, #000 8%, #000 92%, transparent);
}

.ticker-track {
  display: flex;
  width: max-content;
  gap: 10px;
  animation: ticker-scroll 48s linear infinite;
}

.ticker-track-rev {
  animation-name: ticker-scroll-rev;
  animation-duration: 56s;
}

.hero-ticker:hover .ticker-track,
.hero-ticker:hover .ticker-track-rev {
  animation-play-state: paused;
}

@keyframes ticker-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

@keyframes ticker-scroll-rev {
  from { transform: translateX(-50%); }
  to { transform: translateX(0); }
}

.ticker-chip {
  flex: 0 0 auto;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  border-radius: 999px;
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
  font-size: 0.85rem;
  color: var(--text);
  cursor: pointer;
  transition: border-color 0.2s, transform 0.2s, box-shadow 0.2s;
  white-space: nowrap;
  max-width: 240px;
}

.ticker-chip:hover {
  border-color: color-mix(in srgb, var(--accent) 45%, var(--border));
  transform: translateY(-1px);
  box-shadow: var(--shadow-md);
}

.ticker-chip .tc-emoji {
  font-size: 1rem;
}

.ticker-chip .tc-title {
  overflow: hidden;
  text-overflow: ellipsis;
}

.ticker-chip .tc-cat {
  font-size: 0.7rem;
  color: var(--text-3);
  padding: 2px 6px;
  border-radius: 6px;
  background: var(--surface-2);
}

/* —— 精选轮播 —— */
.hero-spotlight {
  position: relative;
  margin: 28px auto 0;
  max-width: 560px;
  padding: 0 40px;
}

.spotlight-stage {
  position: relative;
  min-height: 118px;
}

.spotlight-card {
  position: absolute;
  inset: 0;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 8px;
  text-align: left;
  padding: 18px 20px;
  border-radius: 18px;
  background: var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-md);
  opacity: 0;
  transform: translateY(8px) scale(0.98);
  pointer-events: none;
  transition: opacity 0.45s var(--ease), transform 0.45s var(--ease);
  cursor: pointer;
}

.spotlight-card.active {
  opacity: 1;
  transform: none;
  pointer-events: auto;
  position: relative;
}

.spotlight-card .sp-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.78rem;
  color: var(--text-3);
}

.spotlight-card .sp-emoji {
  font-size: 1.35rem;
}

.spotlight-card .sp-title {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text);
  line-height: 1.35;
}

.spotlight-card .sp-summary {
  font-size: 0.88rem;
  color: var(--text-2);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.spotlight-nav {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  cursor: pointer;
  font-size: 1.2rem;
  line-height: 1;
  z-index: 2;
  box-shadow: var(--shadow-sm);
}

.spotlight-nav:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.spotlight-nav.prev { left: 0; }
.spotlight-nav.next { right: 0; }

.spotlight-dots {
  display: flex;
  justify-content: center;
  gap: 6px;
  margin-top: 12px;
}

.spotlight-dots button {
  width: 7px;
  height: 7px;
  border-radius: 50%;
  border: none;
  padding: 0;
  background: var(--text-3);
  opacity: 0.35;
  cursor: pointer;
}

.spotlight-dots button.active {
  opacity: 1;
  background: var(--accent);
  width: 18px;
  border-radius: 999px;
}

@media (prefers-reduced-motion: reduce) {
  .ticker-track,
  .ticker-track-rev {
    animation: none;
  }
}

@media (max-width: 640px) {
  .hero-ticker .ticker-label {
    display: none;
  }
  .hero-spotlight {
    padding: 0 36px;
  }
  .ticker-chip .tc-cat {
    display: none;
  }
}

.stats {
  display: flex;
  justify-content: center;
  gap: clamp(24px, 6vw, 48px);
  margin-top: 36px;
  padding-top: 28px;
  border-top: 1px solid var(--border);
}

.stat strong {
  display: block;
  font-size: 1.4rem;
  letter-spacing: -0.02em;
}

.stat span {
  color: var(--text-3);
  font-size: 0.85rem;
}

/* Gallery */
.gallery {
  max-width: 1240px;
  margin: 0 auto;
  padding: 20px clamp(16px, 4vw, 36px) 96px;
}

.controls {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin-bottom: 12px;
  padding: 10px;
  border-radius: 18px;
  transition: background 0.25s var(--ease), box-shadow 0.25s var(--ease), border-color 0.25s;
  border: 1px solid transparent;
  position: sticky;
  top: calc(var(--header-h) + 4px);
  z-index: 40;
}

.controls.is-stuck {
  background: color-mix(in srgb, var(--bg) 88%, transparent);
  backdrop-filter: saturate(180%) blur(14px);
  border-color: var(--border);
  box-shadow: var(--shadow-sm);
}

.search-bar {
  position: relative;
  flex: 1 1 240px;
  min-width: 200px;
}

.search-bar svg {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--text-3);
  pointer-events: none;
}

.search-bar input {
  width: 100%;
  height: 44px;
  padding: 0 40px 0 40px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  outline: none;
  transition: border-color 0.2s, box-shadow 0.2s;
}

.search-bar input:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.search-clear {
  position: absolute;
  right: 10px;
  top: 50%;
  transform: translateY(-50%);
  width: 26px;
  height: 26px;
  border: none;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--text-2);
  cursor: pointer;
  font-size: 1rem;
  line-height: 1;
  display: grid;
  place-items: center;
}

.search-clear:hover {
  color: var(--text);
  background: var(--border);
}

.toolbar-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px 16px;
  margin-bottom: 16px;
  min-height: 28px;
}

.result-line {
  color: var(--text-3);
  font-size: 0.88rem;
}

.result-line strong {
  color: var(--text);
  font-weight: 650;
}

.active-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-2);
  font-size: 0.78rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.15s, color 0.15s;
}

.chip:hover {
  background: var(--accent-soft);
  color: var(--accent);
  border-color: transparent;
}

.sort-wrap {
  display: inline-flex;
}

.sort-select {
  height: 40px;
  padding: 0 28px 0 12px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface)
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='10' height='6' viewBox='0 0 10 6'%3E%3Cpath d='M1 1l4 4 4-4' fill='none' stroke='%2386868b' stroke-width='1.5'/%3E%3C/svg%3E")
    no-repeat right 12px center;
  color: var(--text-2);
  font-weight: 500;
  font-size: 0.9rem;
  cursor: pointer;
  appearance: none;
  -webkit-appearance: none;
  outline: none;
}

.sort-select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px var(--accent-soft);
}

.filter-reset {
  opacity: 0.45;
  pointer-events: none;
}

.filter-reset.visible {
  opacity: 1;
  pointer-events: auto;
}

.filters {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.filter-btn,
.category-trigger {
  height: 40px;
  padding: 0 14px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-2);
  cursor: pointer;
  font-weight: 500;
  font-size: 0.9rem;
  transition: all 0.2s var(--ease);
}

.filter-btn:hover,
.category-trigger:hover {
  background: var(--surface-2);
  color: var(--text);
}

.filter-btn.active {
  background: var(--text);
  color: var(--bg);
  border-color: transparent;
}

[data-theme="dark"] .filter-btn.active {
  background: #f5f5f7;
  color: #0b0b0f;
}

.category-dropdown {
  position: relative;
}

.category-trigger {
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.category-options {
  position: absolute;
  top: calc(100% + 8px);
  left: 0;
  min-width: 200px;
  max-height: min(70vh, 420px);
  overflow-y: auto;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  box-shadow: var(--shadow-md);
  padding: 6px;
  display: none;
  z-index: 50;
}

.category-options.open {
  display: block;
}

.category-option {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  text-align: left;
  padding: 10px 12px;
  border: none;
  border-radius: 8px;
  background: transparent;
  color: var(--text);
  cursor: pointer;
  font-size: 0.9rem;
}

.category-option .cat-count {
  font-size: 0.75rem;
  font-variant-numeric: tabular-nums;
  color: var(--text-3);
  background: var(--surface-2);
  padding: 2px 8px;
  border-radius: 999px;
  min-width: 1.75rem;
  text-align: center;
}

.category-option:hover,
.category-option.active {
  background: var(--accent-soft);
  color: var(--accent);
}

.category-option.active .cat-count,
.category-option:hover .cat-count {
  color: var(--accent);
  background: color-mix(in srgb, var(--accent) 14%, transparent);
}

/* Announcement — 精简单行提示条 */
.announcement {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  background: color-mix(in srgb, var(--accent) 6%, var(--surface));
  border: 1px solid color-mix(in srgb, var(--accent) 12%, var(--border));
  border-radius: 999px;
  padding: 8px 14px 8px 12px;
  margin-bottom: 16px;
  min-height: 0;
  overflow: hidden;
  box-shadow: none;
}

.announcement-icon {
  flex-shrink: 0;
  width: 26px;
  height: 26px;
  display: grid;
  place-items: center;
  border-radius: 999px;
  background: var(--accent-soft);
  color: var(--accent);
  font-size: 0.78rem;
  font-weight: 700;
}

#announcementSlides {
  flex: 1;
  min-width: 0;
  position: relative;
}

.announcement-slide {
  display: none;
  align-items: baseline;
  gap: 6px 10px;
  flex-wrap: wrap;
  animation: fadeIn 0.35s var(--ease);
  line-height: 1.45;
}

.announcement-slide.active {
  display: flex;
}

.announcement-slide strong {
  display: inline;
  margin: 0;
  font-size: 0.86rem;
  font-weight: 600;
  color: var(--text);
}

.announcement-slide p,
.announcement-slide .ann-body {
  margin: 0;
  display: inline;
  color: var(--text-2);
  font-size: 0.84rem;
}

.announcement-slide .ann-sep {
  color: var(--text-3);
  opacity: 0.55;
}

.announcement-dots {
  position: static;
  flex-shrink: 0;
  display: flex;
  gap: 5px;
  align-items: center;
}

.announcement-dots button {
  width: 5px;
  height: 5px;
  border-radius: 999px;
  border: none;
  background: var(--text-3);
  opacity: 0.3;
  cursor: pointer;
  padding: 0;
  transition: width 0.2s, opacity 0.2s, background 0.2s;
}

.announcement-dots button.active {
  opacity: 1;
  background: var(--accent);
  width: 14px;
}

/* Tag cloud */
.tag-cloud-wrap {
  margin-bottom: 20px;
  padding: 12px 14px;
  border-radius: var(--radius);
  background: color-mix(in srgb, var(--surface) 88%, var(--surface-2));
  border: 1px solid var(--border);
}

.tag-cloud-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 10px;
}

.tag-cloud-head-left {
  display: flex;
  align-items: center;
  gap: 8px;
}

.tag-cloud-head span {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-3);
  letter-spacing: 0.04em;
}

.tag-cloud-actions {
  display: flex;
  align-items: center;
  gap: 4px;
}

.tag-cloud-clear,
.tag-cloud-toggle {
  border: none;
  background: transparent;
  color: var(--accent);
  font-size: 0.8rem;
  cursor: pointer;
  padding: 2px 8px;
  border-radius: 6px;
  font-family: inherit;
}

.tag-cloud-clear:hover,
.tag-cloud-toggle:hover {
  background: var(--accent-soft);
}

.tag-cloud-clear[hidden],
.tag-cloud-toggle[hidden] {
  display: none;
}

.tag-cloud {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}

.tag-cloud.is-collapsed .tag-cloud-item.is-extra {
  display: none;
}

.tag-cloud-item {
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-2);
  border-radius: 999px;
  padding: 5px 11px;
  cursor: pointer;
  line-height: 1.3;
  transition: background 0.18s, border-color 0.18s, color 0.18s, transform 0.18s;
  font-family: inherit;
}

.tag-cloud-item:hover {
  border-color: color-mix(in srgb, var(--accent) 35%, var(--border));
  color: var(--text);
  background: color-mix(in srgb, var(--accent) 5%, var(--surface));
}

.tag-cloud-item.active {
  border-color: transparent;
  background: var(--accent);
  color: #fff;
  box-shadow: 0 4px 12px color-mix(in srgb, var(--accent) 28%, transparent);
}

.tag-cloud-item .tc-n {
  margin-left: 5px;
  opacity: 0.55;
  font-size: 0.78em;
  font-variant-numeric: tabular-nums;
}

.tag-cloud-item.active .tc-n {
  opacity: 0.85;
}

.tag-cloud-item.w1 { font-size: 0.78rem; opacity: 0.88; }
.tag-cloud-item.w2 { font-size: 0.84rem; }
.tag-cloud-item.w3 { font-size: 0.9rem; font-weight: 500; }
.tag-cloud-item.w4 { font-size: 0.96rem; font-weight: 600; }
.tag-cloud-item.w5 { font-size: 1.02rem; font-weight: 650; color: var(--text); }

.filters {
  scrollbar-width: thin;
}

@media (max-width: 800px) {
  .filters {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    gap: 8px;
    padding-bottom: 4px;
    -webkit-overflow-scrolling: touch;
    mask-image: linear-gradient(90deg, #000 88%, transparent);
  }

  .filters > * {
    flex-shrink: 0;
  }

  .hero-ticker-b {
    display: none;
  }

  .hero-spotlight {
    margin-top: 18px;
  }

  .announcement {
    border-radius: 14px;
    padding: 10px 12px;
  }

  .announcement-slide .ann-sep,
  .announcement-slide .ann-body {
    display: none;
  }

  .tag-cloud-wrap {
    padding: 10px 12px;
  }
}

.card .tag[data-tag],
.card .tag[data-cat] {
  cursor: pointer;
  transition: background 0.15s, color 0.15s, border-color 0.15s;
}

.card .tag[data-tag]:hover,
.card .tag[data-cat]:hover {
  background: var(--accent-soft);
  color: var(--accent);
  border-color: color-mix(in srgb, var(--accent) 25%, transparent);
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(4px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

/* Grid */
.grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(268px, 1fr));
  gap: 20px;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
  cursor: pointer;
  transition: transform 0.25s var(--ease), box-shadow 0.25s var(--ease), border-color 0.25s;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  position: relative;
  content-visibility: auto;
  contain-intrinsic-size: auto 320px;
}

.card::before {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1px;
  background: linear-gradient(135deg, rgba(61, 122, 140, 0.22), transparent 42%, rgba(109, 127, 168, 0.18));
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
  opacity: 0.35;
  z-index: 2;
}

.card:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-md), 0 0 0 1px color-mix(in srgb, var(--accent) 14%, transparent);
}

.card-anime {
  box-shadow: var(--shadow-sm);
}

.card-anime:hover {
  transform: translateY(-4px);
}

.card-cover {
  height: 148px;
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: flex-start;
  padding: 14px;
  overflow: hidden;
}

.card-shine {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    115deg,
    transparent 30%,
    rgba(255, 255, 255, 0.35) 48%,
    transparent 62%
  );
  transform: translateX(-120%);
  animation: shine 5.5s ease-in-out infinite;
  pointer-events: none;
}

.card:hover .card-shine {
  animation-duration: 2.2s;
}

@keyframes shine {
  0%,
  55%,
  100% {
    transform: translateX(-120%);
  }
  70% {
    transform: translateX(120%);
  }
}

.card-corner {
  position: absolute;
  top: 0;
  left: 0;
  width: 28px;
  height: 28px;
  border-top: 2px solid rgba(255, 255, 255, 0.55);
  border-left: 2px solid rgba(255, 255, 255, 0.55);
  border-top-left-radius: 4px;
  opacity: 0.7;
  pointer-events: none;
}

.card-badge-anime {
  position: absolute;
  left: 10px;
  top: 10px;
  font-family: var(--display);
  font-size: 0.78rem;
  padding: 2px 8px;
  border-radius: 999px;
  background: linear-gradient(135deg, #5a9fad, #3d7a8c);
  color: #fff;
  box-shadow: 0 3px 8px rgba(61, 122, 140, 0.25);
  z-index: 1;
}

.card-emoji {
  font-size: 2rem;
  filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.2));
}

.card-actions {
  position: absolute;
  top: 10px;
  right: 10px;
  display: flex;
  gap: 6px;
}

.card-icon-btn {
  width: 34px;
  height: 34px;
  border-radius: 999px;
  border: none;
  background: rgba(255, 255, 255, 0.88);
  backdrop-filter: blur(8px);
  cursor: pointer;
  display: grid;
  place-items: center;
  color: #71717a;
  transition: transform 0.15s, color 0.15s, background 0.15s;
}

[data-theme="dark"] .card-icon-btn {
  background: rgba(0, 0, 0, 0.5);
  color: #d4d4d8;
}

.card-icon-btn:hover {
  transform: scale(1.08);
  color: var(--accent);
}

.card-fav.active {
  color: #f43f5e;
}

.card-date {
  margin-left: auto;
  font-size: 0.72rem;
  color: var(--text-3);
  font-weight: 500;
}

.card-body {
  padding: 14px 16px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
  flex: 1;
}

.card-title {
  font-family: var(--display);
  font-size: 1.05rem;
  font-weight: 400;
  letter-spacing: 0.02em;
}

.card-anime .card-title {
  background: linear-gradient(90deg, var(--text), #db2777);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

[data-theme="dark"] .card-anime .card-title {
  background: linear-gradient(90deg, #f8f0ff, #f9a8d4);
  -webkit-background-clip: text;
  background-clip: text;
}

.card-summary {
  color: var(--text-2);
  font-size: 0.86rem;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1;
}

.card-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  align-items: center;
  margin-top: 4px;
}

.tag {
  font-size: 0.72rem;
  font-weight: 600;
  padding: 3px 8px;
  border-radius: 999px;
  background: var(--surface-2);
  color: var(--text-2);
}

.tag.accent {
  background: var(--accent-soft);
  color: var(--accent);
}

.card-anime .tag.accent {
  background: var(--accent-soft);
  color: var(--accent);
  border: 1px solid color-mix(in srgb, var(--accent) 22%, transparent);
}

[data-theme="dark"] .card-anime .tag.accent {
  color: var(--accent);
}

.empty {
  grid-column: 1 / -1;
  text-align: center;
  padding: 64px 20px;
  color: var(--text-2);
}

.empty strong {
  display: block;
  color: var(--text);
  margin-bottom: 8px;
  font-size: 1.1rem;
}

.empty p {
  margin-bottom: 18px;
}

.loading-state {
  grid-column: 1 / -1;
  min-height: 220px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 14px;
  color: var(--text-2);
}

.loading-spinner {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 3px solid var(--accent-soft);
  border-top-color: var(--accent);
  animation: loading-spin 0.8s linear infinite;
}

@keyframes loading-spin {
  to {
    transform: rotate(360deg);
  }
}

.load-error code {
  padding: 2px 6px;
  border-radius: 6px;
  background: var(--surface-2);
  color: var(--text);
}

.noscript {
  position: fixed;
  inset: auto 16px 16px;
  z-index: 400;
  padding: 14px 18px;
  border: 1px solid var(--border);
  border-radius: 12px;
  background: var(--surface);
  color: var(--text);
  box-shadow: var(--shadow-md);
  text-align: center;
}

.prompt-meta-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
  margin-bottom: 8px;
  font-size: 0.8rem;
  color: var(--text-3);
}

.modal-actions .btn-secondary.active {
  border-color: #f43f5e;
  color: #f43f5e;
}

/* Back to top */
.back-top {
  position: fixed;
  right: 20px;
  bottom: 24px;
  width: 44px;
  height: 44px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  box-shadow: var(--shadow-md);
  cursor: pointer;
  display: grid;
  place-items: center;
  opacity: 0;
  pointer-events: none;
  transform: translateY(12px);
  transition: opacity 0.25s var(--ease), transform 0.25s var(--ease);
  z-index: 90;
}

.back-top.show {
  opacity: 1;
  pointer-events: auto;
  transform: none;
}

.back-top:hover {
  background: var(--accent);
  color: #fff;
  border-color: transparent;
}

/* Modal */
.modal-backdrop {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.45);
  backdrop-filter: blur(6px);
  z-index: 200;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 20px;
}

.modal-backdrop.open {
  display: flex;
}

.modal {
  width: min(720px, 100%);
  max-height: min(88vh, 900px);
  background: var(--surface);
  border-radius: 22px;
  border: 1px solid var(--border);
  box-shadow: var(--shadow-lg), 0 0 40px rgba(244, 114, 182, 0.12);
  overflow: hidden;
  display: flex;
  flex-direction: column;
  animation: modalIn 0.28s var(--ease);
}

.modal-body h2 {
  font-family: var(--display);
  font-weight: 400;
}

@keyframes modalIn {
  from {
    opacity: 0;
    transform: translateY(12px) scale(0.98);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

.modal-cover {
  height: 140px;
  position: relative;
  flex-shrink: 0;
}

.modal-close {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 36px;
  height: 36px;
  border-radius: 999px;
  border: none;
  background: rgba(0, 0, 0, 0.4);
  color: #fff;
  cursor: pointer;
  display: grid;
  place-items: center;
}

.modal-body {
  padding: 20px 22px 22px;
  overflow: auto;
}

.modal-body h2 {
  font-size: 1.4rem;
  letter-spacing: 0.02em;
  margin-bottom: 8px;
}

.modal-summary {
  color: var(--text-2);
  margin-bottom: 14px;
  font-size: 0.95rem;
}

.modal-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 16px;
}

.prompt-box {
  position: relative;
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 14px 16px;
  font-family: ui-monospace, "SF Mono", Menlo, Consolas, monospace;
  font-size: 0.84rem;
  line-height: 1.65;
  white-space: pre-wrap;
  word-break: break-word;
  color: var(--text);
  max-height: 280px;
  overflow: auto;
}

.modal-nav-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-top: 14px;
  padding-top: 12px;
  border-top: 1px solid var(--border);
}

.modal-nav-btn {
  padding: 8px 12px !important;
  height: auto !important;
  font-size: 0.88rem;
}

.modal-nav-btn:disabled {
  opacity: 0.35;
  cursor: not-allowed;
}

.modal-pos {
  font-size: 0.82rem;
  color: var(--text-3);
  font-variant-numeric: tabular-nums;
  white-space: nowrap;
}

.modal-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 12px;
}

.load-more-wrap {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
  margin-top: 28px;
  padding: 8px 0 12px;
}

.load-more-hint {
  font-size: 0.88rem;
  color: var(--text-3);
}

.load-more-sentinel {
  width: 100%;
  height: 1px;
  pointer-events: none;
}

/* Toast */
.toast {
  position: fixed;
  bottom: 28px;
  left: 50%;
  transform: translateX(-50%) translateY(20px);
  background: var(--text);
  color: var(--bg);
  padding: 12px 20px;
  border-radius: 999px;
  font-size: 0.9rem;
  font-weight: 600;
  opacity: 0;
  pointer-events: none;
  transition: all 0.3s var(--ease);
  z-index: 300;
  box-shadow: var(--shadow-md);
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}

/* Footer */
.site-footer {
  border-top: 1px solid var(--border);
  padding: 32px 20px 48px;
  text-align: center;
  color: var(--text-3);
  font-size: 0.9rem;
}

.site-footer a {
  color: var(--accent);
  font-weight: 500;
}

.site-footer p + p {
  margin-top: 8px;
}

/* How-to */
.howto {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 clamp(16px, 4vw, 32px) 64px;
}

.howto h2 {
  text-align: center;
  font-size: 1.5rem;
  letter-spacing: -0.02em;
  margin-bottom: 24px;
}

.howto-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 14px;
}

.howto-item {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 20px;
  box-shadow: var(--shadow-sm);
}

.howto-item .num {
  width: 28px;
  height: 28px;
  border-radius: 8px;
  background: var(--accent-soft);
  color: var(--accent);
  display: grid;
  place-items: center;
  font-weight: 700;
  font-size: 0.85rem;
  margin-bottom: 12px;
}

.howto-item h3 {
  font-size: 1rem;
  margin-bottom: 6px;
}

.howto-item p {
  color: var(--text-2);
  font-size: 0.88rem;
}

.card-preview-img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  z-index: 0;
}

.card-emoji:empty {
  display: none;
}

.card-cover .card-emoji,
.card-cover .card-shine,
.card-cover .card-corner,
.card-cover .card-actions,
.card-cover .card-badge-anime,
.card-cover .card-badge-img {
  z-index: 1;
}

.card-badge-img {
  position: absolute;
  left: 10px;
  bottom: 10px;
  font-size: 0.7rem;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(0, 0, 0, 0.45);
  color: #fff;
  backdrop-filter: blur(6px);
}

/* —— Banana 对照表格 —— */
.banana-section {
  max-width: 1200px;
  margin: 0 auto;
  padding: 12px clamp(16px, 4vw, 32px) 72px;
  position: relative;
  z-index: 1;
}

.banana-head {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-end;
  justify-content: space-between;
  gap: 20px;
  margin-bottom: 22px;
  padding: 22px 24px;
  border-radius: 22px;
  background:
    linear-gradient(135deg, rgba(255, 214, 102, 0.18), rgba(244, 114, 182, 0.12) 45%, rgba(139, 92, 246, 0.1)),
    var(--surface);
  border: 1px solid var(--border);
  box-shadow: var(--shadow-sm);
}

.banana-kicker {
  font-family: var(--display);
  color: var(--accent);
  font-size: 0.95rem;
  margin-bottom: 6px;
  letter-spacing: 0.06em;
}

[data-theme="dark"] .banana-kicker {
  color: #f9a8d4;
}

.showcase-head {
  background:
    linear-gradient(135deg, rgba(192, 38, 211, 0.12), rgba(236, 72, 153, 0.1) 50%, rgba(139, 92, 246, 0.12)),
    var(--surface) !important;
}

.showcase-badge {
  background: linear-gradient(145deg, #ec4899, #c026d3 50%, #8b5cf6) !important;
  color: #fff !important;
  box-shadow: 0 10px 28px rgba(192, 38, 211, 0.35) !important;
}

.about-section .howto-item .num {
  width: auto;
  min-width: 28px;
  padding: 0 6px;
  font-size: 0.75rem;
}

.about-credit {
  margin-top: 22px;
  text-align: center;
  font-size: 0.85rem;
  color: var(--text-3);
  max-width: 640px;
  margin-left: auto;
  margin-right: auto;
  line-height: 1.6;
}

.footer-brand {
  font-weight: 600;
  color: var(--text-2);
}

.footer-sub {
  opacity: 0.9;
}

.footer-sub a {
  color: var(--accent);
  font-weight: 600;
}

.banana-head h2 {
  font-family: var(--display);
  font-size: clamp(1.5rem, 3vw, 2rem);
  font-weight: 400;
  letter-spacing: 0.02em;
  margin-bottom: 8px;
}

.banana-desc {
  color: var(--text-2);
  font-size: 0.92rem;
  max-width: 640px;
  line-height: 1.6;
}

.banana-desc a {
  color: var(--accent);
  font-weight: 600;
  text-decoration: underline;
  text-underline-offset: 3px;
}

.banana-stat-badge {
  text-align: center;
  min-width: 110px;
  padding: 14px 18px;
  border-radius: 18px;
  background: linear-gradient(145deg, #fde68a, #fbbf24 40%, #f472b6);
  color: #1c1008;
  box-shadow: 0 10px 28px rgba(251, 191, 36, 0.35);
}

.banana-stat-badge strong {
  display: block;
  font-size: 1.75rem;
  font-weight: 800;
  letter-spacing: -0.02em;
  line-height: 1.1;
}

.banana-stat-badge span {
  font-size: 0.78rem;
  font-weight: 600;
  opacity: 0.85;
}

.banana-controls {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin-bottom: 12px;
}

.bn-search {
  flex: 1 1 240px;
}

.bn-mode-group {
  display: inline-flex;
  padding: 4px;
  border-radius: 999px;
  border: 1px solid var(--border);
  background: var(--surface);
  gap: 2px;
}

.bn-mode-btn {
  border: none;
  background: transparent;
  color: var(--text-2);
  padding: 8px 14px;
  border-radius: 999px;
  font-size: 0.88rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s var(--ease);
}

.bn-mode-btn.active {
  background: linear-gradient(135deg, #ec4899, #c026d3);
  color: #fff;
  box-shadow: 0 4px 12px rgba(192, 38, 211, 0.28);
}

.bn-count-line {
  color: var(--text-3);
  font-size: 0.88rem;
  margin-bottom: 12px;
}

.bn-count-line strong {
  color: var(--text);
}

.bn-table-wrap {
  border-radius: 18px;
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: var(--shadow-md);
  overflow: auto;
  max-height: min(70vh, 820px);
}

.bn-table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  min-width: 860px;
}

.bn-table thead th {
  position: sticky;
  top: 0;
  z-index: 2;
  background: color-mix(in srgb, var(--surface-2) 92%, var(--pink));
  backdrop-filter: blur(8px);
  text-align: left;
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--text-2);
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  white-space: nowrap;
}

.bn-table tbody tr {
  cursor: pointer;
  transition: background 0.15s;
}

.bn-table tbody tr:hover {
  background: var(--accent-soft);
}

.bn-table tbody tr:nth-child(even) {
  background: color-mix(in srgb, var(--surface-2) 55%, transparent);
}

.bn-table tbody tr:nth-child(even):hover {
  background: var(--accent-soft);
}

.bn-table td {
  padding: 12px 14px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
  font-size: 0.9rem;
}

.col-no {
  width: 48px;
  color: var(--text-3);
  font-variant-numeric: tabular-nums;
  font-size: 0.82rem !important;
}

.col-thumb {
  width: 88px;
}

.bn-thumb {
  width: 72px;
  height: 54px;
  object-fit: cover;
  border-radius: 10px;
  border: 1px solid var(--border);
  display: block;
  background: var(--surface-2);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.bn-thumb-fallback {
  display: grid;
  place-items: center;
  font-size: 1.4rem;
  background: linear-gradient(135deg, #fde68a, #f9a8d4);
}

.bn-title {
  font-weight: 700;
  letter-spacing: -0.01em;
  margin-bottom: 4px;
  color: var(--text);
}

.bn-sub {
  font-size: 0.8rem;
  color: var(--text-3);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  max-width: 360px;
  line-height: 1.4;
}

.bn-pill {
  display: inline-flex;
  align-items: center;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 650;
  background: var(--accent-soft);
  color: var(--accent);
  margin: 2px 4px 2px 0;
  white-space: nowrap;
}

.bn-pill.soft {
  background: var(--surface-2);
  color: var(--text-2);
}

.bn-mode {
  display: inline-flex;
  padding: 4px 10px;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
}

.bn-mode.mode-gen {
  background: rgba(34, 197, 94, 0.14);
  color: #16a34a;
}

.bn-mode.mode-edit {
  background: rgba(59, 130, 246, 0.14);
  color: #2563eb;
}

[data-theme="dark"] .bn-mode.mode-gen {
  color: #4ade80;
}

[data-theme="dark"] .bn-mode.mode-edit {
  color: #60a5fa;
}

.col-author {
  color: var(--text-2);
  font-size: 0.85rem !important;
  white-space: nowrap;
}

.col-actions {
  white-space: nowrap;
}

.bn-act {
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text-2);
  border-radius: 999px;
  padding: 6px 12px;
  font-size: 0.78rem;
  font-weight: 650;
  cursor: pointer;
  margin-right: 4px;
  transition: all 0.15s;
}

.bn-act:hover {
  border-color: transparent;
  background: var(--accent-soft);
  color: var(--accent);
}

.bn-act.primary {
  background: linear-gradient(135deg, #ec4899, #8b5cf6);
  border-color: transparent;
  color: #fff;
}

.bn-act.primary:hover {
  filter: brightness(1.06);
  color: #fff;
}

.bn-empty {
  padding: 40px;
  text-align: center;
  color: var(--text-2);
}

.bn-pager {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 14px;
  margin-top: 16px;
}

.bn-page-btn {
  border: 1px solid var(--border);
  background: var(--surface);
  color: var(--text);
  border-radius: 999px;
  padding: 8px 16px;
  font-weight: 600;
  font-size: 0.88rem;
  cursor: pointer;
}

.bn-page-btn:disabled {
  opacity: 0.4;
  cursor: not-allowed;
}

.bn-page-btn:not(:disabled):hover {
  background: var(--accent-soft);
  color: var(--accent);
}

.bn-page-info {
  font-size: 0.88rem;
  color: var(--text-2);
  font-variant-numeric: tabular-nums;
}

/* mobile cards for banana */
.bn-cards {
  display: none;
  grid-template-columns: 1fr;
  gap: 14px;
  margin-top: 4px;
}

.bn-card {
  display: grid;
  grid-template-columns: 120px 1fr;
  gap: 0;
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--border);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  cursor: pointer;
}

.bn-card-media {
  position: relative;
  min-height: 120px;
  background: var(--surface-2);
}

.bn-card-media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  position: absolute;
  inset: 0;
}

.bn-card-ph {
  display: grid;
  place-items: center;
  height: 100%;
  font-size: 2rem;
  background: linear-gradient(135deg, #fde68a, #f9a8d4);
}

.bn-card-media .bn-mode {
  position: absolute;
  top: 8px;
  left: 8px;
  background: rgba(0, 0, 0, 0.5);
  color: #fff;
}

.bn-card-body {
  padding: 12px 14px;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.bn-card-body h3 {
  font-size: 0.98rem;
  font-weight: 700;
}

.bn-card-body p {
  font-size: 0.8rem;
  color: var(--text-3);
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  flex: 1;
}

.bn-card-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.bn-author {
  font-size: 0.75rem;
  color: var(--text-3);
}

.bn-card-acts {
  display: flex;
  gap: 6px;
  margin-top: 4px;
}

/* banana detail modal */
.bn-modal {
  width: min(820px, 100%);
}

.bn-modal-visual {
  position: relative;
  min-height: 180px;
  max-height: 320px;
  background: linear-gradient(135deg, #312e81, #db2777);
  overflow: hidden;
}

.bn-modal-visual img {
  width: 100%;
  height: 100%;
  max-height: 320px;
  object-fit: contain;
  background: #0b0b12;
  display: block;
}

.bn-modal-refs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  margin-bottom: 12px;
}

.bn-ref-label {
  font-size: 0.8rem;
  color: var(--text-3);
  margin-right: 4px;
}

.bn-ref-thumb img {
  width: 64px;
  height: 48px;
  object-fit: cover;
  border-radius: 8px;
  border: 1px solid var(--border);
}

.bn-modal-backdrop {
  z-index: 220;
}

@media (max-width: 800px) {
  .bn-table-wrap {
    display: none;
  }

  .bn-cards {
    display: grid;
  }
}

@media (max-width: 560px) {
  .stats {
    gap: 12px;
  }

  .stat strong {
    font-size: 1.15rem;
  }

  .header-github-text {
    display: none;
  }

  .header-nav {
    display: none;
  }

  .logo-text small {
    display: none;
  }

  .deco-float {
    display: none;
  }

  .hero {
    padding-top: 34px;
  }

  .controls {
    margin-inline: -6px;
    padding-inline: 6px;
  }

  .search-bar {
    flex-basis: 100%;
  }

  .modal-backdrop {
    align-items: flex-end;
    padding: 0;
  }

  .modal {
    max-height: 92dvh;
    border-radius: 22px 22px 0 0;
  }

  .modal-cover {
    height: 112px;
  }

  .modal-body {
    padding: 18px 16px calc(20px + env(safe-area-inset-bottom));
  }

  .hero-actions .btn-ghost {
    width: 100%;
  }

  .bn-card {
    grid-template-columns: 100px 1fr;
  }

  .banana-stat-badge {
    width: 100%;
  }
}
