/* ============================================================
   Dr. Frithjof Hampel – Sachverständiger
   Design-System: modern-konservativ, 50+ Zielgruppe
   ============================================================ */

/* 1. CSS-Variablen & Reset
   ============================================================ */
:root {
  --color-primary:    #1a2744;
  --color-primary-dk: #111b33;
  --color-accent:     #b8922a;
  --color-accent-lt:  #d4a843;
  --color-bg:         #ffffff;
  --color-bg-subtle:  #f7f6f3;
  --color-bg-dark:    #1a2744;
  --color-text:       #1a1a1a;
  --color-text-muted: #555555;
  --color-border:     #ddd8cc;
  --color-white:      #ffffff;

  --font-heading: Georgia, 'Times New Roman', serif;
  --font-body:    'Segoe UI', system-ui, -apple-system, Arial, sans-serif;

  --fz-sm:   16px;
  --fz-base: 18px;
  --fz-lg:   20px;
  --fz-xl:   24px;
  --fz-2xl:  30px;
  --fz-3xl:  38px;
  --fz-4xl:  48px;

  --lh: 1.75;
  --lh-tight: 1.3;

  --sp-xs:  0.5rem;
  --sp-sm:  1rem;
  --sp-md:  1.5rem;
  --sp-lg:  2.5rem;
  --sp-xl:  4rem;
  --sp-2xl: 6rem;

  --max-w: 1140px;
  --radius: 4px;
  --shadow: 0 2px 16px rgba(0,0,0,0.08);
  --shadow-lg: 0 6px 32px rgba(0,0,0,0.12);
  --transition: 0.2s ease;
}

*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: var(--fz-base); scroll-behavior: smooth; }

body {
  font-family: var(--font-body);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: var(--lh);
  -webkit-font-smoothing: antialiased;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
a:hover { text-decoration: underline; }
ul { list-style: none; }
address { font-style: normal; }

/* 2. Typografie
   ============================================================ */
h1, h2, h3, h4 {
  font-family: var(--font-heading);
  line-height: var(--lh-tight);
  color: var(--color-primary);
  font-weight: normal;
}

h1 { font-size: clamp(1.8rem, 4vw, 2.4rem); margin-bottom: var(--sp-md); }
h2 { font-size: clamp(1.4rem, 3vw, 1.9rem); margin-bottom: var(--sp-sm); }
h3 { font-size: clamp(1.1rem, 2.5vw, 1.4rem); margin-bottom: var(--sp-xs); }

p { margin-bottom: var(--sp-sm); max-width: 70ch; }
p:last-child { margin-bottom: 0; }

.lead {
  font-size: var(--fz-lg);
  color: var(--color-text-muted);
  margin-bottom: var(--sp-md);
}

strong { font-weight: 600; }

/* 3. Layout
   ============================================================ */
.container {
  max-width: var(--max-w);
  margin-left: auto;
  margin-right: auto;
  padding-left: var(--sp-md);
  padding-right: var(--sp-md);
}

.section {
  padding-top: var(--sp-xl);
  padding-bottom: var(--sp-xl);
}

.section--subtle { background: var(--color-bg-subtle); }
.section--dark   { background: var(--color-bg-dark); color: var(--color-white); }
.section--dark h2, .section--dark h3 { color: var(--color-white); }

.section__header { margin-bottom: var(--sp-lg); }
.section__header .lead { margin-top: var(--sp-xs); }

.text-center { text-align: center; }
.text-center p { margin-left: auto; margin-right: auto; }

/* 4. Zugänglichkeit
   ============================================================ */
.skip-link {
  position: absolute;
  top: -100%;
  left: var(--sp-sm);
  background: var(--color-accent);
  color: var(--color-white);
  padding: var(--sp-xs) var(--sp-sm);
  border-radius: 0 0 var(--radius) var(--radius);
  font-weight: 600;
  z-index: 9999;
}
.skip-link:focus { top: 0; }

/* 5. Top-Bar
   ============================================================ */
.top-bar {
  background: var(--color-primary-dk);
  color: var(--color-white);
  font-size: var(--fz-sm);
  padding: var(--sp-xs) 0;
}

.top-bar__inner {
  display: flex;
  gap: var(--sp-md);
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
}

.top-bar__item {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--color-white);
  opacity: 0.9;
  transition: opacity var(--transition);
}
.top-bar__item:hover { opacity: 1; text-decoration: none; }
.top-bar__item svg { flex-shrink: 0; }

