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

:root {
  --bg:        #050505;
  --sidebar:   #0d0d0d;
  --card:      #0f0f0f;
  --card2:     #171717;
  --border:    #1f1f1f;
  --border2:   #2c2c2c;
  --text:      #f2f2f2;
  --muted:     #8a8a8a;
  --dim:       #565656;
  --tag-bg:    #141414;
  --tag-text:  #a8a8a8;
  --accent:    #ffffff;
  --silver:    linear-gradient(180deg, #d6d6d6 0%, #8c8c8c 55%, #5e5e5e 100%);
  --glow:      0 0 0 1px rgba(255,255,255,.06), 0 0 28px rgba(255,255,255,.07);
  --glow-strong: 0 0 0 1px rgba(255,255,255,.10), 0 0 36px rgba(255,255,255,.12), 0 20px 40px -20px rgba(0,0,0,.9);
  --green:     #3ddc97;
  --ease-out:  cubic-bezier(.22,1,.36,1);
  --radius:    12px;
  --radius-lg: 18px;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif;
  background: var(--bg);
  color: var(--text);
  display: flex;
  min-height: 100vh;
  font-size: 14px;
  line-height: 1.5;
}

/* ── Sidebar ── */
.sidebar {
  width: 220px;
  min-width: 220px;
  background: var(--sidebar);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  padding: 20px 12px;
  position: sticky;
  top: 0;
  height: 100vh;
  overflow-y: auto;
}

.sidebar-brand {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 4px 8px 20px;
}

.brand-icon {
  width: 34px;
  height: 34px;
  background: var(--card2);
  border: 1px solid var(--border2);
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.brand-icon svg { opacity: .8; }

.brand-text { line-height: 1.2; }
.brand-text strong { font-size: 13px; font-weight: 600; display: block; }
.brand-text span { font-size: 11px; color: var(--muted); }

nav { flex: 1; display: flex; flex-direction: column; gap: 2px; }

.nav-item {
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 8px 10px;
  border-radius: 8px;
  color: var(--muted);
  text-decoration: none;
  font-size: 13.5px;
  transition: background .15s, color .15s;
}

.nav-item:hover { background: var(--card); color: var(--text); }
.nav-item.active { background: var(--card2); color: var(--text); }
.nav-item svg { flex-shrink: 0; opacity: .7; }
.nav-item.active svg { opacity: 1; }

.sidebar-footer {
  margin-top: auto;
  padding-top: 20px;
  border-top: 1px solid var(--border);
}

.sync-dot {
  width: 7px; height: 7px;
  background: var(--green);
  border-radius: 50%;
  display: inline-block;
  margin-right: 5px;
}

.sidebar-footer small { font-size: 11px; color: var(--dim); display: block; margin-top: 2px; }
.sidebar-footer strong { font-size: 22px; font-weight: 700; display: block; margin: 4px 0; }
.sidebar-footer a { color: var(--dim); font-size: 11px; text-decoration: underline; }

/* ── Main ── */
.main { flex: 1; min-width: 0; padding: 32px 36px; }

/* ── Page header ── */
.page-label {
  font-size: 11px;
  color: var(--muted);
  letter-spacing: .06em;
  text-transform: uppercase;
  margin-bottom: 6px;
  display: flex;
  align-items: center;
  gap: 6px;
}

h1 { font-size: 36px; font-weight: 700; letter-spacing: -.01em; margin-bottom: 24px; }

/* ── Featured card ── */
.featured-wrap {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 20px;
  margin-bottom: 40px;
}

.featured-card {
  background: linear-gradient(135deg, #1a1a1e 0%, #111113 100%);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 36px 40px;
  position: relative;
  overflow: hidden;
}

.featured-card::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse at 80% 50%, rgba(80,80,120,.08) 0%, transparent 60%);
  pointer-events: none;
}

.featured-badge {
  font-size: 11px;
  color: var(--muted);
  letter-spacing: .07em;
  text-transform: uppercase;
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 14px;
}

.featured-badge::before { content: '✦'; font-size: 10px; }

.featured-card h2 { font-size: 42px; font-weight: 800; letter-spacing: -.02em; margin-bottom: 14px; }
.featured-card p { color: var(--muted); max-width: 480px; font-size: 14px; margin-bottom: 24px; }

.featured-tags { display: flex; flex-wrap: wrap; gap: 7px; margin-bottom: 28px; }

.featured-actions { display: flex; gap: 10px; }

.btn {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 9px 18px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 500;
  cursor: pointer;
  transition: opacity .15s, background .15s;
  text-decoration: none;
  border: none;
}

.btn-primary { background: #fff; color: #000; }
.btn-primary:hover { opacity: .88; }
.btn-outline { background: transparent; color: var(--text); border: 1px solid var(--border2); }
.btn-outline:hover { background: var(--card2); }

.featured-preview {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 14px;
}

.preview-plugin-row {
  display: flex;
  align-items: center;
  gap: 12px;
}

.preview-plugin-row strong { font-size: 15px; font-weight: 600; }
.preview-plugin-row span { font-size: 12px; color: var(--muted); }

.preview-art {
  flex: 1;
  height: 100px;
  background: var(--card2);
  border-radius: 8px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  overflow: hidden;
  gap: 2px;
  padding: 8px 12px 0;
}

.preview-bar {
  width: 7px;
  background: linear-gradient(to top, #555, #333);
  border-radius: 2px 2px 0 0;
}

.preview-meta {
  display: flex;
  justify-content: space-between;
  font-size: 11.5px;
  color: var(--dim);
}

/* ── Stats ── */
.stats-row {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
  margin-bottom: 44px;
}

.stat-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px 22px;
}

.stat-card strong { font-size: 30px; font-weight: 700; display: block; }
.stat-card span { font-size: 11px; color: var(--muted); letter-spacing: .05em; text-transform: uppercase; margin-top: 2px; display: block; }

/* ── Section header ── */
.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}

.section-header h2 { font-size: 20px; font-weight: 600; }
.section-header a { font-size: 13px; color: var(--muted); text-decoration: none; display: flex; align-items: center; gap: 4px; }
.section-header a:hover { color: var(--text); }

/* ── Plugin grid ── */
.plugin-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.plugin-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 18px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  text-decoration: none;
  color: inherit;
  transition: border-color .15s, background .15s;
  position: relative;
}

