/* ============================================================
   AutoChineLux — Custom Styles
   Design tokens, components, dark mode, animations, responsive
   ============================================================ */

/* ---- Reset & Base ---- */
*,
*::before,
*::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Inter', sans-serif;
  color: var(--text-primary);
  background-color: var(--bg-primary);
  transition: background-color 0.3s ease, color 0.3s ease;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

a {
  color: var(--accent);
  text-decoration: none;
  transition: color var(--transition-base);
}

a:hover {
  color: var(--accent-hover);
}

/* ---- Design Tokens (Light mode default) ---- */
:root {
  --accent: #00d4aa;
  --accent-rgb: 0, 212, 170;
  --accent-hover: #00b894;
  --accent-light: rgba(0, 212, 170, 0.1);
  --accent-gradient: linear-gradient(135deg, #00d4aa 0%, #00b894 100%);

  --bg-primary: #ffffff;
  --bg-primary-rgb: 255, 255, 255;
  --bg-secondary: #f8f9fa;
  --bg-secondary-rgb: 248, 249, 250;
  --bg-card: #ffffff;
  --bg-surface: #f1f3f5;
  --bg-navbar: #ffffff;
  --text-primary: #1a1a2e;
  --text-secondary: #6c757d;
  --text-muted: #adb5bd;
  --border-color: #dee2e6;
  --border-light: #e9ecef;
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.08);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.1);
  --shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.12);
  --shadow-xl: 0 20px 60px rgba(0, 0, 0, 0.15);

  --font-heading: 'Space Grotesk', sans-serif;
  --font-body: 'Inter', sans-serif;
  --font-mono: 'JetBrains Mono', 'Fira Code', monospace;

  --radius-sm: 6px;
  --radius: 12px;
  --radius-lg: 20px;
  --radius-xl: 28px;
  --radius-full: 9999px;

  --navbar-height: 76px;
  --navbar-scrolled-shadow: 0 4px 20px rgba(0, 0, 0, 0.08);

  --transition-fast: 0.15s ease;
  --transition-base: 0.3s ease;
  --transition-slow: 0.5s ease;
}

/* ---- Dark Mode ---- */
[data-bs-theme="dark"] {
  --bg-primary: #0f0f1a;
  --bg-primary-rgb: 15, 15, 26;
  --bg-secondary: #1a1a2e;
  --bg-secondary-rgb: 26, 26, 46;
  --bg-card: #16213e;
  --bg-surface: #1a1a2e;
  --bg-navbar: #0f0f1a;
  --text-primary: #e8e8e8;
  --text-secondary: #a0a0b0;
  --text-muted: #6c757d;
  --border-color: #2a2a4a;
  --border-light: #1e1e36;
  --shadow-sm: 0 1px 3px rgba(0, 0, 0, 0.3);
  --shadow-md: 0 4px 12px rgba(0, 0, 0, 0.4);
  --shadow-lg: 0 8px 30px rgba(0, 0, 0, 0.5);
  --shadow-xl: 0 20px 60px rgba(0, 0, 0, 0.6);
}

/* ---- Typography ---- */
h1, h2, h3, h4, h5, h6 {
  font-family: var(--font-heading);
  font-weight: 700;
  line-height: 1.2;
  color: var(--text-primary);
}

.display-1, .display-2, .display-3, .display-4, .display-5, .display-6 {
  font-family: var(--font-heading);
}

.text-accent { color: var(--accent); }
.bg-accent { background: var(--accent-gradient); }
.border-accent { border-color: var(--accent); }

/* ---- Utility Classes ---- */
.btn-accent {
  background: var(--accent-gradient);
  color: #fff;
  border: none;
  padding: 0.625rem 1.5rem;
  border-radius: var(--radius-full);
  font-weight: 600;
  transition: all var(--transition-base);
}

.btn-accent:hover {
  background: var(--accent-hover);
  color: #fff;
  transform: translateY(-2px);
  box-shadow: var(--shadow-md);
}

.btn-accent:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.btn-accent-outline {
  border: 2px solid var(--accent);
  color: var(--accent);
  background: transparent;
  padding: 0.625rem 1.5rem;
  border-radius: var(--radius-full);
  font-weight: 600;
  transition: all var(--transition-base);
}

.btn-accent-outline:hover {
  background: var(--accent);
  color: #fff;
  transform: translateY(-2px);
}

.btn-accent-outline:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

.btn-ghost {
  background: transparent;
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  padding: 0.625rem 1.5rem;
  border-radius: var(--radius-full);
  font-weight: 500;
  transition: all var(--transition-base);
}

.btn-ghost:hover {
  background: var(--bg-surface);
  border-color: var(--text-muted);
}

