/* =========================================================
   HIS Integration — Design Tokens
   Colors sampled directly from the client logo (HIS Logo.png):
     background navy  #0E1116
     brand teal        #146265
     off-white text    #C6C1C1
   ========================================================= */

:root {
  /* --- Color: surfaces --- */
  --c-bg: #0E1116;
  --c-bg-elev: #151B22;
  --c-bg-elev-2: #1C2530;
  --c-border: #262F3A;
  --c-border-strong: #333F4C;

  /* --- Color: teal (brand) --- */
  --c-teal-900: #081F20;
  --c-teal-800: #0C3436;
  --c-teal-700: #146265; /* exact brand value from logo */
  --c-teal-600: #1A7478;
  --c-teal-400: #2EC4C9; /* bright accent / glow */
  --c-teal-300: #7FDCDF;

  /* --- Color: text --- */
  --c-text-primary: #F2F0ED;
  --c-text-body: #C9C5C2; /* matches logo off-white */
  --c-text-muted: #8B9299;
  --c-text-on-teal: #F2F0ED;

  /* --- Semantic --- */
  --c-danger: #E57A6E;
  --c-success: #5FC7A6;

  /* --- Typography --- */
  --font-display: 'Manrope', 'Inter', system-ui, sans-serif;
  --font-body: 'Inter', system-ui, sans-serif;

  /* --- Spacing scale (4/8pt rhythm) --- */
  --space-1: 4px;
  --space-2: 8px;
  --space-3: 12px;
  --space-4: 16px;
  --space-5: 24px;
  --space-6: 32px;
  --space-7: 48px;
  --space-8: 64px;
  --space-9: 96px;

  /* --- Radius / Shadow / Motion --- */
  --radius-sm: 8px;
  --radius-md: 14px;
  --radius-lg: 22px;
  --radius-full: 999px;
  --shadow-card: 0 12px 32px -16px rgba(0, 0, 0, 0.55);
  --shadow-glow: 0 0 60px -12px rgba(46, 196, 201, 0.35);
  --ease-out: cubic-bezier(0.16, 1, 0.3, 1);
  --dur-fast: 150ms;
  --dur-base: 250ms;
  --dur-slow: 400ms;

  --container-w: 1180px;
}

/* =========================================================
   Self-hosted fonts (no third-party requests / no IP transfer
   to Google servers — keeps the site GDPR-clean by default)
   ========================================================= */
@font-face {
  font-family: 'Inter';
  font-style: normal;
  font-weight: 400 600;
  font-display: swap;
  src: url('../assets/fonts/inter-latin.woff2') format('woff2');
}
@font-face {
  font-family: 'Manrope';
  font-style: normal;
  font-weight: 400 800;
  font-display: swap;
  src: url('../assets/fonts/manrope-latin.woff2') format('woff2');
}

/* =========================================================
   Reset
   ========================================================= */
*, *::before, *::after { box-sizing: border-box; }
html { scroll-behavior: smooth; }
@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
    scroll-behavior: auto !important;
  }
}

body, h1, h2, h3, p, ul, ol, figure { margin: 0; }
ul, ol { padding: 0; list-style: none; }
img { max-width: 100%; display: block; }
button { font: inherit; cursor: pointer; }
a { color: inherit; text-decoration: none; }
input, textarea, select, button { font: inherit; color: inherit; }

body {
  background: var(--c-bg);
  color: var(--c-text-body);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1, h2, h3 {
  font-family: var(--font-display);
  color: var(--c-text-primary);
  line-height: 1.2;
  font-weight: 700;
}

h1 { font-size: clamp(2.2rem, 4.5vw, 3.4rem); font-weight: 800; letter-spacing: -0.02em; }
h2 { font-size: clamp(1.7rem, 3vw, 2.3rem); letter-spacing: -0.01em; }
h3 { font-size: 1.15rem; font-weight: 700; }

.text-accent { color: var(--c-teal-300); }

.container {
  width: 100%;
  max-width: var(--container-w);
  margin-inline: auto;
  padding-inline: var(--space-5);
}

.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  background: var(--c-teal-400);
  color: #05201f;
  padding: var(--space-3) var(--space-5);
  border-radius: var(--radius-sm);
  z-index: 200;
  font-weight: 600;
}
.skip-link:focus {
  left: var(--space-4);
  top: var(--space-4);
}