.plugin-card:hover { border-color: var(--border2); background: var(--card2); }

.card-top { display: flex; align-items: flex-start; justify-content: space-between; }

.plugin-icon {
  width: 40px; height: 40px;
  background: var(--card2);
  border: 1px solid var(--border2);
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.fav-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--dim);
  padding: 2px;
  transition: color .15s;
  line-height: 1;
}
.fav-btn:hover { color: #d44; }
.fav-btn.active { color: #d44; }

.plugin-name { font-size: 15px; font-weight: 600; }
.plugin-dev { font-size: 12px; color: var(--muted); margin-top: 1px; }
.plugin-desc { font-size: 12.5px; color: var(--muted); line-height: 1.55; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }

.card-tags { display: flex; flex-wrap: wrap; gap: 5px; }

.tag {
  background: var(--tag-bg);
  color: var(--tag-text);
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 999px;
  display: inline-block;
}

.card-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: auto;
  padding-top: 4px;
}

.card-version { font-size: 11.5px; color: var(--dim); }

.card-open {
  font-size: 12px;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 4px;
  text-decoration: none;
  transition: color .15s;
}

.card-open:hover { color: var(--text); }

/* ── Browse toolbar ── */
.browse-toolbar {
  display: flex;
  align-items: center;
  gap: 10px;
  margin-bottom: 20px;
}

.search-wrap {
  position: relative;
  flex: 1;
}

.search-wrap svg {
  position: absolute;
  left: 12px;
  top: 50%;
  transform: translateY(-50%);
  color: var(--dim);
  pointer-events: none;
}

.search-input {
  width: 100%;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 9px 14px 9px 36px;
  font-size: 13.5px;
  color: var(--text);
  outline: none;
  transition: border-color .15s;
}

.search-input::placeholder { color: var(--dim); }
.search-input:focus { border-color: var(--border2); }

.select-wrap select {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 9px 32px 9px 12px;
  font-size: 13px;
  color: var(--text);
  appearance: none;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%23666' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E");
  background-repeat: no-repeat;
  background-position: right 10px center;
  cursor: pointer;
  outline: none;
}

.view-toggle {
  display: flex;
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 8px;
  overflow: hidden;
}

.view-btn {
  background: none;
  border: none;
  padding: 8px 10px;
  cursor: pointer;
  color: var(--dim);
  transition: background .15s, color .15s;
  display: flex;
  align-items: center;
}

.view-btn.active, .view-btn:hover { background: var(--card2); color: var(--text); }

.results-count { font-size: 13px; color: var(--muted); margin-bottom: 16px; }

/* ── Categories ── */
.cat-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}

