/* themes/modave-default/assets/css/style.css */

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

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
    background-color: #ffffff;
    color: #1a1a1a;
    overflow-x: hidden;
}

:root {
    --primary-color: #1a1a1a;
    --secondary-color: #ff4757;
    --success-color: #27ae60;
    --warning-color: #ffa500;
    --add-to-cart-hover: #333;
    --marquee-bg-color: #000000;
    --marquee-text-color: #ffffff;
    --slider-title-font: 'Montserrat', sans-serif;
    --slider-title-color: #ffffff;
    --slider-subtitle-color: #ffffff;
    --slider-button-bg: #ffffff;
    --slider-button-text: #333333;
    --slider-button-hover: #f0f0f0;
}

.top-banner {
    background: var(--marquee-bg-color);
    color: var(--marquee-text-color);
    padding: 12px 0;
    overflow: hidden;
    position: relative;
    width: 100%;
}

.marquee-container {
    width: 100%;
    overflow: hidden;
}

.marquee {
    display: inline-block;
    white-space: nowrap;
    animation: marqueeScroll 35s linear infinite;
    font-size: 15px;
    font-weight: 700;
    will-change: transform;
}

@keyframes marqueeScroll {
    0% {
        transform: translateX(100vw);
    }
    100% {
        transform: translateX(-100%);
    }
}

.header {
    background: white;
    border-bottom: 1px solid #f0f0f0;
    padding: 15px 0;
    position: sticky;
    top: 0;
    z-index: 1000;
    transition: box-shadow 0.3s ease;
}

.header-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: grid;
    grid-template-columns: 60px 1fr 120px;
    align-items: center;
}

.menu-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    transition: background 0.3s;
    justify-self: start;
    color: #1a1a1a;
}

.menu-btn:hover {
    background: #f8f8f8;
}

.menu-btn svg {
    stroke-width: 3;
}

.logo {
    font-size: 28px;
    font-weight: 700;
    color: var(--primary-color);
    text-decoration: none;
    letter-spacing: -1px;
    justify-self: center;
    margin-left: 30px;
}

.header-actions {
    display: flex;
    align-items: center;
    gap: 8px;
    justify-self: end;
}

.header-btn {
    background: none;
    border: none;
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    transition: background 0.3s;
    color: #1a1a1a;
}

.header-btn:hover {
    background: #f8f8f8;
}

.header-btn svg {
    stroke-width: 2.5;
}

.cart-count {
    position: absolute;
    top: -5px;
    right: -5px;
    background: var(--secondary-color);
    color: white;
    border-radius: 50%;
    width: 18px;
    height: 18px;
    font-size: 11px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 600;
}

.stories {
    padding: 20px 20px 15px;
    background: white;
}

.stories-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    gap: 20px;
    overflow-x: auto;
    padding-bottom: 5px;
    justify-content: center;
}

.stories-container::-webkit-scrollbar {
    display: none;
}

.story {
    min-width: 85px;
    text-align: center;
    cursor: pointer;
}

.story-image {
    width: 80px;
    height: 80px;
    border-radius: 50%;
    background: #f8f9fa;
    margin: 0 auto 12px;
    border: 2px solid #e9ecef;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.3s;
    background-size: cover;
    background-position: center;
}

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

.story-title {
    font-size: 12px;
    font-weight: 500;
    color: #666;
    line-height: 1.2;
}

.slider-section {
    position: relative;
    margin-bottom: 0;
}

.slider {
    position: relative;
    height: 400px;
    overflow: hidden;
}

.slide {
    position: absolute;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: all 0.7s cubic-bezier(0.4, 0, 0.2, 1);
    transform: translateX(100%);
    background-size: cover;
    background-position: center;
}

.slide.active {
    opacity: 1;
    transform: translateX(0);
}

.slide.prev {
    transform: translateX(-100%);
    opacity: 0;
}

.slide-content {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: flex-end;
    color: white;
    padding: 40px;
    pointer-events: none;
}

.slide-text {
    max-width: 600px;
    pointer-events: auto;
}

.slide-title {
    font-family: 'Inter', system-ui, -apple-system, sans-serif;
    font-size: 32px;
    font-weight: 800;
    margin-bottom: 15px;
    line-height: 1.1;
    letter-spacing: -0.01em;
    color: var(--slider-title-color);
    text-shadow: 0 2px 4px rgba(0,0,0,0.3);
}

.slide-subtitle {
    font-size: 18px;
    margin-bottom: 25px;
    opacity: 0.95;
    color: var(--slider-subtitle-color);
    font-weight: 500;
    line-height: 1.3;
}

