﻿/* ==========================================================================
   Hero v2 â modern homepage hero (scoped to .hero-v2, loaded after
   responsive.css so it overrides the legacy hero rules in sections.css)
   ========================================================================== */

.hero-v2 {
  --hv2-yellow: #ffc700;
  --hv2-yellow-2: #ffdd3c;
  --hv2-yellow-deep: #f5a300;
  --hv2-ink: #1a1400;
  --hv2-accent: var(--color-blue);
  padding-top: calc(var(--navbar-height) + 4rem);
  padding-bottom: 4rem;
  isolation: isolate;
}
[data-theme="dark"] .hero-v2 {
  --hv2-accent: #7ea0ff;
}

/* ---- Background: dotted grid + soft orbs ---- */
.hv2-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  overflow: hidden;
}
.hv2-grid {
  position: absolute;
  inset: 0;
  background-image:
    linear-gradient(to right, color-mix(in srgb, var(--text-primary) 6%, transparent) 1px, transparent 1px),
    linear-gradient(to bottom, color-mix(in srgb, var(--text-primary) 6%, transparent) 1px, transparent 1px);
  background-size: 56px 56px;
  -webkit-mask-image: radial-gradient(ellipse 80% 65% at 50% 35%, #000 30%, transparent 75%);
  mask-image: radial-gradient(ellipse 80% 65% at 50% 35%, #000 30%, transparent 75%);
}
.hv2-orb {
  position: absolute;
  border-radius: 50%;
  filter: blur(90px);
  opacity: 0.5;
  animation: hv2-drift 18s ease-in-out infinite alternate;
}
.hv2-orb-a {
  width: 520px; height: 520px;
  top: -160px; left: -140px;
  background: color-mix(in srgb, var(--color-blue) 55%, transparent);
}
.hv2-orb-b {
  width: 460px; height: 460px;
  top: 10%; right: -160px;
  background: color-mix(in srgb, var(--color-purple) 45%, transparent);
  animation-delay: -6s;
}
.hv2-orb-c {
  width: 340px; height: 340px;
  bottom: -80px; left: 38%;
  background: color-mix(in srgb, var(--hv2-yellow) 40%, transparent);
  animation-delay: -12s;
}
[data-theme="dark"] .hv2-orb { opacity: 0.35; }
@keyframes hv2-drift {
  0%   { transform: translate(0, 0) scale(1); }
  100% { transform: translate(40px, 30px) scale(1.08); }
}

/* ---- Eyebrow pill ---- */
.hv2-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.65rem;
  padding: 0.35rem 0.9rem 0.35rem 0.35rem;
  border-radius: var(--radius-pill);
  background: var(--bg-glass-strong);
  border: 1px solid var(--border-glass);
  box-shadow: 0 6px 20px -10px rgba(15, 23, 42, 0.25);
  backdrop-filter: blur(12px);
  font-size: 0.84rem;
  font-weight: 600;
  color: var(--text-secondary);
  margin-bottom: 1.6rem;
  max-width: 100%;
}
.hv2-eyebrow-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.25rem 0.7rem;
  border-radius: var(--radius-pill);
  background: linear-gradient(135deg, var(--hv2-yellow-2), var(--hv2-yellow));
  color: var(--hv2-ink);
  font-size: 0.72rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  flex-shrink: 0;
}
.hv2-eyebrow-text {
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.hv2-eyebrow-arrow {
  font-size: 0.65rem;
  color: var(--text-muted);
}

/* ---- Title ---- */
.hv2-title {
  font-weight: 800;
  letter-spacing: -0.035em;
  line-height: 1.04;
  margin-bottom: 1.4rem;
}
/* Reserve stable space for the rotating word so different word lengths never
   reflow the content below (same reason as the legacy rule in sections.css). */
.hero-v2 .hv2-typing-wrap {
  display: block;
  min-height: 2.15em;
}
.hero-v2 .hero-title .typing-text {
  display: inline;
  min-height: 0;
  color: var(--hv2-accent);
  background-image: linear-gradient(
    transparent 64%,
    color-mix(in srgb, var(--hv2-yellow) 55%, transparent) 64%,
    color-mix(in srgb, var(--hv2-yellow) 55%, transparent) 90%,
    transparent 90%
  );
  -webkit-box-decoration-break: clone;
  box-decoration-break: clone;
  padding: 0 0.08em;
}
.hero-v2 .typing-text::after {
  color: var(--hv2-yellow-deep);
}

.hv2-lead {
  font-size: var(--fs-lead);
  line-height: 1.65;
  color: var(--text-secondary);
  max-width: 540px;
  margin-bottom: 0;
}

/* ---- CTAs ---- */
.hv2-cta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-top: 2rem;
}
.hv2-btn-primary,
.hv2-btn-ghost {
  position: relative;
  overflow: hidden;
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  border-radius: var(--radius-pill);
  font-weight: 700;
  font-size: 1rem;
  transition: transform var(--transition-fast), box-shadow var(--transition-fast), background var(--transition-fast), border-color var(--transition-fast);
}
.hv2-btn-primary {
  padding: 0.5rem 0.5rem 0.5rem 1.6rem;
  background: linear-gradient(135deg, var(--hv2-yellow-2) 0%, var(--hv2-yellow) 55%, var(--hv2-yellow-deep) 100%);
  color: var(--hv2-ink) !important;
  border: 0;
  box-shadow: 0 14px 30px -10px rgba(245, 163, 0, 0.6), inset 0 1px 0 rgba(255, 255, 255, 0.6);
}
.hv2-btn-primary::before {
  content: "";
  position: absolute;
  top: 0; left: -60%;
  width: 40%; height: 100%;
  background: linear-gradient(110deg, transparent, rgba(255, 255, 255, 0.65), transparent);
  transform: skewX(-20deg);
  animation: hv2-shine 3.2s ease-in-out infinite;
}
.hv2-btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 20px 40px -12px rgba(245, 163, 0, 0.75), inset 0 1px 0 rgba(255, 255, 255, 0.6);
}
.hv2-btn-icon {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--hv2-ink);
  color: var(--hv2-yellow);
  font-size: 0.9rem;
  transition: transform var(--transition-fast);
}
.hv2-btn-primary:hover .hv2-btn-icon {
  transform: translateX(3px) rotate(-30deg);
}
.hv2-btn-ghost {
  padding: 0.5rem 1.4rem 0.5rem 0.5rem;
  background: var(--bg-glass-strong);
  color: var(--text-primary) !important;
  border: 1px solid var(--border-color);
  backdrop-filter: blur(12px);
}
.hv2-btn-ghost:hover {
  transform: translateY(-3px);
  border-color: var(--hv2-accent);
  box-shadow: 0 14px 30px -14px rgba(47, 91, 255, 0.45);
}
.hv2-play {
  width: 38px;
  height: 38px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  background: var(--gradient-primary);
  color: #fff;
  font-size: 0.75rem;
  padding-left: 2px;
  box-shadow: 0 0 0 0 rgba(47, 91, 255, 0.45);
  animation: hv2-pulse 2.2s infinite;
}
@keyframes hv2-shine {
  0%, 60% { left: -60%; }
  100%    { left: 130%; }
}
@keyframes hv2-pulse {
  0%   { box-shadow: 0 0 0 0 rgba(47, 91, 255, 0.45); }
  70%  { box-shadow: 0 0 0 12px rgba(47, 91, 255, 0); }
  100% { box-shadow: 0 0 0 0 rgba(47, 91, 255, 0); }
}

