/* =============================
   Variables
============================= */
:root {
  --primary-color: #4BA3FF;
  --accent-color: #FFD43B; /* check WCAG contrast if needed */
  --gradient-start: #4BA3FF;
  --gradient-end: #D4F08F;
  --font-family: 'Poppins', sans-serif;
  --text-color: #222;
  --background-color: #fff8dc;
  --star-bg: #fff;
  --border-radius: 12px;
  --shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  --space-2xs: 0.25rem;
  --space-xs: 0.5rem;
  --space-s: 0.75rem;
  --space-m: 1rem;
  --space-l: 1.5rem;
  --space-xl: 2rem;
  --profile-logo: 120px;
  --profile-logo-sm: 90px;
  --profile-gap: 1rem;
  --profile-margin: 2rem;
}

/* =============================
   Reset & Base
============================= */
*, *::before, *::after {
  box-sizing: border-box;
}
body {
  margin: 0;
  padding: 0;
  font-family: var(--font-family);
  color: var(--text-color);
  background: var(--background-color);
  line-height: 1.6;
  overflow-x: hidden;
}
a {
  text-decoration: underline;
  color: var(--primary-color);
}
a:hover, a:focus-visible {
  color: var(--accent-color);
  text-decoration-thickness: 2px;
}
ul {
  list-style: inside disc;
  margin: 0;
  padding: 0 1.5rem;
}
:focus {
  outline: 2px solid var(--accent-color);
  outline-offset: 2px;
}

/* =============================
   Typography
============================= */
h1 {
  font-size: 2.4rem;
  color: var(--primary-color);
  margin: 0.5rem 0;
  text-align: center;
}
h2 {
  font-size: 1.75rem;
  color: var(--primary-color);
  font-weight: 600;
  margin-bottom: 0.5rem;
  text-align: center;
}
h3 {
  font-size: 1.25rem;
  margin-bottom: 0.5rem;
  text-align: center;
}
p {
  margin: 1rem 0;
}
.details {
  font-weight: bold;
}

/* =============================
   Layout Containers
============================= */
.container {
  max-width: 1200px;
  margin: 2rem auto;
  padding: 0 1rem;
}

/* ============================= 
   Header
============================= */
.sticky-header {
  position: sticky;
  top: 0;
  width: 100%;
  background: linear-gradient(135deg, var(--gradient-start), var(--gradient-end));
  border-bottom: 2px solid var(--primary-color);
  z-index: 1000;
}
.header-inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0.5rem 1.5rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.logo img {
  max-height: 60px;
  width: auto;
}
.desktop-header .nav-flex {
  display: flex;
  gap: 0.5rem; /* Reduced gap */
  align-items: center;
  flex-wrap: nowrap; /* Prevent wrapping */
}
.nav-flex a:not(.primary-btn) {
  color: white;
  text-decoration: none;
  font-weight: 600;
  padding: 0.3rem 0.8rem; /* Reduced padding */
  border-radius: var(--border-radius);
  transition: background-color 0.2s ease;
  white-space: nowrap; /* Prevent text wrapping */
  font-size: 0.95rem; /* Slightly smaller font */
}
.nav-flex a:not(.primary-btn):hover {
  background: rgba(255, 255, 255, 0.2);
  color: white;
}
.primary-btn {
  background: var(--accent-color);
  color: var(--primary-color);
  padding: 0.4rem 1rem;
  border-radius: var(--border-radius);
  font-weight: 600;
  text-decoration: none;
}
.primary-btn:hover {
  background: var(--accent-color);
  color: var(--primary-color);
  text-decoration: none;
}
.mobile-header {
  display: none;
}

@media (max-width: 768px) {
  .desktop-header { display: none; }
  .mobile-header { display: block; }

  .mobile-header .header-inner {
    display: grid;
    grid-template-columns: auto 1fr auto;
    align-items: center;
    padding: 0.5rem 1rem;
    gap: 1rem;
  }
  .mobile-header .logo img { max-height: 50px; }
  .menu-icon {
    font-size: 1.6rem;
    background: none;
    border: none;
    color: white;
    cursor: pointer;
  }
  .dropdown-nav {
    display: none;
    position: absolute;
    top: 100%;
    right: 1rem;
    background: var(--star-bg);
    border: 1px solid var(--primary-color);
    border-radius: var(--border-radius);
    box-shadow: var(--shadow);
    flex-direction: column;
    overflow: hidden;
    z-index: 1001;
  }

  .mobile-header-right { position: relative; }

  .mobile-header-right.menu-open .dropdown-nav {
    display: flex;
  }
  .dropdown-nav a {
    padding: 0.75rem 1rem;
    color: var(--primary-color);
    font-weight: 600;
    border-bottom: 1px solid #eee;
  }
}

