/* TT-Werkzeuge – gemeinsame Basis (Stil wie kevinklaassen.de) */

@font-face {
  font-family: "Bricolage";
  src: url("/fonts/bricolage-grotesque-latin-wght-normal.woff2") format("woff2");
  font-weight: 200 800;
  font-display: swap;
}
@font-face {
  font-family: "JetBrains Mono";
  src: url("/fonts/jetbrains-mono-latin-500-normal.woff2") format("woff2");
  font-weight: 500;
  font-display: swap;
}

:root {
  --ink: #0d1320;
  --ink-2: #172033;
  --paper: #f4efe4;
  --paper-2: #e9e1d0;
  --card: #fffdf8;
  --text: #0d1320;
  --muted: #5b6272;
  --line: #d8cfbc;
  --table: #1d4fa0;
  --table-dark: #133a7a;
  --ball: #ff6a1a;
  --lime: #b6f36a;
  --good: #1f8a4c;
  --good-soft: #dcf3e3;
  --bad: #c0441a;
  --bad-soft: #fbe3d8;
  --display: "Bricolage", "Segoe UI", system-ui, sans-serif;
  --mono: "JetBrains Mono", ui-monospace, Consolas, monospace;
  --bar: min(960px, 100% - 2rem);
  --radius: 20px;
  color-scheme: light;
}
@media (prefers-color-scheme: dark) {
  :root {
    --paper: #0d1320;
    --paper-2: #172033;
    --card: #141c2d;
    --text: #eef1f7;
    --muted: #9aa4b8;
    --line: #2a3550;
    --good: #6ad99a;
    --good-soft: #143826;
    --bad: #ff9a6b;
    --bad-soft: #3a1d12;
    color-scheme: dark;
  }
}

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--paper); color: var(--text);
  font-family: var(--display); font-size: 1.0625rem; line-height: 1.55;
}
a { color: inherit; text-decoration-thickness: 2px; text-underline-offset: 0.18em; }
:focus-visible { outline: 3px solid var(--ball); outline-offset: 2px; border-radius: 6px; }
button { font: inherit; color: inherit; }
.bar { width: var(--bar); margin-inline: auto; }
.visually-hidden { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip-link { position: absolute; left: 1rem; top: -4rem; background: var(--ball); color: var(--ink); padding: .5rem 1rem; border-radius: 999px; font-weight: 700; z-index: 100; }
.skip-link:focus { top: 1rem; }

/* Kopf */
.top { background: var(--ink); color: #f4efe4; }
.top .bar { display: flex; justify-content: space-between; align-items: center; gap: .5rem 1rem; min-height: 3.5rem; flex-wrap: wrap; }
.logo { margin: 0; font-weight: 800; letter-spacing: -0.03em; display: flex; align-items: center; gap: .5rem; text-decoration: none; }
.dot { width: .75rem; height: .75rem; border-radius: 50%; background: var(--ball); }
.top nav ul { list-style: none; margin: 0; padding: 0; display: flex; gap: .15rem; flex-wrap: wrap; }
.top nav a { display: block; padding: .35rem .75rem; border-radius: 999px; font-weight: 600; font-size: .95rem; text-decoration: none; color: #d7deec; }
.top nav a:hover, .top nav a[aria-current="page"] { background: #f4efe4; color: var(--ink); }

main.page { padding-block: clamp(2rem, 6vw, 3.5rem) 3rem; }
.page h1 {
  margin: 0; font-weight: 800; letter-spacing: -0.055em; line-height: .92;
  font-size: clamp(2.4rem, 8vw, 4.2rem); text-transform: uppercase;
}
.page h1 em { font-style: normal; color: var(--ball); }
.lede { color: var(--muted); font-size: 1.15rem; max-width: 40rem; margin: 1rem 0 1.75rem; }
h2 { letter-spacing: -0.03em; line-height: 1.15; }

/* Karten & Formulare */
.card { background: var(--card); border: 2px solid var(--line); border-radius: var(--radius); padding: clamp(1rem, 3vw, 1.4rem); }
.label { font-family: var(--mono); font-size: .7rem; text-transform: uppercase; letter-spacing: .08em; color: var(--muted); }
.field { display: grid; gap: .25rem; }
.input, .select {
  width: 100%; min-width: 0; font: inherit; font-size: 1.1rem; font-weight: 600; color: inherit;
  background: var(--paper); border: 2px solid var(--line); border-radius: 12px; padding: .5rem .7rem;
}
.select { appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, currentColor 50%), linear-gradient(135deg, currentColor 50%, transparent 50%);
  background-position: calc(100% - 1rem) 55%, calc(100% - .7rem) 55%; background-size: .3rem .3rem; background-repeat: no-repeat; padding-right: 1.8rem; }
.input:focus, .select:focus { border-color: var(--ball); outline: none; }

.btn {
  font-weight: 700; cursor: pointer; border-radius: 999px; padding: .65rem 1.15rem;
  border: 2px solid var(--text); background: transparent; color: var(--text);
  display: inline-flex; align-items: center; gap: .4rem; text-decoration: none;
}
.btn:hover { background: var(--text); color: var(--paper); }
.btn-primary { background: var(--ball); border-color: var(--ball); color: var(--ink); }
.btn-primary:hover { background: var(--ink); border-color: var(--ink); color: #fff; }
.btn-ghost { border-color: transparent; color: var(--muted); }
.btn-small { padding: .35rem .8rem; font-size: .9rem; }
.btn:disabled { opacity: .45; cursor: not-allowed; }
.actions { display: flex; flex-wrap: wrap; gap: .6rem; }
.msg { min-height: 1.4em; margin: .5rem 0 0; color: var(--good); font-weight: 600; overflow-wrap: anywhere; }

.note { background: var(--paper-2); border-radius: var(--radius); padding: 1.1rem 1.3rem; color: var(--muted); font-size: .95rem; }
.note h2 { color: var(--text); font-size: 1.2rem; margin: 0 0 .4rem; }
.note p { margin: 0 0 .5rem; }
.note p:last-child { margin: 0; }

/* Fuß */
.foot { background: var(--ink); color: #b9c2d3; font-size: .9rem; }
.foot .bar { display: flex; flex-wrap: wrap; justify-content: space-between; gap: .75rem 1.25rem; padding-block: 1.25rem; }
.foot ul { list-style: none; margin: 0; padding: 0; display: flex; gap: 1.25rem; }
.foot a { color: #fff; }

@media (prefers-reduced-motion: reduce) { *, *::before, *::after { transition: none !important; animation: none !important; } }