/* ---- Trust checks ---- */
.hv2-checks {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem 1.4rem;
  list-style: none;
  padding: 0;
  margin: 1.4rem 0 0;
  font-size: 0.86rem;
  font-weight: 500;
  color: var(--text-secondary);
}
.hv2-checks i {
  color: var(--color-success);
  margin-right: 0.3rem;
}

/* ---- QR Menu highlight card ---- */
.hv2-qr {
  position: relative;
  display: flex;
  align-items: center;
  gap: 0.9rem;
  max-width: 540px;
  margin-top: 1.4rem;
  padding: 0.6rem 1rem 0.6rem 0.6rem;
  border-radius: 18px;
  text-decoration: none;
  color: var(--text-primary);
  background:
    linear-gradient(var(--bg-glass-strong), var(--bg-glass-strong)) padding-box,
    linear-gradient(120deg, var(--hv2-yellow), color-mix(in srgb, var(--hv2-yellow) 15%, transparent) 40%, color-mix(in srgb, var(--color-blue) 20%, transparent) 70%, var(--color-blue)) border-box;
  border: 1.5px solid transparent;
  backdrop-filter: blur(12px);
  box-shadow: 0 14px 34px -18px rgba(245, 163, 0, 0.55);
  transition: transform var(--transition-fast), box-shadow var(--transition-fast);
}
.hv2-qr:hover {
  color: var(--text-primary);
  transform: translateY(-3px);
  box-shadow: 0 20px 40px -18px rgba(245, 163, 0, 0.75);
}
.hv2-qr-code {
  position: relative;
  flex-shrink: 0;
  width: 52px;
  height: 52px;
  border-radius: 14px;
  display: grid;
  place-items: center;
  overflow: hidden;
  background: #14110a;
  color: var(--hv2-yellow);
  font-size: 1.75rem;
  box-shadow: inset 0 0 0 1px rgba(255, 199, 0, 0.25);
}
/* Scanner line sweeping over the code */
.hv2-qr-scan {
  position: absolute;
  left: 6px;
  right: 6px;
  height: 2px;
  top: 8px;
  border-radius: 2px;
  background: #ffe066;
  box-shadow: 0 0 10px 3px rgba(255, 199, 0, 0.7);
  animation: hv2-scan 2s ease-in-out infinite alternate;
}
@keyframes hv2-scan {
  to { top: calc(100% - 10px); }
}
.hv2-qr-body {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  min-width: 0;
  flex: 1;
  text-align: left;
}
.hv2-qr-title {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-family: var(--font-heading);
  font-weight: 700;
  font-size: 0.98rem;
  line-height: 1.2;
}
.hv2-qr-tag {
  padding: 0.18rem 0.55rem;
  border-radius: var(--radius-pill);
  background: linear-gradient(135deg, var(--hv2-yellow-2), var(--hv2-yellow));
  color: var(--hv2-ink);
  font-size: 0.68rem;
  font-weight: 800;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  white-space: nowrap;
}
.hv2-qr-sub {
  font-size: 0.78rem;
  color: var(--text-muted);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.hv2-qr-sub i {
  font-size: 0.55rem;
  margin: 0 0.15rem;
  color: var(--hv2-yellow-deep);
  vertical-align: middle;
}
/* Overlapping outlet-type avatars */
.hv2-qr-outlets {
  display: flex;
  flex-shrink: 0;
}
.hv2-qr-outlets span {
  width: 30px;
  height: 30px;
  border-radius: 50%;
  display: grid;
  place-items: center;
  margin-left: -8px;
  font-size: 0.72rem;
  color: #fff;
  border: 2px solid var(--bg-surface);
  transition: transform var(--transition-fast);
}
.hv2-qr-outlets span:nth-child(1) { background: #ff6b3d; margin-left: 0; }
.hv2-qr-outlets span:nth-child(2) { background: #8b5cf6; }
.hv2-qr-outlets span:nth-child(3) { background: #ec4899; }
.hv2-qr-outlets span:nth-child(4) { background: #06b6d4; }
.hv2-qr:hover .hv2-qr-outlets span { transform: translateY(-3px); }
.hv2-qr:hover .hv2-qr-outlets span:nth-child(2) { transition-delay: 0.04s; }
.hv2-qr:hover .hv2-qr-outlets span:nth-child(3) { transition-delay: 0.08s; }
.hv2-qr:hover .hv2-qr-outlets span:nth-child(4) { transition-delay: 0.12s; }
.hv2-qr-go {
  flex-shrink: 0;
  font-size: 0.75rem;
  color: var(--text-muted);
  transition: transform var(--transition-fast), color var(--transition-fast);
}
.hv2-qr:hover .hv2-qr-go {
  color: var(--hv2-yellow-deep);
  transform: translateX(3px);
}

.hero-v2 .hv2-ticker {
  margin-top: 1.5rem;
}

/* ---- Stats ---- */
.hv2-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 0.75rem;
  margin-top: 2rem;
  max-width: 540px;
}
.hv2-stat {
  padding: 0.9rem 1rem;
  border-radius: var(--radius-md);
  background: var(--bg-glass-strong);
  border: 1px solid var(--border-glass);
  backdrop-filter: blur(12px);
  box-shadow: var(--card-shadow);
}
.hv2-stat strong {
  display: block;
  font-family: var(--font-heading);
  font-size: 1.6rem;
  font-weight: 800;
  line-height: 1.1;
  color: var(--text-primary);
}
.hv2-stat span:not(.counter-value) {
  display: block;
  font-size: 0.78rem;
  color: var(--text-muted);
  margin-top: 0.15rem;
}

/* ---- Visual ---- */
.hv2-visual {
  padding: 1.5rem 0;
}
.hv2-ring {
  position: absolute;
  top: 50%;
  left: 50%;
  border-radius: 50%;
  border: 1px dashed color-mix(in srgb, var(--hv2-accent) 35%, transparent);
  transform: translate(-50%, -50%);
  pointer-events: none;
  z-index: 0;
  animation: hv2-spin 60s linear infinite;
}
.hv2-ring-1 { width: 115%; aspect-ratio: 1; }
.hv2-ring-2 {
  width: 85%;
  aspect-ratio: 1;
  border-style: solid;
  border-color: color-mix(in srgb, var(--hv2-yellow) 35%, transparent);
  animation-direction: reverse;
  animation-duration: 45s;
}
@keyframes hv2-spin {
  to { transform: translate(-50%, -50%) rotate(360deg); }
}
.hv2-mock {
  z-index: 2;
  border-radius: 20px;
  padding: 6px;
  background:
    linear-gradient(var(--bg-surface), var(--bg-surface)) padding-box,
    linear-gradient(135deg, var(--hv2-yellow), var(--color-blue) 45%, var(--color-purple)) border-box;
  border: 1.5px solid transparent;
  box-shadow: 0 50px 100px -35px rgba(15, 23, 42, 0.45), 0 0 0 8px color-mix(in srgb, var(--bg-surface) 60%, transparent);
}
.hv2-mock .mock-topbar {
  align-items: center;
  border-radius: 14px 14px 0 0;
}
.hv2-mock img {
  border-radius: 0 0 14px 14px;
}
.hv2-mock .mock-topbar .hv2-url {
  width: auto;
  height: auto;
  border-radius: var(--radius-pill);
  background: var(--bg-surface) !important;
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  font-size: 0.7rem;
  font-weight: 600;
  padding: 0.2rem 0.8rem;
  margin-left: 0.8rem;
}
.hv2-mock .mock-topbar .hv2-url i {
  color: var(--color-success);
  margin-right: 0.25rem;
  font-size: 0.6rem;
}
.hero-v2 .floating-mini-card {
  border-radius: 14px;
  box-shadow: 0 18px 40px -18px rgba(15, 23, 42, 0.4);
}

/* ---- Fit to screen (desktop) ----
   Hero fills exactly one viewport; type, spacing and the dashboard image
   scale with viewport height so everything stays above the fold. */
@media (min-width: 992px) and (min-height: 600px) {
  .hero-v2 {
    min-height: 100vh;
    min-height: 100svh;
    display: flex;
    align-items: center;
    padding-top: calc(var(--navbar-height) + 1rem);
    padding-bottom: clamp(2.5rem, 6vh, 4.5rem);
  }
  .hero-v2 > .container-xl {
    width: 100%;
  }
  .hv2-eyebrow {
    margin-bottom: clamp(0.75rem, 2.2vh, 1.5rem);
  }
  .hv2-title {
    font-size: clamp(2.3rem, min(4.3vw, 6.6vh), 4.4rem);
    margin-bottom: clamp(0.7rem, 2vh, 1.3rem);
  }
  .hv2-lead {
    font-size: clamp(0.95rem, 1.9vh, 1.2rem);
    line-height: 1.55;
  }
  .hv2-cta {
    margin-top: clamp(1rem, 3vh, 2rem);
  }
  .hv2-checks {
    margin-top: clamp(0.7rem, 1.8vh, 1.3rem);
  }
  .hv2-qr {
    margin-top: clamp(0.8rem, 2vh, 1.4rem);
  }
  .hero-v2 .hv2-ticker {
    margin-top: clamp(0.7rem, 1.8vh, 1.4rem);
  }
  .hv2-stats {
    margin-top: clamp(0.9rem, 2.6vh, 2rem);
  }
  .hv2-stat {
    padding: clamp(0.55rem, 1.4vh, 0.9rem) 1rem;
  }
  .hv2-stat strong {
    font-size: clamp(1.2rem, 2.6vh, 1.6rem);
  }
  .hv2-visual {
    padding: 0;
  }
  .hv2-mock img {
    max-height: calc(100vh - var(--navbar-height) - 9rem);
    max-height: calc(100svh - var(--navbar-height) - 9rem);
    object-fit: cover;
    object-position: top left;
  }
}
/* Short laptop screens: drop the secondary rows so the core content fits */
@media (min-width: 992px) and (max-height: 840px) {
  .hero-v2 .hv2-ticker { display: none; }
}
@media (min-width: 992px) and (max-height: 680px) {
  .hv2-checks { display: none; }
}

/* ---- Responsive ---- */
@media (max-width: 991.98px) {
  .hero-v2 {
    padding-top: calc(var(--navbar-height) + 2.5rem);
  }
  .hv2-lead,
  .hv2-stats,
  .hv2-qr {
    margin-inline: auto;
  }
  .hv2-cta,
  .hv2-checks {
    justify-content: center;
  }
}
@media (max-width: 575.98px) {
  .hv2-eyebrow-arrow { display: none; }
  .hv2-cta { flex-direction: column; align-items: stretch; }
  .hv2-btn-primary,
  .hv2-btn-ghost { justify-content: space-between; }
  .hv2-stats { gap: 0.5rem; }
  .hv2-stat { padding: 0.75rem 0.6rem; }
  .hv2-stat strong { font-size: 1.25rem; }
  .hv2-mock .mock-topbar .hv2-url { display: none; }
  .hv2-qr { padding-right: 0.75rem; }
  .hv2-qr-sub { white-space: normal; }
}
@media (max-width: 420px) {
  .hv2-qr-outlets { display: none; }
}
@media (prefers-reduced-motion: reduce) {
  .hv2-orb,
  .hv2-ring,
  .hv2-play,
  .hv2-qr-scan,
  .hv2-btn-primary::before { animation: none; }
}

