:root {
  --blue: #1b2330;
  --green: #01c853;
  --gray: #e8e9ea;
  --text: #1b2330;
  --text-muted: #5a6270;
  --white: #ffffff;
  --header-h: 76px;
}

* { box-sizing: border-box; }

html { scroll-behavior: smooth; }

body {
  margin: 0;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  font-family: 'Segoe UI', system-ui, -apple-system, Roboto, sans-serif;
  color: var(--text);
  background: var(--white);
  line-height: 1.55;
}

main {
  flex: 1;
  display: flex;
  flex-direction: column;
}

.container {
  max-width: 780px;
  margin: 0 auto;
  padding: 0 24px;
  width: 100%;
}

.hidden { display: none !important; }

/* Honeypot-Feld: bewusst nicht display:none (das überspringen manche
   simplen Bots gezielt) — stattdessen aus dem sichtbaren Bereich
   herausgeschoben, für Menschen unsichtbar, per Tab nicht erreichbar. */
.hp-field {
  position: absolute;
  left: -9999px;
  top: auto;
  width: 1px;
  height: 1px;
  overflow: hidden;
}

/* Header — nachgebildet vom alldesk.ch-Menüband: grauer Hintergrund,
   sticky, nur Logo (die Microsite ist eine einzelne Seite, kein Menü
   nötig). */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--gray);
  border-bottom: 1px solid transparent;
  transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

.site-header.scrolled {
  box-shadow: 0 2px 10px rgba(27, 35, 48, 0.1);
  border-bottom-color: #d5d7da;
}

.header-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: var(--header-h);
}

.brand {
  display: flex;
  align-items: center;
}

.brand-logo {
  height: 40px;
  width: auto;
  display: block;
}

/* Pill-Button im Stil des "Fernwartung"-CTAs im alldesk.ch-Menüband. */
.header-cta {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  background: var(--green);
  color: var(--blue);
  text-decoration: none;
  font-weight: 700;
  font-size: 0.95rem;
  padding: 11px 22px;
  border-radius: 999px;
  transition: filter 0.15s ease;
}

.header-cta:hover { filter: brightness(1.08); }

/* Hero füllt die Ansicht unterhalb des Headers — modernes Onepage-Gefühl. */
.hero {
  position: relative;
  overflow: hidden;
  flex: 1;
  min-height: calc(100vh - var(--header-h));
  display: flex;
  align-items: center;
  background: var(--blue);
  color: var(--white);
  text-align: center;
  padding: 48px 0;
}

/* Hero-Inneres: mobil eine Spalte (Grafik liegt als schwacher Hintergrund
   hinter dem Text, siehe .hero-visual-slot), ab 960px ein echtes
   zweispaltiges Layout wie bei ranq.ch — Text links, Grafik als
   eigenständige Spalte rechts, ohne Überlappung/Beschnitt. */
.hero-inner {
  position: relative;
  z-index: 1;
  width: 100%;
}

/* Mobil: kein eigener Layout-Slot, die Grafik legt sich per position:
   absolute selbst hinter den Text (siehe .hero-visual unten). */
.hero-visual-slot {
  display: contents;
}

/* Hintergrund-Visual: Schweiz-Silhouette mit rotierendem Radar-Sweep und
   pulsierenden "Ping"-Punkten (Bedrohungs-/Angriffs-Metapher), plus ein
   paar schwebenden Security-Icons. Rein dekorativ, pointer-events: none. */
.hero-visual {
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: min(90vw, 900px);
  height: auto;
  aspect-ratio: 800 / 700;
  z-index: 0;
  opacity: 0.28;
  pointer-events: none;
  transition: opacity 0.3s ease;
}

@media (min-width: 960px) {
  .hero-inner {
    max-width: 1200px;
    display: flex;
    flex-direction: row-reverse;
    align-items: center;
    justify-content: space-between;
    gap: 48px;
  }

  .hero-text {
    text-align: left;
    max-width: 480px;
    flex: 0 0 auto;
  }

  .hero .lead { margin-left: 0; margin-right: 0; }
  .hero .check-form { margin-left: 0; }

  /* Auf Desktop wird die Grafik ein normales Flex-Item statt eines
     absolut positionierten Hintergrunds — dadurch kein Abschneiden am
     Viewport-Rand mehr und volle Deckkraft, da sie den Text nicht mehr
     überlagert. */
  .hero-visual-slot {
    display: block;
    position: relative;
    flex: 1 1 480px;
    max-width: 600px;
    align-self: center;
  }

  .hero-visual {
    position: static;
    transform: none;
    width: 100%;
    opacity: 1;
  }
}

