/* CSS Variables */
:root {
    --primary-color: #05608A;
    /* Xanh nền logo */
    --secondary-color: #F8F9FA;
    /* Xám rất nhạt */
    --accent-color: #FFC107;
    /* Vàng - Giữ nguyên để tạo điểm nhấn tương phản với xanh */
    --text-color: #333333;
    --text-light: #666666;
    --white: #FFFFFF;
    --black: #000000;
    --success: #28a745;
    --font-heading: 'Montserrat', sans-serif;
    --font-body: 'Open Sans', sans-serif;
    --transition: all 0.3s ease-in-out;
    --container-width: 1200px;
}

/* Reset CSS */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: var(--font-body);
    color: var(--text-color);
    line-height: 1.6;
    background-color: var(--white);
    overflow-x: hidden;
}

a {
    text-decoration: none;
    color: inherit;
    transition: var(--transition);
}

ul {
    list-style: none;
}

img {
    max-width: 100%;
    height: auto;
    display: block;
}

/* Typography */
h1,
h2,
h3,
h4,
h5,
h6 {
    font-family: var(--font-heading);
    font-weight: 700;
    margin-bottom: 1rem;
    color: var(--black);
}

/* Utilities */
.container {
    max-width: var(--container-width);
    margin: 0 auto;
    padding: 0 1rem;
}

.section {
    padding: 5rem 0;
}

.bg-light {
    background-color: var(--secondary-color);
}

.text-center {
    text-align: center;
}

.text-white {
    color: var(--white);
}

.btn {
    display: inline-block;
    padding: 0.8rem 2rem;
    border-radius: 5px;
    font-weight: 600;
    text-transform: uppercase;
    cursor: pointer;
    border: none;
    transition: var(--transition);
}

.btn-primary {
    background-color: var(--primary-color);
    color: var(--white);
    border: 1px solid var(--primary-color);
}

.btn-primary:hover {
    background-color: #044b6e;
    /* Darker blue */
    border-color: #044b6e;
    transform: translateY(-2px);
    box-shadow: 0 4px 6px rgba(5, 96, 138, 0.3);
}

.btn-outline {
    background-color: transparent;
    border: 2px solid var(--white);
    color: var(--white);
}

.btn-outline:hover {
    background-color: var(--white);
    color: var(--primary-color);
}

.divider {
    height: 4px;
    width: 60px;
    background-color: var(--primary-color);
    margin: 1rem auto;
}

.divider.align-left {
    margin: 1rem 0;
}

/* Header */
header {
    background-color: var(--primary-color);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    z-index: 1000;
    transition: var(--transition);
}

.navbar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 1rem 0;
}

.logo {
    font-size: 1.5rem;
    font-weight: 700;
    font-family: var(--font-heading);
    color: var(--white);
}

.logo span {
    color: var(--accent-color);
}

.nav-menu {
    display: flex;
    gap: 2rem;
    align-items: center;
}

.nav-link {
    font-weight: 600;
    color: var(--white);
    opacity: 0.9;
}

.nav-link:hover,
.nav-link.active {
    color: var(--accent-color);
    opacity: 1;
}

.btn-cta {
    background-color: var(--accent-color);
    color: var(--text-color) !important;
    padding: 0.5rem 1.5rem;
    border-radius: 20px;
}

.btn-cta:hover {
    background-color: #ffca2c;
    /* Slightly lighter yellow */
    color: var(--text-color) !important;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.15);
}

.hamburger {
    display: none;
    cursor: pointer;
}

.bar {
    display: block;
    width: 25px;
    height: 3px;
    margin: 5px auto;
    background-color: var(--white);
    transition: var(--transition);
}

/* Hero Section */
#hero {
    height: 100vh;
    background-image: url('../img/2C5A8802-scaled.jpg');
    background-size: cover;
    background-position: center;
    position: relative;
    display: flex;
    align-items: center;
    color: var(--white);
    margin-top: 60px;
    /* Offset for fixed header */
}

.hero-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    /* Overlay tối màu */
}

.hero-content {
    position: relative;
    z-index: 1;
    max-width: 800px;
    text-align: left;
    /* Căn trái cho hiện đại */
}

.hero-title {
    font-size: 3.5rem;
    line-height: 1.2;
    margin-bottom: 1.5rem;
}

.hero-title .highlight {
    color: var(--accent-color);
}

.hero-subtitle {
    font-size: 1.2rem;
    margin-bottom: 2rem;
    color: rgba(255, 255, 255, 0.9);
}

.hero-buttons {
    display: flex;
    gap: 1rem;
}

