/* =========================================================
   CARJALWA - Premium Automotive Theme
   ========================================================= */
:root {
  --cj-black: #0a0b0d;
  --cj-black-2: #121417;
  --cj-dark-gray: #1b1e23;
  --cj-red: #e01c1c;
  --cj-red-dark: #a80f0f;
  --cj-blue: #2fb8ff;
  --cj-white: #f5f6f8;
  --cj-gray-text: #9aa1ab;
  --cj-radius: 14px;
}

* { box-sizing: border-box; }
html, body { overflow-x: hidden; }

body {
  font-family: 'Poppins', system-ui, -apple-system, sans-serif;
  background: var(--cj-black);
  color: var(--cj-white);
}

a { text-decoration: none; }

/* ---------------- Header ---------------- */
.site-header {
  background: linear-gradient(180deg, #000000 0%, #0d0f12 100%);
  border-bottom: 1px solid rgba(255,255,255,0.06);
  position: sticky;
  top: 0;
  z-index: 1000;
}
.brand-logo {
  width: 42px;
  height: 42px;
  object-fit: cover;
  border-radius: 8px;
  background: #fff;
}
.brand-text {
  font-weight: 800;
  font-size: 1.35rem;
  letter-spacing: 0.5px;
  color: var(--cj-white);
}
.brand-text::first-letter { color: var(--cj-red); }
.navbar-nav .nav-link {
  color: var(--cj-gray-text) !important;
  font-weight: 500;
  padding: 0.5rem 1rem !important;
  transition: color 0.2s ease;
}
.navbar-nav .nav-link:hover { color: var(--cj-white) !important; }
.cart-link { position: relative; }
.cart-badge {
  background: var(--cj-red);
  color: #fff;
  font-size: 0.7rem;
  vertical-align: middle;
  box-shadow: 0 0 10px rgba(224,28,28,0.6);
}

/* ---------------- Hero ---------------- */
.hero {
  position: relative;
  padding: 90px 0 100px;
  background:
    radial-gradient(ellipse at 20% 20%, rgba(47,184,255,0.14), transparent 55%),
    radial-gradient(ellipse at 80% 80%, rgba(224,28,28,0.14), transparent 55%),
    linear-gradient(180deg, #000000 0%, #0b0d10 100%);
  overflow: hidden;
  border-bottom: 1px solid rgba(255,255,255,0.05);
}
.hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 120%, rgba(47,184,255,0.18), transparent 60%);
  animation: glowPulse 5s ease-in-out infinite;
  pointer-events: none;
}
@keyframes glowPulse {
  0%, 100% { opacity: 0.55; }
  50% { opacity: 1; }
}
.hero-content { position: relative; z-index: 2; }
.hero-eyebrow {
  color: var(--cj-blue);
  letter-spacing: 3px;
  font-weight: 600;
  font-size: 0.8rem;
  text-transform: uppercase;
}
.hero h1 {
  font-weight: 800;
  font-size: clamp(2.2rem, 5vw, 3.6rem);
  line-height: 1.1;
  margin: 0.5rem 0 1rem;
  text-shadow: 0 0 30px rgba(47,184,255,0.25);
}
.hero h1 span { color: var(--cj-red); }
.hero p.lead {
  color: var(--cj-gray-text);
  font-size: 1.1rem;
  max-width: 520px;
}
.hero-visual {
  position: relative;
  z-index: 2;
}
.hero-visual img {
  width: 100%;
  border-radius: var(--cj-radius);
  filter: drop-shadow(0 20px 40px rgba(0,0,0,0.6));
}

/* ---------------- Buttons ---------------- */
.btn-cj-primary {
  background: linear-gradient(135deg, var(--cj-red) 0%, var(--cj-red-dark) 100%);
  color: #fff;
  border: none;
  font-weight: 600;
  letter-spacing: 0.5px;
  padding: 0.75rem 1.9rem;
  border-radius: 10px;
  box-shadow: 0 8px 24px rgba(224,28,28,0.35);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}
.btn-cj-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 30px rgba(224,28,28,0.5);
  color: #fff;
}
.btn-cj-outline {
  background: transparent;
  color: var(--cj-white);
  border: 1.5px solid rgba(255,255,255,0.25);
  font-weight: 600;
  padding: 0.75rem 1.9rem;
  border-radius: 10px;
  transition: all 0.2s ease;
}
.btn-cj-outline:hover {
  border-color: var(--cj-blue);
  color: var(--cj-blue);
  box-shadow: 0 0 18px rgba(47,184,255,0.25);
}
.btn-whatsapp {
  background: #25D366;
  color: #fff !important;
  border-radius: 8px;
  font-weight: 600;
}

/* ---------------- Sections ---------------- */
.section { padding: 70px 0; }
.section-dark { background: var(--cj-black-2); }
.section-title {
  font-weight: 800;
  font-size: clamp(1.6rem, 3vw, 2.3rem);
  text-align: center;
  margin-bottom: 0.5rem;
}
.section-title span { color: var(--cj-red); }
.section-subtitle {
  text-align: center;
  color: var(--cj-gray-text);
  margin-bottom: 2.5rem;
}

