﻿@import url('https://fonts.googleapis.com/css2?family=Inter:wght@400;500;600;700&display=swap');

/* ====== RESET ====== */

:root {

    --font-family-base: "Inter", "Segoe UI", Tahoma, sans-serif;

    --text-color: #242d3a;

}

* {

    margin: 0;

    padding: 0;

    box-sizing: border-box;

}

/* ====== BODY ====== */

html {

    scroll-behavior: smooth;

}

body {

    min-height: 100vh;

    display: flex;

    flex-direction: column;

}

main {

    flex: 1 0 auto;

}

.footer-bottom {

    margin-top: auto;

    padding: 20px 16px;

    text-align: center;

    background: #0f8c07;

    color: #ffffff;

    font-size: 14px;

}

body {

    font-family: var(--font-family-base);

    color: var(--text-color);

    background: #f6f6f6;

    line-height: 1.6;

}

/* ====== HEADER ====== */

.header {

    position: relative;

    z-index: 20;

    background-color: white;

    border-bottom: 1px solid #eee;

    padding: 12px 20px;

}

.header .container {

    max-width: 1200px;

    margin: auto;

    display: flex;

    align-items: center;

    justify-content: flex-start;

    gap: 24px;

}

.logo-link {

    display: inline-flex;

    align-items: center;

}

.logo-link:hover {

    opacity: 0.9;

}

.logo {

    height: 40px;

    display: block;

}

.main-nav {
    margin-left: 24px;

    display: flex;

    align-items: center;

    gap: 24px;

    font-weight: 600;

}

.main-nav .nav-link {

    color: var(--text-color);

    text-decoration: none;

    font-size: 15px;

    transition: color 0.2s ease-in-out;

}

.main-nav .nav-link.is-active {

    color: #0eaa00;

}

.main-nav .nav-link:hover,

.main-nav .nav-link:focus {

    color: #0eaa00;

}

.search-box {
    flex: 1 1 320px;
    max-width: 360px;
    width: min(100%, 360px);
    margin-left: auto;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    height: 44px;
    padding: 0 14px;
    border: 1px solid #d7dee6;
    border-radius: 28px;
    background: #fff;
}

.search-box input {
    flex: 1 1 auto;
    width: 100%;
    min-width: 0;
    border: none;
    outline: none;
    background: transparent;
    font-size: 15px;
    line-height: 1.4;
    color: #1f2937;
}

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

.search-btn {
    flex: 0 0 36px;
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: none;
    border-radius: 50%;
    background: transparent;
    color: #0eaa00;
    font-size: 18px;
    cursor: pointer;
    transition: background 0.2s ease, color 0.2s ease;
}

.search-btn:hover,
.search-btn:focus {
    background: rgba(14, 170, 0, 0.12);
    color: #0a7a00;
}

.auth-buttons {

    display: flex;

    gap: 10px;

    z-index: 5;

    pointer-events: auto;

}

.header .container .auth-buttons,

.header .container .user-menu {

    margin-left: 12px;

}

.btn-login {

    background-color: #0eaa00;

    color: white;

    border: none;

    border-radius: 24px;

    padding: 10px 20px;

    cursor: pointer;

    font-size: 14px;

    text-decoration: none;

    display: inline-flex;

    align-items: center;

    justify-content: center;

    font-weight: 600;

}

.btn-register {

    background-color: #f5027b;

    color: white;

    border: none;

    border-radius: 24px;

    padding: 10px 20px;

    cursor: pointer;

    font-size: 14px;

    text-decoration: none;

    display: inline-flex;

    align-items: center;

    justify-content: center;

    font-weight: 600;

}

/* ====== BANNER ====== */

.banner-section {

    background: #f6f6f6;

    padding: 20px 0;

}

.banner-wrapper {

    max-width: 1200px;

    margin: auto;

    border-radius: 12px;

    overflow: hidden;

    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);

}

.banner-wrapper img {

    width: 100%;

    display: block;

    border-radius: 12px;

}

/* ====== SÃ¡ÂºÂ¢N PHÃ¡ÂºÂ¨M ====== */

.product-section {

    background: #f6f6f6;

    padding: 40px 0;

}

