@font-face {
  font-family: 'cabinet_grotesk';
  src: url('../font/CabinetGrotesk_Complete/Fonts/TTF/CabinetGrotesk-Variable.ttf') format('truetype');
}

@font-face {
  font-family: 'Montserrat';
  src: url('../font/Montserrat/Montserrat-VariableFont_wght.ttf') format('truetype');
}

/* Hide scrollbar for Chrome, Safari, Opera */
html::-webkit-scrollbar,
body::-webkit-scrollbar {
  display: none;
}

/* Hide scrollbar for IE, Edge, Firefox */
html,
body {
  -ms-overflow-style: none;
  /* IE/Edge */
  scrollbar-width: none;
  /* Firefox */
}


body {
  font-family: 'Montserrat', sans-serif;
  font-weight: 300;
  line-height: 1.3;
  display: flex;
  flex-direction: column;
  min-height: 100dvh;
  margin: 0;
  outline: 1px solid black;
  width: 99%;
  margin: 10px auto;
}

html {
  background: #FFFFE4;
  width: 100%;
}

::selection {
  background: #orange;
}

a {
  font-family: 'Montserrat', sans-serif;
  font-weight: 500;
  text-decoration: none;
  color: orange;
}

a:hover {
  text-decoration: underline;
  text-decoration: underline wavy;
}

.block-link {
  text-decoration: none;
  color: inherit;
  display: block;
}

.block-link:hover {
  text-decoration: none;
  cursor: pointer;
}

header {
  padding: 2vh 5vw;
  border-bottom: 1px solid black;
}

footer {
  padding: 2vh 5vw;
}

header {
  display: grid;
  grid-template-columns: 1fr auto 1fr;
  align-items: center;
  box-sizing: border-box;
}

.header_left nav {
  display: flex;
  align-items: center;
}

.header_left nav>a,
.header_left nav>.dropdown>a {
  padding: 6px 10px;
  text-decoration: none;
}

.header_left nav>a.selected .header_left nav>.dropdown-menu>a.selected {
  border: none;
  border: 1px solid black;
  background-color: #dbdbc5;
}

.header_center h1 {
  font-family: cabinet_grotesk;
  font-weight: 500;
}

.dropdown {
  position: relative;
}

.dropdown-menu {
  display: none;
  position: absolute;
  top: 100%;
  left: 0;
  flex-direction: column;
  background: #FFFFE4;
  border: 1px solid black;
  padding: 0;
}

.dropdown-menu a {
  padding: 6px 10px;
  white-space: nowrap;
  text-decoration: none;
  display: block;
}

.dropdown-menu a.selected {
  background-color: #dbdbc5;
  border: none;
  border-bottom: 1px solid black;
}

.dropdown-menu a:not(:last-child) {
  border-bottom: 1px solid black;
}

.dropdown-menu a:hover {
  background: #dbdbc5;
}

.dropdown:hover .dropdown-menu {
  display: flex;
}

.header_center {
  text-align: center;
}

.header_right {
  display: flex;
  justify-content: flex-end;
  align-items: center;
}

.selected {
  border: 1px solid black;
}

.button {
  padding: 5px 10px;
  background-color: #fccf7b;
  color: black;
  font-weight: bold;
  border: 1px solid gray;
  cursor: pointer;
  transition: background-color 0.2s, border-color 0.2s;
}

.button:hover {
  background-color: #c6a25f;
  border-color: black;
}

main {
  width: 100%;
  flex: 1;
  display: flex;
  flex-direction: column;
  text-align: center;
}

main>* {
  flex: 1;
}

.section {
  width: 100%;
  display: flex;
  padding: 5vh 5vw;
  border-bottom: 1px solid black;
}

.section_horizontal {
  flex: 1;
  display: flex;
  align-items: top;
  justify-content: space-between;
  gap: 20px;
  text-align: left;
}

.section_horizontal {
  font-size: 1.2rem;
}

.section_horizontal h1 {
  padding-top: 5vh;
  padding-bottom: 20px;
}

.section_vertical {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: left;
  text-align: left;
  gap: 2px;
  font-size: 1.2rem;
}

.section_vertical h2 {
  padding-bottom: 20px;
}

.section_vertical h3 {
  font-weight: 400;
  font-size: 1.2rem;
}

.section_welcome {
  display: flex;
  flex-direction: column;
  gap: 20px;
  min-height: 30dvh;
}

.section_welcome h1 {
  font-size: 2.8rem;
  padding-bottom: 20px;
  padding-top: 5vh;
}

.section_welcome p {
  font-size: 1.6rem;
}