/* 6. Site-Header & Logo
   ============================================================ */
.site-header {
  background: var(--color-bg);
  border-bottom: 3px solid var(--color-accent);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 8px rgba(0,0,0,0.07);
}

.site-header__inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: var(--sp-md);
  padding-top: var(--sp-sm);
  padding-bottom: var(--sp-sm);
}

.site-header__logo { text-decoration: none; flex-shrink: 0; }

.logo-text {
  display: flex;
  flex-direction: column;
  line-height: 1.2;
}

.logo-title {
  font-family: var(--font-heading);
  font-size: clamp(1rem, 2.5vw, 1.35rem);
  color: var(--color-primary);
  font-weight: normal;
  letter-spacing: 0.01em;
}

.logo-subtitle {
  font-size: 0.78rem;
  color: var(--color-accent);
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

/* 7. Navigation
   ============================================================ */
.nav-toggle-checkbox { display: none; }

.nav-toggle-label {
  display: none;
  flex-direction: column;
  gap: 5px;
  cursor: pointer;
  padding: var(--sp-xs);
}

.nav-toggle-label span {
  display: block;
  width: 26px;
  height: 2px;
  background: var(--color-primary);
  transition: transform var(--transition), opacity var(--transition);
}

.nav-list {
  display: flex;
  gap: 0;
  align-items: center;
  flex-wrap: wrap;
}

.nav-list a {
  display: block;
  padding: 0.5rem 0.85rem;
  font-size: var(--fz-sm);
  color: var(--color-primary);
  font-weight: 500;
  border-radius: var(--radius);
  transition: background var(--transition), color var(--transition);
  white-space: nowrap;
}

.nav-list a:hover,
.nav-list a[aria-current="page"] {
  background: var(--color-bg-subtle);
  color: var(--color-accent);
  text-decoration: none;
}

/* 8. Page Hero
   ============================================================ */
.page-hero {
  background: var(--color-primary);
  color: var(--color-white);
  padding: var(--sp-xl) 0;
  position: relative;
  overflow: hidden;
}

.page-hero::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 4px;
  background: var(--color-accent);
}

.page-hero__inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-lg);
  align-items: center;
}

.page-hero__content h1 { color: var(--color-white); }

.page-hero__badge {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-xs);
  background: rgba(184,146,42,0.2);
  border: 1px solid var(--color-accent);
  color: var(--color-accent-lt);
  font-size: var(--fz-sm);
  padding: 0.35rem var(--sp-sm);
  border-radius: 2rem;
  margin-bottom: var(--sp-sm);
  font-weight: 500;
}

.page-hero__lead {
  font-size: var(--fz-lg);
  color: rgba(255,255,255,0.85);
  max-width: 60ch;
  margin-bottom: var(--sp-lg);
}

/* Homepage Hero */
.hero { background: var(--color-primary); color: var(--color-white); padding: var(--sp-2xl) 0; }
.hero__inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-xl);
  align-items: center;
}
.hero__content h1 { color: var(--color-white); margin-bottom: var(--sp-md); }
.hero__lead {
  font-size: var(--fz-lg);
  color: rgba(255,255,255,0.85);
  margin-bottom: var(--sp-lg);
  max-width: 58ch;
}
.hero__image img {
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  border: 3px solid var(--color-accent);
}

/* 9. Buttons & CTAs
   ============================================================ */
.btn {
  display: inline-flex;
  align-items: center;
  gap: var(--sp-xs);
  padding: 0.85rem 1.8rem;
  border-radius: var(--radius);
  font-size: var(--fz-base);
  font-weight: 600;
  cursor: pointer;
  border: 2px solid transparent;
  transition: background var(--transition), color var(--transition), border-color var(--transition), transform var(--transition);
  text-decoration: none;
  line-height: 1.2;
}
.btn:hover { text-decoration: none; transform: translateY(-1px); }
.btn:active { transform: translateY(0); }

.btn--primary {
  background: var(--color-accent);
  color: var(--color-white);
  border-color: var(--color-accent);
}
.btn--primary:hover { background: var(--color-accent-lt); border-color: var(--color-accent-lt); }