/* Features Section */
.features-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.feature-card {
    background: var(--white);
    padding: 2rem;
    border-radius: 10px;
    text-align: center;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: var(--transition);
}

.feature-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
}

.icon-box {
    font-size: 3rem;
    color: var(--primary-color);
    margin-bottom: 1.5rem;
}

/* About Section */
.about-wrapper {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    align-items: center;
}

.about-image img {
    border-radius: 10px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.2);
}

.about-list {
    margin: 2rem 0;
}

.about-list li {
    margin-bottom: 0.5rem;
    font-size: 1.1rem;
}

.about-list i {
    color: var(--success);
    margin-right: 0.5rem;
}

/* Products Section */
.products-grid {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 2.5rem;
    margin-top: 3rem;
}

.product-card {
    flex: 0 1 500px;
    /* Don't grow beyond 500px, but can shrink */
    background: var(--white);
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    transition: var(--transition);
    position: relative;
    border: 1px solid #eee;
}

.product-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 30px rgba(0, 0, 0, 0.15);
}

.product-image {
    position: relative;
    height: 350px;
    overflow: hidden;
}

.product-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s ease;
}

.product-card:hover .product-image img {
    transform: scale(1.1);
}

.badge {
    position: absolute;
    top: 10px;
    right: 10px;
    background-color: var(--accent-color);
    color: var(--text-color);
    padding: 5px 10px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 700;
    text-transform: uppercase;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.2);
    z-index: 10;
}

.product-info {
    padding: 1.5rem;
    text-align: center;
}

.product-info h3 {
    font-size: 1.5rem;
    margin-bottom: 0.8rem;
    color: var(--text-color);
}

.price {
    font-weight: 700;
    color: var(--primary-color);
    font-size: 1.3rem;
    margin-bottom: 0.5rem;
}

.desc {
    font-size: 0.9rem;
    color: var(--text-light);
    margin-bottom: 1rem;
}

.add-to-cart {
    width: 100%;
    padding: 0.8rem;
    background: var(--text-color);
    color: var(--white);
    border: none;
    cursor: pointer;
    transition: var(--transition);
}

.add-to-cart:hover {
    background: var(--primary-color);
}

/* Testimonials Section */
.testimonials-slider {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(350px, 1fr));
    gap: 2rem;
    margin-top: 3rem;
}

.testimonial-card {
    background: #fff;
    padding: 2rem;
    border-radius: 10px;
    box-shadow: 0 5px 15px rgba(0, 0, 0, 0.05);
    position: relative;
}

.quote-icon {
    font-size: 2rem;
    color: #e0e0e0;
    margin-bottom: 1rem;
}

.review-text {
    font-style: italic;
    margin-bottom: 1.5rem;
    color: var(--text-light);
}

.customer-info {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.customer-info img {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    object-fit: cover;
}

/* Contact/CTA Section */
.dark-bg {
    background-color: #222;
    color: var(--white);
}

.contact-row {
    display: flex;
    flex-wrap: wrap;
    gap: 4rem;
}

.col-contact-info {
    flex: 1;
    min-width: 300px;
}

.col-contact-form {
    flex: 1;
    min-width: 300px;
    background: var(--white);
    padding: 2rem;
    border-radius: 10px;
    color: var(--text-color);
}

.contact-item {
    display: flex;
    gap: 1rem;
    margin-bottom: 1.5rem;
    align-items: flex-start;
}

.contact-item i {
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    color: var(--primary-color);
}

.social-links a {
    display: inline-flex;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 50%;
    margin-right: 0.5rem;
    color: var(--white);
    transition: var(--transition);
}

.social-links a:hover {
    background: var(--primary-color);
}

/* Form Styles */
.form-group {
    margin-bottom: 1rem;
}

.form-group label {
    display: block;
    margin-bottom: 0.5rem;
    font-weight: 600;
}

.form-group input,
.form-group textarea,
.form-group select {
    width: 100%;
    padding: 0.8rem;
    border: 1px solid #ddd;
    border-radius: 5px;
    font-family: var(--font-body);
}

.form-group input:focus,
.form-group textarea:focus {
    border-color: var(--primary-color);
    outline: none;
}

.btn-block {
    display: block;
    width: 100%;
}

/* Footer Bottom */
#footer-bottom {
    background-color: #111;
    color: #888;
    padding: 2rem 0;
    font-size: 0.9rem;
}

