/* --- CSS RESET & BASES --- */
html, body, div, span, applet, object, iframe,
h1, h2, h3, h4, h5, h6, p, blockquote, pre,
a, abbr, acronym, address, big, cite, code,
del, dfn, em, img, ins, kbd, q, s, samp,
small, strike, strong, sub, sup, tt, var,
b, u, i, center,
dl, dt, dd, ol, ul, li,
fieldset, form, label, legend,
table, caption, tbody, tfoot, thead, tr, th, td,
article, aside, canvas, details, embed, 
figure, figcaption, footer, header, hgroup, 
menu, nav, output, ruby, section, summary,
time, mark, audio, video {
  margin: 0;
  padding: 0;
  border: 0;
  font-size: 100%;
  font: inherit;
  vertical-align: baseline;
  box-sizing: border-box;
}
article,aside,details,figcaption,figure,
footer,header,hgroup,menu,nav,section {
  display: block;
}
body {
  line-height: 1.5;
  background: #F7F8FA;
  color: #16344D;
  font-family: 'Open Sans', Arial, sans-serif;
  font-size: 16px;
  min-height: 100vh;
}
*, *::before, *::after {
  box-sizing: inherit;
}
a {
  color: #16344D;
  text-decoration: none;
  transition: color 0.2s;
}
img {
  max-width: 100%;
  height: auto;
  display: block;
}
input, button, select, textarea {
  font-family: inherit;
  font-size: inherit;
}
:focus {
  outline: 2px solid #EFC44A;
  outline-offset: 2px;
}

/* --- TYPOGRAPHY --- */
h1, h2, h3, h4, h5, h6 {
  font-family: 'Roboto Slab', serif;
  color: #16344D;
  font-weight: 700;
  letter-spacing: -0.01em;
  line-height: 1.15;
  margin-bottom: 16px;
}
h1 {
  font-size: 2.5rem;
  margin-bottom: 24px;
}
h2 {
  font-size: 2rem;
  margin-bottom: 20px;
}
h3 {
  font-size: 1.25rem;
  margin-bottom: 16px;
  font-weight: 600;
}
h4 {
  font-size: 1.1rem;
}
p, ul, ol, table {
  margin-bottom: 16px;
}
ul, ol {
  padding-left: 22px;
  font-size: 1rem;
}
strong { font-weight: 700; }

@media (max-width: 600px) {
  h1 { font-size: 2rem; }
  h2 { font-size: 1.4rem; }
  h3 { font-size: 1.1rem; }
}

/* --- COMMON LAYOUT CONTAINERS --- */
.container {
  width: 100%;
  max-width: 1150px;
  margin: 0 auto;
  padding: 0 20px;
}
.content-wrapper {
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.section {
  margin-bottom: 60px;
  padding: 40px 20px;
  background: #fff;
  border-radius: 20px;
  box-shadow: 0 2px 10px rgba(22,52,77,0.06);
}
@media (max-width: 900px) {
  .section {
    margin-bottom: 40px;
    padding: 28px 8px;
  }
}

.text-section {
  max-width: 700px;
}

/* ---- FLEX PATTERNS ---- */
.card-container {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
}
.card {
  margin-bottom: 20px;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 2px 12px rgba(22,52,77,0.07);
  padding: 28px 24px;
  position: relative;
  display: flex;
  flex-direction: column;
  transition: box-shadow 0.2s, transform 0.22s;
}
.card:hover {
  box-shadow: 0 6px 28px rgba(22,52,77,0.14);
  transform: translateY(-3px) scale(1.01);
}
.content-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
  justify-content: space-between;
}
.text-image-section {
  display: flex;
  align-items: center;
  gap: 30px;
  flex-wrap: wrap;
}
@media (max-width: 768px) {
  .text-image-section {
    flex-direction: column;
    gap: 18px;
  }
  .content-grid {
    flex-direction: column;
    gap: 18px;
  }
  .card-container {
    flex-direction: column;
    gap: 16px;
  }
}
.testimonial-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 20px;
  padding: 20px;
  background: #F7F8FA;
  border-radius: 16px;
  box-shadow: 0 2px 10px rgba(22,52,77,0.04);
  margin-bottom: 24px;
  border-left: 6px solid #EFC44A;
  transition: box-shadow 0.22s, transform 0.18s;
}
.testimonial-card p {
  font-size: 1.1rem;
  color: #16344D;
  margin-bottom: 2px;
}
.testimonial-card span {
  font-size: 0.96rem;
  color: #16344D;
  opacity: 0.87;
}

