/* **********************************************
        REST
********************************************** */

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

table {
  border-collapse: collapse;
  border-spacing: 0;
}

/* **********************************************
        GENERAL
********************************************** */

/* *** COLOURVAR *** */

:root {
  --primary-color: #39755c;
  --secondery-color: #2a9669;
  --tertiary-color: #262626;
  --background-box: rgba(0, 0, 0, 0.75);
  --background-one-color: #22533f;
  --text-color: #ffffff;
}

@font-face {
  font-family: "SourceSans3";
  src: url("../fonts/Source_Sans_3/SourceSans3-VariableFont_wght.ttf")
    format("truetype");
  font-display: swap;
  font-style: normal;
}

@font-face {
  font-family: "SourceSans3-italic";
  src: url("../fonts/Source_Sans_3/SourceSans3-Italic-VariableFont_wght.ttf")
    format("truetype");
  font-display: swap;
  font-style: italic;
}

@font-face {
  font-family: "OldStandardTT";
  src: url("../fonts/Old_Standard_TT/OldStandardTT-Regular.ttf")
    format("truetype");
  font-display: swap;
  font-style: normal;
}

html {
  font-family: "SourceSans3", sans-serif;
  scroll-behavior: smooth;
  background-color: var(--tertiary-color);
}

body {
  min-height: 100vh;
  min-height: 100dvh;
  max-width: 1200px;
  box-shadow: 0px 0px 10px var(--background-box);
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr;
  grid-template-rows: auto 1fr;
  grid-template-areas:
    "navbar"
    "main";
}

h1,
h2,
h3,
h4 {
  font-family: "OldStandardTT", "Times New Roman", Times, serif;
}

i,
em {
  font-style: italic;
}

/* **********************************************
        NAVIGATION
********************************************** */

nav {
  background-color: var(--tertiary-color);
  position: sticky;
  top: 0;
  box-shadow: 0px 0px 20px var(--background-box);
  z-index: 10;
}

nav ul {
  list-style: none;
  display: flex;
}

nav li {
  display: flex;
}

nav .home-li {
  margin-right: auto;
}

nav .home-li img {
  padding: 0;
}

nav a {
  display: flex;
  text-decoration: none;
  color: var(--text-color);
  padding: 0.7em 1em;
  transition: background-color 0.4s ease;
}

nav a:hover {
  background-color: var(--secondery-color);
  transition: background-color 0.5s ease;
}

nav a.active-link {
  background-color: var(--secondery-color);
}

#open-sidebar-button {
  position: fixed;
  top: 0;
  right: 0;
  display: none;
  border: none;
  padding: 1em;
  margin-left: auto;
  cursor: pointer;
  z-index: 10;
  background-color: var(--background-box);
  border-radius: 0 0 0 8px;
}

#close-sidebar-button {
  display: none;
  background: none;
  border: none;
  padding: 1em;
  cursor: pointer;
}

#overlay {
  position: fixed;
  inset: 0;
  background-color: var(--background-box);
  z-index: 9;
  display: none;
}

/* for accessibility to skip menu */
.skip-link {
  opacity: 0;
  pointer-events: none;
  position: absolute;
  top: 10px;
  left: 10px;
  z-index: 1000;
  background-color: var(--tertiary-color);
  color: var(--text-color);
  transition: opacity 0.3s ease;
  padding: 1em;
  border-radius: 8px;
  text-decoration: none;
}
.skip-link:focus {
  opacity: 1;
  pointer-events: auto;
  outline: 2px solid white;
}

@media screen and (max-width: 760px) {
  nav {
    position: fixed;
    top: 0;
    right: -100%;
    height: 100vh;
    width: min(15em, 100%);
    z-index: 10;
    transition: right 300ms ease-out;
  }
  nav.show {
    right: 0;
  }

  nav.show ~ #overlay {
    display: block;
  }
  nav ul {
    width: 100%;
    flex-direction: column;
  }
  nav a {
    width: 100%;
    padding-left: 2.5em;
  }
  nav a.active-link {
    border-bottom: none;
  }
  nav .home-li {
    margin-right: unset;
  }
  #open-sidebar-button,
  #close-sidebar-button {
    display: block;
  }
}

/* **********************************************
        MAIN
********************************************** */

