/* Enhanced CSS Framework for Krav Maga Colchester - Header, Footer & Shop Modernization */

/* =========================================
   AOS EXCLUSION RULES - DISABLE ANIMATIONS FOR SPECIFIC SECTIONS
   ========================================= */
.no-aos,
.no-aos *,
#about,
#about * {
  opacity: 1 !important;
  transform: none !important;
  transition: none !important;
  animation: none !important;
}

/* =========================================
   FONT IMPORTS
   ========================================= */
@font-face {
  font-family: "Bebas Neue";
  src: url("../fonts/BebasNeue-Regular.ttf") format("truetype");
  font-weight: normal;
  font-style: normal;
  font-display: swap;
}

/* =========================================
   CSS VARIABLES - REFERENCE DESIGN SYSTEM
   ========================================= */
:root {
  /* Primary Colors - Reference Design (Updated to Red) */
  --primary: #d12727;
  --primary-hover: #b31e1e;
  --primary-light: #e04848;
  --secondary: #2b2b2b;
  --light: #f8f8f8;
  --dark: #1a1a1a;
  --accent: #ffffff;

  /* Text Colors */
  --text-dark: #1a1a1a;
  --text-light: #4a4a4a;
  --text-muted: #6c757d;

  /* Layout */
  --header-height: 88.5938px;
  --container-max-width: 1200px;

  /* Shadows */
  --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.1);
  --shadow-md: 0 4px 8px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 8px 16px rgba(0, 0, 0, 0.15);

  /* Transitions */
  --transition-fast: 0.15s ease;
  --transition-normal: 0.3s ease;
  --transition-slow: 0.5s ease;

  /* Border Radius */
  --radius-sm: 4px;
  --radius-md: 6px;
  --radius-lg: 10px;
}

/* =========================================
   BASE STYLES - REFERENCE DESIGN SYSTEM
   ========================================= */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  line-height: 1.6;
  color: var(--text-dark);
  background-color: var(--light);
  font-family: "Open Sans", sans-serif;
}

/* Ensure main content doesn't overlap with fixed header on login/register pages */
body.login-page main.container,
body.register-page main.container,
body.admin-login-page main.container {
  padding-top: calc(var(--header-height) + 2rem);
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: "Bebas Neue", sans-serif;
  letter-spacing: 1px;
  color: var(--text-dark);
}

html,
body {
  overflow-x: hidden;
}

html {
  scroll-behavior: smooth;
}

[id] {
  scroll-margin-top: 100px;
}

/* =========================================
   CONTAINER SYSTEM
   ========================================= */
.container {
  width: 90%;
  max-width: var(--container-max-width);
  margin: 0 auto;
  padding: 0 15px;
}

/* =========================================
   HEADER STYLES - REFERENCE DESIGN
   ========================================= */
header {
  background-color: var(--dark);
  color: var(--accent);
  position: fixed;
  width: 100%;
  top: 0;
  z-index: 100;
  box-shadow: var(--shadow-md);
  transition: all var(--transition-normal);
}

.header-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 0;
  min-height: var(--header-height);
}

.logo img {
  height: 50px;
  transition: transform var(--transition-normal);
}

.logo img:hover {
  transform: scale(1.05);
}

/* Navigation Links */
.nav-links {
  display: flex;
  list-style: none;
  align-items: center;
}

.nav-links li {
  margin-left: 2rem;
}

.nav-links a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 500;
  position: relative;
  padding: 0.5rem 0;
  transition: color var(--transition-normal);
}

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

.nav-links a::after {
  content: "";
  position: absolute;
  width: 0;
  height: 2px;
  bottom: 0;
  left: 0;
  background-color: var(--primary);
  transition: width var(--transition-normal);
}

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

/* Mobile Menu Button */
.mobile-menu {
  display: none;
  font-size: 1.5rem;
  cursor: pointer;
  color: var(--accent);
  transition: transform var(--transition-normal);
  padding: 0.5rem;
  z-index: 101;
  background: none;
  border: none;
}

.mobile-menu.active {
  transform: rotate(180deg);
}

/* =========================================
   BUTTON SYSTEM - REFERENCE DESIGN
   ========================================= */
.btn {
  display: inline-block;
  padding: 0.5rem 1.5rem;
  text-decoration: none;
  border-radius: var(--radius-md);
  font-weight: 500;
  text-align: center;
  transition: all var(--transition-normal);
  border: 2px solid transparent;
  cursor: pointer;
  font-family: inherit;
  line-height: 1.5;
}

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

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