.section-badge {
  display: inline-block;
  padding: 0.25rem 1rem;
  border-radius: var(--radius-full);
  background: var(--accent-light);
  color: var(--accent);
  font-size: 0.875rem;
  font-weight: 600;
  letter-spacing: 0.02em;
  margin-bottom: 1rem;
}

.glass-card {
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border: 1px solid rgba(255, 255, 255, 0.2);
}

[data-bs-theme="dark"] .glass-card {
  background: rgba(22, 33, 62, 0.7);
  border: 1px solid rgba(255, 255, 255, 0.05);
}

.section-padding {
  padding: 5rem 0;
}

@media (min-width: 992px) {
  .section-padding {
    padding: 6rem 0;
  }
}

/* ---- Navbar ---- */
.site-header {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  z-index: 1030;
  height: var(--navbar-height);
  transition: all var(--transition-base);
  background: var(--bg-navbar);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  box-shadow: var(--shadow-sm);
}

.site-header.scrolled {
  height: 60px;
  box-shadow: var(--navbar-scrolled-shadow);
}

/* Homepage: fully opaque solid navbar for maximum readability over hero slider */
.site-header.homepage {
  background: var(--bg-primary);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  box-shadow: var(--navbar-scrolled-shadow);
  z-index: 1040;
  border-bottom: 1px solid var(--border-light);
}

[data-bs-theme="dark"] .site-header.homepage {
  background: var(--bg-primary);
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.35);
  border-bottom: 1px solid var(--border-color);
}

.site-header .navbar {
  height: 100%;
  padding-top: 0;
  padding-bottom: 0;
}

.site-header .navbar-brand img {
  height: 36px;
  transition: height var(--transition-base);
}

.site-header.scrolled .navbar-brand img {
  height: 32px;
}

.nav-link {
  font-weight: 500;
  color: var(--text-primary) !important;
  padding: 0.5rem 1rem !important;
  transition: color var(--transition-fast);
  position: relative;
}

.nav-link::after {
  content: '';
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%) scaleX(0);
  width: 60%;
  height: 2px;
  background: var(--accent);
  transition: transform var(--transition-base);
}

.nav-link:hover::after,
.nav-link.active::after {
  transform: translateX(-50%) scaleX(1);
}

.nav-link.active {
  color: var(--accent) !important;
}

.navbar-toggler {
  border: none;
  padding: 0.5rem;
  color: var(--text-primary);
}

.navbar-toggler:focus {
  box-shadow: none;
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* ---- Hero Slider ---- */
.hero-slider {
  position: relative;
  width: 100%;
  height: 100vh;
  min-height: 600px;
  overflow: hidden;
}

.hero-slide {
  position: absolute;
  inset: 0;
  opacity: 0;
  transition: opacity 0.6s ease, transform 0.6s ease;
  transform: scale(1.05);
  z-index: 0;
}

.hero-slide.active {
  opacity: 1;
  transform: scale(1);
  z-index: 1;
}

.hero-slide-bg {
  position: absolute;
  inset: 0;
  background-size: cover;
  background-position: center;
}

.hero-slide-bg::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(15, 15, 26, 0.7) 0%, rgba(15, 15, 26, 0.3) 50%, rgba(0, 0, 0, 0.1) 100%);
}

.hero-slide-content {
  position: relative;
  z-index: 2;
  height: 100%;
  display: flex;
  align-items: center;
}

.hero-slide-content .container {
  padding-top: var(--navbar-height);
}

.hero-badges {
  position: absolute;
  bottom: 2rem;
  left: 0;
  right: 0;
  z-index: 2;
}

.hero-badge-item {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: rgba(255, 255, 255, 0.1);
  backdrop-filter: blur(10px);
  border-radius: var(--radius-full);
  color: #fff;
  font-size: 0.875rem;
  font-weight: 500;
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.hero-slider-controls {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  z-index: 2;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.15);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255, 255, 255, 0.2);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-base);
}

.hero-slider-controls:hover {
  background: var(--accent);
  border-color: var(--accent);
}

.hero-slider-controls.prev { left: 1.5rem; }
.hero-slider-controls.next { right: 1.5rem; }

.hero-dots {
  position: absolute;
  bottom: 6rem;
  left: 0;
  right: 0;
  z-index: 2;
  display: flex;
  justify-content: center;
  gap: 0.5rem;
}

.hero-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.4);
  cursor: pointer;
  transition: all var(--transition-base);
  border: none;
  padding: 0;
}

.hero-dot.active {
  background: var(--accent);
  width: 28px;
  border-radius: 5px;
}

.hero-dot:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* ---- Product Card ---- */
.product-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  border: 1px solid var(--border-light);
  overflow: hidden;
  transition: all var(--transition-base);
  height: 100%;
  display: flex;
  flex-direction: column;
  will-change: transform;
}

.product-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: rgba(0, 212, 170, 0.3);
}

