/* =========================================
   THEME: VIETTEL TELECOM (MODERN FLAT STYLE)
   ========================================= */

/* --- BIẾN MÀU SẮC & CẤU HÌNH --- */
:root {
    --primary-color: #ee0033;   /* Đỏ Viettel */
    --secondary-color: #c4002b; /* Đỏ đậm (Hover) */
    --accent-color: #f7941d;    /* Vàng cam (Icon/Logo) */
    --text-dark: #333333;
    --text-light: #666666;
    --bg-light: #f9f9f9;        /* Nền sáng hơn chút */
    --white: #ffffff;
    --border-color: #e1e4e8;
    --radius: 0px;              /* QUAN TRỌNG: 0px để vuông vức, nam tính */
    --shadow-sm: 0 2px 4px rgba(0, 0, 0, 0.05);
}

/* --- GLOBAL STYLES --- */
body {
    display: block;
    font-family: 'Segoe UI', Roboto, Helvetica, Arial, sans-serif;
    background-color: var(--bg-light);
    color: var(--text-dark);
    margin: 0;
    padding: 0;
    line-height: 1.5;
}

a {
    text-decoration: none;
    color: inherit;
    transition: 0.3s;
}

ul {
    list-style: none;
    padding: 0;
    margin: 0;
}

.vnpt-container {
    width: 100%;
    overflow-x: hidden;
}

/* --- HEADER --- */
.vnpt-header {
    background-color: var(--white);
    box-shadow: 0 2px 10px rgba(0,0,0,0.05);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.header-content-wrapper {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 15px;
    height: 80px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

/* Logo Area */
.vnpt-header .logo {
    display: flex;
    align-items: center;
    gap: 12px;
}

.vnpt-header .logo img {
    height: 45px;
    object-fit: contain;
}

.vnpt-header .logo .brand-text {
    display: flex;
    flex-direction: column;
}

.vnpt-header .logo .brand-text h1 {
    margin: 0;
    font-size: 1.4rem;
    color: var(--primary-color);
    font-weight: 800;
    line-height: 1;
    text-transform: uppercase;
}

.vnpt-header .logo .brand-text span {
    font-size: 0.8rem;
    color: var(--text-light);
    letter-spacing: 1px;
    font-weight: 500;
}

/* --- MENU NAVIGATION (KIỂU GẠCH CHÂN) --- */
.main-nav ul {
    display: flex;
    gap: 10px;
    align-items: center;
}

.main-nav li {
    position: relative;
}

/* Style cho link menu: Chữ to, đậm, không nền */
.main-nav li a {
    padding: 10px 15px;
    font-weight: 700;
    color: var(--text-dark);
    font-size: 15px;
    text-transform: uppercase;
    display: block;
    position: relative; /* Để làm cái gạch chân */
}

/* Hiệu ứng gạch chân chạy ra khi hover */
.main-nav li a::after {
    content: '';
    position: absolute;
    width: 0;
    height: 3px;
    bottom: 0;
    left: 0;
    background-color: var(--primary-color);
    transition: width 0.3s ease;
}

.main-nav li a:hover::after,
.main-nav li.current-menu-item > a::after {
    width: 100%; /* Kéo dài gạch chân 100% */
}

.main-nav li a:hover,
.main-nav li.current-menu-item > a {
    color: var(--primary-color);
}

/* Dropdown Menu (Menu con) */
.main-nav .dropdown:hover .dropdown-content {
    display: block;
    animation: fadeIn 0.2s;
}

.main-nav .dropdown-content {
    display: none;
    position: absolute;
    top: 100%;
    left: 0;
    background: var(--white);
    min-width: 220px;
    box-shadow: 0 4px 12px rgba(0,0,0,0.1);
    border-top: 3px solid var(--primary-color);
    padding: 10px 0;
    z-index: 101;
}

.main-nav .dropdown-content a {
    text-transform: none; /* Menu con viết thường */
    padding: 10px 20px;
    font-weight: 500;
    color: var(--text-dark);
}

.main-nav .dropdown-content a::after {
    display: none; /* Menu con không cần gạch chân */
}

.main-nav .dropdown-content a:hover {
    background-color: var(--bg-light);
    color: var(--primary-color);
}

/* Mobile Menu Button */
.mobile-menu-btn {
    display: none;
    background: none;
    border: none;
    font-size: 1.8rem;
    cursor: pointer;
    color: var(--primary-color);
    padding: 5px;
}

/* --- CONTENT AREA --- */
.vnpt-content {
    max-width: 1200px;
    margin: 30px auto;
    padding: 0 15px;
}

/* Banner Slider */
.main-banner-area {
    display: flex;
    gap: 20px;
    margin-bottom: 40px;
    height: 380px;
}

.main-banner-column {
    flex: 2.5;
    border-radius: var(--radius);
    overflow: hidden;
    position: relative;
}

.slider-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: none;
    animation: fade 0.8s;
}

.slider-image.active { display: block; }

.slider-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    background: rgba(0,0,0,0.3);
    border: none;
    color: white;
    font-size: 2rem;
    padding: 10px 15px;
    cursor: pointer;
    transition: 0.3s;
}
.slider-nav:hover { background: var(--primary-color); }
.slider-nav.prev { left: 0; }
.slider-nav.next { right: 0; }

