/* Библиотека идей — дополнение к styles.css */
.lib-page { --req: #8b7cff; --mkt: #ffb547; }
.lib-page main { padding-bottom: 40px; }

.lib-hero { padding: calc(var(--header-h) + clamp(40px, 7vw, 80px)) 0 clamp(28px, 4vw, 44px); border-bottom: 1px solid var(--line); }
.lib-hero h1 { max-width: 16ch; }
.lib-hero h1 .hl { color: var(--acid); }
.lib-hero .sub { font-size: clamp(17px, 1.6vw, 20px); color: var(--muted); max-width: 720px; margin-top: 18px; }
.lib-kinds { display: grid; gap: 12px; margin-top: 26px; max-width: 900px; }
@media (min-width: 700px) { .lib-kinds { grid-template-columns: 1fr 1fr; } }
.lib-kind { padding: 16px 18px; border-radius: 12px; background: var(--panel); border: 1px solid var(--line); border-left: 4px solid var(--req); }
.lib-kind.market { border-left-color: var(--mkt); }
.lib-kind b { display: block; font-family: var(--font-display); font-size: 15px; margin-bottom: 6px; }
.lib-kind span { color: var(--muted); font-size: 14.5px; }
.lib-mode { display: inline-flex; align-items: center; gap: 10px; font-family: var(--font-mono); font-size: 12.5px; padding: 7px 14px 7px 10px; border-radius: 999px; border: 1px solid var(--acid); color: var(--acid); margin-bottom: 18px; }
.lib-mode .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--acid); }
.lib-mode.bad { border-color: var(--coral); color: var(--coral); }
.lib-mode.bad .dot { background: var(--coral); }

.lib-list { padding: clamp(28px, 4vw, 48px) 0; }
.lib-toolbar { display: flex; flex-wrap: wrap; gap: 10px 24px; margin-bottom: 22px; }
.lib-filters { display: flex; flex-wrap: wrap; gap: 8px; }

