/*
Theme Name:   Platform Child
Theme URI:    https://yoursite.com/
Description:  Child theme for Platform with WooCommerce integration
Author:       Your Name
Author URI:   https://yoursite.com/
Template:     platform
Version:      1.0.0
License:      GNU General Public License v2 or later
License URI:  http://www.gnu.org/licenses/gpl-2.0.html
Text Domain:  platform-child
*/

/* ==========================================================================
   Base Styles
   ========================================================================== */

:root {
    --primary-color: #3498db;
    --secondary-color: #2ecc71;
    --text-color: #333;
    --border-color: #e0e0e0;
    --hover-color: #2980b9;
    --success-color: #27ae60;
    --danger-color: #e74c3c;
}

body {
    font-family: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    color: var(--text-color);
    line-height: 1.6;
}

/* ==========================================================================
   Container & Layout
   ========================================================================== */

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

.row {
    display: flex;
    flex-wrap: wrap;
    margin: 0 -15px;
}

.col {
    padding: 0 15px;
}

/* ==========================================================================
   Header Custom
   ========================================================================== */

.site-header {
    background: #fff;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-top {
    background: #f8f9fa;
    padding: 10px 0;
    font-size: 14px;
}

.header-main {
    padding: 20px 0;
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.site-logo img {
    max-height: 50px;
    width: auto;
}

/* Navigation */
.main-navigation ul {
    display: flex;
    list-style: none;
    margin: 0;
    padding: 0;
    gap: 30px;
}

.main-navigation a {
    color: var(--text-color);
    text-decoration: none;
    font-weight: 500;
    transition: color 0.3s;
}

.main-navigation a:hover {
    color: var(--primary-color);
}

/* ==========================================================================
   DROPDOWN SUBMENU - Danh Mục Sản Phẩm
   ========================================================================== */

/* Submenu Container */
.main-navigation ul ul {
    position: absolute;
    top: 100%;
    left: 0;
    min-width: 220px;
    list-style: none;
    margin: 8px 0 0 0;
    padding: 8px 0;
    background: #fff;
    border-radius: 8px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.12);
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    z-index: 999;
    display: block !important;
    /* Override WP default */
}

/* Hiển thị Submenu khi Hover */
.main-navigation ul li:hover>ul {
    opacity: 1;
    visibility: visible;
    transform: translateY(0);
}

/* Menu Item có Submenu */
.main-navigation ul li {
    position: relative;
}

/* Submenu Item */
.main-navigation ul ul li {
    margin: 0;
    border-bottom: 1px solid #f0f0f0;
}

.main-navigation ul ul li:last-child {
    border-bottom: none;
}

.main-navigation ul ul a {
    display: block;
    padding: 12px 20px;
    color: #555;
    font-size: 14px;
    font-weight: 400;
    transition: all 0.2s ease;
}

.main-navigation ul ul a:hover {
    background: #f8f9fa;
    color: var(--primary-color);
    padding-left: 25px;
}

/* Icon Dropdown Arrow */
.main-navigation ul li.menu-item-has-children>a::after {
    content: "▼";
    margin-left: 5px;
    font-size: 10px;
    opacity: 0.7;
    transition: transform 0.3s;
}

.main-navigation ul li.menu-item-has-children:hover>a::after {
    transform: rotate(180deg);
}

/* Sub-submenu (Level 3) */
.main-navigation ul ul ul {
    top: 0;
    left: 100%;
    margin: 0 0 0 8px;
}

/* ==========================================================================
   MOBILE MENU - RESPONSIVE
   ========================================================================== */

/* Mobile Toggle Button */
.menu-toggle {
    display: none;
    background: var(--primary-color);
    color: #fff;
    border: none;
    padding: 10px 15px;
    border-radius: 6px;
    cursor: pointer;
    font-size: 18px;
    font-weight: 600;
}

.menu-toggle:hover {
    background: var(--hover-color);
}

/* Hamburger Icon */
.menu-toggle::before {
    content: "☰";
    margin-right: 5px;
}

.menu-toggle.toggled::before {
    content: "✕";
}

