/* CSS Reset & Base */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

:root {
    --primary: #D70C19;
    /* Default, will be overridden by PHP injection */
    --primary-contrast: #ffffff;
    --bg-body: #ffffff;
    --bg-surface: #f8fafc;
    --c-white: #ffffff;
    --c-black: #0a0f1d;
    --c-text: #1a1e26;
    --c-text-muted: #64748b;
    --font-heading: 'Montserrat', sans-serif;
    --font-body: 'Montserrat', sans-serif;

    /* Spacing */
    --spacing-xs: 0.5rem;
    /* 8px */
    --spacing-sm: 1rem;
    /* 16px */
    --spacing-md: 1.5rem;
    /* 24px */
    --spacing-lg: 2.5rem;
    /* 40px */
    --spacing-xl: 4rem;
    /* 64px */

    /* Layout */
    --container-width: 1360px;
    --header-height: 72px;
    --site-px: 1.25rem;
    --site-px-desktop: 2.5rem;
}

html {
    font-family: var(--font-body);
    line-height: 1.5;
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body {
    background-color: var(--bg-body);
    color: var(--c-text);
    font-family: var(--font-body);
    -webkit-font-smoothing: antialiased;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

a {
    color: inherit;
    text-decoration: none;
}

button,
input,
select,
textarea {
    font-family: inherit;
    font-size: inherit;
    line-height: inherit;
    color: inherit;
}

ul,
ol {
    list-style: none;
}

/* Base Components */
.container {
    width: 100%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding-left: var(--site-px);
    padding-right: var(--site-px);
}

@media (min-width: 1024px) {
    .container {
        padding-left: var(--site-px-desktop);
        padding-right: var(--site-px-desktop);
    }
}

.hidden {
    display: none !important;
}

/* Visibility Helpers */
.desktop-only {
    display: block !important;
}
.mobile-only {
    display: none !important;
}

@media (max-width: 1024px) {
    .desktop-only {
        display: none !important;
    }
    .mobile-only {
        display: block !important;
    }
}

.block {
    display: block;
}

.flex {
    display: flex;
}

.grid {
    display: grid;
}

.relative {
    position: relative;
}

.absolute {
    position: absolute;
}

.fixed {
    position: fixed;
}





.w-full {
    width: 100%;
}

.h-full {
    height: 100%;
}

.items-center {
    align-items: center;
}

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

.justify-between {
    justify-content: space-between;
}

.flex-col {
    flex-direction: column;
}

.gap-4 {
    gap: 1rem;
}

.gap-8 {
    gap: 2rem;
}

/* Typography */
.text-white {
    color: var(--c-text);
}



.font-bold {
    font-weight: 700;
}

.uppercase {
    text-transform: uppercase;
}

.text-sm {
    font-size: 0.875rem;
}

.text-xl {
    font-size: 1.25rem;
}

.text-2xl {
    font-size: 1.5rem;
}

.text-3xl {
    font-size: 1.875rem;
}

@media (min-width: 768px) {
    .text-2xl {
        font-size: 1.875rem;
    }
}



/* Mega Menu Tags (Replacements for Tailwind) */
.mega-menu-tags {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    margin-bottom: 0.25rem;
}

.mega-menu-tag {
    font-size: 10px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    padding: 2px 8px;
    border-radius: 4px;
    border: 1px solid currentColor;
}

.mega-menu-tag--hybrid {
    background-color: rgba(215, 12, 25, 0.2);
    /* primary/20 */
    color: var(--primary);
    border-color: rgba(215, 12, 25, 0.3);
}

.mega-menu-tag--ev {
    background-color: rgba(16, 185, 129, 0.2);
    /* emerald-500/20 */
    color: #34d399;
    /* emerald-400 */
    border-color: rgba(16, 185, 129, 0.3);
}


.material-symbols-outlined {
    font-variation-settings:
        'FILL' 0,
        'wght' 400,
        'GRAD' 0,
        'opsz' 24;
}

.text-glow {
    text-shadow: 0 0 15px var(--primary);
}

.text-primary {
    color: var(--primary) !important;
}

@keyframes bounce {

    0%,
    100% {
        transform: translateY(-25%);
        animation-timing-function: cubic-bezier(0.8, 0, 1, 1);
    }

    50% {
        transform: translateY(0);
        animation-timing-function: cubic-bezier(0, 0, 0.2, 1);
    }
}

.animate-bounce {
    animation: bounce 1s infinite;
}

/* Contact Form 7 Fixes */
/* Contact Form 7 Fixes & Premium Styles */
.wpcf7-form-control-wrap {
    display: block;
    width: 100%;
    margin-bottom: 1rem;
}

.wpcf7 p {
    margin-bottom: 0 !important;
}

.wpcf7 br {
    display: none;
}

.wpcf7-response-output {
    display: none !important;
}

.wpcf7-mail-sent-ok {
    background: rgba(34, 197, 94, 0.1) !important;
    border-color: #22c55e !important;
    color: #22c55e !important;
}

.wpcf7-not-valid-tip {
    font-size: 0.75rem;
    font-weight: 600;
    color: var(--primary);
    margin-top: 0.25rem;
}

/* Form Grid System for CF7 */
.form-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .form-grid {
        grid-template-columns: repeat(2, 1fr);
    }

    .form-grid .full-width {
        grid-column: span 2;
    }
}

.form-group-label {
    display: block;
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: rgba(0, 0, 0, 0.4);
    margin-bottom: 0.5rem;
    transition: color 0.3s;
}

.dark .form-group-label {
    color: rgba(255, 255, 255, 0.4);
}

.form-input-premium {
    width: 100%;
    height: 3.5rem;
    padding: 0 1.5rem;
    border-radius: 1rem;
    background-color: rgba(0, 0, 0, 0.05);
    border: 2px solid transparent;
    color: #1a1a1a;
    font-size: 1rem;
    font-weight: 500;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    outline: none;
}

.dark .form-input-premium {
    background-color: rgba(255, 255, 255, 0.05);
    color: #ffffff;
}

.form-input-premium:focus {
    background-color: #ffffff;
    border-color: var(--primary);
    box-shadow: 0 10px 15px -3px rgba(var(--primary-rgb), 0.1);
}

.dark .form-input-premium:focus {
    background-color: rgba(255, 255, 255, 0.1);
    border-color: var(--primary);
}

textarea.form-input-premium {
    height: auto;
    padding-top: 1rem;
    padding-bottom: 1rem;
    border-radius: 1.5rem;
}

.form-submit-wrapper {
    margin-top: 1rem;
}

.btn-submit-premium {
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.75rem;
    padding: 1.25rem !important;
    background-color: var(--primary);
    color: var(--primary-contrast);
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    border-radius: 1rem;
    border: none;
    cursor: pointer;
    transition: all 0.4s ease;
}

.btn-submit-premium:hover {
    transform: translateY(-3px);
    box-shadow: 0 15px 30px rgba(var(--primary-rgb), 0.3);
    filter: brightness(1.1);
}

.btn-submit-premium .material-symbols-outlined {
    transition: transform 0.3s ease;
}

.btn-submit-premium:hover .material-symbols-outlined {
    transform: translateX(5px);
}

/* Fix text visibility on light inputs */
.wpcf7 input,
.wpcf7 select {
    color: #112117 !important;
}

.wpcf7 .form-select option {
    background: white;
    color: #112117;
}

.wpcf7 input::placeholder {
    color: rgba(17, 33, 23, 0.4) !important;
}

/* Pagination Styles */
.page-numbers {
    display: flex;
    justify-content: center;
    gap: 0.5rem;
    list-style: none;
    padding: 0;
}

.page-numbers li span.current {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 9999px;
    background-color: var(--primary);
    color: var(--primary-contrast);
    font-weight: 800;
}

.page-numbers li a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 2.5rem;
    height: 2.5rem;
    border-radius: 9999px;
    border: 1px solid rgba(0, 0, 0, 0.1);
    color: inherit;
    font-weight: 500;
    transition: all 0.3s;
}

.dark .page-numbers li a {
    border-color: rgba(255, 255, 255, 0.1);
}

.page-numbers li a:hover {
    background-color: rgba(0, 0, 0, 0.05);
    border-color: var(--primary);
}

.dark .page-numbers li a:hover {
    background-color: rgba(255, 255, 255, 0.05);
}

/* Premium Header Menu */
.menu-item-premium {
    list-style: none !important;
    position: relative; /* Default to relative for sub-menus */
}

.menu-item-premium .sub-menu {
    position: absolute;
    top: 100%;
    left: 0;
    background: #ffffff;
    min-width: 240px;
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.1);
    opacity: 0;
    visibility: hidden;
    transform: translateY(10px);
    transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
    z-index: 1000;
    padding: 1rem 0;
    border-top: 3px solid var(--primary);
    display: flex;
    flex-direction: column;
}

.menu-item-premium:hover > .sub-menu {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

.sub-menu li {
    width: 100%;
}

.sub-menu li a {
    padding: 0.75rem 1.5rem !important;
    display: block !important;
    font-size: 0.8rem !important;
    color: var(--c-text) !important;
    text-transform: uppercase !important;
    letter-spacing: 0.1em !important;
    font-weight: 700 !important;
    transition: all 0.2s ease !important;
}

.sub-menu li a::after {
    display: none !important;
}

.sub-menu li a:hover {
    background: rgba(var(--primary-rgb), 0.05);
    color: var(--primary) !important;
    padding-left: 1.75rem !important;
}

.menu-item-premium a {
    color: var(--c-text);
    text-decoration: none;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.15em;
    padding: 0.5rem 0;
    position: relative;
    transition: all 0.3s ease;
}

@media (min-width: 1024px) {
    .menu-item-premium a {
        font-size: 0.85rem;
    }
}

@media (max-width: 1023px) {
    .menu-item-premium a {
        font-size: 1.25rem;
        /* Matches other items */
        padding: 0.8rem 0;
        text-transform: none;
        /* Consistent with other items */
        font-weight: 600;
    }
}

.menu-item-premium a:hover {
    color: var(--primary);
    opacity: 1;
}

.menu-item-premium a::after {
    content: '';
    position: absolute;
    bottom: 0;
    left: 0;
    width: 0;
    height: 2px;
    background: var(--primary);
    transition: width 0.3s ease;
}

.menu-item-premium a:hover::after {
    width: 100%;
}

.menu-item-premium.current-menu-item a {
    color: var(--primary);
    opacity: 1;
}

.menu-item-premium.current-menu-item a::after {
    width: 100%;
}

/* Mega Menu Styles — CHỈ áp dụng trên desktop.
   Mobile cần .nav-links { position: fixed } để làm slide-in panel.
   Không được dùng position: static !important ở global vì sẽ override mobile fixed. */
@media (min-width: 1025px) {
    .main-nav,
    .nav-list,
    .nav-item-wrapper {
        position: static !important;
    }
}

#header-container {
    position: relative;
}

