/* ==========================================================================
   CADÊ O VEREADOR? — SISTEMA DE DESIGN CÍVICO MOBILE-FIRST
   Zero overflow lateral, alta densidade e imagens sempre preservadas.
   ========================================================================== */

:root {
  --bg-page: #f8f9fa;
  --bg-surface: #ffffff;
  --bg-subtle: #f1f5f9;
  --text-main: #0f172a;
  --text-muted: #475569;
  --text-subtle: #64748b;
  --border: #e2e8f0;
  --border-light: #f1f5f9;

  /* Cores Temáticas */
  --c-blue: #2563eb;
  --c-blue-bg: #eff6ff;
  --c-blue-border: #bfdbfe;

  --c-amber: #d97706;
  --c-amber-bg: #fffbeb;
  --c-amber-border: #fde68a;

  --c-pink: #db2777;
  --c-pink-bg: #fdf2f8;
  --c-pink-border: #fbcfe8;

  --c-green: #059669;
  --c-green-bg: #ecfdf5;
  --c-green-border: #a7f3d0;

  --c-red: #e11d48;
  --c-red-bg: #fff1f2;
  --c-red-border: #fecdd3;

  --c-dark: #0f172a;

  --radius-sm: 6px;
  --radius-md: 10px;
  --radius-lg: 14px;
  --radius-xl: 18px;
  --radius-full: 9999px;

  --shadow-sm: 0 1px 2px 0 rgba(0, 0, 0, 0.04);
  --shadow-md: 0 4px 6px -1px rgba(0, 0, 0, 0.06), 0 2px 4px -2px rgba(0, 0, 0, 0.04);
  --shadow-lg: 0 10px 15px -3px rgba(0, 0, 0, 0.08);
}

*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  max-width: 100%;
}

html {
  scroll-behavior: smooth;
  -webkit-text-size-adjust: 100%;
  overflow-x: hidden;
  width: 100%;
  max-width: 100%;
}