.section_welcome a {
  font-size: 1.2rem
}

.small_img {
  width: 1.5em;
  height: 1.5em;
}

.medium_img {
  width: 30%;
  height: auto;
  max-width: 100%;
  object-fit: contain;
}

.big_img {
  width: 50%;
  height: auto;
  max-width: 100%;
  object-fit: contain;
}

.about_img {
  width: 30%;
  height: auto;
  max-width: 100%;
  object-fit: contain;
  border-radius: 2%;
}

.img_row {
  padding-top: 10px;
  display: flex;
  flex-direction: row;
  justify-items: left;
  align-items: bottom;
  gap: 10px;
  overflow-x: auto;
  scroll-behavior: smooth;
  -webkit-overflow-scrolling: touch;
}

.img_row img {
  flex: 0 0 auto;
  height: 300px;
  object-fit: contain;
}

.subtitle {
  font-weight: bold;
  text-decoration: underline;
  cursor: pointer;
  text-align: left;
  list-style: none;
  display: flex;
  align-items: center;
  gap: 0.5em;
  line-height: 1.5em;
  padding-top: 20px;
}

.projects .subtitle {
  font-weight: 350;
}

.indent {
  padding-left: 1em;
}

.intent p summary {
  text-indent: 1em;
}

details summary+p {
  margin-top: 0.5em;
}

details summary {
  font-weight: bold;
  text-decoration: underline;
  cursor: pointer;
  list-style: none;
  position: relative;
  padding-right: 1.2em;
}

details summary::-webkit-details-marker {
  display: none;
}

details summary::after {
  content: "";
  border: solid black;
  border-width: 0 2px 2px 0;
  display: inline-block;
  padding: 4px;
  position: absolute;
  right: 0.3em;
  top: 50%;
  transform: translateY(-50%) rotate(45deg);
  transition: transform 0.2s ease;
}

details[open] summary::after {
  transform: translateY(-50%) rotate(-135deg);
}

.offer .title {
  align-items: center;
}

.offer {
  display: flex;
  flex-direction: column;
  align-items: top;
  gap: 10px;
}

.offer img {
  width: auto;
  height: 50vh;
  max-height: 50%;
  object-fit: contain;
}

footer {
  width: 100%;
  display: flex;
  justify-content: space-between;
  align-items: center;
  box-sizing: border-box;
  padding: 0;
}

.footer_left {
  display: flex;
  padding: 1vh 5vw;
}

.footer_left>* {
  padding: 6px 10px;
}

.footer_right {
  display: flex;
  padding: 1vh 5vw;
}

.menu-btn {
  display: none;
}

/* Popup overlay */
.popup {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  justify-content: center;
  align-items: center;
  z-index: 1200;
}

.popup:target {
  display: flex;
}

.popup-content {
  background: #FFFFE4;
  padding: 30px;
  border-radius: 12px;
  width: 400px;
  max-width: 90%;
  height: auto;
  position: relative;
  box-shadow: 0 8px 25px rgba(0, 0, 0, 0.3);
  text-align: left;
  display: flex;
  flex-direction: column;
  gap: 20px;
  font-family: Arial, sans-serif;
}

.popup-info {
  display: flex;
  flex-direction: column;
  gap: 10px;
  align-items: flex-start;
}

.popup-info .caption {
  padding-bottom: 10px;
}

.contact_img {
  width: 150px;
  height: 150px;
  object-fit: cover;
  border-radius: 50%;
  margin-bottom: 10px;
}

.close {
  position: absolute;
  top: 10px;
  right: 15px;
  text-decoration: none;
  font-size: 20px;
  color: #333;
}

a.close:hover {
  text-decoration: none;
}

.accent {
  font-size: 1.4rem;
}

.accent-padding {
  padding-top: 5vh;
  font-size: 1.4rem;
}

.impressum {
  gap: 20px;
}

.mobile-menu,
.mobile-menu-overlay,
.mobile {
  display: none;
}

.mobile-view {
  display: none;
}

@media screen and (max-width: 1000px) {
  .section {
    padding: 1vh 5vw;
    flex-direction: column;
  }

  .section_horizontal {
    flex-direction: column;
    gap: 20px;
    justify-content: center;
  }

  .section_horizontal img {
    align-self: center;
  }

  .mobile-reverse {
    flex-direction: column-reverse;
  }

  .mobile-reverse img {
    padding-top: 5vh;
  }

  .section_welcome:last-of-type {
    padding-bottom: 5vh;
  }

  .section_horizontal img.big_img {
    max-width: 100%;
    height: auto;
  }

  .section_horizontal img.medium_img {
    max-width: 100%;
    height: auto;
    min-width: 40%;
  }

  .section_vertical,
  .offer {
    gap: 15px;
  }

  .section_vertical img,
  .offer img {
    max-width: 80%;
    height: auto;
  }

  .offer img {
    height: 20vh;
  }

}

