/* ═══════════════════════════════════════════════════════════════════════════
   BLIP BLOPS — Shared Template Styles
   Base layer on top of Tailwind CDN — animations, components, utilities
   ═══════════════════════════════════════════════════════════════════════════ */

/* ── Skip-to-content (a11y) ───────────────────────────────────────────── */
.skip-link {
  position: absolute;
  top: -100%;
  left: 50%;
  transform: translateX(-50%);
  z-index: 9999;
  padding: 0.75rem 1.5rem;
  background: #fff;
  color: #000;
  border-radius: 0 0 0.5rem 0.5rem;
  font-weight: 600;
  transition: top 0.2s;
}
.skip-link:focus {
  top: 0;
}

/* ── Header scroll state ──────────────────────────────────────────────── */
#site-header {
  transition: padding 0.3s ease, box-shadow 0.3s ease, background 0.3s ease, top 0.3s ease;
}
.header-scrolled {
  top: 0 !important;
  padding-top: 0.5rem !important;
  padding-bottom: 0.5rem !important;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.15);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

/* ── Scroll Animations ────────────────────────────────────────────────── */
.animate-on-scroll {
  opacity: 0;
  transform: translateY(30px);
  transition: opacity 0.7s ease-out, transform 0.7s ease-out;
}
.animate-on-scroll.fade-left {
  transform: translateX(-30px);
}
.animate-on-scroll.fade-right {
  transform: translateX(30px);
}
.animate-on-scroll.scale-up {
  transform: scale(0.92);
}
.animate-on-scroll.in-view,
.stagger-item.in-view {
  opacity: 1;
  transform: translateY(0) translateX(0) scale(1);
}
.stagger-item {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease-out, transform 0.5s ease-out;
}

/* ── Glassmorphism Card ───────────────────────────────────────────────── */
.glass {
  background: rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.08);
}
.glass-light {
  background: rgba(255, 255, 255, 0.65);
  backdrop-filter: blur(16px);
  -webkit-backdrop-filter: blur(16px);
  border: 1px solid rgba(255, 255, 255, 0.3);
}

/* ── Gradient text utility ────────────────────────────────────────────── */
.gradient-text {
  background-clip: text;
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

/* ── Hero parallax (subtle) ───────────────────────────────────────────── */
.parallax-bg {
  background-attachment: fixed;
  background-size: cover;
  background-position: center;
}
@supports not (background-attachment: fixed) {
  .parallax-bg {
    background-attachment: scroll;
  }
}

/* ── Testimonial Carousel ─────────────────────────────────────────────── */
[data-testimonial-track] {
  display: flex;
  transition: transform 0.5s cubic-bezier(0.25, 0.46, 0.45, 0.94);
}
[data-testimonial-card] {
  flex: 0 0 100%;
}
@media (min-width: 768px) {
  [data-testimonial-card] {
    flex: 0 0 33.333%;
  }
}

/* ── Before / After Slider ────────────────────────────────────────────── */
[data-before-after] {
  position: relative;
  overflow: hidden;
  cursor: ew-resize;
}
[data-ba-overlay] {
  position: absolute;
  inset: 0;
  clip-path: inset(0 50% 0 0);
}
[data-ba-slider] {
  position: absolute;
  top: 0;
  bottom: 0;
  left: 50%;
  width: 4px;
  background: white;
  cursor: ew-resize;
  z-index: 10;
}
[data-ba-slider]::after {
  content: "⇔";
  position: absolute;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: white;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 14px;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.3);
}

/* ── Tab active state ─────────────────────────────────────────────────── */
.tab-active {
  border-bottom: 2px solid currentColor;
  font-weight: 600;
}

/* ── FAQ Accordion icon rotation ──────────────────────────────────────── */
[data-accordion-icon] {
  transition: transform 0.3s ease;
}

/* ── Back to top ──────────────────────────────────────────────────────── */
#back-to-top {
  transition: opacity 0.3s ease;
}

/* ── Floating shapes (background decoration) ──────────────────────────── */
.blob {
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.15;
  position: absolute;
  pointer-events: none;
}

/* ── Hover lift effect ────────────────────────────────────────────────── */
.hover-lift {
  transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.hover-lift:hover {
  transform: translateY(-6px);
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.12);
}

/* ── Image shimmer loading placeholder ────────────────────────────────── */
.img-shimmer {
  background: linear-gradient(90deg, #e5e7eb 25%, #f3f4f6 50%, #e5e7eb 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}
@keyframes shimmer {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* ── Mobile Call Bar ──────────────────────────────────────────────────── */
#mobile-call-bar {
  position: fixed;
  bottom: 0;
  left: 0;
  right: 0;
  z-index: 50;
  padding: 0.75rem;
  text-align: center;
}
@media (min-width: 768px) {
  #mobile-call-bar {
    display: none !important;
  }
}

/* ── Star Rating ──────────────────────────────────────────────────────── */
.stars {
  color: #fbbf24;
  letter-spacing: 2px;
}

/* ── Pulse ring for CTA buttons ───────────────────────────────────────── */
.pulse-ring {
  position: relative;
}
.pulse-ring::before {
  content: "";
  position: absolute;
  inset: -4px;
  border-radius: inherit;
  border: 2px solid currentColor;
  opacity: 0;
  animation: pulse-ring 2s cubic-bezier(0.4, 0, 0.6, 1) infinite;
}
@keyframes pulse-ring {
  0%, 100% { opacity: 0; transform: scale(1); }
  50% { opacity: 0.3; transform: scale(1.05); }
}

/* ── Smooth image reveal ──────────────────────────────────────────────── */
img[loading="lazy"] {
  opacity: 0;
  transition: opacity 0.5s ease;
}
img[loading="lazy"].loaded,
img[loading="lazy"]:not([data-src]) {
  opacity: 1;
}

/* ── Print styles ─────────────────────────────────────────────────────── */
@media print {
  #site-header, #mobile-call-bar, #back-to-top, .no-print {
    display: none !important;
  }
  body {
    color: #000 !important;
    background: #fff !important;
  }
}