.cat-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 22px 20px;
  text-decoration: none;
  color: inherit;
  transition: border-color .15s, background .15s;
  display: block;
}

.cat-card:hover { border-color: var(--border2); background: var(--card2); }

.cat-header { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; }

.cat-icon {
  width: 42px; height: 42px;
  background: var(--card2);
  border: 1px solid var(--border2);
  border-radius: 9px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.cat-header strong { font-size: 16px; font-weight: 600; display: block; }
.cat-header span { font-size: 12px; color: var(--muted); }

.cat-plugins { display: flex; flex-direction: column; gap: 4px; }

.cat-plugin-row {
  display: flex;
  justify-content: space-between;
  font-size: 12px;
}

.cat-plugin-row span:first-child { color: var(--muted); }
.cat-plugin-row span:last-child { color: var(--dim); }

/* ── Plugin detail ── */
.plugin-detail-hero {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 32px 36px;
  margin-bottom: 24px;
}

.plugin-detail-top {
  display: flex;
  align-items: flex-start;
  gap: 20px;
  margin-bottom: 24px;
}

.plugin-detail-icon {
  width: 72px; height: 72px;
  background: var(--card2);
  border: 1px solid var(--border2);
  border-radius: 14px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.plugin-detail-meta { flex: 1; }

.detail-breadcrumb {
  font-size: 12px;
  color: var(--muted);
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
}

.detail-breadcrumb a { color: var(--muted); text-decoration: none; }
.detail-breadcrumb a:hover { color: var(--text); }

.plugin-detail-meta h1 { font-size: 30px; margin-bottom: 8px; }
.plugin-detail-meta p { color: var(--muted); font-size: 14px; }

.plugin-detail-actions { display: flex; gap: 10px; }

.detail-body {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 24px;
}

.detail-main { display: flex; flex-direction: column; gap: 24px; }

.detail-section {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 24px 28px;
}

.detail-section h3 { font-size: 13px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); margin-bottom: 16px; }

.feature-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 10px;
}

.feature-item {
  display: flex;
  align-items: center;
  gap: 9px;
  font-size: 13px;
  color: var(--muted);
}

.feature-check {
  width: 20px; height: 20px;
  background: rgba(61,220,151,.12);
  border: 1px solid rgba(61,220,151,.25);
  border-radius: 5px;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--green);
}

.screenshots-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 12px;
}

.screenshot-placeholder {
  background: var(--card2);
  border: 1px solid var(--border2);
  border-radius: 8px;
  aspect-ratio: 16/9;
  display: flex;
  align-items: flex-end;
  overflow: hidden;
  position: relative;
}

.screenshot-label {
  position: absolute;
  top: 10px;
  left: 10px;
  display: flex;
  gap: 4px;
}

