/* VVx GmbH — corporate website
   Visual design v3 (modern/fresh: Sora + Inter, full-bleed animated
   energy-grid hero backgrounds, motion, pill buttons).
   Launched 2026-09-04. */

/* FONTS — self-hosted (SIL Open Font License, licences in assets/fonts/).
   Variable Latin subsets from the @fontsource-variable packages; no request
   ever leaves the site's own origin, so no Google Fonts / GDPR exposure. */
@font-face {
  font-family: 'Inter';
  src: url('../assets/fonts/inter-variable.woff2') format('woff2');
  font-weight: 100 900;
  font-display: swap;
}
@font-face {
  font-family: 'Sora';
  src: url('../assets/fonts/sora-variable.woff2') format('woff2');
  font-weight: 100 900;
  font-display: swap;
}

:root {
  --color-bg: #ffffff;
  --color-bg-alt: #f5f7fa;
  --color-bg-deep: #0a1f36;      /* deep navy — primary brand color */
  --color-navy-dark: #061426;
  --color-graphite: #2f3742;     /* graphite — secondary brand color */
  --color-text: #16202e;
  --color-text-muted: #5b6673;
  --color-on-dark: #eef2f6;
  --color-on-dark-muted: #cfdbe8;
  --color-accent: #3d6fd6;       /* cobalt — primary interactive accent */
  --color-steel: #4c86bf;
  --color-steel-light: #a9c6e8;
  --color-border: #e2e6eb;
  --max-width: 1180px;
  --font-body: 'Inter', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
  --font-heading: 'Sora', var(--font-body);
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: var(--font-body);
  color: var(--color-text);
  background: var(--color-bg);
  line-height: 1.65;
  -webkit-font-smoothing: antialiased;
}

.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 32px;
}

/* Skip link — lets keyboard/screen-reader users jump past the nav */
.skip-link {
  position: absolute;
  left: -9999px;
  top: 0;
  z-index: 100;
  background: var(--color-bg-deep);
  color: #ffffff;
  padding: 12px 20px;
  border-radius: 0 0 6px 0;
  font-weight: 600;
  font-size: 0.9rem;
  text-decoration: none;
}

.skip-link:focus {
  left: 0;
}

/* Visible keyboard focus for every interactive element */
a:focus-visible,
button:focus-visible {
  outline: 2px solid var(--color-accent);
  outline-offset: 3px;
  border-radius: 2px;
}

.hero a:focus-visible,
.photo-band a:focus-visible,
footer.site-footer a:focus-visible {
  outline-color: #a9c6e8;
}

header.site-header {
  background: var(--color-bg);
  border-bottom: 1px solid var(--color-border);
  padding: 22px 0;
  position: sticky;
  top: 0;
  z-index: 10;
}

.site-header .container {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 16px;
}

.site-logo {
  display: inline-flex;
  align-items: flex-end;
  gap: 8px;
  text-decoration: none;
}

.site-logo img {
  display: block;
  height: 44px;
  width: auto;
  border-radius: 3px;
}

.tagline-eyebrow {
  display: inline-flex;
  align-items: center;
  font-size: 0.76rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  font-weight: 700;
  color: var(--color-steel-light);
  margin: 0 0 26px;
  padding: 8px 16px;
  border: 1px solid rgba(169, 198, 232, 0.35);
  border-radius: 100px;
  opacity: 0;
  animation: rise .7s ease forwards;
  animation-delay: .05s;
}

.footer-tagline {
  display: block;
  font-size: 0.72rem;
  letter-spacing: 0.16em;
  text-transform: uppercase;
  color: #98a9bc; /* lightened from #8fa0b3 to clear WCAG AA (4.49 → 5.00) */
  margin-top: 4px;
}

nav.site-nav ul {
  list-style: none;
  display: flex;
  gap: 30px;
  margin: 0;
  padding: 0;
  flex-wrap: wrap;
}

nav.site-nav a {
  text-decoration: none;
  color: var(--color-graphite);
  font-size: 0.93rem;
  font-weight: 600;
  padding-bottom: 4px;
  border-bottom: 1px solid transparent;
}

nav.site-nav a:hover,
nav.site-nav a.active {
  color: var(--color-bg-deep);
  border-bottom-color: var(--color-accent);
}

main {
  min-height: 60vh;
}

