/* ============================================================
 * THÉP THIÊN HƯNG - Main Stylesheet (Modern Industrial UI)
 * Compatible with PHP 5.6.40+ & Bootstrap 5
 * ============================================================ */

:root {
    --primary-red: #D32F2F;
    --dark-red: #B71C1C;
    --industrial-black: #111111;
    --dark-industrial: #1A1A1A;
    --light-industrial: #F8F9FA;
    --border-gray: #E0E0E0;
    --steel-gray: #607D8B;
    --gold-accent: #FFB300;
}

body {
    font-family: 'Roboto', -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    color: #333333;
    background-color: #F8F9FA;
    font-size: 15px;
    line-height: 1.6;
}

/* Custom Typography & Utility Classes */
.fw-black { font-weight: 900 !important; }
.fw-extrabold { font-weight: 800 !important; }

.btn-danger-custom {
    background-color: var(--primary-red);
    color: #FFFFFF;
    border: none;
    transition: all 0.3s ease;
}

.btn-danger-custom:hover {
    background-color: var(--dark-red);
    color: #FFFFFF;
    box-shadow: 0 4px 15px rgba(211, 47, 47, 0.4);
}

.bg-industrial-black {
    background-color: var(--industrial-black) !important;
}

.bg-dark-industrial {
    background-color: var(--dark-industrial) !important;
}

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

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

/* Topbar Header */
.topbar-header {
    font-size: 13px;
    letter-spacing: 0.3px;
}

/* Main Logo Header */
.main-header {
    box-shadow: 0 2px 12px rgba(0,0,0,0.08);
}

.logo-icon-box {
    box-shadow: 0 4px 10px rgba(211, 47, 47, 0.25);
}

.brand-text-main {
    font-family: 'Montserrat', sans-serif;
    letter-spacing: -0.5px;
}

/* Header Search Form */
.search-input-custom {
    border: 2px solid #E5E5E5;
    padding-left: 20px;
    font-size: 14px;
    height: 44px;
    transition: all 0.3s ease;
}

.search-input-custom:focus {
    border-color: var(--primary-red);
    box-shadow: 0 0 0 0.25rem rgba(211, 47, 47, 0.15);
}

.btn-search-custom {
    background-color: var(--primary-red);
    color: #FFFFFF;
    width: 36px;
    height: 36px;
    display: flex;
    align-items: center;
    justify-content: center;
    border: none;
    margin-right: 4px;
    transition: all 0.2s ease;
}

.btn-search-custom:hover {
    background-color: var(--dark-red);
    color: #FFFFFF;
}

/* Main Navigation Bar */
.navbar-dark .navbar-nav .nav-link {
    color: #FFFFFF !important;
    font-size: 14px;
    font-weight: 700;
    letter-spacing: 0.5px;
    padding: 14px 18px !important;
    transition: all 0.2s ease;
}

.navbar-dark .navbar-nav .nav-link:hover,
.navbar-dark .navbar-nav .nav-link.active {
    background-color: var(--primary-red);
    color: #FFFFFF !important;
}

/* Mega Dropdown Menu - Full Width & Wide 4 Columns */
.navbar .dropdown-toggle::after {
    display: none !important;
}

.dropdown-mega {
    position: relative !important;
}

.dropdown-mega .mega-menu {
    position: absolute !important;
    top: 100% !important;
    left: -180px !important;
    width: 920px !important;
    max-width: 920px !important;
    border: none !important;
    border-top: 4px solid var(--primary-red) !important;
    box-shadow: 0 15px 35px rgba(0,0,0,0.2) !important;
    background: #FFFFFF !important;
    padding: 25px 30px !important;
    border-radius: 0 0 10px 10px !important;
    z-index: 1050 !important;
}

.mega-menu-item {
    font-size: 13px;
    font-weight: 700;
    padding: 10px 14px;
    display: block;
    color: #2D3748;
    text-decoration: none;
    transition: all 0.2s ease;
    border-bottom: 1px dashed #EDF2F7;
    white-space: nowrap;
    border-radius: 5px;
}

.mega-menu-item:hover {
    background-color: #FFF0F0;
    color: var(--primary-red) !important;
    padding-left: 20px;
}

