/* Farvevariabler */
:root {
    --cream: #E8E1D9;
    --black: #2B2B2B;
    --green: #A3B18A;
    --orange: #D7A86E;
    --lavender: #D9CCE5;
}

/* Nulstil og grundstruktur */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html, body {
    height: 100%;
}

body {
    font-family: 'Lato', sans-serif;
    font-size: 1rem;
    background-color: var(--cream);
    color: var(--black);
    line-height: 1.6;
    display: flex;
    flex-direction: column;
}

/* Overskrifter med anden skrifttype */
h1, h2, h3 {
    font-family: 'Cormorant Garamond', serif;
    font-weight: 700;
}

/* Header */
header {
    position: fixed;
    width: 100%;
    background-color: var(--green);
    z-index: 1000;
    padding: 1em 2em;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Logo */
.logo {
    font-family: 'Cormorant Garamond', serif;
    font-size: 2em;
    font-weight: 900;
    text-decoration: none;
    color: white;
}

/* Navigation */
nav a {
    color: white;
    margin-left: 1.5em;
    text-decoration: none;
    font-weight: bold;
}

nav a.active {
    text-decoration: underline;
}

/* Main og footer */
main {
    flex: 1;
    padding-top: 100px;
}

footer {
    background-color: var(--black);
    color: var(--cream);
    text-align: center;
    padding: 1em;
}

/* Forside – introduktionssektion */
.forside__intro {
  height: calc(100vh - 100px);
  display: flex;
  justify-content: space-between;
  align-items: stretch;
  padding: 2em;
  animation: fadeInUp 0.8s ease forwards;
  opacity: 0;
}

.forside__intro-text {
  flex: 1 1 50%;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 2em;
  background-color: var(--cream);
}

.forside__intro-text h1 {
  font-size: 2.2rem;
  margin-bottom: 0.5em;
}

.forside__intro-text p {
  font-size: 1rem;
  line-height: 1.5;
  margin-bottom: 1.2em;
}

.forside__intro-img {
  flex: 1 1 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 2em;
}

.forside__intro-img img {
  width: 100%;
  height: 100%;
  max-height: 500px;
  object-fit: cover;
  border-radius: 2rem;
  border: 2px solid var(--lavender);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
  transition: transform 0.4s ease;
}

.forside__intro-img img:hover {
  transform: scale(1.02);
}

.forside__cta {
  display: inline-block;
  background-color: var(--lavender);
  color: var(--black);
  padding: 0.75em 1.5em;
  font-weight: bold;
  border-radius: 2rem;
  text-decoration: none;
  font-size: 1rem;
  transition: background-color 0.3s ease, transform 0.2s ease;
  max-width: fit-content;
}

.forside__cta:hover {
  background-color: var(--orange);
  color: var(--cream);
  transform: translateY(-2px);
}

/* Animation bruges til fade-in fra bund */
@keyframes fadeInUp {
    0% {
        opacity: 0;
        transform: translateY(30px);
    }
    100% {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Scroll-til-top-knap */
.scroll-up-btn {
    position: fixed;
    bottom: clamp(40px, 10vh, 100px);
    right: 30px;
    background-color: var(--orange);
    color: white;
    text-decoration: none;
    font-size: 20px;
    padding: 12px 16px;
    border-radius: 50%;
    box-shadow: 0 4px 6px var(--lavender);
    z-index: 999;
}

.scroll-up-btn:hover {
    background-color: var(--lavender);
}

/* Mobilvisning */
@media (max-width: 768px) {
    .forside .intro {
        flex-direction: column;
        padding: 2em 1.5em;
    }

    .intro-img {
        order: -1; /* Billede vises over teksten på mobil */
        padding: 1em 0;
    }

    .intro-text {
        padding: 1em;
        text-align: center;
    }
}


/* Projekter – sektion med projekter */
.project-section {
    padding: 3em 2em;
    background-color: var(--cream); /* Lys baggrund */
    box-shadow: inset 0 -20px 20px -20px rgba(0, 0, 0, 0.05); /* Blød kant */
    transition: background-color 0.3s ease;
  }
  
  /* Skiftevis mørk baggrund */
  .project-section.dark {
    background-color: var(--green);
    color: var(--cream);
    box-shadow: inset 0 -20px 20px -20px rgba(0, 0, 0, 0.1);
  }
  
  /* Layout for hvert projekt – grid med 2 kolonner */
  .project-section > .projekt {
    max-width: 1100px;
    margin: auto;
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3em;
    align-items: center;
  }
  
  /* Reverse layout – billede til venstre */
  .project-section .projekt.reverse {
    direction: rtl;
  }
  
  .project-section .projekt.reverse .tekst {
    direction: ltr;
  }
  
  /* Tekst i projekterne */
  .projekt .tekst h2 {
    font-size: 2rem;
    margin-bottom: 0.5em;
  }
  
  .projekt .tekst p {
    line-height: 1.6;
    margin-bottom: 1em;
  }
  
  /* Billeder og videoer */
  .projekt img,
  .projekt video {
    max-width: 450px;
    width: 100%;
    height: auto;
    border: 2px solid var(--orange);
    border-radius: 1rem;
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
  }
  
  .projekt img:hover,
  .projekt video:hover {
    transform: scale(1.03);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
  }
  
  /* Responsivt layout på mobil */
  @media (max-width: 768px) {
    .project-section > .projekt,
    .project-section .projekt.reverse {
      grid-template-columns: 1fr; /* Enkelt kolonne */
      text-align: center;
    }
  
    .projekt .tekst,
    .projekt .billede {
      width: 100%;
    }
  
    .projekt img,
    .projekt video {
      max-width: 100%;
    }
  }

/* Om mig – indholdslayout */
.ommig-indhold {
    display: flex;
    flex-wrap: wrap;
    gap: 3em;
    align-items: center;
    justify-content: center;
    padding: 4em 2em;
    max-width: 1100px;
    margin: auto;
    animation: fadeInUp 0.8s ease forwards; /* Indgangseffekt */
    opacity: 0;
  }
  
  /* Billedsektion */
  .ommig-indhold .billede {
    flex: 1 1 40%;
    text-align: center;
  }
  
  .ommig-indhold .billede img {
    width: 100%;
    max-width: 350px;
    height: auto;
    border-radius: 1rem;
    border: 2px solid var(--orange);
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
  }
  
  .ommig-indhold .billede img:hover {
    transform: scale(1.05); /* Zoom-effekt ved hover */
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.15);
  }
  
  /* Tekstdel */
  .ommig-indhold .tekst {
    flex: 1 1 55%;
    font-size: 1.1rem;
    line-height: 1.8;
  }
  
  .ommig-indhold .tekst h1 {
    font-size: 2.2rem;
    margin-bottom: 1em;
  }
  
  /* Mobilvisning */
  @media (max-width: 768px) {
    .ommig-indhold {
      flex-direction: column;
      text-align: center;
    }
  
    .ommig-indhold .tekst {
      text-align: left;
      padding: 0 1em;
    }
  }



/* Kontaktformular – layout og stil */
.kontakt form {
    display: grid;
    gap: 1.5em;
    max-width: 500px;
    margin: 3em auto;
    background-color: white;
    padding: 3em 2em;
    border: 2px solid var(--lavender);
    border-radius: 1.5rem;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08);
    animation: fadeInUp 0.8s ease forwards;
    opacity: 0;
  }
  
  /* Introtekst over formular */
  .kontakt-intro {
    text-align: center;
    max-width: 600px;
    margin: 4em auto 2em;
    padding: 0 1em;
    animation: fadeInUp 0.8s ease forwards;
    opacity: 0;
  }
  
  .kontakt-intro h1 {
    font-size: 2.2rem;
    margin-bottom: 0.5em;
    color: var(--black);
  }
  
  .kontakt-intro p {
    font-size: 1.1rem;
    color: var(--black);
    line-height: 1.6;
  }
  
  /* Formularfelter */
  .kontakt label {
    font-weight: bold;
    margin-bottom: 0.5em;
    display: block;
    font-size: 1rem;
    color: var(--black);
  }
  
  .kontakt input,
  .kontakt textarea {
    width: 100%;
    padding: 0.75em;
    border: 1px solid var(--black);
    border-radius: 0.75rem;
    font-family: inherit;
    font-size: 1rem;
    transition: border-color 0.3s ease, box-shadow 0.3s ease;
  }
  
  /* Fokus-effekt ved klik i felt */
  .kontakt input:focus,
  .kontakt textarea:focus {
    outline: none;
    border-color: var(--lavender);
    box-shadow: 0 0 0 3px rgba(217, 204, 229, 0.3);
  }
  
  /* Beskedfelt */
  .kontakt textarea {
    min-height: 120px;
    resize: vertical;
  }
  
  /* Send-knap */
  .kontakt button {
    background-color: var(--lavender);
    color: var(--black);
    padding: 0.9em;
    font-weight: bold;
    border: none;
    border-radius: 2rem;
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.2s ease;
    font-size: 1rem;
  }
  
  .kontakt button:hover {
    background-color: var(--orange);
    color: var(--cream);
    transform: translateY(-2px);
  }

/* Fade-in animation */
@keyframes fadeInUp {
  0% {
    opacity: 0;
    transform: translateY(30px);
  }
  100% {
    opacity: 1;
    transform: translateY(0);
  }
}

.projekt {
  animation: fadeInUp 0.8s ease forwards;
  opacity: 0;
}

main.projekter h1 {
  text-align: center;
  font-size: 2.5rem;
  margin: 1.5em auto 0.5em;
  width: 100%;
  border-bottom: 2px solid var(--lavender);
  padding-bottom: 0.5em;
  max-width: 700px;
}

/* Responsiv tilpasning */
@media (max-width: 768px) {
}

/* Billeder */
.slide img {
  display: block;
  margin: 0 auto;
  width: auto;
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  border: 4px solid var(--orange);
  box-sizing: border-box;
}

.scroll-up-btn {
  position: fixed;
  bottom: 80px;
  right: 30px;
  background-color: var(--orange);
  color: white;
  text-decoration: none;
  font-size: 20px;
  padding: 12px 16px;
  border-radius: 50%;
  box-shadow: 0 4px 6px var(--lavender);
  z-index: 999;
  bottom: clamp(40px, 10vh, 100px);
}

.scroll-up-btn:hover {
  background-color: var(--lavender);
}

html {
  scroll-behavior: smooth;
}

.project-section:last-of-type {
  min-height: calc(100vh - 160px);
}

/* Mobilvenlig layout (op til 768px bredde) */
@media (max-width: 768px) {
  header {
    flex-direction: column;
    align-items: flex-start;
    padding: 1em;
  }

  nav {
    display: flex;
    flex-direction: column;
    gap: 1em;
    margin-top: 1em;
  }

  .projekt-container,
  .projekt,
  .project-section .projekt.reverse {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .projekt .tekst,
  .projekt .billede {
    width: 100%;
    max-width: 90%;
  }

  .intro-text {
    padding: 2em 1em;
  }

  h1, h2 {
    font-size: 1.8rem;
  }

  .cta-knap {
    font-size: 0.9rem;
    padding: 0.5em 1em;
  }

  footer {
    font-size: 0.8rem;
    padding: 1.5em 1em;
  }
}

/* Burger-ikon */
.burger {
  display: none;
  font-size: 2rem;
  color: white;
  cursor: pointer;
}

/* Skjul checkbox */
#menu-toggle {
  display: none;
}

/* Desktop */
.main-nav {
  display: flex;
  gap: 1.5em;
}

/* Mobil */
@media (max-width: 768px) {
  .burger {
    display: block;
  }

  .main-nav {
    display: none;
    flex-direction: column;
    width: 100%;
    background-color: var(--green);
    margin-top: 1em;
  }

  #menu-toggle:checked + .burger + .main-nav {
    display: flex;
  }

  nav a {
    padding: 1em;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
  }
}