body {
  width: 100%;
  max-width: 100vw;
  overflow-x: hidden;
  position: relative;
  background-color: var(--bg-page);
  color: var(--text-main);
  font-family: 'DM Sans', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

img {
  max-width: 100%;
  height: auto;
  display: block;
}

.wrap {
  width: 100%;
  max-width: 1140px;
  margin: 0 auto;
  padding: 0 12px;
}

@media (min-width: 480px) {
  .wrap {
    padding: 0 16px;
  }
}

@media (min-width: 768px) {
  .wrap {
    padding: 0 24px;
  }
}

/* ==========================================================================
   HEADER & MENU HAMBÚRGUER
   ========================================================================== */
.site-header {
  width: 100%;
  max-width: 100%;
  background: #ffffff;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 0;
  z-index: 50;
  backdrop-filter: blur(8px);
  background-color: rgba(255, 255, 255, 0.96);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 54px;
  gap: 8px;
  min-width: 0;
}

@media (min-width: 768px) {
  .header-inner {
    height: 62px;
  }
}

.brand {
  display: flex;
  align-items: center;
  gap: 8px;
  text-decoration: none;
  color: var(--text-main);
  min-width: 0;
  flex: 1;
  overflow: hidden;
}

.brand-signal {
  color: #dc2626;
  font-size: 1.15rem;
  line-height: 1;
  animation: pulse 2s infinite;
  flex-shrink: 0;
}

@keyframes pulse {
  0%, 100% { opacity: 1; transform: scale(1); }
  50% { opacity: 0.35; transform: scale(0.92); }
}

.brand-title {
  font-family: 'Manrope', sans-serif;
  font-weight: 800;
  font-size: 0.92rem;
  letter-spacing: -0.02em;
  display: flex;
  align-items: center;
  gap: 6px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.brand-title span {
  display: none;
}

@media (min-width: 580px) {
  .brand-title {
    font-size: 1.05rem;
  }
  .brand-title span {
    display: inline-block;
    font-weight: 700;
    font-size: 0.65rem;
    color: var(--c-blue);
    background: var(--c-blue-bg);
    border: 1px solid var(--c-blue-border);
    padding: 1px 5px;
    border-radius: var(--radius-sm);
    letter-spacing: 0.04em;
  }
}

.header-nav {
  display: none;
}

@media (min-width: 860px) {
  .header-nav {
    display: flex;
    gap: 16px;
  }
  .header-nav a {
    text-decoration: none;
    font-size: 0.88rem;
    font-weight: 600;
    color: var(--text-muted);
    transition: color 0.15s;
  }
  .header-nav a:hover {
    color: var(--c-blue);
  }
}

/* BOTÃO HAMBÚRGUER MOBILE */
.menu-toggle {
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  width: 40px;
  height: 40px;
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  cursor: pointer;
  padding: 0;
  gap: 5px;
  transition: all 0.2s ease;
  flex-shrink: 0;
}

@media (min-width: 860px) {
  .menu-toggle {
    display: none !important;
  }
}

.hamburger-bar {
  display: block;
  width: 20px;
  height: 2px;
  background-color: var(--text-main);
  border-radius: 2px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.menu-toggle.is-active .hamburger-bar:nth-child(1) {
  transform: translateY(7px) rotate(45deg);
}
.menu-toggle.is-active .hamburger-bar:nth-child(2) {
  opacity: 0;
}
.menu-toggle.is-active .hamburger-bar:nth-child(3) {
  transform: translateY(-7px) rotate(-45deg);
}

/* GAVETA DO MENU MOBILE (DROPDOWN) */
.mobile-drawer {
  display: none;
  background: #ffffff;
  border-top: 1px solid var(--border-light);
  border-bottom: 2px solid var(--border);
  box-shadow: var(--shadow-lg);
  padding: 10px 14px 16px;
}

@media (min-width: 860px) {
  .mobile-drawer {
    display: none !important;
  }
}

.mobile-drawer.is-open {
  display: block;
  animation: slideDown 0.2s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes slideDown {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}

.drawer-nav {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.drawer-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 12px;
  border-radius: var(--radius-md);
  color: var(--text-main);
  text-decoration: none;
  font-size: 0.92rem;
  font-weight: 700;
  background: var(--bg-subtle);
  border: 1px solid transparent;
  transition: all 0.15s ease;
}

.drawer-link:active, .drawer-link:hover {
  background: var(--c-blue-bg);
  border-color: var(--c-blue-border);
  color: var(--c-blue);
}

.drawer-icon {
  font-size: 1.15rem;
  line-height: 1;
}

/* SUBNAV RÁPIDA (SWIPE HORIZONTAL PARA MOBILE) */
.mobile-subnav {
  width: 100%;
  max-width: 100vw;
  overflow: hidden;
  background: #ffffff;
  border-bottom: 1px solid var(--border);
  position: sticky;
  top: 54px;
  z-index: 40;
}

@media (min-width: 860px) {
  .mobile-subnav {
    display: none;
  }
}

.mobile-subnav-inner {
  display: flex;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding: 8px 12px;
  gap: 8px;
  scrollbar-width: none;
  width: 100%;
}

.mobile-subnav-inner::-webkit-scrollbar {
  display: none;
}

.subnav-pill {
  flex-shrink: 0;
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  padding: 5px 11px;
  border-radius: var(--radius-full);
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--text-muted);
  text-decoration: none;
  white-space: nowrap;
  transition: all 0.15s ease;
}

.subnav-pill:active {
  background: var(--c-blue-bg);
  border-color: var(--c-blue-border);
  color: var(--c-blue);
}

/* ==========================================================================
   HERO & SALÁRIO ACUMULADO
   ========================================================================== */
.hero {
  padding: 16px 0;
}

.hero-live-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: #fef2f2;
  color: #b91c1c;
  border: 1px solid #fecaca;
  padding: 3px 9px;
  border-radius: var(--radius-full);
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  margin-bottom: 10px;
}

.hero-live-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: #dc2626;
}

.hero-title {
  font-family: 'Manrope', sans-serif;
  font-size: clamp(1.35rem, 5.5vw, 2.2rem);
  font-weight: 800;
  line-height: 1.18;
  letter-spacing: -0.03em;
  color: var(--text-main);
  margin-bottom: 8px;
  word-break: break-word;
}

.hero-title span {
  color: var(--c-blue);
}

.hero-subtitle {
  font-size: 0.86rem;
  color: var(--text-muted);
  line-height: 1.45;
  margin-bottom: 14px;
}

/* CARD PRETO DE SALÁRIO DO MANDATO */
.salary-card {
  width: 100%;
  max-width: 100%;
  background: linear-gradient(145deg, #0f172a 0%, #1e293b 100%);
  color: #ffffff;
  border-radius: var(--radius-lg);
  padding: 16px 14px;
  box-shadow: var(--shadow-md);
  margin-bottom: 14px;
  position: relative;
  overflow: hidden;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

@media (min-width: 768px) {
  .salary-card {
    padding: 24px 22px;
    border-radius: var(--radius-xl);
  }
}

.salary-label {
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: #94a3b8;
  margin-bottom: 6px;
  line-height: 1.3;
  word-break: break-word;
}

.salary-amount {
  font-family: 'Manrope', -apple-system, sans-serif;
  font-size: clamp(1.4rem, 6.5vw, 2.4rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: #ffffff;
  line-height: 1.15;
  margin-bottom: 6px;
  word-break: break-all;
}

.salary-details {
  font-size: 0.76rem;
  color: #cbd5e1;
  line-height: 1.35;
}

.salary-details strong {
  color: #38bdf8;
}

/* Pílulas de Estatísticas Rápidas (2x2 no Mobile) */
.quick-pills {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  margin-bottom: 10px;
  width: 100%;
}

@media (min-width: 768px) {
  .quick-pills {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
  }
}

.quick-pill {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 10px;
  display: flex;
  flex-direction: column;
  box-shadow: var(--shadow-sm);
  min-width: 0;
}

.quick-pill-num {
  font-family: 'Manrope', sans-serif;
  font-size: 1.2rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.1;
}

.quick-pill-label {
  font-size: 0.7rem;
  font-weight: 500;
  color: var(--text-subtle);
  margin-top: 3px;
  line-height: 1.25;
}

.hero-audit-date {
  font-size: 0.73rem;
  color: var(--text-subtle);
  margin-bottom: 20px;
}

/* ==========================================================================
   SEÇÕES GERAIS
   ========================================================================== */
.section {
  padding: 20px 0;
}

.section-head {
  margin-bottom: 14px;
}

.eyebrow {
  display: inline-block;
  font-size: 0.7rem;
  font-weight: 800;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--c-blue);
  margin-bottom: 3px;
}

.eyebrow.alert {
  color: var(--c-red);
}

.section-title {
  font-family: 'Manrope', sans-serif;
  font-size: clamp(1.2rem, 4.5vw, 1.75rem);
  font-weight: 800;
  letter-spacing: -0.02em;
  color: var(--text-main);
  margin-bottom: 4px;
  word-break: break-word;
}

.section-subtitle {
  font-size: 0.84rem;
  color: var(--text-muted);
  line-height: 1.4;
}

/* ==========================================================================
   BUSCA LOCAL & BAIRROS
   ========================================================================== */
.search-box {
  background: var(--bg-surface);
  border: 1.5px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 3px 5px 3px 10px;
  display: flex;
  align-items: center;
  gap: 6px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 10px;
  min-height: 48px;
  width: 100%;
}

.search-box:focus-within {
  border-color: var(--c-blue);
  box-shadow: 0 0 0 3px rgba(37, 99, 235, 0.12);
}

.search-icon {
  font-size: 1.1rem;
  color: var(--text-subtle);
  flex-shrink: 0;
}

.search-input {
  flex: 1;
  border: none;
  outline: none;
  font-size: 0.92rem;
  font-family: inherit;
  background: transparent;
  color: var(--text-main);
  min-width: 0;
}

.search-btn {
  background: var(--text-main);
  color: #ffffff;
  border: none;
  font-family: inherit;
  font-weight: 700;
  font-size: 0.82rem;
  padding: 9px 14px;
  border-radius: var(--radius-md);
  cursor: pointer;
  flex-shrink: 0;
  min-height: 38px;
}

.search-btn:active {
  background: #334155;
}

/* ATALHOS DE BAIRROS (SWIPE HORIZONTAL NO MOBILE) */
.quick-tags {
  display: flex;
  flex-wrap: nowrap;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  width: 100%;
  max-width: 100%;
  padding: 3px 2px 10px;
  gap: 7px;
  margin-bottom: 18px;
  scrollbar-width: none;
}

.quick-tags::-webkit-scrollbar {
  display: none;
}

.quick-tag {
  flex-shrink: 0;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  padding: 5px 11px;
  border-radius: var(--radius-full);
  font-size: 0.76rem;
  font-weight: 600;
  color: var(--text-muted);
  cursor: pointer;
  white-space: nowrap;
  box-shadow: var(--shadow-sm);
  transition: all 0.15s ease;
}

.quick-tag:active, .quick-tag:hover {
  border-color: var(--c-blue);
  color: var(--c-blue);
  background: var(--c-blue-bg);
}

/* PAINEL DE 3 COLUNAS DO MODELO */
.city-breakdown {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 14px 12px;
  box-shadow: var(--shadow-sm);
  margin-bottom: 20px;
  width: 100%;
  overflow: hidden;
}

.breakdown-header {
  border-bottom: 1px solid var(--border-light);
  padding-bottom: 10px;
  margin-bottom: 14px;
}

.breakdown-big-num {
  font-family: 'Manrope', sans-serif;
  font-size: 1.6rem;
  font-weight: 800;
  color: var(--c-blue);
  line-height: 1.1;
}

.breakdown-big-label {
  font-size: 0.78rem;
  color: var(--text-muted);
}

.breakdown-cols {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
  min-width: 0;
}

@media (min-width: 860px) {
  .breakdown-cols {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.col-title {
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-subtle);
  margin-bottom: 8px;
}

.rank-item {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 8px;
  min-width: 0;
}

.rank-photo {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  object-fit: cover;
  background: var(--bg-subtle);
  flex-shrink: 0;
}

.rank-info {
  flex: 1;
  min-width: 0;
}

.rank-name-row {
  display: flex;
  justify-content: space-between;
  font-size: 0.76rem;
  font-weight: 600;
  margin-bottom: 3px;
  min-width: 0;
}

.rank-name-row span {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.rank-count {
  font-family: 'Manrope', monospace;
  font-weight: 700;
  color: var(--text-muted);
  margin-left: 6px;
  flex-shrink: 0;
}

.progress-track {
  height: 6px;
  background: var(--bg-subtle);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.progress-bar {
  height: 100%;
  border-radius: var(--radius-full);
  background: var(--c-blue);
}

.progress-bar.amber { background: var(--c-amber); }
.progress-bar.green { background: var(--c-green); }

/* FEED DE PEDIDOS RECENTES */
.feed-header {
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text-subtle);
  margin-bottom: 10px;
}

.request-card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 11px 12px;
  margin-bottom: 9px;
  box-shadow: var(--shadow-sm);
  width: 100%;
  overflow: hidden;
}

.request-top {
  display: flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 6px;
  flex-wrap: wrap;
}

.badge {
  display: inline-flex;
  align-items: center;
  padding: 2px 6px;
  border-radius: var(--radius-sm);
  font-size: 0.66rem;
  font-weight: 700;
  text-transform: uppercase;
  line-height: 1.3;
}

.badge-blue { background: var(--c-blue-bg); color: var(--c-blue); border: 1px solid var(--c-blue-border); }
.badge-amber { background: var(--c-amber-bg); color: var(--c-amber); border: 1px solid var(--c-amber-border); }
.badge-gray { background: var(--bg-subtle); color: var(--text-subtle); }

.request-date {
  font-size: 0.68rem;
  color: var(--text-subtle);
  margin-left: auto;
}

.request-title {
  font-size: 0.84rem;
  font-weight: 500;
  color: var(--text-main);
  line-height: 1.35;
  margin-bottom: 8px;
  word-break: break-word;
  overflow-wrap: break-word;
}

.request-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 0.74rem;
  border-top: 1px solid var(--border-light);
  padding-top: 7px;
  gap: 8px;
}

.request-author {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--text-muted);
  font-weight: 600;
  min-width: 0;
  overflow: hidden;
}

.request-author img {
  width: 20px;
  height: 20px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
}

.request-author span {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.request-link {
  color: var(--c-blue);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.74rem;
  white-space: nowrap;
  flex-shrink: 0;
}

/* ==========================================================================
   ALERTAS ("O PROBLEMA QUE NÃO SOME")
   ========================================================================== */
.alert-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  width: 100%;
}

@media (min-width: 680px) {
  .alert-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  .alert-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
  }
}

.alert-card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 12px;
  display: flex;
  align-items: flex-start;
  gap: 10px;
  box-shadow: var(--shadow-sm);
  width: 100%;
  overflow: hidden;
}