.btn-secondary {
  background-color: var(--secondary);
  color: var(--accent);
  border-color: var(--secondary);
}

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

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

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

.btn-sm {
  padding: 0.375rem 1rem;
  font-size: 0.875rem;
}

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

/* CTA Button - Reference Design */
.cta-button {
  display: inline-block;
  background-color: #d12727;
  color: var(--accent);
  padding: 0.8rem 2rem;
  text-decoration: none;
  border-radius: 4px;
  font-weight: 600;
  text-transform: uppercase;
  font-family: "Bebas Neue", sans-serif;
  letter-spacing: 1px;
  transition: background-color 0.3s ease;
  border: none;
  cursor: pointer;
}

.cta-button:hover {
  background-color: #b31e1e;
  color: var(--accent);
}

/* =========================================
   FORM CONTROLS - ENHANCED STYLING
   ========================================= */
.form-control {
  display: block;
  width: 100%;
  padding: 0.5rem 1rem;
  font-size: 1rem;
  line-height: 1.5;
  color: var(--text-dark);
  background-color: var(--accent);
  background-clip: padding-box;
  border: 2px solid #dee2e6;
  border-radius: var(--radius-md);
  transition: all var(--transition-normal);
}

.form-control:focus {
  border-color: var(--primary);
  outline: 0;
  box-shadow: 0 0 0 0.2rem rgba(209, 39, 39, 0.25);
  background-color: var(--accent);
}

.form-control:hover {
  border-color: var(--primary-light);
}

/* =========================================
   CARD SYSTEM - ENHANCED STYLING
   ========================================= */
.card {
  position: relative;
  display: flex;
  flex-direction: column;
  min-width: 0;
  word-wrap: break-word;
  background-color: var(--accent);
  background-clip: border-box;
  border: none;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  transition: all var(--transition-normal);
}

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

.card-header {
  padding: 1.25rem 1.25rem;
  margin-bottom: 0;
  background-color: rgba(0, 0, 0, 0.03);
  border-bottom: 1px solid rgba(0, 0, 0, 0.125);
  border-top-left-radius: var(--radius-lg);
  border-top-right-radius: var(--radius-lg);
}

.card-body {
  flex: 1 1 auto;
  padding: 1.25rem;
}

.card-footer {
  padding: 1.25rem 1.25rem;
  background-color: rgba(0, 0, 0, 0.03);
  border-top: 1px solid rgba(0, 0, 0, 0.125);
  border-bottom-left-radius: var(--radius-lg);
  border-bottom-right-radius: var(--radius-lg);
}

/* =========================================
   CALENDAR STYLING - UPDATED COLORS
   ========================================= */
#calendar {
  min-height: 500px;
  background: var(--accent);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-sm);
  padding: 1rem;
}

.fc-event {
  cursor: pointer;
  border: none;
  background: linear-gradient(45deg, var(--primary), var(--primary-hover));
  border-radius: var(--radius-md);
  transition: all var(--transition-normal);
}