.product-card-image {
  position: relative;
  aspect-ratio: 16/9;
  overflow: hidden;
  background: var(--bg-surface);
}

.product-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.product-card:hover .product-card-image img {
  transform: scale(1.05);
}

.product-card-badge {
  position: absolute;
  top: 0.75rem;
  left: 0.75rem;
  padding: 0.25rem 0.75rem;
  border-radius: var(--radius-full);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.03em;
}

.product-card-badge.new {
  background: var(--accent);
  color: #fff;
}

.product-card-badge.used {
  background: #fd7e14;
  color: #fff;
}

.product-card-body {
  padding: 1.25rem;
  flex: 1;
  display: flex;
  flex-direction: column;
}

.product-card-brand {
  font-size: 0.8rem;
  color: var(--text-secondary);
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.product-card-title {
  font-size: 1.1rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  font-family: var(--font-heading);
}

.product-card-price {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--text-primary);
  margin-bottom: 0.25rem;
}

.product-card-price .price-old {
  font-size: 1rem;
  font-weight: 400;
  color: var(--text-muted);
  text-decoration: line-through;
  margin-left: 0.5rem;
}

.product-card-specs {
  display: flex;
  gap: 1rem;
  margin-top: auto;
  padding-top: 0.75rem;
  border-top: 1px solid var(--border-light);
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.product-card-specs span {
  display: flex;
  align-items: center;
  gap: 0.3rem;
}

.product-card-rating {
  font-size: 0.85rem;
  color: #ffc107;
  margin-bottom: 0.5rem;
}

.product-card-rating .rating-count {
  color: var(--text-muted);
  margin-left: 0.25rem;
}

/* ---- Brand Card ---- */
.brand-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  border: 1px solid var(--border-light);
  padding: 2rem;
  text-align: center;
  transition: all var(--transition-base);
  height: 100%;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  will-change: transform;
  cursor: pointer;
}

.brand-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
  border-color: var(--accent);
}

.brand-card img {
  height: 60px;
  object-fit: contain;
  margin-bottom: 1rem;
  filter: grayscale(0);
  transition: all var(--transition-base);
}

.brand-card:hover img {
  filter: grayscale(0);
  transform: scale(1.1);
}

.brand-card-title {
  font-size: 1.25rem;
  font-weight: 700;
  font-family: var(--font-heading);
  margin-bottom: 0.25rem;
}

.brand-card-meta {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

/* ---- Testimonial Card ---- */
.testimonial-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  border: 1px solid var(--border-light);
  padding: 2rem;
  text-align: center;
  height: 100%;
}

.testimonial-card .avatar {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  object-fit: cover;
  margin-bottom: 1rem;
  border: 3px solid var(--accent-light);
}

.testimonial-card .name {
  font-weight: 700;
  font-size: 1rem;
  margin-bottom: 0.25rem;
}

.testimonial-card .location {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 0.75rem;
}

.testimonial-card .stars {
  color: #ffc107;
  margin-bottom: 0.75rem;
}

.testimonial-card .quote {
  font-style: italic;
  color: var(--text-secondary);
  line-height: 1.6;
  font-size: 0.95rem;
}

/* ---- Section: Why Us ---- */
.why-card {
  text-align: center;
  padding: 2rem;
  border-radius: var(--radius);
  transition: all var(--transition-base);
  height: 100%;
}

.why-card:hover {
  background: var(--bg-card);
  box-shadow: var(--shadow-md);
}

.why-card .icon-wrapper {
  width: 64px;
  height: 64px;
  border-radius: var(--radius);
  background: var(--accent-light);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1.25rem;
  font-size: 1.5rem;
  color: var(--accent);
}

.why-card h4 {
  font-size: 1.1rem;
  margin-bottom: 0.75rem;
}

.why-card p {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ---- Newsletter ---- */
.newsletter-section {
  background: var(--accent-gradient);
  padding: 4rem 0;
  position: relative;
  overflow: hidden;
}

.newsletter-section::before {
  content: '';
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 30% 50%, rgba(255,255,255,0.1) 0%, transparent 50%);
}

.newsletter-section .container {
  position: relative;
  z-index: 1;
}

.newsletter-section h2 {
  color: #fff;
}

.newsletter-section p {
  color: rgba(255, 255, 255, 0.85);
}

.newsletter-section .form-control {
  border-radius: var(--radius-full);
  padding: 0.75rem 1.25rem;
  border: 2px solid transparent;
}

.newsletter-section .form-control:focus {
  border-color: #fff;
  box-shadow: none;
}

/* ---- Footer ---- */
.site-footer {
  background: var(--bg-secondary);
  border-top: 1px solid var(--border-color);
  padding: 4rem 0 0;
}

.site-footer h5 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 1.25rem;
  font-family: var(--font-heading);
}

