/* ======================= Grundinställningar ======================= */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
  scroll-behavior: smooth; /* mjuk scroll */
}

body {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  background-color: #fff;
  color: #333;
  transition: background-color 0.25s ease, color 0.25s ease;
}

a {
  text-decoration: none;
  color: #007BFF;
  transition: color 0.25s ease;
}

a:hover {
  text-decoration: underline;
}

.book-title {
  font-style: italic;
}

/* ======================= Navbar ======================= */
.navbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 30px;
  background: rgba(255, 255, 255, 0.95);
  position: fixed;
  width: 100%;
  z-index: 1000;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
  transition: all 0.25s ease;
}

.navbar.shrink {
  transform: translateY(-5px);
  padding: 10px 20px;
  box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

.navbar .logo {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.navbar .logo img {
  max-height: 60px;
  height: auto;
  width: auto;
  transition: all 0.25s ease;
}

.logo-text {
  font-size: 1rem;
  font-weight: 400;
  color: #fff;
  text-shadow: 1px 1px 3px rgba(0,0,0,0.6);
  margin-top: 5px;
  transition: all 0.25s ease;
}

.nav-menu {
  display: flex;
  list-style: none;
  transition: all 0.25s ease;
}

.nav-menu li {
  margin-left: 20px;
}

.nav-menu a {
  font-size: 1rem;
  font-weight: 500;
  transition: color 0.25s ease;
}

.hamburger {
  display: none;
  flex-direction: column;
  cursor: pointer;
}

.hamburger span {
  height: 3px;
  width: 25px;
  background: #333;
  margin-bottom: 4px;
  border-radius: 5px;
  transition: all 0.25s ease;
}

/* ======================= Parallax-sektioner ======================= */
.parallax-section,
.parallax1-section,
.parallax2-section,
.parallax3-section,
.parallax4-section,
.parallax5-section,
.parallax6-section {
  position: relative;
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 50px 20px;
  color: #fff;
  text-align: center;

  background-size: cover;
  background-position: center;
  background-attachment: fixed;

  transition: background-color 0.25s ease, color 0.25s ease;
}

/* Flytande färgövergång med overlay */
.parallax-section::before,
.parallax1-section::before,
.parallax2-section::before,
.parallax3-section::before,
.parallax4-section::before,
.parallax5-section::before,
.parallax6-section::before {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(
    rgba(0,0,0,0.25),
    rgba(0,0,0,0.35)
  );
  z-index: 0;
}

/* Bakgrundsbilder */
.parallax-section {
  background-image: url(../images/book.webp);
}
.parallax1-section {
  background-image: url(../images/bg.webp);
}
.parallax2-section {
  background-image: url(../images/book4.webp);
}
.parallax3-section {
  background-image: url(../images/enviro.webp);
}
.parallax4-section {
  background-image: url(../images/book2.webp);
}
.parallax5-section {
  background-image: url(../images/links.webp);
}
.parallax6-section {
  background-image: url(../images/booka.webp);
  display: flex;
  justify-content: center;
  align-items: center;
}

/* Textwrapper för parallaxinnehåll */
.text-wrapper,
.text-wrapper1,
.text-wrapper2,
.text-wrapper3,
.text-wrapper4,
.text-wrapper5,
.text-wrapper6 {
  position: relative;
  z-index: 1;
  background: rgba(255, 255, 255, 0.75);
  padding: 20px;
  border-radius: 12px;
  max-width: 900px;
  width: 100%;
  color: #222;
  transition: transform 0.25s ease, opacity 0.25s ease;
  box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

/* Fotocred i övre högra hörnet */
.photo-credit {
  position: absolute;
  top: 10px;
  right: 15px;
  font-size: 0.8rem;
  color: #fff;
  
  padding: 3px 6px;
  border-radius: 4px;
  font-style: italic;
  z-index: 2;
}

/* ======================= Länkar i parallaxer ======================= */
.text-wrapper a,
.text-wrapper1 a,
.text-wrapper2 a,
.text-wrapper3 a,
.text-wrapper4 a,
.text-wrapper5 a,
.text-wrapper6 a {
  color: #007BFF;
  transition: color 0.25s ease;
}

.text-wrapper a:hover,
.text-wrapper1 a:hover,
.text-wrapper2 a:hover,
.text-wrapper3 a:hover,
.text-wrapper4 a:hover,
.text-wrapper5 a:hover,
.text-wrapper6 a:hover {
  color: #0056b3;
  text-decoration: underline;
}

/* ======================= Kontakt & formulär ======================= */
.kontakt-wrapper {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
  gap: 40px;
  width: 100%;
  max-width: 1100px;
  transition: transform 0.25s ease, opacity 0.25s ease;
}

.image-container {
  flex: 1 1 350px;
  text-align: center;
  transition: all 0.25s ease;
}

.image-container img {
  max-width: 100%;
  border-radius: 10px;
  transition: transform 0.25s ease;
}

.image-container img:hover {
  transform: scale(1.05);
}

/* Kontakt-delens fotocred */
.kontakt-credit {
  display: block;
  font-size: 0.8rem;
  color: #555;
  margin-top: 8px;
  font-style: italic;
  text-align: center;
}

.text-wrapper6 {
  flex: 1 1 400px;
  text-align: left;
  transition: all 0.25s ease;
}

.kontaktform input,
.kontaktform textarea,
.kontaktform button {
  width: 100%;
  margin-bottom: 15px;
  padding: 10px;
  font-size: 1rem;
  border-radius: 5px;
  border: 1px solid #ccc;
  transition: all 0.25s ease;
}

.kontaktform input:focus,
.kontaktform textarea:focus {
  border-color: #007BFF;
  box-shadow: 0 0 5px rgba(0,123,255,0.5);
  outline: none;
}

.kontaktform button {
  background: #007BFF;
  color: #fff;
  border: none;
  cursor: pointer;
  transition: background 0.25s ease, transform 0.2s ease;
}

.kontaktform button:hover {
  background: #0056b3;
  transform: scale(1.05);
}

/* ======================= Footer ======================= */
footer {
  text-align: center;
  padding: 20px;
  background: #222;
  color: #fff;
  transition: background-color 0.25s ease, color 0.25s ease;
}

/* ======================= Uppdrag toggle-knapp ======================= */
.toggle-btn {
  background: #007BFF;
  color: #fff;
  border: none;
  padding: 8px 15px;
  border-radius: 5px;
  cursor: pointer;
  transition: background 0.25s ease, transform 0.2s ease;
}

.toggle-btn:hover {
  background: #0056b3;
  transform: scale(1.05);
}

/* ======================= Extra text gömd initialt ======================= */
.extra-text.hidden {
  display: none;
}

/* ======================= Responsivitet och mobiloptimering ======================= */
@media (max-width: 768px) {
  .hamburger {
    display: flex;
  }

  .nav-menu {
    display: none;
    flex-direction: column;
    width: 100%;
    background: rgba(255,255,255,0.95);
    position: absolute;
    top: 65px;
    left: 0;
    transition: max-height 0.25s ease;
    overflow: hidden;
  }

  .nav-menu.active {
    display: flex;
  }

  .nav-menu li {
    margin: 15px 0;
  }

  .kontakt-wrapper {
    flex-direction: column;
    gap: 20px;
  }

  .text-wrapper6 {
    text-align: center;
  }

  /* Dölj fotocred i mobilläge */
  .photo-credit {
    display: none;
  }

  /* Flytande färger i mobil istället för hårda block */
  .parallax-section { background: linear-gradient(135deg,#4a90e2,#50e3c2); }
  .parallax1-section { background: linear-gradient(135deg,#50e3c2,#f5a623); }
  .parallax2-section { background: linear-gradient(135deg,#f5a623,#9013fe); }
  .parallax3-section { background: linear-gradient(135deg,#9013fe,#7ed321); }
  .parallax4-section { background: linear-gradient(135deg,#7ed321,#d0021b); }
  .parallax5-section { background: linear-gradient(135deg,#d0021b,#f8e71c); }
  .parallax6-section { background: linear-gradient(135deg,#f8e71c,#4a90e2); }
}

.warning-box {
  display: flex;
  align-items: flex-start;
  gap: 15px;
  margin-top: 25px;
  padding: 20px;
  border: 2px solid #cc0000;
  background-color: #fff5f5;
  border-radius: 10px;
  box-shadow: 0 3px 8px rgba(0,0,0,0.15);
}

.warning-icon {
  flex-shrink: 0;
  background: #ffcc00;
  color: #000;
  font-size: 1.8rem;
  font-weight: bold;
  width: 50px;
  height: 50px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 2px 6px rgba(0,0,0,0.2);
}

.warning-text {
  color: #990000;
  font-size: 1rem;
  line-height: 1.6;
}

.warning-text strong {
  color: #cc0000;
}

/* Responsiv anpassning för mobiler */
@media (max-width: 600px) {
  .warning-box {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .warning-icon {
    margin-bottom: 10px;
  }
}
