/* =========================
   BASE
========================= */
* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: #111;
  background: #fff;
}

a {
  text-decoration: none;
  color: inherit;
}

img {
  max-width: 100%;
  display: block;
}

/* =========================
   HEADER & NAV
========================= */
header {
  position: relative;
  z-index: 1000;
}

nav {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 1rem 2rem;
  background: #f5f5f5;
}

.logo {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  color: inherit;
}

.logo img {
  width: 90px;
  height: auto;
}

.logo span {
  font-weight: bold;
  font-size: 1.1rem;
}

.nav-links {
  list-style: none;
  display: flex;
  gap: 2rem;
  margin: 0;
  padding: 0;
}

.menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 2rem;
  cursor: pointer;
}

/* =========================
   HERO + SLIDESHOW
========================= */
.hero-slideshow {
  width: 80%;
  max-width: 1100px;
  margin: 0 auto;
  aspect-ratio: 16 / 9;     /* YHTEINEN KORKEUS */
  position: relative;
  overflow: hidden;
  background: #fff;
}

.hero-slideshow img {
  position: absolute;      /* TÄRKEÄ */
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  opacity: 0;
  transition: opacity 1s ease-in-out;
}

.hero-slideshow img.active {
  opacity: 1;
}

/* =========================
   INTRO
========================= */
.intro {
  max-width: 800px;
  margin: 3rem auto 4rem auto;
  padding: 0 1rem;
  text-align: center;
}

.intro p {
  margin-bottom: 1.5rem;
  font-size: 1.05rem;
}

/* =========================
   REFERENCES / KOHTEET
========================= */
.references {
  max-width: 1100px;
  margin: 4rem auto;
  padding: 0 2rem;
}

.references h2 {
  text-align: center;
  margin-bottom: 3rem;
}

.reference-item {
  margin-bottom: 4rem;
}

.reference-item h3 {
  margin-bottom: 0.5rem;
  font-size: 1.3rem;
}

.reference-description {
  margin-bottom: 1.5rem;
  font-size: 0.95rem;
  color: #555;
  max-width: 700px;
}

.reference-images {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 1rem;
}

.reference-image img {
  width: 100%;
  height: 280px;
  object-fit: cover;
  border-radius: 4px;
}

.image-source {
  margin-top: 0.4rem;
  font-size: 0.75rem;
  color: #777;
}

/* =========================
   FOOTER
========================= */
footer {
  background: #f5f5f5;
  padding: 2rem;
  text-align: center;
  font-size: 0.9rem;
  color: #666;
}

.footer-social {
  margin-top: 1rem;
}
.footer-social img {
  width: 22px;
  height: 22px;
  opacity: 0.7;
  transition: opacity 0.3s ease;
}

.footer-social img:hover {
  opacity: 1;
}
/* =========================
   PALVELUT & YHTEYS – DESKTOP
========================= */
.services,
.contact {
  max-width: 800px;
  margin: 4rem auto;
  padding: 0 2rem;
  text-align: center;
}
/* =========================
   YHTEYS – KUVA
========================= */
.contact-photo {
  width: 150px;
  height: auto;
  border-radius: 50%;
  margin: 0 auto 1.5rem auto;
  display: block;
}

/* =========================
   MOBILE
========================= */
@media (max-width: 768px) {

  nav {
    flex-direction: column;
    gap: 1rem;
  }

  .menu-toggle {
    display: block;
  }

  .nav-links {
    display: none;
    flex-direction: column;
    width: 100%;
    background: #f5f5f5;
    text-align: center;
    padding: 1rem 0;
  }

  .nav-links.show {
    display: flex;
  }

  .hero-slideshow {
    width: 100%;
  }

  .reference-images {
    grid-template-columns: 1fr;
  }

  .reference-image img {
    height: auto;
    object-fit: contain;
  }
}