/* Reset & Base Styles */
:root {
    --primary-color: #FF6B00;
    --primary-dark: #E05D00;
    --secondary-color: #2E86DE;
    --dark-color: #2C3E50;
    --light-color: #ECF0F1;
    --gray-color: #95A5A6;
    --success-color: #27AE60;
    --danger-color: #E74C3C;
    --warning-color: #F39C12;
    --white: #FFFFFF;
    --black: #000000;
    --text-color: #333333;
    --text-light: #7F8C8D;
    --border-color: #DDDDDD;
    --shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    --transition: all 0.3s ease;
}

* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

html {
    scroll-behavior: smooth;
    font-size: 16px;
}

body {
    font-family: 'Poppins', sans-serif;
    line-height: 1.6;
    color: var(--text-color);
    background-color: var(--white);
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

ul {
    list-style: none;
}

button,
input,
textarea {
    font-family: inherit;
    font-size: inherit;
}

.container {
    width: 100%;
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
}

.skip-link {
    position: absolute;
    top: -40px;
    left: 0;
    background: var(--primary-color);
    color: var(--white);
    padding: 8px;
    z-index: 100;
    transition: var(--transition);
}

.skip-link:focus {
    top: 0;
}

/* Header Styles */
.main-header {
    background-color: var(--white);
    box-shadow: var(--shadow);
    position: sticky;
    top: 0;
    z-index: 1000;
    padding: 15px 0;
}

.main-header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 15px;
}

.logo img {
    height: 40px;
    width: auto;
}

.search-box {
    flex: 1;
    min-width: 250px;
    max-width: 600px;
}

.search-box form {
    display: flex;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    overflow: hidden;
}

.search-box input {
    flex: 1;
    padding: 10px 15px;
    border: none;
    outline: none;
}

.search-box button {
    background-color: var(--primary-color);
    color: var(--white);
    border: none;
    padding: 0 15px;
    cursor: pointer;
    transition: var(--transition);
}

.search-box button:hover {
    background-color: var(--primary-dark);
}

.main-nav ul {
    display: flex;
    gap: 20px;
}

.main-nav a {
    font-weight: 500;
    padding: 5px 0;
    position: relative;
}

.main-nav a:hover,
.main-nav a[aria-current="page"] {
    color: var(--primary-color);
}

.main-nav a[aria-current="page"]::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 2px;
    background-color: var(--primary-color);
}

.user-actions {
    display: flex;
    align-items: center;
    gap: 15px;
}

.user-actions a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    transition: var(--transition);
}

.user-actions a:hover {
    background-color: var(--light-color);
    color: var(--primary-color);
}

.cart-icon {
    position: relative;
}

.cart-count {
    position: absolute;
    top: -5px;
    right: -5px;
    background-color: var(--danger-color);
    color: var(--white);
    font-size: 10px;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Breadcrumb */
.breadcrumb {
    padding: 10px 0;
    background-color: var(--light-color);
    font-size: 14px;
}

.breadcrumb ol {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    list-style: none;
}

.breadcrumb li:not(:last-child)::after {
    content: '>>';
    margin-left: 5px;
    color: var(--gray-color);
}

.breadcrumb a:hover {
    color: var(--primary-color);
    text-decoration: underline;
}

/* Hero Banner */
.hero-banner {
    margin-bottom: 30px;
}

.hero-slider {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.slide img {
    width: 100%;
    object-fit: cover;
}

.slide-content {
    position: absolute;
    top: 50%;
    left: 50px;
    transform: translateY(-50%);
    color: var(--white);
    max-width: 500px;
}

.slide-content h1 {
    font-size: 2.5rem;
    margin-bottom: 15px;
    text-shadow: 1px 1px 3px rgba(0, 0, 0, 0.5);
}

.slide-content p {
    font-size: 1.2rem;
    margin-bottom: 20px;
    text-shadow: 1px 1px 2px rgba(0, 0, 0, 0.5);
}

.btn {
    display: inline-block;
    padding: 10px 20px;
    background-color: var(--primary-color);
    color: var(--white);
    border-radius: 4px;
    font-weight: 500;
    transition: var(--transition);
}

.btn:hover {
    background-color: var(--primary-dark);
    transform: translateY(-2px);
}

/* Section Styles */
.section-title {
    font-size: 1.8rem;
    margin-bottom: 20px;
    position: relative;
    padding-bottom: 10px;
}

.section-title::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 60px;
    height: 3px;
    background-color: var(--primary-color);
}

.section-footer {
    text-align: center;
    margin-top: 20px;
}

.view-all {
    display: inline-block;
    padding: 8px 15px;
    color: var(--primary-color);
    font-weight: 500;
    border: 1px solid var(--primary-color);
    border-radius: 4px;
    transition: var(--transition);
}

.view-all:hover {
    background-color: var(--primary-color);
    color: var(--white);
}

/* Product Categories */
.product-categories {
    margin-bottom: 40px;
}

.categories-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(180px, 1fr));
    gap: 15px;
}