.dot { width: 8px; height: 8px; border-radius: 50%; background: var(--border2); }
.dot.r { background: #e55; } .dot.y { background: #da5; } .dot.g { background: var(--green); }

.ss-caption {
  position: absolute;
  bottom: 10px;
  left: 12px;
  font-size: 11px;
  color: var(--dim);
}

.ss-art {
  width: 100%; height: 100%;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: 3px;
  padding: 20px 20px 32px;
}

.ss-bar { background: rgba(255,255,255,.07); border-radius: 2px 2px 0 0; flex: 1; }

.knob-row {
  display: flex;
  justify-content: space-evenly;
  position: absolute;
  bottom: 22px;
  left: 0; right: 0;
  gap: 8px;
  padding: 0 20px;
}

.knob-wrap { display: flex; flex-direction: column; align-items: center; gap: 3px; }

.knob {
  width: 28px; height: 28px;
  background: var(--card);
  border: 1px solid var(--border2);
  border-radius: 50%;
}

.knob-label { font-size: 9px; color: var(--dim); letter-spacing: .04em; text-transform: uppercase; }

.faq-list { display: flex; flex-direction: column; gap: 0; }

.faq-item { padding: 14px 0; border-bottom: 1px solid var(--border); }
.faq-item:last-child { border-bottom: none; }
.faq-item strong { font-size: 13.5px; display: block; margin-bottom: 5px; }
.faq-item p { font-size: 13px; color: var(--muted); }

.changelog-list { display: flex; flex-direction: column; gap: 0; }

.changelog-item {
  display: flex;
  gap: 16px;
  padding: 12px 0;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}

.changelog-item:last-child { border-bottom: none; }

.changelog-ver {
  color: var(--muted);
  min-width: 55px;
  font-variant-numeric: tabular-nums;
}

.changelog-date { color: var(--dim); min-width: 90px; }
.changelog-note { color: var(--text); }

/* Detail sidebar */
.detail-sidebar { display: flex; flex-direction: column; gap: 14px; }

.detail-sidebar-card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 20px;
}

.detail-sidebar-card h3 { font-size: 13px; font-weight: 600; letter-spacing: .04em; text-transform: uppercase; color: var(--muted); margin-bottom: 14px; }

.detail-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 7px 0;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}

.detail-row:last-child { border-bottom: none; }
.detail-row span:first-child { color: var(--muted); }

.compat-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 7px 0;
  border-bottom: 1px solid var(--border);
  font-size: 13px;
}

.compat-item:last-child { border-bottom: none; }
.compat-item span:first-child { color: var(--muted); }

.compat-check { color: var(--green); font-size: 15px; }

/* Related plugins */
.related-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 12px;
  margin-top: 16px;
}

/* Favorites empty */
.empty-state {
  text-align: center;
  padding: 80px 20px;
  color: var(--muted);
}

.empty-state svg { opacity: .2; margin-bottom: 16px; }
.empty-state h2 { font-size: 20px; font-weight: 600; color: var(--text); margin-bottom: 8px; }
.empty-state p { font-size: 14px; }

/* Install steps */
.install-steps { display: flex; flex-direction: column; gap: 12px; }

.install-step {
  display: flex;
  gap: 14px;
  font-size: 13px;
  color: var(--muted);
}

.step-num {
  width: 22px; height: 22px;
  background: var(--card2);
  border: 1px solid var(--border2);
  border-radius: 50%;
  font-size: 11px;
  font-weight: 600;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  color: var(--text);
}