.slide-btn {
    background: var(--slider-button-bg);
    color: var(--slider-button-text);
    border: none;
    padding: 12px 28px;
    border-radius: 25px;
    font-weight: 700;
    font-size: 15px;
    cursor: pointer;
    transition: all 0.3s ease;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    position: relative;
    overflow: hidden;
    width: auto;
    min-width: auto;
    box-shadow: 0 2px 8px rgba(0,0,0,0.2);
}

.slide-btn:hover {
    transform: translateY(-2px);
    background: var(--slider-button-hover);
    box-shadow: 0 4px 12px rgba(0,0,0,0.3);
}

.slide-btn::after {
    content: '';
    width: 14px;
    height: 14px;
    background: currentColor;
    mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12h14'/%3E%3Cpath d='m12 5 7 7-7 7'/%3E%3C/svg%3E") no-repeat center;
    -webkit-mask: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='currentColor' stroke-width='3' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='M5 12h14'/%3E%3Cpath d='m12 5 7 7-7 7'/%3E%3C/svg%3E") no-repeat center;
    mask-size: contain;
    -webkit-mask-size: contain;
    transition: transform 0.3s ease;
}

.slide-btn:hover::after {
    transform: translateX(2px);
}

.slider-dots {
    position: absolute;
    bottom: 25px;
    right: 30px;
    display: flex;
    gap: 8px;
    z-index: 10;
}

.dot {
    width: 8px;
    height: 3px;
    border-radius: 2px;
    background: rgba(255,255,255,0.4);
    cursor: pointer;
    transition: all 0.4s ease;
}

.dot.active {
    width: 24px;
    background: white;
    transform: none;
}

.categories {
    padding: 25px 20px;
    background: #fafafa;
}

.categories-container {
    max-width: 1200px;
    margin: 0 auto;
    position: relative;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 30px;
}

.section-title {
    font-size: 24px;
    font-weight: 700;
    color: #1a1a1a;
}

.nav-arrows {
    display: flex;
    gap: 10px;
}

.nav-arrow {
    width: 40px;
    height: 40px;
    border: 1px solid #ddd;
    border-radius: 50%;
    background: white;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.3s;
    color: #1a1a1a;
    z-index: 10;
}

.nav-arrow:hover {
    background: var(--primary-color);
    color: white;
}

.nav-arrow:disabled {
    opacity: 0.3;
    cursor: not-allowed;
}

.categories-slider {
    overflow-x: auto;
    overflow-y: hidden;
    position: relative;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding-bottom: 10px;
    scroll-behavior: smooth;
}

.categories-slider::-webkit-scrollbar {
    display: none;
}

.categories-grid {
    display: flex;
    gap: 15px;
    width: max-content;
}

.category-card {
    position: relative;
    height: 180px;
    border-radius: 12px;
    overflow: hidden;
    cursor: pointer;
    flex-shrink: 0;
    width: 200px;
}

.category-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
}

.category-name {
    position: absolute;
    bottom: 15px;
    left: 15px;
    color: white;
    font-size: 16px;
    font-weight: 600;
    background: rgba(0,0,0,0.5);
    padding: 8px 14px;
    border-radius: 20px;
    backdrop-filter: blur(8px);
    z-index: 2;
}

.products {
    padding: 25px 20px;
}

.products-container {
    max-width: 1000px;
    margin: 0 auto;
    position: relative;
}

.products-featured .products-slider {
    overflow-x: auto;
    overflow-y: hidden;
    position: relative;
    scrollbar-width: none;
    -ms-overflow-style: none;
    padding-bottom: 10px;
    scroll-behavior: smooth;
}

.products-featured .products-slider::-webkit-scrollbar {
    display: none;
}

.products-featured .products-grid {
    display: flex;
    gap: 15px;
    width: max-content;
}

.products-featured .product-card {
    flex-shrink: 0;
    width: 200px;
}

.products-bestseller .products-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 15px;
    justify-content: center;
}

.product-card {
    background: white;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid #f0f0f0;
    transition: border-color 0.3s;
    cursor: pointer;
    position: relative;
}

.product-card:hover {
    border-color: #ddd;
}

.product-image {
    height: 220px;
    background: #f8f9fa;
    position: relative;
    background-size: cover;
    background-position: center;
}

.product-badge-image {
    position: absolute;
    top: 8px;
    left: 8px;
    width: 55px;
    height: 55px;
    object-fit: contain;
    z-index: 3;
    filter: drop-shadow(0 2px 4px rgba(0,0,0,0.2));
}


.product-rating {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(255,255,255,0.9);
    padding: 4px 6px;
    border-radius: 6px;
    font-size: 12px;
    font-weight: 600;
    color: var(--warning-color);
}

.product-overlay {
    position: absolute;
    bottom: 12px;
    right: 12px;
    opacity: 0;
    transform: translateX(20px);
    transition: all 0.3s ease;
    z-index: 2;
}

.product-card:hover .product-overlay {
    opacity: 1;
    transform: translateX(0);
}