:focus-visible {
  outline: 2px solid var(--c-teal-400);
  outline-offset: 3px;
  border-radius: var(--radius-sm);
}

/* =========================================================
   Buttons
   ========================================================= */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: var(--space-2);
  padding: 13px 24px;
  border-radius: var(--radius-full);
  font-weight: 600;
  font-size: 0.95rem;
  border: 1px solid transparent;
  transition: transform var(--dur-fast) var(--ease-out),
              background-color var(--dur-fast) var(--ease-out),
              border-color var(--dur-fast) var(--ease-out);
  white-space: nowrap;
}
.btn:active { transform: scale(0.97); }
.btn .icon { width: 18px; height: 18px; }

.btn-primary {
  background: var(--c-teal-700);
  color: var(--c-text-on-teal);
}
.btn-primary:hover { background: var(--c-teal-600); }

.btn-ghost {
  background: transparent;
  border-color: var(--c-border-strong);
  color: var(--c-text-primary);
}
.btn-ghost:hover { border-color: var(--c-teal-400); color: var(--c-teal-300); }

.btn-lg { padding: 16px 30px; font-size: 1rem; }
.btn-sm { padding: 10px 18px; font-size: 0.875rem; }
.btn-block { width: 100%; }

/* =========================================================
   Icons
   ========================================================= */
.icon {
  width: 22px;
  height: 22px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.75;
  stroke-linecap: round;
  stroke-linejoin: round;
  flex-shrink: 0;
}
.icon-accent { color: var(--c-teal-400); }
.icon-lg { width: 32px; height: 32px; }

/* =========================================================
   Header
   ========================================================= */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  background: rgba(14, 17, 22, 0.82);
  backdrop-filter: blur(14px);
  border-bottom: 1px solid var(--c-border);
}

.header-inner {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 76px;
  gap: var(--space-5);
}

.brand-logo { height: 34px; width: auto; }

.main-nav {
  display: none;
  align-items: center;
  gap: var(--space-6);
  font-weight: 500;
  font-size: 0.95rem;
  color: var(--c-text-body);
}
.main-nav a { position: relative; padding: var(--space-2) 0; transition: color var(--dur-fast) var(--ease-out); }
.main-nav a:hover { color: var(--c-text-primary); }
.main-nav a::after {
  content: "";
  position: absolute;
  left: 0; right: 100%;
  bottom: -2px;
  height: 2px;
  background: var(--c-teal-400);
  transition: right var(--dur-base) var(--ease-out);
}
.main-nav a:hover::after { right: 0; }

.header-actions { display: flex; align-items: center; gap: var(--space-4); }
.header-actions .btn-primary { display: none; }

.nav-toggle {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 44px;
  height: 44px;
  background: transparent;
  border: 1px solid var(--c-border-strong);
  border-radius: var(--radius-sm);
  color: var(--c-text-primary);
}

.mobile-nav {
  display: flex;
  flex-direction: column;
  gap: var(--space-1);
  max-height: 0;
  overflow: hidden;
  border-top: 1px solid transparent;
  transition: max-height var(--dur-slow) var(--ease-out), border-color var(--dur-slow);
}
.mobile-nav.is-open {
  max-height: 420px;
  border-top-color: var(--c-border);
}
.mobile-nav a {
  padding: var(--space-4) var(--space-5);
  font-weight: 500;
}
.mobile-nav a.btn { margin: var(--space-3) var(--space-5) var(--space-5); }

@media (min-width: 900px) {
  .main-nav { display: flex; }
  .header-actions .btn-primary { display: inline-flex; }
  .nav-toggle { display: none; }
  .mobile-nav { display: none; }
}

/* =========================================================
   Hero
   ========================================================= */
.hero {
  position: relative;
  overflow: hidden;
  padding-block: var(--space-8) var(--space-9);
}