.product-grid {

    max-width: 1200px;

    margin: auto;

    display: grid;

    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));

    gap: 24px;

}

.product-card {

    background: white;

    border-radius: 16px;

    overflow: hidden;

    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06);

    display: flex;

    flex-direction: column;

        transition: box-shadow 0.3s ease;

}

.product-card:hover {

    box-shadow: 0 6px 20px rgba(0, 0, 0, 0.1);

}

.product-image {

    position: relative;

    width: 100%;

    aspect-ratio: 16 / 9;   /* khung cÃ¡Â»â€˜ Ã„â€˜Ã¡Â»â€¹nh tÃ¡Â»â€° lÃ¡Â»â€¡ 16:9 */

    overflow: hidden;       /* Ã¡ÂºÂ©n phÃ¡ÂºÂ§n thÃ¡Â»Â«a */

    border-radius: 12px;    /* bo gÃƒÂ³c */

    background: #f8f8f8;    /* nÃ¡Â»Ân xÃƒÂ¡m nhÃ¡ÂºÂ¡t */

    display: flex;

    align-items: center;

    justify-content: center;

    /* Bo trÃƒÂ²n chÃ¡Â»â€° 2 gÃƒÂ³c trÃƒÂªn */

    border-top-left-radius: 16px;

    border-top-right-radius: 16px;

    border-bottom-left-radius: 0;

    border-bottom-right-radius: 0;

    object-fit: cover;

    margin-bottom: 0;

}

.product-image img {

    width: 100%;          /* fit theo chiÃ¡Â»Âu ngang */

        object-fit: cover;    /* cÃ¡ÂºÂ¯t cho vÃ¡Â»Â«a khung, giÃ¡Â»Â¯ tÃ¡Â»â€° lÃ¡Â»â€¡ */

    object-position: center; /* cÃ„Æ’n giÃ¡Â»Â¯a Ã¡ÂºÂ£nh */

    display: block;

}

.product-pin-badge {

    position: absolute;

    top: 12px;

    right: 12px;

    width: 34px;

    height: 34px;

    border-radius: 50%;

    background: rgba(220, 38, 38, 0.12);

    color: #dc2626;

    display: flex;

    align-items: center;

    justify-content: center;

    font-size: 18px;

    box-shadow: 0 6px 16px rgba(220, 38, 38, 0.18);

    pointer-events: none;

    z-index: 2;

}

.product-content {

    padding: 16px;

    display: flex;

    flex-direction: column;

    gap: 10px;

}

.product-title {

    font-size: 16px;

    font-weight: bold;

    margin-bottom: 6px;

}

.product-desc {

    font-size: 13px;

    color: #555;

    line-height: 1.5;

    margin: 0;

}

.product-desc a {

    color: #f5027b;

    font-weight: bold;

    text-decoration: none;

}

/* ====== GIÃƒÂ ====== */

.price-line {

    display: flex;

    justify-content: space-between;

    align-items: center;

    font-size: 14px;

    margin-bottom: 6px;

}

.price-line .left {

    display: flex;

    align-items: center;

    gap: 8px;

}

.original-price {

    text-decoration: line-through;

    color: #555;

}

.discount {

    color: #f5027b;

    font-weight: bold;

    display: flex;

    align-items: center;

    gap: 4px;

}

.discount i {

    font-size: 16px;

}

.new-price {

    font-size: 20px;

    font-weight: bold;

    color: #000;

}

/* ====== BUTTONS ====== */

.product-actions {

    display: grid;

    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));

    gap: 10px;

    margin-top: 10px;

    align-items: stretch;

}

.product-actions .cart-form {

    display: flex;

}

.product-actions .cart-form button {

    width: 100%;

}

.cart-form {

    margin: 0;

    width: 100%;

}

.btn-outline {

    flex: 1;

    background: #fff;

    color: #e60073;

    border: 1.5px solid #e60073;

    border-radius: 32px;

    padding: 10px 14px;

    font-size: 14px;

    font-weight: 500;

    cursor: pointer;

    display: flex;

    align-items: center;

    justify-content: center;

    gap: 6px;

    transition: all 0.2s ease;

}

.btn-outline:hover {

    background: #ffeaf4;

}

