/* =====================================================
   Kante & Kelle Bauatelier — style.css
   Vibrant_Energetic theme with brand fidelity
   Mobile-first, Flexbox-only layouts
   ===================================================== */

/* 1) RESET & NORMALIZE */
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul, ol { margin: 0 0 16px 20px; padding: 0; }
h1, h2, h3, h4, h5, h6, p { margin: 0 0 16px 0; }
button { background: none; border: none; padding: 0; font: inherit; color: inherit; cursor: pointer; }
:focus { outline: none; }
:focus-visible { outline: 3px solid #00E5FF; outline-offset: 2px; }

/* 2) THEME VARIABLES */
:root {
  /* Brand */
  --color-primary: #263238; /* dark blue-grey */
  --color-secondary: #C2702B; /* warm energetic orange */
  --color-accent: #F5F3EE; /* light warm sand */
  --color-white: #FFFFFF;
  --color-black: #0D0F11;

  /* Vibrant support accents for high-energy details */
  --electric-cyan: #00E5FF;
  --electric-pink: #FF4081;
  --electric-lime: #7CFF4D;
  --electric-violet: #7C4DFF;

  /* Text */
  --text-main: var(--color-primary);
  --text-inverse: var(--color-white);

  /* Effects */
  --shadow-soft: 0 6px 18px rgba(0,0,0,0.08);
  --shadow-lift: 0 10px 24px rgba(0,0,0,0.12);
  --radius-sm: 10px;
  --radius-md: 14px;
  --radius-lg: 18px;

  /* Spacing scale */
  --space-8: 8px; --space-12: 12px; --space-16: 16px; --space-20: 20px; --space-24: 24px; --space-32: 32px; --space-40: 40px; --space-60: 60px;
}

/* 3) BASE TYPOGRAPHY */
body {
  font-family: Verdana, "Segoe UI", Roboto, Arial, sans-serif;
  color: var(--text-main);
  background: var(--color-white);
  line-height: 1.6;
}

h1, h2, h3, h4 {
  font-family: "Trebuchet MS", Verdana, Arial, sans-serif;
  font-weight: 800;
  letter-spacing: 0.2px;
}

h1 { font-size: 30px; line-height: 1.2; }
h2 { font-size: 24px; line-height: 1.25; margin-top: 8px; }
h3 { font-size: 20px; line-height: 1.3; }
h4 { font-size: 18px; line-height: 1.3; }

.subhead {
  font-size: 16px;
  color: var(--color-primary);
  background: var(--color-accent);
  padding: 10px 14px;
  border-left: 6px solid var(--electric-cyan);
  border-radius: var(--radius-sm);
}

p, li { font-size: 16px; }
strong { font-weight: 800; }

/* 4) LAYOUT CONTAINERS — FLEX ONLY */
.container {
  display: flex; flex-direction: column; align-items: stretch; gap: var(--space-20);
  width: 100%; max-width: 1100px; margin: 0 auto; padding: 0 var(--space-20);
}
.content-wrapper {
  display: flex; flex-direction: column; align-items: flex-start; justify-content: flex-start; gap: var(--space-20);
}

/* Mandatory spacing for section blocks */
.section { margin-bottom: 60px; padding: 40px 20px; }
section { display: flex; flex-direction: column; gap: var(--space-20); padding: var(--space-40) 0; }

/* Energetic section accent stripe (decorative) */
section { position: relative; }
section::before {
  content: ""; position: absolute; left: 0; top: 0; height: 4px; width: 100%; background: var(--electric-cyan);
}
section:nth-of-type(2n)::before { background: var(--electric-pink); }
section:nth-of-type(3n)::before { background: var(--electric-lime); }

/* Alternating subtle backgrounds for rhythm */
main section:nth-of-type(2n) { background: var(--color-accent); }

/* 5) HEADER / NAVIGATION */
header { position: relative; background: var(--color-white); border-bottom: 2px solid rgba(38,50,56,0.08); z-index: 1000; }
header .container { padding-top: var(--space-16); padding-bottom: var(--space-16); }
header .content-wrapper { flex-direction: row; align-items: center; justify-content: space-between; gap: var(--space-16); }

.logo img { height: 40px; }

.main-nav { display: none; align-items: center; gap: var(--space-16); }
.main-nav a {
  font-family: "Trebuchet MS", Verdana, Arial, sans-serif;
  font-weight: 700; font-size: 14px; text-transform: uppercase; letter-spacing: 0.6px;
  padding: 10px 12px; border-radius: var(--radius-sm);
  transition: background 200ms ease, color 200ms ease, transform 200ms ease;
}
.main-nav a:hover { background: var(--electric-cyan); color: var(--color-black); transform: translateY(-1px); }
.main-nav a[aria-current="page"] { background: var(--color-secondary); color: var(--text-inverse); }

.header-cta { display: none; align-items: center; }

/* Mobile burger */
.mobile-menu-toggle {
  display: inline-flex; align-items: center; justify-content: center;
  width: 44px; height: 44px; border-radius: 10px; color: var(--text-main);
  background: var(--color-accent);
  box-shadow: var(--shadow-soft);
  transition: transform 200ms ease, background 200ms ease;
}
.mobile-menu-toggle:hover { transform: translateY(-1px); background: var(--electric-cyan); }

/* Mobile menu overlay */
.mobile-menu {
  position: fixed; inset: 0; display: flex; flex-direction: column; justify-content: flex-start; align-items: stretch; gap: var(--space-20);
  background: var(--color-white);
  transform: translateX(100%);
  transition: transform 320ms ease;
  padding: var(--space-20);
  z-index: 2000; box-shadow: var(--shadow-lift);
}
.mobile-menu.active { transform: translateX(0); }
.mobile-menu-close { align-self: flex-end; width: 44px; height: 44px; border-radius: 10px; background: var(--color-accent); }
.mobile-nav { display: flex; flex-direction: column; gap: var(--space-12); }
.mobile-nav a { padding: 14px 10px; border-radius: 10px; font-weight: 700; font-size: 16px; background: var(--color-accent); }
.mobile-nav a:hover { background: var(--electric-pink); color: var(--color-white); }

body.menu-open { overflow: hidden; }

/* 6) BUTTONS */
.button {
  display: inline-flex; align-items: center; justify-content: center; gap: 10px;
  padding: 12px 18px; border-radius: 12px; border: 2px solid var(--color-primary);
  color: var(--color-primary); background: var(--color-white);
  font-weight: 800; text-transform: uppercase; letter-spacing: 0.5px;
  box-shadow: var(--shadow-soft);
  transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease, color 180ms ease, border-color 180ms ease;
}
.button:hover { transform: translateY(-2px); box-shadow: var(--shadow-lift); border-color: var(--electric-cyan); }

.button.primary {
  background: var(--color-secondary); border-color: var(--color-secondary); color: var(--text-inverse);
}
.button.primary:hover {
  background: var(--electric-pink); border-color: var(--electric-pink);
}

/* Link underline accent on hover for inline links */
a:not(.button) { border-bottom: 2px solid rgba(0,0,0,0.1); transition: border-color 200ms ease, color 200ms ease; }
a:not(.button):hover { border-color: var(--electric-cyan); color: var(--color-primary); }

/* 7) TEXT BLOCKS / CARDS */
.text-section {
  display: flex; flex-direction: column; align-items: flex-start; gap: var(--space-12);
  padding: var(--space-16); background: var(--color-white);
  border: 2px solid var(--color-accent); border-radius: var(--radius-md); box-shadow: var(--shadow-soft);
}
.text-section h3 { position: relative; padding-bottom: 6px; }
.text-section h3::after { content: ""; display: block; height: 6px; width: 60px; background: var(--electric-lime); border-radius: 3px; margin-top: 6px; }

/* Testimonials — readable dark on light */
.testimonial-card {
  display: flex; align-items: center; gap: 20px; padding: 20px; flex-wrap: wrap;
  background: var(--color-accent); color: var(--color-primary);
  border: 2px solid rgba(38,50,56,0.08); border-left: 6px solid var(--electric-cyan);
  border-radius: var(--radius-md); box-shadow: var(--shadow-soft);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}
.testimonial-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-lift); border-left-color: var(--electric-pink); }

