/* Victoria Hospital Foundation - Main Styles */

/* ========================================
   CSS Variables & Theme
   ======================================== */
:root {
  /* Colors */
  --primary: #00A0A0;
  --primary-dark: #008888;
  --secondary: #003366;
  --accent: #FF6B4A;
  --accent-hover: #FF5533;
  --success: #4CAF50;
  --text-primary: #333333;
  --text-secondary: #666666;
  --text-light: #999999;
  --bg-white: #FFFFFF;
  --bg-light: #F8F9FA;
  --bg-gray: #E9ECEF;
  --border: #DEE2E6;
  
  /* Typography */
  --font-heading: 'Montserrat', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  --font-body: 'Lato', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  
  /* Spacing */
  --spacing-xs: 0.5rem;
  --spacing-sm: 1rem;
  --spacing-md: 2rem;
  --spacing-lg: 3rem;
  --spacing-xl: 4rem;
  
  /* Border radius */
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  
  /* Shadows */
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.1);
  --shadow-md: 0 4px 6px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 10px 25px rgba(0, 0, 0, 0.15);
  
  /* Container widths */
  --container-max: 1200px;
  --container-wide: 1400px;
}

/* ========================================
   Base Styles
   ======================================== */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

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

body {
  font-family: var(--font-body);
  color: var(--text-primary);
  line-height: 1.6;
  background: var(--bg-white);
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
  margin-bottom: var(--spacing-sm);
  color: var(--secondary);
}

h1 { font-size: 2.5rem; }
h2 { font-size: 2rem; }
h3 { font-size: 1.5rem; }
h4 { font-size: 1.25rem; }
h5 { font-size: 1.125rem; }
h6 { font-size: 1rem; }

p {
  margin-bottom: var(--spacing-sm);
}

a {
  color: var(--primary);
  text-decoration: none;
  transition: color 0.3s ease;
}

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

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

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

/* Screen reader only */
.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;
}

/* ========================================
   Layout Containers
   ======================================== */
.container {
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 var(--spacing-sm);
}

.container-wide {
  max-width: var(--container-wide);
  margin: 0 auto;
  padding: 0 var(--spacing-sm);
}

.section {
  padding: var(--spacing-xl) 0;
}

.section-sm {
  padding: var(--spacing-lg) 0;
}

/* ========================================
   Buttons
   ======================================== */
.btn {
  display: inline-block;
  padding: 0.875rem 2rem;
  font-family: var(--font-heading);
  font-size: 1rem;
  font-weight: 600;
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border: none;
  border-radius: var(--radius-md);
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
}

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

.btn-primary:hover {
  background: var(--accent-hover);
  color: var(--bg-white);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

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

.btn-secondary:hover {
  background: var(--primary-dark);
  color: var(--bg-white);
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

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

.btn-outline:hover {
  background: var(--primary);
  color: var(--bg-white);
}

.btn-lg {
  padding: 1.125rem 2.5rem;
  font-size: 1.125rem;
}

/* ========================================
   Header & Navigation
   ======================================== */
.header {
  background: var(--bg-white);
  box-shadow: var(--shadow-sm);
  position: sticky;
  top: 0;
  z-index: 1000;
}

.nav-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: var(--spacing-sm) 0;
}

.logo {
  display: flex;
  align-items: center;
  font-family: var(--font-heading);
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--secondary);
}

.logo span {
  color: var(--primary);
}

.nav-menu {
  display: flex;
  list-style: none;
  gap: var(--spacing-md);
  align-items: center;
}

.nav-menu a {
  color: var(--text-primary);
  font-weight: 500;
  padding: 0.5rem 0;
  position: relative;
}

.nav-menu a:hover {
  color: var(--primary);
}

.nav-menu a::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  width: 0;
  height: 2px;
  background: var(--primary);
  transition: width 0.3s ease;
}

.nav-menu a:hover::after {
  width: 100%;
}

.nav-dropdown {
  position: relative;
}

.dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  background: var(--bg-white);
  box-shadow: var(--shadow-lg);
  border-radius: var(--radius-md);
  padding: var(--spacing-sm);
  min-width: 200px;
  list-style: none;
}

.nav-dropdown:hover .dropdown-menu {
  display: block;
}

.dropdown-menu li {
  padding: 0.5rem var(--spacing-sm);
}

.dropdown-menu a {
  display: block;
  color: var(--text-primary);
}

.dropdown-menu a:hover {
  color: var(--primary);
}

.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  cursor: pointer;
  padding: 0.5rem;
}

.mobile-menu-toggle span {
  display: block;
  width: 25px;
  height: 3px;
  background: var(--secondary);
  margin: 5px 0;
  transition: 0.3s;
}

/* ========================================
   Hero Section
   ======================================== */
.hero {
  background: linear-gradient(135deg, var(--primary) 0%, var(--secondary) 100%);
  color: var(--bg-white);
  padding: var(--spacing-xl) 0;
  text-align: center;
  position: relative;
  overflow: hidden;
}

