﻿/* Thiết lập chung */
* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: 'Montserrat', Arial, sans-serif;
    background: #f4f4f4;
    color: #222;
    line-height: 1.6;
}

/* ===== HEADER / BANNER ===== */
header {
    background: #004aad; /* Màu xanh đậm chuyên nghiệp hơn */
    color: #fff;
    padding: 25px 0;
}

.header-container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    align-items: center;
    justify-content: flex-start; /* Căn trái giống mẫu Bộ Xây Dựng */
}

.header-logo {
    height: 90px;
    width: auto;
    margin-right: 25px;
    filter: drop-shadow(0px 2px 5px rgba(0,0,0,0.2));
}

.header-text h1 {
    font-size: 1.8rem;
    text-transform: uppercase;
    margin: 0;
    line-height: 1.2;
    letter-spacing: 0.5px;
}

.header-text p {
    font-size: 1rem;
    margin-top: 5px;
    opacity: 0.9;
}

/* ===== NAVIGATION ===== */
nav {
    background: #fff;
    position: sticky;
    top: 0;
    z-index: 1000;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.nav-container {
    max-width: 1100px;
    margin: auto;
    display: flex;
    justify-content: center; /* Căn menu ra giữa */
    padding: 10px 20px;
}

nav ul {
    display: flex;
    list-style: none;
    gap: 5px;
}

    nav ul li a {
        color: #333;
        text-decoration: none;
        font-weight: 600;
        padding: 10px 15px;
        transition: 0.3s;
        border-radius: 4px;
        font-size: 0.95rem;
    }

        nav ul li a:hover, nav ul li a.active {
            background: #004aad;
            color: #fff;
        }


/* ===== NÚT CUỘN LÊN ĐẦU TRANG ===== */
#scrollTopBtn {
    display: none; /* Mặc định ẩn, chỉ hiện khi cuộn xuống */
    position: fixed;
    bottom: 30px; /* Cách đáy 30px */
    right: 30px;  /* Cách phải 30px */
    z-index: 1100; /* Nằm trên cùng mọi thứ */
    border: none;
    outline: none;
    background-color: #ffc107; /* Màu vàng đồng bộ với website của bạn */
    color: #004aad; /* Màu xanh của công ty */
    cursor: pointer;
    padding: 15px;
    border-radius: 50%; /* Làm nút hình tròn */
    font-size: 20px;
    font-weight: bold;
    width: 50px;
    height: 50px;
    box-shadow: 0 4px 10px rgba(0,0,0,0.3);
    transition: all 0.3s ease;
    line-height: 1;
}

#scrollTopBtn:hover {
    background-color: #004aad;
    color: #fff;
    transform: translateY(-5px); /* Hiệu ứng bay lên nhẹ khi di chuột vào */
}



/* ===== SECTIONS ===== */
.section {
    max-width: 1100px;
    margin: 40px auto;
    padding: 20px;
    background: #fff;
    border-radius: 10px;
    box-shadow: 0 2px 15px rgba(0,0,0,0.05);
}

    .section h2 {
        color: #004aad;
        margin-bottom: 25px;
        text-align: center;
        position: relative;
        padding-bottom: 10px;
    }

        .section h2::after {
            content: '';
            position: absolute;
            bottom: 0;
            left: 50%;
            transform: translateX(-50%);
            width: 60px;
            height: 3px;
            background: #ffc107;
        }

.info-box {
    display: flex;
    align-items: stretch; /* Giúp ảnh dài bằng cột chữ */
    gap: 25px; /* Khoảng cách vừa phải giữa 2 cột */
    max-width: 100%;
}

.info-content {
    flex: 0 0 45%; /* Cố định cột chữ chiếm đúng 45% độ rộng */
    min-width: 0;
}

.info-box ul {
    list-style: none;
    margin-bottom: 20px;
}

.info-box li {
    margin-bottom: 10px;
    border-bottom: 1px dashed #eee;
    padding-bottom: 5px;
}

.info-image {
    flex: 1; /* Cột ảnh chiếm 1 phần diện tích */
}

.license-img {
    flex: 1;
    max-width: 350px;
    height: auto;
    border-radius: 8px;
    box-shadow: 0 5px 15px rgba(0,0,0,0.1);
    align-self: flex-start;
}

.info-image-container {
    flex: 0 0 55%; /* Cố định cột ảnh chiếm đúng 55% độ rộng */
    display: flex;
}