/* =============================
   Banner
============================= */
.event-banner-split {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1rem;
  padding: 2rem 1rem;
  background: var(--background-color);
}
.event-banner-split .nonprofit-badge {
  background: var(--accent-color);
  color: white;
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: var(--border-radius);
  font-size: 2rem;
  text-align: center;
  line-height: 1;
}
.event-banner-split .tagline {
  font-size: 1.1rem;
  color: #333;
  text-align: center;
}
.event-banner-split .details {
  font-size: 1rem;
  color: #222;
  text-align: center;
  font-weight: bold;
}

.event-banner-split .pricing-simple {
  font-size: 1rem;
  color: var(--primary-color);
  text-align: center;
  font-weight: 600;
  margin: 1rem 0;
  line-height: 1.4;
}

.banner-image img {
  width: 100%;
  height: auto;
  object-fit: cover;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  margin: 0;
  padding: 0;
}
.banner-image.banner-logo img {
  object-fit: contain;
  border-radius: 50%;
  box-shadow: none;
}
@media (min-width: 769px) {
  .event-banner-split {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    grid-template-rows: auto auto auto auto auto;
    gap: 1rem;
    max-width: 1200px;
    margin: 0 auto;
    align-items: center;
    text-align: center;
  }
  .banner-image.banner-image-left   { grid-column: 1; grid-row: 1; justify-self: end; }
  .banner-image.banner-logo         { grid-column: 2; grid-row: 1; justify-self: center; }
  .banner-image.banner-image-right  { grid-column: 3; grid-row: 1; justify-self: start; }
  .event-banner-split > h1,
  .event-banner-split .nonprofit-badge,
  .event-banner-split .tagline,
  .event-banner-split .details,      
  .event-banner-split .pricing-simple { grid-column: 1 / -1; }
}


/* =============================
   Cards & Sponsors
============================= */
.card {
  background: var(--star-bg);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  padding: 1rem;
  margin-bottom: 1rem;
}
.card > h2:not(.event-title) {
  font-size: 1.75rem;
  text-align: center;
  margin-bottom: 1rem;
}
@media only screen and (max-width: 600px) {
  .card > h2:not(.event-title) {
    font-size: 1.4rem;
  }
}

.card:hover {
  transform: translateY(-2px);
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
}

.event-header {
  display: flex;
  align-items: center;
  margin-bottom: 1rem;
  gap: 0.75rem;
}

.event-emoji {
  font-size: 2rem;
  flex-shrink: 0;
}

.event-title {
  font-size: 1.5rem;
  color: var(--primary-color);
  font-weight: 700;
  margin: 0;
  text-align: left;
}

.event-details {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1rem;
  padding: 0.75rem;
  background: linear-gradient(135deg, #f8f9ff, #fff);
  border-radius: 8px;
  border-left: 4px solid var(--primary-color);
}

.detail-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-weight: 600;
  font-size: 0.9rem;
}

.detail-icon {
  color: var(--primary-color);
  font-weight: bold;
}

.event-description {
  font-size: 1rem;
  line-height: 1.7;
  margin-bottom: 1rem;
}

.beginner-friendly {
  display: inline-block;
  background: var(--accent-color);
  color: var(--text-color);
  padding: 0.25rem 0.75rem;
  border-radius: 20px;
  font-size: 0.85rem;
  font-weight: 600;
  margin-bottom: 1rem;
}

.price-highlight {
  background: var(--primary-color);
  color: white;
  padding: 0.2rem 0.5rem;
  border-radius: 6px;
  font-weight: 600;
  text-decoration: none; /* Remove underline */
  display: inline-block; /* Helps with padding/margins */
  cursor: pointer;
  transition: all 0.2s ease;
}

.price-highlight:hover {
  background: var(--accent-color);
  color: var(--primary-color);
  text-decoration: none;
}

.free-highlight {
  background: #10b981;
  color: white;
  padding: 0.2rem 0.5rem;
  border-radius: 6px;
  font-weight: 600;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
  h1 {
    font-size: 2rem;
  }
  
  .event-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.5rem;
  }
  
  .event-title {
    font-size: 1.3rem;
  }
  
  .event-emoji {
    font-size: 1.5rem;
  }
  
  .event-details {
    flex-direction: column;
    gap: 0.5rem;
  }
  
  .card {
    padding: 1rem;
  }
}

