/* Mobile App Style CSS - Exact Match to Design */
:root {
    --primary-orange: #D4AF37;
    --secondary-orange: #D4AF37;
    --gradient-orange: linear-gradient(135deg, #D4AF37 0%, #D4AF37 50%, #D4AF37 100%);
    --white: #ffffff;
    --black: #000000;
    --gray-text: #666666;
    --light-gray: #f5f5f5;
    --shadow-card: 0 4px 12px rgba(0,0,0,0.1);
    --border-radius: 12px;
}

/* Reset and Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html, body {
    height: 100%;
    width: 100%;
    overflow-x: hidden;
    margin: 0;
    padding: 0;
    -webkit-overflow-scrolling: touch;
    -webkit-text-size-adjust: 100%;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, sans-serif;
    line-height: 1.6;
    color: var(--black);
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

/* Mobile App Container */
.mobile-app-container {
    background: var(--gradient-orange);
    flex: 1;
    width: 100vw;
    max-width: 100%;
    position: relative;
    padding-bottom: 80px;
    min-height: 100vh;
    min-height: 100dvh; /* Dynamic viewport height for mobile browsers */
    display: flex;
    flex-direction: column;
}

/* Top Header Bar */
.top-header-bar {
    background: #f8f9fa;
    padding: 8px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 12px;
    border-bottom: 1px solid #e9ecef;
    width: 100%;
    flex-shrink: 0;
}

.shipping-notice {
    color: #6c757d;
    font-weight: 500;
}

.auth-links {
    display: flex;
    align-items: center;
    gap: 8px;
}

.auth-link {
    color: #6c757d;
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s ease;
}

.auth-link:hover {
    color: var(--primary-orange);
}

.divider {
    color: #dee2e6;
    margin: 0 4px;
}

/* Main Header */
.main-header {
    background: white;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    box-shadow: 0 2px 4px rgba(0,0,0,0.1);
    width: 100%;
    flex-shrink: 0;
}

.brand-section {
    flex: 1;
}

.brand-name {
    font-size: 24px;
    font-weight: 700;
    color: var(--primary-orange);
    margin: 0;
    letter-spacing: -0.5px;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

.header-btn {
    background: none;
    border: none;
    font-size: 18px;
    color: #6c757d;
    cursor: pointer;
    transition: color 0.3s ease;
    position: relative;
    text-decoration: none;
    padding: 8px;
}

.header-btn:hover {
    color: var(--primary-orange);
}

.cart-count {
    position: absolute;
    top: 0;
    right: 0;
    background: var(--primary-orange);
    color: white;
    font-size: 10px;
    font-weight: 600;
    padding: 2px 6px;
    border-radius: 10px;
    min-width: 16px;
    text-align: center;
    line-height: 1.2;
}

/* Hero Image Section */
.hero-image-section {
    position: relative;
    height: 400px;
    margin: 0;
    border-radius: 0;
    overflow: hidden;
    box-shadow: none;
}

.hero-carousel {
    position: relative;
    width: 100%;
    height: 100%;
}

.hero-slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: opacity 1s ease-in-out;
}

.hero-slide.active {
    opacity: 1;
}

.hero-slide-bg {
    width: 100%;
    height: 100%;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: flex;
    align-items: center;
    justify-content: flex-start;
    padding: 0 30px;
}

/* Modern Slide Content */
.slide-content-modern {
    max-width: 350px;
    color: white;
    text-align: left;
}

.hero-title {
    font-size: 32px;
    font-weight: 700;
    line-height: 1.2;
    margin-bottom: 15px;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.8);
}

.text-highlight {
    color: #D4AF37;
    font-weight: 800;
}

.hero-description {
    font-size: 16px;
    line-height: 1.4;
    opacity: 0.95;
    margin-bottom: 25px;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.8);
}