.mega-menu-container {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    background: #ffffff;
    border-bottom: 2px solid var(--primary);
    box-shadow: 0 40px 80px rgba(0, 0, 0, 0.1);
    opacity: 0;
    visibility: hidden;
    transform: translateY(0);
    transition: all 0.3s ease;
    z-index: 1000;
    padding: 2.5rem 0;
}

.menu-item-premium:hover .mega-menu-container,
.nav-item-wrapper:hover .mega-menu-container {
    opacity: 1;
    visibility: visible;
}

.mega-menu-content {
    max-width: 1280px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

@media (min-width: 1024px) {
    .mega-menu-content {
        padding-left: var(--site-px-desktop);
        padding-right: var(--site-px-desktop);
    }
}

.mega-menu-grid {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 1rem;
    width: 100%;
}

.mega-menu-item {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.5rem;
    text-decoration: none;
    transition: all 0.3s ease;
    text-align: center;
    min-width: 0;
    /* Allow items to shrink if needed */
}

.mega-menu-image-wrapper {
    width: 100%;
    aspect-ratio: 16/9;
    border-radius: 0.5rem;
    overflow: hidden;
    background: #f8fafc;
    border: 1px solid rgba(0, 0, 0, 0.05);
    display: flex;
    align-items: center;
    justify-content: center;
}

.mega-menu-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    padding: 0.75rem;
    box-sizing: border-box;
    transition: transform 0.6s ease;
}

.mega-menu-info {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.25rem;
    width: 100%;
}

.mega-menu-item:hover .mega-menu-image {
    transform: scale(1.1);
}

.mega-menu-car-title {
    color: var(--c-text);
    font-size: 0.95rem;
    font-weight: 800;
    margin: 0;
    transition: color 0.3s ease;
    text-transform: none;
    letter-spacing: -0.01em;
}

.mega-menu-item:hover .mega-menu-car-title {
    color: var(--primary);
}

@media (max-width: 1024px) {
    .mega-menu-container {
        display: none;
        /* Hide on mobile/tablet to use mobile menu instead */
    }
}

/* Header Styles */
.site-wrapper {
    position: relative;
    width: 100%;
    display: flex;
    flex-direction: column;
}

.site-header {
    position: sticky;
    top: 0;
    /* z-index: 200 > nav-links panel (150) → hamburger luôn click được dù panel đang mở */
    z-index: 200;
    width: 100%;
    border-bottom: 1px solid rgba(0, 0, 0, 0.05);
    background-color: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(12px);
    transition: all 0.3s ease;
}

.header-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    white-space: nowrap;
    position: relative;
    /* padding handles by .container */
    height: var(--header-height);
}

@media (max-width: 1023px) {
    :root {
        --header-height: 64px;
    }
    .header-container {
        height: 64px;
    }
}

.site-logo {
    display: flex;
    align-items: center;
    gap: 1rem;
    z-index: 50;
    color: var(--c-text);
}

.logo-link {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.logo-img {
    height: 32px;
    width: auto;
    object-fit: contain;
}

@media (max-width: 1023px) {
    .logo-img {
        height: 20px;
    }
}

.logo-icon {
    width: 1.5rem;
    height: 1.5rem;
    color: var(--primary);
}

.logo-text {
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1.25;
    letter-spacing: -0.015em;
    color: var(--c-text);
}

/* Navigation & Actions Visibility (Desktop vs Mobile) */
/* KHÔNG dùng display: none trên mobile vì position: fixed bên trong sẽ bị ẩn theo.
   Thay vào đó: absolute + 0 kích thước → không chiếm chỗ trong flex header,
   nhưng con .nav-links { position: fixed } vẫn render được. */
.main-nav-wrapper {
    position: absolute;
    width: 0;
    height: 0;
    flex: 1;
    justify-content: center;
}

.header-actions {
    display: none;
    /* Hidden on mobile */
    align-items: center;
    gap: 1.5rem;
}

.site-logo,
.mobile-actions {
    z-index: 1100; /* Stay above mobile menu overlay */
    display: flex;
    align-items: center;
    gap: 5px;
}

.hamburger-btn {
    background: none;
    border: none;
    color: var(--c-text);
    padding: 0.5rem 0 0.5rem 0.5rem;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
}

.hamburger-btn i {
    font-size: 28px; /* Standard mobile size */
}

@media (min-width: 1024px) {
    .main-nav-wrapper {
        display: flex;
        position: static; /* Restore để tham gia flex layout header */
        width: auto;
        height: auto;
    }

    .header-actions {
        display: flex;
    }

    .mobile-actions {
        display: none;
    }
}

.nav-list {
    display: flex;
    align-items: center;
    gap: 2.5rem;
}

/* Top Bar styles */
.site-top-bar {
    background-color: #0c1222;
    /* Dark Premium Navy */
    color: #ffffff;
    font-size: 0.8125rem;
    padding: 8px 0;
    border-bottom: 1px solid rgba(255, 255, 255, 0.05);
}

@media (max-width: 1023px) {
    .site-top-bar {
        display: none;
        /* Hide top bar on mobile as requested by standard UX */
    }
}

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

.top-bar-left,
.top-bar-right {
    display: flex;
    align-items: center;
    gap: 1.5rem;
}

.top-bar-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    color: rgba(255, 255, 255, 0.8);
    transition: color 0.3s ease;
}

.top-bar-item:hover {
    color: var(--primary);
}

.top-bar-item .material-symbols-outlined {
    font-size: 16px;
    color: var(--primary);
}

.top-bar-label {
    font-weight: 500;
    opacity: 0.7;
}

.top-bar-value {
    font-weight: 700;
}

.top-bar-divider {
    width: 1px;
    height: 12px;
    background: rgba(255, 255, 255, 0.2);
}