.alert-badge-col {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-width: 46px;
  padding: 6px 4px;
  background: var(--c-red-bg);
  border: 1px solid var(--c-red-border);
  border-radius: var(--radius-md);
  flex-shrink: 0;
}

.alert-big-number {
  font-family: 'Manrope', sans-serif;
  font-size: 1.5rem;
  font-weight: 800;
  color: var(--c-red);
  line-height: 1;
}

.alert-unit {
  font-size: 0.62rem;
  font-weight: 700;
  color: var(--c-red);
  text-transform: uppercase;
  margin-top: 2px;
}

.alert-info-col {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.alert-street {
  font-size: 0.9rem;
  font-weight: 700;
  color: var(--text-main);
  line-height: 1.25;
  margin-bottom: 2px;
  word-break: break-word;
  overflow-wrap: break-word;
}

.alert-neighborhood {
  font-size: 0.74rem;
  color: var(--text-subtle);
  margin-bottom: 5px;
}

.alert-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 4px;
  margin-bottom: 6px;
}

.alert-action-link {
  color: var(--c-red);
  font-weight: 700;
  font-size: 0.76rem;
  text-decoration: none;
  align-self: flex-start;
}

/* ==========================================================================
   HOMENAGEM OU TRABALHO? (2x2 NO MOBILE)
   ========================================================================== */
