/* ===== LOCAL FONTS ===== */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 300 700;
  font-display: swap;
  src: url('../fonts/inter-normal-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'Cormorant Garamond';
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url('../fonts/cormorant-garamond-normal-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'Cormorant Garamond';
  font-style: italic;
  font-weight: 400 500;
  font-display: swap;
  src: url('../fonts/cormorant-garamond-italic-latin.woff2') format('woff2');
}

/* ===== RESET & BASE ===== */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }
html { scroll-behavior: smooth; font-size: 16px; }
body {
  font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  font-size: var(--fs-body); color: #1a1a1a; line-height: 1.7;
  -webkit-font-smoothing: antialiased; overflow-x: hidden;
}

/* ===== BRAND COLORS (from business card) ===== */
:root {
  --primary: #00196E;
  --primary-light: #1a3a8a;
  --primary-dark: #000e3d;
  --accent: #C4A06C;
  --accent-light: #d4b88a;
  --accent-dark: #a8844e;
  --bg-light: #F8F7F4;
  --bg-white: #FFFFFF;
  --bg-blue-tint: #F0F2F8;
  --text-dark: #1a1a1a;
  --text-medium: #4a4a4a;
  --text-light: #7a7a7a;
  --border: #e0e0e0;
  --shadow: 0 4px 20px rgba(0,0,0,0.08);
  --shadow-lg: 0 8px 40px rgba(0,0,0,0.12);
  --radius: 8px;
  --nav-height: 72px;
  --font-serif: 'Cormorant Garamond', Georgia, 'Times New Roman', serif;

  /* Font sizes */
  --fs-micro: 0.7rem;
  --fs-xs: 0.75rem;
  --fs-small: 0.82rem;
  --fs-sm: 0.85rem;
  --fs-body: 1rem;
  --fs-lead: 1.05rem;
  --fs-subtitle: clamp(1.05rem, 1.3vw, 1.2rem);
  --fs-tagline: clamp(1.1rem, 1.8vw, 1.4rem);
  --fs-h3: clamp(1.3rem, 2vw, 1.6rem);
  --fs-h2: clamp(2rem, 3.5vw, 3rem);
  --fs-h1: clamp(2.4rem, 5vw, 4rem);
}

/* ===== FONT SIZE CLASSES ===== */
.text-h1   { font-size: var(--fs-h1); }
.text-h2   { font-size: var(--fs-h2); }
.text-h3   { font-size: var(--fs-h3); }
.text-lead     { font-size: var(--fs-lead); }
.text-body     { font-size: var(--fs-body); }
.text-sm       { font-size: var(--fs-sm); }
.text-small    { font-size: var(--fs-small); }
.text-xs       { font-size: var(--fs-xs); }
.text-micro    { font-size: var(--fs-micro); }

/* ===== TYPOGRAPHY ===== */
h1, h2, h3, h4, h5 { font-family: var(--font-serif); font-weight: 600; line-height: 1.25; color: var(--primary); }
h1 { font-size: var(--fs-h1); font-weight: 700; }
h2 { font-size: var(--fs-h2); font-weight: 600; letter-spacing: -0.01em; }
h3 { font-size: var(--fs-h3); font-weight: 600; }
.section-subtitle {
  font-family: var(--font-serif); font-size: var(--fs-subtitle);
  color: var(--accent); font-weight: 500; font-style: italic;
  margin-bottom: 0.5rem; letter-spacing: 0.02em;
}
.nobr {
  white-space: nowrap;
}

/* ===== HEADER / NAVIGATION ===== */
header {
  position: fixed; top: 0; left: 0; right: 0; z-index: 1000;
  height: var(--nav-height);
  transition: all 0.4s cubic-bezier(0.25, 0.46, 0.45, 0.94);
  display: flex; align-items: center;
  background: var(--primary);
  box-shadow: 0 2px 20px rgba(0,0,0,0.15);
}
nav {
  width: 100%; max-width: 1200px; margin: 0 auto;
  display: flex; align-items: center; justify-content: space-between;
  padding: 0 24px;
}
.nav-logo {
  display: flex; align-items: center; gap: 12px; text-decoration: none;
}
.nav-logo img { height: 38px; width: auto; }
.nav-logo-text {
  font-family: var(--font-serif); font-size: 1.15rem; font-weight: 600;
  color: #ffffff; line-height: 1.2;
}
.nav-logo-text small {
  display: block; font-family: 'Inter', sans-serif;
  font-size: var(--fs-micro); font-weight: 400; color: rgba(255,255,255,0.7);
}
.nav-links { display: flex; align-items: center; gap: 2px; list-style: none; }
.nav-links a {
  text-decoration: none; font-weight: 500;
  color: rgba(255,255,255,0.85);
  padding: 8px 14px; border-radius: 6px; transition: all 0.2s;
  white-space: nowrap;
}
.nav-links a:hover, .nav-links a.active {
  color: #ffffff;
  background: rgba(255,255,255,0.12);
}
.nav-toggle {
  display: none; flex-direction: column; gap: 5px;
  cursor: pointer; padding: 8px; background: none; border: none;
}
.nav-toggle span {
  display: block; width: 24px; height: 2px;
  background: #ffffff; border-radius: 2px; transition: all 0.3s;
}