.category-card {
    display: block;
    background-color: var(--white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
    text-align: center;
}

.category-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.category-card img {
    width: 100%;
    height: 120px;
    object-fit: cover;
}

.category-card h3 {
    padding: 15px 10px;
    font-size: 1rem;
    font-weight: 500;
}

/* Product Cards */
.featured-products {
    margin-bottom: 40px;
}

.products-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 20px;
}

.product-card {
    background-color: var(--white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.product-image {
    display: block;
    height: 200px;
    overflow: hidden;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.product-card:hover .product-image img {
    transform: scale(1.05);
}

.product-info {
    padding: 15px;
}

.product-title {
    font-size: 1rem;
    font-weight: 500;
    margin-bottom: 10px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.product-price {
    margin-bottom: 10px;
}

.current-price {
    font-size: 1.2rem;
    font-weight: 700;
    color: var(--primary-color);
}

.original-price {
    font-size: 0.9rem;
    text-decoration: line-through;
    color: var(--gray-color);
    margin-left: 5px;
}

.product-rating {
    display: flex;
    align-items: center;
    gap: 5px;
    margin-bottom: 10px;
    font-size: 0.9rem;
}

.stars {
    display: flex;
    color: var(--warning-color);
}

.star {
    display: inline-block;
}

.star.filled {
    color: var(--warning-color);
}

.star.half::after {
    content: '★';
    position: absolute;
    width: 50%;
    overflow: hidden;
    color: var(--warning-color);
}

.rating-value {
    font-weight: 500;
    margin-left: 3px;
}

.sold-count {
    color: var(--text-light);
    margin-left: 10px;
}

.product-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 5px;
    margin-top: 10px;
}

.badge {
    display: inline-block;
    padding: 3px 8px;
    font-size: 0.7rem;
    border-radius: 3px;
    font-weight: 500;
}

.badge.free-shipping {
    background-color: rgba(46, 134, 222, 0.1);
    color: var(--secondary-color);
    border: 1px solid var(--secondary-color);
}

.badge.cashback {
    background-color: rgba(39, 174, 96, 0.1);
    color: var(--success-color);
    border: 1px solid var(--success-color);
}

.badge.discount {
    background-color: rgba(231, 76, 60, 0.1);
    color: var(--danger-color);
    border: 1px solid var(--danger-color);
}

/* Promo Section */
.special-promo {
    margin-bottom: 40px;
}

.promo-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.promo-card {
    position: relative;
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow);
}

.promo-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.promo-content {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 20px;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.8), transparent);
    color: var(--white);
}

.promo-content h3 {
    font-size: 1.5rem;
    margin-bottom: 5px;
}

.promo-content p {
    margin-bottom: 15px;
}

.countdown {
    display: flex;
    gap: 5px;
    margin-bottom: 15px;
    font-family: monospace;
    font-size: 1.2rem;
}

/* Blog Section */
.blog-section {
    margin-bottom: 40px;
}

.blog-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.blog-card {
    background-color: var(--white);
    border-radius: 8px;
    overflow: hidden;
    box-shadow: var(--shadow);
    transition: var(--transition);
}

.blog-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.1);
}

.blog-image {
    display: block;
    height: 200px;
    overflow: hidden;
}

.blog-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: var(--transition);
}

.blog-card:hover .blog-image img {
    transform: scale(1.05);
}

.blog-content {
    padding: 20px;
}