/* Hero Carousel */
.hero-slide-item {
    min-height: 520px;
    height: auto;
    background-size: cover;
    background-position: center;
    position: relative;
}

.hero-slide-default {
    background: url('../images/bg_top.jpg') no-repeat center center;
    background-size: cover;
}

.hero-overlay {
    background: linear-gradient(90deg, rgba(15,23,42,0.82) 0%, rgba(15,23,42,0.55) 60%, rgba(15,23,42,0.25) 100%);
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.bg-dark-glass {
    background: rgba(15, 23, 42, 0.65) !important;
    backdrop-filter: blur(8px);
}

.hero-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 34px;
    line-height: 1.25;
    letter-spacing: -0.5px;
}

.hero-showcase-img {
    height: 340px;
    transition: transform 0.5s ease;
}

.hero-image-card:hover .hero-showcase-img {
    transform: scale(1.03);
}

.hero-glass-floating {
    backdrop-filter: blur(12px);
    background: rgba(15, 23, 42, 0.88) !important;
    z-index: 5;
}

@media (max-width: 991.98px) {
    .hero-slide-item { min-height: 440px; }
    .hero-title { font-size: 26px; }
}

/* Quick Stats Counter Bar */
.counter-bar {
    background-color: var(--industrial-black);
    border-top: 3px solid var(--primary-red);
    box-shadow: inset 0 2px 8px rgba(0,0,0,0.3);
}

.counter-number {
    font-family: 'Montserrat', sans-serif;
    font-size: 34px;
    font-weight: 900;
    color: var(--gold-accent);
    line-height: 1.1;
    margin-bottom: 4px;
}

.counter-label {
    color: #FFFFFF !important;
    font-size: 13px;
    font-weight: 700;
    letter-spacing: 0.8px;
    text-transform: uppercase;
    opacity: 0.9;
}

/* Section Title Styling */
.section-header {
    margin-bottom: 40px;
    position: relative;
}

.section-subtitle {
    color: var(--primary-red);
    font-weight: 800;
    font-size: 13px;
    letter-spacing: 2px;
    text-uppercase: uppercase;
    display: block;
    margin-bottom: 6px;
}

.section-title {
    font-family: 'Montserrat', sans-serif;
    font-size: 32px;
    font-weight: 900;
    color: var(--dark-industrial);
    text-uppercase: uppercase;
    position: relative;
}

.section-title::after {
    content: '';
    display: block;
    width: 60px;
    height: 4px;
    background: var(--primary-red);
    margin-top: 10px;
}

.section-header.text-center .section-title::after {
    margin-left: auto;
    margin-right: auto;
}

/* Product Cards Grid - 100% UNCROPPED FULL VISIBILITY */
.product-card {
    border: 1px solid #E0E0E0;
    border-radius: 8px;
    overflow: hidden;
    background: #FFFFFF;
    transition: all 0.3s ease;
    height: 100%;
    display: flex;
    flex-direction: column;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.12);
    border-color: var(--primary-red);
}

.product-img-wrapper {
    position: relative;
    overflow: hidden;
    height: 230px;
    background: #FFFFFF;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    border-bottom: 1px solid #F0F0F0;
}

.product-img-wrapper img {
    max-width: 100%;
    max-height: 100%;
    width: auto;
    height: auto;
    object-fit: contain;
    transition: transform 0.4s ease;
    margin: auto;
}

.product-card:hover .product-img-wrapper img {
    transform: scale(1.06);
}

.product-badge {
    position: absolute;
    top: 10px;
    left: 10px;
    background: var(--primary-red);
    color: #FFF;
    font-size: 11px;
    font-weight: 700;
    padding: 3px 8px;
    border-radius: 3px;
    text-uppercase: uppercase;
    z-index: 2;
}

.product-title {
    font-size: 15px;
    font-weight: 700;
    color: var(--dark-industrial);
    line-height: 1.4;
    height: 42px;
    overflow: hidden;
}

.product-price {
    font-size: 16px;
    font-weight: 800;
    color: var(--primary-red);
}

/* Category Cards Grid - 100% UNCROPPED FULL VISIBILITY */
.category-card-item {
    transition: all 0.3s ease;
    border: 1px solid #E5E5E5 !important;
}

