/* ==========================================================================
   KDK VIETNAM — LIGHT DECOR CSS v3.0
   Header: minimal. White section canvas handled by soundwave-canvas.js.
   This file only provides: dot grid bg, header minimal polish, card hover,
   content heading EQ bars, spec table, blockquote, sidebar accent.
   ========================================================================== */

/* ─────────────────────────────────────────────────────────────────────────
   1. GLOBAL — Subtle dot grid on all pages
   ───────────────────────────────────────────────────────────────────────── */
body::before {
  content: '';
  position: fixed;
  inset: 0;
  background-image: radial-gradient(circle, rgba(226,232,240,0.7) 1px, transparent 1px);
  background-size: 30px 30px;
  pointer-events: none;
  z-index: -1;
}

/* ─────────────────────────────────────────────────────────────────────────
   2. HEADER — Minimal. Just a thin animated red line under the nav.
   ───────────────────────────────────────────────────────────────────────── */
.nav-container {
  position: relative;
  background: rgba(255,255,255,0.97) !important;
  border-bottom: 1px solid rgba(237,27,36,0.08);
  box-shadow: 0 2px 12px rgba(0,0,0,0.05);
}

/* Single animated red frequency line — only animation in header */
.nav-container::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0;
  width: 100%; height: 2px;
  background: linear-gradient(
    90deg,
    transparent 0%, transparent 15%,
    rgba(237,27,36,0.6) 30%,
    #ed1b24 45%, #ff8a93 55%,
    rgba(237,27,36,0.6) 70%,
    transparent 85%, transparent 100%
  );
  background-size: 200% 100%;
  animation: navLineSweep 7s linear infinite;
  pointer-events: none;
  z-index: 10;
}
@keyframes navLineSweep {
  0%   { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* Remove any old header::after */
.header::after { display: none !important; }

/* Logo hover */
.logo img { transition: filter 0.3s ease, transform 0.3s ease; }
.logo:hover img {
  filter: drop-shadow(0 0 7px rgba(237,27,36,0.28));
  transform: scale(1.03);
}

/* Nav link hover underline (Desktop Only) */
@media (min-width: 992px) {
  .nav-link { position: relative; }
  .nav-link::before {
    content: '';
    position: absolute;
    bottom: -2px; left: 50%;
    transform: translateX(-50%) scaleX(0);
    width: 18px; height: 2.5px;
    background: #ed1b24; border-radius: 2px;
    transition: transform 0.3s cubic-bezier(0.16,1,0.3,1);
  }
  .nav-link:hover::before, .nav-link.active::before {
    transform: translateX(-50%) scaleX(1);
  }
}

@media (max-width: 991px) {
  .nav-link::before,
  .nav-link:hover::before,
  .nav-link.active::before,
  .nav-menu .nav-link::before,
  .nav-menu .nav-link:hover::before,
  .nav-menu .nav-link.active::before {
    display: none !important;
    content: none !important;
    transform: scale(0) !important;
    opacity: 0 !important;
  }
}
.nav-link::after { display: none !important; }

/* ─────────────────────────────────────────────────────────────────────────
   3. SECTION CANVAS HOST — Ensure sections can hold the canvas
   (Canvas is injected by soundwave-canvas.js initLightSectionDecor)
   ───────────────────────────────────────────────────────────────────────── */
.section {
  position: relative;
  overflow: hidden;
}
.section > .container {
  position: relative;
  z-index: 1;
}

/* ─────────────────────────────────────────────────────────────────────────
   4. CARDS — Audio equalizer bar on hover (bottom edge)
   ───────────────────────────────────────────────────────────────────────── */
.product-card,
.blog-card {
  position: relative;
  transition: transform 0.3s cubic-bezier(0.16,1,0.3,1), box-shadow 0.3s ease !important;
  will-change: transform, box-shadow;
}

/* EQ bar strip appears at card bottom on hover */
.product-card::after,
.blog-card::after {
  content: '';
  position: absolute;
  bottom: 0; left: 0; right: 0;
  height: 3px;
  border-radius: 0 0 var(--radius-md, 12px) var(--radius-md, 12px);
  background: linear-gradient(
    90deg,
    #ed1b24 0%, #ff8a93 12%, #ed1b24 24%,
    transparent 28%, transparent 36%,
    #ed1b24 38%, #ff8a93 50%, #ed1b24 62%,
    transparent 66%, transparent 74%,
    #ed1b24 76%, #ff8a93 88%, #ed1b24 100%
  );
  opacity: 0;
  transition: opacity 0.3s ease;
  pointer-events: none;
}
.product-card:hover::after,
.blog-card:hover::after { opacity: 1; }

.product-card:hover,
.blog-card:hover {
  transform: translateY(-5px) !important;
  box-shadow: 0 14px 36px -8px rgba(237,27,36,0.16), 0 2px 8px rgba(0,0,0,0.04) !important;
}
.solution-card:hover {
  transform: translateY(-4px) !important;
  box-shadow: 0 16px 40px -10px rgba(237,27,36,0.18) !important;
}

/* ─────────────────────────────────────────────────────────────────────────
   5. ARTICLE & PRODUCT DETAIL HEADINGS — Animated EQ bar
   ───────────────────────────────────────────────────────────────────────── */
.dp-entry-content h2,
.dp-entry-content h3,
.html-entry-content h2,
.html-entry-content h3,
.product-full-description h2,
.product-full-description h3 {
  position: relative;
  padding-left: 20px;
}
.dp-entry-content h2::before,
.dp-entry-content h3::before,
.html-entry-content h2::before,
.html-entry-content h3::before,
.product-full-description h2::before,
.product-full-description h3::before {
  content: '';
  position: absolute;
  left: 0; top: 10%;
  height: 80%; width: 4px;
  background: linear-gradient(to bottom, #ed1b24, #ff8a93);
  border-radius: 4px;
  animation: eqPulse 1.6s ease-in-out infinite alternate;
  transform-origin: center;
}
.dp-entry-content h3::before,
.html-entry-content h3::before,
.product-full-description h3::before {
  background: linear-gradient(to bottom, #ff8a93, #ed1b24);
  animation-delay: -0.8s;
}
@keyframes eqPulse {
  0%   { transform: scaleY(0.65); opacity: 0.75; }
  100% { transform: scaleY(1.05); opacity: 1; }
}

/* ─────────────────────────────────────────────────────────────────────────
   6. BLOCKQUOTE — Audio caption style
   ───────────────────────────────────────────────────────────────────────── */
.dp-entry-content blockquote,
.html-entry-content blockquote {
  border-left: 4px solid #ed1b24;
  background: linear-gradient(to right, rgba(237,27,36,0.04), transparent);
  padding: 16px 20px;
  border-radius: 0 8px 8px 0;
  font-style: italic;
  color: var(--text-body);
  margin: 24px 0;
}

/* ─────────────────────────────────────────────────────────────────────────
   7. SPEC TABLE — Dark header row (audio panel feel)
   ───────────────────────────────────────────────────────────────────────── */
.dp-spec-table th {
  background: linear-gradient(135deg, #0b0d12, #1a1f2c) !important;
  letter-spacing: 0.5px;
}
.dp-spec-table tr:hover td { background: rgba(237,27,36,0.03) !important; }

/* ─────────────────────────────────────────────────────────────────────────
   8. SIDEBAR — Red top accent border
   ───────────────────────────────────────────────────────────────────────── */
.dp-sidebar .card-box { border-top: 3px solid #ed1b24 !important; }