.hero-glow {
  position: absolute;
  inset: -20% -10% auto -10%;
  height: 620px;
  background: radial-gradient(60% 60% at 50% 20%, rgba(20, 98, 101, 0.35), transparent 70%);
  pointer-events: none;
}

.hero-inner {
  position: relative;
  display: grid;
  gap: var(--space-8);
  align-items: center;
}

.eyebrow {
  color: var(--c-teal-300);
  font-weight: 700;
  font-size: 0.8rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  margin-bottom: var(--space-4);
}

.hero-lead {
  margin-top: var(--space-5);
  max-width: 46ch;
  font-size: 1.08rem;
  color: var(--c-text-body);
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: var(--space-4);
  margin-top: var(--space-7);
}

.hero-visual { justify-self: center; width: min(420px, 90vw); }
.network-graphic { width: 100%; height: auto; }
.net-nodes .node {
  fill: var(--c-teal-400);
  stroke: var(--c-teal-900);
  stroke-width: 6;
}
.net-nodes .node-core { fill: var(--c-teal-300); }
.net-nodes .node-sm { fill: var(--c-teal-600); }

@media (min-width: 900px) {
  .hero-inner { grid-template-columns: 1.05fr 0.95fr; }
}

/* =========================================================
   Trust strip
   ========================================================= */
.trust-strip {
  border-top: 1px solid var(--c-border);
  border-bottom: 1px solid var(--c-border);
  padding-block: var(--space-6);
}
.trust-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: var(--space-5);
}
.trust-item {
  display: flex;
  align-items: center;
  gap: var(--space-3);
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--c-text-body);
}
@media (min-width: 700px) {
  .trust-grid { grid-template-columns: repeat(4, 1fr); }
}

/* =========================================================
   Sections
   ========================================================= */
.section { padding-block: var(--space-9); }
.section-alt { background: var(--c-bg-elev); }

.section-head { max-width: 640px; margin-bottom: var(--space-8); }
.section-lead { margin-top: var(--space-4); font-size: 1.05rem; color: var(--c-text-body); }

/* =========================================================
   Services grid
   ========================================================= */
.services-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-5);
}
@media (min-width: 640px) { .services-grid { grid-template-columns: repeat(2, 1fr); } }
@media (min-width: 1000px) { .services-grid { grid-template-columns: repeat(4, 1fr); } }

.service-card {
  background: var(--c-bg-elev);
  border: 1px solid var(--c-border);
  border-radius: var(--radius-md);
  padding: var(--space-6);
  transition: transform var(--dur-base) var(--ease-out),
              border-color var(--dur-base) var(--ease-out),
              box-shadow var(--dur-base) var(--ease-out);
}
.service-card:hover {
  transform: translateY(-4px);
  border-color: var(--c-teal-600);
  box-shadow: var(--shadow-card);
}
.service-icon {
  width: 52px;
  height: 52px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: var(--radius-sm);
  background: var(--c-teal-900);
  color: var(--c-teal-400);
  margin-bottom: var(--space-5);
}
.service-card h3 { margin-bottom: var(--space-3); }
.service-card p { font-size: 0.92rem; color: var(--c-text-muted); }

/* =========================================================
   Process list
   ========================================================= */
.process-list {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-6);
  counter-reset: step;
}
@media (min-width: 900px) { .process-list { grid-template-columns: repeat(4, 1fr); } }

.process-item {
  position: relative;
  padding-top: var(--space-6);
  border-top: 2px solid var(--c-border-strong);
}
.process-item::before {
  content: "";
  position: absolute;
  top: -2px; left: 0;
  width: 46px;
  height: 2px;
  background: var(--c-teal-400);
}
.process-num {
  display: block;
  font-family: var(--font-display);
  font-weight: 800;
  font-size: 1.6rem;
  color: var(--c-teal-400);
  margin-bottom: var(--space-3);
}
.process-item p { margin-top: var(--space-3); font-size: 0.92rem; color: var(--c-text-muted); }

/* =========================================================
   Why-us grid
   ========================================================= */
.why-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-5);
}
@media (min-width: 640px) { .why-grid { grid-template-columns: repeat(2, 1fr); } }

