/* Author: Vincent Douma - Douma AI Systems */
/* Algemene basis */
html {
  background-color: #0a0f1a;
  height: 100%;
  scroll-behavior: smooth;
}

body {
  margin: 0;
  font-family: Arial, sans-serif;
  /* single responsive background image with a slightly lighter dark gradient overlay */
  background-color: transparent;
  /* Backgrounds are now handled by pseudo-elements for animation */
  color: #fff;
  position: relative; /* For z-index stacking context */
  z-index: 0;
  /* Sticky Footer Setup */
  display: flex;
  flex-direction: column;
  min-height: 100vh;
}

/* Zorg dat alle hoofdelementen de volledige breedte behouden in de flex-container */
body > header,
body > section,
body > .logo-centered,
body > footer {
  width: 100%;
  box-sizing: border-box; /* Voorkomt dat padding de breedte vergroot */
  flex-shrink: 0; /* Voorkomt dat elementen onbedoeld krimpen */
}

body::before, body::after, html::before {
  content: '';
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-repeat: no-repeat;
  background-size: cover;
  background-position: center center;
}

/* Layer 3 (Top): background_cir.jpg */
body::before {
  background-image: linear-gradient(to bottom, rgba(10,15,26,0.65) 0%, rgba(10,15,26,0.9) 65%), url("../images/background_cir.jpg");
  z-index: -2; /* Behind canvas */
  animation: fade-top 60s linear infinite, ken-burns-2 70s linear infinite;
}

/* Layer 2 (Middle): circuit-pattern.jpg */
body::after {
  background-image: linear-gradient(to bottom, rgba(10,15,26,0.65) 0%, rgba(10,15,26,0.9) 65%), url("../images/circuit-pattern.jpg");
  z-index: -3; /* Behind everything */
  animation: fade-middle 60s linear infinite, ken-burns-1 60s linear infinite;
}

/* Layer 1 (Bottom): backgr_c.jpg */
html::before {
  background-image: linear-gradient(to bottom, rgba(10,15,26,0.65) 0%, rgba(10,15,26,0.9) 65%), url("../images/backgr_c.jpg");
  z-index: -4;
  animation: ken-burns-2 80s linear infinite;
}

header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
  position: sticky; /* Maakt de header vast */
  top: 0; /* Plakt hem aan de bovenkant */
  background: rgba(10, 15, 26, 0.4); /* Licht transparant donker */
  backdrop-filter: blur(12px); /* Sterke vervaging van de achtergrond */
  -webkit-backdrop-filter: blur(12px);
  z-index: 1000; /* Zorg dat het boven alles blijft */
  border-bottom: none;
}

header .logo img {
  height: 52px;
  height: 40px;
  margin-right: 12px;
  filter: brightness(1.25) saturate(1.05);
  transition: transform 0.15s ease, filter 0.15s ease;
  cursor: pointer;
}

@media (max-width: 768px) {
  header .logo img {
    height: 44px;
    height: 32px;
  }
}

header nav ul {
  list-style: none;
  display: flex;
  gap: 1rem;
  margin: 0;
  padding: 0;
}

header nav a {
  color: #fff;
  text-decoration: none;
  transition: color 0.3s ease;
}

/* Zorgt dat de navigatie rechts uitlijnt als het logo weg is uit de header */
header nav {
  display: flex;
  justify-content: flex-end;
}

header nav a:hover,
header nav a:focus {
  color: #ffaa00;
  outline: none;
}

header nav a.active {
  border-bottom: 2px solid #ffaa00;
}

/* Hamburger Menu (Desktop: verborgen) */
.hamburger {
  display: none;
  flex-direction: column;
  cursor: pointer;
  gap: 5px;
}

.hamburger span {
  width: 25px;
  height: 3px;
  background-color: #fff;
  transition: all 0.3s ease;
}

