
*{margin:0;padding:0;box-sizing:border-box}
html{-webkit-font-smoothing:antialiased;-moz-osx-font-smoothing:grayscale}
body{font-family:'Inter','Segoe UI',-apple-system,BlinkMacSystemFont,Roboto,sans-serif;
     background:#f8fafc;color:#0f172a;padding-bottom:0;font-size:14px;
     line-height:1.5;letter-spacing:.01em}

header{background:#0f172a;color:#fff;padding:10px 16px;
       min-height:56px;display:flex;
       align-items:center;justify-content:space-between;position:sticky;
       top:0;z-index:100;border-bottom:1px solid #1e293b;
       flex-wrap:wrap;gap:8px}
header h1{font-size:14px;font-weight:600;letter-spacing:.05em}
header h1 a{color:#fff;text-decoration:none}
header .right{display:flex;gap:6px;align-items:center;flex-wrap:wrap}

/* ============ Мобильная адаптация сетки карточек ============ */
@media (max-width:640px){
  body > main,
  main{ padding:0 10px !important; }

  .grid{
    grid-template-columns:repeat(2, minmax(0, 1fr)) !important;
    gap:8px !important;
  }

  .card{ gap:6px; }
  .card .body{ padding:0; }
  .card .artist{
    font-size:12px;
    white-space:normal;
    display:-webkit-box;
    -webkit-line-clamp:2;
    -webkit-box-orient:vertical;
    overflow:hidden;
    text-overflow:ellipsis;
    word-break:break-word;
  }
 /* ============ ИНОАГЕНТ ============ */
/* ============ ИНОАГЕНТ ============ */
.artist-row{
  display:flex;
  align-items:center;
  gap:4px;
  min-width:0;
  width: 100%;
  flex-wrap: nowrap; /* Запрещаем перенос на новую строку */
}

.artist-row .artist{
  display: block;              /* ← вместо -webkit-box */
  flex: 1 1 0%;                /* ← явный flex-grow */
  min-width: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  word-break: normal;
  overflow-wrap: normal;
}
.fa-badge{
  flex:none;
  font-size:11px;
  color:#a16207;
  line-height:1;
  cursor:help;
  user-select:none;
}
.fa-badge:hover{ color:#b91c1c; }
@media (max-width:640px){
  .artist-row .artist{
    white-space:normal;
    display:-webkit-box;
    -webkit-line-clamp:2;
    -webkit-box-orient:vertical;
    overflow:hidden;
    word-break:break-word;
  }
}
  .card .title{
    font-size:11px;
    white-space:normal;
    display:-webkit-box;
    -webkit-line-clamp:2;
    -webkit-box-orient:vertical;
    overflow:hidden;
    word-break:break-word;
  }
  .card .meta{ font-size:10px; margin-top:2px; }
  .card .owner{ font-size:9px; }
.copy-btn{ width:26px;height:26px; top:6px;left:6px; font-size:11px; }
 
  .card .badge{ font-size:8px; padding:1px 4px; }
}

.btn-nav,.btn-admin,.btn-wish,.btn-friends,.btn-add,.btn-msg, .btn-logout{
  background:transparent;color:#cbd5e1;padding:7px 12px;
  border:1px solid #334155;border-radius:4px;text-decoration:none;
  font-weight:500;font-size:12px;transition:all .12s;display:inline-block;
  letter-spacing:.02em;white-space:nowrap}
.btn-nav:hover,.btn-admin:hover,.btn-wish:hover,.btn-friends:hover,

.btn-add{background:#334155;color:#fff;border-color:#334155}
.btn-add:hover{background:#475569;border-color:#475569}
.btn-admin{color:#fbbf24;border-color:#78350f}
.btn-admin:hover{background:#1c1917;border-color:#a16207;color:#fbbf24}
.btn-wish{color:#f472b6;border-color:#831843;position:relative}
.btn-wish:hover{background:#1c1917;border-color:#be185d;color:#f472b6}
.btn-wish .badge-count{background:#be185d;color:#fff;padding:1px 6px;
  border-radius:3px;font-size:10px;margin-left:5px;font-weight:600}
 
.wish-info .wish-notes{
  margin-top:8px;
  padding:8px 10px 8px 12px;
  background:linear-gradient(180deg, #fffbeb 0%, #fef3c7 100%);
  border-left:3px solid #f59e0b;
  border-radius:3px;
  font-size:12px;
  color:#78350f;
  line-height:1.55;
  font-style:italic;
  cursor:pointer;
  user-select:none;
  position:relative;
  transition:background .12s;
}
.wish-info .wish-notes:hover{
  background:linear-gradient(180deg, #fef3c7 0%, #fde68a 100%);
}
.wish-info .wish-notes .notes-text{
  display:-webkit-box;
  -webkit-line-clamp:1;         /* свёрнуто: 2 строки */
  -webkit-box-orient:vertical;
  overflow:hidden;
  word-break:break-word;
}
.wish-info .wish-notes.open .notes-text{
  -webkit-line-clamp:unset;
  display:block;
}

.wish-info .wish-notes .notes-arrow{
  display:inline-block;
  float:right;
  font-style:normal;
  color:#a16207;
  font-size:10px;
  margin-left:6px;
  transition:transform .15s;
}
.wish-info .wish-notes.open .notes-arrow{
  transform:rotate(90deg);
}

.btn-friends .badge-count{
  background:#0ea5e9;color:#fff;padding:1px 6px;
  border-radius:3px;font-size:10px;margin-left:5px;font-weight:600}
.btn-msg{color:#a5b4fc;border-color:#312e81;position:relative}
.btn-msg:hover{background:#1e1b4b;border-color:#4338ca;color:#a5b4fc}
.btn-msg .badge-count{background:#6366f1;color:#fff;padding:1px 6px;
  border-radius:3px;font-size:10px;margin-left:5px;font-weight:600}
.user-chip{background:#1e293b;color:#cbd5e1;padding:7px 12px;
  border-radius:4px;font-size:12px;font-weight:500;text-decoration:none;
  max-width:150px;overflow:hidden;text-overflow:ellipsis;white-space:nowrap;
  display:inline-block;border:1px solid #1e293b;letter-spacing:.02em}
.user-chip:hover{background:#334155;color:#fff}

/* ============ Мобильный header ============ */
@media (max-width:640px){
  header{ padding:8px 12px; gap:6px; position:relative; }
  header h1{ font-size:13px; flex-basis:100%; margin-bottom:2px; }
  header .right{ flex-basis:100%; justify-content:flex-start; gap:5px; }
  header .right .btn-nav,
  header .right .btn-admin,
  header .right .btn-wish,
  header .right .btn-add,
  header .right .btn-logout,
  header .right .btn-msg{ font-size:11px; padding:6px 9px; }
  header .right .user-chip{
    font-size:11px; padding:6px 9px;
  }
  header .right .btn-friends{ font-size:11px; padding:6px 9px; }
  header .right .user-chip{ max-width:110px; }
}
main{max-width:1200px;margin:24px auto;padding:0 24px}
@media (max-width:640px){
  main{ padding:0 10px; margin:16px auto; }
}
.stats{display:grid;grid-template-columns:repeat(auto-fit,minmax(130px,1fr));
       gap:1px;margin-bottom:24px;background:#e2e8f0;border:1px solid #e2e8f0;
       border-radius:6px;overflow:hidden}
.stat{background:#fff;padding:16px 18px}
.stat .num{font-size:22px;font-weight:600;color:#0f172a;letter-spacing:-.02em;
  font-variant-numeric:tabular-nums}
.stat .lbl{font-size:10px;color:#64748b;margin-top:2px;text-transform:uppercase;
  letter-spacing:.08em;font-weight:600}
.stat.money .num{color:#15803d}
.stat.money{background:#f0fdf4}

.filters{display:flex;gap:6px;flex-wrap:wrap;margin-bottom:16px}
.filters a{padding:7px 14px;background:#fff;border-radius:4px;
           text-decoration:none;color:#334155;font-size:12px;
           border:1px solid #e2e8f0;font-weight:500;transition:all .12s;
           letter-spacing:.02em}
.filters a:hover{border-color:#94a3b8}

.filters a.active{background:#0f172a;color:#fff;border-color:#0f172a}

.searchbar{display:flex;gap:8px;margin-bottom:16px}
.searchbar input{flex:1;padding:10px 14px;border:1px solid #e2e8f0;
                 border-radius:4px;font-size:14px;background:#fff;
                 transition:border-color .12s;font-family:inherit}
.searchbar input:focus{outline:none;border-color:#0f172a}
.searchbar button{padding:10px 20px;background:#0f172a;color:#fff;
                  border:none;border-radius:4px;font-weight:500;font-size:13px;
                  cursor:pointer;transition:background .12s;font-family:inherit;
                  letter-spacing:.02em}
.searchbar button:hover{background:#1e293b}

.grid{display:grid;grid-template-columns:repeat(auto-fill,minmax(170px,1fr));
      gap:16px}
   
.card{cursor:pointer;display:flex;flex-direction:column;gap:8px;
      transition:opacity .12s;position:relative}
.card:hover{opacity:.85}
.card .body{display:flex;flex-direction:column;gap:3px;padding:0 2px}
 .card .artist{
  font-weight:600;
  font-size:13px;
  line-height:1.3;
  color:#0f172a;
  letter-spacing:-.01em;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
  word-break:break-word;
  overflow-wrap:anywhere;
  white-space:normal;
  text-decoration:none;
}
.card .title{
  font-size:12px;
  color:#64748b;
  line-height:1.3;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
  word-break:break-word;
  overflow-wrap:anywhere;
  white-space:normal;
  text-decoration:none;
}
.card .meta{font-size:11px;color:#94a3b8;display:flex;
            justify-content:space-between;align-items:center;margin-top:4px;
            font-variant-numeric:tabular-nums;letter-spacing:.02em}
.card .owner{font-size:10px;color:#94a3b8;margin-top:2px;
             overflow:hidden;text-overflow:ellipsis;white-space:nowrap}
.card .owner a{color:#334155;text-decoration:none;font-weight:500}
.card .owner a:hover{color:#0f172a;text-decoration:underline}
.card .artist,
.card .title{
  text-decoration: none;
  color: inherit;
}
.heart-btn{position:absolute;top:8px;right:8px;z-index:10;
  background:rgba(255,255,255,.92);border:1px solid #e2e8f0;border-radius:4px;
  width:32px;height:32px;display:flex;align-items:center;justify-content:center;
  cursor:pointer;font-size:15px;transition:all .12s;padding:0;line-height:1;
  color:#94a3b8}
.heart-btn:hover{background:#fff;border-color:#0f172a;color:#0f172a}
.heart-btn.active{background:#be185d;color:#fff;border-color:#be185d}
.heart-btn.disabled{opacity:.5;cursor:default}

.copy-btn{position:absolute;top:8px;left:8px;z-index:10;
  background:rgba(255,255,255,.92);border:1px solid #e2e8f0;border-radius:4px;
  width:32px;height:32px;display:flex;align-items:center;justify-content:center;
  cursor:pointer;font-size:14px;transition:all .12s;padding:0;line-height:1;
  color:#94a3b8}
.copy-btn:hover{background:#fff;border-color:#0f172a;color:#0f172a}
.copy-btn.done{background:#f0fdf4;color:#15803d;border-color:#bbf7d0;cursor:default}
.copy-btn.done:hover{background:#f0fdf4;border-color:#bbf7d0;color:#15803d}

.badge{padding:2px 6px;border-radius:3px;font-size:9px;font-weight:600;
       text-transform:uppercase;letter-spacing:.06em;
       background:#f1f5f9;color:#475569;border:1px solid #e2e8f0}
.badge.vinyl{background:#f5f3ff;color:#5b21b6;border-color:#ddd6fe}
.badge.cd{background:#ecfeff;color:#155e75;border-color:#cffafe}
.badge.cassette{background:#fff7ed;color:#9a3412;border-color:#ffedd5}
.priority-0{color:#15803d}
.priority-1{color:#a16207}
.priority-2{color:#b91c1c}
.modal{position:relative;}
.cover{position:relative;width:100%;aspect-ratio:1/1;display:flex;
       align-items:center;justify-content:center;overflow:hidden;background:#f1f5f9;
       border:1px solid #e2e8f0;border-radius:4px}

.cover.vinyl{
  border-radius:50%;
  background:
    radial-gradient(circle at 32% 26%, rgba(255,255,255,.18), transparent 42%),
    radial-gradient(circle at 68% 78%, rgba(255,255,255,.05), transparent 38%),
    repeating-radial-gradient(circle at 50% 50%,
      #0a0a0a 0, #0a0a0a 1px, #1a1a1a 1px, #1a1a1a 2px,
      #0a0a0a 2px, #0a0a0a 3px);
  border:none;
}
.cover.vinyl .art{position:relative;width:58%;height:58%;border-radius:50%;
  object-fit:cover;z-index:2;box-shadow:0 0 0 2px #050505}
.cover.vinyl .center{position:absolute;width:5%;height:5%;border-radius:50%;
  background:#f1f5f9;z-index:3}
.cover.vinyl .empty-art{background:#1a1a1a;color:#64748b;display:flex;
  align-items:center;justify-content:center;font-size:20px;border-radius:50%}

.cover.cd{
  border-radius:50%;
  background:
    radial-gradient(circle at 35% 28%, rgba(255,255,255,.7), transparent 50%),
    radial-gradient(circle at 70% 75%, rgba(180,200,220,.25), transparent 45%),
    conic-gradient(from 25deg at 50% 50%,
      #e8e8ea, #f0f0f2, #e0e4e8, #f2f0ec,
      #e8e6ea, #e2ece6, #f0e8ec, #e8e8ea);
  border:none;
}
.cover.cd .art{position:relative;width:86%;height:86%;border-radius:50%;
  object-fit:cover;z-index:2}
.cover.cd .center{position:absolute;width:12%;height:12%;border-radius:50%;
  background:radial-gradient(circle,
      #fafafa 0 42%, rgba(180,180,190,.5) 44%, transparent 60%);
  z-index:3}
.cover.cd .empty-art{background:#e8e8ea;color:#94a3b8;display:flex;
  align-items:center;justify-content:center;font-size:22px}
/* ============ Вращение пластинки при наведении ============ */
.cover.vinyl .art,
.cover.cd .art{
  transition: transform .6s cubic-bezier(.22,.61,.36,1);
  will-change: transform;
}

.cover.vinyl:hover .art,
.cover.cd:hover .art{
  animation: spin-disc 3s linear infinite;
}

@keyframes spin-disc{
  from{ transform: rotate(0deg); }
  to  { transform: rotate(360deg); }
}
/* ============================================================
   КАССЕТА v3 — минимализм с лентой и катушками
   ============================================================ */
.cover.cassette{
  border-radius:6px;
  background:
    linear-gradient(180deg, #2e3238 0%, #1c1f24 60%, #14161a 100%);
  border:1px solid #0a0c0f;
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.1),
    inset 0 -1px 0 rgba(0,0,0,.4),
    0 1px 3px rgba(0,0,0,.2);
  position:relative;
  overflow:hidden;
}

/* Этикетка сверху — вкладыш с названием */
.cover.cassette::before{
  content:"";
  position:absolute;
   top:4%;
  left:7%;
  right:7%;
  height:50%;
  border-radius:2px;
  background:
    /* тонкие линии, как у настоящих кассет */
    
  box-shadow:
    inset 0 1px 0 rgba(255,255,255,.9),
    inset 0 -1px 0 rgba(0,0,0,.06);
  z-index:1;
}

/* Обложка, если загружена — перекрывает этикетку */
.cover.cassette .art{
  position:absolute;
   top:4%;
  left:7%;
  width:86%;
  height:50%;
  object-fit:cover;
  border-radius:2px;
  z-index:2;
  
}

/* Пустое состояние */
.cover.cassette .empty-art{ 
background:#1a1a1a;
color:#64748b;
display:flex;
 
  align-items:center;
  justify-content:center;
  font-size:20px;
}

/* Окно с катушками — тёмный прямоугольник снизу */
.cover.cassette .center{
  position:absolute;
  bottom:6%;
  left:10%;
  right:10%;
  height:32%;;
  border-radius:3px;
  background:
    radial-gradient(ellipse at 50% 100%,
      rgba(60,60,60,.3) 0%, transparent 60%),
    linear-gradient(180deg, #0a0c0f 0%, #050708 100%);
  box-shadow:
    inset 0 1px 4px rgba(0,0,0,.9),
    inset 0 -1px 0 rgba(255,255,255,.08);
  z-index:3;
  overflow:hidden;
  display:block;
  padding:0;
}

/* Лента — провисающая полоса по дну окна */
.cover.cassette .tape{
  position:absolute;
  left:18%;
  right:18%;
  bottom:12%;
  height:16%;
  border-radius:0 0 60% 60% / 0 0 100% 100%;
  background:
    linear-gradient(180deg, #1a1410 0%, #0a0806 100%);
  box-shadow:
    0 1px 0 rgba(255,255,255,.06),
    inset 0 -1px 2px rgba(0,0,0,.8);
  z-index:1;
  pointer-events:none;
}

/* Катушки — общий стиль */
.cover.cassette .reel{
  position:absolute;
  top:50%;
  border-radius:50%;
  transform:translateY(-50%);
  background:
    repeating-conic-gradient(
      from 0deg,
      #3a3a3a 0deg 20deg,
      #1a1a1a 20deg 40deg
    );
  box-shadow:
    inset 0 0 0 2px #0a0c0f,
    inset 0 0 0 4px #5a5a5a,
    inset 0 0 0 6px #1a1a1a,
    inset 0 0 0 8px #0a0c0f;
  z-index:2;
  transition: transform .4s cubic-bezier(.22,.61,.36,1);
  will-change: transform;
}

/* Левая — большая намотка */
.cover.cassette .reel-left{
  left:10%;
  width:32%;
  aspect-ratio:1/1;
}

/* Правая — маленькая намотка */
.cover.cassette .reel-right{
  right:10%;
  width:24%;
  aspect-ratio:1/1;
}

/* Вращение при наведении */
.cover.cassette:hover .reel-left{
  animation: reel-spin 2.4s linear infinite;
}

.cover.cassette:hover .reel-right{
  animation: reel-spin 1.6s linear infinite;
}

@keyframes reel-spin{
  from{ transform:translateY(-50%) rotate(0deg); }
  to  { transform:translateY(-50%) rotate(360deg); }
}
.dbmeter{display:flex;align-items:center;gap:6px;margin-top:4px}
.dbmeter .bars{display:flex;gap:1.5px;flex:1}
.dbmeter .seg{flex:1;height:4px;background:#e2e8f0;border-radius:1px;
  transition:background .12s}
.dbmeter .seg.on.low{background:#64748b}
.dbmeter .seg.on.mid{background:#334155}
.dbmeter .seg.on.high{background:#0f172a}
.dbmeter .val{font-size:10px;font-weight:600;color:#64748b;
  font-family:ui-monospace,'SF Mono',Menlo,monospace;min-width:30px;
  text-align:right;letter-spacing:.02em;font-variant-numeric:tabular-nums}
.dbmeter.big{margin:14px 0 4px}
.dbmeter.big .seg{height:10px;border-radius:1px}
.dbmeter.big .val{font-size:14px;min-width:52px}
.dbmeter.big .label{font-size:10px;color:#64748b;text-transform:uppercase;
  letter-spacing:.08em;margin-bottom:6px;font-weight:600}

.empty{text-align:center;padding:60px 20px;color:#94a3b8;font-size:14px}
.empty a{color:#0f172a;text-decoration:underline;font-weight:500}

.modal-bg{position:fixed;inset:0;background:rgba(15,23,42,.6);display:none;
  align-items:center;justify-content:center;padding:16px;z-index:200}
.modal-bg.show{display:flex}
.modal{background:#fff;border-radius:6px;padding:24px;max-width:540px;width:100%;
  max-height:90vh;overflow-y:auto;border:1px solid #e2e8f0}
.modal h3{margin-bottom:12px;color:#0f172a;font-size:16px;font-weight:600;
  letter-spacing:-.01em}
.modal .modal-cover{max-width:240px;margin:0 auto 18px}
.modal .modal-photo{width:100%;border-radius:4px;margin-bottom:14px;
  background:#f1f5f9;object-fit:cover;max-height:300px;border:1px solid #e2e8f0}
.modal .info p{margin:6px 0;font-size:13px;color:#334155;line-height:1.5}
.modal .info strong{color:#64748b;font-weight:500;font-size:11px;
  text-transform:uppercase;letter-spacing:.06em;margin-right:6px}
.modal .actions{margin-top:18px;display:flex;gap:8px}
.modal .actions a,.modal .actions button{flex:1;padding:10px;border:1px solid #e2e8f0;
  border-radius:4px;font-size:13px;font-weight:500;cursor:pointer;
  text-align:center;text-decoration:none;background:#fff;color:#334155;
  transition:all .12s;font-family:inherit;letter-spacing:.02em}
.modal .actions a:hover,.modal .actions button:hover{background:#f8fafc;
  border-color:#94a3b8;color:#0f172a}
.modal{position:relative;}
.modal-close{
  position:absolute;
  top:12px;
  right:12px;
  width:32px;
  height:32px;
  border-radius:50%;
  background:#f1f5f9;
  border:1px solid #e2e8f0;
  color:#334155;
  font-size:18px;
  font-weight:600;
  line-height:1;
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
  transition:all .12s;
  padding:0;
  z-index:10;
  font-family:inherit;
}
.modal-close:hover{
  background:#0f172a;
  color:#fff;
  border-color:#0f172a;
}
@media (max-width:640px){
  .modal-close{
    top:8px;
    right:8px;
    width:36px;
    height:36px;
    font-size:20px;
  }
}
.btn-edit{background:#f8fafc !important;color:#334155 !important}
.btn-del{background:#fff !important;color:#b91c1c !important;
  border-color:#fecaca !important}
.btn-del:hover{background:#fef2f2 !important;border-color:#f87171 !important}
.btn-buy{background:#0f172a !important;color:#fff !important;
  border-color:#0f172a !important}
.btn-buy:hover{background:#1e293b !important}

.toast{position:fixed;bottom:24px;left:50%;transform:translateX(-50%);
  padding:10px 20px;border-radius:4px;color:#fff;font-size:13px;
  font-weight:500;z-index:999;display:none;border:1px solid transparent;
  background:#0f172a;letter-spacing:.02em}
.toast.ok{background:#0f172a;border-color:#1e293b}
.toast.err{background:#7f1d1d;border-color:#991b1b}
.upload-progress{
  display:none;
  margin-top:10px;
  background:#f1f5f9;
  border:1px solid #e2e8f0;
  border-radius:4px;
  overflow:hidden;
  height:24px;
  position:relative;
}
.upload-progress.show{ display:block; }
.upload-progress .bar{
  height:100%;
  width:0%;
  background:#0f172a;
  transition:width .15s linear;
}
.upload-progress .label{
  position:absolute;
  inset:0;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:11px;
  font-weight:600;
  color:#0f172a;
  letter-spacing:.02em;
  font-family:ui-monospace,'SF Mono',Menlo,monospace;
}
.upload-progress.done .bar{ background:#15803d; }
.upload-progress.done .label{ color:#15803d; }
.upload-progress.error .bar{ background:#b91c1c; }
.upload-progress.error .label{ color:#b91c1c; }
.profile-head{background:#fff;border-radius:6px;padding:24px;
  margin-bottom:20px;border:1px solid #e2e8f0;display:flex;align-items:center;
  gap:20px;flex-wrap:wrap}
  
.avatar{width:56px;height:56px;border-radius:4px;flex:none;
  background:#0f172a;color:#fff;
  display:flex;align-items:center;justify-content:center;
  font-size:22px;font-weight:600;letter-spacing:-.02em}
.profile-info{flex:1;min-width:200px}
.profile-info h2{font-size:18px;color:#0f172a;margin-bottom:4px;font-weight:600;
  letter-spacing:-.01em;display:flex;align-items:center;gap:8px;flex-wrap:wrap}
.profile-info p{font-size:13px;color:#64748b}
.own-badge{background:#f0fdf4;color:#15803d;padding:3px 8px;border-radius:3px;
  font-size:10px;font-weight:600;text-transform:uppercase;letter-spacing:.06em;
  border:1px solid #bbf7d0}
.admin-badge{background:#fffbeb;color:#a16207;padding:3px 8px;border-radius:3px;
  font-size:10px;font-weight:600;text-transform:uppercase;letter-spacing:.06em;
  border:1px solid #fde68a}

.setup-preview{background:#fff;border-radius:6px;padding:20px;margin-bottom:20px;
  border:1px solid #e2e8f0}
.setup-head{display:flex;align-items:center;gap:10px;margin-bottom:14px;
  font-size:12px;font-weight:600;color:#0f172a;letter-spacing:.04em;
  flex-wrap:wrap}
.setup-count{background:#f1f5f9;color:#475569;padding:3px 10px;border-radius:3px;
  font-size:10px;font-weight:600;border:1px solid #e2e8f0;
  letter-spacing:.04em}
.setup-link{margin-left:auto;color:#334155;text-decoration:none;font-size:12px;
  font-weight:500;padding:5px 10px;border-radius:3px;transition:all .12s;
  border:1px solid transparent}
.setup-link:hover{background:#f1f5f9;color:#0f172a;border-color:#e2e8f0}
.setup-head-actions{
  display:inline-flex;
  gap:6px;
  flex-wrap:wrap;
  align-items:center;
}
@media (min-width:641px){
  .setup-head-actions{margin-left:auto}
}
.setup-head-actions .setup-link{
  margin-left:0;
  padding:4px 10px;
  border:1px solid #e2e8f0;
  border-radius:4px;
  background:#fff;
  color:#334155;
  font-size:11px;
  font-weight:600;
  text-decoration:none;
  transition:all .12s;
  white-space:nowrap;
}
.setup-head-actions .setup-link:hover{
  background:#f8fafc;
  border-color:#94a3b8;
  color:#0f172a;
}
.setup-head-actions .setup-link.add-btn{
  color:#15803d;
  background:#f0fdf4;
  border-color:#bbf7d0;
}
.setup-head-actions .setup-link.add-btn:hover{
  background:#dcfce7;
  border-color:#86efac;
  color:#15803d;
}
@media (max-width:640px){
  .setup-head{gap:6px}
  .setup-head-actions{gap:4px}
  .setup-head-actions .setup-link{padding:5px 9px}
}
.setup-mini-grid{display:flex;gap:6px;flex-wrap:wrap}
.setup-mini{width:56px;height:56px;border-radius:4px;overflow:hidden;
  background:#f1f5f9;display:flex;align-items:center;justify-content:center;
  font-size:20px;color:#94a3b8;flex:none;border:1px solid #e2e8f0;
  text-decoration:none;transition:border-color .12s}
.setup-mini img{width:100%;height:100%;object-fit:cover}
a.setup-mini:hover{border-color:#0f172a}
.setup-empty{background:#fff;border-radius:6px;padding:20px;margin-bottom:20px;
  border:1px solid #e2e8f0;display:flex;align-items:center;gap:12px;
  font-size:13px;color:#64748b}
.setup-empty a{color:#0f172a;text-decoration:none;font-weight:500;
  margin-left:auto;font-size:12px;padding:6px 12px;border:1px solid #e2e8f0;
  border-radius:3px;transition:all .12s;letter-spacing:.02em}
.setup-empty a:hover{background:#f8fafc;border-color:#94a3b8}

.wear-bar{width:100%;height:4px;background:#e2e8f0;border-radius:2px;
  overflow:hidden;margin-top:6px}
.wear-fill{height:100%;transition:width .3s,background .3s;border-radius:2px}
.wear-ok .wear-fill{background:#15803d}
.wear-warn .wear-fill{background:#ca8a04}
.wear-danger .wear-fill{background:#b91c1c}
.wear-label{font-size:10px;margin-top:3px;font-weight:600;
  font-family:ui-monospace,'SF Mono',Menlo,monospace;
  font-variant-numeric:tabular-nums;letter-spacing:.02em}
.wear-label.wear-ok{color:#15803d}
.wear-label.wear-warn{color:#a16207}
.wear-label.wear-danger{color:#b91c1c}

/* ============ СЕТКА СЕТАПА — горизонтальное заполнение ============ */
.setup-grid{
  display:grid;
  grid-template-columns:repeat(auto-fill, minmax(220px, 1fr));
  gap:14px;
  align-items:start;
  margin-bottom:8px;
}
.setup-grid .setup-item{
  width:100%;
  max-width:none;
}
@media (max-width:520px){
  .setup-grid{grid-template-columns:1fr}
}
/* ================================================================== */
.pagination{
  display:flex;
  justify-content:center;
  align-items:center;
  gap:8px;
  margin-top:24px;
  font-size:13px;
  flex-wrap:wrap;
}
.pagination a{
  padding:7px 14px;
  background:#fff;
  color:#334155;
  border:1px solid #e2e8f0;
  border-radius:4px;
  text-decoration:none;
  font-weight:500;
  transition:all .12s;
  letter-spacing:.02em;
}
.pagination a:hover{
  border-color:#0f172a;
  color:#0f172a;
}
.pagination .disabled{
  padding:7px 14px;
  background:#f8fafc;
  color:#cbd5e1;
  border:1px solid #e2e8f0;
  border-radius:4px;
}
.pagination .pg-info{
  color:#64748b;
  font-size:12px;
  letter-spacing:.02em;
}
.setup-item{background:#fff;border-radius:6px;overflow:hidden;
  border:1px solid #e2e8f0;display:flex;flex-direction:column;
  transition:border-color .12s;cursor:pointer;position:relative}
.setup-item:hover{border-color:#94a3b8}
.setup-item .photo{width:100%;aspect-ratio:4/3;object-fit:cover;background:#f1f5f9;
  display:block;border-bottom:1px solid #e2e8f0}
.setup-item .no-photo{width:100%;aspect-ratio:4/3;background:#f1f5f9;
  display:flex;align-items:center;justify-content:center;font-size:32px;
  color:#cbd5e1;border-bottom:1px solid #e2e8f0}
.setup-item .body{padding:12px 14px;display:flex;flex-direction:column;gap:3px;flex:1}
.setup-item .brand{font-size:10px;color:#64748b;font-weight:600;
  text-transform:uppercase;letter-spacing:.06em}
.setup-item .model{font-size:13px;font-weight:600;color:#0f172a;line-height:1.3}
.setup-item .year{font-size:11px;color:#94a3b8;margin-top:auto;padding-top:6px;
  font-variant-numeric:tabular-nums}
.setup-item .price{font-size:12px;color:#15803d;font-weight:600;margin-top:2px;
  font-variant-numeric:tabular-nums}
.setup-item .setup-type{
  position:absolute;
  top:8px;
  left:8px;
  background:rgba(15,23,42,.85);
  color:#fff;
  padding:3px 8px;
  border-radius:3px;
  font-size:9px;
  font-weight:600;
  text-transform:uppercase;
  letter-spacing:.06em;
  z-index:5;
  max-width:calc(100% - 60px);
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.hero{background:#fff;border-radius:6px;padding:20px;margin-bottom:20px;
      border:1px solid #e2e8f0;display:flex;
      justify-content:space-between;align-items:center;flex-wrap:wrap;gap:12px}
.hero h2{font-size:15px;color:#0f172a;margin-bottom:4px;font-weight:600;
  letter-spacing:.02em}
.hero p{font-size:12px;color:#64748b;letter-spacing:.02em}

.comments-block{background:#fff;border-radius:6px;padding:20px;margin-top:24px;
  border:1px solid #e2e8f0}
.comments-title{font-size:13px;color:#0f172a;font-weight:600;margin-bottom:16px;
  display:flex;align-items:center;gap:8px;letter-spacing:.02em}
.comments-title span{background:#f1f5f9;color:#475569;padding:2px 8px;
  border-radius:3px;font-size:10px;font-weight:600;border:1px solid #e2e8f0}
.comment-form{display:flex;flex-direction:column;gap:8px;margin-bottom:18px;
  padding:14px;background:#f8fafc;border-radius:4px;
  border:1px solid #e2e8f0}
.comment-form textarea{width:100%;min-height:70px;padding:10px 12px;
  border:1px solid #e2e8f0;border-radius:4px;font-size:13px;
  font-family:inherit;resize:vertical;background:#fff;
  transition:border-color .12s;line-height:1.5}
.comment-form textarea:focus{outline:none;border-color:#0f172a}
.comment-form button{align-self:flex-end;padding:8px 16px;background:#0f172a;
  color:#fff;border:none;border-radius:4px;font-size:12px;font-weight:500;
  cursor:pointer;transition:background .12s;font-family:inherit;
  letter-spacing:.02em}
.comment-form button:hover{background:#1e293b}
.comments-list{display:flex;flex-direction:column;gap:10px}
.comment-item{background:#f8fafc;border-radius:4px;padding:14px;
  border:1px solid #e2e8f0;border-left:3px solid #334155}
.comment-header{display:flex;align-items:center;gap:10px;margin-bottom:6px;
  flex-wrap:wrap}
.comment-author{font-weight:600;font-size:12px;color:#0f172a;
  letter-spacing:.02em}
.comment-author a{color:#0f172a;text-decoration:none}
.comment-author a:hover{text-decoration:underline}
.comment-date{font-size:11px;color:#94a3b8;
  font-family:ui-monospace,'SF Mono',Menlo,monospace;
  font-variant-numeric:tabular-nums}
.comment-del{margin-left:auto;background:transparent;border:none;color:#b91c1c;
  font-size:12px;font-weight:600;cursor:pointer;padding:2px 8px;border-radius:3px;
  transition:background .12s}
.comment-del:hover{background:#fef2f2}
.comment-text{font-size:13px;color:#334155;line-height:1.6;white-space:pre-wrap;
  word-break:break-word}
.comments-empty{text-align:center;color:#94a3b8;font-size:13px;padding:24px;
  font-style:italic}
/* ============ ОТВЕТЫ НА КОММЕНТАРИИ ============ */
.comment-reply{
  background:transparent;border:none;color:#334155;
  font-size:12px;font-weight:600;cursor:pointer;
  padding:2px 8px;border-radius:3px;transition:background .12s;
  margin-left:auto;font-family:inherit;letter-spacing:.02em;
}
.comment-reply:hover{background:#f1f5f9;color:#0f172a}
.comment-reply + .comment-del{margin-left:6px}

.comment-replies{
  margin-top:10px;padding-left:14px;
  border-left:2px solid #e2e8f0;
  display:flex;flex-direction:column;gap:8px;
}
.comment-reply-item{
  background:#fff;border-left:3px solid #64748b;
  padding:10px 12px;margin:0;
}
.comment-reply-item .comment-text{font-size:12px;}

.comment-reply-form{
  margin-top:10px;padding:10px;
  background:#fff;border-radius:4px;
  border:1px solid #e2e8f0;
  display:flex;flex-direction:column;gap:8px;
}
.comment-reply-form textarea{
  width:100%;min-height:56px;padding:8px 10px;
  border:1px solid #e2e8f0;border-radius:4px;
  font-size:13px;font-family:inherit;resize:vertical;
  background:#fff;line-height:1.5;
}
.comment-reply-form textarea:focus{outline:none;border-color:#0f172a}
.comment-reply-actions{
  display:flex;gap:6px;justify-content:flex-end;
}
.comment-reply-actions button{
  padding:7px 14px;border-radius:4px;font-size:12px;
  font-weight:500;cursor:pointer;font-family:inherit;
  letter-spacing:.02em;transition:all .12s;
}
.comment-reply-actions button[type="submit"]{
  background:#0f172a;color:#fff;border:none;
}
.comment-reply-actions button[type="submit"]:hover{background:#1e293b}
.btn-cancel-sm{
  background:#fff;color:#334155;border:1px solid #e2e8f0;
}
.btn-cancel-sm:hover{background:#f8fafc;border-color:#94a3b8}
.tracklist{margin-top:16px;border-top:1px solid #e2e8f0;padding-top:14px}
.tracklist-title{font-size:11px;font-weight:600;color:#0f172a;margin-bottom:12px;
  text-transform:uppercase;letter-spacing:.08em}
.track-side-group{margin-bottom:12px}
.track-side-label{font-size:10px;color:#94a3b8;font-weight:600;
  text-transform:uppercase;letter-spacing:.08em;margin-bottom:6px}
.track-row{display:flex;align-items:baseline;gap:10px;padding:6px 0;
  font-size:13px;border-bottom:1px solid #f1f5f9}
.track-row:last-child{border-bottom:none}
.track-num{min-width:32px;color:#94a3b8;
  font-family:ui-monospace,'SF Mono',Menlo,monospace;font-weight:600;
  font-size:11px;font-variant-numeric:tabular-nums}
.track-name{flex:1;color:#1e293b}
.track-dur{color:#94a3b8;font-family:ui-monospace,'SF Mono',Menlo,monospace;
  font-size:11px;font-weight:500;font-variant-numeric:tabular-nums}

.wish-item{background:#fff;border-radius:6px;padding:14px;display:flex;gap:14px;
  border:1px solid #e2e8f0;align-items:center;position:relative;
  transition:border-color .12s}
.wish-item:hover{border-color:#94a3b8}
.wish-thumb{width:64px;height:64px;border-radius:4px;overflow:hidden;flex:none;
  background:#f1f5f9;display:flex;align-items:center;justify-content:center;
  font-size:24px;color:#cbd5e1;border:1px solid #e2e8f0}
.wish-thumb img{width:100%;height:100%;object-fit:cover}
.wish-info{flex:1;min-width:0}
.wish-info .t1{
  font-weight:600;font-size:13px;color:#0f172a;line-height:1.3;
  overflow:hidden;text-overflow:ellipsis;
  display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;
  word-break:break-word;
}
.wish-info .t2{
  font-size:12px;color:#64748b;margin-top:2px;
  overflow:hidden;text-overflow:ellipsis;
  display:-webkit-box;-webkit-line-clamp:2;-webkit-box-orient:vertical;
  word-break:break-word;
}
.wish-info .meta{font-size:11px;color:#94a3b8;margin-top:6px;display:flex;
  gap:8px;flex-wrap:wrap;align-items:center}
.wish-actions{display:flex;gap:6px;flex:none}
.wish-actions button,.wish-actions a{padding:7px 12px;border:1px solid #e2e8f0;
  border-radius:4px;font-size:11px;font-weight:500;cursor:pointer;
  text-decoration:none;background:#fff;color:#334155;transition:all .12s;
  white-space:nowrap;font-family:inherit;letter-spacing:.02em}
.wish-actions button:hover,.wish-actions a:hover{background:#f8fafc;
  border-color:#94a3b8;color:#0f172a}
.wish-item{
  flex-wrap:wrap;
  align-items:flex-start;
}
.wish-tracks{
  flex-basis:100%;
  margin-top:10px;
  padding-top:10px;
  border-top:1px solid #f1f5f9;
  display:none;         /* ← свёрнут по умолчанию */
}
.wish-tracks.open{ display:block; }

.wish-tracks-toggle{
  flex-basis:100%;
  margin-top:10px;
  padding-top:10px;
  border-top:1px solid #f1f5f9;
  background:transparent;
  border-left:none;border-right:none;border-bottom:none;
  color:#334155;
  font-size:11px;
  font-weight:600;
  cursor:pointer;
  text-align:left;
  padding:10px 0 0;
  letter-spacing:.02em;
  font-family:inherit;
  transition:color .12s;
}
.wish-tracks-toggle:hover{ color:#0f172a; text-decoration:underline; }
.wish-tracks-toggle .arrow{
  display:inline-block;
  transition:transform .15s;
  margin-right:4px;
}
.wish-tracks-toggle.open .arrow{ transform:rotate(90deg); }
.wish-tracks-title{
  font-size:10px;
  color:#94a3b8;
  text-transform:uppercase;
  letter-spacing:.06em;
  font-weight:600;
  margin-bottom:8px;
}
.wish-track-row{
  display:flex;
  align-items:baseline;
  gap:10px;
  font-size:12px;
  color:#334155;
  line-height:1.5;
  padding:2px 0;
}
.wish-track-num{
  min-width:32px;
  color:#94a3b8;
  font-family:ui-monospace,'SF Mono',Menlo,monospace;
  font-weight:600;
  font-size:11px;
}
.wish-track-name{ flex:1; }
.wish-track-dur{
  color:#94a3b8;
  font-family:ui-monospace,'SF Mono',Menlo,monospace;
  font-size:11px;
}
.btn-w-buy{background:#f0fdf4 !important;color:#15803d !important;
  border-color:#bbf7d0 !important}
.btn-w-buy:hover{background:#dcfce7 !important;border-color:#86efac !important}
.btn-w-edit{background:#f8fafc !important}
.btn-w-del{background:#fff !important;color:#b91c1c !important;
  border-color:#fecaca !important}
.btn-w-del:hover{background:#fef2f2 !important;border-color:#f87171 !important}
.pill{display:inline-block;padding:2px 7px;border-radius:3px;font-size:9px;
  font-weight:600;text-transform:uppercase;letter-spacing:.06em;
  border:1px solid transparent}
.pill.kind-release{background:#f1f5f9;color:#334155;border-color:#e2e8f0}
.pill.kind-setup{background:#faf5ff;color:#6b21a8;border-color:#e9d5ff}
.pill.p0{background:#f0fdf4;color:#15803d;border-color:#bbf7d0}
.pill.p1{background:#fffbeb;color:#a16207;border-color:#fde68a}
.pill.p2{background:#fef2f2;color:#b91c1c;border-color:#fecaca}

.wish-grid{display:grid;grid-template-columns:1fr 1fr;gap:10px}
@media (max-width:700px){.wish-grid{grid-template-columns:1fr}}

.kind-tabs{display:flex;gap:6px;margin-bottom:16px;flex-wrap:wrap}
.kind-tabs a{padding:7px 14px;background:#fff;border-radius:4px;
  text-decoration:none;color:#334155;font-size:12px;border:1px solid #e2e8f0;
  font-weight:500;transition:all .12s;letter-spacing:.02em}
.kind-tabs a:hover{border-color:#94a3b8}
.kind-tabs a.active{background:#0f172a;color:#fff;border-color:#0f172a}

.wish-add-bar{
  background:#fff;border-radius:6px;padding:14px 16px;margin-bottom:16px;
  border:1px solid #e2e8f0;display:flex;gap:8px;align-items:center;
  flex-wrap:wrap;
}
.wish-add-bar span{
  font-size:12px;color:#64748b;letter-spacing:.02em;flex:none;
}
.wish-add-bar a{
  padding:8px 14px;background:#0f172a;color:#fff;border-radius:4px;
  text-decoration:none;font-weight:500;font-size:12px;
  transition:background .12s;letter-spacing:.02em;white-space:nowrap;
  flex:none;
}
.wish-add-bar a:hover{background:#1e293b}
.wish-add-bar a.setup-link{background:#334155}
.wish-add-bar a.setup-link:hover{background:#475569}

@media (max-width:640px){
  .wish-add-bar{
    padding:12px 14px;gap:6px;
  }
  .wish-add-bar span{
    flex-basis:100%;margin-bottom:2px;
  }
  .wish-add-bar a{
    flex:1 1 auto;text-align:center;padding:9px 10px;
    font-size:11px;
  }
  .wish-add-bar span[style*="margin-left:auto"]{
    flex-basis:100%;font-size:10px !important;
    text-align:left;margin-left:0 !important;
  }
}

.stat.wish-total .num{color:#0f172a}

.page-title{font-size:14px;color:#0f172a;font-weight:600;margin-bottom:6px;
  letter-spacing:.04em}
.page-sub{font-size:12px;color:#64748b;margin-bottom:20px;letter-spacing:.02em}
.section-title{font-size:11px;color:#94a3b8;text-transform:uppercase;
  letter-spacing:.08em;margin:20px 0 10px;font-weight:600}
.modal-cover-img{
  width:100%;
  max-width:280px;
  aspect-ratio:1/1;
  object-fit:cover;
  border-radius:6px;
  display:block;
  margin:0 auto 18px;
  border:1px solid #e2e8f0;
  background:#f1f5f9;
}
.modal-cover-empty{
  width:100%;
  max-width:280px;
  aspect-ratio:1/1;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:64px;
  color:#cbd5e1;
  background:#f1f5f9;
  border-radius:6px;
  margin:0 auto 18px;
  border:1px solid #e2e8f0;
}
/* ============ НОВЫЕ ПОЛЬЗОВАТЕЛИ ============ */
.latest-users-block{
  margin-top:28px;
  background:#fff;
  border:1px solid #e2e8f0;
  border-radius:6px;
  padding:20px;
}
.latest-users-title{
  font-size:12px;
  font-weight:600;
  color:#0f172a;
  text-transform:uppercase;
  letter-spacing:.08em;
  margin-bottom:16px;
  display:flex;
  align-items:center;
  gap:8px;
}
.users-grid{
  display:grid;
  grid-template-columns:repeat(auto-fill, minmax(220px, 1fr));
  gap:10px;
}
.user-card{
  display:flex;
  align-items:center;
  gap:12px;
  padding:10px 12px;
  border:1px solid #e2e8f0;
  border-radius:4px;
  text-decoration:none;
  color:#0f172a;
  transition:all .12s;
  background:#f8fafc;
}
.user-card:hover{
  border-color:#94a3b8;
  background:#fff;
}
.user-avatar{
  width:40px;
  height:40px;
  flex:none;
  border-radius:4px;
  background:#0f172a;
  color:#fff;
  display:flex;
  align-items:center;
  justify-content:center;
  font-size:16px;
  font-weight:600;
  letter-spacing:-.02em;
}
.user-card-info{
  min-width:0;
  flex:1;
}
.user-card-name{
  font-size:13px;
  font-weight:600;
  color:#0f172a;
  display:flex;
  align-items:center;
  gap:6px;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
}
.user-card-admin{
  font-size:9px;
  font-weight:600;
  text-transform:uppercase;
  letter-spacing:.06em;
  padding:2px 6px;
  border-radius:3px;
  background:#fffbeb;
  color:#a16207;
  border:1px solid #fde68a;
  flex:none;
}
.user-card-date{
  font-size:11px;
  color:#94a3b8;
  margin-top:2px;
  font-family:ui-monospace,'SF Mono',Menlo,monospace;
  font-variant-numeric:tabular-nums;
}
.wear-block{margin-top:16px;padding:14px;background:#f8fafc;
  border:1px solid #e2e8f0;border-radius:4px}
.wear-head{display:flex;justify-content:space-between;align-items:center;
  font-size:11px;font-weight:600;color:#0f172a;
  text-transform:uppercase;letter-spacing:.06em;margin-bottom:10px}
.wear-pct{font-family:ui-monospace,'SF Mono',Menlo,monospace;
  font-variant-numeric:tabular-nums;font-size:12px}
.wear-pct.wear-ok{color:#15803d}
.wear-pct.wear-warn{color:#a16207}
.wear-pct.wear-danger{color:#b91c1c}
.wear-row{display:flex;justify-content:space-between;font-size:11px;
  color:#64748b;margin-top:6px;
  font-family:ui-monospace,'SF Mono',Menlo,monospace;
  font-variant-numeric:tabular-nums}
.wear-actions{display:flex;gap:6px;margin-top:12px;flex-wrap:wrap}
.wear-btn{padding:6px 12px;background:#fff;border:1px solid #e2e8f0;
  border-radius:4px;font-size:11px;font-weight:500;cursor:pointer;
  color:#334155;transition:all .12s;font-family:inherit;
  letter-spacing:.02em}
.wear-btn:hover{background:#0f172a;color:#fff;border-color:#0f172a}
.wear-btn-reset{color:#b91c1c;border-color:#fecaca}
.wear-btn-reset:hover{background:#fef2f2;color:#b91c1c;border-color:#f87171}
.wear-warning{margin-top:10px;padding:8px 10px;background:#fef2f2;
  border:1px solid #fecaca;border-radius:4px;font-size:12px;
  color:#b91c1c;line-height:1.4}
  /* ============ СИГНАЛЬНЫЙ ПУТЬ ============ */
.signal-chain{
  background:#fff;
  border:1px solid #e2e8f0;
  border-radius:6px;
  padding:18px 20px;
  margin-bottom:20px;
}
.signal-chain-title{
  font-size:11px;
  color:#94a3b8;
  text-transform:uppercase;
  letter-spacing:.08em;
  font-weight:600;
  margin-bottom:14px;
}
.signal-chain-flow{
  display:flex;
  align-items:center;
  flex-wrap:wrap;
  gap:10px;
}
.signal-node{
  display:flex;
  flex-direction:column;
  align-items:center;
  justify-content:center;
  gap:4px;
  padding:12px 14px;
  min-width:110px;
  max-width:150px;
  background:#f8fafc;
  border:1px solid #e2e8f0;
  border-radius:6px;
  text-decoration:none;
  color:#0f172a;
  transition:all .15s;
  cursor:pointer;
}
.signal-node:hover{
  background:#fff;
  border-color:#0f172a;
  transform:translateY(-2px);
  box-shadow:0 4px 12px rgba(15,23,42,.08);
}
.signal-icon{
  font-size:24px;
  line-height:1;
  margin-bottom:2px;
}
.signal-brand{
  font-size:10px;
  color:#64748b;
  font-weight:600;
  text-transform:uppercase;
  letter-spacing:.04em;
  text-align:center;
  overflow:hidden;
  text-overflow:ellipsis;
  white-space:nowrap;
  max-width:100%;
}
.signal-model{
  font-size:12px;
  color:#0f172a;
  font-weight:600;
  text-align:center;
  line-height:1.25;
  overflow:hidden;
  text-overflow:ellipsis;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  max-width:100%;
}
.signal-arrow{
  color:#94a3b8;
  font-size:18px;
  font-weight:300;
  flex:none;
  user-select:none;
}
@media (max-width:640px){
  .signal-chain-flow{
    flex-direction:column;
    align-items:stretch;
    gap:6px;
  }
  .signal-node{
    flex-direction:row;
    justify-content:flex-start;
    gap:12px;
    max-width:none;
    min-width:0;
    padding:10px 14px;
    text-align:left;
  }
  .signal-icon{
    font-size:20px;
    margin:0;
    flex:none;
  }
  .signal-brand{
    text-align:left;
    display:inline;
    white-space:normal;
  }
  .signal-model{
    text-align:left;
    -webkit-line-clamp:1;
  }
  .signal-arrow{
    text-align:center;
    transform:rotate(90deg);
    font-size:16px;
    padding:2px 0;
  }
}
/* ============ БЛОК ДРУЗЕЙ В ПРОФИЛЕ (компактный) ============ */
.friends-preview{
  background:#fff;border-radius:6px;padding:14px 16px;margin-bottom:20px;
  border:1px solid #e2e8f0;
}
.friends-head{
  display:flex;align-items:center;gap:8px;margin-bottom:10px;
  font-size:11px;font-weight:600;color:#64748b;
  letter-spacing:.08em;text-transform:uppercase;
  flex-wrap:wrap;
}
.friends-head .count{
  background:#f1f5f9;color:#475569;padding:1px 7px;border-radius:3px;
  font-size:10px;font-weight:600;border:1px solid #e2e8f0;
  letter-spacing:.04em;text-transform:none;
}
.friends-grid{
  display:flex;flex-wrap:wrap;gap:6px;
}
.friend-card{
  display:inline-flex;align-items:center;gap:6px;
  padding:4px 10px 4px 4px;
  border:1px solid #e2e8f0;
  border-radius:100px;
  background:#fff;
  text-decoration:none;
  color:#0f172a;
  transition:all .12s;
  max-width:200px;
}
.friend-card:hover{
  border-color:#0f172a;
  background:#f8fafc;
}
.friend-card .fc-av{
  width:22px;height:22px;flex:none;border-radius:50%;
  background:#0f172a;color:#fff;
  display:flex;align-items:center;justify-content:center;
  font-size:10px;font-weight:600;letter-spacing:-.02em;
}
.friend-card .fc-name{
  font-size:12px;font-weight:500;color:#0f172a;
  overflow:hidden;text-overflow:ellipsis;white-space:nowrap;
  min-width:0;
}
.friend-card .fc-admin{
  font-size:8px;font-weight:600;text-transform:uppercase;
  letter-spacing:.06em;padding:1px 4px;border-radius:2px;
  background:#fffbeb;color:#a16207;border:1px solid #fde68a;
  flex:none;
}
.friends-empty{
  background:#fff;border-radius:6px;padding:12px 16px;margin-bottom:20px;
  border:1px solid #e2e8f0;display:flex;align-items:center;gap:12px;
  font-size:12px;color:#64748b;
}
.friends-empty a{
  color:#0f172a;text-decoration:none;font-weight:500;
  margin-left:auto;font-size:11px;padding:5px 10px;
  border:1px solid #e2e8f0;border-radius:3px;transition:all .12s;
  letter-spacing:.02em;white-space:nowrap;
}
.friends-empty a:hover{background:#f8fafc;border-color:#94a3b8}

@media (max-width:640px){
  .friends-preview{padding:12px 14px}
  .friend-card{padding:3px 8px 3px 3px;max-width:150px}
  .friend-card .fc-av{width:20px;height:20px;font-size:9px}
  .friend-card .fc-name{font-size:11px}
  .friends-empty{padding:10px 12px;font-size:11px}
}
@media (max-width:640px){
  .wish-actions{
    flex-basis:100%;
    justify-content:flex-end;
    margin-top:8px;
    padding-top:8px;
    border-top:1px solid #f1f5f9;
  }
  .wish-actions button,
  .wish-actions a{
    flex:1;
    text-align:center;
    padding:8px 6px;
    font-size:11px;
  }
}
/* ============ КОМПАКТНЫЕ ФИЛЬТРЫ В ПРОФИЛЕ ============ */
.filters-bar {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin-bottom: 16px;
}

.artist-filter {
  display: flex;
  align-items: center;
  gap: 8px;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 4px;
  padding: 2px 4px 2px 10px;
  height: 33px; /* подгоняем под высоту кнопок */
  box-sizing: border-box;
}

.sort-filter {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.sort-filter .filter-label {
  font-size: 11px;
  color: #94a3b8;
  text-transform: uppercase;
  letter-spacing: .08em;
  font-weight: 600;
  white-space: nowrap;
  margin-right: 2px;
}
.sort-filter a {
  padding: 5px 10px;
  background: #fff;
  border: 1px solid #e2e8f0;
  border-radius: 4px;
  color: #334155;
  text-decoration: none;
  font-size: 12px;
  font-weight: 500;
  transition: all .12s;
  white-space: nowrap;
}
.sort-filter a:hover { border-color: #94a3b8; }
.sort-filter a.active {
  background: #0f172a;
  color: #fff;
  border-color: #0f172a;
}

.artist-clear {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: 3px;
  background: #fef2f2;
  color: #b91c1c;
  text-decoration: none;
  font-size: 11px;
  font-weight: 600;
  transition: background .12s;
}

.artist-clear:hover {
  background: #fecaca;
}

@media (max-width: 640px) {
  .filters-bar {
    gap: 8px;
  }
  .artist-filter {
    flex-basis: 100%; /* на мобильных переносим на новую строку */
    justify-content: space-between;
  }
  .artist-filter select {
    max-width: none;
    flex: 1;
  }
}
/* ============ ПОСЛЕДНИЕ ИЗ БЛОГА (главная) ============ */
.latest-blog-block{
  margin-top:28px;
  background:#fff;
  border:1px solid #e2e8f0;
  border-radius:6px;
  padding:20px;
}
.latest-blog-title{
  font-size:12px;
  font-weight:600;
  color:#0f172a;
  text-transform:uppercase;
  letter-spacing:.08em;
  margin-bottom:16px;
  display:flex;
  align-items:center;
  gap:8px;
}
.latest-blog-all{
  margin-left:auto;
  font-size:11px;
  font-weight:500;
  color:#334155;
  text-decoration:none;
  text-transform:none;
  letter-spacing:.02em;
  padding:4px 10px;
  border-radius:3px;
  border:1px solid transparent;
  transition:all .12s;
}
.latest-blog-all:hover{
  background:#f8fafc;
  border-color:#e2e8f0;
  color:#0f172a;
}
.latest-blog-grid{
  display:grid;
  grid-template-columns:repeat(auto-fill, minmax(220px, 1fr));
  gap:12px;
}
.latest-blog-card{
  display:flex;
  gap:12px;
  padding:10px;
  border:1px solid #e2e8f0;
  border-radius:6px;
  background:#f8fafc;
  text-decoration:none;
  color:#0f172a;
  transition:all .12s;
  align-items:flex-start;
  min-width:0;
}
.latest-blog-card:hover{
  background:#fff;
  border-color:#94a3b8;
  transform:translateY(-1px);
}
.latest-blog-cover{
  width:64px;
  height:64px;
  flex:none;
  border-radius:4px;
  overflow:hidden;
  background:#f1f5f9;
  display:flex;
  align-items:center;
  justify-content:center;
  border:1px solid #e2e8f0;
}
.latest-blog-cover img{
  width:100%;
  height:100%;
  object-fit:cover;
  display:block;
}
.latest-blog-emoji{
  font-size:24px;
  color:#cbd5e1;
  line-height:1;
}
.latest-blog-info{
  min-width:0;
  flex:1;
  display:flex;
  flex-direction:column;
  gap:2px;
}
.latest-blog-post-title{
  font-size:13px;
  font-weight:600;
  color:#0f172a;
  line-height:1.3;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
  word-break:break-word;
}
.latest-blog-excerpt{
  font-size:11px;
  color:#64748b;
  line-height:1.4;
  display:-webkit-box;
  -webkit-line-clamp:2;
  -webkit-box-orient:vertical;
  overflow:hidden;
}
.latest-blog-meta{
  font-size:10px;
  color:#94a3b8;
  margin-top:4px;
  display:flex;
  gap:8px;
  flex-wrap:wrap;
  font-variant-numeric:tabular-nums;
  letter-spacing:.02em;
}
.latest-blog-author{ color:#334155; font-weight:500; }
.latest-blog-views{ color:#94a3b8; }

@media (max-width:640px){
  .latest-blog-block{ padding:14px; }
  .latest-blog-grid{
    grid-template-columns:1fr;
    gap:8px;
  }
  .latest-blog-cover{ width:56px; height:56px; }
  .latest-blog-post-title{ font-size:12px; }
}
/* ============ ЛАЙТБОКС (общий) ============ */
.lightbox{
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.92);
  z-index: 9999;
  display: none;
  align-items: center;
  justify-content: center;
  padding: 24px;
  cursor: zoom-out;
  opacity: 0;
  transition: opacity .2s ease;
}
.lightbox.show{
  display: flex;
  opacity: 1;
}
.lightbox-img{
  max-width: 100%;
  max-height: 100%;
  object-fit: contain;
  border-radius: 4px;
  box-shadow: 0 8px 40px rgba(0,0,0,.6);
  cursor: default;
  user-select: none;
  transform: scale(.94);
  transition: transform .2s ease;
}
.lightbox.show .lightbox-img{
  transform: scale(1);
}
.lightbox-close{
  position: absolute;
  top: 16px;
  right: 16px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  border: none;
  background: #fff;
  color: #0f172a;
  font-size: 22px;
  font-weight: 600;
  line-height: 1;
  cursor: pointer;
  padding: 0;
  font-family: inherit;
  transition: background .12s, transform .12s;
  z-index: 10;              /* ← добавить эту строку */
}
.lightbox-close:hover{
  background: #f1f5f9;
  transform: scale(1.06);
}
@media (max-width: 640px){
  .lightbox{
    padding: 64px 16px 32px;     /* сверху много места под крестик, снизу тоже отступ */
  }
  .lightbox-img{
    max-width: 100%;
    max-height: calc(100dvh - 140px);   /* картинка заметно меньше экрана */
  }
  .lightbox-close{
    top: 12px;
    right: 12px;
    width: 48px;                 /* палец точно попадёт */
    height: 48px;
    font-size: 22px;
    z-index: 10;
  }
}
.qr-btn{
  background:#f1f5f9;color:#0f172a;border:1px solid #e2e8f0;
  padding:4px 10px;border-radius:4px;font-size:11px;font-weight:600;
  cursor:pointer;font-family:inherit;letter-spacing:.04em;
  transition:all .12s;text-transform:none;
}
.qr-btn:hover{background:#0f172a;color:#fff;border-color:#0f172a;}

.qr-modal{max-width:380px;}
.qr-box{
  position:relative;display:flex;align-items:center;justify-content:center;
  background:#fff;border:1px solid #e2e8f0;border-radius:6px;
  padding:16px;margin-bottom:14px;min-height:312px;
}
#qrCanvas{border-radius:4px;display:block;}
.qr-loading{
  position:absolute;inset:0;display:flex;align-items:center;justify-content:center;
  color:#94a3b8;font-size:13px;
}
.qr-url{display:flex;gap:6px;margin-bottom:14px;}
.qr-url input{
  flex:1;padding:8px 10px;border:1px solid #e2e8f0;border-radius:4px;
  font-size:12px;font-family:ui-monospace,'SF Mono',Menlo,monospace;
  color:#334155;background:#f8fafc;
}
.qr-url button{
  padding:8px 12px;background:#fff;border:1px solid #e2e8f0;border-radius:4px;
  cursor:pointer;font-size:14px;transition:all .12s;
}
.qr-url button:hover{background:#0f172a;color:#fff;border-color:#0f172a;}
/* ===== Кнопка «Пожаловаться» в углу модалки ===== */
.modal-report{
  position:absolute;
  top:12px;
  right:52px;
  width:32px;
  height:32px;
  border-radius:50%;
  background:#f8fafc;
  border:1px solid #e2e8f0;
  color:#94a3b8;
  font-size:14px;
  line-height:1;
  cursor:pointer;
  display:flex;
  align-items:center;
  justify-content:center;
  transition:all .12s;
  padding:0;
  font-family:inherit;
  z-index:10;
}
.modal-report:hover{
  background:#fef2f2;
  border-color:#fecaca;
  color:#b91c1c;
}
@media (max-width:640px){
  .modal-report{
    top:8px;
    right:48px;
    width:36px;
    height:36px;
    font-size:15px;
  }
}


/* Исправление: значок предупреждения и исполнитель всегда в одной строке */
.artist-row{
  display:flex;
  align-items:center;
  justify-content:flex-start;
  gap:4px;
  width:100%;
  min-width:0;
  flex-wrap:nowrap;
}
.artist-row .fa-badge{
  display:inline-flex;
  align-items:center;
  flex:0 0 auto;
  white-space:nowrap;
  line-height:1.3;
}
.artist-row .artist{
  display:block;
  flex:1 1 auto;
  min-width:0;
  max-width:100%;
  white-space:nowrap;
  overflow:hidden;
  text-overflow:ellipsis;
  word-break:normal;
  overflow-wrap:normal;
}
.fa-notice {
  background: #fffbeb;
  border: 1px solid #fde68a;
  border-radius: 4px;
  padding: 10px 12px;
  margin-top: 14px;
  color: #92400e;
  font-size: 12px;
  line-height: 1.6;
}
.fa-notice strong {
  color: #78350f;
  font-weight: 600;
}