/* === VARIABLES & THEME === */
:root {
  --primary: #FF4B2B;        /* Fiery orange-red */
  --secondary: #1A1A2E;      /* Deep navy */
  --accent: #00C9A7;         /* Teal green */
  --bg-dark: #0F0F1A;
  --bg-card: #161625;
  --text-light: #F4F4F9;
  --text-muted: #A0A0B0;
  --white: #FFFFFF;
  --border-color: #2A2A40;
  
  --font-heading: 'Bebas Neue', sans-serif;
  --font-body: 'Inter', sans-serif;
  
  --radius: 12px;
  --transition: all 0.3s cubic-bezier(0.25, 0.8, 0.25, 1);
}

/* Light / Dark Mode Toggle (defaulting to dark based on guidelines) */
body.light-mode {
  --bg-dark: #F4F4F9;
  --bg-card: #FFFFFF;
  --text-light: #1A1A2E;
  --text-muted: #555566;
  --border-color: #E0E0E0;
}

/* === RESET & FOUNDATION === */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
}

body {
  font-family: var(--font-body);
  background-color: var(--bg-dark);
  color: var(--text-light);
  line-height: 1.6;
  overflow-x: hidden;
}

h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  letter-spacing: 1px;
  line-height: 1.2;
}

a {
  color: inherit;
  text-decoration: none;
}

ul {
  list-style: none;
}

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

/* === UTILITIES & ANIMATIONS === */
.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

.section-padding {
  padding: 80px 0;
}

.text-center { text-align: center; }
.text-primary { color: var(--primary); }
.text-accent { color: var(--accent); }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 12px 28px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 1rem;
  cursor: pointer;
  transition: var(--transition);
  border: none;
  text-transform: uppercase;
  font-family: var(--font-heading);
  letter-spacing: 1px;
}

.btn-primary {
  background: linear-gradient(135deg, #FF416C, var(--primary));
  color: var(--white);
  box-shadow: 0 4px 15px rgba(255, 75, 43, 0.3);
}

.btn-primary:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 25px rgba(255, 75, 43, 0.5);
}

.btn-outline {
  background: transparent;
  color: var(--primary);
  border: 2px solid var(--primary);
}

.btn-outline:hover {
  background: var(--primary);
  color: var(--white);
}

.btn-accent {
  background: var(--accent);
  color: var(--secondary);
}

.badge {
  padding: 4px 8px;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: bold;
  text-transform: uppercase;
}
.badge-sale {
  background: var(--primary);
  color: white;
}

/* Skeleton Loading Layer */
.skeleton {
  background: linear-gradient(90deg, var(--border-color) 25%, #3a3a50 50%, var(--border-color) 75%);
  background-size: 200% 100%;
  animation: loading 1.5s infinite;
}

@keyframes loading {
  0% { background-position: 200% 0; }
  100% { background-position: -200% 0; }
}

/* === HEADER & NAVIGATION === */
header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  background-color: rgba(26, 26, 46, 0.95);
  backdrop-filter: blur(10px);
  z-index: 1000;
  border-bottom: 1px solid var(--border-color);
  transition: var(--transition);
}

.top-bar {
  background-color: var(--primary);
  color: var(--white);
  font-size: 0.85rem;
  padding: 8px 0;
  text-align: center;
  font-weight: 500;
}

.nav-container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 15px 20px;
  max-width: 1200px;
  margin: 0 auto;
}

.logo {
  font-family: var(--font-heading);
  font-size: 2rem;
  color: var(--white);
  display: flex;
  align-items: center;
  gap: 8px;
}
.logo span {
  color: var(--primary);
}

.nav-links {
  display: flex;
  gap: 30px;
  align-items: center;
}

.nav-links a {
  font-weight: 500;
  font-size: 1rem;
  transition: var(--transition);
  position: relative;
}

.nav-links a:hover {
  color: var(--primary);
}

/* Mega Menu Dropdown */
.has-mega-menu:hover .mega-menu {
  opacity: 1;
  visibility: visible;
  top: 100%;
}

.mega-menu {
  position: absolute;
  top: 120%;
  left: 0;
  width: 100%;
  background: var(--bg-card);
  border-bottom: 2px solid var(--primary);
  padding: 30px;
  display: flex;
  gap: 40px;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
  box-shadow: 0 10px 30px rgba(0,0,0,0.5);
  z-index: 999;
}

