/* ===== VARIABEL CSS ===== */
:root {
    /* Warna */
    --primary-color: #E53935; /* Warna Merah */
    --primary-color-dark: #C62828;
    --primary-color-light: #FFEBEE;
    --secondary-color: #FF6B6B;
    --text-color: #333333;
    --text-color-light: #666666;
    --background-color: #FFFFFF;
    --background-color-alt: #F9F9F9;
    --border-color: #EEEEEE;
    --success-color: #4CAF50;
    --warning-color: #FFC107;
    --error-color: #F44336;
    
    /* Tipografi */
    --body-font: 'Poppins', sans-serif;
    --h1-font-size: 2.5rem;
    --h2-font-size: 2rem;
    --h3-font-size: 1.25rem;
    --normal-font-size: 1rem;
    --small-font-size: 0.875rem;
    --smaller-font-size: 0.75rem;
    
    /* Font Weight */
    --font-light: 300;
    --font-regular: 400;
    --font-medium: 500;
    --font-semi-bold: 600;
    --font-bold: 700;
    
    /* Margin */
    --mb-1: 0.5rem;
    --mb-2: 1rem;
    --mb-3: 1.5rem;
    --mb-4: 2rem;
    --mb-5: 2.5rem;
    --mb-6: 3rem;
    
    /* z-index */
    --z-tooltip: 10;
    --z-fixed: 100;
    
    /* Border Radius */
    --border-radius-sm: 0.25rem;
    --border-radius: 0.5rem;
    --border-radius-lg: 1rem;
    
    /* Box Shadow */
    --box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    --box-shadow-hover: 0 10px 20px rgba(0, 0, 0, 0.1);
}

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

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--body-font);
    font-size: var(--normal-font-size);
    color: var(--text-color);
    line-height: 1.6;
    background-color: var(--background-color);
}

h1, h2, h3, h4 {
    font-weight: var(--font-semi-bold);
    color: var(--text-color);
}

ul {
    list-style: none;
}

a {
    text-decoration: none;
    color: var(--text-color);
    transition: all 0.3s ease;
}

a:hover {
    color: var(--primary-color);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* ===== LAYOUT ===== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.section {
    padding: 5rem 0;
}

.section-header {
    text-align: center;
    margin-bottom: var(--mb-5);
}

.section-header h2 {
    font-size: var(--h2-font-size);
    color: var(--text-color);
    margin-bottom: var(--mb-1);
    position: relative;
    padding-bottom: 1rem;
}

.section-header h2::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    width: 50px;
    height: 3px;
    background-color: var(--primary-color);
}

.section-header p {
    color: var(--text-color-light);
}

/* ===== BUTTONS ===== */
.btn {
    display: inline-block;
    padding: 0.75rem 1.5rem;
    border-radius: var(--border-radius);
    font-weight: var(--font-medium);
    transition: all 0.3s ease;
    cursor: pointer;
    text-align: center;
}

.btn-primary {
    background-color: #dc3545;
    border-color: #dc3545;
}

.btn-primary:hover {
    background-color: #c82333;
    border-color: #bd2130;
}

.btn-secondary {
    background-color: transparent;
    color: var(--primary-color);
    border: 2px solid var(--primary-color);
}

.btn-secondary:hover {
    background-color: var(--primary-color-light);
    color: var(--primary-color-dark);
    transform: translateY(-3px);
    box-shadow: var(--box-shadow);
}

.btn-outline {
    background-color: transparent;
    color: var(--text-color);
    border: 2px solid var(--border-color);
}

.btn-outline:hover {
    border-color: var(--primary-color);
    color: var(--primary-color);
    transform: translateY(-3px);
}

.btn-white {
    background-color: white;
    color: var(--primary-color);
    border: 2px solid white;
}

.btn-white:hover {
    background-color: transparent;
    color: white;
    transform: translateY(-3px);
    box-shadow: var(--box-shadow);
}

/* ===== HEADER ===== */
header {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    background-color: var(--background-color);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    z-index: var(--z-fixed);
    transition: all 0.3s ease;
}

.header-wrapper {
    display: flex;
    justify-content: space-between;
    align-items: center;
    height: 100px;
    padding: 10px 0;
}