.why-card {
  padding: var(--space-6);
  border-radius: var(--radius-md);
  background: linear-gradient(160deg, var(--c-teal-900), transparent 60%), var(--c-bg-elev);
  border: 1px solid var(--c-border);
}
.why-card h3 { margin: var(--space-4) 0 var(--space-2); }
.why-card p { font-size: 0.92rem; color: var(--c-text-muted); }

/* =========================================================
   Kontakt
   ========================================================= */
.kontakt-grid {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-8);
}
@media (min-width: 960px) {
  .kontakt-grid { grid-template-columns: 0.9fr 1.1fr; align-items: start; }
}

.contact-list { margin-top: var(--space-7); display: flex; flex-direction: column; gap: var(--space-5); }
.contact-list li { display: flex; align-items: flex-start; gap: var(--space-4); }
.contact-label { display: block; font-size: 0.8rem; color: var(--c-text-muted); margin-bottom: 2px; }
.contact-value { font-weight: 600; color: var(--c-text-primary); }
.contact-value.placeholder {
  color: var(--c-text-muted);
  font-style: italic;
  font-weight: 500;
}
.contact-value.placeholder::after {
  content: attr(data-placeholder);
  display: block;
  font-style: normal;
  font-size: 0.72rem;
  color: var(--c-teal-400);
  margin-top: 2px;
}

.kontakt-form {
  background: var(--c-bg-elev-2);
  border: 1px solid var(--c-border);
  border-radius: var(--radius-lg);
  padding: var(--space-7);
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
}

.form-row {
  display: grid;
  grid-template-columns: 1fr;
  gap: var(--space-5);
}
@media (min-width: 560px) { .form-row { grid-template-columns: 1fr 1fr; } }

.field { display: flex; flex-direction: column; gap: var(--space-2); }
.field label { font-size: 0.85rem; font-weight: 600; color: var(--c-text-primary); }

.field input, .field select, .field textarea {
  background: var(--c-bg);
  border: 1px solid var(--c-border-strong);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  color: var(--c-text-primary);
  min-height: 44px;
  transition: border-color var(--dur-fast) var(--ease-out);
}
.field textarea { min-height: 120px; resize: vertical; }
.field input:focus, .field select:focus, .field textarea:focus {
  border-color: var(--c-teal-400);
  outline: none;
}
.field input:invalid:not(:placeholder-shown) { border-color: var(--c-danger); }

.form-status {
  font-size: 0.9rem;
  min-height: 1.2em;
}
.form-status.success { color: var(--c-success); }
.form-status.error { color: var(--c-danger); }

/* =========================================================
   Footer
   ========================================================= */
.site-footer { border-top: 1px solid var(--c-border); padding-block: var(--space-7); }
.footer-inner {
  display: flex;
  flex-direction: column;
  gap: var(--space-5);
  align-items: center;
  text-align: center;
}
.footer-nav { display: flex; flex-wrap: wrap; gap: var(--space-5); justify-content: center; font-size: 0.9rem; color: var(--c-text-muted); }
.footer-nav a:hover { color: var(--c-text-primary); }
.footer-copy { font-size: 0.82rem; color: var(--c-text-muted); }

@media (min-width: 760px) {
  .footer-inner { flex-direction: row; justify-content: space-between; text-align: left; }
}

.footer-bottom {
  margin-top: var(--space-6);
  padding-top: var(--space-6);
  border-top: 1px solid var(--c-border);
  display: flex;
  flex-direction: column;
  gap: var(--space-4);
  align-items: center;
  text-align: center;
}
.footer-legal { display: flex; flex-wrap: wrap; gap: var(--space-5); justify-content: center; font-size: 0.85rem; color: var(--c-text-muted); }
.footer-legal a:hover { color: var(--c-teal-300); }

@media (min-width: 760px) {
  .footer-bottom { flex-direction: row; justify-content: space-between; text-align: left; }
}

/* =========================================================
   Interior page hero (Marke / Kontakt / Legal pages)
   ========================================================= */
