﻿/* 1. CSS Variables & Reset */
:root {
  --primary: #1B5B6E;
  --primary-dark: #0d3a47;
  --accent: #E8711A;
  --accent-hover: #cf5e0e;
  --logo-red: #C8102E;
  --bg-light: #F5F7FA;
  --bg-section: #f9fafb;
  --text-dark: #1a1a1a;
  --text-gray: #6b7280;
  --border: #e5e7eb;
  --white: #ffffff;
  --success: #16a34a;
  --radius: 8px;
  --shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: 'Be Vietnam Pro', sans-serif;
  color: var(--text-dark);
  background: var(--white);
}

a {
  text-decoration: none;
  color: inherit;
}

ul {
  list-style: none;
}

img {
  max-width: 100%;
  display: block;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

/* 2. Header - sticky */








.nav-menu {
  flex: 1;
  padding: 0 2vw;
}
.nav-menu ul {
  display: flex;
  justify-content: space-evenly;
  gap: 16px;
}

.nav-menu a {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-dark);
  transition: color 0.2s;
}

.nav-menu a:hover,
.nav-menu a.active {
  color: var(--accent);
}



.search-toggle {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--text-gray);
  font-size: 16px;
}

.btn-cta {
  background: var(--accent);
  color: var(--white);
  padding: 9px 18px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 14px;
  transition: background 0.2s;
  white-space: nowrap;
}

.btn-cta:hover {
  background: var(--accent-hover);
}

.hamburger {
  display: none;
  background: none;
  border: none;
  font-size: 22px;
  color: var(--text-dark);
  cursor: pointer;
}

.header.scrolled {
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.12);
}

/* Mobile Nav */
.mobile-nav-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.5);
  z-index: 200;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  display: flex;
}

.mobile-nav-overlay.active {
  opacity: 1;
  visibility: visible;
}

.mobile-nav {
  background: var(--white);
  width: 280px;
  height: 100%;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 24px;
  transform: translateX(-100%);
  transition: transform 0.3s ease;
}

.mobile-nav-overlay.active .mobile-nav {
  transform: translateX(0);
}

.mobile-nav-header {
  display: flex;
        position: relative;
        z-index: 10000;
  justify-content: space-between;
  align-items: center;
}

.mobile-close {
  background: none;
  border: none;
  font-size: 22px;
  cursor: pointer;
}