.full-height-img {
    width: 100%;
    height: 100%;
    /* Dùng contain thay vì cover nếu bạn muốn thấy toàn bộ tờ giấy phép mà không bị cắt mép */
    object-fit: contain;
    object-position: top;
    border: 1px solid #ddd;
    border-radius: 5px;
    background-color: #fff; /* Tạo nền trắng cho vùng thừa của ảnh */
}


.map-container {
    width: 100%;
    max-width: 1200px; /* Giới hạn độ rộng bằng với nội dung website */
    margin: 0 auto 40px auto; /* Căn giữa và tạo khoảng cách với Footer */
    padding: 0 15px;
}

    .map-container iframe {
        border-radius: 12px; /* Bo góc bản đồ */
        box-shadow: 0 4px 20px rgba(0,0,0,0.1); /* Tạo bóng đổ nhẹ */
        border: 2px solid #004aad; /* Thêm viền xanh mỏng theo màu công ty */
    }


.contact-container {
    display: flex;
    flex-wrap: wrap;
    gap: 30px;
    align-items: stretch; /* Giúp bản đồ dài bằng cột thông tin */
    margin-top: 20px;
}

.contact-info {
    flex: 1; /* Chiếm 1 phần (khoảng 50%) */
    min-width: 300px;
}

.contact-map {
    flex: 1; /* Chiếm 1 phần (khoảng 50%) */
    min-width: 300px;
    display: flex;
}

    .contact-map iframe {
        border-radius: 8px;
        box-shadow: 0 4px 12px rgba(0,0,0,0.1);
        width: 100%;
        height: 100%; /* Ép bản đồ phủ kín cột */
    }



/* ===== GALLERY ===== */
.gallery {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
}

.gallery-item img {
    width: 100%;
    height: 250px;
    object-fit: cover;
    border-radius: 8px;
    transition: 0.3s;
}

    .gallery-item img:hover {
        transform: scale(1.03);
    }

/* ===== FOOTER ===== */
footer {
    text-align: center;
    /* Sử dụng màu xanh đậm thay vì đen */
    background: #004aad;
    /* Hoặc dùng màu này nếu muốn đậm hơn nữa: background: #002147; */
    color: #ffffff; /* Chữ trắng cho nổi bật */
    padding: 40px 20px;
    margin-top: 50px;
    font-size: 0.95rem;
    border-top: 4px solid #ffc107; /* Thêm một đường kẻ màu vàng làm điểm nhấn */
    line-height: 1.8;
}

    footer p {
        margin: 5px 0;
        opacity: 0.8; /* Làm chữ phụ mờ nhẹ đi cho tinh tế */
    }

/* ===== RESPONSIVE ===== */
@media (max-width: 768px) {
    .header-container {
        flex-direction: column;
        text-align: center;
    }

    .header-logo {
        margin-right: 0;
        margin-bottom: 15px;
        height: 70px;
    }

    .header-text h1 {
        font-size: 1.4rem;
    }

    .info-box {
        flex-direction: column;
    }

    .license-img {
        max-width: 100%;
    }

    .full-height-img {
        height: auto; /* Trả về tự động trên mobile để không bị cắt ảnh quá nhiều */
    }

    .info-content, .info-image-container {
        flex: 0 0 100%;
    }

    .map-container iframe {
        height: 300px; /* Giảm chiều cao trên điện thoại cho đỡ tốn diện tích */
    }
	
	/* 1. Tạo hiệu ứng cuộn ngang mượt mà cho Menu */
    .nav-container {
        overflow-x: auto;
        white-space: nowrap;
        display: block; /* Chuyển từ flex sang block để scroll hoạt động */
        -webkit-overflow-scrolling: touch;
        padding: 0;
        border-bottom: 1px solid #eee;
    }

    nav ul {
        display: flex;
        padding: 0 10px;
        gap: 0;
    }

    nav ul li a {
        padding: 12px 15px;
        font-size: 0.9rem;
        display: inline-block;
    }

    /* 2. Sửa lỗi "khối xanh" khi nhấn vào (Active) */
    nav ul li a:active, 
    nav ul li a:focus,
    nav ul li a.active {
        background: #004aad;
        color: #fff;
        border-radius: 0; /* Bỏ bo góc để không bị lệch khối trên mobile */
    }

    /* Ẩn thanh cuộn để menu nhìn sạch hơn */
    .nav-container::-webkit-scrollbar {
        display: none;
    }

    /* 3. Thu gọn Header để nhường chỗ cho nội dung */
    header {
        padding: 15px 0;
    }
    .header-logo {
        height: 55px;
        margin-bottom: 8px;
    }
    .header-text h1 {
        font-size: 1.1rem;
    }

}