.fc-event:hover {
  background: linear-gradient(45deg, var(--primary-hover), var(--primary));
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.fc-event-title,
.fc-event-time {
  color: white !important;
  font-weight: 500;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

/* =========================================
   ALERT SYSTEM - UPDATED COLORS
   ========================================= */
.alert {
  position: relative;
  padding: 0.75rem 1.25rem;
  margin-bottom: 1rem;
  border: 1px solid transparent;
  border-radius: var(--radius-md);
}

.alert-success {
  color: #155724;
  background-color: #d4edda;
  border-color: #c3e6cb;
}

.alert-danger {
  color: #721c24;
  background-color: #f8d7da;
  border-color: #f5c6cb;
}

.alert-warning {
  color: #856404;
  background-color: #fff3cd;
  border-color: #ffeaa7;
}

.alert-info {
  color: #0c5460;
  background-color: #d1ecf1;
  border-color: #bee5eb;
}

.alert-primary {
  color: #721c24;
  background-color: rgba(209, 39, 39, 0.1);
  border-color: rgba(209, 39, 39, 0.2);
}

/* =========================================
   BADGE SYSTEM - UPDATED COLORS
   ========================================= */
.badge {
  display: inline-block;
  padding: 0.35em 0.65em;
  font-size: 0.75em;
  font-weight: 700;
  line-height: 1;
  text-align: center;
  white-space: nowrap;
  vertical-align: baseline;
  border-radius: var(--radius-sm);
}

.badge-primary {
  color: var(--accent);
  background-color: var(--primary);
}

.badge-secondary {
  color: var(--accent);
  background-color: var(--secondary);
}

.badge-success {
  color: var(--accent);
  background-color: #28a745;
}

.badge-danger {
  color: var(--accent);
  background-color: #dc3545;
}

.badge-warning {
  color: var(--text-dark);
  background-color: #ffc107;
}

.badge-info {
  color: var(--accent);
  background-color: #17a2b8;
}

/* =========================================
   TABLE STYLING - ENHANCED
   ========================================= */
.table {
  width: 100%;
  margin-bottom: 1rem;
  color: var(--text-dark);
  background-color: var(--accent);
  border-collapse: collapse;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: var(--shadow-sm);
}

.table th,
.table td {
  padding: 0.75rem;
  vertical-align: top;
  border-top: 1px solid #dee2e6;
}

.table thead th {
  vertical-align: bottom;
  border-bottom: 2px solid #dee2e6;
  background-color: var(--light);
  font-weight: 600;
  color: var(--text-dark);
}

.table tbody tr:hover {
  background-color: rgba(209, 39, 39, 0.05);
}

/* =========================================
   ADMIN SPECIFIC STYLES
   ========================================= */
.btn-view-student-trigger:hover {
  color: var(--primary-hover) !important;
  text-decoration: underline !important;
}

/* Admin Dashboard Cards */
.admin-card {
  background: linear-gradient(135deg, var(--accent) 0%, var(--light) 100%);
  border-left: 4px solid var(--primary);
  transition: all var(--transition-normal);
}

.admin-card:hover {
  border-left-color: var(--primary-hover);
  transform: translateX(4px);
}

/* =========================================
   UTILITY CLASSES
   ========================================= */
.text-primary {
  color: var(--primary) !important;
}
.text-secondary {
  color: var(--secondary) !important;
}
.text-dark {
  color: var(--text-dark) !important;
}
.text-light {
  color: var(--text-light) !important;
}
.text-muted {
  color: var(--text-muted) !important;
}

.bg-primary {
  background-color: var(--primary) !important;
}
.bg-secondary {
  background-color: var(--secondary) !important;
}
.bg-light {
  background-color: var(--light) !important;
}
.bg-dark {
  background-color: var(--dark) !important;
}

.border-primary {
  border-color: var(--primary) !important;
}
.border-secondary {
  border-color: var(--secondary) !important;
}

/* =========================================
   SECTION STYLING - REFERENCE DESIGN
   ========================================= */
.section {
  padding: 4rem 0;
  position: relative;
  z-index: 2;
  /* Ensure sections maintain proper stacking context */
  background-color: white;
  margin-top: 0;
}

.section-title {
  text-align: center;
  margin-bottom: 3rem;
}

.section-title h2 {
  font-size: 2.5rem;
  font-family: "Bebas Neue", sans-serif;
  letter-spacing: 1px;
  color: var(--text-dark);
  position: relative;
  display: inline-block;
}

.section-title h2:after {
  content: "";
  display: block;
  width: 80px;
  height: 4px;
  background-color: var(--primary);
  margin: 1rem auto 0;
}

/* About Section Specific Styling */
.about-content {
  display: flex;
  align-items: center;
  gap: 2rem;
}

.about-text h2 {
  font-size: 2.5rem;
  font-family: "Bebas Neue", sans-serif;
  letter-spacing: 1px;
  color: var(--text-dark);
  margin-bottom: 1rem;
  position: relative;
}

.about-text h2:after {
  content: "";
  display: block;
  width: 80px;
  height: 4px;
  background-color: var(--primary);
  margin: 1rem 0;
}

.about-text h3 {
  font-size: 1.8rem;
  font-family: "Bebas Neue", sans-serif;
  color: var(--text-dark);
  margin-bottom: 1rem;
}

.about-text h4 {
  font-size: 1.5rem;
  font-family: "Bebas Neue", sans-serif;
  color: var(--text-dark);
  margin-bottom: 1.5rem;
}

.about-text p {
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text-light);
  margin-bottom: 1rem;
}

/* Dark Background Sections */
.instructors-section,
.membership-section,
.testimonials-section {
  background-color: var(--dark);
  color: var(--accent);
  width: 100vw;
  position: relative;
  left: 50%;
  right: 50%;
  margin-left: -50vw;
  margin-right: -50vw;
  /* Ensure they don't affect document flow */
  margin-top: 0;
  margin-bottom: 0;
  z-index: 2;
}

/* White Background Sections (Default) */
.classes-section,
.faq-section {
  background-color: var(--accent);
  color: var(--text-dark);
}

.faq-section .section-title h2 {
  color: var(--text-dark);
}

.faq-section .section-title h2:after {
  background-color: var(--primary);
}

.faq-section .section-title p {
  color: var(--text-light);
}

.instructors-section .section-title h2,
.membership-section .section-title h2,
.testimonials-section .section-title h2 {
  color: var(--accent);
}

.instructors-section .section-title h2:after,
.membership-section .section-title h2:after,
.testimonials-section .section-title h2:after {
  background-color: var(--primary);
}

.instructors-section .section-title p,
.membership-section .section-title p,
.testimonials-section .section-title p {
  color: rgba(255, 255, 255, 0.8);
}

.instructors-section .card {
  background-color: var(--accent);
  border: none;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.instructors-section .card:hover {
  transform: translateY(-8px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
}

.instructors-section .alert-info,
.membership-section .alert-info,
.testimonials-section .alert-info {
  background-color: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.2);
  color: var(--accent);
}

/* Membership Section Specific */
.membership-section .card {
  background-color: var(--accent);
  border: none;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.3);
}

.membership-section .card:hover {
  transform: translateY(-8px);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.4);
}