/* Toast / notif */
.notif-row {
  background: var(--card2);
  border: 1px solid var(--border2);
  border-radius: 8px;
  padding: 12px 16px;
  font-size: 13px;
  color: var(--muted);
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.notif-dot { width: 7px; height: 7px; border-radius: 50%; background: var(--green); flex-shrink: 0; }

/* Utilities */
.mt-32 { margin-top: 32px; }
.text-muted { color: var(--muted); }
.text-dim { color: var(--dim); }


/* ════════════════════════════════════════════
   Enhancements — monochrome glass, glow & motion
   ════════════════════════════════════════════ */

body {
  background:
    radial-gradient(1000px 600px at 70% -20%, rgba(255,255,255,.045), transparent 60%),
    var(--bg);
  background-attachment: fixed;
  -webkit-font-smoothing: antialiased;
}

h1, h2, .stat-card strong, .sidebar-footer strong, .brand-text strong, .plugin-name {
  font-family: 'Space Grotesk', 'Inter', system-ui, sans-serif;
}
h1 { font-size: 44px; letter-spacing: -.025em; }

::selection { background: rgba(255,255,255,.2); }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: #1e1e1e; border-radius: 999px; border: 3px solid var(--bg); }
::-webkit-scrollbar-thumb:hover { background: #2e2e2e; }

/* shared glass surface */
.featured-card, .featured-preview, .stat-card, .plugin-card, .cat-card,
.plugin-detail-hero, .detail-section, .detail-sidebar-card, .browse-toolbar, .sidebar {
  background: linear-gradient(180deg, #111 0%, #0a0a0a 100%);
  border: 1px solid var(--border);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.04);
}

/* ── Sidebar: floating panel ── */
.sidebar {
  margin: 12px 0 12px 12px;
  height: calc(100vh - 24px);
  top: 12px;
  border-radius: 22px;
  padding: 18px 12px;
}
.brand-icon {
  border-radius: 50%;
  background: radial-gradient(circle at 35% 30%, #e6e6e6, #6a6a6a 70%, #3a3a3a);
  border: none;
  box-shadow: 0 0 18px rgba(255,255,255,.15);
}
.brand-icon svg { opacity: 1; animation: spinSlow 16s linear infinite; }
.brand-icon svg path { stroke: #111; }

.nav-item {
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 9px 12px;
  transition: background .2s, color .2s, border-color .2s, box-shadow .25s, transform .2s var(--ease-out);
}
.nav-item:hover { background: #121212; color: var(--text); transform: translateX(2px); }
.nav-item.active {
  background: linear-gradient(180deg, #1f1f1f, #151515);
  border-color: #2c2c2c;
  color: #fff;
  font-weight: 500;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.06), 0 0 20px rgba(255,255,255,.05);
}

.sidebar-footer {
  background: linear-gradient(180deg, #131313, #0c0c0c);
  border: 1px solid var(--border);
  border-radius: 16px;
  padding: 16px;
}
.sidebar-footer strong { font-size: 24px; }
.sync-dot { background: #bbb; animation: pulseDot 2.2s infinite; }

/* ── Featured hero ── */
.featured-card, .featured-preview { border-radius: 24px; }
.featured-card {
  background:
    radial-gradient(500px 260px at 15% 0%, rgba(255,255,255,.05), transparent 60%),
    linear-gradient(180deg, #121212 0%, #090909 100%);
}
.featured-card::before {
  background: linear-gradient(115deg, transparent 35%, rgba(255,255,255,.03) 47%, transparent 60%);
  background-size: 250% 100%;
  animation: sheen 8s ease-in-out infinite;
}
.featured-badge {
  display: inline-flex;
  padding: 4px 11px;
  border: 1px solid var(--border2);
  background: #141414;
  border-radius: 999px;
}
.featured-badge::before { animation: twinkle 2.4s ease-in-out infinite; }
.featured-card h2 {
  font-family: 'Space Grotesk', 'Inter', sans-serif;
  font-size: 58px;
  letter-spacing: -.03em;
  background: linear-gradient(180deg, #fff 20%, #9a9a9a 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}
.featured-card p { font-size: 15px; }

/* ── Buttons: pills ── */
.btn {
  border-radius: 999px;
  padding: 10px 20px;
  transition: transform .2s var(--ease-out), box-shadow .25s, background .2s, border-color .2s, filter .2s;
}
.btn:active { transform: scale(.97); }
.btn-primary {
  background: var(--silver);
  color: #fff;
  font-weight: 600;
  text-shadow: 0 1px 2px rgba(0,0,0,.35);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.45), 0 0 24px rgba(255,255,255,.12);
}
.btn-primary:hover { opacity: 1; filter: brightness(1.12); transform: translateY(-2px); box-shadow: inset 0 1px 0 rgba(255,255,255,.5), 0 0 38px rgba(255,255,255,.25); }
.btn-outline { background: #0e0e0e; border-color: var(--border2); }
.btn-outline:hover { background: #171717; border-color: #444; transform: translateY(-2px); box-shadow: 0 0 24px rgba(255,255,255,.08); }

/* ── Visualizer ── */
.preview-art {
  position: relative;
  min-height: 160px;
  padding: 0;
  border-radius: 14px;
  background: radial-gradient(ellipse at 50% 100%, rgba(255,255,255,.05), transparent 70%), #0a0a0a;
}
.viz { display: block; width: 100%; height: 100%; position: absolute; inset: 0; }
.ss-art { position: relative; padding: 0; }
.preview-meta { font-family: ui-monospace, 'JetBrains Mono', Consolas, monospace; font-size: 11px; }

/* ── Round, glossy icons ── */
.plugin-icon, .cat-icon, .plugin-detail-icon {
  border-radius: 50% !important;
  background: radial-gradient(circle at 35% 25%, #2a2a2a, #121212 70%);
  border: 1px solid #2a2a2a;
  color: #e6e6e6 !important;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.08), 0 4px 14px rgba(0,0,0,.6);
  transition: transform .3s var(--ease-out), box-shadow .3s, border-color .3s;
}
.plugin-detail-icon { border-radius: 22px !important; }

/* ── Tags ── */
.tag { background: transparent; border: 1px solid var(--border2); color: var(--muted); padding: 2px 9px; transition: border-color .2s, color .2s; }
.card-tags .tag:first-child, .featured-tags .tag { background: #222; border-color: #333; color: #f0f0f0; font-weight: 600; }

/* ── Cards: glass + glow on hover ── */
.plugin-card, .cat-card, .stat-card {
  position: relative;
  overflow: hidden;
  border-radius: 20px;
  transition: transform .3s var(--ease-out), border-color .3s, box-shadow .35s, background .3s;
}
.plugin-card { padding: 20px; }
.plugin-card::before, .cat-card::before, .stat-card::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(280px circle at var(--mx, 50%) var(--my, 0%), rgba(255,255,255,.07), transparent 65%);
  opacity: 0;
  transition: opacity .3s;
  pointer-events: none;
}
.plugin-card:hover, .cat-card:hover, .stat-card:hover {
  transform: translateY(-3px);
  border-color: #3c3c3c;
  box-shadow: var(--glow-strong);
}
.plugin-card:hover::before, .cat-card:hover::before, .stat-card:hover::before { opacity: 1; }
.plugin-card:hover .plugin-icon, .cat-card:hover .cat-icon {
  transform: scale(1.07);
  border-color: #444;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.12), 0 0 18px rgba(255,255,255,.14);
}

.card-footer { border-top: 1px solid var(--border); padding-top: 14px; margin-top: auto; }
.card-version { font-family: ui-monospace, 'JetBrains Mono', Consolas, monospace; font-size: 11px; }
.card-open { color: #eee; font-weight: 500; transition: color .2s, transform .2s var(--ease-out); }
.plugin-card:hover .card-open { color: #fff; transform: translate(2px,-1px); }

.fav-btn {
  width: 30px; height: 30px;
  border-radius: 50%;
  border: 1px solid var(--border2);
  background: #0e0e0e;
  display: flex; align-items: center; justify-content: center;
  color: #bbb;
  position: relative; z-index: 1;
  transition: color .2s, transform .2s var(--ease-out), border-color .2s, box-shadow .2s;
}
.fav-btn:hover { color: #fff; border-color: #555; box-shadow: 0 0 14px rgba(255,255,255,.15); transform: scale(1.08); }
.fav-btn.active { color: #fff; border-color: #666; }
.fav-btn.active svg path { fill: currentColor; }
.fav-btn.pop { animation: heartPop .45s var(--ease-out); }

/* ── Stats ── */
.stat-card strong { font-size: 32px; }

/* ── Browse toolbar: one glass panel ── */
.browse-toolbar { padding: 12px; border-radius: 22px; }
.search-input, .select-wrap select, .view-toggle {
  background: #0c0c0c;
  border: 1px solid var(--border2);
  transition: border-color .2s, box-shadow .2s;
}
.search-input { border-radius: 999px; padding: 11px 16px 11px 40px; }
.search-wrap svg { left: 15px; }
.select-wrap select { border-radius: 12px; padding: 10px 34px 10px 14px; }
.view-toggle { border-radius: 12px; padding: 3px; gap: 2px; }
.view-btn { border-radius: 9px; }
.view-btn.active { background: #222; box-shadow: inset 0 1px 0 rgba(255,255,255,.08); }
.search-input:focus, .select-wrap select:focus, .search-input:hover, .select-wrap select:hover {
  border-color: #444;
  box-shadow: 0 0 0 3px rgba(255,255,255,.05), 0 0 20px rgba(255,255,255,.06);
}

/* ── Detail page ── */
.plugin-detail-hero, .detail-section, .detail-sidebar-card { border-radius: 22px; transition: border-color .25s, box-shadow .3s; }
.detail-section:hover, .detail-sidebar-card:hover { border-color: var(--border2); box-shadow: var(--glow); }
.step-num { background: var(--silver); border: none; color: #fff; }
.screenshot-placeholder { border-radius: 14px; background: #0a0a0a; }
.knob { background: radial-gradient(circle at 35% 30%, #2c2c2c, #101010); position: relative; }
.knob::after {
  content: '';
  position: absolute;
  left: 50%; top: 3px;
  width: 2px; height: 8px;
  margin-left: -1px;
  border-radius: 2px;
  background: #eee;
  box-shadow: 0 0 6px rgba(255,255,255,.6);
  transform-origin: 50% 11px;
  animation: knobTurn 5s ease-in-out infinite alternate;
}
.knob-wrap:nth-child(2) .knob::after { animation-delay: -1.3s; }
.knob-wrap:nth-child(3) .knob::after { animation-delay: -2.6s; }
.knob-wrap:nth-child(4) .knob::after { animation-delay: -3.9s; }

/* ── Entrance animations (class added by app.js, so no-JS still shows content) ── */
.reveal { opacity: 0; transform: translateY(14px); filter: blur(4px); }
.reveal.in { animation: rise .7s var(--ease-out) forwards; animation-delay: var(--d, 0ms); }

@keyframes rise      { to { opacity: 1; transform: none; filter: none; } }
@keyframes sheen     { 0%,100% { background-position: 120% 0; } 50% { background-position: -20% 0; } }
@keyframes pulseDot  { 0% { box-shadow: 0 0 0 0 rgba(255,255,255,.45); } 70% { box-shadow: 0 0 0 7px rgba(255,255,255,0); } 100% { box-shadow: 0 0 0 0 rgba(255,255,255,0); } }
@keyframes twinkle   { 0%,100% { opacity: .45; } 50% { opacity: 1; } }
@keyframes spinSlow  { to { transform: rotate(360deg); } }
@keyframes heartPop  { 0% { transform: scale(1); } 40% { transform: scale(1.35); } 100% { transform: scale(1); } }
@keyframes knobTurn  { from { transform: rotate(-130deg); } to { transform: rotate(130deg); } }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { animation: none !important; transition: none !important; }
  .reveal { opacity: 1; transform: none; filter: none; }
}

/* ── Home: popular / updates / category tiles ── */
.mt-44 { margin-top: 44px; }
.section-hint { font-size: 12.5px; color: var(--muted); display: inline-flex; align-items: center; gap: 6px; }

.plugin-icon { position: relative; }
.icon-badge {
  position: absolute;
  right: -3px; bottom: -3px;
  font-size: 8.5px;
  font-weight: 700;
  letter-spacing: .02em;
  color: #ddd;
  background: #0b0b0b;
  border-radius: 6px;
  padding: 0 3px;
  line-height: 13px;
}

.popular-grid { grid-template-columns: repeat(4, 1fr); }
.card-ident { display: flex; align-items: center; gap: 12px; min-width: 0; }
.card-ident .plugin-icon { width: 44px; height: 44px; }

.update-list {
  background: linear-gradient(180deg, #101010, #0a0a0a);
  border: 1px solid var(--border);
  border-radius: 22px;
  padding: 10px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,.04);
}
.update-row {
  position: relative;
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 10px 14px 10px 36px;
  border-radius: 14px;
  color: inherit;
  text-decoration: none;
  border: 1px solid transparent;
  transition: background .25s, border-color .25s, box-shadow .3s, transform .25s var(--ease-out);
}
.update-row::before {             /* timeline line */
  content: '';
  position: absolute;
  left: 18px; top: 0; bottom: 0;
  width: 1px;
  background: linear-gradient(180deg, transparent, #2a2a2a 30%, #2a2a2a 70%, transparent);
}
.update-row:first-child::before { top: 50%; }
.update-row:last-child::before  { bottom: 50%; }
.update-dot {
  position: absolute;
  left: 14px; top: 50%;
  width: 9px; height: 9px;
  margin-top: -4.5px;
  border-radius: 50%;
  background: #1c1c1c;
  border: 1px solid #333;
  transition: background .25s, box-shadow .25s;
}
.update-row .plugin-icon { width: 40px; height: 40px; }
.update-info { flex: 1; min-width: 0; }
.update-title { display: flex; align-items: center; gap: 8px; }
.update-title strong { font-size: 14px; font-weight: 600; }
.ver-chip {
  font-family: ui-monospace, 'JetBrains Mono', Consolas, monospace;
  font-size: 10px;
  color: var(--muted);
  background: #161616;
  border: 1px solid var(--border2);
  border-radius: 6px;
  padding: 0 6px;
  line-height: 17px;
}
.update-meta { font-size: 12.5px; color: var(--muted); }
.update-arrow { color: var(--dim); transition: color .2s, transform .25s var(--ease-out); }
.update-row:hover {
  background: #141414;
  border-color: #2c2c2c;
  box-shadow: 0 0 24px rgba(255,255,255,.05);
}
.update-row:hover .update-dot { background: #eee; box-shadow: 0 0 10px rgba(255,255,255,.7); }
.update-row:hover .update-arrow { color: #fff; transform: translateX(3px); }
.update-row:hover .plugin-icon { border-color: #444; box-shadow: inset 0 1px 0 rgba(255,255,255,.12), 0 0 16px rgba(255,255,255,.12); }

.cat-tiles {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
  gap: 12px;
}
.cat-tile {
  position: relative;
  overflow: hidden;
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 16px;
  min-height: 78px;
  border-radius: 18px;
  background: linear-gradient(180deg, #111 0%, #0a0a0a 100%);
  border: 1px solid var(--border);
  box-shadow: inset 0 1px 0 rgba(255,255,255,.04);
  color: inherit;
  text-decoration: none;
  transition: transform .3s var(--ease-out), border-color .3s, box-shadow .35s;
}
.cat-tile::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(200px circle at var(--mx, 50%) var(--my, 0%), rgba(255,255,255,.07), transparent 65%);
  opacity: 0;
  transition: opacity .3s;
  pointer-events: none;
}
.cat-tile .plugin-icon { width: 40px; height: 40px; flex-shrink: 0; }
.cat-tile strong { display: block; font-size: 13.5px; font-weight: 600; line-height: 1.25; }
.cat-tile span { font-size: 12px; color: var(--muted); }
.cat-tile:hover { transform: translateY(-3px); border-color: #3c3c3c; box-shadow: var(--glow-strong); }
.cat-tile:hover::before { opacity: 1; }
.cat-tile:hover .plugin-icon { transform: scale(1.07); border-color: #444; box-shadow: inset 0 1px 0 rgba(255,255,255,.12), 0 0 16px rgba(255,255,255,.14); }

@media (max-width: 1100px) { .popular-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 760px)  { .popular-grid { grid-template-columns: 1fr; } }

/* ── Responsive ── */
@media (max-width: 1100px) {
  .featured-wrap { grid-template-columns: 1fr; }
  .featured-preview { min-height: 260px; }
  .plugin-grid, .cat-grid { grid-template-columns: repeat(2, 1fr); }
  .related-grid { grid-template-columns: repeat(2, 1fr); }
  .detail-body { grid-template-columns: 1fr; }
}
@media (max-width: 760px) {
  body { flex-direction: column; }
  .sidebar { position: static; width: auto; min-width: 0; height: auto; margin: 12px 12px 0; }
  .sidebar nav { flex-direction: row; flex-wrap: wrap; }
  .sidebar-footer { display: none; }
  .main { padding: 24px 16px; }
  .stats-row, .plugin-grid, .cat-grid, .related-grid { grid-template-columns: 1fr 1fr; }
  .plugin-grid, .cat-grid { grid-template-columns: 1fr; }
  .browse-toolbar { flex-wrap: wrap; }
  .featured-card { padding: 28px 24px; }
  .featured-card h2 { font-size: 42px; }
}