.top-bar-socials {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.top-bar-social-link {
    color: rgba(255, 255, 255, 0.6);
    font-size: 0.875rem;
    transition: all 0.3s ease;
}

.top-bar-social-link:hover {
    color: var(--primary);
    transform: translateY(-2px);
}

/* Header Adjustments after removing contact info */
.header-actions {
    gap: 1rem;
}

@media (min-width: 1024px) {
    .nav-list {
        gap: 2.5rem;
        /* Restore spacious gap */
    }
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 9999px;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    transition: all 0.3s;
    cursor: pointer;
    border: none;
    outline: none;
}

.btn-primary {
    background-color: var(--primary);
    color: var(--primary-contrast);
    box-shadow: 0 10px 15px -3px rgba(var(--primary-rgb), 0.2), 0 4px 6px -2px rgba(var(--primary-rgb), 0.1);
}

.btn-primary:hover {
    background-color: #b90a15;
    /* Darker shade of brand red */
    color: var(--primary-contrast);
    box-shadow: 0 12px 20px -5px rgba(185, 10, 21, 0.4);
    transform: translateY(-1px);
}

.btn-cta {
    padding: 0.625rem 1.5rem;
    font-size: 0.75rem;
}

.btn-sm {
    padding: 0.5rem 1rem;
    font-size: 0.625rem;
}

.hamburger-btn:focus {
    outline: none;
}

/* =============================================
   MOBILE MENU PANEL (Slide-in Drawer)
   Dùng chung nav .nav-links cho cả desktop & mobile.
   Desktop: flex horizontal (CSS ở dưới).
   Mobile : panel fixed từ phải, toggle bằng class .active.
   ============================================= */

/* Khoá scroll khi menu mở */
body.menu-open {
    overflow: hidden;
}

/* Backdrop mờ — pseudo-element trên .nav-links khi active */
.nav-links.active::before {
    content: '';
    position: fixed;
    inset: 0;
    background: rgba(0, 0, 0, 0.45);
    z-index: -1; /* Nằm sau panel nhưng trước nội dung trang */
    backdrop-filter: blur(2px);
    -webkit-backdrop-filter: blur(2px);
    animation: fadeIn 0.25s ease;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to   { opacity: 1; }
}


/* =============================================
   MOBILE NAV PANEL (Slide-in Drawer)
   ============================================= */
@media (max-width: 1024px) {
    .nav-links {
        display: flex !important; /* Force visible on mobile */
        position: fixed;
        top: 0;
        right: -100%;
        width: 300px;
        height: 100vh;
        background: #ffffff;
        flex-direction: column;
        justify-content: flex-start;
        align-items: flex-start;
        gap: 0;
        padding: 100px 24px 30px;
        overflow-y: auto;
        transition: all 0.4s cubic-bezier(0.165, 0.84, 0.44, 1);
        box-shadow: -10px 0 30px rgba(0, 0, 0, 0.1);
        /* Panel phải cao hơn page content nhưng thấp hơn header.
           Header được ép z-index: 200 (xem rule .site-header bên dưới),
           panel ở 150 → nằm trên page content, dưới header → hamburger luôn click được */
        z-index: 150;
        display: flex;
        box-sizing: border-box;
    }

    .nav-links.active {
        right: 0;
    }

    .nav-links > li {
        width: 100%;
        border-bottom: 1px solid rgba(0, 0, 0, 0.06);
    }

    .nav-links li a {
        color: #1a1e26 !important;
        font-size: 15px;
        padding: 14px 0;
        display: block;
        font-weight: 700;
        text-transform: uppercase;
        letter-spacing: 0.05em;
    }

    .nav-links li a::after {
        display: none !important;
    }

    /* SUBMENU ACCORDION
       Desktop rule .nav-list .sub-menu đã được chuyển vào @media (min-width:1025px)
       nên không còn conflict — không cần !important nữa */
    .nav-links .sub-menu {
        position: static;
        width: 100%;
        min-width: 0;
        background: transparent;
        box-shadow: none;
        border-top: none;
        opacity: 1;
        visibility: visible;
        transform: none;
        display: none; /* Hidden by default */
        padding: 0 0 12px 16px;
        backdrop-filter: none;
        transition: none;
    }

    .nav-links li.active > .sub-menu {
        display: block;
    }

    .nav-links .sub-menu li a {
        padding: 8px 0;
        font-size: 14px;
        color: var(--c-text-muted) !important;
        text-transform: none;
        font-weight: 600;
    }

    .nav-links .sub-menu li a:hover {
        color: var(--primary) !important;
        padding-left: 5px;
    }

    /* SUBMENU TOGGLE BUTTON */
    .menu-item-has-children {
        position: relative;
    }

    .menu-item-has-children > a {
        padding-right: 44px;
    }

    .submenu-toggle {
        position: absolute;
        top: 0;
        right: 0;
        width: 44px;
        height: 48px;
        background: none;
        border: none;
        border-left: 1px solid rgba(0, 0, 0, 0.05);
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        color: #64748b;
        z-index: 5;
    }

    .submenu-toggle i {
        font-size: 12px;
        transition: transform 0.3s;
        pointer-events: none;
    }

    .menu-item-has-children.active > .submenu-toggle i {
        transform: rotate(180deg);
        color: var(--primary);
    }

    /* ── "Sản phẩm" accordion (has-cars-submenu) ─── */
    /* <li> cần relative để .submenu-toggle absolute đúng vị trí */
    .has-cars-submenu {
        position: relative;
    }

    /* Link "Sản phẩm" nhường chỗ cho nút toggle bên phải */
    .has-cars-submenu > .nav-item-wrapper > a {
        padding-right: 44px;
    }

    /* Toggle button được inject vào sau <a> bên trong .nav-item-wrapper */
    .has-cars-submenu > .nav-item-wrapper > .submenu-toggle {
        position: absolute;
        top: 0;
        right: 0;
        width: 44px;
        height: 48px;
        background: none;
        border: none;
        border-left: 1px solid rgba(0, 0, 0, 0.05);
        display: flex;
        align-items: center;
        justify-content: center;
        cursor: pointer;
        color: #64748b;
        z-index: 5;
    }

    /* Mobile sub-menu: ẩn mặc định, là direct child của <li> */
    .nav-links .mobile-cars-submenu {
        display: none;
        list-style: none;
        padding: 0 0 12px 16px;
        margin: 0;
    }

    /* Mở khi <li> có class active — JS cũng setProperty('display','block','important') để đảm bảo */
    .has-cars-submenu.active > .mobile-cars-submenu {
        display: block;
    }

    /* Style item xe trong accordion */
    .mobile-cars-submenu li a {
        padding: 8px 0 !important;
        font-size: 14px !important;
        color: #64748b !important;
        text-transform: none !important;
        font-weight: 600 !important;
        letter-spacing: 0 !important;
        display: block !important;
    }

    .mobile-cars-submenu li a:hover {
        color: var(--primary) !important;
        padding-left: 5px !important;
    }

    /* Ẩn mega-menu container trên mobile */
    .nav-links .mega-menu-container {
        display: none !important;
    }
}

/* Ẩn submenu toggle trên desktop — PHẢI đặt trong min-width để không override mobile flex.
   Rule global display:none đặt SAU @media(max-width) sẽ thắng do cùng specificity → arrow mất. */
@media (min-width: 1025px) {
    .submenu-toggle {
        display: none;
    }
}

/* Mobile cars sub-menu: ẩn trên desktop, JS setProperty kiểm soát trên mobile */
@media (min-width: 1025px) {
    .mobile-cars-submenu {
        display: none !important;
    }
}

button:hover, button:focus {
    background-color: transparent;
}
.menu-toggle:hover, .menu-toggle:focus,
.submenu-toggle:hover, .submenu-toggle:focus {
    background: none !important;
    outline: none;
}

/* Modal Styles */
.modal-overlay {
    position: fixed;
    top: 0;
    right: 0;
    bottom: 0;
    left: 0;
    z-index: 100;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1rem;
    opacity: 0;
    pointer-events: none;
    transition: all 0.3s;
    color: var(--c-text);
}

#modal-backdrop {
    position: absolute;
    inset: 0;
    background-color: rgba(255, 255, 255, 0.8);
    backdrop-filter: blur(4px);
}

.modal-content {
    position: relative;
    width: 100%;
    max-width: 32rem;
    /* max-w-lg */
    transform: scale(0.9);
    opacity: 0;
    transition: all 0.3s;
    background-color: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.05);
    border-radius: 2rem;
    overflow: hidden;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25);
    color: var(--c-text);
}

.dark .modal-content {
    background-color: var(--bg-body);
    border-color: rgba(255, 255, 255, 0.1);
    color: var(--c-white);
}

.close-modal-btn {
    position: absolute;
    top: 1.5rem;
    right: 1.5rem;
    color: rgba(0, 0, 0, 0.4);
    background: none;
    border: none;
    cursor: pointer;
    transition: color 0.3s;
}

.dark .close-modal-btn {
    color: rgba(255, 255, 255, 0.4);
}

.close-modal-btn:hover {
    color: var(--primary);
}

.modal-body {
    padding: 2.5rem 1.5rem;
}

@media (min-width: 768px) {
    .modal-body {
        padding: 3.5rem 3rem;
    }
}

.modal-title {
    font-size: 1.75rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: -0.01em;
    margin-bottom: 1rem;
    line-height: 1.2;
}

@media (min-width: 768px) {
    .modal-title {
        font-size: 2.25rem;
    }
}

.modal-desc {
    font-size: 0.875rem;
    line-height: 1.6;
    opacity: 0.8;
    margin-bottom: 2rem;
}

/* Success Modal Specifics */
.success-popup {
    z-index: 10000;
}

.thank-you-card {
    max-width: 400px;
    padding: 3rem 2rem;
    text-align: center;
}

.success-icon-wrapper {
    width: 80px;
    height: 80px;
    background-color: rgba(78, 143, 195, 0.1);
    color: var(--primary);
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
}

.success-icon {
    font-size: 48px;
}

.modal-form {
    text-align: left;
}

/* ── Modal mobile fix ───────────────────────────────────────────────────── */
@media (max-width: 767px) {
    .modal-overlay {
        padding: 0;
        align-items: flex-end;   /* bottom-sheet từ dưới lên */
    }
    .modal-content {
        width: 100%;
        max-width: 100%;
        border-radius: 1.5rem 1.5rem 0 0;
        max-height: 90dvh;       /* không vượt quá 90% màn hình */
        overflow-y: auto;
        -webkit-overflow-scrolling: touch;
    }
    .modal-body {
        padding: 2rem 1.25rem 2.5rem;
    }
    .close-modal-btn {
        top: 1rem;
        right: 1rem;
    }
}


/* Premium Dark Footer */
.site-footer-premium {
    background-color: #333333;
    color: #ffffff;
    padding: 4rem 0 3rem;
    font-size: 0.9rem;
}

.footer-main-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
}

@media (min-width: 768px) {
    .footer-main-grid {
        grid-template-columns: 1.5fr 1fr 1fr 1fr;
    }
}

.footer-logos {
    margin-bottom: 2rem;
}

.footer-logo-img {
    height: 24px;
    width: auto;
}

.footer-dealer-name {
    font-size: 1.5rem;
    font-weight: 800;
    margin-bottom: 1.5rem;
    color: #ffffff;
}

.footer-contact-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 1rem;
}

.footer-contact-item {
    display: flex;
    gap: 0.75rem;
    align-items: flex-start;
}

.footer-contact-item span {
    font-size: 1.25rem;
    color: #ffffff;
    margin-top: 0.1rem;
}

.footer-contact-item p {
    margin: 0;
    line-height: 1.4;
    color: rgba(255, 255, 255, 0.8);
}

.footer-company-legal {
    font-size: 0.85rem;
    line-height: 1.6;
    color: #ffffff;
    font-weight: 700;
    text-transform: uppercase;
    margin-top: 1rem;
}

.company-tax {
    margin-top: 0.5rem;
}

