/* AMAZING DESIGN — стиль в духе Claude Code: тёмный, тёплый, просторный, аккуратный */

@font-face{
  font-family:'Gerhaus';
  src:url('../fonts/Gerhaus.ttf') format('truetype');
  font-weight:700;
  font-display:swap;
}

:root{
  --bg:#191817;
  --bg-2:#1f1e1c;
  --surface:#242221;
  --surface-2:#2c2a28;
  --ink:#e8e5e1;
  --muted:#a6a19a;
  --faint:#726e67;
  --line:rgba(255,255,255,.09);
  --line-strong:rgba(255,255,255,.18);
  --accent:#d97757;
  --accent-ink:#ffffff;
  --accent-soft:rgba(217,119,87,.13);
  --accent-glow:rgba(217,119,87,.16);
  --header-h:76px;
  --radius-lg:12px;
  --radius-md:9px;
  --radius-sm:6px;
  --shadow-sm:0 1px 2px rgba(0,0,0,.3);
  --shadow:0 4px 16px rgba(0,0,0,.38);
  --shadow-lg:0 16px 44px rgba(0,0,0,.5);
  --font:system-ui,-apple-system,"Segoe UI",Roboto,"Helvetica Neue",Arial,sans-serif;
  --mono:ui-monospace,"Cascadia Code",Consolas,"SF Mono",Menlo,monospace;
  --img-zoom:1;
}

html[data-theme="light"]{
  --bg:#f7f6f4;
  --bg-2:#efedea;
  --surface:#ffffff;
  --surface-2:#f4f2ef;
  --ink:#232120;
  --muted:#6f6b66;
  --faint:#9c9790;
  --line:#e6e3de;
  --line-strong:#d4d0c9;
  --accent:#c45f3a;
  --accent-ink:#ffffff;
  --accent-soft:#fae9e0;
  --accent-glow:rgba(196,95,58,.12);
  --shadow-sm:0 1px 2px rgba(30,24,18,.05);
  --shadow:0 4px 16px rgba(30,24,18,.08);
  --shadow-lg:0 16px 44px rgba(30,24,18,.13);
}

[hidden]{display:none!important}
*{box-sizing:border-box}

html{scroll-behavior:smooth}

body{
  margin:0;
  font-family:var(--font);
  font-size:16px;
  line-height:1.6;
  color:var(--ink);
  background:var(--bg);
  min-height:100vh;
  overflow-x:hidden;
  -webkit-font-smoothing:antialiased;
  text-rendering:optimizeLegibility;
  transition:background .25s ease,color .25s ease;
}

button{font-family:inherit;color:inherit;cursor:pointer}
img{display:block}
input{font-family:inherit}

::selection{background:var(--accent);color:var(--accent-ink)}

::-webkit-scrollbar{width:12px;height:12px}
::-webkit-scrollbar-thumb{background:var(--line-strong);border-radius:999px;border:3px solid var(--bg);background-clip:content-box}
::-webkit-scrollbar-track{background:transparent}

:focus-visible{outline:2px solid var(--accent);outline-offset:2px}

@media (prefers-reduced-motion:reduce){
  *{transition:none!important;animation:none!important}
  html{scroll-behavior:auto}
}

/* ---------- Шапка ---------- */
.header{
  position:sticky;
  top:0;
  z-index:50;
  background:color-mix(in srgb,var(--bg) 82%,transparent);
  -webkit-backdrop-filter:blur(12px);
  backdrop-filter:blur(12px);
  border-bottom:1px solid var(--line);
}

.header-inner{
  max-width:1180px;
  margin:0 auto;
  height:var(--header-h);
  padding:0 28px;
  display:flex;
  align-items:center;
  gap:20px;
}

.logo{
  display:flex;
  align-items:center;
  gap:11px;
  text-decoration:none;
  color:var(--ink);
  flex:none;
  cursor:pointer;
}

