/* ═══════════════════════════════════════════════════════════════════
   DM TECH STUDIO — CINEMATIC DIWALI FESTIVE THEME
   Design: Premium Diwali × Technology
   Author: DM Tech Studio (Festive Edition)
   Easily disabled: Set $diwaliTheme = false in header.php
   ═══════════════════════════════════════════════════════════════════ */

/* ── 0. CSS VARIABLES ── */
:root {
  --dw-gold-1: #ffffff;
  --dw-gold-2: #fef08a;
  --dw-gold-3: #f59e0b;
  --dw-gold-4: #d97706;
  --dw-gold-5: #b45309;
  --dw-saffron: #ea580c;
  --dw-amber: #fbbf24;
  --dw-halo: rgba(245, 158, 11, 0.35);
  --dw-border-gold: rgba(245, 158, 11, 0.32);
  --dw-glass-bg: rgba(10, 14, 26, 0.85);
  --dw-banner-height: 38px;
}

/* ── 1. FESTIVE TOP ANNOUNCEMENT BAR ── */
.festive-announcement-bar {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  height: var(--dw-banner-height);
  z-index: 1001;
  background: linear-gradient(90deg,
    rgba(10, 14, 26, 0.96) 0%,
    rgba(32, 22, 10, 0.96) 25%,
    rgba(40, 26, 12, 0.98) 50%,
    rgba(32, 22, 10, 0.96) 75%,
    rgba(10, 14, 26, 0.96) 100%
  );
  border-bottom: 1px solid rgba(245, 158, 11, 0.28);
  box-shadow: 0 4px 20px rgba(245, 158, 11, 0.15);
  backdrop-filter: blur(14px);
  -webkit-backdrop-filter: blur(14px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 0 16px;
  font-family: var(--font-ui, "Plus Jakarta Sans", sans-serif);
  color: #ffffff;
  transition: transform 0.35s cubic-bezier(0.16, 1, 0.3, 1), opacity 0.35s ease;
}

.festive-announcement-bar.is-hidden {
  transform: translateY(-100%);
  opacity: 0;
  pointer-events: none;
}

.festive-announcement-inner {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 12px;
  letter-spacing: 0.5px;
  text-align: center;
}

.festive-bar-diya {
  font-size: 14px;
  filter: drop-shadow(0 0 6px rgba(245, 158, 11, 0.8));
  animation: diyaIconBob 3s ease-in-out infinite;
}

.festive-bar-text {
  font-weight: 500;
  background: linear-gradient(90deg, #ffffff 0%, #fef08a 40%, #f59e0b 80%, #ffffff 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  background-size: 200% auto;
  animation: goldShimmer 6s linear infinite;
}

.festive-bar-sparkle {
  font-size: 12px;
  color: var(--dw-amber);
}

.festive-bar-close {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.45);
  font-size: 14px;
  cursor: pointer;
  padding: 4px 8px;
  line-height: 1;
  border-radius: 4px;
  transition: color 0.2s, background 0.2s;
}

.festive-bar-close:hover {
  color: #ffffff;
  background: rgba(255, 255, 255, 0.08);
}

/* ── 2. NAVBAR COORDINATION (ZERO OVERLAP) ── */
body.festive-theme.has-festive-banner nav,
body.festive-theme.has-festive-banner #mainNav,
body.festive-theme.has-festive-banner nav.scrolled,
body.festive-theme.has-festive-banner #mainNav.scrolled {
  top: var(--dw-banner-height, 38px) !important;
  transition: top 0.35s cubic-bezier(0.16, 1, 0.3, 1), background 0.4s, padding 0.4s !important;
}

body.festive-theme nav,
body.festive-theme #mainNav {
  transition: top 0.35s cubic-bezier(0.16, 1, 0.3, 1), background 0.4s, padding 0.4s !important;
}

/* ── 3. HERO CINEMATIC ATMOSPHERE ── */
body.festive-theme .intro-hero {
  position: relative;
  overflow: hidden;
}

/* Ambient warm golden illumination overlay */
body.festive-theme .intro-hero::after {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(ellipse 70% 55% at 50% 18%, rgba(245, 158, 11, 0.12) 0%, transparent 68%),
    radial-gradient(circle at 15% 85%, rgba(234, 88, 12, 0.08) 0%, transparent 45%),
    radial-gradient(circle at 85% 85%, rgba(245, 158, 11, 0.08) 0%, transparent 45%);
  pointer-events: none;
  z-index: 5;
}

