/* Custom Mobile Navigation Styles for Portrait/Vertical Mobile */

/* Hide Observable Framework's default header */
.observablehq-header,
header[data-observablehq],
[data-observablehq-header] {
  display: none !important;
}

/* Remove border from Observable header div */
#observablehq-header {
  border-bottom: none !important;
  left: 0 !important;
  right: 0 !important;
  position: static !important;
}

/* Style the Observable Framework header */
.custom-header {

  background: white;
  border-bottom: 1px solid #e5e7eb;
  padding-top: 1rem;
  padding-bottom: 0.5rem;
  margin-top: 1rem;
  margin-bottom: -1px;
  position: sticky;
  top: 0;
  z-index: 1000;
  width: 100vw;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
}

.header-container {
  max-width: 1200px;
  margin: 0;
  padding: 0 1rem;
}





.header-nav {
  display: none !important;
}





/* Hamburger menu button - only show on mobile portrait (vertical) */
.mobile-nav-toggle {
  display: none;
  position: fixed;
  top: 1rem;
  right: 1rem;
  z-index: 1003;
  background: var(--theme-foreground-focus);
  border: none;
  border-radius: 4px;
  padding: 0.5rem;
  cursor: pointer;
  width: 40px;
  height: 40px;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 4px;
  transition: background 0.2s;
}

.mobile-nav-toggle:hover {
  background: var(--theme-foreground-muted);
}

.mobile-nav-toggle span {
  display: block;
  width: 24px;
  height: 2px;
  background: var(--theme-background);
  transition: all 0.3s;
  border-radius: 2px;
}



.mobile-nav-toggle.active span:nth-child(1) {
  transform: translateY(6px) rotate(45deg);
}

.mobile-nav-toggle.active span:nth-child(2) {
  opacity: 0;
}

.mobile-nav-toggle.active span:nth-child(3) {
  transform: translateY(-6px) rotate(-45deg);
}

/* Mobile navigation menu */
.mobile-nav-menu {
  display: none;
  position: fixed;
  top: 0;
  right: -100%;
  width: 250px;
  height: 100vh;
  background: var(--theme-background);
  box-shadow: -2px 0 8px rgba(0, 0, 0, 0.1);
  z-index: 1002;
  transition: right 0.3s ease;
  overflow-y: auto;
  padding: 4rem 1rem 1rem;
  pointer-events: none;
}

/* Enable pointer events and show menu when active */
.mobile-nav-menu.active {
  display: flex;
  flex-direction: column;
  pointer-events: auto;
  right: 0;
}

.mobile-nav-menu nav {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.mobile-nav-menu nav a {
  display: block;
  padding: 0.75rem 1rem;
  color: var(--theme-foreground);
  text-decoration: none;
  border-radius: 4px;
  transition: background 0.2s;
  font-size: 16px;
}

.mobile-nav-menu nav a:hover {
  background: var(--theme-foreground-faintest);
}

.mobile-nav-menu nav a.active {
  background: var(--theme-foreground-fainter);
  font-weight: 600;
}

/* Overlay when menu is open */
.mobile-nav-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100vh;
  background: rgba(0, 0, 0, 0.5);
  z-index: 999;
  opacity: 0;
  transition: opacity 0.3s;
  pointer-events: none;
}

.mobile-nav-overlay.active {
  display: flex;
  opacity: 1;
  pointer-events: auto;
}

/* Show hamburger menu always */
.mobile-nav-toggle {
  display: flex;
}

/* Ensure content doesn't get hidden behind the hamburger button and header */
main {
  padding-top: 0;
  padding-left: 0 !important;
  padding-right: 0 !important;
  margin-left: 0 !important;
  margin-right: 0 !important;
  max-width: none !important;
  width: 100% !important;
  overflow-x: clip;
}

/* Override Observable Framework's main container to allow full-width content */
#observablehq-main {
  max-width: none !important;
  padding: 0 !important;
  margin: 0 !important;
}

/* Remove left/right margin from Observable Framework center container (keep top margin) */
#observablehq-center {
  margin-left: 0 !important;
  margin-right: 0 !important;
}

/* ===== INDEX PAGE STYLES (moved from index.md) ====== */
:root {
  --primary-blue: #2563eb;
  --primary-blue-dark: #1d4ed8;
  --navy-blue: rgba(25, 46, 81, 0.8);
  --text-primary: #111827;
  --text-secondary: #6b7280;
  --text-muted: #9ca3af;
  --bg-primary: #ffffff;
  --bg-secondary: #f9fafb;
  --bg-card: #ffffff;
  --border-light: #e5e7eb;
  --border-medium: #d1d5db;
  --red-500: #ef4444;
  --green-500: #10b981;
  --orange-500: #f59e0b;
  --shadow-sm: 0 1px 2px 0 rgb(0 0 0 / 0.05);
  --shadow-md: 0 4px 6px -1px rgb(0 0 0 / 0.1);
  --shadow-lg: 0 10px 15px -3px rgb(0 0 0 / 0.1);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  margin: 0;
  padding: 0;
  width: 100%;
  box-sizing: border-box;
  scroll-behavior: smooth;
  overflow-x: clip;
}

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  line-height: 1.6;
  color: var(--text-primary);
  background-color: var(--bg-primary);
  margin: 0 !important;
  padding: 0 !important;
  width: 100%;
  box-sizing: border-box;
  overflow-x: clip;
}



.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
  width: 100%;
}

/* Narrower max-width for member page content for better readability */
.content-container {
  max-width: 900px;
  margin: 0 auto;
  padding: 0 2rem;
  width: 100%;
}


/* Hero Section */
.hero {
  /* Background image set via inline style in index.md */
  height: 500px;
  width: 100%;
  margin: 0;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  box-sizing: border-box;
}

/* Fallback for very wide screens */
@media (min-width: 1400px) {
  .hero {
    background-size: 100% auto;
  }
}

.hero-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  max-width: 500px;
}

.hero-title-box {
  background: var(--navy-blue);
  backdrop-filter: blur(2px);
  border-radius: 16px;
  padding: 2rem 2.5rem;
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.4);
  border: 1px solid var(--navy-blue);
  margin-bottom: 2rem;
}

