/* ===========================
   CSS RESET & NORMALIZE
   =========================== */
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,
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;
}
html {
  box-sizing: border-box;
  height: 100%;
}
*, *:before, *:after {
  box-sizing: inherit;
}
body {
  min-height: 100vh;
  background: #F6F7F9;
  color: #204060;
  line-height: 1.6;
  font-family: 'Roboto', Arial, Helvetica, sans-serif;
  font-size: 16px;
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
}

/* ===========================
   TYPOGRAPHY
   =========================== */

h1, h2, h3, h4, h5, h6 {
  font-family: 'Montserrat', Arial, Helvetica, sans-serif;
  font-weight: 700;
  color: #204060;
  letter-spacing: -0.02em;
  margin-bottom: 16px;
}
h1 { font-size: 2.4rem; line-height: 1.13; margin-bottom: 20px; }
h2 { font-size: 1.8rem; line-height: 1.2; margin-bottom: 18px; }
h3 { font-size: 1.32rem; line-height: 1.22; margin-bottom: 12px; }
h4 { font-size: 1.12rem; line-height: 1.25; }

@media (min-width: 600px) {
  h1 { font-size: 3rem; }
  h2 { font-size: 2.2rem; }
  h3 { font-size: 1.6rem; }
}
p, ul, ol {
  color: #204060;
  line-height: 1.7;
  margin-bottom: 16px;
}
strong, b { font-weight: 700; color: #204060; }
a {
  color: #204060;
  text-decoration: none;
  transition: color .15s;
}
a:hover {
  color: #8AB6D6;
  text-decoration: underline;
}

ul, ol {
  padding-left: 20px;
  margin-bottom: 16px;
}
ul li, ol li {
  margin-bottom: 8px;
  padding-left: 2px;
}

/* ===========================
   PAGE STRUCTURE & LAYOUT
   =========================== */

.container {
  width: 100%;
  max-width: 1200px;
  padding-left: 20px;
  padding-right: 20px;
  margin-left: auto;
  margin-right: auto;
}

.content-wrapper {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

.section {
  margin-bottom: 60px;
  padding: 40px 20px;
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 4px 20px 0 rgba(32, 64, 96, 0.04);
}

@media (max-width: 768px) {
  .section {
    padding: 24px 8px;
    margin-bottom: 36px;
    border-radius: 10px;
  }
}

/* ===========================
   HEADER & NAVIGATION
   =========================== */

header {
  background: #fff;
  box-shadow: 0 4px 12px rgba(32,64,96,0.03);
  position: sticky;
  top: 0;
  z-index: 1002;
}
header .container {
  display: flex;
  align-items: center;
  justify-content: flex-start;
  gap: 32px;
  min-height: 72px;
}
header img {
  height: 40px;
  width: auto;
  margin-right: 18px;
}
.main-nav {
  display: flex;
  gap: 22px;
  align-items: center;
  flex: 1 1 auto;
}
.main-nav a {
  font-family: 'Montserrat', Arial, Helvetica, sans-serif;
  color: #204060;
  font-size: 16px;
  letter-spacing: 0.01em;
  padding: 6px 0;
  border-bottom: 2px solid transparent;
  transition: border-color .18s, color .15s;
}
.main-nav a:hover, .main-nav a:focus {
  color: #8AB6D6;
  border-bottom: 2px solid #8AB6D6;
}

.cta-btn {
  display: inline-block;
  font-family: 'Montserrat', Arial, Helvetica, sans-serif;
  font-size: 16px;
  font-weight: 700;
  background: #204060;
  color: #fff;
  padding: 10px 26px;
  border: none;
  border-radius: 24px;
  transition: background .22s, color .12s, box-shadow .18s;
  box-shadow: 0 2px 8px rgba(32,64,96,0.07);
  cursor: pointer;
  margin-left: 16px;
}
.cta-btn:hover, .cta-btn:focus {
  background: #8AB6D6;
  color: #204060;
}

.mobile-menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 2rem;
  color: #204060;
  cursor: pointer;
  margin-left: 16px;
  padding: 6px 12px;
  transition: color .18s;
}
.mobile-menu-toggle:focus, .mobile-menu-toggle:hover {
  color: #8AB6D6;
}

@media (max-width: 1024px) {
  .main-nav { gap: 12px; }
  .cta-btn { padding: 10px 16px; font-size: 15px; margin-left: 8px; }
  header .container { gap: 12px; }
}
@media (max-width: 860px) {
  .main-nav { gap: 8px; }
  .cta-btn { font-size: 15px; padding: 9px 12px; }
  header .container { gap: 0; }
}

@media (max-width: 768px) {
  .main-nav, .cta-btn {
    display: none !important;
  }
  .mobile-menu-toggle {
    display: block;
    z-index: 1003;
  }
}

/* ===========================
   MOBILE MENU OVERLAY
   =========================== */
.mobile-menu {
  position: fixed;
  top: 0;
  right: 0;
  left: 0;
  bottom: 0;
  background: rgba(32,40,80,0.96);
  color: #fff;
  z-index: 1200;
  transform: translateX(100%);
  transition: transform 0.35s cubic-bezier(.5,.1,.15,1);
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  padding: 0;
}
.mobile-menu.active {
  transform: translateX(0);
}
.mobile-menu-close {
  background: none;
  border: none;
  color: #fff;
  font-size: 2.6rem;
  cursor: pointer;
  margin: 36px 28px 12px 0;
  transition: color .15s;
}
.mobile-menu-close:hover, .mobile-menu-close:focus {
  color: #8AB6D6;
}
.mobile-nav {
  width: 100%;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  padding: 28px 32px;
  gap: 18px;
}
.mobile-nav a {
  font-size: 1.25rem;
  font-family: 'Montserrat', Arial, Helvetica, sans-serif;
  color: #fff;
  padding: 12px 0;
  transition: color .2s;
  border-bottom: 1px solid rgba(255,255,255,0.06);
  width: 100%;
}
.mobile-nav a:hover, .mobile-nav a:focus {
  color: #8AB6D6;
}
/* Make each nav link easily tappable */
.mobile-nav a {
  min-height: 48px;
  display: flex;
  align-items: center;
}

/* ===========================
   HERO SECTION
   =========================== */
.hero {
  padding: 64px 0 32px 0;
  background: #F6F7F9;
}
.hero .container {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 28px;
}
.hero h1 {
  font-size: 2.1rem;
  font-family: 'Montserrat', Arial, Helvetica, sans-serif;
  font-weight: 700;
  margin-bottom: 8px;
}
.hero p {
  font-size: 1.12rem;
  max-width: 550px;
  color: #2c3d55;
}
.hero .cta-btn {
  margin-top: 18px;
}
@media (min-width: 600px){
  .hero h1 { font-size: 2.9rem; }
  .hero { padding-top: 82px; padding-bottom: 48px; }
}

/* ===========================
   FEATURES/GRID
   =========================== */
.features, .services, .about, .testimonials, .contact, .legal {
  margin-bottom: 60px;
}
.features .feature-grid, .services .feature-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 28px;
  justify-content: flex-start;
}
.feature {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 2px 12px 0 rgba(32, 64, 96, 0.05);
  padding: 28px 18px 24px 18px;
  flex: 1 1 260px;
  min-width: 240px;
  max-width: 310px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 15px;
  margin-bottom: 20px;
  transition: box-shadow .18s;
}
.feature img {
  width: 44px;
  height: 44px;
  margin-bottom: 8px;
  filter: grayscale(0.07) brightness(0.92); /* subtle minimalist icon */
}
.feature h3 {
  font-size: 1.19rem;
  margin-bottom: 8px;
}
.feature p {
  font-size: 1rem;
  color: #2c3d55;
}
.feature:hover {
  box-shadow: 0 6px 22px 0 rgba(32,64,96,0.12);
}

