/* Frontpage Hero-Funnel: responsive layout guard.
   Mobile stays stacked up to 820px. Tablet/Desktop layouts start above that. */

.hero-funnel {
  min-height: 100svh;
  max-width: 100vw;
  overflow-x: clip;
  overflow-y: visible;
  background:
    radial-gradient(circle at 76% 30%, rgba(30,117,255,.24), transparent 34%),
    radial-gradient(circle at 5% 76%, rgba(45,157,255,.14), transparent 30%),
    linear-gradient(140deg, #02050c 0%, #06111f 54%, #020711 100%) !important;
}

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

.hero-funnel::before {
  content: '';
  position: absolute;
  inset: 0;
  z-index: -2;
  pointer-events: none;
  background: url('/assets/frontpage/pagivo-hero-glow-bg.svg') center / cover no-repeat;
  opacity: .58;
}

.hero-funnel::after,
.hero-funnel .particle-canvas,
.hero-funnel .energy-ribbon { display: none !important; }

.hero-funnel .hero-video-wrap { opacity: .14 !important; }

.hero-funnel .hero-video-overlay {
  background:
    linear-gradient(180deg, rgba(2,4,10,.78) 0%, rgba(2,4,10,.44) 42%, rgba(2,4,10,.9) 100%),
    linear-gradient(90deg, rgba(2,4,10,.76) 0%, rgba(2,4,10,.22) 54%, rgba(2,4,10,.48) 100%) !important;
}

html body .hero.hero-funnel .hero-funnel-shell {
  width: min(var(--max), calc(100vw - 32px)) !important;
  max-width: calc(100vw - 32px) !important;
  min-height: auto !important;
  display: grid !important;
  grid-template-columns: 1fr !important;
  grid-template-areas:
    'copy'
    'visual'
    'benefits' !important;
  align-items: start !important;
  gap: 18px !important;
  padding-top: 104px !important;
  padding-bottom: 34px !important;
}

html body .hero.hero-funnel .hero-funnel-copy,
html body .hero.hero-funnel .hero-visual,
html body .hero.hero-funnel .hero-benefit-grid { min-width: 0 !important; }

html body .hero.hero-funnel .hero-funnel-copy { grid-area: copy !important; }
html body .hero.hero-funnel .hero-visual { grid-area: visual !important; }
html body .hero.hero-funnel .hero-benefit-grid { grid-area: benefits !important; }

html body .hero.hero-funnel .hero-audience {
  display: inline-flex !important;
  margin: 0 0 15px !important;
  color: #f7c451 !important;
  font-size: clamp(.76rem, .86vw, .88rem) !important;
  font-weight: 800 !important;
  letter-spacing: .13em !important;
}

html body .hero.hero-funnel #hero-title {
  max-width: 730px !important;
  margin: 0 0 15px !important;
  color: #fff !important;
  font-size: clamp(2.4rem, 6.8vw, 4.02rem) !important;
  line-height: 1.02 !important;
  letter-spacing: -.055em !important;
  font-weight: 850 !important;
}

html body .hero.hero-funnel #hero-title::before { content: none !important; display: none !important; }
html body .hero.hero-funnel #hero-title > span { display: block !important; font: inherit !important; color: inherit !important; line-height: inherit !important; letter-spacing: inherit !important; }

html body .hero.hero-funnel .hero-lead {
  max-width: 570px !important;
  margin: 0 !important;
  color: rgba(255,255,255,.82) !important;
  font-size: clamp(1rem, 1.18vw, 1.12rem) !important;
  line-height: 1.46 !important;
}

.hero-proof-points,
.hero-check-trust {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 17px;
  margin: 14px 0 0;
  padding: 0;
  list-style: none;
  color: rgba(255,255,255,.78);
}