.site-footer a {
  color: var(--text-secondary);
  font-size: 0.9rem;
  transition: color var(--transition-fast);
  display: inline-block;
  padding: 0.15rem 0;
}

.site-footer a:hover {
  color: var(--accent);
}

.site-footer .social-links a {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  background: var(--bg-surface);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  color: var(--text-primary);
  margin-right: 0.5rem;
  transition: all var(--transition-base);
}

.site-footer .social-links a:hover {
  background: var(--accent);
  color: #fff;
  transform: translateY(-2px);
}

.footer-bottom {
  border-top: 1px solid var(--border-color);
  padding: 1.5rem 0;
  margin-top: 3rem;
  font-size: 0.85rem;
  color: var(--text-muted);
}

/* ---- Catalog Filters Sidebar ---- */
.filter-sidebar {
  position: sticky;
  top: calc(var(--navbar-height) + 1rem);
}

.filter-sidebar .card {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius);
}

.filter-section {
  margin-bottom: 1.5rem;
}

.filter-section:last-child {
  margin-bottom: 0;
}

.filter-section-title {
  font-size: 0.85rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--text-primary);
  margin-bottom: 0.75rem;
}

.filter-checkbox label {
  font-size: 0.9rem;
  color: var(--text-primary);
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.25rem 0;
}

.filter-checkbox input[type="checkbox"],
.filter-checkbox input[type="radio"] {
  accent-color: var(--accent);
}

/* Range Slider Custom */
.price-range-values {
  display: flex;
  justify-content: space-between;
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-top: 0.5rem;
}

.form-range::-webkit-slider-thumb {
  background: var(--accent);
}

.form-range::-moz-range-thumb {
  background: var(--accent);
}

/* ---- Product Detail ---- */
.product-gallery-main {
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-surface);
  aspect-ratio: 16/10;
  position: relative;
}

.product-gallery-main img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.product-thumbnails {
  display: flex;
  gap: 0.5rem;
  margin-top: 0.75rem;
}

.product-thumbnail {
  width: 80px;
  height: 60px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  cursor: pointer;
  border: 2px solid transparent;
  transition: all var(--transition-fast);
  flex-shrink: 0;
}

.product-thumbnail:hover,
.product-thumbnail.active {
  border-color: var(--accent);
}

.product-thumbnail img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.specs-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.75rem;
}

.spec-item {
  background: var(--bg-surface);
  border-radius: var(--radius-sm);
  padding: 0.75rem 1rem;
}

.spec-item-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.03em;
  font-weight: 600;
  margin-bottom: 0.15rem;
}

.spec-item-value {
  font-size: 1rem;
  font-weight: 600;
  color: var(--text-primary);
}

/* ---- Blog Card ---- */
.blog-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  border: 1px solid var(--border-light);
  overflow: hidden;
  transition: all var(--transition-base);
  height: 100%;
}

.blog-card:hover {
  transform: translateY(-4px);
  box-shadow: var(--shadow-lg);
}

.blog-card-image {
  aspect-ratio: 16/9;
  overflow: hidden;
}

.blog-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.5s ease;
}

.blog-card:hover .blog-card-image img {
  transform: scale(1.05);
}

.blog-card-body {
  padding: 1.5rem;
}

.blog-card-meta {
  font-size: 0.8rem;
  color: var(--text-secondary);
  display: flex;
  gap: 0.75rem;
  margin-bottom: 0.5rem;
}

.blog-card-category {
  display: inline-block;
  padding: 0.15rem 0.75rem;
  border-radius: var(--radius-full);
  background: var(--accent-light);
  color: var(--accent);
  font-size: 0.75rem;
  font-weight: 600;
}

.blog-card-title {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  font-family: var(--font-heading);
}

.blog-card-title a {
  color: var(--text-primary);
}

.blog-card-title a:hover {
  color: var(--accent);
}

.blog-card-excerpt {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.6;
}

/* ---- FAQ ---- */
.faq-category-tabs {
  border-bottom: 2px solid var(--border-color);
  margin-bottom: 2rem;
}

.faq-category-tabs .nav-link {
  color: var(--text-secondary);
  font-weight: 600;
  border: none;
  padding: 0.75rem 1.25rem;
  position: relative;
  background: transparent !important;
}

.faq-category-tabs .nav-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  right: 0;
  height: 2px;
  background: transparent;
}

.faq-category-tabs .nav-link.active {
  color: var(--accent);
}

.faq-category-tabs .nav-link.active::after {
  background: var(--accent);
}

.accordion-item {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: var(--radius-sm) !important;
  margin-bottom: 0.5rem;
}

.accordion-button {
  background: var(--bg-card);
  color: var(--text-primary);
  font-weight: 600;
  font-size: 0.95rem;
  box-shadow: none !important;
  border-radius: var(--radius-sm) !important;
}

.accordion-button:not(.collapsed) {
  color: var(--accent);
  background: var(--bg-card);
}

