/* Modern Clean Timeline Design */

/* Base Variables */
:root {
  /* Color System */
  --color-background: #f8f9fa;
  --color-surface: #ffffff;
  --color-surface-variant: #f3f4f6;
  --color-primary: #34857a;
  --color-primary-light: #50a89b;
  --color-primary-dark: #225e54;
  --color-secondary: #e4775e;
  --color-accent: #ffc23c;

  --rwb-gradient: linear-gradient(180deg, #dc5656 33.3%, #ffffff 33.3%, #ffffff 66.6%, #50aa4d 66.6%);


  /* Category Colors */
  --color-conservation: #3ab795;
  --color-development: #ee6c4d;
  --color-special: #ffd166;

  /* Text Colors */
  --color-text-primary: #1a2b33;
  --color-text-secondary: #4b5563;
  --color-text-tertiary: #646f7d;
  --color-text-light: #ffffff;

  /* Elevations & Effects */
  --shadow-sm: 0 1px 2px rgba(0,0,0,0.04), 0 2px 4px rgba(0,0,0,0.06);
  --shadow-md: 0 4px 6px rgba(0,0,0,0.04), 0 10px 15px rgba(0,0,0,0.05);
  --shadow-lg: 0 10px 25px rgba(0,0,0,0.05), 0 20px 48px rgba(0,0,0,0.07);
  --shadow-focus: 0 0 0 3px rgba(52, 133, 122, 0.25);

  /* Animation Timings */
  --transition-fast: 150ms cubic-bezier(0.25, 0.8, 0.25, 1);
  --transition-normal: 300ms cubic-bezier(0.25, 0.8, 0.25, 1);
  --transition-slow: 500ms cubic-bezier(0.25, 0.8, 0.25, 1);
  --transition-bounce: 500ms cubic-bezier(0.34, 1.56, 0.64, 1);

  /* Spacing System */
  --spacing-xxs: 0.25rem;
  --spacing-xs: 0.5rem;
  --spacing-sm: 0.75rem;
  --spacing-md: 1rem;
  --spacing-lg: 1.5rem;
  --spacing-xl: 2rem;
  --spacing-2xl: 2.5rem;
  --spacing-3xl: 3rem;
  --spacing-4xl: 4rem;

  /* Border Radius */
  --radius-sm: 0.25rem;
  --radius-md: 0.5rem;
  --radius-lg: 1rem;
  --radius-full: 9999px;

  /* Timeline Specific */
  --timeline-width: 3px;
  --timeline-dot-size: 30px;
  --timeline-item-spacing: 3rem;
}

/* Base Reset & Typography */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

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

body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  color: var(--color-text-primary);
  background-color: var(--color-background);
  line-height: 1.6;
  overflow-x: hidden;


}

.body-bg {
  position:fixed;
  top:0;
  left:0;
  right:0;
  bottom:0;
  width:100%;
  height: 100%;
  background-image: linear-gradient(to bottom right, rgb(176 223 247) 0%, rgb(225 236 247 / 80%) 30%, rgba(248, 249, 250, 0.1) 60%), url(assets/bg1.avif);
  background-position: bottom right;
  background-repeat: no-repeat;
  background-size: cover;
  background-attachment: fixed;
  z-index: -1;
  overflow: hidden;
}

h1, h2, h3, h4, h5, h6 {
  /* font-family: 'Playfair Display', serif; */
  font-weight: 900;
  line-height: 1.25;
  text-transform:uppercase;
  letter-spacing: -0.03em;
  font-family: 'Montserrat', sans-serif;
  /* font-family:'Gotham'; */

}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 var(--spacing-lg);
}