/* ---- Hero: full-bleed animated "energy grid" background ---- */
.hero {
  position: relative;
  overflow: hidden;
  padding: 108px 0 92px;
  color: var(--color-on-dark);
  background: var(--color-navy-dark);
  text-align: left;
}

.hero.hero-alt { padding: 70px 0; }

.hero svg.hero-bg {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
}

.hero .hero-scrim {
  position: absolute;
  inset: 0;
  background: linear-gradient(100deg, rgba(6,20,38,0.94) 0%, rgba(6,20,38,0.78) 42%, rgba(6,20,38,0.4) 75%, rgba(6,20,38,0.18) 100%);
}

.hero .container { position: relative; z-index: 2; }

.hero h1 {
  font-family: var(--font-heading);
  font-size: 2.85rem;
  font-weight: 700;
  line-height: 1.12;
  letter-spacing: -0.015em;
  margin: 0 0 24px;
  color: #ffffff;
  max-width: 740px;
  opacity: 0;
  animation: rise .7s ease forwards;
  animation-delay: .2s;
}

.hero p.lead {
  font-size: 1.12rem;
  color: var(--color-on-dark-muted);
  max-width: 610px;
  margin: 0 0 32px;
  opacity: 0;
  animation: rise .7s ease forwards;
  animation-delay: .38s;
}

.hero .btn {
  opacity: 0;
  animation: rise .7s ease forwards;
  animation-delay: .54s;
}

@keyframes rise {
  from { opacity: 0; transform: translateY(16px); }
  to { opacity: 1; transform: translateY(0); }
}

.btn {
  display: inline-block;
  background: var(--color-accent);
  color: #ffffff;
  padding: 14px 30px;
  border-radius: 100px;
  text-decoration: none;
  font-weight: 700;
  font-size: 0.95rem;
  border: 1px solid var(--color-accent);
  transition: background 0.15s ease, transform 0.15s ease;
}

.btn:hover { background: #5583e0; transform: translateY(-1px); }

.btn.btn-outline {
  background: transparent;
  color: var(--color-bg-deep);
  border: 1.5px solid var(--color-bg-deep);
  padding: 12.5px 28.5px;
}

.btn.btn-outline:hover {
  background: var(--color-bg-deep);
  color: #fff;
  transform: translateY(-1px);
}

section {
  padding: 76px 0;
}

section.alt { background: var(--color-bg-alt); }

h2 {
  font-family: var(--font-heading);
  color: var(--color-bg-deep);
  font-size: 1.85rem;
  font-weight: 700;
  margin: 0 0 16px;
  text-align: center;
  letter-spacing: -0.01em;
}

.section-lead {
  text-align: center;
  color: var(--color-text-muted);
  max-width: 580px;
  margin: 0 auto 44px;
}

.cta { text-align: center; }
.cta p { max-width: 560px; margin: 0 auto 30px; color: var(--color-text-muted); }

.grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
  gap: 28px;
  margin-top: 40px;
}

.card {
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-top: 3px solid var(--color-accent);
  border-radius: 8px;
  padding: 26px;
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.card:hover {
  box-shadow: 0 10px 26px rgba(10, 31, 54, 0.1);
  transform: translateY(-3px);
}

.card h3 {
  margin-top: 0;
  font-family: var(--font-heading);
  color: var(--color-bg-deep);
  font-size: 1.1rem;
  font-weight: 700;
}

/* Pillar-style cards: centered, rounded gradient icon.
   Used for Velocity / Vantage / Exchange sections
   (Home "Why VVx GmbH" and About "Our Approach"). */
.grid.grid-pillar {
  text-align: center;
}

.card.card-pillar {
  background: transparent;
  border: none;
  border-radius: 0;
  padding: 8px 14px;
  text-align: center;
  transition: transform 0.25s ease;
}

.card.card-pillar:hover { transform: translateY(-3px); box-shadow: none; }

.card.card-pillar .pillar-label {
  font-size: 0.72rem;
  font-weight: 700;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--color-accent);
  margin: 0 0 16px;
}

.card.card-pillar .pillar-icon {
  width: 52px;
  height: 52px;
  border-radius: 16px;
  background: linear-gradient(135deg, var(--color-bg-deep) 0%, var(--color-accent) 100%);
  margin: 0 auto 20px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-family: var(--font-heading);
  color: #fff;
  font-weight: 700;
  font-size: 1rem;
  transition: transform 0.25s ease;
}