.footer-link-list {
    list-style: none;
    padding: 0;
    margin: 0;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.footer-link-list li a {
    color: rgba(255, 255, 255, 0.8);
    text-decoration: none;
    transition: color 0.3s;
    font-weight: 500;
}

.footer-link-list li a:hover {
    color: var(--primary);
}

.footer-socials {
    display: flex;
    gap: 1.5rem;
    margin-top: 0;
}

.social-icon {
    font-size: 1.75rem;
    color: #ffffff;
    transition: transform 0.3s;
}

.social-icon:hover {
    transform: scale(1.1);
    color: var(--primary);
}

@media (max-width: 767px) {
    .footer-main-grid {
        text-align: left;
    }

    .footer-socials {
        justify-content: flex-start;
    }
}


/* Main Content Layout */
.main-content {
    display: flex;
    flex-direction: column;
    gap: 4rem;
    /* gap-16 */
    padding-top: 2.5rem;
}

/* Hero Section */
.hero-section {
    width: 100%;
    margin-bottom: 2rem;
}



.hero-bg {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    width: 100%;
    height: calc(95vh - 48px);
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    padding-bottom: 3rem;
    border-radius: 1rem;
    overflow: hidden;
}

.hero-container {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1.5rem;
    padding-left: 0;
    /* Align with parent padding */
}

.hero-content {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    max-width: 42rem;
    /* max-w-2xl */
    text-align: left;
}

.hero-title {
    color: #ffffff;
    font-size: 2.25rem;
    /* text-4xl */
    font-weight: 700;
    line-height: 1.25;
    letter-spacing: -0.033em;
}

@media (min-width: 768px) {
    .hero-title {
        font-size: 3.75rem;
        /* text-6xl */
    }
}

.hero-desc {
    color: rgba(255, 255, 255, 0.9);
    font-size: 0.875rem;
    /* text-sm */
    font-weight: 400;
    line-height: 1.5;
}

@media (min-width: 768px) {
    .hero-desc {
        font-size: 1.125rem;
        /* text-lg */
        line-height: 1.625;
    }
}

.hero-cta {
    min-width: 84px;
    max-width: 480px;
    height: 2.5rem;
    /* h-10 */
    padding: 0 1rem;
    font-size: 0.875rem;
}

@media (min-width: 768px) {
    .hero-cta {
        height: 3rem;
        /* h-12 */
        padding: 0 1.5rem;
        font-size: 1rem;
    }
}

.truncate {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

/* Technology Section */
/* Technology Section Wrapper */

.tech-section {
    width: 100%;
    padding: 100px 0;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

.tech-section.dark-theme {
    color: #ffffff;
}

.tech-section.dark-theme .section-title {
    color: #ffffff;
}

.tech-section.dark-theme .section-desc {
    color: rgba(255, 255, 255, 0.8);
}

.tech-section.dark-theme .btn-outline {
    border-color: rgba(255, 255, 255, 0.3);
    color: #ffffff;
}

.tech-section.dark-theme .btn-outline:hover {
    background-color: #ffffff;
    color: #0a0f1d;
}

/* Technology Layout */
.tech-videos-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2rem;
}

@media (min-width: 1024px) {
    .tech-videos-grid {
        grid-template-columns: 1fr 1fr;
    }
}

.tech-video-item {
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: 1rem;
    overflow: hidden;
    box-shadow: 0 25px 50px rgba(0, 0, 0, 0.5);
    transition: transform 0.3s ease;
}

.tech-video-item:hover {
    transform: translateY(-5px);
}

/* Global Typography for Sections */
.section-header {
    margin-bottom: 2rem;
    text-align: left;
}

.section-desc {
    font-size: 1rem;
    color: var(--c-text-muted);
    line-height: 1.625;
    max-width: 48rem;
}

.btn-outline {
    background-color: transparent;
    border: 1px solid rgba(0, 0, 0, 0.2);
    color: var(--c-text);
    font-size: 1rem;
    font-weight: 700;
    height: 3rem;
    padding: 0 1.5rem;
    border-radius: 9999px;
    transition: all 0.3s;
}

.dark .btn-outline {
    border-color: rgba(255, 255, 255, 0.2);
    color: var(--c-white);
}

.btn-outline:hover {
    background-color: rgba(0, 0, 0, 0.1);
}

.dark .btn-outline:hover {
    background-color: rgba(255, 255, 255, 0.1);
}

.tech-video {
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: 0.5rem;
    position: relative;
    overflow: hidden;
    cursor: pointer;
}

.tech-video-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.tech-video:hover .tech-video-img {
    transform: scale(1.05);
}

.video-overlay {
    position: absolute;
    inset: 0;
    background-color: rgba(0, 0, 0, 0.2);
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background-color 0.3s;
}

.tech-video:hover .video-overlay {
    background-color: rgba(0, 0, 0, 0.3);
}

.play-btn {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 4rem;
    height: 4rem;
    background-color: rgba(215, 12, 25, 0.8);
    /* primary/80 */
    backdrop-filter: blur(4px);
    border-radius: 9999px;
    transition: all 0.3s;
    border: none;
    cursor: pointer;
}

@media (min-width: 768px) {
    .play-btn {
        width: 5rem;
        height: 5rem;
    }
}

.tech-video:hover .play-btn {
    background-color: var(--primary);
    transform: scale(1.1);
}

.play-icon {
    color: var(--bg-body);
    font-size: 2.25rem;
}

@media (min-width: 768px) {
    .play-icon {
        font-size: 3rem;
    }
}

/* Models Section */
.models-section {
    display: flex;
    flex-direction: column;
    gap: 3rem;
    padding: 2.5rem 0;
    /* Vertical padding only */
}

.news-info {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
    padding: 0.5rem 0 0 0 !important;
}

.car-info {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    padding: 0 !important;
    /* Force zero padding to align with image/logo */
}

.models-group {
    width: 100%;
}

.group-title {
    color: var(--c-text);
    font-size: 2.5rem;
    font-weight: 700;
    line-height: 1.25;
    letter-spacing: -0.015em;
    padding: 0.5rem 0 0.75rem 0 !important;
    margin-left: 0 !important;
    position: relative;
    /* Use pseudo-element for border to avoid pushing text */
}

.group-title::before {
    content: '';
    position: absolute;
    left: -1.15rem;
    /* Fits inside the 1.25rem/20px container padding on mobile */
    top: 0.5rem;
    bottom: 0.75rem;
    width: 4px;
    background-color: currentColor;
}

@media (min-width: 768px) {
    .group-title {
        margin-left: 0;
    }
}

.dark .group-title {
    color: var(--c-white);
}

.border-emerald::before {
    color: #10b981;
}

.border-primary::before {
    color: var(--primary);
}

.highlight-text {
    color: var(--primary);
}



.models-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
    padding: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
}

@media (min-width: 1024px) {
    .models-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 1.5rem;
    }
}

.car-card {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding-bottom: 0.75rem;
    transition: all 0.3s;
}

.car-image-wrapper {
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: 1rem;
    overflow: hidden;
    border: 1px solid rgba(0, 0, 0, 0.05);
}

.car-image-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}

.car-card:hover .car-image-img {
    transform: scale(1.1);
}

.car-title {
    color: var(--c-text);
    font-size: 1.25rem;
    font-weight: 700;
    line-height: 1.5;
    transition: color 0.3s;
}

@media (max-width: 768px) {
    .car-title {
        font-size: 1rem;
    }

    .car-specs {
        font-size: 0.75rem;
    }
}

.dark .car-title {
    color: var(--c-white);
}

.car-card:hover .car-title {
    color: var(--primary);
}

.car-specs {
    color: var(--c-text-muted);
    font-size: 0.875rem;
    line-height: 1.5;
}

.dark .car-specs {
    color: rgba(255, 255, 255, 0.7);
}

.empty-msg {
    padding: 0;
    color: rgba(255, 255, 255, 0.4);
}

/* Highlights Section */
.highlights-section {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

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

.highlights-grid-container {
    width: 100%;
}

.highlights-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .highlights-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

.highlight-item {
    width: 100%;
}

.highlight-card {
    position: relative;
    width: 100%;
    aspect-ratio: 16 / 10;
    border-radius: 0.5rem;
    overflow: hidden;
}

.highlight-bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
}

.highlight-overlay {
    position: absolute;
    inset: 0;
    background: linear-gradient(to top, rgba(0, 0, 0, 0.6), transparent);
}

.highlight-content {
    position: absolute;
    bottom: 0;
    left: 0;
    padding: 1.5rem;
}

.highlight-title {
    color: var(--c-white);
    font-size: 1.5rem;
    font-weight: 700;
}

.highlight-desc {
    color: rgba(255, 255, 255, 0.8);
    margin-top: 0.25rem;
}

/* News Section */
.news-section {
    display: flex;
    flex-direction: column;
    gap: 2rem;
    align-items: flex-start;
    /* Fix centering shift */
    padding: 4rem 0;
    /* Vertical padding only */
    margin-left: 0 !important;
}

.news-container {
    width: 100%;
    padding: 0 !important;
    margin-left: 0 !important;
}

.news-grid {
    display: grid;
    gap: 1.5rem;
    padding: 0 !important;
    margin-top: 1.5rem;
    margin-left: 0 !important;
}

@media (min-width: 768px) and (max-width: 1023px) {
    .news-grid {
        grid-template-columns: repeat(2, 1fr);
    }
}

@media (min-width: 1024px) {
    .news-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.news-card {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    cursor: pointer;
}

.news-image-wrapper {
    width: 100%;
    aspect-ratio: 16 / 9;
    border-radius: 0.5rem;
    overflow: hidden;
    background-color: rgba(0, 0, 0, 0.1);
}

.news-image-img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.news-card:hover .news-image-img {
    transform: scale(1.05);
}

.news-info {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
}

.news-category {
    display: inline-block;
    color: var(--primary);
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 0.25rem;
}

.news-title {
    color: var(--c-text);
    font-size: 1.1rem;
    font-weight: 700;
    line-height: 1.5;
    transition: color 0.3s;
}

.dark .news-title {
    color: var(--c-white);
}

.news-card:hover .news-title {
    color: var(--primary);
}

.news-excerpt {
    color: rgba(10, 15, 29, 0.8);
    font-size: 0.875rem;
    line-height: 1.5;
}

.dark .news-excerpt {
    color: rgba(255, 255, 255, 0.8);
}

.news-cta {
    height: 3rem;
    padding: 0 1.5rem;
    font-size: 1rem;
    min-width: 84px;
    max-width: 480px;
}

/* Contact Section */
.display-section {
    container-type: inline-size;
}

@media (max-width: 767px) {
    .display-section {
        /* Remove or adjust to avoid overflow. 
           If the goal is full-width box, use negative margin on the INNER box inside container */
        overflow-x: hidden;
    }
}

/* Contact Section Styles - New Design */
.contact-section-new {
    position: relative;
    padding: 120px 0;
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
}

.contact-card-container {
    display: grid;
    grid-template-columns: 1fr;
    gap: 4rem;
}

@media (min-width: 1024px) {
    .contact-card-container {
        grid-template-columns: 1fr 500px;
        /* Swaped: Highlights Left, Card Right */
        align-items: center;
    }
}

/* Highlights Styling (Left Side) */
.contact-highlights {
    color: #ffffff;
}

.highlights-main-title {
    color: #ffffff;
    font-size: 1.75rem;
    font-weight: 700;
    margin-bottom: 2.5rem;
    line-height: 1.2;
    text-transform: uppercase;
    letter-spacing: -0.01em;
}

@media (min-width: 1024px) {
    .highlights-main-title {
        font-size: 2.25rem;
    }
}

.highlights-list {
    display: flex;
    flex-direction: column;
    gap: 2.5rem;
}

.highlight-item-sub {
    display: flex;
    gap: 1.5rem;
    align-items: flex-start;
}

.highlight-icon-wrap {
    width: 3.5rem;
    height: 3.5rem;
    border-radius: 1rem;
    background: rgba(215, 12, 25, 0.15);
    /* primary with transparency */
    border: 1px solid rgba(215, 12, 25, 0.3);
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--primary);
    flex-shrink: 0;
    backdrop-filter: blur(10px);
}

.highlight-icon-wrap span {
    font-size: 1.75rem;
}