.membership-section .alert-light {
  background-color: rgba(255, 255, 255, 0.1);
  border-color: rgba(255, 255, 255, 0.2);
  color: var(--accent);
}

/* About Section Layout - Compact Design */
.about-content {
  margin-top: 2rem;
}

.about-text h3 {
  font-size: 1.75rem;
  font-family: "Bebas Neue", sans-serif;
  color: var(--text-dark);
  margin-bottom: 1.5rem;
}

.about-text p {
  font-size: 1rem;
  line-height: 1.6;
  color: var(--text-light);
  margin-bottom: 1.2rem;
}

.about-text .cta-button {
  margin-top: 1.5rem;
}

/* Desktop Layout - Improved Flexbox Layout */
@media (min-width: 992px) {
  .about-content {
    display: flex !important;
    align-items: center;
    gap: 4rem;
    margin-top: 3rem;
    flex-wrap: nowrap;
  }

  .about-content .col-lg-6:first-child {
    flex: 0 0 45% !important;
    max-width: 45% !important;
    padding-right: 0 !important;
    margin-bottom: 0 !important;
  }

  .about-content .col-lg-6:last-child {
    flex: 0 0 55% !important;
    max-width: 55% !important;
    padding-left: 0 !important;
    margin-bottom: 0 !important;
  }

  .about-text {
    padding: 0;
    padding-left: 2rem;
    height: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center;
  }

  .about-text h3 {
    font-size: 2rem;
    margin-bottom: 1.5rem;
  }

  .about-text p {
    font-size: 1.1rem;
    line-height: 1.7;
    margin-bottom: 1.3rem;
  }

  .about-text .cta-button {
    margin-top: 2rem;
    display: inline-block;
    width: auto;
    max-width: fit-content;
  }

  /* Ensure image doesn't get too large */
  .about-content img {
    max-height: 400px;
    width: 100%;
    object-fit: cover;
  }
}

/* Fix chatbot badge clipping - ensure container doesn't clip overflow */
#kmc-chatbot-container {
  overflow: visible !important;
}

.kmc-chatbot-toggle {
  overflow: visible !important;
  position: relative;
}

/* Ensure chatbot badge is properly positioned and visible */
.kmc-chatbot-badge {
  position: absolute;
  top: -8px;
  right: -8px;
  background: #2d3748;
  color: white;
  font-size: 10px;
  font-weight: 600;
  padding: 2px 6px;
  border-radius: 10px;
  border: 2px solid white;
  letter-spacing: 0.5px;
  z-index: 10001;
  white-space: nowrap;
  pointer-events: none;
}

/* Testimonials Glide Centering Fix */
#testimonials-glide {
  max-width: 100%;
  margin: 0 auto;
}

.glide__track {
  display: flex;
  justify-content: center;
  align-items: center;
}

