/* =========================
   IMPORTS & RESET
========================= */
@import url("main.css");

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

/* =========================
   LAYOUT
========================= */
.category-container,
.cars-section {
  display: flex;
  max-width: 1200px;
  margin: 20px auto;
  gap: 20px;
  padding: 0 15px;
}

.sidebar {
  flex: 1;
  min-width: 200px;
  background: #f9f9f9;
  padding: 20px;
  border-radius: 8px;
}

.products-section {
  flex: 4;
  height: 500px; /* Or max-height to let it grow up to a certain size */
  overflow-y: auto; /* Adds vertical scrollbar only if content overflows */
  border: 1px solid #ccc;
  padding: 20px;
  border-radius: 8px;
}

.sorting-bar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.product-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 20px;
}

/* =========================
   FILTERS
========================= */
.filter-group {
  margin-bottom: 20px;
}

.filter-group label {
  display: block;
  margin: 10px 0;
  font-size: 14px;
}

/* =========================
   PRODUCT CARD
========================= */
.product-card {
  background: #fff;
  border: 1px solid #eee;
  border-radius: 10px;
  overflow: hidden;
  transition: transform 0.3s, box-shadow 0.3s;
}

.product-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.product-image {
  background: #f5f5f5;
}

.product-image img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}

.product-info {
  padding: 15px;
}

.product-title {
  font-size: 16px;
  margin: 5px 0;
}

.price {
  font-size: 18px;
  font-weight: bold;
  color: #174c5d;
}

/* =========================
   BUTTONS & BADGES
========================= */
.add-to-cart-btn {
  width: 100%;
  margin-top: 10px;
  padding: 10px;
  border: none;
  border-radius: 5px;
  background: #0f3845;
  color: #fff;
  cursor: pointer;
  transition: transform 0.15s, background-color 0.15s;
}

.add-to-cart-btn:active {
  transform: scale(0.95);
  background-color: #174c5d;
}

.cart-count {
  background: #ff4500;
  color: #fff;
  border-radius: 50%;
  padding: 2px 6px;
  font-size: 12px;
  position: relative;
  top: -10px;
  left: -5px;
}

/* =========================
   MODAL
========================= */
.modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  z-index: 1000;
}

.modal-content {
  background: #fff;
  margin: 5% auto;
  padding: 20px;
  width: 70%;
  border-radius: 10px;
  position: relative;
}

.close-button {
  position: absolute;
  top: 10px;
  right: 20px;
  font-size: 28px;
  cursor: pointer;
}

.modal-grid {
  display: flex;
  gap: 30px;
  align-items: center;
}

.modal-img {
  width: 50%;
  border-radius: 8px;
}

.modal-price {
  font-size: 24px;
  font-weight: bold;
  color: #0f3845;
}

/* =========================
   PAYMENT METHOD
========================= */
.method {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  min-height: 100px;
}

.method-label {
  font-weight: bold;
  margin-top: 5px;
}

.brand-icons {
  display: flex;
  gap: 5px;
  margin-top: 8px;
  font-size: 1.2rem;
  opacity: 0.7;
}

.method.active .brand-icons {
  opacity: 1;
  color: #1a1f71;
}

/* =========================
   SKELETON LOADING
========================= */
@keyframes shimmer {
  0% { background-position: -468px 0; }
  100% { background-position: 468px 0; }
}

.skeleton {
  background: #f6f7f8;
  background-image: linear-gradient(
    to right,
    #f6f7f8 0%,
    #edeef1 20%,
    #f6f7f8 40%,
    #f6f7f8 100%
  );
  background-repeat: no-repeat;
  background-size: 800px 104px;
  animation: shimmer 1.2s linear infinite;
}

.skeleton-card {
  width: 100%;
  height: 300px;
  border-radius: 10px;
}

/* =========================
   TOAST NOTIFICATION
========================= */
.toast-alert {
  position: fixed;
  top: 20px;
  right: -400px;
  padding: 15px 25px;
  background: #0f3845;
  color: #fff;
  border-radius: 8px;
  box-shadow: 0 5px 15px rgba(0, 0, 0, 0.3);
  z-index: 9999;
  overflow: hidden;
  transition: right 0.5s cubic-bezier(0.18, 0.89, 0.32, 1.28);
}

.toast-alert.show {
  right: 20px;
}

.toast-content {
  display: flex;
  align-items: center;
  gap: 12px;
}

.toast-content i {
  font-size: 20px;
  color: #4caf50;
}

.progress-bar {
  position: absolute;
  bottom: 0;
  left: 0;
  height: 4px;
  width: 100%;
  background: #ff4500;
  transform-origin: left;
}

.toast-alert.show .progress-bar {
  animation: progress 3s linear forwards;
}

@keyframes progress {
  from { transform: scaleX(1); }
  to { transform: scaleX(0); }
}
/* =========================
   SUPERCAR HERO SECTION
========================= */
.welcome-hero {
    position: relative;
    width: 100%;
    height: 550px;
    background: linear-gradient(rgba(0,0,0,0.6), rgba(0,0,0,0.3)), 
                url('https://images.unsplash.com/photo-1503376780353-7e6692767b70?auto=format&fit=crop&q=80&w=2070'); 
    background-size: cover;
    background-position: center;
    display: flex;
    align-items: center;
    padding: 0 10%;
    margin-bottom: 40px;
    color: #fff;
    overflow: hidden;
}