@media (max-width: 768px) {

    /* Hiện nút toggle */
    .menu-toggle {
        display: block;
    }

    /* Ẩn menu desktop */
    .main-navigation {
        position: fixed;
        top: 90px;
        /* Điều chỉnh theo chiều cao header */
        left: -100%;
        width: 280px;
        height: calc(100vh - 90px);
        background: #fff;
        box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
        transition: left 0.3s ease;
        overflow-y: auto;
        z-index: 998;
        padding: 20px 0;
    }

    /* Menu mở */
    .main-navigation.toggled {
        left: 0;
    }

    /* Overlay khi menu mở */
    .main-navigation.toggled::before {
        content: '';
        position: fixed;
        top: 90px;
        left: 280px;
        width: calc(100vw - 280px);
        height: calc(100vh - 90px);
        background: rgba(0, 0, 0, 0.5);
        z-index: -1;
    }

    /* Menu dọc mobile */
    .main-navigation ul {
        flex-direction: column;
        gap: 0;
    }

    .main-navigation ul li {
        border-bottom: 1px solid #f0f0f0;
    }

    .main-navigation ul li a {
        padding: 15px 20px;
        display: block;
    }

    /* Submenu mobile */
    .main-navigation ul ul {
        position: static;
        opacity: 1;
        visibility: visible;
        transform: none;
        box-shadow: none;
        background: #f8f9fa;
        margin: 0;
        padding: 0;
        max-height: 0;
        overflow: hidden;
        transition: max-height 0.3s ease;
    }

    /* Hiển thị submenu khi có class 'open' */
    .main-navigation ul li.menu-item-has-children.open>ul {
        max-height: 500px;
        /* Đủ lớn để chứa các item */
    }

    /* Icon dropdown mobile */
    .main-navigation ul li.menu-item-has-children>a::after {
        float: right;
        transform: rotate(0deg);
    }

    .main-navigation ul li.menu-item-has-children.open>a::after {
        transform: rotate(180deg);
    }

    /* Submenu level 3 mobile */
    .main-navigation ul ul ul {
        position: static;
        left: auto;
        margin: 0;
        background: #e9ecef;
    }
}

/* Mobile - Điều chỉnh header */
@media (max-width: 768px) {
    .site-header .container {
        justify-content: space-between;
    }

    .header-main {
        position: relative;
    }
}

/* ==========================================================================
   WooCommerce Overrides
   ========================================================================== */

/* Shop Archive */
.woocommerce-breadcrumb {
    padding: 15px 0;
    font-size: 14px;
    color: #666;
}

.woocommerce .woocommerce-result-count {
    margin: 0;
    color: #666;
}

.woocommerce .woocommerce-ordering {
    margin: 0;
}

/* Product Grid */
.woocommerce ul.products {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(250px, 1fr));
    gap: 30px;
    margin: 30px 0;
}

.woocommerce ul.products li.product {
    background: #fff;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    overflow: hidden;
    transition: all 0.3s ease;
    position: relative;
}

.woocommerce ul.products li.product:hover {
    transform: translateY(-8px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.15);
    border-color: var(--primary-color);
}

/* Product Image */
.woocommerce ul.products li.product img {
    width: 100%;
    height: 280px;
    object-fit: cover;
    transition: transform 0.3s;
}

.woocommerce ul.products li.product:hover img {
    transform: scale(1.05);
}

/* Sale Badge */
.woocommerce span.onsale {
    background: var(--danger-color);
    color: white;
    padding: 5px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: bold;
    position: absolute;
    top: 15px;
    left: 15px;
    z-index: 10;
}

/* Product Info */
.woocommerce ul.products li.product .woocommerce-loop-product__title {
    font-size: 16px;
    font-weight: 600;
    margin: 15px;
    color: var(--text-color);
    height: 48px;
    overflow: hidden;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
}

/* Product Price */
.woocommerce ul.products li.product .price {
    font-size: 20px;
    font-weight: bold;
    color: var(--secondary-color);
    margin: 0 15px 15px;
    display: block;
}

.woocommerce ul.products li.product .price del {
    color: #999;
    font-size: 16px;
    margin-right: 8px;
}

.woocommerce ul.products li.product .price ins {
    text-decoration: none;
}

/* Add to Cart Button */
.woocommerce ul.products li.product .button {
    background: var(--primary-color);
    color: white;
    width: calc(100% - 30px);
    margin: 0 15px 15px;
    padding: 12px;
    border-radius: 8px;
    text-align: center;
    font-weight: 600;
    transition: all 0.3s;
    border: none;
}

