/* ==========================================================================
   Schlindwein Steuerberatung
   Jede Farbe steht zweimal: zuerst als Hex-Fallback, dann als oklch-Wert.
   Browser ohne oklch-Unterstuetzung ignorieren die zweite Zeile und behalten
   den Hex-Wert. Die oklch-Werte sind massgeblich, die Hex-Werte daraus
   umgerechnet.
   ========================================================================== */

/* --- Schrift: selbst gehostet, keine Verbindung zu Google ---------------- */
@font-face {
  font-family: 'Sora';
  font-style: normal;
  font-weight: 400 600;            /* Variable Font: eine Datei fuer alle Schnitte */
  font-display: swap;
  src: url('../fonts/sora-latin.woff2') format('woff2');
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA,
                 U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122,
                 U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
@font-face {
  font-family: 'Sora';
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url('../fonts/sora-latin-ext.woff2') format('woff2');
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF,
                 U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF,
                 U+2020, U+20A0-20AB, U+20AD-20C0, U+2113, U+2C60-2C7F, U+A720-A7FF;
}

/* --- Farb- und Masstokens ------------------------------------------------ */
:root {
  --bg: #fcfcfa;                --bg: oklch(99% 0.002 90);
  --bg-section: #f2f2f0;        --bg-section: oklch(96% 0.002 90);
  --ink: #0d0d0d;               --ink: oklch(16% 0 0);
  --ink-soft: #555555;          --ink-soft: oklch(45% 0 0);
  --line: #d7d7d7;              --line: oklch(88% 0 0);

  /* Akzent. Die drei abgeleiteten Toene behalten den Farbton (205) und
     variieren nur Helligkeit und Saettigung. Wird der Akzent geaendert,
     muessen alle vier Werte angepasst werden. */
  --accent: #00646f;            --accent: oklch(45% 0.10 205);
  --accent-dark: #004853;       --accent-dark: oklch(35% 0.10 205);
  --accent-tint: #b7edf3;       --accent-tint: oklch(91% 0.055 205);
  --accent-line: #8cbbc0;       --accent-line: oklch(76% 0.05 205);

  --radius: 8px;
  --radius-sm: 6px;
  --section-pad: clamp(76px, 9.5vw, 124px);

  /* Hoehe des klebenden Kopfbereichs: 20px Polsterung oben und unten,
     46px hoher Kontakt-Button, 1px Trennlinie. Der Wert steuert zugleich,
     wo ein Sprung ueber die Navigation landet – siehe scroll-padding-top.
     Wird die Polsterung oder die Button-Groesse geaendert, muss er mit. */
  --header-h: 87px;
}

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

body {
  margin: 0;
  font-family: 'Sora', system-ui, sans-serif;
  font-weight: 400;
  background: var(--bg);
  color: var(--ink);
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3, p { margin: 0; }
ul { margin: 0; padding: 0; list-style: none; }
img, svg { max-width: 100%; }

a { color: var(--accent-dark); text-decoration: none; }
a:hover { color: var(--accent); }
a:focus-visible,
.btn:focus-visible,
button:focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }

/* Sprungmarke fuer Tastatur- und Screenreader-Nutzung */
.skip-link {
  position: absolute; left: -9999px; top: 0; z-index: 100;
  background: var(--accent); color: var(--bg);
  padding: 12px 20px; border-radius: 0 0 var(--radius-sm) 0;
}
.skip-link:focus { left: 0; color: var(--bg); }

.visually-hidden {
  position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; border: 0;
}

.container {
  max-width: 1120px;
  margin: 0 auto;
  padding-left: clamp(20px, 5vw, 48px);
  padding-right: clamp(20px, 5vw, 48px);
}

.section { padding-top: var(--section-pad); padding-bottom: var(--section-pad); }
.section--tinted { background: var(--bg-section); }

/* --- Typografie ---------------------------------------------------------- */
.eyebrow {
  display: block; text-transform: uppercase; letter-spacing: 0.18em;
  font-size: 12px; font-weight: 600; color: var(--accent-dark);
  margin-bottom: 14px;
}
.h2 {
  font-size: clamp(28px, 4vw, 40px); font-weight: 500;
  letter-spacing: -0.015em; margin: 0 0 16px;
}
.section-intro {
  font-size: 16px; color: var(--ink-soft); max-width: 560px;
  line-height: 1.6; margin: 0 0 64px; text-wrap: pretty;
}
/* Wenn der Absatz den Abschnitt beendet und kein Raster mehr folgt. */
.section-intro--schluss { margin-bottom: 0; }

/* --- Wortmarke -----------------------------------------------------------
   Beide Zeilen sind gleich breit: die Unterzeile ist so weit gesperrt, dass
   sie buendig unter der Wortmarke abschliesst. Die Laufweite haengt an der
   Schriftgroesse und darf nicht ohne Neuberechnung geaendert werden.        */
.wordmark {
  display: flex; flex-direction: column; gap: 3px;
  font-weight: 500; line-height: 1; color: var(--ink);
}
.wordmark:hover { color: var(--ink); }
.wordmark__name { font-size: 19px; letter-spacing: 0.05em; }
.wordmark__sub {
  font-size: 8px; letter-spacing: 0.734em; text-transform: uppercase;
  opacity: 0.55;
}
.wordmark--small .wordmark__name { font-size: 14px; }
.wordmark--small .wordmark__sub { font-size: 7px; letter-spacing: 0.5em; }

/* --- Buttons ------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  padding: 16px 30px;
  font-family: inherit; font-size: 15px; font-weight: 600;
  border-radius: var(--radius-sm); border: 1px solid transparent;
  cursor: pointer; white-space: nowrap;
}
.btn--primary { background: var(--accent); color: var(--bg); }
.btn--primary:hover { background: var(--accent-dark); color: var(--bg); }
.btn--ghost { background: transparent; color: var(--ink); border-color: var(--line); }
.btn--ghost:hover { border-color: var(--ink); color: var(--ink); }
.btn--compact { padding: 13px 22px; font-size: 14px; }
.btn--block { width: 100%; }

/* --- Hinweisstreifen im Testmodus ---------------------------------------- */
.testhinweis {
  margin: 0; padding: 9px 16px; text-align: center;
  background: #8a5a00; color: #fff;
  font-size: 13px; line-height: 1.5;
}
.testhinweis code {
  font-family: ui-monospace, Consolas, monospace;
  background: rgba(255, 255, 255, 0.18); padding: 1px 5px; border-radius: 3px;
}

/* --- Kopfbereich --------------------------------------------------------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: var(--bg); border-bottom: 1px solid var(--line);
}
.site-header__inner {
  display: flex; align-items: center; justify-content: space-between;
  padding-top: 20px; padding-bottom: 20px;
}
.nav-links { display: flex; gap: 36px; align-items: center; }
.nav-links a { color: var(--ink); font-size: 14px; font-weight: 500; }
.nav-links a:hover { color: var(--accent-dark); }

/* --- Hero ---------------------------------------------------------------- */
.hero { padding-top: clamp(88px, 12vw, 152px); padding-bottom: clamp(88px, 12vw, 152px); }
.hero__inner { max-width: 780px; margin: 0 auto; text-align: center; }
.hero__rule {
  width: 56px; height: 3px; background: var(--accent);
  border-radius: 2px; margin: 0 auto 32px;
}
.hero__title {
  font-size: clamp(34px, 5.5vw, 58px); font-weight: 500;
  letter-spacing: -0.02em; line-height: 1.12; margin: 0 0 26px;
  text-wrap: balance;
}
.hero__lead {
  font-size: clamp(16px, 2vw, 19px); color: var(--ink-soft);
  line-height: 1.65; max-width: 600px; margin: 0 auto; text-wrap: pretty;
}
.hero__actions {
  display: flex; gap: 16px; justify-content: center;
  margin-top: 40px; flex-wrap: wrap;
}

/* --- Leistungen ---------------------------------------------------------- */
.services-grid {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 48px 40px;
}
.service { border-top: 2px solid var(--accent-line); padding-top: 24px; }
.service__num {
  display: block; font-size: 12px; font-weight: 600; letter-spacing: 0.14em;
  color: var(--accent-dark); font-variant-numeric: tabular-nums;
  margin-bottom: 16px;
}
.service__title { font-size: 18px; font-weight: 600; margin: 0 0 8px; }
.service__text { font-size: 15px; color: var(--ink-soft); line-height: 1.6; text-wrap: pretty; }

/* --- Digital arbeiten ---------------------------------------------------- */
.digital-grid {
  display: grid; grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 40px 32px;
}
.feature { text-align: center; padding: 0 8px; }
.feature__badge {
  width: 52px; height: 52px; border-radius: 50%; background: var(--accent-tint);
  display: flex; align-items: center; justify-content: center; margin: 0 auto 22px;
}
.feature__badge svg { width: 22px; height: 22px; display: block; }
.feature__title { font-size: 16px; font-weight: 600; margin: 0 0 8px; }
.feature__text { font-size: 14px; color: var(--ink-soft); line-height: 1.6; text-wrap: pretty; }

.digital-note {
  max-width: 640px; margin: 56px auto 0; padding-top: 40px;
  border-top: 1px solid var(--accent-line); text-align: center;
  font-size: 16px; color: var(--ink-soft); line-height: 1.7; text-wrap: pretty;
}

/* --- Kontakt ------------------------------------------------------------- */
.contact-grid {
  display: grid; grid-template-columns: 0.85fr 1.15fr;
  gap: 64px; align-items: start;
}
.contact__lead {
  font-size: 16px; color: var(--ink-soft); line-height: 1.65;
  margin-bottom: 40px; text-wrap: pretty;
}
.contact-list { display: flex; flex-direction: column; gap: 22px; }
.contact-item { display: flex; align-items: flex-start; gap: 14px; }
.contact-item svg {
  width: 22px; height: 22px; display: block; flex-shrink: 0; margin-top: 2px;
}
.contact-item__label {
  font-size: 13px; font-weight: 600; color: var(--ink-soft);
  text-transform: uppercase; letter-spacing: 0.05em; margin-bottom: 4px;
}
.contact-item__value { font-size: 15px; }
.contact-item__value a { color: var(--ink); }
.contact-item__value a:hover { color: var(--accent-dark); }

/* --- Formular ------------------------------------------------------------ */
.form-card {
  background: var(--bg-section); border: 1px solid var(--line);
  border-radius: var(--radius); padding: clamp(24px, 4vw, 40px);
}
.field { margin-bottom: 20px; }
label { display: block; font-size: 13px; font-weight: 600; color: var(--ink); margin-bottom: 6px; }

input, textarea {
  font-family: inherit; font-size: 15px; color: var(--ink);
  background: var(--bg); border: 1px solid var(--line);
  border-radius: var(--radius-sm); padding: 13px 14px; width: 100%;
}
textarea { resize: vertical; min-height: 120px; }
input:focus, textarea:focus {
  outline: 2px solid var(--accent); outline-offset: 2px; border-color: var(--accent);
}
input[aria-invalid="true"], textarea[aria-invalid="true"] { border-color: #b3261e; }

.field--consent { display: flex; align-items: flex-start; gap: 10px; }
.field--consent input {
  width: 19px; height: 19px; padding: 0; margin-top: 1px;
  flex-shrink: 0; accent-color: var(--accent);
}
.field--consent label {
  font-weight: 400; font-size: 13px; color: var(--ink-soft); margin: 0;
}

.form-note { font-size: 12px; color: var(--ink-soft); margin-top: 16px; }
.field-error { display: block; font-size: 12px; color: #b3261e; margin-top: 6px; font-weight: 500; }

/* Honeypot: fuer Menschen unsichtbar, Bots fuellen ihn aus */
.hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }

.alert {
  border-radius: var(--radius); padding: 18px 20px; margin-bottom: 28px;
  font-size: 15px; line-height: 1.6;
}
.alert--ok { background: var(--accent-tint); color: var(--accent-dark); }
.alert--error { background: #fdecea; color: #8c1d18; }

/* --- Fussbereich --------------------------------------------------------- */
.site-footer { border-top: 1px solid var(--line); }
.site-footer__inner {
  display: flex; align-items: center; justify-content: space-between;
  gap: 16px; flex-wrap: wrap; padding-top: 32px; padding-bottom: 32px;
}
.site-footer__copy { font-size: 13px; color: var(--ink-soft); }
.site-footer__links { display: flex; gap: 24px; font-size: 13px; }
.site-footer__links a { color: var(--ink-soft); }
.site-footer__links a:hover { color: var(--accent-dark); }

/* --- Rechtstexte --------------------------------------------------------- */
.legal { max-width: 720px; }
.legal h2 { font-size: 20px; font-weight: 600; margin: 40px 0 12px; }
.legal h2:first-of-type { margin-top: 24px; }
.legal p, .legal li { font-size: 15px; color: var(--ink-soft); line-height: 1.7; }
.legal p { margin-bottom: 12px; }
.legal ul { list-style: disc; padding-left: 20px; margin-bottom: 12px; }
.legal li { margin-bottom: 6px; }

/* --- Einblendung beim Laden ---------------------------------------------- */
@keyframes fadeInUp {
  from { opacity: 0; transform: translateY(14px); }
  to   { opacity: 1; transform: translateY(0); }
}
.animate-in { animation: fadeInUp 0.7s cubic-bezier(0.16, 0.8, 0.3, 1) both; }
.animate-in--2 { animation-delay: 0.1s; }
.animate-in--3 { animation-delay: 0.18s; }
.animate-in--4 { animation-delay: 0.3s; }

@media (prefers-reduced-motion: reduce) {
  .animate-in { animation: none; }
  * { scroll-behavior: auto !important; }
}

/* Ein Sprung ueber die Navigation soll den angesteuerten Abschnitt buendig
   unter dem Kopfbereich beginnen lassen – vom vorherigen Abschnitt darf nichts
   stehen bleiben. Deshalb entspricht der Abstand exakt der Kopfhoehe. */
html { scroll-behavior: smooth; scroll-padding-top: var(--header-h); }

/* --- Umbrueche ----------------------------------------------------------- */
@media (max-width: 900px) {
  /* Auf dem Smartphone bleibt der Kopfbereich schlank und klebend:
     Wortmarke + Kontakt-Button. Die drei Ankerlinks entfallen – bei einer
     kurzen Onepage wiegt der dauerhaft erreichbare Kontakt-Button mehr als
     drei Sprungmarken. */
  .nav-links { display: none; }

  /* Tippflaechen auf Touch-Geraeten auf mind. 44px bringen.
     Die negativen Aussenabstaende gleichen die Polsterung wieder aus, damit
     die Tippflaeche waechst, das Layout sich aber nicht verschiebt. */
  .wordmark { padding: 7px 0; }
  .site-footer__links a { display: inline-block; padding: 14px 0; }
  .contact-item__value a { display: inline-block; padding: 14px 0; margin: -14px 0; }
  .field--consent label { padding: 6px 0; margin: -6px 0; }

  /* Tablet: sechs Leistungen zweispaltig. Einspaltig waere die Spalte hier
     unnoetig lang, obwohl die Breite fuer zwei Spalten reicht. */
  .services-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 40px 32px; }
  .contact-grid { grid-template-columns: 1fr; gap: 48px; }
}

@media (max-width: 640px) {
  .services-grid { grid-template-columns: 1fr; gap: 40px; }
  .digital-grid { grid-template-columns: 1fr; }
  .hero__actions { flex-direction: column; align-items: stretch; }
}

/* --- Druck --------------------------------------------------------------- */
@media print {
  .site-header, .hero__actions, .form-card { display: none; }
  body { background: #fff; color: #000; }
}
