/* Main Colors: */
/* #3D348B; */
/* #7678ED; */
/* #F7B801; */
/* #F18701; */
/* #F35804; */

/* #615d8a; */
/* #9c9dee; */
/* #f3de9f; */
/* #f1dda0; */
/* #f1bb9d; */

/* ---------- Grundlayout ---------- */
body {
  font-family: "Segoe UI", sans-serif;
  background: #fffcd0ff;
  margin: 0;
  padding: 0;
  /* color: #866239; */
  color: #615d8a;
}

/* ---------- Header ---------- */
header {
  text-align: center;
  background: transparent;
}

.layout {
  display: flex;
  align-items: flex-start;
  gap: 2rem; /* space between sidebars and main content */
  min-height: calc(100vh - 150px); /* fill viewport minus header height */
  padding: 2rem;
  box-sizing: border-box;
  max-width: 1600px;
  margin: 0 auto;
}

.header-banner {
  position: absolute;
  top: 0;
  left: 0;
  right: 0;
  height: 1000px;
  z-index: -1;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  pointer-events: none;
}



main {
  flex: 1;
  max-width: 900px; /* your desired page width */
  min-width: 0; /* allows flex item to shrink */
  padding: 1rem 2rem;
  box-sizing: border-box;
}

main section {
  max-width: 100%;
  width: 100%;
  margin: 2rem 0;           /* consistent vertical spacing */
  padding: 0;               /* remove inconsistent padding */
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth; /* enables smooth jump animation */
}

h1, h2, h3, h4, h5, h6 {
  scroll-margin-top: 20px; /* adjust for header */
}

/* ---------- Sidebar ---------- */
.sidebar {
  position: sticky;
  top: 20px;
  align-self: flex-start;
  box-shadow: 0 2px 5px #615d8a;
  padding: 1rem;
  width: 200px; /* fixed sidebar width */
  box-sizing: border-box;
  background-color: #fefefe;
  border-radius: 8px;
}

/* Left sidebar (Navigation) */
.sidebar--left {
  border-right: 1px solid #f1dda0;
}

/* Right sidebar (Table of Contents) */
.sidebar--right {
  border-left: 1px solid #f1dda0;
}

/* ---------- Left Navigation ---------- */
.left-nav ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.left-nav li {
  margin: 0;
  padding: 0;
}

.left-nav a {
  display: block;
  padding: 10px 12px;
  text-decoration: none;
  color: #615d8a;
  font-weight: bold;
  border-left: 3px solid transparent;
  transition: background-color 0.15s ease, color 0.15s ease, border-left-color 0.15s ease;
  border-radius: 4px;
  margin-bottom: 4px;
}

.left-nav a:hover,
.left-nav a:focus {
  background-color: #615d8a;
  color: #f1dda0;
  border-left-color: #f1dda0;
}

/* Active navigation link (current page) */
.left-nav a.active {
  border-left-color: #615d8a;
  background-color: #f1dda0;
  color: #615d8a;
}

/* Table of Contents (right sidebar) */
#toc {
  margin: 0;
  padding: 0;
  list-style: none;
}

#toc a {
  display: block;
  padding: 6px 8px;
  text-decoration: none;
  color: #615d8a;
  border-left: 3px solid transparent;
  transition: background-color 0.15s ease, color 0.15s ease;
}

#toc a:hover {
  background-color: #615d8a;
  color: #f1dda0;
}

#toc a.active {
  border-left-color: #615d8a;
  background-color: #f1dda0;
}

#toc li {
  margin: 0;
  padding: 0;
}

/* ---------- Hauptinhalte ---------- */
main {
  max-width: 900px;
  margin: 2em auto;
  padding: 1em;
}

.intro,
.produkte,
.news,
.fortbildung {
  margin-bottom: 2em;
  /* background-color: #fffcd0ff; */
  border-radius: 12px;
}

/* ---------- Überschriften ---------- */
/* .intro h1,
.intro h2 {
  color: #855219;
} */

/* ---------- Produktkarten ---------- */
.produkt-grid {
  display: flex;
  gap: 2em;
  flex-wrap: wrap;
  justify-content: center;
}

