/* =====================================================================
   Steuerkanzlei Schleicher – Modernes Stylesheet
   Corporate Identity: Navy #1f3a5f · Slate-Blau #6d86b3 · Orange #f4511e
   Standalone (ohne Bootstrap/jQuery) · responsiv · WCAG-orientiert
   ===================================================================== */

/* ---------- Farb-Schema ----------
   Feste Light-CI für alle: verhindert das automatische (kontrastarme)
   Abdunkeln durch Auto-Dark-Mode mobiler Browser. */
:root { color-scheme: only light; }

/* ---------- Design Tokens ---------- */
:root {
  --navy:        #1f3a5f;
  --navy-dark:   #152a45;
  --navy-900:    #0f2440;
  --blue:        #6d86b3;
  --blue-soft:   #eef2f8;
  --accent:      #f4511e;
  --accent-dark: #d63e10;
  --red:         #cc0000;

  --ink:     #1b2733;
  --text:    #4b5768;
  --muted:   #7a8695;
  --line:    #e4e8ef;

  --surface:      #ffffff;
  --surface-alt:  #f5f7fa;
  --surface-alt2: #eaeef4;

  --focus: #ffbf47;

  --radius:    16px;
  --radius-sm: 10px;
  --radius-pill: 999px;

  --shadow-sm: 0 1px 2px rgba(16,31,54,.05), 0 1px 3px rgba(16,31,54,.06);
  --shadow:    0 12px 34px -14px rgba(16,31,54,.20);
  --shadow-lg: 0 28px 64px -22px rgba(16,31,54,.30);

  --container: 1160px;
  --header-h: 76px;

  --ease: cubic-bezier(.22,.61,.36,1);
}

/* ---------- Fonts ---------- */
@font-face {
  font-family: "Lato";
  src: url("../fonts/Lato/Lato-Regular.ttf") format("truetype");
  font-weight: 400;
  font-display: swap;
}

/* ---------- Reset / Base ---------- */
*, *::before, *::after { box-sizing: border-box; }

html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  font-family: "Lato", system-ui, -apple-system, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  font-size: clamp(15.5px, 0.4vw + 15px, 17px);
  line-height: 1.75;
  color: var(--text);
  background: var(--surface);
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

img { max-width: 100%; height: auto; display: block; }

a { color: var(--navy); text-decoration: none; transition: color .2s var(--ease); }
a:hover { color: var(--accent); }

h1, h2, h3, h4 { color: var(--ink); line-height: 1.2; margin: 0 0 .6em; font-weight: 800; }

h2 {
  font-size: clamp(1.6rem, 2.4vw + 1rem, 2.35rem);
  letter-spacing: -0.01em;
}
h3 { font-size: clamp(1.2rem, 1vw + .9rem, 1.5rem); font-weight: 700; }
h4 { font-size: 1.1rem; font-weight: 700; color: var(--navy); }

p { margin: 0 0 1.05em; }
p:last-child { margin-bottom: 0; }

strong { color: var(--ink); font-weight: 700; }

