:root {
  --bg: #07111f;
  --bg-soft: #0d1728;
  --panel: rgba(255,255,255,0.88);
  --panel-dark: rgba(8,18,32,0.72);
  --panel-solid: #ffffff;
  --text: #10203b;
  --text-soft: #60708d;
  --primary: #4f46e5;
  --primary-2: #8b5cf6;
  --accent: #14b8a6;
  --success: #0f9d58;
  --warning: #d97706;
  --danger: #dc2626;
  --border: rgba(148, 163, 184, 0.22);
  --border-strong: rgba(148, 163, 184, 0.38);
  --shadow: 0 18px 48px rgba(15, 23, 42, 0.12);
  --radius: 24px;
}
*{box-sizing:border-box}
html{scroll-behavior:smooth}
body{
  margin:0;
  font-family:Inter,system-ui,-apple-system,Segoe UI,Roboto,sans-serif;
  color:var(--text);
  background:
    radial-gradient(circle at top left, rgba(99,102,241,.12), transparent 24%),
    radial-gradient(circle at top right, rgba(20,184,166,.12), transparent 20%),
    linear-gradient(180deg,#edf2ff 0%,#f7f9fd 28%,#eef3fb 100%);
}
a{text-decoration:none;color:inherit}
.container{width:min(1220px,calc(100% - 28px));margin:0 auto}
.topbar{
  position:sticky;top:0;z-index:50;
  background:rgba(255,255,255,.78);
  backdrop-filter:blur(14px);
  border-bottom:1px solid rgba(255,255,255,.55);
  box-shadow:0 8px 30px rgba(15,23,42,.04);
}
.topbar-inner{display:flex;align-items:center;justify-content:space-between;padding:14px 0;gap:16px}
.brand{display:flex;align-items:center;gap:12px;font-weight:800}
.brand-mark{
  width:46px;height:46px;border-radius:15px;
  background:linear-gradient(135deg,var(--primary),var(--primary-2));
  color:#fff;display:grid;place-items:center;
  box-shadow:0 12px 28px rgba(79,70,229,.28)
}
.nav{display:flex;gap:10px;flex-wrap:wrap;align-items:center}
.nav a,.btn{
  border:1px solid transparent;
  background:#fff;
  padding:11px 16px;
  border-radius:14px;
  font-weight:700;
  cursor:pointer;
  display:inline-flex;align-items:center;justify-content:center;gap:8px;
  transition:.18s ease;
}
.nav a:hover,.btn:hover{transform:translateY(-1px);box-shadow:var(--shadow)}
.nav-toggle{display:none;width:46px;height:46px;border-radius:14px;border:1px solid var(--border-strong);background:#fff;align-items:center;justify-content:center;flex-direction:column;gap:5px;box-shadow:none}
.nav-toggle span{display:block;width:18px;height:2px;background:var(--text);border-radius:999px;transition:.18s ease}
.nav-toggle.is-open span:nth-child(1){transform:translateY(7px) rotate(45deg)}
.nav-toggle.is-open span:nth-child(2){opacity:0}
.nav-toggle.is-open span:nth-child(3){transform:translateY(-7px) rotate(-45deg)}
.nav-logout-form .btn{width:auto}

.nav .btn-primary, .btn-primary{
  background:linear-gradient(135deg,var(--primary),var(--primary-2));
  color:#fff;
  box-shadow:0 14px 35px rgba(79,70,229,.26)
}
.btn-outline{border-color:var(--border-strong);background:#fff}
.btn-danger{background:var(--danger);color:#fff}
.btn-success{background:var(--success);color:#fff}
.btn-warning{background:var(--warning);color:#fff}
.hero{padding:40px 0 22px}
.hero-premium{margin-top:12px}
.hero-grid,.hero-grid-wide{display:grid;grid-template-columns:1.2fr .8fr;gap:22px}
.hero-grid-wide{grid-template-columns:1.35fr .9fr}
.card{
  background:var(--panel-solid);
  border:1px solid var(--border);
  border-radius:var(--radius);
  box-shadow:var(--shadow);
}
.hero-copy{padding:30px}
.hero-title{font-size:clamp(2rem,4vw,3.55rem);line-height:1.02;margin:0 0 16px}
.hero-sub{color:var(--text-soft);font-size:1.05rem;line-height:1.68;margin:0 0 24px}
.stats{display:grid;grid-template-columns:repeat(3,1fr);gap:12px}
.stat{
  padding:18px;border-radius:18px;
  background:linear-gradient(180deg,#f9fbff,#eef4ff);
  border:1px solid rgba(99,102,241,.12)
}
.stat b{display:block;font-size:1.6rem}
.filters{
  padding:18px;margin:22px 0;
  display:grid;grid-template-columns:2fr 1fr 1fr auto auto;gap:12px;align-items:end
}
.filters-hero{align-items:end}
label{display:block;font-size:.93rem;font-weight:700;margin-bottom:8px}
input,select,textarea{
  width:100%;padding:12px 14px;border:1px solid var(--border-strong);
  border-radius:14px;background:#fff;font:inherit;color:var(--text)
}
textarea{min-height:110px;resize:vertical}
.grid{display:grid;gap:18px}
.grid-3{grid-template-columns:repeat(3,1fr)}
.grid-2{grid-template-columns:repeat(2,1fr)}
.book-card{overflow:hidden;display:flex;flex-direction:column}
.book-cover{height:220px;background:#eef2ff;background-size:cover;background-position:center}
.book-body{padding:18px;display:flex;flex-direction:column;gap:12px}
.muted{color:var(--text-soft)}
.badge{
  display:inline-flex;align-items:center;padding:8px 12px;border-radius:999px;
  background:#eef2ff;color:#3730a3;font-weight:800;font-size:.82rem
}
.badge.success{background:#ecfdf3;color:#166534}
.badge.warning{background:#fff7ed;color:#b45309}
.badge.danger{background:#fef2f2;color:#b91c1c}
.meta{display:flex;flex-wrap:wrap;gap:10px;font-size:.92rem;color:var(--text-soft)}
.section-title{display:flex;justify-content:space-between;align-items:end;gap:12px;margin:28px 0 16px}
.section-title h2,.section-title h3,.section-title h4{margin:0}
.table-wrap{overflow:auto}
.table{width:100%;border-collapse:collapse}
.table th,.table td{padding:14px;border-bottom:1px solid #edf0f5;text-align:left;vertical-align:top}
.table th{font-size:.9rem;color:var(--text-soft);font-weight:700}
.flash{padding:14px 16px;border-radius:16px;margin:14px 0;font-weight:700}
.flash.success{background:#ecfdf3;color:#166534}
.flash.error{background:#fef2f2;color:#991b1b}
.flash.info{background:#eff6ff;color:#1d4ed8}
.kpi-grid{display:grid;grid-template-columns:repeat(4,1fr);gap:16px}
.kpi{padding:18px}
.kpi .num{font-size:2rem;font-weight:800}
.kpi .muted{font-size:.92rem}
.map-shell{padding:0;overflow:hidden}
.map-toolbar{padding:16px 18px;border-bottom:1px solid #edf0f5;display:flex;justify-content:space-between;gap:12px;flex-wrap:wrap}
.map{height:420px}
.auth-wrap{width:min(620px,100%);margin:34px auto}
.form-card{padding:26px}
.footer{
  padding:46px 0 60px;
  color:#dce6fb;
}
.footer-shell{
  border-radius:32px;
  overflow:hidden;
  background:
    radial-gradient(circle at top left, rgba(99,102,241,.26), transparent 22%),
    radial-gradient(circle at bottom right, rgba(20,184,166,.20), transparent 18%),
    linear-gradient(180deg,#0b1426 0%,#0e1930 100%);
  border:1px solid rgba(255,255,255,.08);
  box-shadow:0 24px 60px rgba(2,8,23,.28);
}
.footer-top{
  padding:24px 24px 0;
  display:flex;align-items:center;justify-content:space-between;gap:16px;flex-wrap:wrap;
}
.footer-top .muted{color:#a9b7d6}
.footer-grid{
  display:grid;
  grid-template-columns:1.3fr 1fr 1fr 1fr;
  gap:18px;
  padding:22px 24px 26px;
}
.footer-card{
  padding:20px 22px;height:100%;
  background:rgba(255,255,255,.04);
  border:1px solid rgba(255,255,255,.08);
  border-radius:22px;
  backdrop-filter: blur(6px);
}
.footer-card h4{margin:0 0 14px;color:#fff}
.footer-brand{margin-bottom:6px}
.footer-list{margin:0;padding-left:18px;color:#dce6fb;display:grid;gap:8px}
.payments{display:flex;gap:10px;flex-wrap:wrap;margin-top:10px}
.pay-badge{
  display:inline-flex;align-items:center;justify-content:center;
  padding:10px 14px;border-radius:14px;background:rgba(255,255,255,.06);
  border:1px solid rgba(255,255,255,.08);font-weight:800;color:#fff
}
.footer-bottom{
  border-top:1px solid rgba(255,255,255,.08);
  padding:18px 24px 22px;
  display:flex;justify-content:space-between;gap:12px;flex-wrap:wrap;
  color:#a9b7d6;font-size:.92rem
}
.list-clean{list-style:none;padding:0;margin:0;display:grid;gap:10px}
.inline-form{display:inline}
.two-col{display:grid;grid-template-columns:2fr 1fr;gap:22px}
.center{display:flex;align-items:center;justify-content:center}
.small{font-size:.9rem}
.actions{display:flex;gap:10px;flex-wrap:wrap}
.feature-list{display:grid;gap:12px;margin-top:8px}
.feature-item{display:grid;gap:4px;padding:14px 16px;border:1px solid rgba(99,102,241,.10);border-radius:18px;background:#f7f9ff}
.info-strip{display:grid;grid-template-columns:1fr 1fr;gap:18px;margin:18px 0 24px}
.info-card{padding:18px 20px}
.tag-row{display:flex;flex-wrap:wrap;gap:10px;margin-top:10px}
.tag{padding:8px 12px;border-radius:999px;background:#11192f;border:1px solid rgba(255,255,255,.08);font-size:.9rem;color:#d7def7}
.supply-grid{display:grid;grid-template-columns:1.1fr .9fr;gap:18px;margin:16px 0 24px}
.supply-list{display:grid;gap:12px}
.supply-item{padding:16px 18px;border:1px solid #edf0f5;border-radius:18px;background:#fff}
.supply-item strong{display:block;margin-bottom:4px}
.helper-note{
  padding:14px 16px;border-radius:18px;background:#eef6ff;border:1px solid #dbeafe;color:#1e3a8a
}
.pricing-strip{display:grid;grid-template-columns:repeat(3,1fr);gap:16px;margin-top:10px}
.price-card{padding:20px}
.price-card .price{font-size:1.7rem;font-weight:800}
.soft-card{background:linear-gradient(180deg,#ffffff,#f7faff)}
@media (max-width: 980px){
  .hero-grid,.hero-grid-wide,.two-col,.grid-3,.grid-2,.kpi-grid,.footer-grid,.info-strip,.supply-grid,.pricing-strip{grid-template-columns:1fr}
  .filters{grid-template-columns:1fr 1fr}
  .stats{grid-template-columns:1fr}
  .map{height:320px}
}
@media (max-width: 640px){
  .filters{grid-template-columns:1fr}
  .topbar-inner{align-items:center;flex-direction:row;flex-wrap:wrap}
  .brand{flex:1;min-width:0}
  .brand > div{min-width:0}
  .nav-toggle{display:inline-flex}
  .nav{width:100%;display:none;flex-direction:column;align-items:stretch}
  .nav.is-open{display:flex}
  .nav a,.nav .btn{width:100%}
  .nav-logout-form{width:100%}
  .hero-copy{padding:22px}
  .book-cover{height:180px}
  .footer-top,.footer-bottom{padding-left:18px;padding-right:18px}
  .footer-grid{padding:18px}
}


.plan-grid{display:grid;grid-template-columns:repeat(auto-fit,minmax(220px,1fr));gap:16px}
.plan-card{padding:18px;border:1px solid rgba(148,163,184,.18);border-radius:20px;background:linear-gradient(180deg,rgba(15,23,42,.74),rgba(2,6,23,.88));box-shadow:0 10px 30px rgba(2,6,23,.18)}
.plan-card.is-current{border-color:rgba(251,191,36,.45);box-shadow:0 14px 36px rgba(251,191,36,.08)}
.plan-name{font-size:1.1rem;font-weight:800;margin-bottom:6px}
.plan-price{font-size:1.5rem;font-weight:800;margin-bottom:12px}
.stack-actions{display:grid;gap:8px}
.btn-success{background:#0f9d58;color:#fff;border:none}
.btn-success:hover{filter:brightness(1.05)}


.map-grid{display:grid;grid-template-columns:minmax(0,1.55fr) minmax(320px,.95fr);gap:18px;align-items:start}.map-sidebar{padding:22px;position:sticky;top:18px;min-height:520px}.feature-book-item{gap:6px}.checkout-grid{align-items:start}.compact-list li{margin-bottom:8px}.dashboard-sections .card{min-height:320px}@media (max-width: 980px){.map-grid{grid-template-columns:1fr}.map-sidebar{position:static;min-height:auto}}

#map,
#searchMap{
  width:100%;
  min-height:420px;
  border-radius:0 0 24px 24px;
}

.leaflet-container{
  width:100%;
  height:100%;
  border-radius:0 0 24px 24px;
  z-index:1;
}

.map-shell{
  overflow:hidden;
}

.map-sidebar{
  background:var(--panel-solid);
}

.map-sidebar .feature-book-item{
  background:#f8faff;
  border:1px solid rgba(99,102,241,.10);
  border-radius:18px;
}

.map-toolbar{
  background:#fff;
}

@media (max-width: 980px){
  #map,
  #searchMap{
    min-height:320px;
  }
}


.book-hero-card{display:grid;grid-template-columns:minmax(320px,1.05fr) minmax(340px,.95fr);gap:0;overflow:hidden;margin-top:22px}.book-hero-media{min-height:620px;background-size:cover;background-position:center}.book-hero-body{padding:26px 28px;background:linear-gradient(180deg,#ffffff,#f7fbff)}.book-hero-top{display:flex;justify-content:space-between;gap:12px;align-items:center}.book-hero-title{font-size:2.4rem;line-height:1.08;margin:14px 0 10px}.book-hero-author{font-size:1.2rem;color:#5a6f96;margin-bottom:14px}.book-chip-row{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:12px;margin:18px 0}.book-chip{padding:14px 16px;border-radius:18px;background:#fff;border:1px solid #e5edf8}.book-chip span{display:block;font-size:.86rem;color:#6b7280;margin-bottom:6px}.book-chip strong{font-size:1.06rem}.book-info-grid{display:grid;grid-template-columns:1fr 1fr;gap:14px;margin-top:12px}.book-owner-card{padding:22px}.book-owner-head{display:grid;grid-template-columns:110px 1fr;gap:16px;align-items:start}.book-owner-cover{height:140px;border-radius:20px;background-size:cover;background-position:center;background-color:#eef2f7}.book-manage-grid,.book-edit-layout{align-items:start}.rental-flow-card{padding:22px}.rental-chat-list{display:grid;gap:10px;max-height:360px;overflow:auto;padding-right:4px}.chat-bubble{padding:14px 16px;border-radius:18px;background:#f5f8ff;border:1px solid #dbeafe;max-width:760px}.chat-bubble.is-own{background:#eefbf3;border-color:#c5f0d2;margin-left:auto}.review-grid{display:grid;grid-template-columns:1fr 1fr;gap:18px}.review-grid-book{align-items:start}.table .stack-actions .btn{width:100%}@media (max-width:980px){.book-hero-card,.book-info-grid,.review-grid,.book-chip-row,.book-owner-head,.book-edit-layout{grid-template-columns:1fr}.book-hero-media{min-height:320px}.book-hero-title{font-size:1.9rem}}


.workspace-layout{padding-top:26px}
.workspace-shell{display:grid;grid-template-columns:290px minmax(0,1fr);gap:24px;align-items:start}
.workspace-sidebar{position:sticky;top:92px}
.workspace-brand,.workspace-pagebar{
  background:linear-gradient(180deg,rgba(255,255,255,.96),rgba(244,247,255,.94));
  border:1px solid rgba(148,163,184,.2);
  box-shadow:0 18px 42px rgba(15,23,42,.08)
}
.workspace-brand{padding:18px;border-radius:28px}
.workspace-brand-top{display:flex;align-items:center;gap:14px;margin-bottom:16px}
.workspace-brand-title{font-size:1.1rem;font-weight:800}
.workspace-nav{display:grid;gap:8px}
.workspace-link{
  display:flex;align-items:center;justify-content:space-between;
  padding:13px 15px;border-radius:16px;font-weight:700;
  color:var(--text);border:1px solid transparent;background:transparent;transition:.18s ease
}
.workspace-link:hover{background:#f6f8ff;border-color:rgba(99,102,241,.14);transform:translateX(2px)}
.workspace-link.is-active{background:linear-gradient(135deg,var(--primary),var(--primary-2));color:#fff;box-shadow:0 14px 30px rgba(79,70,229,.22)}
.workspace-main{min-width:0;display:grid;gap:18px}
.workspace-pagebar{padding:22px 24px;border-radius:28px;display:flex;align-items:center;justify-content:space-between;gap:16px;flex-wrap:wrap}
.workspace-eyebrow{font-size:.82rem;font-weight:800;letter-spacing:.08em;text-transform:uppercase;color:var(--text-soft);margin-bottom:4px}
.workspace-title{margin:0;font-size:clamp(1.7rem,3vw,2.5rem);line-height:1.06}
.workspace-actions{display:flex;gap:10px;flex-wrap:wrap}
.workspace-page .section-title{margin:8px 0 14px}
.workspace-page .card{border-radius:26px}
.workspace-page .kpi,.workspace-page .info-card,.workspace-page .soft-card{background:linear-gradient(180deg,#ffffff,#f8faff)}
.workspace-page .table th,.workspace-page .table td{padding:16px 14px}
.workspace-page .table tbody tr:hover{background:rgba(99,102,241,.04)}
.workspace-page .btn{border-radius:14px}
.workspace-page .helper-note{border-radius:18px}
.workspace-page .two-col{align-items:start}
.page-dashboard .kpi-grid{grid-template-columns:repeat(4,minmax(0,1fr))}
.page-dashboard .kpi .num{font-size:2.3rem}
.page-dashboard .card{overflow:hidden}
.page-dashboard .section-title + .kpi-grid{margin-top:0}
.page-my-rentals .table td:last-child,.page-admin .table td:last-child,.page-admin-finance .table td:last-child{min-width:190px}
.page-my-rentals .inline-form,.page-admin .inline-form{display:block}
.page-my-rentals .inline-form .btn,.page-admin .inline-form .btn{width:100%}
.page-my-rentals .inline-form + .inline-form,.page-admin .inline-form + .inline-form{margin-top:8px}
.page-my-books .book-owner-card,.page-edit-book .book-owner-card{padding:18px}
.page-my-books .book-owner-head,.page-edit-book .book-owner-head{display:grid;grid-template-columns:140px minmax(0,1fr);gap:18px;align-items:start}
.book-owner-cover{width:140px;height:180px;border-radius:20px;background:#eef2ff;background-size:cover;background-position:center;box-shadow:0 12px 24px rgba(15,23,42,.12)}
.book-manage-grid{grid-template-columns:1.1fr .9fr}
.book-edit-layout{grid-template-columns:.9fr 1.1fr}
.page-admin .kpi-grid,.page-admin-finance .kpi-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
.page-admin .card,.page-admin-finance .card{background:linear-gradient(180deg,#ffffff,#f8fbff)}
.page-messages .two-col,.page-admin-finance .two-col,.page-dashboard .two-col{grid-template-columns:1.2fr .8fr}
@media (max-width: 1180px){
  .workspace-shell{grid-template-columns:1fr}
  .workspace-sidebar{position:static}
  .workspace-nav{grid-template-columns:repeat(auto-fit,minmax(160px,1fr))}
}
@media (max-width: 820px){
  .workspace-pagebar{padding:18px}
  .workspace-actions,.workspace-nav{grid-template-columns:1fr}
  .workspace-link,.workspace-actions .btn{width:100%}
  .book-manage-grid,.book-edit-layout,.page-messages .two-col,.page-admin-finance .two-col,.page-dashboard .two-col{grid-template-columns:1fr}
  .page-dashboard .kpi-grid{grid-template-columns:repeat(2,minmax(0,1fr))}
}
@media (max-width: 640px){
  .workspace-layout{padding-top:18px}
  .workspace-brand{padding:16px}
  .workspace-pagebar{border-radius:22px}
  .workspace-title{font-size:1.5rem}
  .page-dashboard .kpi-grid,.page-admin .kpi-grid,.page-admin-finance .kpi-grid{grid-template-columns:1fr}
  .page-my-books .book-owner-head,.page-edit-book .book-owner-head{grid-template-columns:1fr}
  .book-owner-cover{width:100%;height:220px}
}

.dispute-card{padding:18px;border-radius:22px;background:linear-gradient(180deg,#fff,#f8fbff);border:1px solid rgba(148,163,184,.18)}
.dispute-attachments{display:grid;grid-template-columns:repeat(auto-fit,minmax(150px,1fr));gap:12px}
.dispute-attachment{display:grid;gap:8px;padding:10px;border-radius:18px;border:1px solid #e2e8f0;background:#fff;color:var(--text)}
.dispute-attachment img{width:100%;height:120px;object-fit:cover;border-radius:14px;background:#eef2ff}
.wrap-actions{display:flex;flex-wrap:wrap;gap:10px}
.page-admin-disputes .kpi-grid{grid-template-columns:repeat(3,minmax(0,1fr))}
.page-admin-disputes .card{background:linear-gradient(180deg,#ffffff,#f8fbff)}
.page-admin-disputes .two-col{align-items:start}
@media (max-width: 820px){.page-admin-disputes .kpi-grid{grid-template-columns:1fr}}

/*ЛОГО*/
.brand-logo {
    width: 100px;
    height: 100px;
    object-fit: contain;
    margin-right: 5px;
}

.footer-logo {
    width: 95px;
    height: 95px;
    object-fit: contain;
    margin-right: 12px;
}

/* catalog and book page cleanup */
.book-hero-card{box-shadow:0 18px 60px rgba(15,23,42,.08);border:1px solid #e5edf8;border-radius:28px;background:#fff}
.book-hero-media{background-color:#eef2f7}
.book-hero-body{padding:34px 36px}
.book-hero-top .badge{font-size:.92rem;padding:10px 14px;border-radius:999px}
.book-hero-title{font-size:3rem;margin-bottom:12px}
.book-hero-author{font-size:1.5rem;font-weight:600;color:#58709a}
.book-hero-meta{display:flex;flex-wrap:wrap;gap:10px;margin:2px 0 18px}
.book-hero-meta span{padding:8px 12px;border-radius:999px;background:#f5f8ff;border:1px solid #dbe7fb;color:#27436f;font-size:.9rem;font-weight:600}
.book-chip-row{grid-template-columns:repeat(auto-fit,minmax(150px,1fr));align-items:stretch}
.book-chip{min-height:96px;display:flex;flex-direction:column;justify-content:center;box-shadow:0 6px 24px rgba(15,23,42,.04)}
.book-chip strong{font-size:1.2rem;line-height:1.2}
.book-info-grid .soft-card{border-radius:22px;background:#fbfdff;box-shadow:0 10px 28px rgba(15,23,42,.04)}
.owner-book-note{display:grid;gap:6px;padding:16px 18px;border-radius:20px;background:linear-gradient(180deg,#fff9ed,#fff4d8);border:1px solid #f4d38a;color:#6f4f0a}
.owner-book-note strong{font-size:1rem;color:#8b5a00}
.filters.filters-hero{align-items:end}
.filters.filters-hero .muted.small{grid-column:1/-1;margin-top:-4px}
.book-card{border-radius:24px;overflow:hidden;box-shadow:0 14px 40px rgba(15,23,42,.06)}
.book-card .book-cover{min-height:240px;background-size:cover;background-position:center}
.book-card .book-body{display:grid;gap:14px;padding:18px 18px 20px}
.book-card .meta{display:grid;gap:6px}
.book-card .btn{width:100%;justify-content:center}
.map-toolbar{justify-content:space-between;align-items:center}
@media (max-width:980px){
  .book-hero-body{padding:22px}
  .book-hero-title{font-size:2.25rem}
}

.workspace-layout{padding-top:14px}
.workspace-shell{grid-template-columns:270px minmax(0,1fr);gap:20px}
.workspace-sidebar{top:82px}
.workspace-brand{padding:14px 16px;border-radius:24px}
.workspace-brand-top{gap:12px;margin-bottom:12px}
.workspace-user-avatar{
  width:52px;height:52px;border-radius:18px;display:inline-flex;align-items:center;justify-content:center;
  font-weight:800;font-size:1.2rem;color:#fff;flex:0 0 52px;
  background:linear-gradient(135deg,#5b3df5 0%, #8b5cf6 45%, #a66a2c 100%);
  box-shadow:0 12px 28px rgba(91,61,245,.22);
}
.workspace-pagebar{padding:18px 22px;border-radius:24px}
.workspace-pagebar .workspace-eyebrow{display:none}
.workspace-page.page-dashboard .workspace-pagebar{display:none}

.dashboard-topline{padding:24px 26px;display:flex;align-items:flex-start;justify-content:space-between;gap:16px;flex-wrap:wrap}
.dashboard-topline-title{margin:2px 0 8px;font-size:1.9rem}
.dashboard-topline-copy{margin:0;max-width:760px}
.dashboard-quick-actions{display:flex;gap:10px;flex-wrap:wrap}
.dashboard-kpis{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px;margin:18px 0}
.dashboard-kpi{padding:18px 20px}
.dashboard-kpi-label{display:block;font-size:.88rem;color:var(--text-soft);margin-bottom:10px}
.dashboard-kpi strong{font-size:1.6rem;line-height:1.1}
.finance-center-card{padding:24px 26px;max-width:1000px;margin:0 auto}
.finance-center-head{margin-bottom:14px}
.finance-table-wrap{overflow:auto;border:1px solid #e5edf8;border-radius:22px;background:#fff}
.finance-table{width:100%;border-collapse:separate;border-spacing:0}
.finance-table th,.finance-table td{padding:16px 18px;text-align:left;border-bottom:1px solid #edf2fb;vertical-align:top}
.finance-table thead th{font-size:.88rem;text-transform:uppercase;letter-spacing:.04em;color:#6b7280;background:#f8fbff}
.finance-table tbody tr:last-child td{border-bottom:none}
.finance-value{font-size:1.15rem;font-weight:800;color:#14213d;white-space:nowrap}
.finance-value-accent{color:#5b3df5}
.finance-payout-grid{display:grid;grid-template-columns:1fr 1fr;gap:18px;margin-top:18px}
.finance-payout-panel{padding:20px;border:1px solid #e5edf8;border-radius:22px;background:#f8fbff}
.page-my-rentals .two-col{grid-template-columns:1.1fr .9fr}
.rentals-table-card{overflow-x:auto}
.btn-dispute-outline{background:#fff;color:#dc2626;border:1.5px solid #dc2626}
.btn-dispute-outline:hover{background:#fff5f5}
.helper-note-danger{background:#fff5f5;border-color:#fecaca;color:#991b1b}
.sheet-modal{position:fixed;inset:0;z-index:80;opacity:0;pointer-events:none;transition:opacity .18s ease}
.sheet-modal:target{opacity:1;pointer-events:auto}
.sheet-modal-backdrop{position:absolute;inset:0;background:rgba(15,23,42,.48);backdrop-filter:blur(4px)}
.sheet-modal-panel{position:relative;width:min(760px,calc(100vw - 32px));max-height:min(86vh,860px);overflow:auto;margin:7vh auto 0;background:#fff;border-radius:28px;padding:22px;border:1px solid rgba(148,163,184,.18);box-shadow:0 32px 70px rgba(15,23,42,.26)}
.sheet-modal-danger .sheet-modal-panel{border-color:#fecaca}
.sheet-modal-head{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;margin-bottom:14px}
.sheet-modal-head h3{margin:0 0 6px}
.sheet-modal-close{display:inline-flex;align-items:center;justify-content:center;width:40px;height:40px;border-radius:14px;background:#f5f7fb;border:1px solid #e5edf8;color:#111827;font-size:1.7rem;line-height:1;text-decoration:none}
.sheet-chat-list{display:grid;gap:10px;max-height:42vh;overflow:auto;padding-right:4px;margin-bottom:14px}
.sheet-dispute-history{display:grid;gap:12px;max-height:34vh;overflow:auto;padding-right:4px;margin-bottom:14px}
.sheet-form textarea{min-height:130px}
.page-my-rentals .rental-flow-card{max-width:980px;margin:0 auto}

@media (max-width: 980px){
  .dashboard-kpis,.finance-payout-grid,.page-my-rentals .two-col{grid-template-columns:1fr}
  .workspace-shell{grid-template-columns:1fr}
  .workspace-sidebar{position:static}
}
@media (max-width: 640px){
  .workspace-layout{padding-top:10px}
  .workspace-brand{border-radius:22px}
  .workspace-pagebar{padding:16px 18px}
  .dashboard-topline{padding:20px 18px}
  .finance-center-card{padding:18px}
  .finance-table th,.finance-table td{padding:13px 14px}
  .sheet-modal-panel{width:100vw;max-width:none;max-height:88vh;margin:auto 0 0;border-radius:24px 24px 0 0;padding:18px 16px 22px;position:absolute;left:0;right:0;bottom:0}
  .sheet-chat-list{max-height:36vh}
  .sheet-dispute-history{max-height:28vh}
}


.nav-link-cabinet{position:relative}
.nav-notice-badge{display:inline-flex;align-items:center;justify-content:center;min-width:20px;height:20px;padding:0 6px;border-radius:999px;background:linear-gradient(135deg,#7c3aed,#5b3df5);color:#fff;font-size:.75rem;font-weight:800;box-shadow:0 8px 18px rgba(91,61,245,.28)}

.dashboard-kpi-plum{
  background:linear-gradient(180deg,#ffffff 0%,#faf7ff 100%);
  border:1px solid rgba(124,58,237,.16);
}
.dashboard-kpi-accent{
  color:#fff;
  background:linear-gradient(135deg,#5b3df5 0%,#7c3aed 48%,#9f67ff 100%);
  border:1px solid rgba(91,61,245,.2);
  box-shadow:0 22px 44px rgba(91,61,245,.22);
}
.dashboard-kpi-accent .dashboard-kpi-label,
.dashboard-kpi-accent .small{color:rgba(255,255,255,.88)}
.finance-table-wrap-compact{border-radius:18px}
.finance-table-compact th,.finance-table-compact td{padding:13px 14px}
.finance-value-positive{color:#15803d}
.finance-value-negative{color:#b91c1c}

.rentals-top-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:16px;margin:0 0 18px}
.compact-stats-card{padding:20px 22px;border:1px solid rgba(124,58,237,.12);background:linear-gradient(180deg,#ffffff 0%,#faf7ff 100%)}
.mini-stats-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.mini-stat-box{padding:16px 18px;border-radius:20px;background:linear-gradient(135deg,#5b3df5 0%,#7c3aed 60%,#9f67ff 100%);color:#fff;box-shadow:0 18px 34px rgba(91,61,245,.18)}
.mini-stat-box span{display:block;font-size:.86rem;opacity:.9;margin-bottom:8px}
.mini-stat-box strong{font-size:1.35rem;line-height:1.08}
.rentals-table-card{border-radius:26px;border:1px solid rgba(124,58,237,.10);overflow:hidden}
.rentals-table-card .table thead th{background:#faf7ff;color:#6b7280;border-bottom:1px solid #ece4fb}
.rentals-table-card .table tbody tr:nth-child(even){background:rgba(124,58,237,.018)}
.rentals-table-card .table tbody tr:hover{background:rgba(124,58,237,.05)}
.stack-actions{display:grid;gap:10px}
.rental-extend-form,.rental-cancel-form,.rental-code-form{gap:8px}
.page-my-rentals .helper-note{background:#f6f2ff;border-color:#e8defc;color:#4c1d95}
.page-my-rentals .btn-dispute-outline{color:#b91c1c;border-color:#f3b6bc;background:#fff}
.page-my-rentals .btn-dispute-outline:hover{background:#fff5f5}

@media (max-width: 980px){
  .rentals-top-grid{grid-template-columns:1fr}
}
@media (max-width: 640px){
  .nav-link-cabinet{justify-content:space-between}
  .dashboard-kpi strong{font-size:1.45rem}
  .mini-stats-grid{grid-template-columns:1fr}
  .compact-stats-card{padding:18px}
}

/* --- production refinement: cabinet + admin --- */
.container{width:min(1440px,calc(100% - 32px))}
.topbar{border-bottom:1px solid rgba(124,58,237,.08);background:rgba(255,255,255,.9)}
.topbar-inner{padding:16px 0}
.brand{gap:14px}
.brand-logo{width:80px;height:80px;margin-right:2px;flex:0 0 72px}
.brand > div:first-of-type,.brand > div{min-width:0}
.nav{justify-content:flex-end}
.nav a,.btn{min-height:46px}

.workspace-layout{padding-top:20px;padding-bottom:22px}
.workspace-shell{grid-template-columns:280px minmax(0,1fr);gap:22px;align-items:start}
.workspace-sidebar{top:96px}
.workspace-brand{padding:18px 18px 20px;border-radius:28px;background:linear-gradient(180deg,#ffffff 0%,#fbf8ff 100%);border:1px solid rgba(124,58,237,.12);box-shadow:0 18px 48px rgba(15,23,42,.08)}
.workspace-brand-title{font-size:1.35rem;line-height:1.05;margin-bottom:4px}
.workspace-user-avatar{width:58px;height:58px;flex-basis:58px;border-radius:20px;font-size:1.3rem;background:linear-gradient(135deg,#6d44f8 0%,#8b5cf6 48%,#b16b35 100%)}
.workspace-nav{gap:10px}
.workspace-link{padding:14px 16px;border-radius:18px;font-size:1.03rem}
.workspace-link.is-active{box-shadow:0 16px 34px rgba(91,61,245,.24)}
.workspace-main{display:grid;gap:20px;min-width:0}
.workspace-pagebar{padding:20px 24px;border-radius:28px;background:linear-gradient(180deg,#ffffff 0%,#fbf8ff 100%);border:1px solid rgba(124,58,237,.10)}
.workspace-title{font-size:clamp(2rem,3vw,2.8rem)}
.workspace-page.page-admin .workspace-title,.workspace-page.page-admin-finance .workspace-title{font-size:clamp(2.2rem,3.2vw,3rem)}

.card{border-radius:28px;box-shadow:0 18px 50px rgba(15,23,42,.08)}
.soft-card,.workspace-page .card{background:linear-gradient(180deg,#ffffff 0%,#fcfaff 100%)}
.section-title{margin:10px 0 16px}
.section-title h2,.section-title h3{font-size:clamp(1.2rem,2vw,1.6rem)}
.muted{color:#66789a}

.dashboard-topline,.admin-hero-card{padding:28px 30px;border:1px solid rgba(124,58,237,.10);background:linear-gradient(180deg,#ffffff 0%,#fbf8ff 100%)}
.dashboard-topline-title,.admin-hero-title{margin:0 0 10px;font-size:clamp(1.9rem,3vw,2.6rem);line-height:1.02}
.dashboard-topline-copy,.admin-hero-copy{max-width:820px;line-height:1.7}
.dashboard-quick-actions{gap:12px}
.dashboard-kpis,.admin-kpi-grid{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:16px}
.dashboard-kpi{padding:22px 24px;min-height:154px;display:flex;flex-direction:column;justify-content:space-between;border-radius:26px}
.dashboard-kpi-label{display:block;font-size:.92rem;letter-spacing:.02em;color:#6a5db0;text-transform:none;margin-bottom:14px}
.dashboard-kpi strong{display:block;font-size:2rem;line-height:1.02;margin-bottom:8px}
.dashboard-kpi .small,.dashboard-kpi .muted{line-height:1.5}
.dashboard-kpi-plum{background:linear-gradient(180deg,#ffffff 0%,#faf7ff 100%);border:1px solid rgba(124,58,237,.16)}
.dashboard-kpi-accent{background:linear-gradient(135deg,#5b3df5 0%,#7c3aed 52%,#9f67ff 100%);color:#fff;border:1px solid rgba(91,61,245,.18)}
.dashboard-kpi-accent .dashboard-kpi-label,.dashboard-kpi-accent .small{color:rgba(255,255,255,.86)}

.finance-center-card{padding:28px 30px;border:1px solid rgba(124,58,237,.10);background:linear-gradient(180deg,#ffffff 0%,#fcfaff 100%)}
.finance-table-wrap,.admin-table-card{border:1px solid rgba(124,58,237,.10);border-radius:24px;overflow:auto;background:#fff}
.finance-table thead th,.admin-table-card .table thead th{background:#faf7ff;color:#6b7280;border-bottom:1px solid #ece4fb}
.finance-table th,.finance-table td,.admin-table-card .table th,.admin-table-card .table td{padding:16px 18px;vertical-align:top}
.finance-table tbody tr:nth-child(even),.admin-table-card .table tbody tr:nth-child(even){background:rgba(124,58,237,.02)}
.finance-table tbody tr:hover,.admin-table-card .table tbody tr:hover{background:rgba(124,58,237,.05)}
.finance-value{font-size:1.18rem;font-weight:800}
.finance-payout-grid,.admin-overview-grid,.admin-dual-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}
.finance-payout-panel,.admin-panel-card{padding:22px 24px;border:1px solid rgba(124,58,237,.10);border-radius:24px;background:linear-gradient(180deg,#ffffff 0%,#fbf8ff 100%)}

.admin-money-list{display:grid;gap:12px}
.admin-money-row{display:flex;align-items:flex-start;justify-content:space-between;gap:16px;padding:16px 18px;border-radius:20px;background:#fff;border:1px solid rgba(124,58,237,.10)}
.admin-money-row strong{display:block;margin-bottom:4px}
.admin-money-value{font-size:1.5rem;font-weight:800;color:#10203b;white-space:nowrap}
.admin-inline-form .btn,.admin-payout-form .btn{width:100%}
.admin-payout-form{min-width:260px;gap:10px}
.admin-log-list{gap:12px}
.admin-log-card{padding:16px 18px;border-radius:22px;background:linear-gradient(180deg,#ffffff 0%,#faf7ff 100%);border:1px solid rgba(124,58,237,.10)}

.rentals-top-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px;margin-bottom:18px}
.compact-stats-card{padding:22px 24px;border-radius:26px;border:1px solid rgba(124,58,237,.12);background:linear-gradient(180deg,#ffffff 0%,#fbf8ff 100%)}
.mini-stats-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:12px}
.mini-stat-box{padding:18px 20px;border-radius:22px;background:linear-gradient(135deg,#5b3df5 0%,#7c3aed 60%,#9f67ff 100%);color:#fff;box-shadow:0 18px 36px rgba(91,61,245,.18)}
.mini-stat-box span{display:block;font-size:.88rem;opacity:.92;margin-bottom:8px}
.mini-stat-box strong{display:block;font-size:1.45rem;line-height:1.02}
.rentals-table-card{border-radius:28px;border:1px solid rgba(124,58,237,.10);overflow:auto;background:#fff}
.rentals-table-card .table thead th{background:#faf7ff;color:#6b7280;border-bottom:1px solid #ece4fb}
.rentals-table-card .table tbody tr:nth-child(even){background:rgba(124,58,237,.02)}
.rentals-table-card .table tbody tr:hover{background:rgba(124,58,237,.05)}
.stack-actions{display:grid;gap:10px;min-width:220px}
.stack-actions .btn{width:100%}

.page-admin .workspace-main,.page-admin-finance .workspace-main,.page-dashboard .workspace-main,.page-my-rentals .workspace-main{min-width:0;max-width:none}
.page-admin .section-title,.page-admin-finance .section-title{align-items:center}
.page-admin .table td:last-child,.page-admin-finance .table td:last-child{min-width:220px}
.page-admin .table,.page-admin-finance .table,.page-my-rentals .table{min-width:1000px}
.page-my-rentals .table td:last-child{min-width:240px}

@media (max-width: 1180px){
  .workspace-shell{grid-template-columns:1fr}
  .workspace-sidebar{position:static}
  .dashboard-kpis,.admin-kpi-grid,.finance-payout-grid,.admin-overview-grid,.admin-dual-grid,.rentals-top-grid{grid-template-columns:1fr 1fr}
}
@media (max-width: 860px){
  .container{width:min(100%,calc(100% - 20px))}
  .dashboard-kpis,.admin-kpi-grid,.finance-payout-grid,.admin-overview-grid,.admin-dual-grid,.rentals-top-grid,.mini-stats-grid{grid-template-columns:1fr}
  .workspace-pagebar{padding:18px}
  .workspace-nav{grid-template-columns:1fr}
  .workspace-link{width:100%}
  .topbar-inner{gap:12px}
  .nav{width:100%}
}
@media (max-width: 640px){
  .brand-logo{width:65px;height:65px;flex-basis:65px}
  .workspace-brand-title{font-size:1.18rem}
  .workspace-user-avatar{width:52px;height:52px;flex-basis:52px}
  .dashboard-topline,.admin-hero-card,.finance-center-card,.compact-stats-card,.admin-panel-card{padding:20px 18px}
  .dashboard-kpi{padding:18px}
  .admin-money-row{flex-direction:column;align-items:flex-start}
  .admin-money-value{font-size:1.3rem}
  .page-admin .table,.page-admin-finance .table,.page-my-rentals .table{min-width:860px}
}
.messages-layout{display:grid;grid-template-columns:minmax(260px,.9fr) minmax(0,1.55fr) minmax(280px,.95fr);gap:18px;align-items:start}
.messages-sidebar,.messages-chat-shell,.messages-profile-shell{padding:20px}
.messages-sidebar-head,.messages-chat-head{display:flex;justify-content:space-between;gap:12px;align-items:flex-start;margin-bottom:14px}
.messages-conversations{display:grid;gap:12px}
.conversation-card{display:grid;gap:6px;padding:14px 15px;border:1px solid var(--border);border-radius:18px;background:linear-gradient(180deg,#fff,#f8fbff);transition:.18s ease}
.conversation-card:hover{transform:translateY(-1px);box-shadow:var(--shadow)}
.conversation-card.is-active{border-color:rgba(79,70,229,.35);box-shadow:0 14px 30px rgba(79,70,229,.10);background:linear-gradient(180deg,#f8f7ff,#eef2ff)}
.conversation-card-top{display:flex;justify-content:space-between;gap:10px;align-items:flex-start}
.conversation-book{font-weight:700;color:#4b5d7b}
.conversation-last-message{color:var(--text-soft);font-size:.94rem;line-height:1.5}
.messages-book-strip{display:flex;gap:14px;align-items:center;padding:14px 16px;border:1px solid var(--border);border-radius:18px;background:linear-gradient(180deg,#f9fbff,#f3f7ff);margin-bottom:14px}
.messages-book-cover,.peer-book-cover{width:62px;height:82px;border-radius:14px;background:#eef2ff;background-size:cover;background-position:center;flex:0 0 auto}
.messages-chat-list{display:grid;gap:12px;max-height:620px;overflow:auto;padding-right:4px;margin-bottom:14px}
.messages-compose-form{display:grid;gap:12px}
.messages-profile-head{display:flex;gap:14px;align-items:center;margin-bottom:16px}
.messages-avatar{width:58px;height:58px;border-radius:18px;display:grid;place-items:center;font-weight:800;color:#fff;background:linear-gradient(135deg,var(--primary),var(--primary-2));box-shadow:0 12px 28px rgba(79,70,229,.24)}
.messages-profile-stats{display:grid;grid-template-columns:1fr 1fr;gap:12px}
.messages-peer-books{display:grid;gap:10px}
.peer-book-card{display:flex;gap:12px;padding:12px;border:1px solid var(--border);border-radius:18px;background:#fff}
.messages-empty-state{min-height:240px;display:grid;place-items:center;text-align:center;gap:8px}
@media (max-width: 1180px){.messages-layout{grid-template-columns:1fr}.messages-chat-list{max-height:none}}

/* === BRAND BUTTON (сливовый как в лого) === */
.btn-plum {
    background: linear-gradient(135deg, #6f3cff 0%, #8a5cff 100%);
    color: #fff;
    border: none;
    border-radius: 12px;
    padding: 10px 18px;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 6px 18px rgba(111, 60, 255, 0.25);
}

.btn-plum:hover {
    transform: translateY(-1px);
    box-shadow: 0 10px 22px rgba(111, 60, 255, 0.35);
}

.btn-plum:active {
    transform: translateY(0);
    box-shadow: 0 4px 10px rgba(111, 60, 255, 0.2);
}



/* === My Rentals hero + bulk delete blocks === */

.rentals-hero-card {
    display: grid;
    grid-template-columns: minmax(0, 1.6fr) minmax(280px, 0.8fr);
    gap: 22px;
    align-items: stretch;
    padding: 28px 30px;
    border: 1px solid #e6e9f5;
    border-radius: 28px;
    background: linear-gradient(180deg, #ffffff 0%, #f8f9ff 100%);
    box-shadow: 0 18px 50px rgba(28, 42, 90, 0.07);
    margin-bottom: 22px;
}

.workspace-eyebrow {
    font-size: 13px;
    line-height: 1.2;
    font-weight: 800;
    letter-spacing: 0.12em;
    text-transform: uppercase;
    color: #6f3cff;
    margin-bottom: 10px;
}

.rentals-hero-title {
    margin: 0 0 12px;
    font-size: 40px;
    line-height: 1.08;
    font-weight: 800;
    color: #102043;
}

.rentals-hero-copy {
    margin: 0;
    max-width: 900px;
    font-size: 18px;
    line-height: 1.55;
    color: #61739b;
}

.rentals-hero-side {
    display: grid;
    grid-template-columns: 1fr;
    gap: 14px;
}

.rentals-hero-side-box {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 128px;
    padding: 18px 20px;
    border-radius: 22px;
    border: 1px solid #e7e9f6;
    background: linear-gradient(180deg, #fdfdff 0%, #f4f6ff 100%);
    box-shadow: inset 0 1px 0 rgba(255,255,255,0.85);
}

.rentals-hero-side-box span {
    font-size: 13px;
    font-weight: 700;
    color: #7081a8;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 8px;
}

.rentals-hero-side-box strong {
    font-size: 30px;
    line-height: 1.05;
    font-weight: 800;
    color: #102043;
    margin-bottom: 8px;
}

.rentals-hero-side-box small {
    font-size: 14px;
    line-height: 1.45;
    color: #6f7fa4;
}

.rentals-bulk-form {
    overflow: hidden;
    border: 1px solid #e7e9f5;
    border-radius: 28px;
    background: #ffffff;
    box-shadow: 0 18px 50px rgba(28, 42, 90, 0.06);
}

.rentals-bulk-toolbar {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    padding: 22px 24px 18px;
    border-bottom: 1px solid #eceffa;
    background: linear-gradient(180deg, #fcfcff 0%, #f7f8ff 100%);
}

.rentals-bulk-toolbar strong {
    display: block;
    margin-bottom: 6px;
    font-size: 20px;
    line-height: 1.2;
    font-weight: 800;
    color: #13234a;
}

.rentals-bulk-toolbar .muted.small {
    max-width: 760px;
    font-size: 14px;
    line-height: 1.45;
    color: #7081a8;
}

.rentals-bulk-delete {
    min-width: 220px;
    min-height: 52px;
    padding: 14px 22px;
    border: none;
    border-radius: 16px;
    font-size: 16px;
    font-weight: 800;
    line-height: 1;
    box-shadow: 0 12px 24px rgba(230, 39, 39, 0.18);
}

.rentals-table-card-premium .table {
    width: 100%;
    border-collapse: collapse;
}

.rentals-table-card-premium .table thead th {
    padding: 18px 14px;
    background: #f8f7ff;
    border-bottom: 1px solid #e7e9f5;
    font-size: 14px;
    font-weight: 800;
    color: #61739b;
    text-align: left;
    vertical-align: middle;
}

.rentals-table-card-premium .table tbody td {
    padding: 16px 14px;
    border-bottom: 1px solid #eef1fb;
    vertical-align: top;
    font-size: 15px;
    color: #13234a;
}

.rentals-table-card-premium .table tbody tr:last-child td {
    border-bottom: none;
}

.rentals-table-card-premium .table tbody tr:hover {
    background: #fcfcff;
}

.rentals-check-col {
    width: 52px;
    min-width: 52px;
    text-align: center;
}

.rentals-checkbox-wrap {
    position: relative;
    display: inline-flex;
    width: 22px;
    height: 22px;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

.rentals-checkbox-wrap input {
    position: absolute;
    inset: 0;
    opacity: 0;
    margin: 0;
    cursor: pointer;
}

.rentals-checkbox-wrap span,
.rentals-master-checkbox {
    display: inline-block;
    width: 22px;
    height: 22px;
    border-radius: 7px;
    border: 1.5px solid #b9b4ff;
    background: #fff;
    box-sizing: border-box;
    transition: all 0.18s ease;
}

.rentals-checkbox-wrap input:checked + span,
.rentals-master-checkbox:checked {
    background: linear-gradient(135deg, #6f3cff 0%, #8a5cff 100%);
    border-color: #6f3cff;
    box-shadow: 0 10px 18px rgba(111, 60, 255, 0.18);
}

.rentals-checkbox-wrap input:checked + span::after {
    content: "";
    position: absolute;
    width: 6px;
    height: 11px;
    border: solid #fff;
    border-width: 0 2px 2px 0;
    transform: rotate(45deg);
    top: 4px;
    left: 8px;
}

.rentals-master-checkbox {
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
    vertical-align: middle;
}

.rentals-checkbox-disabled {
    display: inline-block;
    width: 22px;
    text-align: center;
    color: #b1bbd3;
    font-weight: 800;
    font-size: 18px;
    line-height: 22px;
}

.rentals-table-card-premium .stack-actions {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.rentals-table-card-premium .btn,
.rentals-table-card-premium .btn-outline,
.rentals-table-card-premium .btn-primary,
.rentals-table-card-premium .btn-danger,
.rentals-table-card-premium .btn-success {
    min-height: 48px;
    border-radius: 16px;
    font-weight: 800;
}

.rentals-table-card-premium .helper-note {
    padding: 12px 14px;
    border-radius: 14px;
    background: #f4f7ff;
    border: 1px solid #dfe7fb;
    color: #48618f;
    font-size: 14px;
    line-height: 1.45;
}

@media (max-width: 1100px) {
    .rentals-hero-card {
        grid-template-columns: 1fr;
    }

    .rentals-hero-title {
        font-size: 34px;
    }
}

@media (max-width: 768px) {
    .rentals-hero-card {
        padding: 20px 16px;
        border-radius: 22px;
    }

    .workspace-eyebrow {
        font-size: 12px;
    }

    .rentals-hero-title {
        font-size: 28px;
        line-height: 1.12;
    }

    .rentals-hero-copy {
        font-size: 16px;
    }

    .rentals-hero-side-box {
        min-height: 110px;
        border-radius: 18px;
        padding: 16px;
    }

    .rentals-hero-side-box strong {
        font-size: 26px;
    }

    .rentals-bulk-form {
        border-radius: 22px;
    }

    .rentals-bulk-toolbar {
        flex-direction: column;
        align-items: stretch;
        padding: 18px 16px 14px;
    }

    .rentals-bulk-delete {
        width: 100%;
        min-width: 0;
    }

    .rentals-table-card-premium .table thead th,
    .rentals-table-card-premium .table tbody td {
        padding: 14px 10px;
        font-size: 14px;
    }

    .rentals-check-col {
        width: 44px;
        min-width: 44px;
    }
}

/* === Home hero / map / subscriptions / FAQ update === */
.home-hero-photo{position:relative;overflow:hidden;border-radius:32px;min-height:620px;display:flex;align-items:stretch;background:#d8d2c6;box-shadow:0 24px 70px rgba(0,0,0,.14);margin:14px 0 24px}
.hero-photo-bg{position:absolute;inset:0;width:100%;height:100%;object-fit:cover;object-position:66% center;z-index:0;transform:scale(1.01)}
.hero-photo-overlay{position:absolute;inset:0;z-index:1;background:linear-gradient(90deg,rgba(8,15,12,.80) 0%,rgba(8,15,12,.68) 34%,rgba(8,15,12,.34) 58%,rgba(8,15,12,.08) 100%),linear-gradient(180deg,rgba(0,0,0,.08) 0%,rgba(0,0,0,.24) 100%)}
.hero-photo-glow{position:absolute;inset:0;z-index:1;background:radial-gradient(circle at top right,rgba(255,255,255,.18),transparent 34%),radial-gradient(circle at bottom left,rgba(105,225,151,.10),transparent 30%);pointer-events:none}
.hero-photo-content{position:relative;z-index:2;width:100%;max-width:760px;padding:56px 48px;display:flex;flex-direction:column;justify-content:center;color:#fff}
.hero-kicker{display:inline-flex;align-items:center;gap:10px;width:fit-content;background:rgba(255,255,255,.14);color:#fff;border:1px solid rgba(255,255,255,.20);padding:10px 16px;border-radius:999px;font-size:14px;font-weight:800;letter-spacing:.02em;margin-bottom:18px;backdrop-filter:blur(6px)}
.hero-photo-title{margin:0 0 18px;font-size:clamp(34px,6vw,66px);line-height:1.02;font-weight:900;letter-spacing:-.03em;max-width:700px;color:#fff;text-shadow:0 10px 30px rgba(0,0,0,.28)}
.hero-photo-sub{margin:0 0 28px;max-width:640px;font-size:clamp(17px,2.2vw,22px);line-height:1.6;color:rgba(255,255,255,.92);text-shadow:0 8px 24px rgba(0,0,0,.24)}
.hero-photo-actions{display:flex;flex-wrap:wrap;gap:14px;margin-bottom:28px}.hero-photo-actions .btn{min-width:210px}.btn-hero-light{background:rgba(255,255,255,.10);border-color:rgba(255,255,255,.26)!important;color:#fff}.btn-hero-light:hover{background:rgba(255,255,255,.16);color:#fff}
.hero-mini-stats{display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:14px;max-width:640px}.hero-mini-stat{background:rgba(255,255,255,.10);border:1px solid rgba(255,255,255,.16);border-radius:20px;padding:16px 18px;backdrop-filter:blur(6px);min-height:92px}.hero-mini-stat strong{display:block;font-size:28px;line-height:1;color:#fff;margin-bottom:8px}.hero-mini-stat span{display:block;font-size:13px;line-height:1.45;color:rgba(255,255,255,.82)}
.how-works-wrap{margin:28px 0 24px}.how-works-card{padding:34px 28px 26px;border-radius:28px;background:linear-gradient(180deg,#fff 0%,#fcfbf7 100%)}.how-works-head{text-align:center;margin-bottom:26px}.how-works-head h2{margin:0 0 10px;font-size:clamp(28px,4vw,48px);line-height:1.08}.how-works-head p{margin:0 auto;max-width:760px;color:#667085;font-size:16px;line-height:1.65}
.steps-line{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:20px;position:relative;margin-top:8px}.steps-line::before{content:"";position:absolute;left:10%;right:10%;top:34px;height:2px;background:linear-gradient(90deg,rgba(37,182,92,.18),rgba(37,182,92,.32),rgba(37,182,92,.18));z-index:0}.step-card{position:relative;z-index:1;text-align:center;padding:0 12px 10px}.step-number{width:68px;height:68px;margin:0 auto 22px;border-radius:50%;background:linear-gradient(180deg,#35d06d 0%,#1faa57 100%);color:#fff;display:grid;place-items:center;font-size:34px;font-weight:800;box-shadow:0 16px 30px rgba(44,193,101,.24);border:6px solid #f8fbf7}.step-icon{width:112px;height:112px;margin:0 auto 18px;border-radius:28px;background:linear-gradient(180deg,#ffffff 0%,#f5f9f6 100%);border:1px solid #e8f0ea;box-shadow:0 12px 26px rgba(16,24,40,.05);display:grid;place-items:center}.step-icon svg{width:64px;height:64px}.step-card h3{margin:0 0 10px;font-size:clamp(22px,2vw,28px);line-height:1.15}.step-card p{margin:0;color:#475467;font-size:15px;line-height:1.7}
.section-title-stack{align-items:flex-start}.home-map-layout{display:grid;grid-template-columns:minmax(300px,.95fr) minmax(0,1.65fr);gap:18px;align-items:start;margin-bottom:22px}.map-filter-card{padding:22px;position:sticky;top:18px}.map-filter-head{display:grid;gap:4px;margin-bottom:14px}.map-filter-form{display:grid;gap:14px}.map-filter-actions{display:grid;grid-template-columns:1fr 1fr;gap:10px}.map-shell-home{overflow:hidden;border-radius:26px;background:linear-gradient(180deg,#fff,#f9fbff)}.map-toolbar-rich{padding:18px 20px;background:linear-gradient(180deg,rgba(79,70,229,.02),rgba(20,184,166,.03));border-bottom:1px solid #e8edf7}.map-home{height:560px}
.leaflet-popup-content-wrapper{border-radius:18px;box-shadow:0 18px 45px rgba(15,23,42,.16)}.map-popup-card{line-height:1.6}.map-popup-card a{font-weight:700}
.pricing-strip-subscriptions{grid-template-columns:repeat(2,minmax(0,1fr))}.plan-showcase{padding:24px;border:1px solid rgba(148,163,184,.18)}.plan-showcase .price{font-size:2rem}.plan-showcase-accent{background:linear-gradient(180deg,#ffffff,#f6fbff);border-color:rgba(79,70,229,.16);box-shadow:0 18px 40px rgba(79,70,229,.07)}.compact-list-dark{color:var(--text);padding-left:20px}
.faq-section{margin:30px 0 8px}.faq-list{display:grid;gap:14px}.faq-item{background:#fff;border:1px solid #e6ebf4;border-radius:22px;box-shadow:0 10px 28px rgba(15,23,42,.06);overflow:hidden}.faq-item summary{list-style:none;cursor:pointer;padding:24px 28px;font-size:clamp(1.15rem,2vw,1.45rem);font-weight:800;position:relative;padding-right:72px}.faq-item summary::-webkit-details-marker{display:none}.faq-item summary::after{content:'+';position:absolute;right:26px;top:50%;transform:translateY(-50%);font-size:2rem;line-height:1;color:#7a7f89;font-weight:400}.faq-item[open] summary::after{content:'×';color:#35a95e}.faq-answer{padding:0 28px 24px;color:#1f2937;font-size:1.05rem;line-height:1.7;max-width:1040px}
.plan-grid-showcase{grid-template-columns:repeat(2,minmax(0,1fr))}.plan-card-light{background:linear-gradient(180deg,#fff,#f7faff);color:var(--text)}.plan-card-pro{background:linear-gradient(180deg,#ffffff,#f6fbff);color:var(--text);border:1px solid rgba(79,70,229,.16);box-shadow:0 16px 38px rgba(79,70,229,.08)}.plan-card-pro .plan-price,.plan-card-light .plan-price,.plan-card-pro .plan-name,.plan-card-light .plan-name{color:var(--text)}
.subscriptions-hero{padding-top:10px}
@media (max-width:1100px){.steps-line{grid-template-columns:repeat(2,minmax(0,1fr));gap:26px 18px}.steps-line::before{display:none}.home-map-layout{grid-template-columns:1fr}.map-filter-card{position:static}}
@media (max-width:820px){.home-hero-photo{min-height:560px;border-radius:24px}.hero-photo-bg{object-position:72% center}.hero-photo-content{max-width:100%;padding:34px 22px 28px;justify-content:flex-end}.hero-kicker{font-size:13px;padding:9px 14px;margin-bottom:14px}.hero-photo-title{margin-bottom:14px}.hero-photo-sub{font-size:16px;margin-bottom:20px;max-width:100%}.hero-photo-actions{flex-direction:column;gap:12px;margin-bottom:20px}.hero-photo-actions .btn{width:100%;min-width:0}.hero-mini-stats{grid-template-columns:1fr;gap:10px;max-width:100%}.hero-mini-stat{min-height:auto;padding:14px 16px}.hero-mini-stat strong{font-size:24px}.how-works-card{padding:26px 18px 20px;border-radius:22px}.how-works-head{margin-bottom:20px}.how-works-head p{font-size:15px}.steps-line,.pricing-strip-subscriptions,.plan-grid-showcase{grid-template-columns:1fr}.step-card{padding:0 4px 6px}.step-number{width:60px;height:60px;font-size:28px;margin-bottom:18px}.step-icon{width:96px;height:96px;border-radius:24px}.step-icon svg{width:56px;height:56px}.step-card h3{font-size:20px}.step-card p{font-size:14px;line-height:1.65}.map-home{height:520px}.map-filter-actions{grid-template-columns:1fr}.faq-item summary{padding:20px 20px;padding-right:56px;font-size:1.1rem}.faq-item summary::after{right:20px}.faq-answer{padding:0 20px 20px;font-size:1rem}}
@media (max-width:560px){.home-hero-photo{min-height:520px}.hero-photo-bg{object-position:74% center}.hero-photo-content{padding:28px 16px 18px}.hero-photo-title{font-size:34px;line-height:1.02}.hero-photo-sub{font-size:15px;line-height:1.55}.map-home{height:460px}}


/* Catalog page */
.catalog-shell{display:flex;flex-direction:column;gap:22px;margin-top:10px}
.catalog-topbar{display:grid;grid-template-columns:minmax(0,1.4fr) minmax(320px,1fr);gap:18px;align-items:stretch}
.catalog-kicker{display:inline-flex;align-items:center;gap:8px;padding:8px 14px;border-radius:999px;background:rgba(37,182,92,.1);color:#0f7a3b;font-size:.82rem;font-weight:800;margin-bottom:14px}
.catalog-topbar h1{margin:0 0 12px;font-size:clamp(2rem,3.6vw,3.4rem);line-height:1.03;color:#0f172a}
.catalog-topbar p{margin:0;color:#475569;font-size:1rem;line-height:1.7;max-width:760px}
.catalog-summary-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}
.catalog-summary-card{background:linear-gradient(180deg,#ffffff 0%,#f8fbff 100%);border:1px solid rgba(148,163,184,.18);border-radius:24px;padding:20px;box-shadow:0 14px 32px rgba(15,23,42,.05)}
.catalog-summary-card strong{display:block;font-size:1.5rem;line-height:1.05;color:#0f172a;margin-bottom:8px}
.catalog-summary-card span{display:block;color:#64748b;line-height:1.5}
.catalog-layout{display:grid;grid-template-columns:320px minmax(0,1fr);gap:20px;align-items:start}
.catalog-sidebar{position:sticky;top:92px;padding:22px;border-radius:28px}
.catalog-sidebar-head h2{margin:0 0 8px;font-size:1.4rem;color:#0f172a}
.catalog-sidebar-head p{margin:0 0 18px;color:#64748b;line-height:1.6}
.catalog-filter-form{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:14px}
.catalog-field{display:flex;flex-direction:column;gap:8px}
.catalog-field-full{grid-column:1/-1}
.catalog-filter-form label{font-size:.9rem;font-weight:700;color:#334155}
.catalog-filter-form input,.catalog-filter-form select{width:100%;padding:13px 14px;border:1px solid rgba(148,163,184,.28);border-radius:16px;background:#fff;color:#0f172a;box-sizing:border-box}
.catalog-filter-form input:focus,.catalog-filter-form select:focus{outline:none;border-color:#22c55e;box-shadow:0 0 0 4px rgba(34,197,94,.12)}
.catalog-checkbox{grid-column:1/-1;display:flex;align-items:flex-start;gap:10px;padding:2px 2px 4px;color:#334155;font-weight:600}
.catalog-checkbox input{width:18px;height:18px;margin-top:2px}
.catalog-filter-actions{grid-column:1/-1;display:flex;gap:12px;flex-wrap:wrap}
.catalog-main{display:flex;flex-direction:column;gap:18px}
.catalog-results-bar{display:flex;justify-content:space-between;gap:14px;align-items:flex-end;padding:20px 22px;border-radius:24px}
.catalog-results-bar h2{margin:0 0 8px;font-size:1.45rem;color:#0f172a}
.catalog-results-bar p{margin:0;color:#475569;line-height:1.6}
.catalog-results-note{max-width:360px;color:#64748b;line-height:1.6;text-align:right}
.catalog-grid{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:18px}
.catalog-book-card{overflow:hidden;border-radius:28px;display:flex;flex-direction:column;height:100%}
.catalog-book-cover-wrap{position:relative;padding:16px 16px 0}
.catalog-book-cover{height:270px;border-radius:24px;background-position:center;background-size:cover;background-repeat:no-repeat}
.catalog-book-badge{position:absolute;left:28px;top:28px}
.catalog-book-body{display:flex;flex-direction:column;gap:14px;padding:18px}
.catalog-book-head{display:flex;gap:14px;justify-content:space-between;align-items:flex-start}
.catalog-book-head h3{margin:0 0 8px;font-size:1.32rem;line-height:1.2;color:#0f172a}
.catalog-book-price{white-space:nowrap;font-size:1rem;font-weight:800;color:#0f7a3b;background:rgba(37,182,92,.1);padding:10px 12px;border-radius:999px}
.catalog-book-meta{display:flex;flex-wrap:wrap;gap:8px}
.catalog-book-meta span{display:inline-flex;align-items:center;padding:8px 12px;border-radius:999px;background:#f8fafc;border:1px solid rgba(148,163,184,.16);color:#475569;font-size:.86rem}
.catalog-book-excerpt{margin:0;color:#475569;line-height:1.7;min-height:72px}
.catalog-book-footer{display:flex;justify-content:space-between;gap:12px;align-items:center;margin-top:auto}
.catalog-empty-state{padding:28px;border-radius:28px;grid-column:1/-1}
.catalog-empty-state p{margin:10px 0 18px;line-height:1.7}
@media (max-width: 1100px){.catalog-layout{grid-template-columns:1fr}.catalog-sidebar{position:static}.catalog-grid{grid-template-columns:1fr 1fr}.catalog-topbar{grid-template-columns:1fr}.catalog-results-bar{align-items:flex-start;flex-direction:column}.catalog-results-note{text-align:left;max-width:none}}
@media (max-width: 760px){.catalog-shell{gap:18px}.catalog-topbar h1{font-size:2rem}.catalog-summary-grid{grid-template-columns:1fr 1fr}.catalog-filter-form{grid-template-columns:1fr}.catalog-grid{grid-template-columns:1fr}.catalog-book-cover{height:230px}.catalog-book-head{flex-direction:column}.catalog-book-price{align-self:flex-start}.catalog-book-footer{flex-direction:column;align-items:stretch}.catalog-book-footer .btn{width:100%;justify-content:center}}



/* === Home page polish / map sizing / ajax search === */
.section-title-stack{align-items:flex-start}
.home-hero-photo{margin:14px 0 24px}
.hero-photo-content{max-width:700px;padding:64px 56px 34px}
.hero-photo-actions .btn{min-width:220px;justify-content:center}
.hero-mini-stats{align-items:stretch}
.hero-mini-stat{display:flex;flex-direction:column;justify-content:flex-start}

.home-map-layout{display:grid;grid-template-columns:minmax(290px,340px) minmax(0,1fr);gap:24px;align-items:stretch;margin-bottom:22px}
.map-filter-card{padding:24px 22px;position:sticky;top:18px;min-height:620px;display:flex;flex-direction:column}
.map-filter-head{display:grid;gap:4px;margin-bottom:16px}
.map-filter-form{display:grid;gap:16px;flex:1}
.map-filter-form input,.map-filter-form select{min-height:56px}
.map-filter-actions{display:grid;grid-template-columns:1fr 1fr;gap:12px;margin-top:2px}
.map-filter-actions .btn{min-height:48px;justify-content:center}
.map-filter-note{margin-top:2px}
.map-shell-home{overflow:hidden;border-radius:26px;background:linear-gradient(180deg,#fff,#f9fbff);min-height:620px}
.map-toolbar-rich{padding:20px 22px;background:linear-gradient(180deg,rgba(79,70,229,.02),rgba(20,184,166,.03));border-bottom:1px solid #e8edf7}
.map-home{height:620px}

@media (max-width:1100px){
  .home-map-layout{grid-template-columns:1fr;gap:18px}
  .map-filter-card{position:static;min-height:auto}
  .map-shell-home{min-height:0}
}
@media (max-width:820px){
  .hero-photo-content{max-width:100%;padding:34px 22px 28px}
  .hero-photo-actions{flex-direction:column;gap:12px;margin-bottom:20px}
  .hero-photo-actions .btn{width:100%;min-width:0}
  .hero-mini-stats{grid-template-columns:1fr;gap:10px;max-width:100%}
  .map-filter-actions{grid-template-columns:1fr}
  .map-home{height:520px}
}
@media (max-width:560px){
  .hero-photo-content{padding:28px 16px 18px}
  .map-filter-card{padding:20px 16px}
  .map-toolbar-rich{padding:18px 16px}
  .map-home{height:460px}
}
/* ================================
   MOBILE FIX — MY RENTALS (FINAL)
   ================================ */
/* --- mobile fix: my-rentals (UX FIXED) --- */
@media (max-width: 768px){

  .page-my-rentals .workspace-main,
  .page-my-rentals .workspace-page,
  .page-my-rentals .card,
  .page-my-rentals .table-wrap,
  .page-my-rentals .rentals-table-card{
    min-width: 0;
  }

  /* ✅ ВАЖНО: НЕ БЛОКИРУЕМ вертикальный скролл */
  .page-my-rentals .rentals-table-card,
  .page-my-rentals .table-wrap{
    overflow-x: auto !important;
    overflow-y: visible !important; /* <-- КЛЮЧ */
    -webkit-overflow-scrolling: touch;
    touch-action: auto; /* <-- КЛЮЧ */
  }

  .page-my-rentals .rentals-table-card{
    display: block;
    width: 100%;
    max-width: 100%;
    padding-bottom: 6px;
    border-radius: 22px;
    position: relative;
  }

  .page-my-rentals .rentals-table-card .table{
    width: max-content;
    min-width: 1180px;
  }

  .page-my-rentals .rentals-table-card .table th,
  .page-my-rentals .rentals-table-card .table td{
    white-space: nowrap;
  }

  /* --- ФИКС ХЕДЕРА (не двигается) --- */
  .page-my-rentals .rentals-table-card thead th{
    position: sticky;
    top: 0;
    background: #fff;
    z-index: 3;
  }

  /* --- ПОДСКАЗКА "ПРОВЕДІТЬ ВБІК" --- */
  .page-my-rentals .rentals-table-card::after{
    content: "Проведіть вбік →";
    position: absolute;
    right: 10px;
    bottom: 6px;
    font-size: 11px;
    color: #3b82f6; /* синий как ты хотел */
    background: rgba(255,255,255,0.9);
    padding: 3px 6px;
    border-radius: 6px;
    pointer-events: none;
  }

  .page-my-rentals .rentals-bulk-toolbar{
    display: grid;
    gap: 12px;
  }

  .page-my-rentals .rentals-bulk-delete{
    width: 100%;
  }
}