main {
  grid-area: main;
}

section {
  padding: 5em 0;
  border-bottom: 1px solid var(--text-color);
}

/* **********************************************
        HINTERGRUND
********************************************** */

/* Hintergrund für die Abschnitte */

#willkommen {
  position: relative;
  overflow: hidden;
  background-color: var(--tertiary-color);
  height: 1000px;
  width: auto;
  @media (min-width: 413px) and (max-width: 760px) {
    height: 630px;
  }
  @media (max-width: 412px) {
    height: 430px;
  }
}

#austellungen,
#impressum {
  position: relative;
  overflow: hidden;
  background-color: var(--tertiary-color);
}

/* Full-bleed cover image (same file as preload for #willkommen). */
#willkommen .cover-bg,
#austellungen .cover-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: center;
  z-index: 0;
  pointer-events: none;
}
#impressum .cover-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: bottom;
  z-index: 0;
  pointer-events: none;
}

#willkommen > *:not(.cover-bg),
#austellungen > *:not(.cover-bg),
#impressum > *:not(.cover-bg) {
  position: relative;
  z-index: 1;
}

#buecher {
  background-color: var(--background-one-color);
}

.backgroundBox {
  background-color: var(--background-box);
  padding-top: 1em;
  padding-bottom: 1em;
  margin: 0 auto;
  box-shadow: 3px 3px 15px var(--background-box);
}

/* **********************************************
        HEADINGS, PARAGRAPHS and more
********************************************** */

h1 {
  font-size: clamp(1.2rem, calc(5vw + 1rem), 4rem);
  text-align: center;
  color: var(--text-color);
  margin-top: 2em;
}

#homePage h1 {
  text-shadow:
    3px 3px 15px #000000,
    -3px 3px 15px #000000;
}

.buecher h1,
.galerie h1 {
  margin-top: 1em;
  margin-bottom: 0.5em;
}

h2 {
  color: var(--text-color);
  text-align: center;
  text-transform: uppercase;
  letter-spacing: 3px;
}

h2.untertitel {
  font-size: clamp(1.2rem, calc(3vw + 1rem), 2rem);
  text-shadow:
    3px 3px 15px #000000,
    -3px 3px 15px #000000;
}

h2.h2StartSeite {
  font-size: clamp(1.2rem, calc(5vw + 1rem), 4rem);
  margin-bottom: 0.6em;
}

h2.h2Shadow {
  text-shadow:
    3px 3px 15px #000000,
    -3px 3px 15px #000000;
}

h3 {
  font-size: 1.4rem;
  color: var(--secondery-color);
  margin-bottom: 0.5em;
  text-transform: lowercase;
}

#buecher h3 {
  color: var(--text-color);
  margin-top: 0.4em;
  margin-bottom: 0.4em;
}

.h3SpaceAbove {
  margin-top: 1.2em;
}

h4 {
  font-size: 1.4rem;
  color: var(--text-color);
}

p,
li {
  font-size: 1.1rem;
  color: var(--text-color);
  line-height: 1.3;
  hyphens: auto;
}

nav li {
  font-size: 0.95rem;
}

th,
td,
.tableYear,
.tableExhibition {
  font-size: 1.1rem;
  color: var(--text-color);
  line-height: 1.3;
}

/* **********************************************
        TABLE
********************************************** */

.standardTable {
  color: var(--text-color);
}

.standardTable th {
  padding: 0.3em 0.7em 0.3em 0.3em;
  font-weight: bold;
  text-align: right;
  vertical-align: top;
  text-wrap-mode: nowrap;
}

.standardTable td {
  padding-top: 0.3em;
  padding-bottom: 0.3em;
  vertical-align: top;
}

/* **********************************************
        VITA 
********************************************** */

.vitaGrid {
  display: flex;
  flex-wrap: wrap;
  gap: 2em;
  justify-content: center;
  margin-left: min(4%, 1em);
  margin-right: min(4%, 1em);
}
.vitaItem {
  max-width: 30em;
}

#vita p {
  margin-top: 0.5em;
}

.vitaOverview {
  margin-bottom: 1em;
}

.vitaOverview,
.vitaPressestimmen {
  padding-top: 0.45em;
}