.accordion-button::after {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%236c757d' viewBox='0 0 16 16'%3E%3Cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3E%3C/svg%3E");
}

.accordion-button:not(.collapsed)::after {
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' fill='%2300d4aa' viewBox='0 0 16 16'%3E%3Cpath fill-rule='evenodd' d='M1.646 4.646a.5.5 0 0 1 .708 0L8 10.293l5.646-5.647a.5.5 0 0 1 .708.708l-6 6a.5.5 0 0 1-.708 0l-6-6a.5.5 0 0 1 0-.708z'/%3E%3C/svg%3E");
}

.accordion-body {
  color: var(--text-secondary);
  font-size: 0.9rem;
  line-height: 1.6;
}

/* ---- Contact Form ---- */
.contact-form .form-control,
.contact-form .form-select {
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
  padding: 0.625rem 1rem;
  background: var(--bg-card);
  color: var(--text-primary);
  transition: border-color var(--transition-fast);
}

.contact-form .form-control:focus,
.contact-form .form-select:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px var(--accent-light);
}

.contact-form .form-control.is-valid,
.contact-form .form-select.is-valid {
  border-color: #198754;
}

.contact-form .form-control.is-invalid,
.contact-form .form-select.is-invalid {
  border-color: #dc3545;
}

.contact-info-item {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.5rem;
}

.contact-info-item .icon {
  width: 44px;
  height: 44px;
  border-radius: var(--radius);
  background: var(--accent-light);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
  flex-shrink: 0;
}

.contact-info-item h6 {
  font-size: 0.9rem;
  font-weight: 700;
  margin-bottom: 0.15rem;
}

.contact-info-item p {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 0;
}

/* ---- Back to Top ---- */
#back-to-top {
  position: fixed;
  bottom: 2rem;
  right: 2rem;
  z-index: 1040;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  background: var(--accent-gradient);
  color: #fff;
  border: none;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  opacity: 0;
  visibility: hidden;
  transform: translateY(20px);
  transition: all var(--transition-base);
  box-shadow: var(--shadow-md);
}

#back-to-top.visible {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

#back-to-top:hover {
  transform: translateY(-3px);
  box-shadow: var(--shadow-lg);
}

#back-to-top:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 4px;
}

/* ---- Animations ---- */
.animate-fade-in,
.animate-slide-up,
.animate-slide-left,
.animate-slide-right,
.animate-scale-in {
  opacity: 0;
  transition: opacity 0.6s ease, transform 0.6s ease;
}

.animate-slide-up { transform: translateY(30px); }
.animate-slide-left { transform: translateX(-30px); }
.animate-slide-right { transform: translateX(30px); }
.animate-scale-in { transform: scale(0.95); }

.animate-fade-in.visible,
.animate-slide-up.visible,
.animate-slide-left.visible,
.animate-slide-right.visible,
.animate-scale-in.visible {
  opacity: 1;
  transform: translate(0, 0) scale(1);
}

.animate-stagger > * {
  opacity: 0;
  transform: translateY(20px);
  transition: opacity 0.5s ease, transform 0.5s ease;
}

.animate-stagger.visible > *:nth-child(1) { transition-delay: 0s; }
.animate-stagger.visible > *:nth-child(2) { transition-delay: 0.1s; }
.animate-stagger.visible > *:nth-child(3) { transition-delay: 0.2s; }
.animate-stagger.visible > *:nth-child(4) { transition-delay: 0.3s; }
.animate-stagger.visible > *:nth-child(5) { transition-delay: 0.4s; }
.animate-stagger.visible > *:nth-child(6) { transition-delay: 0.5s; }

.animate-stagger.visible > * {
  opacity: 1;
  transform: translateY(0);
}

/* ---- Lazy Loading Images ---- */
img[data-src] {
  background: var(--bg-surface);
  min-height: 100px;
  transition: opacity 0.4s ease;
  opacity: 0.4;
}

img[data-src].loaded {
  opacity: 1;
}

/* ---- Stats Counter ---- */
.stat-counter {
  font-size: 2.5rem;
  font-weight: 700;
  color: var(--accent);
  font-family: var(--font-heading);
  line-height: 1;
  margin-bottom: 0.25rem;
}

.stat-label {
  font-size: 0.9rem;
  color: var(--text-secondary);
  font-weight: 500;
}

/* ---- Breadcrumb ---- */
.breadcrumb {
  background: transparent;
  padding: 0.75rem 0;
  margin-bottom: 0;
}

.breadcrumb-item a {
  color: var(--text-secondary);
}

.breadcrumb-item.active {
  color: var(--text-primary);
}

.breadcrumb-item + .breadcrumb-item::before {
  color: var(--text-muted);
}

/* ---- Offcanvas Mobile Filters ---- */
.offcanvas {
  background: var(--bg-primary);
}