.hero-btn {
    display: inline-block;
    background: #D4AF37;
    color: white;
    padding: 14px 28px;
    border-radius: 8px;
    text-decoration: none;
    font-weight: 600;
    font-size: 16px;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(255, 107, 53, 0.3);
    text-transform: capitalize;
}

.hero-btn:hover {
    background: #e85a2b;
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(255, 107, 53, 0.4);
    color: white;
    text-decoration: none;
}

.carousel-indicators {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
    z-index: 10;
}

.indicator {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    background: rgba(255,255,255,0.4);
    cursor: pointer;
    transition: all 0.4s ease;
    border: 2px solid rgba(255,255,255,0.6);
}

.indicator.active {
    background: rgba(255, 107, 53, 0.9);
    border-color: white;
    transform: scale(1.3);
    box-shadow: 0 0 10px rgba(255, 107, 53, 0.5);
}

.indicator:hover {
    background: rgba(255,255,255,0.7);
    transform: scale(1.1);
}

/* Section Headers */
.section-header {
    padding: 20px 20px 15px;
    background: rgba(255, 255, 255, 0.95);
    margin: 0 15px 0;
    border-radius: var(--border-radius) var(--border-radius) 0 0;
}

.section-title-row {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 5px;
}

.section-title {
    font-size: 22px;
    font-weight: 700;
    color: var(--black);
    margin: 0;
    display: flex;
    align-items: center;
    gap: 8px;
}

.fire-icon {
    font-size: 18px;
}

.section-subtitle {
    font-size: 14px;
    color: var(--gray-text);
    margin: 0;
}

.view-all-link {
    color: var(--primary-orange);
    text-decoration: none;
    font-weight: 600;
    font-size: 14px;
    display: flex;
    align-items: center;
    gap: 5px;
    transition: color 0.3s ease;
}

.view-all-link:hover {
    color: var(--secondary-orange);
}

/* Clearance Section */
.clearance-section {
    margin: 20px 0;
}

.clearance-carousel-container {
    background: rgba(255, 255, 255, 0.95);
    margin: 0 15px;
    border-radius: 0 0 var(--border-radius) var(--border-radius);
    padding: 15px 10px 20px;
    box-shadow: var(--shadow-card);
}

.clearance-carousel {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    padding: 0 10px;
}

.clearance-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    transition: transform 0.3s ease;
}

.clearance-card:hover {
    transform: translateY(-3px);
}

.clearance-image-container {
    position: relative;
    height: 120px;
    overflow: hidden;
}

.clearance-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

/* Clearance Products Horizontal */
.clearance-products-horizontal {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    padding: 10px 0;
    margin-bottom: 20px;
}

.clearance-product-card {
    background: white;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.product-image-wrapper {
    position: relative;
    height: 120px;
    background: var(--light-gray);
}

.product-img {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.product-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray-text);
    font-size: 24px;
}

.discount-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    background: #e74c3c;
    color: white;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 11px;
    font-weight: 700;
}

.clearance-timer {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    padding: 3px 6px;
    border-radius: 8px;
    font-size: 10px;
    font-weight: 600;
}

.clearance-info {
    padding: 12px;
}

.clearance-title {
    font-size: 13px;
    font-weight: 600;
    margin-bottom: 6px;
    line-height: 1.3;
    height: 32px;
    overflow: hidden;
    color: var(--black);
}

.clearance-price {
    margin-bottom: 10px;
}

.sale-price {
    font-size: 14px;
    font-weight: 700;
    color: #e74c3c;
}

.original-price {
    font-size: 11px;
    text-decoration: line-through;
    color: var(--gray-text);
    margin-left: 5px;
}

.quick-add-btn {
    width: 100%;
    background: var(--primary-orange);
    color: white;
    border: none;
    padding: 8px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 4px;
    transition: background 0.3s ease;
    cursor: pointer;
}

.quick-add-btn:hover {
    background: var(--secondary-orange);
}

/* Categories Section */
.categories-section {
    margin: 25px 0;
    padding: 0 20px;
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
    margin-top: 15px;
}