.hero-title {
  font-size: 2.5rem;
  font-weight: 800;
  margin: 0 0 2rem 0;
  line-height: 1.1;
  letter-spacing: -0.02em;
  color: #ffffff;
  text-shadow: 2px 2px 6px rgba(0, 0, 0, 0.8);
  white-space: nowrap;
}

.hero-subtitle {
  font-size: 0.875rem;
  font-weight: 600;
  color: rgba(255, 255, 255, 0.9);
  text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.8);
  margin-bottom: 1.5rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
}


/* Input Section */
.zip-input-section {
  margin-bottom: 1.5rem;
}


.input-group {
  display: flex;
  gap: 0;
  margin-bottom: 0;
  align-items: stretch;
}

.zip-input {
  flex: 1;
  padding: 1rem 1.25rem;
  border: 2px solid rgba(255, 255, 255, 0.6);
  border-radius: 8px 0 0 8px;
  font-size: 1rem;
  font-weight: 500;
  transition: all 0.3s ease;
  background: transparent;
  color: #ffffff;
}

.zip-input::placeholder {
  color: rgba(255, 255, 255, 0.7);
}

.zip-input:focus {
  outline: none;
  border-color: rgba(255, 255, 255, 0.9);
  background: transparent;
  box-shadow: 0 0 0 3px rgba(255, 255, 255, 0.2);
}

.find-rep-btn {
  padding: 1rem 2rem;
  background: var(--navy-blue);
  color: white;
  border: 2px solid var(--navy-blue);
  border-radius: 0 8px 8px 0;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  transition: all 0.3s ease;
  text-transform: uppercase;
  letter-spacing: 0.025em;
  min-width: 140px;
}

.find-rep-btn:hover {
  background: rgba(25, 46, 81, 0.9);
  border-color: rgba(25, 46, 81, 0.9);
}

.find-rep-btn:active {
  background: rgba(25, 46, 81, 1);
}

.social-proof {
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.75rem;
  font-weight: 400;
  text-align: center;
  margin-top: 1rem;
}

.btn-secondary {
  padding: 0.75rem 1.25rem;
  background: transparent;
  border: 1px solid rgba(255, 255, 255, 0.3);
  border-radius: 8px;
  color: rgba(255, 255, 255, 0.9);
  cursor: pointer;
  font-size: 0.875rem;
  font-weight: 500;
  transition: all 0.3s ease;
  margin-top: 1rem;
}

.btn-secondary:hover {
  border-color: rgba(255, 255, 255, 0.5);
  background: rgba(255, 255, 255, 0.1);
}












/* Trending Section */
.trending-section {
  padding: 3rem 0;
  background: var(--bg-secondary);
}

.section-header {
  text-align: center;
  margin-bottom: 2.5rem;
}

.trending-badge {
  display: inline-block;
  background: var(--red-500);
  color: white;
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.going-viral-badge {
  display: inline-block;
  background: var(--red-500);
  color: white;
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.875rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  border: 2px solid #dc2626;
  box-shadow: 0 2px 4px rgba(220, 38, 38, 0.2);
}

h2.section-title, .section-title {
  font-size: 2rem;
  font-weight: 800;
  margin-bottom: 0.5rem;
  text-align: center !important;
  display: block;
  width: 100%;
}

/* Special case for Congress on X Today title with info icon */
.congress-title {
  display: flex !important;
  align-items: center !important;
  justify-content: center !important;
  gap: 0.5rem !important;
}

.congress-info-wrapper {
  position: relative;
  display: inline-block;
}

.congress-info-icon {
  font-size: 1rem;
  color: #64748b;
  cursor: pointer;
  font-weight: normal;
  user-select: none;
}

.congress-info-icon:hover {
  color: #374151;
}

.congress-tooltip {
  display: none;
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(0, 0, 0, 0.9);
  color: white;
  padding: 0.75rem;
  border-radius: 6px;
  font-size: 0.875rem;
  font-weight: normal;
  white-space: nowrap;
  z-index: 1000;
  margin-top: 0.5rem;
  box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
}

.congress-tooltip::before {
  content: '';
  position: absolute;
  top: -5px;
  left: 50%;
  transform: translateX(-50%);
  border-left: 5px solid transparent;
  border-right: 5px solid transparent;
  border-bottom: 5px solid rgba(0, 0, 0, 0.9);
}

/* Additional targeting for section titles in trending sections */
.trending-section h2.section-title,
.section-header h2.section-title,
.container h2.section-title,
.trending-section .section-header h2.section-title,
.trending-section .container .section-header h2.section-title,
section.trending-section .container .section-header h2.section-title,
div.section .trending-section .container .section-header h2.section-title {
  text-align: center !important;
  margin-left: auto !important;
  margin-right: auto !important;
}

.section-description {
  font-size: 1rem;
  color: var(--text-secondary);
  text-align: center !important;
}

/* Additional specific targeting for district description */
.trending-section .section-header .section-description,
.section-header p.section-description {
  text-align: center !important;
  margin-left: auto !important;
  margin-right: auto !important;
}

.section-subtitle {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.senators-section {
  margin-top: 3rem;
  padding-top: 2rem;
  border-top: 1px solid var(--border-light);
}

/* District Controls */
.district-controls {
  margin-top: 1rem;
}

/* Issues Filter */
.issues-filter {
  margin: 2rem 0;
  padding: 1.5rem;
  background: var(--bg-card);
  border-radius: 12px;
  border: 1px solid var(--border-light);
}

.filter-label {
  font-weight: 600;
  margin-bottom: 0.75rem;
  color: var(--text-primary);
}

.filter-chips {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.filter-chip {
  padding: 0.375rem 0.75rem;
  background: var(--bg-secondary);
  border: 1px solid var(--border-light);
  border-radius: 20px;
  font-size: 0.875rem;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  gap: 0.25rem;
}

.filter-chip:hover,
.filter-chip.active {
  background: var(--primary-blue);
  color: white;
  border-color: var(--primary-blue);
}

.filter-chip.clear-filter {
  background: var(--text-muted);
  color: white;
  border-color: var(--text-muted);
}

.chip-count {
  background: rgba(255,255,255,0.2);
  padding: 0.125rem 0.375rem;
  border-radius: 10px;
  font-size: 0.75rem;
}

/* Tweet Cards Grid */
.tweets-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
  gap: 1.5rem;
  margin-top: 2rem;
}

.tweet-card {
  background: var(--bg-card);
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: var(--shadow-md);
  transition: transform 0.2s, box-shadow 0.2s;
  border: 1px solid var(--border-light);
  border-left: 4px solid var(--border-light);
  overflow-x: auto;
  position: relative;
}

/* Desktop: limit tweets to max 1/3 of screen width */
@media (min-width: 769px) {
  .tweet-card {
    max-width: 33vw;
  }
}

.tweet-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-lg);
}

