/* Base Styles - for index page */
:root {
  --color-terracotta: #e07a5f;
  --color-terracotta-dark: #c45d41;
  --color-terracotta-light: #ff8a70;
  --color-green: #57cc99;
  --color-green-light: #80ed99;
  --color-green-dark: #38a169;
  --color-yellow: #f9c846;
  --color-yellow-light: #ffe066;
  --color-dark: #403d39;
  --color-light: #fff1e6;
  --color-gray: #a7b39a;

  /* Spacing variables */
  --spacing-sm: 0.5rem;
  --spacing-md: 1rem;
  --spacing-lg: 2rem;
  --spacing-xl: 4rem;

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

body {
  font-family: "Poppins", sans-serif;
  margin: 0;
  padding: 0;
  color: var(--color-dark);
  background-color: var(--color-light);
}

.site-logo {
  height: 90px;
  width: auto;
  transition: transform 0.3s ease;
}

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

/* Enhance focus styles for better accessibility */
:focus {
  outline: 3px solid var(--color-terracotta);
  outline-offset: 2px;
}

/* Skip to content - enhance visibility when focused */
.sr-only:focus,
.sr-only:active {
  display: block;
  width: auto;
  height: auto;
  padding: 15px;
  background-color: var(--color-terracotta);
  color: white;
  font-weight: bold;
  z-index: 9999;
  border-radius: 0 0 4px 0;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
}

/* Language Switcher */
.active-lang {
  color: var(--color-terracotta);
  font-weight: 600;
}

/* Hero Section */
.hero-section {
  background-color: #403d39; /* Fallback color while image loads */
  color: white;
  position: relative;
  overflow: hidden;
}

/* Picture element support */
.hero-section picture {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hero-section picture img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

/* Add will-change to improve GPU rendering */
.hero-section,
[data-bg*="waterproject"] {
  will-change: background-image;
}

.hero-section:before {
  content: "";
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 10px;
  background: linear-gradient(
    90deg,
    var(--color-yellow) 33%,
    var(--color-green) 33%,
    var(--color-green) 66%,
    var(--color-terracotta) 66%
  );
  z-index: 1;
}

/* Buttons */
.btn-primary {
  background-color: var(--color-terracotta);
  color: white;
  padding: 0.75rem 2rem;
  border-radius: var(--radius-full);
  font-weight: 600;
  display: inline-block;
  transition: all 0.3s ease;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
  border: 2px solid var(--color-terracotta);
}

.btn-primary:hover {
  background-color: var(--color-terracotta-light);
  border-color: var(--color-terracotta-light);
  transform: translateY(-3px);
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.15);
}

.btn-secondary {
  background-color: var(--color-green);
  color: white;
  padding: 0.75rem 2rem;
  border-radius: var(--radius-full);
  font-weight: 600;
  display: inline-block;
  transition: all 0.3s ease;
  box-shadow: 0 4px 10px rgba(0, 0, 0, 0.1);
  border: 2px solid var(--color-green);
}

.btn-secondary:hover {
  background-color: var(--color-green-light);
  border-color: var(--color-green-light);
  transform: translateY(-3px);
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.15);
}

/* Statistics Cards */
.stat-card {
  background-color: white;
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
  border-top: 5px solid;
  border-image: linear-gradient(
      to right,
      var(--color-terracotta),
      var(--color-yellow)
    )
    1;
}

.stat-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.1);
}

.stat-number {
  font-size: 2.75rem;
  font-weight: 800;
  color: var(--color-terracotta);
  margin-bottom: 0.5rem;
}

.stat-label {
  color: var(--color-green);
  font-weight: 600;
  font-size: 1.1rem;
}

/* Story Cards */
.story-card {
  background-color: white;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
  transition: all 0.3s ease;
  border-bottom: 5px solid;
  border-image: linear-gradient(
      to right,
      var(--color-green),
      var(--color-yellow)
    )
    1;
}

.story-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.15);
}

/* Team Cards */
.team-card {
  background-color: white;
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
  height: 100%;
  border-top: 4px solid;
  border-image: linear-gradient(
      to right,
      var(--color-terracotta),
      var(--color-yellow)
    )
    1;
}

.team-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.1);
}