.add-to-cart-btn {
    background: rgba(255,255,255,0.95);
    color: #333;
    border: none;
    padding: 8px 14px;
    border-radius: 20px;
    font-weight: 600;
    cursor: pointer;
    font-size: 12px;
    backdrop-filter: blur(10px);
    transition: all 0.3s;
    box-shadow: 0 2px 10px rgba(0,0,0,0.15);
    display: flex;
    align-items: center;
    gap: 6px;
    white-space: nowrap;
}

.add-to-cart-btn svg {
    width: 14px;
    height: 14px;
    transition: transform 0.3s ease;
    flex-shrink: 0;
}

.add-to-cart-btn:hover {
    background: white;
    transform: scale(1.03);
    box-shadow: 0 4px 15px rgba(0,0,0,0.2);
}

.add-to-cart-btn:hover svg {
    transform: translateX(2px);
}

.product-info {
    padding: 15px;
}

.product-title {
    font-size: 14px;
    font-weight: 600;
    margin-bottom: 8px;
    color: #1a1a1a;
    line-height: 1.3;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    text-overflow: ellipsis;
    min-height: 36px;
    max-height: 36px;
}

.product-footer {
    display: flex;
    justify-content: flex-start;
    align-items: center;
    gap: 12px;
}

.product-price {
    display: flex;
    align-items: center;
    gap: 6px;
}

.price-current {
    font-size: 16px;
    font-weight: 800;
    color: #000000;
}

.price-old {
    font-size: 12px;
    color: #999;
    text-decoration: line-through;
}

.add-to-cart-icon {
    width: 35px;
    height: 35px;
    background: var(--primary-color);
    color: white;
    border: none;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: background 0.3s;
}

.add-to-cart-icon:hover {
    background: var(--add-to-cart-hover);
}

.products-dots {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 20px;
}

.products-dot {
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: rgba(0,0,0,0.3);
    cursor: pointer;
    transition: all 0.3s ease;
}

.products-dot.active {
    background: var(--primary-color);
    transform: scale(1.2);
}

.shipping-info {
    padding: 20px 20px;
    background: white;
    border-top: 1px solid #e9ecef;
    text-align: center;
}

.shipping-container {
    max-width: 1200px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 20px;
}

.shipping-icon {
    color: var(--success-color);
    flex-shrink: 0;
    font-size: 32px;
}

.shipping-content h3 {
    font-size: 18px;
    font-weight: 700;
    color: #1a1a1a;
    margin-bottom: 4px;
}

.shipping-content p {
    font-size: 14px;
    color: #666;
}

.feature-images {
    padding: 20px 20px;
    background: white;
}

.feature-images-container {
    max-width: 900px;
    margin: 0 auto;
}

.feature-images-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

.feature-image {
    height: 280px;
    background: #f8f9fa;
    border-radius: 12px;
    cursor: pointer;
    transition: transform 0.3s;
    background-size: cover;
    background-position: center;
    position: relative;
    overflow: hidden;
}

.feature-image:hover {
    transform: translateY(-3px);
}

.feature-overlay {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    background: linear-gradient(transparent, rgba(0,0,0,0.7));
    color: white;
    padding: 20px;
    transform: translateY(100%);
    transition: transform 0.3s;
}

.feature-image:hover .feature-overlay {
    transform: translateY(0);
}

.feature-overlay h3 {
    font-size: 18px;
    font-weight: 600;
}

.banner-section {
    padding: 25px 20px;
    background: #fafafa;
}

.banner-container {
    max-width: 1200px;
    margin: 0 auto;
}

.banner-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 20px;
}

.banner-item {
    position: relative;
    height: 200px;
    border-radius: 8px;
    overflow: hidden;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: flex-end;
    color: white;
}

.banner-item:hover {
    transform: translateY(-3px);
    box-shadow: 0 10px 30px rgba(0,0,0,0.15);
}

.banner-content {
    position: relative;
    padding: 25px;
    z-index: 2;
    width: 100%;
}

.banner-title {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 8px;
    line-height: 1.2;
}

.banner-description {
    font-size: 16px;
    opacity: 0.9;
    line-height: 1.4;
}

.banner-arrow {
    position: absolute;
    bottom: 25px;
    right: 25px;
    width: 50px;
    height: 50px;
    background: rgba(255,255,255,0.15);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.4s ease;
    backdrop-filter: blur(10px);
    z-index: 3;
    overflow: hidden;
}