.btn-outline i {

    font-size: 14px;

}

.btn-buy {

    display: block;

    width: 100%;                /* trÃƒÂ n ra full chiÃ¡Â»Âu ngang */

    background: #0f8c07;

    color: #fff;

    border: none;

    border-radius: 50px;         /* bo gÃƒÂ³c vÃ¡Â»Â«a phÃ¡ÂºÂ£i */

    padding: 14px 0;            /* chiÃ¡Â»Âu cao thoÃƒÂ¡ng */

    font-size: 16px;

    font-weight: 600;

    cursor: pointer;

    text-align: center;

    margin-top: 0px;           /* khoÃ¡ÂºÂ£ng cÃƒÂ¡ch vÃ¡Â»â€ºi ÃƒÂ´ trÃƒÂªn */

    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.15);

    transition: all 0.25s ease;

}

.btn-buy:hover {

    background: #0c6c05;

    transform: translateY(-2px);

    box-shadow: 0 5px 10px rgba(0, 0, 0, 0.2);

}

.btn-buy:active {

    transform: translateY(0);

    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.2);

}

/* ====== Ã„ÂÃ†Â¯Ã¡Â»Å“NG GÃ¡ÂºÂ CH PHÃƒâ€šN Ãƒâ€ ====== */

.divider {

    border: none;

    border-top: 1px solid #e0e0e0;

    margin: 6px 0;

}

/* ====== HEADER RESPONSIVE ====== */

/* Tablet breakpoint */

@media (max-width: 768px) {

    .header {

        padding: 12px;

    }

    .main-nav {

        margin-left: 0;

        width: 100%;

        justify-content: center;

        flex-wrap: wrap;

        gap: 16px;

    }

    .header .container .auth-buttons,

    .header .container .user-menu {

        margin-left: 0;

    }

    .header .container {

        max-width: 100%;

        width: 100%;

        flex-direction: column;

        align-items: center;

        gap: 12px;

    }

    .logo {

        height: 36px;

    }

    .search-box {
        flex: 1 1 100%;
        width: min(100%, 320px);
        max-width: 320px;
        height: 42px;
        margin-left: 0;
        margin-right: 0;
        padding: 0 12px;
    }

    .auth-buttons,

    .user-menu {

        width: 100%;

    }

    .auth-buttons {

        display: grid;

        grid-template-columns: repeat(2, minmax(0, 1fr));

        gap: 10px;

    }

    .btn-login,

    .btn-register {

        width: 100%;

        padding: 12px 0;

    }

    .slider-wrapper {

        aspect-ratio: 15 / 4;

        max-height: 280px;

    }

    .product-card {

        border-radius: 14px;

    }

    .product-content {

        padding: 14px;

        gap: 8px;

    }

    .price-line {

        margin-bottom: 6px;

    }

    .product-actions {

        gap: 8px;

        margin-top: 10px;

    }

    .divider {

        margin: 6px 0;

    }

    .btn-outline,

    .btn-buy {

        padding: 12px;

    }

}

/* Mobile breakpoint */

@media (max-width: 576px) {

    .main-nav {

        gap: 12px;

    }

    .search-box {
        width: 100%;
        max-width: 100%;
        height: 40px;
        padding: 0 10px;
    }

    .slider-wrapper {

        aspect-ratio: 15 / 4;

        max-height: 220px;

    }

    .product-card {

        border-radius: 16px;

    }

    .product-content {

        padding: 12px;

        gap: 6px;

    }

    .price-line {

        margin-bottom: 4px;

    }

    .product-actions {

        grid-template-columns: 1fr;

        gap: 8px;

        margin-top: 8px;

    }

    .divider {

        margin: 6px 0;

    }

    .btn-outline,

    .btn-buy {

        padding: 11px;

    }

    .user-menu {

        justify-content: center;

        gap: 12px;

    }

    .cart-link {

        margin-right: 0;

    }

    .user-dropdown {

        display: flex;

        align-items: center;

        justify-content: center;

        gap: 8px;

    }

    .user-dropdown .username {

        text-align: center;

    }

}

/* Small mobile breakpoint */