.highlight-text-wrap h3 {
    font-size: 1.35rem;
    font-weight: 800;
    margin-bottom: 0.5rem;
    color: #ffffff;
}

.highlight-text-wrap p {
    font-size: 1rem;
    color: rgba(255, 255, 255, 0.75);
    line-height: 1.6;
    margin: 0;
}

/* Info Card Styling (Right Side) */
.contact-info-card {
    background: #ffffff;
    padding: 3.5rem;
    border-radius: 2rem;
    box-shadow: 0 50px 100px rgba(0, 0, 0, 0.4);
    color: #0f172a;
}

.contact-info-card .company-name {
    color: var(--primary);
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    font-size: 0.75rem;
    margin-bottom: 1rem;
}

.contact-info-card .section-title {
    color: #0f172a;
    font-size: 2.25rem;
    text-align: left;
    margin-bottom: 1.25rem;
    font-weight: 800;
}

.contact-info-card .section-desc {
    color: #64748b;
    text-align: left;
    margin: 0 0 2.5rem 0;
    max-width: 100%;
}

.contact-info-list {
    display: flex;
    flex-direction: column;
    gap: 1.75rem;
    margin-bottom: 3rem;
}

.contact-info-item {
    display: flex;
    gap: 1.25rem;
    align-items: flex-start;
}

.contact-info-item span {
    color: var(--primary);
    font-size: 1.75rem;
    flex-shrink: 0;
}

.info-text label {
    display: block;
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    color: #94a3b8;
    margin-bottom: 0.25rem;
    letter-spacing: 0.05em;
}

.info-text p {
    font-size: 1rem;
    font-weight: 600;
    color: #1e293b;
    line-height: 1.5;
}

.contact-info-action {
    text-align: center;
}

.contact-info-action button {
    width: 100%;
}

@media (min-width: 768px) {
    .contact-info-action button {
        width: auto;
        padding: 1rem 2.5rem;
    }
}

@media (max-width: 767px) {
    .contact-info-card {
        padding: 2.5rem 1.5rem;
        border-radius: 1.5rem;
    }

    .contact-info-card .section-title {
        font-size: 1.75rem;
    }
}

/* Ensure CF7 submit button is styled consistent with premium look */
.wpcf7-submit {
    display: block !important;
    width: 100% !important;
    max-width: 300px;
    margin: 2rem auto 0 !important;
    padding: 1rem 2rem !important;
    height: auto !important;
    background-color: var(--primary) !important;
    color: white !important;
    font-weight: 900 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.15em !important;
    border-radius: 9999px !important;
    border: none !important;
    transition: all 0.3s ease !important;
    cursor: pointer !important;
}

.wpcf7-submit:hover {
    background-color: white !important;
    color: var(--primary) !important;
    transform: translateY(-2px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.2);
}

/* Form Styles */
.form-container {
    display: flex;
    flex-direction: column;
    gap: 1.25rem;
}

/* Global Form Overrides for CF7 compatibility */
.wpcf7-form .wpcf7-text,
.wpcf7-form .wpcf7-number,
.wpcf7-form .wpcf7-date,
.wpcf7-form .wpcf7-textarea,
.wpcf7-form .wpcf7-select {
    width: 100% !important;
    height: 3.5rem;
    padding: 0 1.5rem !important;
    border-radius: 1rem !important;
    background-color: rgba(0, 0, 0, 0.05) !important;
    border: 2px solid transparent !important;
    color: #1a1a1a !important;
    font-size: 1rem !important;
    font-weight: 500 !important;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1) !important;
    outline: none !important;
    margin-bottom: 0 !important;
}

.dark .wpcf7-form .wpcf7-text,
.dark .wpcf7-form .wpcf7-number,
.dark .wpcf7-form .wpcf7-date,
.dark .wpcf7-form .wpcf7-textarea,
.dark .wpcf7-form .wpcf7-select {
    background-color: rgba(255, 255, 255, 0.05) !important;
    color: #ffffff !important;
}

.wpcf7-form .wpcf7-text:focus,
.wpcf7-form .wpcf7-number:focus,
.wpcf7-form .wpcf7-date:focus,
.wpcf7-form .wpcf7-textarea:focus,
.wpcf7-form .wpcf7-select:focus {
    background-color: #ffffff !important;
    border-color: var(--primary) !important;
    box-shadow: 0 10px 15px -3px rgba(var(--primary-rgb), 0.1) !important;
}

.dark .wpcf7-form .wpcf7-text:focus,
.dark .wpcf7-form .wpcf7-number:focus,
.dark .wpcf7-form .wpcf7-date:focus,
.dark .wpcf7-form .wpcf7-textarea:focus,
.dark .wpcf7-form .wpcf7-select:focus {
    background-color: rgba(255, 255, 255, 0.1) !important;
}

/* Form đăng ký trong bài viết → card nổi bật, giới hạn chiều ngang */
.single-post-page .post-prose-content .wpcf7 {
    max-width: 560px;
    margin: 2.5rem auto;
    padding: 2rem 1.75rem 2.25rem;
    background: linear-gradient(180deg, #ffffff 0%, #f4f7fc 100%);
    border: 1px solid rgba(var(--primary-rgb), 0.18);
    border-top: 4px solid var(--primary);
    border-radius: 20px;
    box-shadow: 0 18px 40px -18px rgba(15, 23, 42, 0.28);
    scroll-margin-top: 110px;
}

.single-post-page .post-prose-content .wpcf7 .form-heading {
    margin: 0 0 0.4rem;
    text-align: center;
    font-size: 1.5rem;
    font-weight: 800;
    letter-spacing: -0.01em;
    color: var(--primary);
}

.single-post-page .post-prose-content .wpcf7 .form-subheading {
    margin: 0 auto 1.5rem;
    max-width: 420px;
    text-align: center;
    font-size: 0.95rem;
    line-height: 1.5;
    color: #64748b;
}

.single-post-page .post-prose-content .wpcf7 .form-container {
    max-width: 420px;
    margin: 0 auto;
}

@media (max-width: 600px) {
    .single-post-page .post-prose-content .wpcf7 {
        padding: 1.5rem 1.25rem 1.75rem;
        border-radius: 16px;
    }
}

.wpcf7-form .wpcf7-textarea {
    height: auto !important;
    padding-top: 1rem !important;
    padding-bottom: 1rem !important;
    border-radius: 1.5rem !important;
}

.wpcf7-submit {
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    width: 100% !important;
    padding: 1.25rem !important;
    background-color: var(--primary) !important;
    color: var(--primary-contrast) !important;
    font-weight: 900 !important;
    text-transform: uppercase !important;
    letter-spacing: 0.15em !important;
    border-radius: 1rem !important;
    border: none !important;
    cursor: pointer !important;
    transition: all 0.4s ease !important;
    margin-top: 1rem !important;
}

.wpcf7-submit:hover {
    transform: translateY(-3px) !important;
    box-shadow: 0 15px 30px rgba(var(--primary-rgb), 0.3) !important;
    filter: brightness(1.1);
}

.wpcf7-response-output {
    background-color: rgba(255, 255, 255, 0.05);
    border: none !important;
    border-radius: 1rem !important;
    color: white !important;
    padding: 1rem !important;
    text-align: center;
    margin-top: 1.5rem !important;
}

.wpcf7-mail-sent-ok {
    background-color: rgba(16, 185, 129, 0.1);
    color: #10b981 !important;
}

.wpcf7-validation-errors {
    background-color: rgba(239, 68, 68, 0.1);
    color: #ef4444 !important;
}

/* Cars Archive */
.cars-archive {
    padding: var(--spacing-xl) 0;
}

.cars-archive-header {
    text-align: center;
    margin-bottom: var(--spacing-xl);
    display: flex;
    flex-direction: column;
    gap: var(--spacing-sm);
}

.cars-archive-title {
    font-size: 2.5rem;
    font-weight: 900;
    text-transform: uppercase;
}

@media (min-width: 768px) {
    .cars-archive-title {
        font-size: 4rem;
    }
}

.cars-archive-desc {
    max-width: 45rem;
    margin: 0 auto;
    font-size: 1.125rem;
    line-height: 1.6;
    color: var(--c-text-muted);
}

.cars-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1rem;
}

@media (min-width: 1024px) {
    .cars-grid {
        grid-template-columns: repeat(4, 1fr);
        gap: 2rem;
    }
}

@media (min-width: 1024px) {
    .cars-grid {
        grid-template-columns: repeat(4, 1fr);
    }
}

.car-card-premium__price {
    margin-top: auto;
    padding-top: 1rem;
    border-top: 1px dashed rgba(0, 0, 0, 0.1);
    color: var(--c-primary);
    font-weight: 700;
    font-size: 1rem;
    display: flex;
    justify-content: space-between;
    align-items: center;
    flex-wrap: nowrap;
}

.car-card-premium__price span {
    font-size: 0.8rem;
    font-weight: 400;
    color: var(--c-text-muted);
    white-space: nowrap;
}

/* Car Card Premium */
.car-card-premium {
    background-color: #ffffff;
    border: 1px solid rgba(0, 0, 0, 0.06);
    border-radius: 2rem;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
}

.car-card-premium:hover {
    border-color: var(--primary);
    transform: translateY(-0.5rem);
    background-color: rgba(0, 0, 0, 0.02);
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
}

.car-card-premium__image-wrapper {
    position: relative;
    aspect-ratio: 16/10;
    overflow: hidden;
    background: rgba(0, 0, 0, 0.01);
}

.car-card-premium__image {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
    /* Better for car photos to avoid cropping */
    transition: transform 0.6s cubic-bezier(0.165, 0.84, 0.44, 1);
}

.car-card-premium:hover .car-card-premium__image {
    transform: scale(1.05);
}

.car-card-premium__content {
    padding: 0.5rem;
    display: flex;
    flex-direction: column;
    flex: 1;
}

@media (min-width: 768px) {
    .car-card-premium__content {
        padding: 1.5rem;
    }
}

.car-card-premium__header {
    margin-bottom: 0.75rem;
}

.car-card-premium__title {
    font-size: 0.95rem;
    /* Adjusted for 2-col mobile */
    font-weight: 800;
    text-transform: uppercase;
    margin-bottom: 0.25rem;
    transition: color 0.3s;
    line-height: 1.2;
}

