/* Enhanced Home Page Styles */

/* Custom red gradient button */
.btn-red {
  background: linear-gradient(120deg, #ff4b2b, #ff416c);
  border: none;
  transition: all 0.3s ease;
}
.btn-red:hover {
  background: linear-gradient(120deg, #ff416c, #ff4b2b);
  transform: translateY(-3px);
  box-shadow: 0 10px 20px rgba(255, 65, 108, 0.4);
}

/* Input focus style */
.form-control:focus {
  border-color: #ff416c;
  box-shadow: 0 0 0 0.25rem rgba(255, 65, 108, 0.2);
}

/* Announcement Bar */
.announcement-bar {
    font-size: 0.8rem;
    border-bottom: 1px solid #333;
}

.announcement-bar a:hover {
    color: #f8f9fa !important;
    text-decoration: underline !important;
}

/* Mini Features Bar */
.mini-features {
    border: 1px solid #e0e0e0;
}

.feature-item {
    flex: 1;
    transition: transform 0.3s ease;
}

.feature-item:hover {
    transform: translateY(-2px);
}

/* Mobile Categories Grid */
.mobile-categories-grid .row {
    overflow-x: auto;
    flex-wrap: nowrap;
    padding-bottom: 10px;
}

.mobile-categories-grid .col-4 {
    min-width: 33.333%;
}

.mobile-category-item {
    color: #333;
    text-decoration: none;
    transition: all 0.3s ease;
    border: 1px solid #f0f0f0;
}

.mobile-category-item:hover {
    transform: translateY(-3px);
    border-color: var(--red);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

/* Daily Deals */
.deal-countdown {
    min-width: 100px;
}

.countdown-timer {
    font-family: 'Courier New', monospace;
    font-size: 1.2rem;
    font-weight: bold;
}

.deal-badge {
    z-index: 1;
    border-radius: 0 0 8px 0;
}

.deal-card .price-section {
    display: flex;
    align-items: center;
    gap: 8px;
}

.deal-card .progress {
    background-color: #e9ecef;
}

/* Trending Products */
.trending-tabs .btn {
    border-radius: 20px;
    padding: 6px 12px;
    font-size: 0.8rem;
}

.trending-card {
    transition: all 0.3s ease;
}

.trending-card:hover {
    transform: scale(1.05);
}

.trending-card .card-title {
    font-size: 0.8rem;
    line-height: 1.2;
    height: 2.4em;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* Supplier Spotlight */
.bg-gradient-red {
    background: linear-gradient(135deg, var(--red) 0%, #c62828 100%);
}

.supplier-stats .stat-item {
    text-align: center;
}

.supplier-stats .stat-number {
    font-weight: 700;
}

.supplier-stats .stat-label {
    font-size: 0.8rem;
    opacity: 0.9;
}

/* Industry Solutions */
.solution-card {
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.solution-card:hover {
    transform: translateY(-5px);
    border-color: var(--red);
}

/* Testimonials */
.testimonial-card {
    transition: all 0.3s ease;
}

.testimonial-card:hover {
    transform: translateY(-3px);
}

.testimonial-author img {
    object-fit: cover;
}

/* Global Reach */
.global-stats {
    background: linear-gradient(135deg, #f8f9fa 0%, #e9ecef 100%);
}

.global-stats .stat-number {
    font-weight: 700;
}

/* Newsletter */
.newsletter-card {
    background: white;
}

/* Enhanced Responsive Design */
@media (max-width: 768px) {
    .announcement-bar .col-md-8 {
        margin-bottom: 5px;
    }
    
    .hero-slider .carousel-item img {
        height: 300px !important;
    }
    
    .mini-features {
        display: none !important;
    }
    
    .deals-header {
        flex-direction: column;
        text-align: center;
        gap: 15px;
    }
    
    .deal-countdown {
        min-width: 80px;
    }
    
    .countdown-timer {
        font-size: 1rem;
    }
    
    .trending-tabs {
        margin-top: 10px;
    }
    
    .trending-tabs .btn-group {
        width: 100%;
    }
    
    .trending-tabs .btn {
        flex: 1;
    }
    
    .supplier-spotlight .row {
        text-align: center;
    }
    
    .supplier-stats {
        justify-content: center;
        gap: 20px;
    }
    
    .global-stats {
        padding: 30px 20px !important;
    }
    
    .global-stats .stat-number {
        font-size: 1.5rem;
    }
    
    .newsletter-card {
        padding: 30px 20px !important;
    }
    
    .newsletter form {
        flex-direction: column;
        gap: 10px;
    }
    
    .newsletter .form-control {
        margin-right: 0 !important;
    }
}

@media (max-width: 576px) {
    .hero-section {
        margin-top: 5px;
    }
    
    .mobile-categories-grid .col-4 {
        min-width: 50%;
    }
    
    .deal-card .card-body {
        padding: 10px;
    }
    
    .trending-card .card-body {
        padding: 8px;
    }
    
    .solution-card {
        padding: 20px 15px !important;
    }
    
    .testimonial-card .card-body {
        padding: 15px;
    }
    
    .app-banner {
        padding: 30px 20px !important;
    }
    
    .app-banner .row {
        text-align: center;
    }
}

/* Touch-friendly improvements for mobile */
@media (hover: none) and (pointer: coarse) {
    .category-item:hover,
    .product-card:hover,
    .quick-access-item:hover,
    .mobile-category-item:hover,
    .solution-card:hover,
    .testimonial-card:hover {
        transform: none;
    }
    
    .card {
        cursor: pointer;
    }
}

/* Loading animations for better mobile experience */
.section-loading {
    opacity: 0;
    transform: translateY(20px);
    animation: fadeInUp 0.6s ease forwards;
}

@keyframes fadeInUp {
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Better touch targets for mobile */
.btn, .card, .nav-link {
    min-height: 44px;
}

.form-control {
    min-height: 44px;
}

/* Smooth scrolling for mobile */
html {
    scroll-behavior: smooth;
}

/* Performance optimizations for mobile */
@media (max-width: 768px) {
    .hero-slider .carousel-item img {
        loading: lazy;
    }
    
    .product-card img,
    .deal-card img,
    .trending-card img {
        loading: lazy;
    }
}

/* Enhanced mobile navigation */
.bottom-nav {
    padding-bottom: env(safe-area-inset-bottom);
}

/* Better text readability on mobile */
@media (max-width: 768px) {
    body {
        font-size: 14px;
    }
    
    .card-title {
        font-size: 0.9rem;
    }
    
    .btn {
        font-size: 0.9rem;
    }
}

/* Improved grid layouts for mobile */
@media (max-width: 576px) {
    .row.g-3 {
        margin-left: -8px;
        margin-right: -8px;
    }
    
    .row.g-3 > [class*="col-"] {
        padding-left: 8px;
        padding-right: 8px;
    }
}

/* Complete Categories Styles */

/* Categories Sidebar Scroll */
.categories-sidebar {
    max-height: 400px;
    overflow-y: auto;
}

/* Category Showcase Cards */
.category-showcase-card {
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.category-showcase-card:hover {
    transform: translateY(-5px);
    border-color: var(--red);
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.15) !important;
}

.category-icon {
    transition: transform 0.3s ease;
}

.category-showcase-card:hover .category-icon {
    transform: scale(1.1);
}

.subcategories a {
    transition: color 0.3s ease;
    text-decoration: none;
}

.subcategories a:hover {
    color: var(--red) !important;
}

/* Industry Spotlight Cards */
.industry-card {
    min-height: 200px;
    transition: transform 0.3s ease;
}

.industry-card:hover {
    transform: translateY(-3px);
}

.bg-gradient-primary {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
}

.bg-gradient-success {
    background: linear-gradient(135deg, #4facfe 0%, #00f2fe 100%);
}

/* Enhanced Mobile Categories */
@media (max-width: 768px) {
    .categories-sidebar {
        display: none;
    }
    
    .all-categories-showcase .col-6 {
        margin-bottom: 15px;
    }
    
    .category-showcase-card {
        padding: 20px 15px !important;
    }
    
    .category-showcase-card h5 {
        font-size: 1rem;
    }
    
    .subcategories a {
        font-size: 0.8rem;
    }
    
    .industry-card {
        margin-bottom: 15px;
        min-height: 180px;
    }
    
    .industry-card h4 {
        font-size: 1.2rem;
    }
    
    .industry-card p {
        font-size: 0.9rem;
    }
}

/* Scrollbar styling for categories sidebar */
.categories-sidebar::-webkit-scrollbar {
    width: 6px;
}

.categories-sidebar::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.categories-sidebar::-webkit-scrollbar-thumb {
    background: var(--red);
    border-radius: 3px;
}

.categories-sidebar::-webkit-scrollbar-thumb:hover {
    background: #b71c1c;
}

/* Category icons colors */
.category-showcase-card .fa-apple-alt { color: #4CAF50; }
.category-showcase-card .fa-tshirt { color: #2196F3; }
.category-showcase-card .fa-mobile-alt { color: #9C27B0; }
.category-showcase-card .fa-tv { color: #FF9800; }
.category-showcase-card .fa-heart { color: #E91E63; }
.category-showcase-card .fa-gamepad { color: #795548; }
.category-showcase-card .fa-couch { color: #8BC34A; }
.category-showcase-card .fa-cogs { color: #607D8B; }
.category-showcase-card .fa-hard-hat { color: #FFC107; }
.category-showcase-card .fa-briefcase { color: #3F51B5; }
.category-showcase-card .fa-box { color: #009688; }
.category-showcase-card .fa-bolt { color: #FF5722; }
.category-showcase-card .fa-palette { color: #E91E63; }
.category-showcase-card .fa-shield-alt { color: #4CAF50; }
.category-showcase-card .fa-tools { color: #795548; }
.category-showcase-card .fa-car { color: #2196F3; }
.category-showcase-card .fa-running { color: #FF9800; }
.category-showcase-card .fa-gift { color: #E91E63; }
.category-showcase-card .fa-flask { color: #009688; }
.category-showcase-card .fa-plug { color: #FFC107; }

/* Mobile optimization for category grid */
@media (max-width: 576px) {
    .all-categories-showcase .row {
        margin-left: -8px;
        margin-right: -8px;
    }
    
    .all-categories-showcase .col-6 {
        padding-left: 8px;
        padding-right: 8px;
    }
    
    .category-showcase-card {
        padding: 15px 10px !important;
    }
    
    .category-icon .fa-3x {
        font-size: 2em !important;
    }
    
    .category-showcase-card h5 {
        font-size: 0.9rem;
        margin-bottom: 15px !important;
    }
}

/* Loading animation for categories */
.category-showcase-card {
    animation: fadeInUp 0.6s ease;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Staggered animation for category cards */
.category-showcase-card:nth-child(1) { animation-delay: 0.1s; }
.category-showcase-card:nth-child(2) { animation-delay: 0.2s; }
.category-showcase-card:nth-child(3) { animation-delay: 0.3s; }
.category-showcase-card:nth-child(4) { animation-delay: 0.4s; }
.category-showcase-card:nth-child(5) { animation-delay: 0.5s; }
.category-showcase-card:nth-child(6) { animation-delay: 0.6s; }
.category-showcase-card:nth-child(7) { animation-delay: 0.7s; }
.category-showcase-card:nth-child(8) { animation-delay: 0.8s; }