.offcanvas-header {
  border-bottom: 1px solid var(--border-color);
}

/* ---- Page Header ---- */
.page-header {
  padding: calc(var(--navbar-height) + 2rem) 0 2rem;
  background: var(--bg-secondary);
}

[data-bs-theme="dark"] .page-header {
  background: var(--bg-secondary);
}

/* ---- Legal Tabs ---- */
.legal-tabs .nav-link {
  color: var(--text-secondary);
  font-weight: 600;
  border: 1px solid var(--border-color);
  border-bottom: none;
  background: var(--bg-secondary);
}

.legal-tabs .nav-link.active {
  color: var(--accent);
  background: var(--bg-primary);
  border-color: var(--border-color);
  border-bottom-color: var(--bg-primary);
}

/* ---- Search Bar ---- */
.search-bar {
  position: relative;
}

.search-bar .search-toggle {
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 1.1rem;
  cursor: pointer;
  padding: 0.5rem;
}

.search-bar .search-input {
  position: absolute;
  top: 100%;
  right: 0;
  width: 280px;
  padding: 0.75rem 1rem;
  border-radius: var(--radius);
  border: 1px solid var(--border-color);
  background: var(--bg-card);
  box-shadow: var(--shadow-lg);
  opacity: 0;
  visibility: hidden;
  transform: translateY(10px);
  transition: all var(--transition-base);
  z-index: 1050;
}

.search-bar .search-input.open {
  opacity: 1;
  visibility: visible;
  transform: translateY(0);
}

/* ---- Language Switcher ---- */
.lang-switcher .dropdown-toggle {
  background: none;
  border: none;
  color: var(--text-primary);
  font-weight: 600;
  font-size: 0.85rem;
  padding: 0.5rem;
}

.lang-switcher .dropdown-menu {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  box-shadow: var(--shadow-lg);
  border-radius: var(--radius-sm);
  min-width: auto;
}

.lang-switcher .dropdown-item {
  font-size: 0.85rem;
  color: var(--text-primary);
  padding: 0.4rem 0.75rem;
}

.lang-switcher .dropdown-item:hover {
  background: var(--accent-light);
  color: var(--accent);
}

/* ---- Dark Mode Toggle ---- */
.dark-mode-toggle {
  background: none;
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  color: var(--text-primary);
  font-size: 1.15rem;
  transition: all var(--transition-fast);
}

.dark-mode-toggle:hover {
  background: var(--accent-light);
  color: var(--accent);
}

.dark-mode-toggle:focus-visible {
  outline: 2px solid var(--accent);
  outline-offset: 2px;
}

/* ---- Sort Bar ---- */
.sort-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem 1rem;
  background: var(--bg-card);
  border-radius: var(--radius);
  border: 1px solid var(--border-color);
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
  gap: 0.75rem;
}

.sort-bar .form-select {
  width: auto;
  min-width: 180px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
  background: var(--bg-card);
  color: var(--text-primary);
  padding: 0.4rem 2rem 0.4rem 0.75rem;
  font-size: 0.9rem;
}

.view-toggle {
  display: flex;
  gap: 0.25rem;
}

.view-toggle button {
  width: 36px;
  height: 36px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border-color);
  background: transparent;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  transition: all var(--transition-fast);
}

.view-toggle button.active {
  background: var(--accent-light);
  color: var(--accent);
  border-color: var(--accent);
}

/* ---- Results Count ---- */
.results-count {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

/* ---- Print Styles ---- */
@media print {
  .site-header,
  .site-footer,
  #back-to-top,
  .dark-mode-toggle,
  .lang-switcher,
  .search-bar,
  .hero-slider-controls,
  .hero-dots,
  .newsletter-section {
    display: none !important;
  }

  body {
    color: #000;
    background: #fff;
    font-size: 12pt;
  }

  a {
    color: #000 !important;
    text-decoration: underline;
  }

  .page-header {
    padding-top: 0;
    background: none;
  }

  @page {
    margin: 2cm;
  }
}

/* ---- Reduced Motion ---- */
@media (prefers-reduced-motion: reduce) {
  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }

  .hero-slide {
    transition: none !important;
  }
}