/* ===========================
   GENERIC FLEX PATTERNS
   =========================== */
.card-container {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
}
.card {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(32,64,96,0.06);
  padding: 28px 20px;
  margin-bottom: 20px;
  position: relative;
  transition: box-shadow .15s;
}
.card:hover {
  box-shadow: 0 4px 18px rgba(32,64,96,0.10);
}
.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;
}
.testimonial-card {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 12px;
  padding: 28px 24px;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 2px 10px rgba(32,64,96,0.08);
  margin-bottom: 20px;
  min-width: 260px;
  max-width: 420px;
}
.testimonial-card p {
  font-style: italic;
  font-size: 1.1em;
  color: #204060;
}
.testimonial-card span {
  font-size: .96em;
  color: #204060;
  font-family: 'Montserrat', Arial, Helvetica, sans-serif;
  margin-top: 6px;
}
.feature-item {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 15px;
}

@media (max-width: 1024px) {
  .feature { min-width: 170px; padding: 18px 10px 20px 10px; }
  .card { padding: 18px 12px; }
  .testimonial-card { padding: 16px 10px; }
}
@media (max-width: 768px) {
  .feature-grid, .content-grid, .card-container {
    flex-direction: column;
    gap: 14px;
  }
  .testimonial-list {
    flex-direction: column;
    gap: 16px;
    display: flex;
  }
}