/* Side Banners */
.side-banners-column {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.side-banner {
    flex: 1;
    border-radius: var(--radius);
    overflow: hidden;
}
.side-banner img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}
.side-banner:hover img { transform: scale(1.05); }

/* --- POST GRID (KIỂU FLAT - VUÔNG VỨC) --- */
.main-content-grid {
    display: flex;
    gap: 30px;
    align-items: flex-start;
}

.middle-col { flex: 1; }
.right-col { flex: 0 0 280px; display: flex; flex-direction: column; gap: 20px; }

.section-title {
    display: flex;
    align-items: center;
    margin-bottom: 25px;
}
.section-title h2 {
    color: var(--primary-color);
    margin: 0;
    margin-right: 15px;
    font-size: 1.5rem;
    text-transform: uppercase;
    font-weight: 800;
}
.section-title .line { flex: 1; height: 2px; background: #eee; }

/* Post Card Styles */
.post-card {
    display: flex;
    background: var(--white);
    border-radius: var(--radius); /* Vuông */
    border: 1px solid #eee;       /* Viền mỏng */
    box-shadow: none;             /* Bỏ bóng */
    overflow: hidden;
    margin-bottom: 20px;
    transition: all 0.3s;
}

.post-card:hover {
    border-color: var(--primary-color); /* Hover đổi màu viền */
    box-shadow: 0 5px 15px rgba(238, 0, 51, 0.1); /* Bóng đỏ nhẹ */
}

.post-img-wrapper {
    flex: 0 0 280px;
    overflow: hidden;
}
.post-img-wrapper img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.5s;
}
.post-card:hover img { transform: scale(1.05); }

.post-content {
    flex: 1;
    padding: 20px 25px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
}

.post-title {
    margin: 0 0 10px 0;
    font-size: 1.3rem;
    font-weight: 700;
    line-height: 1.4;
}
.post-title a:hover { color: var(--primary-color); }