.btn--outline {
  background: transparent;
  color: var(--color-white);
  border-color: rgba(255,255,255,0.5);
}
.btn--outline:hover { border-color: var(--color-white); background: rgba(255,255,255,0.1); }

.btn--outline-dark {
  background: transparent;
  color: var(--color-primary);
  border-color: var(--color-primary);
}
.btn--outline-dark:hover { background: var(--color-primary); color: var(--color-white); }

.btn-group {
  display: flex;
  gap: var(--sp-sm);
  flex-wrap: wrap;
  align-items: center;
}

/* CTA Section */
.cta-section {
  background: var(--color-primary);
  color: var(--color-white);
  padding: var(--sp-xl) 0;
  text-align: center;
}
.cta-section h2 { color: var(--color-white); margin-bottom: var(--sp-sm); }
.cta-section .lead { color: rgba(255,255,255,0.8); margin: 0 auto var(--sp-lg); }
.cta-section .btn-group { justify-content: center; }

.cta-inline {
  background: var(--color-bg-subtle);
  border-left: 4px solid var(--color-accent);
  padding: var(--sp-lg);
  border-radius: 0 var(--radius) var(--radius) 0;
  margin-top: var(--sp-xl);
}
.cta-inline h3 { color: var(--color-primary); margin-bottom: var(--sp-xs); }
.cta-inline p { max-width: none; margin-bottom: var(--sp-md); }

/* 10. Trust-Bar
   ============================================================ */
.trust-bar {
  background: var(--color-bg-subtle);
  border-top: 1px solid var(--color-border);
  border-bottom: 1px solid var(--color-border);
  padding: var(--sp-md) 0;
}

.trust-bar__list {
  display: flex;
  gap: var(--sp-lg);
  flex-wrap: wrap;
  justify-content: center;
  align-items: center;
}

.trust-bar__item {
  display: flex;
  align-items: center;
  gap: var(--sp-xs);
  font-size: var(--fz-sm);
  color: var(--color-text-muted);
  font-weight: 500;
}

.trust-bar__item svg {
  color: var(--color-accent);
  flex-shrink: 0;
}

/* 11. Service Cards
   ============================================================ */
.services-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
  gap: var(--sp-md);
}

.service-card {
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  padding: var(--sp-lg);
  transition: box-shadow var(--transition), transform var(--transition), border-color var(--transition);
  display: flex;
  flex-direction: column;
}

.service-card:hover {
  box-shadow: var(--shadow);
  transform: translateY(-3px);
  border-color: var(--color-accent);
  text-decoration: none;
}

.service-card__icon {
  width: 48px;
  height: 48px;
  background: rgba(184,146,42,0.12);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: var(--sp-sm);
  color: var(--color-accent);
}

.service-card h3 { color: var(--color-primary); margin-bottom: var(--sp-xs); }
.service-card p { color: var(--color-text-muted); flex: 1; font-size: var(--fz-sm); margin-bottom: var(--sp-sm); }
.service-card .card-link {
  color: var(--color-accent);
  font-weight: 600;
  font-size: var(--fz-sm);
  display: inline-flex;
  align-items: center;
  gap: 4px;
}

/* 12. Über mich / Portrait-Abschnitt
   ============================================================ */
.about-section__inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-xl);
  align-items: start;
}

.about-section__image img {
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  border-bottom: 4px solid var(--color-accent);
}

.credentials-list {
  margin-top: var(--sp-md);
  display: flex;
  flex-direction: column;
  gap: var(--sp-xs);
}

.credentials-list li {
  display: flex;
  align-items: flex-start;
  gap: var(--sp-xs);
  font-size: var(--fz-sm);
  color: var(--color-text);
}

.credentials-list li::before {
  content: '✓';
  color: var(--color-accent);
  font-weight: 700;
  flex-shrink: 0;
  margin-top: 2px;
}

/* 13. Galerie / Bild-Grid
   ============================================================ */
.image-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: var(--sp-sm);
  margin-top: var(--sp-md);
}

.image-grid img {
  width: 100%;
  height: 260px;
  object-fit: cover;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
}

/* 14. Inhaltsseiten
   ============================================================ */
