/* User-Style.css - Mobile Town E-commerce Frontend Styles */
/* Extracted and organized from frontend demo files */

/* ===== GLOBAL STYLES ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}

body {
    background-color: #f8f9fa;
    color: #333;
    line-height: 1.6;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
}

/* ===== HEADER STYLES ===== */
.main-header,
.header {
    background: white;
    border-radius: 12px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    padding: 15px 25px;
    margin-bottom: 30px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
}

.brand {
    display: flex;
    align-items: center;
    gap: 15px;
}

.brand-name {
    font-size: 24px;
    font-weight: 700;
    color: #1a1f36;
    text-decoration: none;
}

.search-container {
    min-width: 200px;
    max-width: 600px;
    margin: 0 20px;
    position: relative;
}

.search-bar {
    width: 100%;
    padding: 12px 20px;
    padding-right: 50px;
    border: 2px solid #e2e8f0;
    border-radius: 8px;
    font-size: 16px;
    transition: all 0.3s ease;
}

.search-bar:focus {
    outline: none;
    border-color: #4a6cf7;
    box-shadow: 0 0 0 3px rgba(74, 108, 247, 0.2);
}

.search-btn {
    position: absolute;
    right: 5px;
    top: 50%;
    transform: translateY(-50%);
    background: #4a6cf7;
    border: none;
    border-radius: 6px;
    color: white;
    width: 40px;
    height: 40px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.search-btn:hover {
    background: #3451c9;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 20px;
}

.action-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-decoration: none;
    color: #4a5568;
    font-size: 14px;
    transition: color 0.3s ease;
}

.action-item:hover {
    color: #4a6cf7;
}

.action-icon {
    font-size: 20px;
    margin-bottom: 4px;
}

.cart-count {
    background: #4a6cf7;
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 12px;
    position: absolute;
    top: -5px;
    right: -5px;
}

.hamburger {
    display: none;
    flex-direction: column;
    justify-content: space-between;
    width: 30px;
    height: 21px;
    cursor: pointer;
}

.hamburger span {
    height: 3px;
    width: 100%;
    background-color: #4a5568;
    border-radius: 3px;
    transition: all 0.3s ease;
}

.cart-wrapper {
    position: relative;
}

/* ===== PAGE HEADER STYLES ===== */
.header {
    text-align: center;
    margin-bottom: 40px;
}

.header h1 {
    color: #2d3748;
    font-size: 2.5rem;
    margin-bottom: 10px;
    font-weight: 700;
}

.header p {
    color: #718096;
    font-size: 1.1rem;
    max-width: 600px;
    margin: 0 auto;
}

/* ===== HERO SLIDER STYLES ===== */
.hero-slider {
    margin-bottom: 50px;
    position: relative;
    height: auto;
    overflow: hidden;
}

.slider {
    position: relative;
    max-width: 100%;
    overflow: hidden;
    border-radius: 15px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
}

.slides {
    display: flex;
    transition: transform 0.5s ease-in-out;
}

.slide {
    width: 100%;
    flex-shrink: 0;
    display: flex;
    justify-content: center;
    align-items: center;
}

.slide img {
    width: 100%;
    max-width: 1500px;
    aspect-ratio: 3 / 1;
    object-fit: cover;
    height: auto;
    display: block;
}

.dots {
    text-align: center;
    margin-top: 15px;
}

.hero-dot {
    height: 10px;
    width: 10px;
    margin: 0 5px;
    background-color: #bbb;
    border-radius: 50%;
    display: inline-block;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

.hero-dot.active {
    background-color: #4a6cf7;
}

/* Hide mobile slider by default */
#slider2 {
    display: none;
}

/* ===== CATEGORIES SECTION ===== */
.categories-section {
    margin-bottom: 50px;
}

.section-title {
    font-size: 28px;
    text-align: center;
    margin-bottom: 30px;
    color: #222;
    position: relative;
    padding-bottom: 15px;
}

.section-title::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, #4a6cf7, #3b5bdb);
    border-radius: 2px;
}

.categories-slider {
    position: relative;
    overflow: hidden;
    padding: 20px 0;
    touch-action: pan-y;
}

.categories-track {
    display: flex;
    transition: transform 0.5s ease;
    cursor: grab;
    gap: 20px;
}

.categories-track:active {
    cursor: grabbing;
}

.category-card {
    flex: 0 0 200px;
    background: white;
    border-radius: 16px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    transition: all 0.3s ease;
    padding: 15px;
    text-align: center;
}

.category-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
}

