/*
Theme Name: Battery World Theme
Theme URI: https://exidecare.in
Author: Battery World, Wagholi
Author URI: https://exidecare.in
Description: Animated power solutions theme with a full-screen video hero, liquid glass UI and Inter typography. Elementor compatible. Editable from Appearance > Customize.
Version: 1.1.0
Requires at least: 6.0
Tested up to: 6.7
Requires PHP: 7.4
License: GNU General Public License v2 or later
License URI: https://www.gnu.org/licenses/gpl-2.0.html
Text Domain: battery-world
Tags: one-page, video, dark, custom-colors, custom-menu, full-width-template, threaded-comments
*/

/* =========================================================
   1. BASE  (applies site-wide, including Elementor pages)
   ========================================================= */

html { scroll-behavior: smooth; }

body {
  margin: 0;
  font-family: 'Inter', sans-serif;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  background: #000;
  color: #fff;
  line-height: 1.6;
}

img { max-width: 100%; height: auto; }

a { color: inherit; }

/* =========================================================
   2. SITE CHROME for inner / Elementor pages
   Plain CSS on purpose - Tailwind is NOT loaded on these
   pages so it cannot reset or fight Elementor styles.
   ========================================================= */

.bw-bar {
  position: sticky;
  top: 0;
  z-index: 100;
  padding: 16px 24px;
  background: rgba(0, 0, 0, 0.85);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.bw-bar__inner {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  flex-wrap: wrap;
}

.bw-logo {
  font-size: 1.4rem;
  font-weight: 600;
  letter-spacing: -0.02em;
  text-decoration: none;
  color: #fff;
}

.bw-nav ul {
  display: flex;
  align-items: center;
  gap: 28px;
  list-style: none;
  margin: 0;
  padding: 0;
}

.bw-nav a {
  font-size: 0.9rem;
  text-decoration: none;
  color: #d1d5db;
  transition: color 0.2s;
}

.bw-nav a:hover { color: #fff; }

.bw-btn {
  display: inline-block;
  background: #fff;
  color: #000;
  padding: 9px 22px;
  border-radius: 8px;
  font-size: 0.88rem;
  font-weight: 500;
  text-decoration: none;
  transition: background 0.2s;
}

.bw-btn:hover { background: #e5e7eb; color: #000; }

.bw-footer {
  padding: 40px 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.bw-footer__inner {
  max-width: 1280px;
  margin: 0 auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  flex-wrap: wrap;
  font-size: 0.85rem;
  color: #9ca3af;
}

.bw-footer a { text-decoration: none; color: #9ca3af; transition: color 0.2s; }
.bw-footer a:hover { color: #fff; }

/* Content wrapper for normal posts / pages.
   Elementor Canvas + Full Width templates bypass this entirely. */
.bw-page {
  max-width: 900px;
  margin: 0 auto;
  padding: 64px 24px 96px;
}

.bw-page__title {
  font-size: clamp(2rem, 5vw, 3rem);
  font-weight: 400;
  letter-spacing: -0.03em;
  margin: 0 0 28px;
}

.bw-page a { color: #fff; }

.bw-page h2, .bw-page h3, .bw-page h4 {
  font-weight: 500;
  letter-spacing: -0.02em;
  margin: 40px 0 12px;
}

.bw-meta {
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.15em;
  color: #9ca3af;
  margin-bottom: 12px;
}

.bw-entry { margin-bottom: 56px; }

/* =========================================================
   3. ANIMATED DESIGN  (homepage template only)
   ========================================================= */

.liquid-glass {
  background: rgba(0, 0, 0, 0.4);
  background-blend-mode: luminosity;
  backdrop-filter: blur(4px);
  -webkit-backdrop-filter: blur(4px);
  border: none;
  box-shadow: inset 0 1px 1px rgba(255, 255, 255, 0.1);
  position: relative;
  overflow: hidden;
}
.liquid-glass::before {
  content: '';
  position: absolute;
  inset: 0;
  border-radius: inherit;
  padding: 1.4px;
  background: linear-gradient(180deg,
    rgba(255,255,255,0.3) 0%, rgba(255,255,255,0.1) 20%,
    rgba(255,255,255,0) 40%, rgba(255,255,255,0) 60%,
    rgba(255,255,255,0.1) 80%, rgba(255,255,255,0.3) 100%);
  -webkit-mask: linear-gradient(#fff 0 0) content-box, linear-gradient(#fff 0 0);
  -webkit-mask-composite: xor;
  mask-composite: exclude;
  pointer-events: none;
}

.anim-char {
  display: inline-block;
  opacity: 0;
  transform: translateX(-18px);
  transition: opacity 500ms ease, transform 500ms ease;
}
.anim-char.in {
  opacity: 1;
  transform: translateX(0);
}

.fade-init {
  opacity: 0;
  transition-property: opacity;
  transition-timing-function: ease;
}
.fade-init.in { opacity: 1; }

.reveal {
  opacity: 0;
  transform: translateY(24px);
  transition: opacity 0.8s ease, transform 0.8s ease;
}
.reveal.in { opacity: 1; transform: translateY(0); }

.ticker-inner {
  display: inline-flex;
  white-space: nowrap;
  animation: ticker 30s linear infinite;
}
@keyframes ticker {
  from { transform: translateX(0); }
  to { transform: translateX(-50%); }
}

.glass-card { transition: transform 0.3s ease, box-shadow 0.3s ease; }
.glass-card:hover { transform: translateY(-4px); }

/* WordPress admin bar offset */
body.admin-bar .bw-hero { height: calc(100vh - 32px); }

/* Respect reduced-motion preferences */
@media (prefers-reduced-motion: reduce) {
  .anim-char, .fade-init, .reveal { transition: none !important; opacity: 1 !important; transform: none !important; }
  .ticker-inner { animation: none; }
}