.produkt-card {
  width: 250px;
  background-color: #fefefe;
  border-radius: 12px;
  padding: 1em;
  box-shadow: 0 0 8px rgba(0, 0, 0, 0.1);
  transition: transform 0.3s ease;
}

.produkt-bild {
  width: 100%;
  border-radius: 8px;
}

.add-to-cart {
  display: inline-block;
  margin-top: 0.5rem;
  padding: 0.4rem 0.8rem;
  background-color: #ebdb85;
  color: #855219;
  text-decoration: none;
  border-radius: 4px;
  transition: background-color 0.2s;
}

.add-to-cart:hover {
  background-color: #855219;
  color: #f3de9f;
}

/* ---------- Einzelprodukt (singe-product) ---------- */
.singe-product {
  max-width: 1100px;
  margin: 2rem auto;
  border-radius: 14px;
}

/* reuse produkt-grid but center content for a single product */
.singe-product .produkt-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
  gap: 1.5rem;
  width: 100%;
  padding: 0;
  box-sizing: border-box;
}

/* make the product card wider and horizontal for detail view */
.singe-product .produkt-card {
  width: 720px;
  display: flex;
  gap: 1.25rem;
  align-items: flex-start;
  padding: 1.25rem;
}

/* image becomes a fixed column on larger screens */
.singe-product .produkt-bild {
  width: 240px;
  height: 240px;
  object-fit: cover;
  flex: 0 0 240px;
  border-radius: 10px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.06);
}

/* content column */
.singe-product .produkt-card > div,
.singe-product .produkt-card > h4,
.singe-product .produkt-card > p,
.singe-product .produkt-card > strong {
  flex: 1 1 auto;
}

/* headings and description */
.singe-product .produkt-card h4 {
  margin: 0 0 0.5rem 0;
  color: #855219;
  font-size: 1.2rem;
}

.singe-product .produkt-card p {
  margin: 0 0 1rem 0;
  color: #f3de9f;
  line-height: 1.4;
}

/* price styling */
.singe-product .produkt-card strong {
  display: inline-block;
  font-size: 1.1rem;
  white-space: nowrap; /* prevent line break */
  color: #f3de9f;
  padding: 0.35rem 0.6rem;
  border-radius: 6px;
}

/* responsive: stack card vertically on small screens */
@media (max-width: 760px) {
  .singe-product .produkt-card {
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .singe-product .produkt-bild {
    width: 100%;
    height: auto;
    flex: none;
  }

  .singe-product .produkt-card > h4,
  .singe-product .produkt-card > p,
  .singe-product .produkt-card > strong {
    width: 100%;
  }
}


/* ---------- Buttons ---------- */
button {
  border-radius: 8px;
  padding: 0.5em 1em;
  background-color: #ffcc80;
  border: none;
  cursor: pointer;
  transition: background-color 0.3s ease;
}

button:hover {
  background-color: #f3de9f;
}

/* ---------- Footer ---------- */
footer {
  text-align: center;
  background: transparent;
  padding: 1em 1em;
  font-size: 0.9rem;
  color: #615d8a;
}

footer a {
  color: #615d8a;
  text-decoration: none;
}

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


/* ---------- Post Footer Banner ---------- */
.post-footer-banner {
  position: relative;
  width: 100vw;
  left: 50%;
  transform: translateX(-50%);
  margin: 0;
  overflow: hidden;
}

.post-footer-banner img {
  display: block;
  width: 100%;
  height: auto;
  object-fit: cover;
}

/* ---------- Responsive Design ---------- */
@media (max-width: 1200px) {
  .layout {
    gap: 1rem;
    padding: 1rem;
  }
  
  .sidebar {
    width: 180px;
  }
  
  main {
    padding: 1rem;
  }
}

@media (max-width: 900px) {
  .layout {
    flex-direction: column;
  }
  
  .sidebar {
    position: relative;
    top: 0;
    width: 100%;
    margin-bottom: 1rem;
  }
  
  .sidebar--left {
    order: -1; /* Navigation appears first on mobile */
  }
  
  .left-nav ul {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
  }
  
  .left-nav a {
    margin-bottom: 0;
    padding: 8px 12px;
  }
  
  main {
    max-width: 100%;
  }
}