@media (min-width: 768px) {
    .car-card-premium__title {
        font-size: 1.2rem;
    }
}

.car-card-premium:hover .car-card-premium__title {
    color: var(--primary);
}

.car-card-premium__tagline {
    font-size: 0.875rem;
    color: var(--c-text-muted);
    font-style: italic;
}

.car-card-premium__specs {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 1.5rem;
    padding-top: 1.5rem;
    border-top: 1px solid rgba(0, 0, 0, 0.05);
    margin-bottom: 2rem;
}

.car-card-premium__spec-label {
    font-size: 0.75rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--primary);
    margin-bottom: 0.25rem;
}

.car-card-premium__spec-value {
    font-size: 1.125rem;
    font-weight: 700;
    color: var(--c-text);
}

.car-card-premium__footer {
    margin-top: auto;
}

.car-card-premium__btn {
    width: 100%;
    display: flex;
    justify-content: center;
    padding: 1.25rem !important;
    /* Slightly taller */
    letter-spacing: 0.15em !important;
    /* More premium spacing */
    font-weight: 900 !important;
    border-radius: 1.5rem !important;
    /* Matching card radius better */
    transition: all 0.4s ease !important;
}

.car-card-premium:hover .car-card-premium__btn {
    background-color: var(--primary);
    box-shadow: 0 0 20px rgba(78, 143, 195, 0.4);
    transform: scale(1.02);
}

.cars-archive-empty {
    padding: 5rem 0;
    text-align: center;
}

/* Contact Page Styles */
.contact-hero {
    position: relative;
    height: 600px;
    width: 100%;
    display: flex;
    align-items: center;
    overflow: hidden;
}

@media (min-width: 768px) {
    .contact-hero {
        height: 600px;
    }
}

.contact-hero__bg {
    position: absolute;
    inset: 0;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    z-index: 1;
}

.contact-hero__content {
    position: relative;
    z-index: 2;
    text-align: center;
}



.contact-hero__desc {
    max-width: 40rem;
    margin: 0 auto;
    font-size: 1rem;
    color: var(--c-text-muted);
    line-height: 1.6;
}

@media (min-width: 768px) {
    .contact-hero__desc {
        font-size: 1.125rem;
    }
}

.contact-info-section {
    position: relative;
    z-index: 10;
    margin-top: -50px !important;
    margin-bottom: 3rem;
}

.contact-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 1.5rem;
}

@media (min-width: 768px) {
    .contact-grid {
        grid-template-columns: repeat(3, 1fr);
    }
}

.contact-card {
    background-color: var(--bg-body);
    border: 1px solid rgba(0, 0, 0, 0.08);
    border-radius: 2rem;
    padding: 2.5rem;
    text-align: center;
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
    align-items: center;
}

.contact-card:hover {
    border-color: var(--primary);
    transform: translateY(-0.5rem);
}

.contact-card__icon {
    width: 4rem;
    height: 4rem;
    background: rgba(78, 143, 195, 0.1);
    border-radius: 1.25rem;
    display: flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 1.5rem;
    color: var(--primary);
    transition: transform 0.3s ease;
}

.contact-card:hover .contact-card__icon {
    transform: scale(1.1);
}

.contact-card__icon .material-symbols-outlined {
    font-size: 2rem;
}

.contact-card__title {
    font-size: 1.25rem;
    font-weight: 800;
    text-transform: uppercase;
    margin-bottom: 0.5rem;
}

.contact-card__subtitle {
    font-size: 0.875rem;
    color: var(--c-text-muted);
    margin-bottom: 1.5rem;
}

.contact-card__link {
    font-size: 1.125rem;
    font-weight: 600;
    color: var(--primary);
    text-decoration: underline;
    text-decoration-color: rgba(78, 143, 195, 0.3);
    text-underline-offset: 6px;
    transition: color 0.3s;
}

.contact-card__link:hover {
    color: var(--primary);
}


/* ── Địa chỉ nhiều showroom ────────────────────────────────────────
   Mỗi showroom là 1 .address-block riêng: pin icon + nhãn + địa chỉ
   (xem byd_get_addresses()). Dùng trong card & panel trang liên hệ;
   trang chủ dùng sẵn mẫu .contact-info-item nên không cần class này. */
.address-block {
    display: flex;
    align-items: flex-start;
    gap: 0.6rem;
    text-align: left;
}

.address-block + .address-block {
    margin-top: 0.9rem;
    padding-top: 0.9rem;
    border-top: 1px solid rgba(148, 163, 184, 0.35);
}

.address-block__pin {
    flex-shrink: 0;
    font-size: 1.25rem;
    line-height: 1.4;
    color: var(--primary);
}

.address-block__label {
    display: block;
    font-size: 0.7rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: #94a3b8;
    margin-bottom: 0.15rem;
}

.address-block__text {
    margin: 0;
    line-height: 1.45;
}

.contact-main {
    padding: 6rem 20px;
}

.contact-layout {
    display: flex;
    flex-direction: column;
    gap: 4rem;
}

@media (min-width: 1024px) {
    .contact-layout {
        flex-direction: row;
        align-items: flex-start;
    }
}

.contact-form-side {
    flex: 1;
}

@media (max-width: 1023px) {

    .contact-form-side,
    .contact-info-side {
        padding: 0 1rem;
    }
}

.contact-section-header {
    margin-bottom: 3rem;
    padding-top: 2rem;
    /* Added padding top for mobile */
}



.contact-section-desc {
    max-width: 35rem;
    color: var(--c-text-muted);
    line-height: 1.6;
}

.contact-info-side {
    width: 100%;
}

@media (min-width: 1024px) {
    .contact-info-side {
        width: 50%;
    }
}

.contact-info-panel {
    position: relative;
    background: rgba(0, 10, 20, 0.02);
    border: 1px solid rgba(0, 0, 0, 0.05);
    border-radius: 2.5rem;
    overflow: hidden;
    padding: 3rem;
    height: 100%;
    min-height: 450px;
    display: flex;
    flex-direction: column;
    justify-content: center;
}

.contact-info-panel__content {
    position: relative;
    z-index: 2;
    text-align: center;
}

.contact-info-panel__icon {
    width: 5rem;
    height: 5rem;
    background: rgba(78, 143, 195, 0.15);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 1.5rem;
    color: var(--primary);
}

.contact-info-panel__icon .material-symbols-outlined {
    font-size: 2.5rem;
}

.contact-info-panel__title {
    font-size: 1.5rem;
    font-weight: 900;
    text-transform: uppercase;
    margin-bottom: 1rem;
}

.contact-info-panel__desc {
    color: var(--c-text-muted);
    margin-bottom: 2.5rem;
}

.opening-hours-card {
    background: rgba(0, 0, 0, 0.03);
    border: 1px solid rgba(0, 0, 0, 0.05);
    border-radius: 1.5rem;
    padding: 2rem;
    text-align: left;
}

.opening-hours-title {
    font-size: 0.75rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.2rem;
    color: var(--primary);
    margin-bottom: 1.5rem;
}

.opening-hours-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.opening-hours-item {
    display: flex;
    justify-content: space-between;
    font-size: 0.875rem;
}

.opening-hours-day {
    color: var(--c-text-muted);
}

.opening-hours-time {
    font-weight: 700;
}

.contact-info-panel__bg {
    position: absolute;
    inset: 0;
    z-index: 1;
    opacity: 0.1;
    background-image: url("https://images.unsplash.com/photo-1526778548025-fa2f459cd5c1?q=80&w=2068&auto=format&fit=crop");
    background-size: cover;
    filter: grayscale(1) contrast(1.2);
}

/* FAQ Styles */
.contact-faq {
    padding: 6rem 0;
    background: rgba(0, 0, 0, 0.01);
    border-top: 1px solid rgba(0, 0, 0, 0.05);
}

.contact-faq__title {
    text-align: center;
    margin-bottom: 4rem;
}