.viral-tweet-card.republican-tweet {
  border-left-color: #ef4444;
}

.viral-tweet-card.democrat-tweet {
  border-left-color: #3b82f6;
}

.viral-tweet-card.independent-tweet {
  border-left-color: #8b5cf6;
}

.tweet-header {
  display: flex;
  justify-content: space-between;
  align-items: start;
  margin-bottom: 1rem;
}

.rep-info {
  flex: 1;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.rep-details {
  display: flex;
  flex-direction: column;
}

.party-chip {
  display: inline-block;
  padding: 0.25rem 0.5rem;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.party-chip.democrat {
  background: #dbeafe;
  color: #1e40af;
}

.party-chip.republican {
  background: #fee2e2;
  color: #dc2626;
}

.party-chip.independent {
  background: #f3f4f6;
  color: #374151;
}

.rep-name {
  font-weight: 700;
  font-size: 1.1rem;
  display: block;
  margin-bottom: 0.25rem;
}

.rep-handle {
  font-size: 0.875rem;
  color: var(--text-muted);
}

.chamber-badge {
  display: inline-block;
  background: var(--text-secondary);
  color: white;
  padding: 0.125rem 0.5rem;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 600;
  margin: 0 0.5rem;
}

.rep-district {
  color: var(--text-secondary);
  font-size: 0.875rem;
}

.viral-score {
  background: var(--orange-500);
  color: white;
  padding: 0.125rem 0.5rem;
  border-radius: 12px;
  font-size: 0.75rem;
  position: absolute;
  top: 0.5rem;
  right: 0.5rem;
  font-weight: 600;
}

.viral-score-number {
  font-weight: 700;
  font-size: 1.25rem;
  display: block;
}

.viral-score-label {
  font-size: 0.75rem;
  opacity: 0.9;
}

.tweet-content {
  font-size: 1rem;
  line-height: 1.6;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.tweet-meta {
  display: flex;
  gap: 1rem;
  margin-bottom: 1rem;
  font-size: 0.875rem;
  color: var(--text-muted);
  align-items: center;
  flex-wrap: wrap;
}

.engagement-stat {
  font-size: 0.875rem;
}

.tweet-time {
  color: var(--text-muted);
  font-size: 0.875rem;
}

.view-original {
  color: var(--primary-blue);
  text-decoration: none;
  font-size: 0.875rem;
}

.view-original:hover {
  text-decoration: underline;
}

.view-tweet-btn {
  color: var(--primary-blue);
  text-decoration: none;
  font-size: 0.7rem;
  font-weight: 500;
  transition: all 0.2s ease;
}

.view-tweet-btn:hover {
  text-decoration: underline;
}

.tweet-actions {
  display: flex;
  gap: 0.75rem;
  flex-wrap: wrap;
  margin-bottom: 0.75rem;
}

.action-btn {
  padding: 0.375rem 0.75rem;
  border: 1px solid var(--border-medium);
  border-radius: 6px;
  background: var(--bg-primary);
  color: var(--text-primary);
  text-decoration: none;
  font-size: 0.75rem;
  font-weight: 500;
  display: flex;
  align-items: center;
  gap: 0.25rem;
  transition: all 0.2s;
  cursor: pointer;
}

.action-btn:hover {
  border-color: var(--primary-blue);
  color: var(--primary-blue);
}

.action-btn.primary {
  background: var(--primary-blue);
  color: white;
  border-color: var(--primary-blue);
}

.action-btn.primary:hover {
  background: var(--primary-blue-dark);
}

.action-btn:disabled,
.action-btn.disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.action-btn-compact {
  padding: 0.25rem 0.5rem;
  border: 1px solid var(--border-medium);
  border-radius: 4px;
  background: var(--bg-primary);
  color: var(--text-primary);
  text-decoration: none;
  font-size: 0.7rem;
  font-weight: 500;
  display: inline-flex;
  align-items: center;
  gap: 0.125rem;
  transition: all 0.2s;
  cursor: pointer;
  margin-left: 0.5rem;
}

.action-btn-compact:hover {
  border-color: var(--primary-blue);
  color: var(--primary-blue);
}

.action-btn-compact.disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.tweet-tags {
  margin-top: 0.75rem;
  display: flex;
  gap: 0.375rem;
  flex-wrap: wrap;
}

.tweet-tag {
  background: var(--bg-secondary);
  padding: 0.25rem 0.5rem;
  border-radius: 12px;
  font-size: 0.75rem;
  color: var(--text-secondary);
}

/* Tweets Section Header */
.tweets-section-header {
  text-align: center;
  margin-bottom: 2rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border-light);
}

.tweets-section-title {
  font-size: 1.5rem;
  font-weight: 700;
  color: var(--text-primary);
  margin: 0 0 0.5rem 0;
  line-height: 1.2;
  text-align: center !important;
  margin-left: auto !important;
  margin-right: auto !important;
  display: block !important;
  width: 100% !important;
}

.tweets-section-subtitle {
  font-size: 1rem;
  color: var(--text-secondary);
  margin: 0;
  line-height: 1.4;
  text-align: center !important;
  margin-left: auto !important;
  margin-right: auto !important;
  display: block !important;
  width: 100% !important;
}

/* Tweets Section Indicator */
.tweets-section-indicator {
  text-align: center;
  margin: 1.5rem 0 2rem 0;
  padding: 0.75rem 1rem;
  background: var(--bg-secondary);
  border-radius: 8px;
}

.tweets-label {
  font-size: 1rem;
  color: var(--text-primary);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.8px;
}

/* No Tweets State */
.no-tweets {
  text-align: center;
  padding: 3rem 1rem;
  color: var(--text-secondary);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
}

/* District Newsletter Signup - inherits from .signup-section but with slight variation */
.district-signup {
  border-top: 1px solid var(--border-light);
  margin-top: 2rem;
}

.district-signup .mc-field-group {
  margin-bottom: 0.5rem;
}

.district-signup .mc-field-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-size: 0.875rem;
  color: #9fb3c8;
  font-weight: 500;
}

.district-signup .input {
  margin-bottom: 0;
}

.no-tweets-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
}

