/* =====================================================================
   Reset & Base
   ===================================================================== */
* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
html { scroll-behavior: smooth; }
body {
  font-family: Verdana, Arial, sans-serif;
  font-size: 16px;
  line-height: 1.6;
  color: #0B2333;
  background-color: #FCFCFD;
}
img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
button, input, select, textarea { font: inherit; color: inherit; }
ul, ol { margin: 0; padding-left: 1.2rem; }
figure { margin: 0; }

/* =====================================================================
   Brand Variables (with fallbacks)
   ===================================================================== */
:root {
  --primary: #0B3A53; /* brand primary */
  --secondary: #2E7D6D; /* brand secondary */
  --accent: #F4F6F8; /* brand accent */
  --ink: #0B2333; /* dark text */
  --bg: #FCFCFD; /* page bg */
  /* Creative Artistic accent helpers (solid, vibrant) */
  --violet: #6C5CE7;
  --magenta: #E84393;
  --gold: #FFB400;
  --mint: #00C2A8;
  --sky: #00A3FF;
  --card-bg: #FFFFFF;
  --muted: #6A7A86;
  --shadow-sm: 0 2px 10px rgba(11, 58, 83, 0.08);
  --shadow-md: 0 10px 30px rgba(11, 58, 83, 0.12);
}

/* =====================================================================
   Typography
   ===================================================================== */
h1, h2, h3, h4, h5, h6 {
  font-family: Georgia, 'Times New Roman', serif;
  color: var(--primary);
  margin: 0 0 12px 0;
}
h1 { font-size: 44px; line-height: 1.15; letter-spacing: -0.5px; }
h2 { font-size: 32px; line-height: 1.2; letter-spacing: -0.3px; }
h3 { font-size: 22px; line-height: 1.3; }
p { margin: 0 0 16px 0; color: var(--ink); }
.breadcrumbs { color: var(--muted); font-size: 14px; }
.small { font-size: 14px; color: var(--muted); }

/* Decorative heading accent (creative_artistic: bold color block underlines) */
h1, h2 {
  position: relative;
}
h1::after, h2::after {
  content: '';
  position: absolute;
  left: 0;
  bottom: -6px;
  width: 72px;
  height: 8px;
  background: var(--gold);
  border-radius: 8px;
}

/* =====================================================================
   Layout Helpers & Mandatory Patterns
   ===================================================================== */
.container {
  width: 100%;
  max-width: 1180px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}