.woocommerce ul.products li.product .button:hover {
    background: var(--hover-color);
    transform: scale(1.02);
}

.woocommerce ul.products li.product .button.added {
    background: var(--success-color);
}

/* Quick View Button */
.product-quick-view {
    position: absolute;
    top: 15px;
    right: 15px;
    background: white;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    opacity: 0;
    transition: all 0.3s;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
    cursor: pointer;
}

.woocommerce ul.products li.product:hover .product-quick-view {
    opacity: 1;
}

/* ==========================================================================
   Single Product Page
   ========================================================================== */

.woocommerce div.product {
    margin-top: 30px;
}

.woocommerce div.product div.images {
    width: 48%;
    float: left;
}

.woocommerce div.product div.summary {
    width: 48%;
    float: right;
    padding: 30px;
    background: #f8f9fa;
    border-radius: 12px;
}

.woocommerce div.product .product_title {
    font-size: 32px;
    font-weight: 700;
    margin-bottom: 15px;
    color: var(--text-color);
}

.woocommerce div.product p.price {
    font-size: 28px;
    color: var(--secondary-color);
    font-weight: bold;
    margin-bottom: 20px;
}

.woocommerce div.product .woocommerce-product-rating {
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 10px;
}

.woocommerce div.product .product_meta {
    padding-top: 20px;
    border-top: 1px solid var(--border-color);
    margin-top: 20px;
    font-size: 14px;
}

/* Add to Cart Form */
.woocommerce div.product form.cart {
    margin: 25px 0;
}

.woocommerce div.product form.cart .quantity {
    display: inline-block;
    margin-right: 10px;
}

.woocommerce div.product form.cart input.qty {
    width: 70px;
    padding: 12px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    text-align: center;
    font-size: 16px;
}

.woocommerce div.product form.cart .single_add_to_cart_button {
    background: var(--primary-color);
    color: white;
    padding: 15px 40px;
    border-radius: 8px;
    font-weight: 600;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
    font-size: 16px;
}

.woocommerce div.product form.cart .single_add_to_cart_button:hover {
    background: var(--hover-color);
    transform: translateY(-2px);
    box-shadow: 0 4px 12px rgba(52, 152, 219, 0.3);
}

/* Product Tabs */
.woocommerce div.product .woocommerce-tabs {
    clear: both;
    margin-top: 50px;
}

.woocommerce div.product .woocommerce-tabs ul.tabs {
    display: flex;
    border-bottom: 2px solid var(--border-color);
    margin: 0;
    padding: 0;
    list-style: none;
}

.woocommerce div.product .woocommerce-tabs ul.tabs li {
    margin: 0;
    padding: 15px 30px;
    cursor: pointer;
    border-bottom: 3px solid transparent;
    transition: all 0.3s;
}

.woocommerce div.product .woocommerce-tabs ul.tabs li.active {
    border-bottom-color: var(--primary-color);
    color: var(--primary-color);
}

.woocommerce div.product .woocommerce-tabs .panel {
    padding: 30px 0;
}

/* ==========================================================================
   Cart Page
   ========================================================================== */

.woocommerce-cart table.cart {
    border: 1px solid var(--border-color);
    border-radius: 8px;
}

.woocommerce-cart table.cart th {
    background: #f8f9fa;
    padding: 15px;
    font-weight: 600;
}

.woocommerce-cart table.cart td {
    padding: 20px;
    vertical-align: middle;
}

.woocommerce-cart table.cart img {
    width: 80px;
    height: 80px;
    object-fit: cover;
    border-radius: 8px;
}

.woocommerce-cart .cart-collaterals {
    margin-top: 30px;
}

.woocommerce-cart .cart-collaterals .cart_totals {
    background: #f8f9fa;
    padding: 30px;
    border-radius: 12px;
}

.woocommerce-cart .cart-collaterals .cart_totals h2 {
    font-size: 24px;
    margin-bottom: 20px;
}

.woocommerce-cart .wc-proceed-to-checkout .checkout-button {
    background: var(--secondary-color);
    color: white;
    width: 100%;
    padding: 15px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 16px;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
}

