/* ============================================================================
   BASE  ·  Reset, Typografie, Grundlagen, Utilities
   ============================================================================ */

*, *::before, *::after { box-sizing: border-box; }
* { margin: 0; padding: 0; }

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

body {
    font-family: var(--font-body);
    font-size: var(--text-base);
    line-height: 1.55;
    color: var(--text);
    background-color: var(--bg-body);
    background-image:
        radial-gradient(1100px 620px at 88% -8%, var(--accent-soft), transparent 60%),
        radial-gradient(900px 540px at -6% 8%, rgba(255,255,255,.025), transparent 55%);
    background-attachment: fixed;
    -webkit-font-smoothing: antialiased;
    text-rendering: optimizeLegibility;
    min-height: 100vh;
    overflow-x: hidden;
}

h1, h2, h3, h4, h5 { font-family: var(--font-display); font-weight: 600; line-height: 1.15; letter-spacing: -.01em; color: var(--text); }
h1 { font-size: var(--text-2xl); }
h2 { font-size: var(--text-xl); }
h3 { font-size: var(--text-lg); }

a { color: inherit; text-decoration: none; }
button { font: inherit; color: inherit; cursor: pointer; background: none; border: none; }
input, select, textarea { font: inherit; color: inherit; }
img, svg { display: block; max-width: 100%; }
ul, ol { list-style: none; }
table { border-collapse: collapse; width: 100%; }

code, kbd, .mono { font-family: var(--font-mono); }

/* Inline-SVG-Icons */
.ico { width: 1.15em; height: 1.15em; flex: 0 0 auto; stroke-width: 2; }
.ico-sm { width: 16px; height: 16px; }
.ico-lg { width: 22px; height: 22px; }

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

/* Fokus — sichtbar & gethemt */
:focus-visible {
    outline: 2px solid var(--accent);
    outline-offset: 2px;
    border-radius: var(--r-xs);
}
:focus:not(:focus-visible) { outline: none; }

/* Scrollbar */
* { scrollbar-width: thin; scrollbar-color: var(--line-2) transparent; }
::-webkit-scrollbar { width: 10px; height: 10px; }
::-webkit-scrollbar-track { background: transparent; }
::-webkit-scrollbar-thumb { background: var(--line-2); border-radius: 99px; border: 3px solid transparent; background-clip: content-box; }
::-webkit-scrollbar-thumb:hover { background: var(--text-faint); background-clip: content-box; }

/* ----------------------------- Utilities ----------------------------- */
.container { width: 100%; max-width: var(--container); margin-inline: auto; padding-inline: var(--sp-6); }

.row { display: flex; gap: var(--sp-4); }
.row-between { display: flex; align-items: center; justify-content: space-between; gap: var(--sp-4); }
.row-center { display: flex; align-items: center; gap: var(--sp-2); }
.col { display: flex; flex-direction: column; }
.wrap { flex-wrap: wrap; }
.grow { flex: 1 1 auto; min-width: 0; }
.gap-1 { gap: var(--sp-1); } .gap-2 { gap: var(--sp-2); } .gap-3 { gap: var(--sp-3); }
.gap-4 { gap: var(--sp-4); } .gap-6 { gap: var(--sp-6); }

.grid { display: grid; gap: var(--sp-5); }
.grid-2 { grid-template-columns: repeat(2, 1fr); }
.grid-3 { grid-template-columns: repeat(3, 1fr); }
.grid-4 { grid-template-columns: repeat(4, 1fr); }
.grid-auto { grid-template-columns: repeat(auto-fill, minmax(240px, 1fr)); }

.text-dim { color: var(--text-dim); }
.text-mute { color: var(--text-mute); }
.text-accent { color: var(--accent); }
.text-success { color: var(--success-ink); }
.text-danger { color: var(--danger-ink); }
.text-warning { color: var(--warning-ink); }
.text-center { text-align: center; }
.text-right { text-align: right; }
.fw-500 { font-weight: 500; } .fw-600 { font-weight: 600; } .fw-700 { font-weight: 700; }
.fs-xs { font-size: var(--text-xs); } .fs-sm { font-size: var(--text-sm); } .fs-lg { font-size: var(--text-lg); }
.truncate { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.uppercase { text-transform: uppercase; letter-spacing: .08em; }

.mt-1 { margin-top: var(--sp-1); } .mt-2 { margin-top: var(--sp-2); } .mt-3 { margin-top: var(--sp-3); } .mt-4 { margin-top: var(--sp-4); } .mt-5 { margin-top: var(--sp-5); } .mt-6 { margin-top: var(--sp-6); }
.mb-1 { margin-bottom: var(--sp-1); } .mb-2 { margin-bottom: var(--sp-2); } .mb-3 { margin-bottom: var(--sp-3); } .mb-4 { margin-bottom: var(--sp-4); } .mb-5 { margin-bottom: var(--sp-5); } .mb-6 { margin-bottom: var(--sp-6); }
.hidden { display: none !important; }
.full { width: 100%; }

.eyebrow {
    font-family: var(--font-mono);
    font-size: var(--text-2xs);
    text-transform: uppercase;
    letter-spacing: .16em;
    color: var(--text-mute);
}

@media (max-width: 900px) {
    .grid-4 { grid-template-columns: repeat(2, 1fr); }
    .grid-3 { grid-template-columns: 1fr; }
    .grid-2 { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
    .grid-4 { grid-template-columns: 1fr; }
    .container { padding-inline: var(--sp-4); }
}

@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after {
        animation-duration: .01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: .01ms !important;
        scroll-behavior: auto !important;
    }
}