.glide__slides {
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  padding: 0;
  list-style: none;
}

/* Desktop centering for testimonials */
@media (min-width: 992px) {
  #testimonials-glide {
    display: flex;
    justify-content: center;
    align-items: center;
  }

  .glide__track {
    justify-content: center;
    width: 100%;
  }

  .glide__slides {
    justify-content: center;
  }
}

/* Calendar Space Efficiency Improvements */
.calendar-container {
  padding: 1rem !important;
}

.fc {
  font-size: 0.9rem;
}

.fc-header-toolbar {
  margin-bottom: 0.5rem !important;
  padding: 0.5rem 0;
}

.fc-daygrid-day {
  min-height: 80px !important;
}

.fc-day-today {
  background-color: rgba(209, 39, 42, 0.1) !important;
}

/* Remove extra spacing in calendar */
.fc-daygrid-body {
  margin-top: 0 !important;
}

.fc-scrollgrid {
  border: 1px solid #dee2e6 !important;
}

/* Compact event display */
.fc-event {
  font-size: 0.8rem;
  padding: 1px 3px;
  margin: 1px 0;
}

.fc-event-title {
  font-weight: 500;
}

/* Hide empty weeks more aggressively */
.fc-daygrid-week:not(:has(.fc-event)):not(:has(.fc-day-today)) {
  display: none;
}

/* Hide past dates (grey squares) - only show current week onwards */
.fc-day-past:not(.fc-day-today) {
  display: none !important;
}

/* Hide past weeks entirely if they contain only past dates */
.fc-daygrid-week:has(.fc-day-past):not(:has(.fc-day-today)):not(
    :has(.fc-day-future)
  ) {
  display: none !important;
}

/* Ensure proper spacing when past dates are hidden */
.fc-daygrid-body-unbalanced .fc-daygrid-week:first-child {
  border-top: none !important;
}

/* Make sure the calendar starts cleanly from current week */
.fc-daygrid-day-frame {
  min-height: 80px;
}

/* Contact Section Styling */
.contact-section {
  background-color: var(--light);
  color: var(--text-dark);
}

.contact-info h3 {
  font-family: "Bebas Neue", sans-serif;
  color: var(--text-dark);
  font-size: 1.75rem;
}

.contact-item {
  padding: 1rem 0;
  border-bottom: 1px solid rgba(0, 0, 0, 0.1);
}

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

.contact-icon {
  width: 50px;
  height: 50px;
  background: var(--primary);
  color: white;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  flex-shrink: 0;
  position: relative;
}

.contact-icon i {
  font-size: 1.2rem;
  color: white;
  z-index: 2;
  position: relative;
}

/* Fallback text if FontAwesome doesn't load */
.contact-icon::before {
  position: absolute;
  color: white;
  font-weight: bold;
  font-size: 0.9rem;
  z-index: 1;
}

.contact-icon:has(.fa-map-marker-alt)::before {
  content: "📍";
  font-size: 1.1rem;
}

.contact-icon:has(.fa-phone)::before {
  content: "📞";
  font-size: 1.1rem;
}

.contact-icon:has(.fa-envelope)::before {
  content: "📧";
  font-size: 1.1rem;
}

.contact-icon:has(.fa-share-alt)::before {
  content: "🌐";
  font-size: 1.1rem;
}

/* Hide fallback when FontAwesome is working */
.contact-icon i:not(.fa-fallback) ~ ::before {
  display: none;
}

.contact-details h5 {
  font-family: "Bebas Neue", sans-serif;
  color: var(--text-dark);
  margin-bottom: 0.5rem;
  font-size: 1.1rem;
}

.contact-link {
  color: var(--text-light);
  text-decoration: none;
  transition: color var(--transition-normal);
  line-height: 1.6;
}

.contact-link:hover {
  color: var(--primary);
  text-decoration: none;
}

.social-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
}

.social-link {
  color: var(--text-light);
  text-decoration: none;
  transition: color var(--transition-normal);
  font-weight: 500;
}

.social-link:hover {
  color: var(--primary);
  text-decoration: none;
}

.social-link i {
  margin-right: 0.5rem;
  font-size: 1.1rem;
}

.map-container h3 {
  font-family: "Bebas Neue", sans-serif;
  color: var(--text-dark);
  font-size: 1.75rem;
}

.map-wrapper {
  box-shadow: var(--shadow-md);
  border-radius: 8px;
  overflow: hidden;
}

