/* ==========================================================================
   Kruitwagen.de – Zentrales Stylesheet
   Modular aufgebaut. Design-Tokens oben zentral pflegbar.
   ========================================================================== */

/* --- Design Tokens ------------------------------------------------------- */
:root {
  /* Farben – eigenständige Palette, an seriösen Finanz-Look angelehnt */
  --c-primary:        #0a2540;   /* Tiefes Nachtblau (Haupt) */
  --c-primary-700:    #0e3a63;   /* Blau heller */
  --c-primary-500:    #1d5fa3;   /* Akzentblau */
  --c-accent:         #2bb5a0;   /* Türkis-Akzent (Signatur) */
  --c-accent-600:     #1f9486;
  --c-ink:            #14202e;   /* Fließtext dunkel */
  --c-muted:          #5b6b7c;   /* Sekundärtext */
  --c-line:           #e2e8f0;   /* Trennlinien */
  --c-bg:             #ffffff;
  --c-bg-soft:        #f5f8fc;   /* Sektions-Hintergrund */
  --c-bg-deep:        #071b30;   /* Footer/Hero dunkel */
  --c-white:          #ffffff;
  --c-warn-bg:        #fff7e6;
  --c-warn-line:      #f0c36d;

  /* Typografie */
  --font-display: "Segoe UI", "Inter", system-ui, -apple-system, sans-serif;
  --font-body:    "Segoe UI", "Inter", system-ui, -apple-system, sans-serif;

  --fs-xs:   0.78rem;
  --fs-sm:   0.88rem;
  --fs-base: 1rem;
  --fs-md:   1.15rem;
  --fs-lg:   1.4rem;
  --fs-xl:   2rem;
  --fs-2xl:  2.8rem;
  --fs-3xl:  3.6rem;

  /* Layout */
  --maxw: 1180px;
  --gap: 1.5rem;
  --radius: 14px;
  --radius-sm: 9px;
  --shadow-sm: 0 1px 3px rgba(10,37,64,.08), 0 1px 2px rgba(10,37,64,.06);
  --shadow-md: 0 6px 24px rgba(10,37,64,.10);
  --shadow-lg: 0 18px 48px rgba(10,37,64,.16);
  --transition: 0.22s cubic-bezier(.4,0,.2,1);
}

/* --- Reset / Base -------------------------------------------------------- */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; -webkit-text-size-adjust: 100%; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .001ms !important; transition-duration: .001ms !important; }
}
body {
  margin: 0;
  font-family: var(--font-body);
  font-size: var(--fs-base);
  line-height: 1.65;
  color: var(--c-ink);
  background: var(--c-bg);
  -webkit-font-smoothing: antialiased;
}
h1,h2,h3,h4 { font-family: var(--font-display); line-height: 1.18; color: var(--c-primary); font-weight: 700; margin: 0 0 .5em; }
h1 { font-size: var(--fs-3xl); letter-spacing: -.02em; }
h2 { font-size: var(--fs-2xl); letter-spacing: -.015em; }
h3 { font-size: var(--fs-lg); }
p { margin: 0 0 1rem; }
a { color: var(--c-primary-500); text-decoration: none; transition: color var(--transition); }
a:hover { color: var(--c-accent-600); }
img { max-width: 100%; display: block; }
:focus-visible { outline: 3px solid var(--c-accent); outline-offset: 2px; border-radius: 3px; }

