/* ==========================================================================
   Base Styles & Reset
   ========================================================================== */

*,
*::before,
*::after {
  box-sizing: border-box;
}

* {
  margin: 0;
  padding: 0;
}

html {
  font-size: 16px;
  scroll-behavior: smooth;
}

body {
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, Cantarell, 'Open Sans', 'Helvetica Neue', sans-serif;
  background: var(--background-gray);
  color: var(--text-dark);
  line-height: 1.6;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

/* ==========================================================================
   Color Variables & Utilities
   ========================================================================== */

:root {
  --primary-purple: #9600fe;
  --primary-blue: #0096fe;
  --primary-dark-blue: #1e40af;
  --primary-light-blue: #2563eb;
  --secondary-purple: #7e22ce;
  --background-gray: #f4f7f9;
  --white: #ffffff;
  --light-gray: #f0f4f8;
  --border-gray: #ddd;
  --text-gray: #777;
  --text-dark: #333;
  --placeholder-gray: #e0e0e0;
  --shadow-light: 0 1px 5px rgba(0, 0, 0, 0.1);
  --shadow-medium: 0 2px 6px rgba(0, 0, 0, 0.1);
  --shadow-heavy: 0 4px 10px rgba(0, 0, 0, 0.1);
  --border-radius: 6px;
  --border-radius-small: 4px;
  --transition-fast: 0.3s ease;
  --transition-normal: 0.2s ease;
}

/* Utility Classes */
.hidden { display: none !important; }

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

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

/* ==========================================================================
   Typography
   ========================================================================== */

h1, h2, h3, h4, h5, h6 {
  margin-top: 0;
  line-height: 1.2;
  font-weight: 600;
  color: var(--text-dark);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; margin-bottom: 1.5rem; }
h3 { font-size: 1.5rem; margin-bottom: 1rem; }
h4 { font-size: 1.25rem; margin-bottom: 0.75rem; }

p {
  margin-bottom: 1rem;
  color: var(--text-dark);
}

a {
  color: var(--primary-blue);
  text-decoration: none;
  transition: color var(--transition-fast);
}

a:hover,
a:focus {
  color: var(--primary-dark-blue);
}

a:focus {
  outline: 2px solid var(--primary-blue);
  outline-offset: 2px;
}

/* ==========================================================================
   Layout
   ========================================================================== */

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

.section {
  padding: 2rem 0;
}

.grid,
.listing-grid,
.challenge-grid,
.stats-section,
.steps,
.showcase-grid {
  display: grid;
  gap: 1.5rem;
}

.grid-auto-fill,
.listing-grid {
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
}

.grid-3 {
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
}

@media (min-width: 768px) {
  .grid-3 {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* ==========================================================================
   Header & Navigation
   ========================================================================== */

header {
  background-color: var(--primary-purple);
  color: var(--white);
  padding: 0.5rem 0;
  box-shadow: var(--shadow-medium);
  position: sticky;
  top: 0;
  z-index: 100;
}

nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  padding: 0 1rem;
  max-width: 1200px;
  margin: 0 auto;
}

.brand-slogan {
  display: flex;
  flex-direction: column;
}

.nav-brand {
  font-size: 1.75em;
  font-weight: 700;
  color: var(--white);
  text-decoration: none;
}

.slogan {
  font-size: 0.85em;
  color: rgba(255, 255, 255, 0.9);
}

.nav-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--white);
  font-size: 1.5em;
  cursor: pointer;
  padding: 0.5rem;
  border-radius: 4px;
}

.nav-toggle:focus {
  outline: 2px solid var(--white);
  outline-offset: 2px;
}

.nav-links {
  display: flex;
  gap: 1.5rem;
  list-style: none;
}

.nav-links a {
  color: var(--white);
  text-decoration: none;
  font-weight: 500;
  padding: 0.75rem 1rem;
  border-radius: var(--border-radius-small);
  transition: background-color 0.3s ease, color 0.3s ease;
}

.nav-links a:hover,
.nav-links a.active {
  color: #e0e0ff;
  background-color: rgba(255, 255, 255, 0.1);
}