.category-card-item:hover {
    transform: translateY(-5px);
    box-shadow: 0 12px 30px rgba(0,0,0,0.12) !important;
    border-color: var(--primary-red) !important;
}

.category-img-box {
    position: relative;
    overflow: hidden;
    height: 220px !important;
    background: #FFFFFF !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    padding: 15px !important;
    border-bottom: 1px solid #F0F0F0;
}

.category-img-box img {
    max-width: 100% !important;
    max-height: 100% !important;
    width: auto !important;
    height: auto !important;
    object-fit: contain !important;
    transition: transform 0.4s ease;
    margin: auto;
}

.category-card-item:hover .category-img-box img {
    transform: scale(1.06);
}

.category-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0,0,0,0.4);
    opacity: 0;
    transition: all 0.3s ease;
}

.category-card-item:hover .category-overlay {
    opacity: 1;
}

/* Floating Contact Widgets - Bottom Right Corner */
.floating-contact-box {
    position: fixed;
    bottom: 30px;
    right: 30px;
    z-index: 9999;
    display: flex;
    flex-direction: column;
    gap: 12px;
    align-items: flex-end;
}

.float-btn {
    height: 48px;
    border-radius: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #FFFFFF !important;
    text-decoration: none !important;
    box-shadow: 0 6px 18px rgba(0,0,0,0.25);
    transition: all 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    position: relative;
    border: none;
    cursor: pointer;
    font-size: 18px;
}

.float-btn:hover {
    transform: scale(1.08);
    box-shadow: 0 8px 22px rgba(0,0,0,0.35);
    color: #FFFFFF !important;
}

/* Hotline Phone Button */
.float-phone {
    background-color: var(--primary-red);
    width: 48px;
    height: 48px;
    border-radius: 50%;
    padding: 0;
}

.float-phone-1 {
    background-color: #D32F2F;
}

.float-phone-2 {
    background-color: #E65100;
}
.float-phone-2 .float-tooltip {
    background-color: #E65100;
}
.float-phone-2 .float-tooltip::after {
    border-color: transparent transparent transparent #E65100;
}

.float-phone i {
    font-size: 18px;
    animation: phone-ring 1.5s infinite ease-in-out;
}

.float-tooltip {
    position: absolute;
    right: 62px;
    top: 50%;
    transform: translateY(-50%);
    background-color: var(--primary-red);
    color: #FFFFFF;
    font-weight: 700;
    font-size: 13px;
    padding: 7px 16px;
    border-radius: 30px;
    white-space: nowrap;
    box-shadow: 0 6px 18px rgba(0,0,0,0.25);
    opacity: 0;
    visibility: hidden;
    transition: all 0.3s ease;
    pointer-events: none;
}

.float-tooltip::after {
    content: '';
    position: absolute;
    right: -6px;
    top: 50%;
    transform: translateY(-50%);
    border-width: 6px 0 6px 6px;
    border-style: solid;
    border-color: transparent transparent transparent var(--primary-red);
}

.float-phone:hover .float-tooltip {
    opacity: 1;
    visibility: visible;
    right: 58px;
}

.phone-wave {
    position: absolute;
    top: -4px;
    left: -4px;
    right: -4px;
    bottom: -4px;
    border-radius: 50%;
    border: 2px solid var(--primary-red);
    animation: pulse-wave 2s infinite;
    pointer-events: none;
}

/* Zalo Button */
.float-zalo {
    background-color: #0088FF;
    width: 48px;
}

.float-zalo .zalo-text {
    font-size: 13px;
    font-weight: 900;
    letter-spacing: -0.3px;
}