.mega-column h4 {
  color: var(--accent);
  margin-bottom: 15px;
}
.mega-column ul li {
  margin-bottom: 10px;
}
.mega-column ul li a {
  color: var(--text-muted);
  font-weight: 400;
}
.mega-column ul li a:hover {
  color: var(--white);
}

.nav-icons {
  display: flex;
  gap: 20px;
  align-items: center;
}
.nav-icon {
  position: relative;
  cursor: pointer;
  font-size: 1.2rem;
}
.cart-count {
  position: absolute;
  top: -8px;
  right: -10px;
  background: var(--primary);
  color: white;
  font-size: 0.7rem;
  padding: 2px 6px;
  border-radius: 50%;
  font-weight: bold;
}

/* Mobile Menu Toggle */
.menu-toggle {
  display: none;
  font-size: 1.5rem;
  cursor: pointer;
}

/* === NOTIFICATION BAR (Social Proof) === */
.social-proof-toast {
  position: fixed;
  bottom: 20px;
  left: 20px;
  background: var(--bg-card);
  border-left: 4px solid var(--accent);
  padding: 15px;
  border-radius: var(--radius);
  box-shadow: 0 10px 25px rgba(0,0,0,0.5);
  display: flex;
  align-items: center;
  gap: 15px;
  transform: translateX(-150%);
  transition: transform 0.5s ease-out;
  z-index: 1001;
}
.social-proof-toast.show {
  transform: translateX(0);
}

/* === FOOTER === */
footer {
  background-color: var(--secondary);
  padding: 60px 0 20px;
  border-top: 1px solid var(--border-color);
}

.footer-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 40px;
  margin-bottom: 40px;
}

.footer-col h3 {
  color: var(--white);
  margin-bottom: 20px;
  font-size: 1.5rem;
}

.footer-col ul li {
  margin-bottom: 12px;
}
.footer-col ul li a {
  color: var(--text-muted);
  transition: var(--transition);
}
.footer-col ul li a:hover {
  color: var(--primary);
  padding-left: 5px;
}

.newsletter-form {
  display: flex;
  margin-top: 15px;
}
.newsletter-form input {
  padding: 12px;
  border: none;
  background: var(--bg-dark);
  color: white;
  border-radius: var(--radius) 0 0 var(--radius);
  outline: none;
  width: 100%;
}
.newsletter-form button {
  border-radius: 0 var(--radius) var(--radius) 0;
}

.social-icons {
  display: flex;
  gap: 15px;
  margin-top: 20px;
}
.social-icons a {
  display: inline-flex;
  width: 40px;
  height: 40px;
  background: var(--bg-dark);
  color: var(--white);
  align-items: center;
  justify-content: center;
  border-radius: 50%;
  transition: var(--transition);
}
.social-icons a:hover {
  background: var(--primary);
  transform: translateY(-3px);
}

.footer-bottom {
  text-align: center;
  padding-top: 20px;
  border-top: 1px solid var(--border-color);
  color: var(--text-muted);
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  align-items: center;
  gap: 15px;
}

.payment-icons {
  display: flex;
  gap: 10px;
  font-size: 1.5rem;
}

/* === BACK TO TOP === */
.back-to-top {
  position: fixed;
  bottom: 80px;
  right: 20px;
  background: var(--primary);
  color: white;
  width: 45px;
  height: 45px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
  z-index: 99;
  box-shadow: 0 4px 10px rgba(0,0,0,0.3);
}
.back-to-top.visible {
  opacity: 1;
  visibility: visible;
}
.back-to-top:hover {
  transform: translateY(-5px);
}

/* === CART DRAWER === */
.cart-drawer {
  position: fixed;
  top: 0;
  right: -400px;
  width: 100%;
  max-width: 400px;
  height: 100vh;
  background: var(--bg-card);
  z-index: 10000;
  box-shadow: -5px 0 25px rgba(0,0,0,0.5);
  transition: right 0.4s ease;
  display: flex;
  flex-direction: column;
}
.cart-drawer.open {
  right: 0;
}
.cart-header {
  padding: 20px;
  border-bottom: 1px solid var(--border-color);
  display: flex;
  justify-content: space-between;
  align-items: center;
}
.close-cart {
  cursor: pointer;
  font-size: 1.5rem;
}
.cart-body {
  padding: 20px;
  flex-grow: 1;
  overflow-y: auto;
}
.cart-footer {
  padding: 20px;
  border-top: 1px solid var(--border-color);
  background: var(--bg-dark);
}
.cart-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0,0,0,0.7);
  z-index: 9999;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
}
.cart-overlay.show {
  opacity: 1;
  visibility: visible;
}