.woocommerce-cart .wc-proceed-to-checkout .checkout-button:hover {
    background: var(--success-color);
    transform: translateY(-2px);
}

/* ==========================================================================
   Checkout Page
   ========================================================================== */

.woocommerce-checkout .woocommerce-billing-fields h3 {
    font-size: 24px;
    margin-bottom: 20px;
    color: var(--text-color);
}

.woocommerce-checkout .form-row {
    margin-bottom: 20px;
}

.woocommerce-checkout .form-row label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
}

.woocommerce-checkout .form-row input.input-text,
.woocommerce-checkout .form-row textarea,
.woocommerce-checkout .form-row select {
    width: 100%;
    padding: 12px;
    border: 2px solid var(--border-color);
    border-radius: 8px;
    font-size: 14px;
    transition: border-color 0.3s;
}

.woocommerce-checkout .form-row input.input-text:focus,
.woocommerce-checkout .form-row textarea:focus,
.woocommerce-checkout .form-row select:focus {
    border-color: var(--primary-color);
    outline: none;
}

#order_review_heading {
    font-size: 24px;
    margin-top: 40px;
    margin-bottom: 20px;
}

.woocommerce-checkout #order_review {
    background: #f8f9fa;
    padding: 30px;
    border-radius: 12px;
}

.woocommerce-checkout #place_order {
    background: var(--secondary-color);
    color: white;
    width: 100%;
    padding: 15px;
    border-radius: 8px;
    font-weight: 600;
    font-size: 16px;
    border: none;
    cursor: pointer;
    transition: all 0.3s;
}

.woocommerce-checkout #place_order:hover {
    background: var(--success-color);
    transform: translateY(-2px);
}

/* ==========================================================================
   Widgets
   ========================================================================== */

.widget {
    background: #f8f9fa;
    padding: 25px;
    border-radius: 12px;
    margin-bottom: 30px;
}

.widget .widget-title {
    font-size: 20px;
    font-weight: 600;
    margin-bottom: 20px;
    padding-bottom: 15px;
    border-bottom: 2px solid var(--border-color);
}

.widget ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.widget ul li {
    padding: 10px 0;
    border-bottom: 1px solid var(--border-color);
}

.widget ul li:last-child {
    border-bottom: none;
}

.widget ul li a {
    color: var(--text-color);
    text-decoration: none;
    transition: color 0.3s;
}

.widget ul li a:hover {
    color: var(--primary-color);
}

/* ==========================================================================
   Footer
   ========================================================================== */

.site-footer {
    background: #2c3e50;
    color: white;
    padding: 60px 0 20px;
    margin-top: 80px;
}

.footer-widgets {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-widget h3 {
    font-size: 18px;
    margin-bottom: 20px;
}

.footer-widget ul {
    list-style: none;
    padding: 0;
}

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

.footer-widget ul li a {
    color: #bdc3c7;
    text-decoration: none;
    transition: color 0.3s;
}

.footer-widget ul li a:hover {
    color: white;
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 30px;
    text-align: center;
    color: #bdc3c7;
}

/* ==========================================================================
   Responsive Design
   ========================================================================== */

@media (max-width: 992px) {
    .woocommerce ul.products {
        grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
        gap: 20px;
    }

    .woocommerce div.product div.images,
    .woocommerce div.product div.summary {
        width: 100%;
        float: none;
    }

    .woocommerce div.product div.summary {
        margin-top: 30px;
    }
}

@media (max-width: 768px) {
    .main-navigation ul {
        flex-direction: column;
        gap: 15px;
    }

    .woocommerce ul.products {
        grid-template-columns: repeat(auto-fill, minmax(150px, 1fr));
        gap: 15px;
    }

    .woocommerce ul.products li.product img {
        height: 200px;
    }

    .footer-widgets {
        grid-template-columns: 1fr;
        gap: 30px;
    }
}

@media (max-width: 576px) {
    .woocommerce ul.products {
        grid-template-columns: 1fr 1fr;
    }

    .woocommerce ul.products li.product .woocommerce-loop-product__title {
        font-size: 14px;
    }

    .woocommerce ul.products li.product .price {
        font-size: 16px;
    }
}

/* ==========================================================================
   Utilities
   ========================================================================== */

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

.mt-20 {
    margin-top: 20px;
}

.mb-20 {
    margin-bottom: 20px;
}

.pt-40 {
    padding-top: 40px;
}

.pb-40 {
    padding-bottom: 40px;
}

/* Loading Animation */
.loading {
    position: relative;
    pointer-events: none;
    opacity: 0.6;
}

.loading::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 20px;
    height: 20px;
    margin: -10px 0 0 -10px;
    border: 2px solid var(--primary-color);
    border-radius: 50%;
    border-top-color: transparent;
    animation: spin 0.6s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* ========================================
   FORCE REMOVE FOOTER SPACING
   ======================================== */

/* Target all possible footer wrappers */
footer,
.site-footer,
#site-footer,
.boxes-footer {
    margin-bottom: 0 !important;
    padding-bottom: 0;
}

/* Footer bottom bar */
.footer-bottom {
    margin: 0 !important;
}

/* Remove spacing after footer */
footer::after,
.site-footer::after,
#site-footer::after {
    display: none !important;
    content: none !important;
    height: 0 !important;
    margin: 0 !important;
    padding: 0 !important;
}