/* Contact Cards */
.contact-card {
  background-color: white;
  border-radius: var(--radius-lg);
  padding: 2rem;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
  height: 100%;
}

.contact-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.1);
}

.object-center-top {
  object-position: center 30%;
}

/* Video player styles */
.play-btn {
  transition: all 0.3s ease;
}

.play-btn:hover {
  transform: scale(1.1);
  background-color: var(--color-terracotta-light);
}

/* Cookie Banner */
.cookie-banner {
  box-shadow: 0 -5px 15px rgba(0, 0, 0, 0.1);
}

/* Pattern Accent */
.pattern-accent {
  background-image: url("data:image/svg+xml,%3Csvg width='60' height='60' viewBox='0 0 60 60' xmlns='http://www.w3.org/2000/svg'%3E%3Cg fill='none' fill-rule='evenodd'%3E%3Cg fill='%23e07a5f' fill-opacity='0.15'%3E%3Cpath d='M36 34v-4h-2v4h-4v2h4v4h2v-4h4v-2h-4zm0-30V0h-2v4h-4v2h4v4h2V6h4V4h-4zM6 34v-4H4v4H0v2h4v4h2v-4h4v-2H6zM6 4V0H4v4H0v2h4v4h2V6h4V4H6z'/%3E%3C/g%3E%3C/g%3E%3C/svg%3E");
}

/* Navigation underline effect */
.nav-link {
  position: relative;
  transition: color 0.3s ease;
}

.nav-link:hover {
  transform: translateY(-2px);
}

.nav-link:hover .nav-indicator {
  width: 100%;
}

.nav-indicator {
  position: absolute;
  left: 0;
  bottom: 0;
  width: 0;
  height: 1px;
  background-color: var(--color-terracotta);
  transition: width 0.3s ease;
}

/* Improve focus indicators for interactive elements */
a:focus,
button:focus,
input:focus,
textarea:focus,
select:focus {
  outline: 3px solid var(--color-terracotta);
  outline-offset: 2px;
}

/* Improve text contrast for accessibility */
.text-gray-300 {
  color: #d1d5db;
}

.text-gray-500 {
  color: #6b7280;
}

/* Timeline styles - CORRECTED MOBILE VERSION */
.timeline-container {
  position: relative;
}

/* Desktop timeline - center line */
.timeline-container::after {
  content: "";
  position: absolute;
  width: 4px;
  background-color: var(--color-terracotta);
  top: 0;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
}

.timeline-item {
  position: relative;
  width: 50%;
  padding: 10px 40px;
  margin-bottom: 20px;
}

.timeline-item::after {
  content: "";
  position: absolute;
  width: 24px;
  height: 24px;
  background-color: #fff;
  border: 4px solid var(--color-terracotta);
  border-radius: 50%;
  top: 16px;
  z-index: 1;
}

.timeline-left {
  left: 0;
}

.timeline-right {
  left: 50%;
}

.timeline-left::after {
  right: -12px;
}

.timeline-right::after {
  left: -12px;
}

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

/* Desktop timeline - center line */
.timeline-container::after {
  content: "";
  position: absolute;
  width: 4px;
  background-color: var(--color-terracotta);
  top: 0;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
}

.timeline-item {
  position: relative;
  width: 50%;
  padding: 10px 40px;
  margin-bottom: 20px;
}

.timeline-item::after {
  content: "";
  position: absolute;
  width: 24px;
  height: 24px;
  background-color: #fff;
  border: 4px solid var(--color-terracotta);
  border-radius: 50%;
  top: 16px;
  z-index: 1;
}

.timeline-left {
  left: 0;
}

.timeline-right {
  left: 50%;
}

.timeline-left::after {
  right: -12px;
}

.timeline-right::after {
  left: -12px;
}