.mobile-nav ul {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.mobile-nav a {
  font-size: 16px;
  font-weight: 500;
  padding: 8px 0;
  border-bottom: 1px solid var(--bg-light);
  display: block;
}

.mobile-nav a.active {
  color: var(--accent);
}

.btn-cta-mobile {
  background: var(--accent);
  color: var(--white);
  padding: 12px;
  text-align: center;
  border-radius: var(--radius);
  font-weight: 600;
  margin-top: 10px;
}

/* 3. Hero Banner */
.hero-banner {
  background: linear-gradient(to right, rgba(0, 0, 0, 0.85) 0%, rgba(0, 0, 0, 0.2) 60%, rgba(0, 0, 0, 0) 100%), url('../images/hero-bg.png') center/cover no-repeat;
  min-height: 340px;
  display: flex;
  align-items: center;
}

.hero-overlay {
  width: 100%;
  padding: 60px 0;
}

.hero-overlay .container {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.hero-label {
  text-transform: uppercase;
  font-size: 12px;
  font-weight: 700;
  color: var(--accent);
  letter-spacing: 2px;
}

.hero-title {
  font-size: 42px;
  font-weight: 800;
  color: var(--white);
  line-height: 1.15;
  text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.hero-sub {
  font-size: 16px;
  color: rgba(255, 255, 255, 0.9);
  max-width: 520px;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
}

.hero-search {
  display: flex;
  align-items: center;
  max-width: 480px;
  background: var(--white);
  border-radius: 6px;
  padding: 6px 6px 6px 20px;
  margin-top: 24px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
}

.hero-search .search-icon {
  color: var(--text-gray);
  margin-right: 12px;
  font-size: 18px;
  display: flex;
  align-items: center;
}

.hero-search input {
  flex: 1;
  border: none;
  outline: none;
  font-family: 'Be Vietnam Pro', sans-serif;
  font-size: 15px;
  color: var(--text-dark);
  background: transparent;
  display: flex;
  align-items: center;
}

.hero-search button {
  background: var(--accent);
  border: none;
  color: var(--white);
  width: 44px;
  height: 44px;
  border-radius: 4px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  transition: background 0.2s;
  flex-shrink: 0;
}

.hero-search button:hover {
  background: var(--accent-hover);
}

/* 4. Category Tabs */
.category-section {
  background: var(--white);
  border-bottom: 1px solid var(--border);
  padding: 16px 0;
}

.category-tabs {
  display: flex;
  flex-direction: row;
  gap: 12px;
  overflow-x: auto;
  scrollbar-width: none;
}

.category-tabs::-webkit-scrollbar {
  display: none;
}

.cat-tab {
  background: #f5f5f5;
  border: none;
  border-radius: 8px;
  padding: 8px 16px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-dark);
  cursor: pointer;
  white-space: nowrap;
  transition: all 0.2s ease;
  font-family: 'Be Vietnam Pro', sans-serif;
  flex-shrink: 0;
  text-align: center;
}

.cat-tab:hover {
  background: #e5e5e5;
}

.cat-tab.active {
  background: var(--accent);
  color: var(--white);
}

.cat-tab.active:hover {
  background: var(--accent-hover);
}

/* 5. Main Content */
.main-content {
  padding-top: 40px;
  padding-bottom: 30px;
}

.section-title {
  font-size: 24px;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 0;
}

/* 6. Layout Grid (Main + Sidebar) */
.layout-grid {
  display: grid;
  grid-template-columns: 1fr 280px;
  gap: 24px;
  align-items: flex-start;
}

.articles-column {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.featured-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 24px;
}

.sidebar-column {
  display: flex;
  flex-direction: column;
  gap: 24px;
}

/* 7. Post Card (featured) */
.featured-post {
  display: flex;
  flex-direction: column;
  height: 100%;
}

.post-img-wrap {
  position: relative;
  border-radius: var(--radius);
  overflow: hidden;
  background: var(--bg-light);
  aspect-ratio: 16/9;
}

.post-img-wrap img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: var(--radius);
  transition: transform 0.3s;
}

.featured-post:hover .post-img-wrap img {
  transform: scale(1.03);
}

.img-badge {
  position: absolute;
  bottom: 12px;
  left: 12px;
  background: rgba(0, 0, 0, 0.6);
  color: var(--white);
  padding: 4px 10px;
  border-radius: 4px;
  font-size: 13px;
  font-weight: 600;
}

.compare-badge {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  background: rgba(0, 0, 0, 0.35);
  color: var(--white);
  font-size: 16px;
  font-weight: 700;
}

.post-info {
  display: flex;
  flex-direction: column;
  gap: 6px;
  flex: 1;
  padding: 12px 16px 16px;
}

.post-cat {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--accent);
  letter-spacing: 1px;
}

