/* General Styles */
body {
    font-family: 'Inter', sans-serif;
    background-color: #f4f6f8;
    color: #333;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

h1, h2, h3, h4, h5, h6 {
    font-weight: 600;
}

/* Navbar */
.navbar {
    background-color: #ff4747 !important; /* AliExpress Red */
}
.navbar-brand {
    font-weight: 700;
}
.search-form .form-control {
    border-radius: 20px 0 0 20px;
    padding-left: 20px;
}
.search-form .btn {
    border-radius: 0 20px 20px 0;
    background-color: #ffc107;
}

/* Category Nav */
.category-nav .nav-link {
    font-size: 0.9rem;
    font-weight: 500;
    transition: color 0.2s ease;
}
.category-nav .nav-link:hover {
    color: #ff4747 !important;
}

/* Product Cards */
.product-card {
    border: none;
    border-radius: 12px;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    overflow: hidden;
    background: #fff;
    height: 100%;
}
.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}
.product-img-wrapper {
    position: relative;
    padding-top: 100%; /* 1:1 Aspect Ratio */
    overflow: hidden;
    background: #f8f9fa;
}
.product-img-wrapper img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}
.product-card:hover .product-img-wrapper img {
    transform: scale(1.05);
}
.discount-badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background-color: #ff4747;
    color: white;
    padding: 4px 8px;
    border-radius: 4px;
    font-size: 0.8rem;
    font-weight: 700;
    z-index: 2;
}
.product-title {
    font-size: 0.95rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;  
    overflow: hidden;
    margin-bottom: 0.5rem;
    color: #333;
    text-decoration: none;
}
.product-title:hover {
    color: #ff4747;
}
.price-current {
    font-size: 1.25rem;
    font-weight: 700;
    color: #ff4747;
}
.price-old {
    font-size: 0.9rem;
    color: #999;
    text-decoration: line-through;
}

/* Action Buttons */
.btn-wishlist {
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid #ddd;
    border-radius: 50%;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #666;
    transition: all 0.2s;
    cursor: pointer;
}
.btn-wishlist:hover, .btn-wishlist.active {
    background: #ffebeb;
    color: #ff4747;
    border-color: #ff4747;
}

/* Loader */
.skeleton {
    background-color: #e2e5e7;
    background-image: linear-gradient(90deg, rgba(255, 255, 255, 0), rgba(255, 255, 255, 0.5), rgba(255, 255, 255, 0));
    background-size: 40px 100%;
    background-repeat: no-repeat;
    background-position: left -40px top 0;
    animation: shine 1.2s ease-in-out infinite;
}
@keyframes shine {
    to { background-position: right -40px top 0; }
}

/* Single Product Page */
.product-gallery {
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid #eee;
    background: #fff;
}
.thumbnail-img {
    cursor: pointer;
    border: 2px solid transparent;
    border-radius: 8px;
    opacity: 0.7;
    transition: all 0.2s;
}
.thumbnail-img:hover, .thumbnail-img.active {
    border-color: #ff4747;
    opacity: 1;
}

/* Utilities */
.text-truncate-2 {
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;  
    overflow: hidden;
}