/* Hero sectie */
.hero {
  box-sizing: border-box;
  text-align: center;
  padding: 4rem 2rem;
  min-height: 60vh;
  padding-bottom: 4rem;
  background: linear-gradient(135deg, #0a0f1a, #1a2340);
  position: relative;
  z-index: 1;
}

.hero h1 {
  font-size: 2rem;
  margin-bottom: 1rem;
  color: #ffffff;
  text-shadow: 0 6px 18px rgba(0,0,0,0.6);
  opacity: 0;
  will-change: transform, opacity, filter;
  animation: text-entrance-left 1.2s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.hero p {
  max-width: 600px;
  margin: 0 auto 2rem;
  color: rgba(255,255,255,0.92);
  text-shadow: 0 4px 12px rgba(0,0,0,0.5);
  opacity: 0;
  will-change: transform, opacity, filter;
  animation: text-entrance-right 1.2s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

/* Specifieke animatie voor knoppen in de hero sectie */
.hero .cta, .hero .cta-button {
  opacity: 0;
  will-change: transform, opacity, filter;
  animation: text-entrance-left 1.2s cubic-bezier(0.22, 1, 0.36, 1) forwards;
  pointer-events: none; /* Niet klikbaar tijdens vliegen */
  animation: text-entrance-left 1.2s cubic-bezier(0.22, 1, 0.36, 1) forwards, enable-pointer 0.1s 1.2s forwards;
}

/* Zorg dat de outline knop zijn pulse behoudt na binnenkomst */
.hero .cta-button.cta-outline {
  animation: text-entrance-left 1.2s cubic-bezier(0.22, 1, 0.36, 1) forwards, pulse-glow 2.5s infinite ease-in-out 1.2s;
  pointer-events: none;
  animation: text-entrance-left 1.2s cubic-bezier(0.22, 1, 0.36, 1) forwards, pulse-glow 2.5s infinite ease-in-out 1.2s, enable-pointer 0.1s 1.2s forwards;
}

.cta, .cta-button {
  display: inline-block;
  margin: 1rem;
  padding: 0.75rem 1.5rem;
  background: #ffaa00;
  color: #0a0f1a;
  text-decoration: none;
  border-radius: 4px;
  font-weight: bold;
  transition: all 0.3s ease;
  box-sizing: border-box;
}

.cta:hover, .cta-button:hover,
.cta:focus, .cta-button:focus {
  background: #cc8800;
  transform: translateY(-2px);
  transform: translateY(-2px) !important;
  box-shadow: 0 4px 12px rgba(255, 170, 0, 0.4);
  outline: none; /* De box-shadow is de focus indicator */
}

/* Outline variant voor secundaire acties */
.cta-button.cta-outline {
  background: transparent;
  border: 1px solid #ffaa00;
  color: #ffaa00;
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  animation: pulse-glow 2.5s infinite ease-in-out;
}

.cta-button.cta-outline:hover,
.cta-button.cta-outline:focus {
  background: rgba(255, 170, 0, 0.1);
  box-shadow: 0 0 15px rgba(255, 170, 0, 0.3);
  transform: translateY(-2px);
  transform: translateY(-2px) !important;
  outline: none; /* De box-shadow is de focus indicator */
}

/* Flipcards */
.flip-cards {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 2.5rem;
  padding: 2.5rem 2.5rem 4rem 2.5rem; /* extra bottom padding so footer sits lower */
  max-width: 1200px;
  margin: 0 auto;
  align-items: start;
}

/* Specifieke margin voor Home pagina om overlap te regelen */
.home-cards {
  margin-top: -60px;
}

/* Tablet breakpoint: 2 columns */
@media (max-width: 1024px) {
  .flip-cards {
    grid-template-columns: repeat(2, 1fr);
  }
}

/* Keyframes voor Flip Card Entrance (vervangt transition voor betere hover-controle) */
@keyframes card-entrance-anim {
  0% {
    opacity: 0;
    transform: translateY(100px);
    filter: blur(5px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
    filter: blur(0);
  }
}

.flip-card {
  perspective: 1000px;
  perspective-origin: 50% 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  /* Scroll-in animatie */
  opacity: 0;
  /* Transition met delay voor het sluiten (eerst draaien, dan zakken) */
  transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) 0.5s;
  will-change: opacity, transform, filter;
  transform-style: preserve-3d;
  cursor: pointer;
}

.flip-card-inner {
  position: relative;
  width: 100%;
  height: 170px;
  transition: transform 0.8s;
  transform-style: preserve-3d;
  transform-origin: 50% 50% 0;
  will-change: transform;
  transform: translateZ(0);
}

.flip-card.visible {
  opacity: 1;
  transform: translateY(0);
  filter: none;
  animation: card-entrance-anim 1s ease-out backwards;
}

/* Lift effect bij hoveren (Alleen Desktop/Muis) */
@media (hover: hover) {
  .flip-card:hover {
    transform: perspective(1000px) translateY(-40px) rotateX(10deg);
    z-index: 10;
    transition-delay: 0s; /* Direct omhoog bij hover */
  }

  .flip-card:hover .flip-card-inner {
    transform: rotateY(180deg);
    transition-delay: 0.5s;
  }
}

/* Active state voor touch/click (Mobiel & Desktop klik) */
.flip-card.active {
  transform: perspective(1000px) translateY(-40px) rotateX(10deg);
  z-index: 10;
  transition-delay: 0s; /* Direct omhoog bij click */
}

.flip-card.active .flip-card-inner {
  transform: rotateY(180deg);
  transition-delay: 0.5s;
}

/* Staggered (één voor één) animatie voor de flip cards */
 .flip-card.visible:nth-child(1) { animation-delay: 0.1s; }
 .flip-card.visible:nth-child(2) { animation-delay: 0.25s; }
 .flip-card.visible:nth-child(3) { animation-delay: 0.4s; }
 .flip-card.visible:nth-child(4) { animation-delay: 0.55s; }
 .flip-card.visible:nth-child(5) { animation-delay: 0.7s; }
 .flip-card.visible:nth-child(6) { animation-delay: 0.85s; }

.flip-card-front, .flip-card-back {
  position: absolute;
  width: 100%;
  height: 100%;
  backface-visibility: hidden;
  -webkit-backface-visibility: hidden;
  box-sizing: border-box;
  border: 1px solid #f5d10780;
  border-radius: 8px;
  padding: 1rem;
  display: flex;
  flex-direction: column;
  justify-content: center; /* Centreer de content verticaal */
  align-items: center;
}

.flip-card-front svg {
  stroke: #ffaa00;
}

.flip-card-front {
  background: #111a33;
}

.flip-card-back {
  background: #1a2340;
  transform: rotateY(180deg);
}

/* Modules grid */
.modules-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 2rem;
  padding: 2rem;
  text-align: center;
}

.modules-grid .module {
  display: flex;
  flex-direction: column;
  justify-content: flex-start; /* Forceert iconen naar de bovenkant */
  align-items: center;
  height: 100%; /* Zorgt dat de module de hele hoogte vult */
  /* Scroll-in animatie voor de modules */
  opacity: 0;
  transform: translateY(50px);
  filter: blur(5px);
  will-change: opacity, transform, filter;
  transition: opacity 0.8s ease-out, transform 0.8s ease-out, filter 0.8s ease-out;
}

.modules-grid .module img {
  height: 64px;
  margin-bottom: 1rem;
}

.modules-grid .module.visible {
  opacity: 1;
  transform: translateY(0);
  filter: blur(0);
}

/* Staggered (één voor één) animatie voor de modules */
.modules-grid .module.visible:nth-child(1) { transition-delay: 0.1s; }
.modules-grid .module.visible:nth-child(2) { transition-delay: 0.3s; }
.modules-grid .module.visible:nth-child(3) { transition-delay: 0.5s; }
.modules-grid .module.visible:nth-child(4) { transition-delay: 0.7s; }

/* === Icon Animaties (Diensten) === */

/* 1. Intake: Spraakwolkje heen en weer */
@keyframes bubble-conversation {
  0% { transform: translate(0, 0); opacity: 0; }
  5% { transform: translate(0, 0); opacity: 1; }
  20% { transform: translate(0, 0); opacity: 1; }
  25% { transform: translate(0, 0); opacity: 0; }
  /* Lange pauze tussen wisselen (20%) */
  45% { transform: translate(0, 0) scaleX(-1); opacity: 0; }
  50% { transform: translate(0, 0) scaleX(-1); opacity: 1; }
  80% { transform: translate(0, 0) scaleX(-1); opacity: 1; }
  85% { transform: translate(0, 0) scaleX(-1); opacity: 0; }
  /* Lange pauze aan het einde (15%) */
  100% { transform: translate(0, 0) scaleX(-1); opacity: 0; }
}

.anim-bubble {
  transform-box: fill-box;
  transform-origin: center;
  opacity: 0; /* Start onzichtbaar */
}

/* Class voor actieve animatie (aangestuurd door JS) */
.anim-bubble.active {
  animation: bubble-conversation 6s ease-in-out;
}

/* 2. Analyse: Vergrootglas draaien */
@keyframes search-scan {
  0% { transform: translate(0, -3px); }
  12.5% { transform: translate(4px, -2px); }
  25% { transform: translate(6px, 0); }
  37.5% { transform: translate(4px, 2px); }
  50% { transform: translate(0, 3px); }
  62.5% { transform: translate(-4px, 2px); }
  75% { transform: translate(-6px, 0); }
  87.5% { transform: translate(-4px, -2px); }
  100% { transform: translate(0, -3px); }
}

.anim-search {
  animation: search-scan 5s linear infinite;
}

/* 3. Ontwerp: Lijnen bewegen */
@keyframes line-shift-h {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(4px); }
}
@keyframes line-shift-v {
  0%, 100% { transform: translateX(0); }
  50% { transform: translateX(4px); }
}

.anim-line-h { animation: line-shift-h 3s ease-in-out infinite; }
.anim-line-v { animation: line-shift-v 3s ease-in-out infinite; }

/* 4. Implementatie: Tandwielen draaien */
@keyframes gear-spin-cw {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}
@keyframes gear-spin-ccw {
  from { transform: rotate(0deg); }
  to { transform: rotate(-360deg); }
}

.anim-gear-cw {
  transform-origin: 12px 12px; /* Aangepast draaipunt voor linker tandwiel */
  animation: gear-spin-cw 8s linear infinite;
}
.anim-gear-ccw {
  transform-origin: 28px 12px; /* Aangepast draaipunt voor rechter tandwiel */
  animation: gear-spin-ccw 8s linear infinite;
}

/* === Icon Animaties (Flip Cards Home) === */

/* AVG Shield Animation */
@keyframes shield-flip {
  from { transform: rotateY(0deg); }
  to { transform: rotateY(360deg); }
}
@keyframes shield-content-swap {
  0%, 40% { opacity: 1; }
  41%, 100% { opacity: 0; }
}
@keyframes shield-checkmark-swap {
  0%, 45% { opacity: 0; }
  50%, 90% { opacity: 1; }
  95%, 100% { opacity: 0; }
}

.anim-shield {
  animation: shield-flip 5s linear infinite;
  transform-origin: center;
}
.anim-shield .shield-original {
  animation: shield-content-swap 5s linear infinite;
}
.anim-shield .shield-checkmark {
  opacity: 0; /* Start hidden */
  animation: shield-checkmark-swap 5s linear infinite;
}

@keyframes radar-pulse {
  0%, 100% { transform: scale(1); opacity: 1; }
  50% { transform: scale(0.6); opacity: 0.8; }
}
.anim-radar-pulse {
  transform-origin: center;
  transform-box: fill-box;
  animation: radar-pulse 2s ease-in-out infinite;
}

/* Modular Box Animation (Bounce with Squash) */
@keyframes box-bounce {
  0%, 100% { transform: translateY(-10px) scale(1, 1); animation-timing-function: ease-in; } /* In de lucht */
  45% { transform: translateY(0) scale(1, 1); } /* Raakt grond */
  50% { transform: translateY(0) scale(1.2, 0.8); } /* Impact: Plat en breed (Squash) */
  55% { transform: translateY(0) scale(0.9, 1.1); animation-timing-function: ease-out; } /* Veert op: Lang en smal */
}
.anim-box-bounce {
  animation: box-bounce 1.5s infinite;
  transform-origin: center bottom; /* Vervormen vanaf de onderkant */
  transform-box: fill-box;
}

/* Secure Flow Animation (Pulse + Flatline Alert) */
@keyframes pulse-beat {
  0% { stroke-dashoffset: 50; opacity: 1; }
  15% { stroke-dashoffset: 0; opacity: 1; }
  30% { stroke-dashoffset: -50; opacity: 1; }
  30.1% { stroke-dashoffset: 50; opacity: 1; } /* Reset voor slag 2 */
  45% { stroke-dashoffset: 0; opacity: 1; }
  60% { stroke-dashoffset: -50; opacity: 1; }
  60.1% { opacity: 0; } /* Verberg voor flatline */
  100% { opacity: 0; }
}

@keyframes flatline-sequence {
  0%, 60% { opacity: 0; stroke-dashoffset: 22; stroke: #ffaa00; }
  60.1% { opacity: 1; stroke-dashoffset: 22; stroke: #ffaa00; } /* Start tekenen van links */
  75% { stroke-dashoffset: 0; stroke: #ffaa00; } /* Volledig getekend */
  80% { stroke: #ff4444; } /* Wordt rood en blijft even staan */
  95% { stroke-dashoffset: -22; opacity: 1; } /* Verdwijnt naar rechts */
  100% { opacity: 0; stroke-dashoffset: -22; } /* Volledig verdwenen en gereset */
}

@keyframes exclamation-sequence {
  0%, 79% { opacity: 0; transform: scale(0.5); }
  80% { opacity: 1; transform: scale(1.2); stroke: #ff4444; } /* Pop in sync met rood */
  85% { transform: scale(1); }
  95% { opacity: 1; transform: scale(1); }
  100% { opacity: 0; transform: scale(0.5); }
}

.anim-pulse-normal {
  stroke-dasharray: 50;
  stroke-dashoffset: 50;
  stroke: #ffaa00;
  animation: pulse-beat 8s linear infinite;
}
.anim-flatline-draw {
  stroke-dasharray: 22;
  stroke-dashoffset: 22;
  animation: flatline-sequence 8s linear infinite;
}
.anim-exclamation {
  transform-origin: center;
  animation: exclamation-sequence 8s linear infinite;
}

/* Single Gear Animation */
.anim-single-gear {
  transform-origin: center;
  animation: gear-spin-cw 8s linear infinite;
}

/* Contactformulier */
.contact-section {
  max-width: 1100px;
  margin: 2rem auto;
  padding: 0 2rem;
}

.contact-grid {
  display: grid;
  grid-template-columns: 1fr 1.5fr;
  gap: 2rem;
}

.contact-info, .contact-form-container {
  background: #111a33;
  padding: 2rem;
  border-radius: 8px;
  position: relative; /* Nodig voor positionering van het logo */
  opacity: 0;
  transform: translateY(250px); /* Start veel dieper (langer traject) */
  filter: blur(5px);
  will-change: opacity, transform, filter;
  transition: opacity 1.2s ease-out, transform 1.2s ease-out, filter 1.2s ease-out; /* Langzamere, dramatische beweging */
}

.contact-info.visible, .contact-form-container.visible {
  opacity: 1;
  transform: translateY(0);
  filter: blur(0);
}

/* Logo rechtsboven in formulieren/blokken */
.form-logo {
  position: absolute;
  top: 1.5rem;
  right: 1.5rem;
  width: 80px; /* Pas de grootte aan naar wens */
  height: auto;
  border-radius: 4px;
}

.contact-info h2, .contact-form-container h2 {
  margin-top: 0;
  color: #ffaa00;
}

.contact-info p {
  color: #ccc;
  line-height: 1.6;
}

.contact-list {
  list-style: none;
  padding: 0;
  margin: 2rem 0;
}

.contact-list li {
  margin-bottom: 1.5rem;
  color: #fff;
}

.contact-list strong {
  display: block;
  color: #ffaa00;
  font-size: 0.9rem;
  margin-bottom: 0.25rem;
}

.contact-list a {
  color: #fff;
  text-decoration: none;
  transition: color 0.3s;
}

.contact-list a:hover {
  color: #ffaa00;
}

.form-row {
  display: flex;
  gap: 1.5rem;
  margin-bottom: 1rem;
}

.form-group {
  flex: 1;
}

.contact-form-container label {
  display: block;
  margin-bottom: 0.5rem;
  font-size: 0.9rem;
  color: #ccc;
}

.contact-form-container input,
.contact-form-container textarea,
.contact-form-container select {
  width: 100%;
  padding: 0.75rem;
  border: 1px solid #334155;
  border-radius: 4px;
  background: #0a0f1a;
  color: #fff;
  font-family: inherit;
  transition: border-color 0.3s, box-shadow 0.3s;
  box-sizing: border-box;
}

.contact-form-container input:focus,
.contact-form-container textarea:focus,
.contact-form-container select:focus {
  outline: none;
  border-color: #ffaa00;
  box-shadow: 0 0 0 2px rgba(255, 170, 0, 0.2);
}

.contact-form-container button {
  margin-top: 1.5rem;
  padding: 0.75rem 1.5rem;
  background: #ffaa00;
  color: #0a0f1a;
  border: none;
  border-radius: 4px;
  font-weight: bold;
  cursor: pointer;
  transition: all 0.3s ease;
}

.contact-form-container button:hover,
.contact-form-container button:focus {
  background: #cc8800;
  transform: translateY(-2px);
  box-shadow: 0 4px 12px rgba(255, 170, 0, 0.4);
  outline: none;
}

/* Succesmelding styling */
.success-message {
  text-align: center;
  padding: 2rem;
  animation: logo-entrance 0.5s ease-out;
  border: 1px solid #00cc00;
  background-color: rgba(0, 204, 0, 0.1);
  border-radius: 8px;
}

.success-message svg {
  width: 64px;
  height: 64px;
  stroke: #00cc00;
  margin-bottom: 1rem;
}

@media (max-width: 768px) {
  .contact-grid {
    grid-template-columns: 1fr;
    gap: 4rem; /* Meer ruimte tussen contactgegevens en formulier op mobiel */
  }
  .form-row {
    flex-direction: column;
    gap: 0;
  }
  .form-group {
    margin-bottom: 1rem;
  }
}

/* Privacy secties */
.privacy {
  max-width: 800px;
  margin: 2rem auto;
  padding: 2rem;
}

.privacy h2 {
  margin-top: 2rem;
  color: #ffaa00;
}

/* Footer */
footer {
  text-align: center;
  padding: 0;
  height: 50px; /* Iets compacter */
  display: flex;
  align-items: center;
  justify-content: center;
  background: transparent;
  margin-top: 1rem;
  border-top: 1px solid rgba(255,255,255,0.04);
  color: #f5f8ff;
  z-index: 2; /* Ensure footer is above canvas but below other elements if needed */
  position: relative; /* Anchor for absolutely positioned children */
  margin-top: auto; /* Duwt de footer naar beneden (Sticky Footer) */
}

footer p {
  margin: 0; /* Removes default browser margins from paragraphs */
}

.footer-credit {
  position: absolute;
  bottom: 1px; /* Consistent positioning from the bottom */
  right: 10px; /* Consistent positioning from the right */
  font-size: 0.75rem;
  opacity: 0.5;
}

/* === Cookie Banner === */
.cookie-banner {
  position: fixed;
  bottom: 0;
  left: 0;
  width: 100%;
  background: rgba(10, 15, 26, 0.9);
  backdrop-filter: blur(8px);
  -webkit-backdrop-filter: blur(8px);
  padding: 1rem 2rem;
  box-sizing: border-box;
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  z-index: 2000;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
  transform: translateY(100%);
  transition: transform 0.5s ease-in-out;
}

.cookie-banner.visible {
  transform: translateY(0);
}

.cookie-banner p {
  margin: 0;
  color: #ccc;
  font-size: 0.9rem;
}

.cookie-banner a {
  color: #ffaa00;
  text-decoration: underline;
}
.cookie-banner .cta-button {
  margin: 0;
  padding: 0.5rem 1rem;
  flex-shrink: 0;
}
/* === Circuit achtergrond en animatie === */
.hero, .flip-cards {
  /* sections are now transparent so the single body background shows through */
  background: transparent;
  position: relative;
  z-index: 1;
}

/* Animated tech-overlay to suggest information flow */
.hero::before,
.flip-cards::before {
  /* removed overlay svg per user request (single image only) */
  content: none;
}

/* overlay is now static; no keyframes */

/* circuitMove animation removed — background is now static */

/* === Mobiele navigatie (optie C) === */
@media (max-width: 768px) {
  .cookie-banner {
    flex-direction: column;
    text-align: center;
    padding: 1.5rem;
  }
  .cookie-banner .cta-button {
    margin-top: 1rem;
  }
  
  /* Hamburger zichtbaar maken */
  .hamburger {
    display: flex;
  }

  /* Header blijft in een rij (Logo links, Hamburger rechts) */
  header {
    flex-direction: row;
    align-items: center;
  }

  /* Navigatie menu styling voor mobiel (Dropdown) */
  header nav {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: rgba(10, 15, 26, 0.98); /* Donkere achtergrond */
    backdrop-filter: blur(10px);
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    padding: 2rem 0;
    
    /* Verbergen door naar boven te schuiven */
    transform: translateY(-150%);
    transition: transform 0.3s ease-in-out;
    z-index: -1; /* Achter de header balk */
    
    display: flex;
    justify-content: center;
  }

  /* Class om menu te tonen */
  header nav.active {
    transform: translateY(0);
    box-shadow: 0 10px 20px rgba(0,0,0,0.5);
  }

  header nav ul {
    flex-direction: column;
    align-items: center;
    width: 100%;
    gap: 1.5rem;
  }

  header nav ul li {
    width: auto;
    text-align: center;
  }

  header nav ul li a {
    display: inline-block;
    padding: 0.5rem 1rem;
    font-size: 1.1rem;
  }

  /* Hamburger Animatie naar X */
  .hamburger.active span:nth-child(1) {
    transform: rotate(45deg) translate(5px, 6px);
  }
  .hamburger.active span:nth-child(2) {
    opacity: 0;
  }
  .hamburger.active span:nth-child(3) {
    transform: rotate(-45deg) translate(5px, -6px);
  }
}

/* === Hero optimalisatie voor mobiel === */
@media (max-width: 768px) {
  .hero {
    padding: 3rem 1.5rem;
  }

  .hero h1 {
    font-size: 1.6rem;
    line-height: 1.3;
    margin-bottom: 1rem;
  }

  .hero p {
    font-size: 1rem;
    line-height: 1.5;
    margin-bottom: 1.5rem;
  }
}

/* === Flipcards optimalisatie voor mobiel === */
@media (max-width: 768px) {
  .flip-cards {
    grid-template-columns: 1fr;
    gap: 2rem;
    padding: 2rem;
  }
  
  .home-cards {
    margin-top: -20px; /* Minder overlap op mobiel voor animatieruimte */
  }

  .flip-card-inner {
    height: 140px; /* was 160px */
  }

  .flip-card-front,
  .flip-card-back {
    padding: 1rem;
  }

  .flip-card-front h3,
  .flip-card-back h3 {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
  }

  .flip-card-back p {
    font-size: 0.95rem;
    line-height: 1.4;
  }
}

/* === Modules grid optimalisatie voor mobiel === */
@media (max-width: 768px) {
  .modules-grid {
    gap: 1.5rem;
    padding: 1.5rem;
  }

  .modules-grid .module img {
    height: 48px; /* was 64px */
    margin-bottom: 0.75rem;
  }

  .modules-grid .module h3 {
    font-size: 1.1rem;
    margin-bottom: 0.5rem;
  }

  .modules-grid .module p {
    font-size: 0.95rem;
    line-height: 1.4;
  }
}

/* === Footer optimalisatie voor mobiel === */
@media (max-width: 768px) {
  footer {
    padding: 1.5rem 1rem;
    font-size: 0.95rem;
    text-align: center;
  }
}

/* Animatie voor mobiele knop */
@keyframes mobile-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-5px); }
}

/* === Knoppen en Formulier optimalisatie voor mobiel === */
@media (max-width: 768px) {
  .cta, .cta-button {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    text-align: center;
    margin: 1rem 0;
  }

  .cta-button.cta-outline {
    display: flex;
    justify-content: center;
    animation: pulse-glow 2.5s infinite ease-in-out, mobile-float 3s ease-in-out infinite;
  }

  .contact-form-container input,
  .contact-form-container textarea,
  .contact-form-container select {
    font-size: 16px; /* Voorkomt automatisch inzoomen op iOS */
  }

  .contact-form-container button {
    width: 100%; /* Maak de verzendknop schermbreed voor makkelijk tikken */
    padding: 1rem;
  }
}

/* === Over-ons foto optimalisatie voor mobiel === */
@media (max-width: 768px) {
  .over-ons-foto {
    max-width: 250px; /* was groter */
    margin: 1.5rem auto;
    display: block;
  }

  .over-ons-tekst {
    padding: 0 1rem;
    font-size: 1rem;
    line-height: 1.5;
  }
}

/* === Nieuwe toevoegingen voor uniformiteit === */

/* Keyframe animatie voor achtergrond fade */
@keyframes fade-top {
  0%, 28% { opacity: 1; }
  33%, 95% { opacity: 0; }
  100% { opacity: 1; }
}

@keyframes fade-middle {
  0%, 61% { opacity: 1; }
  66%, 95% { opacity: 0; }
  100% { opacity: 1; }
}

/* Keyframe animatie voor pulserende gloed */
@keyframes pulse-glow {
  0% {
    box-shadow: 0 0 4px rgba(255, 170, 0, 0.2);
  }
  50% {
    box-shadow: 0 0 16px rgba(255, 170, 0, 0.6);
  }
  100% {
    box-shadow: 0 0 4px rgba(255, 170, 0, 0.2);
  }
}

/* Keyframe animatie voor Ken Burns effect (pan/zoom) */
@keyframes ken-burns-1 {
  0% {
    transform: scale(1.1) translate(4%, -2%);
  }
  50% {
    transform: scale(1.25) translate(-4%, 2%);
  }
  100% {
    transform: scale(1.1) translate(4%, -2%);
  }
}
@keyframes ken-burns-2 {
  0% {
    transform: scale(1.25) translate(-4%, 3%);
  }
  50% {
    transform: scale(1.1) translate(4%, -3%);
  }
  100% {
    transform: scale(1.25) translate(-4%, 3%);
  }
}

/* Achtergrond animatie canvas */
#network-canvas {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  z-index: -1; /* Achter de content */
  pointer-events: none;
}

/* Gecentreerd Logo Container */
.logo-centered {
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 40px 0;
}

/* Animatie voor logo binnenkomst */
@keyframes logo-entrance {
  0% { opacity: 0; transform: translateY(-30px); }
  100% { opacity: 1; transform: translateY(0); }
}

/* Dramatische Logo Animatie */
@keyframes dramatic-entrance {
  0% {
    opacity: 0;
    /* Start hoog (-150px), gekanteld en zakt naar beneden */
    transform: perspective(1000px) rotateX(25deg) translateY(-150px);
    filter: blur(6px);
  }
  100% {
    opacity: 1;
    /* Eindigt recht en op zijn plek */
    transform: perspective(1000px) rotateX(0deg) translateY(0);
    filter: blur(0);
  }
}

/* Tekst Animatie: Inkomend van Links met Blur */
@keyframes text-entrance-left {
  0% {
    opacity: 0;
    transform: translateX(-40px);
    filter: blur(5px);
  }
  100% {
    opacity: 1;
    transform: translateX(0);
    filter: blur(0);
  }
}

/* === Over Ons Sectie Styling === */
.about {
  position: relative;
  z-index: 2;
  max-width: 800px;
  margin-left: auto;
  margin-right: auto;
  padding: 0 2rem;
  /* Gebruik VH (viewport height) in plaats van vaste pixels om overlap te voorkomen */
  margin-top: -40vh;
}

/* Aanpassing voor kleinere schermen (zoals 13 inch laptops) */
@media (max-height: 700px) {
  .about {
    margin-top: -20vh; /* Minder overlap op lagere schermen */
  }
}

/* Specifieke animatie voor Over Ons content */
.story h2 {
  opacity: 0;
  will-change: transform, opacity, filter;
  animation: text-entrance-left 1.2s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.story p {
  opacity: 0;
  will-change: transform, opacity, filter;
  animation: text-entrance-right 1.2s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

/* Tekst Animatie: Inkomend van Rechts met Blur */
@keyframes text-entrance-right {
  0% {
    opacity: 0;
    transform: translateX(40px);
    filter: blur(5px);
  }
  100% {
    opacity: 1;
    transform: translateX(0);
    filter: blur(0);
  }
}

.logo-centered img {
  width: 300px;
  height: auto;
  opacity: 0;
  transition: transform 0.4s ease, filter 0.4s ease, box-shadow 0.4s ease;
  border-radius: 12px;
  will-change: transform, opacity, filter, box-shadow;
}

.logo-centered img.visible {
  opacity: 1;
  animation: dramatic-entrance 1.2s cubic-bezier(0.22, 1, 0.36, 1) forwards;
}

.logo-centered img:hover {
  transform: scale(1.05);
  filter: brightness(1.15);
  box-shadow: 0 0 30px rgba(255, 170, 0, 0.3);
}

/* === Portret foto animaties (Over ons) === */

/* Subtiele vormverandering (ademen) */
@keyframes portrait-morph {
  0% { border-radius: 30%; }
  50% { border-radius: 45%; } /* Iets ronder */
  100% { border-radius: 30%; }
}

.portrait-img {
  width: 160px;
  height: 200px;
  border-radius: 30%;
  border: 3px solid #ffaa00;
  box-shadow: 0 8px 20px rgba(0,0,0,0.5);
  object-fit: cover;
  object-position: center 25%;
  
  animation: logo-entrance 1.2s ease-out, portrait-morph 6s ease-in-out infinite;
  transition: transform 0.4s ease, box-shadow 0.4s ease, border-color 0.4s ease;
}

.portrait-img:hover {
  transform: scale(1.05);
  box-shadow: 0 0 30px rgba(255, 170, 0, 0.5);
  border-color: #fff;
}

/* Traffic Light Styles (Modules) */
.traffic-light {
  display: flex;
  gap: 6px;
  background: #05080f;
  padding: 6px;
  border-radius: 20px;
  margin-top: 15px;
  border: 1px solid #333;
}
.light { width: 10px; height: 10px; border-radius: 50%; background-color: #2a2a2a; }
.light.red.active { background-color: #ff4444; box-shadow: 0 0 8px #ff4444; }
.light.orange.active { background-color: #ffbb33; box-shadow: 0 0 8px #ffbb33; }
.light.green.active { background-color: #00cc00; box-shadow: 0 0 8px #00cc00; }

/* 404 Blinking Animation */
@keyframes blink-animation {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

.blink-exclamation {
  animation: blink-animation 1.2s infinite;
}

/* === Connected Lift Effect (Domino) === */
/* Zorgt dat de kaart erboven meetilt als je over de onderste kaart hovert */

/* Desktop (3 kolommen): Mapping 4->1, 5->2, 6->3 */
@media (min-width: 1025px) {
  .flip-card:nth-child(1):has(~ .flip-card:nth-child(4):hover),
  .flip-card:nth-child(2):has(~ .flip-card:nth-child(5):hover),
  .flip-card:nth-child(3):has(~ .flip-card:nth-child(6):hover),
  .flip-card:nth-child(1):has(~ .flip-card:nth-child(4).active),
  .flip-card:nth-child(2):has(~ .flip-card:nth-child(5).active),
  .flip-card:nth-child(3):has(~ .flip-card:nth-child(6).active) {
    transform: perspective(1000px) translateY(-40px) rotateX(10deg);
    z-index: 9;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) 0.1s;
  }
}

/* Helper animatie om interactie pas na binnenkomst mogelijk te maken */
@keyframes enable-pointer {
  to { pointer-events: auto; }
}

/* Soft Launch Melding (Contactpagina) */
.soft-launch-notice {
  background: rgba(255, 170, 0, 0.1);
  border-left: 3px solid #ffaa00;
  padding: 1rem;
  margin-bottom: 2rem;
  border-radius: 0 4px 4px 0;
  color: #fff;
  font-style: italic;
  font-size: 0.95rem;
  line-height: 1.5;
}

/* Tablet (2 kolommen): Mapping 3->1, 4->2, 5->3, 6->4 */
@media (max-width: 1024px) and (min-width: 769px) {
  .flip-card:nth-child(1):has(~ .flip-card:nth-child(3):hover),
  .flip-card:nth-child(2):has(~ .flip-card:nth-child(4):hover),
  .flip-card:nth-child(3):has(~ .flip-card:nth-child(5):hover),
  .flip-card:nth-child(4):has(~ .flip-card:nth-child(6):hover),
  .flip-card:nth-child(1):has(~ .flip-card:nth-child(3).active),
  .flip-card:nth-child(2):has(~ .flip-card:nth-child(4).active),
  .flip-card:nth-child(3):has(~ .flip-card:nth-child(5).active),
  .flip-card:nth-child(4):has(~ .flip-card:nth-child(6).active) {
    transform: perspective(1000px) translateY(-40px) rotateX(10deg);
    z-index: 9;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) 0.1s;
  }
}

/* Mobiel (1 kolom): Domino effect via JS class .bump-up */
@media (max-width: 768px) {
  .flip-card.bump-up {
    transform: perspective(1000px) translateY(-40px) rotateX(10deg);
    z-index: 9;
    transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275) 0s;
  }
}
