/* Import font from Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght@300;400;500;600;700&display=swap');

/* Basic resets and typography */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', sans-serif;
    line-height: 1.6;
    color: #333333;
    background-color: #f5f5f5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

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

/* --- Shared Styles (from style.css) --- */
/* These are included here for completeness of product-catalog.css.
   In a real project, you might link style.css for main elements
   like header/footer and only put specific product catalog styles here. */

:root {
    --primary-color: #20c997; /* Teal */
    --primary-dark-color: #1a9c78; /* Darker Teal */
    --secondary-color: #ffffff; /* White */
    --text-color: #333333; /* Dark Gray */
    --light-gray: #f5f5f5; /* Light Gray */
    --medium-gray: #6b7280; /* Medium Gray for text */
    --dark-gray: #4b5563; /* Dark Gray for headings */
    --footer-bg: #2d3748; /* Darker gray for footer */
    --red-color: #ef4444; /* Red for badge */
    --yellow-color: #facc15; /* Yellow for stars */
}

.header {
    background-color: var(--secondary-color);
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
    padding: 16px 0;
    position: relative;
}

.header-container {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.logo img {
    width: 100px;
}

.nav-desktop ul {
    list-style: none;
    display: flex;
    gap: 24px;
}

.nav-desktop a {
    text-decoration: none;
    color: var(--medium-gray);
    font-weight: 500;
    transition: color 0.2s ease;
}

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

.header-icons {
    display: flex;
    gap: 16px;
}

.header-icons .icon {
    color: var(--medium-gray);
    font-size: 1.125rem;
    transition: color 0.2s ease;
}

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

.hamburger-menu {
    display: none;
    background: none;
    border: none;
    font-size: 1.5rem;
    color: var(--medium-gray);
    cursor: pointer;
    padding: 8px;
}

.nav-mobile {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background-color: var(--secondary-color);
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    z-index: 1000;
    padding: 10px 0;
}

.nav-mobile.active {
    display: block;
}

.nav-mobile ul {
    list-style: none;
    padding: 10px 20px;
}

.nav-mobile li {
    margin-bottom: 10px;
}

.nav-mobile a {
    text-decoration: none;
    color: var(--dark-gray);
    font-weight: 500;
    display: block;
    padding: 10px 0;
    transition: color 0.2s ease;
}

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

.nav-mobile a i {
    margin-right: 10px;
}

.footer {
    background-color: var(--footer-bg);
    color: var(--medium-gray);
    padding: 60px 0 20px;
}

.footer-container {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 30px;
    padding-bottom: 40px;
}

.footer-column h3 {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--secondary-color);
    margin-bottom: 20px;
}

.footer-column p {
    font-size: 0.9375rem;
    line-height: 1.7;
    margin-bottom: 20px;
}

.footer-column ul {
    list-style: none;
}

.footer-column ul li {
    margin-bottom: 10px;
}

.footer-column ul li i {
    margin-right: 10px;
    color: var(--primary-color);
}

.footer-column ul li a {
    text-decoration: none;
    color: var(--medium-gray);
    font-size: 0.9375rem;
    transition: color 0.2s ease;
}

.footer-column ul li a:hover {
    color: var(--secondary-color);
}

.social-icons {
    display: flex;
    gap: 15px;
}

.social-icon {
    color: var(--medium-gray);
    font-size: 1.25rem;
    transition: color 0.2s ease;
}

.social-icon:hover {
    color: var(--secondary-color);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 20px;
    text-align: center;
    font-size: 0.875rem;
    color: #a0aec0;
}


/* --- Page Title Section --- */
.page-title-section {
    background-color: var(--secondary-color);
    padding: 40px 0;
    text-align: center;
    border-bottom: 1px solid #e0e0e0;
}

.page-title-section h1 {
    font-size: 2.5rem; /* ~40px */
    font-weight: 700;
    color: var(--dark-gray);
}

/* --- Product Catalog Section --- */
.product-catalog-section {
    padding: 50px 0;
    background-color: #f9f9f9;
}

.search-filter-bar {
    display: flex;
    justify-content: center; /* Center the search bar */
    align-items: center;
    gap: 20px;
    margin-bottom: 40px;
}

.search-box {
    display: flex;
    border: 1px solid #ccc;
    border-radius: 9999px; /* Rounded full */
    overflow: hidden;
    width: 100%;
    max-width: 500px; /* Limit search bar width */
}

.search-box input {
    flex-grow: 1;
    border: none;
    padding: 10px 20px;
    font-size: 1rem;
    outline: none;
}

.search-box input::placeholder {
    color: #a0aec0;
}

.search-button {
    background-color: var(--primary-color);
    color: var(--secondary-color);
    border: none;
    padding: 10px 20px;
    cursor: pointer;
    font-size: 1rem;
    transition: background-color 0.2s ease;
}

.search-button:hover {
    background-color: var(--primary-dark-color);
}

.filter-button {
    background-color: var(--secondary-color);
    color: var(--medium-gray);
    border: 1px solid #ccc;
    border-radius: 9999px;
    padding: 10px 18px;
    cursor: pointer;
    font-size: 1rem;
    transition: background-color 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.filter-button:hover {
    background-color: var(--primary-color);
    color: var(--secondary-color);
    border-color: var(--primary-color);
}

.product-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); /* Responsive grid */
    gap: 30px;
    margin-bottom: 50px;
}