.hero::before {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: url('/placeholder.svg?height=600&width=1920') center/cover;
  opacity: 0.15;
  z-index: 0;
}

.hero-content {
  position: relative;
  z-index: 1;
  max-width: 800px;
  margin: 0 auto;
}

.hero h1 {
  color: var(--bg-white);
  font-size: 3rem;
  margin-bottom: var(--spacing-md);
}

.hero p {
  font-size: 1.25rem;
  margin-bottom: var(--spacing-lg);
  opacity: 0.95;
}

.hero-buttons {
  display: flex;
  gap: var(--spacing-sm);
  justify-content: center;
  flex-wrap: wrap;
}

/* ========================================
   Notice Banner
   ======================================== */
.notice-banner {
  background: #FFF3CD;
  border-left: 4px solid #FFB800;
  padding: var(--spacing-sm) var(--spacing-md);
  margin: var(--spacing-md) 0;
  border-radius: var(--radius-sm);
  display: flex;
  align-items: flex-start;
  gap: var(--spacing-sm);
}

.notice-banner strong {
  color: var(--secondary);
}

.notice-banner-close {
  background: none;
  border: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--text-secondary);
  margin-left: auto;
}

/* ========================================
   Cards
   ======================================== */
.card {
  background: var(--bg-white);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  overflow: hidden;
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}

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

.card-img {
  width: 100%;
  height: 250px;
  object-fit: cover;
}

.card-content {
  padding: var(--spacing-md);
}

.card-title {
  font-size: 1.25rem;
  margin-bottom: var(--spacing-sm);
  color: var(--secondary);
}

.card-text {
  color: var(--text-secondary);
  margin-bottom: var(--spacing-sm);
}

.card-link {
  color: var(--primary);
  font-weight: 600;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
}

/* ========================================
   Grid Layouts
   ======================================== */
.grid {
  display: grid;
  gap: var(--spacing-md);
}

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

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

.grid-4 {
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
}

/* ========================================
   Stats Section
   ======================================== */
.stats {
  background: var(--bg-light);
  padding: var(--spacing-lg) 0;
}

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

.stat-item {
  background: var(--bg-white);
  padding: var(--spacing-md);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
}

.stat-number {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--primary);
  font-family: var(--font-heading);
}

.stat-label {
  font-size: 1rem;
  color: var(--text-secondary);
  margin-top: var(--spacing-xs);
}

/* ========================================
   Priority Areas
   ======================================== */
.priority-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: var(--spacing-lg);
  margin-top: var(--spacing-lg);
}

.priority-card {
  text-align: center;
  padding: var(--spacing-lg);
  background: var(--bg-white);
  border-radius: var(--radius-lg);
  border: 2px solid var(--border);
  transition: all 0.3s ease;
}

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

.priority-icon {
  width: 80px;
  height: 80px;
  margin: 0 auto var(--spacing-sm);
  background: var(--primary);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--bg-white);
  font-size: 2rem;
}

/* ========================================
   Newsletter Signup
   ======================================== */
.newsletter {
  background: var(--secondary);
  color: var(--bg-white);
  padding: var(--spacing-lg) 0;
  text-align: center;
}

.newsletter h2 {
  color: var(--bg-white);
  margin-bottom: var(--spacing-sm);
}

.newsletter p {
  margin-bottom: var(--spacing-md);
  opacity: 0.9;
}

.newsletter-form {
  display: flex;
  max-width: 500px;
  margin: 0 auto;
  gap: var(--spacing-sm);
}

.newsletter-form input {
  flex: 1;
  padding: 0.875rem var(--spacing-sm);
  border: none;
  border-radius: var(--radius-md);
  font-size: 1rem;
}

.newsletter-form button {
  padding: 0.875rem var(--spacing-md);
}

/* ========================================
   Footer
   ======================================== */
.footer {
  background: var(--secondary);
  color: var(--bg-white);
  padding: var(--spacing-xl) 0 0;
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: var(--spacing-lg);
  margin-bottom: var(--spacing-lg);
}

.footer h3 {
  color: var(--bg-white);
  font-size: 1.125rem;
  margin-bottom: var(--spacing-sm);
}

.footer p, .footer a {
  color: rgba(255, 255, 255, 0.8);
  font-size: 0.95rem;
}

.footer a:hover {
  color: var(--bg-white);
}

.footer-links {
  list-style: none;
}

.footer-links li {
  margin-bottom: 0.5rem;
}

.social-links {
  display: flex;
  gap: var(--spacing-sm);
  margin-top: var(--spacing-sm);
}

.social-link {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.1);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.3s ease;
}

.social-link:hover {
  background: var(--primary);
}

.footer-bottom {
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  padding: var(--spacing-md) 0;
  text-align: center;
  font-size: 0.875rem;
  color: rgba(255, 255, 255, 0.7);
}

.footer-bottom-links {
  display: flex;
  justify-content: center;
  gap: var(--spacing-md);
  margin-top: var(--spacing-sm);
  flex-wrap: wrap;
}

