/* ============================================================
   QP Pro Services — Five Pillars of Continuity Hero
   CSS for the new Three.js powered hero section
   ============================================================ */

/* ---------- Wrapper ---------- */
#qp-hero {
  position: relative;
  width: 100%;
  height: 100vh;
  min-height: 600px;
  max-height: 960px;
  overflow: hidden;
  background: #e5ebea;
  display: flex;
  align-items: center;
  justify-content: center;
}

/* ---------- Three.js Canvas ---------- */
#hero-canvas {
  position: absolute;
  inset: 0;
  width: 100% !important;
  height: 100% !important;
  z-index: 1;
  display: block;
}

/* ---------- Overlay gradient (bottom fade) ---------- */
#qp-hero::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 0;
  right: 0;
  height: 220px;
  background: linear-gradient(to bottom, transparent 0%, #b2d0d4 100%);
  z-index: 2;
  pointer-events: none;
}

/* ---------- Content overlay ---------- */
.hero-content {
  position: relative;
  z-index: 10;
  width: 100%;
  max-width: 1200px;
  padding: 0 40px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 60px;
  align-items: center;
}

/* ---------- Left: text block ---------- */
.hero-text {
  color: #fff;
}

.hero-tag {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 3px;
  text-transform: uppercase;
  color: #00a1b6;
  margin-bottom: 28px;
  opacity: 0;
  animation: fadeSlideUp 0.8s ease 0.5s forwards;
}

.hero-tag::before {
  content: '';
  display: inline-block;
  width: 36px;
  height: 1px;
  background: #00a1b6;
}

.hero-title {
  font-size: clamp(38px, 5vw, 68px);
  font-weight: 700;
  line-height: 1.08;
  letter-spacing: -2px;
  color: #00a1b6;
  margin-bottom: 24px;
  opacity: 0;
  animation: fadeSlideUp 0.9s ease 0.7s forwards;
}

.hero-title span {
  color: #ba8c78;
  font-style: italic;
  font-weight: 400;
  font-family: 'Georgia', serif;
}

.hero-subtitle {
  font-size: 16px;
  line-height: 1.7;
  color: #203247;
  max-width: 480px;
  margin-bottom: 48px;
  opacity: 0;
  animation: fadeSlideUp 0.9s ease 0.9s forwards;
}

/* ---------- CTA buttons ---------- */
.hero-cta-group {
  display: flex;
  align-items: center;
  gap: 20px;
  flex-wrap: wrap;
  opacity: 0;
  animation: fadeSlideUp 0.9s ease 1.1s forwards;
}

.hero-btn-primary {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  padding: 16px 32px;
  background: #00a1b6;
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  letter-spacing: 0.5px;
  border-radius: 100px;
  text-decoration: none;
  transition: background 0.3s, transform 0.2s, box-shadow 0.3s;
  box-shadow: 0 0 0 0 rgba(0, 161, 182, 0);
}

.hero-btn-primary:hover {
  background: #0090a3;
  transform: translateY(-2px);
  box-shadow: 0 12px 40px rgba(0, 161, 182, 0.35);
  color: #fff;
}

.hero-btn-primary i {
  font-size: 12px;
  transition: transform 0.25s;
}

.hero-btn-primary:hover i {
  transform: translateX(4px);
}

.hero-btn-secondary {
  font-size: 14px;
  color: #ba8c78;
  text-decoration: none;
  letter-spacing: 0.3px;
  transition: color 0.3s;
  display: flex;
  align-items: center;
  gap: 6px;
}

.hero-btn-secondary:hover {
  color: #00a1b6;
}

/* ---------- Right: 5 Pillars indicator cards ---------- */
.hero-pillars {
  display: flex;
  flex-direction: column;
  gap: 12px;
  opacity: 0;
  animation: fadeSlideUp 0.9s ease 1.3s forwards;
}

.pillar-card {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 20px;
  border: 1px solid #c2dde0;
  border-radius: 10px;
  background: rgba(255, 255, 255, 0.03);
  backdrop-filter: blur(6px);
  cursor: pointer;
  transition: border-color 0.3s, background 0.3s, transform 0.25s;
  text-decoration: none;
}

.pillar-card:hover {
  border-color: rgba(0, 161, 182, 0.35);
  background: rgba(0, 161, 182, 0.07);
  transform: translateX(6px);
}

.pillar-card.active {
  border-color: rgba(0, 161, 182, 0.5);
  background: rgba(0, 161, 182, 0.1);
}