/* ---------------- Search ---------------- */
.search-box {
  max-width: 420px;
  margin: 0 auto 2.5rem;
}
.search-box input {
  background: var(--cj-dark-gray);
  border: 1px solid rgba(255,255,255,0.1);
  color: #fff;
  border-radius: 30px;
  padding: 0.7rem 1.3rem;
}
.search-box input:focus {
  border-color: var(--cj-blue);
  box-shadow: 0 0 0 3px rgba(47,184,255,0.15);
  background: var(--cj-dark-gray);
  color: #fff;
}
.search-box input::placeholder { color: var(--cj-gray-text); }

/* ---------------- Product Cards ---------------- */
.product-card {
  background: linear-gradient(180deg, #16181c 0%, #101114 100%);
  border: 1px solid rgba(255,255,255,0.06);
  border-radius: var(--cj-radius);
  overflow: hidden;
  height: 100%;
  transition: transform 0.25s ease, box-shadow 0.25s ease, border-color 0.25s ease;
  position: relative;
}
.product-card:hover {
  transform: translateY(-6px);
  border-color: rgba(47,184,255,0.35);
  box-shadow: 0 16px 40px rgba(0,0,0,0.5), 0 0 24px rgba(47,184,255,0.12);
}
.product-card .img-wrap {
  background: #fff;
  aspect-ratio: 1/1;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
  position: relative;
}
.product-card .img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.product-card:hover .img-wrap img { transform: scale(1.06); }
.badge-discount {
  position: absolute;
  top: 10px;
  left: 10px;
  background: var(--cj-red);
  color: #fff;
  font-weight: 700;
  font-size: 0.72rem;
  padding: 0.3rem 0.6rem;
  border-radius: 6px;
  box-shadow: 0 0 12px rgba(224,28,28,0.5);
}
.badge-featured {
  position: absolute;
  top: 10px;
  right: 10px;
  background: rgba(47,184,255,0.15);
  color: var(--cj-blue);
  border: 1px solid rgba(47,184,255,0.4);
  font-weight: 600;
  font-size: 0.68rem;
  padding: 0.3rem 0.55rem;
  border-radius: 6px;
}
.product-card .body { padding: 1.1rem 1.1rem 1.3rem; }
.product-card .p-name {
  font-weight: 600;
  font-size: 1.02rem;
  margin-bottom: 0.25rem;
  color: var(--cj-white);
}
.product-card .p-desc {
  color: var(--cj-gray-text);
  font-size: 0.85rem;
  min-height: 2.4em;
  margin-bottom: 0.7rem;
}
.price-current {
  color: var(--cj-red);
  font-weight: 700;
  font-size: 1.15rem;
}
.price-old {
  color: var(--cj-gray-text);
  text-decoration: line-through;
  font-size: 0.85rem;
  margin-left: 0.4rem;
}
.stock-in { color: #35d07f; font-size: 0.8rem; font-weight: 600; }
.stock-out { color: var(--cj-red); font-size: 0.8rem; font-weight: 600; }
.product-card .actions { display: flex; gap: 0.5rem; margin-top: 0.9rem; }
.product-card .actions .btn { flex: 1; font-size: 0.85rem; padding: 0.55rem 0.5rem; }

/* ---------------- Feature Boxes ---------------- */
.feature-box {
  text-align: center;
  padding: 2rem 1.2rem;
  border-radius: var(--cj-radius);
  background: linear-gradient(180deg, #15171b, #0d0e11);
  border: 1px solid rgba(255,255,255,0.06);
  height: 100%;
}
.feature-box .icon {
  font-size: 2.2rem;
  margin-bottom: 0.8rem;
  filter: drop-shadow(0 0 12px rgba(47,184,255,0.4));
}
.feature-box h5 { font-weight: 700; margin-bottom: 0.4rem; }
.feature-box p { color: var(--cj-gray-text); font-size: 0.88rem; margin: 0; }

/* ---------------- CTA Bottom ---------------- */
.cta-bottom {
  background:
    radial-gradient(circle at 30% 30%, rgba(224,28,28,0.18), transparent 55%),
    radial-gradient(circle at 70% 70%, rgba(47,184,255,0.15), transparent 55%),
    #000;
  text-align: center;
  padding: 80px 0;
  border-top: 1px solid rgba(255,255,255,0.06);
  border-bottom: 1px solid rgba(255,255,255,0.06);
}
.cta-bottom h2 { font-weight: 800; font-size: clamp(1.6rem, 4vw, 2.4rem); }
.cta-bottom p { color: var(--cj-gray-text); margin-bottom: 1.6rem; }

/* ---------------- Footer ---------------- */
.site-footer {
  background: #000;
  border-top: 1px solid rgba(255,255,255,0.06);
  color: var(--cj-gray-text);
}
.footer-heading { color: #fff; font-weight: 700; margin-bottom: 0.9rem; }
.footer-tagline { color: var(--cj-gray-text); }
.footer-links li { margin-bottom: 0.5rem; }
.footer-links a { color: var(--cj-gray-text); transition: color 0.2s; }
.footer-links a:hover { color: var(--cj-blue); }
.footer-bottom {
  border-top: 1px solid rgba(255,255,255,0.06);
  font-size: 0.85rem;
}

/* ---------------- Product Detail Page ---------------- */
.pd-gallery-main {
  background: #fff;
  border-radius: var(--cj-radius);
  overflow: hidden;
  aspect-ratio: 1/1;
  display: flex;
  align-items: center;
  justify-content: center;
}
.pd-gallery-main img { width: 100%; height: 100%; object-fit: cover; }
.pd-thumbs { display: flex; gap: 0.6rem; margin-top: 0.8rem; flex-wrap: wrap; }
.pd-thumbs img {
  width: 70px; height: 70px; object-fit: cover; border-radius: 8px;
  background: #fff; cursor: pointer; border: 2px solid transparent;
}
.pd-thumbs img.active { border-color: var(--cj-blue); }
.pd-title { font-weight: 800; font-size: 1.8rem; }
.pd-price { font-size: 1.8rem; color: var(--cj-red); font-weight: 800; }
.qty-selector {
  display: inline-flex;
  align-items: center;
  border: 1px solid rgba(255,255,255,0.15);
  border-radius: 8px;
  overflow: hidden;
}
.qty-selector button {
  background: var(--cj-dark-gray);
  border: none;
  color: #fff;
  width: 40px;
  height: 42px;
  font-size: 1.1rem;
}
.qty-selector input {
  width: 55px;
  text-align: center;
  border: none;
  background: var(--cj-black-2);
  color: #fff;
  height: 42px;
}
.pd-info-block {
  background: var(--cj-dark-gray);
  border-radius: var(--cj-radius);
  padding: 1.5rem;
  margin-top: 1rem;
}
.pd-info-block h5 { font-weight: 700; margin-bottom: 0.6rem; }
.pd-info-block ul { padding-left: 1.2rem; color: var(--cj-gray-text); }

/* ---------------- Cart / Checkout ---------------- */
.cart-table { color: #fff; }
.cart-table th { color: var(--cj-gray-text); font-weight: 600; border-color: rgba(255,255,255,0.08); }
.cart-table td { vertical-align: middle; border-color: rgba(255,255,255,0.08); }
.cart-item-img { width: 64px; height: 64px; object-fit: cover; border-radius: 8px; background: #fff; }
.summary-card {
  background: var(--cj-dark-gray);
  border-radius: var(--cj-radius);
  padding: 1.5rem;
  border: 1px solid rgba(255,255,255,0.06);
}
.summary-row { display: flex; justify-content: space-between; margin-bottom: 0.6rem; color: var(--cj-gray-text); }
.summary-row.total { color: #fff; font-weight: 700; font-size: 1.2rem; border-top: 1px solid rgba(255,255,255,0.1); padding-top: 0.8rem; margin-top: 0.6rem; }

.checkout-form label { color: var(--cj-gray-text); font-weight: 500; margin-bottom: 0.3rem; }
.checkout-form .form-control, .checkout-form .form-select {
  background: var(--cj-dark-gray);
  border: 1px solid rgba(255,255,255,0.12);
  color: #fff;
  border-radius: 8px;
  padding: 0.65rem 0.9rem;
}
.checkout-form .form-control:focus, .checkout-form .form-select:focus {
  background: var(--cj-dark-gray);
  color: #fff;
  border-color: var(--cj-blue);
  box-shadow: 0 0 0 3px rgba(47,184,255,0.15);
}
.payment-option {
  background: var(--cj-dark-gray);
  border: 1.5px solid var(--cj-blue);
  border-radius: 10px;
  padding: 1rem 1.2rem;
  display: flex;
  align-items: center;
  gap: 0.7rem;
}

/* ---------------- Order Success ---------------- */
.success-check {
  width: 80px; height: 80px;
  border-radius: 50%;
  background: rgba(53,208,127,0.15);
  color: #35d07f;
  font-size: 2.4rem;
  display: flex; align-items: center; justify-content: center;
  margin: 0 auto 1rem;
  border: 2px solid rgba(53,208,127,0.4);
}
.order-box {
  background: var(--cj-dark-gray);
  border-radius: var(--cj-radius);
  padding: 1.5rem;
}

/* ---------------- Empty States ---------------- */
.empty-state { text-align: center; padding: 60px 20px; color: var(--cj-gray-text); }
.empty-state .icon { font-size: 3rem; margin-bottom: 1rem; }

/* ---------------- Utilities ---------------- */
.glow-text-blue { color: var(--cj-blue); text-shadow: 0 0 16px rgba(47,184,255,0.5); }

@media (max-width: 767px) {
  .hero { padding: 60px 0 70px; text-align: center; }
  .hero p.lead { margin: 0 auto; }
  .section { padding: 50px 0; }
}