.themes-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  width: 100%;
}

@media (min-width: 768px) {
  .themes-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 12px;
  }
}

.theme-card {
  border-radius: var(--radius-lg);
  padding: 10px;
  display: flex;
  flex-direction: column;
  text-decoration: none;
  border: 1px solid transparent;
  box-shadow: var(--shadow-sm);
  min-width: 0;
  overflow: hidden;
}

.theme-card.blue { background: var(--c-blue-bg); border-color: var(--c-blue-border); color: #1e3a8a; }
.theme-card.amber { background: var(--c-amber-bg); border-color: var(--c-amber-border); color: #78350f; }
.theme-card.pink { background: var(--c-pink-bg); border-color: var(--c-pink-border); color: #831843; }
.theme-card.green { background: var(--c-green-bg); border-color: var(--c-green-border); color: #064e3b; }

.theme-count {
  font-family: 'Manrope', sans-serif;
  font-size: 1.25rem;
  font-weight: 800;
  line-height: 1.1;
  margin-bottom: 2px;
}

.theme-pct {
  font-size: 0.7rem;
  font-weight: 700;
  opacity: 0.85;
  margin-bottom: 3px;
}

.theme-name {
  font-size: 0.8rem;
  font-weight: 700;
  line-height: 1.2;
}

.theme-desc {
  display: none;
}

@media (min-width: 768px) {
  .theme-desc {
    display: block;
    font-size: 0.78rem;
    opacity: 0.85;
    margin-top: 8px;
  }
  .theme-count {
    font-size: 1.7rem;
  }
}

/* ==========================================================================
   CARDS DOS 23 VEREADORES (ALTA DENSIDADE MOBILE)
   ========================================================================== */
.controls-bar {
  display: flex;
  flex-direction: column;
  gap: 8px;
  margin-bottom: 10px;
  width: 100%;
}

@media (min-width: 640px) {
  .controls-bar {
    flex-direction: row;
  }
}

.control-input, .control-select {
  padding: 9px 11px;
  border-radius: var(--radius-md);
  border: 1px solid var(--border);
  background: var(--bg-surface);
  font-family: inherit;
  font-size: 0.84rem;
  outline: none;
  min-height: 42px;
  width: 100%;
}

.control-input:focus, .control-select:focus {
  border-color: var(--c-blue);
}

.v-count-bar {
  margin-bottom: 12px;
}

#v-count-badge {
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--text-subtle);
  background: var(--bg-subtle);
  padding: 3px 8px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}

.vereadores-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 12px;
  width: 100%;
}

@media (min-width: 640px) {
  .vereadores-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  .vereadores-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 16px;
  }
}