/* === RESPONSIVE STYLES === */
@media (max-width: 992px) {
  .nav-links {
    display: none; /* Mobile menu override in JS */
  }
  .menu-toggle {
    display: block;
  }
  .mega-menu {
    display: none !important;
  }
  
  /* Bottom Nav for Mobile */
  .mobile-bottom-nav {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    background: var(--secondary);
    border-top: 1px solid var(--border-color);
    z-index: 1000;
    justify-content: space-around;
    padding: 10px 0;
  }
  .mobile-bottom-nav a {
    display: flex;
    flex-direction: column;
    align-items: center;
    font-size: 0.75rem;
    color: var(--text-muted);
    gap: 5px;
  }
  .mobile-bottom-nav a.active {
    color: var(--primary);
  }
  .mobile-bottom-nav a i {
    font-size: 1.2rem;
  }
}
@media (min-width: 993px) {
  .mobile-bottom-nav {
    display: none;
  }
}

/* === PRODUCT CARDS === */
.product-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  overflow: hidden;
  border: 1px solid var(--border-color);
  transition: var(--transition);
  position: relative;
  display: flex;
  flex-direction: column;
  height: 100%;
}
.product-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 25px rgba(0,0,0,0.4);
  border-color: var(--primary);
}
.product-image-wrap {
  position: relative;
  padding-top: 100%; /* 1:1 Aspect Ratio */
  background: var(--bg-dark);
  overflow: hidden;
}
.product-image-placeholder {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #232336;
  color: var(--text-muted);
  font-weight: bold;
}
.product-card:hover .quick-view {
  opacity: 1;
  bottom: 10px;
}
.quick-view {
  position: absolute;
  bottom: -40px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(255, 255, 255, 0.9);
  color: var(--secondary);
  padding: 8px 15px;
  border-radius: 20px;
  font-weight: 600;
  font-size: 0.85rem;
  opacity: 0;
  transition: all 0.3s;
  cursor: pointer;
  white-space: nowrap;
}
.quick-view:hover {
  background: var(--primary);
  color: white;
}
.product-details {
  padding: 20px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}
.product-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 5px;
  color: var(--text-light);
}
.product-rating {
  color: #FFC107;
  font-size: 0.9rem;
  margin-bottom: 10px;
}
.product-rating span {
  color: var(--text-muted);
  font-size: 0.8rem;
  margin-left: 5px;
}
.product-price {
  font-size: 1.2rem;
  font-weight: bold;
  color: var(--accent);
  margin-bottom: 15px;
  display: flex;
  align-items: center;
  gap: 10px;
}
.product-price del {
  color: var(--text-muted);
  font-size: 0.9rem;
  font-weight: normal;
}
.add-to-cart {
  margin-top: auto;
  width: 100%;
}

/* === MISC COMPONENTS === */
.section-header {
  text-align: center;
  margin-bottom: 50px;
}
.section-header h2 {
  font-size: 2.5rem;
  margin-bottom: 10px;
}
.section-header h2 span {
  color: var(--primary);
}
.section-header p {
  color: var(--text-muted);
  font-size: 1.1rem;
}

/* Exit-intent popup */
.exit-popup-overlay {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background: rgba(0,0,0,0.8);
  z-index: 100000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  visibility: hidden;
  transition: var(--transition);
}
.exit-popup-overlay.show {
  opacity: 1;
  visibility: visible;
}
.exit-popup {
  background: var(--bg-card);
  padding: 40px;
  border-radius: var(--radius);
  max-width: 500px;
  text-align: center;
  position: relative;
  transform: translateY(50px);
  transition: transform 0.4s ease;
  border: 2px solid var(--primary);
}
.exit-popup-overlay.show .exit-popup {
  transform: translateY(0);
}
.exit-close {
  position: absolute;
  top: 15px;
  right: 15px;
  cursor: pointer;
  font-size: 1.5rem;
}