/* MOBILE TIMELINE  */
@media (max-width: 768px) {
  /* Position timeline line to the left of content blocks */
  .timeline-container::after {
    left: 15px !important;
    transform: none !important;
  }

  /* Make all timeline items full width with left margin for the line */
  .timeline-item {
    width: 100% !important;
    padding-left: 40px !important;
    padding-right: 15px !important;
    left: 0 !important;
    margin-bottom: 25px !important;
  }

  /* Position dots on the timeline line, outside the content blocks */
  .timeline-item::after {
    left: 3px !important;
    right: auto !important;
    width: 20px !important;
    height: 20px !important;
    border-width: 3px !important;
  }

  /* Override any right positioning */
  .timeline-right {
    left: 0 !important;
  }

  /* Make timeline cards more mobile-friendly */
  .timeline-item > div {
    padding: 1rem !important;
    border-radius: 8px !important;
    margin-left: 0 !important;
  }

  /* Adjust timeline item content for mobile */
  .timeline-item h3 {
    font-size: 1rem !important;
    margin-bottom: 0.5rem !important;
    line-height: 1.3 !important;
  }

  .timeline-item p {
    font-size: 0.875rem !important;
    line-height: 1.4 !important;
    margin-bottom: 0.5rem !important;
  }

  /* Date styling */
  .timeline-item .text-gray-500 {
    font-size: 0.75rem !important;
    margin-top: 0.5rem !important;
  }
}

/* Extra small screens - even tighter positioning */
@media (max-width: 480px) {
  .timeline-container::after {
    left: 15px !important;
  }

  .timeline-item {
    padding-left: 40px !important;
    padding-right: 10px !important;
  }

  .timeline-item::after {
    left: 3px !important;
    width: 18px !important;
    height: 18px !important;
  }

  .timeline-item > div {
    padding: 0.75rem !important;
  }
}

/* Carousel Styling */
.carousel {
  position: relative;
  overflow: hidden;
  border-radius: var(--radius-lg);
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.08);
}

.carousel-inner {
  display: flex;
  transition: transform 0.5s ease;
}

.carousel-item {
  min-width: 100%;
}

.carousel-control {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 10;
  width: 40px;
  height: 40px;
  background-color: rgba(224, 122, 95, 0.8);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
}

.carousel-control:hover {
  background-color: var(--color-terracotta);
}

.carousel-control-prev {
  left: 20px;
}

.carousel-control-next {
  right: 20px;
}

.carousel-indicators {
  position: absolute;
  bottom: 20px;
  left: 0;
  right: 0;
  display: flex;
  justify-content: center;
  gap: 8px;
  z-index: 10;
}

.carousel-indicator {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background-color: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: all 0.3s ease;
}

.carousel-indicator.active {
  background-color: #fff;
  transform: scale(1.2);
}

/* Content Cards */
.content-card {
  background-color: white;
  border-radius: var(--radius-lg);
  overflow: hidden;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.05);
  transition: all 0.3s ease;
  height: 100%;
  position: relative;
}

.content-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 30px rgba(0, 0, 0, 0.1);
}

.card-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.1),
    rgba(0, 0, 0, 0.7)
  );
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  padding: 1.5rem;
  transition: background 0.3s ease;
}

.content-card:hover .card-overlay {
  background: linear-gradient(
    to bottom,
    rgba(0, 0, 0, 0.2),
    rgba(0, 0, 0, 0.8)
  );
}

/* Content toggle for read more/less */
.content-toggle {
  overflow: hidden;
  max-height: 200px;
  transition: max-height 0.5s ease;
}

.content-toggle.expanded {
  max-height: 1000px;
}

/* Page-specific overrides */

/* Hero Section for watwedoen page */
.watwedoen .hero-section {
  background-image:
    linear-gradient(to bottom, rgba(64, 61, 57, 0.5), rgba(224, 122, 95, 0.4)),
    url("/img/Kangai.webp");
}

/* Hero Section for team/wiewijzijn page */
.wiewijzijn .hero-section,
.contact .hero-section,
.projecten .hero-section {
  background-image:
    linear-gradient(to bottom, rgba(64, 61, 57, 0.5), rgba(224, 122, 95, 0.4)),
    url("/img/team-banner.webp");
}

/* Modal styles */
.modal {
  display: none;
  position: fixed;
  z-index: 100;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0, 0, 0, 0.7);
  opacity: 0;
  transition: opacity 0.3s ease;
}

.modal.show {
  opacity: 1;
}

.modal-content {
  background-color: #fff;
  margin: 5% auto;
  padding: 20px;
  border: 1px solid #888;
  width: 80%;
  max-width: 800px;
  border-radius: var(--radius-lg);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
  transform: translateY(-20px);
  transition: transform 0.3s ease;
  position: relative;
  max-height: 90vh;
  overflow-y: auto;
}

