:root {
  --bg: #eaedf3;
  --card: #ffffff;
  --surface: #f8fafc;
  --line: #eef2f6;
  --border: #e2e8f0;
  --text: #0f172a;
  --muted: #64748b;
  --accent: #2563eb;
  --accent-soft: #eff6ff;
  --accent-text: #ffffff;

  --paid-bg: #dcfce7;
  --paid-text: #15803d;
  --paid-bar: #16a34a;

  --partial-bg: #fef3c7;
  --partial-text: #b45309;

  --unpaid-bg: #f1f5f9;
  --unpaid-text: #64748b;

  --danger: #dc2626;
  --danger-soft: #fef2f2;
  --success: #16a34a;

  --shadow: 0 1px 3px rgba(15, 23, 42, 0.05), 0 1px 2px rgba(15, 23, 42, 0.03);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Inter", "Segoe UI", Roboto, sans-serif;
  -webkit-tap-highlight-color: transparent;
}

body {
  background: var(--bg);
  color: var(--text);
  padding: calc(var(--tg-safe-area-inset-top, 0px) + var(--tg-content-safe-area-inset-top, 0px) + 14px) 14px calc(86px + env(safe-area-inset-bottom));
  max-width: 960px;
  margin: 0 auto;
}

.ic {
  width: 15px;
  height: 15px;
  stroke-width: 2;
  flex-shrink: 0;
  vertical-align: -2.5px;
}
.nav-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 22px;
}
.nav-icon .ic {
  width: 20px;
  height: 20px;
  stroke-width: 1.9;
  vertical-align: 0;
}

header {
  padding: 2px 2px 14px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 12px;
}
h1 { font-size: 19px; font-weight: 800; letter-spacing: -0.3px; color: var(--text); }
.subtitle { font-size: 12px; color: var(--muted); margin-top: 2px; }

.tab-content { display: none; animation: fadeIn 0.16s ease; }
.tab-content.active { display: block; }
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(4px); }
  to { opacity: 1; transform: translateY(0); }
}

.block-title {
  font-size: 11.5px;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  letter-spacing: 0.6px;
  margin: 16px 4px 8px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.panel {
  background: var(--card);
  border-radius: 16px;
  padding: 4px 15px;
  margin-bottom: 10px;
  box-shadow: var(--shadow);
  border: 1px solid var(--line);
}

.list-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  padding: 12px 0;
  border-bottom: 1px solid var(--line);
}
.list-row:last-child { border-bottom: none; }
.row-label { font-size: 14px; font-weight: 600; display: flex; align-items: center; gap: 7px; color: var(--text); }
.row-sub { font-size: 11.5px; color: var(--muted); margin-top: 2px; display: flex; align-items: center; gap: 4px; flex-wrap: wrap; }
.row-right { text-align: right; }
.row-val { font-size: 14.5px; font-weight: 700; white-space: nowrap; color: var(--text); }

.hero-card {
  background: linear-gradient(180deg, #ffffff 0%, #eff6ff 100%);
  border: 1px solid #bfdbfe;
  border-radius: 20px;
  padding: 18px;
  margin-bottom: 12px;
  box-shadow: 0 6px 18px rgba(37, 99, 235, 0.08);
}
.hero-top { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.badge {
  font-size: 11.5px;
  font-weight: 700;
  padding: 4px 10px;
  border-radius: 999px;
  background: var(--partial-bg);
  color: var(--partial-text);
  white-space: nowrap;
}
.badge.ok { background: var(--paid-bg); color: var(--paid-text); }
.badge.warn { background: var(--danger-soft); color: var(--danger); }

.hero-bal { font-size: 28px; font-weight: 800; letter-spacing: -0.6px; color: var(--text); margin-top: 4px; }
.hero-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-top: 14px; }

.btn-primary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 11px 14px;
  border-radius: 12px;
  border: none;
  cursor: pointer;
  background: var(--accent);
  color: var(--accent-text);
  font-weight: 600;
  font-size: 13.5px;
  text-decoration: none;
}
.btn-secondary {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 11px 14px;
  border-radius: 12px;
  border: 1px solid var(--border);
  cursor: pointer;
  background: #ffffff;
  color: var(--text);
  font-weight: 600;
  font-size: 13.5px;
  text-decoration: none;
}