.intro-text {
  text-align: center;
  font-size: 1.1rem;
  color: #555;
  margin-bottom: 3rem;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
}

/* Utility to manage vertical rhythm inside a container */
.flow > * + * { margin-top: var(--flow-space, 1rem); }

.profile-block {
  display: grid;
  grid-template-columns: var(--profile-logo) 1fr; /* image left, text right */
  gap: var(--profile-gap);
  align-items: flex-start;
  margin-bottom: var(--profile-margin);
}

/* Image */
.profile-logo {
  width: var(--profile-logo);
  height: auto;
  object-fit: contain;
  justify-self: start;
}

/* Text */
.profile-copy {
  text-align: left;
}
.profile-copy h3 {
  text-align: left;     /* override global heading center */
  margin: 0 0 0.5rem 0;
}
.profile-copy p {
  margin: 0 0 0.75rem 0;
  max-width: none;      /* undo .card p max-width if you set it */
}

/* Ensure global .card p centering doesn't leak in */
.card .profile-block p {
  margin-left: 0;
  margin-right: 0;
}

/* Mobile: stack, but keep image before text */
@media (max-width: 600px) {
  .profile-block {
    grid-template-columns: 1fr;
    grid-template-areas:
      "logo"
      "copy";
  }
  .profile-logo {
    grid-area: logo;
    width: var(--profile-logo-sm);
    margin: 0 auto 0.75rem;
  }
  .profile-copy {
    grid-area: copy;
  }
}

/* Optional: respect reduced motion */
@media (prefers-reduced-motion: reduce) {
  .profile-block { scroll-behavior: auto; }
}


/* Sponsor logos in other parts of the site */
.sponsor-logos {
  display: flex;
  gap: .5rem;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  margin: .5rem 0;
}
.sponsor-logos img {
  max-height: 80px;
  width: auto;
}

/* Sponsor grid: 3‑columns by default, 1‑column under 600px */
.sponsor-grid {
  display: grid;
  gap: 1rem;
  margin-top: 1rem;
  align-items: stretch;
  grid-template-columns: repeat(3, 1fr);
}
@media (max-width: 599px) {
  .sponsor-grid {
    grid-template-columns: 1fr;
  }
}

/* Individual sponsor cards */
.sponsor-card {
  background: #fff;
  padding: 1rem;
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 160px;
  cursor: pointer;
  transition: transform 0.2s;
}
.sponsor-card:hover {
  transform: scale(1.05);
}
.sponsor-card img {
  max-height: 80px;
  width: auto;
}
.sponsor-card.active {
  outline: 3px solid var(--primary-color);
  outline-offset: -3px;
}

/* Info panel spanning full width */
.sponsor-info-row {
  grid-column: 1 / -1;
}
.sponsor-info {
  max-height: 0;
  opacity: 0;
  overflow: hidden;
  transition: opacity .3s ease, max-height .3s ease;
}
.sponsor-info.show {
  max-height: 1000px; /* big enough */
  opacity: 1;
}

/* Fade‑in keyframes */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(-5px); }
  to   { opacity: 1; transform: translateY(0); }
}

/* Ad-blocker-safe inline external links */
.sponsor-info a {
  display: inline-block;
  color: var(--primary-color);
  text-decoration: underline;
  font-weight: 600;
  font-size: 1rem;
}
.sponsor-info a:hover,
.sponsor-info a:focus {
  color: var(--accent-color);
  outline: none;
}

:focus-visible {
  outline: 2px solid var(--accent-color);
  outline-offset: 2px;
}

/* =============================
   Contact Page Styles
============================= */

/* Contact card specific styling */
.contact-card {
  max-width: 700px;
  margin: 0 auto;
  padding: 2.5rem;
  background: var(--star-bg);
  border-radius: var(--border-radius);
  box-shadow: var(--shadow);
}

.contact-card h1 {
  color: var(--primary-color);
  font-size: 2.2rem;
  margin-bottom: 1.5rem;
  text-align: center;
}