.content-section__inner {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--sp-xl);
  align-items: start;
}

.content-section__text ul {
  list-style: disc;
  padding-left: var(--sp-md);
  margin-bottom: var(--sp-sm);
}

.content-section__text li { margin-bottom: 0.35rem; }

.highlight-box {
  background: var(--color-bg-subtle);
  border-left: 4px solid var(--color-accent);
  padding: var(--sp-md) var(--sp-lg);
  border-radius: 0 var(--radius) var(--radius) 0;
  margin: var(--sp-md) 0;
  font-size: var(--fz-lg);
  color: var(--color-primary);
  font-family: var(--font-heading);
  font-style: italic;
}

/* 15. Zweispaltige Karten (z.B. Versicherungsschaden)
   ============================================================ */
.two-col-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: var(--sp-md);
  margin-top: var(--sp-md);
}

.info-card {
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-top: 4px solid var(--color-accent);
  border-radius: var(--radius);
  padding: var(--sp-lg);
}

.info-card h3 { color: var(--color-primary); margin-bottom: var(--sp-sm); }
.info-card ul { list-style: disc; padding-left: var(--sp-md); }
.info-card li { margin-bottom: 0.35rem; font-size: var(--fz-sm); }

/* 16. Ablauf / Numbered Steps
   ============================================================ */
.steps-list {
  display: flex;
  flex-direction: column;
  gap: var(--sp-md);
  margin-top: var(--sp-md);
}

.step {
  display: flex;
  gap: var(--sp-md);
  align-items: flex-start;
}

.step__number {
  width: 44px;
  height: 44px;
  min-width: 44px;
  background: var(--color-accent);
  color: var(--color-white);
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  font-size: var(--fz-lg);
  font-weight: 700;
}

.step__content h3 { color: var(--color-primary); font-size: var(--fz-base); margin-bottom: 0.25rem; }
.step__content p { font-size: var(--fz-sm); color: var(--color-text-muted); margin-bottom: 0; }

/* 17. FAQ (details/summary)
   ============================================================ */
.faq-list {
  display: flex;
  flex-direction: column;
  gap: 0;
  border: 1px solid var(--color-border);
  border-radius: var(--radius);
  overflow: hidden;
}

.faq-list details {
  border-bottom: 1px solid var(--color-border);
}
.faq-list details:last-child { border-bottom: none; }

.faq-list summary {
  cursor: pointer;
  padding: var(--sp-md) var(--sp-lg);
  font-weight: 600;
  font-size: var(--fz-base);
  color: var(--color-primary);
  display: flex;
  justify-content: space-between;
  align-items: center;
  user-select: none;
  list-style: none;
  transition: background var(--transition);
}
.faq-list summary::-webkit-details-marker { display: none; }

.faq-list summary::after {
  content: '+';
  font-size: 1.4rem;
  font-weight: 300;
  color: var(--color-accent);
  line-height: 1;
  flex-shrink: 0;
  margin-left: var(--sp-sm);
}

details[open] summary::after { content: '−'; }

.faq-list summary:hover { background: var(--color-bg-subtle); }

.faq-answer {
  padding: 0 var(--sp-lg) var(--sp-md);
  color: var(--color-text-muted);
  font-size: var(--fz-sm);
  line-height: var(--lh);
}
.faq-answer p { max-width: none; }

/* 18. Trust-Badges (Footer)
   ============================================================ */
.trust-badges {
  display: flex;
  gap: var(--sp-sm);
  align-items: center;
  flex-wrap: wrap;
  margin-bottom: var(--sp-sm);
}

.trust-badges img {
  object-fit: contain;
  filter: none;
}

.trust-text {
  font-size: var(--fz-sm);
  color: rgba(255,255,255,0.75);
  margin-bottom: 0.25rem;
}

/* 19. Footer
   ============================================================ */
.site-footer {
  background: var(--color-primary-dk);
  color: rgba(255,255,255,0.85);
  padding-top: var(--sp-xl);
}

.site-footer__grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: var(--sp-lg);
  padding-bottom: var(--sp-xl);
}

.site-footer h3 {
  color: var(--color-accent-lt);
  font-size: var(--fz-sm);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  margin-bottom: var(--sp-sm);
  font-family: var(--font-body);
  font-weight: 700;
}