/* Lists inside content wrappers */
.content-wrapper ul, .content-wrapper ol { display: flex; flex-direction: column; gap: 8px; }

/* 8) FLEX PATTERNS — REQUIRED CLASSES */
.card-container { display: flex; flex-wrap: wrap; gap: 24px; }
.card { margin-bottom: 20px; position: relative; display: flex; flex-direction: column; gap: 12px; padding: 16px; background: var(--color-white); border: 1px solid rgba(0,0,0,0.06); border-radius: var(--radius-md); box-shadow: var(--shadow-soft); }
.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; }
.feature-item { display: flex; flex-direction: column; align-items: flex-start; gap: 15px; }

/* 9) HERO / HEADINGS ENERGY CUES */
main h1 { position: relative; }
main h1::after { content: ""; display: block; height: 8px; width: 90px; background: var(--electric-cyan); border-radius: 4px; margin-top: 10px; }

/* 10) FOOTER */
footer { background: var(--color-primary); color: #9a3a3a; }
footer section { padding: var(--space-40) 0; }
footer .content-wrapper { flex-direction: column; gap: var(--space-20); }
.footer-nav { display: flex; flex-wrap: wrap; gap: var(--space-12); }
.footer-nav a { color: var(--text-inverse); padding: 8px 10px; border-radius: 8px; background: rgba(255,255,255,0.04); }
.footer-nav a:hover { background: var(--electric-cyan); color: var(--color-black); }
footer address, footer p { color: rgba(52, 52, 52, 0.9); }

/* 11) FORMS / ADDRESS blocks */
address { font-style: normal; display: flex; flex-direction: column; gap: 8px; }

/* 12) COOKIES — BANNER & MODAL */
.cookie-banner {
  position: fixed; left: 0; right: 0; bottom: 0;
  display: flex; flex-direction: column; align-items: stretch; gap: var(--space-16);
  background: var(--color-white); color: var(--color-primary);
  border-top: 4px solid var(--electric-cyan);
  padding: var(--space-20);
  box-shadow: 0 -10px 24px rgba(0,0,0,0.12);
  transform: translateY(100%);
  transition: transform 300ms ease;
  z-index: 3000;
}
.cookie-banner.show { transform: translateY(0); }
.cookie-banner .actions { display: flex; flex-wrap: wrap; gap: 10px; }
.cookie-accept { composes: button primary; }
.cookie-reject, .cookie-settings { composes: button; }
/* Fallback since CSS Modules 'composes' is not standard; apply styles explicitly */
.cookie-accept, .cookie-reject, .cookie-settings { display: inline-flex; align-items: center; justify-content: center; gap: 10px; padding: 12px 18px; border-radius: 12px; font-weight: 800; text-transform: uppercase; letter-spacing: 0.5px; box-shadow: var(--shadow-soft); transition: transform 180ms ease, box-shadow 180ms ease, background 180ms ease, color 180ms ease, border-color 180ms ease; }
.cookie-accept { background: var(--color-secondary); color: var(--text-inverse); border: 2px solid var(--color-secondary); }
.cookie-accept:hover { background: var(--electric-pink); border-color: var(--electric-pink); transform: translateY(-2px); box-shadow: var(--shadow-lift); }
.cookie-reject { background: var(--color-white); color: var(--color-primary); border: 2px solid var(--color-primary); }
.cookie-reject:hover { border-color: var(--electric-cyan); transform: translateY(-2px); box-shadow: var(--shadow-lift); }
.cookie-settings { background: var(--color-accent); color: var(--color-primary); border: 2px solid var(--color-accent); }
.cookie-settings:hover { background: var(--electric-cyan); color: var(--color-black); transform: translateY(-2px); box-shadow: var(--shadow-lift); }

/* Cookie modal overlay */
.cookie-modal-overlay {
  position: fixed; inset: 0; background: rgba(0,0,0,0.5);
  display: none; align-items: center; justify-content: center;
  z-index: 4000;
}
.cookie-modal-overlay.open { display: flex; }
.cookie-modal {
  display: flex; flex-direction: column; gap: var(--space-16);
  background: var(--color-white); color: var(--color-primary);
  width: 92%; max-width: 560px;
  border-radius: var(--radius-lg); box-shadow: var(--shadow-lift);
  border: 3px solid var(--electric-cyan);
  padding: var(--space-24);
}
.cookie-modal .modal-header { display: flex; align-items: center; justify-content: space-between; }
.cookie-modal .categories { display: flex; flex-direction: column; gap: 12px; }
.cookie-category { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px; background: var(--color-accent); border-radius: 10px; }
.cookie-category .note { font-size: 14px; opacity: 0.85; }
/* Toggle style */
.toggle { position: relative; width: 46px; height: 28px; border-radius: 28px; background: #d0d6da; transition: background 200ms ease; }
.toggle[data-on="true"] { background: var(--electric-lime); }
.toggle .knob { position: relative; left: 2px; top: 2px; width: 24px; height: 24px; border-radius: 50%; background: var(--color-white); box-shadow: var(--shadow-soft); transition: transform 200ms ease; }
.toggle[data-on="true"] .knob { transform: translateX(18px); }
.cookie-modal .actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: flex-end; }

/* 13) UTILITIES */
.hidden { display: none !important; }
.muted { opacity: 0.7; }
.center { text-align: center; }

/* 14) RESPONSIVE */
@media (min-width: 768px) {
  h1 { font-size: 40px; }
  h2 { font-size: 28px; }
  h3 { font-size: 22px; }

  .text-image-section { flex-direction: row; }
  .content-wrapper { gap: var(--space-24); }
}

@media (min-width: 992px) {
  /* Show desktop nav, hide burger */
  .main-nav { display: flex; }
  .header-cta { display: flex; }
  .mobile-menu-toggle { display: none; }

  /* Footer as row */
  footer .content-wrapper { flex-direction: row; align-items: flex-start; justify-content: space-between; }
}

/* 15) PAGE-SPECIFIC LIGHT TOUCHES */
/* Index hero CTA area */
main > section:first-of-type .button.primary { box-shadow: 0 8px 0 0 rgba(194,112,43,0.4); }
main > section:first-of-type .button.primary:hover { box-shadow: 0 10px 0 0 rgba(255,64,129,0.45); }

/* Lists inside hero and info blocks: punchy markers */
ul li::marker { color: var(--electric-violet); }
ol li::marker { color: var(--electric-pink); font-weight: 800; }

/* 16) ACCESSIBILITY & CONTRAST IN TESTIMONIALS */
/* Dark text enforced on light testimonial background */
.testimonial-card, .testimonial-card p, .testimonial-card strong { color: #1b2327; }

/* 17) PREVENT OVERLAPS & CONSISTENT GAPS */
main .container .content-wrapper > * + * { margin-top: 0; }
.container, .content-wrapper, section, footer .content-wrapper { gap: var(--space-20); }

/* 18) MANDATED FLEXBOX GAP & SPACING RULES (re-assert) */
/* Ensuring minimum spacing between content cards/sections */
.card, .testimonial-card, .text-section { margin-bottom: 20px; }

/* 19) HEADER ACTIVE STATE FOR ACCESSIBILITY */
.main-nav a:focus-visible, .mobile-nav a:focus-visible { box-shadow: 0 0 0 3px var(--electric-cyan) inset; }

/* 20) ICON INLINE ALIGNMENT */
p img[alt^="Telefon"], p img[alt^="E-Mail"], p img[alt^="Adresse"], p img[alt^="Location"], p img[alt^="Icon"], address img {
  display: inline-block; vertical-align: middle; margin-right: 8px; height: 18px; width: auto;
}

/* 21) PRINT BASICS */
@media print {
  .mobile-menu, .mobile-menu-toggle, .cookie-banner, .cookie-modal-overlay { display: none !important; }
  a { text-decoration: underline; }
}