.v-card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
  width: 100%;
  box-sizing: border-box;
}

.v-card-top {
  padding: 10px 12px;
  display: flex;
  align-items: center;
  gap: 10px;
  border-bottom: 1px solid var(--border-light);
  background: linear-gradient(180deg, #f8fafc 0%, #ffffff 100%);
  min-width: 0;
}

.v-card-photo {
  width: 46px;
  height: 46px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #ffffff;
  box-shadow: 0 1px 3px rgba(0,0,0,0.12);
  background: var(--bg-subtle);
  flex-shrink: 0;
}

.v-card-id {
  flex: 1;
  min-width: 0;
  overflow: hidden;
}

.v-card-name-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 6px;
  margin-bottom: 2px;
  min-width: 0;
}

.v-card-name {
  font-family: 'Manrope', sans-serif;
  font-size: 0.94rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.2;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

.v-presenca-badge {
  font-family: 'Manrope', sans-serif;
  font-size: 0.68rem;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: var(--radius-full);
  background: var(--c-green-bg);
  color: var(--c-green);
  border: 1px solid var(--c-green-border);
  white-space: nowrap;
  flex-shrink: 0;
}

.v-presenca-badge.amber {
  background: var(--c-amber-bg);
  color: var(--c-amber);
  border-color: var(--c-amber-border);
}

.v-presenca-badge.red {
  background: var(--c-red-bg);
  color: var(--c-red);
  border-color: var(--c-red-border);
}

.v-card-meta-row {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 0.72rem;
  min-width: 0;
}

.party-badge {
  background: #0f172a;
  color: #ffffff;
  font-size: 0.65rem;
  font-weight: 800;
  padding: 2px 6px;
  border-radius: var(--radius-sm);
  letter-spacing: 0.04em;
  flex-shrink: 0;
}

.v-eleicao-tag {
  font-size: 0.7rem;
  color: var(--text-subtle);
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  min-width: 0;
}

/* Faixa de Presença */
.v-presence-strip {
  padding: 8px 12px;
  border-bottom: 1px solid var(--border-light);
  background: #fcfcfc;
}

.v-presence-progress {
  height: 5px;
  background: var(--bg-subtle);
  border-radius: var(--radius-full);
  overflow: hidden;
  margin-bottom: 4px;
}

.v-presence-bar {
  height: 100%;
  background: var(--c-green);
  border-radius: var(--radius-full);
}

.v-presence-bar.amber { background: var(--c-amber); }
.v-presence-bar.red { background: var(--c-red); }

.v-presence-legend {
  display: flex;
  justify-content: space-between;
  font-size: 0.7rem;
  color: var(--text-muted);
}

.v-presence-legend strong {
  color: var(--text-main);
}

.falta-tag {
  color: var(--c-red);
  font-weight: 700;
}

/* Micro-Grid Custo, Propostas e Plenário */
.v-stats-row {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  padding: 7px 4px;
  background: #f8fafc;
  border-bottom: 1px solid var(--border-light);
  text-align: center;
  gap: 2px;
}

.v-stat-item {
  display: flex;
  flex-direction: column;
  min-width: 0;
}

.v-stat-val {
  font-family: 'Manrope', sans-serif;
  font-size: 0.82rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.15;
}

.v-stat-lbl {
  font-size: 0.6rem;
  color: var(--text-subtle);
  margin-top: 2px;
  line-height: 1.2;
  word-break: break-word;
}

/* Bloco Propostas */
.v-proposals-block {
  padding: 9px 12px;
  border-bottom: 1px solid var(--border-light);
}

.v-block-label {
  font-size: 0.64rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-subtle);
  margin-bottom: 5px;
}