/* Contact Sticky Bar */
.contact-sticky-bar {
  position: sticky;
  bottom: 0;
  background: var(--bg-card);
  border-top: 1px solid var(--border-light);
  box-shadow: var(--shadow-lg);
  padding: 1rem 0;
  z-index: 50;
}

.contact-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
}

.contact-rep {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.contact-name {
  font-weight: 600;
}

.contact-district {
  color: var(--text-secondary);
  font-size: 0.875rem;
}

.contact-actions {
  display: flex;
  gap: 0.5rem;
}

.contact-btn {
  padding: 0.25rem 0.5rem;
  border: 1px solid var(--border-medium);
  border-radius: 4px;
  background: var(--bg-primary);
  color: var(--text-primary);
  text-decoration: none;
  font-size: 0.7rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.contact-btn.primary {
  background: var(--primary-blue);
  color: white;
  border-color: var(--primary-blue);
}

.contact-btn:hover {
  border-color: var(--primary-blue);
  color: var(--primary-blue);
}

.contact-btn.primary:hover {
  background: var(--primary-blue-dark);
  color: white;
}

.contact-btn.financial-details {
  background: #16a34a;
  color: white;
  border-color: #16a34a;
}

.contact-btn.financial-details:hover {
  background: #15803d;
  color: white;
  border-color: #15803d;
}

.contact-btn.fec-btn {
  background: white;
  color: #16a34a;
  border-color: #16a34a;
}

.contact-btn.fec-btn:hover {
  background: white;
  color: #16a34a;
  border-color: #16a34a;
}

/* FEC button styling - smaller and positioned below contact buttons */
.fec-link-container {
  margin-top: 0.1rem;
  display: flex;
  justify-content: flex-start;
}

.fec-link {
  color: #16a34a !important;
  text-decoration: none;
  font-size: 0.75rem;
  font-weight: 400;
}
.fec-link:hover {
  color: #15803d;
  text-decoration: underline;
}

/* FEC Data Indicator */
.fec-data-indicator {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 0.5rem 1rem;
  margin-bottom: 0.5rem;
}

.fec-available-badge {
  display: inline-flex;
  align-items: center;
  padding: 0.375rem 0.75rem;
  background: white;
  color: #16a34a;
  border: 1px solid #16a34a;
  border-radius: 6px;
  font-size: 0.75rem;
  font-weight: 500;
  white-space: nowrap;
}


/* Representatives Contact Section */
.representatives-contact-section {
  padding: 2rem 0 4rem 0;
  background: linear-gradient(135deg, rgba(232, 234, 238, 0.3) 0%, rgba(110, 141, 190, 0.3) 100%);
  border-top: 1px solid var(--border-light);
}

.representatives-contact-section .section-header {
  text-align: center !important;
}

.representatives-contact-section .section-header .contact-section-title,
.representatives-contact-section .contact-section-title,
section.representatives-contact-section .section-header .contact-section-title,
h3.contact-section-title {
  text-align: center !important;
  margin-left: auto !important;
  margin-right: auto !important;
  display: block !important;
  width: 100% !important;
}

.contact-section-title {
  font-size: 1.5rem;
  color: var(--text-primary);
  margin: 0 0 0.5rem 0;
  text-align: center !important;
}

.representatives-contact-section .section-header .contact-section-subtitle,
.representatives-contact-section .contact-section-subtitle,
section.representatives-contact-section .section-header .contact-section-subtitle,
p.contact-section-subtitle {
  text-align: center !important;
  margin-left: auto !important;
  margin-right: auto !important;
  display: block !important;
  width: 100% !important;
}

.contact-section-subtitle {
  color: var(--text-secondary);
  margin: 0 0 2rem 0;
  text-align: center !important;
  font-size: 0.95rem;
}

.representatives-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
  max-width: 1000px;
  margin: 0 auto;
}

.fec-disclaimer {
  text-align: center;
  margin-top: 2rem;
}

.fec-disclaimer p {
  font-size: 0.75rem;
  color: var(--text-secondary);
  opacity: 0.7;
  margin: 0;
}

.fec-disclaimer-inline {
  text-align: center;
  margin-top: 0.05rem;
  margin-bottom: 1rem;
}

.fec-disclaimer-inline p {
  font-size: 0.65rem;
  color: var(--text-secondary);
  opacity: 0.6;
  margin: 0;
  font-style: italic;
}

.rep-contact-card {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-left: 4px solid var(--border-light);
  border-radius: 12px;
  padding: 1.5rem;
  position: relative;
  transition: all 0.2s ease;
}

.rep-contact-card:hover {
  border-color: var(--border-medium);
  box-shadow: var(--shadow-sm);
}

.rep-contact-card.republican-contact {
  border-left-color: #ef4444;
}

.rep-contact-card.democrat-contact {
  border-left-color: #3b82f6;
}

.rep-contact-card.independent-contact {
  border-left-color: #8b5cf6;
}

.rep-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.rep-role {
  font-size: 0.8rem;
  color: var(--text-secondary);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.rep-info {
  margin-bottom: 0.5rem;
}

.rep-name {
  font-size: 1.1rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0 0 0.25rem 0;
}

.rep-district {
  color: var(--text-secondary);
  font-size: 0.9rem;
  margin: 0;
}


.rep-actions {
  display: flex;
  gap: 0.375rem;
  flex-wrap: nowrap;
  padding-bottom: 0.5rem;
}

.rep-contact-card .financial-data-grid {
  display: flex !important;
  flex-direction: row !important;
  flex-wrap: nowrap !important;
  justify-content: space-between !important;
  align-items: flex-start !important;
  margin-bottom: 0.25rem;
  width: 100% !important;
  padding: 1rem 1rem 0 1rem;
  gap: 2rem !important;
  border-top: 1px solid var(--border-light);
}

.rep-contact-card .financial-data-grid span {
  display: flex !important;
  flex-direction: row !important;
  flex: 1 !important;
  gap: 2rem !important;
  width: 100% !important;
}

.rep-contact-card .financial-item {
  display: flex !important;
  flex-direction: column !important;
  align-items: center !important;
  text-align: center;
  flex: 1 1 20% !important;
  min-width: 0;
}

.financial-emoji {
  font-size: 0.8rem;
  line-height: 1;
}

.financial-label {
  font-size: 0.65rem;
  color: var(--text-secondary);
  font-weight: 500;
  text-align: center;
}

.financial-value {
  font-size: 0.6rem;
  font-weight: normal;
  color: var(--text-primary);
  text-align: center;
}

.contact-btn.social {
  background: #1da1f2;
  color: white;
  border-color: #1da1f2;
}

.contact-btn.social:hover {
  background: #0d8bd9;
  color: white;
  border-color: #0d8bd9;
}

/* Compact Representatives Contact Section */
.representatives-contact-compact {
  margin-bottom: 1.5rem;
  padding: 1rem;
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: 8px;
}

.compact-reps-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: 1rem;
}

.compact-rep-card {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0.75rem;
  background: var(--bg-primary);
  border: 1px solid var(--border-light);
  border-radius: 6px;
  transition: all 0.2s ease;
}

.compact-rep-card:hover {
  border-color: var(--border-medium);
}

.compact-rep-info {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
  min-width: 0;
  flex: 1;
}

.compact-role {
  font-size: 0.75rem;
  color: var(--text-secondary);
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.compact-name {
  font-size: 0.9rem;
  font-weight: 600;
  color: var(--text-primary);
  margin: 0;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.compact-actions {
  display: flex;
  gap: 0.5rem;
  flex-shrink: 0;
}

.compact-btn {
  padding: 0.375rem 0.75rem;
  border: 1px solid var(--border-medium);
  border-radius: 4px;
  background: var(--bg-primary);
  color: var(--text-primary);
  font-size: 0.75rem;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.2s;
  white-space: nowrap;
}

.compact-btn.primary {
  background: var(--primary-blue);
  color: white;
  border-color: var(--primary-blue);
}

.compact-btn:hover {
  border-color: var(--primary-blue);
  color: var(--primary-blue);
}

.compact-btn.primary:hover {
  background: var(--primary-blue-dark);
  color: white;
}

/* Stats Section */
.stats-section {
  padding: 3rem 0;
  background: var(--bg-primary);
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 2rem;
  text-align: center;
}

.stat-item {
  padding: 1.5rem;
}

.stat-number {
  font-size: 3rem;
  font-weight: 800;
  color: var(--primary-blue);
  display: block;
}

.stat-label {
  font-size: 1.125rem;
  color: var(--text-secondary);
  margin-top: 0.5rem;
}

/* Legacy support for existing elements */
.muted {
  color: var(--text-muted);
}

.small {
  font-size: 0.85rem;
}

.section {
  margin: 1.5rem 0;
}

.card {
  background: var(--bg-card);
  border-radius: 14px;
  padding: 1rem;
  border: 1px solid var(--border-light);
}

.h1 {
  font-size: 1.2rem;
  font-weight: 800;
}

.h2 {
  font-size: 1rem;
  font-weight: 700;
  margin: 0.35rem 0;
}

/* Boards for national snapshot */
.boards {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  margin-top: 0.75rem;
}

.board {
  background: var(--bg-card);
  border: 1px solid var(--border-light);
  border-radius: 12px;
  padding: 0.75rem;
}

.cols {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 1rem;
}

.li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.3rem 0.2rem;
  border-bottom: 1px dashed var(--border-medium);
}

.li .v {
  font-weight: 700;
  width: 3.5rem;
  display: inline-block;
}

.partyhead {
  margin-bottom: 0.4rem;
}

.chips {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.chip {
  display: inline-flex;
  align-items: center;
  gap: 0.25rem;
  padding: 0.2rem 0.5rem;
  border-radius: 999px;
  background: var(--bg-secondary);
  border: 1px solid var(--border-medium);
  font-size: 0.85rem;
}

.chip-outline {
  background: transparent;
}

/* Below fold spacer - only on desktop */
.below-fold-spacer {
  height: 15vh;
  min-height: 100px;
}

/* Responsive Design */
@media (max-width: 768px) {
  /* Remove spacer on mobile */
  .below-fold-spacer {
    display: none;
  }

  /* Reduce top white space and adjust header spacing on mobile */
  .custom-header {
    margin-top: 0;
    padding: 0.25rem 0;
  }

  .header-container {
    padding: 0.5rem 1rem;
  }

  .header-container img {
    margin: 0;
    padding: 0;
  }

  /* Mobile Navigation */
  .nav-links {
    gap: 0.75rem;
  }
  
  .nav-link {
    font-size: 0.85rem;
    padding: 0.4rem 0.75rem;
  }
  
  .hero-content {
    max-width: 90%;
    margin: 0 1rem;
  }
  
  .hero-title-box {
    padding: 1.75rem 2rem;
    margin-bottom: 0.5rem;
  }
  
  .hero-title {
    font-size: 1.875rem;
    margin: 0 0 1rem 0;
  }
  
  .zip-input-section {
    padding: 1.25rem;
  }

  .input-group {
    flex-direction: column;
    gap: 0.5rem;
  }
  
  .zip-input {
    border-radius: 8px;
  }
  
  .find-rep-btn {
    border-radius: 8px;
  }

  .nav-links {
    display: none;
  }

  .tweets-grid {
    grid-template-columns: 1fr;
  }

  .tweet-actions {
    justify-content: center;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .contact-info {
    flex-direction: column;
    align-items: stretch;
    text-align: center;
  }
  
  .filter-chips {
    justify-content: center;
  }
  
  .contact-actions {
    justify-content: center;
  }

  .cols {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 480px) {
  .container {
    padding: 0 0.75rem;
  }

  .hero-content {
    max-width: 95%;
    margin: 0 0.5rem;
  }
  
  .hero-title-box {
    padding: 1.5rem 1.75rem;
  }
  
  .hero-title {
    font-size: 1.75rem;
  }
  
  .zip-input-section {
    padding: 1rem;
  }

  .tweet-card {
    padding: 1rem;
  }

  .section-title {
    font-size: 2rem;
  }

  .stats-grid {
    grid-template-columns: 1fr;
  }
}

/* Add these rules to your existing CSS */
.trending-tweets {
  margin-top: 2rem;
}



/* Map Showcase Section */
.map-showcase-section {
  padding: 4rem 0;
  background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
  border-top: 1px solid var(--border-light);
}

.viral-tweets-showcase {
  background: var(--bg-card);
  border-radius: 16px;
  padding: 2rem;
  box-shadow: var(--shadow-lg);
  border: 1px solid var(--border-light);
}

.party-tweets-grid {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  gap: 2rem;
  align-items: start;
  max-width: 1200px;
  margin: 0 auto;
}

.party-column {
  display: flex;
  flex-direction: column;
}

.party-header {
  margin-bottom: 1.5rem;
  text-align: center;
}

.party-title {
  font-size: 1.25rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: var(--text-primary);
}

.party-count {
  font-size: 0.875rem;
  color: var(--text-secondary);
}

.party-tweets {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.viral-tweet-card {
  background: var(--bg-card);
  border-radius: 8px;
  padding: 1rem;
  border: 1px solid var(--border-light);
  border-left: 4px solid var(--border-light);
  overflow-x: auto;
  position: relative;
  box-shadow: var(--shadow-sm);
}
/* Desktop: limit viral tweet cards to max 1/3 of screen width */
@media (min-width: 769px) {
  .viral-tweet-card {
    max-width: 33vw;
  }
}

.republican-column .viral-tweet-card {
  border-left-color: #ef4444;
}

.democrat-column .viral-tweet-card {
  border-left-color: #3b82f6;
}

.tweet-author {
  display: flex;
  align-items: center;
  margin-bottom: 0.5rem;
  gap: 0.5rem;
}

.author-info {
  display: flex;
  flex-direction: column;
  gap: 0.1rem;
}

.author-name {
  font-weight: 600;
  font-size: 0.875rem;
  color: var(--text-primary);
}

.username {
  font-weight: 400;
  font-size: 0.75rem;
  color: var(--text-secondary);
  opacity: 0.8;
}



.tweet-text {
  font-size: 0.875rem;
  line-height: 1.4;
  color: var(--text-secondary);
  margin-bottom: 0.75rem;
}

.tweet-engagement {
  display: flex;
  gap: 1rem;
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* Party Breakdown Center Column */
.party-breakdown {
  display: flex;
  flex-direction: column;
  align-items: center;
  min-width: 200px;
  padding: 1rem;
}

.breakdown-chart {
  text-align: center;
  margin-bottom: 2rem;
}

.chart-title {
  font-size: 1.125rem;
  font-weight: 600;
  margin-bottom: 1rem;
  color: var(--text-primary);
}

.pie-chart {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  background: conic-gradient(
    #ef4444 0% var(--rep-percent, 0%),
    #3b82f6 var(--rep-percent, 0%) calc(var(--rep-percent, 0%) + var(--dem-percent, 0%)),
    #9ca3af calc(var(--rep-percent, 0%) + var(--dem-percent, 0%)) 100%
  );
  margin: 0 auto 1rem;
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
}


.pie-center {
  width: 60px;
  height: 60px;
  background: var(--bg-card);
  border-radius: 50%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
  position: relative;
  z-index: 1;
}

.pie-total {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
  line-height: 1;
}

.pie-label {
  font-size: 0.5rem;
  color: var(--text-muted);
  margin-top: 0.125rem;
}

.chart-legend {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  font-size: 0.75rem;
}

.legend-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.legend-color {
  width: 12px;
  height: 12px;
  border-radius: 2px;
}

.republican-color {
  background: #ef4444;
}

.democrat-color {
  background: #3b82f6;
}

.other-color {
  background: #9ca3af;
}

.map-cta-button {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 1rem 2rem;
  background: rgba(59, 130, 246, 0.85);
  color: white !important;
  text-decoration: none;
  border-radius: 8px;
  font-weight: 700;
  font-size: 1rem;
  transition: all 0.3s ease;
  text-align: center;
  border: 2px solid rgba(59, 130, 246, 0.85);
  cursor: pointer;
  text-transform: uppercase;
  letter-spacing: 0.025em;
  min-width: 140px;
}
.us-map-icon {
  flex-shrink: 0;
  opacity: 0.9;
  transition: opacity 0.3s ease;
}

.map-cta-button:hover {
  background: #2563eb;
  border-color: #2563eb;
  color: white !important;
  text-decoration: none;
}

.map-cta-button:visited {
  color: white !important;
}

.map-cta-button:active {
  background: #1d4ed8;
}

/* Responsive adjustments for viral tweets section */
@media (max-width: 768px) {
  .party-tweets-grid {
    grid-template-columns: 1fr;
    gap: 2rem;
  }
  
  .party-breakdown {
    order: -1;
  }
}

@media (max-width: 480px) {
  .map-showcase-section {
    padding: 6rem 0 2rem 0;
    margin-top: 5rem;
  }
  
  .viral-tweets-showcase {
    padding: 1.5rem;
  }
  
  .party-tweets-grid {
    gap: 1.5rem;
  }
}

/* Time Filter Controls */
.time-filter-controls {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  margin: 2rem 0;
}

.time-filter-label {
  font-weight: 600;
  color: var(--text-primary);
  font-size: 0.9rem;
}

.time-filter-buttons {
  display: flex;
  gap: 0.5rem;
}

.time-filter-btn {
  padding: 0.5rem 1rem;
  border: 2px solid var(--border-medium);
  border-radius: 8px;
  background: var(--bg-primary);
  color: var(--text-primary);
  font-size: 0.875rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  /* Enhanced mobile touch support */
  touch-action: manipulation;
  -webkit-tap-highlight-color: transparent;
  user-select: none;
  -webkit-user-select: none;
  -webkit-touch-callout: none;
  /* Ensure minimum touch target size */
  min-height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.time-filter-btn:hover {
  border-color: var(--primary-blue);
  color: var(--primary-blue);
}
.time-filter-btn:active {
  transform: scale(0.98);
  background: var(--primary-blue);
  color: white;
  border-color: var(--primary-blue);
}

.time-filter-btn.active {
  background: rgba(59, 130, 246, 0.85);
  color: white;
  border-color: rgba(59, 130, 246, 0.85);
}

.time-filter-btn.active:hover {
  background: rgba(37, 99, 235, 0.85);
}
.time-filter-btn.active:active {
  background: rgba(37, 99, 235, 0.85);
  transform: scale(0.98);
}

/* Responsive adjustments for time filter */
@media (max-width: 480px) {
  .time-filter-controls {
    flex-direction: column;
    gap: 0.75rem;
  }
  
  .time-filter-buttons {
    width: 100%;
    justify-content: center;
  }
  
  .time-filter-btn {
    flex: 1;
    min-width: 120px;
  }
}

/* Add font import at the top */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700;800&display=swap');

/* Newsletter Signup Section */
.signup-section {
  padding: 2rem 0;
  background: linear-gradient(135deg, rgba(232, 234, 238, 0.3) 0%, rgba(110, 141, 190, 0.3) 100%);
}

.signup-box {
  background: #121a2f;
  border: 1px solid #26365f;
  border-radius: 12px;
  padding: 1rem;
  max-width: 320px;
  margin: 0 auto;
  text-align: center;
  color: #e9eef7;
  font-family: system-ui, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
}

.signup-box h2 {
  margin: 0 0 0.5rem;
  font-size: 1.5rem;
  font-weight: 700;
  color: #ffffff;
}

.signup-box p {
  margin: 0 0 1.5rem;
  font-size: 1rem;
  color: #9fb3c8;
  line-height: 1.5;
}

.signup-box .input {
  width: 100%;
  padding: 0.4rem 0.6rem;
  border-radius: 6px;
  border: 1px solid #2b3a5e;
  background: #0f1730;
  color: #e9eef7;
  margin-bottom: 0.8rem;
  font-size: 0.9rem;
  box-sizing: border-box;
  transition: border-color 0.2s ease;
}

.signup-box .input:focus {
  outline: none;
  border-color: #3b82f6;
}

.signup-box .input::placeholder {
  color: #9fb3c8;
}

.signup-box .btn {
  width: 100%;
  padding: 0.6rem;
  border-radius: 6px;
  border: none;
  background: #3b82f6;
  color: #ffffff;
  font-weight: 600;
  font-size: 0.9rem;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.signup-box .btn:hover {
  background: #2563eb;
}

.signup-box .btn:active {
  background: #1d4ed8;
}

.signup-box small {
  display: block;
  margin-top: 1rem;
  font-size: 0.875rem;
  color: #9fb3c8;
}

@media (max-width: 768px) {
  .signup-box {
    max-width: 350px;
    padding: 1.5rem;
  }
}

@media (max-width: 480px) {
  .signup-section {
    padding: 3rem 0;
  }
  
  .signup-box {
    max-width: 300px;
    padding: 1.25rem;
  }
  
  .signup-box h2 {
    font-size: 1.375rem;
  }
  
  .signup-box p {
    font-size: 0.9rem;
  }
}

/* Issues Section Styles */
.issues-section {
  padding: 3rem 0;
  background: var(--bg-secondary);
  border-bottom: 1px solid var(--border-light);
}

/* Interactive Topic Cards */
.topic-cards-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 1.5rem;
  margin-top: 1.5rem;
}

.topic-card {
  background: var(--bg-card);
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: var(--shadow-md);
  border: 1px solid var(--border-light);
  transition: all 0.3s ease;
}

.topic-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--primary-blue);
}

.topic-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1rem;
}

.topic-card-title {
  font-size: 1.125rem;
  font-weight: 700;
  color: var(--text-primary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  margin: 0;
}

.topic-card-count {
  background: var(--primary-blue);
  color: white;
  padding: 0.25rem 0.75rem;
  border-radius: 15px;
  font-size: 0.75rem;
  font-weight: 600;
}

.topic-card-preview {
  font-size: 0.9rem;
  line-height: 1.5;
  color: var(--text-secondary);
  font-style: italic;
  margin-bottom: 1rem;
  border-left: 3px solid var(--border-light);
  padding-left: 1rem;
}

.topic-card-stats {
  display: flex;
  gap: 1rem;
  margin-bottom: 1rem;
  flex-wrap: wrap;
}

.card-stat {
  font-size: 0.875rem;
  color: var(--text-muted);
}

.topic-card-btn {
  width: 100%;
  padding: 0.75rem;
  background: var(--primary-blue);
  color: white;
  border: none;
  border-radius: 8px;
  font-weight: 600;
  cursor: pointer;
  transition: background-color 0.2s ease;
}

.topic-card-btn:hover {
  background: var(--primary-blue-dark);
}

/* Issue Modal Styles */
.issue-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.issue-modal {
  background: var(--bg-card);
  border-radius: 16px;
  max-width: 1200px;
  max-height: 90vh;
  width: 100%;
  overflow: hidden;
  box-shadow: 0 20px 40px rgba(0, 0, 0, 0.3);
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1.5rem 2rem;
  border-bottom: 1px solid var(--border-light);
  background: var(--bg-secondary);
}

.modal-header h2 {
  margin: 0;
  font-size: 1.5rem;
  color: var(--text-primary);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.modal-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  color: var(--text-muted);
  cursor: pointer;
  padding: 0.5rem;
  border-radius: 8px;
  transition: all 0.2s ease;
}

.modal-close:hover {
  background: var(--border-light);
  color: var(--text-primary);
}

.modal-content {
  padding: 2rem;
  max-height: calc(90vh - 100px);
  overflow-y: auto;
}

.filtered-tweets-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(400px, 1fr));
  gap: 1.5rem;
}

.filtered-tweet-card {
  background: var(--bg-primary);
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: var(--shadow-sm);
  border: 1px solid var(--border-light);
  border-left: 6px solid var(--border-light);
  transition: all 0.2s ease;
  overflow-x: auto;
  position: relative;
}
/* Desktop: limit filtered tweet cards to max 1/3 of screen width */
@media (min-width: 769px) {
  .filtered-tweet-card {
    max-width: 33vw;
  }
}

.filtered-tweet-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}


/* Responsive adjustments */
@media (max-width: 768px) {
  .topic-cards-grid {
    grid-template-columns: 1fr;
  }
  
  .issue-modal {
    margin: 0.5rem;
    max-height: 95vh;
  }
  
  .modal-header {
    padding: 1rem 1.5rem;
  }
  
  .modal-content {
    padding: 1.5rem;
  }
  
  .filtered-tweets-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }
  
  .filtered-tweet-card {
    padding: 1rem;
  }
}

@media (max-width: 480px) {
  .issue-modal-overlay {
    padding: 0.5rem;
  }
  
  .modal-header h2 {
    font-size: 1.25rem;
  }
  
  .modal-content {
    padding: 1rem;
  }
}

/* Stats Section */
.stats-section {
  background: #f8fafc;
  padding: 2rem 0;
  border-top: 1px solid #e2e8f0;
}

.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
  margin-bottom: 2rem;
}

.stat-card {
  background: white;
  padding: 1.5rem 1rem;
  border-radius: 8px;
  text-align: center;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
  border: 1px solid #e2e8f0;
}

.stat-number {
  font-size: 1.8rem;
  font-weight: 800;
  color: var(--primary-blue);
  margin-bottom: 0.25rem;
  line-height: 1;
}

.stat-label {
  font-size: 0.9rem;
  color: #64748b;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.stats-footer {
  text-align: left;
  margin-top: 2rem;
}

.stats-footer p {
  color: #64748b;
  font-size: 0.9rem;
  margin: 0;
}

@media (max-width: 768px) {
  .q3-link-section {
    padding: 2rem 0;
  }

  .q3-link-card {
    padding: 1.5rem;
  }

  .q3-link-content {
    gap: 1rem;
  }

  .q3-link-icon {
    font-size: 2.5rem;
  }

  .q3-link-title {
    font-size: 1.25rem;
  }

  .q3-link-description {
    font-size: 0.9rem;
  }

  .q3-link-arrow {
    font-size: 1.5rem;
  }

  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
  }

  .stat-card {
    padding: 1.5rem 1rem;
  }

  .stat-number {
    font-size: 2rem;
  }
  
  .rep-contact-card .financial-data-grid {
    display: grid !important;
    grid-template-columns: repeat(5, 1fr) !important;
    gap: 0.5rem !important;
    padding: 0.75rem 0 0 0 !important;
    margin-bottom: 1rem !important;
    width: 100% !important;
  }
  
  .rep-contact-card .financial-item {
    text-align: center !important;
  }
}