.post-title {
  font-size: 17px;
  font-weight: 700;
  color: var(--text-dark);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.post-title:hover {
  color: var(--accent);
}

.featured-large .post-title {
  font-size: 20px;
}

.post-excerpt {
  font-size: 14px;
  color: var(--text-gray);
  line-height: 1.6;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.post-date {
  font-size: 12px;
  color: var(--text-gray);
  display: flex;
  align-items: center;
  gap: 6px;
  margin-top: 10px;
}

/* 8. Sidebar CTA Card */
.sidebar-cta-card {
  background: #FFF4EC;
  border-radius: 12px;
  padding: 24px;
  margin-bottom: 32px;
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.cta-card-icon {
  font-size: 32px;
  color: var(--accent);
}

.sidebar-cta-card h3 {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-dark);
  line-height: 1.4;
}

.sidebar-cta-card p {
  font-size: 13px;
  color: var(--text-gray);
  line-height: 1.6;
}

.btn-accent-outline {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  background: var(--accent);
  color: var(--white);
  padding: 10px 18px;
  border-radius: var(--radius);
  font-weight: 600;
  font-size: 14px;
  transition: background 0.2s;
  width: fit-content;
  margin-top: 4px;
}

.btn-accent-outline:hover {
  background: var(--accent-hover);
}

/* 9. Popular Posts */
.sidebar-heading {
  font-size: 16px;
  font-weight: 700;
  color: var(--text-dark);
  margin-bottom: 16px;
}

.popular-posts {
  padding: 20px 0;
}

.popular-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
  list-style: none;
}

.popular-list li {
  display: flex;
  align-items: center;
  gap: 12px;
}

.pop-num {
  font-size: 28px;
  font-weight: 300;
  color: var(--text-gray);
  flex-shrink: 0;
  width: 32px;
  text-align: left;
}

.pop-thumb {
  width: 60px;
  height: 60px;
  aspect-ratio: 1 / 1;
  object-fit: cover;
  border-radius: 8px;
  flex-shrink: 0;
}

.popular-list a {
  flex: 1;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-dark);
  line-height: 1.5;
  transition: color 0.2s;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.popular-list a:hover {
  color: var(--accent);
}

/* 10. Articles Grid */
.article-rows {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  row-gap: 32px;
  column-gap: 24px;
}

.article-card {
  display: flex;
  flex-direction: column;
  height: 100%;
}

/* 11. Sidebar Email */

.email-subscribe-box {
  background: #fff8f0;
  border-radius: 12px;
  padding: 24px;
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.email-icon {
  font-size: 32px;
  color: var(--accent);
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.email-subscribe-box h3 {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-dark);
}

.email-subscribe-box p {
  font-size: 14px;
  color: #64748B;
  line-height: 1.5;
}

.email-form {
  display: flex;
  flex-direction: row;
  flex-wrap: nowrap;
  height: 48px;
  width: 100%;
}

.email-form input {
  flex: 1;
  min-width: 0;
  width: 100%;
  border: 1px solid #e2e8f0;
  border-right: none;
  border-radius: 8px 0 0 8px;
  outline: none;
  padding: 0 16px;
  font-family: 'Be Vietnam Pro', sans-serif;
  font-size: 14px;
  background: var(--white);
  color: var(--text-dark);
}

.email-form input::placeholder {
  color: #94a3b8;
}

.email-form button {
  background: var(--accent);
  color: var(--white);
  border: none;
  border-radius: 0 8px 8px 0;
  padding: 0 20px;
  cursor: pointer;
  font-size: 16px;
  transition: background 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.email-form button:hover {
  background: var(--accent-hover);
}

/* 12. Pagination */
.pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 25px 0 0px;
}

.page-btn {
  background: var(--white);
  border: 1px solid var(--border);
  border-radius: 6px;
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  font-family: 'Be Vietnam Pro', sans-serif;
  transition: all 0.2s;
}

.page-btn:hover {
  border-color: var(--accent);
  color: var(--accent);
}

.page-btn.active {
  background: var(--accent);
  border-color: var(--accent);
  color: var(--white);
}

.page-dots {
  font-size: 14px;
  color: var(--text-gray);
  padding: 0 4px;
}

.page-next {
  width: auto;
  padding: 0 14px;
}

/* 13. Footer */




.brand-slogan {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-dark);
  margin-bottom: 8px;
}























.hotline-link {
  color: var(--accent) !important;
  font-weight: 600;
}













/* 14. Back to top */
.back-to-top {
  position: fixed;
  bottom: 24px;
  right: 24px;
  background: var(--primary);
  color: var(--white);
  border: none;
  width: 44px;
  height: 44px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 16px;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s;
  z-index: 50;
}

.back-to-top.show {
  opacity: 1;
  visibility: visible;
}

.back-to-top:hover {
  background: var(--accent);
}

/* 15. Responsive - Tablet ≤1024px */
@media (max-width: 1024px) {
  .nav-menu {
    display: none;
  }

  .hamburger {
    display: block;
  }

  .btn-cta {
    display: none;
  }

  .hero-title {
    font-size: 32px;
  }

  .layout-grid {
    grid-template-columns: 1fr;
  }

  .featured-grid {
    display: flex;
    flex-direction: column;
    gap: 24px;
  }

  .sidebar-column {
    flex-direction: row;
    flex-wrap: wrap;
  }
}

/* 16. Responsive - Mobile ≤768px */
@media (max-width: 768px) {
  .hero-title {
    font-size: 26px;
  }

  .hero-sub {
    font-size: 14px;
  }

  .hero-banner {
    min-height: 220px;
  }

  .layout-grid {
    grid-template-columns: 1fr;
  }

  .featured-grid {
    display: flex;
    flex-direction: column;
    gap: 24px;
  }

  .sidebar-column {
    flex-direction: column;
  }

  .sidebar-cta-card,
  .popular-posts {
    flex: 0 0 100%;
  }

  .article-rows {
    display: flex;
    flex-direction: column;
    gap: 24px;
  }







  .section-title {
    font-size: 20px;
  }

  .main-content {
    padding-top: 24px;
    padding-bottom: 0;
  }


}

/* 17. Mobile small ≤480px */
@media (max-width: 480px) {
  .hero-title {
    font-size: 22px;
  }

  .category-tabs {
    gap: 6px;
  }

  .cat-tab {
    padding: 5px 12px;
    font-size: 13px;
  }

  .pagination {
    gap: 4px;
  }

  .page-btn {
    width: 34px;
    height: 34px;
    font-size: 13px;
  }
}
/* --- CSS ĐỂ LÀM TOÀN BỘ BOX CLICK ĐƯỢC (THẺ A FULL BOX) --- */
.product-card, .article-card, .featured-post {
  position: relative;
}
.product-card a::after, .article-card a::after, .featured-post a::after {
  content: "";
  position: absolute;
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
  z-index: 10;
}

/* Contact links hover state */
.contact-link:hover {
  text-decoration: underline !important;
  opacity: 0.8;
}
/* ============================================================== */
/* STANDARDIZED HEADER & MOBILE MENU CSS (ADDED BY AI)            */
/* ============================================================== */

/* DESKTOP LAYOUT (Default) */






.main-nav {
    display: flex;
    align-items: center;
}

.nav-list {
    display: flex;
    gap: 24px;
    list-style: none;
    margin: 0;
    padding: 0;
}

.nav-item {
    text-decoration: none;
    color: #333;
    font-weight: 500;
    font-size: 16px;
}



.mobile-menu-btn {
    display: none; /* Hidden on desktop */
    background: none;
    border: none;
    font-size: 24px;
    cursor: pointer;
    color: #0d3b45;
}

.mobile-only {
    display: none;
}

.menu-overlay {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background: rgba(0,0,0,0.5);
    z-index: 9998;
    opacity: 0;
    transition: opacity 0.3s ease;
}

.menu-overlay.menu-active {
    display: block;
    opacity: 1;
}

/* MOBILE LAYOUT */
@media (max-width: 1024px) {


    /* Hide desktop actions */


    /* Show mobile menu button */
    .mobile-menu-btn {
        display: block;
        position: relative;
        z-index: 9999;
    }

    /* Standardize mobile Sidebar Menu */
    .main-nav {
        position: fixed;
        top: 0;
        left: 0;
        width: 280px;
        display: flex;
        height: 100vh;
        background: #fff;
        z-index: 9999;
        flex-direction: column;
        align-items: flex-start;
        padding: 0;
        transform: translateX(-100%);
        transition: transform 0.3s ease-in-out;
        box-shadow: 2px 0 8px rgba(0,0,0,0.1);
        overflow-y: auto;
    }

    /* Active state for Sidebar */
    .main-nav.menu-active {
        transform: translateX(0);
    }

    .mobile-only {
        display: flex !important;
    }

    .nav-list {
        flex-direction: column;
        width: 100%;
        gap: 0;
    }

    .nav-list li {
        width: 100%;
        border-bottom: 1px solid #eee;
    }

    .nav-list .nav-item {
        display: block;
        padding: 16px 20px;
        width: 100%;
    }

    .mobile-nav-header {
        width: 100%;
        display: flex;
        justify-content: space-between;
        align-items: center;
        padding: 16px 20px;
        border-bottom: 1px solid #eee;
    }

    .mobile-nav-logo {
        height: 40px;
    }

    .mobile-nav-close {
        background: none;
        border: none;
        font-size: 24px;
        cursor: pointer;
        color: #333;
    }

    .mobile-nav-footer {
        flex-direction: column;
        width: 100%;
        padding: 20px;
        gap: 12px;
        margin-top: auto;
    }

    .btn-mobile-consult {
        display: block;
        text-align: center;
        background: #ff6a00;
        color: #fff;
        padding: 12px;
        border-radius: 8px;
        text-decoration: none;
        font-weight: bold;
    }
    
    .mobile-hotline {
        display: block;
        text-align: center;
        color: #0d3b45;
        text-decoration: none;
        font-weight: bold;
        font-size: 16px;
    }
}

/* DESKTOP ACTIONS STANDARDIZATION (ADDED BY AI) */

.search-box {
    display: flex;
    align-items: center;
    border: 1px solid #ddd;
    border-radius: 4px;
    padding: 4px 10px;
    background: #f9f9f9;
}
.search-box input {
    border: none;
    outline: none;
    background: transparent;
    padding: 5px;
    font-size: 14px;
    width: 150px;
}
.search-box button {
    background: none;
    border: none;
    cursor: pointer;
    color: #666;
}
.btn-try-fit {
    background-color: #ff6a00;
    color: #fff;
    padding: 9px 18px;
    border-radius: 4px;
    font-weight: 700;
    font-size: 13px;
    text-decoration: none;
    transition: background 0.2s;
    white-space: nowrap;
}
.btn-try-fit:hover {
    background-color: #e65c00;
}
.hotline {
    white-space: nowrap;
    font-weight: 700;
    color: #333;
    font-size: 14px;
}
.hotline a {
    color: inherit;
    text-decoration: none;
}
.nav-item:hover, .nav-item.active {
    color: #ff6a00;
}