/* Contact intro section */
.contact-intro {
  text-align: center;
  margin-bottom: 2rem;
  padding: 1.5rem;
  background: linear-gradient(135deg, #f8f9ff, #fff);
  border-radius: 12px;
  border-left: 4px solid var(--primary-color);
}

.contact-intro p {
  margin: 0.5rem 0;
  font-size: 1.1rem;
}

.contact-email {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  background: var(--primary-color);
  color: white;
  padding: 0.75rem 1.5rem;
  border-radius: 25px;
  text-decoration: none;
  font-weight: 600;
  margin: 1rem 0;
  transition: all 0.3s ease;
}

.contact-email:hover {
  background: var(--accent-color);
  color: var(--primary-color);
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.contact-email::before {
  content: "✉️";
  font-size: 1.2rem;
}

/* Form styling */
.contact-form {
  margin-top: 2rem;
}

.form-section-title {
  font-size: 1.3rem;
  color: var(--primary-color);
  font-weight: 600;
  margin-bottom: 1.5rem;
  text-align: center;
  position: relative;
}

.form-section-title::after {
  content: "";
  display: block;
  width: 60px;
  height: 3px;
  background: var(--accent-color);
  margin: 0.5rem auto 0;
  border-radius: 2px;
}

.form-row {
  margin-bottom: 1.5rem;
}

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

.form-row input,
.form-row textarea {
  width: 100%;
  padding: 0.875rem 1rem;
  border: 2px solid #e2e8f0;
  border-radius: var(--border-radius);
  font-family: var(--font-family);
  font-size: 1rem;
  transition: all 0.3s ease;
  background: #fafafa;
}

.form-row input:focus,
.form-row textarea:focus {
  outline: none;
  border-color: var(--primary-color);
  background: white;
  box-shadow: 0 0 0 3px rgba(75, 163, 255, 0.1);
}

.form-row textarea {
  resize: vertical;
  min-height: 120px;
  line-height: 1.6;
}

/* Submit button styling */
.form-submit {
  text-align: center;
  margin-top: 2rem;
}

.contact-form .primary-btn {
  background: linear-gradient(135deg, var(--primary-color), #357ae8);
  color: white;
  border: none;
  padding: 0.875rem 2rem;
  font-size: 1.1rem;
  font-weight: 600;
  border-radius: var(--border-radius);
  cursor: pointer;
  transition: all 0.3s ease;
  text-decoration: none;
  display: inline-block;
  min-width: 160px;
}

.contact-form .primary-btn:hover {
  background: linear-gradient(135deg, #357ae8, var(--primary-color));
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(75, 163, 255, 0.3);
}

.contact-form .primary-btn:active {
  transform: translateY(0);
}

/* Success and error messages */
.success {
  background: linear-gradient(135deg, #10b981, #059669);
  color: white;
  padding: 1rem 1.5rem;
  border-radius: var(--border-radius);
  text-align: center;
  font-weight: 600;
  margin: 1.5rem 0;
  box-shadow: 0 4px 12px rgba(16, 185, 129, 0.2);
}

.success::before {
  content: "✅ ";
  margin-right: 0.5rem;
}

.error {
  background: linear-gradient(135deg, #ef4444, #dc2626);
  color: white;
  padding: 1rem 1.5rem;
  border-radius: var(--border-radius);
  text-align: center;
  font-weight: 600;
  margin: 1.5rem 0;
  box-shadow: 0 4px 12px rgba(239, 68, 68, 0.2);
}

.error::before {
  content: "⚠️ ";
  margin-right: 0.5rem;
}

/* Thank you state styling */
.thank-you-message {
  text-align: center;
  padding: 3rem 2rem;
}

.thank-you-message h2 {
  color: var(--primary-color);
  font-size: 1.8rem;
  margin-bottom: 1rem;
}

.thank-you-message p {
  font-size: 1.1rem;
  color: #666;
  margin-bottom: 2rem;
}

/* Mobile responsiveness */
@media (max-width: 768px) {
  .contact-card {
    margin: 1rem;
    padding: 1.5rem;
  }
  
  .contact-card h1 {
    font-size: 1.8rem;
  }
  
  .contact-intro {
    padding: 1rem;
  }
  
  .contact-email {
    padding: 0.625rem 1rem; /* Reduced horizontal padding */
    font-size: 0.9rem; /* Slightly smaller font */
    word-break: break-all; /* Allow email to break if needed */
    max-width: 100%; /* Ensure it doesn't exceed container */
    box-sizing: border-box; /* Include padding in width calculation */
  }
  
  .form-row input,
  .form-row textarea {
    padding: 0.75rem;
  }
  
  .contact-form .primary-btn {
    padding: 0.75rem 1.5rem;
    font-size: 1rem;
    width: 100%;
  }
}

/* Loading state for form submission */
.contact-form.loading .primary-btn {
  opacity: 0.7;
  cursor: not-allowed;
  pointer-events: none;
}

.contact-form.loading .primary-btn::after {
  content: " ⏳";
}

/*.banner-image overrides removed to restore original behavior*/

footer.container {
  text-align: center;
  font-size: 0.9rem;
  padding: 2rem 1rem;
}