@media (max-width: 420px) {

    .search-box {
        height: 38px;
        padding: 0 8px;
    }

    .main-nav {

        gap: 10px;

    }

    .auth-buttons {

        grid-template-columns: 1fr;

    }

    .slider-wrapper {

        aspect-ratio: 15 / 4;

        max-height: 180px;

    }

    .product-content {

        padding: 11px;

        gap: 5px;

    }

    .product-actions {

        gap: 6px;

        margin-top: 6px;

    }

    .btn-outline,

    .btn-buy {

        padding: 10px;

    }

    .user-menu {

        gap: 10px;

    }

}

.user-info {

    display: flex;

    align-items: center;

    gap: 10px;

    font-weight: bold;

}

.user-avatar {

    width: 36px;

    height: 36px;

    border-radius: 50%;

    object-fit: cover;

}

.cart-icon {

    font-size: 22px;

    color: #e91e63;

    cursor: pointer;

}

.user-menu {

    display: flex;

    align-items: center;

    position: relative;

}

.cart-icon {

    font-size: 22px;

    color: #f5027b;

    cursor: pointer;

    transition: transform 0.2s ease;

}

.cart-link {

    position: relative;

    display: inline-flex;

    align-items: center;

    margin-right: 20px;

    color: inherit;

    text-decoration: none;

}

.cart-link:hover .cart-icon {

    transform: translateY(-1px);

}

.cart-count {

    position: absolute;

    top: -6px;

    right: -10px;

    background: #f5027b;

    color: #fff;

    border-radius: 999px;

    padding: 0 6px;

    min-width: 18px;

    line-height: 18px;

    font-size: 12px;

    font-weight: 600;

    text-align: center;

}

.user-dropdown {

    position: relative;

    cursor: pointer;

    display: inline-block;

}

.user-dropdown .avatar {

    width: 35px;

    height: 35px;

    border-radius: 50%;

    margin-right: 6px;

    vertical-align: middle;

}

.user-dropdown .username {

    font-weight: bold;

    color: #111;

    vertical-align: middle;

}

/* Dropdown menu */

.user-dropdown {

    position: relative;

    cursor: pointer;

    display: inline-block;

}

.user-dropdown .avatar {

    width: 35px;

    height: 35px;

    border-radius: 50%;

    margin-right: 6px;

    vertical-align: middle;

}

.user-dropdown .username {

    font-weight: bold;

    color: #111;

    vertical-align: middle;

}

/* Dropdown menu mÃ¡ÂºÂ·c Ã„â€˜Ã¡Â»â€¹nh Ã¡ÂºÂ©n */

.user-dropdown .dropdown {

    display: none;

    position: absolute;

    top: 45px;

    right: 0;

    background: white;

    border: 1px solid #ddd;

    border-radius: 6px;

    box-shadow: 0 4px 10px rgba(0,0,0,0.1);

    min-width: 180px;

    list-style: none;

    padding: 8px 0;

    z-index: 1000;

    opacity: 0;

    transform: translateY(-10px);

    transition: all 0.2s ease;

}

/* Khi JS thÃƒÂªm class .show thÃƒÂ¬ hiÃ¡Â»â€¡n */

.user-dropdown .dropdown.show {

    display: block;

    opacity: 1;

    transform: translateY(0);

}

.user-dropdown .dropdown li {

    padding: 10px 16px;

}

.user-dropdown .dropdown li a {

    text-decoration: none;

    color: #333;

    display: flex;

    align-items: center;

    gap: 8px;

}

.user-dropdown .dropdown li a:hover {

    background: #f5f5f5;

}

.hero-slider {

    position: relative;

    max-width: 1200px;

    margin: 32px auto;

    border-radius: 18px;

    overflow: hidden;

    box-shadow: 0 16px 32px rgba(20, 40, 90, 0.12);

}

.slider-wrapper {

    position: relative;

    width: 100%;

    max-width: 1200px;

    aspect-ratio: 15 / 4;

    max-height: 313px;

    overflow: hidden;

}

.slide {

    position: absolute;

    inset: 0;

    opacity: 0;

    transition: opacity 0.6s ease;

    pointer-events: none;

    z-index: 0;

}