/* ---- Responsive ---- */
@media (max-width: 991.98px) {
  .hero-slider {
    height: 80vh;
    min-height: 500px;
  }

  .hero-slide-content h1 {
    font-size: 1.75rem;
  }

  .hero-slide-content p {
    font-size: 0.95rem;
  }

  .hero-badges {
    bottom: 1rem;
  }

  .hero-badge-item {
    font-size: 0.75rem;
    padding: 0.35rem 0.75rem;
  }

  .hero-slider-controls {
    width: 36px;
    height: 36px;
    font-size: 0.85rem;
  }

  .hero-slider-controls.prev { left: 0.75rem; }
  .hero-slider-controls.next { right: 0.75rem; }

  .hero-dots {
    bottom: 4rem;
  }

  .filter-sidebar {
    position: static;
  }

  .site-header .navbar-collapse {
    background: var(--bg-primary);
    border-radius: var(--radius);
    box-shadow: var(--shadow-lg);
    padding: 1rem;
    margin-top: 0.5rem;
  }

  .specs-grid {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 767.98px) {
  .hero-slider {
    height: 70vh;
    min-height: 400px;
  }

  .hero-slide-content h1 {
    font-size: 1.5rem;
  }

  .hero-badges {
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
  }

  .specs-grid {
    grid-template-columns: 1fr 1fr;
  }

  .sort-bar .form-select {
    min-width: 140px;
  }
}

@media (max-width: 575.98px) {
  .hero-slider {
    height: 60vh;
    min-height: 350px;
  }

  .stat-counter {
    font-size: 1.75rem;
  }
}

/* ============================================================
   Account / Profile Page
   ============================================================ */
.account-sidebar {
  position: sticky;
  top: calc(var(--navbar-height) + 2rem);
  background: var(--bg-card);
  border-radius: var(--radius);
  border: 1px solid var(--border-color);
  overflow: hidden;
}

.account-sidebar .account-user {
  padding: 1.5rem;
  text-align: center;
  border-bottom: 1px solid var(--border-color);
  background: var(--bg-surface);
}

.account-sidebar .account-avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: var(--accent-light);
  color: var(--accent);
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.75rem;
  margin: 0 auto 0.75rem;
}

.account-sidebar .account-user-name {
  font-weight: 700;
  font-size: 1.1rem;
}