.modal.show .modal-content {
  transform: translateY(0);
}

.close-modal {
  position: absolute;
  right: 20px;
  top: 15px;
  font-size: 28px;
  font-weight: bold;
  color: #aaa;
  transition: color 0.3s ease;
}

.close-modal:hover {
  color: var(--color-terracotta);
  text-decoration: none;
  cursor: pointer;
}

/* Project Cards */
.project-card {
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
}

.project-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

/* No scrollbar for carousel */
.no-scrollbar {
  -ms-overflow-style: none;
  scrollbar-width: none;
}

.no-scrollbar::-webkit-scrollbar {
  display: none;
}

/* Info Cards */
.info-card {
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
}

.info-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 15px 30px rgba(0, 0, 0, 0.1);
}

/* Water Project Page Specific Styles */

/* Hero Section for Water Project page */
.water-project .hero-section {
  background-image:
    linear-gradient(to bottom, rgba(64, 61, 57, 0.5), rgba(224, 122, 95, 0.4)),
    url("/img/hero-image.webp");
}

/* Impact Visualization */
.progress-bar {
  width: 65%;
  transition: width 1.5s ease-in-out;
}

/* Step Cards */
.step-card {
  transition:
    transform 0.3s ease,
    box-shadow 0.3s ease;
}

.step-card:hover {
  transform: scale(1.05);
}

/* Number indicators */
.step-number {
  width: 48px;
  height: 48px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  font-weight: bold;
  border-radius: 50%;
  margin: 0 auto 16px;
}

/* Quote Section */
.quote-section {
  position: relative;
}

.quote-section .quote-mark {
  position: absolute;
  top: 0;
  left: 0;
  transform: translate(-25%, -25%);
  opacity: 0.2;
}

/* Nasarian PAGE */

/* Hero Section for Naserian page */
.naserian-story .hero-section {
  background-image:
    linear-gradient(to bottom, rgba(64, 61, 57, 0.5), rgba(224, 122, 95, 0.4)),
    url("/img/naserianwinkel.webp");
  background-size: cover;
  background-position: center;
}

/* Neema Page Specific Styles */

/* Hero Section for Neema page */
.neema-story .hero-section {
  background-image:
    linear-gradient(to bottom, rgba(64, 61, 57, 0.5), rgba(224, 122, 95, 0.4)),
    url("/img/naserianwinkel.webp");
}

/* Read More Button Styles */
.read-more-btn {
  transition: color 0.2s ease;
  display: inline-flex;
  align-items: center;
}

.read-more-btn svg {
  transition: transform 0.2s ease;
}

.read-more-btn:hover svg {
  transform: translateX(3px);
}

/* Team Modal Specific Styles */
#amy-modal .modal-content,
#roxane-modal .modal-content,
#hannah-modal .modal-content,
#julia-modal .modal-content,
#kangai-modal .modal-content {
  padding: 2rem;
}

/* Base styles */
.container {
  width: 100%;
}

/* Small devices */
@media (min-width: 576px) {
  .container {
    max-width: 540px;
  }
}

/* Medium devices */
@media (min-width: 768px) {
  .container {
    max-width: 720px;
  }
}

/* Large devices */
@media (min-width: 992px) {
  .container {
    max-width: 960px;
  }
}

/* Extra large devices */
@media (min-width: 1200px) {
  .container {
    max-width: 1140px;
  }
}

/* Mobile optimizations */
@media (max-width: 768px) {
  .nav-link,
  button,
  .btn-primary,
  .btn-secondary {
    padding: 0.75rem 1rem;
    min-height: 44px;
    min-width: 44px;
  }

  .story-card,
  .team-card,
  .stat-card {
    padding: 1.5rem;
    margin-bottom: 1rem;
  }

  h1 {
    font-size: 2rem !important;
  }

  h2 {
    font-size: 1.75rem !important;
  }
}

/* Improve readability on small screens */
@media (max-width: 480px) {
  body {
    font-size: 16px;
  }

  p {
    line-height: 1.6;
  }
}

/* Print styles */
@media print {
  header,
  footer,
  nav,
  .hero-section:before,
  .cookie-banner {
    display: none;
  }

  body {
    background-color: white;
    color: black;
  }

  a {
    text-decoration: none;
    color: black;
  }

  .container {
    width: 100%;
    max-width: 100%;
  }

  .btn-primary,
  .btn-secondary {
    border: 1px solid #999;
    background: none !important;
    color: #333 !important;
  }
}