.page-hero {
  padding-block: var(--space-8) var(--space-7);
  position: relative;
  overflow: hidden;
}
.page-hero .container { position: relative; }
.page-hero h1 { max-width: 24ch; }
.page-hero-lead { margin-top: var(--space-4); max-width: 58ch; font-size: 1.05rem; color: var(--c-text-body); }

/* =========================================================
   Legal pages: disclaimer + prose
   ========================================================= */
.legal-notice {
  display: flex;
  gap: var(--space-4);
  align-items: flex-start;
  background: rgba(217, 164, 65, 0.08);
  border: 1px solid rgba(217, 164, 65, 0.35);
  border-radius: var(--radius-md);
  padding: var(--space-5);
  margin-bottom: var(--space-8);
  color: #E9C77E;
  font-size: 0.92rem;
  line-height: 1.6;
}
.legal-notice .icon { color: #E9C77E; margin-top: 2px; }
.legal-notice strong { color: #F3D89A; }

.legal-content {
  max-width: 74ch;
  padding-bottom: var(--space-9);
}
.legal-content h2 {
  font-size: 1.3rem;
  margin-top: var(--space-8);
  margin-bottom: var(--space-3);
}
.legal-content h2:first-child { margin-top: 0; }
.legal-content h3 {
  font-size: 1.05rem;
  margin-top: var(--space-6);
  margin-bottom: var(--space-2);
  color: var(--c-text-primary);
}
.legal-content p { margin-bottom: var(--space-4); color: var(--c-text-body); }
.legal-content ul { margin: 0 0 var(--space-4); padding-left: var(--space-5); list-style: disc; color: var(--c-text-body); }
.legal-content li { margin-bottom: var(--space-2); }
.legal-content a { color: var(--c-teal-300); text-decoration: underline; text-underline-offset: 2px; }
.legal-content a:hover { color: var(--c-teal-400); }

.fill {
  color: var(--c-teal-300);
  font-style: italic;
  border-bottom: 1px dashed var(--c-teal-600);
}

/* =========================================================
   CTA band
   ========================================================= */
.cta-band {
  border-radius: var(--radius-lg);
  padding: var(--space-8) var(--space-6);
  text-align: center;
  background: linear-gradient(160deg, var(--c-teal-900), var(--c-bg-elev) 70%);
  border: 1px solid var(--c-border);
}
.cta-band h2 { margin-bottom: var(--space-3); }
.cta-band p { max-width: 50ch; margin-inline: auto; color: var(--c-text-body); }
.cta-band .btn { margin-top: var(--space-6); }

/* =========================================================
   Logo mark: hero animation (Marke page)
   ========================================================= */
.logo-mark {
  position: relative;
  width: min(480px, 80vw);
  margin-inline: auto;
}
.logo-mark img { width: 100%; height: auto; display: block; }
.logo-mark::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(115deg, transparent 42%, rgba(255, 255, 255, 0.55) 50%, transparent 58%);
  background-size: 320% 100%;
  -webkit-mask-image: url("../assets/his-logo-solo.png");
  mask-image: url("../assets/his-logo-solo.png");
  -webkit-mask-size: contain;
  mask-size: contain;
  -webkit-mask-repeat: no-repeat;
  mask-repeat: no-repeat;
  -webkit-mask-position: center;
  mask-position: center;
}

@media (prefers-reduced-motion: no-preference) {
  .logo-mark {
    opacity: 0;
    transform: translateY(14px) scale(0.97);
    animation: logo-in 900ms var(--ease-out) forwards;
  }
  .logo-mark::after {
    animation: logo-shine 4.5s ease-in-out 1.1s infinite;
  }
}
@keyframes logo-in {
  to { opacity: 1; transform: none; }
}
@keyframes logo-shine {
  0%, 15% { background-position: 220% 0; }
  55%, 100% { background-position: -60% 0; }
}

/* =========================================================
   Scroll reveal
   ========================================================= */
.reveal {
  opacity: 0;
  transform: translateY(16px);
  transition: opacity var(--dur-slow) var(--ease-out), transform var(--dur-slow) var(--ease-out);
}
.reveal.is-visible { opacity: 1; transform: none; }
@media (prefers-reduced-motion: reduce) {
  .reveal { opacity: 1; transform: none; }
}