.category-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    padding: 20px 10px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: var(--border-radius);
    text-decoration: none;
    color: var(--black);
    transition: all 0.3s ease;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.category-card:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
    color: var(--primary-orange);
}

.category-icon {
    font-size: 24px;
    margin-bottom: 8px;
}

.category-name {
    font-size: 12px;
    font-weight: 600;
    text-align: center;
}

/* Products Section */
.products-section {
    margin: 25px 0;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    padding: 15px 20px 20px;
    background: rgba(255, 255, 255, 0.95);
    margin: 0 15px;
    border-radius: 0 0 var(--border-radius) var(--border-radius);
    box-shadow: var(--shadow-card);
}

.product-card {
    background: white;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
    transition: transform 0.3s ease;
}

.product-card:hover {
    transform: translateY(-3px);
}

.product-image-wrapper {
    position: relative;
    height: 140px;
    overflow: hidden;
}

.product-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
    transition: transform 0.3s ease;
}

.product-card:hover .product-image {
    transform: scale(1.05);
}

.product-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 10px;
    font-weight: 600;
    color: white;
}

.product-badge.featured {
    background: var(--primary-orange);
}

.wishlist-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    background: rgba(255, 255, 255, 0.9);
    border: none;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s ease;
    color: var(--gray-text);
}

.wishlist-btn:hover {
    background: white;
    color: #e74c3c;
}

.product-info {
    padding: 12px;
}

.product-link {
    text-decoration: none;
    color: inherit;
}

.product-name {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 6px;
    line-height: 1.3;
    height: 36px;
    overflow: hidden;
    color: var(--black);
}

.product-price {
    font-size: 16px;
    font-weight: 700;
    color: var(--primary-orange);
    margin-bottom: 8px;
}

.product-rating {
    display: flex;
    align-items: center;
    gap: 6px;
    margin-bottom: 10px;
}

.stars {
    display: flex;
    gap: 2px;
}

.stars i {
    font-size: 12px;
    color: #ffc107;
}

.rating-count {
    font-size: 11px;
    color: var(--gray-text);
}

.add-cart-btn {
    width: 100%;
    background: var(--primary-orange);
    color: white;
    border: none;
    padding: 10px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: background 0.3s ease;
    cursor: pointer;
}

.add-cart-btn:hover {
    background: var(--secondary-orange);
}

/* Latest Products Section */
.latest-products-section {
    margin: 25px 0;
}

.latest-carousel-container {
    background: rgba(255, 255, 255, 0.95);
    margin: 0 15px;
    border-radius: 0 0 var(--border-radius) var(--border-radius);
    padding: 15px 10px 20px;
    box-shadow: var(--shadow-card);
}

.latest-carousel {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
    padding: 0 10px;
}

.latest-card {
    background: white;
    border-radius: 12px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    overflow: hidden;
    transition: transform 0.3s ease;
}

.latest-card:hover {
    transform: translateY(-3px);
}

.latest-image-container {
    position: relative;
    height: 110px;
    overflow: hidden;
}

.latest-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.new-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    background: #28a745;
    color: white;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 10px;
    font-weight: 700;
}

.latest-info {
    padding: 10px;
}

.latest-title {
    font-size: 12px;
    font-weight: 600;
    margin-bottom: 6px;
    line-height: 1.3;
    height: 30px;
    overflow: hidden;
    color: var(--black);
}

.latest-price {
    font-size: 13px;
    font-weight: 700;
    color: var(--primary-orange);
    margin-bottom: 8px;
}

.countdown-timer {
    position: absolute;
    bottom: 8px;
    right: 8px;
    background: rgba(0,0,0,0.7);
    color: white;
    padding: 3px 6px;
    border-radius: 8px;
    font-size: 10px;
    font-weight: 600;
}

.product-details {
    padding: 12px;
    text-align: left;
}