.blog-content h3 {
    font-size: 1.2rem;
    margin-bottom: 10px;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.blog-content p {
    color: var(--text-light);
    margin-bottom: 15px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.read-more {
    color: var(--primary-color);
    font-weight: 500;
    display: inline-flex;
    align-items: center;
    gap: 5px;
}

.read-more::after {
    content: '→';
    transition: var(--transition);
}

.read-more:hover::after {
    transform: translateX(3px);
}

/* Footer */
.main-footer {
    background-color: var(--dark-color);
    color: var(--light-color);
    padding: 50px 0 20px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 125px;
    margin-bottom: 30px;
}

.footer-col h3 {
    font-size: 1.2rem;
    margin-bottom: 15px;
    color: var(--white);
    position: relative;
    padding-bottom: 10px;
}

.footer-col h3::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 40px;
    height: 2px;
    background-color: var(--primary-color);
}

.footer-col ul {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.footer-col a {
    font-size: 0.9rem;
    color: var(--gray-color);
    transition: var(--transition);
}

.footer-col a:hover {
    color: var(--primary-color);
    padding-left: 5px;
}

.social-links {
    display: flex;
    gap: 15px;
    margin-bottom: 20px;
}

.social-links a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: rgba(255, 255, 255, 0.1);
    color: var(--white);
    transition: var(--transition);
}

.social-links a:hover {
    background-color: var(--primary-color);
    transform: translateY(-3px);
}

.app-download {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.app-store img {
    height: 40px;
    width: auto;
    border-radius: 5px;
    transition: var(--transition);
}

.app-store:hover img {
    transform: translateY(-2px);
}

.footer-bottom {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 20px;
    padding-top: 20px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.copyright {
    font-size: 0.9rem;
    color: var(--gray-color);
    text-align: center;
}

.payment-methods {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
    justify-content: center;
}

.payment-methods img {
    height: 25px;
    width: auto;
    filter: grayscale(100%) brightness(1.5);
    opacity: 0.7;
    transition: var(--transition);
}

.payment-methods img:hover {
    filter: none;
    opacity: 1;
}

/* Chat Widget & Back to Top */
.chat-widget {
    position: fixed;
    bottom: 20px;
    right: 20px;
    z-index: 999;
}

.chat-toggle {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background-color: var(--primary-color);
    color: var(--white);
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    transition: var(--transition);
}

.chat-toggle:hover {
    background-color: var(--primary-dark);
    transform: scale(1.1);
}

.back-to-top {
    position: fixed;
    bottom: 90px;
    right: 20px;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    background-color: var(--dark-color);
    color: var(--white);
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    z-index: 998;
}

.back-to-top.visible {
    opacity: 1;
    visibility: visible;
}

.back-to-top:hover {
    background-color: var(--primary-color);
}

/* Responsive Styles */
@media (max-width: 992px) {
    .main-header .container {
        flex-direction: column;
    }

    .search-box {
        width: 100%;
        order: 3;
        margin-top: 15px;
    }

    .main-nav ul {
        gap: 15px;
    }

    .slide-content {
        left: 30px;
    }

    .slide-content h1 {
        font-size: 2rem;
    }
}

@media (max-width: 768px) {
    html {
        font-size: 15px;
    }

    .main-nav {
        width: 100%;
        overflow-x: auto;
        padding-bottom: 10px;
    }

    .main-nav ul {
        gap: 10px;
        padding: 0 10px;
    }

    .slide-content {
        left: 20px;
        max-width: 80%;
    }

    .slide-content h1 {
        font-size: 1.8rem;
    }

    .slide-content p {
        font-size: 1rem;
    }

    .categories-grid {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
    }

    .footer-grid {
        grid-template-columns: 1fr 1fr;
    }
}

@media (max-width: 576px) {
    .slide-content {
        left: 15px;
        max-width: 90%;
    }

    .slide-content h1 {
        font-size: 1.5rem;
    }

    .products-grid {
        grid-template-columns: 1fr 1fr;
        gap: 15px;
    }

    .product-image {
        height: 150px;
    }

    .promo-grid {
        grid-template-columns: 1fr;
    }

    .footer-grid {
        grid-template-columns: 1fr;
    }

    .footer-bottom {
        flex-direction: column;
    }
}

/* Tambahan styling khusus halaman produk */
.product-gallery {
    display: grid;
    grid-template-columns: 100px 1fr;
    gap: 15px;
}

.thumbnail-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.thumbnail {
    border: 1px solid var(--border-color);
    border-radius: 4px;
    cursor: pointer;
    transition: var(--transition);
}

.thumbnail:hover {
    border-color: var(--primary-color);
}

.thumbnail.active {
    border-color: var(--primary-color);
    box-shadow: 0 0 0 2px rgba(255, 107, 0, 0.3);
}

.main-image {
    border-radius: 8px;
    overflow: hidden;
    position: relative;
}

.zoom-hint {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background-color: rgba(0,0,0,0.7);
    color: white;
    padding: 5px 10px;
    border-radius: 4px;
    font-size: 0.8rem;
    display: none;
}

.main-image:hover .zoom-hint {
    display: block;
}

.product-details {
    display: grid;
    grid-template-columns: 1fr 350px;
    gap: 30px;
}

.product-actions {
    background-color: var(--light-color);
    padding: 20px;
    border-radius: 8px;
    position: sticky;
    top: 20px;
}

.price-container {
    margin-bottom: 20px;
}

.current-price {
    font-size: 1.8rem;
    font-weight: 700;
    color: var(--primary-color);
}

.original-price {
    font-size: 1.2rem;
    text-decoration: line-through;
    color: var(--gray-color);
    margin-left: 10px;
}

.discount-badge {
    background-color: var(--danger-color);
    color: white;
    padding: 3px 8px;
    border-radius: 4px;
    font-size: 0.9rem;
    margin-left: 10px;
}

.stock-status {
    display: flex;
    align-items: center;
    gap: 5px;
    margin: 15px 0;
    color: var(--success-color);
    font-weight: 500;
}

.variant-options {
    margin: 20px 0;
}

.variant-title {
    font-weight: 500;
    margin-bottom: 10px;
}

.variant-selector {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
}

.variant-option {
    border: 1px solid var(--border-color);
    padding: 8px 15px;
    border-radius: 4px;
    cursor: pointer;
    transition: var(--transition);
}

.variant-option:hover {
    border-color: var(--primary-color);
}

.variant-option.selected {
    background-color: var(--primary-color);
    color: white;
    border-color: var(--primary-color);
}

.variant-option.disabled {
    opacity: 0.5;
    cursor: not-allowed;
    position: relative;
}

.variant-option.disabled::after {
    content: "";
    position: absolute;
    top: 50%;
    left: 0;
    right: 0;
    height: 1px;
    background-color: var(--danger-color);
    transform: rotate(-5deg);
}

.quantity-selector {
    display: flex;
    align-items: center;
    gap: 10px;
    margin: 20px 0;
}

.quantity-btn {
    width: 40px;
    height: 40px;
    border: 1px solid var(--border-color);
    background-color: white;
    font-size: 1.2rem;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border-radius: 4px;
}

.quantity-input {
    width: 60px;
    height: 40px;
    text-align: center;
    border: 1px solid var(--border-color);
    border-radius: 4px;
}

.action-buttons {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.btn-cart {
    background-color: var(--primary-color);
    color: white;
    border: none;
    padding: 15px;
    border-radius: 4px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
}

.btn-cart:hover {
    background-color: var(--primary-dark);
}

.btn-buy {
    background-color: var(--success-color);
    color: white;
    border: none;
    padding: 15px;
    border-radius: 4px;
    font-weight: 500;
    cursor: pointer;
    transition: var(--transition);
}

.btn-buy:hover {
    background-color: #219653;
}

.delivery-info {
    margin-top: 20px;
    padding-top: 20px;
    border-top: 1px dashed var(--border-color);
}

.delivery-input {
    width: 100%;
    padding: 10px;
    border: 1px solid var(--border-color);
    border-radius: 4px;
    margin-bottom: 10px;
}

.delivery-estimate {
    margin-top: 15px;
    font-size: 0.9rem;
}

.delivery-estimate strong {
    color: var(--primary-color);
}

.product-tabs {
    margin-top: 40px;
}

.tab-header {
    display: flex;
    border-bottom: 1px solid var(--border-color);
}

.tab-btn {
    padding: 15px 25px;
    background: none;
    border: none;
    cursor: pointer;
    font-weight: 500;
    position: relative;
}

.tab-btn.active {
    color: var(--primary-color);
}

.tab-btn.active::after {
    content: "";
    position: absolute;
    bottom: -1px;
    left: 0;
    right: 0;
    height: 3px;
    background-color: var(--primary-color);
}

.tab-content {
    padding: 20px 0;
    display: none;
}

.tab-content.active {
    display: block;
}

.specs-table {
    width: 100%;
    border-collapse: collapse;
}

.specs-table tr:nth-child(even) {
    background-color: var(--light-color);
}

.specs-table td {
    padding: 12px 15px;
    border-bottom: 1px solid var(--border-color);
}

.specs-table td:first-child {
    font-weight: 500;
    width: 30%;
}

.review-item {
    padding: 20px 0;
    border-bottom: 1px solid var(--border-color);
}

.review-header {
    display: flex;
    justify-content: space-between;
    margin-bottom: 10px;
}

.review-author {
    font-weight: 500;
}

.review-date {
    color: var(--gray-color);
    font-size: 0.9rem;
}

.review-images {
    display: flex;
    gap: 10px;
    margin: 10px 0;
    flex-wrap: wrap;
}

.review-image {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 4px;
    cursor: pointer;
}

.related-products {
    margin-top: 50px;
}

@media (max-width: 992px) {
    .product-details {
        grid-template-columns: 1fr;
    }
    
    .product-actions {
        position: static;
    }
}

@media (max-width: 768px) {
    .product-gallery {
        grid-template-columns: 1fr;
    }
    
    .thumbnail-container {
        flex-direction: row;
        order: 2;
        margin-top: 10px;
    }
}