.logo {
    display: flex;
    align-items: center;
}

.logo img {
    max-height: 200px;
    width: auto;
}

.logo h1 {
    font-size: 1.5rem;
    font-weight: var(--font-bold);
    color: var(--primary-color);
}

nav ul {
    display: flex;
}

nav ul li {
    margin-left: 1.5rem;
}

nav ul li a {
    font-weight: var(--font-medium);
    position: relative;
}

nav ul li a::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 0;
    width: 0;
    height: 2px;
    background-color: var(--primary-color);
    transition: width 0.3s ease;
}

nav ul li a:hover::after,
nav ul li a.active::after {
    width: 100%;
}

.header-icons {
    display: flex;
    align-items: center;
}

.header-icons a {
    margin-left: 1rem;
    font-size: 1.2rem;
    color: var(--text-color);
    position: relative;
}

.header-icons a:hover {
    color: var(--primary-color);
}

.cart-count {
    position: absolute;
    top: -8px;
    right: -8px;
    background-color: var(--primary-color);
    color: white;
    font-size: 0.7rem;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 2px 5px rgba(229, 57, 53, 0.3);
}

.mobile-menu-btn {
    display: none;
    font-size: 1.5rem;
    cursor: pointer;
}

/* ===== HERO SECTION ===== */
.hero {
    padding: 8rem 0 5rem;
    background-color: var(--primary-color-light);
    overflow: hidden;
    background-image: linear-gradient(135deg, var(--primary-color-light) 0%, #FFF5F5 100%);
}

.hero .container {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
    align-items: center;
}

.hero-content h1 {
    font-size: 2.8rem;
    line-height: 1.2;
    margin-bottom: var(--mb-3);
    color: var(--text-color);
}

.hero-content p {
    font-size: 1.1rem;
    color: var(--text-color-light);
    margin-bottom: var(--mb-4);
}

.hero-buttons {
    display: flex;
    gap: 1rem;
}

.hero-image {
    position: relative;
}

.hero-image img {
    border-radius: var(--border-radius-lg);
    box-shadow: var(--box-shadow);
    transition: transform 0.5s ease;
}

.hero-image:hover img {
    transform: scale(1.02);
}

/* ===== FEATURES SECTION ===== */
.features {
    padding: 5rem 0;
    background-color: var(--background-color);
}

.features-wrapper {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
}

.feature-card {
    background-color: white;
    padding: 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    text-align: center;
    transition: all 0.3s ease;
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--box-shadow-hover);
}

.feature-icon {
    width: 70px;
    height: 70px;
    background-color: var(--primary-color-light);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    margin: 0 auto var(--mb-3);
    box-shadow: 0 5px 15px rgba(229, 57, 53, 0.2);
}

.feature-icon i {
    font-size: 1.8rem;
    color: var(--primary-color);
}

.feature-card h3 {
    margin-bottom: var(--mb-2);
    font-size: var(--h3-font-size);
}

.feature-card p {
    color: var(--text-color-light);
}

/* ===== PRODUCTS SECTION ===== */
.products {
    padding: 5rem 0;
    background-color: var(--background-color-alt);
}

.product-categories {
    display: flex;
    justify-content: center;
    margin-bottom: var(--mb-4);
    flex-wrap: wrap;
    gap: 1rem;
}

.category-btn {
    padding: 0.5rem 1.5rem;
    border: 1px solid var(--border-color);
    border-radius: var(--border-radius);
    background-color: transparent;
    color: var(--text-color);
    font-weight: var(--font-medium);
    cursor: pointer;
    transition: all 0.3s ease;
}

.category-btn:hover,
.category-btn.active {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.products-wrapper {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
}

.product-card {
    background-color: white;
    border-radius: var(--border-radius);
    overflow: hidden;
    box-shadow: var(--box-shadow);
    transition: all 0.3s ease;
    position: relative;
}

.product-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--box-shadow-hover);
}

.product-badge {
    position: absolute;
    top: 1rem;
    left: 1rem;
    background-color: var(--primary-color);
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: var(--border-radius-sm);
    font-size: var(--smaller-font-size);
    font-weight: var(--font-medium);
    z-index: 1;
    box-shadow: 0 2px 5px rgba(229, 57, 53, 0.3);
}