.category-image {
    width: 100px;
    height: 100px;
    object-fit: cover;
    border-radius: 50%;
    margin: 0 auto 15px;
    border: 3px solid #4a6cf7;
    padding: 3px;
}

.category-content {
    padding: 10px 5px;
}

.category-title {
    font-size: 16px;
    font-weight: 600;
    margin-bottom: 8px;
    color: #222;
}

.category-offer {
    font-size: 13px;
    color: #e74c3c;
    font-weight: 500;
    margin-bottom: 12px;
}

.shop-btn {
    display: inline-block;
    padding: 6px 14px;
    background: #4a6cf7;
    color: white;
    border-radius: 20px;
    text-decoration: none;
    font-size: 13px;
    font-weight: 500;
    transition: background 0.3s ease;
}

.shop-btn:hover {
    background: #3451c9;
    color: white;
}

.slider-dots {
    display: flex;
    justify-content: center;
    margin-top: 30px;
    gap: 10px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: #ddd;
    cursor: pointer;
    transition: background 0.3s ease;
}

.dot.active {
    background: #4a6cf7;
}

/* ===== PRODUCTS GRID ===== */
.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 25px;
    margin-top: 30px;
}

.product-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.07);
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 20px rgba(0, 0, 0, 0.1);
}

.product-image {
    height: 250px;
    overflow: hidden;
    position: relative;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.discount-badge {
    position: absolute;
    top: 15px;
    right: 15px;
    background: #4a6cf7;
    color: white;
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
}

.product-info {
    padding: 20px;
}

.product-title {
    font-size: 18px;
    font-weight: 600;
    color: #2d3748;
    margin-bottom: 12px;
    height: 50px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-box-orient: vertical;
}

.product-price {
    display: flex;
    align-items: center;
    margin-bottom: 5px;
}

.current-price {
    font-size: 20px;
    font-weight: 700;
    color: #1a1f36;
}

.original-price {
    font-size: 16px;
    color: #a0aec0;
    text-decoration: line-through;
    margin-left: 10px;
}

.discount-text {
    color: #4a6cf7;
    font-size: 14px;
    font-weight: 600;
}

/* ===== TOP BRANDS SECTION ===== */
.top-brands-section {
    margin: 50px 0;
    padding: 20px 0;
}

.brands-title {
    text-align: center;
    font-size: 28px;
    margin-bottom: 30px;
    color: #222;
    position: relative;
    padding-bottom: 15px;
}

.brands-title::after {
    content: "";
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 80px;
    height: 4px;
    background: linear-gradient(90deg, #4a6cf7, #3b5bdb);
    border-radius: 2px;
}

.brands-container {
    overflow: hidden;
    position: relative;
    padding: 15px 0;
}

.brands-track {
    display: flex;
    animation: scroll 30s linear infinite;
    width: max-content;
}

.brand-item {
    flex: 0 0 auto;
    margin: 0 25px;
    display: flex;
    align-items: center;
    justify-content: center;
}

.brand-logo {
    max-height: 60px;
    width: auto;
    object-fit: contain;
    filter: grayscale(100%);
    opacity: 0.7;
    transition: all 0.3s ease;
}

.brand-logo:hover {
    filter: grayscale(0%);
    opacity: 1;
    transform: scale(1.05);
}

@keyframes scroll {
    0% {
        transform: translateX(0);
    }
    100% {
        transform: translateX(-50%);
    }
}

.brands-container:hover .brands-track {
    animation-play-state: paused;
}

/* ===== ASSURED CARDS ===== */
.assured-card {
    background: #fff;
    border-radius: 16px;
    padding: 2rem;
    box-shadow: 0 10px 30px rgba(0,0,0,.1);
    height: 100%;
    transition: transform .3s;
    border: 1px solid #f1f5f9;
}

.assured-card:hover {
    transform: translateY(-5px);
}

.assured-icon {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto;
    background: #f8fafc;
}

/* ===== FEATURES STRIP ===== */
.features {
    background: #0f172a;
    color: #fff;
}

.feat-item {
    border-right: 1px solid rgba(255,255,255,.1);
}

/* ===== DEAL BADGE ===== */
.deal-badge {
    background: #e74c3c;
    color: white;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 600;
    display: inline-block;
    margin-bottom: 10px;
}

/* ===== FOOTER STYLES ===== */
.footer {
    background: #1a1f36;
    color: white;
    border-radius: 12px;
    padding: 40px 20px 20px;
    margin-top: 30px;
}

.footer-top {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 30px;
    margin-bottom: 40px;
}

.footer-column h3 {
    font-size: 18px;
    margin-bottom: 20px;
    color: #fff;
    position: relative;
    padding-bottom: 10px;
}

.footer-column h3:after {
    content: '';
    position: absolute;
    left: 0;
    bottom: 0;
    width: 40px;
    height: 2px;
    background: #4a6cf7;
}

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 12px;
}

.footer-links a {
    color: #a0aec0;
    text-decoration: none;
    transition: color 0.3s ease;
    display: inline-block;
}

.footer-links a:hover {
    color: #4a6cf7;
    transform: translateX(5px);
}

.footer-newsletter p {
    color: #a0aec0;
    margin-bottom: 20px;
    line-height: 1.6;
}

.newsletter-form {
    display: flex;
    gap: 10px;
}

.newsletter-input {
    flex: 1;
    padding: 12px 15px;
    border: none;
    border-radius: 6px;
    background: #2d3748;
    color: white;
}

.newsletter-input:focus {
    outline: none;
    box-shadow: 0 0 0 2px #4a6cf7;
}

.newsletter-btn {
    background: #4a6cf7;
    color: white;
    border: none;
    border-radius: 6px;
    padding: 0 20px;
    cursor: pointer;
    transition: background 0.3s ease;
}

.newsletter-btn:hover {
    background: #3451c9;
}

.footer-social {
    display: flex;
    gap: 15px;
    margin-top: 20px;
}

.social-icon {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background: #2d3748;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    text-decoration: none;
    transition: all 0.3s ease;
}

.social-icon:hover {
    background: #4a6cf7;
    transform: translateY(-3px);
}

.footer-bottom {
    border-top: 1px solid #2d3748;
    padding-top: 20px;
    display: flex;
    flex-wrap: wrap;
    justify-content: space-between;
    align-items: center;
}

.footer-copyright {
    color: #a0aec0;
}

.footer-payment {
    display: flex;
    gap: 10px;
    margin-top: 10px;
}

.payment-method {
    width: 50px;
    height: 30px;
    background: #2d3748;
    border-radius: 4px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #a0aec0;
}

.footer-app {
    display: flex;
    gap: 15px;
    margin-top: 15px;
}

.app-download {
    display: flex;
    align-items: center;
    gap: 10px;
    background: #2d3748;
    padding: 8px 15px;
    border-radius: 6px;
    text-decoration: none;
    color: white;
    transition: background 0.3s ease;
}

.app-download:hover {
    background: #4a6cf7;
}

.app-icon {
    font-size: 24px;
}

/* ===== RESPONSIVE STYLES ===== */
@media (min-width: 768px) {
    .search-container {
        flex: 1;
    }
}

@media (max-width: 1024px) {
    .category-card {
        flex: 0 0 calc(25% - 20px);
    }
    
    .brand-logo {
        height: 50px;
    }
}

@media (max-width: 768px) {
    .category-card {
        flex: 0 0 calc(33.333% - 20px);
    }
    
    .header h1 {
        font-size: 2rem;
    }
    
    .products-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 15px;
    }
    
    /* Show mobile slider and hide desktop slider */
    #slider1 {
        display: none;
    }

    #slider2 {
        display: block;
    }

    #slider2 .slide img {
        aspect-ratio: 1 / 1;
        object-fit: cover;
        border-radius: 15px;
    }
    
    .brand-logo {
        height: 40px;
    }
    
    .search-container {
        order: 3;
        width: 100%;
        max-width: none;
        margin: 15px 0 0 0;
    }
    
    .hamburger {
        display: flex;
    }
    
    .brand-name {
        font-size: 20px;
    }
    
    .action-item span {
        display: none;
    }
    
    .action-item {
        font-size: 18px;
    }

    .main-header,
    .header {
        justify-content: space-between;
    }

    .brand {
        flex: 1;
        justify-content: center;
        position: relative;
    }

    .hamburger {
        position: absolute;
        left: 0;
    }

    .header-actions {
        right: 20px;
    }

    .brand-name {
        font-size: 20px;
        text-align: center;
    }
}

@media (max-width: 576px) {
    .category-card {
        flex: 0 0 calc(50% - 20px);
    }
    
    .category-title {
        font-size: 15px;
    }
    
    .category-image {
        width: 80px;
        height: 80px;
    }
    
    .header h1 {
        font-size: 1.8rem;
    }
    
    .products-grid {
        grid-template-columns: 1fr;
    }
    
    .product-title {
        font-size: 16px;
    }
    
    .current-price {
        font-size: 18px;
    }
    
    .brand-logo {
        height: 30px;
        margin: 0 15px;
    }
    
    .brands-title {
        font-size: 24px;
    }
}