/* Modern Header - Simplified */
.page-header {
  background: linear-gradient(180deg, #3b4c93, transparent);
  color: var(--color-text-light);
  padding: var(--spacing-3xl) 0;
  position: relative;
  height:350px;
  /* Ensure header container allows text to scale without being cut off */
  overflow: visible;
}



.page-header .container {
  position: fixed;
  /* z-index: 1; */
  max-width: 100%;
  width:100%;
  text-align: center;
    /* Animation setup */
  animation: header-text-scroll linear forwards;
  animation-timeline: scroll(root);
  /* Animate over the first 250px of page scroll */
  animation-range: 0 300px;
  transform-origin: top; /* Scale from the center */
}

.page-title {
  font-size: clamp(2rem, 5vw, 3rem);
  margin-bottom: var(--spacing-md);
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.page-title .accent {
  color: var(--color-accent);
  /* font-style: italic; */
}

.page-subtitle {
  font-size: clamp(1rem, 2vw, 1.25rem);
  opacity: 0.9;
}

/* Timeline Section */
.timeline-section {
  min-height: 100svh;
  padding: var(--spacing-3xl) 0 var(--spacing-4xl);
  position: relative;
  z-index: 1;


}

/* Timeline Categories - Modern Pills */
.timeline-categories {
  display: flex;
  flex-wrap: wrap;
  gap: var(--spacing-sm);
  margin: auto;
  margin-bottom: var(--spacing-3xl);
  justify-content: center;
  max-width: 1000px;
  width: fit-content;
  padding: var(--spacing-xs); /* Slightly reduced padding */
  border-radius: var(--radius-full); /* Make container fully rounded */
  background: rgba(255, 255, 255, 0.6); /* Lighter, less transparent background */
  backdrop-filter: blur(8px); /* Slightly stronger blur */
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08); /* Softer outer shadow */
  border: 1px solid rgba(255, 255, 255, 0.2); /* Subtle border */
}

.category-btn,
.sort-btn { /* Apply base styles to both button types */
  display: flex;
  align-items: center;
  gap: var(--spacing-xs);
  padding: var(--spacing-sm) var(--spacing-lg);
  border-radius: var(--radius-full);
  border: 1px solid transparent; /* Prepare for border transition */
  background-color: transparent; /* Make default transparent within the container */
  color: var(--color-text-secondary);
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition-normal);
  font-size: 0.9rem;
  box-shadow: none; /* Remove default shadow */
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
}

.category-btn .btn-icon,
.sort-btn .btn-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 24px;
  height: 24px;
  border-radius: var(--radius-full);
  background-color: rgba(0, 0, 0, 0.05);
  transition: all var(--transition-normal);

}

.category-btn:hover,
.sort-btn:hover {
  background-color: rgba(255, 255, 255, 0.5); /* Subtle background on hover */
  color: var(--color-text-primary);
  /* transform: translateY(-1px); */ /* Optional subtle lift */
  border-color: rgba(0, 0, 0, 0.05); /* Subtle border on hover */
}

.category-btn.active {
  background-color: var(--color-primary);
  color: var(--color-text-light);
  box-shadow: 0 2px 8px rgba(52, 133, 122, 0.3); /* Shadow for active state */
  border-color: transparent;
}

.category-btn.active .btn-icon {
  background-color: rgba(255, 255, 255, 0.2);
}

.sort-btn.reversed .btn-icon i {
  transform: rotate(180deg);
}

.sort-btn.reversed {
  /* background-color: var(--color-accent); */
  color: var(--color-text-primary);
  /* box-shadow: 0 2px 8px rgba(255, 194, 60, 0.4); Shadow for reversed state */
  border-color: transparent;
}

.sort-btn.reversed .btn-icon {
  background-color: rgba(255, 255, 255, 0.2);
}

/* Responsive adjustments for the sort button */
@media (max-width: 768px) {
  /* ... existing responsive styles ... */
  .timeline-categories {
    padding: var(--spacing-xs); /* Ensure padding consistency */
  }
}

/* --- Responsive Design --- */