/* Mobilvenlig layout (op til 768px bredde) */
@media (max-width: 768px) {
  header {
    flex-direction: column;
    align-items: flex-start;
    padding: 1em;
  }

  nav {
    display: flex;
    flex-direction: column;
    gap: 1em;
    margin-top: 1em;
  }

  .projekt-container,
  .projekt,
  .project-section .projekt.reverse {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .projekt .tekst,
  .projekt .billede {
    width: 100%;
    max-width: 90%;
  }

  .intro-text {
    padding: 2em 1em;
  }

  h1, h2 {
    font-size: 1.8rem;
  }

  .cta-knap {
    font-size: 0.9rem;
    padding: 0.5em 1em;
  }

  footer {
    font-size: 0.8rem;
    padding: 1.5em 1em;
  }
}

/* Burger-ikon */
.burger {
  display: none;
  font-size: 2rem;
  color: white;
  cursor: pointer;
}

/* Skjul checkbox */
#menu-toggle {
  display: none;
}

/* Desktop */
.main-nav {
  display: flex;
  gap: 1.5em;
}

/* Mobil */
@media (max-width: 768px) {
  .burger {
    display: block;
  }

  .main-nav {
    display: none;
    flex-direction: column;
    width: 100%;
    background-color: var(--green);
    margin-top: 1em;
  }

  #menu-toggle:checked + .burger + .main-nav {
    display: flex;
  }

  nav a {
    padding: 1em;
    border-top: 1px solid rgba(255, 255, 255, 0.2);
  }
}