/* Abstraktes Security-Dashboard-Panel statt Landkarte/Radar (zu nah an
   einer anderen Website) — ein "Monitor" mit Log-Zeilen, Scan-Beam und
   Mini-Balkendiagramm, klar als generische IT-Übersicht erkennbar statt
   konkreter Inhalte. */
.panel-bg {
  fill: rgba(255, 255, 255, 0.04);
}

.panel-header {
  fill: rgba(255, 255, 255, 0.06);
}

.panel-border {
  fill: none;
  stroke: rgba(232, 233, 234, 0.25);
  stroke-width: 1.5;
}

.panel-live-dot {
  fill: #01c853;
  animation: live-pulse 1.6s ease-in-out infinite;
}

@keyframes live-pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.25; }
}

.scan-beam {
  animation: scan-move 3.2s ease-in-out infinite;
}

@keyframes scan-move {
  0% { transform: translateY(0); }
  100% { transform: translateY(450px); }
}

.panel-line {
  fill: rgba(1, 200, 83, 0.35);
  animation: line-appear 4s ease-in-out infinite;
}

@keyframes line-appear {
  0%, 100% { opacity: 0.35; }
  50% { opacity: 0.9; }
}

.panel-cursor {
  fill: #01c853;
  animation: cursor-blink 1s steps(1) infinite;
}

@keyframes cursor-blink {
  0%, 49% { opacity: 1; }
  50%, 100% { opacity: 0; }
}

.hero-icon-float {
  transform-origin: center;
  animation: icon-float 4s ease-in-out infinite;
}

@keyframes icon-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

/* Glassmorphismus-Karte für das Eingabeformular über dem Netzwerk-Hintergrund. */
.glass {
  background: rgba(255, 255, 255, 0.08);
  border: 1px solid rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-radius: 14px;
  padding: 14px;
}

.hero h1 {
  font-size: 2.6rem;
  margin: 0 0 20px;
  font-weight: 700;
}

.lead {
  color: var(--gray);
  font-size: 1.1rem;
  max-width: 560px;
  margin: 0 auto 40px;
}

.check-form {
  display: flex;
  gap: 12px;
  max-width: 480px;
  margin: 0 auto;
}

#domain-input {
  flex: 1;
  padding: 15px 16px;
  border-radius: 6px;
  border: none;
  font-size: 1rem;
}

#check-button {
  background: var(--green);
  color: var(--blue);
  border: none;
  padding: 15px 24px;
  border-radius: 6px;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  transition: filter 0.15s ease;
}

#check-button:hover { filter: brightness(1.08); }
#check-button:disabled { opacity: 0.6; cursor: default; }

.form-hint {
  color: #ff8a80;
  min-height: 1.2em;
  margin: 12px 0 0;
  font-size: 0.9rem;
}

/* Auf dem hellen Kontaktformular-Hintergrund braucht es dunkleres Rot als
   auf dem dunklen Hero, sonst ist der Kontrast zu schwach. */
#contact-error {
  color: #b3261e;
}

.loading-section, .result-section {
  flex: 1;
  min-height: calc(100vh - var(--header-h));
  display: flex;
  align-items: center;
  padding: 56px 0;
}

/* Dunkler Hintergrund wie der Hero, statt whrend des Scans abrupt auf
   Weiss zu wechseln — sonst wirkt der Sprung mitten im Ablauf zu hart. */
.loading-section {
  background: var(--blue);
  color: var(--white);
}

.loading-section .container,
.result-section .container {
  width: 100%;
}

.loader {
  max-width: 480px;
  margin: 0 auto;
  text-align: center;
}

.loader-bar-wrap {
  position: relative;
  margin-top: 36px;
}

/* Domain-Label "reitet" auf dem Fortschritt mit, damit sichtbar ist, was
   gerade geprüft wird, statt eines anonymen Balkens. */
.loader-tag {
  position: absolute;
  bottom: 100%;
  margin-bottom: 10px;
  left: 0%;
  transform: translateX(-50%);
  background: var(--green);
  color: var(--blue);
  font-weight: 700;
  font-size: 0.8rem;
  padding: 5px 12px;
  border-radius: 999px;
  white-space: nowrap;
  transition: left 0.7s ease;
  box-shadow: 0 3px 10px rgba(0, 0, 0, 0.3);
}