/* Canvas for floating golden particles */
#festiveHeroCanvas {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 6;
}

/* ── 4. FESTIVE HERO HEADLINE & BADGE ── */
.festive-hero-greet {
  display: flex;
  flex-direction: column;
  align-items: center;
  margin-bottom: 18px;
  animation: fadeSlideUp 0.8s cubic-bezier(0.16, 1, 0.3, 1) 0.2s both;
}

.festive-diya-badge {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 6px 16px;
  border-radius: 100px;
  background: rgba(245, 158, 11, 0.12);
  border: 1px solid rgba(245, 158, 11, 0.35);
  box-shadow: 0 4px 18px rgba(245, 158, 11, 0.15), inset 0 1px 0 rgba(254, 240, 138, 0.3);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  font-family: var(--font-ui, "Plus Jakarta Sans", sans-serif);
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 2px;
  text-transform: uppercase;
  color: var(--dw-gold-2);
  margin-bottom: 12px;
}

.festive-diya-badge .badge-diya {
  font-size: 14px;
  filter: drop-shadow(0 0 6px #f59e0b);
}

.festive-diya-badge .badge-sparkle {
  font-size: 11px;
  color: #fef08a;
}

.festive-hero-title {
  font-family: var(--font-display, "Playfair Display", serif);
  font-size: clamp(20px, 3.2vw, 36px);
  font-weight: 400;
  line-height: 1.25;
  letter-spacing: -0.5px;
  text-align: center;
  margin: 0;
  background: linear-gradient(135deg, #ffffff 0%, #fef08a 35%, #f59e0b 70%, #d97706 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
  background-size: 200% auto;
  animation: goldShimmer 7s linear infinite;
  text-shadow: 0 0 25px rgba(245, 158, 11, 0.3);
}

.festive-hero-title em {
  font-style: italic;
  font-weight: 500;
}

/* ── 5. REALISTIC 3D GLOWING BRASS DIYAS ── */
.festive-hero-diya {
  position: absolute;
  z-index: 8;
  display: flex;
  flex-direction: column;
  align-items: center;
  pointer-events: none;
  user-select: none;
  animation: diyaGentleFloat 5s ease-in-out infinite alternate;
}

.festive-hero-diya.diya-hero-left {
  left: clamp(20px, 4.5vw, 64px);
  bottom: clamp(32px, 8vh, 76px);
}

.festive-hero-diya.diya-hero-right {
  right: clamp(20px, 4.5vw, 64px);
  bottom: clamp(32px, 8vh, 76px);
  animation-delay: -2.5s;
}

/* Flame & Halo */
.diya-flame-wrap {
  position: relative;
  width: 22px;
  height: 32px;
  display: flex;
  align-items: flex-end;
  justify-content: center;
}

.diya-flame-halo {
  position: absolute;
  top: -14px;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(251, 191, 36, 0.7) 0%, rgba(245, 158, 11, 0.3) 50%, transparent 75%);
  filter: blur(6px);
  animation: diyaHaloPulse 2.2s infinite alternate ease-in-out;
  pointer-events: none;
}

.diya-flame-body {
  position: relative;
  width: 13px;
  height: 22px;
  background: linear-gradient(to top, #ea580c 0%, #f59e0b 45%, #fef08a 85%, #ffffff 100%);
  border-radius: 50% 50% 35% 35% / 70% 70% 30% 30%;
  box-shadow: 0 0 16px 5px rgba(245, 158, 11, 0.75), 0 0 32px 10px rgba(234, 88, 12, 0.4);
  animation: diyaFlameFlicker 1.4s infinite ease-in-out;
  transform-origin: bottom center;
}

.diya-flame-body::after {
  content: '';
  position: absolute;
  bottom: 2px;
  left: 50%;
  transform: translateX(-50%);
  width: 4px;
  height: 9px;
  background: #ffffff;
  border-radius: 50%;
  box-shadow: 0 0 6px #ffffff;
}

/* Brass Bowl */
.diya-brass-bowl {
  position: relative;
  width: 46px;
  height: 18px;
  background: linear-gradient(180deg, #d97706 0%, #92400e 55%, #78350f 100%);
  border-radius: 0 0 46px 46px;
  border: 1px solid rgba(251, 191, 36, 0.8);
  box-shadow: 0 6px 14px rgba(0, 0, 0, 0.6), inset 0 2px 4px rgba(254, 240, 138, 0.45);
  margin-top: -1px;
}

.diya-brass-bowl::before {
  content: '';
  position: absolute;
  top: -2px;
  left: 50%;
  transform: translateX(-50%);
  width: 48px;
  height: 5px;
  background: linear-gradient(90deg, #b45309, #fbbf24, #b45309);
  border-radius: 50%;
}

.diya-glow-mat {
  width: 60px;
  height: 14px;
  margin-top: 2px;
  background: radial-gradient(ellipse at center, rgba(245, 158, 11, 0.35) 0%, rgba(225, 29, 72, 0.18) 50%, transparent 75%);
  border-radius: 50%;
  filter: blur(2px);
}

/* ── 6. SUBTLE GOLD LIGHT SWEEP ON PRIMARY BUTTONS ── */
body.festive-theme .btn-primary {
  position: relative;
  overflow: hidden;
}

body.festive-theme .btn-primary::after {
  content: '';
  position: absolute;
  top: 0;
  left: -130%;
  width: 60%;
  height: 100%;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.35), transparent);
  transform: skewX(-22deg);
  animation: btnSweep 4.5s ease-in-out infinite 1.5s;
}

/* ── 7. RESTRAINED WEBSITE-WIDE FESTIVE HIGHLIGHTS ── */
/* Marquee Strip */
body.festive-theme .strip-dot {
  background: var(--dw-gold-3) !important;
  box-shadow: 0 0 8px var(--dw-gold-3) !important;
}

/* Section Labels */
body.festive-theme .section-label::before,
body.festive-theme .section-label::after {
  background: linear-gradient(90deg, var(--dw-gold-3), var(--dw-gold-4)) !important;
}

/* Service Cards: subtle dual-tone festive hover */
body.festive-theme .svc-card {
  transition: border-color 0.35s ease, box-shadow 0.35s ease, transform 0.35s ease;
}

body.festive-theme .svc-card:hover {
  border-color: rgba(245, 158, 11, 0.35) !important;
  box-shadow: 0 20px 48px -12px rgba(245, 158, 11, 0.16), 0 0 24px rgba(0, 98, 255, 0.12) !important;
}

body.festive-theme .svc-pill {
  border-color: rgba(245, 158, 11, 0.25) !important;
  background: rgba(245, 158, 11, 0.08) !important;
  color: var(--dw-gold-3) !important;
}

/* Why Us cards */
body.festive-theme .why-card:hover {
  border-color: rgba(245, 158, 11, 0.25) !important;
}

/* Review Cards: warm quote mark */
body.festive-theme .review-card:hover {
  border-color: rgba(245, 158, 11, 0.25) !important;
}

body.festive-theme .review-q {
  color: var(--dw-gold-3) !important;
  opacity: 0.22 !important;
}

/* CTA Section: subtle ambient warm radial */
body.festive-theme .cta-section {
  position: relative;
}

body.festive-theme .cta-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(ellipse 65% 55% at 50% 50%, rgba(245, 158, 11, 0.07) 0%, transparent 70%);
  pointer-events: none;
  z-index: 0;
}

body.festive-theme .cta-section > * {
  position: relative;
  z-index: 1;
}

/* Social Rail */
body.festive-theme .social-rail-wrap {
  border-color: rgba(245, 158, 11, 0.25) !important;
  box-shadow: 0 4px 20px rgba(245, 158, 11, 0.12) !important;
}

/* ── 8. KEYFRAME ANIMATIONS ── */
@keyframes goldShimmer {
  0% { background-position: -200% center; }
  100% { background-position: 200% center; }
}

@keyframes btnSweep {
  0% { left: -130%; }
  100% { left: 130%; }
}

@keyframes diyaFlameFlicker {
  0%   { transform: scale(1) rotate(-1deg); }
  25%  { transform: scale(1.06, 0.95) rotate(1.8deg); }
  50%  { transform: scale(0.96, 1.05) rotate(-1.5deg); }
  75%  { transform: scale(1.04, 0.98) rotate(1.2deg); }
  100% { transform: scale(1) rotate(-1deg); }
}

@keyframes diyaHaloPulse {
  0%, 100% { opacity: 0.65; transform: scale(0.96); }
  50%      { opacity: 1; transform: scale(1.18); }
}

@keyframes diyaGentleFloat {
  0%   { transform: translateY(0); }
  100% { transform: translateY(-8px); }
}

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

/* ── 9. RESPONSIVE DESIGN (MOBILE & TABLET) ── */
@media (max-width: 860px) {
  :root {
    --dw-banner-height: 42px;
  }
  .festive-announcement-inner {
    font-size: 11px;
    gap: 6px;
    padding-right: 20px;
  }
  .festive-hero-diya.diya-hero-left {
    left: 16px;
    bottom: 20px;
    transform: scale(0.72);
    transform-origin: bottom left;
  }
  .festive-hero-diya.diya-hero-right {
    right: 16px;
    bottom: 20px;
    transform: scale(0.72);
    transform-origin: bottom right;
  }
}

@media (max-width: 600px) {
  :root {
    --dw-banner-height: 46px;
  }
  .festive-announcement-inner {
    font-size: 10.5px;
  }
  .festive-hero-title {
    font-size: 20px;
  }
  .festive-diya-badge {
    font-size: 10px;
    padding: 5px 12px;
  }
  /* On very small phones, gently fade diyas to avoid covering stats */
  .festive-hero-diya {
    opacity: 0.65;
  }
}

/* ── 10. ACCESSIBILITY / PREFERS-REDUCED-MOTION ── */
@media (prefers-reduced-motion: reduce) {
  body.festive-theme *,
  body.festive-theme *::before,
  body.festive-theme *::after {
    animation-duration: 0.001ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.001ms !important;
  }
  #festiveHeroCanvas {
    display: none !important;
  }
}