.hero-content {
    max-width: 650px;
    z-index: 2;
    animation: fadeInUp 1s ease;
}

.hero-badge {
    background: rgba(255, 69, 0, 0.2);
    color: #0f3845;
    padding: 8px 16px;
    border-radius: 50px;
    font-size: 14px;
    font-weight: 600;
    display: inline-block;
    border: 1px solid rgba(255, 69, 0, 0.3);
    margin-bottom: 20px;
}

.hero-content h1 {
    font-size: 4rem;
    line-height: 1.1;
    margin-bottom: 20px;
    font-weight: 800;
}

/* .text-gradient {
    background: linear-gradient(to right, #ff4500, #ff8c00);
    -webkit-text-fill-color: transparent;
} */

.hero-content p {
    font-size: 1.2rem;
    color: rgba(255,255,255,0.8);
    margin-bottom: 35px;
}

/* Buttons */
.hero-actions {
    display: flex;
    gap: 20px;
}

.btn-primary {
    background: #0f3845;
    color: #fff;
    padding: 15px 35px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    transition: 0.3s;
    box-shadow: 0 10px 20px #031319;
}

.btn-glass {
    background: rgba(255,255,255,0.1);
    backdrop-filter: blur(10px);
    border: 1px solid rgba(255,255,255,0.2);
    color: #fff;
    padding: 15px 35px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: bold;
    transition: 0.3s;
}

/* .btn-primary:hover { transform: translateY(-3px); background: #e03e00; } */
.btn-glass:hover { background: rgba(255,255,255,0.2); }

/* Hero Stats Overlay */
.hero-stats {
    position: absolute;
    bottom: 40px;
    right: 10%;
    display: flex;
    gap: 40px;
    background: rgba(0,0,0,0.5);
    backdrop-filter: blur(15px);
    padding: 20px 40px;
    border-radius: 15px;
    border: 1px solid rgba(255,255,255,0.1);
}

.stat-item { text-align: center; }
/* .stat-item strong { display: block; font-size: 24px; color: #ff4500; } */
.stat-item span { font-size: 12px; text-transform: uppercase; color: #ccc; }

/* Animations */
@keyframes fadeInUp {
    from { opacity: 0; transform: translateY(30px); }
    to { opacity: 1; transform: translateY(0); }
}

:root {
    --gold: #d4af37;
    --accent: #ff4500;
    --dark: #0a0a0a;
    --glass: rgba(255, 255, 255, 0.1);
    --text-muted: #a0a0a0;
}

/* Hero Section Refinement */
.welcome-hero {
    position: relative;
    height: 70vh;
    background: url('https://images.unsplash.com/photo-1614162692292-7ac56d7f7f1e?auto=format&fit=crop&q=80&w=2070') center/cover no-repeat;
    display: flex;
    align-items: center;
    padding: 0 5%;
    margin-bottom: 50px;
    border-radius: 0 0 40px 40px;
    overflow: hidden;
}

.hero-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to right, rgba(0,0,0,0.9) 20%, transparent);
}

.text-gradient {
    /* background: linear-gradient(to right, var(--accent), #ff8c00); */
    -webkit-text-fill-color: transparent;
    font-weight: 900;
}

.hero-badge {
    background: var(--glass);
    backdrop-filter: blur(10px);
    border: 1px solid var(--glass);
    padding: 8px 15px;
    border-radius: 50px;
    font-size: 13px;
    color: #0f3845;
    margin-bottom: 20px;
    display: inline-block;
}

/* Sidebar & Layout */
.category-wrapper {
    display: grid;
    grid-template-columns: 280px 1fr;
    gap: 40px;
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 20px;
}

.sidebar-box {
    position: sticky;
    top: 100px;
    background: #fff;
    padding: 25px;
    border-radius: 20px;
    box-shadow: 0 10px 30px rgba(0,0,0,0.05);
}

/* Custom Checkbox Look */
.custom-cb {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    cursor: pointer;
    transition: 0.3s;
}

.custom-cb:hover { color: var(--accent); }

/* Product Inventory Header */
.inventory-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.sort-dropdown {
    padding: 10px;
    border-radius: 10px;
    border: 1px solid #ddd;
    outline: none;
}

/* Hero Stats Styling */
.hero-stats {
    position: absolute;
    bottom: 30px;
    right: 50px;
    display: flex;
    gap: 30px;
    background: rgba(0,0,0,0.6);
    backdrop-filter: blur(15px);
    padding: 20px 40px;
    border-radius: 20px;
    border: 1px solid var(--glass);
}

.stat-item strong {
    display: block;
    font-size: 22px;
    color: #fff;
}

.stat-item span {
    font-size: 11px;
    text-transform: uppercase;
    color: var(--text-muted);
}