.post-excerpt {
    font-size: 0.95rem;
    color: var(--text-light);
    line-height: 1.6;
    margin-bottom: 15px;
    display: -webkit-box;
    -webkit-line-clamp: 3;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.read-more {
    font-weight: 700;
    color: var(--primary-color);
    text-transform: uppercase;
    font-size: 0.85rem;
}

/* Sidebar Widgets */
.support-box {
    background: var(--white);
    border: 1px solid #eee;
    padding: 20px;
    border-top: 4px solid var(--primary-color);
}
.support-box h4 {
    margin-top: 0;
    text-align: center;
    color: var(--primary-color);
    text-transform: uppercase;
}

/* --- FOOTER (NEW DESIGN - 2 COLUMNS) --- */
.vnpt-footer {
    /* Gradient Đỏ đậm sang Đen */
    background: linear-gradient(135deg, #c80028 0%, #32000a 100%);
    color: white;
    padding: 50px 0 20px;
    margin-top: 50px;
}

/* Flex layout cho Footer */
.vnpt-footer .header-content-wrapper {
    display: flex;
    justify-content: space-between;
    flex-wrap: wrap;
    gap: 30px;
    align-items: flex-start;
    height: auto; /* Override chiều cao cố định của header */
}

/* Cột Trái: Thông tin */
.footer-left {
    flex: 2;
    min-width: 300px;
}

.footer-brand {
    color: var(--accent-color);
    font-size: 1.2rem;
    font-weight: 800;
    margin-bottom: 20px;
    text-transform: uppercase;
}

.footer-info-list li {
    margin-bottom: 12px;
    font-size: 0.95rem;
    opacity: 0.9;
    display: flex;
    gap: 10px;
}
.footer-info-list li i {
    color: var(--accent-color);
    margin-top: 4px;
    width: 20px;
}

/* Cột Phải: Mạng xã hội */
.footer-right {
    flex: 1;
    min-width: 200px;
    display: flex;
    flex-direction: column;
    align-items: flex-end; /* Căn phải */
}

.social-title {
    font-weight: 700;
    margin-bottom: 15px;
    text-transform: uppercase;
    font-size: 0.9rem;
}

.social-icons {
    display: flex;
    gap: 12px;
}

/* Style Icon Tròn */
.social-link {
    width: 40px;
    height: 40px;
    border: 1px solid rgba(255,255,255,0.2);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    font-size: 1.1rem;
    transition: all 0.3s;
    background: rgba(0,0,0,0.1);
}

.social-link:hover {
    background: white;
    transform: translateY(-3px);
}
/* Màu riêng cho từng mạng XH khi hover */
.social-link.fb:hover { color: #1877f2; }
.social-link.ins:hover { color: #c32aa3; }
.social-link.ytb:hover { color: #ff0000; }
.social-link.in:hover { color: #0077b5; } /* LinkedIn */

/* Copyright */
.copyright {
    text-align: center;
    margin-top: 30px;
    padding-top: 20px;
    border-top: 1px solid rgba(255,255,255,0.1);
    font-size: 0.85rem;
    opacity: 0.6;
}

/* --- ANIMATIONS --- */
@keyframes fade { from { opacity: 0.8 } to { opacity: 1 } }
@keyframes fadeIn { from { opacity: 0; transform: translateY(10px) } to { opacity: 1; transform: translateY(0) } }

/* --- RESPONSIVE --- */
@media (max-width: 1024px) {
    .main-content-grid { flex-direction: column; }
    .right-col { width: 100%; flex-direction: row; flex-wrap: wrap; }
    .right-col .support-box { flex: 1; min-width: 250px; }
    
    .main-banner-area { flex-direction: column; height: auto; }
    .main-banner-column { height: 300px; }
    .side-banners-column { flex-direction: row; height: 150px; }

    /* Mobile Menu */
    .mobile-menu-btn { display: block; }
    .main-nav {
        display: none;
        position: absolute;
        top: 80px; left: 0; width: 100%;
        background: var(--white);
        box-shadow: 0 5px 15px rgba(0,0,0,0.1);
        border-top: 1px solid #eee;
    }
    .main-nav.active { display: block; animation: fadeIn 0.3s; }
    .main-nav ul { flex-direction: column; gap: 0; align-items: flex-start; }
    .main-nav li { width: 100%; }
    .main-nav li a {
        padding: 15px 20px;
        border-bottom: 1px solid #f9f9f9;
    }
    .main-nav li a::after { display: none; } /* Mobile bỏ gạch chân */
    
    /* Footer Mobile */
    .footer-right { align-items: flex-start; margin-top: 20px; }
}

@media (max-width: 768px) {
    .post-card { flex-direction: column; }
    .post-img-wrapper { flex: 0 0 200px; width: 100%; }
    .side-banners-column { flex-direction: column; height: 300px; }
    .right-col { flex-direction: column; }
}
.right-col img, 
.support-box img {
    max-width: 100% !important; /* Bắt buộc ảnh không được rộng hơn cái cột */
    height: auto;               /* Tự động tính chiều cao cho ảnh không bị méo */
    display: block;             
}