.logo-badge{
  width:38px;
  height:38px;
  border-radius:9px;
  object-fit:contain;
}

.logo-text{
  font-size:15.5px;
  font-weight:650;
  letter-spacing:.2px;
  white-space:nowrap;
}

.logo-text .logo-accent{color:var(--accent)}

.search-wrap{
  flex:1;
  max-width:520px;
  margin:0 auto;
  position:relative;
}

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

#search{
  width:100%;
  height:42px;
  padding:0 44px 0 42px;
  border:1px solid var(--line);
  border-radius:10px;
  background:var(--surface);
  color:var(--ink);
  font-size:14.5px;
  transition:border-color .2s ease,box-shadow .2s ease;
  appearance:none;
}

#search::-webkit-search-cancel-button{display:none}
#search::placeholder{color:var(--faint)}

#search:focus{
  outline:none;
  border-color:var(--accent);
  box-shadow:0 0 0 3px var(--accent-glow);
}

.search-clear{
  position:absolute;
  right:7px;
  top:50%;
  transform:translateY(calc(-50% - 1px));
  width:28px;
  height:28px;
  border-radius:50%;
  border:none;
  background:var(--surface-2);
  color:var(--muted);
  font-size:15px;
  line-height:1;
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
  transition:background .2s ease,color .2s ease;
}

.search-clear:hover{background:var(--line-strong);color:var(--ink)}

.header-btns{display:flex;align-items:center;gap:10px;flex:none}

.icon-btn{
  width:42px;
  height:42px;
  border-radius:10px;
  border:1px solid var(--line);
  background:var(--surface);
  color:var(--ink);
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
  transition:border-color .18s ease,background .18s ease;
}

.icon-btn:hover{border-color:var(--line-strong);background:var(--surface-2)}

#themeIco{font-size:17px;line-height:1}

.grid-ico{
  width:15px;
  height:15px;
  background-repeat:no-repeat;
  background-image:
    radial-gradient(circle,currentColor 2.4px,transparent 2.9px),
    radial-gradient(circle,currentColor 2.4px,transparent 2.9px),
    radial-gradient(circle,currentColor 2.4px,transparent 2.9px),
    radial-gradient(circle,currentColor 2.4px,transparent 2.9px);
  background-position:0 0,100% 0,0 100%,100% 100%;
  background-size:50% 50%;
}

body[data-view="list"] .grid-ico{
  background-image:
    linear-gradient(currentColor,currentColor),
    linear-gradient(currentColor,currentColor),
    linear-gradient(currentColor,currentColor);
  background-size:100% 3px;
  background-position:0 0,0 50%,0 100%;
  background-repeat:no-repeat;
}

body[data-mode="home"] #viewToggle{display:none}

/* ---------- Контент ---------- */
.main{
  max-width:1180px;
  margin:0 auto;
  padding:0 28px 120px;
  min-height:62vh;
}

/* ---------- Hero ---------- */
.hero{padding:96px 0 40px;max-width:780px;margin:0 auto;text-align:center}

.hero-kicker{
  font-size:11.5px;
  font-weight:600;
  letter-spacing:.22em;
  text-transform:uppercase;
  color:var(--accent);
}

.hero-title{
  margin:22px 0 0;
  font-family:'Gerhaus',var(--font);
  font-size:clamp(36px,5vw,54px);
  font-weight:700;
  line-height:1.08;
  letter-spacing:-.02em;
}

.hero-sub{
  margin:22px auto 0;
  font-size:17px;
  line-height:1.65;
  color:var(--muted);
  max-width:600px;
}

.hero-stats{
  display:flex;
  flex-wrap:wrap;
  justify-content:center;
  gap:10px;
  margin-top:30px;
}

.stat-pill{
  display:inline-flex;
  align-items:center;
  height:34px;
  padding:0 15px;
  border-radius:999px;
  background:var(--surface);
  border:1px solid var(--line);
  font-size:13px;
  font-weight:500;
  color:var(--muted);
}