.loader-tag::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 5px solid transparent;
  border-top-color: var(--green);
}

.loader-bar {
  height: 10px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.12);
  overflow: hidden;
  margin-bottom: 16px;
  box-shadow: 0 0 18px rgba(1, 200, 83, 0.25);
}

.loader-bar-fill {
  position: relative;
  height: 100%;
  width: 0%;
  border-radius: 999px;
  background: linear-gradient(90deg, #01c853, #4dffa0, #01c853);
  background-size: 200% 100%;
  box-shadow: 0 0 12px rgba(1, 200, 83, 0.7);
  animation: bar-shimmer 1.4s linear infinite;
  transition: width 0.4s ease;
  overflow: hidden;
}

.loader-bar-fill::after {
  content: '';
  position: absolute;
  inset: 0;
  background-image: repeating-linear-gradient(
    45deg,
    rgba(255, 255, 255, 0.3) 0,
    rgba(255, 255, 255, 0.3) 8px,
    transparent 8px,
    transparent 16px
  );
  animation: stripes-move 0.8s linear infinite;
}

@keyframes bar-shimmer {
  0% { background-position: 0% 0; }
  100% { background-position: 200% 0; }
}

@keyframes stripes-move {
  0% { background-position: 0 0; }
  100% { background-position: 32px 0; }
}

#loading-step {
  color: var(--gray);
  font-size: 0.95rem;
}

.result-container {
  text-align: center;
  max-width: 640px;
  margin: 0 auto;
}

/* Ergebnis deutlich hervorgehoben: eigene Karte mit Farbverlauf-Rahmen
   passend zur Kategorie, statt einfach im Fliesstext unterzugehen. */