/* Back to Top */
.back-to-top {
    position: fixed;
    bottom: 2rem;
    right: 2rem;
    width: 50px;
    height: 50px;
    background: var(--primary-color);
    color: var(--white);
    display: flex;
    justify-content: center;
    align-items: center;
    border-radius: 50%;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    opacity: 0;
    pointer-events: none;
    transition: var(--transition);
    z-index: 999;
}

.back-to-top.show {
    opacity: 1;
    pointer-events: auto;
}

/* Floating Contact */
.floating-contact {
    position: fixed;
    bottom: 20px;
    left: 20px;
    z-index: 999;
    display: flex;
    flex-direction: column-reverse;
    /* Stack from bottom */
    gap: 15px;
}

.contact-icon {
    width: 50px;
    height: 50px;
    border-radius: 50%;
    display: flex;
    justify-content: center;
    align-items: center;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    transition: var(--transition);
    position: relative;
    color: #fff;
    background: #fff;
    /* Default bg */
    text-decoration: none;
}

.contact-icon:hover {
    transform: scale(1.1);
}

.contact-icon img {
    width: 30px;
    height: 30px;
    object-fit: contain;
}

.contact-icon.hotline {
    background-color: #dc3545;
    animation: pulse 2s infinite;
    width: auto;
    padding: 0 20px 0 15px;
    border-radius: 50px;
    gap: 10px;
}

.contact-icon.hotline i {
    font-size: 24px;
}

.hotline-text {
    color: #fff;
    font-weight: 700;
    font-size: 1rem;
    white-space: nowrap;
}

.contact-icon.zalo {
    background-color: #0068ff;
    /* Zalo Blue */
}

.contact-icon.messenger {
    background-color: #0084ff;
    /* Messenger Blue */
}

/* Tooltip on hover */
.tooltip {
    position: absolute;
    left: 60px;
    top: 50%;
    transform: translateY(-50%);
    background-color: rgba(0, 0, 0, 0.8);
    color: #fff;
    padding: 5px 10px;
    border-radius: 5px;
    font-size: 0.9rem;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: var(--transition);
    pointer-events: none;
}

.contact-icon:hover .tooltip {
    opacity: 1;
    visibility: visible;
    left: 65px;
    /* Slight slide effect */
}

@keyframes pulse {
    0% {
        box-shadow: 0 0 0 0 rgba(220, 53, 69, 0.7);
    }

    70% {
        box-shadow: 0 0 0 15px rgba(220, 53, 69, 0);
    }

    100% {
        box-shadow: 0 0 0 0 rgba(220, 53, 69, 0);
    }
}


/* Open Letter Section */
#open-letter {
    background-image: url('../img/2C5A8802-scaled.jpg');
    background-size: cover;
    background-position: center;
    background-attachment: fixed;
    /* Parallax effect */
    position: relative;
    padding: 6rem 0;
    color: var(--white);
}

.open-letter-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    /* Darker overlay for readability */
}

.open-letter-content {
    position: relative;
    z-index: 2;
    max-width: 800px;
    margin: 0 auto;
}

.letter-body {
    font-size: 1.1rem;
    line-height: 1.8;
}

.letter-body strong {
    color: var(--accent-color);
}

.mb-3 {
    margin-bottom: 1rem;
}

.mb-4 {
    margin-bottom: 1.5rem;
}

.text-right {
    text-align: right;
}

.font-italic {
    font-style: italic;
}

/* Responsive */
@media (max-width: 992px) {
    .about-wrapper {
        grid-template-columns: 1fr;
    }

    .contact-row {
        flex-direction: column;
    }

    .hero-title {
        font-size: 2.5rem;
    }
}

@media (max-width: 768px) {
    .hamburger {
        display: block;
        z-index: 1001;
        /* Above mobile menu */
    }

    .hamburger.active .bar:nth-child(1) {
        transform: translateY(8px) rotate(45deg);
    }

    .hamburger.active .bar:nth-child(2) {
        opacity: 0;
    }

    .hamburger.active .bar:nth-child(3) {
        transform: translateY(-8px) rotate(-45deg);
    }

    .nav-menu {
        position: fixed;
        left: -100%;
        top: 0;
        gap: 0;
        flex-direction: column;
        background-color: var(--white);
        width: 100%;
        height: 100vh;
        text-align: center;
        transition: 0.3s;
        padding-top: 5rem;
        box-shadow: 0 10px 20px rgba(0, 0, 0, 0.1);
    }

    .nav-menu.active {
        left: 0;
    }

    .nav-item {
        margin: 1.5rem 0;
    }

    .hero-title {
        font-size: 2rem;
    }

    .hero-content {
        text-align: center;
    }

    .hero-buttons {
        justify-content: center;
    }
}