.pillar-num {
  font-size: 10px;
  font-weight: 700;
  letter-spacing: 2px;
  color: #00a1b6;
  min-width: 28px;
  font-family: 'Courier New', monospace;
}

.pillar-label {
  font-size: 14px;
  font-weight: 500;
  color: #00a1b6;
  flex: 1;
}

.pillar-dot {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: rgba(0, 161, 182, 0.3);
  transition: background 0.3s, transform 0.3s;
}

.pillar-card:hover .pillar-dot,
.pillar-card.active .pillar-dot {
  background: #00a1b6;
  transform: scale(1.5);
}

/* ---------- Scroll indicator ---------- */
.hero-scroll-indicator {
  position: absolute;
  bottom: 36px;
  left: 50%;
  transform: translateX(-50%);
  z-index: 10;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
  opacity: 0;
  animation: fadeIn 1s ease 2s forwards;
}

.hero-scroll-indicator span {
  font-size: 10px;
  letter-spacing: 2.5px;
  text-transform: uppercase;
  color: #ba8c78;
}

.scroll-line {
  width: 1px;
  height: 48px;
  background: linear-gradient(to bottom,#ba8c78, transparent);
  animation: scrollPulse 2s ease-in-out infinite;
}

/* ---- Mobile fallback ---- */
.hero-mobile-fallback {
  display: none;
  position: absolute;
  inset: 0;
  z-index: 0;
  background:
    radial-gradient(ellipse 80% 60% at 20% 50%, rgba(0, 161, 182, 0.12) 0%, transparent 70%),
    radial-gradient(ellipse 60% 80% at 80% 30%, rgba(186, 140, 120, 0.08) 0%, transparent 70%),
    #0e1e1d;
}

/* Static pillars for mobile fallback */
.hero-static-pillars {
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  display: flex;
  align-items: flex-end;
  gap: 12px;
  height: 55%;
  padding-bottom: 0;
}

.static-pillar {
  width: 3px;
  border-radius: 2px 2px 0 0;
  background: linear-gradient(to top, #00a1b6, transparent);
  opacity: 0.4;
}

.static-pillar:nth-child(1) { height: 100%; }
.static-pillar:nth-child(2) { height: 80%; }
.static-pillar:nth-child(3) { height: 90%; }
.static-pillar:nth-child(4) { height: 70%; }
.static-pillar:nth-child(5) { height: 85%; }

/* ---------- Keyframes ---------- */
@keyframes fadeSlideUp {
  from { opacity: 0; transform: translateY(28px); }
  to   { opacity: 1; transform: translateY(0); }
}

@keyframes fadeIn {
  from { opacity: 0; }
  to   { opacity: 1; }
}

@keyframes scrollPulse {
  0%   { transform: scaleY(1); opacity: 1; }
  50%  { transform: scaleY(0.5); opacity: 0.3; }
  100% { transform: scaleY(1); opacity: 1; }
}

/* ---------- Responsive ---------- */
@media (max-width: 1024px) {
  .hero-content {
    grid-template-columns: 1fr;
    gap: 36px;
    max-width: 640px;
    padding: 0 30px;
  }

  .hero-pillars {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 10px;
  }
}

@media (max-width: 768px) {
  #qp-hero {
    max-height: 100vh;
    min-height: 100svh;
  }

  /* Show fallback, hide canvas on mobile for perf */
  .no-webgl #hero-canvas,
  .qp-mobile #hero-canvas {
    display: none;
  }

  .no-webgl .hero-mobile-fallback,
  .qp-mobile .hero-mobile-fallback {
    display: block;
  }

  .hero-content {
    padding: 0 20px;
    text-align: center;
  }

  .hero-text {
    text-align: center;
  }

  .hero-subtitle {
    margin-left: auto;
    margin-right: auto;
  }

  .hero-cta-group {
    justify-content: center;
  }

  .hero-pillars {
    grid-template-columns: 1fr;
    max-width: 320px;
    margin: 0 auto;
  }

  .pillar-card:hover {
    transform: none;
  }

  .hero-scroll-indicator {
    bottom: 20px;
  }
}

@media (prefers-reduced-motion: reduce) {
  .hero-tag,
  .hero-title,
  .hero-subtitle,
  .hero-cta-group,
  .hero-pillars,
  .hero-scroll-indicator {
    animation: none;
    opacity: 1;
  }

  .scroll-line {
    animation: none;
  }
}