.feature-item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 15px;
  margin-bottom: 20px;
}

/* --- FEATURE GRID (SERVICES, KOMPETENZEN) --- */
.feature-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
  margin-top: 18px;
}
.feature-grid > div {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 2px 10px rgba(22,52,77,0.07);
  padding: 28px 20px;
  flex: 1 1 250px;
  min-width: 220px;
  max-width: 340px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  transition: box-shadow 0.18s, transform 0.15s;
}
.feature-grid > div:hover {
  box-shadow: 0 6px 28px rgba(22,52,77,0.13);
  transform: translateY(-3px) scale(1.01);
}
.feature-grid img {
  width: 38px;
  height: 38px;
  margin-bottom: 8px;
}
.feature-grid h3 {
  font-size: 1.12rem;
  margin-bottom: 10px;
}
.feature-grid p {
  font-size: 1rem;
  color: #16344D;
  margin-bottom: 0;
}
.feature-grid div > a {
  margin-top: 12px;
  align-self: flex-start;
  font-weight: 600;
  text-decoration: underline;
  color: #16344D;
  transition: color 0.2s;
}
.feature-grid div > a:hover {
  color: #EFC44A;
}

@media (max-width: 800px) {
  .feature-grid {
    flex-direction: column;
    gap: 16px;
  }
  .feature-grid > div {
    max-width: 100%;
  }
}