/* --- Layout helpers ------------------------------------------------------ */
.container { width: 100%; max-width: var(--maxw); margin-inline: auto; padding-inline: 1.25rem; }
.section { padding: clamp(3rem, 7vw, 6rem) 0; }
.section--soft { background: var(--c-bg-soft); }
.section--deep { background: var(--c-bg-deep); color: #c8d6e5; }
.section--deep h2, .section--deep h3 { color: #fff; }
.eyebrow {
  display: inline-block; font-size: var(--fs-sm); font-weight: 600; letter-spacing: .12em;
  text-transform: uppercase; color: var(--c-accent-600); margin-bottom: .8rem;
}
.lead { font-size: var(--fs-md); color: var(--c-muted); max-width: 60ch; }
.center { text-align: center; }
.center .lead { margin-inline: auto; }

/* --- Buttons ------------------------------------------------------------- */
.btn {
  display: inline-flex; align-items: center; gap: .55rem;
  font: inherit; font-weight: 600; font-size: var(--fs-base);
  padding: .8rem 1.6rem; border-radius: var(--radius-sm);
  border: 2px solid transparent; cursor: pointer;
  transition: all var(--transition); text-decoration: none;
}
.btn--primary { background: var(--c-accent); color: #04231f; }
.btn--primary:hover { background: var(--c-accent-600); color: #fff; transform: translateY(-2px); box-shadow: var(--shadow-md); }
.btn--ghost { background: transparent; color: var(--c-white); border-color: rgba(255,255,255,.5); }
.btn--ghost:hover { background: rgba(255,255,255,.12); color: #fff; border-color: #fff; }
.btn--outline { background: transparent; color: var(--c-primary); border-color: var(--c-line); }
.btn--outline:hover { border-color: var(--c-primary-500); color: var(--c-primary-500); }
.btn svg { width: 1.1em; height: 1.1em; }

/* --- Header / Nav -------------------------------------------------------- */
.site-header {
  position: sticky; top: 0; z-index: 50;
  background: rgba(255,255,255,.92); backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--c-line);
}
.nav { display: flex; align-items: center; justify-content: space-between; gap: 1rem; min-height: 72px; }
.brand { display: flex; align-items: center; gap: .7rem; font-family: var(--font-display); font-weight: 700; font-size: var(--fs-md); color: var(--c-primary); }
.brand__mark { width: 38px; height: 38px; flex: 0 0 auto; }
.nav__links { display: flex; align-items: center; gap: 1.6rem; list-style: none; margin: 0; padding: 0; }
.nav__links a { color: var(--c-ink); font-weight: 500; font-size: var(--fs-sm); }
.nav__links a:hover { color: var(--c-accent-600); }
.nav__actions { display: flex; align-items: center; gap: .8rem; }

/* Sprachumschalter */
.lang-switch { display: inline-flex; border: 1px solid var(--c-line); border-radius: 999px; overflow: hidden; }
.lang-switch button {
  font: inherit; font-size: var(--fs-xs); font-weight: 600; cursor: pointer;
  border: 0; background: transparent; color: var(--c-muted); padding: .35rem .7rem;
  transition: all var(--transition);
}
.lang-switch button[aria-pressed="true"] { background: var(--c-primary); color: #fff; }

/* Burger */
.nav__toggle { display: none; background: none; border: 0; cursor: pointer; padding: .4rem; }
.nav__toggle svg { width: 28px; height: 28px; color: var(--c-primary); }

@media (max-width: 860px) {
  .nav__links {
    position: fixed; inset: 72px 0 auto 0; flex-direction: column; gap: 0;
    background: #fff; border-bottom: 1px solid var(--c-line); padding: .5rem 1.25rem 1.25rem;
    transform: translateY(-120%); transition: transform var(--transition); box-shadow: var(--shadow-md);
  }
  .nav__links.is-open { transform: translateY(0); }
  .nav__links li { width: 100%; border-bottom: 1px solid var(--c-line); }
  .nav__links a { display: block; padding: .9rem .2rem; font-size: var(--fs-base); }
  .nav__toggle { display: inline-flex; }
}

/* --- Hero ---------------------------------------------------------------- */
.hero {
  position: relative; overflow: hidden;
  background:
    radial-gradient(1200px 500px at 80% -10%, rgba(43,181,160,.18), transparent 60%),
    linear-gradient(160deg, var(--c-bg-deep) 0%, var(--c-primary) 55%, var(--c-primary-700) 100%);
  color: #eaf2fb;
}
.hero__grid { display: grid; grid-template-columns: 1.15fr .85fr; gap: clamp(2rem,5vw,4rem); align-items: center; padding: clamp(3.5rem,8vw,6.5rem) 0; }
.hero h1 { color: #fff; margin-bottom: .4em; }
.hero .lead { color: #c2d4e8; font-size: var(--fs-lg); }
.hero__cta { display: flex; flex-wrap: wrap; gap: .9rem; margin-top: 1.8rem; }
.hero__portrait {
  position: relative; justify-self: center;
  width: min(360px, 80vw); aspect-ratio: 4/5; border-radius: var(--radius);
  overflow: hidden; box-shadow: var(--shadow-lg); border: 3px solid rgba(255,255,255,.14);
  background: linear-gradient(160deg, #16334f, #0b2138);
}
.hero__portrait img { width: 100%; height: 100%; object-fit: cover; }
.hero__portrait figcaption {
  position: absolute; left: 0; right: 0; bottom: 0; padding: 1rem 1.1rem .9rem;
  background: linear-gradient(transparent, rgba(4,15,28,.86)); font-size: var(--fs-sm);
}
.hero__portrait figcaption strong { display: block; color: #fff; font-size: var(--fs-md); }
.hero__portrait figcaption span { color: var(--c-accent); }
@media (max-width: 820px) {
  .hero__grid { grid-template-columns: 1fr; text-align: center; }
  .hero__cta { justify-content: center; }
  .hero .lead { margin-inline: auto; }
}

/* --- Cards / Grids ------------------------------------------------------- */
.grid { display: grid; gap: var(--gap); }
.grid--3 { grid-template-columns: repeat(3, 1fr); }
.grid--2 { grid-template-columns: repeat(2, 1fr); }
@media (max-width: 880px) { .grid--3 { grid-template-columns: 1fr 1fr; } }
@media (max-width: 620px) { .grid--3, .grid--2 { grid-template-columns: 1fr; } }

.card {
  background: #fff; border: 1px solid var(--c-line); border-radius: var(--radius);
  padding: 1.7rem; box-shadow: var(--shadow-sm); transition: all var(--transition);
  height: 100%;
}
.card:hover { transform: translateY(-4px); box-shadow: var(--shadow-md); border-color: #cfe0f0; }
.card__icon {
  width: 52px; height: 52px; border-radius: 12px; display: grid; place-items: center;
  background: linear-gradient(160deg, rgba(43,181,160,.16), rgba(29,95,163,.14));
  color: var(--c-accent-600); margin-bottom: 1rem;
}
.card__icon svg { width: 26px; height: 26px; }
.card h3 { margin-bottom: .35em; }
.card p { color: var(--c-muted); font-size: var(--fs-sm); margin: 0; }

/* Tool-Karten (Platzhalter Rechner) */
.tool-card { position: relative; }
.tool-card .badge {
  position: absolute; top: 1rem; right: 1rem; font-size: var(--fs-xs); font-weight: 600;
  padding: .2rem .6rem; border-radius: 999px; background: var(--c-bg-soft); color: var(--c-muted);
  border: 1px solid var(--c-line);
}
.tool-card .badge--soon { background: var(--c-warn-bg); color: #8a5a00; border-color: var(--c-warn-line); }
.tool-card .badge--live { background: rgba(43,181,160,.14); color: var(--c-accent-600); border-color: rgba(43,181,160,.4); }

/* --- About / Profil ------------------------------------------------------ */
.about__grid { display: grid; grid-template-columns: .9fr 1.1fr; gap: clamp(2rem,5vw,3.5rem); align-items: center; }
@media (max-width: 820px) { .about__grid { grid-template-columns: 1fr; } }
.facts { list-style: none; margin: 1.4rem 0 0; padding: 0; display: grid; gap: .7rem; }
.facts li { display: flex; gap: .7rem; align-items: flex-start; font-size: var(--fs-sm); }
.facts svg { width: 20px; height: 20px; color: var(--c-accent-600); flex: 0 0 auto; margin-top: .15rem; }
.timeline { list-style: none; margin: 1rem 0 0; padding: 0; border-left: 2px solid var(--c-line); }
.timeline li { position: relative; padding: 0 0 1.3rem 1.4rem; }
.timeline li::before { content: ""; position: absolute; left: -7px; top: .35rem; width: 12px; height: 12px; border-radius: 50%; background: var(--c-accent); border: 2px solid #fff; }
.timeline time { font-weight: 700; color: var(--c-primary); font-size: var(--fs-sm); }
.timeline p { margin: .15rem 0 0; color: var(--c-muted); font-size: var(--fs-sm); }

/* --- Tags ---------------------------------------------------------------- */
.tags { display: flex; flex-wrap: wrap; gap: .5rem; margin-top: 1rem; }
.tag { font-size: var(--fs-xs); font-weight: 600; padding: .35rem .8rem; border-radius: 999px; background: var(--c-bg-soft); border: 1px solid var(--c-line); color: var(--c-primary-700); }

/* --- Contact ------------------------------------------------------------- */
.contact__grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(1.5rem,4vw,3rem); }
@media (max-width: 760px) { .contact__grid { grid-template-columns: 1fr; } }
.contact__item { display: flex; gap: .9rem; align-items: flex-start; margin-bottom: 1.1rem; }
.contact__item svg { width: 24px; height: 24px; color: var(--c-accent); flex: 0 0 auto; margin-top: .15rem; }
.contact__item a { color: #dceaf7; }
.contact__item span small { display: block; color: #8fa6bd; font-size: var(--fs-xs); text-transform: uppercase; letter-spacing: .08em; }

/* --- Footer -------------------------------------------------------------- */
.site-footer { background: #04101e; color: #8fa6bd; padding: 3rem 0 2rem; font-size: var(--fs-sm); }
.site-footer a { color: #b9cadd; }
.site-footer a:hover { color: #fff; }
.footer__grid { display: flex; flex-wrap: wrap; justify-content: space-between; gap: 2rem; margin-bottom: 2rem; }
.footer__links { display: flex; flex-wrap: wrap; gap: 1.2rem; list-style: none; margin: 0; padding: 0; }
.footer__bottom { border-top: 1px solid rgba(255,255,255,.1); padding-top: 1.4rem; display: flex; flex-wrap: wrap; justify-content: space-between; gap: 1rem; font-size: var(--fs-xs); }

/* --- Legal pages --------------------------------------------------------- */
.legal-page { max-width: 820px; }
.legal-page h2 { font-size: var(--fs-xl); margin-top: 2.2rem; }
.legal-page h3 { font-size: var(--fs-md); margin-top: 1.6rem; }
.legal-page p, .legal-page li { color: var(--c-ink); font-size: var(--fs-sm); }
.todo {
  background: var(--c-warn-bg); border: 1px solid var(--c-warn-line); border-radius: var(--radius-sm);
  padding: .2rem .5rem; font-weight: 600; color: #8a5a00;
}
.note-box {
  background: var(--c-bg-soft); border-left: 4px solid var(--c-accent); border-radius: var(--radius-sm);
  padding: 1rem 1.2rem; margin: 1.5rem 0; font-size: var(--fs-sm); color: var(--c-muted);
}

/* --- i18n helper: zeigt/versteckt Sprachvarianten ------------------------ */
[data-i18n-hide] { display: none !important; }

/* --- Utility ------------------------------------------------------------- */
.mt-0{margin-top:0}.mb-0{margin-bottom:0}.skip-link{position:absolute;left:-999px}
.skip-link:focus{left:1rem;top:1rem;background:#fff;padding:.6rem 1rem;border-radius:8px;z-index:100;box-shadow:var(--shadow-md)}