.card.card-pillar:hover .pillar-icon {
  transform: translateY(-4px) rotate(-4deg) scale(1.06);
}

.card.card-pillar h3 {
  font-size: 1.15rem;
}

.card.card-pillar p {
  font-size: 0.94rem;
  color: var(--color-text-muted);
  margin: 0;
}

/* ---- Full-bleed animated "photo" band (energy-grid motif) ---- */
.photo-band {
  position: relative;
  min-height: 300px;
  display: flex;
  align-items: center;
  overflow: hidden;
  color: #fff;
  padding: 0;
}

.photo-band svg.hero-bg { position: absolute; inset: 0; width: 100%; height: 100%; }
.photo-band .hero-scrim { position: absolute; inset: 0; background: linear-gradient(180deg, rgba(6,20,38,0.5) 0%, rgba(6,20,38,0.85) 100%); }
.photo-band .container { position: relative; z-index: 2; text-align: center; }
.photo-band .stat { font-family: var(--font-heading); font-size: 2.2rem; font-weight: 700; margin: 0 0 10px; }
.photo-band p { max-width: 560px; margin: 0 auto; color: var(--color-on-dark-muted); }

/* ---- Legal pages (privacy) ---- */
.legal { max-width: 780px; }
.legal h2 { text-align: left; font-size: 1.25rem; margin: 36px 0 10px; }
.legal p { margin: 0 0 14px; }