/* Mobile specific styles for filter/sort buttons */
@media (max-width: 600px) {
    .timeline-categories {
        position: fixed; /* Fix to viewport */
        bottom: 0;       /* Align to bottom */
        left: 0;         /* Align to left */
        right: 0;        /* Align to right */
        width: 100%;     /* Full width */
        z-index: 50;     /* Ensure it's above timeline content */

        flex-direction: row; /* Keep buttons in a row */
        justify-content: space-around; /* Distribute buttons evenly */
        align-items: center; /* Center items vertically */
        gap: 0.25rem; /* Reduce gap between buttons */
        padding: var(--spacing-xs) var(--spacing-xs); /* Reduce vertical padding */
        border-radius: 0; /* Remove border-radius for bottom bar */
        background: rgba(248, 249, 250, 0.9); /* More opaque background */
        backdrop-filter: blur(10px);
        box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.1); /* Shadow on top edge */
        border-top: 1px solid rgba(0, 0, 0, 0.05); /* Subtle top border */
        /* Remove margin-bottom as it's fixed */
        margin-bottom: 0;
    }

    .category-btn,
    .sort-btn {
        /* width: auto; */ /* Keep width auto */
        flex-grow: 0; /* Don't grow, let them size naturally */
        flex-basis: auto; /* Reset basis */
        justify-content: center;
        padding: 0.5rem; /* Reduce padding, make more square */
        font-size: 0.8rem;
        background-color: transparent;
        border: none;
        border-radius: var(--radius-full); /* Keep buttons round */
        min-width: 40px; /* Ensure minimum touch target size */
        min-height: 40px; /* Ensure minimum touch target size */
    }

    .category-btn .btn-icon,
    .sort-btn .btn-icon {
        margin-right: 0; /* Remove margin as text is hidden */
        font-size: 1rem; /* Slightly larger icon */
    }

    /* Hide button text on mobile */
    .category-btn .btn-text,
    .sort-btn .btn-text {
        display: none;
    }

    /* Adjust active/hover states for bottom bar */
     .category-btn:hover,
    .sort-btn:hover {
      background-color: rgba(0, 0, 0, 0.05);
      border-color: transparent;
    }

    .category-btn.active {
      background-color: rgba(52, 133, 122, 0.15);
      color: var(--color-primary-dark);
      box-shadow: none;
      border-radius: var(--radius-full);
    }

    /* Make active icon more prominent */
    .category-btn.active .btn-icon {
        color: var(--color-primary);
    }

    .sort-btn.reversed {
      background-color: rgba(255, 194, 60, 0.2);
      color: #a06d00;
      box-shadow: none;
      border-radius: var(--radius-full);
    }

    /* Make reversed icon more prominent */
    .sort-btn.reversed .btn-icon {
        color: #a06d00;
    }


    /* Add padding to the bottom of the timeline section to avoid overlap */
    .timeline-section {
        /* Adjust padding based on the new, smaller height of the fixed bar */
        /* Height approx: padding-top + padding-bottom + button height */
        /* Example: 0.5rem + 0.5rem + 40px = ~3.5rem */
        padding-bottom: calc(var(--spacing-4xl) + 3.5rem); /* Adjust extra space */
    }
}

/* Main Timeline */
.timeline-container {
  position: relative;
}

.timeline {
  position: relative;
  padding: 0;
  max-width: 1000px;
  margin: 0 auto;
}

/* The vertical line */
.timeline::before {
  content: "";
  position: absolute;
  left: 50%;
  top: 0;
  bottom: 0;
  width: var(--timeline-width);
  transform: translateX(-50%);
  /* background: linear-gradient(to bottom, var(--color-primary-light), var(--color-primary-dark)); */
  background: var(--color-surface-variant);
  mask-image: linear-gradient( to bottom, hsl(0 0% 0% / 0), 60px, hsl(0 0% 0% / 1) 20%, hsl(0 0% 0% / 1) calc(100% - 60px), hsl(0 0% 0% / 0) 100% );
  /* box-shadow: 0 0 10px rgba(52, 133, 122, 0.2); */
}

/* Timeline Item */
.timeline-item {
  position: relative;
  margin-bottom: var(--timeline-item-spacing);
  display: flex;
  justify-content: center;
  opacity: 0;
  transform: translateY(30px);
  transition: opacity var(--transition-slow), transform var(--transition-slow);
  width: 100%;
  perspective: 1000px; /* Add perspective for 3D effect */
}

.timeline-item[data-category="conservation"] {
 --color-cat: var(--color-conservation);
}
.timeline-item[data-category="development"] {
 --color-cat: var(--color-development);
}

.timeline-item[data-category="special"] {
 --color-cat: var(--color-special);
}

.timeline-item.visible {
  opacity: 1;
  transform: translateY(0);
}

/* Left-side items */
.timeline-item.odd {
  flex-direction: row;
  perspective-origin: right;
}

/* Right-side items */
.timeline-item.even {
  flex-direction: row-reverse;
  perspective-origin: left;
}

