/* ShopVerse storefront - store theme comes from CSS variables injected in base.html */
:root {
  --brand: #0d6efd;
  --brand-2: #212529;
  --accent: #ffc107;
  --page-bg: #f6f7fb;
  --font-heading: "Poppins", system-ui, sans-serif;
  --font-body: "Inter", system-ui, sans-serif;
  --radius: 14px;
  --shadow-sm: 0 2px 10px rgba(16, 24, 40, .06);
  --shadow: 0 10px 30px rgba(16, 24, 40, .10);
  --muted: #6b7280;
}

html[lang="hi"] { --font-body: "Noto Sans Devanagari", "Inter", sans-serif; --font-heading: "Noto Sans Devanagari", sans-serif; }
html[lang="kn"] { --font-body: "Noto Sans Kannada", "Inter", sans-serif; --font-heading: "Noto Sans Kannada", sans-serif; }

body { font-family: var(--font-body); background: var(--page-bg); color: #1f2937; }
h1, h2, h3, h4, h5, h6, .font-heading { font-family: var(--font-heading); }
a { color: var(--brand); }
a:hover { color: color-mix(in srgb, var(--brand) 80%, #000); }

.text-brand { color: var(--brand) !important; }
.bg-brand { background: var(--brand) !important; color: #fff; }
.bg-brand-soft { background: color-mix(in srgb, var(--brand) 8%, #fff) !important; }
.border-brand { border-color: var(--brand) !important; }

.btn-brand { --bs-btn-color: #fff; --bs-btn-bg: var(--brand); --bs-btn-border-color: var(--brand);
  --bs-btn-hover-color: #fff; --bs-btn-hover-bg: color-mix(in srgb, var(--brand) 85%, #000);
  --bs-btn-hover-border-color: color-mix(in srgb, var(--brand) 85%, #000);
  --bs-btn-active-bg: color-mix(in srgb, var(--brand) 75%, #000); --bs-btn-active-color: #fff;
  --bs-btn-disabled-bg: var(--brand); --bs-btn-disabled-border-color: var(--brand); }
.btn-outline-brand { --bs-btn-color: var(--brand); --bs-btn-border-color: var(--brand); --bs-btn-hover-bg: var(--brand);
  --bs-btn-hover-color: #fff; --bs-btn-hover-border-color: var(--brand); --bs-btn-active-bg: var(--brand); --bs-btn-active-color: #fff; }
.btn-accent { background: var(--accent); border-color: var(--accent); color: #111; font-weight: 600; }
.btn-accent:hover { filter: brightness(.95); color: #111; }

/* ----- top bars ----- */
.demo-banner { background: repeating-linear-gradient(45deg, #111827, #111827 12px, #1f2937 12px, #1f2937 24px); color: #fde68a; font-size: .8rem; }
.topbar { background: var(--brand-2); color: rgba(255,255,255,.85); font-size: .85rem; }
.topbar a, .topbar .btn-link { color: rgba(255,255,255,.9); text-decoration: none; }
.topbar .form-select-sm { background-color: rgba(255,255,255,.1); color: #fff; border-color: rgba(255,255,255,.2); min-width: 0; }
.topbar .form-select-sm option { color: #111; }
.store-pill { border-radius: 999px; padding: .2rem .75rem; display: inline-flex; gap: .35rem; align-items: center; background: rgba(255,255,255,.1); }

.site-header { background: #fff; box-shadow: var(--shadow-sm); position: sticky; top: 0; z-index: 1030; }
.brand-logo { font-family: var(--font-heading); font-weight: 700; font-size: 1.45rem; color: var(--brand-2); text-decoration: none; display: flex; align-items: center; gap: .5rem; }
.brand-logo .logo-mark { width: 40px; height: 40px; border-radius: 12px; background: var(--brand); color: #fff; display: grid; place-items: center; font-size: 1.25rem; }
.brand-logo small { display: block; font-size: .7rem; font-weight: 500; color: var(--muted); font-family: var(--font-body); letter-spacing: .02em; }
.header-search { position: relative; }
.header-search .form-control { border-radius: 999px; padding-left: 1.1rem; padding-right: 3rem; background: #f3f4f6; border-color: transparent; height: 44px; }
.header-search .form-control:focus { background: #fff; border-color: var(--brand); box-shadow: 0 0 0 .2rem color-mix(in srgb, var(--brand) 20%, transparent); }
.header-search button { position: absolute; right: 4px; top: 4px; border-radius: 999px; height: 36px; width: 36px; padding: 0; }
.search-suggest { position: absolute; top: 100%; left: 0; right: 0; background: #fff; border-radius: 12px; box-shadow: var(--shadow); z-index: 1050; margin-top: 6px; overflow: hidden; display: none; }
.search-suggest a { display: flex; gap: .75rem; align-items: center; padding: .55rem .9rem; color: inherit; text-decoration: none; }
.search-suggest a:hover, .search-suggest a.active { background: #f3f4f6; }
.search-suggest img { width: 38px; height: 38px; object-fit: cover; border-radius: 8px; }
.header-icon { position: relative; color: #374151; font-size: 1.35rem; text-decoration: none; display: inline-flex; flex-direction: column; align-items: center; line-height: 1; }
.header-icon small { font-size: .68rem; margin-top: 3px; color: var(--muted); }
.header-icon .count { position: absolute; top: -6px; right: -8px; background: var(--accent); color: #111; font-size: .65rem; border-radius: 999px; min-width: 18px; height: 18px; display: grid; place-items: center; font-weight: 700; }
.category-nav { background: #fff; border-top: 1px solid #eef0f4; }
.category-nav .nav-link { color: #374151; font-weight: 500; padding: .7rem .9rem; white-space: nowrap; }
.category-nav .nav-link:hover, .category-nav .nav-link.active { color: var(--brand); }
.category-nav .dropdown-menu { border: 0; box-shadow: var(--shadow); border-radius: 12px; }

.vehicle-bar { background: linear-gradient(90deg, var(--brand-2), color-mix(in srgb, var(--brand-2) 70%, var(--brand))); color: #fff; }
.vehicle-bar .form-select { min-width: 140px; }

/* ----- hero ----- */
.hero-slide { border-radius: 22px; overflow: hidden; position: relative; min-height: 360px; background-size: cover; background-position: center; }
.hero-slide::after { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(0,0,0,.55), rgba(0,0,0,.05)); }
.hero-content { position: relative; z-index: 2; color: #fff; padding: 3rem; max-width: 560px; }
.hero-content h2 { font-size: clamp(1.8rem, 3.2vw, 2.8rem); font-weight: 700; }
.section-title { display: flex; justify-content: space-between; align-items: end; margin-bottom: 1.25rem; }
.section-title h3 { font-weight: 700; margin: 0; }
.section-title h3::after { content: ""; display: block; width: 44px; height: 4px; border-radius: 4px; background: var(--brand); margin-top: .45rem; }

.category-tile { background: #fff; border-radius: var(--radius); padding: 1rem; text-align: center; box-shadow: var(--shadow-sm); text-decoration: none; color: inherit; display: block; transition: .2s; height: 100%; }
.category-tile:hover { transform: translateY(-4px); box-shadow: var(--shadow); color: var(--brand); }
.category-tile .tile-img { width: 100%; aspect-ratio: 1; border-radius: 12px; object-fit: cover; background: var(--page-bg); margin-bottom: .6rem; display: grid; place-items: center; font-size: 2rem; color: var(--brand); overflow: hidden; }
.category-tile .tile-img img { width: 100%; height: 100%; object-fit: cover; }

/* ----- product card ----- */
.product-card { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow-sm); overflow: hidden; height: 100%; display: flex; flex-direction: column; transition: .2s; position: relative; }
.product-card:hover { box-shadow: var(--shadow); transform: translateY(-3px); }
.product-card .thumb { position: relative; aspect-ratio: 1; background: #f3f4f6; overflow: hidden; display: block; }
.product-card .thumb img { width: 100%; height: 100%; object-fit: cover; transition: .4s; }
.product-card:hover .thumb img { transform: scale(1.05); }
.product-card .badges { position: absolute; top: 10px; left: 10px; display: flex; flex-direction: column; gap: 4px; z-index: 2; }
.product-card .actions { position: absolute; top: 10px; right: 10px; display: flex; flex-direction: column; gap: 6px; z-index: 2; opacity: 0; transform: translateX(8px); transition: .2s; }
.product-card:hover .actions, .product-card .actions .active { opacity: 1; transform: none; }
.product-card .actions .btn { width: 36px; height: 36px; border-radius: 50%; padding: 0; display: grid; place-items: center; background: #fff; box-shadow: var(--shadow-sm); border: 0; color: #374151; }
.product-card .actions .btn.active, .product-card .actions .btn:hover { color: #dc3545; }
.product-card .actions .btn.js-compare.active { color: var(--brand); }
@media (hover: none) { .product-card .actions { opacity: 1; transform: none; } }
.product-card .body { padding: .9rem 1rem 1rem; display: flex; flex-direction: column; flex: 1; }
.product-card .brand { font-size: .75rem; color: var(--muted); text-transform: uppercase; letter-spacing: .04em; }
.product-card .title { font-weight: 600; color: #111827; text-decoration: none; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; min-height: 2.6em; font-size: .95rem; }
.product-card .title:hover { color: var(--brand); }
.price { font-weight: 700; font-size: 1.1rem; color: #111827; }
.mrp { text-decoration: line-through; color: var(--muted); font-size: .85rem; }
.off { color: #16a34a; font-weight: 600; font-size: .85rem; }
.stars { color: #f59e0b; letter-spacing: 1px; }
.list-view .product-col { width: 100%; }
.list-view .product-card { flex-direction: row; }
.list-view .product-card .thumb { width: 220px; flex-shrink: 0; }
@media (max-width: 575px) { .list-view .product-card .thumb { width: 130px; } }

.badge-fit { background: #dcfce7; color: #166534; }
.badge-nofit { background: #fee2e2; color: #991b1b; }

/* ----- filters ----- */
.filter-card { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow-sm); padding: 1.1rem; position: sticky; top: 140px; }
.filter-group + .filter-group { border-top: 1px solid #f0f1f4; padding-top: .9rem; margin-top: .9rem; }
.filter-group h6 { font-size: .8rem; text-transform: uppercase; letter-spacing: .05em; color: var(--muted); font-weight: 700; }
.filter-scroll { max-height: 190px; overflow-y: auto; }
.swatch { width: 26px; height: 26px; border-radius: 50%; border: 2px solid #fff; box-shadow: 0 0 0 1px #d1d5db; display: inline-block; cursor: pointer; }
.swatch-check:checked + .swatch, .swatch.selected { box-shadow: 0 0 0 2px var(--brand); }
.results-loading { opacity: .45; pointer-events: none; transition: opacity .2s; }

/* ----- product detail ----- */
.gallery-main { background: #fff; border-radius: var(--radius); overflow: hidden; position: relative; aspect-ratio: 1; cursor: zoom-in; box-shadow: var(--shadow-sm); }
.gallery-main img { width: 100%; height: 100%; object-fit: cover; transition: transform .15s ease-out; }
.gallery-main.zooming img { transform: scale(2); }
.gallery-thumbs img { width: 72px; height: 72px; object-fit: cover; border-radius: 10px; cursor: pointer; border: 2px solid transparent; opacity: .75; }
.gallery-thumbs img.active, .gallery-thumbs img:hover { border-color: var(--brand); opacity: 1; }
.variant-options .opt { border: 1.5px solid #d1d5db; border-radius: 10px; padding: .4rem .9rem; background: #fff; cursor: pointer; font-weight: 500; min-width: 48px; }
.variant-options .opt.selected { border-color: var(--brand); color: var(--brand); background: color-mix(in srgb, var(--brand) 6%, #fff); }
.variant-options .opt.disabled { opacity: .35; text-decoration: line-through; cursor: not-allowed; }
.variant-options .opt.swatch-opt { width: 38px; height: 38px; border-radius: 50%; padding: 0; min-width: 0; border: 3px solid #fff; box-shadow: 0 0 0 1px #d1d5db; }
.variant-options .opt.swatch-opt.selected { box-shadow: 0 0 0 2px var(--brand); }
.info-card { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow-sm); padding: 1.1rem 1.25rem; }
.delivery-result { font-size: .9rem; }
.spec-table th { width: 38%; color: var(--muted); font-weight: 500; }
.rating-bar { height: 8px; border-radius: 4px; background: #eef0f4; overflow: hidden; }
.rating-bar span { display: block; height: 100%; background: #f59e0b; }
.sticky-buy { position: sticky; top: 130px; }

/* ----- checkout ----- */
.checkout-steps { display: flex; gap: .5rem; justify-content: center; margin-bottom: 1.5rem; flex-wrap: wrap; }
.checkout-steps .step { display: flex; align-items: center; gap: .5rem; color: var(--muted); font-weight: 500; }
.checkout-steps .step .num { width: 30px; height: 30px; border-radius: 50%; display: grid; place-items: center; background: #e5e7eb; font-weight: 700; }
.checkout-steps .step.done .num, .checkout-steps .step.active .num { background: var(--brand); color: #fff; }
.checkout-steps .step.active { color: #111827; }
.checkout-steps .sep { width: 40px; height: 2px; background: #e5e7eb; align-self: center; }
.choice-card { border: 2px solid #e5e7eb; border-radius: 14px; padding: 1rem; cursor: pointer; transition: .15s; background: #fff; display: block; }
.choice-card:hover { border-color: color-mix(in srgb, var(--brand) 50%, #fff); }
.choice-card.selected, .btn-check:checked + .choice-card { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 4%, #fff); }
.summary-card { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow-sm); padding: 1.25rem; position: sticky; top: 140px; }
.summary-card .row-line { display: flex; justify-content: space-between; padding: .3rem 0; }
.summary-card .grand { border-top: 1px dashed #d1d5db; margin-top: .5rem; padding-top: .75rem; font-size: 1.15rem; font-weight: 700; }

/* ----- payment modal ----- */
#paymentModal .modal-content { border-radius: 20px; border: 0; overflow: hidden; }
#paymentModal .modal-header { background: linear-gradient(120deg, var(--brand), color-mix(in srgb, var(--brand) 55%, var(--brand-2))); color: #fff; }
.pay-option { border: 2px solid #eef0f4; border-radius: 14px; padding: .85rem 1rem; display: flex; gap: .9rem; align-items: center; cursor: pointer; transition: .15s; background: #fff; width: 100%; text-align: left; }
.pay-option:hover:not(.disabled) { border-color: color-mix(in srgb, var(--brand) 45%, #fff); }
.pay-option.selected { border-color: var(--brand); background: color-mix(in srgb, var(--brand) 5%, #fff); }
.pay-option.disabled { opacity: .5; cursor: not-allowed; }
.pay-option .pay-icon { width: 46px; height: 46px; border-radius: 12px; display: grid; place-items: center; font-size: 1.4rem; background: #f3f4f6; flex-shrink: 0; color: var(--brand-2); }
.pay-option .pay-icon img { max-width: 34px; max-height: 34px; }
.wallet-toggle { background: #fff7ed; border: 1px dashed #fdba74; border-radius: 14px; }
.pay-stage { display: none; }
.pay-stage.active { display: block; }

/* ----- tracking timeline ----- */
.progress-track { display: flex; justify-content: space-between; position: relative; margin: 1.5rem 0 1rem; }
.progress-track::before { content: ""; position: absolute; top: 22px; left: 8%; right: 8%; height: 4px; background: #e5e7eb; z-index: 0; }
.progress-track .pt-step { text-align: center; position: relative; z-index: 1; flex: 1; }
.progress-track .pt-dot { width: 46px; height: 46px; border-radius: 50%; display: grid; place-items: center; margin: 0 auto .4rem; background: #e5e7eb; color: #6b7280; font-size: 1.2rem; border: 4px solid #fff; }
.progress-track .pt-step.done .pt-dot { background: var(--brand); color: #fff; }
.progress-track .pt-step.current .pt-dot { box-shadow: 0 0 0 4px color-mix(in srgb, var(--brand) 25%, transparent); }
.progress-track .pt-step small { font-weight: 500; }
.timeline { list-style: none; padding-left: 0; position: relative; }
.timeline li { position: relative; padding: 0 0 1.1rem 2rem; }
.timeline li::before { content: ""; position: absolute; left: 7px; top: 6px; bottom: -6px; width: 2px; background: #e5e7eb; }
.timeline li:last-child::before { display: none; }
.timeline li::after { content: ""; position: absolute; left: 0; top: 4px; width: 16px; height: 16px; border-radius: 50%; background: #fff; border: 3px solid var(--brand); }
.timeline li.muted::after { border-color: #cbd5e1; }

/* ----- misc ----- */
.page-header { padding: 1.5rem 0 1rem; }
.breadcrumb { font-size: .85rem; margin-bottom: .25rem; }
.card-soft { background: #fff; border-radius: var(--radius); box-shadow: var(--shadow-sm); border: 0; }
.empty-state { text-align: center; padding: 3rem 1rem; color: var(--muted); }
.empty-state i { font-size: 3rem; color: #cbd5e1; display: block; margin-bottom: 1rem; }
.countdown span { background: var(--brand-2); color: #fff; border-radius: 8px; padding: .3rem .55rem; font-weight: 700; font-variant-numeric: tabular-nums; }
.brand-strip .brand-chip { background: #fff; border-radius: 12px; padding: .9rem 1.4rem; box-shadow: var(--shadow-sm); font-weight: 700; color: #4b5563; font-family: var(--font-heading); white-space: nowrap; }
.testimonial { background: #fff; border-radius: var(--radius); padding: 1.5rem; box-shadow: var(--shadow-sm); height: 100%; }
.promo-banner { border-radius: 18px; overflow: hidden; position: relative; min-height: 160px; background-size: cover; background-position: center; color: #fff; display: flex; align-items: center; padding: 1.5rem 2rem; }
.promo-banner::before { content: ""; position: absolute; inset: 0; background: linear-gradient(90deg, rgba(0,0,0,.6), rgba(0,0,0,0)); }
.promo-banner > * { position: relative; }
.site-footer { background: var(--brand-2); color: rgba(255,255,255,.7); margin-top: 4rem; }
.site-footer a { color: rgba(255,255,255,.75); text-decoration: none; }
.site-footer a:hover { color: #fff; }
.site-footer h6 { color: #fff; font-weight: 600; letter-spacing: .02em; }
.account-nav .list-group-item { border: 0; border-radius: 10px !important; margin-bottom: 2px; }
.account-nav .list-group-item.active { background: var(--brand); }
.qty-input { width: 110px; }
.qty-input .form-control { text-align: center; }
.letter-spacing { letter-spacing: .5em; }

/* demo guide */
.demo-guide-btn { position: fixed; right: 18px; bottom: 18px; z-index: 1040; border-radius: 999px; box-shadow: var(--shadow); }
.demo-guide { position: fixed; right: 18px; bottom: 76px; width: min(380px, calc(100vw - 36px)); max-height: 72vh; overflow-y: auto; z-index: 1045; display: none; border-radius: 18px; }
.demo-guide.show { display: block; animation: slideUp .2s ease-out; }
.demo-guide code { font-size: .8rem; }
@keyframes slideUp { from { transform: translateY(12px); opacity: 0 } to { transform: none; opacity: 1 } }
.copyable { cursor: pointer; }
.copyable:hover { background: #fff3cd; }

.toast-container { z-index: 1090; }
.skeleton { background: linear-gradient(90deg, #eee 25%, #f5f5f5 50%, #eee 75%); background-size: 200% 100%; animation: shimmer 1.2s infinite; border-radius: 10px; }
@keyframes shimmer { 0% { background-position: 200% 0 } 100% { background-position: -200% 0 } }

@media (max-width: 991px) {
  .filter-card, .summary-card, .sticky-buy { position: static; }
  .hero-content { padding: 2rem 1.5rem; }
  .hero-slide { min-height: 280px; }
}
.place-items-center { place-items: center; }
.list-view .list-only { display: block !important; }
.brand-logo > span:last-child { white-space: nowrap; line-height: 1.15; }
@media (max-width: 575px) { .brand-logo { font-size: 1.1rem; } .brand-logo small { display: none; } }
.qty-input { width: 132px; flex-wrap: nowrap; } .qty-input .form-control { min-width: 48px; padding-left: .25rem; padding-right: .25rem; }