/* ---- Contact form ---- */
.contact-form { max-width: 720px; margin: 0 auto; }
.contact-form .form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; }
.contact-form .field { display: flex; flex-direction: column; margin-bottom: 18px; }
.contact-form label { font-weight: 600; font-size: 0.9rem; margin-bottom: 6px; color: var(--color-bg-deep); }
.contact-form label .opt { font-weight: 400; color: var(--color-text-muted); }
.contact-form input,
.contact-form textarea {
  font: inherit;
  color: var(--color-text);
  background: var(--color-bg);
  border: 1px solid var(--color-border);
  border-radius: 8px;
  padding: 12px 14px;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.contact-form textarea { min-height: 160px; resize: vertical; }
.contact-form input:focus,
.contact-form textarea:focus {
  outline: none;
  border-color: var(--color-accent);
  box-shadow: 0 0 0 3px rgba(61,111,214,0.18);
}
.contact-form .consent { display: flex; gap: 10px; align-items: flex-start; font-size: 0.88rem; color: var(--color-text-muted); margin: 4px 0 22px; }
.contact-form .consent input { margin-top: 4px; flex: none; }
.contact-form .btn { border: 0; cursor: pointer; font-family: inherit; }
.contact-form .hp { position: absolute; left: -9999px; width: 1px; height: 1px; overflow: hidden; }
.form-status { max-width: 720px; margin: 0 auto 26px; padding: 14px 18px; border-radius: 8px; font-size: 0.95rem; }
.form-status.ok { background: rgba(12,163,12,0.10); border: 1px solid #0ca30c; color: #0b5e0b; }
.form-status.err { background: rgba(208,59,59,0.08); border: 1px solid #d03b3b; color: #8a1f1f; }
.contact-cards .card p { margin: 0; }
.contact-cards .card p + p { margin-top: 6px; }

dl.impressum dt {
  font-weight: 700;
  font-family: var(--font-heading);
  margin-top: 22px;
  color: var(--color-bg-deep);
  font-size: 0.95rem;
}

dl.impressum dd {
  margin: 4px 0 0;
  color: var(--color-text);
}

footer.site-footer {
  background: var(--color-graphite);
  color: var(--color-on-dark-muted);
  padding: 36px 0;
  font-size: 0.85rem;
}

footer.site-footer .container {
  display: flex;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 12px;
}

footer.site-footer a {
  color: var(--color-on-dark-muted);
}

footer.site-footer a:hover { color: #fff; }

/* ---- Motion: flowing pipeline lines, pulsing nodes, drifting glow ---- */
.flow-line { stroke-dasharray: 10 8; animation: flow 5s linear infinite; }
.flow-line.slow { animation-duration: 9s; animation-direction: reverse; }
.flow-line.slower { animation-duration: 13s; }
@keyframes flow { to { stroke-dashoffset: -180; } }

.node-pulse { transform-box: fill-box; transform-origin: center; animation: pulse 2.6s ease-in-out infinite; }
.node-pulse:nth-child(2) { animation-delay: .4s; }
.node-pulse:nth-child(3) { animation-delay: .8s; }
.node-pulse:nth-child(4) { animation-delay: 1.2s; }
.node-pulse:nth-child(5) { animation-delay: 1.6s; }
.node-pulse:nth-child(6) { animation-delay: 2s; }
@keyframes pulse {
  0%, 100% { opacity: .55; transform: scale(1); }
  50% { opacity: 1; transform: scale(1.6); }
}

.glow-drift { animation: drift 14s ease-in-out infinite alternate; transform-origin: center; }
@keyframes drift {
  from { transform: translate(0,0) scale(1); }
  to { transform: translate(-40px, 20px) scale(1.08); }
}

/* Off-screen backgrounds get .is-paused from js/main.js */
svg.hero-bg.is-paused .flow-line,
svg.hero-bg.is-paused .node-pulse,
svg.hero-bg.is-paused .glow-drift { animation-play-state: paused; }

/* Scroll-reveal (see js/main.js) */
.reveal { opacity: 0; transform: translateY(24px); transition: opacity .6s ease, transform .6s ease; }
.reveal.in-view { opacity: 1; transform: translateY(0); }

@media (prefers-reduced-motion: reduce) {
  .flow-line, .node-pulse, .glow-drift, .tagline-eyebrow, .hero h1, .hero p.lead, .hero .btn {
    animation: none !important;
    opacity: 1 !important;
    transform: none !important;
  }
  .reveal { opacity: 1; transform: none; transition: none; }
}

/* ---- Mobile nav toggle (hamburger) ---- */
.nav-toggle {
  display: none;
  background: transparent;
  border: 1px solid var(--color-border);
  border-radius: 8px;
  width: 44px;
  height: 44px;
  padding: 0;
  cursor: pointer;
  align-items: center;
  justify-content: center;
  transition: border-color .15s ease;
}

.nav-toggle:hover { border-color: var(--color-accent); }

.nav-toggle-bars { position: relative; }

.nav-toggle-bars,
.nav-toggle-bars::before,
.nav-toggle-bars::after {
  display: block;
  width: 20px;
  height: 2px;
  background: var(--color-bg-deep);
  border-radius: 2px;
  transition: transform .25s ease, background .2s ease;
}

.nav-toggle-bars::before,
.nav-toggle-bars::after {
  content: "";
  position: absolute;
  left: 0;
}

.nav-toggle-bars::before { top: -6px; }
.nav-toggle-bars::after { top: 6px; }

.nav-toggle[aria-expanded="true"] .nav-toggle-bars { background: transparent; }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars::before { transform: translateY(6px) rotate(45deg); }
.nav-toggle[aria-expanded="true"] .nav-toggle-bars::after { transform: translateY(-6px) rotate(-45deg); }

@media (max-width: 860px) {
  .container { padding: 0 22px; }


  header.site-header { padding: 12px 0; }
  .site-logo img { height: 38px; }
  .site-header .container { flex-wrap: wrap; gap: 0; align-items: center; }

  .nav-toggle { display: inline-flex; }

  nav.site-nav {
    flex-basis: 100%;
    max-height: 0;
    overflow: hidden;
    transition: max-height .3s ease;
  }

  nav.site-nav.open { max-height: 340px; }

  nav.site-nav ul {
    flex-direction: column;
    gap: 0;
    margin-top: 10px;
  }

  nav.site-nav li { border-top: 1px solid var(--color-border); }

  nav.site-nav a {
    display: block;
    padding: 13px 2px;
    border-bottom: none;
  }

  nav.site-nav a:hover,
  nav.site-nav a.active {
    border-bottom: none;
    color: var(--color-accent);
  }

  .hero { padding: 72px 0 62px; }
  .hero.hero-alt { padding: 54px 0; }
  .hero h1 { font-size: 2.05rem; }
  .hero p.lead { font-size: 1.02rem; }

  section { padding: 56px 0; }
  h2 { font-size: 1.55rem; }

  .photo-band { min-height: 250px; }
  .photo-band .stat { font-size: 1.8rem; }

  footer.site-footer .container { flex-direction: column; }

  .contact-form .form-row { grid-template-columns: 1fr; gap: 0; }
}

@media (max-width: 420px) {
  .hero h1 { font-size: 1.8rem; }
  .tagline-eyebrow { font-size: 0.68rem; letter-spacing: 0.12em; padding: 7px 13px; }
}
