/* =====================================================
   TraumRaum Ausbau – Industrial Modern UI
   Single stylesheet for all pages
   Constraints: Flexbox-only layouts, no CSS Grid/Columns
   Brand: Dark, metallic, urban; Trebuchet MS (display), Verdana (body)
   ===================================================== */

/* ==========================
   CSS RESET / NORMALIZE
   ========================== */
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { -webkit-text-size-adjust: 100%; }
img, picture, video, canvas, svg { display: block; max-width: 100%; height: auto; }
input, button, textarea, select { font: inherit; color: inherit; }
a { color: inherit; text-decoration: none; }
ul, ol { margin: 0; padding-left: 1.25rem; }
h1, h2, h3, h4, h5, h6, p { margin: 0; }
button { border: none; background: none; cursor: pointer; }
:focus-visible { outline: 2px dashed #F3E9DC; outline-offset: 2px; }

/* ==========================
   THEME TOKENS (with fallbacks)
   ========================== */
:root {
  --color-bg: #0F1418; /* deep charcoal */
  --color-surface: #141B21; /* slightly lighter surface */
  --color-surface-2: #19232B; /* contrast surface */
  --color-primary: #2E3A46; /* brand primary */
  --color-secondary: #8A5A3C; /* brand bronze */
  --color-accent: #F3E9DC; /* brand accent (light) */
  --color-text: #D9E1E8; /* light text on dark */
  --color-muted: #A1ABB4; /* muted text */
  --color-border: #2A3239; /* subtle borders */
  --shadow-1: 0 1px 2px rgba(0,0,0,0.35);
  --shadow-2: 0 6px 18px rgba(0,0,0,0.35);
  --radius-6: 6px; 
  --radius-10: 10px;
  --container-max: 1180px;
}

/* ==========================
   BASE TYPOGRAPHY
   ========================== */
body {
  background: var(--color-bg, #0F1418);
  color: var(--color-text, #D9E1E8);
  font-family: Verdana, Geneva, sans-serif; /* body font */
  line-height: 1.6;
  font-size: 16px;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

h1, h2, h3, h4 {
  font-family: "Trebuchet MS", Tahoma, sans-serif; /* display font */
  letter-spacing: 0.4px;
}

h1 { font-size: 32px; line-height: 1.25; margin-bottom: 14px; }
h2 { font-size: 24px; line-height: 1.3; margin-bottom: 12px; }
h3 { font-size: 18px; line-height: 1.35; margin-bottom: 8px; }

p { font-size: 16px; color: var(--color-text, #D9E1E8); }
strong { color: #E6EDF3; font-weight: 700; }
em { color: var(--color-muted, #A1ABB4); }

/* Utility: visually hidden (used in footer headings) */
.visually-hidden { position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }

/* ==========================
   LAYOUT CONTAINERS – Flexbox Only
   ========================== */
.container {
  width: 100%;
  max-width: var(--container-max);
  margin: 0 auto;
  padding: 0 20px;
  display: flex; /* flex-only rule */
  flex-direction: column;
}

.content-wrapper {
  display: flex; /* flex-only rule */
  flex-direction: column; /* mobile-first */
  gap: 16px;
}

/* Global section rhythm */
main > section { padding: 40px 0; border-top: 1px solid var(--color-border); background: var(--color-surface, #141B21); }
main > section:nth-of-type(even) { background: var(--color-surface-2, #19232B); }

/* Text blocks used throughout */
.text-section { margin-top: 4px; display: flex; flex-direction: column; gap: 10px; }

/* Spacing between structural sections */
section + section { margin-top: 10px; }

/* ==========================
   HEADER / NAVIGATION
   ========================== */
header { background: #0C1115; border-bottom: 1px solid var(--color-border); position: relative; z-index: 50; }
header .container { padding-top: 14px; padding-bottom: 14px; }
header .content-wrapper { flex-direction: row; align-items: center; justify-content: space-between; gap: 12px; }

.logo img { height: 34px; width: auto; filter: invert(1) }

/* Desktop nav hidden on mobile */
.main-nav { display: none; align-items: center; gap: 14px; }
.main-nav a { color: #D5DEE6; padding: 8px 10px; border-radius: var(--radius-6); transition: color .2s ease, background-color .2s ease; text-transform: uppercase; font-size: 12px; letter-spacing: 0.8px; }
.main-nav a:hover { background: rgba(243,233,220,0.08); color: #FFFFFF; }
.main-nav a[aria-current="page"] { color: var(--color-accent); }

/* Hamburger */
.mobile-menu-toggle {
  color: #E8EEF3;
  background: rgba(255,255,255,0.06);
  border: 1px solid var(--color-border);
  border-radius: 8px;
  width: 42px; height: 42px;
  display: flex; align-items: center; justify-content: center;
  transition: background .2s ease, transform .2s ease;
}
.mobile-menu-toggle:hover { background: rgba(255,255,255,0.1); transform: translateY(-1px); }

/* Mobile menu overlay */
.mobile-menu {
  position: fixed; left: 0; right: 0; top: 0; bottom: 0;
  display: flex; /* flex container for panel */
  justify-content: flex-end; align-items: stretch;
  background: rgba(0,0,0,0.6);
  backdrop-filter: saturate(120%) blur(2px);
  transform: translateX(20px);
  opacity: 0; pointer-events: none;
  transition: transform .3s ease, opacity .3s ease;
  z-index: 1000;
}
/* when opened by JS – support both class and aria */
.mobile-menu.open, .mobile-menu[aria-hidden="false"] {
  transform: translateX(0);
  opacity: 1; pointer-events: auto;
}

.mobile-nav { 
  background: #0F151A; border-left: 1px solid var(--color-border);
  width: 80vw; max-width: 360px; height: 100%;
  padding: 24px; display: flex; flex-direction: column; gap: 10px;
}
.mobile-nav a {
  padding: 14px 10px; border-radius: 8px; color: #E3E9EF;
  background: rgba(46,58,70,0.15);
  border: 1px solid rgba(42,50,57,0.8);
  transition: background .2s ease, color .2s ease, border-color .2s ease;
}
.mobile-nav a:hover { background: rgba(46,58,70,0.3); color: #FFFFFF; border-color: rgba(138,90,60,0.7); }
.mobile-nav a[aria-current="page"] { background: rgba(243,233,220,0.14); color: var(--color-accent); border-color: rgba(243,233,220,0.6); }

.mobile-menu-close {
  align-self: flex-end; margin-bottom: 8px;
  color: #E8EEF3; background: rgba(255,255,255,0.06);
  border: 1px solid var(--color-border); border-radius: 8px;
  width: 40px; height: 40px; display: flex; align-items: center; justify-content: center;
  transition: background .2s ease;
}
.mobile-menu-close:hover { background: rgba(255,255,255,0.12); }

/* ==========================
   BUTTONS
   ========================== */
.button {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 8px; padding: 12px 18px; border-radius: 10px;
  background: #1C252C; color: #EAF1F6;
  border: 1px solid var(--color-border);
  box-shadow: var(--shadow-1);
  transition: background .2s ease, transform .2s ease, box-shadow .2s ease, color .2s ease, border-color .2s ease;
}
.button:hover { transform: translateY(-1px); box-shadow: var(--shadow-2); background: #242F38; }
.button:active { transform: translateY(0); }

.button.primary { 
  background: var(--color-secondary, #8A5A3C); 
  color: #0E1216; 
  border-color: #A06A4A;
  font-weight: 700;
}
.button.primary:hover { background: #9A6545; border-color: #B97853; }

.button.secondary {
  background: transparent; color: var(--color-accent, #F3E9DC);
  border-color: rgba(243,233,220,0.5);
}
.button.secondary:hover { background: rgba(243,233,220,0.08); }

/* Make nav CTA distinct */
.main-nav a.button.primary { padding: 10px 14px; font-size: 12px; letter-spacing: .6px; }

/* ==========================
   CONTENT ELEMENTS
   ========================== */
/* Icon inline spacing */
.text-section img[alt^="Telefon"],
.text-section img[alt^="E-Mail"],
.text-section img[alt^="Adresse"],
.text-section img[alt^="Öffnungszeiten"],
.text-section img[alt^="Time"],
.text-section img[alt^="Location"] {
  display: inline-block; vertical-align: middle; margin: -2px 6px 0 0; opacity: 0.9;
}

/* Lists */
ul.text-section, ol.text-section { display: flex; flex-direction: column; gap: 8px; }
ul li, ol li { padding-left: 2px; }

/* Testimonials – light cards for readability */
.testimonial-card {
  display: flex; align-items: center; gap: 20px; padding: 20px; /* required */
  background: var(--color-accent, #F3E9DC);
  color: #2B3440; /* dark text for contrast */
  border: 1px solid #E2D5C4;
  border-left: 6px solid var(--color-secondary, #8A5A3C);
  border-radius: var(--radius-10);
  box-shadow: 0 4px 14px rgba(0,0,0,0.18);
}
.testimonial-card p { color: #2B3440; }
.testimonial-card strong { color: #1C232A; }
.testimonial-card:hover { transform: translateY(-1px); transition: transform .2s ease; }

/* Footer navigation */
.footer-nav { display: flex; flex-wrap: wrap; gap: 12px; }
.footer-nav a { color: #C8D2DA; padding: 6px 8px; border-radius: 6px; border: 1px solid transparent; }
.footer-nav a:hover { background: rgba(255,255,255,0.06); border-color: var(--color-border); }
.footer-nav a[aria-current="page"] { color: var(--color-accent); border-color: rgba(243,233,220,0.5); }

footer { background: #0C1115; border-top: 1px solid var(--color-border); }
footer .text-section p { color: #BFC8D0; }

/* ==========================
   MANDATORY SPACING & ALIGNMENT PATTERNS
   (Included exactly as requested)
   ========================== */
.section { margin-bottom: 60px; padding: 40px 20px; }
.card-container { display: flex; flex-wrap: wrap; gap: 24px; }
.card { margin-bottom: 20px; position: relative; }
.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; align-items: center; gap: 20px; padding: 20px; }
.feature-item { display: flex; flex-direction: column; align-items: flex-start; gap: 15px; }

/* Default styling for .card */
.card {
  background: #11181F; color: #DCE4EA;
  border: 1px solid var(--color-border); border-radius: 10px;
  padding: 20px; box-shadow: var(--shadow-1);
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease;
}
.card:hover { transform: translateY(-2px); box-shadow: var(--shadow-2); border-color: rgba(138,90,60,0.5); }

/* ==========================
   HERO / HEADLINES
   ========================== */
main section[aria-labelledby="hero-title"] .content-wrapper { gap: 16px; }
main section[aria-labelledby="hero-title"] h1 { font-size: 30px; letter-spacing: .2px; }

/* ==========================
   COOKIE CONSENT – Banner & Modal
   ========================== */
.cookie-banner {
  position: fixed; left: 0; right: 0; bottom: 0; z-index: 1200;
  background: #0F151B; color: #E6EDF3;
  border-top: 1px solid var(--color-border);
  box-shadow: 0 -8px 24px rgba(0,0,0,0.35);
  transform: translateY(110%);
  opacity: 0; pointer-events: none;
  transition: transform .35s ease, opacity .35s ease;
}
.cookie-banner.show { transform: translateY(0); opacity: 1; pointer-events: auto; }
.cookie-banner .container { padding: 16px 20px; }
.cookie-banner .content-wrapper { gap: 12px; }
.cookie-actions { display: flex; flex-wrap: wrap; gap: 10px; }
.cookie-actions .button { padding: 10px 14px; font-size: 14px; }
.cookie-actions .accept { background: var(--color-secondary); color: #111417; border-color: #A06A4A; }
.cookie-actions .reject { background: #1C252C; color: #E8EEF3; border-color: var(--color-border); }
.cookie-actions .settings { background: transparent; color: var(--color-accent); border-color: rgba(243,233,220,0.5); }
.cookie-actions .reject:hover { background: #24303A; }

/* Cookie modal overlay */
.cookie-modal {
  position: fixed; inset: 0; z-index: 1300;
  display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,0.65);
  opacity: 0; pointer-events: none; transition: opacity .25s ease;
}
.cookie-modal.show { opacity: 1; pointer-events: auto; }
.cookie-modal .cookie-modal-content {
  width: 92%; max-width: 720px;
  background: #121921; color: #E6EDF3;
  border: 1px solid var(--color-border); border-radius: 12px; box-shadow: var(--shadow-2);
  padding: 20px; display: flex; flex-direction: column; gap: 14px;
}
.cookie-modal .cookie-modal-header { display: flex; align-items: center; justify-content: space-between; }
.cookie-modal .cookie-modal-body { display: flex; flex-direction: column; gap: 12px; }
.cookie-modal .cookie-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 0; border-bottom: 1px dashed var(--color-border); }
.cookie-modal .cookie-row:last-child { border-bottom: none; }

/* Toggle switch */
.toggle {
  display: inline-flex; align-items: center; gap: 10px;
}
.switch {
  width: 44px; height: 26px; border-radius: 26px;
  background: #2A333B; border: 1px solid var(--color-border);
  position: relative; display: inline-flex; align-items: center; padding: 2px;
  transition: background .2s ease, border-color .2s ease;
}
.switch::after {
  content: ""; width: 20px; height: 20px; border-radius: 50%;
  background: #E6EDF3; transform: translateX(0);
  transition: transform .2s ease, background .2s ease;
}
.switch.on { background: var(--color-secondary); border-color: #A06A4A; }
.switch.on::after { transform: translateX(18px); background: #111417; }

/* ==========================
   RESPONSIVE BEHAVIOR (Mobile-first)
   ========================== */
@media (min-width: 480px) {
  h1 { font-size: 34px; }
}

@media (min-width: 768px) {
  h1 { font-size: 40px; }
  h2 { font-size: 28px; }
  .content-wrapper { gap: 18px; }
  .text-image-section { flex-direction: row; }
}

@media (min-width: 992px) {
  header .content-wrapper { gap: 18px; }
  .logo img { height: 40px; }
  .main-nav { display: flex; }
  .mobile-menu-toggle { display: none; }
  /* Align header nav flex row */
  header .content-wrapper { display: flex; flex-direction: row; align-items: center; justify-content: space-between; }

  /* Hero layout can breathe a bit more */
  main section[aria-labelledby="hero-title"] .content-wrapper { gap: 18px; }
}

/* ==========================
   INDUSTRIAL MODERN ACCENTS
   ========================== */
/* Subtle metallic edge lines on sections */
main > section { 
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.03), inset 0 -1px 0 rgba(0,0,0,0.35);
}
/* Accent underline for h2 */
h2 { position: relative; padding-bottom: 6px; }
h2::after {
  content: ""; display: block; height: 3px; width: 56px; margin-top: 8px;
  background: linear-gradient(90deg, rgba(138,90,60,0.9), rgba(243,233,220,0.75));
}

/* Links */
a { color: var(--color-accent); text-decoration: none; border-bottom: 1px dashed transparent; transition: color .2s ease, border-color .2s ease; }
a:hover { color: #FFF; border-color: rgba(243,233,220,0.6); }

/* ==========================
   ACCESSIBLE STATES
   ========================== */
button:focus-visible, .button:focus-visible, a:focus-visible { outline: 2px dashed var(--color-accent); outline-offset: 2px; }

/* ==========================
   EXTRA FLEX PATTERNS (for future content)
   ========================== */
.features, .card-grid, .cta-row, .info-row { display: flex; flex-wrap: wrap; gap: 20px; }

/* ==========================
   PAGE-SPECIFIC TWEAKS
   ========================== */
/* Index badges list spacing */
[aria-labelledby="warum-title"] .content-wrapper, 
[aria-labelledby="leistungen-title"] .content-wrapper,
[aria-labelledby="ablauf-title"] .content-wrapper,
[aria-labelledby="stimmen-title"] .content-wrapper,
[aria-labelledby="kontaktkurz-title"] .content-wrapper { gap: 14px; }

/* Price list readability */
[aria-labelledby="preisrahmen-title"] ul li, 
[aria-labelledby="faktoren-title"] ul li { color: #CFD7DE; }

/* Contact inline info */
[aria-labelledby="reach-title"] .text-section p { display: flex; align-items: center; gap: 8px; }

/* Thank-you page emphasis */
[aria-labelledby="naechste-schritte"] ul li { color: #DCE4EA; }

/* ==========================
   PRINT BASICS
   ========================== */
@media print {
  .mobile-menu, .mobile-menu-toggle, .cookie-banner, .cookie-modal { display: none !important; }
  a { color: #000; border: none; }
}