.product-image {
    position: relative;
    overflow: hidden;
}

.product-image img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    transition: transform 0.5s ease;
}

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

.product-actions {
    position: absolute;
    bottom: -50px;
    left: 0;
    width: 100%;
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    padding: 1rem;
    background-color: rgba(255, 255, 255, 0.9);
    transition: bottom 0.3s ease;
}

.product-card:hover .product-actions {
    bottom: 0;
}

.product-actions a {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: white;
    display: flex;
    justify-content: center;
    align-items: center;
    color: var(--text-color);
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
    transition: all 0.3s ease;
}

.product-actions a:hover {
    background-color: var(--primary-color);
    color: white;
}

.product-info {
    padding: 1.5rem;
}

.product-info h3 {
    font-size: 1.1rem;
    margin-bottom: var(--mb-1);
    font-weight: var(--font-medium);
}

.product-rating {
    display: flex;
    align-items: center;
    margin-bottom: var(--mb-1);
}

.product-rating i {
    color: #FFD700;
    font-size: var(--small-font-size);
}

.product-rating span {
    margin-left: 0.5rem;
    font-size: var(--smaller-font-size);
    color: var(--text-color-light);
}

.product-price {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.current-price {
    font-size: 1.1rem;
    font-weight: var(--font-semi-bold);
    color: var(--primary-color);
}

.old-price {
    font-size: var(--small-font-size);
    color: var(--text-color-light);
    text-decoration: line-through;
}

.view-more-container {
    text-align: center;
    margin-top: var(--mb-5);
}

/* ===== PROMO BANNER ===== */
.promo-banner {
    padding: 4rem 0;
    background-color: var(--primary-color);
    color: white;
    text-align: center;
    background-image: linear-gradient(to right, var(--primary-color), var(--primary-color-dark));
}

.promo-content h2 {
    color: white;
    font-size: var(--h2-font-size);
    margin-bottom: var(--mb-2);
}

.promo-content p {
    margin-bottom: var(--mb-3);
    font-size: 1.1rem;
}

/* ===== TESTIMONIALS SECTION ===== */
.testimonials {
    padding: 5rem 0;
    background-color: var(--background-color);
}

.testimonials-wrapper {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
}

.testimonial-card {
    background-color: white;
    padding: 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
    transition: all 0.3s ease;
}

.testimonial-card:hover {
    transform: translateY(-10px);
    box-shadow: var(--box-shadow-hover);
}

.testimonial-rating {
    margin-bottom: var(--mb-2);
}

.testimonial-rating i {
    color: #FFD700;
}

.testimonial-text {
    font-style: italic;
    margin-bottom: var(--mb-3);
    color: var(--text-color-light);
}

.testimonial-author {
    display: flex;
    align-items: center;
}

.testimonial-author img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
    margin-right: 1rem;
}

.author-info h4 {
    font-weight: var(--font-medium);
    margin-bottom: 0.25rem;
}

.author-info p {
    font-size: var(--smaller-font-size);
    color: var(--text-color-light);
}

/* ===== PAYMENT & SHIPPING SECTION ===== */
.payment-shipping {
    padding: 5rem 0;
    background-color: var(--background-color-alt);
}

.payment-shipping-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 3rem;
}

.payment-methods,
.shipping-methods {
    background-color: white;
    padding: 2rem;
    border-radius: var(--border-radius);
    box-shadow: var(--box-shadow);
}

.payment-methods h3,
.shipping-methods h3 {
    margin-bottom: var(--mb-3);
    text-align: center;
}

.methods-logos {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 1.5rem;
    align-items: center;
}

.methods-logos img {
    height: 40px;
    object-fit: contain;
    filter: grayscale(100%);
    opacity: 0.7;
    transition: all 0.3s ease;
}

.methods-logos img:hover {
    filter: grayscale(0%);
    opacity: 1;
}

/* ===== CTA SECTION ===== */
.cta {
    padding: 5rem 0;
    background-color: var(--primary-color-dark);
    color: white;
    text-align: center;
    background-image: linear-gradient(to right, var(--primary-color-dark), var(--primary-color));
}

.cta-content h2 {
    color: white;
    font-size: var(--h2-font-size);
    margin-bottom: var(--mb-2);
}