/* Footer padding */
footer {
  padding-left: 1rem !important;
  padding-right: 1rem !important;
}

@media (max-width: 480px) {
  .stats-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .representatives-grid {
    grid-template-columns: 1fr;
    gap: 1rem;
  }

  .rep-contact-card {
    padding: 1.25rem;
  }

  .rep-actions {
    padding-bottom: 1.5rem;
  }
  
  
  .rep-contact-card .financial-data-grid {
    display: flex !important;
    flex-direction: row !important;
    justify-content: space-evenly !important;
    gap: 2rem !important;
    padding: 0.75rem 0.1rem 0.5rem 0.1rem !important;
    margin-bottom: 1rem !important;
    width: 100% !important;
    border: 1px solid rgba(0,0,0,0.05) !important;
    border-radius: 6px !important;
    background: rgba(248, 250, 252, 0.3) !important;
  }

  .rep-contact-card .financial-data-grid span {
    display: flex !important;
    flex-direction: row !important;
    flex: 1 !important;
    gap: 2rem !important;
    width: 100% !important;
  }
  
  .rep-contact-card .financial-item {
    display: flex !important;
    flex-direction: column !important;
    align-items: center !important;
    flex: 1 1 20% !important;
    text-align: center !important;
    min-width: 0 !important;
  }
  
  .financial-emoji {
    font-size: 0.5rem;
  }

  .financial-label {
    font-size: 0.4rem;
  }

  .financial-value {
    font-size: 0.4rem;
  }

  .rep-contact-card .financial-data-grid {
    gap: 0.2rem !important;
    padding: 0.3rem !important;
  }

  .rep-contact-card .financial-data-grid span {
    padding: 0.2rem !important;
    min-width: 0 !important;
  }

  .rep-name {
    font-size: 0.85rem !important;
  }

  .rep-role {
    font-size: 0.6rem !important;
  }

  .rep-header {
    margin-bottom: 0.3rem !important;
  }

  .rep-info {
    margin-bottom: 0.3rem !important;
  }
  
  .rep-actions {
    flex-direction: row;
    gap: 0.5rem;
    justify-content: flex-start;
  }

  .contact-btn {
    text-align: center;
  }

  .rep-district {
    font-size: 0.7rem !important;
  }
  
  .compact-reps-grid {
    grid-template-columns: 1fr;
  }
  
  .compact-rep-card {
    flex-direction: column;
    align-items: stretch;
    gap: 0.75rem;
  }
  
  .compact-actions {
    justify-content: center;
  }
  
  .stats-section {
    padding: 2rem 0;
  }
}