/* Messenger Button */
.float-messenger {
    background: linear-gradient(135deg, #00C6FF 0%, #0072FF 100%);
    width: 48px;
}

.float-messenger i {
    font-size: 20px;
}

/* Back To Top Button */
.float-top {
    background-color: #1A1A1A;
    color: #FFFFFF !important;
    border: 1px solid #333333;
    width: 48px;
}

.float-top:hover {
    background-color: var(--primary-red);
    border-color: var(--primary-red);
}

/* Keyframe Animations */
@keyframes phone-ring {
    0% { transform: rotate(0deg); }
    10% { transform: rotate(15deg); }
    20% { transform: rotate(-15deg); }
    30% { transform: rotate(15deg); }
    40% { transform: rotate(-15deg); }
    50% { transform: rotate(0deg); }
    100% { transform: rotate(0deg); }
}

@keyframes pulse-wave {
    0% { transform: scale(1); opacity: 0.8; }
    70% { transform: scale(1.08, 1.3); opacity: 0; }
    100% { transform: scale(1.08, 1.3); opacity: 0; }
}

@media (max-width: 768px) {
    .floating-contact-box {
        bottom: 20px;
        right: 15px;
        gap: 10px;
    }
    .float-btn {
        height: 44px;
    }
    .float-zalo, .float-messenger, .float-top {
        width: 44px;
    }
    .float-phone {
        padding: 0 14px;
    }
}

/* Footer & High Contrast Typography System */
footer, .footer-industrial {
    font-size: 14px;
    line-height: 1.7;
    background-color: #141414 !important;
    color: #E5E7EB !important;
}

.text-light-muted {
    color: #E5E7EB !important;
}

.text-light-50 {
    color: #9CA3AF !important;
}

.bg-dark-industrial .text-muted,
.bg-black .text-muted,
footer .text-muted {
    color: #A1A1AA !important;
}

.footer-link-item {
    color: #E5E7EB !important;
    text-decoration: none !important;
    transition: all 0.2s ease;
    display: inline-block;
}

.footer-link-item:hover {
    color: #FF3333 !important;
    transform: translateX(3px);
}

footer a.text-light-50:hover {
    color: #FF3333 !important;
}

.footer-bottom {
    background-color: #0D0D0D;
    font-size: 13px;
}

/* Light Mode Secondary Text Contrast Improvement */
.text-muted {
    color: #4B5563 !important;
}

.bg-light .text-muted,
.card-body .text-muted {
    color: #6B7280 !important;
}

/* Premium Modern Product Detail Pills System */
.product-tabs-header {
    background-color: #F8FAFC !important;
    border-color: #E2E8F0 !important;
}

.product-detail-pills .nav-link {
    color: #475569 !important;
    background-color: #FFFFFF !important;
    border: 1px solid #E2E8F0 !important;
    font-size: 14px;
    letter-spacing: 0.3px;
    transition: all 0.25s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
}

.product-detail-pills .nav-link i {
    color: #DC2626 !important;
    transition: transform 0.25s ease, color 0.25s ease;
}

.product-detail-pills .nav-link:hover {
    color: #0F172A !important;
    background-color: #F1F5F9 !important;
    border-color: #CBD5E1 !important;
    transform: translateY(-1px);
}

.product-detail-pills .nav-link:hover i {
    transform: scale(1.15);
}

.product-detail-pills .nav-link.active {
    color: #FFFFFF !important;
    background: linear-gradient(135deg, #DC2626 0%, #B91C1C 100%) !important;
    border-color: #B91C1C !important;
    box-shadow: 0 4px 12px rgba(220, 38, 38, 0.25) !important;
}

.product-detail-pills .nav-link.active i {
    color: #FFFFFF !important;
}

/* Content & Specification List Typography inside tabs */
.product-description-content h1,
.product-description-content h2,
.product-description-content h3 {
    font-weight: 800;
    color: #0F172A;
    margin-top: 1.5rem;
    margin-bottom: 1rem;
    padding-left: 0.75rem;
    border-left: 4px solid #DC2626;
}

.product-description-content ul,
.product-specs-content ul {
    padding-left: 1.25rem;
    margin-bottom: 1.25rem;
}

.product-description-content li,
.product-specs-content li {
    margin-bottom: 0.5rem;
    color: #334155;
}

/* Standard Product & Article Description Image Sizing System */
.product-description-content img,
.product-specs-content img,
.product-app-content img,
.article-content img {
    max-width: 450px !important;
    width: 100% !important;
    height: auto !important;
    display: block !important;
    margin: 1.5rem auto !important;
    border-radius: 12px !important;
    border: 1px solid #E2E8F0 !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.06) !important;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
}

.product-description-content img:hover,
.product-specs-content img:hover,
.article-content img:hover {
    transform: scale(1.01);
    box-shadow: 0 8px 20px rgba(0, 0, 0, 0.1) !important;
}