/* Marker now in the center */
.timeline-marker {
  position: absolute;
  left: 50%;
  top:40%;
  transform: translateX(-50%);
  width: auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  z-index: 5;
}

.marker-line {
  display: none; /* Hide the line as we have a central timeline */
}

.marker-point {
  width: var(--timeline-dot-size);
  height: var(--timeline-dot-size);
  border-radius: 50%;
  /* background: linear-gradient(145deg, var(--color-primary), var(--color-primary-dark)); */
  background: var(--color-cat);
  display: flex;
  align-items: center;
  justify-content: center;
  color: white;
  font-size: 100%;
  box-shadow: 0 0 0 4px var(--color-cat);
  z-index: 2;
}

.marker-date {
  position: absolute;
  top: -24px;
  width: 100%;
  text-align: center;
  font-size: 0.7rem;
  font-weight: 500;
  color: var(--color-text-tertiary);
  white-space: nowrap;
}

/* Timeline Card - Enhanced for alternating layout */
.timeline-card {
  background-color: #ffffffd1;
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
  overflow: hidden;
  /* transition: transform var(--transition-normal), box-shadow var(--transition-normal), background-color var(--transition-normal); */ /* Combined below */
  position: relative;
  width: calc(50% - 60px); /* Adjusted width for alternating layout */
  /* backdrop-filter:blur(3px); */
  transform-style: preserve-3d; /* Ensure children are positioned in 3D space */
  transition: transform 0.5s cubic-bezier(0.25, 0.8, 0.25, 1), box-shadow 0.5s cubic-bezier(0.25, 0.8, 0.25, 1), background-color var(--transition-normal); /* Combined transitions */
  transform: rotateY(0deg); /* Initial state */
  border: 1px solid var(--color-cat);
}

/* Left-side items (odd) - align card to the right of the item */
.timeline-item.odd .timeline-card {
  margin-right: 30px;
  margin-left: auto;
  perspective-origin: center;
}

/* Right-side items (even) - align card to the left of the item */
.timeline-item.even .timeline-card {
  margin-left: 30px;
  margin-right: auto;
  perspective-origin: center;
}

/* Specific hover effects for odd and even items */
.timeline-item.odd .timeline-card:hover {
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
  background-color: var(--color-surface);
}

.timeline-item.even .timeline-card:hover {
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.2);
  background-color: var(--color-surface);
}
@media (min-width: 768px) {
  .timeline-item.odd .timeline-card:hover {
    transform: rotateY(-5deg) scale(1.02); /* Tilt right */
  }

  .timeline-item.even .timeline-card:hover {
    transform: rotateY(5deg) scale(1.02); /* Tilt left */
  }
}

.card-ribbon {
  position: absolute;
  top: 0;
  right: 0; /* Default for odd items */
  width: 5px;
  height: 100%;
  background: linear-gradient(to bottom, var(--color-cat), var(--color-cat)); /* Moved color logic here */
}

/* Reposition ribbon for even items */
@media (min-width: 768px) {
  .card-ribbon {
    left: auto;
    right: 0;
  }
  .timeline-item.even .card-ribbon {
    left: 0; /* Reset left for even items */
    right: auto; /* Reset right for even items */
  }
}

/* Remove ribbon color logic from here as it's now in the base .card-ribbon rule */
/* .card-ribbon {
  background: linear-gradient(to bottom, var(--color-cat), var(--color-cat));
} */

.card-body {
  padding: var(--spacing-lg);
}

.card-header {
  margin-bottom: var(--spacing-md);
}

.card-date {
  display: block;
  font-size: 0.75rem;
  color: var(--color-text-tertiary);
  font-weight: 600;
  margin-bottom: var(--spacing-xxs);
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.card-title {
  font-size: 1.4rem;
  color: var(--color-text-primary);
}

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

.card-text {
  font-size: 0.95rem;
  color: var(--color-text-secondary);
  line-height: 1.6;
}

.card-text strong,
.card-text b {
  color: var(--color-text-primary);
  font-weight: 600;
}

.card-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-top: var(--spacing-lg);
  padding-top: var(--spacing-md);
  border-top: 1px solid var(--color-surface-variant);
  position: relative; /* Added for absolute positioning of expanded source */
}

