/* ================= HERO SECTION ================= */
.hero { padding: 140px 0 60px; background: linear-gradient(180deg, #d8f3dc 0%, var(--bg) 100%); }
.hero-layout { display: flex; align-items: center; justify-content: space-between; gap: 40px; }
.hero-col-img { flex: 1; display: flex; justify-content: center; }
.hero-img-fix { width: 100%; max-width: 500px; height: auto; display: block; object-fit: contain; }
.hero-col-text { flex: 1; }
.hero-col-text h1 { font-family: var(--font-head); font-size: 3.5rem; margin-bottom: 20px; color: var(--primary); line-height: 1.2; }
.hero-col-text p { margin-bottom: 30px; font-size: 1.1rem; color: var(--text); max-width: 90%; }
.badge-hero { background: var(--white); padding: 8px 20px; border-radius: 30px; font-size: 0.9rem; display: inline-flex; align-items: center; gap: 8px; color: var(--primary); font-weight: 700; margin-bottom: 20px; box-shadow: 0 4px 10px rgba(0,0,0,0.05); }
.cta-btn { padding: 16px 45px; background: var(--primary); color: white; border: none; border-radius: 50px; font-weight: 600; font-size: 1.1rem; cursor: pointer; transition: var(--transition); box-shadow: 0 10px 25px rgba(45, 106, 79, 0.3); }

/* ================= FILTER ================= */
.filter-wrapper { max-width: 850px; margin: -40px auto 100px; padding: 0 20px; position: relative; z-index: 10; }
.search-box { background: var(--white); border-radius: 60px; display: flex; align-items: center; gap: 12px; padding: 6px 6px 6px 20px; box-shadow: 0 15px 40px rgba(0,0,0,0.1); border: 1px solid var(--border); width: 100%; }
.search-icon { color: #999; font-size: 1.2rem; }
.search-input { flex: 1; min-width: 0; border: none; background: transparent; font-size: 1rem; color: var(--text); }
.filter-toggle-btn { width: 45px; height: 45px; flex-shrink: 0; border-radius: 50%; border: none; background: var(--secondary); color: white; cursor: pointer; }
.filter-panel { background: var(--white); margin-top: 15px; border-radius: 24px; max-height: 0; overflow: hidden; transition: 0.5s cubic-bezier(0.4, 0, 0.2, 1); opacity: 0; box-shadow: var(--shadow); }
.filter-panel.active { padding: 25px; max-height: 500px; opacity: 1; margin-bottom: 20px; }
.filter-row { display: flex; gap: 30px; margin-bottom: 20px; flex-wrap: wrap; }
.filter-group { flex: 1; min-width: 200px; }
.filter-group label { display: block; font-weight: 600; margin-bottom: 10px; }
.tags-container { display: flex; gap: 10px; flex-wrap: wrap; }
.tag-chip { padding: 8px 18px; background: rgba(0,0,0,0.05); border-radius: 30px; cursor: pointer; font-size: 0.9rem; font-weight: 500; transition: 0.2s; border: 1px solid transparent; color: var(--text); }
.tag-chip.active { background: var(--primary); color: white; }

.global-not-found { display: none; text-align: center; padding: 60px 20px; background: var(--white); border-radius: 20px; border: 1px dashed var(--border); margin-bottom: 40px; }
.global-not-found.active { display: block; animation: fadeInUp 0.5s ease; }
.icon-404 { font-size: 5rem; color: var(--secondary); margin-bottom: 20px; opacity: 0.5; }
.global-not-found h3 { font-family: var(--font-head); font-size: 1.8rem; margin-bottom: 10px; color: var(--text); }
.btn-reset { margin-top: 20px; padding: 10px 25px; background: var(--text); color: white; border: none; border-radius: 30px; cursor: pointer; display: inline-flex; align-items: center; gap: 8px; font-weight: 600; }

/* ================= SECTION STYLES ================= */
.section-wrapper { margin-bottom: 80px; } 
.section-header { display: flex; align-items: center; gap: 15px; margin-bottom: 40px; padding-top: 10px; }
.sec-icon { font-size: 1.6rem; background: var(--white); width: 50px; height: 50px; border-radius: 14px; display: flex; align-items: center; justify-content: center; color: var(--primary); box-shadow: 0 4px 12px rgba(0,0,0,0.05); }
.sec-title { font-family: var(--font-head); color: var(--primary); font-size: 2rem; }

.features-section { padding: 60px 0; background: var(--white); margin: 40px 0; border-top: 1px solid var(--border); border-bottom: 1px solid var(--border); }
.features-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: 30px; max-width: 1200px; margin: 0 auto; padding: 0 20px; text-align: center; }
.feat-item { padding: 25px; border-radius: 20px; background: rgba(0,0,0,0.02); transition: 0.3s; }
.feat-icon { font-size: 2.5rem; color: var(--secondary); margin-bottom: 15px; display: inline-block; background: rgba(82, 183, 136, 0.1); width: 60px; height: 60px; line-height: 60px; border-radius: 50%; }

.marquee-section { padding: 60px 0; background: var(--bg); overflow: hidden; position: relative; }
.section-title-center { text-align: center; font-family: var(--font-head); font-size: 2.2rem; margin-bottom: 40px; color: var(--primary); }
.marquee-wrapper { overflow: hidden; white-space: nowrap; position: relative; width: 100%; }
.marquee-track { display: flex; gap: 30px; animation: scrollMarquee 40s linear infinite; width: max-content; }
.marquee-track:hover { animation-play-state: paused; }
@keyframes scrollMarquee { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }
.testimonial-card { background: var(--white); padding: 25px; border-radius: 20px; width: 320px; flex-shrink: 0; box-shadow: 0 8px 20px rgba(0,0,0,0.05); border-left: 5px solid var(--secondary); position: relative; white-space: normal; }
.testimonial-card p { font-style: italic; color: var(--text); opacity: 0.8; font-size: 0.95rem; margin: 10px 0; line-height: 1.6; }
.testimonial-card strong { color: var(--primary); display: block; margin-top: 10px; }

/* ================= OCEAN/WAVES ================= */
.ocean-wrapper { position: absolute; top: -80px; left: 0; width: 100%; height: 80px; overflow: hidden; z-index: 1; pointer-events: none; }
.wave { position: absolute; bottom: -1px; left: 0; width: 200%; height: 100%; background-repeat: repeat-x; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 800 88' preserveAspectRatio='none'%3E%3Cpath d='M0,88V40c133.33,0,266.67-40,400-40s266.67,40,400,40v48H0Z' fill='%231b4332'/%3E%3C/svg%3E"); background-size: 50% 100%; transform: translate3d(0, 0, 0); }
.wave1 { z-index: 1000; opacity: 1; animation: waveMove 12s linear infinite; }
.wave2 { z-index: 999; opacity: 0.5; animation: waveMove 18s linear infinite; bottom: 5px; margin-left: -150px; }
.wave3 { z-index: 998; opacity: 0.2; animation: waveMove 25s linear infinite; bottom: 10px; margin-left: -300px; }
@keyframes waveMove { 0% { transform: translateX(0); } 100% { transform: translateX(-50%); } }

/* ================= HOME RESPONSIVE ================= */
@media (max-width: 768px) {
    .hero { padding: 100px 20px 60px; }
    .hero-layout { flex-direction: column; gap: 20px; }
    .hero-col-img { order: 1; width: 100%; justify-content: center; }
    .hero-col-text { order: 2; text-align: center; display: flex; flex-direction: column; align-items: center; }
    .hero-img-fix { max-width: 320px; }
    .hero-col-text h1 { font-size: 2.2rem; }
    
    .filter-wrapper { margin-bottom: 60px; }
    .filter-panel.active { padding: 15px; }

    /* Điều chỉnh Grid Card ở Home */
    .grid { grid-template-columns: repeat(2, 1fr); gap: 10px; } 
    .card-thumb { height: 130px; font-size: 3rem; }
    .card-body { padding: 12px; }
    .card-title { font-size: 0.9rem; margin: 4px 0; }
    .btn-add { font-size: 0.8rem; padding: 8px; }
    .card-price { font-size: 1rem; margin-bottom: 8px; }
}

/* --- CSS Giỏ hàng (Cập nhật) --- */
.cart-sidebar {
    background: #fdfdfd;
    box-shadow: -5px 0 15px rgba(0,0,0,0.1);
    display: flex;
    flex-direction: column;
}

.cart-header {
    background: var(--primary); /* Màu xanh chủ đạo */
    color: white;
    padding: 15px 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.cart-header h2 { font-size: 1.2rem; margin: 0; font-weight: 600; }
.close-cart-btn { color: white; font-size: 1.5rem; background: none; border: none; cursor: pointer; }

/* Phần địa chỉ trong giỏ hàng */
.cart-address-section {
    background: #e8f5e9; /* Nền xanh nhạt */
    padding: 15px;
    margin: 10px;
    border-radius: 8px;
    border: 1px dashed var(--primary);
    font-size: 0.9rem;
}
.cart-addr-header { display: flex; justify-content: space-between; font-weight: bold; margin-bottom: 5px; color: #2e7d32; }
.cart-addr-display { color: #555; line-height: 1.4; }
.edit-addr-link { color: #d32f2f; text-decoration: underline; cursor: pointer; font-size: 0.85rem; }

/* Danh sách sản phẩm */
.cart-body {
    flex: 1;
    overflow-y: auto;
    padding: 10px;
}

.cart-item {
    display: flex;
    gap: 10px;
    background: white;
    padding: 10px;
    margin-bottom: 10px;
    border-radius: 8px;
    border: 1px solid #eee;
    box-shadow: 0 2px 5px rgba(0,0,0,0.03);
    transition: transform 0.2s;
}
.cart-item:hover { transform: translateY(-2px); }

.cart-item img { width: 60px; height: 60px; object-fit: cover; border-radius: 5px; }
.cart-item-details { flex: 1; display: flex; flex-direction: column; justify-content: space-between; }
.cart-item-title { font-weight: 600; font-size: 0.95rem; color: #333; }
.cart-item-price { color: #d32f2f; font-weight: bold; }

.cart-item-actions { display: flex; justify-content: space-between; align-items: center; margin-top: 5px; }
.qty-btn { background: #eee; border: none; width: 25px; height: 25px; border-radius: 4px; cursor: pointer; }
.remove-btn { color: #999; font-size: 1.2rem; cursor: pointer; background: none; border: none; }
.remove-btn:hover { color: #d32f2f; }

/* Footer giỏ hàng */
.cart-footer {
    padding: 20px;
    border-top: 1px solid #eee;
    background: white;
}
.cart-total-row { display: flex; justify-content: space-between; font-size: 1.1rem; font-weight: bold; margin-bottom: 15px; }
.btn-checkout {
    width: 100%; background: #d32f2f; color: white;
    padding: 12px; border: none; border-radius: 6px;
    font-weight: bold; text-transform: uppercase; letter-spacing: 1px;
    cursor: pointer; transition: background 0.3s;
}
.btn-checkout:hover { background: #b71c1c; }