.partner-logos {
  display: flex;
  justify-content: center;
  gap: var(--spacing-md);
  margin-top: var(--spacing-sm);
  flex-wrap: wrap;
  opacity: 0.7;
}

.partner-logo {
  height: 40px;
  width: auto;
}

/* ========================================
   Forms
   ======================================== */
.form-group {
  margin-bottom: var(--spacing-md);
}

.form-label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 600;
  color: var(--text-primary);
}

.form-input,
.form-textarea,
.form-select {
  width: 100%;
  padding: 0.875rem var(--spacing-sm);
  border: 2px solid var(--border);
  border-radius: var(--radius-md);
  font-family: var(--font-body);
  font-size: 1rem;
  transition: border-color 0.3s ease;
}

.form-input:focus,
.form-textarea:focus,
.form-select:focus {
  outline: none;
  border-color: var(--primary);
}

.form-textarea {
  min-height: 150px;
  resize: vertical;
}

/* ========================================
   Modal Styles
   ======================================== */
/* Added modal styles for donation popup */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  z-index: 2000;
  align-items: center;
  justify-content: center;
  padding: var(--spacing-sm);
  overflow-y: auto;
}

.modal-content {
  background: var(--bg-white);
  border-radius: var(--radius-lg);
  padding: var(--spacing-lg);
  max-width: 700px;
  width: 100%;
  max-height: 90vh;
  overflow-y: auto;
  position: relative;
  box-shadow: var(--shadow-lg);
}

.modal-close {
  position: absolute;
  top: var(--spacing-sm);
  right: var(--spacing-sm);
  background: none;
  border: none;
  font-size: 2rem;
  color: var(--text-secondary);
  cursor: pointer;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: all 0.3s ease;
}

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

.donation-form {
  margin-top: var(--spacing-md);
}

.form-row {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--spacing-sm);
}

.donation-amounts {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(100px, 1fr));
  gap: var(--spacing-sm);
}

.amount-option {
  position: relative;
  cursor: pointer;
}

.amount-option input[type="radio"] {
  position: absolute;
  opacity: 0;
}

.amount-option span {
  display: block;
  padding: 1rem;
  text-align: center;
  border: 2px solid var(--border);
  border-radius: var(--radius-md);
  font-weight: 600;
  transition: all 0.3s ease;
}

.amount-option input[type="radio"]:checked + span {
  background: var(--primary);
  color: var(--bg-white);
  border-color: var(--primary);
}

.amount-option:hover span {
  border-color: var(--primary);
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  cursor: pointer;
}

.checkbox-label input[type="checkbox"] {
  width: 20px;
  height: 20px;
  cursor: pointer;
}

.btn-block {
  width: 100%;
  display: block;
}

/* ========================================
   Utility Classes
   ======================================== */
.text-center { text-align: center; }
.text-left { text-align: left; }
.text-right { text-align: right; }

.bg-light { background: var(--bg-light); }
.bg-white { background: var(--bg-white); }

.mt-1 { margin-top: var(--spacing-sm); }
.mt-2 { margin-top: var(--spacing-md); }
.mt-3 { margin-top: var(--spacing-lg); }

.mb-1 { margin-bottom: var(--spacing-sm); }
.mb-2 { margin-bottom: var(--spacing-md); }
.mb-3 { margin-bottom: var(--spacing-lg); }

.p-1 { padding: var(--spacing-sm); }
.p-2 { padding: var(--spacing-md); }
.p-3 { padding: var(--spacing-lg); }

/* ========================================
   Responsive Design
   ======================================== */
@media (max-width: 768px) {
  html {
    font-size: 14px;
  }
  
  h1 { font-size: 2rem; }
  h2 { font-size: 1.75rem; }
  h3 { font-size: 1.35rem; }
  
  .nav-menu {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--bg-white);
    flex-direction: column;
    padding: var(--spacing-sm);
    box-shadow: var(--shadow-lg);
  }
  
  .nav-menu.active {
    display: flex;
  }
  
  .mobile-menu-toggle {
    display: block;
  }
  
  .dropdown-menu {
    position: static;
    box-shadow: none;
    padding-left: var(--spacing-md);
  }
  
  .hero h1 {
    font-size: 2rem;
  }
  
  .hero p {
    font-size: 1rem;
  }
  
  .hero-buttons {
    flex-direction: column;
  }
  
  .newsletter-form {
    flex-direction: column;
  }
  
  .footer-bottom-links {
    flex-direction: column;
    gap: var(--spacing-sm);
  }
  
  .section {
    padding: var(--spacing-md) 0;
  }

  /* Added responsive styles for modal */
  .modal-content {
    padding: var(--spacing-md);
    margin: var(--spacing-sm);
  }

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

  .form-row {
    grid-template-columns: 1fr;
  }
}

@media (min-width: 769px) and (max-width: 1024px) {
  .container {
    padding: 0 var(--spacing-md);
  }
}