.product-card {
    background-color: var(--secondary-color);
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
    overflow: hidden;
    text-align: center;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-card:hover {
    transform: translateY(-8px);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.12);
}

.product-image-wrapper {
    position: relative;
    width: 100%;
    height: 250px; /* Fixed height for consistent image size */
    overflow: hidden;
}

.product-image-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover; /* Cover the area, crop if needed */
}

.discount-badge {
    position: absolute;
    top: 15px;
    left: 15px;
    background-color: var(--red-color);
    color: var(--secondary-color);
    font-weight: 600;
    padding: 6px 12px;
    border-radius: 4px;
    font-size: 0.875rem; /* ~14px */
}

.product-card h3 {
    font-size: 1.375rem; /* ~22px */
    font-weight: 600;
    color: var(--dark-gray);
    margin-top: 20px;
    margin-bottom: 8px;
}

.product-card .price {
    font-size: 1.25rem; /* ~20px */
    font-weight: 700;
    color: var(--primary-color);
    margin-bottom: 15px;
}

.product-card .price s {
    font-size: 1rem; /* ~16px */
    font-weight: 400;
    color: var(--medium-gray);
    margin-left: 8px;
}

.buy-button {
    background-color: var(--primary-color);
    color: var(--secondary-color);
    border: none;
    width: 100%;
    padding: 15px 0;
    font-size: 1.125rem; /* ~18px */
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.2s ease;
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    border-top: 1px solid rgba(255, 255, 255, 0.2); /* Subtle line */
}

.buy-button:hover {
    background-color: var(--primary-dark-color);
}

/* --- Pagination --- */
.pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 10px;
    margin-top: 30px;
}

.page-link {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    background-color: var(--secondary-color);
    color: var(--medium-gray);
    text-decoration: none;
    font-weight: 500;
    transition: background-color 0.2s ease, color 0.2s ease;
    border: 1px solid #e0e0e0;
}

.page-link:hover {
    background-color: var(--primary-color);
    color: var(--secondary-color);
    border-color: var(--primary-color);
}

.page-link.active {
    background-color: var(--primary-color);
    color: var(--secondary-color);
    border-color: var(--primary-color);
    pointer-events: none; /* Disable click on active page */
}

.page-link-dots {
    color: var(--medium-gray);
    font-weight: 500;
}


/* --- Responsive Design --- */

/* Tablet (Max-width 768px) */
@media (max-width: 768px) {
    .header-icons,
    .nav-desktop {
        display: none;
    }

    .hamburger-menu {
        display: block;
    }

    .header-container {
        padding: 0 20px;
    }

    .nav-mobile.active {
        display: block;
    }

    .nav-mobile ul {
        padding: 10px 20px;
    }

    .nav-mobile li {
        margin-bottom: 10px;
    }

    .nav-mobile a {
        padding: 10px 0;
    }

    .product-catalog-section {
        padding: 40px 0;
    }

    .search-filter-bar {
        flex-direction: column; /* Stack search and filter */
        gap: 15px;
        margin-bottom: 30px;
    }

    .search-box {
        max-width: 100%; /* Full width for mobile search */
    }

    .filter-button {
        width: 100%; /* Full width for filter button */
        max-width: 300px; /* Optional: limit width even if full width */
    }

    .product-grid {
        grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); /* Adjust min-width for tablets */
        gap: 20px;
    }

    .product-image-wrapper {
        height: 200px; /* Slightly smaller image height */
    }

    .product-card h3 {
        font-size: 1.2rem;
    }

    .product-card .price {
        font-size: 1.1rem;
    }

    .buy-button {
        font-size: 1rem;
        padding: 12px 0;
    }

    .pagination {
        gap: 8px;
    }

    .page-link {
        width: 36px;
        height: 36px;
        font-size: 0.9rem;
    }

    /* Footer adjustments from style.css */
    .footer-container {
        grid-template-columns: 1fr;
        text-align: center;
    }

    .footer-column ul {
        padding: 0;
    }

    .footer-column ul li {
        justify-content: center;
    }

    .social-icons {
        justify-content: center;
    }
}

/* Handphone (Max-width 480px) */
@media (max-width: 480px) {
    .container {
        padding: 0 15px;
    }

    .page-title-section h1 {
        font-size: 2rem;
        padding: 30px 0;
    }

    .product-catalog-section {
        padding: 30px 0;
    }

    .search-filter-bar {
        margin-bottom: 25px;
        gap: 10px;
    }

    .search-box input,
    .search-button,
    .filter-button {
        padding: 8px 15px;
        font-size: 0.9rem;
    }

    .product-grid {
        grid-template-columns: 1fr; /* Single column for phones */
        gap: 15px;
    }

    .product-image-wrapper {
        height: 220px; /* Adjust height for single column to look good */
    }

    .product-card h3 {
        font-size: 1.1rem;
    }

    .product-card .price {
        font-size: 1rem;
    }

    .buy-button {
        font-size: 0.9rem;
        padding: 10px 0;
    }

    .pagination {
        gap: 5px;
        flex-wrap: wrap; /* Allow pagination items to wrap */
    }

    .page-link {
        width: 32px;
        height: 32px;
        font-size: 0.8rem;
    }

    /* Footer adjustments from style.css */
    .footer {
        padding: 40px 0 15px;
    }

    .footer-column h3 {
        font-size: 1.125rem;
        margin-bottom: 15px;
    }

    .footer-column p,
    .footer-column ul li,
    .footer-bottom p {
        font-size: 0.875rem;
    }
}