.category-tag {
  font-size: 0.75rem;
  font-weight: 500;
  padding: var(--spacing-xxs) var(--spacing-xs);
  border-radius: var(--radius-sm);
}

.timeline-item[data-category="conservation"] .category-tag {
  background-color: rgba(58, 183, 149, 0.1);
  color: var(--color-conservation);
}

.timeline-item[data-category="development"] .category-tag {
  background-color: rgba(238, 108, 77, 0.1);
  color: var(--color-development);
}

.card-source {
  width: auto; /* Allow width to adjust to content */
  padding: var(--spacing-xs) var(--spacing-md); /* Adjust padding */
  height: 32px;
  display: inline-flex; /* Use inline-flex for alignment */
  align-items: center;
  justify-content: center;
  gap: var(--spacing-xs); /* Add gap between icon and text */
  border-radius: var(--radius-full);
  border: 1px solid var(--color-surface-variant);
  color: var(--color-text-tertiary);
  transition: all var(--transition-normal);
  text-decoration: none;
  position: relative;
  overflow: hidden;
  background-color: var(--color-surface);
  z-index: 5;
  font-size: 0.8rem; /* Adjust font size if needed */
  font-weight: 500;
  margin-bottom: -5px;

}

.card-source .source-text {
    /* Styles for the text if needed, e.g., margin */
    line-height: 1; /* Ensure text aligns well vertically */
}

.card-source:hover {
  /* width: auto; */ /* Ensure width remains auto on hover */
  padding: var(--spacing-xs) var(--spacing-md); /* Keep padding consistent */
  border-radius: var(--radius-full);
  background-color: var(--color-primary);
  color: white;
  border-color: var(--color-primary);
  transform: translateY(-3px);
  box-shadow: var(--shadow-md);
  text-decoration: none;
}

.card-source i {
  font-size: 0.85rem;
  transition: transform var(--transition-normal);
  flex-shrink: 0; /* Prevent icon from shrinking */
  font-size: 0.85rem;
  transition: transform var(--transition-normal);
  flex-shrink: 0; /* Prevent icon from shrinking */
  margin-right: -0.43rem;
  margin-top: 0.1875rem;
}

/* Loading State */
.timeline-loading {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: var(--spacing-3xl) 0;
  color: var(--color-text-tertiary);
}

.loading-circle {
  width: 50px;
  height: 50px;
  margin-bottom: var(--spacing-md);
}

.loading-circle circle {
  stroke: var(--color-primary);
  stroke-dasharray: 126;
  stroke-dashoffset: 0;
  transform-origin: center;
  animation: loadingCircle 1.5s linear infinite;
}

@keyframes loadingCircle {
  0% { stroke-dashoffset: 126; }
  100% { stroke-dashoffset: 0; }
}

/* Timeline error message */
.timeline-error {
  text-align: center;
  padding: var(--spacing-2xl);
  background-color: var(--color-surface);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow-md);
}

.timeline-error h3 {
  color: var(--color-secondary);
  margin-bottom: var(--spacing-md);
}


/* Custom Classes Support */
/* Examples of custom classes that can be used in the JSON */
.timeline-item.highlight-event .marker-point {
  width: calc(var(--timeline-dot-size) * 1.5);
  height: calc(var(--timeline-dot-size) * 1.5);
  border: 2px solid var(--color-accent);
  box-shadow: 0 0 0 4px rgba(255, 194, 60, 0.25);
}

.timeline-item.important .marker-date {
  color: var(--color-secondary);
  font-weight: bold;
}

.highlight-event .timeline-card {
  border: 4px solid var(--color-accent);
  box-shadow: 0 5px 15px rgba(255, 194, 60, 0.15), var(--shadow-md);
  background: linear-gradient(to bottom right, rgba(255, 194, 60, 0.1), rgba(255, 194, 60, 0.05));
}

.highlight-event .timeline-card .card-header {
  background-color: rgba(255, 194, 60, 0.1);
  margin: calc(var(--spacing-md) * -1);
  margin-bottom: var(--spacing-md);
  padding: var(--spacing-md);
  border-bottom: 1px dashed rgba(255, 194, 60, 0.3);
}