.hero-proof-points li,
.hero-check-trust li { display: inline-flex; align-items: center; gap: 7px; }
.hero-proof-points li::before,
.hero-check-trust li::before { content: '✓'; color: #f7c451; font-weight: 900; }

html body .hero.hero-funnel .hero-funnel-actions { display: flex !important; flex-wrap: wrap; gap: 12px !important; margin: 18px 0 0 !important; }
html body .hero.hero-funnel .hero-funnel-actions .btn { min-height: 52px !important; border-radius: 14px !important; padding: 0 19px !important; font-size: .96rem !important; }

html body .hero.hero-funnel .hero-blue-cta {
  color: #eef6ff !important;
  border: 1px solid rgba(104,174,255,.62) !important;
  background:
    linear-gradient(180deg, rgba(255,255,255,.16), rgba(255,255,255,0) 42%),
    linear-gradient(135deg, #1e74ff 0%, #0e4fd2 58%, #092b86 100%) !important;
  box-shadow: 0 0 0 1px rgba(255,255,255,.12) inset, 0 0 42px rgba(30,117,255,.34), 0 18px 46px rgba(0,0,0,.28) !important;
}

html body .hero.hero-funnel .hero-contact-cta { color: rgba(255,255,255,.86) !important; border: 1px solid rgba(255,255,255,.16) !important; background: rgba(255,255,255,.045) !important; }

html body .hero.hero-funnel .hero-score-form {
  width: min(100%, 560px) !important;
  margin-top: 14px !important;
  padding: 12px !important;
  display: grid !important;
  gap: 10px !important;
  border: 1px solid rgba(255,255,255,.15) !important;
  border-radius: 22px !important;
  background:
    radial-gradient(circle at 18% 0%, rgba(113,183,255,.16), transparent 38%),
    radial-gradient(circle at 78% 100%, rgba(244,210,173,.11), transparent 34%),
    linear-gradient(180deg, rgba(13,24,46,.68), rgba(5,9,20,.54)) !important;
  box-shadow: 0 20px 54px rgba(0,0,0,.28), inset 0 1px 0 rgba(255,255,255,.08) !important;
  backdrop-filter: blur(18px) !important;
}

html body .hero.hero-funnel .hero-score-fields { display: grid !important; grid-template-columns: minmax(0, 1.08fr) minmax(0, .92fr) !important; gap: 9px !important; }
html body .hero.hero-funnel .hero-score-field { display: grid !important; gap: 6px !important; color: rgba(255,255,255,.9) !important; font-size: .9rem !important; font-weight: 800 !important; }

html body .hero.hero-funnel .hero-score-field input,
html body .hero.hero-funnel .hero-score-field select {
  width: 100% !important;
  min-height: 48px !important;
  border: 1px solid rgba(255,255,255,.18) !important;
  border-radius: 15px !important;
  background: linear-gradient(180deg, rgba(255,255,255,.11), rgba(255,255,255,.045)), rgba(1,5,14,.32) !important;
  color: #fff !important;
  padding: 0 15px !important;
}

html body .hero.hero-funnel .hero-score-field option { color: #07111f !important; }
html body .hero.hero-funnel .hero-score-field input::placeholder { color: rgba(255,255,255,.42) !important; }
html body .hero.hero-funnel .hero-score-submit { width: 100% !important; min-height: 54px !important; border-radius: 999px !important; font-size: clamp(.96rem, 1.1vw, 1.04rem) !important; white-space: nowrap !important; }
.hero-check-trust { justify-content: center; margin-top: -1px; font-size: .8rem; }

.hero-visual { width: min(100%, 805px); max-width: 100%; min-width: 0; margin: 0 auto; }
.hero-visual-image {
  content: url('/assets/frontnew/moderne_dachdecker_website_auf_geraeten_transparent.png');
  width: 100%;
  max-width: 100%;
  height: auto;
  filter: brightness(1.06) contrast(1.04) saturate(1.02) drop-shadow(0 32px 62px rgba(0,0,0,.34));
}

.hero-visual-caption {
  width: min(92%, 520px);
  margin: -32px auto 0;
  padding: 12px 15px;
  display: grid;
  gap: 2px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 18px;
  color: rgba(255,255,255,.76);
  background: linear-gradient(180deg, rgba(7,15,30,.82), rgba(5,9,20,.72));
  text-align: center;
}

.hero-visual-caption span { color: #f7c451; font-size: .7rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; }
.hero-visual-caption strong { color: #fff; font-size: .95rem; line-height: 1.22; }

.hero-benefit-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; min-width: 0; width: 100%; }

.hero-benefit-card {
  min-width: 0;
  min-height: 88px;
  display: grid;
  grid-template-columns: 56px minmax(0, 1fr);
  grid-template-areas: 'icon title' 'icon text';
  align-content: center;
  column-gap: 14px;
  padding: 15px 18px;
  border: 1px solid rgba(255,255,255,.12);
  border-radius: 20px;
  background: linear-gradient(180deg, rgba(255,255,255,.07), rgba(255,255,255,.035)), rgba(4,11,23,.72);
}

.hero-benefit-icon {
  grid-area: icon;
  width: 52px;
  height: 52px;
  position: relative;
  display: block;
  align-self: center;
  isolation: isolate;
  border-radius: 0;
  color: transparent !important;
  font-size: 0 !important;
  background: none !important;
  box-shadow: none;
}

.hero-benefit-icon::before {
  content: '';
  position: absolute;
  left: 50%;
  top: 50%;
  width: calc(100% + 20px);
  height: calc(100% + 20px);
  border-radius: 999px;
  transform: translate(-50%, -50%);
  background: radial-gradient(circle, rgba(30,117,255,.34) 0%, rgba(30,117,255,.18) 34%, rgba(30,117,255,0) 72%);
  pointer-events: none;
  z-index: 0;
}

.hero-benefit-icon::after {
  content: '';
  position: absolute;
  inset: 0;
  z-index: 1;
  background: transparent center / contain no-repeat;
}

.hero-benefit-card:nth-child(1) .hero-benefit-icon::after { background-image: url('/assets/frontnew/neon_monitor_mit_goldenen_funken_transparent.png'); }
.hero-benefit-card:nth-child(2) .hero-benefit-icon::after { background-image: url('/assets/frontnew/neon_netzwerkdiagramm_mit_goldenen_knoten_transparent.png'); }
.hero-benefit-card:nth-child(3) .hero-benefit-icon::after { background-image: url('/assets/frontnew/neon_wachstumsdiagramm_mit_goldenen_akzenten_transparent.png'); }

html body .hero-benefit-card h2 { grid-area: title; margin: 0 0 3px !important; color: #fff !important; font-size: 1rem !important; line-height: 1.12 !important; letter-spacing: -.03em !important; font-weight: 800 !important; }
.hero-benefit-card p { grid-area: text; margin: 0; color: rgba(255,255,255,.72); font-size: .86rem; line-height: 1.3; }

html body .live-demo-card { background-image: linear-gradient(180deg, rgba(5,10,22,.12), rgba(5,10,22,.18)), url('/assets/frontpage/pagivo-before-after-preview.svg'); background-position: center; background-size: cover; }
html body .live-demo-card .live-demo-preview { opacity: .08; }

@media (min-width: 1180px) {
  html body .site-header {
    top: clamp(16px, 2.2vw, 24px) !important;
    width: min(1360px, calc(100vw - 72px)) !important;
    max-width: calc(100vw - 72px) !important;
  }

  html body .hero.hero-funnel .hero-funnel-shell {
    width: min(1360px, calc(100vw - 72px)) !important;
    max-width: calc(100vw - 72px) !important;
    min-height: min(755px, 100svh) !important;
    grid-template-columns: minmax(0, .92fr) minmax(0, 1.08fr) !important;
    grid-template-areas: 'copy visual' 'benefits benefits' !important;
    align-items: center !important;
    column-gap: clamp(34px, 4.5vw, 76px) !important;
    row-gap: clamp(12px, 2vh, 22px) !important;
    padding-top: clamp(132px, 13vh, 152px) !important;
    padding-bottom: clamp(24px, 3.3vh, 34px) !important;
  }
  html body .hero.hero-funnel .hero-funnel-copy { max-width: 690px !important; }
  html body .hero.hero-funnel .hero-visual { justify-self: end !important; margin: 0 !important; }
}

@media (min-width: 821px) and (max-width: 1179px) {
  html body .hero-funnel { min-height: auto !important; overflow-y: visible !important; }

  html body .site-header {
    top: 18px !important;
    width: min(1060px, calc(100vw - 40px)) !important;
    max-width: calc(100vw - 40px) !important;
    display: flex !important;
    align-items: center !important;
    justify-content: space-between !important;
    gap: 16px !important;
  }

  html body .site-header .brand-video-link { width: clamp(112px, 18vw, 160px) !important; height: clamp(30px, 5vw, 44px) !important; }
  html body .nav-toggle { display: grid !important; place-items: center !important; flex: 0 0 auto !important; }

  html body .main-nav {
    position: absolute !important;
    top: calc(100% + 10px) !important;
    right: 0 !important;
    width: min(320px, calc(100vw - 40px)) !important;
    display: grid !important;
    grid-template-columns: 1fr !important;
    gap: 4px !important;
    padding: 10px !important;
    border-radius: 22px !important;
    background: rgba(5,9,20,.94) !important;
    border: 1px solid rgba(255,255,255,.1) !important;
    box-shadow: 0 24px 58px rgba(0,0,0,.42), inset 0 1px 0 rgba(255,255,255,.08) !important;
    opacity: 0 !important;
    visibility: hidden !important;
    pointer-events: none !important;
    transform: translateY(-6px) !important;
    transition: opacity .16s ease, transform .16s ease, visibility .16s ease !important;
  }

  html body .main-nav.is-open { opacity: 1 !important; visibility: visible !important; pointer-events: auto !important; transform: translateY(0) !important; }
  html body .main-nav a { display: block !important; width: 100% !important; padding: 11px 13px !important; border-radius: 14px !important; font-size: .9rem !important; text-align: left !important; }

  html body .hero.hero-funnel .hero-funnel-shell {
    width: min(1060px, calc(100vw - 40px)) !important;
    max-width: calc(100vw - 40px) !important;
    grid-template-columns: minmax(0, .95fr) minmax(220px, .82fr) !important;
    grid-template-areas: 'copy visual' 'benefits benefits' !important;
    align-items: center !important;
    gap: 18px 20px !important;
    padding-top: clamp(92px, 12vh, 118px) !important;
    padding-bottom: 34px !important;
  }

  html body .hero.hero-funnel .hero-funnel-copy { max-width: 100% !important; }
  html body .hero.hero-funnel .hero-visual { width: min(100%, 410px) !important; justify-self: end !important; margin: 0 !important; }

  html body .hero.hero-funnel #hero-title { font-size: clamp(1.9rem, 5vw, 3.25rem) !important; line-height: 1.02 !important; }
  html body .hero.hero-funnel .hero-lead { font-size: clamp(.82rem, 2.1vw, 1rem) !important; line-height: 1.38 !important; }
  html body .hero.hero-funnel .hero-audience { font-size: clamp(.62rem, 1.55vw, .78rem) !important; margin-bottom: 10px !important; }
  html body .hero.hero-funnel .hero-proof-points { font-size: clamp(.72rem, 1.7vw, .88rem) !important; gap: 6px 12px !important; margin-top: 10px !important; }

  html body .hero.hero-funnel .hero-funnel-actions { margin-top: 14px !important; }
  html body .hero.hero-funnel .hero-funnel-actions .btn { min-height: 42px !important; font-size: clamp(.7rem, 1.7vw, .9rem) !important; padding-inline: 14px !important; }
  html body .hero.hero-funnel .hero-contact-cta { display: none !important; }

  html body .hero.hero-funnel .hero-score-form { width: 100% !important; margin-top: 12px !important; padding: 10px !important; border-radius: 18px !important; gap: 9px !important; }
  html body .hero.hero-funnel .hero-score-fields { grid-template-columns: 1fr !important; gap: 7px !important; }
  html body .hero.hero-funnel .hero-score-field { font-size: clamp(.68rem, 1.6vw, .82rem) !important; gap: 5px !important; }
  html body .hero.hero-funnel .hero-score-field input,
  html body .hero.hero-funnel .hero-score-field select { min-height: 38px !important; border-radius: 12px !important; font-size: clamp(.72rem, 1.8vw, .86rem) !important; }
  html body .hero.hero-funnel .hero-score-submit { min-height: 42px !important; font-size: clamp(.74rem, 1.8vw, .9rem) !important; }
  html body .hero.hero-funnel .hero-check-trust { font-size: clamp(.62rem, 1.5vw, .76rem) !important; gap: 5px 10px !important; }

  html body .hero.hero-funnel .hero-visual-caption { margin-top: -20px !important; padding: 10px 12px !important; }
  html body .hero.hero-funnel .hero-visual-caption span { font-size: clamp(.52rem, 1.25vw, .66rem) !important; }
  html body .hero.hero-funnel .hero-visual-caption strong { font-size: clamp(.72rem, 1.55vw, .9rem) !important; }

  html body .hero.hero-funnel .hero-benefit-grid { grid-template-columns: repeat(3, minmax(0, 1fr)) !important; gap: 10px !important; }
  html body .hero.hero-funnel .hero-benefit-card { min-height: 72px !important; padding: 11px 12px !important; grid-template-columns: 40px minmax(0, 1fr) !important; column-gap: 10px !important; }
  html body .hero.hero-funnel .hero-benefit-icon { width: 36px !important; height: 36px !important; }
  html body .hero-benefit-card h2 { font-size: clamp(.72rem, 1.7vw, .9rem) !important; }
  html body .hero-benefit-card p { font-size: clamp(.62rem, 1.45vw, .78rem) !important; line-height: 1.25 !important; }
}

@media (max-width: 820px) {
  html body .hero-funnel { min-height: auto !important; overflow-y: visible !important; }

  html body .hero.hero-funnel::after {
    content: '';
    position: absolute;
    display: block !important;
    z-index: -1;
    left: 0;
    top: 0;
    width: min(78vw, 340px);
    height: 178px;
    pointer-events: none;
    background:
      radial-gradient(circle at 18% 20%, rgba(0,0,0,.98) 0%, rgba(0,0,0,.86) 40%, rgba(0,0,0,0) 76%),
      linear-gradient(135deg, #02040a 0%, #02040a 38%, rgba(2,4,10,.7) 62%, rgba(2,4,10,0) 100%);
  }

  html body .site-header .brand-logo-video { display: block !important; }
  html body .site-header .brand-video-link.is-video-ready .brand-logo-video { opacity: 1 !important; }
  html body .site-header .brand-video-link.is-video-ready .brand-logo-fallback { opacity: 0 !important; }

  html body .site-header .brand-logo-video-shell {
    overflow: hidden !important;
    background: #02040a !important;
    border-radius: 6px !important;
  }

  html body .site-header .brand-video-link {
    width: clamp(132px, 42vw, 205px) !important;
    height: clamp(36px, 10.5vw, 52px) !important;
    background: transparent !important;
    box-shadow: none !important;
  }

  html body .hero.hero-funnel .hero-funnel-shell {
    width: min(100% - 22px, var(--max)) !important;
    max-width: calc(100vw - 22px) !important;
    grid-template-columns: 1fr !important;
    grid-template-areas:
      'copy'
      'visual'
      'benefits' !important;
    align-items: start !important;
    padding-top: 96px !important;
  }

  html body .hero.hero-funnel .hero-funnel-copy,
  html body .hero.hero-funnel .hero-visual,
  html body .hero.hero-funnel .hero-benefit-grid {
    grid-area: auto;
    justify-self: stretch !important;
  }

  html body .hero.hero-funnel .hero-funnel-copy { grid-area: copy !important; }
  html body .hero.hero-funnel .hero-visual { grid-area: visual !important; width: min(100%, 590px) !important; margin: 8px auto 0 !important; }
  html body .hero.hero-funnel .hero-benefit-grid { grid-area: benefits !important; }

  html body .hero.hero-funnel #hero-title { font-size: clamp(2rem, 10vw, 2.92rem) !important; }
  html body .hero.hero-funnel .hero-funnel-actions .btn,
  html body .hero.hero-funnel .hero-score-submit { width: 100% !important; }
  html body .hero.hero-funnel .hero-contact-cta { display: none !important; }
  html body .hero.hero-funnel .hero-score-fields { grid-template-columns: 1fr !important; }

  html body .hero.hero-funnel .hero-check-trust {
    width: 100% !important;
    display: grid !important;
    grid-template-columns: repeat(3, minmax(0, 1fr)) !important;
    justify-content: stretch !important;
    justify-items: center !important;
    gap: 6px !important;
    font-size: clamp(.58rem, 2.45vw, .74rem) !important;
  }

  html body .hero.hero-funnel .hero-check-trust li {
    justify-content: center !important;
    gap: 4px !important;
    white-space: nowrap !important;
    min-width: 0 !important;
  }

  html body .hero.hero-funnel .hero-visual-caption {
    width: calc(100% - 32px) !important;
    margin: 6px auto 0 !important;
    padding: 10px 12px !important;
    border-radius: 16px !important;
  }
  html body .hero.hero-funnel .hero-visual-caption span { font-size: clamp(.56rem, 2.5vw, .66rem) !important; letter-spacing: .1em !important; }
  html body .hero.hero-funnel .hero-visual-caption strong { font-size: clamp(.96rem, 4.2vw, 1.08rem) !important; line-height: 1.18 !important; }

  html body .hero.hero-funnel .hero-benefit-grid { grid-template-columns: 1fr !important; gap: 10px !important; }
  html body .hero.hero-funnel .hero-benefit-card { min-height: 88px !important; padding: 16px 18px !important; }
  html body .hero.hero-funnel .hero-benefit-icon { width: 48px !important; height: 48px !important; }
}