/* ===========================
   BLOG POSTS & FILTER
   =========================== */
.blog-list {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
}
.blog-post {
  background: #fff;
  border-radius: 16px;
  box-shadow: 0 2px 10px rgba(32,64,96,0.08);
  padding: 28px 22px 22px 22px;
  min-width: 240px;
  flex: 1 1 280px;
  margin-bottom: 20px;
  display: flex;
  flex-direction: column;
  gap: 10px;
  position: relative;
  transition: box-shadow .15s;
}
.blog-post h3 {
  font-size: 1.14rem;
  margin-bottom: 8px;
}
.blog-post p {
  color: #204060;
  font-size: 1rem;
}
.blog-post .cta-btn-small {
  align-self: flex-start;
  background: #8AB6D6;
  color: #204060;
  border-radius: 20px;
  padding: 6px 14px;
  font-family: 'Montserrat', Arial, Helvetica, sans-serif;
  font-size: .98rem;
  font-weight: 600;
  margin-top: 8px;
  border: none;
  transition: background .18s, color .13s, box-shadow .13s;
}
.blog-post .cta-btn-small:hover, .blog-post .cta-btn-small:focus {
  background: #204060;
  color: #fff;
}
.blog-filter {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 20px;
}

/* ===========================
   LEGAL TEXTS, TEXT SECTIONS
   =========================== */