.map-wrapper iframe {
  width: 100%;
  height: 400px;
  border: none;
}

/* Contact section responsive adjustments */
@media (max-width: 991px) {
  .contact-section .row {
    text-align: center;
  }

  .contact-item {
    justify-content: center;
    text-align: center;
  }

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

  .social-links {
    justify-content: center;
  }
}

/* =========================================
   RESPONSIVE DESIGN
   ========================================= */
@media (max-width: 768px) {
  .mobile-menu-trigger {
    display: block;
  }

  .nav-wrapper {
    position: fixed;
    top: var(--header-height);
    left: 0;
    width: 100%;
    height: calc(100vh - var(--header-height));
    background-color: var(--dark);
    transform: translateX(100%);
    opacity: 0;
    visibility: hidden;
    overflow-y: auto;
    transition: transform var(--transition-normal),
      opacity var(--transition-normal), visibility var(--transition-normal);
    display: flex;
    flex-direction: column;
  }

  .nav-wrapper.is-active {
    transform: translateX(0);
    opacity: 1;
    visibility: visible;
  }

  .nav-links {
    display: flex;
    flex-direction: column;
    justify-content: flex-start;
    align-items: center;
    padding: 0.75rem 1rem;
    height: 100%;
  }

  .nav-links li {
    margin: 0.1rem 0;
    width: 100%;
  }

  .nav-links a {
    font-size: 0.95rem;
    padding: 0.5rem 1rem;
    display: block;
    width: 100%;
    text-align: center;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    transition: background-color var(--transition-normal);
  }

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

  .nav-links li:last-child a {
    border-bottom: none;
  }

  .mobile-menu {
    display: block;
  }

  .container {
    width: 95%;
    padding: 0 10px;
  }

  h1 {
    font-size: 2.5rem;
  }
  h2 {
    font-size: 2rem;
  }
  h3 {
    font-size: 1.75rem;
  }

  .btn {
    display: block;
    width: 100%;
    margin: 0.5rem 0;
  }

  .card {
    margin: 1rem 0;
  }

  .about-content {
    flex-direction: column;
    text-align: center;
  }

  .about-text h2:after {
    margin: 1rem auto;
  }
}

@media (max-width: 576px) {
  .header-container {
    padding: 0.5rem 0;
  }

  .logo img {
    height: 40px;
  }

  h1 {
    font-size: 2rem;
  }
  h2 {
    font-size: 1.5rem;
  }
  h3 {
    font-size: 1.25rem;
  }
}

/* =========================================
   ANIMATION CLASSES (Prepared for AOS)
   ========================================= */
.fade-in {
  opacity: 0;
  transform: translateY(30px);
  transition: all 0.6s ease;
}

.fade-in.aos-animate {
  opacity: 1;
  transform: translateY(0);
}

.slide-up {
  opacity: 0;
  transform: translateY(50px);
  transition: all 0.8s ease;
}

.slide-up.aos-animate {
  opacity: 1;
  transform: translateY(0);
}

.zoom-in {
  opacity: 0;
  transform: scale(0.9);
  transition: all 0.6s ease;
}

.zoom-in.aos-animate {
  opacity: 1;
  transform: scale(1);
}

/* =========================================
   LEGACY COMPATIBILITY
   ========================================= */
/* Maintain existing class names for backward compatibility */
.fc-event-title,
.fc-event-time {
  color: white !important;
  font-weight: 500;
  text-shadow: 0 1px 2px rgba(0, 0, 0, 0.3);
}

/* =========================================
   MAP STYLES - FIX OVERLAPPING
   ========================================= */
.map-container {
  position: relative;
  z-index: 1;
}

.map-wrapper {
  position: relative;
  z-index: 1;
}

#map {
  position: relative;
  z-index: 1;
}

/* Ensure Leaflet controls don't interfere */
.leaflet-control-container {
  z-index: 2 !important;
}

.leaflet-popup {
  z-index: 3 !important;
}

/* =========================================
   FOOTER STYLES - REFERENCE DESIGN
   ========================================= */
.footer-section {
  background-color: var(--dark);
  color: var(--accent);
  padding: 2rem 0;
  text-align: center;
  margin-top: auto;
}

.footer-content {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 1.5rem;
}

.footer-logo img {
  height: 50px;
  max-width: 200px;
  object-fit: contain;
}