.vitaItem:last-child p {
  padding-bottom: 0.6em;
  border-bottom: 1px solid white;
}

/* **********************************************
        AUSTELLUNGEN
********************************************** */

.austellungenTable {
  background-color: var(--background-box);
  padding: 1.5em 1em;
  columns: 1;
  gap: 2em;
  margin: 0;
}
.austellungenTable div {
  max-width: 400px;
  margin: 0 auto;
  padding-bottom: 0.2em;
}

@media (min-width: 480px) {
  .austellungenTable {
    background-color: var(--background-box);
    padding: 2em;
  }
}

@media (min-width: 768px) {
  .austellungenTable {
    max-width: 1000px;
    columns: 2;
    margin: 0 auto;
  }
}

.austellungenTable > div {
  display: flex;
  gap: 1.2em;
}

.austellungenTable .tableYear {
  font-weight: bold;
}

.austellungenTable .tableExhibition {
  flex: 1;
}

/* **********************************************
        ARBEITEN 
********************************************** */

.arbeitenGrid {
  display: grid;
  grid-template-columns: repeat(auto-fit, 300px);
  /* grid-auto-rows: 300px; */
  gap: 1em;
  justify-content: center;
}

.arbeitenItem {
  text-decoration: none;
  border-radius: 5px;
  overflow: hidden;
  background-color: var(--primary-color);
  box-shadow: 3px 3px 15px #000000b4;
  display: grid;
  grid-template-areas: "stack";
  place-items: end stretch;
  transition: transform 0.3s ease;
}
.arbeitenItem span {
  color: var(--text-color);
  
  font-size: 1.2rem;
  text-align: center;
  padding: 0.5em 0;
}

.arbeitenItem img {
  display: block;
  grid-column: 1 / 2;
  grid-row: 1 / 2;
}
.arbeitenItem:hover {
  background-color: var(--secondery-color);
  transform: scale(1.03);
  transition: transform 0.3s ease;
  border: 1px solid var(--tertiary-color);
}

/* Sub-Galerie */

.galerie-image-grid {
  display: grid;
  max-width: 600px;
  grid-template-columns: 1fr;
  gap: 3em;
  margin: 1em auto 2em auto;
  padding: 0 2em;
}

.galerie-images {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: flex-start;
}

.galerie-images img {
  width: 100%;
  box-shadow: 3px 3px 15px #000000b4;
}

/* **********************************************
        BUECHER
********************************************** */

.buchGrid {
  display: grid;
  grid-template-columns: auto;
  gap: 1.3em;
  justify-content: center;
  margin-left: min(4%, 1em);
  margin-right: min(4%, 1em);
}

.buchItem {
  display: grid;
  grid-template-columns: auto 230px 1fr;
  gap: 2.6em;
  padding: 2em;
  max-width: 1100px;

  @media (max-width: 1100px) {
    grid-template-columns: 1fr;
    grid-template-rows: 3;
    text-align: center;
  }
}
.buchItem:not(:last-child) {
  padding-bottom: 2.8em;
  border-bottom: 1px solid white;
}

.buchtext {
  text-align: left;
}

.buchSubItem:last-child p + p {
  margin-top: 0.4rem;
}

.buchSubItem img {
  width: 220px;
  box-shadow: 3px 3px 15px #000000b4;
}

/* **********************************************
        AKTUELLES
********************************************** */

.aktuelles {
  text-align: center;
  margin-top: 2em;
  @media (max-width: 840px) {
    margin-top: 1em;
  }
}

.aktuelles p {
  font-weight: bold;
}

.aktuelles img {
  max-height: 400px;
  box-shadow:
    3px 3px 15px #000000,
    -3px 3px 15px #000000;
  border: 1px solid #00000027;
  transition: transform 0.3s ease;
  margin-bottom: 1em;

  @media (max-width: 840px) {
    max-height: 330px;
  }
}

/* **********************************************
        IMPRESSUM
********************************************** */

.impressumGrid {
  width: min(90%, 660px);
  margin: auto;
  padding: 1em 1em;
}

.impressumGrid p ~ p {
  margin-top: 0.6rem;
}

.email {
  margin-top: 0.3em;
  margin-bottom: 1em;
}

.weblink {
  text-decoration: none;
  color: var(--primary-color);
}