.v-prop-list {
  list-style: none;
}

.v-prop-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 0.75rem;
  padding: 2px 0;
  color: var(--text-muted);
}

.v-prop-bullet {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  display: inline-block;
  margin-right: 5px;
  flex-shrink: 0;
}

.v-prop-bullet.blue { background: var(--c-blue); }
.v-prop-bullet.amber { background: var(--c-amber); }
.v-prop-bullet.pink { background: var(--c-pink); }
.v-prop-bullet.green { background: var(--c-green); }
.v-prop-bullet.gray { background: #94a3b8; }

.v-prop-num {
  font-family: 'Manrope', monospace;
  font-weight: 700;
  color: var(--text-main);
}

/* Bloco Votações */
.v-votes-block {
  padding: 9px 12px;
  border-bottom: 1px solid var(--border-light);
}

.v-votes-dual {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px;
  margin-bottom: 5px;
}

.v-vote-box {
  padding: 5px 6px;
  border-radius: var(--radius-sm);
  text-align: center;
}

.v-vote-box.yes { background: var(--c-green-bg); border: 1px solid var(--c-green-border); color: #064e3b; }
.v-vote-box.no { background: var(--c-red-bg); border: 1px solid var(--c-red-border); color: #881337; }

.v-vote-num {
  font-family: 'Manrope', sans-serif;
  font-weight: 800;
  font-size: 0.95rem;
  line-height: 1;
}

.v-vote-lbl {
  font-size: 0.62rem;
  font-weight: 700;
  text-transform: uppercase;
}

.v-card-footer {
  padding: 9px 12px;
  margin-top: auto;
}

.btn-open-profile {
  width: 100%;
  min-height: 42px;
  background: var(--bg-subtle);
  color: var(--text-main);
  border: 1px solid var(--border);
  font-family: inherit;
  font-weight: 700;
  font-size: 0.82rem;
  padding: 8px 10px;
  border-radius: var(--radius-md);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.15s ease;
}

.btn-open-profile:active {
  background: var(--c-blue-bg);
  border-color: var(--c-blue-border);
  color: var(--c-blue);
}

/* ==========================================================================
   TRANSPARÊNCIA
   ========================================================================== */
.transparency-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  width: 100%;
}

@media (min-width: 640px) {
  .transparency-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (min-width: 1024px) {
  .transparency-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 14px;
  }
}

.transparency-card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 12px 14px;
  box-shadow: var(--shadow-sm);
  width: 100%;
  overflow: hidden;
}

.transparency-card h4 {
  font-size: 0.92rem;
  font-weight: 700;
  margin-bottom: 5px;
}

.transparency-card p {
  font-size: 0.78rem;
  color: var(--text-muted);
  line-height: 1.35;
  margin-bottom: 7px;
}

.transparency-card a {
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--c-blue);
  text-decoration: none;
}

/* ==========================================================================
   FOOTER
   ========================================================================== */
.site-footer {
  background: #ffffff;
  border-top: 1px solid var(--border);
  padding: 24px 0;
  margin-top: 30px;
  width: 100%;
}

.footer-content {
  text-align: center;
  font-size: 0.78rem;
  color: var(--text-subtle);
  word-break: break-word;
}

.footer-content b {
  color: var(--text-main);
}

/* ==========================================================================
   MODAL DE DETALHES (BOTTOM SHEET NO MOBILE)
   ========================================================================== */
dialog#details {
  border: none;
  background: #ffffff;
  color: var(--text-main);
  box-shadow: 0 20px 40px -10px rgba(0, 0, 0, 0.35);
  margin: auto;
  max-width: 640px;
  width: 94%;
  border-radius: var(--radius-lg);
  outline: none;
}

@media (max-width: 640px) {
  dialog#details {
    width: 100%;
    max-width: 100%;
    position: fixed;
    bottom: 0;
    top: auto;
    margin: 0;
    border-radius: 18px 18px 0 0;
    max-height: 90vh;
  }
}

dialog#details::backdrop {
  background: rgba(15, 23, 42, 0.65);
  backdrop-filter: blur(4px);
}

.dialog-inner {
  padding: 16px 14px;
  max-height: 85vh;
  overflow-y: auto;
  -webkit-overflow-scrolling: touch;
}

.dialog-drag-handle {
  width: 36px;
  height: 4px;
  background: var(--border);
  border-radius: var(--radius-full);
  margin: 0 auto 10px;
  display: block;
}

@media (min-width: 641px) {
  .dialog-drag-handle {
    display: none;
  }
}

.dialog-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  border-bottom: 1px solid var(--border);
  padding-bottom: 10px;
  margin-bottom: 12px;
}