.account-sidebar .account-user-email {
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.account-nav {
  list-style: none;
  padding: 0;
  margin: 0;
}

.account-nav li a {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.875rem 1.5rem;
  color: var(--text-primary);
  font-weight: 500;
  font-size: 0.95rem;
  transition: all var(--transition-fast);
  border-left: 3px solid transparent;
  text-decoration: none;
}

.account-nav li a:hover {
  background: var(--accent-light);
  color: var(--accent);
}

.account-nav li a.active {
  background: var(--accent-light);
  color: var(--accent);
  border-left-color: var(--accent);
}

.account-nav li a i {
  width: 20px;
  text-align: center;
  font-size: 1.05rem;
}

.account-section {
  display: none;
  animation: fadeIn 0.3s ease;
}

.account-section.active {
  display: block;
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

.account-card {
  background: var(--bg-card);
  border-radius: var(--radius);
  border: 1px solid var(--border-color);
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}

.account-card-title {
  font-size: 1.15rem;
  font-weight: 700;
  margin-bottom: 1.25rem;
  font-family: var(--font-heading);
}

/* Order table */
.order-table {
  width: 100%;
  font-size: 0.9rem;
}

.order-table th {
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  font-size: 0.75rem;
  letter-spacing: 0.05em;
  padding: 0.75rem 1rem;
  border-bottom: 2px solid var(--border-color);
}

.order-table td {
  padding: 1rem;
  border-bottom: 1px solid var(--border-light);
  vertical-align: middle;
}

.order-table tr:hover td {
  background: var(--bg-surface);
}

.status-badge {
  display: inline-block;
  padding: 0.2rem 0.75rem;
  border-radius: var(--radius-full);
  font-size: 0.8rem;
  font-weight: 600;
}

.status-badge.pending { background: #fff3cd; color: #856404; }
.status-badge.processing { background: #cce5ff; color: #004085; }
.status-badge.shipped { background: #d4edda; color: #155724; }
.status-badge.delivered { background: #d4edda; color: #155724; }
.status-badge.cancelled { background: #f8d7da; color: #721c24; }

[data-bs-theme="dark"] .status-badge.pending { background: rgba(255, 193, 7, 0.2); color: #ffc107; }
[data-bs-theme="dark"] .status-badge.processing { background: rgba(13, 110, 253, 0.2); color: #6ea8fe; }
[data-bs-theme="dark"] .status-badge.shipped { background: rgba(25, 135, 84, 0.2); color: #75b798; }
[data-bs-theme="dark"] .status-badge.delivered { background: rgba(25, 135, 84, 0.2); color: #75b798; }
[data-bs-theme="dark"] .status-badge.cancelled { background: rgba(220, 53, 69, 0.2); color: #ea868f; }

/* Wishlist grid */
.wishlist-grid .product-card {
  margin-bottom: 0;
}

/* ============================================================
   Tracking Page
   ============================================================ */
.tracking-hero {
  background: var(--bg-secondary);
  padding: calc(var(--navbar-height) + 2rem) 0 2rem;
  text-align: center;
}

.tracking-hero h1 {
  margin-bottom: 0.5rem;
}

.tracking-hero p {
  color: var(--text-secondary);
  max-width: 500px;
  margin: 0 auto 1.5rem;
}

.tracking-search {
  max-width: 500px;
  margin: 0 auto;
}

.tracking-search .input-group {
  box-shadow: var(--shadow-md);
  border-radius: var(--radius-full);
  overflow: hidden;
}

.tracking-search .form-control {
  border: 2px solid var(--border-color);
  padding: 0.75rem 1.25rem;
  font-size: 1rem;
}

.tracking-search .form-control:focus {
  border-color: var(--accent);
  box-shadow: none;
}

.tracking-search .btn {
  padding: 0.75rem 1.5rem;
}

/* Timeline */
.tracking-timeline {
  max-width: 700px;
  margin: 3rem auto;
  padding: 0 1rem;
}

.timeline-item {
  display: flex;
  gap: 1rem;
  position: relative;
  padding-bottom: 2rem;
}

.timeline-item:last-child {
  padding-bottom: 0;
}

.timeline-icon {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  z-index: 1;
  position: relative;
  transition: all var(--transition-base);
}

.timeline-icon.completed {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 0 0 4px var(--accent-light);
}

.timeline-icon.current {
  background: var(--accent);
  color: #fff;
  box-shadow: 0 0 0 6px rgba(0, 212, 170, 0.25);
  animation: pulse-dot 2s ease-in-out infinite;
}

.timeline-icon.pending {
  background: var(--bg-surface);
  color: var(--text-muted);
  border: 2px solid var(--border-color);
}

@keyframes pulse-dot {
  0%, 100% { box-shadow: 0 0 0 4px rgba(0, 212, 170, 0.25); }
  50% { box-shadow: 0 0 0 10px rgba(0, 212, 170, 0.1); }
}

.timeline-connector {
  position: absolute;
  left: 24px;
  top: 48px;
  bottom: 0;
  width: 2px;
  transform: translateX(-50%);
  background: var(--border-color);
}

.timeline-item:last-child .timeline-connector {
  display: none;
}

.timeline-connector.completed {
  background: var(--accent);
}

.timeline-content {
  flex: 1;
  padding-top: 0.5rem;
}

.timeline-content h4 {
  font-size: 1rem;
  font-weight: 700;
  margin-bottom: 0.15rem;
  font-family: var(--font-heading);
}

.timeline-content .timeline-date {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-bottom: 0.25rem;
}

.timeline-content .timeline-desc {
  font-size: 0.9rem;
  color: var(--text-secondary);
  line-height: 1.5;
}

.timeline-content .timeline-status {
  display: inline-block;
  font-size: 0.75rem;
  font-weight: 600;
  padding: 0.15rem 0.5rem;
  border-radius: var(--radius-full);
  margin-top: 0.25rem;
}

.timeline-status.completed {
  background: var(--accent-light);
  color: var(--accent);
}

.timeline-status.current {
  background: rgba(0, 212, 170, 0.15);
  color: var(--accent);
}

.timeline-status.pending {
  background: var(--bg-surface);
  color: var(--text-muted);
}

/* Tracking result header */
.tracking-result-header {
  text-align: center;
  margin-bottom: 2rem;
  padding: 2rem;
  background: var(--bg-card);
  border-radius: var(--radius);
  border: 1px solid var(--border-color);
}

.tracking-result-header .order-number {
  font-size: 1.25rem;
  font-weight: 700;
  color: var(--accent);
  font-family: var(--font-heading);
}

.tracking-result-header .order-status {
  display: inline-block;
  padding: 0.35rem 1rem;
  border-radius: var(--radius-full);
  font-size: 0.9rem;
  font-weight: 600;
  margin-top: 0.5rem;
}

.tracking-result-header .order-status.in-transit {
  background: var(--accent-light);
  color: var(--accent);
}

/* ============================================================
   Mobile responsive for Account & Tracking
   ============================================================ */
@media (max-width: 991.98px) {
  .account-sidebar {
    position: static;
    margin-bottom: 1.5rem;
  }

  .account-nav {
    display: flex;
    flex-wrap: wrap;
    gap: 0.25rem;
    padding: 1rem;
  }

  .account-nav li a {
    padding: 0.5rem 1rem;
    border-left: none;
    border-radius: var(--radius-full);
    font-size: 0.85rem;
  }

  .account-nav li a.active {
    border-left: none;
    background: var(--accent);
    color: #fff;
  }

  .order-table {
    font-size: 0.8rem;
  }

  .order-table th,
  .order-table td {
    padding: 0.5rem;
  }
}

@media (max-width: 575.98px) {
  .order-table {
    display: block;
    overflow-x: auto;
  }

  .timeline-icon {
    width: 40px;
    height: 40px;
    font-size: 1rem;
  }

  .timeline-connector {
    left: 20px;
  }
}