@media screen and (max-width: 850px) {
  body {
    outline: none;
    font-size: 0.9rem;
  }

  main {
    gap: 20px;
    /* optional spacing between sections */
  }

  header,
  footer {
    grid-template-columns: 1fr;
    text-align: center;
  }

  footer {
    margin-bottom: 10px;
  }

  .footer_left>a {
    padding: 0;
  }

  /* compact offers row */
  .offers_row .title {
    display: flex;
    justify-content: space-between;
  }

  .offer img p {
    display: hidden;
  }

  .desktop-view {
    display: none;
  }

  .mobile-view {
    display: block;
  }

  .mobile-view img {
    width: 1.5em;
    height: 1.5em;
  }

  .offers_row .offer:last-child {
    padding-bottom: 5vh;
  }

  details[open]>*:not(summary) {
    padding-left: 1em;
  }

  .horizontal {
    display: flex;
    flex-direction: row;
  }

  header {
    display: flex;
    flex-direction: row;
    align-items: bottom;
    gap: 0;
    justify-content: space-between;
  }

  .header_right {
    display: none;
  }

  .header_center {
    margin-top: 20px;
    text-align: center;
  }

  .header_center h1 {
    font-size: 1.6rem;
  }

  footer,
  header,
  nav,
  .mobile-menu nav a {
    font-size: 0.9rem;
  }

  footer {
    align-items: flex-start;
  }

  .footer_left {
    flex-direction: column;
    text-align: left;
  }

  .footer_left>a {
    padding-bottom: 1vh;
  }

  .about_img {
    width: 50vw;
  }

  .section_horizontal,
  .section_vertical {
    font-size: 1rem;
  }

  .section_welcome h1 {
    font-size: 2rem;
  }

  .section_welcome p {
    font-size: 1.2rem;
  }

  .section_welcome a {
    font-size: 1rem;
  }

  .accent,
  .accent_padding {
    font-size: 1.1rem;
  }

  .mobile {
    display: flex;
  }

  .mobile-menu nav {
    display: flex;
    flex-direction: column;
    gap: 10px;
  }

  .mobile-menu nav a {
    padding: 6px 10px;
    text-decoration: none;
    color: black;
    display: block;
    border: 1px solid black;
  }

  .mobile-menu nav a:hover {
    background: #dbdbc5;
  }

  .mobile-menu,
  .mobile-menu-overlay {
    display: none;
  }

  .mobile-menu.active,
  .mobile-menu-overlay.active {
    display: flex;
  }

  .mobile-menu.active {
    flex-direction: column;
    gap: 10px;
  }

  .mobile-menu nav {
    display: flex;
    flex-direction: row;
    gap: 10px;
  }

  .menu-btn {
    display: block;
    position: relative;
    z-index: 1000;
    padding: 5px 10px;
    background-color: #fccf7b;
    color: black;
    font-weight: bold;
    border: 1px solid gray;
    cursor: pointer;
    transition: background-color 0.2s, border-color 0.2s;
  }

  .mobile-menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    z-index: 999;
  }

  .mobile-menu {
    display: none;
    position: fixed;
    top: 15vh;
    left: 5%;
    right: 5%;
    background: #FFFFE4;
    border: 1px solid black;
    padding: 10px;
    z-index: 1000;
    flex-direction: column;
  }

  .mobile-menu.active,
  .mobile-menu-overlay.active {
    display: flex;
  }

  .mobile-menu.active {
    flex-direction: column;
    gap: 10px;
  }

  .mobile-menu nav {
    display: flex;
    flex-direction: column;
    gap: 10px;
  }

  .mobile-menu nav a {
    padding: 6px 10px;
    text-decoration: none;
    color: black;
    display: block;
    border: 1px solid black;
  }

  .mobile-menu nav a:hover {
    background: #dbdbc5;
  }

  /* hide desktop nav on mobile */
  .header_left {
    display: none;
  }

  .mobile-menu,
  .mobile-menu-overlay {
    transition: opacity 0.3s ease, transform 0.3s ease;
    opacity: 0;
    pointer-events: none;
  }

  .mobile-menu.active,
  .mobile-menu-overlay.active {
    opacity: 1;
    pointer-events: auto;
  }

  .mobile-menu {
    transform: translateY(-20px);
  }

  .mobile-menu.active {
    transform: translateY(0);
  }

}