/* Fix the Ashe Foundation logo in footer */
footer a img[alt="ASHE Foundation Logo"],
footer .inline-block img {
  height: auto;
  width: 150px;
  max-width: 100%;
  object-fit: contain;
  padding: 4px;
  background-color: transparent;
  border-radius: 4px;
}

/* Fix the ANBI logo display in footer */
footer .anbi-logo img,
footer a img[alt*="anbi"],
footer a img[alt*="ANBI"],
footer img[title="ANBI"] {
  height: auto;
  max-height: 65px;
  width: auto;
  max-width: 100%;
  object-fit: contain;
  padding: 3px;
  background-color: white;
  border-radius: 4px;
}

/* Add support for reduced motion */
@media (prefers-reduced-motion: reduce) {
  * {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}

/* Utility classes */
.text-shadow {
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.2);
}

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

/* Optimize images with object-fit */
img {
  max-width: 100%;
  height: auto;
  object-fit: cover;
}

/* Fix cross-browser issues */
input,
button,
textarea,
select {
  font-family: inherit;
  font-size: inherit;
}

/* Homepage-specific hero with Maasai image */
.home-hero-section {
  background-image:
    linear-gradient(to bottom, rgba(0, 0, 0, 0.4), rgba(224, 122, 95, 0.3)),
    url("/img/maasai-water-view.webp");
  background-size: cover;
  background-position: center;
  color: white;
  position: relative;
}

/* Ensure graph modal appears above everything else including the navbar */
#graph-modal {
  z-index: 1000 !important;
}

/* EMERGENCY FIXES - VERY SPECIFIC SELECTORS */

/* PROJECT PAGE - FORCE ORANGE ARROWS ONLY, NO DOTS */
/* Hide ALL dot indicators on project pages */
.projecten .carousel-indicators,
.projecten .carousel-indicators button,
.projecten .carousel-indicator,
body.projecten .carousel-indicators,
.projecten [class*="indicator"],
.projecten .bg-orange-500,
.projecten .bg-rose-600 {
  display: none !important;
  visibility: hidden !important;
  opacity: 0 !important;
}

/* Force orange arrows to show on project pages - ALL SCREEN SIZES */
.projecten .carousel-control,
.projecten .carousel-control-prev,
.projecten .carousel-control-next,
body.projecten .carousel-control {
  display: flex !important;
  visibility: visible !important;
  background-color: #e07a5f !important;
  width: 40px !important;
  height: 40px !important;
  border-radius: 50% !important;
  position: absolute !important;
  top: 50% !important;
  transform: translateY(-50%) !important;
  z-index: 50 !important;
  border: none !important;
  cursor: pointer !important;
  color: white !important;
}

.projecten .carousel-control:hover {
  background-color: #ff8a70 !important;
}

/* Make sure arrows are positioned correctly */
.projecten .carousel-control-prev {
  left: 1rem !important;
}

.projecten .carousel-control-next {
  right: 1rem !important;
}

/* RESET TEAM PAGE - REMOVE PROBLEMATIC OVERRIDES */
@media (min-width: 1025px) {
  /* Simple grid setup - let the existing HTML structure work */
  .wiewijzijn .grid,
  #team-carousel .grid {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 1.5rem !important;
  }

  /* Basic team card styling */
  .wiewijzijn .team-card,
  #team-carousel .team-card {
    height: auto !important;
    width: 100% !important;
  }

  /* Reset carousel structure */
  .wiewijzijn .carousel-item,
  #team-carousel .carousel-item {
    width: 100% !important;
  }
}
/* Base styles for carousel indicators */
.carousel-indicators {
  display: flex;
  justify-content: center;
  align-items: center;
  margin: 0;
  padding: 0;
  z-index: 20;
}

/* Style for individual indicators */
.carousel-indicators button,
.carousel-indicator {
  width: 8px !important;
  height: 8px !important;
  margin: 0 5px !important;
  opacity: 0.9;
  background-color: #ffffff !important;
  box-shadow: 0 0 3px rgba(0, 0, 0, 0.5);
  border: none !important;
  padding: 0 !important;
  border-radius: 50%;
}