::selection { background: var(--accent); color: #fff; }

/* ---------- Layout helpers ---------- */
.container {
  width: 100%;
  max-width: var(--container);
  margin-inline: auto;
  padding-inline: clamp(20px, 5vw, 40px);
}

.section { padding: clamp(56px, 8vw, 104px) 0; }
.section--alt  { background: var(--surface-alt); }
.section--alt2 { background: var(--surface-alt2); }
.section--navy {
  background: linear-gradient(160deg, var(--navy) 0%, var(--navy-900) 100%);
  color: #cdd6e4;
}
.section--navy h2, .section--navy h3, .section--navy h4 { color: #fff; }
.section--navy strong { color: #fff; }
.section--navy a { color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.section--navy a:hover { color: var(--accent); }

.section-head { max-width: 760px; margin: 0 auto clamp(36px, 5vw, 56px); text-align: center; }
.section-head p { color: var(--muted); font-size: 1.08rem; }
.section--navy .section-head p { color: #b7c2d6; }

.eyebrow {
  display: inline-block;
  font-size: .78rem;
  font-weight: 800;
  letter-spacing: .18em;
  text-transform: uppercase;
  color: var(--accent);
  margin-bottom: .9rem;
}

.lead { font-size: clamp(1.05rem, .6vw + 1rem, 1.25rem); color: var(--text); }

/* ---------- Buttons ---------- */
.btn {
  --btn-bg: var(--accent);
  --btn-fg: #fff;
  display: inline-flex;
  align-items: center;
  gap: .5em;
  padding: .85em 1.6em;
  border-radius: var(--radius-pill);
  background: var(--btn-bg);
  color: var(--btn-fg);
  font-weight: 700;
  font-size: .98rem;
  letter-spacing: .01em;
  border: 2px solid transparent;
  cursor: pointer;
  transition: transform .2s var(--ease), box-shadow .2s var(--ease), background .2s var(--ease), color .2s var(--ease);
  box-shadow: 0 10px 24px -12px rgba(244,81,30,.7);
}
.btn:hover { transform: translateY(-2px); color: #fff; box-shadow: 0 16px 30px -12px rgba(244,81,30,.8); }
.btn:active { transform: translateY(0); }

.btn--ghost {
  --btn-bg: transparent;
  --btn-fg: #fff;
  border-color: rgba(255,255,255,.5);
  box-shadow: none;
}
.btn--ghost:hover { background: rgba(255,255,255,.12); border-color: #fff; box-shadow: none; }

.btn--outline {
  --btn-bg: transparent;
  --btn-fg: var(--navy);
  border-color: var(--line);
  box-shadow: none;
}
.btn--outline:hover { background: var(--navy); color: #fff; border-color: var(--navy); box-shadow: none; }

/* ---------- Header / Nav ---------- */
.site-header {
  position: fixed;
  inset: 0 0 auto 0;
  height: var(--header-h);
  z-index: 1000;
  background: rgba(255,255,255,.82);
  backdrop-filter: saturate(180%) blur(14px);
  -webkit-backdrop-filter: saturate(180%) blur(14px);
  border-bottom: 1px solid var(--line);
  transition: box-shadow .3s var(--ease), background .3s var(--ease);
}
.site-header.is-scrolled { box-shadow: 0 6px 24px -14px rgba(16,31,54,.28); background: rgba(255,255,255,.94); }

.nav {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
}
.nav__brand { display: flex; align-items: center; flex: 0 0 auto; }
.nav__brand img { height: 42px; width: auto; }

.nav__links {
  display: flex;
  align-items: center;
  gap: clamp(4px, 1vw, 14px);
  list-style: none;
  margin: 0;
  padding: 0;
}
.nav__links a {
  display: inline-block;
  padding: .5em .7em;
  font-size: .82rem;
  font-weight: 700;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--navy);
  border-radius: 8px;
  position: relative;
}
.nav__links a::after {
  content: "";
  position: absolute;
  left: .7em; right: .7em; bottom: .28em;
  height: 2px;
  background: var(--accent);
  transform: scaleX(0);
  transform-origin: left;
  transition: transform .25s var(--ease);
}
.nav__links a:hover, .nav__links a.is-active { color: var(--accent); }
.nav__links a:hover::after, .nav__links a.is-active::after { transform: scaleX(1); }

.nav__toggle {
  display: none;
  width: 46px; height: 46px;
  border: 0;
  background: transparent;
  cursor: pointer;
  padding: 10px;
  border-radius: 10px;
}
.nav__toggle span {
  display: block;
  height: 2px;
  background: var(--navy);
  border-radius: 2px;
  transition: transform .3s var(--ease), opacity .2s var(--ease);
}
.nav__toggle span + span { margin-top: 5px; }
.nav[data-open="true"] .nav__toggle span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.nav[data-open="true"] .nav__toggle span:nth-child(2) { opacity: 0; }
.nav[data-open="true"] .nav__toggle span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* ---------- Hero ---------- */
.hero {
  position: relative;
  margin-top: var(--header-h);
  padding: clamp(64px, 12vw, 130px) 0 clamp(60px, 9vw, 110px);
  background:
    radial-gradient(1100px 520px at 78% -10%, rgba(109,134,179,.30), transparent 60%),
    radial-gradient(900px 500px at 0% 110%, rgba(244,81,30,.10), transparent 55%),
    linear-gradient(155deg, var(--navy) 0%, var(--navy-900) 100%);
  color: #dbe3f0;
  overflow: hidden;
}
.hero::after {
  content: "";
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(rgba(255,255,255,.04) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255,255,255,.04) 1px, transparent 1px);
  background-size: 46px 46px;
  mask-image: radial-gradient(circle at 70% 20%, #000, transparent 75%);
  -webkit-mask-image: radial-gradient(circle at 70% 20%, #000, transparent 75%);
  pointer-events: none;
}
.hero__inner { position: relative; max-width: 760px; }
.hero__logo {
  display: block;
  width: 100%;
  background: #fff;
  padding: clamp(20px, 3.4vw, 38px) clamp(26px, 4.5vw, 52px);
  border-radius: 22px;
  box-shadow: var(--shadow-lg);
  margin-bottom: 1.6rem;
}
.hero__logo img { width: 100%; height: auto; }
.hero h1 {
  color: #fff;
  font-size: clamp(2.1rem, 4vw + 1rem, 3.6rem);
  line-height: 1.08;
  letter-spacing: -0.02em;
  margin-bottom: .45em;
}
.hero .lead { color: #c3cee0; max-width: 60ch; }
.hero__actions { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 2rem; }

.hero__badge {
  display: flex;
  width: fit-content;
  align-items: center;
  gap: .6em;
  padding: .5em 1.1em;
  margin-bottom: 1.6rem;
  border: 1px solid rgba(255,255,255,.22);
  border-radius: var(--radius-pill);
  background: rgba(255,255,255,.06);
  font-size: .82rem;
  font-weight: 700;
  letter-spacing: .04em;
  color: #dbe3f0;
}
.hero__badge .dot { width: 8px; height: 8px; border-radius: 50%; background: var(--accent); box-shadow: 0 0 0 4px rgba(244,81,30,.25); }

/* ---------- Generic two-column ---------- */
.split {
  display: grid;
  grid-template-columns: 1.15fr .85fr;
  gap: clamp(28px, 5vw, 64px);
  align-items: center;
}
.split--rev .split__media { order: -1; }

.media-badge {
  aspect-ratio: 1;
  width: min(320px, 80%);
  margin-inline: auto;
  border-radius: 28px;
  display: grid;
  place-items: center;
  background: linear-gradient(150deg, var(--blue-soft), #fff);
  border: 1px solid var(--line);
  box-shadow: var(--shadow);
  color: var(--navy);
}
.media-badge svg { width: 44%; height: 44%; }
.section--navy .media-badge { background: rgba(255,255,255,.06); border-color: rgba(255,255,255,.14); color: #fff; }

/* ---------- Feature cards ---------- */
.grid { display: grid; gap: clamp(18px, 2.4vw, 28px); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }

.card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(24px, 3vw, 34px);
  box-shadow: var(--shadow-sm);
  transition: transform .3s var(--ease), box-shadow .3s var(--ease), border-color .3s var(--ease);
  height: 100%;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow); border-color: #d5dce7; }

.card__icon {
  width: 52px; height: 52px;
  display: grid; place-items: center;
  border-radius: 14px;
  background: linear-gradient(150deg, var(--navy), var(--blue));
  color: #fff;
  margin-bottom: 18px;
}
.card__icon svg { width: 26px; height: 26px; }
.card h4 { margin-bottom: .7em; color: var(--ink); font-size: 1.12rem; }

/* Feature list */
.flist { list-style: none; margin: 0; padding: 0; }
.flist li {
  position: relative;
  padding-left: 1.7em;
  margin-bottom: .55em;
}
.flist li::before {
  content: "";
  position: absolute;
  left: 0; top: .62em;
  width: 8px; height: 8px;
  border-radius: 2px;
  background: var(--accent);
  transform: rotate(45deg);
}
.flist--check li::before {
  content: "";
  left: .1em; top: .5em;
  width: 12px; height: 7px;
  background: none;
  border-left: 2.5px solid var(--accent);
  border-bottom: 2.5px solid var(--accent);
  transform: rotate(-45deg);
  border-radius: 1px;
}

/* ---------- Contact cards ---------- */
.contact-card {
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(24px, 3vw, 32px);
  box-shadow: var(--shadow-sm);
  transition: transform .3s var(--ease), box-shadow .3s var(--ease);
}
.contact-card:hover { transform: translateY(-4px); box-shadow: var(--shadow); }
.contact-card h4 { color: var(--ink); font-size: 1.2rem; margin-bottom: .2em; }
.contact-card .role { color: var(--muted); font-size: .92rem; margin-bottom: 1.2em; }
.contact-list { list-style: none; margin: 0; padding: 0; }
.contact-list li { display: flex; align-items: flex-start; gap: .7em; margin-bottom: .6em; }
.contact-list svg { width: 18px; height: 18px; flex: 0 0 18px; color: var(--accent); margin-top: .35em; }
.contact-list a { color: var(--text); }
.contact-list a:hover { color: var(--accent); }

/* Kanzlei-Karte über die volle Breite, Angaben zentriert nebeneinander */
.contact-lead { margin-bottom: clamp(18px, 2.4vw, 28px); }
.contact-card--wide { text-align: center; }
.contact-card--wide .contact-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: .4em 2.6em;
  margin-top: 1em;
}
.contact-card--wide .contact-list li { margin-bottom: .3em; }

/* 3 Personen-Kacheln: Zeilen (Name/Titel/Telefon+Mail) spaltenübergreifend
   bündig – via Subgrid, damit unterschiedlich lange Titel nicht verrutschen */
@media (min-width: 621px) {
  .grid--align .contact-card {
    display: grid;
    grid-template-rows: subgrid;
    grid-row: span 3;
    row-gap: 0;
  }
}

/* ---------- Historie ---------- */
.figure-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  gap: 14px;
}
.figure-card img {
  width: 170px; height: 170px;
  object-fit: cover;
  border-radius: 50%;
  border: 5px solid #fff;
  box-shadow: var(--shadow);
}

/* ---------- Highlight / phone box ---------- */
.callout {
  background: linear-gradient(150deg, var(--navy), var(--navy-900));
  color: #fff;
  border-radius: var(--radius);
  padding: clamp(22px, 3vw, 30px);
  display: flex;
  align-items: center;
  gap: 18px;
  box-shadow: var(--shadow);
}
.callout svg { width: 40px; height: 40px; flex: 0 0 40px; color: var(--accent); }
.callout .label { font-size: .82rem; letter-spacing: .08em; text-transform: uppercase; color: #aebbd2; margin: 0; }
.callout .num { font-size: 1.5rem; font-weight: 800; color: #fff; margin: 0; }
.callout .num a { color: #fff; text-decoration: none; }

/* ---------- Datenaustausch / login image ---------- */
.login-img { display: inline-block; border-radius: var(--radius-sm); overflow: hidden; box-shadow: var(--shadow); transition: transform .3s var(--ease); }
.login-img:hover { transform: translateY(-3px); }

/* ---------- News (Aktuelles) ---------- */
.news-wrap {
  max-width: 860px;
  margin-inline: auto;
  background: var(--surface);
  border: 1px solid var(--line);
  border-radius: var(--radius);
  padding: clamp(24px, 4vw, 44px);
  box-shadow: var(--shadow-sm);
  text-align: left;
}
.news-wrap a { color: var(--navy); }
.news-wrap a:hover { color: var(--accent); }

/* ---------- Map ---------- */
.map { height: clamp(320px, 45vw, 460px); width: 100%; filter: saturate(.95); }

/* ---------- Partner / DATEV ---------- */
.partner { display: flex; justify-content: center; align-items: center; padding: 40px 0; }
.partner img { opacity: .85; transition: opacity .3s var(--ease); }
.partner img:hover { opacity: 1; }

/* ---------- Rechtstext-/Inhaltsseiten (Impressum, Datenschutz) ---------- */
.page-hero {
  margin-top: var(--header-h);
  background:
    radial-gradient(900px 420px at 85% -20%, rgba(109,134,179,.28), transparent 60%),
    linear-gradient(155deg, var(--navy) 0%, var(--navy-900) 100%);
  color: #dbe3f0;
  padding: clamp(46px, 7vw, 84px) 0 clamp(38px, 5vw, 60px);
}
.page-hero h1 {
  color: #fff;
  font-size: clamp(1.9rem, 3vw + 1rem, 2.9rem);
  letter-spacing: -0.01em;
  margin: 0;
}
.breadcrumb {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: .5em;
  font-size: .9rem;
  color: #9fb0c8;
  margin-bottom: 1.1rem;
}
.breadcrumb a { color: #c3cee0; }
.breadcrumb a:hover { color: var(--accent); }
.breadcrumb span[aria-hidden] { opacity: .5; }

.legal { padding: clamp(46px, 7vw, 84px) 0; }
.legal__inner { max-width: 840px; margin-inline: auto; }
.legal h2 {
  font-size: clamp(1.35rem, 1.4vw + 1rem, 1.8rem);
  margin-top: 2.2em;
  padding-top: .2em;
  color: var(--ink);
}
.legal h2:first-child { margin-top: 0; }
.legal h3 { margin-top: 1.8em; color: var(--navy); font-size: 1.2rem; }
.legal h4 { margin-top: 1.6em; color: var(--navy); }
.legal p { margin-bottom: 1em; }
.legal ul, .legal ol { margin: 0 0 1.3em; padding-left: 1.35em; }
.legal li { margin-bottom: .5em; }
.legal ul li::marker { color: var(--accent); }
.legal ol li::marker { color: var(--navy); font-weight: 700; }
.legal hr { border: 0; border-top: 1px solid var(--line); margin: 2.2em 0; }
.legal a { color: var(--navy); text-decoration: underline; text-underline-offset: 2px; }
.legal a:hover { color: var(--accent); }

.info-card {
  background: var(--surface-alt);
  border: 1px solid var(--line);
  border-left: 4px solid var(--accent);
  border-radius: 14px;
  padding: clamp(20px, 3vw, 30px);
  margin: 1.6em 0;
}
.info-card :last-child { margin-bottom: 0; }
.info-card .info-card__title {
  font-weight: 800;
  color: var(--ink);
  margin-bottom: .4em;
  display: block;
}

/* ---------- Footer ---------- */
.site-footer {
  background: var(--navy-900);
  color: #9fb0c8;
  padding: clamp(40px, 6vw, 64px) 0 32px;
  text-align: center;
}
.site-footer a { color: #dbe3f0; }
.site-footer a:hover { color: var(--accent); }
.footer-links { font-size: 1.05rem; font-weight: 600; margin-bottom: .8rem; }
.footer-links a { margin: 0 .5em; }
.footer-copy { font-size: .95rem; color: #7e8ea8; }

.to-top {
  position: fixed;
  right: clamp(16px, 3vw, 28px);
  bottom: clamp(16px, 3vw, 28px);
  width: 48px; height: 48px;
  display: grid; place-items: center;
  background: var(--accent);
  color: #fff;
  border-radius: 50%;
  box-shadow: 0 12px 26px -10px rgba(244,81,30,.75);
  opacity: 0;
  visibility: hidden;
  transform: translateY(12px);
  transition: opacity .3s var(--ease), transform .3s var(--ease), visibility .3s;
  z-index: 900;
}
.to-top.is-visible { opacity: 1; visibility: visible; transform: translateY(0); }
.to-top:hover { color: #fff; transform: translateY(-3px); }
.to-top svg { width: 22px; height: 22px; }

/* ---------- Scroll target offset ---------- */
[id] { scroll-margin-top: calc(var(--header-h) + 16px); }

/* ---------- Reveal on scroll (nur mit aktivem JS) ---------- */
.js .reveal {
  opacity: 0;
  transform: translateY(28px);
  transition: opacity .7s var(--ease), transform .7s var(--ease);
  will-change: opacity, transform;
}
.js .reveal.is-visible { opacity: 1; transform: none; }

/* ---------- Accessibility ---------- */
.skip-link {
  position: absolute;
  left: 12px; top: -60px;
  z-index: 1100;
  background: var(--navy);
  color: #fff;
  padding: 10px 18px;
  border-radius: 0 0 10px 10px;
  transition: top .25s var(--ease);
}
.skip-link:focus { top: 0; color: #fff; }

:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 4px; }

.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;
}

/* ---------- Responsive ---------- */
@media (max-width: 960px) {
  .grid--3 { grid-template-columns: repeat(2, 1fr); }
}

@media (max-width: 860px) {
  .nav__toggle { display: block; }
  .nav__links {
    position: fixed;
    inset: var(--header-h) 0 auto 0;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    background: #fff;
    border-bottom: 1px solid var(--line);
    box-shadow: var(--shadow);
    padding: 8px 16px 18px;
    max-height: calc(100vh - var(--header-h));
    overflow-y: auto;
    transform: translateY(-12px);
    opacity: 0;
    visibility: hidden;
    transition: opacity .25s var(--ease), transform .25s var(--ease), visibility .25s;
  }
  .nav[data-open="true"] .nav__links { opacity: 1; visibility: visible; transform: none; }
  .nav__links a {
    padding: .95em .6em;
    font-size: .95rem;
    border-bottom: 1px solid var(--line);
    border-radius: 0;
  }
  .nav__links li:last-child a { border-bottom: 0; }
  .nav__links a::after { display: none; }

  .split { grid-template-columns: 1fr; }
  .split--rev .split__media { order: 0; }
  .media-badge { width: min(240px, 60%); }
}

@media (max-width: 620px) {
  .grid--3, .grid--2 { grid-template-columns: 1fr; }
  .hero__actions { flex-direction: column; align-items: stretch; }
  .hero__actions .btn { justify-content: center; }
  .callout { flex-direction: column; text-align: center; align-items: center; }
}

/* ---------- Reduced motion ---------- */
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  .reveal { opacity: 1; transform: none; transition: none; }
  * { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}