/* Main wrapper */
#page,
.site,
.wrapper {
    margin-bottom: 0 !important;
    padding-bottom: 0 !important;
}

/* Content area */
#content,
.site-content,
main {
    margin-bottom: 0 !important;
}

/* Remove WordPress default spacing */
body {
    padding-bottom: 0 !important;
}

/* Ensure body ends at footer */
body>*:last-child {
    margin-bottom: 0 !important;
}


/*!
 * FIX: Remove Red Border When Click/Focus
 * Loại bỏ viền đỏ khi nhấp vào card
 */

/* ============================================
   REMOVE OUTLINE/BORDER ON CLICK
============================================= */

/* Xóa outline/border khi click vào BẤT KỲ element nào */
*:focus,
*:focus-visible,
*:active,
*:focus-within {
    outline: none !important;
    border: none !important;
    box-shadow: none !important;
}

/* Xóa tap highlight trên mobile */
* {
    -webkit-tap-highlight-color: transparent !important;
    -webkit-touch-callout: none !important;
    -webkit-user-select: none !important;
}

/* Chỉ thêm spacing và border, còn lại kế thừa theme */
.related-post-section {
    margin-top: 50px;
    padding-top: 50px;
    border-top: 2px solid #e0e0e0;
}

@media (max-width: 768px) {
    .related-post-section {
        margin-top: 30px;
        padding-top: 30px;
    }
}

.related-post-category {
    margin-top: 40px;
    padding: 25px;
    background: #ffffff;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.08);
}

.related-post-category .post-wrapper {
    display: flex;
    gap: 20px;
    align-items: flex-start;
}

.related-post-category .post-image {
    flex: 0 0 200px;
}

.related-post-category .post-image img {
    width: 100%;
    height: auto;
    border-radius: 5px;
    display: block;
}

.related-post-category .post-content {
    flex: 1;
}

.related-post-category h3 {
    font-size: 18px;
    font-weight: 600;
    color: #333;
    margin: 0 0 10px 0;
    line-height: 1.4;
}

.related-post-category .post-excerpt {
    color: #666;
    line-height: 1.6;
    margin-bottom: 15px;
    font-size: 14px;
}

.related-post-category .read-more {
    display: inline-block;
    color: #0073aa;
    text-decoration: none;
    font-weight: 600;
    transition: color 0.3s ease;
}

.related-post-category .read-more:hover {
    color: #005a87;
}

/* Responsive */
@media (max-width: 768px) {
    .related-post-category .post-wrapper {
        flex-direction: column;
    }

    .related-post-category .post-image {
        flex: 0 0 auto;
    }
}

/*================================== THÊM - KHÔNG CÓ BÓNG MÀU ========================================= */
/* ==================== FLOATING BUTTONS - PHẲNG, KHÔNG BÓNG MÀU ==================== */
.floating-buttons-group {
    position: fixed;
    bottom: 25px;
    right: 25px;
    z-index: 9998;
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 15px;
}

