/* ============================================================
   VEDHAI — PREMIUM UPGRADE LAYER
   Ultra-premium animation enhancements. Loaded AFTER style.css.
   Never overrides the base design — only elevates it.
============================================================ */

/* ---------- Scroll-Reveal System (gated on JS availability) ---------- */
html.js-reveal [data-reveal] {
  opacity: 0;
  transform: translateY(26px);
  filter: blur(6px);
  transition:
    opacity .9s cubic-bezier(0.16, 1, 0.3, 1),
    transform .9s cubic-bezier(0.16, 1, 0.3, 1),
    filter .9s cubic-bezier(0.16, 1, 0.3, 1);
  transition-delay: var(--d, 0s);
  will-change: opacity, transform, filter;
}
html.js-reveal [data-reveal].revealed {
  opacity: 1;
  transform: translateY(0);
  filter: blur(0);
}

/* ---------- Cursor-tracking aurora glow inside glass cards ---------- */
.glass-card { --mx: 50%; --my: 50%; }
.glass-card::after {
  content: "";
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: radial-gradient(340px circle at var(--mx) var(--my),
              rgba(0, 201, 167, 0.14), rgba(212, 175, 55, 0.07) 42%, transparent 68%);
  opacity: 0;
  transition: opacity .45s ease;
  pointer-events: none;
  z-index: 1;
}
.glass-card:hover::after { opacity: 1; }

/* ---------- Magnetic premium buttons ---------- */
.glow-btn { transition: transform .25s cubic-bezier(0.16, 1, 0.3, 1), box-shadow .25s ease !important; }

/* ---------- Gold shimmer sweep on hero gradient text ---------- */
.hero-title .text-gradient {
  background-size: 200% 200%;
  animation: goldShimmer 6s ease-in-out infinite;
}
@keyframes goldShimmer {
  0%, 100% { background-position: 0% 50%; }
  50%      { background-position: 100% 50%; }
}

/* ---------- Hero: radar rings behind the clock ---------- */
.hero-visual { position: relative; }
.clock-radar {
  position: absolute;
  top: 50%; left: 50%;
  width: 440px; height: 440px;
  transform: translate(-50%, -50%);
  pointer-events: none;
  z-index: 0;
}
.clock-radar span {
  position: absolute;
  inset: 0;
  border: 1px solid rgba(0, 201, 167, 0.28);
  border-radius: 50%;
  opacity: 0;
  animation: radarPulse 3.9s cubic-bezier(0.16, 1, 0.3, 1) infinite;
}
.clock-radar span:nth-child(2) { animation-delay: 1.3s; border-color: rgba(212, 175, 55, 0.22); }
.clock-radar span:nth-child(3) { animation-delay: 2.6s; }
@keyframes radarPulse {
  0%   { transform: scale(0.52); opacity: 0.75; }
  100% { transform: scale(1.18); opacity: 0; }
}