.lib-grid { display: grid; gap: 16px; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); }
.lib-card {
  text-align: left; padding: 0; border-radius: 14px; overflow: hidden;
  background: var(--panel); border: 1px solid var(--line);
  display: flex; flex-direction: column;
  transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
}
.lib-card:hover { transform: translateY(-4px); border-color: var(--line-strong); box-shadow: 0 16px 40px rgba(0,0,0,.4); }
.lc-cover {
  position: relative; height: 112px; display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, rgba(139,124,255,.35), rgba(139,124,255,.05));
}
.lib-card.market .lc-cover, .lm-head.market { background: linear-gradient(135deg, rgba(255,181,71,.32), rgba(255,181,71,.04)); }
.lc-logo { width: 64px; height: 64px; border-radius: 14px; background: rgba(10,12,16,.75); display: grid; place-items: center; overflow: hidden; border: 1px solid var(--line-strong); }
.lc-logo img { width: 100%; height: 100%; object-fit: contain; background: #fff; }
.lc-logo span { font-family: var(--font-display); font-weight: 700; font-size: 20px; }
/* [07.10.2026] пиктограмма жанра вместо логотипа */
.lc-logo svg { width: 34px; height: 34px; fill: none; stroke: var(--text); stroke-width: 1.6; stroke-linecap: round; stroke-linejoin: round; }
.lc-type { position: absolute; top: 10px; left: 10px; font-family: var(--font-mono); font-size: 10px; letter-spacing: .06em; text-transform: uppercase; padding: 3px 8px; border-radius: 6px; background: rgba(10,12,16,.8); color: var(--req); }
.lib-card.market .lc-type, .lm-head.market .lc-type { color: var(--mkt); }
.lc-sample { position: absolute; top: 10px; right: 10px; font-family: var(--font-mono); font-size: 10px; letter-spacing: .06em; text-transform: uppercase; padding: 3px 8px; border-radius: 6px; border: 1px dashed var(--line-strong); color: var(--muted); background: rgba(10,12,16,.6); }
.lc-body { padding: 16px 16px 12px; flex: 1; display: flex; flex-direction: column; gap: 8px; }
.lc-id { font-family: var(--font-mono); font-size: 11px; color: var(--dim); }
.lc-body h3 { font-size: 16px; line-height: 1.25; }
.lc-body p { color: var(--muted); font-size: 14px; display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden; margin: 0; }
.lc-tags { display: flex; flex-wrap: wrap; gap: 6px; margin-top: auto; padding-top: 6px; }
.lc-tags span { font-size: 11.5px; padding: 3px 8px; border-radius: 999px; border: 1px solid var(--line-strong); color: var(--muted); }
.lc-foot { padding: 11px 16px; border-top: 1px solid var(--line); font-size: 13px; color: var(--muted); }
.is-member .lc-foot { color: var(--acid); }
.lib-empty { color: var(--muted); }

.lib-access { padding: clamp(28px, 5vw, 64px) 0; border-top: 1px solid var(--line); }
.lib-access-box { display: grid; gap: 28px; padding: clamp(22px, 4vw, 40px); border-radius: 20px; border: 1px solid var(--line); background: var(--panel); }
@media (min-width: 900px) { .lib-access-box { grid-template-columns: 1.5fr 1fr; align-items: center; } }
.lib-steps { margin: 16px 0 0; padding-left: 22px; display: grid; gap: 10px; color: var(--muted); }
.lib-steps li::marker { color: var(--acid); font-family: var(--font-mono); }
.lib-access-cta { display: grid; gap: 10px; }
.lib-access-cta p { font-size: 14px; margin-top: 6px; }

/* окно карточки */
.lib-modal { position: fixed; inset: 0; z-index: 60; background: rgba(5,6,9,.78); backdrop-filter: blur(6px); -webkit-backdrop-filter: blur(6px); display: none; align-items: center; justify-content: center; padding: 16px; }
.lib-modal.open { display: flex; }
.lib-dialog { position: relative; width: 100%; max-width: 720px; max-height: 100%; overflow: auto; background: var(--panel); border: 1px solid var(--line-strong); border-radius: 20px; animation: rise .3s ease; }
.lm-head { position: relative; padding: 44px clamp(20px, 3vw, 32px) 22px; background: linear-gradient(135deg, rgba(139,124,255,.28), rgba(139,124,255,.03)); }
.lm-head .lc-id { margin-top: 10px; }
/* [07.10.2026] пиктограмма в открытой карточке */
.lm-logo { margin-top: 4px; }
.lm-head h2 { font-size: clamp(20px, 2.8vw, 28px); margin: 8px 0 10px; }
.lm-head p { color: var(--muted); }
.lm-fields { margin: 0; padding: 18px clamp(20px, 3vw, 32px) 0; display: grid; gap: 14px; }
.lf dt { font-family: var(--font-mono); font-size: 11px; letter-spacing: .08em; text-transform: uppercase; color: var(--dim); margin-bottom: 4px; }
.lf dd { margin: 0; font-size: 15px; }
.lf dd.hint { font-style: italic; color: var(--muted); }
.lf dd.free { color: var(--dim); }
.st { display: inline-block; font-style: normal; font-family: var(--font-mono); font-size: 10px; letter-spacing: .06em; text-transform: uppercase; padding: 2px 7px; border-radius: 5px; margin-right: 8px; vertical-align: 1px; }
.st.req { background: rgba(201,255,61,.14); color: var(--acid); }
.st.hint { background: rgba(255,255,255,.07); color: var(--muted); }
.lm-must, .lm-rights { margin: 18px clamp(20px, 3vw, 32px) 0; padding: 14px 16px; border-radius: 12px; }
.lm-must { border: 1px solid rgba(255,106,61,.5); background: rgba(255,106,61,.06); }
.lm-rights { border: 1px solid rgba(255,181,71,.5); background: rgba(255,181,71,.06); }
.lm-must h4, .lm-rights h4 { font-size: 14px; margin: 0 0 8px; }
.lm-must ul { margin: 0 0 8px; padding-left: 20px; }
.lm-must p.muted, .lm-note { font-size: 13.5px; }
.lm-note { padding: 14px clamp(20px, 3vw, 32px) 24px; margin: 0; }
.lm-locked { position: relative; padding: 18px clamp(20px, 3vw, 32px) 28px; }
.lm-blur { display: grid; gap: 14px; filter: blur(5px); opacity: .45; user-select: none; pointer-events: none; }
.lm-lock { position: absolute; left: 50%; top: 50%; transform: translate(-50%, -50%); width: min(92%, 420px); text-align: center; padding: 20px; border-radius: 14px; background: rgba(10,12,16,.92); border: 1px solid var(--line-strong); }
.lm-lock b { display: block; margin-bottom: 6px; }
.lm-lock p { color: var(--muted); font-size: 14px; margin-bottom: 12px; }
.lm-head .lc-sample { right: 64px; top: 16px; }
.lm-head .lc-type { top: 16px; left: clamp(20px, 3vw, 32px); }

/* крестик поверх шапки карточки */
.lib-dialog .scheme-close, .scheme-dialog .scheme-close { z-index: 5; background: rgba(10,12,16,.7); }

/* [04.10.2026] плашка вместо карточек, пока их нет */
.lib-soon { padding: clamp(24px, 4vw, 44px); border-radius: 20px; border: 1px dashed rgba(139,124,255,.6); background: linear-gradient(150deg, rgba(139,124,255,.14), rgba(139,124,255,.03)); display: grid; gap: 14px; max-width: 820px; }
.lib-soon h2 { font-size: clamp(22px, 3vw, 32px); }
.lib-soon p { color: var(--muted); font-size: 16.5px; max-width: 640px; margin: 0; }