.dialog-close {
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  border-radius: 50%;
  width: 34px;
  height: 34px;
  font-size: 1.3rem;
  color: var(--text-subtle);
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  line-height: 1;
  flex-shrink: 0;
}

.dialog-close:active {
  background: var(--border);
}

/* ==========================================================================
   AVISO DA SESSÃO PLENÁRIA
   ========================================================================== */
.session-alert-banner {
  margin-top: 14px;
  background: #f0fdf4;
  border: 1px solid #bbf7d0;
  border-radius: var(--radius-md);
  padding: 10px 14px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.session-alert-content {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.85rem;
  color: #166534;
}

.session-pulse-dot {
  width: 9px;
  height: 9px;
  border-radius: 50%;
  background: #22c55e;
  box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7);
  animation: pulse-session 2s infinite;
  display: inline-block;
  flex-shrink: 0;
}

@keyframes pulse-session {
  0% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0.7); }
  70% { box-shadow: 0 0 0 8px rgba(34, 197, 94, 0); }
  100% { box-shadow: 0 0 0 0 rgba(34, 197, 94, 0); }
}

.session-alert-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.session-btn {
  font-size: 0.75rem;
  font-weight: 700;
  padding: 6px 12px;
  border-radius: var(--radius-full);
  text-decoration: none;
  transition: all 0.15s ease;
  white-space: nowrap;
}

.session-btn.pauta {
  background: #166534;
  color: #ffffff;
}

.session-btn.pauta:hover, .session-btn.pauta:active {
  background: #14532d;
}

.session-btn.tv {
  background: #ffffff;
  color: #166534;
  border: 1px solid #bbf7d0;
}

.session-btn.tv:hover, .session-btn.tv:active {
  background: #dcfce7;
}

/* ==========================================================================
   VIAGENS E DIÁRIAS OFICIAIS
   ========================================================================== */
.viagens-summary-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 10px;
  margin-bottom: 20px;
}

@media (min-width: 640px) {
  .viagens-summary-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

.v-sum-card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 14px 16px;
  box-shadow: var(--shadow-sm);
  display: flex;
  flex-direction: column;
}

.v-sum-card.dark {
  background: #0f172a;
  border-color: #1e293b;
  color: #ffffff;
}

.v-sum-lbl {
  font-size: 0.64rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-subtle);
  margin-bottom: 4px;
}

.v-sum-card.dark .v-sum-lbl {
  color: #94a3b8;
}

.v-sum-val {
  font-family: 'Manrope', sans-serif;
  font-size: clamp(1.2rem, 3.5vw, 1.6rem);
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.15;
  margin-bottom: 4px;
}

.v-sum-card.dark .v-sum-val {
  color: #38bdf8;
}

.v-sum-sub {
  font-size: 0.72rem;
  color: var(--text-muted);
}

.v-sum-card.dark .v-sum-sub {
  color: #cbd5e1;
}

.viagens-layout-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: 16px;
}

@media (min-width: 860px) {
  .viagens-layout-grid {
    grid-template-columns: 1.15fr 0.85fr;
    gap: 20px;
  }
}

.viagens-col {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 16px;
  box-shadow: var(--shadow-sm);
}

.col-title {
  font-size: 0.72rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  text-transform: uppercase;
  color: var(--text-subtle);
  margin-bottom: 12px;
  padding-bottom: 6px;
  border-bottom: 1px solid var(--border-light);
}

.viagem-rank-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 8px 0;
  border-bottom: 1px solid var(--border-light);
}

.viagem-rank-item:last-child {
  border-bottom: none;
}

.v-rank-avatar {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  object-fit: cover;
  flex-shrink: 0;
  background: var(--bg-subtle);
  border: 1px solid var(--border);
}

.v-rank-info {
  flex: 1;
  min-width: 0;
}

.v-rank-name {
  font-size: 0.82rem;
  font-weight: 700;
  color: var(--text-main);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.v-rank-party {
  font-size: 0.68rem;
  color: var(--text-subtle);
}

.v-rank-bar-wrap {
  width: 100%;
  height: 6px;
  background: var(--bg-subtle);
  border-radius: var(--radius-full);
  margin-top: 4px;
  overflow: hidden;
}

.v-rank-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--c-blue), #0284c7);
  border-radius: var(--radius-full);
}

.v-rank-stats {
  text-align: right;
  flex-shrink: 0;
}

.v-rank-val {
  font-family: 'Manrope', sans-serif;
  font-size: 0.82rem;
  font-weight: 800;
  color: var(--text-main);
}

.v-rank-trips {
  font-size: 0.68rem;
  color: var(--text-subtle);
}

.destino-item {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 7px 0;
  border-bottom: 1px solid var(--border-light);
  font-size: 0.8rem;
}

.destino-item:last-child {
  border-bottom: none;
}

.destino-name {
  color: var(--text-muted);
  font-weight: 500;
  padding-right: 8px;
}