/* Active indicator styling */
.carousel-indicators .active,
.carousel-indicators .bg-rose-600,
.carousel-indicator.active,
.carousel-indicator.bg-rose-600 {
  transform: scale(1.2) !important;
  background-color: #ffffff !important;
  opacity: 1;
}

/* Ensure buttons have higher z-index */
.project-card a,
.project-card button {
  position: relative !important;
  z-index: 25 !important;
}

/* PROJECT PAGE SPECIFIC STYLES */
/* Hide dots on project page desktop - use arrows instead */
.projecten .carousel-indicators {
  display: none !important;
}

/* Show orange arrows on project page for all screen sizes */
.projecten .carousel-control {
  display: flex !important;
  width: 40px !important;
  height: 40px !important;
  background-color: #e07a5f !important;
  border-radius: 50% !important;
  position: absolute !important;
  top: 50% !important;
  transform: translateY(-50%) !important;
  z-index: 30 !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3) !important;
}

.projecten .carousel-control:hover {
  background-color: #ff8a70 !important;
}

/* Device-specific positioning for OTHER pages (not projects) */
@media (max-width: 768px) {
  /* Hide dot indicators on mobile for all carousels except team */
  .carousel-indicators:not(.team-indicators) {
    display: none !important;
  }
}

@media (min-width: 769px) {
  /* Desktop indicators positioning for non-project pages */
  .carousel-indicators:not(.team-indicators) {
    position: static !important;
    margin-top: 8px !important;
    margin-bottom: 16px !important;
    display: flex !important;
  }

  .carousel-indicators button,
  .carousel-indicator {
    width: 10px !important;
    height: 10px !important;
    margin: 0 6px !important;
  }

  /* But still hide on project pages */
  .projecten .carousel-indicators {
    display: none !important;
  }
}

/* TEAM CAROUSEL - ORANGE THEMED */
/* Team carousel mobile container */
.carousel-inner-mobile {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.carousel-inner-mobile::-webkit-scrollbar {
  display: none;
}

/* Mobile carousel slides */
.carousel-inner-mobile > div {
  flex-shrink: 0;
  width: 100%;
  scroll-snap-align: center;
  padding: 0 1rem;
}

/* Team arrow buttons - orange theme */
.carousel-control {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 30;
  width: 40px;
  height: 40px;
  background-color: #e07a5f;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all 0.3s ease;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.2);
  border: none;
}

.carousel-control:hover {
  background-color: #ff8a70;
  transform: translateY(-50%) scale(1.1);
}

.carousel-control-prev {
  left: 1rem;
}

.carousel-control-next {
  right: 1rem;
}

/* Team carousel indicators - orange theme */
.carousel-indicator {
  width: 8px !important;
  height: 8px !important;
  border-radius: 50%;
  background-color: rgba(224, 122, 95, 0.3) !important;
  transition: all 0.2s ease;
  border: none !important;
  padding: 0 !important;
  cursor: pointer;
  margin: 0 4px !important;
}

.carousel-indicator.active {
  background-color: #e07a5f !important;
  transform: scale(1.2);
}

/* Desktop team carousel styles */
@media (min-width: 1025px) {
  /* Force proper desktop layout for team carousel */
  #team-carousel .carousel-inner:not(.carousel-inner-mobile) {
    display: flex;
    transition: transform 0.5s ease;
  }

  #team-carousel .carousel-inner:not(.carousel-inner-mobile) .carousel-item {
    min-width: 100%;
    flex-shrink: 0;
    display: block;
  }

  /* Force 3-column grid layout for desktop team cards */
  #team-carousel .carousel-item .grid,
  .wiewijzijn .carousel-item .grid {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 1.5rem !important;
    width: 100% !important;
  }

  /* Show desktop indicators for team */
  #team-carousel .carousel-indicators {
    display: flex !important;
    justify-content: center;
    margin-top: 1rem;
  }

  /* Ensure team cards maintain proper size on desktop */
  #team-carousel .team-card,
  .wiewijzijn .team-card {
    padding: 2rem;
    height: auto;
    max-width: none;
    width: 100%;
  }

  /* Fix any flex issues that might stretch cards */
  #team-carousel .carousel-item > div,
  .wiewijzijn .carousel-item > div {
    display: grid !important;
    grid-template-columns: repeat(3, 1fr) !important;
    gap: 1.5rem !important;
  }
}