.site-footer address {
  font-size: var(--fz-sm);
  line-height: 1.8;
}

.site-footer address + address {
  margin-top: var(--sp-md);
}

.site-footer address a {
  color: rgba(255,255,255,0.75);
  transition: color var(--transition);
}
.site-footer address a:hover { color: var(--color-white); text-decoration: none; }

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.footer-links a {
  color: rgba(255,255,255,0.75);
  font-size: var(--fz-sm);
  transition: color var(--transition);
}
.footer-links a:hover { color: var(--color-accent-lt); text-decoration: none; }

.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding: var(--sp-md) 0;
}

.footer-bottom__inner {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: var(--sp-sm);
  font-size: var(--fz-sm);
  color: rgba(255,255,255,0.5);
}

.footer-legal {
  display: flex;
  gap: var(--sp-md);
}

.footer-legal a {
  color: rgba(255,255,255,0.5);
  transition: color var(--transition);
}
.footer-legal a:hover { color: var(--color-white); text-decoration: none; }

/* 20. Breadcrumb
   ============================================================ */
.breadcrumb {
  font-size: var(--fz-sm);
  color: rgba(255,255,255,0.6);
  margin-bottom: var(--sp-md);
}
.breadcrumb a { color: rgba(255,255,255,0.6); }
.breadcrumb a:hover { color: var(--color-white); text-decoration: none; }
.breadcrumb span { margin: 0 0.4rem; }

/* Breadcrumb auf hellen Seiten */
.breadcrumb--light { color: var(--color-text-muted); }
.breadcrumb--light a { color: var(--color-text-muted); }
.breadcrumb--light a:hover { color: var(--color-accent); }

/* 21. Responsive – Tablet (min 768px)
   ============================================================ */
@media (min-width: 768px) {
  .hero__inner {
    grid-template-columns: 1fr 1fr;
  }

  .about-section__inner {
    grid-template-columns: 1fr 2fr;
  }

  .page-hero__inner {
    grid-template-columns: 2fr 1fr;
  }

  .content-section__inner {
    grid-template-columns: 1fr 1fr;
  }
}

/* 22. Responsive – Desktop (min 1024px)
   ============================================================ */
@media (min-width: 1024px) {
  .hero { padding: var(--sp-2xl) 0; }

  .hero__inner {
    grid-template-columns: 3fr 2fr;
    gap: var(--sp-2xl);
  }

  .about-section__inner {
    grid-template-columns: 300px 1fr;
    gap: var(--sp-2xl);
  }

  .site-footer__grid {
    grid-template-columns: 2fr 1fr 1fr 1fr;
  }
}

/* 23. Responsive – Mobile Navigation (max 900px)
   ============================================================ */
@media (max-width: 900px) {
  .nav-toggle-label {
    display: flex;
    z-index: 200;
  }

  .main-nav {
    position: absolute;
    top: 100%;
    left: 0;
    right: 0;
    background: var(--color-bg);
    border-top: 1px solid var(--color-border);
    box-shadow: var(--shadow);
    max-height: 0;
    overflow: hidden;
    transition: max-height 0.3s ease;
  }

  .nav-toggle-checkbox:checked ~ .main-nav {
    max-height: 600px;
  }

  .nav-toggle-checkbox:checked ~ .nav-toggle-label span:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
  }
  .nav-toggle-checkbox:checked ~ .nav-toggle-label span:nth-child(2) {
    opacity: 0;
  }
  .nav-toggle-checkbox:checked ~ .nav-toggle-label span:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
  }

  .nav-list {
    flex-direction: column;
    padding: var(--sp-sm) 0;
  }

  .nav-list a {
    padding: 0.8rem var(--sp-md);
    display: block;
    border-radius: 0;
    border-bottom: 1px solid var(--color-border);
  }

  .nav-list li:last-child a { border-bottom: none; }

  .site-header { position: relative; }
  .site-header__inner { position: relative; }
}

/* 24. Druckstile
   ============================================================ */
@media print {
  .top-bar, .site-header, .site-footer, .btn, .cta-section { display: none; }
  body { font-size: 12pt; }
  a[href]::after { content: ' (' attr(href) ')'; font-size: 10pt; }
}