.destino-badge {
  background: var(--c-blue-bg);
  color: var(--c-blue);
  border: 1px solid var(--c-blue-border);
  padding: 2px 8px;
  border-radius: var(--radius-full);
  font-weight: 700;
  font-size: 0.72rem;
  white-space: nowrap;
}

.trip-card {
  padding: 10px;
  border-radius: var(--radius-md);
  background: var(--bg-subtle);
  border: 1px solid var(--border);
  margin-bottom: 8px;
  font-size: 0.78rem;
}

.trip-card:last-child {
  margin-bottom: 0;
}

.trip-header {
  display: flex;
  justify-content: space-between;
  gap: 6px;
  margin-bottom: 4px;
}

.trip-who {
  font-weight: 700;
  color: var(--text-main);
}

.trip-cost {
  font-family: 'Manrope', sans-serif;
  font-weight: 800;
  color: var(--c-blue);
}

.trip-dest {
  color: var(--text-muted);
  margin-bottom: 4px;
}

.trip-motive {
  color: var(--text-subtle);
  font-size: 0.72rem;
  line-height: 1.35;
  margin-bottom: 4px;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.trip-footer {
  display: flex;
  justify-content: space-between;
  font-size: 0.68rem;
  color: var(--text-subtle);
}

/* ==========================================================================
   COMPARADOR LADO A LADO
   ========================================================================== */
.comparador-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 14px;
  margin-bottom: 18px;
  box-shadow: var(--shadow-sm);
  flex-wrap: wrap;
}

.comp-select-box {
  flex: 1;
  min-width: 220px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.comp-label {
  font-size: 0.65rem;
  font-weight: 800;
  letter-spacing: 0.05em;
  color: var(--text-subtle);
}

.comp-vs-badge {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--c-dark);
  color: #ffffff;
  font-family: 'Manrope', sans-serif;
  font-weight: 800;
  font-size: 0.8rem;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  margin-top: 14px;
}

@media (max-width: 600px) {
  .comp-vs-badge {
    margin: 4px auto;
  }
}

.comparador-result {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  overflow: hidden;
}

.comp-header-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  border-bottom: 1px solid var(--border);
  background: var(--bg-subtle);
}

.comp-person-header {
  padding: 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 8px;
}

.comp-person-header:first-child {
  border-right: 1px solid var(--border);
}

.comp-avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid #ffffff;
  box-shadow: var(--shadow-sm);
  background: #cbd5e1;
}

.comp-person-name {
  font-family: 'Manrope', sans-serif;
  font-size: 1rem;
  font-weight: 800;
  color: var(--text-main);
  line-height: 1.2;
}

.comp-person-party {
  font-size: 0.72rem;
  font-weight: 700;
  color: var(--text-muted);
}

.comp-row {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  padding: 10px 12px;
  border-bottom: 1px solid var(--border-light);
  font-size: 0.84rem;
}

.comp-row:last-child {
  border-bottom: none;
}

.comp-row:nth-child(even) {
  background: #fafbfc;
}

.comp-side-val {
  font-family: 'Manrope', sans-serif;
  font-weight: 700;
}

.comp-side-val.left {
  text-align: right;
  padding-right: 10px;
}

.comp-side-val.right {
  text-align: left;
  padding-left: 10px;
}

.comp-side-val.leader {
  color: var(--c-blue);
  font-weight: 800;
}

.comp-metric-label {
  font-size: 0.72rem;
  font-weight: 800;
  color: var(--text-subtle);
  text-transform: uppercase;
  text-align: center;
  letter-spacing: 0.04em;
  padding: 3px 8px;
  background: var(--bg-subtle);
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-light);
  min-width: 120px;
}

/* ==========================================================================
   ESTILOS DE IMPRESSÃO & PDF (@media print)
   ========================================================================== */
@media print {
  body {
    background: #ffffff !important;
    color: #000000 !important;
    font-size: 10pt !important;
  }

  .site-header,
  .mobile-subnav,
  .search-box,
  .quick-tags,
  .controls-bar,
  .btn-open-profile,
  .request-link,
  .alert-action-link,
  dialog {
    display: none !important;
  }

  .wrap {
    max-width: 100% !important;
    padding: 0 !important;
  }

  .salary-card {
    background: #0f172a !important;
    color: #ffffff !important;
    -webkit-print-color-adjust: exact;
    print-color-adjust: exact;
    page-break-inside: avoid;
    break-inside: avoid;
  }

  .v-card,
  .alert-card,
  .request-card,
  .theme-card,
  .quick-pill,
  .transparency-card {
    page-break-inside: avoid !important;
    break-inside: avoid !important;
    border: 1px solid #d1d5db !important;
    box-shadow: none !important;
    margin-bottom: 10pt !important;
  }

  .badge {
    border: 1px solid #999 !important;
    margin-right: 6px !important;
  }

  .request-top span {
    margin-right: 6px !important;
  }
}