/* --- HERO & GRADIENT BACKGROUNDS --- */
section:first-of-type, .hero,
.header-bg {
  background: linear-gradient(100deg, #16344D 40%, #26719C 100%);
  color: #fff;
  border-radius: 0 0 32px 32px;
  box-shadow: 0 4px 28px rgba(22,52,77,0.13);
  margin-bottom: 60px;
  padding: 60px 0 54px 0;
}
section:first-of-type h1, section:first-of-type p, section:first-of-type .cta, section:first-of-type h2, section:first-of-type a {
  color: #fff;
}
@media (max-width: 600px) {
  section:first-of-type, .hero, .header-bg {
    border-radius: 0 0 18px 18px;
    padding: 34px 0 30px 0;
  }
}

/* --- BUTTONS & CTA --- */
.cta, .feature-grid a, button, .btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 28px;
  background: linear-gradient(94deg, #EFC44A 10%, #FFD85E 100%);
  color: #16344D;
  border-radius: 28px;
  font-weight: 700;
  font-size: 1.05rem;
  border: none;
  cursor: pointer;
  box-shadow: 0 2px 12px rgba(239,196,74,0.13);
  transition: background 0.19s, color 0.18s, box-shadow 0.2s, transform 0.18s;
  text-decoration: none;
  margin-top: 14px;
}
.cta:hover, .feature-grid a:hover, button:hover, .btn:hover {
  background: linear-gradient(90deg, #FFD85E 20%, #EFC44A 90%);
  color: #16344D;
  box-shadow: 0 4px 20px rgba(239,196,74,0.20);
  transform: translateY(-2px) scale(1.01);
}

/* --- MAIN NAVIGATION --- */
header {
  background: #fff;
  box-shadow: 0 4px 20px rgba(22,52,77,0.08);
  padding: 0;
  position: relative;
  z-index: 20;
}
.main-nav {
  display: flex;
  align-items: center;
  gap: 20px;
  padding: 14px 0;
  justify-content: flex-start;
}
.main-nav a {
  font-size: 1.05rem;
  font-weight: 500;
  color: #16344D;
  transition: color 0.18s;
  line-height: 1.25;
  padding: 6px 14px;
  border-radius: 20px;
}
.main-nav a.cta {
  margin-left: 18px;
}
.main-nav a:hover, .main-nav a:focus {
  color: #EFC44A;
  background: rgba(239,196,74,0.08);
}
.main-nav img {
  width: 138px;
  margin-right: 10px;
  vertical-align: middle;
}

/* --- MOBILE NAVIGATION --- */
.mobile-menu-toggle {
  display: none;
  position: absolute;
  right: 20px;
  top: 18px;
  z-index: 30;
  background: none;
  border: none;
  font-size: 2.4rem;
  color: #16344D;
  padding: 2px 8px;
  cursor: pointer;
  transition: color 0.19s, transform 0.18s;
}
.mobile-menu-toggle:hover {
  color: #EFC44A;
  transform: scale(1.07);
}
.mobile-menu {
  position: fixed;
  top: 0;
  left: 0;
  height: 100vh;
  width: 100vw;
  background: rgba(22,52,77, 0.97);
  box-shadow: 0 0 44px rgba(22,52,77,0.15);
  z-index: 192;
  transform: translateX(-100%);
  transition: transform 0.32s cubic-bezier(.51,1.41,.64,1);
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: flex-start;
  padding-top: 56px;
  gap: 38px;
}
.mobile-menu.open {
  transform: translateX(0);
}
.mobile-menu-close {
  position: absolute;
  top: 20px;
  right: 20px;
  background: none;
  border: none;
  color: #EFC44A;
  font-size: 2.1rem;
  cursor: pointer;
  z-index: 400;
  padding: 3px 10px;
  transition: color 0.2s, transform 0.18s;
}
.mobile-menu-close:hover {
  color: #fff;
  transform: scale(1.1);
}
.mobile-nav {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 16px;
  margin-left: 36px;
}
.mobile-nav a {
  font-size: 1.25rem;
  color: #fff;
  padding: 11px 0 11px 2px;
  border-radius: 12px;
  font-weight: 600;
  transition: color 0.16s, background 0.16s;
}
.mobile-nav a:hover, .mobile-nav a:focus {
  color: #EFC44A;
  background: rgba(239,196,74,0.1);
}
@media (max-width: 1050px) {
  .main-nav {
    gap: 10px;
  }
}
@media (max-width: 900px) {
  .main-nav a {
    font-size: 0.98rem;
    padding: 5px 7px;
  }
  .main-nav img {
    width: 108px;
  }
}
@media (max-width: 800px) {
  .main-nav {
    flex-wrap: wrap;
    gap: 8px;
  }
  .main-nav a.cta {
    margin-left: 8px;
  }
}
@media (max-width: 750px) {
  .main-nav {
    display: none;
  }
  .mobile-menu-toggle {
    display: block;
  }
}
@media (min-width: 751px) {
  .mobile-menu {
    display: none !important;
  }
  .mobile-menu-toggle {
    display: none;
  }
}

/* --- TABLES --- */
table {
  border-collapse: collapse;
  width: 100%;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 1px 6px rgba(22,52,77,0.05);
  margin-bottom: 22px;
  overflow: hidden;
}
th, td {
  padding: 16px 12px;
  text-align: left;
  font-size: 1rem;
  border-bottom: 1px solid #EEF0F2;
}
thead th {
  background: #16344D;
  color: #fff;
  font-weight: 700;
  font-size: 1.05rem;
}
tbody tr:last-child td {
  border-bottom: none;
}
@media (max-width: 600px) {
  table, thead, tbody, th, td, tr {
    display: block;
  }
  thead tr {
    display: none;
  }
  td {
    padding: 10px 6px;
    position: relative;
    border-bottom: 1px solid #EEF0F2;
    font-size: 0.97rem;
  }
}

/* --- TIMELINE (ablauf.html) --- */
.timeline {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  align-items: center;
  margin: 18px 0 10px 0;
  font-size: 1.08rem;
  color: #16344D;
}
.timeline div {
  background: #EFC44A;
  color: #16344D;
  border-radius: 14px;
  padding: 5px 14px;
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(239,196,74,0.09);
}
@media (max-width: 650px) {
  .timeline {
    flex-direction: column;
    gap: 8px;
    align-items: flex-start;
  }
}

/* --- MAP SNIPPET (kontakt.html) --- */
.map-snippet {
  background: #16344D;
  color: #fff;
  border-radius: 14px;
  padding: 18px 16px;
  margin-top: 18px;
  font-size: 1rem;
  box-shadow: 0 1px 8px rgba(22,52,77,0.08);
}

/* --- FOOTER --- */
footer {
  background: #16344D;
  color: #fff;
  margin-top: 64px;
  padding: 0 0 0 0;
  letter-spacing: 0;
}
footer .container {
  padding: 0 20px;
}
footer .content-wrapper {
  display: flex;
  flex-wrap: wrap;
  flex-direction: row;
  align-items: flex-start;
  justify-content: space-between;
  gap: 32px;
  padding: 38px 0 16px 0;
}
footer img {
  width: 98px;
  margin-bottom: 12px;
}
footer p, footer a {
  color: #fff;
  font-size: 1rem;
  opacity: 0.94;
}
.footer-nav {
  display: flex;
  flex-direction: column;
  gap: 10px;
}
.footer-nav a {
  color: #EFC44A;
  text-decoration: underline;
  font-weight: 500;
  opacity: 0.9;
  transition: color 0.17s;
}
.footer-nav a:hover {
  color: #fff;
}
@media (max-width: 800px) {
  footer .content-wrapper {
    flex-direction: column;
    gap: 14px;
    align-items: flex-start;
  }
}

/* --- COOKIE CONSENT BANNER --- */
.cookie-banner {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  background: #16344D;
  color: #fff;
  padding: 24px 16px;
  display: flex;
  align-items: flex-start;
  flex-wrap: wrap;
  gap: 18px;
  box-shadow: 0 -2px 26px rgba(22,52,77,0.13);
  z-index: 9999;
  font-size: 1rem;
  font-family: 'Open Sans', Arial, sans-serif;
  transition: transform 0.35s, opacity 0.25s;
}
.cookie-banner.hide {
  opacity: 0;
  pointer-events: none;
  transform: translateY(100%);
}
.cookie-banner .cookie-text {
  flex: 1 1 230px;
  min-width: 160px;
  max-width: 540px;
}
.cookie-banner .cookie-actions {
  display: flex;
  flex-direction: row;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
}
.cookie-banner button {
  font-size: 1rem;
  padding: 10px 22px;
  border-radius: 28px;
  margin: 0;
  background: #EFC44A;
  color: #16344D;
  border: none;
  cursor: pointer;
  font-weight: 700;
  transition: background 0.17s, color 0.16s;
}
.cookie-banner button:hover {
  background: #FFD85E;
}
.cookie-banner .cookie-settings-btn {
  background: #fff;
  color: #16344D;
  border: 1.5px solid #EFC44A;
}
.cookie-banner .cookie-settings-btn:hover {
  background: #F7F8FA;
  color: #16344D;
}

@media (max-width: 600px) {
  .cookie-banner {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
    padding: 18px 6px;
    font-size: 0.97rem;
  }
  .cookie-banner .cookie-actions {
    flex-direction: column;
    gap: 10px;
  }
}

/* --- COOKIE PREFERENCES MODAL --- */
.cookie-modal {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(22,52,77, 0.78);
  z-index: 10001;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 1;
  pointer-events: auto;
  transition: opacity 0.32s;
}
.cookie-modal.hide {
  opacity: 0;
  pointer-events: none;
}
.cookie-modal-content {
  background: #fff;
  color: #16344D;
  border-radius: 18px;
  padding: 34px 30px 24px 30px;
  max-width: 460px;
  width: 95%;
  box-shadow: 0 6px 28px rgba(22,52,77,0.13);
  display: flex;
  flex-direction: column;
  gap: 20px;
  position: relative;
}
.cookie-modal-content h3 {
  font-size: 1.35rem;
  margin-bottom: 12px;
  color: #16344D;
}
.cookie-modal-content ul {
  list-style: none;
  padding: 0;
  margin: 0 0 8px 0;
}
.cookie-modal-content ul li {
  margin-bottom: 10px;
  display: flex;
  align-items: center;
  gap: 14px;
  font-size: 1rem;
}
.cookie-category-switch {
  display: inline-flex;
  align-items: center;
}
.cookie-category-switch input[type="checkbox"] {
  appearance: none;
  width: 34px;
  height: 18px;
  background: #EEF0F2;
  border-radius: 11px;
  position: relative;
  outline: none;
  cursor: pointer;
  margin-right: 6px;
  transition: background 0.22s;
}
.cookie-category-switch input[type="checkbox"]:checked {
  background: #EFC44A;
}
.cookie-category-switch input[type="checkbox"]:before {
  content: '';
  display: block;
  width: 16px;
  height: 16px;
  border-radius: 50%;
  background: #fff;
  position: absolute;
  left: 1px;
  top: 1px;
  transition: transform 0.19s;
}
.cookie-category-switch input[type="checkbox"]:checked:before {
  transform: translateX(16px);
}
.cookie-modal-close {
  position: absolute;
  top: 10px;
  right: 10px;
  background: none;
  border: none;
  font-size: 1.34rem;
  color: #16344D;
  cursor: pointer;
}
.cookie-modal-actions {
  display: flex;
  flex-direction: row;
  gap: 12px;
  justify-content: flex-end;
}
.cookie-modal-actions button {
  font-size: 1rem;
  padding: 8px 22px;
  border-radius: 28px;
  border: none;
  background: #EFC44A;
  color: #16344D;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.17s;
}
.cookie-modal-actions button:hover {
  background: #FFD85E;
}

@media (max-width: 500px) {
  .cookie-modal-content {
    padding: 18px 6px 12px 10px;
    max-width: 97vw;
  }
}

/* --- ADDITIONAL & MICROINTERACTIONS --- */
a, button, .cta, .feature-grid > div {
  transition: color 0.18s, background 0.2s, box-shadow 0.18s, transform 0.17s;
}
a:focus-visible {
  outline: 2px solid #EFC44A;
  outline-offset: 2px;
}

/* Spacing for all list items */
ul li, ol li {
  margin-bottom: 8px;
}
ul li:last-child, ol li:last-child {
  margin-bottom: 0;
}

/* SHADOWS & RADIUS */
section, .card, .feature-grid > div, .testimonial-card, .cookie-banner, .cookie-modal-content {
  border-radius: 16px;
}

/* --- UTILITIES --- */
.mt-32 { margin-top: 32px; }
.mt-16 { margin-top: 16px; }
.mb-32 { margin-bottom: 32px; }
.mb-20 { margin-bottom: 20px; }
.text-center { text-align: center; }

/* --- RESPONSIVE GRID SHIFTS WITH FLEX ONLY --- */
@media (max-width: 600px) {
  .container {
    padding: 0 5px;
  }
  .section {
    margin-bottom: 20px;
    padding: 18px 0 12px 0;
    border-radius: 9px;
  }
}

/* --- MISC & OVERRIDES --- */
.included-features {
  margin-top: 24px;
}
.included-features h3 {
  margin-bottom: 10px;
}

/* --- PRINT OPTIMIZATION --- */
@media print {
  body, .container, .content-wrapper, section, .section, footer {
    background: #fff !important;
    color: #000 !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    padding: 0 !important;
    margin: 0 !important;
  }
  nav, .main-nav, .mobile-menu-toggle, .mobile-menu, .cta, .cookie-banner, .cookie-modal {
    display: none !important;
  }
}