.banner-arrow-content {
    position: relative;
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.banner-arrow i {
    color: white;
    font-size: 18px;
    transition: all 0.4s ease;
    transform: translateX(0);
}

.banner-arrow-text {
    position: absolute;
    color: white;
    font-size: 12px;
    font-weight: 600;
    white-space: nowrap;
    transform: translateX(100%);
    opacity: 0;
    transition: all 0.4s ease;
}

.banner-item:hover .banner-arrow {
    background: rgba(255,255,255,0.25);
    width: 100px;
}

.banner-item:hover .banner-arrow i {
    transform: translateX(-40px);
    opacity: 0;
}

.banner-item:hover .banner-arrow-text {
    transform: translateX(0);
    opacity: 1;
}

.footer {
    background: #f8f9fa;
    padding: 40px 20px 20px;
    margin-top: 25px;
}

.gallery-thumbnails::-webkit-scrollbar {
    width: 6px;
    height: 6px;
}

.gallery-thumbnails::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.gallery-thumbnails::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 10px;
}

.gallery-thumbnails::-webkit-scrollbar-thumb:hover {
    background: #555;
}

.gallery-slider-container {
    width: 100%;
    overflow: hidden;
}

.gallery-slider {
    display: flex;
    gap: 10px;
    overflow-x: auto;
    overflow-y: hidden;
    padding: 5px 0;
    scrollbar-width: thin;
    scrollbar-color: #888 #f1f1f1;
    scroll-behavior: smooth;
    -webkit-overflow-scrolling: touch;
}

.gallery-slider::-webkit-scrollbar {
    height: 6px;
}

.gallery-slider::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.gallery-slider::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 10px;
}

.gallery-slider::-webkit-scrollbar-thumb:hover {
    background: #555;
}

.gallery-thumb {
    width: 100px;
    height: 100px;
    min-width: 100px;
    object-fit: cover;
    border-radius: 8px;
    cursor: pointer;
    border: 2px solid transparent;
    transition: border-color 0.3s;
}

.footer-container {
    max-width: 1200px;
    margin: 0 auto;
    text-align: center;
}

.footer-logo {
    font-size: 24px;
    font-weight: 700;
    margin-bottom: 15px;
}

.footer-info {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-bottom: 20px;
    flex-wrap: wrap;
}

.footer-item {
    font-size: 14px;
    color: #666;
}

.footer-categories {
    display: flex;
    justify-content: center;
    gap: 20px;
    margin-bottom: 30px;
    flex-wrap: wrap;
}

.footer-link {
    color: #666;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s;
}

.footer-link:hover {
    color: #1a1a1a;
}

.footer-bottom {
    border-top: 1px solid #e9ecef;
    padding-top: 20px;
    color: #999;
    font-size: 14px;
}

@media (min-width: 768px) {
    .products-bestseller .products-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 20px;
    }

    .product-image {
        height: 220px;
    }

    .feature-images-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 15px;
    }

    .banner-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 25px;
    }

    .stories-container {
        justify-content: center;
    }

    .product-badge-image {
        width: 60px;
        height: 60px;
        top: 10px;
        left: 10px;
    }

    .product-detail-badge {
        width: 85px !important;
        height: 85px !important;
    }
}

@media (max-width: 768px) {
    .logo {
        margin-left: 60px;
    }

    .slide-title {
        font-size: 32px;
    }

    .slide-subtitle {
        font-size: 16px;
    }
 
    .footer-info {
        flex-direction: column;
        gap: 10px;
    }

    .footer-categories {
        flex-direction: column;
        gap: 10px;
    }

    .stories-container {
        justify-content: center;
    }

    .feature-images-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .category-card {
        width: calc(50vw - 30px);
        min-width: calc(50vw - 30px);
        max-width: calc(50vw - 30px);
    }

    .products-featured .product-card {
        width: calc(50vw - 30px);
        min-width: calc(50vw - 30px);
        max-width: calc(50vw - 30px);
    }

    .product-detail-badge {
        width: 65px !important;
        height: 65px !important;
        top: 12px !important;
        left: 12px !important;
    }

    .related-products-grid {
        grid-template-columns: repeat(2, 1fr) !important;
    }

    .product-gallery > div {
        flex-direction: column !important;
    }

    .gallery-thumbnails {
        width: 100% !important;
        max-height: none !important;
        overflow-x: auto !important;
        overflow-y: hidden !important;
        margin-top: 15px;
    }

    .gallery-thumbnails > div {
        flex-direction: row !important;
    }

    .main-image {
        height: 400px !important;
    }

    .gallery-slider-container {
        margin-top: 12px !important;
        width: 100%;
        overflow: hidden;
    }

    .gallery-slider {
        gap: 8px;
        padding: 3px 0;
    }

    .gallery-thumb {
        width: 80px !important;
        height: 80px !important;
        min-width: 80px !important;
    }

    .product-main {
        grid-template-columns: 1fr !important;
        gap: 30px !important;
    }

    #image-counter {
        font-size: 12px !important;
        padding: 6px 12px !important;
    }

    #modal-counter {
        font-size: 14px !important;
        padding: 10px 20px !important;
    }
}