:root {
  --purple: #7b68ee;
  --header-h: 84px;
  --btn-h: 44px;
  --radius: 12px;
  --card-radius: 16px;
}
header .logo, .logo { height: 64px !important; width: auto; }
body > header {
  background: #fff;
  border-bottom: 1px solid #f3f0fa;
  position: sticky;
  top: 0;
  z-index: 40;
  height: var(--header-h);
}
body > header .header-row {
  width: min(1220px, calc(100% - 40px)) !important;
  margin: 0 auto;
  height: var(--header-h);
  min-height: var(--header-h) !important;
  display: flex;
  align-items: center;
  gap: 24px;
  flex-wrap: nowrap;
}
.btn-purple, .ghost-btn, .read-btn, .btn-fill-header, .btn-ghost-header, .btn-author-header {
  height: var(--btn-h);
  border-radius: 10px;
}
.side-card, .post-card, .card, .paper, .panel, .block {
  border-radius: var(--card-radius);
}
/* Полидис временно скрыт. Оформление кнопки сохранено:
.polidis{position:relative;display:inline-flex;align-items:center;gap:8px;height:42px;padding:0 10px 0 6px;background:#111;color:#d4af5a!important;border-radius:8px;text-decoration:none!important}
.polidis-mark{width:30px;height:30px;border:1.5px solid #d4af5a;display:inline-flex;align-items:center;justify-content:center;font-family:Montserrat,serif;font-weight:800;font-size:16px}
.polidis-txt b{font-family:Montserrat,sans-serif;font-size:12px;letter-spacing:.08em;font-weight:800}
.polidis-tip{position:absolute;left:50%;top:calc(100% + 8px);transform:translateX(-50%) translateY(4px);background:#111;color:#f3e6c0;font-size:12px;font-weight:700;padding:8px 12px;opacity:0}
.polidis:hover .polidis-tip{opacity:1;transform:translateX(-50%) translateY(0)}
*/
nav { display: flex; align-items: center; gap: 22px; }
nav a { color: #222; text-decoration: none; font-weight: 600; }
nav a:hover { color: #7b68ee; }
a.polidis { display: none !important; }
.polidis {
  position: relative;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 42px;
  padding: 0 10px 0 6px;
  background: #111;
  color: #d4af5a !important;
  border-radius: 8px;
  text-decoration: none !important;
  flex: none;
}
.polidis:hover { color: #e8c97a !important; }
.polidis-mark {
  width: 30px;
  height: 30px;
  border: 1.5px solid #d4af5a;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  font-family: Montserrat, serif;
  font-weight: 800;
  font-size: 16px;
}
.polidis-txt {
  display: flex;
  flex-direction: column;
  line-height: 1.05;
}
.polidis-txt b {
  font-family: Montserrat, sans-serif;
  font-size: 12px;
  letter-spacing: .08em;
  font-weight: 800;
}
.polidis-txt small {
  font-size: 9px;
  letter-spacing: .02em;
  color: #cfc3a0;
  font-weight: 500;
}
.polidis-tip {
  position: absolute;
  left: 50%;
  top: calc(100% + 8px);
  transform: translateX(-50%) translateY(4px);
  background: #111;
  color: #f3e6c0;
  font-size: 12px;
  font-weight: 700;
  white-space: nowrap;
  padding: 8px 12px;
  border-radius: 8px;
  opacity: 0;
  pointer-events: none;
  transition: opacity .18s ease, transform .18s ease;
  box-shadow: 0 10px 22px rgba(0,0,0,.18);
  z-index: 30;
}
.polidis-tip::before {
  content: "";
  position: absolute;
  left: 50%;
  top: -5px;
  width: 8px;
  height: 8px;
  background: #111;
  transform: translateX(-50%) rotate(45deg);
}
.polidis:hover .polidis-tip {
  opacity: 1;
  transform: translateX(-50%) translateY(0);
}
.btn-author-header {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  height: 46px;
  padding: 0 14px;
  border-radius: 8px;
  border: 1.5px solid #7b68ee;
  background: #fff;
  color: #5b4ad0;
  font-weight: 700;
  font-size: 15px;
  text-decoration: none !important;
  white-space: nowrap;
}
.btn-author-header:hover { background: #f7f5ff; }
html { height: 100%; }
body {
  min-height: 100vh;
  min-height: 100dvh;
  display: flex;
  flex-direction: column;
}
body > header { flex: none; }
body > main, body > .page, body > section { flex: 1 0 auto; }
.site-footer {
  border-top: 1px solid #efeafc;
  background: #fff;
  color: #666;
  padding: 36px 0 22px;
  margin-top: auto;
  flex: none;
  width: 100%;
  font-size: 13px;
  line-height: 1.55;
}
.site-footer .foot-grid {
  width: min(1220px, calc(100% - 48px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1.4fr 1fr 1fr;
  gap: 28px;
}
.site-footer b { color: #222; display: block; margin-bottom: 8px; font-size: 14px; }
.site-footer a { color: #5b4ad0; text-decoration: none; }
.site-footer a:hover { text-decoration: underline; }
.site-footer .copy {
  width: min(1220px, calc(100% - 48px));
  margin: 22px auto 0;
  padding-top: 14px;
  border-top: 1px solid #f0ecfb;
  color: #888;
  font-size: 12px;
}
@media (max-width: 800px) {
  .site-footer .foot-grid { grid-template-columns: 1fr; }
}
header nav a {
  font-size: 18px;
  font-weight: 800;
}
.header-actions {
  margin-left: auto;
  display: flex;
  align-items: center;
  gap: 10px;
}
.btn-ghost-header,
.btn-fill-header {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 108px;
  height: 46px;
  padding: 0 16px;
  border-radius: 8px;
  font-weight: 700;
  font-size: 15px;
  text-decoration: none;
  border: 0;
  cursor: pointer;
  font-family: inherit;
}
.btn-ghost-header {
  background: #fff;
  color: #5b4ad0;
  border: 1.5px solid #d9ccff;
}
.btn-ghost-header:hover { background: #f7f5ff; }
.btn-fill-header {
  background: #7b68ee;
  color: #fff;
}
.btn-fill-header:hover { background: #6d58e9; }
.header-user {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  max-width: 240px;
  height: 46px;
  padding: 4px 14px 4px 4px;
  border: 1.5px solid #e4dcff;
  border-radius: 999px;
  background: #fff;
  text-decoration: none !important;
  color: #333;
  font-weight: 700;
}
.header-user span {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  text-decoration: none !important;
}
.header-user img {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
  background: #ece7ff;
  flex: 0 0 36px;
}
.header-user:hover { background: #f7f5ff; }
.header-plus {
  width: 36px; height: 36px; border-radius: 50%;
  display: inline-flex; position: relative;
  background: #7b68ee; text-decoration: none; flex: none;
}
.header-plus:before,
.header-plus:after {
  content: "";
  position: absolute;
  left: 50%; top: 50%;
  background: #fff;
  border-radius: 1px;
  transform: translate(-50%, -50%);
}
.header-plus:before { width: 14px; height: 2px; }
.header-plus:after { width: 2px; height: 14px; }
.header-plus:hover { background: #6d58e9; }
.header-shop {
  height: 36px; padding: 0 12px; border-radius: 18px;
  display: inline-flex; align-items: center;
  background: #111; color: #fff; text-decoration: none;
  font-size: 13px; font-weight: 800; flex: none;
}
.header-shop:hover { background: #333; color: #fff; }
.live-flag {
  display: inline-flex; align-items: center; gap: 6px;
  height: 22px; padding: 0 8px; margin-left: 8px;
  background: #e11d48; color: #fff; border-radius: 999px;
  font-size: 11px; font-weight: 800; letter-spacing: .04em; text-transform: uppercase;
  vertical-align: middle;
}
.live-flag i { width: 7px; height: 7px; border-radius: 50%; background: #fff; }
.page-soft { background: #f8f6ff; min-height: calc(100vh - 84px); padding: 48px 0 80px; }
.split {
  display: grid;
  grid-template-columns: 340px 1fr;
  gap: 36px;
  align-items: start;
}
.side-card {
  background: #fff;
  border: 1px solid #efeafc;
  border-radius: 18px;
  padding: 28px 24px;
}
.avatar-lg {
  width: 144px; height: 144px; border-radius: 50%;
  border: 8px solid #d9ccff; object-fit: cover; margin: 0 auto; display: block;
}
.side-card h1 { text-align: center; font-size: 28px; margin-top: 20px; font-family: Montserrat, sans-serif; }
.bio { text-align: center; color: #666; margin-top: 12px; line-height: 1.5; }
.hr { height: 1px; background: #ece8ff; margin: 28px 0; }
.kv { display: flex; justify-content: space-between; margin: 14px 0; color: #666; }
.kv b { color: #333; }
.kv b.accent { color: #7b68ee; }
.plan {
  border: 1px solid #ece8ff; border-radius: 14px; padding: 14px 16px; margin-bottom: 12px; background: #fff;
}
.plan .row { display: flex; justify-content: space-between; font-weight: 700; }
.plan p { color: #777; font-size: 13px; margin-top: 6px; white-space: pre-line; }
.ghost-btn {
  display: flex;
  width: 100%;
  align-items: center;
  justify-content: center;
  text-align: center;
  text-decoration: none;
  color: #333;
  border: 1px solid #ece8ff;
  background: #fff;
  border-radius: 12px;
  padding: 12px 16px;
  font-weight: 600;
  font-size: 15px;
  line-height: 1.3;
  cursor: pointer;
  margin-bottom: 10px;
  font-family: inherit;
  white-space: nowrap;
}
.ghost-btn:hover { background: #f7f5ff; }
.ghost-btn.danger { border-color: #fecaca; color: #ef4444; }
.chip {
  display: inline-flex; align-items: center; justify-content: center;
  background: #7b68ee; color: #fff;
  font-size: 11px; font-weight: 700; letter-spacing: .04em;
  text-transform: uppercase; padding: 8px 12px;
}
.post-row {
  background: #fff; border: 1px solid #efeafc; border-radius: 16px;
  display: grid; grid-template-columns: 240px 1fr; overflow: hidden;
}
.post-row .thumb { background: #ece7ff; min-height: 180px; position: relative; }
.post-row .info { padding: 22px 24px; }
.post-row h3 { font-size: 24px; font-weight: 800; font-family: Montserrat, sans-serif; margin-top: 12px; }
.list { display: grid; gap: 22px; }
#product-list[hidden], .list[hidden] { display: none !important; }
.section-row { display: flex; justify-content: space-between; align-items: center; margin-bottom: 28px; gap: 12px; flex-wrap: wrap; }
.section-row .row-acts { display: flex; gap: 8px; flex-wrap: wrap; margin-left: auto; }
.btn-purple {
  display: inline-flex; align-items: center; justify-content: center;
  background: #7b68ee; color: #fff; border: 0; border-radius: 8px;
  padding: 12px 22px; font-weight: 700; cursor: pointer; font-family: inherit;
  text-decoration: none; line-height: 1.2; white-space: nowrap;
}
.btn-purple:hover { background: #6d58e9; }
.btn-purple.wide { width: 100%; height: 48px; margin-top: 24px; }
.lock {
  position: absolute; top: 12px; left: 12px;
  background: #fff; color: #6e5ae6;
  font-size: 12px; font-weight: 700;
  padding: 6px 10px; border-radius: 999px;
}
.notice {
  background: #ece7ff; color: #4a3db8; border-radius: 12px; padding: 12px 14px; font-size: 14px; margin-bottom: 18px;
}
.auth-card input, .auth-card select, textarea.field {
  width: 100%; border: 1px solid #ddd; border-radius: 10px;
  padding: 12px 14px; margin-bottom: 16px; font-size: 15px; outline: none; font-family: inherit;
}
.auth-card label { display: block; font-weight: 600; color: #555; margin-bottom: 8px; }
.auth-card input:focus { border-color: #7b68ee; box-shadow: 0 0 0 3px #d9ccff; }
.err { color: #ef4444; font-size: 14px; margin: -8px 0 14px; min-height: 18px; }
.demo-row { display: none !important; }
.demo-row button {
  width: 100%; border: 1px solid #ece8ff; background: #f7f5ff; border-radius: 10px;
  padding: 10px 12px; text-align: left; cursor: pointer; font-family: inherit;
}
@media (max-width: 900px) {
  .split, .post-row { grid-template-columns: 1fr; }
  header .header-row {
    width: calc(100% - 16px) !important;
    min-height: 64px !important;
    gap: 8px !important;
    flex-wrap: nowrap !important;
  }
  header .logo, .logo { height: 40px !important; }
  header nav { gap: 8px; min-width: 0; overflow: hidden; }
  header nav a { font-size: 18px; font-weight: 800; white-space: nowrap; }
  .header-actions { gap: 6px; flex: none; }
  .header-plus, .header-shop { display: none; }
  .header-user span { display: none; }
  .header-user { max-width: 44px; padding: 3px; height: 40px; }
  .header-user img { width: 32px; height: 32px; flex-basis: 32px; }
  .btn-purple, .ghost-btn { white-space: normal; }
  .btn-purple.wide { height: 42px; margin-top: 12px; font-size: 14px; }
  .btn-author-header { display: none !important; }
  .btn-ghost-header, .btn-fill-header { min-width: 0; height: 36px; padding: 0 10px; font-size: 13px; }
  #msg-btn, #note-btn { width: 36px; height: 36px; font-size: 15px; }
  #note-panel { right: -20px; }
}
.usti-plans {
  position: fixed; inset: 0; z-index: 90; background: rgba(28,18,58,.48);
  display: none; align-items: center; justify-content: center; padding: 16px;
}
.usti-plans.show { display: flex; }
.usti-plans .card {
  width: min(440px, 100%); background: #fff; padding: 22px 22px 16px;
  box-shadow: 0 20px 50px rgba(40,20,80,.2); max-height: 86vh; overflow: auto;
}
.usti-plans h3 { font-family: Montserrat, sans-serif; font-size: 22px; margin: 0 0 6px; }
.usti-plans .muted { color: #6b6680; margin: 0 0 16px; line-height: 1.45; }
.usti-plans .plan { background: #ece7ff; padding: 14px; margin-bottom: 10px; }
.usti-plans .plan .name { font-weight: 800; }
.usti-plans .plan .price { margin: 4px 0 8px; }
.usti-plans .plan .desc { color: #7b72a8; font-size: 13px; line-height: 1.45; margin-bottom: 10px; }
.usti-plans .plan button {
  width: 100%; height: 40px; border: 0; background: #7b68ee; color: #fff;
  font-weight: 800; cursor: pointer; font-family: inherit;
}
.usti-plans .plan button.done { background: #22c55e; }
.usti-plans .plan button:disabled { background: #c5bddf; cursor: not-allowed; }
.usti-plans .close {
  width: 100%; height: 40px; margin-top: 6px; border: 1.5px solid #d9ccff;
  background: #fff; color: #5b4ad0; font-weight: 700; cursor: pointer;
}
#support-fab {
  position: fixed; right: 22px; bottom: 22px; z-index: 90;
  width: 54px; height: 54px; border-radius: 50%; border: 0;
  background: #7b68ee; color: #fff; font-size: 24px; font-weight: 800;
  display: inline-flex; align-items: center; justify-content: center;
  box-shadow: 0 10px 24px rgba(90,70,180,.28); cursor: pointer;
}
#support-panel {
  display: none; position: fixed; right: 22px; bottom: 86px; z-index: 91;
  width: min(360px, calc(100vw - 32px)); height: 420px;
  background: #fff; border-radius: 16px; border: 1px solid #efeafc;
  box-shadow: 0 18px 40px rgba(30,20,60,.18);
  flex-direction: column; overflow: hidden;
}
#support-panel.open { display: flex; }
.sp-head {
  background: #7b68ee; color: #fff; padding: 10px 12px 10px 14px; font-weight: 800;
  display: flex; align-items: center; justify-content: space-between; gap: 8px; line-height: 1;
}
.sp-head button {
  border: 0; background: none; color: #fff; font-size: 22px; cursor: pointer;
  width: 28px; height: 28px; padding: 0; display: inline-flex; align-items: center; justify-content: center;
  line-height: 1; flex: none;
}
#support-msgs { flex: 1; overflow: auto; padding: 12px; background: #f8f6ff; }
.sp-msg { max-width: 85%; padding: 8px 10px; border-radius: 10px; margin-bottom: 8px; font-size: 13px; line-height: 1.4; }
.sp-msg.user { background: #7b68ee; color: #fff; margin-left: auto; }
.sp-msg.admin { background: #fff; border: 1px solid #e4dcff; }
.sp-hint { color: #777; font-size: 13px; }
.sp-row { display: flex; gap: 6px; padding: 10px; border-top: 1px solid #efeafc; }
.sp-row input { flex: 1; border: 1px solid #e4dcff; border-radius: 8px; padding: 8px 10px; font: inherit; }
.sp-row button { border: 0; background: #7b68ee; color: #fff; border-radius: 8px; padding: 0 10px; font-weight: 700; cursor: pointer; }
.sp-name { display: flex; flex-direction: column; gap: 8px; padding: 10px; border-top: 1px solid #efeafc; }
.sp-name[hidden] { display: none !important; }
.sp-name input { border: 1px solid #e4dcff; border-radius: 8px; padding: 10px 12px; font: inherit; }
.sp-name button { border: 0; background: #7b68ee; color: #fff; border-radius: 8px; height: 42px; font-weight: 700; cursor: pointer; }
#usti-toasts {
  position: fixed; left: 18px; bottom: 18px; z-index: 120;
  display: flex; flex-direction: column; gap: 8px; width: min(320px, calc(100vw - 36px));
  pointer-events: none;
}
.usti-toast {
  background: #1f1b2e; color: #fff; padding: 12px 14px; font-size: 14px; line-height: 1.4;
  opacity: 0; transform: translateY(8px); transition: .2s ease;
  border-left: 4px solid #7b68ee; box-shadow: 0 10px 24px rgba(20,16,40,.18);
}
.usti-toast.show { opacity: 1; transform: none; }
.usti-toast.err { border-left-color: #ef4444; }
.usti-toast.ok { border-left-color: #22c55e; }
#note-wrap { position: relative; display: flex; gap: 8px; align-items: center; }
#msg-btn,
#note-btn {
  width: 42px; height: 42px; border: 1.5px solid #e4dcff; background: #fff;
  cursor: pointer; position: relative; font-size: 18px;
}
#note-dot {
  position: absolute; top: 6px; right: 8px; width: 8px; height: 8px;
  background: #ef4444; border-radius: 50%;
}
#msg-btn { text-decoration: none; color: inherit; display: inline-flex; align-items: center; justify-content: center; }
#msg-dot {
  position: absolute; top: 2px; right: 2px; min-width: 16px; height: 16px; padding: 0 4px;
  background: #7b68ee; color: #fff; border-radius: 99px; font-size: 10px; font-weight: 800;
  display: inline-flex; align-items: center; justify-content: center; line-height: 1;
  font-style: normal; font-family: Inter, system-ui, sans-serif;
}
#note-panel {
  display: none; position: absolute; right: 0; top: calc(100% + 8px); z-index: 50;
  width: min(340px, 80vw); max-height: 380px; overflow: auto;
  background: #fff; border: 1px solid #efeafc; box-shadow: 0 14px 30px rgba(30,20,60,.14);
}
#note-panel.open { display: block; }
#note-panel a, #note-panel p {
  display: flex; align-items: center; gap: 10px; padding: 10px 12px; color: #333; text-decoration: none;
  border-bottom: 1px solid #f4f1fb; font-size: 14px;
}
#note-panel img {
  width: 36px; height: 36px; border-radius: 50%; object-fit: cover;
  flex: 0 0 36px; background: #efeafc;
}
#note-panel .note-txt { min-width: 0; flex: 1; }
#note-panel small { display: block; color: #777; font-size: 12px; margin-top: 3px; }
#note-panel a:hover { background: #f7f5ff; }
.play-btn {
  position: absolute !important; inset: 0 !important; display: flex !important;
  align-items: center !important; justify-content: center !important;
  background: rgba(10,8,20,.42) !important; cursor: pointer; border: 0 !important;
  padding: 0 !important; margin: 0 !important; width: 100% !important; height: 100% !important;
  z-index: 6 !important; appearance: none; -webkit-appearance: none; color: #fff;
}
.play-btn i {
  width: 74px !important; height: 74px !important; border-radius: 50% !important;
  background: rgba(15,12,28,.55) !important; border: 3px solid #fff !important;
  position: relative !important; display: block !important; flex: none !important;
}
.play-btn i:after {
  content: "" !important; position: absolute !important; left: 28px !important; top: 22px !important;
  width: 0 !important; height: 0 !important;
  border-style: solid !important; border-width: 14px 0 14px 22px !important;
  border-color: transparent transparent transparent #fff !important;
  display: block !important;
}
.lock-banner { z-index: 8; pointer-events: auto; cursor: pointer; }
.cover-wrap.locked .play-btn { pointer-events: none !important; }
.react-bar {
  display: inline-flex; align-items: center;
  border: 1.5px solid #d9d0f5; background: #fff;
  border-radius: 999px; overflow: hidden; height: 40px;
}
.react-bar .react {
  border: 0; border-radius: 0; height: 100%;
  background: transparent; text-decoration: none; color: inherit;
  align-items: center; justify-content: center;
}
.react-bar .react + .react { border-left: 1px solid #e6defa; }
.react-bar .react:hover { background: #f4f0ff; color: #5b4ad0; }
.react {
  display: inline-flex; align-items: center; gap: 8px;
  height: 40px; padding: 0 14px; border: 1px solid #e6defa; background: #fff;
  color: #3d3478; font: inherit; font-weight: 700; cursor: pointer;
  border-radius: 999px;
}
.react svg { width: 18px; height: 18px; fill: none; stroke: currentColor; stroke-width: 1.8; display: block; flex: none; }
.react .n { min-width: 1.2em; line-height: 1; display: flex; align-items: center; height: 18px; }
.react.on { background: #7b68ee; border-color: #7b68ee; color: #fff; }
.react.pop .n { animation: like-pop .28s ease; }
.react-bar .react:first-child { border-radius: 999px 0 0 999px; }
.react-bar .react:last-child { border-radius: 0 999px 999px 0; }
.react.star {
  position: relative; padding: 0 12px;
  transform: none !important; box-shadow: none !important; filter: none !important;
}
.react.star svg { fill: none; }
.react.star.on,
.react-bar .react.star.on {
  background: #fff4ed; color: #ea580c; border-color: #fdba74;
}
.react.star.on svg { fill: #f97316; stroke: #ea580c; }
@media (hover: hover) {
  .react.star:hover,
  .react-bar .react.star:hover {
    background: #fff4ed; color: #ea580c;
  }
  .react.star:hover svg { fill: #f97316; stroke: #ea580c; }
  .react.star:hover::after {
    content: attr(data-tip);
    position: absolute; left: 50%; bottom: calc(100% + 8px);
    transform: translateX(-50%);
    background: #1f1638; color: #fff; font-size: 12px; font-weight: 700;
    white-space: nowrap; padding: 6px 10px; border-radius: 8px; z-index: 30;
    pointer-events: none;
  }
}
@keyframes like-pop {
  0% { transform: scale(1); }
  40% { transform: scale(1.35); }
  100% { transform: scale(1); }
}
.c-item {
  background: #f7f5ff; padding: 12px 14px; margin: 0 0 8px;
}
.c-item.reply { background: #f3f0ff; margin-left: 28px; }
video::-internal-media-controls-download-button { display: none; }
a[download] { pointer-events: none; }

#app-drawer, #to-top, #create-fab, #note-sheet { display: none; }
#app-dock {
  display: none;
  position: fixed !important;
  left: 0; right: 0; bottom: 0;
  z-index: 200 !important;
  height: calc(58px + env(safe-area-inset-bottom, 0px));
  padding-bottom: env(safe-area-inset-bottom, 0px);
  background: #fff;
  border-top: 1px solid #efeaf8;
  align-items: stretch;
  justify-content: space-around;
  box-shadow: 0 -8px 24px rgba(40,20,80,.06);
  transform: translateZ(0);
}
.dock-item {
  flex: 1; display: flex; flex-direction: column; align-items: center; justify-content: center;
  gap: 2px; color: #6b6680; text-decoration: none; background: none; border: 0;
  font: inherit; font-size: 11px; font-weight: 700; min-height: 44px; position: relative; cursor: pointer;
}
.dock-item svg { width: 22px; height: 22px; fill: none; stroke: currentColor; stroke-width: 1.8; }
.dock-item.on { color: #7b68ee; }
#app-dock.guest {
  display: none;
  padding: 8px 16px calc(8px + env(safe-area-inset-bottom, 0px));
  height: auto;
  min-height: calc(58px + env(safe-area-inset-bottom, 0px));
  align-items: center;
  justify-content: center;
}
.dock-login {
  display: flex; align-items: center; justify-content: center;
  width: 100%; height: 46px; border-radius: 12px;
  background: #7b68ee; color: #fff; font-weight: 800; text-decoration: none;
}
.dock-dot {
  position: absolute; top: 6px; right: calc(50% - 16px);
  min-width: 8px; height: 8px; background: #ef4444; border-radius: 99px;
}
#app-drawer {
  position: fixed; inset: 0; z-index: 220; background: rgba(20,14,40,.45);
  align-items: flex-end; justify-content: center;
}
#app-drawer.open { display: flex; }
#app-drawer .drawer-card {
  width: 100%; max-height: 82vh; overflow: auto; background: #fff;
  border-radius: 18px 18px 0 0;
  padding: 8px 16px calc(20px + env(safe-area-inset-bottom, 0px));
  display: flex; flex-direction: column; gap: 0;
}
.drawer-grab {
  width: 40px; height: 4px; border-radius: 99px; background: #ddd4f3;
  margin: 6px auto 8px; display: block;
}
.drawer-head {
  display: flex; justify-content: space-between; align-items: center;
  min-height: 40px; margin-bottom: 8px;
}
.drawer-head b { font-size: 18px; }
.drawer-x {
  width: 36px !important; min-height: 36px !important; height: 36px;
  border-radius: 50%; background: #f4f0ff !important; color: #5b4ad0 !important;
  font-size: 22px; justify-content: center !important; padding: 0 !important;
}
.drawer-user {
  background: #f7f5ff; border-radius: 12px; padding: 12px 14px;
  font-weight: 800; margin-bottom: 8px;
}
.drawer-label {
  margin: 12px 0 4px; font-size: 11px; font-weight: 800; letter-spacing: .08em;
  text-transform: uppercase; color: #9a92b8;
}
#app-drawer a, #app-drawer button {
  display: flex; align-items: center; min-height: 46px; padding: 0 10px;
  border: 0; background: none; text-align: left; font: inherit; font-weight: 700;
  color: #333; text-decoration: none; cursor: pointer; border-radius: 10px;
}
#app-drawer a:hover, #app-drawer button:hover { background: #f7f5ff; }
#drawer-out.drawer-out {
  margin-top: 14px; justify-content: center; background: #fff1f2 !important;
  color: #e11d48 !important; border: 1px solid #fecaca !important; border-radius: 12px;
}
#note-sheet {
  position: fixed; inset: 0; z-index: 230; background: rgba(20,14,40,.45);
  align-items: flex-end; justify-content: center;
}
#note-sheet.open { display: flex; }
#note-sheet .sheet {
  width: 100%; max-height: 78vh; overflow: auto; background: #fff;
  border-radius: 18px 18px 0 0;
  padding: 8px 14px calc(18px + env(safe-area-inset-bottom, 0px));
}
.sheet-head {
  display: flex; justify-content: space-between; align-items: center;
  min-height: 40px; margin-bottom: 8px; font-weight: 800;
}
.sheet-head b { font-size: 18px; }
.sheet-head button { border: 0; background: none; color: #7b68ee; font-weight: 700; }
#sheet-list { display: flex; flex-direction: column; gap: 8px; }
#sheet-list a {
  display: flex; align-items: center; gap: 12px;
  padding: 12px; border-radius: 14px; background: #f7f5ff;
  color: inherit; text-decoration: none;
}
#sheet-list img {
  width: 44px; height: 44px; border-radius: 50%; object-fit: cover;
  flex: none; background: #ece7ff;
}
#sheet-list .note-txt { min-width: 0; flex: 1; }
#sheet-list strong { display: block; font-size: 14px; font-weight: 800; line-height: 1.3; }
#sheet-list small { display: block; color: #7a7198; font-weight: 400; margin-top: 4px; font-size: 13px; line-height: 1.35; }
#sheet-list a:active { background: #efeaff; }
.sheet-empty { text-align: center; color: #8a82a8; padding: 28px 8px; }
#to-top, #create-fab {
  position: fixed; z-index: 60; right: 14px;
  height: 44px; min-width: 44px; padding: 0 14px;
  border: 0; background: #7b68ee; color: #fff; font-weight: 800;
  box-shadow: 0 10px 20px rgba(90,70,180,.25); text-decoration: none;
  align-items: center; justify-content: center;
}
#to-top {
  bottom: calc(92px + env(safe-area-inset-bottom));
  display: none; width: 48px; height: 48px; min-width: 48px; padding: 0;
  font-size: 22px; border-radius: 50%; line-height: 1;
}
#to-top.show { display: inline-flex; }
body.dash-page #to-top { display: none !important; }
#create-fab { bottom: calc(86px + env(safe-area-inset-bottom)); display: none; }

html.phone #app-dock,
body.phone #app-dock { display: flex !important; }
html.phone #app-dock.off,
body.phone #app-dock.off { display: none !important; }
@media (max-width: 900px) {
  #app-dock { display: flex !important; }
  #app-dock.off { display: none !important; }
  html, body { overflow-x: hidden; max-width: 100%; }
  img, video, iframe, svg { max-width: 100%; }
  .wrap, .header-row, main, .page-soft, .split, .side-card, .post-card, section, aside, article {
    max-width: 100%;
    min-width: 0;
    box-sizing: border-box;
  }
  .wrap, .header-row { width: 100% !important; padding-left: 12px; padding-right: 12px; }
  h1, h2, h3, p { overflow-wrap: anywhere; }
  #create-fab { display: inline-flex; }
  body { padding-bottom: calc(70px + env(safe-area-inset-bottom, 0px)); }
  .desktop-only { display: none !important; }
  header nav,
  header .header-actions,
  header .header-user { display: none !important; }
  body > header {
    display: flex !important;
    align-items: center;
    justify-content: center;
    height: 48px !important;
    min-height: 48px !important;
    overflow: hidden;
    background: #fff;
    border-bottom: 1px solid #f3f0fa;
  }
  :root { --header-h: 48px; }
  header .header-row {
    width: 100% !important;
    height: 48px !important;
    min-height: 48px !important;
    justify-content: center !important;
    padding: 0 !important;
    gap: 0 !important;
  }
  header .logo, .logo { height: 32px !important; }
  .dock-ava {
    width: 22px; height: 22px; border-radius: 50%; object-fit: cover;
    background: #ece7ff; display: block;
  }
  .dock-item.on .dock-ava { box-shadow: 0 0 0 2px #7b68ee; }
  .header-actions { gap: 0; }
  .header-user { max-width: none; height: 40px; padding-right: 10px; }
  .header-user span { display: inline !important; max-width: 28vw; }
  .site-footer { padding-bottom: 28px; }
  .post-card .body .foot,
  .card .foot,
  article .foot {
    flex-direction: column;
    align-items: stretch !important;
    gap: 12px;
  }
  .read-btn, .sub-btn {
    width: 100% !important;
    min-height: 44px;
    justify-content: center;
  }
  .modal, .usti-plans { padding: 0; align-items: stretch; }
  .modal-card, .usti-plans .card {
    width: 100% !important;
    max-width: none;
    min-height: 100%;
    border-radius: 0;
    padding: 20px 16px calc(24px + env(safe-area-inset-bottom));
  }
  #support-fab, #support-panel { display: none !important; }
  #support-panel.open { display: flex !important; bottom: calc(80px + env(safe-area-inset-bottom)); }
  .page-soft { padding: 20px 0 40px; }
  .wrap { width: calc(100% - 24px) !important; }
  body.author-page .wrap,
  .page-soft .wrap { width: 100% !important; }
  .post-card, .author-page .card, .feed-col .card {
    border-radius: 14px !important;
    box-shadow: 0 12px 28px rgba(40,20,80,.28) !important;
    margin: 0 10px 14px !important;
  }
  .split { display: flex !important; flex-direction: column; height: auto !important; min-height: 0 !important; }
  .side-card { margin-bottom: 16px; }
  aside#plans { order: 2; }
  .cover-cta {
    position: absolute; left: 12px; right: 12px; bottom: 12px; z-index: 9;
    display: flex; flex-direction: column; align-items: center; gap: 8px;
  }
  .cover-cta .sub-now {
    min-height: 44px; padding: 0 16px; background: #7b68ee; color: #fff;
    border: 0; font-weight: 800; width: 100%; max-width: 320px;
  }
}

@media (min-width: 901px) {
  #app-dock, #app-drawer, #app-drawer.open, #to-top, #create-fab, #note-sheet { display: none !important; }
}

@media (hover: hover) {
  button:not(:disabled),
  .btn-purple,
  .ghost-btn,
  .read-btn,
  .fav,
  .btn-schedule,
  .sub-btn,
  .plan button,
  .btn-fill-header,
  .btn-ghost-header,
  .btn-author-header,
  .header-user,
  .dock-item,
  a.btn-purple {
    transition: transform .16s ease, box-shadow .16s ease, background .16s ease, filter .16s ease;
  }
  button:not(:disabled):not(.react):hover,
  .btn-purple:hover,
  .ghost-btn:hover,
  .read-btn:hover,
  .fav:hover,
  .btn-schedule:hover,
  .sub-btn:hover,
  .plan button:hover,
  .btn-fill-header:hover,
  .btn-ghost-header:hover,
  .btn-author-header:hover,
  .header-user:hover,
  a.btn-purple:hover {
    transform: translateY(-1px);
    box-shadow: 0 8px 18px rgba(90,70,180,.16);
    filter: brightness(1.05);
  }
  .dock-item:hover { color: #7b68ee; }
}

#usti-ask {
  display: none; position: fixed; inset: 0; z-index: 80;
  background: rgba(28, 18, 48, .45); align-items: center; justify-content: center; padding: 16px;
}
#usti-ask.show { display: flex; }
#usti-ask .ask-card {
  width: min(420px, 100%); background: #fff; border-radius: 18px;
  padding: 22px 22px 18px; box-shadow: 0 20px 50px rgba(40, 20, 80, .22);
}
#usti-ask h3 { margin: 0 0 8px; font-family: Montserrat, sans-serif; font-size: 20px; }
#usti-ask p { margin: 0 0 18px; color: #555; line-height: 1.45; }
#usti-ask .ask-acts { display: flex; justify-content: flex-end; gap: 8px; }
#usti-ask .ask-no {
  height: 42px; padding: 0 16px; border-radius: 12px; border: 1.5px solid #ece8ff;
  background: #fff; color: #5b4ad0; font: 700 14px Inter, sans-serif; cursor: pointer;
}
#usti-ask .ask-yes {
  height: 42px; padding: 0 16px; border-radius: 12px; border: 0;
  background: #7b68ee; color: #fff; font: 700 14px Inter, sans-serif; cursor: pointer;
}
#usti-ask .ask-yes.danger { background: #e11d48; }

a.top-link {
  display: inline-flex;
  align-items: center;
  height: 40px;
  padding: 0 14px;
  margin: 0 0 14px;
  border-radius: 12px;
  border: 1.5px solid #d9ccff;
  background: #fff;
  color: #5b4ad0;
  font-weight: 700;
  font-size: 14px;
  text-decoration: none;
  box-sizing: border-box;
}
a.top-link:hover { background: #f7f5ff; }

.post-date{color:#8a7cc8;font-size:13px;font-weight:600;margin:4px 0 8px;}

body.club-page .site-footer,
body.club-page #app-dock,
html.phone body.club-page #app-dock,
body.phone.club-page #app-dock,
body.club-page #app-drawer,
body.club-page #to-top { display: none !important; }