/* Mobile team carousel styles */
@media (max-width: 1024px) {
  /* Hide desktop indicators on mobile - no bottom dots */
  .carousel-indicator,
  .carousel-indicators {
    display: none !important;
  }

  /* Make arrow buttons more prominent on mobile */
  .carousel-control {
    width: 44px;
    height: 44px;
    z-index: 30;
  }

  /* Adjust team card padding for mobile */
  .team-card {
    padding: 1.5rem 1rem;
    margin: 0 auto;
    max-width: 320px;
  }

  /* Ensure proper spacing */
  #team-carousel {
    padding-bottom: 2rem;
  }
}

/* Remove any small screen hiding of controls - we want them visible */
@media (max-width: 640px) {
  .carousel-control {
    display: flex !important;
    width: 40px;
    height: 40px;
  }
}

/* Team member images - make them consistent */
.team-card img {
  width: 144px;
  height: 144px;
  object-fit: cover;
  margin: 0 auto 1.5rem;
  border-radius: 50%;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

/* Improve team card layout on mobile */
@media (max-width: 768px) {
  .team-card {
    text-align: center;
    min-height: auto;
  }

  .team-card h3 {
    font-size: 1.125rem;
    line-height: 1.4;
    margin-bottom: 0.5rem;
  }

  .team-card p {
    font-size: 0.875rem;
    line-height: 1.5;
  }

  .read-more-btn {
    margin-top: 1rem;
    justify-content: center;
  }
}

/* Fix for volunteer card in mobile view */
@media (max-width: 1024px) {
  .team-card.pattern-accent {
    background-color: var(--color-light);
    padding: 2rem 1rem;
  }

  .team-card.pattern-accent svg {
    margin: 0 auto 1rem;
  }

  .team-card.pattern-accent h3,
  .team-card.pattern-accent p {
    text-align: center;
  }

  .team-card.pattern-accent a {
    margin: 1rem auto 0;
    display: inline-flex;
  }
}

/* Lazy loading styles */
.lazy-background {
  background-color: #403d39;
  transition: background-color 0.3s ease;
}

.lazy-background.loaded {
  background-color: transparent;
}

/* Donate page specific mobile fixes */
@media (max-width: 768px) {
  .bank-details-container {
    word-break: break-all;
    overflow-wrap: break-word;
  }

  .bank-details-container .font-semibold {
    font-size: 0.9rem;
    word-break: break-all;
    line-height: 1.4;
  }

  .bg-light.p-8 {
    padding: 1rem !important;
  }

  .py-3.border-b {
    flex-direction: column;
    align-items: flex-start !important;
    gap: 0.5rem;
  }

  .py-3.border-b .font-medium {
    font-size: 0.9rem;
  }

  .py-3.border-b .font-semibold {
    font-size: 0.85rem;
    color: var(--color-terracotta);
  }
}

/* Additional mobile fixes for donate page */
@media (max-width: 480px) {
  .bank-details-container .text-lg {
    font-size: 1rem !important;
  }

  iframe[name="donorbox"] {
    min-width: 280px !important;
    width: 100% !important;
  }
}

/* Fix payment methods section on mobile */
@media (max-width: 768px) {
  .payment-methods-title {
    font-size: 1rem !important;
  }

  [role="list"] [role="listitem"] {
    padding: 0.75rem 0.5rem !important;
  }

  [role="list"] [role="listitem"] .font-medium {
    font-size: 0.75rem !important;
    line-height: 1.2;
    text-align: center;
    word-break: break-word;
  }

  [role="list"] [role="listitem"] .w-12.h-12 {
    width: 2rem !important;
    height: 2rem !important;
    margin-bottom: 0.25rem !important;
  }

  [role="list"] [role="listitem"] .w-12.h-12 svg {
    width: 1rem !important;
    height: 1rem !important;
  }
}

/* Extra small screens */
@media (max-width: 480px) {
  [role="list"] [role="listitem"] .font-medium {
    font-size: 0.7rem !important;
  }

  .grid.grid-cols-2.gap-4 {
    gap: 0.5rem !important;
  }
}