.footer-links {
  display: flex;
  list-style: none;
  gap: 1.5rem;
  margin: 0;
  padding: 0;
  flex-wrap: wrap;
  justify-content: center;
}

.footer-links li {
  margin: 0;
}

.footer-links a {
  color: var(--accent);
  text-decoration: none;
  font-weight: 500;
  padding: 0.25rem 0.5rem;
  border-radius: var(--radius-sm);
  transition: color var(--transition-normal);
}

.footer-links a:hover {
  color: var(--primary);
}

.footer-content .copyright {
  font-size: 0.9rem;
  margin: 0;
  color: var(--accent);
}

.footer-content p:last-child {
  font-size: 0.9rem;
  margin: 0;
  color: var(--accent);
}

.footer-content p:last-child a {
  color: var(--accent);
  text-decoration: underline;
  transition: color var(--transition-normal);
}

.footer-content p:last-child a:hover {
  color: var(--primary);
}

/* Footer responsive design */
@media (max-width: 768px) {
  .footer-links {
    flex-wrap: wrap;
    justify-content: center;
    gap: 1rem;
  }

  .footer-links a {
    font-size: 0.9rem;
  }

  .footer-content {
    gap: 1rem;
  }
}

@media (max-width: 576px) {
  .footer-links {
    flex-direction: column;
    gap: 0.5rem;
    align-items: center;
  }

  .footer-links a {
    display: block;
    text-align: center;
    padding: 0.5rem;
  }

  .footer-content .copyright,
  .footer-content p:last-child {
    font-size: 0.8rem;
    text-align: center;
  }
}

/* =========================================
   CLASS IMAGE CONSISTENCY
   ========================================= */

.class-image-container {
  position: relative;
  width: 100%;
  /* Use aspect-ratio for modern browsers */
  aspect-ratio: 1 / 1;
  /* Fallback for older browsers */
  height: 0;
  padding-bottom: 100%; /* Creates 1:1 ratio */
  overflow: hidden;
  border-radius: 8px 8px 0 0;
  background: var(--primary);
}

/* For browsers that support aspect-ratio, remove padding fallback */
@supports (aspect-ratio: 1 / 1) {
  .class-image-container {
    height: auto;
    padding-bottom: 0;
  }
}

.class-image-container img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  transition: transform 0.3s ease;
}

.class-image-container:hover img {
  transform: scale(1.05);
}

.class-image-placeholder {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(
    135deg,
    var(--primary) 0%,
    var(--primary-hover) 100%
  );
  border-radius: 8px 8px 0 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* Ensure consistent card heights - adjust for 1:1 ratio */
.classes-section .card {
  min-height: auto; /* Let content determine height */
}

.classes-section .card-body {
  display: flex;
  flex-direction: column;
  padding: 1.5rem;
  flex-grow: 1;
}

.classes-section .class-details {
  margin-top: auto;
}

/* Remove responsive height adjustments since aspect-ratio handles it */
@media (max-width: 768px) {
  /* Aspect ratio will automatically adjust, no need for fixed height */
  .class-image-container {
    /* All sizing handled by aspect-ratio */
  }

  .classes-section .card {
    min-height: auto;
  }
}

@media (max-width: 576px) {
  .class-image-container {
    border-radius: 6px 6px 0 0;
  }

  .class-image-placeholder {
    border-radius: 6px 6px 0 0;
  }
}

@media (max-width: 480px) {
  .classes-section .card-body {
    padding: 1rem;
  }
}

/* Clean modal styling - Bootstrap 5 compatible */
.modal-content {
  border-radius: 0.5rem;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

/* Mobile responsive modal adjustments */
@media (max-width: 576px) {
  .modal-dialog {
    margin: 1rem;
    max-width: calc(100vw - 2rem);
  }

  .modal-content {
    max-height: calc(100vh - 2rem);
    overflow-y: auto;
  }
}
.modal-body {
  position: relative !important;
  z-index: 1 !important;
  background: white !important;
}

/* Fix any potential header/footer conflicts */
header,
.header-container {
  z-index: 1000 !important;
}

footer,
.footer-section {
  z-index: 1000 !important;
}

/* Class card hover effect improvement */
#classes .card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
  transition: all 0.3s ease;
}

#classes .card {
  transition: all 0.3s ease;
  cursor: pointer;
}

/* View Details button styling */
.card-footer .btn {
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  transition: all 0.3s ease;
}

.card-footer .btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}
