/* ==========================================================================
   SHANOVA — Reset, Grundtypografie, Fokus, Utilities
   ========================================================================== */

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

html {
  -webkit-text-size-adjust: 100%;
  scroll-behavior: smooth;
  scroll-padding-top: calc(var(--sh-header-h-sticky) + 24px);
}

body {
  margin: 0;
  background: var(--sh-bg-800);
  color: var(--sh-text);
  font-family: var(--sh-font-body);
  font-size: var(--sh-fs-body);
  line-height: var(--sh-lh-body);
  font-weight: 400;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  text-rendering: optimizeLegibility;
  overflow-x: hidden;
}

body.is-locked { overflow: hidden; }

h1, h2, h3, h4, h5, h6 {
  font-family: var(--sh-font-head);
  font-weight: 500;
  line-height: var(--sh-lh-head);
  margin: 0 0 var(--sp-4);
  color: var(--sh-text);
  text-wrap: balance;
}

h1 { font-size: var(--sh-fs-h1); letter-spacing: var(--sh-ls-h1); }
h2 { font-size: var(--sh-fs-h2); letter-spacing: var(--sh-ls-h2); }
h3 { font-size: var(--sh-fs-h3); }
h4 { font-size: var(--sh-fs-h4); }

p { margin: 0 0 var(--sp-4); max-width: var(--sh-measure); }
p:last-child { margin-bottom: 0; }

ul, ol { margin: 0 0 var(--sp-4); padding-left: 1.25em; max-width: var(--sh-measure); }
li { margin-bottom: var(--sp-2); }
li:last-child { margin-bottom: 0; }

a {
  color: var(--sh-gold-400);
  text-decoration: none;
  transition: color var(--dur) var(--ease);
}
a:hover {
  color: var(--sh-gold-300);
  text-decoration: underline;
  text-underline-offset: 4px;
  text-decoration-thickness: 1px;
}

strong, b { font-weight: 600; color: var(--sh-text); }

small { font-size: var(--sh-fs-small); }

hr {
  border: 0;
  border-top: 1px solid var(--sh-line);
  margin: var(--sp-12) 0;
}

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

code, kbd, samp, pre {
  font-family: var(--sh-font-mono);
  font-size: 0.9em;
}

code {
  background: var(--sh-bg-900);
  border: 1px solid var(--sh-line);
  border-radius: var(--r-xs);
  padding: 0.12em 0.4em;
  color: var(--sh-gold-300);
}

pre {
  background: var(--sh-bg-900);
  border: 1px solid var(--sh-line);
  border-left: 2px solid var(--sh-gold-500);
  border-radius: var(--r-sm);
  padding: var(--sp-4) var(--sp-6);
  overflow-x: auto;
  line-height: 1.6;
  margin: 0 0 var(--sp-6);
  font-size: var(--sh-fs-small);
  color: var(--sh-text-2);
}
pre code { background: none; border: 0; padding: 0; color: inherit; }

table {
  width: 100%;
  border-collapse: collapse;
  font-size: var(--sh-fs-small);
  margin: 0 0 var(--sp-6);
}
th, td {
  text-align: left;
  padding: var(--sp-3) var(--sp-4);
  border-bottom: 1px solid var(--sh-line);
}
th {
  font-family: var(--sh-font-mono);
  font-size: var(--sh-fs-xs);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--sh-text-3);
  font-weight: 500;
}

blockquote {
  margin: 0 0 var(--sp-6);
  padding: var(--sp-2) 0 var(--sp-2) var(--sp-6);
  border-left: 2px solid var(--sh-gold-500);
  color: var(--sh-text-2);
  font-size: var(--sh-fs-body-l);
}

::selection { background: var(--sh-gold-a35); color: var(--sh-text); }

/* ---------- Fokus: nirgends entfernt ---------- */
:focus { outline: none; }
:focus-visible {
  outline: 2px solid var(--sh-gold-300);
  outline-offset: 2px;
  border-radius: var(--r-xs);
}

/* ---------- Sprunglink ---------- */
.skip-link {
  position: absolute;
  left: var(--sp-4);
  top: var(--sp-4);
  z-index: 200;
  transform: translateY(-200%);
  background: var(--sh-gold-500);
  color: var(--sh-text-dark);
  font-weight: 600;
  font-size: var(--sh-fs-small);
  padding: var(--sp-3) var(--sp-4);
  border-radius: var(--r-sm);
  transition: transform var(--dur-slow) var(--ease);
}
.skip-link:focus-visible { transform: translateY(0); text-decoration: none; }

/* ==========================================================================
   Typografische Bausteine
   ========================================================================== */

/* Das typografische Zitat aus dem Claim: klein, weit gesperrt. */
.eyebrow {
  display: block;
  font-family: var(--sh-font-body);
  font-size: var(--sh-fs-eyebrow);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: var(--sh-ls-eyebrow);
  color: var(--sh-silver-300);
  margin: 0 0 var(--sp-4);
}
.eyebrow--gold { color: var(--sh-gold-500); }

.display {
  font-size: var(--sh-fs-display);
  line-height: var(--sh-lh-tight);
  letter-spacing: var(--sh-ls-display);
  font-weight: 500;
  margin: 0 0 var(--sp-6);
}

/* Schriftmuster ohne Gliederungswirkung — fuer den Styleguide, damit dort
   keine zweite h1 entsteht. */
.t-h1, .t-h2, .t-h3 {
  font-family: var(--sh-font-head);
  font-weight: 500;
  line-height: var(--sh-lh-head);
  color: var(--sh-text);
  margin: 0;
}
.t-h1 { font-size: var(--sh-fs-h1); letter-spacing: var(--sh-ls-h1); }
.t-h2 { font-size: var(--sh-fs-h2); letter-spacing: var(--sh-ls-h2); }
.t-h3 { font-size: var(--sh-fs-h3); }

.lead {
  font-size: var(--sh-fs-body-l);
  color: var(--sh-text-2);
  max-width: 58ch;
}

.meta {
  font-family: var(--sh-font-mono);
  font-size: var(--sh-fs-xs);
  color: var(--sh-text-3);
  letter-spacing: 0.02em;
}

.muted { color: var(--sh-text-2); }
.dim   { color: var(--sh-text-3); }

/* ==========================================================================
   Utilities
   ========================================================================== */

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

.stack > * + * { margin-top: var(--sp-4); }
.stack-lg > * + * { margin-top: var(--sp-8); }

.text-center { text-align: center; }
.mb-0 { margin-bottom: 0; }
.mt-6 { margin-top: var(--sp-6); }
.mt-8 { margin-top: var(--sp-8); }
.mt-12 { margin-top: var(--sp-12); }

/* Hexagon-Maske — der direkteste Formbezug zum Logo. */
.hex {
  clip-path: var(--clip-hex);
  -webkit-clip-path: var(--clip-hex);
}

/* Duenne Goldlinie als Sektionstrenner. */
.rule-gold {
  height: 1px;
  border: 0;
  margin: 0;
  background: linear-gradient(90deg,
    transparent,
    var(--sh-gold-a35) 15%,
    var(--sh-gold-a35) 85%,
    transparent);
}

.rule {
  height: 1px;
  border: 0;
  margin: 0;
  background: var(--sh-line);
}

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