/* ---------- Hero: orbiting map pins around the clock ---------- */
.pin-orbit {
  position: absolute;
  top: 50%; left: 50%;
  width: 350px; height: 350px;
  margin: -175px 0 0 -175px;
  pointer-events: none;
  z-index: 2;
  animation: orbitSpin 26s linear infinite;
}
.pin-orbit--fast {
  width: 262px; height: 262px;
  margin: -131px 0 0 -131px;
  animation-duration: 17s;
  animation-direction: reverse;
}
@keyframes orbitSpin { to { transform: rotate(360deg); } }
.pin-wrap {
  position: absolute;
  top: -13px; left: 50%;
  margin-left: -12px;
  display: block;
  filter: drop-shadow(0 8px 14px rgba(0, 0, 0, 0.55));
  animation: orbitSpin 26s linear infinite reverse;
}
.pin-orbit--fast .pin-wrap { animation-duration: 17s; animation-direction: normal; }
.pin-ic {
  width: 24px; height: 24px;
  fill: var(--primary-gold, #D4AF37);
  stroke: var(--primary-gold, #D4AF37);
  stroke-width: 1.4;
  animation: pinBob 2.7s ease-in-out infinite;
}
.pin-orbit--fast .pin-ic {
  fill: var(--primary-teal, #00C9A7);
  stroke: var(--primary-teal, #00C9A7);
  animation-delay: 1.1s;
}
@keyframes pinBob {
  0%, 100% { transform: translateY(0); }
  50%      { transform: translateY(-7px); }
}

/* ---------- HOW IT WORKS section ---------- */
.process-section {
  padding: 100px 0 60px;
  position: relative;
}
.process-intro {
  text-align: center;
  color: var(--text-secondary, rgba(255,255,255,.7));
  max-width: 640px;
  margin: -10px auto 48px;
  font-size: 1.05rem;
  line-height: 1.7;
}
.process-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 24px;
  position: relative;
}
.process-card {
  padding: 34px 26px 28px;
  text-align: center;
  position: relative;
  transition: transform .5s cubic-bezier(0.16, 1, 0.3, 1), box-shadow .5s ease, border-color .5s ease;
}
.process-card:hover {
  transform: translateY(-10px);
  box-shadow: 0 24px 60px rgba(0, 201, 167, 0.16), 0 8px 24px rgba(0, 0, 0, 0.4);
  border-color: rgba(0, 201, 167, 0.45);
}
.process-num {
  font-family: var(--font-display, 'Orbitron', sans-serif);
  font-size: 2.6rem;
  font-weight: 800;
  line-height: 1;
  background: linear-gradient(135deg, rgba(0,201,167,.9), rgba(212,175,55,.9));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  margin-bottom: 14px;
  letter-spacing: 2px;
}
.process-icon {
  width: 58px; height: 58px;
  margin: 0 auto 18px;
  border-radius: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(135deg, rgba(0,201,167,.16), rgba(212,175,55,.12));
  border: 1px solid rgba(0, 201, 167, 0.35);
  box-shadow: inset 0 0 18px rgba(0, 201, 167, 0.12);
}
.process-icon .ic { width: 26px; height: 26px; stroke: var(--primary-teal, #00C9A7); }
.process-card h3 {
  font-size: 1.12rem;
  margin-bottom: 10px;
  color: var(--text-primary, #fff);
  letter-spacing: .3px;
}
.process-card p {
  font-size: .92rem;
  line-height: 1.65;
  color: var(--text-secondary, rgba(255,255,255,.65));
  margin: 0;
}
@media (min-width: 981px) {
  .process-grid::before {
    content: "";
    position: absolute;
    top: 96px; left: 8%; right: 8%;
    height: 1px;
    background: linear-gradient(90deg, transparent, rgba(0,201,167,.4) 20%, rgba(212,175,55,.4) 80%, transparent);
    z-index: 0;
  }
  .process-card { z-index: 1; }
}
@media (max-width: 980px) { .process-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .process-grid { grid-template-columns: 1fr; } }

/* ---------- THE TRANSFORMATION section ---------- */
.transform-section {
  padding: 90px 0 110px;
  position: relative;
  overflow: hidden;
}
.transform-intro {
  text-align: center;
  color: var(--text-secondary, rgba(255,255,255,.7));
  max-width: 620px;
  margin: -10px auto 54px;
  font-size: 1.05rem;
  line-height: 1.7;
}
.transform-stage {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 56px;
  flex-wrap: wrap;
}
.tm-radar {
  position: absolute;
  top: 50%; left: 50%;
  width: 560px; height: 560px;
  max-width: 90vw; max-height: 90vw;
  transform: translate(-50%, -50%);
  pointer-events: none;
  z-index: 0;
}
.tm-radar span {
  position: absolute;
  inset: 0;
  border: 1px solid rgba(0, 201, 167, 0.2);
  border-radius: 50%;
  opacity: 0;
  animation: radarPulse 4.2s cubic-bezier(0.16, 1, 0.3, 1) infinite;
}

/* ---------- Phone mockup (Google Maps profile) ---------- */
.tm-phone {
  position: relative;
  z-index: 1;
  width: 330px;
  max-width: 88vw;
  border-radius: 42px;
  padding: 14px;
  background: linear-gradient(160deg, #10182a 0%, #0a0f1c 60%);
  border: 1px solid rgba(255, 255, 255, 0.12);
  box-shadow:
    0 40px 90px rgba(0, 0, 0, 0.6),
    0 0 0 1px rgba(0, 201, 167, 0.08),
    inset 0 1px 0 rgba(255, 255, 255, 0.08);
  animation: phoneFloat 7s ease-in-out infinite;
  transform-style: preserve-3d;
}
@keyframes phoneFloat {
  0%, 100% { transform: translateY(0) rotateX(0deg) rotateY(0deg); }
  50%      { transform: translateY(-14px) rotateX(1.2deg) rotateY(-1.2deg); }
}
.tm-notch {
  position: absolute;
  top: 22px; left: 50%;
  transform: translateX(-50%);
  width: 110px; height: 22px;
  background: #05080f;
  border-radius: 12px;
  z-index: 3;
  border: 1px solid rgba(255, 255, 255, 0.05);
}
.tm-screen {
  border-radius: 30px;
  min-height: 600px;
  padding: 52px 16px 20px;
  background:
    radial-gradient(circle at 20% 15%, rgba(0, 201, 167, 0.08), transparent 42%),
    repeating-linear-gradient(0deg, transparent 0 34px, rgba(255,255,255,0.035) 34px 35px),
    repeating-linear-gradient(90deg, transparent 0 34px, rgba(255,255,255,0.035) 34px 35px),
    linear-gradient(165deg, #0d1524 0%, #070b14 100%);
  border: 1px solid rgba(255, 255, 255, 0.07);
  display: flex;
  flex-direction: column;
  gap: 13px;
  overflow: hidden;
}
.tm-search {
  display: flex;
  align-items: center;
  gap: 9px;
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 12px;
  padding: 9px 12px;
  font-size: .78rem;
  color: rgba(255, 255, 255, 0.75);
  white-space: nowrap;
  overflow: hidden;
}
.tm-search .ic { width: 14px; height: 14px; stroke: var(--primary-teal, #00C9A7); flex: none; }
.tm-title-row { display: flex; flex-direction: column; gap: 7px; }
.tm-title-row h4 {
  margin: 0;
  font-size: 1.02rem;
  line-height: 1.3;
  color: #fff;
  font-weight: 700;
}
.tm-badge {
  align-self: flex-start;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: .62rem;
  font-weight: 700;
  letter-spacing: .8px;
  text-transform: uppercase;
  color: #0a0f1c;
  background: linear-gradient(135deg, #D4AF37, #f0d98c);
  padding: 4px 9px;
  border-radius: 999px;
  opacity: 0;
  transform: translateY(6px) scale(.9);
  transition: opacity .6s ease .35s, transform .6s cubic-bezier(0.16, 1, 0.3, 1) .35s;
}
.tm-badge .ic { width: 11px; height: 11px; stroke: #0a0f1c; }
.tm-phone.after .tm-badge { opacity: 1; transform: translateY(0) scale(1); }
.tm-cat-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  font-size: .72rem;
  flex-wrap: wrap;
}

/* ---------- Stars: the hero moment ---------- */
.tm-stars-row {
  display: flex;
  align-items: center;
  gap: 9px;
  flex-wrap: wrap;
}
.tm-rating { position: relative; font-size: 1.06rem; font-weight: 800; min-width: 34px; }
.tm-rate-before, .tm-rate-after { transition: opacity .55s ease; }
.tm-rate-before { color: rgba(255, 255, 255, 0.45); }
.tm-rate-after {
  position: absolute;
  left: 0; top: 0;
  color: var(--primary-gold, #D4AF37);
  opacity: 0;
}
.tm-phone.after .tm-rate-before { opacity: 0; }
.tm-phone.after .tm-rate-after  { opacity: 1; }
.tm-stars {
  position: relative;
  font-size: 1.04rem;
  letter-spacing: 2px;
  line-height: 1;
  display: inline-block;
}
.tm-stars-base { color: rgba(255, 255, 255, 0.22); }
.tm-stars-fill {
  position: absolute;
  left: 0; top: 0;
  overflow: hidden;
  white-space: nowrap;
  color: var(--primary-gold, #D4AF37);
  width: 46%;
  text-shadow: 0 0 12px rgba(212, 175, 55, 0.55);
  transition: width 1.4s cubic-bezier(0.16, 1, 0.3, 1) .25s;
}
.tm-phone.after .tm-stars-fill { width: 98%; }
.tm-reviews { position: relative; font-size: .74rem; min-width: 76px; color: rgba(255,255,255,.55); }
.tm-rev-before, .tm-rev-after { transition: opacity .55s ease; }
.tm-rev-after { position: absolute; left: 0; top: 0; color: var(--primary-gold, #D4AF37); opacity: 0; }
.tm-phone.after .tm-rev-before { opacity: 0; }
.tm-phone.after .tm-rev-after  { opacity: 1; }

/* ---------- Action buttons ---------- */
.tm-actions { display: flex; gap: 8px; }
.tm-action {
  flex: 1;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  font-size: .72rem;
  font-weight: 600;
  padding: 9px 4px;
  border-radius: 11px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(255, 255, 255, 0.05);
  color: rgba(255, 255, 255, 0.6);
  transition: all .6s ease .4s;
  white-space: nowrap;
}
.tm-action .ic { width: 13px; height: 13px; }
.tm-phone.after .tm-action {
  color: #fff;
  border-color: rgba(0, 201, 167, 0.45);
  background: rgba(0, 201, 167, 0.1);
  box-shadow: 0 0 16px rgba(0, 201, 167, 0.12);
}
.tm-phone.after .tm-call {
  border-color: rgba(212, 175, 55, 0.6);
  background: linear-gradient(135deg, rgba(212,175,55,.22), rgba(212,175,55,.1));
  box-shadow: 0 0 20px rgba(212, 175, 55, 0.25);
}

/* ---------- Photo strip: dull to premium ---------- */
.tm-photos { display: grid; grid-template-columns: repeat(4, 1fr); gap: 7px; }
.tm-ph {
  display: block;
  height: 58px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  filter: grayscale(.85) brightness(.55);
  transition: filter .9s ease .5s, transform .9s cubic-bezier(0.16, 1, 0.3, 1) .5s;
}
.tm-ph-1 { background: linear-gradient(140deg, #2a3550, #16203a 60%, #0e1626); }
.tm-ph-2 { background: linear-gradient(140deg, #3a2f22, #241c12 60%, #14100a); }
.tm-ph-3 { background: linear-gradient(140deg, #22303a, #142028 60%, #0c1319); }
.tm-ph-more {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: .74rem;
  font-weight: 700;
  color: rgba(255, 255, 255, 0.4);
  background: rgba(255, 255, 255, 0.04);
  opacity: 0;
  transition: opacity .6s ease .8s;
}

/* ---------- Before / After legend cards ---------- */
.tm-legend {
  display: flex;
  flex-direction: column;
  gap: 18px;
  z-index: 1;
}
.tm-legend-card {
  padding: 18px 22px;
  min-width: 265px;
  display: grid;
  grid-template-columns: 1fr auto;
  align-items: center;
  gap: 4px 14px;
}
.tm-legend-k {
  grid-column: 1 / -1;
  font-size: .74rem;
  font-weight: 600;
  letter-spacing: .6px;
  text-transform: uppercase;
  color: rgba(255, 255, 255, 0.55);
}
.tm-legend-before {
  font-size: 1.3rem;
  font-weight: 800;
  color: rgba(255, 255, 255, 0.35);
  position: relative;
}
.tm-legend-before::after {
  content: "";
  position: absolute;
  left: 0; top: 52%;
  width: 100%; height: 2px;
  background: rgba(255, 84, 89, 0.6);
  transform: rotate(-6deg);
}
.tm-legend-after {
  font-size: 1.55rem;
  font-weight: 800;
  font-family: var(--font-display, 'Orbitron', sans-serif);
  background: linear-gradient(135deg, #00C9A7, #D4AF37);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  font-variant-numeric: tabular-nums;
}

/* ---------- Responsive ---------- */
@media (max-width: 1100px) {
  .transform-stage { gap: 40px; }
}
@media (max-width: 720px) {
  .tm-legend { flex-direction: row; flex-wrap: wrap; justify-content: center; }
  .tm-legend-card { min-width: 220px; flex: 1; }
  .tm-screen { min-height: 560px; }
}
@media (max-width: 400px) {
  .tm-phone { width: 300px; }
  .tm-screen { min-height: 520px; }
}

/* ---------- Reduced motion: respect user preference ---------- */
@media (prefers-reduced-motion: reduce) {
  .clock-radar span, .tm-radar span,
  .pin-orbit, .pin-wrap, .pin-ic,
  .tm-phone, .hero-title .text-gradient {
    animation: none !important;
  }
  html.js-reveal [data-reveal] {
    opacity: 1;
    transform: none;
    filter: none;
    transition: none;
  }
}

.tm-phone.after .tm-ph { filter: grayscale(0) brightness(1.05); transform: scale(1.02); }
.tm-phone.after .tm-ph-1 { background: linear-gradient(140deg, #00c9a7, #0b8f7c 55%, #075e54); }
.tm-phone.after .tm-ph-2 { background: linear-gradient(140deg, #f0c94a, #c99a2e 55%, #8a6a1a); }
.tm-phone.after .tm-ph-3 { background: linear-gradient(140deg, #4a90d9, #2a6bb0 55%, #1a4575); }
.tm-phone.after .tm-ph-more { opacity: 1; color: rgba(255,255,255,.85); }

/* ---------- Review quote ---------- */
.tm-review-quote {
  margin-top: auto;
  border-radius: 13px;
  padding: 12px 14px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid rgba(255, 255, 255, 0.08);
  opacity: 0;
  transform: translateY(10px);
  transition: opacity .7s ease .7s, transform .7s cubic-bezier(0.16, 1, 0.3, 1) .7s;
}
.tm-phone.after .tm-review-quote { opacity: 1; transform: translateY(0); }
.tm-q-name { font-size: .74rem; font-weight: 700; color: #fff; margin-right: 8px; }
.tm-q-stars { font-size: .68rem; color: var(--primary-gold, #D4AF37); letter-spacing: 1.5px; }
.tm-review-quote p { margin: 6px 0 0; font-size: .76rem; line-height: 1.55; color: rgba(255, 255, 255, 0.72); }

.tm-cat { color: rgba(255, 255, 255, 0.55); }
.tm-status { font-weight: 600; }
.tm-open { color: #34d399; }

.tm-radar span:nth-child(2) { animation-delay: 1.4s; border-color: rgba(212, 175, 55, 0.16); }
.tm-radar span:nth-child(3) { animation-delay: 2.8s; }