.legal {
  background: #fff;
  padding: 32px 20px;
  border-radius: 12px;
  box-shadow: 0 3px 13px rgba(32,64,96,0.04);
}
.text-section {
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.text-section ul {
  margin-bottom: 0;
}

/* ===========================
   STATISTICS BOX (STADTÜBERBLICK)
   =========================== */
.statistics {
  margin-top: 18px;
  background: #8AB6D6;
  color: #204060;
  border-radius: 10px;
  padding: 16px;
  font-size: 1.045rem;
  font-family: 'Roboto', Arial, Helvetica, sans-serif;
  font-weight: 500;
}
.statistics strong { color: #204060; }

/* ===========================
   FAQ, STEP GUIDE (KAUFBERATUNG)
   =========================== */
.step-guide {
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.faq-snippet {
  background: #f6f7f9;
  border-left: 5px solid #8AB6D6;
  padding: 14px 18px;
  border-radius: 8px;
  font-size: .98rem;
  color: #204060;
  margin-top: 10px;
}

/* ===========================
   CONTACT LIST ICONS
   =========================== */
.text-section ul li {
  display: flex;
  align-items: center;
  gap: 10px;
}
.text-section ul li img {
  width: 24px;
  height: 24px;
  margin-right: 4px;
  filter: grayscale(0.1) brightness(1) contrast(0.97);
}

/* ===========================
   BUTTONS & TRANSITIONS
   =========================== */
button, .cta-btn, .cta-btn-small {
  transition: background .18s, color .15s, box-shadow .13s;
  outline: none;
}
.cta-btn:active, .cta-btn-small:active {
  box-shadow: 0 2px 10px rgba(32,64,96,0.09);
  background: #8AB6D6;
  color: #204060;
}

/* ===========================
   FOOTER
   =========================== */
footer {
  background: #fff;
  padding-top: 38px;
  padding-bottom: 32px;
  box-shadow: 0 -2px 16px 0 rgba(32,64,96,0.03);
}
footer .container {
  display: flex;
  flex-wrap: wrap;
  gap: 22px;
  justify-content: space-between;
  align-items: center;
}
.footer-nav {
  display: flex;
  flex-wrap: wrap;
  gap: 18px;
  margin-bottom: 8px;
}
.footer-nav a {
  color: #204060;
  font-size: 1rem;
  opacity: 0.87;
  transition: opacity .13s;
}
.footer-nav a:hover, .footer-nav a:focus {
  opacity: 1;
  color: #8AB6D6;
}
.footer-contact {
  font-size: 0.99rem;
  color: #2c3d55;
  opacity: 0.82;
}
@media (max-width: 700px){
  footer .container { flex-direction: column; align-items: flex-start; gap: 8px; }
  .footer-nav { gap: 10px; }
}

/* ===========================
   COOKIE CONSENT BANNER & MODAL
   =========================== */
.cookie-banner {
  position: fixed;
  left: 0;
  right: 0;
  bottom: 0;
  background: #fff;
  border-top: 1px solid #dde3e9;
  box-shadow: 0 -2px 20px rgba(32,64,96,0.06);
  padding: 24px 20px;
  display: flex;
  align-items: flex-start;
  gap: 22px;
  z-index: 2000;
  animation: cookieSlideUp 0.4s cubic-bezier(.24,.89,.36,1);
}
@keyframes cookieSlideUp {
  from { transform: translateY(100px); opacity: 0; }
  to { transform: translateY(0); opacity: 1; }
}
.cookie-banner .cookie-text {
  flex: 1 1 auto;
  font-size: 1rem;
  color: #204060;
  max-width: 600px;
}
.cookie-banner .cookie-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}
.cookie-btn {
  font-family: 'Montserrat', Arial, Helvetica, sans-serif;
  padding: 8px 20px;
  border-radius: 24px;
  border: none;
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
  background: #204060;
  color: #fff;
  margin-right: 0;
  transition: background .16s, color .15s, box-shadow .13s;
  box-shadow: 0 2px 6px rgba(32,64,96,0.07);
}
.cookie-btn.secondary {
  background: #8AB6D6;
  color: #204060;
}
.cookie-btn.settings {
  background: transparent;
  border: 1.5px solid #204060;
  color: #204060;
}
.cookie-btn:hover, .cookie-btn:focus {
  background: #8AB6D6;
  color: #204060;
}
.cookie-btn.settings:hover,.cookie-btn.settings:focus {
  background: #204060;
  color: #fff;
  border-color: #204060;
}

/* Responsive banner on mobile */
@media (max-width: 600px) {
  .cookie-banner {
    flex-direction: column;
    padding: 18px 6px;
    gap: 18px;
  }
  .cookie-btn {
    font-size: .97rem;
    padding: 8px 16px;
    min-width: 120px;
  }
  .cookie-banner .cookie-text {
    font-size: .97rem;
    max-width: 100%;
  }
}

/* --- Cookie Modal --- */
.cookie-modal-overlay {
  position: fixed;
  top: 0; left: 0; right: 0; bottom: 0;
  background: rgba(32,64,96,0.2);
  z-index: 2100;
  display: none;
  align-items: center;
  justify-content: center;
}
.cookie-modal-overlay.active {
  display: flex;
  animation: fadein .18s;
}
@keyframes fadein {
  from { opacity:0; }
  to { opacity: 1; }
}
.cookie-modal {
  background: #fff;
  border-radius: 14px;
  box-shadow: 0 7px 32px rgba(32,64,96,0.14);
  padding: 34px 26px 24px 26px;
  min-width: 310px;
  max-width: 98vw;
  width: 100%;
  max-width: 420px;
  color: #204060;
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 20px;
  animation: fadein .17s;
}
.cookie-modal h2 {
  font-size: 1.3rem;
  margin-bottom: 10px;
}
.cookie-categories {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.cookie-category {
  display: flex;
  flex-direction: column;
  gap: 4px;
  background: #f6f7f9;
  border-radius: 8px;
  padding: 11px 14px 10px 14px;
}
.cookie-category .category-header {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 600;
  font-family: 'Montserrat', Arial, Helvetica, sans-serif;
  font-size: 1rem;
  color: #204060;
}
.cookie-category .toggle {
  margin-left: auto;
}
/* fake switch/toggle */
.cookie-toggle {
  width: 36px;
  height: 20px;
  border-radius: 10px;
  background: #dde3e9;
  position: relative;
  display: inline-block;
  vertical-align: middle;
  transition: background .18s;
  border: none;
  cursor: pointer;
}
.cookie-toggle[aria-checked="true"] {
  background: #8AB6D6;
}
.cookie-toggle .slider {
  position: absolute;
  top: 2px;
  left: 2px;
  width: 16px;
  height: 16px;
  background: #fff;
  border-radius: 50%;
  transition: left .21s cubic-bezier(.4,.7,.2,1);
  box-shadow: 0 2px 8px rgba(32,64,96,0.08);
}
.cookie-toggle[aria-checked="true"] .slider {
  left: 18px;
}
.cookie-modal-actions {
  display: flex;
  flex-direction: row;
  gap: 10px;
  margin-top: 4px;
}
.cookie-modal .modal-close {
  position: absolute;
  right: 14px;
  top: 16px;
  background: none;
  border: none;
  font-size: 2rem;
  color: #8AB6D6;
  cursor: pointer;
  transition: color .15s;
}
.cookie-modal .modal-close:hover, .cookie-modal .modal-close:focus {
  color: #204060;
}
.cookie-modal .hint {
  font-size: .94em;
  color: #6a7a95;
}
/* Responsive Modal */
@media (max-width: 520px) {
  .cookie-modal {
    padding: 16px 6px 10px 6px;
    min-width: 0;
  }
}

/* ===========================
   UTILITIES
   =========================== */
.mt-0 { margin-top: 0 !important; }
.mb-0 { margin-bottom: 0 !important; }
.text-center { text-align: center !important; }
.flex-row { display: flex; flex-direction: row; }
.flex-col { display: flex; flex-direction: column; }
.gap-8 { gap: 8px !important; }
.gap-16 { gap: 16px !important; }
.gap-20 { gap: 20px !important; }

/* ===========================
   RESPONSIVE SPACING & ALIGNMENT
   =========================== */
@media (max-width: 900px) {
  .features .feature-grid, .services .feature-grid {
    gap: 12px;
  }
}
@media (max-width: 640px) {
  .container { padding-left: 5px; padding-right: 5px; }
  .feature, .card, .testimonial-card, .blog-post { min-width: 0; width: 100%; max-width: 100%; }
}
@media (max-width: 480px) {
  html, body { font-size: 15px; }
}

.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;
    align-items: flex-start;
  }
}

/* ===========================
   MICRO-INTERACTIONS
   =========================== */
.feature, .card, .blog-post, .testimonial-card {
  transition: box-shadow .17s, transform .18s;
}
.feature:hover, .card:hover, .blog-post:hover, .testimonial-card:hover {
  box-shadow: 0 7px 28px rgba(32, 64, 96, 0.15);
  transform: translateY(-2px) scale(1.015);
}
a, button, .cta-btn, .cta-btn-small, .cookie-btn {
  outline: none;
  transition: color .13s, background .13s, box-shadow .12s;
}
a:focus, button:focus, .cta-btn:focus, .cta-btn-small:focus, .cookie-btn:focus {
  box-shadow: 0 0 0 2px #8AB6D6;
}

/* ===========================
   OVERRIDES & FIXES
   =========================== */
::-webkit-input-placeholder { color: #a1afc5; }
::-moz-placeholder { color: #a1afc5; }
:-ms-input-placeholder { color: #a1afc5; }
::placeholder { color: #a1afc5; }

/* Hide visually but keep for accessibility */
.sr-only {
  position: absolute !important;
  width: 1px !important;
  height: 1px !important;
  padding: 0 !important;
  margin: -1px !important;
  overflow: hidden !important;
  clip: rect(0,0,0,0) !important;
  border: 0 !important;
}

/* ===========================
   END OF CSS
   =========================== */