.hist-head, .hist-row { display: grid; grid-template-columns: 1.15fr 1fr 1fr 1fr; align-items: center; font-size: 12.5px; }
.hist-head {
  font-size: 10.5px;
  font-weight: 700;
  color: var(--muted);
  text-transform: uppercase;
  padding: 10px 0 6px;
  border-bottom: 1px solid var(--line);
}
.hist-row { padding: 10px 0; border-bottom: 1px solid var(--line); }
.hist-row:last-child { border-bottom: none; }
.hist-head span:not(:first-child), .hist-row span:not(:first-child), .hist-row b:not(:first-child) { text-align: right; }

.poll-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-left: 4px solid var(--accent);
  border-radius: 16px;
  padding: 14px 15px;
  margin-bottom: 10px;
  box-shadow: var(--shadow);
}
.poll-opt {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--border);
  border-radius: 11px;
  padding: 10px 12px;
  margin-top: 7px;
  cursor: pointer;
  background: var(--surface);
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  font-weight: 600;
}
.poll-opt.chosen { border-color: var(--accent); background: var(--accent-soft); }
.poll-opt-bar {
  position: absolute;
  left: 0;
  top: 0;
  bottom: 0;
  background: rgba(37, 99, 235, 0.12);
  pointer-events: none;
  transition: width 0.25s ease;
}
.poll-opt.chosen .poll-opt-bar { background: rgba(37, 99, 235, 0.2); }
.poll-opt-text, .poll-opt-stat { position: relative; z-index: 1; }
.poll-opt-stat { font-size: 12px; color: var(--muted); white-space: nowrap; }
.poll-foot { display: flex; justify-content: space-between; align-items: center; gap: 8px; margin-top: 10px; font-size: 11.5px; color: var(--muted); }