/* Badge Miễn Phí - Không bóng màu */
.floating-badge {
    background: linear-gradient(135deg, #ff3b9a 0%, #ff0080 100%);
    color: #fff;
    padding: 10px 20px;
    border-radius: 30px;
    font-size: 14px;
    font-weight: 800;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    animation: badge-float 2.5s ease-in-out infinite;
    letter-spacing: 0.5px;
}

.badge-icon {
    font-size: 18px;
    animation: gift-spin 4s linear infinite;
}

.badge-text {
    text-transform: uppercase;
}

@keyframes badge-float {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-8px);
    }
}

@keyframes gift-spin {

    0%,
    100% {
        transform: rotate(0deg);
    }

    25% {
        transform: rotate(-20deg);
    }

    75% {
        transform: rotate(20deg);
    }
}

/* ==================== NÚT TRÒN - KHÔNG BÓNG MÀU ==================== */
.float-btn {
    width: 60px;
    height: 60px;
    border: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    text-decoration: none;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
    position: relative;
    overflow: visible;
}

.float-btn:hover {
    transform: translateY(-3px) scale(1.05);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

/* SVG Icon */
.btn-icon-svg {
    width: 32px;
    height: 32px;
    color: #fff;
    transition: transform 0.3s ease;
}

.float-btn:hover .btn-icon-svg {
    transform: scale(1.1);
}

/* Tooltip */
.btn-tooltip {
    position: absolute;
    right: 75px;
    background: rgba(0, 0, 0, 0.9);
    color: #fff;
    padding: 8px 14px;
    border-radius: 6px;
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    pointer-events: none;
}

.btn-tooltip::after {
    content: '';
    position: absolute;
    top: 50%;
    right: -6px;
    transform: translateY(-50%);
    border: 6px solid transparent;
    border-left-color: rgba(0, 0, 0, 0.9);
}

.float-btn:hover .btn-tooltip {
    opacity: 1;
    visibility: visible;
    right: 70px;
}

/* ==================== NÚT TƯ VẤN - XANH DƯƠ̂NG PHẲNG ==================== */
.btn-consultation {
    background: linear-gradient(135deg, #4aa7dd 0%, #3d84ff 100%);
}

.btn-consultation:hover {
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.btn-consultation .btn-icon-svg {
    animation: chat-bounce 2s ease-in-out infinite;
}

@keyframes chat-bounce {

    0%,
    100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-3px);
    }
}

/* ==================== NÚT ZALO - XANH PHẲNG ==================== */
.btn-zalo {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    background: linear-gradient(135deg, #ffffff 0%, #ffffff 100%);
}

.btn-zalo:hover {
    box-shadow: 0 6px 16px rgb(255, 255, 255);
}

/* Chữ Zalo - Màu Xanh Dương */
.zalo-text {
    font-size: 13px;
    font-weight: 900;
    color: #007bff !important;
    /* Màu xanh dương */
    letter-spacing: -0.5px;
    text-transform: none;
    font-family: 'Arial Black', Arial, sans-serif;
    transition: all 0.3s ease;
    text-shadow: 0 1px 3px rgba(0, 0, 0, 0.2);
    line-height: 1;
}


.btn-zalo:hover .zalo-text {
    transform: scale(1.05);
    color: #000000 !important;
}

/* ==================== POPUP TƯ VẤN ==================== */
.consultation-popup {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: none;
    align-items: center;
    justify-content: center;
}

.consultation-popup.active {
    display: flex;
    animation: fadeIn 0.3s ease;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }

    to {
        opacity: 1;
    }
}

.popup-overlay {
    position: absolute;
    inset: 0;
    background: rgba(0, 0, 0, 0.8);
    backdrop-filter: blur(10px);
}

.popup-box {
    position: relative;
    width: 90%;
    max-width: 480px;
    max-height: 90vh;
    background: #fff;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.5);
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        transform: translateY(50px);
        opacity: 0;
    }

    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.popup-close {
    position: absolute;
    top: 15px;
    right: 15px;
    width: 36px;
    height: 36px;
    border: none;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.25);
    backdrop-filter: blur(10px);
    color: #fff;
    font-size: 28px;
    cursor: pointer;
    z-index: 10;
    transition: all 0.3s ease;
}

.popup-close:hover {
    background: rgba(255, 255, 255, 0.35);
    transform: rotate(90deg);
}