.faq-list {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.faq-item {
    background: rgba(0, 0, 0, 0.01);
    border: 1px solid rgba(0, 0, 0, 0.05);
    border-radius: 1.5rem;
    overflow: hidden;
    transition: all 0.3s ease;
}

.faq-item:hover {
    border-color: rgba(78, 143, 195, 0.3);
    background: rgba(0, 0, 0, 0.02);
}

.faq-question {
    padding: 1.5rem 2rem;
    cursor: pointer;
    font-weight: 800;
    text-transform: uppercase;
    font-size: 0.9375rem;
    letter-spacing: 0.05em;
    display: flex;
    justify-content: space-between;
    align-items: center;
    list-style: none;
}

.faq-question::-webkit-details-marker {
    display: none;
}

.faq-question .material-symbols-outlined {
    transition: transform 0.3s ease;
    color: var(--primary);
}

.faq-item[open] .faq-question .material-symbols-outlined {
    transform: rotate(180deg);
}

.faq-answer {
    padding: 0 2rem 2rem;
    font-size: 1rem;
    line-height: 1.6;
    color: var(--c-text-muted);
}

/* CSS Reset & Variables */
:root {
    --site-px: 1.25rem;
    --site-px-desktop: 2.5rem;
    --container-width: 1360px;
}

/* Global Container - THE TRUTH TABLE FOR ALIGNMENT */
.container {
    width: 100%;
    max-width: var(--container-width);
    margin: 0 auto;
    padding-left: var(--site-px);
    padding-right: var(--site-px);
    position: relative;
}

@media (min-width: 1024px) {
    .container {
        padding-left: var(--site-px-desktop);
        padding-right: var(--site-px-desktop);
    }
}

/* Cleanup SECTION layouts */
/* .tech-section,
.models-section,
.highlights-section,
.news-section,
.display-section {
    padding-top: 5rem;
    padding-bottom: 5rem;
    width: 100%;
} */

/* Reset all internal spacings that cause misalignment */
/* .tech-grid,
.models-grid,
.news-grid,
.section-header,
.contact-box {
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
} */

/* Title Spacing reset & Decorative border setup */
.group-title {
    padding-left: 0 !important;
    margin-left: 0 !important;
    text-align: left;
    position: relative;
}

@media (max-width: 768px) {
    .group-title {
        font-size: 1.75rem;
    }
}

.group-title::before {
    content: '';
    position: absolute;
    left: -1rem;
    /* Fits inside the 2.5rem container padding */
    top: 0.5rem;
    bottom: 0.5rem;
    width: 4px;
    background-color: currentColor;
}

/* Hero cleanup */
.hero-bg {
    border-radius: 1rem;
    overflow: hidden;
    margin-bottom: 2rem;
}

/* Tech grid fix */
.tech-grid {
    display: grid;
    grid-template-columns: 1fr;
    gap: 3rem;
    align-items: center;
}

@media (min-width: 1024px) {
    .tech-grid {
        grid-template-columns: 1fr 1fr;
    }
}

/* Model Grid fix */
/* Model Grid fix already applied above */

/* Car card info cleanup */
.car-info,
.news-info {
    padding: 1rem 0 0 0 !important;
    /* No horizontal padding */
}

/* News Archive Page Styles */
.news-archive-page {
    padding-top: 3rem;
    padding-bottom: 6rem;
}

.news-archive-header {
    margin-bottom: 4rem;
    text-align: left;
}

.news-layout-split {
    display: flex;
    flex-direction: column;
    gap: 3rem;
}

@media (min-width: 1024px) {
    .news-layout-split {
        flex-direction: row;
    }
}

.news-main-col {
    flex: 1;
}

.news-sidebar {
    width: 100%;
}

@media (min-width: 1024px) {
    .news-sidebar {
        width: 320px;
        flex-shrink: 0;
    }
}

.news-sidebar-sticky {
    position: sticky;
    top: calc(var(--header-height) + 2rem);
}

/* News Grid Archive */
.news-grid-archive {
    display: grid;
    grid-template-columns: 1fr;
    gap: 2.5rem;
    align-items: start; /* card co theo nội dung, không kéo cao bằng nhau (tránh khoảng trống đáy) */
}

/* Đã bỏ nút "Xem thêm" trong card danh mục → description sát padding đáy card */
.news-grid-archive .news-card-excerpt {
    margin-bottom: 0;
}

@media (min-width: 768px) {
    .news-grid-archive {
        grid-template-columns: repeat(2, 1fr);
    }
}

.news-card-boxed {
    background: var(--bg-surface);
    border: 1px solid rgba(0, 0, 0, 0.05);
    border-radius: 1rem;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition: all 0.3s ease;
}

.news-card-boxed:hover {
    transform: translateY(-5px);
    border-color: var(--primary);
    background: #ffffff;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.05);
}

.news-card-image-wrapper {
    position: relative;
    aspect-ratio: 1.91; /* 1200x630 approx */
    overflow: hidden;
}

.news-card-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}



.news-card-link-overlay {
    position: absolute;
    inset: 0;
    z-index: 10;
}

.news-card-body {
    padding: 2rem;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
}

.news-card-meta {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 1rem;
}

.news-category {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--primary);
    letter-spacing: 0.1em;
}

.news-date {
    font-size: 0.8125rem;
    color: var(--c-text-muted);
}

.news-card-title {
    font-size: 1rem;
    font-weight: 800;
    line-height: 1.3;
    margin-bottom: 1rem;
    color: var(--c-text);
}

.news-card-excerpt {
    font-size: 0.9375rem;
    color: var(--c-text-muted);
    line-height: 1.6;
    margin-bottom: 2rem;
}

.news-read-more {
    margin-top: auto;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.875rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    color: var(--c-white);
    transition: color 0.3s ease;
}

.news-card-boxed:hover .news-read-more {
    color: var(--primary);
}

/* Sidebar Widgets */
.sidebar-widget {
    margin-bottom: 3rem;
}

.sidebar-widget-title {
    font-size: 1.25rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin-bottom: 1.5rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(255, 255, 255, 0.1);
}

.category-list {
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

.category-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 1.5rem;
    background: var(--bg-surface);
    border: 1px solid rgba(0, 0, 0, 0.05);
    border-radius: 1rem;
    font-size: 0.875rem;
    font-weight: 700;
    color: var(--c-text);
    transition: all 0.3s ease;
}

.category-item:hover,
.category-item.active {
    background: rgba(var(--primary-rgb), 0.1);
    border-color: var(--primary);
    color: var(--primary);
}

.category-count {
    background: rgba(0, 0, 0, 0.05);
    padding: 0.25rem 0.5rem;
    border-radius: 0.5rem;
    font-size: 0.75rem;
    color: var(--c-text-muted);
}

.category-item.active .category-count {
    background: var(--primary);
    color: var(--primary-contrast);
}

/* Sidebar Promo */
.sidebar-promo {
    background: linear-gradient(135deg, rgba(var(--primary-rgb), 0.2), rgba(var(--primary-rgb), 0.05));
    border: 1px solid rgba(var(--primary-rgb), 0.3);
    padding: 2.5rem;
    border-radius: 1.5rem;
    text-align: center;
}

.promo-label {
    font-size: 0.625rem;
    font-weight: 900;
    text-transform: uppercase;
    letter-spacing: 0.2em;
    color: var(--primary);
    margin-bottom: 1rem;
}

.promo-title {
    font-size: 1.25rem;
    font-weight: 900;
    text-transform: uppercase;
    margin-bottom: 1rem;
}

.promo-text {
    font-size: 0.8125rem;
    color: var(--c-text-muted);
    margin-bottom: 2rem;
    line-height: 1.5;
}

.btn-full {
    width: 100%;
}

/* Pagination */
.news-pagination {
    margin-top: 5rem;
    display: flex;
    justify-content: center;
}

.news-pagination ul {
    display: flex;
    gap: 0.5rem;
    list-style: none;
}

.news-pagination li a,
.news-pagination li span {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 3rem;
    height: 3rem;
    border-radius: 1rem;
    background: rgba(255, 255, 255, 0.05);
    border: 1px solid rgba(255, 255, 255, 0.1);
    font-weight: 700;
    transition: all 0.3s ease;
}

.news-pagination li span.current {
    background: var(--primary);
    color: var(--primary-contrast);
    border-color: var(--primary);
}

.news-pagination li a:hover {
    border-color: var(--primary);
    color: var(--primary);
}


/* Single Post Page Styles */
.single-post-page {
    padding-top: 3rem;
    padding-bottom: 6rem;
}

.post-header {
    margin-bottom: 3rem;
}

.post-meta-top {
    display: flex;
    align-items: center;
    gap: 1.5rem;
    margin-bottom: 1.5rem;
}

.post-category {
    background: rgba(var(--primary-rgb), 0.1);
    color: var(--primary);
    padding: 0.25rem 0.75rem;
    border-radius: 99px;
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.05em;
}

.post-read-time {
    font-size: 0.8125rem;
    color: var(--c-text-muted);
}

.post-title {
    margin-bottom: 2rem;
    line-height: 1.1;
}

.post-author-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.author-avatar {
    width: 3rem;
    height: 3rem;
    background: var(--bg-surface);
    border-radius: 99px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: var(--c-text-muted);
}

.author-name {
    font-weight: 700;
    color: var(--c-text);
}

.post-date {
    font-size: 0.8125rem;
    color: var(--c-text-muted);
}

.post-featured-image {
    width: 100%;
    background: #0050c1;
    border-radius: 1.5rem;
    overflow: hidden;
    margin-bottom: 4rem;
}

/* Ảnh đại diện hiển thị trọn vẹn theo tỉ lệ gốc (banner sự kiện 16:9 không bị crop/viền) */
.post-featured-image img {
    display: block;
    width: 100%;
    height: auto;
}

@media (max-width: 768px) {
    .post-featured-image {
        aspect-ratio: unset;
    }
}

.post-layout-split {
    display: flex;
    flex-direction: column;
    gap: 4rem;
}

@media (min-width: 1024px) {
    .post-layout-split {
        flex-direction: row;
    }
}

.post-main-content {
    flex: 1;
    min-width: 0;
    /* Fix flex child overflow */
}

.post-prose-content {
    font-size: 1.125rem;
    line-height: 1.8;
    color: var(--c-text);
}

.post-prose-content h2,
.post-prose-content h3 {
    color: var(--c-text);
    margin: 2.5rem 0 1rem;
    font-weight: 800;
    text-transform: uppercase;
    line-height: 1.3;
}

/* Mobile */
@media (max-width: 1023px) {
    .post-prose-content {
        font-size: 15px;
    }
    .post-prose-content h2 {
        font-size: 1.25rem;
    }
    .post-prose-content h3 {
        font-size: 1.1rem;
    }
}

/* Desktop */
@media (min-width: 1024px) {
    .post-prose-content h2 {
        font-size: 1.8rem;
    }
    .post-prose-content h3 {
        font-size: 1.5rem;
    }
}

.post-prose-content p {
    margin-bottom: 1.5rem;
}

/* ── Responsive video embeds ───────────────────────────── */
/* Wrapper cho Gutenberg embed block */
.post-prose-content .wp-block-embed,
.post-prose-content .wp-block-embed__wrapper {
    position: relative;
    width: 100%;
    margin: 1.5rem 0;
}

.post-prose-content .wp-block-embed__wrapper {
    aspect-ratio: 16 / 9;
    border-radius: 1rem;
    overflow: hidden;
}

.post-prose-content .wp-block-embed__wrapper iframe {
    position: absolute;
    inset: 0;
    width: 100% !important;
    height: 100% !important;
    border-radius: 1rem;
}

/* Fallback cho iframe trực tiếp (không qua embed block) */
.post-prose-content > iframe,
.post-prose-content p > iframe,
.post-prose-content video,
.post-prose-content embed,
.post-prose-content object {
    width: 100% !important;
    height: auto !important;
    aspect-ratio: 16 / 9;
    border-radius: 1rem;
    margin: 1.5rem 0;
    display: block;
}

.post-prose-content img {
    max-width: 100%;
    height: auto;
    border-radius: 1rem;
    margin: 2rem 0 0;
}

.post-prose-content blockquote {
    border-left: 4px solid var(--primary);
    background: rgba(var(--primary-rgb), 0.05);
    padding: 2rem;
    border-radius: 0 1rem 1rem 0;
    font-style: italic;
    margin: 2rem 0;
}

/* Post Navigation */
.post-navigation-links {
    margin-top: 5rem;
    padding-top: 3rem;
    border-top: 1px solid rgba(0, 0, 0, 0.1);
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 2rem;
}