.ann-card {
  background: var(--card);
  border: 1px solid var(--line);
  border-left: 4px solid #f59e0b;
  border-radius: 15px;
  padding: 13px 15px;
  margin-bottom: 8px;
  box-shadow: var(--shadow);
}
.ann-card.urgent { border-left: 4px solid var(--danger); background: #fff5f5; }
.ann-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 8px; }
.ann-title { font-size: 14.5px; font-weight: 700; color: var(--text); display: flex; align-items: center; gap: 6px; }
.ann-body { font-size: 13px; line-height: 1.45; color: #334155; margin-top: 5px; white-space: pre-line; }
.ann-date { font-size: 11px; color: var(--muted); margin-top: 7px; }

.contacts-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; }
.contact-btn {
  display: flex;
  flex-direction: column;
  gap: 4px;
  padding: 12px 13px;
  background: linear-gradient(180deg, #ffffff 0%, #f8fafc 100%);
  border: 1px solid #e2e8f0;
  border-radius: 14px;
  text-decoration: none;
  color: var(--text);
  box-shadow: var(--shadow);
}
.contact-btn:active { background: var(--surface); }
.contact-role { font-size: 13px; font-weight: 700; display: flex; align-items: center; gap: 6px; }
.contact-role .ic { color: var(--accent); }
.contact-phone { font-size: 11.5px; color: var(--muted); font-weight: 500; }

.total-box {
  background: linear-gradient(135deg, #1e3a8a, #2563eb);
  color: #ffffff;
  border-radius: 18px;
  padding: 16px 18px;
  margin-bottom: 10px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  box-shadow: 0 6px 18px rgba(37, 99, 235, 0.22);
}
.total-label { font-size: 12px; opacity: 0.85; }
.total-val { font-size: 24px; font-weight: 800; letter-spacing: -0.5px; margin-top: 2px; }
.total-extra { font-size: 11.5px; opacity: 0.85; text-align: right; }
.total-extra b { display: block; font-size: 14px; color: #ffffff; margin-top: 2px; opacity: 1; }

.flow-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-bottom: 10px; }
.flow-cell {
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 11px 12px;
  box-shadow: var(--shadow);
}
.flow-cell.inc, .rep-mini.inc { background: #f0fdf4; border: 1px solid #dcfce7; }
.flow-cell.exp, .rep-mini.exp { background: #fef2f2; border: 1px solid #fee2e2; }
.flow-cell.neu, .rep-mini.acc { background: #eff6ff; border: 1px solid #dbeafe; }
.flow-cell .lbl { font-size: 11px; color: var(--muted); font-weight: 600; }
.flow-cell .val { font-size: 14px; font-weight: 700; margin-top: 4px; }

.board-stats { display: grid; grid-template-columns: repeat(2, 1fr); gap: 8px; margin-bottom: 12px; }
@media (min-width: 700px) { .board-stats { grid-template-columns: repeat(4, 1fr); } }
.board-actions { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 14px; }
.board-toolbar { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 10px; align-items: center; }
.board-toolbar input { flex: 1; min-width: 200px; }

.house-toolbar { display: flex; flex-direction: column; gap: 8px; margin-bottom: 10px; }
.legend { display: flex; flex-wrap: wrap; gap: 12px; font-size: 12px; color: var(--muted); padding: 0 2px; }
.legend span { display: flex; align-items: center; gap: 5px; }
.dot { width: 10px; height: 10px; border-radius: 3px; display: inline-block; }
.dot.paid { background: var(--paid-bar); }
.dot.partial { background: #f59e0b; }
.dot.unpaid { background: #cbd5e1; }

.sec-switcher { display: grid; grid-template-columns: repeat(4, 1fr); gap: 4px; background: #dce2ec; padding: 3px; border-radius: 12px; }
.sec-switcher.cols-3 { grid-template-columns: repeat(3, 1fr); }
.sec-pill { background: transparent; border: none; color: var(--muted); font-size: 12px; font-weight: 600; padding: 7px 6px; border-radius: 9px; cursor: pointer; }
.sec-pill.active { background: var(--card); color: var(--text); box-shadow: 0 1px 2px rgba(15, 23, 42, 0.08); }

.bar-bg { height: 6px; background: #e2e8f0; border-radius: 999px; overflow: hidden; margin-top: 6px; }
.bar-fill { height: 100%; background: var(--accent); border-radius: 999px; }

.sections { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 10px; align-items: end; }
.section-box { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 12px; box-shadow: var(--shadow); }
.sec-head { display: flex; justify-content: space-between; margin-bottom: 8px; font-weight: 700; font-size: 14px; }
.sec-stat { color: var(--accent); font-size: 12.5px; font-weight: 600; }

.floor-row { display: grid; gap: 4px; margin-bottom: 4px; }
.cols-5 { grid-template-columns: repeat(5, 1fr); }
.cols-4 { grid-template-columns: repeat(4, 1fr); }

.win { height: 31px; border-radius: 7px; display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 700; cursor: pointer; }
.win.unpaid { background: var(--unpaid-bg); color: var(--unpaid-text); }
.win.partial { background: var(--partial-bg); color: var(--partial-text); }
.win.paid { background: var(--paid-bg); color: var(--paid-text); }
.win.empty { background: transparent; cursor: default; }

.commercial { margin-top: 10px; background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 12px; box-shadow: var(--shadow); }
.comm-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(50px, 1fr)); gap: 5px; margin-top: 8px; }

.rep-carousel { display: flex; gap: 12px; overflow-x: auto; scroll-snap-type: x mandatory; scroll-behavior: smooth; padding: 2px 2px 10px; margin: 0 -2px 6px; -webkit-overflow-scrolling: touch; }
.rep-carousel::-webkit-scrollbar { display: none; }
.rep-slide { flex: 0 0 92%; scroll-snap-align: center; background: var(--card); border: 1px solid var(--line); border-radius: 20px; padding: 16px; box-shadow: 0 4px 14px rgba(15, 23, 42, 0.05); }
.rep-slide-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 12px; }
.rep-slide-title { font-size: 16px; font-weight: 800; color: var(--text); }
.rep-slide-hint { font-size: 11px; color: var(--muted); font-weight: 600; }
.rep-money-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin-bottom: 12px; }
.rep-mini { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 9px 11px; }
.rep-mini .lbl { font-size: 11px; color: var(--muted); font-weight: 600; }
.rep-mini .val { font-size: 15px; font-weight: 800; margin-top: 2px; }

.rep-funds-box { border-top: 1px solid var(--line); padding-top: 10px; }
.rep-funds-head { display: grid; grid-template-columns: 1.35fr 1fr 1fr 1fr; font-size: 10.5px; font-weight: 700; color: var(--muted); text-transform: uppercase; margin-bottom: 6px; }
.rep-funds-row { display: grid; grid-template-columns: 1.35fr 1fr 1fr 1fr; font-size: 12.5px; padding: 5px 0; align-items: center; }
.rep-funds-row span:not(:first-child), .rep-funds-head span:not(:first-child), .rep-funds-row b:not(:first-child) { text-align: right; }

.rep-dots { display: flex; justify-content: center; gap: 6px; margin-bottom: 12px; }
.rep-dot { width: 7px; height: 7px; border-radius: 999px; background: #cbd5e1; transition: all 0.2s ease; }
.rep-dot.active { width: 20px; background: var(--accent); }

select, input, textarea { background: var(--card); color: var(--text); border: 1px solid var(--border); border-radius: 10px; padding: 9px 11px; font-size: 13.5px; }

.cat-box { background: var(--card); border: 1px solid var(--line); border-radius: 16px; padding: 14px 15px; margin-bottom: 10px; box-shadow: var(--shadow); }
.cat-row { margin-bottom: 11px; }
.cat-row:last-child { margin-bottom: 0; }
.cat-head { display: flex; justify-content: space-between; align-items: center; font-size: 13px; gap: 8px; }

.tx-list { display: flex; flex-direction: column; gap: 7px; }
.tx-item { background: var(--card); border: 1px solid var(--line); border-radius: 13px; padding: 11px 13px; display: flex; justify-content: space-between; align-items: center; gap: 8px; box-shadow: var(--shadow); }
.tx-meta { font-size: 11.5px; color: var(--muted); margin-top: 2px; line-height: 1.35; }
.tx-amt { font-weight: 700; font-size: 13.5px; color: var(--danger); white-space: nowrap; }

.small-btn { background: var(--card); color: var(--text); border: 1px solid var(--border); border-radius: 8px; padding: 4px 9px; font-size: 11.5px; font-weight: 600; cursor: pointer; display: inline-flex; align-items: center; gap: 4px; }

.bottom-nav {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  border-top: 1px solid var(--border);
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 4px;
  padding: 6px 8px calc(8px + env(safe-area-inset-bottom));
}
.bottom-nav.resident-3 { grid-template-columns: repeat(3, 1fr); }
.bottom-nav.has-board { grid-template-columns: repeat(5, 1fr); }
.house-facade-details.board-open { border: none; background: transparent; box-shadow: none; padding: 0; margin: 0; }
.house-facade-details.board-open > summary { display: none !important; }
.house-facade-details.board-open > .home-acc-body { padding: 0; border-top: none; }
.nav-item { background: none; border: none; color: var(--muted); cursor: pointer; display: flex; flex-direction: column; align-items: center; gap: 3px; padding: 5px 4px; border-radius: 12px; font-size: 10.5px; font-weight: 600; transition: background 0.15s ease, color 0.15s ease; }
.nav-item.active { color: var(--accent); background: var(--accent-soft); }

.modal-overlay { position: fixed; inset: 0; background: rgba(15, 23, 42, 0.45); display: none; align-items: flex-end; justify-content: center; z-index: 100; }
@media (min-width: 600px) { .modal-overlay { align-items: center; padding: 16px; } }
.modal-overlay.open { display: flex; }
.modal { background: var(--card); border-radius: 22px 22px 0 0; width: 100%; max-width: 480px; max-height: 88vh; overflow-y: auto; padding: 20px 18px calc(24px + env(safe-area-inset-bottom)); position: relative; box-shadow: 0 -4px 24px rgba(15, 23, 42, 0.12); }
@media (min-width: 600px) { .modal { border-radius: 20px; padding-bottom: 20px; } }
.modal-close { position: absolute; top: 14px; right: 16px; background: var(--surface); border: 1px solid var(--border); border-radius: 50%; width: 30px; height: 30px; color: var(--muted); font-size: 18px; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.modal-title { font-size: 17.5px; font-weight: 800; margin-bottom: 3px; padding-right: 36px; }
.modal-sub { font-size: 12.5px; color: var(--muted); margin-bottom: 14px; }
.srv-row { background: var(--surface); border: 1px solid var(--line); border-radius: 12px; padding: 10px 12px; margin-bottom: 8px; }
.srv-top { display: flex; justify-content: space-between; align-items: center; font-size: 13.5px; font-weight: 600; }
.srv-nums { font-size: 11.5px; color: var(--muted); margin-top: 3px; }
.form-group { margin-bottom: 12px; }
.form-group label { display: block; font-size: 12px; font-weight: 600; color: var(--muted); margin-bottom: 4px; }
.form-group input, .form-group select, .form-group textarea { width: 100%; }
.receipt-img { width: 100%; border-radius: 10px; margin-top: 8px; border: 1px solid var(--line); }

@media (min-width: 900px) {
  body { max-width: 1180px; padding: 20px 24px 40px; }
  header { padding: 0 0 20px; margin-bottom: 16px; border-bottom: 1px solid var(--border); }
  .bottom-nav, .bottom-nav.resident-3, .bottom-nav.has-board {
    position: static;
    background: var(--card);
    backdrop-filter: none;
    border: 1px solid var(--border);
    border-radius: 14px;
    padding: 4px;
    display: flex;
    gap: 4px;
    box-shadow: var(--shadow);
  }
  .nav-item { flex-direction: row; gap: 7px; padding: 8px 14px; font-size: 13px; }
  .nav-icon { height: auto; }
  .nav-icon .ic { width: 16px; height: 16px; }
  .desktop-grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 20px; align-items: start; }
  .desktop-col > .block-title:first-child { margin-top: 0; }
  .rep-slide { flex: 0 0 380px; }
}


/* Розширена картка квартири для правління */
.modal.wide { max-width: 640px; }
.apt-tabs {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 4px;
  background: #dce2ec;
  padding: 3px;
  border-radius: 12px;
  margin-bottom: 14px;
}
.apt-tab-btn {
  background: transparent;
  border: none;
  color: var(--muted);
  font-size: 12px;
  font-weight: 600;
  padding: 7px 4px;
  border-radius: 9px;
  cursor: pointer;
}
.apt-tab-btn.active {
  background: var(--card);
  color: var(--text);
  box-shadow: 0 1px 2px rgba(15, 23, 42, 0.08);
}
.info-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 8px;
  margin-bottom: 12px;
}
.info-cell {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 8px 10px;
}
.info-cell .lbl { font-size: 11px; color: var(--muted); font-weight: 600; }
.info-cell .val { font-size: 13.5px; font-weight: 700; margin-top: 2px; color: var(--text); }
.form-row-2 {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px;
}


/* Графіки на Мій дім */
.chart-wrap { position: relative; height: 210px; width: 100%; }
.chart-wrap-sm { height: 185px; }

/* Профіль мешканця та авто */
.profile-strip {
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid #dbeafe;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}
.avatar-img {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #bfdbfe;
  flex-shrink: 0;
  background: #e2e8f0;
}
.avatar-placeholder {
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--accent-soft);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: 800;
  font-size: 16px;
  flex-shrink: 0;
  border: 1px solid #bfdbfe;
}
.cars-wrap {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-top: 8px;
}
.car-chip {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 11.5px;
  font-weight: 600;
  background: #ffffff;
  border: 1px solid #cbd5e1;
  border-radius: 8px;
  padding: 4px 8px;
  color: var(--text);
}
.car-plate {
  background: #eff6ff;
  color: #1d4ed8;
  border: 1px solid #bfdbfe;
  border-radius: 4px;
  padding: 1px 5px;
  font-family: ui-monospace, SFMono-Regular, Menlo, monospace;
  font-weight: 800;
  font-size: 11px;
}
.preset-row {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  margin-bottom: 6px;
}
.chk-row {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  font-size: 13px;
}
.chk-row input[type="checkbox"] { width: auto; }
.meta-pills {
  display: flex;
  flex-wrap: wrap;
  gap: 5px;
  margin-top: 6px;
}
.meta-pill {
  font-size: 10.5px;
  font-weight: 600;
  padding: 2px 7px;
  border-radius: 6px;
  background: var(--surface);
  border: 1px solid var(--border);
  color: var(--muted);
}
.ann-card.pinned {
  border-left-color: var(--accent);
  background: #f8fbff;
}
.log-row {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: 11px;
  padding: 9px 11px;
  margin-bottom: 7px;
  font-size: 12.5px;
}
.log-top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  font-weight: 700;
}
.log-sub {
  font-size: 11.5px;
  color: var(--muted);
  margin-top: 3px;
  word-break: break-word;
}


/* Інтерактивні звіти */
.rep-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 10px;
}
.rep-pills {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}
.rep-pill {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 6px 11px;
  font-size: 12px;
  font-weight: 600;
  color: var(--muted);
  cursor: pointer;
  transition: all .15s;
}
.rep-pill:hover { border-color: var(--accent); color: var(--text); }
.rep-pill.active {
  background: var(--accent);
  color: #fff;
  border-color: var(--accent);
}
.rep-slide {
  cursor: pointer;
  border: 2px solid transparent;
  transition: border-color .15s, box-shadow .15s, transform .15s;
}
.rep-slide:hover { border-color: #bfdbfe; }
.rep-slide.active {
  border-color: var(--accent);
  box-shadow: 0 6px 18px rgba(37, 99, 235, 0.14);
}
.rep-slide-badge {
  font-size: 10.5px;
  font-weight: 700;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--surface);
  color: var(--muted);
  border: 1px solid var(--border);
}
.rep-slide.active .rep-slide-badge {
  background: var(--accent-soft);
  color: var(--accent);
  border-color: #bfdbfe;
}
.rep-dot { cursor: pointer; }


/* Банер режиму перегляду як мешканець */
.preview-banner {
  background: #eff6ff;
  border-bottom: 1px solid #bfdbfe;
  color: #1e40af;
  padding: 8px 16px;
  font-size: 12.5px;
  font-weight: 600;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}
