/*
 * Basisstijl voor de website van ISTM (Interim Solutions That Matter).
 * Zakelijk, overzichtelijk en blauw kleurpalet.
 */

:root {
  --brand-dark: #003366;
  --brand-darker: #00224d;
  --brand-accent: #eaf0f6;
}

* { box-sizing: border-box; }

body {
  font-family: Arial, sans-serif;
  margin: 0;
  padding: 0;
  color: #222;
  background-color: #f5f7fa;
  line-height: 1.6;
}

/* Vloeiend scrollen en anchor-compensatie voor sticky balken */
html { 
  scroll-behavior: smooth; 
  scroll-padding-top: 120px; /* compenseert topbar + header */
}

/* Topbar (sticky) */
.topbar {
  background-color: var(--brand-darker);
  color: #fff;
  font-size: 0.8rem;
  padding: 0.5rem 1rem;
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: sticky;
  top: 0;
  z-index: 1000;
}
.topbar .contact-info,
.topbar .social {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
}
.topbar .contact-info span,
.topbar .social a {
  margin-right: 1rem;
  color: #fff;
  text-decoration: none;
}
.topbar .social a:hover { text-decoration: underline; }

/* Header (sticky) */
header {
  background-color: var(--brand-dark);
  color: #fff;
  padding: 1rem 2rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  position: sticky;
  top: 32px; /* hoogte van de topbar */
  z-index: 999;
}

.logo img {
  height: 60px;
  width: auto;
  background-color: #ffffff;
  padding: 0.3rem;
  border-radius: 4px;
  box-shadow: 0 0 4px rgba(0,0,0,0.1);
}

nav {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
}
nav a {
  color: #ffffff;
  margin-left: 1.5rem;
  text-decoration: none;
  font-weight: 500;
}
nav a:hover { text-decoration: underline; }

/* Main */
main { padding: 2rem; }

/* Secties */
.welcome,
.services-section,
.about-section,
.contact-section {
  padding: 2rem;
  margin-bottom: 2rem;
  border-radius: 8px;
}
#welcome, #diensten, #over, #contact { scroll-margin-top: 120px; }

.welcome { background-color: #fff; }
.services-section { background-color: var(--brand-accent); }
.about-section { background-color: #fff; }
.contact-section { background-color: var(--brand-accent); }

/* Welkom layout */
.welcome-flex {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 2rem;
}
.welcome-text { flex: 1 1 50%; }
.welcome-image { flex: 1 1 45%; }
.welcome-image img {
  width: 100%;
  height: auto;
  border-radius: 8px;
  object-fit: cover;
}

/* Diensten grid en cards */
.services-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  margin-top: 1rem;
}
.service-card {
  background-color: #ffffff;
  border-radius: 8px;
  box-shadow: 0 4px 8px rgba(0,0,0,0.06);
  flex: 1;
  min-width: 250px;
  max-width: 31%;
  display: flex;
  flex-direction: column;
}
.service-card img {
  width: 100%;
  height: 140px;        /* compacte header-visual zoals voorbeeld */
  object-fit: cover;
  border-top-left-radius: 8px;
  border-top-right-radius: 8px;
  border-bottom: 1px solid rgba(0,0,0,0.06);
}
.service-card h3 {
  margin: 1rem 1rem 0.5rem 1rem;
  color: var(--brand-dark);
  font-size: 1.3rem;
}
.service-card p { margin: 0 1rem 0.75rem 1rem; color: #333; }
.service-card ul {
  margin: 0 1rem 1rem 1.25rem;
  padding: 0;
}
.service-card ul li { margin: 0.25rem 0; }

@keyframes scroll-logos {
  0% { transform: translateX(0); }
  100% { transform: translateX(-50%); }
}
.logo-carousel { overflow: hidden; margin: 2rem auto; }
.logo-carousel .logo-track {
  display: flex; align-items: center;
  animation: scroll-logos 30s linear infinite;
}
.logo-carousel .logo-track img { height: 80px; width: auto; margin: 0 2rem; }

/* Contact layout */
.contact-flex {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 2rem;
}
.contact-image { flex: 1 1 40%; }
.contact-image img {
  width: 100%; height: auto; border-radius: 8px; object-fit: cover;
}
.contact-content { flex: 1 1 50%; }
.contact-content form { max-width: none; margin: 0; }

/* Formulieren */
form {
  max-width: 600px;
  margin: 0 auto;
  display: flex;
  flex-direction: column;
}
form label { margin-top: 1rem; }
form input, form textarea {
  padding: 0.5rem;
  font-size: 1rem;
  margin-top: 0.25rem;
  border: 1px solid #ccc;
  border-radius: 4px;
}
form textarea { min-height: 150px; }
button {
  margin-top: 1.5rem;
  padding: 0.75rem;
  background-color: var(--brand-dark);
  color: white;
  border: none;
  border-radius: 4px;
  cursor: pointer;
  font-size: 1rem;
}
button:hover { background-color: var(--brand-darker); }

/* Footer */
footer { margin-top: 3rem; }
.bottombar {
  background-color: var(--brand-darker);
  color: #fff;
  font-size: 0.85rem;
  padding: 0.75rem 1rem;
  text-align: center;
}

/* Responsief */
@media (max-width: 900px) {
  .service-card { max-width: 48%; }
}
@media (max-width: 768px) {
  .welcome-flex, .contact-flex { flex-direction: column; }
  .welcome-text, .welcome-image, .contact-image, .contact-content { flex-basis: 100%; }
}
@media (max-width: 600px) {
  nav { flex-direction: column; align-items: flex-start; }
  nav a { margin: 0.5rem 0; }
  header { flex-direction: column; align-items: flex-start; }
  .service-card { max-width: 100%; }
}