/* ---------- Заголовок раздела ---------- */
.section-head{
  display:flex;
  align-items:baseline;
  justify-content:space-between;
  gap:16px;
  margin:56px 0 26px;
  padding-top:38px;
  border-top:1px solid var(--line);
}

.section-title{
  margin:0;
  font-size:25px;
  font-weight:700;
  letter-spacing:-.01em;
}

.section-note{font-size:13px;color:var(--faint);white-space:nowrap}

/* ---------- Сетка коллекций ---------- */
.collections{
  display:grid;
  grid-template-columns:repeat(auto-fill,minmax(330px,1fr));
  gap:24px;
}

.cat-card{
  background:var(--surface);
  border:1px solid var(--line);
  border-radius:var(--radius-lg);
  overflow:hidden;
  cursor:pointer;
  transition:border-color .2s ease,box-shadow .2s ease,transform .2s ease;
}

.cat-card:hover{
  border-color:var(--line-strong);
  box-shadow:var(--shadow);
  transform:translateY(-3px);
}

.cat-card:active{transform:translateY(0)}

.cat-preview{
  height:230px;
  position:relative;
  overflow:hidden;
  background:var(--bg-2);
  background:
    radial-gradient(130% 130% at 50% -10%, color-mix(in srgb, var(--cat-color, #64748b) 30%, transparent), transparent 60%),
    radial-gradient(100% 100% at 12% 115%, color-mix(in srgb, var(--cat-color, #64748b) 18%, transparent), transparent 55%),
    var(--bg-2);
  border-bottom:1px solid var(--line);
}

.cv-tile{
  position:absolute;
  display:flex;
  align-items:center;
  justify-content:center;
}

.cv-tile.solo{
  left:50%;
  top:50%;
  width:52%;
  height:auto;
  aspect-ratio:1/1;
  margin-left:-26%;
  margin-top:-26%;
}

.cv-tile img{
  width:100%;
  height:100%;
  object-fit:contain;
  filter:drop-shadow(0 14px 18px rgba(0,0,0,.45));
}

.cat-info{padding:17px 20px 19px}

.cat-top{
  display:flex;
  align-items:baseline;
  justify-content:space-between;
  gap:4px 12px;
}

.cat-name{
  font-size:17.5px;
  font-weight:700;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.cat-count{
  font-family:var(--mono);
  font-size:11.5px;
  font-weight:600;
  letter-spacing:.06em;
  color:var(--faint);
  white-space:nowrap;
}

/* ---------- Панель каталога ---------- */
.toolbar{
  display:flex;
  align-items:center;
  gap:18px;
  flex-wrap:wrap;
  padding-top:44px;
}

.back-btn{
  display:inline-flex;
  align-items:center;
  height:40px;
  padding:0 18px;
  border-radius:9px;
  border:1px solid var(--line);
  background:var(--surface);
  color:var(--ink);
  font-size:14px;
  font-weight:600;
  cursor:pointer;
  transition:border-color .18s ease,background .18s ease;
}

.back-btn:hover{border-color:var(--line-strong);background:var(--surface-2)}

.crumb{
  flex:1;
  min-width:0;
  font-size:14px;
  color:var(--muted);
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.crumb b{color:var(--ink);font-weight:650}

.count{
  font-family:var(--mono);
  font-size:13px;
  color:var(--faint);
  white-space:nowrap;
}

.catalog-title{
  margin:16px 0 28px;
  font-size:clamp(30px,4.2vw,42px);
  font-weight:700;
  letter-spacing:-.02em;
  line-height:1.1;
}

/* ---------- Сетка предметов ---------- */
.grid{
  display:grid;
  grid-template-columns:repeat(auto-fill,minmax(216px,1fr));
  gap:20px;
}

.card{
  background:var(--surface);
  border:1px solid var(--line);
  border-radius:var(--radius-lg);
  padding:13px;
  display:flex;
  flex-direction:column;
  cursor:pointer;
  transition:border-color .2s ease,box-shadow .2s ease,transform .2s ease;
}

.card:hover{
  border-color:var(--line-strong);
  box-shadow:var(--shadow);
  transform:translateY(-3px);
}

.card:active{transform:translateY(0)}

.card-img{
  aspect-ratio:1/1;
  border-radius:var(--radius-md);
  background:var(--bg-2);
  border:1px solid var(--line);
  display:flex;
  align-items:center;
  justify-content:center;
  overflow:hidden;
}

.card-img img{
  width:100%;
  height:100%;
  object-fit:contain;
}

.card-body{padding:14px 6px 6px;min-width:0}

.card-title{
  font-size:14.5px;
  font-weight:650;
  line-height:1.3;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}

.card-id{
  margin-top:4px;
  font-family:var(--mono);
  font-size:11.5px;
  font-weight:600;
  letter-spacing:.04em;
  color:var(--accent);
}

/* Список */
body[data-view="list"] .grid{grid-template-columns:1fr;gap:10px}

body[data-view="list"] .card{
  flex-direction:row;
  align-items:center;
  gap:16px;
  padding:10px 14px;
  border-radius:var(--radius-md);
}

body[data-view="list"] .card-img{
  width:60px;
  height:60px;
  aspect-ratio:auto;
  flex:none;
  border-radius:8px;
}

body[data-view="list"] .card-img img{padding:0}

body[data-view="list"] .card-body{flex:1;padding:0;min-width:0}

/* ---------- Пустой раздел ---------- */
.empty{
  padding:80px 20px;
  display:flex;
  flex-direction:column;
  align-items:center;
  text-align:center;
}

.empty-ico{
  width:72px;
  height:72px;
  border-radius:16px;
  background:var(--surface);
  border:1px solid var(--line);
  color:var(--faint);
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:32px;
  margin-bottom:22px;
}

.empty-title{font-size:24px;font-weight:700;letter-spacing:-.01em}

.empty-sub{font-size:15px;color:var(--muted);max-width:460px;line-height:1.6;margin-top:8px}

/* ---------- Онбординг (каталог не собран) ---------- */
.onboard{
  border:1px dashed var(--line-strong);
  border-radius:var(--radius-lg);
  padding:56px 28px;
  text-align:center;
  background:var(--surface);
  grid-column:1/-1;
}

.onboard-title{font-size:22px;font-weight:700}

.onboard-sub{font-size:15px;color:var(--muted);max-width:500px;margin:12px auto 0;line-height:1.65}

.onboard-steps{
  display:inline-block;
  margin-top:22px;
  padding:10px 18px;
  border-radius:9px;
  background:var(--surface-2);
  border:1px solid var(--line);
  color:var(--ink);
  font-family:var(--mono);
  font-size:12.5px;
}

/* ---------- Лайтбокс ---------- */
.lightbox{
  position:fixed;
  inset:0;
  z-index:100;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:28px;
}

.lb-backdrop{
  position:absolute;
  inset:0;
  background:rgba(10,10,10,.7);
  -webkit-backdrop-filter:blur(8px);
  backdrop-filter:blur(8px);
}

.lb-inner{
  position:relative;
  max-width:940px;
  width:100%;
  animation:lbIn .25s ease;
}

@keyframes lbIn{
  from{opacity:0;transform:translateY(12px)}
  to{opacity:1;transform:translateY(0)}
}

.lb-close{
  position:absolute;
  top:-12px;
  right:-12px;
  z-index:2;
  width:40px;
  height:40px;
  border-radius:50%;
  border:1px solid var(--line-strong);
  background:var(--surface);
  color:var(--ink);
  font-size:22px;
  line-height:1;
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
  transform:translateY(-1px);
  transition:transform .18s ease,background .18s ease;
}

.lb-close:hover{transform:scale(1.07) translateY(-1px);background:var(--surface-2)}

.lb-stage{
  display:flex;
  align-items:center;
  gap:14px;
}

.lb-img-wrap{
  flex:1;
  min-width:0;
  display:flex;
  align-items:center;
  justify-content:center;
}

#lbImg{
  width:min(70vw, 640px);
  height:min(70vh, 640px);
  border-radius:var(--radius-lg);
  background:var(--bg-2);
  border:1px solid var(--line);
  box-shadow:var(--shadow-lg);
  padding:24px;
  object-fit:contain;
}

.lb-nav{
  flex:none;
  width:46px;
  height:46px;
  border-radius:50%;
  border:1px solid var(--line);
  background:var(--surface);
  color:var(--ink);
  font-size:27px;
  line-height:1;
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
  transform:translateY(-1px);
  transition:transform .18s ease,background .18s ease;
}

.lb-nav:hover{transform:scale(1.06) translateY(-1px);background:var(--surface-2)}

.lb-meta{
  margin-top:20px;
  text-align:center;
  display:flex;
  flex-direction:column;
  align-items:center;
}

.lb-title{font-size:22px;font-weight:700;letter-spacing:-.01em}

.lb-id{
  margin-top:12px;
  font-family:var(--mono);
  font-size:12px;
  font-weight:600;
  letter-spacing:.08em;
  color:var(--accent);
  background:var(--accent-soft);
  padding:5px 14px;
  border-radius:999px;
}

.lb-tags{
  display:flex;
  flex-wrap:wrap;
  gap:8px;
  justify-content:center;
  margin-top:16px;
}

.lb-tag{
  font-size:12.5px;
  font-weight:500;
  color:var(--muted);
  background:var(--surface);
  border:1px solid var(--line);
  padding:5px 12px;
  border-radius:999px;
}

.lb-tag.acc{
  background:var(--accent);
  color:var(--accent-ink);
  border-color:transparent;
}

.lb-desc{
  max-width:580px;
  margin-top:18px;
  font-size:14.5px;
  line-height:1.65;
  color:var(--muted);
}

.lb-file{
  margin-top:8px;
  font-family:var(--mono);
  font-size:11.5px;
  color:var(--faint);
}

/* ---------- Подвал ---------- */
.footer{
  padding:48px 28px 42px;
  text-align:center;
  font-size:13px;
  color:var(--faint);
  line-height:1.8;
  max-width:780px;
  margin:0 auto;
  border-top:1px solid var(--line);
}

.footer b{color:var(--muted);font-weight:600}

.footer-note{margin-top:4px}

/* ---------- Кнопки и контакты в подвале ---------- */
.footer-actions{
  display:flex;
  flex-wrap:wrap;
  gap:10px;
  justify-content:center;
  margin-bottom:26px;
}

.btn{
  display:inline-flex;
  align-items:center;
  justify-content:center;
  gap:9px;
  height:44px;
  padding:0 18px;
  border-radius:11px;
  border:1px solid var(--line);
  background:var(--surface);
  color:var(--ink);
  font-size:14px;
  font-weight:600;
  font-family:inherit;
  line-height:1;
  cursor:pointer;
  text-decoration:none;
  transition:border-color .18s ease,background .18s ease,transform .18s ease;
}
.btn svg{flex:none}
.btn:hover{border-color:var(--line-strong);background:var(--surface-2)}

.btn-primary{
  background:var(--accent);
  color:var(--accent-ink);
  border-color:transparent;
}
.btn-primary:hover{background:var(--accent);filter:brightness(1.1)}

.btn-sm{height:36px;padding:0 14px;font-size:13px;border-radius:9px}

.footer-brand,.footer-dev{margin:2px 0}
.footer-brand b{color:var(--muted);font-weight:700}
.footer-brand .footer-accent{color:var(--accent);font-weight:500}
.footer-dev b{color:var(--accent)}

/* ---------- Модалки ---------- */
.modal{
  position:fixed;
  inset:0;
  z-index:110;
  display:flex;
  align-items:center;
  justify-content:center;
  padding:20px;
}

.modal-backdrop{
  position:absolute;
  inset:0;
  background:rgba(10,10,10,.7);
  -webkit-backdrop-filter:blur(8px);
  backdrop-filter:blur(8px);
}

.modal-inner{
  position:relative;
  width:100%;
  max-width:430px;
  background:var(--bg-2);
  border:1px solid var(--line);
  border-radius:var(--radius-lg);
  padding:28px 26px;
  box-shadow:var(--shadow-lg);
  animation:lbIn .25s ease;
  text-align:center;
}

.modal-close{
  position:absolute;
  top:10px;
  right:10px;
  width:36px;
  height:36px;
  border-radius:50%;
  border:1px solid var(--line);
  background:var(--surface);
  color:var(--ink);
  font-size:20px;
  line-height:1;
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
  transform:translateY(-1px);
  transition:transform .18s ease,background .18s ease;
}
.modal-close:hover{transform:scale(1.07) translateY(-1px);background:var(--surface-2)}

.modal-title{font-size:20px;font-weight:700;letter-spacing:-.01em}
.modal-sub{margin:8px 0 20px;font-size:13.5px;color:var(--muted);line-height:1.6}

.donate-card{
  max-width:340px;
  margin:0 auto 14px;
  border:1px dashed var(--line-strong);
  border-radius:var(--radius-md);
  padding:16px 14px;
  background:var(--surface);
}
.donate-card-num{
  font-family:var(--mono);
  font-size:18px;
  font-weight:600;
  letter-spacing:.04em;
  color:var(--accent);
}
.donate-card .btn{margin-top:12px}

.donate-recipient{
  margin-bottom:18px;
  font-size:13.5px;
  color:var(--muted);
}
.donate-recipient b{color:var(--ink)}
.donate-recipient + .donate-recipient{margin-top:-12px}

.tg-list{display:flex;flex-direction:column;gap:8px}

.tg-row{
  display:flex;
  align-items:center;
  justify-content:space-between;
  gap:10px;
  padding:13px 15px;
  border:1px solid var(--line);
  border-radius:var(--radius-md);
  background:var(--surface);
  color:var(--ink);
  text-decoration:none;
  font-family:var(--mono);
  font-size:14px;
  font-weight:600;
  transition:border-color .18s ease,background .18s ease;
}
.tg-row:hover{border-color:var(--line-strong);background:var(--surface-2)}
.tg-open{color:var(--accent);font-family:var(--font);font-size:12.5px;font-weight:600}

/* ---------- Кнопка «наверх» ---------- */
.to-top{
  position:fixed;
  right:26px;
  bottom:26px;
  z-index:60;
  width:46px;
  height:46px;
  border-radius:12px;
  border:1px solid var(--line);
  background:var(--surface);
  color:var(--ink);
  font-size:17px;
  cursor:pointer;
  box-shadow:var(--shadow);
  display:flex;
  align-items:center;
  justify-content:center;
  transition:transform .18s ease,background .18s ease;
}

.to-top:hover{transform:translateY(-3px);background:var(--surface-2)}

/* ---------- Переход между сайтами и свечения ---------- */
.switch-btn{
  position:relative;
  display:inline-flex;
  align-items:center;
  justify-content:center;
  flex:none;
  height:42px;
  padding:0 42px;
  border-radius:10px;
  border:1px solid transparent;
  background:var(--accent);
  color:var(--accent-ink);
  font-size:15px;
  font-weight:650;
  line-height:1;
  text-decoration:none;
  white-space:nowrap;
  transition:filter .18s ease,transform .18s ease;
}
.switch-btn:hover{filter:brightness(1.08)}
.switch-btn:active{transform:translateY(1px)}
.switch-btn .switch-ico{
  position:absolute;
  left:8px;
  bottom:2px;
  height:36px;
  width:auto;
  display:block;
  border-radius:4px;
  pointer-events:none;
}

/* Картинка-ссылка на страницу подсказок (без фона) */
.switch-img{
  display:inline-flex;
  align-items:center;
  flex:none;
  text-decoration:none;
  line-height:0;
  transition:transform .18s ease,filter .18s ease;
}
.switch-img img{height:50px;width:auto;display:block}
.switch-img:hover{transform:translateY(-1px);filter:brightness(1.07)}

/* Кнопка-картинка «Вернуться обратно» на странице подсказок */
.switch-back img{height:70px;border-radius:10px}

/* Страница подсказок: розовый неон-акцент вместо оранжевого */
body.partner{
  --accent:#ff4d85;
  --accent-ink:#fff;
  --accent-soft:rgba(255,77,133,.14);
  --accent-glow:rgba(255,77,133,.28);
}
html[data-theme="light"] body.partner{
  --accent:#d6336c;
  --accent-soft:#ffe0ec;
  --accent-glow:rgba(214,51,108,.18);
}

body.partner .logo-badge{width:auto;height:48px;border-radius:0}

.glow{
  position:fixed;
  z-index:5;
  width:min(58vw,820px);
  height:auto;
  pointer-events:none;
  opacity:.85;
}
.glow-tr{top:0;right:0;transform:translate(12%,-12%)}
.glow-bl{bottom:0;left:0;transform:translate(-12%,12%)}
html[data-theme="light"] .glow{opacity:.65}

/* Карточка коллекции на странице подсказок: персонаж на прозрачном фоне */
body.partner .collections{
  grid-template-columns:minmax(280px,560px);
  justify-content:center;
}

body.partner .cat-card{
  overflow:visible;
  background:transparent;
  border:none;
  box-shadow:none;
}
body.partner .cat-card:hover{
  border-color:transparent;
  box-shadow:none;
}

body.partner .p-cover{
  position:relative;
  display:flex;
  justify-content:center;
  background:transparent;
}

body.partner .p-cover-img{
  width:100%;
  height:auto;
  object-fit:contain;
}

/* Подсказки: карточки и лайтбокс повторяют формат картинки (не квадрат) */
body.partner .card-img{aspect-ratio:16/9}

body.partner .grid{grid-template-columns:repeat(auto-fit,minmax(340px,1fr))}

body.partner .lb-viewport{
  position:relative;
  overflow:hidden;
  max-width:min(94vw,1280px);
  max-height:74vh;
  border-radius:var(--radius-lg);
  background:var(--bg-2);
  border:1px solid var(--line);
  box-shadow:var(--shadow-lg);
  padding:14px;
  cursor:grab;
  touch-action:none;
  display:flex;
  align-items:center;
  justify-content:center;
}
body.partner .lb-viewport:active{cursor:grabbing}

body.partner #lbImg{
  display:block;
  width:auto;
  height:auto;
  max-width:100%;
  max-height:66vh;
  object-fit:contain;
  transform-origin:center;
  transition:transform .2s ease;
  padding:0;
  border-radius:0;
  border:none;
  box-shadow:none;
}

body.partner .lb-viewport.dragging #lbImg{transition:none}

body.partner .lb-zoom{
  display:flex;
  align-items:center;
  justify-content:center;
  gap:10px;
  margin-top:18px;
}

.zoom-btn{
  flex:none;
  width:38px;
  height:38px;
  border-radius:10px;
  border:1px solid var(--line);
  background:var(--surface);
  color:var(--ink);
  font-size:18px;
  line-height:1;
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
  transition:border-color .18s ease,background .18s ease;
}
.zoom-btn:hover{border-color:var(--line-strong);background:var(--surface-2)}
.zoom-btn.zoom-reset{font-size:15px;color:var(--muted)}

.zoom-val{
  min-width:52px;
  text-align:center;
  font-family:var(--mono);
  font-size:12.5px;
  font-weight:600;
  color:var(--muted);
}

#zoomRange{
  flex:1;
  max-width:220px;
  accent-color:var(--accent);
  cursor:pointer;
}

body.partner .lb-backdrop{background:rgba(10,10,10,.45)}

/* ---------- Адаптивность ---------- */
@media (max-width:1100px){
  .collections{grid-template-columns:repeat(auto-fill,minmax(240px,1fr));gap:18px}
  .grid{grid-template-columns:repeat(auto-fill,minmax(180px,1fr));gap:18px}
}

@media (max-width:720px){
  .header-inner{flex-wrap:wrap;height:auto;padding:10px 16px;gap:10px 12px}
  .header-btns{margin-left:auto;height:56px;align-self:center}
  .logo{height:56px;flex:none;align-self:center}
  .search-wrap{order:3;flex:1 0 100%;max-width:none;margin:0}

  .logo-text{display:none}
  .logo-badge{width:42px;height:42px;border-radius:8px;font-size:12px;flex:none;display:block}

  #search{height:40px;padding-left:38px;font-size:14px}
  .search-icon{left:12px}

  .icon-btn{width:40px;height:40px}

  .switch-btn{padding:0 34px;font-size:14px}
  .switch-btn .switch-ico{height:28px;left:6px}
  .switch-img img{height:50px}
  .switch-back img{height:56px}
  .glow{width:min(85vw,380px)}
  body.partner .logo-badge{height:52px;width:130px;flex:none;object-fit:contain;display:block}
  body.partner .grid{grid-template-columns:1fr}
  body.partner .lb-viewport{max-height:64vh}
  body.partner #lbImg{max-width:100%;max-height:56vh}
  .zoom-btn{width:34px;height:34px}
  #zoomRange{max-width:150px}

  .main{padding:0 16px 96px}

  .hero{padding:64px 0 28px}
  .hero-title{font-size:32px}
  .hero-sub{font-size:15.5px}

  .section-head{margin:40px 0 18px;padding-top:28px}
  .section-title{font-size:21px}
  .section-note{display:none}

  .collections{grid-template-columns:repeat(2,1fr);gap:12px}
  .cat-preview{height:180px}
  .cat-info{padding:13px 14px 14px}
  .cat-name{font-size:15px}
  .cat-count{font-size:10px}

  .toolbar{padding-top:30px;gap:12px}
  .back-btn{height:38px;padding:0 15px;font-size:13.5px}

  .grid{grid-template-columns:repeat(auto-fill,minmax(146px,1fr));gap:12px}
  .card{border-radius:11px;padding:9px}
  .card-img{border-radius:8px}
  .card-img img{padding:0}
  .card-body{padding:11px 4px 4px}
  .card-title{font-size:13.5px}
  .card-id{font-size:10.5px}

  body[data-view="list"] .card{padding:8px 11px;gap:12px}
  body[data-view="list"] .card-img{width:52px;height:52px}
  body[data-view="list"] .card-title{font-size:13.5px}

  .catalog-title{margin:12px 0 20px;font-size:28px}

  .lightbox{padding:12px}
  .lb-close{top:-6px;right:-6px;width:36px;height:36px}
  #lbImg{width:min(88vw,520px);height:min(58vh,520px);border-radius:11px;padding:14px}
  .lb-nav{width:38px;height:38px;font-size:21px}
  .lb-stage{gap:6px}
  .lb-title{font-size:18px}
  .lb-tag{font-size:11.5px;padding:4px 10px}

  .to-top{right:16px;bottom:16px;width:42px;height:42px}
}

@media (max-width:480px){
  .collections{grid-template-columns:1fr}
  .grid{grid-template-columns:repeat(2,1fr)}
}

@media (max-width:480px){
  .modal-inner{padding:26px 16px}
  .donate-card-num{font-size:15px;letter-spacing:.02em}
  .footer-actions .btn{padding:0 14px}
}