.content-wrapper {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
section { padding: 40px 0; margin-bottom: 60px; }
.section { margin-bottom: 60px; padding: 40px 20px; } /* mandatory */
.card-container { display: flex; flex-wrap: wrap; gap: 24px; } /* mandatory */
.card { margin-bottom: 20px; position: relative; } /* mandatory */
.content-grid { display: flex; flex-wrap: wrap; gap: 20px; justify-content: space-between; } /* mandatory */
.text-image-section { display: flex; align-items: center; gap: 30px; flex-wrap: wrap; } /* mandatory */
.testimonial-card { display: flex; align-items: center; gap: 20px; padding: 20px; } /* mandatory - extended below */
.feature-item { display: flex; flex-direction: column; align-items: flex-start; gap: 15px; } /* mandatory */

/* Generic card look */
.card-like,
.feature-grid > div,
.service-list > div,
.tools > div,
.step-cards > div,
.area-cards-grid > div,
.resource-cards > div,
.team-overview-cards > div,
.tax-overview-cards > div,
.service-per-step-grid > div {
  background: var(--card-bg);
  border: 2px solid rgba(11, 58, 83, 0.08);
  border-radius: 16px;
  padding: 18px 18px 20px;
  box-shadow: var(--shadow-sm);
  position: relative;
  display: flex;
  flex-direction: column;
  gap: 10px;
}
/* Artistic corner accent (unique element) */
.card-like::before,
.feature-grid > div::before,
.service-list > div::before,
.tools > div::before,
.step-cards > div::before,
.area-cards-grid > div::before,
.resource-cards > div::before,
.team-overview-cards > div::before,
.tax-overview-cards > div::before,
.service-per-step-grid > div::before {
  content: '';
  position: absolute;
  top: -6px; right: -6px;
  width: 16px; height: 16px;
  background: var(--magenta);
  border-radius: 50%;
}

/* =====================================================================
   Header & Navigation
   ===================================================================== */
header { position: sticky; top: 0; z-index: 1000; background: #FFFFFF; box-shadow: 0 2px 16px rgba(11,58,83,0.06); }
header .container { flex-direction: row; align-items: center; justify-content: space-between; gap: 14px; padding-top: 12px; padding-bottom: 12px; }
header img { height: 36px; width: auto; }

.main-nav { display: none; align-items: center; gap: 14px; }
.main-nav a {
  color: var(--ink);
  font-weight: 600;
  padding: 8px 10px;
  border-radius: 10px;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}
.main-nav a:hover { background: var(--accent); color: var(--primary); transform: translateY(-1px); }

.mobile-menu-toggle {
  display: inline-flex;
  align-items: center; justify-content: center;
  width: 40px; height: 40px;
  border: 2px solid var(--primary);
  border-radius: 10px;
  background: #fff; color: var(--primary);
  cursor: pointer;
  transition: transform 0.2s ease, background 0.2s ease;
}
.mobile-menu-toggle:hover { transform: translateY(-1px); background: var(--accent); }

/* Mobile menu overlay */
.mobile-menu {
  position: fixed; inset: 0 0 0 0; /* full screen */
  background: rgba(11, 35, 51, 0.5);
  display: flex;
  justify-content: flex-end;
  transform: translateX(100%);
  transition: transform 0.35s ease;
  z-index: 1200;
}
.mobile-menu.open { transform: translateX(0); }
.mobile-menu-close {
  position: absolute; top: 16px; right: 18px;
  width: 40px; height: 40px;
  border-radius: 10px; border: 2px solid #fff; background: transparent; color: #fff;
  display: inline-flex; align-items: center; justify-content: center;
}
.mobile-nav {
  width: 86%; max-width: 360px; height: 100%;
  background: #FFFFFF;
  display: flex; flex-direction: column; gap: 8px;
  padding: 64px 22px 22px;
  box-shadow: var(--shadow-md);
}
.mobile-nav a {
  display: flex; align-items: center;
  padding: 14px 12px;
  border-radius: 12px;
  font-weight: 700;
  color: var(--primary);
  background: #fff;
  border: 2px solid rgba(11,58,83,0.08);
}
.mobile-nav a:hover { background: var(--accent); }

/* =====================================================================
   Buttons
   ===================================================================== */
.button {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 12px 18px;
  border-radius: 14px;
  border: 2px solid transparent;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease, color 0.2s ease;
  text-align: center;
}
.button-primary {
  background: var(--secondary);
  color: #fff;
  box-shadow: 0 6px 0 rgba(0,0,0,0.08);
}
.button-primary:hover { transform: translateY(-2px); box-shadow: 0 10px 16px rgba(46,125,109,0.25); }
.button-primary:focus { outline: 3px solid var(--gold); outline-offset: 2px; }

.button-secondary {
  background: #fff;
  color: var(--primary);
  border-color: var(--primary);
}
.button-secondary:hover { background: var(--accent); transform: translateY(-2px); }

/* Artistic micro-interaction underline for links within text */
.content-wrapper a:not(.button) {
  color: var(--secondary);
  border-bottom: 2px solid var(--gold);
}
.content-wrapper a:not(.button):hover { color: var(--primary); }

/* =====================================================================
   Hero Sections (creative_artistic)
   ===================================================================== */
.hero { position: relative; overflow: hidden; background: #FFFFFF; }
.hero .container { min-height: 340px; align-items: flex-start; justify-content: center; }
.hero p { max-width: 780px; color: var(--ink); }
/* Decorative solid shapes */
.hero::before, .hero::after {
  content: '';
  position: absolute;
  z-index: 0;
}
.hero::before {
  width: 180px; height: 180px;
  background: var(--violet);
  opacity: 0.08;
  border-radius: 24px;
  top: -40px; left: -30px;
  transform: rotate(12deg);
}
.hero::after {
  width: 220px; height: 220px;
  background: var(--gold);
  opacity: 0.12;
  border-radius: 50%;
  bottom: -60px; right: -40px;
}
.hero .content-wrapper { position: relative; z-index: 1; }

.trust-badges, .trust-logos {
  display: flex; flex-wrap: wrap; gap: 16px; align-items: center;
}
.trust-badges img, .trust-logos img { height: 28px; width: auto; filter: saturate(1.1); }

/* =====================================================================
   Feature / Service / Tools / Grids (flex only)
   ===================================================================== */
.feature-grid,
.service-list,
.tools,
.area-cards-grid,
.resource-cards,
.team-overview-cards,
.service-per-step-grid,
.testimonials-list,
.testimonials-slider,
.phase-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}
.feature-grid > div,
.service-list > div,
.tools > div,
.area-cards-grid > div,
.resource-cards > div,
.team-overview-cards > div,
.service-per-step-grid > div {
  flex: 1 1 260px;
}
.phase-tabs > div { flex: 1 1 220px; background: #fff; border: 2px dashed var(--mint); border-radius: 16px; padding: 16px; }
.phase-tabs > div h3 { margin-bottom: 6px; color: var(--secondary); }

/* =====================================================================
   Lists & Timelines
   ===================================================================== */
.benefit-list,
.value-points,
.milestone-checklists,
.do-dont-list,
.document-list,
.area-highlights-list,
.schools-transport-amenities-list,
.topic-list-kaufvertrag-wegrecht,
.red-flags-list,
.notary-checklist,
.data-subject-rights-list {
  display: flex; flex-direction: column; gap: 10px; padding-left: 0; list-style: none;
}
.benefit-list li,
.value-points li,
.milestone-checklists li,
.do-dont-list li,
.document-list li,
.area-highlights-list li,
.schools-transport-amenities-list li,
.topic-list-kaufvertrag-wegrecht li,
.red-flags-list li,
.notary-checklist li,
.data-subject-rights-list li {
  position: relative;
  padding-left: 28px;
}
.benefit-list li::before,
.value-points li::before,
.milestone-checklists li::before,
.document-list li::before,
.area-highlights-list li::before,
.schools-transport-amenities-list li::before,
.topic-list-kaufvertrag-wegrecht li::before,
.data-subject-rights-list li::before {
  content: '';
  position: absolute; left: 0; top: 7px;
  width: 12px; height: 12px; border-radius: 50%; background: var(--mint);
}
.red-flags-list li::before { background: var(--magenta); }
.notary-checklist li::before { background: var(--gold); }
.do-dont-list li:nth-child(odd)::before { background: var(--secondary); }
.do-dont-list li:nth-child(even)::before { background: var(--magenta); }

.process-timeline,
.legal-timeline,
.meeting-agenda-points {
  list-style: none; padding-left: 0; margin: 0;
  display: flex; flex-direction: column; gap: 12px;
  border-left: 4px solid var(--accent);
  padding-left: 16px;
}
.process-timeline li strong,
.legal-timeline li strong {
  display: inline-flex; align-items: center; justify-content: center;
  width: 28px; height: 28px; margin-right: 8px;
  border-radius: 50%; background: var(--gold); color: #000; font-weight: 800;
}

.step-cards { display: flex; flex-wrap: wrap; gap: 20px; }
.step-cards > div { flex: 1 1 260px; }

.anchor-navigation { display: flex; flex-wrap: wrap; gap: 12px; }
.anchor-navigation a { padding: 10px 14px; border-radius: 12px; background: var(--accent); color: var(--primary); font-weight: 700; }
.anchor-navigation a:hover { background: #E9EEF1; }

/* =====================================================================
   Interactive / Maps / Tables
   ===================================================================== */
.interactive-map {
  display: flex; flex-direction: column; gap: 14px;
  background: #fff; border: 2px solid rgba(11,58,83,0.08); border-radius: 16px; padding: 16px; box-shadow: var(--shadow-sm);
}
.filter-controls, .legend, .search-bar { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; }
.search-bar input { width: 100%; max-width: 420px; padding: 10px 12px; border-radius: 10px; border: 2px solid var(--accent); }

.comparison-table table,
.cookie-categories-table table { width: 100%; border-collapse: collapse; background: #fff; border: 2px solid rgba(11,58,83,0.08); border-radius: 12px; overflow: hidden; }
.comparison-table th, .comparison-table td,
.cookie-categories-table th, .cookie-categories-table td { padding: 12px; text-align: left; }
.comparison-table thead, .cookie-categories-table thead { background: var(--accent); }
.comparison-table tbody tr:nth-child(even), .cookie-categories-table tbody tr:nth-child(even) { background: #FAFBFC; }

.price-trends-snapshot, .rental-yield-snapshot, .download-checklist, .glossary-teaser, .sample-templates-teaser, .budget-planner-teaser, .mortgage-readiness-check-teaser, .grunderwerbsteuer-by-state-teaser, .notary-appointment-support-teaser, .relocation-checklist-teaser, .calendar-invite-teaser {
  display: flex; align-items: center; justify-content: space-between; gap: 12px;
  background: #fff; border: 2px dashed var(--sky); border-radius: 14px; padding: 14px 16px;
}

/* =====================================================================
   Testimonials (contrast-focused)
   ===================================================================== */
.testimonials-slider, .testimonials-list { align-items: stretch; }
.testimonial-card {
  background: #FFFFFF;
  border: 2px solid rgba(11, 58, 83, 0.12);
  border-left: 6px solid var(--secondary);
  border-radius: 16px;
  color: var(--ink);
  box-shadow: var(--shadow-sm);
  flex: 1 1 320px;
}
.testimonial-card p { margin: 0; color: var(--ink); }
.testimonial-card span { color: var(--muted); font-weight: 600; }

/* =====================================================================
   Contact & Utility Blocks
   ===================================================================== */
.contact-teaser {
  display: flex; flex-wrap: wrap; gap: 16px; align-items: center; justify-content: space-between;
  background: var(--accent); border-radius: 16px; padding: 16px 18px; border: 2px solid rgba(11,58,83,0.08);
}
.contact-details img { width: 18px; height: 18px; display: inline-block; vertical-align: middle; margin-right: 8px; }
.opening-hours { color: var(--muted); }
.map-embed { display: flex; }

.metrics-counters { display: flex; flex-wrap: wrap; gap: 16px; }
.metrics-counters > div {
  background: #fff; border-radius: 16px; padding: 14px 16px; border: 2px solid rgba(11,58,83,0.08);
  display: flex; align-items: baseline; gap: 10px; box-shadow: var(--shadow-sm);
}
.metrics-counters span { font-weight: 800; color: var(--secondary); font-size: 22px; }

/* =====================================================================
   Footer
   ===================================================================== */
footer { background: #0B1320; color: #EAF0F4; padding: 28px 0; margin-top: 40px; }
footer .container { gap: 16px; }
.footer-nav { display: flex; flex-wrap: wrap; gap: 12px; }
.footer-nav a { color: #EAF0F4; opacity: 0.9; padding: 6px 8px; border-radius: 8px; }
.footer-nav a:hover { background: rgba(255,255,255,0.08); }
.social-links { display: flex; gap: 12px; align-items: center; }
.social-links img { width: 20px; height: 20px; filter: invert(1) brightness(1.2); opacity: 0.9; }
.social-links a:hover img { opacity: 1; }

/* =====================================================================
   Legal Richtext
   ===================================================================== */
.legal-content-richtext { background: #fff; border-radius: 16px; border: 2px solid rgba(11,58,83,0.08); padding: 18px; box-shadow: var(--shadow-sm); }
.text-section h3 { margin-top: 10px; color: var(--secondary); }
.last-updated-note { margin-top: 10px; color: var(--muted); }
.contact-for-privacy { margin-top: 8px; padding: 12px 14px; background: var(--accent); border-radius: 12px; }

/* =====================================================================
   Mobile Navigation Visibility Rules
   ===================================================================== */
@media (min-width: 992px) {
  .main-nav { display: flex; }
  .mobile-menu-toggle { display: none; }
  header .container { padding-top: 16px; padding-bottom: 16px; }
}

/* =====================================================================
   Responsive Layout Rules (flex-direction switching)
   ===================================================================== */
@media (min-width: 768px) {
  .container { gap: 24px; }
  .text-image-section { flex-direction: row; }
  .contact-teaser { flex-direction: row; }
  .hero .container { min-height: 380px; }
  h1 { font-size: 52px; }
}
@media (max-width: 768px) {
  .text-image-section { flex-direction: column; align-items: flex-start; }
}

/* =====================================================================
   Forms & Inputs (generic)
   ===================================================================== */
input[type="text"], input[type="email"], input[type="tel"], input[type="range"], textarea {
  border: 2px solid var(--accent);
  border-radius: 10px;
  padding: 10px 12px;
  width: 100%;
}
label { display: inline-flex; align-items: center; gap: 8px; }

/* =====================================================================
   Micro animations
   ===================================================================== */
@keyframes fadeUp { from { opacity: 0; transform: translateY(12px); } to { opacity: 1; transform: translateY(0); } }
.hero .content-wrapper { animation: fadeUp 0.5s ease both; }

/* =====================================================================
   Cookie Consent Banner & Modal
   ===================================================================== */
.cookie-banner {
  position: fixed; left: 16px; right: 16px; bottom: 16px;
  background: #FFFFFF;
  border: 2px solid rgba(11,58,83,0.12);
  border-left: 8px solid var(--gold);
  border-radius: 16px;
  box-shadow: var(--shadow-md);
  padding: 16px;
  display: flex; flex-direction: column; gap: 12px;
  transform: translateY(140%);
  transition: transform 0.35s ease;
  z-index: 1400;
}
.cookie-banner.show { transform: translateY(0); }
.cookie-banner .cookie-text { color: var(--ink); }
.cookie-banner .cookie-actions { display: flex; flex-wrap: wrap; gap: 10px; justify-content: flex-end; }
.cookie-banner .button-accept { background: var(--secondary); color: #fff; border: 2px solid var(--secondary); }
.cookie-banner .button-reject { background: #fff; color: var(--primary); border: 2px solid var(--primary); }
.cookie-banner .button-settings { background: var(--accent); color: var(--primary); border: 2px solid rgba(11,58,83,0.08); }

.cookie-modal {
  position: fixed; inset: 0;
  background: rgba(0,0,0,0.55);
  display: none; align-items: center; justify-content: center; padding: 16px;
  z-index: 1500;
}
.cookie-modal.open { display: flex; }
.cookie-modal-content {
  background: #fff; border-radius: 16px; border: 2px solid rgba(11,58,83,0.12);
  width: 100%; max-width: 720px; padding: 18px; display: flex; flex-direction: column; gap: 14px;
}
.cookie-categories { display: flex; flex-direction: column; gap: 10px; }
.cookie-category { display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 10px 12px; border-radius: 12px; background: var(--accent); }
.cookie-category .always-on { font-weight: 700; color: var(--muted); }

/* Simple toggle switch style for cookie options (analytics/marketing) */
.toggle { position: relative; width: 46px; height: 26px; border-radius: 20px; background: #D7DEE3; border: 2px solid #C7D1D8; transition: background 0.2s ease; }
.toggle::after { content: ''; position: absolute; top: 2px; left: 2px; width: 20px; height: 20px; border-radius: 50%; background: #fff; box-shadow: var(--shadow-sm); transition: transform 0.2s ease; }
.toggle.on { background: var(--secondary); border-color: var(--secondary); }
.toggle.on::after { transform: translateX(20px); }

.cookie-modal-actions { display: flex; justify-content: flex-end; gap: 10px; }

/* =====================================================================
   Artistic extras (subtle colorful separators)
   ===================================================================== */
section .container::after {
  content: '';
  display: block;
  height: 4px; width: 64px;
  background: var(--violet);
  border-radius: 8px;
  opacity: 0.12;
  margin-top: 8px;
}

/* =====================================================================
   Page-specific tweaks
   ===================================================================== */
/* Breadcrumb spacing in heroes */
.hero .breadcrumbs { margin-top: 4px; }

/* Trust logo row center */
.trust-logos { justify-content: center; }

/* Contact page list spacing */
.contact-details { display: block; }
.contact-details span { margin-left: 6px; }

/* Map embed */
.map-embed > div { border-radius: 12px; border: 2px solid rgba(11,58,83,0.08); }

/* Footer alignment on wider screens */
@media (min-width: 992px) {
  footer .container { flex-direction: row; align-items: center; justify-content: space-between; }
}

/* =====================================================================
   Accessibility & Focus Visible
   ===================================================================== */
:focus { outline: none; }
:focus-visible { outline: 3px solid var(--gold); outline-offset: 2px; }

/* =====================================================================
   Spacing Consistency Utilities
   ===================================================================== */
.mt-0 { margin-top: 0; } .mt-8 { margin-top: 8px; } .mt-16 { margin-top: 16px; } .mt-24 { margin-top: 24px; }
.mb-0 { margin-bottom: 0; } .mb-8 { margin-bottom: 8px; } .mb-16 { margin-bottom: 16px; } .mb-24 { margin-bottom: 24px; }

/* =====================================================================
   Ensure no overlap and consistent gaps
   ===================================================================== */
section .container > * + * { margin-top: 8px; }

/* =====================================================================
   Desktop enhancements
   ===================================================================== */
@media (min-width: 1024px) {
  .container { padding: 0 28px; }
  .feature-grid > div,
  .service-list > div,
  .tools > div,
  .area-cards-grid > div,
  .resource-cards > div,
  .team-overview-cards > div,
  .service-per-step-grid > div {
    flex: 1 1 calc(33.333% - 20px);
  }
  .testimonials-slider { justify-content: space-between; }
}

/* =====================================================================
   High contrast rule for testimonials/reviews
   ===================================================================== */
.testimonials-slider .testimonial-card, .testimonials-list .testimonial-card {
  background: #FFFFFF; color: #0B2333;
}

/* =====================================================================
   End
   ===================================================================== */
