/* ============================================================
   LunchDrive — Hero Motif Layer
   Gradient atmosphere orbs + story flow animation
   Only affects index-v2.html via homepage-motif.css
   ============================================================ */

/* ============================================================
   HERO VISUAL — position context
   ============================================================ */
.s-hero__visual {
  position: relative;
  overflow: visible; /* allow story icons to bleed above */
}

/* Browser sits above orbs */
.s-hero__browser {
  position: relative;
  z-index: 2;
}

/* ============================================================
   GRADIENT ATMOSPHERE ORBS
   3 blurred circles behind the browser screenshot
   ============================================================ */
.hv-orb {
  position: absolute;
  border-radius: 50%;
  pointer-events: none;
  z-index: 0;
  will-change: transform;
}

.hv-orb--blue {
  width: 62%;
  height: 70%;
  background: radial-gradient(ellipse at center,
    rgba(14, 111, 184, .20) 0%,
    transparent 70%);
  filter: blur(48px);
  top: 5%;
  left: -8%;
  animation: orbDriftA 22s ease-in-out infinite alternate;
}

.hv-orb--cyan {
  width: 52%;
  height: 58%;
  background: radial-gradient(ellipse at center,
    rgba(56, 189, 248, .16) 0%,
    transparent 70%);
  filter: blur(52px);
  top: 15%;
  right: -6%;
  animation: orbDriftB 18s ease-in-out infinite alternate;
}

.hv-orb--violet {
  width: 44%;
  height: 50%;
  background: radial-gradient(ellipse at center,
    rgba(142, 118, 222, .13) 0%,
    transparent 70%);
  filter: blur(44px);
  bottom: 0%;
  left: 22%;
  animation: orbDriftC 25s ease-in-out infinite alternate;
}

@keyframes orbDriftA {
  from { transform: translate(0,    0)    scale(1);    }
  to   { transform: translate(5%,   8%)   scale(1.08); }
}
@keyframes orbDriftB {
  from { transform: translate(0,    0)    scale(1.04); }
  to   { transform: translate(-8%,  6%)   scale(0.94); }
}
@keyframes orbDriftC {
  from { transform: translate(0,    0)    scale(0.92); }
  to   { transform: translate(6%,  -10%)  scale(1.06); }
}

@media (prefers-reduced-motion: reduce) {
  .hv-orb { animation: none; }
}

/* ============================================================
   STORY FLOW
   Restaurace → LunchDrive → Zaměstnanci
   Positioned above the browser frame
   ============================================================ */
.hv-story {
  position: relative;
  z-index: 3;
  width: 100%;
  height: 90px;
  margin-bottom: -2px; /* tightly connects to browser top */
}

/* Hide on small screens — only desktop makes sense */
@media (max-width: 767px) {
  .hv-story { display: none; }
}

/* ---- Curved arc SVG ---- */
.hv-arc {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  overflow: visible;
}

/* Path draws left to right */
.hv-arc-path {
  opacity: 0;
  stroke-dasharray: 700;
  stroke-dashoffset: 700;
  animation: drawArc 1.2s cubic-bezier(.42, 0, .2, 1) .3s forwards;
}

@keyframes drawArc {
  0%   { stroke-dashoffset: 700; opacity: 0;   }
  5%   { opacity: .22; }
  100% { stroke-dashoffset: 0;   opacity: .22; }
}

/* ---- Icon base ---- */
.hv-icon {
  position: absolute;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 5px;
  opacity: 0;
  transform: translateY(10px) scale(.85);
}

/* Staggered appear */
.hv-icon--1 { left:  6%;              top: calc(50% - 30px); animation: iconReveal .4s ease-out  .6s forwards; }
.hv-icon--2 { left: 50%;             top: calc(50% - 30px); transform: translateX(-50%) translateY(10px) scale(.85);
              animation: iconRevealCenter .4s ease-out 1.1s forwards; }
.hv-icon--3 { right: 6%;             top: calc(50% - 30px); animation: iconReveal .4s ease-out 1.6s forwards; }

@keyframes iconReveal {
  to { opacity: 1; transform: translateY(0) scale(1); }
}
@keyframes iconRevealCenter {
  to { opacity: 1; transform: translateX(-50%) translateY(0) scale(1); }
}

/* ---- White badge card ---- */
.hv-badge {
  width: 60px;
  height: 60px;
  background: #fff;
  border-radius: 0;
  border: 1px solid rgba(27, 33, 38, .09);
  box-shadow:
    0 2px 8px  rgba(27, 33, 38, .08),
    0 8px 24px rgba(27, 33, 38, .07);
  display: grid;
  place-items: center;
}

.hv-badge img { object-fit: contain; }

/* ---- Label under icon ---- */
.hv-icon-label {
  font-family: var(--font-display);
  font-size: 10px;
  font-weight: 600;
  letter-spacing: .06em;
  text-transform: uppercase;
  color: var(--muted);
  white-space: nowrap;
}

/* ---- Gentle float after appearance ---- */
.hv-float {
  animation-fill-mode: both;
}

.hv-float--a {
  animation:
    iconRevealBadge 0s .6s both,
    iconFloat       4.2s ease-in-out 1.1s infinite;
}
.hv-float--b {
  animation:
    iconRevealBadge 0s 1.1s both,
    iconFloat       4.8s ease-in-out 1.6s infinite;
}
.hv-float--c {
  animation:
    iconRevealBadge 0s 1.6s both,
    iconFloat       4.0s ease-in-out 2.1s infinite;
}

/* Zero-duration noop — badge itself doesn't need separate reveal */
@keyframes iconRevealBadge { to {} }

@keyframes iconFloat {
  0%, 100% { transform: translateY(0px);  }
  50%       { transform: translateY(-4px); }
}

/* ============================================================
   REDUCED MOTION
   ============================================================ */
@media (prefers-reduced-motion: reduce) {
  .hv-arc-path {
    animation: none;
    stroke-dashoffset: 0;
    opacity: .22;
  }

  .hv-icon {
    animation: none;
    opacity: 1;
    transform: none;
  }

  .hv-icon--2 { transform: translateX(-50%) translateY(0) scale(1); }

  .hv-float--a,
  .hv-float--b,
  .hv-float--c {
    animation: none;
  }
}