.nav-link-item a {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.nav-link-item small {
    font-size: 0.75rem;
    font-weight: 700;
    text-transform: uppercase;
    color: var(--primary);
}

.nav-link-item strong {
    font-size: 1.125rem;
    color: var(--c-text);
    transition: color 0.3s;
}

.nav-link-item a:hover strong {
    color: var(--primary);
}

.nav-link-item.next {
    text-align: right;
}

/* Sidebar Recent Posts */
.recent-posts-list {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.recent-post-item {
    display: flex;
    gap: 1rem;
    align-items: center;
}

.recent-post-thumb {
    width: 80px;
    height: 60px;
    flex-shrink: 0;
    border-radius: 0.5rem;
    overflow: hidden;
}

.recent-post-thumb img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s;
}

.recent-post-item:hover img {
    transform: scale(1.1);
}

.recent-post-title {
    font-size: 0.9375rem;
    font-weight: 700;
    line-height: 1.4;
    color: var(--c-text);
}

.recent-post-title a:hover {
    color: var(--primary);
}

.post-sidebar {
    width: 100%;
}

@media (min-width: 1024px) {
    .post-sidebar {
        width: 320px;
        flex-shrink: 0;
    }
}

.post-sidebar-sticky {
    position: sticky;
    top: calc(var(--header-height) + 2rem);
}


/* 
   TRUTH TABLE FOR TYPOGRAPHY 
   Standardizing h1 and h2 across all pages 
*/

h1,
.hero-title,
.section-title-main {
    color: var(--c-text);
    margin-bottom: 1.25rem;
}

.page-title {
    color: var(--c-text);
    margin-bottom: 1.25rem;
    font-size: 1.5rem;
    font-weight: 800;
    line-height: 1.3;
}



@media (min-width: 1024px) {

    h1,
    .hero-title,
    .section-title-main {
        font-size: 2.5rem;
        /* Desktop */
    }

    .page-title {
        font-size: 2rem;
    }
}

h2.section-title,
.h2-title,
h2 {
    font-size: 1.75rem;
    /* Mobile */
    font-weight: 700;
    line-height: 1.2;
    letter-spacing: -0.01em;
    text-transform: uppercase;
    color: var(--c-text);
    margin-bottom: 1rem;
}

@media (min-width: 1024px) {

    h2.section-title,
    .h2-title,
    h2 {
        font-size: 2.25rem;
        /* Desktop */
    }
}

/* Common Highlights */
.highlight-text {
    color: var(--primary);
}

/* List Styles for Post Content */
.single-post-wrapper .post-prose-content ul {
    list-style-type: disc;
    margin: 1.25rem 0;
    padding-left: 2rem;
}

.single-post-wrapper .post-prose-content ol {
    list-style-type: decimal;
    margin: 1.25rem 0;
    padding-left: 2rem;
}

.single-post-wrapper .post-prose-content li {
    margin: 0.5rem 0;
    line-height: 1.8;
}

.single-post-wrapper .post-prose-content p {
    margin-bottom: 1.25rem;
    line-height: 1.8;
}

/* ── Figure & Figcaption ───────────────────────────────── */
.single-post-wrapper .post-prose-content figure {
    margin: 2rem 0;
}

.single-post-wrapper .post-prose-content figcaption,
.single-post-wrapper .post-prose-content .wp-element-caption,
.single-post-wrapper .post-prose-content .wp-caption-text {
    margin-top: .5rem;
    font-size: .825rem;
    font-style: italic;
    color: #6b7280;
    text-align: center;
    line-height: 1.55;
    padding: 0 .5rem;
}
/* Standard Dropdown Support — Desktop Only */
.nav-list li {
    position: relative; /* All menu items are anchors for their sub-menus */
}

@media (min-width: 1025px) {
    /* Items that have Mega Menu MUST be static to allow full-width dropdown */
    .nav-list li:has(.mega-menu-container),
    .nav-list li.nav-item-wrapper {
        position: static !important;
    }

    /* Desktop dropdown: absolute, hidden by default, shown on hover */
    .nav-list .sub-menu {
        position: absolute;
        top: 100%;
        left: 0;
        background: #ffffff;
        min-width: 240px;
        box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
        opacity: 0;
        visibility: hidden;
        transform: translateY(15px);
        transition: all 0.3s cubic-bezier(0.165, 0.84, 0.44, 1);
        z-index: 1000;
        padding: 0.75rem 0;
        border-top: 3px solid var(--primary);
        display: flex;
        flex-direction: column;
        margin: 0;
    }

    .nav-list li:hover > .sub-menu {
        opacity: 1;
        visibility: visible;
        transform: translateY(0);
    }
}

.sub-menu li {
    width: 100% !important;
    position: relative;
}

.sub-menu li a {
    padding: 0.75rem 1.5rem !important;
    display: block !important;
    font-size: 0.85rem !important;
    color: var(--c-text) !important;
    text-transform: uppercase !important;
    letter-spacing: 0.05em !important;
    font-weight: 700 !important;
    transition: all 0.2s ease !important;
    white-space: nowrap;
    border: none !important;
}

.sub-menu li a::after {
    display: none !important;
}

.sub-menu li a:hover {
    background: rgba(215, 12, 25, 0.05) !important;
    color: var(--primary) !important;
    padding-left: 1.75rem !important;
}

/* Enhanced Table Styles for Post Content */
.single-post-wrapper .post-prose-content table,
.single-post-wrapper .post-prose-content .wp-block-table table {
    width: 100% !important; /* Keep this for layout integrity */
    border-collapse: collapse;
    margin: 1.5rem 0;
    font-size: 0.95rem;
    background: #ffffff;
    border-radius: 8px;
    overflow: hidden;
    border: 1px solid #cbd5e1;
}

.single-post-wrapper .post-prose-content table th, 
.single-post-wrapper .post-prose-content table td,
.single-post-wrapper .post-prose-content .wp-block-table th,
.single-post-wrapper .post-prose-content .wp-block-table td {
    padding: 12px 16px;
    text-align: left;
    border: 1px solid #cbd5e1;
    line-height: 1.5;
}

.single-post-wrapper .post-prose-content table th,
.single-post-wrapper .post-prose-content .wp-block-table th {
    background-color: #f8fafc;
    font-weight: 800;
    color: var(--c-text);
    text-transform: uppercase;
    font-size: 0.85rem;
    letter-spacing: 0.05em;
    border-bottom: 2px solid #cbd5e1;
}

.single-post-wrapper .post-prose-content table tr:nth-child(even),
.single-post-wrapper .post-prose-content .wp-block-table tr:nth-child(even) {
    background-color: #f9fafb;
}

.single-post-wrapper .post-prose-content table tr:hover,
.single-post-wrapper .post-prose-content .wp-block-table tr:hover {
    background-color: rgba(var(--primary-rgb), 0.02);
}

/* Responsive Table Wrapper */
@media (max-width: 768px) {
    .single-post-wrapper .post-prose-content table,
    .single-post-wrapper .post-prose-content .wp-block-table {
        display: block;
        overflow-x: auto;
        white-space: nowrap;
        -webkit-overflow-scrolling: touch;
    }
}

/* Bài tin tức khuyến mãi: banner trái + bảng ưu đãi phải (T7/2026).
   Bảng-wrapper .km-2col chỉ để layout → reset border/nền; bảng ưu đãi
   lồng bên trong vẫn giữ style mặc định của .post-prose-content table. */
.single-post-wrapper .post-prose-content table.km-2col,
.single-post-wrapper .post-prose-content table.km-2col > tbody > tr > td {
    border: none !important;
    background: transparent !important;
    border-radius: 0 !important;
}

.single-post-wrapper .post-prose-content table.km-2col {
    table-layout: fixed;
    margin: 1.5rem 0;
    white-space: normal;
}

.single-post-wrapper .post-prose-content table.km-2col > tbody > tr > td {
    padding: 0 1rem !important;
    vertical-align: top;
}

.single-post-wrapper .post-prose-content table.km-2col > tbody > tr > td.km-2col__banner {
    width: 42%;
    vertical-align: middle;
}

.single-post-wrapper .post-prose-content table.km-2col img {
    margin: 0;
    width: 100%;
    border-radius: 12px;
}

.single-post-wrapper .post-prose-content table.km-2col td > table {
    margin: 0 !important;
}

@media (max-width: 768px) {
    .single-post-wrapper .post-prose-content table.km-2col,
    .single-post-wrapper .post-prose-content table.km-2col > tbody,
    .single-post-wrapper .post-prose-content table.km-2col > tbody > tr,
    .single-post-wrapper .post-prose-content table.km-2col > tbody > tr > td {
        display: block;
        width: 100% !important;
        padding: 0 !important;
        overflow: visible;
        white-space: normal;
    }

    .single-post-wrapper .post-prose-content table.km-2col > tbody > tr > td.km-2col__banner {
        margin-bottom: 1rem;
    }
}

/* Bài tin tức — gallery ảnh lớn (grid 2 cột, tile đều) thay vì thumbnail bé */
.single-post-wrapper .post-prose-content .gallery {
    display: grid !important;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
    margin: 1.5rem 0 0;
}
/* Tôn trọng số cột từ shortcode [gallery columns="N"] */
.single-post-wrapper .post-prose-content .gallery.gallery-columns-3 { grid-template-columns: repeat(3, 1fr); }
.single-post-wrapper .post-prose-content .gallery.gallery-columns-4 { grid-template-columns: repeat(4, 1fr); }
.single-post-wrapper .post-prose-content .gallery br { display: none; }
.single-post-wrapper .post-prose-content .gallery-item {
    width: 100% !important;
    margin: 0 !important;
    float: none !important;
    padding: 0 !important;
}
.single-post-wrapper .post-prose-content .gallery-item img {
    width: 100%;
    aspect-ratio: 4 / 3;
    object-fit: cover;
    border: none !important;
    border-radius: 12px;
    margin: 0 !important;
    display: block;
}
.single-post-wrapper .post-prose-content .gallery-icon { margin: 0 !important; }
@media (max-width: 600px) {
    .single-post-wrapper .post-prose-content .gallery {
        grid-template-columns: 1fr;
    }
}