.product-title {
    font-size: 12px;
    font-weight: 600;
    color: var(--black);
    margin-bottom: 8px;
    line-height: 1.3;
    height: 32px;
    overflow: hidden;
}

.price-container {
    display: flex;
    flex-direction: column;
    gap: 2px;
    margin-bottom: 10px;
}

.current-price {
    color: var(--primary-orange);
    font-size: 14px;
    font-weight: 700;
}

.original-price {
    color: var(--gray-text);
    font-size: 11px;
    text-decoration: line-through;
}

.add-to-cart-btn {
    background: var(--primary-orange);
    color: white;
    border: none;
    width: 30px;
    height: 30px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 12px;
}

/* View All Clearance */
.view-all-clearance {
    margin-top: 15px;
}

.view-all-btn {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: var(--primary-orange);
    text-decoration: none;
    font-size: 14px;
    font-weight: 600;
    padding: 8px 16px;
    border-radius: 20px;
    background: rgba(255, 107, 53, 0.1);
    transition: all 0.3s ease;
}

.view-all-btn:hover {
    background: rgba(255, 107, 53, 0.2);
    color: var(--primary-orange);
}

/* Trending Section */
.trending-section {
    margin: 30px 20px 20px;
    text-align: center;
}

.trending-header {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.2);
    padding: 8px 16px;
    border-radius: 20px;
    color: white;
    font-size: 14px;
    font-weight: 600;
}

.star-icon {
    font-size: 16px;
}

/* Featured Section */
.featured-section {
    background: var(--light-gray);
    margin-top: 20px;
    padding: 30px 20px;
    border-radius: 25px 25px 0 0;
    min-height: 50vh;
}

.section-title {
    font-size: 24px;
    font-weight: 700;
    color: var(--black);
    margin-bottom: 20px;
    text-align: left;
}

.highlight {
    color: var(--primary-orange);
}

/* Featured Products Grid */
.featured-products-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 15px;
}

.mobile-product-card {
    background: white;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--shadow-card);
    transition: transform 0.3s ease;
}

.mobile-product-card:hover {
    transform: translateY(-3px);
}

.product-image-container {
    position: relative;
    height: 180px;
    background: var(--light-gray);
}

.product-image {
    width: 100%;
    height: 100%;
    object-fit: contain;
}

.image-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--gray-text);
    font-size: 32px;
}

.featured-badge {
    position: absolute;
    top: 8px;
    left: 8px;
    background: var(--primary-orange);
    color: white;
    padding: 4px 8px;
    border-radius: 12px;
    font-size: 10px;
    font-weight: 600;
}

.wishlist-btn {
    position: absolute;
    top: 8px;
    right: 8px;
    width: 32px;
    height: 32px;
    background: rgba(255, 255, 255, 0.9);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    color: var(--gray-text);
    font-size: 14px;
    transition: all 0.3s ease;
}

.wishlist-btn:hover {
    background: white;
    color: #e74c3c;
}

.product-info-mobile {
    padding: 15px;
}

.product-name-mobile {
    font-size: 14px;
    font-weight: 600;
    color: var(--black);
    margin-bottom: 8px;
    line-height: 1.3;
    height: 36px;
    overflow: hidden;
}

.product-price-mobile {
    color: var(--black);
    font-size: 16px;
    font-weight: 700;
    margin-bottom: 12px;
}

.mobile-add-cart-btn {
    background: var(--primary-orange);
    color: white;
    border: none;
    width: 100%;
    padding: 10px;
    border-radius: 8px;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
    transition: all 0.3s ease;
}

.mobile-add-cart-btn:hover {
    background: var(--secondary-orange);
    transform: translateY(-1px);
}

/* Mobile app compatibility - bottom navigation handled by unified-mobile.css */
/* Remove conflicting navigation styles to allow unified system to work */

/* Ensure mobile app container works with unified navigation */
.mobile-app-container {
    padding-bottom: 80px; /* Space for unified bottom navigation */
}