.result-card {
  background: linear-gradient(160deg, var(--blue), #232d3f);
  color: var(--white);
  border-radius: 16px;
  padding: 44px 32px;
  margin-bottom: 32px;
  box-shadow: 0 12px 32px rgba(27, 35, 48, 0.18);
}

/* Score-Ring: grosse, farbige Kennzahl statt versteckter Textwertung.
   Zahl wird per absoluter Positionierung im Wrapper zentriert statt über
   Margin-Schätzwerte, die je nach Zeilenhöhe/Font daneben lagen. */
.score-gauge-wrap {
  position: relative;
  width: 120px;
  height: 120px;
  margin: 0 auto 24px;
}

.score-gauge {
  width: 100%;
  height: 100%;
  transform: rotate(-90deg);
}

.score-ring-track {
  fill: none;
  stroke: rgba(255, 255, 255, 0.12);
  stroke-width: 10;
}

.score-ring-fill {
  fill: none;
  stroke-width: 10;
  stroke-linecap: round;
  transition: stroke-dashoffset 0.8s ease, stroke 0.3s ease;
}

.score-ring-fill.low { stroke: #ff6b4a; }
.score-ring-fill.mid { stroke: #ffc233; }
.score-ring-fill.high { stroke: var(--green); }

.score-value {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.8rem;
  font-weight: 800;
  line-height: 1;
}

.result-badge {
  display: inline-block;
  padding: 8px 18px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 0.85rem;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  margin-bottom: 20px;
}

.result-badge.low { background: #ffe3e0; color: #b3261e; }
.result-badge.mid { background: #fff2cc; color: #8a6100; }
.result-badge.high { background: #e0f7e9; color: #146c2e; }

.result-card h2 {
  font-size: 2rem;
  margin: 0 0 16px;
}

.result-card .result-description {
  color: var(--gray);
  max-width: 480px;
  margin: 0 auto;
}

/* Sneak Peek: ein paar geprüfte Kategorien sind namentlich sichtbar
   (farblich hervorgehoben), der Rest wird als gesperrte Platzhalter-Karte
   dargestellt. Die verborgenen Namen werden serverseitig nie an den
   Client geschickt (kein CSS-Blur, der im Quellcode auslesbar wäre). */
.sneak-peek {
  text-align: left;
  margin-bottom: 32px;
}

.sneak-peek h3 {
  margin: 0 0 8px;
  font-size: 1.15rem;
}

.sneak-peek-hint {
  color: var(--text-muted);
  font-size: 0.9rem;
  margin: 0 0 16px;
}

.category-list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  gap: 10px;
}

.category-list li {
  border-radius: 8px;
  padding: 12px 14px;
  font-size: 0.9rem;
  font-weight: 600;
}

/* Die 2 gezeigten Checks sind bewusst gewählt (bevorzugt fehlgeschlagene)
   und entsprechend rot/grün eingefärbt statt neutral. */
.category-ok {
  background: #e0f7e9;
  color: #146c2e;
  border: 1px solid #b8ecc9;
}

.category-fail {
  background: #ffe3e0;
  color: #b3261e;
  border: 1px solid #ffc4bd;
}

/* Gesperrte Platzhalter tragen keinen echten Namen (der Server schickt
   nur den anonymisierten Pass/Fail-Status), sind aber entsprechend
   rot/grün eingefärbt statt pauschal in einer Farbe — sonst wirkt es bei
   einem schlechten Score so, als hätte die Domain überall versagt, auch
   wenn einzelne Checks bestanden wurden. Label/Icon sind zusätzlich
   optisch stark geblurrt: der Effekt ist rein dekorativ, der Text im
   Quellcode bleibt ein generisches "Security Check #.." mit Zufallszahl,
   also unbedenklich. Gestrichelter statt durchgezogener Rahmen macht den
   Unterschied zu den 2 aufgedeckten Checks sichtbar. */
.category-locked {
  display: flex;
  align-items: center;
  gap: 8px;
  font-weight: 500;
  border-style: dashed;
  border-width: 1px;
}

.category-locked svg { flex-shrink: 0; filter: blur(2.5px); opacity: 0.7; }

.category-locked-label {
  filter: blur(4.5px);
  opacity: 0.85;
  letter-spacing: 0.5px;
}

.contact-box {
  background: var(--gray);
  border-radius: 10px;
  padding: 32px;
  text-align: left;
  margin-bottom: 24px;
}

.contact-box h3 {
  margin-top: 0;
}

.cta-button {
  display: inline-block;
  background: var(--green);
  color: var(--blue);
  border: none;
  padding: 14px 26px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 1rem;
  cursor: pointer;
  margin-top: 6px;
  transition: filter 0.15s ease, transform 0.15s ease;
}

.cta-button:hover { filter: brightness(1.08); transform: translateY(-1px); }

.contact-form {
  display: flex;
  flex-direction: column;
  gap: 10px;
  margin-top: 18px;
}

.contact-form input {
  padding: 12px 14px;
  border-radius: 6px;
  border: 1px solid #c6c9cd;
  font-size: 0.95rem;
}

.contact-form button {
  background: var(--blue);
  color: var(--white);
  border: none;
  padding: 13px 20px;
  border-radius: 6px;
  font-weight: 700;
  cursor: pointer;
  margin-top: 4px;
  transition: background 0.15s ease, opacity 0.15s ease;
}

.contact-form button:hover:not(:disabled) { background: #0f151f; }
.contact-form button:disabled { opacity: 0.5; cursor: not-allowed; }

.contact-sent {
  color: #146c2e;
  font-weight: 600;
  margin-top: 14px;
}

.link-button {
  background: none;
  border: none;
  color: var(--text-muted);
  text-decoration: underline;
  cursor: pointer;
  font-size: 0.9rem;
}

.disclaimer {
  background: var(--gray);
  color: var(--text-muted);
  font-size: 0.85rem;
  text-align: center;
  padding: 28px 0;
}

/* Nachgebildet vom Footer-Balken auf www.alldesk.ch: dünne Trennlinie
   oben, links Copyright-Zeile, rechts Rechtstext-Links. */
.site-footer {
  background: var(--blue);
  color: var(--gray);
  padding: 20px 0;
  font-size: 0.85rem;
  border-top: 1px solid rgba(232, 233, 234, 0.15);
}

.footer-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.footer-copy { color: var(--gray); }

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 24px;
}

.footer-links a {
  color: var(--gray);
  text-decoration: none;
}

.footer-links a:hover { color: var(--green); }

@media (max-width: 520px) {
  .footer-row { flex-direction: column; text-align: center; }
  .footer-links { justify-content: center; gap: 16px; }
}

@media (max-width: 760px) {
  .brand-logo { height: 32px; }
  .header-cta span { display: none; }
}

@media (max-width: 520px) {
  .check-form { flex-direction: column; }
  .hero h1 { font-size: 1.8rem; }
  .header-cta { padding: 10px 14px; gap: 0; }
  .header-cta svg { width: 20px; height: 20px; }
}