.nav-links a.active {
  text-decoration: underline;
}

/* Mobile Menu */
@media (max-width: 768px) {
  .nav-toggle {
    display: block;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 70px;
    left: 1rem;
    right: 1rem;
    background-color: #2c3e50;
    flex-direction: column;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    max-height: 0;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease-out;
  }

  .nav-links.show {
    display: flex;
    max-height: 500px;
    opacity: 1;
    visibility: visible;
    padding: 0.5rem 0;
  }

  /* Responsive Adjustments */
  .container { margin: 1rem auto; padding: 0 0.75rem; }
  .section { padding: 1.5rem 0; }
  h1 { font-size: 2rem; }
  h2 { font-size: 1.75rem; }

  .search-container { flex-direction: column; }
  .search-button { width: 100%; }

  .filters { flex-direction: column; align-items: stretch; }
  .filters select { width: 100%; }

  .listing-grid { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); padding: 1rem; }
  .card { padding: 1.25rem; }

  .footer { flex-direction: column; text-align: center; }
  .footer-links { justify-content: center; }

  .hero-buttons { flex-direction: column; align-items: center; }
  .stats-section { grid-template-columns: 1fr 1fr; }
}

/* ==========================================================================
   Cards & Content
   ========================================================================== */

.card,
.challenge-card,
.showcase-card {
  background: var(--white);
  padding: 1.5rem;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-light);
  margin-bottom: 1.5rem;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}

.card:hover,
.challenge-card:hover,
.showcase-card:hover {
  transform: translateY(-2px);
  box-shadow: var(--shadow-medium);
}

.card h3,
.card .info h2,
.challenge-card h3,
.showcase-card h3 {
  margin-bottom: 0.75rem;
  color: var(--primary-dark-blue);
}

.card .info p,
.challenge-card p,
.showcase-card p {
  margin: 0.5rem 0;
  color: var(--text-gray);
  font-size: 0.95rem;
}

.img-placeholder {
  background: linear-gradient(45deg, var(--placeholder-gray), #e0e0e0);
  height: 180px;
  border-radius: var(--border-radius);
  margin-bottom: 1rem;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-gray);
  font-size: 0.9rem;
}

/* ==========================================================================
   Forms
   ========================================================================== */

form {
  background: var(--white);
  padding: 2rem;
  border-radius: var(--border-radius);
  margin-bottom: 2rem;
  box-shadow: var(--shadow-medium);
}

form input,
form textarea,
form select,
.filters select {
  width: 100%;
  margin: 0.5rem 0 1rem 0;
  padding: 0.75rem;
  border: 1px solid var(--border-gray);
  border-radius: var(--border-radius-small);
  font-size: 1rem;
  transition: border-color var(--transition-fast), box-shadow var(--transition-fast);
}

form input:focus,
form textarea:focus,
form select:focus {
  outline: none;
  border-color: var(--primary-blue);
  box-shadow: 0 0 0 3px rgba(0, 150, 254, 0.1);
}

fieldset {
  border: 1px solid var(--border-gray);
  border-radius: var(--border-radius-small);
  padding: 1.5rem;
  margin: 1.5rem 0;
}

legend {
  font-weight: 600;
  padding: 0 0.5rem;
  color: var(--primary-dark-blue);
}

label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 500;
}

/* Checkbox & Radio - FIXED VERSION */
.checkbox-group,
.radio-group {
  margin: 1rem 0;
}

.checkbox-group,
.radio-group {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.checkbox-group > *,
.radio-group > * {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
}

.checkbox-group input[type="checkbox"],
.radio-group input[type="radio"],
input[type="checkbox"],
input[type="radio"] {
  width: auto !important;
  margin: 0 !important;
  padding: 0;
  flex-shrink: 0;
  transform: scale(1.2);
}

.checkbox-group label,
.radio-group label,
input[type="checkbox"] + label,
input[type="radio"] + label {
  font-weight: normal;
  margin: 0;
  display: inline-block;
  line-height: 1.4;
  cursor: pointer;
}

/* ==========================================================================
   Buttons
   ========================================================================== */

button,
.btn {
  display: inline-block;
  padding: 12px 24px;
  background: var(--primary-purple);
  color: var(--white);
  border: none;
  border-radius: var(--border-radius);
  cursor: pointer;
  text-decoration: none;
  font-weight: 600;
  font-size: 1rem;
  transition: background-color var(--transition-fast), transform var(--transition-normal), box-shadow var(--transition-normal);
  text-align: center;
}

button:hover,
.btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 12px rgba(0, 0, 0, 0.15);
  color: var(--white);
  }