/* Responsive adjustments */
@media (max-width: 480px) {
    .mobile-app-container {
        padding-bottom: 90px;
    }
    
    .top-header-bar {
        padding: 6px 15px;
        font-size: 11px;
    }
    
    .main-header {
        padding: 12px 15px;
    }
    
    .brand-name {
        font-size: 20px;
    }
    
    .shipping-notice {
        font-size: 11px;
    }
    
    .auth-links {
        font-size: 11px;
    }
    
    .clearance-carousel {
        gap: 10px;
    }
    
    .clearance-card {
        flex: 0 0 120px;
    }
    
    .categories-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 10px;
    }
    
    .category-card {
        padding: 15px 8px;
    }
    
    .category-icon {
        font-size: 20px;
    }
    
    .category-name {
        font-size: 11px;
    }
    
    .products-grid {
        gap: 12px;
        padding: 15px;
    }
    
    .product-card .product-image-wrapper {
        height: 130px;
    }
    
    .latest-carousel {
        gap: 10px;
    }
    
    .latest-card {
        flex: 0 0 120px;
    }
    
    .hero-image-section {
        height: 350px;
    }
    
    .hero-slide-bg {
        padding: 0 20px;
    }
    
    .hero-title {
        font-size: 28px;
    }
    
    .hero-description {
        font-size: 14px;
    }
    
    .hero-btn {
        padding: 12px 24px;
        font-size: 14px;
    }
}

@media (min-width: 481px) and (max-width: 768px) {
    .mobile-app-container {
        padding-bottom: 85px;
    }
    
    .hero-image-section {
        height: 420px;
    }
    
    .hero-title {
        font-size: 36px;
    }
    
    .hero-description {
        font-size: 17px;
    }
}

@media (min-width: 769px) {
    .mobile-app-container {
        max-width: 480px;
        margin: 0 auto;
        box-shadow: 0 0 20px rgba(0,0,0,0.1);
        padding-bottom: 80px;
    }
    
    .bottom-navigation {
        max-width: 480px;
        margin: 0 auto;
        left: 50%;
        transform: translateX(-50%);
    }
}

@media (min-width: 1024px) {
    .mobile-app-container {
        max-width: 520px;
    }
    
    .bottom-navigation {
        max-width: 520px;
    }
}

/* Full viewport height adjustment */
@media screen and (max-height: 600px) {
    .mobile-app-container {
        min-height: 100vh;
        padding-bottom: 70px;
    }
    
    .hero-image-section {
        height: 250px;
    }
}

/* Landscape orientation */
@media screen and (orientation: landscape) and (max-height: 500px) {
    .hero-image-section {
        height: 200px;
        margin: 10px;
    }
    
    .contact-bar {
        padding: 8px 20px;
    }
    
    .mobile-app-container {
        padding-bottom: 70px;
    }
}

/* Form styles */
form {
    margin: 0;
}

button[type="submit"] {
    border: none;
    cursor: pointer;
}

/* Loading and transition effects */
.mobile-product-card,
.clearance-product-card {
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Scrollbar styles for horizontal scroll */
.clearance-carousel::-webkit-scrollbar,
.latest-carousel::-webkit-scrollbar {
    height: 4px;
}

.clearance-carousel::-webkit-scrollbar-track,
.latest-carousel::-webkit-scrollbar-track {
    background: rgba(255, 255, 255, 0.3);
    border-radius: 2px;
}

.clearance-carousel::-webkit-scrollbar-thumb,
.latest-carousel::-webkit-scrollbar-thumb {
    background: rgba(255, 107, 53, 0.5);
    border-radius: 2px;
}

.clearance-carousel::-webkit-scrollbar-thumb:hover,
.latest-carousel::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 107, 53, 0.7);
}

/* Image placeholder styling */
.image-placeholder {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: var(--light-gray);
    color: var(--gray-text);
    font-size: 24px;
}