/* ── 11. GLOBAL FIXED CEREMONIAL DIYA (ALL PAGES) ── */
.festive-global-diya {
  position: fixed;
  bottom: 22px;
  left: 24px;
  z-index: 998;
  display: flex;
  flex-direction: column;
  align-items: center;
  pointer-events: auto;
  cursor: pointer;
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
  filter: drop-shadow(0 4px 16px rgba(245, 158, 11, 0.3));
}

.festive-global-diya:hover {
  transform: scale(1.15) translateY(-3px);
}

@media (max-width: 768px) {
  .festive-global-diya {
    bottom: 16px;
    left: 16px;
    transform: scale(0.82);
    transform-origin: bottom left;
  }
}

/* ── 12. SPARKLE BURST PARTICLES (CLICK INTERACTION) ── */
.festive-spark-particle {
  position: fixed;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: radial-gradient(circle, #ffffff 0%, #fef08a 40%, #f59e0b 80%);
  box-shadow: 0 0 10px #f59e0b, 0 0 20px #fbbf24;
  pointer-events: none;
  z-index: 10000;
  animation: sparkBurst 0.65s cubic-bezier(0.16, 1, 0.3, 1) forwards;
}

@keyframes sparkBurst {
  0% {
    transform: translate(0, 0) scale(1);
    opacity: 1;
  }
  100% {
    transform: translate(var(--tx, 30px), var(--ty, 30px)) scale(0);
    opacity: 0;
  }
}

/* ── 13. INNER PAGE HEROES (SERVICES, ABOUT, PORTFOLIO, BLOG, CONTACT) ── */
body.festive-theme .page-hero {
  position: relative;
  background:
    radial-gradient(ellipse 70% 60% at 50% 0%, rgba(245, 158, 11, 0.12) 0%, transparent 68%),
    linear-gradient(180deg, rgba(255, 255, 255, 0.94) 0%, rgba(246, 249, 252, 1) 100%) !important;
  overflow: hidden;
}

body.festive-theme .page-hero h1 span,
body.festive-theme .wm-head h1 span,
body.festive-theme .cm-hero h1 span {
  background: linear-gradient(135deg, #f59e0b 0%, #d97706 50%, #b45309 100%);
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}

body.festive-theme .page-hero .label::before,
body.festive-theme .page-hero .label::after,
body.festive-theme .head .label::before,
body.festive-theme .head .label::after {
  background: linear-gradient(90deg, var(--dw-gold-3), var(--dw-gold-4)) !important;
}

.festive-page-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 5px 14px;
  border-radius: 100px;
  background: rgba(245, 158, 11, 0.10);
  border: 1px solid rgba(245, 158, 11, 0.28);
  font-family: var(--font-ui, "Plus Jakarta Sans", sans-serif);
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 1.5px;
  text-transform: uppercase;
  color: var(--dw-gold-4);
  margin-bottom: 12px;
  box-shadow: 0 4px 14px rgba(245, 158, 11, 0.1);
}

.festive-page-badge .badge-diya {
  font-size: 13px;
  filter: drop-shadow(0 0 4px #f59e0b);
}

.festive-page-badge .badge-sparkle {
  font-size: 11px;
  color: #f59e0b;
}

/* ── 14. ABOUT PAGE FESTIVE STYLING ── */
body.festive-theme .vision-manifesto {
  border-color: rgba(245, 158, 11, 0.28) !important;
  box-shadow: 0 16px 45px rgba(245, 158, 11, 0.08) !important;
}

body.festive-theme .vision-badge {
  background: rgba(245, 158, 11, 0.12) !important;
  border-color: rgba(245, 158, 11, 0.3) !important;
  color: var(--dw-gold-4) !important;
}

body.festive-theme .vision-card:hover {
  border-color: rgba(245, 158, 11, 0.35) !important;
  box-shadow: 0 16px 40px rgba(245, 158, 11, 0.1) !important;
}

body.festive-theme .vision-pill {
  background: rgba(245, 158, 11, 0.08) !important;
  border-color: rgba(245, 158, 11, 0.25) !important;
  color: var(--dw-gold-4) !important;
}

body.festive-theme .story-stat strong,
body.festive-theme .about-since-label {
  color: var(--dw-gold-4) !important;
}

body.festive-theme .team-card:hover {
  border-color: rgba(245, 158, 11, 0.3) !important;
}

/* ── 15. SERVICES PAGE & SERVICE DETAIL PAGES ── */
body.festive-theme .service-block:hover {
  border-color: rgba(245, 158, 11, 0.35) !important;
  box-shadow: 0 16px 45px rgba(245, 158, 11, 0.09) !important;
}

body.festive-theme .service-meta .pill {
  background: rgba(245, 158, 11, 0.1) !important;
  border-color: rgba(245, 158, 11, 0.28) !important;
  color: var(--dw-gold-4) !important;
}

body.festive-theme .service-meta .num {
  color: rgba(245, 158, 11, 0.35) !important;
}

body.festive-theme .svc-list li::before {
  background: var(--dw-gold-3) !important;
}

/* ── 16. PORTFOLIO PAGE ── */
body.festive-theme .wm-filter-btn.active {
  background: linear-gradient(135deg, var(--dw-gold-3), var(--dw-gold-4)) !important;
  border-color: transparent !important;
  color: #ffffff !important;
  box-shadow: 0 6px 18px rgba(245, 158, 11, 0.25) !important;
}

body.festive-theme .wm-card:hover {
  border-color: rgba(245, 158, 11, 0.35) !important;
  box-shadow: 0 16px 45px rgba(245, 158, 11, 0.12) !important;
}

body.festive-theme .wm-card-tag {
  background: rgba(245, 158, 11, 0.1) !important;
  border-color: rgba(245, 158, 11, 0.25) !important;
  color: var(--dw-gold-4) !important;
}

/* ── 17. CONTACT PAGE & FORM FIELDS (ALL PAGES) ── */
body.festive-theme .contact-form-box {
  border-color: rgba(245, 158, 11, 0.25) !important;
  box-shadow: 0 16px 45px rgba(245, 158, 11, 0.08) !important;
}

body.festive-theme .form-group input:focus,
body.festive-theme .form-group textarea:focus,
body.festive-theme .form-group select:focus,
body.festive-theme .form-field input:focus,
body.festive-theme .form-field textarea:focus {
  border-color: rgba(245, 158, 11, 0.55) !important;
  box-shadow: 0 0 0 3px rgba(245, 158, 11, 0.12) !important;
}

body.festive-theme .budget-btn.active {
  border-color: var(--dw-gold-3) !important;
  background: rgba(245, 158, 11, 0.12) !important;
  color: var(--dw-gold-4) !important;
}

body.festive-theme .contact-info-card:hover {
  border-color: rgba(245, 158, 11, 0.3) !important;
}

/* ── 18. BLOG PAGE ── */
body.festive-theme .bp-card:hover,
body.festive-theme .blog-card:hover {
  border-color: rgba(245, 158, 11, 0.32) !important;
  box-shadow: 0 16px 40px rgba(245, 158, 11, 0.1) !important;
}

body.festive-theme .bp-pill,
body.festive-theme .blog-tag {
  background: rgba(245, 158, 11, 0.1) !important;
  border-color: rgba(245, 158, 11, 0.25) !important;
  color: var(--dw-gold-4) !important;
}

/* ── 19. FOOTER FESTIVE ACCENTS (ALL PAGES) ── */
body.festive-theme footer {
  border-top-color: rgba(245, 158, 11, 0.18) !important;
}

body.festive-theme .footer-brand em {
  background: linear-gradient(135deg, var(--dw-gold-3), var(--dw-gold-4));
  -webkit-background-clip: text;
  background-clip: text;
  -webkit-text-fill-color: transparent;
}