/* ===== HERO ===== */
.hero {
  position: relative; min-height: 100vh;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  overflow: hidden;
}
.hero::before {
  content: '';
  position: absolute; inset: 0;
  background:
    radial-gradient(ellipse 80% 60% at 50% 20%, rgba(196,160,108,0.08) 0%, transparent 70%),
    radial-gradient(ellipse 60% 50% at 80% 80%, rgba(255,255,255,0.03) 0%, transparent 60%);
  pointer-events: none;
}
.hero-logo-bg {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  pointer-events: none; z-index: 0;
}
.hero-logo-bg img {
  width: min(90vw, 800px); height: auto;
  opacity: 0.1;
  filter: brightness(0.5) invert(1);
  transform: scale(1.1);
}
.hero-content {
  position: relative; z-index: 1; text-align: center;
  max-width: 760px; padding: 24px;
}
.hero-content h1 { color: #fff; margin-bottom: 0.5rem; }
.hero-content .hero-tagline {
  font-family: var(--font-serif); font-size: var(--fs-tagline);
  color: var(--accent-light); font-style: italic; margin-bottom: 1.5rem;
}
.hero-content p {
  color: rgba(255,255,255,0.8);
  max-width: 600px; margin: 0 auto 2rem;
}
.hero-badge {
  display: inline-block; padding: 6px 20px; border-radius: 50px;
  background: rgba(255,255,255,0.1); border: 1px solid rgba(255,255,255,0.15);
  color: var(--accent-light); font-size: var(--fs-xs); font-weight: 500;
  margin-bottom: 1.5rem; letter-spacing: 0.05em; text-transform: uppercase;
}
.btn {
  display: inline-block; padding: 14px 36px; border-radius: 50px;
  font-size: var(--fs-body); font-weight: 600; text-decoration: none;
  transition: all 0.3s; border: none; cursor: pointer;
}
.btn-primary { background: var(--accent); color: var(--primary-dark); }
.btn-primary:hover {
  background: var(--accent-light); transform: translateY(-2px);
  box-shadow: 0 8px 24px rgba(196,160,108,0.35);
}
.btn-outline { background: transparent; color: #fff; border: 2px solid rgba(255,255,255,0.3); }
.btn-outline:hover { background: rgba(255,255,255,0.1); border-color: rgba(255,255,255,0.5); }
.hero-buttons { display: flex; gap: 16px; justify-content: center; flex-wrap: wrap; }
.scroll-indicator {
  position: absolute; bottom: 32px; left: 50%; transform: translateX(-50%);
  z-index: 1; display: flex; flex-direction: column; align-items: center; gap: 8px;
  color: rgba(255,255,255,0.4); font-size: var(--fs-micro);
  letter-spacing: 0.1em; text-transform: uppercase;
  text-decoration: none; animation: bounce 2s infinite;
}
.scroll-indicator svg { width: 20px; height: 20px; }
@keyframes bounce {
  0%, 100% { transform: translateX(-50%) translateY(0); }
  50% { transform: translateX(-50%) translateY(8px); }
}

/* ===== SECTIONS ===== */
section { padding: 80px 24px; position: relative; }
.section-inner { max-width: 1120px; margin: 0 auto; }
.section-header { text-align: center; max-width: 720px; margin: 0 auto 3rem; }
.section-header p { color: var(--text-medium); font-size: var(--fs-lead); }
.section-white { background: var(--bg-white); }
.section-light { background: var(--bg-light); }
.section-blue-tint { background: var(--bg-blue-tint); }
.section-primary { background: var(--primary); color: #fff; }
.section-primary h2, .section-primary h3 { color: #fff; }
.section-primary .section-subtitle { color: var(--accent-light); }
.section-primary p { color: rgba(255,255,255,0.85); }
.section-gold { background: rgba(196, 160, 108, 0.6); }
.section-gold .section-subtitle { color: #ffffff; }
.section-gold .two-col h3 i { color: #ffffff; }
.section-gold .service-item .dot { background: var(--primary); }
.section-gold .service-list { max-width: 800px; margin: 0 auto; }

/* ===== PRACTICE AREAS (Startseite) ===== */
.practice-grid {
  display: grid; grid-template-columns: repeat(3, 1fr);
  gap: 24px; margin-top: 2rem;
}
.practice-card {
  background: var(--bg-white); border-radius: var(--radius);
  padding: 32px 28px; box-shadow: var(--shadow);
  border: 1px solid var(--border);
  transition: all 0.3s; text-align: center;
}
.practice-card:hover { transform: translateY(-4px); box-shadow: var(--shadow-lg); }
.practice-card .icon {
  width: 75px; height: 75px; border-radius: 50%;
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-light) 100%);
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 1rem; font-size: 2.5rem; color: #fff;
}
.practice-card h3 { margin-bottom: 0.75rem; }
.practice-card p { color: var(--text-medium); }

/* ===== SCHULDNERBERATUNG (Steps) ===== */
.section-schuldnerberatung {
  position: relative;
  overflow: hidden;
}
.schuldnerberatung-bg {
  position: absolute;
  top: 0; right: 0; bottom: 0;
  width: 100%;
  pointer-events: none;
  z-index: 0;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  overflow: hidden;
}
.schuldnerberatung-bg img {
  height: 120%;
  width: auto;
  opacity: 0.20;
  transform: translateX(15%);
}
.section-schuldnerberatung .section-inner {
  position: relative;
  z-index: 1;
}
.steps-grid {
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 28px; counter-reset: step;
}
.step-card {
  counter-increment: step; text-align: center; padding: 32px 20px;
  background: var(--bg-white); border-radius: var(--radius);
  box-shadow: var(--shadow); border: 1px solid var(--border);
  transition: all 0.3s; position: relative;
}
.step-card:hover { transform: translateY(-3px); box-shadow: var(--shadow-lg); }
.step-card::before {
  content: counter(step);
  width: 44px; height: 44px; border-radius: 50%;
  background: var(--primary); color: #fff;
  display: flex; align-items: flex-end; justify-content: center;
  font-family: var(--font-serif); font-size: 2rem; font-weight: 700;
  margin: 0 auto 1rem;
}
.step-card h3 { margin-bottom: 0.6rem; }
.step-card p { color: var(--text-medium); }

/* ===== INSOLVENZRECHT ===== */
.insolvenzrecht-layout {
  display: flex;
  gap: 48px;
  align-items: flex-start;
}
.insolvenzrecht-image {
  flex: 0 0 42%;
  max-width: 42%;
  border-radius: var(--radius);
  overflow: hidden;
}
.insolvenzrecht-image img {
  width: 100%;
  height: auto;
  display: block;
}
.insolvenzrecht-content {
  flex: 1;
  min-width: 0;
}
@media (max-width: 900px) {
  .insolvenzrecht-layout {
    flex-direction: column;
    gap: 24px;
  }
  .insolvenzrecht-image {
    flex: none;
    max-width: 100%;
  }
}

/* ===== ARBEITSRECHT ===== */
.service-list { max-width: 800px; margin: 0 auto; }
.service-item {
  display: flex; align-items: flex-start; gap: 14px; padding: 14px 0;
  border-bottom: 1px solid rgba(0,0,0,0.06);
}
.service-item:last-child { border-bottom: none; }
.service-item .dot {
  flex-shrink: 0; width: 8px; height: 8px; border-radius: 50%;
  background: var(--accent); margin-top: 10px;
}
.service-item span { color: var(--text-medium); }
.section-primary .service-item { border-bottom-color: rgba(255,255,255,0.1); }
.section-primary .service-item span { color: rgba(255,255,255,0.9); }
.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; }
.two-col h3 { margin-bottom: 1.2rem; }
.two-col h3 i { color: var(--accent); margin-right: 8px; }

/* ===== ÜBER UNS ===== */
.profile-grid { display: grid; grid-template-columns: 1fr; gap: 48px; }
.profile-card {
  background: var(--bg-white); border-radius: var(--radius);
  box-shadow: var(--shadow); padding: 32px; border: 1px solid var(--border);
}
.profile-card .photo {
  width: 120px; height: 120px; border-radius: 50%; object-fit: cover;
  float: left; margin: 0 24px 12px 0;   background: var(--bg-blue-tint);
}
.profile-card h3 { margin-bottom: 0.2rem; }
.profile-card .title { color: var(--accent); font-weight: 500; margin-bottom: 0.1rem; }
.profile-card .subtitle { color: var(--text-light); margin-bottom: 1rem; }
.profile-card p { color: var(--text-medium); margin-bottom: 0.6rem; }
.profile-card ul { list-style: none; padding: 0; }
.profile-card ul li {
  padding: 4px 0; padding-left: 18px; position: relative;
  color: var(--text-medium);
}
.profile-card ul li::before { content: '•'; position: absolute; left: 0; color: var(--accent); font-weight: 700; }
.publications { margin-top: 1.2rem; }
.publications h4 { font-family: var(--font-serif); color: var(--primary); font-size: 1.1rem; margin-bottom: 0.5rem; }
.publications ul li { font-size: var(--fs-sm); color: var(--text-light); }
.of-counsel-badge {
  display: inline-block; padding: 4px 14px; border-radius: 50px;
  background: var(--accent); color: var(--primary-dark);
  font-size: var(--fs-xs); font-weight: 600; letter-spacing: 0.05em;
  margin-bottom: 0.75rem; text-transform: uppercase;
}

/* ===== KONTAKT ===== */
.contact-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 48px; align-items: start; }
.contact-info h3 { margin-bottom: 1rem; }
.contact-info .detail { display: flex; gap: 12px; margin-bottom: 1rem; }
.contact-info .detail-icon {
  width: 40px; height: 40px; border-radius: 50%;
  background: var(--bg-blue-tint); color: var(--primary);
  display: flex; align-items: center; justify-content: center;
  flex-shrink: 0; font-size: 1rem;
}
.contact-info .detail-text { color: var(--text-medium); }
.contact-info .detail-text strong { color: var(--text-dark); display: block; }
.contact-form {
  background: var(--bg-white); border-radius: var(--radius);
  padding: 32px; box-shadow: var(--shadow); border: 1px solid var(--border);
}
.contact-form label { display: block; font-weight: 500; color: var(--text-dark); margin-bottom: 4px; }
.contact-form input, .contact-form textarea {
  width: 100%; padding: 12px 16px; border-radius: 6px; border: 1px solid var(--border);
  font-family: 'Inter', sans-serif;
  transition: border-color 0.2s; margin-bottom: 1rem;
  background: var(--bg-light);
}
.contact-form input:focus, .contact-form textarea:focus {
  outline: none; border-color: var(--primary); background: var(--bg-white);
}
.contact-form textarea { min-height: 120px; resize: vertical; }
.contact-form button { width: 100%; }
.form-honeypot {
  position: absolute !important; left: -10000px !important;
  width: 1px !important; height: 1px !important; overflow: hidden !important;
}
.form-status { min-height: 1.7em; margin-top: 0.8rem; text-align: center; }
.form-status.is-success { color: #216e39; }
.form-status.is-error { color: #a12622; }
.contact-form button:disabled { cursor: wait; opacity: 0.7; transform: none; }
.directions {
  margin-top: 2rem; padding: 24px;
  background: var(--bg-white); border-radius: var(--radius);
  border: 1px solid var(--border);
}
.directions h4 { font-family: var(--font-serif); color: var(--primary); margin-bottom: 1rem; }
.directions .dir-item { display: flex; gap: 12px; margin-bottom: 0.8rem; }
.directions .dir-icon { color: var(--accent); font-weight: 700; flex-shrink: 0; width: 70px; }
.directions .dir-text { color: var(--text-medium); }

/* ===== IMPRESSUM / FOOTER ===== */
.footer {
  background: var(--primary-dark); color: rgba(255,255,255,0.7);
  padding: 60px 24px 32px;
}
.footer-inner { max-width: 1120px; margin: 0 auto; }
.footer-grid { display: grid; grid-template-columns: 2fr 1fr 1fr 1fr; gap: 40px; margin-bottom: 40px; }
.footer h4 { color: #fff; font-family: var(--font-serif); font-size: 1.15rem; margin-bottom: 1rem; }
.footer p, .footer a { color: rgba(255,255,255,0.6); line-height: 1.8; text-decoration: none; }
.footer a:hover { color: var(--accent-light); }
.footer ul { list-style: none; }
.footer ul li { padding: 2px 0; }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.1);
  padding-top: 24px; text-align: center;
  font-size: var(--fs-small); color: rgba(255,255,255,0.4);
}
.footer .impressum-text { color: rgba(255,255,255,0.5); line-height: 1.6; margin-top: 0.5rem; }

/* ===== LEGAL MODALS ===== */
body.modal-open { overflow: hidden; }
.legal-modal {
  position: fixed; inset: 0; z-index: 2000;
  display: flex; align-items: center; justify-content: center;
  padding: 24px;
}
.legal-modal[hidden] { display: none; }
.legal-modal-backdrop {
  position: absolute; inset: 0;
  background: rgba(0, 14, 61, 0.82);
  backdrop-filter: blur(4px);
}
.legal-modal-dialog {
  position: relative; z-index: 1;
  width: min(920px, 100%); max-height: calc(100vh - 48px);
  overflow-y: auto; overscroll-behavior: contain;
  background: var(--bg-white); border-radius: var(--radius);
  border-top: 5px solid var(--accent); box-shadow: var(--shadow-lg);
}
.legal-modal-content { padding: 48px 56px 56px; }
.legal-modal-content h2 { margin-bottom: 1.5rem; padding-right: 32px; }
.legal-modal-content h3 { margin: 2rem 0 0.8rem; font-size: 1.55rem; }
.legal-modal-content h4 { margin: 1.5rem 0 0.6rem; font-size: 1.2rem; color: var(--primary); }
.legal-modal-content p { margin-bottom: 1rem; color: var(--text-medium); }
.legal-modal-content ul { margin: 0 0 1.25rem 1.4rem; color: var(--text-medium); }
.legal-modal-content li { margin-bottom: 0.65rem; }
.legal-modal-content a { color: var(--primary); text-decoration-color: var(--accent); }
.legal-modal-close {
  position: sticky; top: 14px; float: right; z-index: 2;
  width: 42px; height: 42px; margin: 14px 14px -56px 0;
  border: 0; border-radius: 50%; cursor: pointer;
  background: var(--primary); color: #fff;
  font-size: 1.8rem; line-height: 1;
  box-shadow: var(--shadow); transition: background 0.2s, transform 0.2s;
}
.legal-modal-close:hover { background: var(--primary-light); transform: scale(1.05); }
.legal-modal-close:focus-visible { outline: 3px solid var(--accent); outline-offset: 2px; }

/* ===== RESPONSIVE ===== */
@media (max-width: 1024px) {
  .contact-grid { grid-template-columns: 1fr; gap: 32px; }
  .steps-grid { grid-template-columns: repeat(2, 1fr); }
  .two-col { grid-template-columns: 1fr; gap: 32px; }
  .footer-grid { grid-template-columns: 1fr 1fr; }
}
@media (max-width: 768px) {
  header.scrolled .nav-links,
  .nav-links {
    display: none;
    position: absolute; top: var(--nav-height); left: 0; right: 0;
    background: var(--primary);
    flex-direction: column; padding: 16px; box-shadow: var(--shadow-lg); gap: 4px;
  }
  header.scrolled .nav-links.open,
  .nav-links.open { display: flex; }
  .nav-links a { width: 100%; padding: 12px 16px; color: rgba(255,255,255,0.85); }
  .nav-links a:hover, .nav-links a.active { background: rgba(255,255,255,0.12); color: #fff; }
  .nav-toggle { display: flex; }
  section { padding: 56px 20px; }
  .practice-grid, .steps-grid { grid-template-columns: 1fr; }
  .hero-content h1 { font-size: var(--fs-h2); }
  .footer-grid { grid-template-columns: 1fr; }
  .profile-card .photo { float: none; margin: 0 0 1rem 0; shape-outside: none; }
  .schuldnerberatung-bg { width: 70%; }
  .schuldnerberatung-bg img { height: 80%; }
  .legal-modal { padding: 12px; }
  .legal-modal-dialog { max-height: calc(100vh - 24px); }
  .legal-modal-content { padding: 36px 24px 40px; }
}