button:focus,
.btn:focus {
  outline: 2px solid var(--primary-blue);
  outline-offset: 2px;
}

.btn-primary {
  background: var(--primary-purple);
  color: var(--white);
}

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

.btn-secondary,
.btn-outline {
  background-color: transparent;
  color: var(--white);
  border: 2px solid var(--white);
}

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

/* Special Buttons */
.hero .buttons button,
.cta button,
.home-cta button {
  background: var(--white);
  color: var(--primary-dark-blue);
  padding: 0.75rem 1.5rem;
  border-radius: var(--border-radius-small);
  margin: 0.5rem;
  font-weight: 500;
}

.hero .buttons button:hover,
.cta button:hover,
.home-cta button:hover {
  background: rgba(255, 255, 255, 0.9);
  transform: translateY(-1px);
}

.card button {
  margin-top: 1rem;
  width: 100%;
  padding: 0.6rem 1rem;
}

.market-button {
  background: var(--primary-light-blue);
  color: var(--white);
  padding: 0.5rem 1rem;
  border: none;
  border-radius: var(--border-radius-small);
  cursor: pointer;
  margin-top: 0.75rem;
  transition: all var(--transition-fast);
}

.market-button:hover {
  background: var(--primary-blue);
  transform: translateY(-1px);
}

/* ==========================================================================
   Search & Filters
   ========================================================================== */

.search-container {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  max-width: 600px;
  margin: 1.5rem auto;
  padding: 0 1rem;
}

.search-input:focus,
.search-button {
  outline: none;
  border-color: var(--primary-blue);
  box-shadow: 0 0 0 3px rgba(0, 150, 254, 0.1);
}

.search-button {
  padding: 0.85rem 1.75rem;
  background: var(--primary-purple);
  color: var(--white);
  border: none;
  border-radius: var(--border-radius-small);
  cursor: pointer;
  transition: all var(--transition-fast);
  font-weight: 500;
  white-space: nowrap;
}

.search-button:hover {
  background: var(--primary-blue);
  transform: translateY(-1px);
  box-shadow: var(--shadow-medium);
}

.filters {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 1rem;
  padding: 1.5rem;
  background: var(--white);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow-light);
  margin: 1rem auto;
  max-width: 1000px;
}

.filters select {
  min-width: 150px;
  padding: 0.6rem 1rem;
  border: 1px solid var(--border-gray);
  border-radius: var(--border-radius-small);
  background: var(--white);
}