.cta-content p {
    margin-bottom: var(--mb-4);
    font-size: 1.1rem;
    max-width: 700px;
    margin-left: auto;
    margin-right: auto;
}

/* ===== FOOTER ===== */
footer {
    background-color: #222;
    color: #fff;
    padding-top: 5rem;
}

.footer-wrapper {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2rem;
    margin-bottom: 3rem;
}

.footer-about h3,
.footer-links h3,
.footer-category h3,
.footer-contact h3 {
    color: white;
    margin-bottom: var(--mb-3);
    font-size: 1.2rem;
}

.footer-about p {
    margin-bottom: var(--mb-3);
    color: #ccc;
}

.social-media {
    display: flex;
    gap: 1rem;
}

.social-media a {
    width: 40px;
    height: 40px;
    background-color: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    color: white;
    transition: all 0.3s ease;
}

.social-media a:hover {
    background-color: var(--primary-color);
    transform: translateY(-3px);
    box-shadow: 0 5px 15px rgba(229, 57, 53, 0.3);
}

.footer-links ul li,
.footer-category ul li {
    margin-bottom: 0.75rem;
}

.footer-links ul li a,
.footer-category ul li a {
    color: #ccc;
    transition: all 0.3s ease;
}

.footer-links ul li a:hover,
.footer-category ul li a:hover {
    color: var(--primary-color);
    padding-left: 5px;
}

.footer-contact ul li {
    display: flex;
    align-items: flex-start;
    margin-bottom: 1rem;
    color: #ccc;
}

.footer-contact ul li i {
    margin-right: 1rem;
    color: var(--primary-color);
    text-shadow: 0 0 5px rgba(229, 57, 53, 0.2);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding: 1.5rem 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: wrap;
    gap: 1rem;
}

.footer-bottom p {
    color: #ccc;
}

.footer-bottom-links {
    display: flex;
    gap: 1.5rem;
}

.footer-bottom-links a {
    color: #ccc;
    font-size: var(--small-font-size);
}

.footer-bottom-links a:hover {
    color: var(--primary-color);
}

/* ===== BACK TO TOP BUTTON ===== */
.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 50px;
    height: 50px;
    background-color: var(--primary-color);
    color: white;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 1.2rem;
    box-shadow: 0 5px 15px rgba(229, 57, 53, 0.3);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    z-index: var(--z-tooltip);
}

.back-to-top.active {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background-color: var(--primary-color-dark);
    transform: translateY(-5px);
}

/* ===== RESPONSIVE DESIGN ===== */
@media screen and (max-width: 1024px) {
    :root {
        --h1-font-size: 2.25rem;
        --h2-font-size: 1.75rem;
    }
    
    .features-wrapper,
    .products-wrapper,
    .testimonials-wrapper,
    .footer-wrapper {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media screen and (max-width: 768px) {
    .container {
        padding: 0 1rem;
    }
    
    .hero .container {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .hero-content {
        order: 2;
    }
    
    .hero-image {
        order: 1;
        margin-bottom: var(--mb-4);
    }
    
    .hero-buttons {
        justify-content: center;
    }
    
    .payment-shipping-wrapper {
        grid-template-columns: 1fr;
    }
    
    nav {
        position: fixed;
        top: 80px;
        left: -100%;
        width: 80%;
        height: calc(100vh - 80px);
        background-color: var(--background-color);
        padding: 2rem;
        box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
        transition: left 0.3s ease;
    }
    
    nav.active {
        left: 0;
    }
    
    nav ul {
        flex-direction: column;
    }
    
    nav ul li {
        margin: 1.5rem 0;
        margin-left: 0;
    }
    
    .mobile-menu-btn {
        display: block;
    }
}

@media screen and (max-width: 576px) {
    :root {
        --h1-font-size: 2rem;
        --h2-font-size: 1.5rem;
        --h3-font-size: 1.1rem;
    }
    
    .features-wrapper,
    .products-wrapper,
    .testimonials-wrapper,
    .footer-wrapper {
        grid-template-columns: 1fr;
    }
    
    .footer-bottom {
        flex-direction: column;
        text-align: center;
    }
    
    .footer-bottom-links {
        justify-content: center;
    }
}