/* Responsive Adjustments */
@media (max-width: 768px) {
  .timeline::before {
    left: 0;
    transform: none;
  }

  .timeline-marker {
    left: 0;
  }

  .timeline-item {
    flex-direction: row !important;
    justify-content: flex-start;
  }

  .timeline-card {
    width: calc(100% - 16px);
  }

  /* Reset margins for mobile */
  .timeline-item.odd .timeline-card,
  .timeline-item.even .timeline-card {
    margin-left: 16px;
    margin-right: 16px;
  }
}

@media (max-width: 480px) {
  .page-header {
    padding: var(--spacing-xl) 0;
  }

  .category-btn, .sort-btn { /* Apply snap to sort button too */
    scroll-snap-align: start;
    flex-shrink: 0;
  }

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

/* Simple Site Footer */


#contact-section {
    position: relative;
    overflow: hidden;
    z-index: 0;
    color: white;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    /* clip-path: polygon(0 50px, 100% 0, 100% 100%, 0 100%); */
    padding:  15rem 2rem 4rem 2rem;
    background: linear-gradient(180deg, rgba(0, 0, 0, 0) 0%, rgb(24 35 95 / 84%) 64%);
    margin-top: -15rem;
}

.contact-content {
    display: flex;
    width: 100%;
    max-width: 1200px;
    flex-direction: row;
    align-items: center;
    justify-content: space-between;
    gap: 4rem;
    position: relative;
}

.contact-subtitle {
    font-size: clamp(1.5rem, 4vw, 2.2rem);
    font-weight: 600;
    line-height: 1.4;
    margin: 0;
    max-width: 600px;
    position: relative;
    text-align: left;
    text-transform: initial;
    padding-left: 25px; /* Add left padding to make space for the vertical line */
}

.contact-subtitle::after {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 3px; /* Make the line thin */
    height: 80%; /* Make the line 80% of the text height */
    background: var(--rwb-gradient); /* Keep the red-white-blue gradient */
    border-radius: 1.5px;
}

.contact-link {
    display: inline-block;
    margin-top: 1.5rem;
    color: var(--text);
    text-decoration: none;
    font-weight: 600;
    font-size: 1.1rem;
    padding: 0.5rem 1.5rem;
    border-radius: 25px;
    background: rgba(255, 255, 255, 0.1);
    border: 1px solid rgba(255, 255, 255, 0.2);
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.contact-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: all 0.5s ease;
}

.contact-link:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.2);
}

.contact-link:hover::before {
    left: 100%;
}

/* Adjust mobile styles */
@media (max-width: 768px) {
    .contact-subtitle {
        text-align: center;
        padding-left: 0; /* Remove left padding on mobile */
        padding-top: 25px; /* Add top padding for the horizontal line on mobile */
    }

    .contact-subtitle::after {
        left: 50%;
        top: 0;
        transform: translateX(-50%);
        width: 120px; /* Make the line wider on mobile */
        height: 3px; /* Make the line thin on mobile */
        background: linear-gradient(90deg, #dc5656 33.3%, #ffffff 33.3%, #ffffff 66.6%, #50aa4d 66.6%);; /* Keep the red-white-blue gradient */

    }
    .contact-content {
        flex-direction: column;
        text-align: center;
        gap: 3rem;
    }
}

.logo-wrapper {
    width: 200px;
    height: auto;
    position: relative;
    transition: transform 0.3s ease;
}

.logo-wrapper:hover {
    transform: translateY(-5px);
}

.logo-wrapper::before {
    content: '';
    position: absolute;
    bottom: -15px;
    left: 50%;
    transform: translateX(-50%);
    width: 30px;
    height: 3px;
    background: var(--primary);
    border-radius: 1.5px;
    opacity: 0;
    transition: opacity 0.3s ease, width 0.3s ease;
}

.logo-wrapper:hover::before {
    opacity: 1;
    width: 60px;
}

#logo {
    transition: filter 0.3s ease;
}

#logo:hover {
    filter: drop-shadow(0 0 15px rgba(255, 255, 255, 0.8));
}

#logo img {
    max-width: 100%;
    height: auto;
}

/* Define the keyframes for the scroll animation */
@keyframes header-text-scroll {
  from {
    opacity: 1;
    filter:blur(0px);
    transform: scale(1);
  }
  to {
    opacity: 0;
    filter:blur(10px);
    transform: scale(2);
  }
}