.slide.active {

    opacity: 1;

    pointer-events: auto;

    z-index: 1;

}

.slide a {

    display: block;

    width: 100%;

    height: 100%;

}

.slide img {

    width: 100%;

    height: 100%;

    object-fit: contain;

    background-color: #fff;

    display: block;

}

.slide-caption {

    position: absolute;

    left: 24px;

    bottom: 24px;

    padding: 14px 20px;

    background: rgba(0, 0, 0, 0.5);

    color: #fff;

    border-radius: 12px;

    font-size: 18px;

    max-width: 60%;

}

.slider-btn {

    position: absolute;

    top: 50%;

    transform: translateY(-50%);

    width: 44px;

    height: 44px;

    border-radius: 50%;

    border: none;

    background: rgba(255, 255, 255, 0.85);

    display: flex;

    align-items: center;

    justify-content: center;

    cursor: pointer;

    color: #0f8c07;

    font-size: 22px;

    transition: background 0.2s ease;

    z-index: 5;

    pointer-events: auto;

}

.slider-btn:hover {

    background: rgba(255, 255, 255, 1);

}

.slider-btn.prev {

    left: 16px;

}

.slider-btn.next {

    right: 16px;

}

.slider-dots {

    position: absolute;

    bottom: 18px;

    left: 50%;

    transform: translateX(-50%);

    display: flex;

    gap: 10px;

    z-index: 5;

    pointer-events: auto;

}

.slider-dots .dot {

    width: 10px;

    height: 10px;

    border-radius: 50%;

    border: none;

    background: rgba(255, 255, 255, 0.6);

    cursor: pointer;

}

.slider-dots .dot.active {

    background: #0f8c07;

}

.pagination {

    display: flex;

    justify-content: center;

    gap: 10px;

    margin-top: 28px;

}

.page-link {

    padding: 8px 14px;

    border-radius: 10px;

    border: 1px solid #d6dde6;

    color: #273244;

    text-decoration: none;

    font-weight: 600;

    transition: all 0.2s ease;

}

.page-link:hover {

    border-color: #0f8c07;

    color: #0f8c07;

}

.page-link.active {

    background: #0f8c07;

    color: #fff;

    border-color: #0f8c07;

}

.empty-state {

    grid-column: 1 / -1;

    text-align: center;

    font-size: 18px;

    color: #5b6676;

    padding: 40px 0;

}

.back-to-top {
    position: fixed;
    right: 24px;
    bottom: 24px;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    background: linear-gradient(135deg, #f5027b, #ff4ba2);
    color: #fff;
    border: none;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 10px 24px rgba(245, 2, 123, 0.42);
    opacity: 0;
    pointer-events: none;
    transition: opacity 0.2s ease, transform 0.2s ease;
    z-index: 999;
}

.back-to-top.show {

    opacity: 1;

    pointer-events: all;

    transform: translateY(-6px);

}

.category-filter {

    display: flex;

    justify-content: center;   /* CÃ„Æ’n giÃ¡Â»Â¯a theo chiÃ¡Â»Âu ngang */

    gap: 16px;

    flex-wrap: wrap;

    align-items: center;

    margin: 0px 0 24px;

}

.category-filter__title {

    font-weight: 700;

    font-size: 16px;

    color: #273244;

    text-transform: uppercase;

    letter-spacing: 0.06em;

    margin-right: 8px;

}

.filter-pill {

    display: inline-flex;

    align-items: center;

    padding: 10px 22px;

    border-radius: 999px;

    border: 1px solid #d9e0ec;

    background: #ffffff;

    color: #415064;

    text-decoration: none;

    font-weight: 600;

    font-size: 14px;

    box-shadow: 0 8px 22px rgba(18, 38, 77, 0.08);

    transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease, color 0.2s ease;

}

.filter-pill:hover {

    border-color: #0f8c07;

    color: #0f8c07;

    transform: translateY(-2px);

    box-shadow: 0 12px 28px rgba(15, 140, 7, 0.18);

}

.filter-pill.active {

    background: #0f8c07;

    color: #ffffff;

    border-color: #0f8c07;

    box-shadow: 0 16px 34px rgba(15, 140, 7, 0.30);

}