.profile {
  font-size: 1.2rem;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

/* ==========================================================================
   Specialty Sections
   ========================================================================== */

/* Hero Sections */
.hero,
.showcase-hero {
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: var(--white);
  text-align: center;
  padding: 4rem 2rem;
  margin-bottom: 2rem;
}

.hero h1,
.showcase-hero h1 {
  font-size: 3rem;
  margin-bottom: 1rem;
  font-weight: 700;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

.hero p,
.showcase-hero p {
  font-size: 1.2rem;
  margin: 0 auto 2rem;
  max-width: 600px;
  color: rgba(255, 255, 255, 0.9);
}

.hero-buttons {
  display: flex;
  gap: 1rem;
  justify-content: center;
  flex-wrap: wrap;
}

/* Stats Section */
.stats-section {
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 2rem;
  padding: 3rem 2rem;
  text-align: center;
  background: #f8f9fa;
}

.stat-card h3 {
  font-size: 2.5rem;
  color: var(--primary-purple);
  margin-bottom: 0.5rem;
}

/* How It Works */
.how-it-works {
  padding: 4rem 2rem;
  text-align: center;
}

.how-it-works h2 {
  margin-bottom: 3rem;
  color: #2c3e50;
}

.steps {
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  max-width: 1200px;
  margin: 0 auto;
}

.step {
  padding: 2rem;
  border-radius: 8px;
  background: var(--white);
  box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

.step-number {
  width: 50px;
  height: 50px;
  background: var(--primary-purple);
  color: var(--white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.5rem;
  font-weight: bold;
  margin: 0 auto 1rem;
}

/* Featured Challenges */
.featured-section {
  padding: 4rem 2rem;
  background: #f8f9fa;
}

.featured-section h2 {
  text-align: center;
  margin-bottom: 3rem;
  color: #2c3e50;
}

.challenge-grid {
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 2rem;
  max-width: 1200px;
  margin: 0 auto 2rem;
}

.challenge-card {
  background: var(--white);
  padding: 1.5rem;
  border-radius: 8px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
}

.challenge-card:hover {
  transform: translateY(-5px);
}

.challenge-card h3 {
  color: #2c3e50;
  margin-bottom: 0.5rem;
}

.challenge-tag {
  background: var(--primary-purple);
  color: var(--white);
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 0.8rem;
  margin: 0.5rem 0;
  display: inline-block;
}

.challenge-meta {
  display: flex;
  justify-content: space-between;
  font-size: 0.9rem;
  color: #666;
  margin-top: 1rem;
  flex-wrap: wrap;
  gap: 0.5rem;
}

/* Home CTA */
.home-cta,
.cta {
  text-align: center;
  padding: 3rem 2rem;
}

.home-cta {
  background: linear-gradient(135deg, #667eea, #764ba2);
  color: var(--white);
}

.home-cta h2 {
  font-size: 2.5rem;
  margin-bottom: 1rem;
}

.home-cta p {
  color: rgba(255, 255, 255, 0.9);
}

.cta {
  background-color: #dbeafe;
  border-radius: var(--border-radius);
}

.section-title {
  text-align: center;
  margin: 2rem 0 1.5rem;
  color: var(--primary-dark-blue);
  position: relative;
}

.section-title::after {
  content: '';
  display: block;
  width: 60px;
  height: 3px;
  background: var(--primary-purple);
  margin: 0.75rem auto;
  border-radius: 2px;
}

/* ==========================================================================
   Showcase Specific Styles
   ========================================================================== */

/* Filter Section */
.filter-section {
  padding: 2rem 1rem;
  background: var(--white);
  box-shadow: var(--shadow-light);
  margin-bottom: 2rem;
}

/* Tabs */
.tabs-section {
  padding: 0 1rem;
}

.tab-container {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 2rem;
  border-bottom: 2px solid var(--border-gray);
}

.tab {
  background: none;
  border: none;
  padding: 1rem 1.5rem;
  cursor: pointer;
  font-weight: 600;
  color: var(--text-gray);
  border-bottom: 3px solid transparent;
  transition: all var(--transition-fast);
}

.tab:hover {
  color: var(--primary-blue);
}

.tab.active {
  color: var(--primary-purple);
  border-bottom: 3px solid var(--primary-purple);
}

.tab-content {
  display: none;
}

.tab-content.active {
  display: block;
  animation: fadeIn 0.3s ease;
}

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

/* Card Badges */
.card-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 2rem;
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  margin-bottom: 1rem;
}

.card-badge.challenge {
  background: #fee2e2;
  color: #b91c1c;
}

.card-badge.solution {
  background: #dcfce7;
  color: #166534;
}

.card-badge.project {
  background: #dbeafe;
  color: #1d4ed8;
}

.card-badge.startup {
  background: #f0f9ff;
  color: #0369a1;
}

/* Card Meta */
.card-meta {
  display: flex;
  justify-content: space-between;
  margin: 1rem 0;
  font-size: 0.9rem;
}

.category {
  background: var(--light-gray);
  padding: 0.25rem 0.75rem;
  border-radius: var(--border-radius-small);
}

.prize,
.status,
.funding {
  font-weight: 600;
}

.prize {
  color: var(--primary-purple);
}

.status.active {
  color: #16a34a;
}

.funding {
  color: #0369a1;
}

/* Card Stats */
.impact-stats,
.card-stats {
  display: flex;
  gap: 1rem;
  margin: 1rem 0;
}

.impact-item,
.stat {
  flex: 1;
  text-align: center;
  padding: 0.75rem;
  background: var(--light-gray);
  border-radius: var(--border-radius-small);
}

.impact-number,
.stat-number {
  display: block;
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--primary-dark-blue);
}

.impact-label,
.stat-label {
  font-size: 0.8rem;
  color: var(--text-gray);
}

/* Progress Bar */
.progress-bar {
  height: 8px;
  background: var(--border-gray);
  border-radius: 4px;
  margin: 1rem 0;
  overflow: hidden;
}

.progress {
  height: 100%;
  background: var(--primary-purple);
  border-radius: 4px;
}

/* Card Footer */
.card-footer {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  color: var(--text-gray);
  margin: 1rem 0;
  flex-wrap: wrap;
  gap: 0.5rem;
}

/* Card Link */
.card-link {
  display: block;
  text-align: center;
  padding: 0.75rem;
  background: var(--primary-purple);
  color: var(--white);
  border-radius: var(--border-radius-small);
  font-weight: 600;
  transition: background-color var(--transition-fast);
}

.card-link:hover {
  background: var(--secondary-purple);
  color: var(--white);
}

/* Tab CTA */
.tab-cta {
  text-align: center;
  padding: 3rem 2rem;
  background: #f0f9ff;
  border-radius: var(--border-radius);
  margin-top: 2rem;
}

.tab-cta h2 {
  margin-bottom: 1rem;
  color: var(--primary-dark-blue);
}

/* ==========================================================================
   Circles (Startup Stages)
   ========================================================================== */

.circle {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 1.5rem;
  justify-items: center;
  align-items: center;
  padding: 2rem 0;
}

.stage {
  background: linear-gradient(135deg, var(--primary-purple), var(--primary-blue));
  border-radius: 50%;
  padding: 2rem;
  width: 160px;
  height: 160px;
  box-shadow: var(--shadow-heavy);
  text-align: center;
  display: flex;
  flex-direction: column;
  justify-content: center;
  transition: all var(--transition-fast);
  color: var(--white);
  cursor: pointer;
  text-decoration: none;
}

.stage:hover,
.stage:focus {
  transform: scale(1.05);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.2);
  outline: 2px solid var(--white);
  outline-offset: 4px;
}

.stage span {
  font-weight: 600;
  font-size: 1.1rem;
  margin-top: 0.5rem;
}

/* ==========================================================================
   Tags & Badges
   ========================================================================== */

.tag {
  background: var(--light-gray);
  padding: 0.25rem 0.75rem;
  border-radius: var(--border-radius-small);
  margin-right: 0.5rem;
  font-size: 0.85rem;
  display: inline-block;
  margin-bottom: 0.25rem;
}

.badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  font-size: 0.8rem;
  border-radius: 2rem;
  font-weight: 500;
  text-transform: uppercase;
}

.badge.hot   { background: #fecaca; color: #b91c1c; }
.badge.new   { background: #bbf7d0; color: #166534; }
.badge.featured { background: #bfdbfe; color: #1d4ed8; }

/* ==========================================================================
   Interactive
   ========================================================================== */

.vote {
  cursor: pointer;
  font-weight: bold;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem;
  border-radius: var(--border-radius-small);
  transition: background-color var(--transition-fast);
}

.vote:hover {
  background-color: rgba(0, 0, 0, 0.05);
}

.vote:focus {
  outline: 2px solid var(--primary-blue);
  outline-offset: 2px;
}

.actions {
  display: flex;
  gap: 1rem;
  justify-content: flex-end;
  margin-top: 1rem;
}

/* ==========================================================================
   Modals
   ========================================================================== */

.modal {
  display: none;
  position: fixed;
  top: 0; left: 0;
  width: 100%; height: 100%;
  background: rgba(0, 0, 0, 0.7);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  animation: fadeIn 0.2s ease;
}

.modal.show {
  display: flex;
}

.modal-content {
  background: var(--white);
  padding: 2rem;
  border-radius: var(--border-radius);
  width: 90%;
  max-width: 600px;
  max-height: 90vh;
  overflow-y: auto;
  box-shadow: var(--shadow-heavy);
  animation: modalSlideIn 0.3s ease;
}

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

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}

.preview {
  display: none;
  background: var(--light-gray);
  padding: 1.5rem;
  border-radius: var(--border-radius);
  margin: 1rem 0;
}

.preview h3 {
  margin-bottom: 1rem;
  color: var(--primary-dark-blue);
}

.preview-item {
  margin-bottom: 0.75rem;
  padding: 0.5rem 0;
  border-bottom: 1px solid var(--border-gray);
}

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

/* ==========================================================================
   Footer
   ========================================================================== */

footer {
  text-align: center;
  font-size: 0.9rem;
  color: var(--text-gray);
  padding: 2rem 1rem;
  margin-top: auto;
  border-top: 1px solid var(--border-gray);
  background: var(--white);
}

.footer {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 1rem;
  font-size: 0.95rem;
}

.footer-links {
  display: flex;
  gap: 1.5rem;
}

/* ==========================================================================
   Responsive Design
   ========================================================================== */

@media (max-width: 992px) {
  .circle {
    grid-template-columns: repeat(2, 1fr);
    gap: 2rem;
  }
  
  .tab-container {
    justify-content: center;
  }
}

@media (max-width: 768px) {
  .nav-toggle {
    display: block;
  }

  .nav-links {
    display: none;
    position: absolute;
    top: 70px;
    left: 1rem;
    right: 1rem;
    background-color: #b54cfe;
    flex-direction: column;
    border-radius: 8px;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    overflow: hidden;
    max-height: 0;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease-out;
  }

  .nav-links.show {
    display: flex;
    max-height: 500px;
    opacity: 1;
    visibility: visible;
    padding: 0.5rem 0;
  }

  /* Responsive Adjustments */
  .container { margin: 1rem auto; padding: 0 0.75rem; }
  .section { padding: 1.5rem 0; }
  h1 { font-size: 2rem; }
  h2 { font-size: 1.75rem; }

  .search-container { flex-direction: column; }
  .search-button { width: 100%; }

  .filters { flex-direction: column; align-items: stretch; }
  .filters select { width: 100%; }

  .listing-grid { grid-template-columns: repeat(auto-fill, minmax(250px, 1fr)); padding: 1rem; }
  .card { padding: 1.25rem; }

  .footer { flex-direction: column; text-align: center; }
  .footer-links { justify-content: center; }

  .hero-buttons { flex-direction: column; align-items: center; }
  .stats-section { grid-template-columns: 1fr 1fr; }
  
  .tab-container {
    flex-direction: column;
    align-items: center;
  }
  
  .impact-stats,
  .card-stats {
    flex-direction: column;
  }
  
  .card-footer {
    flex-direction: column;
    gap: 0.5rem;
  }
}

@media (max-width: 480px) {
  .stage {
    width: 130px;
    height: 130px;
    padding: 1.5rem;
  }
  .stage span {
    font-size: 0.95rem;
  }
  .hero h1,
  .showcase-hero h1 { font-size: 1.75rem; }
  .hero p,
  .showcase-hero p { font-size: 1rem; }
  form { padding: 1.5rem; }
  .modal-content { width: 95%; padding: 1.5rem; }
  
  .impact-stats,
  .card-stats {
    flex-direction: column;
  }
}

/* ==========================================================================
   Print
   ========================================================================== */

@media print {
  nav, .nav-toggle, .search-container, .actions, .cta, .modal, footer {
    display: none !important;
  }

  .card {
    box-shadow: none;
    border: 1px solid var(--border-gray);
    page-break-inside: avoid;
  }

  a {
    color: #000 !important;
    text-decoration: underline;
  }

  h1, h2, h3, h4 { color: #000; }

  body {
    background: white;
    color: black;
    font-size: 12pt;
  }

  .container {
    width: 100%;
    margin: 0;
    padding: 0.5rem;
  }
}