/* ==========================================================
   NG-Technikwerk – Website Stylesheet
   Statische HTML5-Website | Mobile First Enhancements
   ========================================================== */

/* 1. Design-Tokens und Basis */
:root {
  color-scheme: dark;

  --bg: #0b1320;
  --panel: #111e2d;
  --panel2: #17283b;
  --text: #f0f7fd;
  --muted: #aec0d0;
  --accent: #38bdf8;
  --accent2: #62e1c0;
  --line: #2b4054;
  --max: 1120px;
}

.nowrap {
  white-space: nowrap;
}

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

html {
  scroll-behavior: smooth;
  scroll-padding-top: 1.5rem;
}

body {
  margin: 0;
  min-width: 0;
  background: var(--bg);
  color: var(--text);
  font: 400 1rem / 1.7 system-ui, -apple-system, BlinkMacSystemFont,
    "Segoe UI", sans-serif;
  overflow-wrap: break-word;
}

a {
  color: inherit;
}

a:focus-visible {
  outline: 3px solid var(--accent2);
  outline-offset: 4px;
}

img,
svg {
  max-width: 100%;
}

img {
  height: auto;
}

h1,
h2,
h3,
p {
  margin-top: 0;
}

h1,
h2,
h3 {
  line-height: 1.17;
  letter-spacing: -0.035em;
  overflow-wrap: break-word;
}

h1 {
  max-width: 850px;
  font-size: clamp(2.6rem, 6.5vw, 5.25rem);
}

h2 {
  font-size: clamp(2rem, 4vw, 3.15rem);
}

h3 {
  font-size: 1.35rem;
}

.container {
  width: min(var(--max), calc(100% - 40px));
  margin-inline: auto;
}

/* 2. Barrierefreiheit */
.skip {
  position: absolute;
  top: -5rem;
  left: 1rem;
  z-index: 10;
  padding: 0.6rem;
  background: white;
  color: black;
}

.skip:focus {
  top: 1rem;
}

/* 3. Header und Navigation */
.site-header {
  border-bottom: 1px solid var(--line);
  background: #0b1320f2;
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1.4rem;
  min-height: 86px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  min-width: 0;
  text-decoration: none;
  font-weight: 850;
  letter-spacing: 0.02em;
  line-height: 1.05;
}

.brand-mark {
  width: 45px;
  height: 45px;
  flex: none;
}

.brand span span {
  display: block;
  margin-top: 0.2rem;
  color: var(--accent);
  font-size: 0.65rem;
  letter-spacing: 0.19em;
}

.nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: clamp(0.6rem, 2vw, 1.6rem);
}

.nav a {
  color: #d6e4ef;
  font-size: 0.93rem;
  font-weight: 650;
  text-decoration: none;
}

.nav a:hover,
.footer-links a:hover,
.text-link:hover {
  color: var(--accent);
}

.nav .nav-cta {
  padding: 0.55rem 0.95rem;
  border: 1px solid var(--accent);
  border-radius: 8px;
  color: var(--text);
}

/* 4. Hero */
.hero {
  position: relative;
  overflow: hidden;
  padding: clamp(80px, 11vw, 155px) 0 clamp(78px, 10vw, 130px);
  background: radial-gradient(
    ellipse 65% 85% at 100% 10%,
    #153451 0%,
    transparent 70%
  );
}

.eyebrow {
  margin-bottom: 1.2rem;
  color: var(--accent2);
  font-size: 0.82rem;
  font-weight: 750;
  letter-spacing: 0.15em;
  text-transform: uppercase;
}

.hero p {
  max-width: 660px;
  font-size: clamp(1.08rem, 1.8vw, 1.24rem);
}

.accent {
  color: var(--accent);
}

.actions {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-top: 2rem;
}

/* 5. Buttons */
.button {
  display: inline-block;
  max-width: 100%;
  padding: 0.85rem 1.25rem;
  border-radius: 9px;
  background: var(--accent);
  color: #05111c;
  font-weight: 800;
  line-height: 1.4;
  text-align: center;
  text-decoration: none;
  overflow-wrap: anywhere;
  transition: background-color 150ms ease, border-color 150ms ease;
}

.button:hover {
  background: #8cddff;
}

.button.secondary {
  border: 1px solid #637b91;
  background: transparent;
  color: var(--text);
}

.button.secondary:hover {
  border-color: var(--accent);
}

/* 6. Vertrauensmerkmale */
.trust {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem 2rem;
  margin-top: 2.4rem;
  color: var(--muted);
  font-size: 0.9rem;
}

.trust span::before {
  content: "✓";
  padding-right: 0.5rem;
  color: var(--accent2);
}

/* 7. Inhaltsabschnitte */
.section {
  padding: clamp(72px, 9vw, 110px) 0;
}

.section-dark {
  background: #0f1a28;
}

.section-intro {
  max-width: 720px;
  margin-bottom: 2.4rem;
}

.section-intro p {
  font-size: 1.08rem;
}

.grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.2rem;
}

.service {
  min-width: 0;
  padding: 2rem;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: var(--panel);
}

.service .number {
  color: var(--accent2);
  font-size: 0.85rem;
  font-weight: 800;
  letter-spacing: 0.12em;
}

.service p {
  min-height: 7rem;
}

.service ul {
  margin: 1rem 0 0;
  padding-left: 1.25rem;
  color: #d2dfeb;
}

.service li {
  margin: 0.35rem 0;
}

/* 8. Geteilte Inhalte und Hervorhebungen */
.split {
  display: grid;
  grid-template-columns: 1.1fr 0.9fr;
  align-items: center;
  gap: 3rem;
}

.highlight {
  padding: 2.2rem;
  border: 1px solid var(--line);
  border-radius: 15px;
  background: linear-gradient(145deg, #163047, #10202d);
}

.highlight strong {
  display: block;
  color: var(--text);
  font-size: 1.2rem;
}

/* 9. Ablauf / Schritte */
.steps {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 1.2rem;
  counter-reset: step;
}

.step {
  min-width: 0;
  padding: 1.5rem;
  border-left: 2px solid var(--accent);
  background: #122133;
}

.step .count {
  color: var(--accent2);
  font-weight: 800;
}

/* 10. Kontakt */
.contact {
  padding: clamp(2rem, 6vw, 4rem);
  border: 1px solid #2a4962;
  border-radius: 18px;
  background: linear-gradient(105deg, #132a40, #0f2030);
}

.contact p {
  max-width: 650px;
}

.contact .button {
  margin-top: 0.5rem;
}

/* Wird in der mobilen Ansicht gewechselt.
   Hierfür muss das HTML .desktop-only und .mobile-only enthalten. */
.mobile-only {
  display: none;
}

/* 11. Footer */
.footer {
  padding: 2.1rem 0;
  border-top: 1px solid var(--line);
}

.footer-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 1.5rem;
}

.footer p {
  margin: 0;
  font-size: 0.87rem;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 1.3rem;
}

.footer-links a {
  color: var(--muted);
  font-size: 0.9rem;
}

/* 12. Impressum und Datenschutz */
.legal {
  max-width: 850px;
  padding: 4.5rem 0 6rem;
}

.legal h1 {
  font-size: clamp(2.6rem, 5vw, 4rem);
}

.legal h2 {
  margin-top: 2.3rem;
  font-size: 1.5rem;
}

.legal h3 {
  font-size: 1.15rem;
}

.legal p,
.legal li {
  max-width: 78ch;
}

.legal a {
  color: var(--accent);
  overflow-wrap: anywhere;
}

.legal address {
  color: var(--muted);
  font-style: normal;
}

.small {
  font-size: 0.88rem;
}

.text-link {
  color: var(--accent);
  text-underline-offset: 3px;
}

/* 13. Tablet und kleine Notebooks */
@media (max-width: 790px) {
  .header-inner {
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
    min-height: 0;
    padding: 1rem 0;
  }

  .nav {
    width: 100%;
    gap: 0.75rem 1rem;
  }

  .grid,
  .steps {
    grid-template-columns: 1fr;
  }

  .service p {
    min-height: 0;
  }

  .split {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }

  .hero {
    padding-top: 78px;
  }
}

/* 14. Smartphones: Touch-Ziele, Kontakt und Abstände */
@media (max-width: 767px) {
  .desktop-only {
    display: none;
  }

  .mobile-only {
    display: inline;
  }

  .contact .button {
    display: block;
    width: 100%;
    max-width: 320px;
    min-height: 48px;
    margin: 0.75rem 0 0;
    align-content: center;
  }

  .actions .button {
    min-height: 48px;
  }

  .nav a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
  }

  .footer-links a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
  }
}

/* 15. Schmale Smartphones */
@media (max-width: 420px) {
  .container {
    width: min(var(--max), calc(100% - 28px));
  }

  h1 {
    font-size: clamp(2.15rem, 10vw, 2.75rem);
  }

  h2 {
    font-size: clamp(1.75rem, 8vw, 2.3rem);
  }

  .hero {
    padding: 64px 0 76px;
  }

  .section {
    padding: 60px 0;
  }

  .nav {
    gap: 0.35rem 0.85rem;
  }

  .nav a {
    font-size: 0.85rem;
  }

  .nav .nav-cta {
    padding: 0.4rem 0.6rem;
  }

  .actions {
    flex-direction: column;
    gap: 0.75rem;
  }

  .actions .button {
    width: 100%;
  }

  .trust {
    gap: 0.55rem 1rem;
  }

  .service {
    padding: 1.5rem;
  }

  .highlight {
    padding: 1.5rem;
  }

  .contact {
    padding: 1.5rem;
  }

  .contact .button {
    max-width: none;
  }

  .legal {
    padding: 3rem 0 4rem;
  }
}

/* 16. Bewegung reduzieren, falls vom System gewünscht */
@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  .button {
    transition: none;
  }
}