.popup-header {
    background: linear-gradient(135deg, #4aa7dd 0%, #3d84ff 100%);
    color: #fff;
    padding: 35px 24px 28px;
    text-align: center;
}

.header-icon-svg {
    width: 64px;
    height: 64px;
    color: #fff;
    margin: 0 auto 12px;
    display: block;
}

.popup-header h3 {
    font-size: 24px;
    font-weight: 700;
    margin: 0 0 8px;
}

.popup-header p {
    font-size: 14px;
    margin: 0;
    opacity: 0.95;
}

/* Form */
.popup-form {
    padding: 25px 24px;
    overflow-y: auto;
    max-height: calc(90vh - 160px);
}

.form-row {
    margin-bottom: 16px;
}

.form-row label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #333;
    margin-bottom: 6px;
}

.req {
    color: #e74c3c;
}

.form-row input,
.form-row select,
.form-row textarea {
    width: 100%;
    padding: 12px 14px;
    font-size: 14px;
    font-family: inherit;
    border: 2px solid #e0e0e0;
    border-radius: 8px;
    background: #fafafa;
    transition: all 0.2s ease;
    box-sizing: border-box;
}

.form-row input:focus,
.form-row select:focus,
.form-row textarea:focus {
    outline: none;
    border-color: #4aa7dd;
    background: #fff;
    box-shadow: 0 0 0 3px rgba(74, 167, 221, 0.1);
}

.form-row select {
    cursor: pointer;
    appearance: none;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12'%3E%3Cpath fill='%234aa7dd' d='M6 9L1 4h10z'/%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 14px center;
    padding-right: 40px;
}

.form-row textarea {
    resize: vertical;
    min-height: 80px;
}

/* Submit Button - Không bóng màu */
.btn-submit {
    width: 100%;
    padding: 15px;
    background: linear-gradient(135deg, #4aa7dd 0%, #3d84ff 100%);
    color: #fff;
    border: none;
    border-radius: 8px;
    font-size: 16px;
    font-weight: 700;
    cursor: pointer;
    transition: all 0.3s ease;
    margin-top: 10px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.btn-submit:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

.btn-submit:disabled {
    opacity: 0.7;
    cursor: not-allowed;
}

.btn-submit.loading .txt {
    display: none;
}

.btn-submit:not(.loading) .loading {
    display: none;
}

/* Messages */
.form-message .alert {
    padding: 12px 14px;
    border-radius: 8px;
    font-size: 14px;
    margin-top: 14px;
}

.alert.success {
    background: #d4edda;
    color: #155724;
    border: 2px solid #c3e6cb;
}

.alert.error {
    background: #f8d7da;
    color: #721c24;
    border: 2px solid #f5c6cb;
}

/* ==================== RESPONSIVE ==================== */
@media (max-width: 768px) {
    .floating-buttons-group {
        bottom: 20px;
        right: 20px;
        gap: 12px;
    }

    .floating-badge {
        padding: 8px 16px;
        font-size: 13px;
    }

    .badge-icon {
        font-size: 16px;
    }

    .float-btn {
        width: 55px;
        height: 55px;
    }

    .btn-icon-svg {
        width: 28px;
        height: 28px;
    }

    .zalo-text {
        font-size: 12px;
        letter-spacing: -0.8px;
    }

    .btn-zalo {
        width: 55px;
        height: 55px;
    }

    .btn-tooltip {
        font-size: 13px;
        padding: 6px 12px;
    }

    .popup-box {
        width: 95%;
    }
}

/* Scrollbar */
.popup-form::-webkit-scrollbar {
    width: 5px;
}

.popup-form::-webkit-scrollbar-thumb {
    background: linear-gradient(135deg, #4aa7dd 0%, #4aa7dd 100%);
    border-radius: 3px;
}

/* ============================================
   Khắc phục H1UserAgentFontSizeInSection
   ============================================ */

/* Reset font-size cho tất cả H1 */
h1 {
    font-size: 2em !important;
    margin: 0.67em 0 !important;
    line-height: 1.2 !important;
}

/* H1 trong các thẻ semantic HTML5 */
section h1,
article h1,
aside h1,
nav h1,
main h1 {
    font-size: 2em !important;
    margin: 0.67em 0 !important;
}

/* H1 trong nested sections */
section section h1,
article article h1 {
    font-size: 1.5em !important;
}

/* Responsive cho mobile */
@media (max-width: 768px) {
    h1 {
        font-size: 1.75em !important;
    }
}
