/* Личный кабинет МузПо — перенесено из E:\CODE\Audiopoetry\index.html
   дословно (страницы входа/регистрации, избранного, баланса). Требует
   public.css (токены, .grid/.card, .site-footer, топбар) — подключать вместе. */

/* ---------- формы (общие: вход/регистрация) ---------- */
.field{ margin-bottom:14px; }
.field:last-child{ margin-bottom:0; }
.field label{ display:block; font-size:12.5px; font-weight:700; margin-bottom:7px; }
.input-wrap{ position:relative; }
.field input{ width:100%; height:44px; border:1px solid var(--line); background:#fff; border-radius:12px; padding:0 14px; outline:none; font-size:14px; }
.field input:focus{ border-color:rgba(47,103,82,.5); box-shadow:0 0 0 3px rgba(47,103,82,.07); }
.field-hint{ font-size:11.5px; color:var(--muted); line-height:1.4; margin-top:6px; }
.error-text{ font-size:11.5px; color:var(--danger); line-height:1.4; margin-top:6px; display:none; }
.error-text.show{ display:block; }
.field input.error{ border-color:rgba(169,68,66,.6); box-shadow:0 0 0 3px rgba(169,68,66,.06); }
.password-wrap{ position:relative; }
.password-wrap input{ padding-right:44px; }
.toggle-pass{ position:absolute; right:5px; top:50%; transform:translateY(-50%); width:34px; height:34px; border:0; background:transparent; border-radius:8px; color:var(--muted); cursor:pointer; display:grid; place-items:center; }
.toggle-pass:hover{ background:var(--paper); color:var(--ink); }

/* ---------- auth pages (полноэкранные, свой минимальный header) ---------- */
body.auth-mode main{ padding-block:0; }
.auth-shell{ min-height:100vh; display:grid; grid-template-rows:auto 1fr auto; }
.auth-shell a{ color:var(--green); text-decoration:none; }
.auth-shell a:hover{ text-decoration:underline; }
.auth-head{ height:72px; display:flex; align-items:center; justify-content:space-between; border-bottom:1px solid rgba(16,33,62,.08); }
.auth-head .brand{ text-decoration:none; cursor:pointer; border:0; background:none; padding:0; }
.auth-back-link{ font-size:13.5px; color:var(--muted); background:none; border:0; cursor:pointer; padding:0; font-family:inherit; text-decoration:none; }
.auth-back-link:hover{ color:var(--ink); }
.auth-main{ display:grid; place-items:center; padding:44px 0 54px; }
.auth-card{ width:min(470px,100%); background:rgba(255,254,250,.97); border:1px solid rgba(16,33,62,.07); border-radius:24px; box-shadow:0 8px 28px rgba(25,39,56,.07); padding:30px; }
.auth-card h1{ font:700 40px/1.05 "Fraunces",Georgia,serif; letter-spacing:-.02em; margin:0 0 10px; }
.auth-card .lead{ margin:0 0 24px; color:var(--muted); font-size:14.5px; line-height:1.5; }
.auth-form{ display:flex; flex-direction:column; gap:15px; }
.row-between{ display:flex; align-items:center; justify-content:space-between; gap:12px; }
.forgot{ font-size:12.5px; background:none; border:0; cursor:pointer; padding:0; font-family:inherit; color:var(--green); }
.auth-card .primary{ width:100%; height:46px; border:0; border-radius:12px; background:var(--green); color:#fff; font-weight:700; cursor:pointer; box-shadow:0 6px 16px rgba(47,103,82,.14); }
.auth-card .primary:hover{ filter:brightness(.98); transform:translateY(-1px); }
.auth-switch{ margin-top:20px; padding-top:18px; border-top:1px solid var(--line); text-align:center; color:var(--muted); font-size:13.5px; }
.auth-switch a{ font-weight:700; cursor:pointer; }
.forgot-pass-link{ display:inline-block; margin-top:8px; font-size:12.5px; color:var(--muted); font-weight:600; }
.forgot-pass-link:hover{ color:var(--green); }
.checkbox-row{ display:grid; grid-template-columns:20px 1fr; gap:10px; align-items:start; margin-top:1px; cursor:pointer; }
.checkbox-row input{ appearance:none; -webkit-appearance:none; width:18px; height:18px; margin:1px 0 0; border:1px solid #cfc8ba; border-radius:5px; background:#fff; display:grid; place-items:center; cursor:pointer; }
.checkbox-row input:checked{ background:var(--green); border-color:var(--green); }
.checkbox-row input:checked::after{ content:""; width:8px; height:4px; border-left:2px solid #fff; border-bottom:2px solid #fff; transform:translateY(-1px) rotate(-45deg); }
.checkbox-copy{ font-size:12.5px; line-height:1.5; color:var(--muted); }
.checkbox-copy a{ font-weight:600; }
.auth-footer{ display:flex; justify-content:space-between; gap:16px; padding:20px 4px 24px; color:var(--muted); font-size:12px; }
.auth-state[hidden]{ display:none; }
.code-note{ background:var(--green-soft); border:1px solid rgba(47,103,82,.13); border-radius:13px; padding:12px 13px; color:var(--ink-soft); font-size:12.5px; line-height:1.5; margin-bottom:18px; }
.auth-secondary{ width:100%; height:43px; border:1px solid var(--line); border-radius:11px; background:#fff; color:var(--ink-soft); font-weight:600; cursor:pointer; margin-top:8px; }
.auth-secondary:hover{ border-color:rgba(47,103,82,.35); }
.code-boxes{ display:grid; grid-template-columns:repeat(6,1fr); gap:8px; margin-top:15px; }
.code-boxes input{ width:100%; height:48px; text-align:center; border:1px solid var(--line); border-radius:11px; background:#fff; font:600 18px/1 "IBM Plex Mono",monospace; outline:none; }
.code-boxes input:focus{ border-color:rgba(47,103,82,.5); box-shadow:0 0 0 3px rgba(47,103,82,.07); }
.resend{ margin-top:10px; font-size:12px; color:var(--muted); }
.resend button{ border:0; background:transparent; color:var(--green); padding:0; cursor:pointer; font-weight:600; }

/* ---------- личный кабинет: общая шапка страницы ---------- */
.page-head{ display:flex; align-items:flex-end; justify-content:space-between; gap:24px; margin:0 0 22px; padding:46px 4px 0; }
.page-head-copy{ max-width:820px; }
.page-head h1{ font-size:clamp(36px,4.2vw,54px); line-height:1.02; letter-spacing:-.025em; margin:0 0 10px; color:var(--ink); }
.page-head h1 span{ color:var(--gold); }
.page-head p{ margin:0; color:var(--muted); font-size:16px; line-height:1.55; max-width:760px; }
/* .search-wrap/.search-icon/.search — базовые правила теперь в public.css
   (общий компонент карточки/поиска), подключается на всех страницах вместе с app.css. */
.page-head .search-wrap{ width:min(440px,100%); flex:0 0 auto; }

.lib-state{ margin-top:26px; text-align:center; padding:56px 20px; background:var(--paper-raised); border:1px solid var(--line); border-radius:20px; color:var(--muted); }
.lib-state strong{ display:block; color:var(--ink); font-family:"Fraunces",serif; font-weight:600; font-size:23px; margin-bottom:6px; }
.lib-state-icon{ width:56px; height:56px; border-radius:50%; margin:0 auto 14px; display:grid; place-items:center; background:var(--gold-soft); color:var(--gold); font-size:26px; }

/* ---------- баланс ---------- */
.settings-stack{ display:flex; flex-direction:column; gap:16px; }
.settings-card{ background:rgba(255,254,250,.96); border:1px solid rgba(16,33,62,.07); border-radius:20px; box-shadow:0 5px 20px rgba(25,39,56,.045); padding:22px; }
.balance-hero{
  background:linear-gradient(135deg,rgba(255,254,250,.98),rgba(250,234,209,.48));
  border:1px solid rgba(211,130,18,.16); border-radius:22px; box-shadow:0 5px 20px rgba(25,39,56,.055);
  padding:24px 26px; display:flex; justify-content:space-between; align-items:flex-end; gap:20px;
}
.balance-label{ font-size:12px; color:var(--muted); margin-bottom:6px; }
.balance-value{ font:700 clamp(42px,6vw,62px)/1 "Fraunces",Georgia,serif; letter-spacing:-.025em; }
.balance-value span{ color:var(--gold); }
.balance-caption{ color:var(--muted); font-size:12.5px; line-height:1.45; max-width:320px; text-align:right; }
.payment-result-card{ text-align:center; padding:46px 24px; max-width:480px; margin:0 auto; }
.payment-result-icon{ width:64px; height:64px; border-radius:50%; display:grid; place-items:center; font-size:28px; font-weight:700; margin:0 auto 18px; }
.payment-result-success .payment-result-icon{ background:var(--green-soft); color:var(--green); }
.payment-result-failed .payment-result-icon{ background:var(--danger-soft); color:var(--danger); }
.payment-result-text{ color:var(--ink-soft); font-size:14.5px; line-height:1.6; margin:0 0 24px; }
.payment-result-actions{ display:flex; gap:10px; justify-content:center; flex-wrap:wrap; }
.card-head{ margin-bottom:18px; }
.card-head h2{ font:700 27px/1.15 "Fraunces",Georgia,serif; margin:0 0 6px; }
.card-head p{ margin:0; color:var(--muted); font-size:13px; line-height:1.5; }
.amount-grid{ display:grid; grid-template-columns:repeat(5,minmax(0,1fr)); gap:9px; margin-bottom:14px; }
.amount-btn{ height:46px; border:1px solid var(--line); background:#fff; border-radius:12px; cursor:pointer; font-weight:600; color:var(--ink-soft); }
.amount-btn:hover{ border-color:rgba(47,103,82,.38); }
.amount-btn.active{ background:var(--green); border-color:var(--green); color:#fff; box-shadow:0 5px 14px rgba(47,103,82,.14); }
.custom-wrap{ display:grid; grid-template-columns:minmax(0,1fr) 160px; gap:10px; align-items:end; }
.custom-wrap .input-wrap input{ padding-right:42px; }
.currency{ position:absolute; right:14px; top:50%; transform:translateY(-50%); color:var(--muted); font-size:13px; }
.topup-btn{ height:46px; border:0; border-radius:12px; background:var(--green); color:#fff; font-weight:700; cursor:pointer; box-shadow:0 6px 16px rgba(47,103,82,.14); }
.topup-btn:hover{ filter:brightness(.98); transform:translateY(-1px); }
.history-card{ padding:0; overflow:hidden; }
.history-head{ padding:22px 22px 16px; border-bottom:1px solid var(--line); }
.history-head h2{ font:700 27px/1.15 "Fraunces",Georgia,serif; margin:0 0 6px; }
.history-head p{ margin:0; color:var(--muted); font-size:13px; }
.history-table{ width:100%; border-collapse:collapse; }
.history-table th,.history-table td{ padding:15px 22px; text-align:left; border-bottom:1px solid var(--line); }
.history-table th{ font-size:11.5px; text-transform:uppercase; letter-spacing:.06em; color:var(--muted); font-weight:700; background:rgba(248,246,240,.55); }
.history-table tr:last-child td{ border-bottom:0; }
.history-date{ font-size:13.5px; color:var(--ink-soft); }
.history-amount{ font-family:"IBM Plex Mono",monospace; font-weight:600; color:var(--green); white-space:nowrap; }
.history-empty td{ color:var(--muted); font-size:13.5px; }

/* ---------- настройки аккаунта ---------- */
.btn.danger{ background:var(--danger); color:#fff; font-weight:600; }
.form-actions{ display:flex; align-items:center; gap:8px; margin-top:15px; }

.settings-row{ display:grid; grid-template-columns:230px minmax(0,1fr); gap:30px; align-items:start; }
.section-copy h2{ font:700 24px/1.15 "Fraunces",Georgia,serif; margin:0 0 7px; }
.section-copy p{ margin:0; color:var(--muted); font-size:13px; line-height:1.5; }
.section-form{ min-width:0; }

.profile-editor{ display:grid; grid-template-columns:118px minmax(0,1fr); gap:20px; align-items:center; }
.avatar-box{ display:flex; flex-direction:column; align-items:center; gap:10px; }
.avatar{ width:104px; height:104px; border-radius:50%; overflow:hidden; background:linear-gradient(145deg,#e6efe9,#f7e8cf); border:1px solid var(--line); display:grid; place-items:center; color:var(--green); font:700 34px/1 "Fraunces",Georgia,serif; box-shadow:0 5px 16px rgba(25,39,56,.06); }
.avatar img{ width:100%; height:100%; object-fit:cover; display:block; }
.avatar-actions{ display:flex; flex-direction:column; gap:6px; width:100%; }
.upload-label{ position:relative; overflow:hidden; text-align:center; border:1px solid var(--line); background:#fff; border-radius:10px; padding:8px 10px; font-size:12px; font-weight:600; color:var(--ink-soft); cursor:pointer; min-height:40px; display:flex; align-items:center; justify-content:center; }
.upload-label:hover{ border-color:rgba(47,103,82,.38); color:var(--green); }
.upload-label input{ position:absolute; inset:0; opacity:0; cursor:pointer; }
.remove-photo{ border:0; background:transparent; color:var(--muted); font-size:11.5px; padding:3px; cursor:pointer; min-height:40px; }
.remove-photo:hover{ color:var(--danger); }
.photo-help{ font-size:11.5px; color:var(--muted); line-height:1.45; margin-top:10px; }

.account-line{ display:flex; align-items:center; justify-content:space-between; gap:16px; padding:13px 0; border-bottom:1px solid var(--line); }
.account-line:first-child{ padding-top:0; }
.account-line:last-child{ border-bottom:0; padding-bottom:0; }
.account-value{ min-width:0; }
.account-label{ font-size:11.5px; color:var(--muted); margin-bottom:3px; }
.account-text{ font-size:14px; color:var(--ink); overflow:hidden; text-overflow:ellipsis; }
.inline-btn{ white-space:nowrap; }

.password-grid{ display:grid; grid-template-columns:1fr 1fr; gap:12px; }
.password-grid .full{ grid-column:1/-1; }

.danger-card{ border-color:rgba(169,68,66,.18); background:rgba(255,253,251,.96); }
.danger-card .section-copy h2{ color:#7f3432; }
.danger-panel{ display:flex; align-items:center; justify-content:space-between; gap:24px; padding:15px 16px; border:1px solid rgba(169,68,66,.16); background:var(--danger-soft); border-radius:14px; }
.danger-panel strong{ display:block; font-size:14px; margin-bottom:4px; }
.danger-panel span{ display:block; color:#7c6462; font-size:12px; line-height:1.45; }
.delete-warning{ background:var(--danger-soft); border:1px solid rgba(169,68,66,.15); border-radius:12px; padding:12px 13px; color:#795a58; font-size:12.5px; line-height:1.5; margin-bottom:14px; }

/* ---------- модальные окна (общие) ---------- */
body.modal-open{ overflow:hidden; }
.my-modal-backdrop{ position:fixed; inset:0; z-index:100; background:rgba(16,33,62,.28); backdrop-filter:blur(3px); display:grid; place-items:center; padding:20px; }
.my-modal{ width:min(720px,100%); max-height:min(88vh,850px); overflow:auto; background:var(--paper-raised); border:1px solid rgba(16,33,62,.08); border-radius:22px; box-shadow:0 24px 70px rgba(20,31,47,.22); }
.my-modal-head{ position:sticky; top:0; z-index:2; background:rgba(255,254,250,.96); backdrop-filter:blur(8px); display:flex; align-items:flex-start; justify-content:space-between; gap:20px; padding:20px 22px 16px; border-bottom:1px solid var(--line); }
.my-modal-head h2{ font-size:27px; margin-bottom:4px; }
.my-modal-head p{ margin:0; color:var(--muted); font-size:12.5px; }
.close-btn{ position:relative; width:40px; min-width:40px; height:40px; min-height:40px; aspect-ratio:1/1; flex:0 0 40px; padding:0; margin:0; border:1px solid var(--line); background:#fff; border-radius:50%; color:var(--muted); -webkit-appearance:none; appearance:none; cursor:pointer; }
.close-btn::before,.close-btn::after{ content:""; position:absolute; left:50%; top:50%; width:12px; height:1.5px; border-radius:999px; background:currentColor; transform-origin:center; }
.close-btn::before{ transform:translate(-50%,-50%) rotate(45deg); }
.close-btn::after{ transform:translate(-50%,-50%) rotate(-45deg); }
.close-btn:hover{ border-color:rgba(16,33,62,.18); color:var(--ink-soft); background:var(--paper); }
.my-modal-body{ padding:20px 22px 22px; }
.my-modal-actions{ display:flex; align-items:center; justify-content:flex-end; gap:8px; margin-top:20px; padding-top:16px; border-top:1px solid var(--line); }
.my-modal-actions .btn{ min-height:40px; }

.my-toast{ position:fixed; right:22px; bottom:22px; z-index:200; background:var(--ink); color:#fff; border-radius:12px; padding:11px 14px; font-size:13px; box-shadow:0 14px 36px rgba(16,33,62,.2); transform:translateY(20px); opacity:0; pointer-events:none; transition:.2s ease; }
.my-toast.show{ transform:none; opacity:1; }

@media(max-width:900px){
  .page-head{ align-items:flex-start; flex-direction:column; padding-top:32px; }
  .balance-hero{ align-items:flex-start; flex-direction:column; }
  .balance-caption{ text-align:left; }
  .settings-row{ grid-template-columns:1fr; gap:18px; }
  .section-copy{ max-width:620px; }
}
@media(max-width:620px){
  .page-head{ padding-top:24px; }
  .settings-card{ padding:17px; border-radius:17px; }
  .balance-hero{ padding:20px; border-radius:18px; }
  .balance-value{ font-size:48px; }
  .amount-grid{ grid-template-columns:repeat(2,minmax(0,1fr)); }
  .amount-grid .amount-btn:last-child{ grid-column:1/-1; }
  .custom-wrap{ grid-template-columns:1fr; }
  .topup-btn{ width:100%; }
  .history-table th,.history-table td{ padding:13px 16px; }
  .auth-head{ height:64px; }
  .auth-main{ padding:28px 0 36px; align-items:start; }
  .auth-card{ padding:22px 18px; border-radius:19px; }
  .code-boxes{ gap:5px; }
  .code-boxes input{ height:44px; }
  .profile-editor{ grid-template-columns:1fr; align-items:start; }
  .avatar-box{ align-items:flex-start; }
  .avatar-actions{ width:170px; }
  .photo-help{ max-width:340px; }
  .password-grid{ grid-template-columns:1fr; }
  .password-grid .full{ grid-column:auto; }
  .account-line{ align-items:flex-start; flex-direction:column; }
  .danger-panel{ align-items:flex-start; flex-direction:column; }
  .danger-panel .btn{ width:100%; }
  .my-modal-head{ padding:17px 17px 14px; }
  .my-modal-body{ padding:17px; }
  .my-modal-actions{ flex-direction:column-reverse; align-items:stretch; }
  .my-modal-actions .btn{ width:100%; }
}

/* ---------- мои песни ---------- */
.library-tools{ display:flex; align-items:center; justify-content:space-between; gap:16px; margin-bottom:16px; }
.library-tools .search-wrap{ min-width:290px; max-width:520px; flex:1; padding:0 16px; }
.library-tools .search{ padding:13px 0; }
.filters{ display:flex; align-items:center; gap:7px; overflow-x:auto; scrollbar-width:none; }
.filters::-webkit-scrollbar{ display:none; }
.filter{ border:1px solid var(--line); background:var(--paper-raised); border-radius:999px; padding:9px 13px; font-size:13px; color:var(--ink-soft); white-space:nowrap; cursor:pointer; }
.filter.active{ background:var(--green); border-color:var(--green); color:#fff; }

.song-list{ display:flex; flex-direction:column; gap:12px; }
.song-card{
  display:grid; grid-template-columns:104px minmax(0,1fr) auto; gap:17px; align-items:center;
  background:rgba(255,254,250,.97); border:1px solid rgba(16,33,62,.07); border-radius:18px; padding:11px 13px 11px 11px;
  box-shadow:0 5px 18px rgba(25,39,56,.05); transition:box-shadow .18s ease,border-color .18s ease,transform .18s ease;
}
.song-card:hover{ border-color:rgba(211,130,18,.42); box-shadow:0 9px 24px rgba(25,39,56,.08); transform:translateY(-1px); }
.song-cover{ width:104px; height:130px; border-radius:14px; position:relative; overflow:hidden; display:grid; place-items:center; background:#ddd; box-shadow:inset 0 0 0 1px rgba(16,33,62,.06); }
.song-cover img{ width:100%; height:100%; object-fit:cover; display:block; }
.song-cover::after{ content:""; position:absolute; inset:50% 0 0; background:linear-gradient(to top,rgba(11,29,48,.24),transparent); }
.song-audio{ display:none; }
.my-cover-a{ background:linear-gradient(160deg,#e6b35d 0 28%,#c9783f 29% 51%,#6f8d74 52% 73%,#66859a 74%); }
.my-cover-b{ background:linear-gradient(160deg,#dfe9ef 0 36%,#9fb8c8 37% 55%,#f0f0e6 56% 72%,#7d9a80 73%); }
.my-cover-c{ background:linear-gradient(155deg,#ccb892 0 31%,#7f9aa8 32% 55%,#536f84 56% 74%,#2f4e61 75%); }
.my-cover-d{ background:linear-gradient(160deg,#ead49a 0 30%,#b89072 31% 54%,#879a73 55% 72%,#536f61 73%); }
.my-cover-e{ background:linear-gradient(160deg,#34415e 0 34%,#243249 35% 56%,#6d5d55 57% 76%,#b79468 77%); }
.cover-label{ position:absolute; left:10px; right:10px; bottom:9px; z-index:2; color:#fff; font:600 12px/1.2 "Fraunces",Georgia,serif; text-shadow:0 1px 4px rgba(0,0,0,.24); white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.play-cover{ position:relative; z-index:3; width:40px; height:40px; border-radius:50%; border:1px solid rgba(255,255,255,.68); background:rgba(255,255,255,.9); color:var(--green); display:grid; place-items:center; box-shadow:0 4px 12px rgba(20,30,45,.12); cursor:pointer; flex-shrink:0; }
.play-cover:hover{ background:var(--green); color:#fff; border-color:var(--green); }
.play-cover svg{ display:block; margin-left:2px; }

.song-main{ min-width:0; align-self:stretch; display:flex; flex-direction:column; justify-content:center; padding:2px 0; }
.song-top{ display:flex; align-items:flex-start; justify-content:space-between; gap:16px; }
.song-title-wrap{ min-width:0; }
.song-title{ font:600 22px/1.15 "Fraunces",Georgia,serif; margin:0 0 6px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis; }
.song-meta{ display:flex; align-items:center; flex-wrap:wrap; gap:7px 12px; color:var(--muted); font-size:12.5px; }
.song-meta .dot::before{ content:"•"; margin-right:5px; color:#b7b1a5; }
.pub-status{ display:inline-flex; align-items:center; gap:7px; border-radius:999px; padding:6px 10px; font-size:11.5px; font-weight:600; white-space:nowrap; flex:0 0 auto; }
.pub-status::before{ content:""; width:7px; height:7px; border-radius:50%; background:currentColor; opacity:.85; }
.pub-status.public{ background:var(--green-soft); color:var(--green); }
.pub-status.private{ background:#f1eee7; color:#706f68; }
.pub-status.generating{ background:var(--gold-soft); color:var(--gold); }
.pub-status.failed{ background:var(--danger-soft); color:var(--danger); }
.expiry{ margin-top:10px; display:inline-flex; align-items:center; gap:7px; width:max-content; max-width:100%; font-size:12px; color:#8b672d; background:#fbf0dd; border-radius:999px; padding:6px 9px; }
.expiry.soon{ color:#9a4e34; background:#f8e6df; }
.generation-error-note{ margin-top:10px; padding:10px 12px; background:var(--danger-soft); color:#7f3432; border-radius:10px; font-size:12.5px; line-height:1.4; max-width:480px; }
.generation-notice-note{ margin-top:10px; padding:10px 12px; background:var(--green-soft); color:var(--green); border-radius:10px; font-size:12.5px; line-height:1.4; max-width:480px; }
.actions{ display:flex; align-items:center; justify-content:flex-end; gap:7px; flex-wrap:wrap; max-width:390px; }
.action{ height:40px; border:1px solid var(--line); background:#fff; border-radius:11px; padding:0 12px; display:inline-flex; align-items:center; gap:7px; font-size:12.5px; color:var(--ink-soft); white-space:nowrap; cursor:pointer; text-decoration:none; }
.action:hover{ border-color:rgba(47,103,82,.4); color:var(--green); background:#fdfefa; text-decoration:none; }
.action.primary{ background:var(--green); border-color:var(--green); color:#fff; font-weight:600; }
.action.primary:hover{ filter:brightness(.97); }
.action svg{ width:16px; height:16px; stroke:currentColor; fill:none; stroke-width:1.8; stroke-linecap:round; stroke-linejoin:round; }
.more-wrap{ position:relative; }
.more-action{ width:40px; padding:0; justify-content:center; font-size:20px; line-height:1; }
.more-menu{ position:absolute; right:0; top:calc(100% + 8px); z-index:35; min-width:190px; background:#fff; border:1px solid var(--line); border-radius:12px; box-shadow:0 14px 36px rgba(25,39,56,.15); padding:6px; }
.more-menu button{ width:100%; border:0; background:transparent; border-radius:8px; text-align:left; padding:9px 10px; font-size:13px; color:var(--ink-soft); cursor:pointer; min-height:40px; }
.more-menu button:hover{ background:var(--paper); color:var(--ink); }
.more-menu .danger{ color:var(--danger); }
.more-menu .danger:hover{ background:var(--danger-soft); color:var(--danger); }

.lib-state button{ border:0; background:var(--green); color:#fff; border-radius:999px; padding:11px 17px; font-weight:600; cursor:pointer; margin-top:6px; }
.lib-state.is-error{ color:var(--danger); }
.lib-state.is-error strong{ color:var(--danger); }
.lib-state.is-error button{ background:#fff; color:var(--danger); border:1px solid var(--danger); }

.skeleton-list{ display:flex; flex-direction:column; gap:12px; }
.skeleton-row{ display:grid; grid-template-columns:104px minmax(0,1fr); gap:17px; background:rgba(255,254,250,.97); border:1px solid rgba(16,33,62,.07); border-radius:18px; padding:11px 13px 11px 11px; height:152px; }
.skeleton-block{ border-radius:14px; background:linear-gradient(90deg,var(--line) 25%,#f2efe6 37%,var(--line) 63%); background-size:400% 100%; animation:skeletonShine 1.4s ease infinite; }
.skeleton-row .skeleton-block:first-child{ width:104px; height:130px; }
.skeleton-lines{ display:flex; flex-direction:column; gap:10px; padding:6px 0; }
.skeleton-lines .skeleton-block{ height:14px; }
.skeleton-lines .skeleton-block:nth-child(1){ width:46%; height:22px; }
.skeleton-lines .skeleton-block:nth-child(2){ width:70%; }
.skeleton-lines .skeleton-block:nth-child(3){ width:30%; }
@keyframes skeletonShine{ 0%{ background-position:100% 0; } 100%{ background-position:0 0; } }

/* ---------- мои песни: модалка «Оформление» ---------- */
.confirm-modal{ width:min(470px,100%); }
.confirm-modal .my-modal-body{ padding-top:18px; }
.confirm-modal p{ color:var(--muted); line-height:1.55; margin:0; }
.confirm-note{ margin-top:10px; padding:10px 12px; background:var(--gold-soft); color:var(--ink-soft); border-radius:10px; font-size:12.5px; line-height:1.4; }
.form-grid{ display:grid; grid-template-columns:210px minmax(0,1fr); gap:22px; }
.cover-editor{ display:flex; flex-direction:column; gap:10px; }
.cover-preview{ aspect-ratio:4/5; width:100%; border-radius:16px; overflow:hidden; background:linear-gradient(160deg,#d9c49b,#8aa08b 55%,#5f7e87); display:grid; place-items:center; position:relative; border:1px solid var(--line); }
.cover-preview img{ width:100%; height:100%; object-fit:cover; display:block; }
.cover-preview span{ font-family:"Fraunces",Georgia,serif; font-weight:600; color:#fff; text-align:center; padding:14px; text-shadow:0 1px 4px rgba(0,0,0,.18); }
.upload-btn{ position:relative; overflow:hidden; border:1px solid var(--line); background:#fff; border-radius:11px; padding:10px 12px; text-align:center; font-size:13px; font-weight:600; color:var(--ink-soft); cursor:pointer; min-height:40px; display:flex; align-items:center; justify-content:center; }
.upload-btn:hover{ border-color:rgba(47,103,82,.4); color:var(--green); }
.upload-btn input{ position:absolute; inset:0; opacity:0; cursor:pointer; }
.remove-cover-btn{ border:0; background:transparent; color:var(--danger); font-size:12.5px; font-weight:600; cursor:pointer; padding:6px 2px; min-height:40px; }
.remove-cover-btn:hover{ text-decoration:underline; }
.upload-help{ font-size:11.5px; color:var(--muted); line-height:1.45; }
.my-fields{ display:flex; flex-direction:column; gap:15px; }
.my-field label{ display:block; font-size:12.5px; font-weight:700; margin-bottom:7px; }
.my-field input,.my-field textarea{ width:100%; border:1px solid var(--line); background:#fff; border-radius:12px; padding:11px 13px; outline:none; font-size:13.5px; font-family:inherit; }
.my-field textarea{ min-height:112px; resize:vertical; line-height:1.5; }
.my-field input:focus,.my-field textarea:focus{ border-color:rgba(47,103,82,.52); box-shadow:0 0 0 3px rgba(47,103,82,.07); }
.counter{ text-align:right; margin-top:4px; font-size:11px; color:var(--muted); }

@media(max-width:1120px){
  .song-card{ grid-template-columns:96px minmax(0,1fr); }
  .song-cover{ width:96px; height:120px; }
  .actions{ grid-column:2; justify-content:flex-start; max-width:none; margin-top:-4px; }
}
@media(max-width:860px){
  .library-tools{ align-items:stretch; flex-direction:column; }
  .library-tools .search-wrap{ max-width:none; min-width:0; }
  .filters{ justify-content:flex-start; }
  .form-grid{ grid-template-columns:170px minmax(0,1fr); }
}
@media(max-width:620px){
  .song-card{ grid-template-columns:80px minmax(0,1fr); gap:12px; padding:10px; }
  .song-cover{ width:80px; height:100px; border-radius:12px; }
  .cover-label{ font-size:10px; }
  .song-title{ font-size:19px; }
  .song-top{ display:block; }
  .pub-status{ margin-top:7px; }
  .actions{ grid-column:1/-1; margin-top:2px; }
  .action{ flex:1; justify-content:center; }
  .more-action{ flex:0 0 40px; }
  .form-grid{ grid-template-columns:1fr; }
  .cover-editor{ max-width:240px; }
}
