/* Reset và Base Styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Roboto', sans-serif;
    line-height: 1.5;
    color: #333;
    background-color: #f8f9fa;
    font-size: 14px; /* Reduced base font size */
}

/* Shared simple footer (aligned like góp-ý) */
.footer {
    background: #1f2937;
    color: #fff;
    padding: 1.5rem 0;
    text-align: center;
    margin-top: 3rem;
}

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

.footer-content p {
    font-size: 0.9rem;
    color: #9ca3af;
}

a {
    text-decoration: none;
    color: inherit;
}

/* News card links */
.news-card > a {
    display: flex;
    flex-direction: column;
    height: 100%;
}

.news-card:not(.featured) > a {
    flex-direction: row;
    gap: 1rem;
}

/* Popular item links */
.popular-item > a {
    display: flex;
    gap: 0.8rem;
    width: 100%;
}

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

/* Banner Section */
.banner-section {
    position: relative;
    width: 100%;
    height: 20vh;
    min-height: 150px;
    overflow: hidden;
}

.banner-container {
    position: relative;
    width: 100%;
    height: 100%;
}

.banner-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.banner-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.4);
    display: flex;
    align-items: center;
    justify-content: center;
}

.banner-slogan {
    color: white;
    font-size: 2.5rem;
    font-weight: 700;
    text-align: center;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.5);
    padding: 0 20px;
}

/* Header */
.header {
    background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    position: sticky;
    top: 0;
    z-index: 1000;
}

.navbar {
    padding: 1rem 0;
}

.nav-container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
    display: flex;
    justify-content: space-between;
    align-items: center;
    position: relative;
}

.nav-menu {
    display: flex;
    gap: 2rem;
}

.mobile-menu-toggle {
    display: none;
    background: none;
    border: none;
    color: white;
    font-size: 1.5rem;
    cursor: pointer;
    padding: 0.5rem;
    z-index: 1001;
}

.nav-menu.mobile-open {
    display: flex;
}

.nav-link {
    color: white;
    text-decoration: none;
    font-weight: 500;
    font-size: 1.1rem;
    padding: 0.5rem 1rem;
    border-radius: 8px;
    transition: all 0.3s ease;
    position: relative;
    overflow: hidden;
}

.nav-link::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.nav-link:hover::before {
    left: 100%;
}

.nav-link:hover {
    background: rgba(255, 255, 255, 0.15);
    transform: translateY(-2px);
}

.nav-link::after {
    content: '';
    position: absolute;
    bottom: -5px;
    left: 50%;
    width: 0;
    height: 3px;
    background: #fbbf24;
    transition: all 0.3s ease;
    transform: translateX(-50%);
    border-radius: 2px;
}

.nav-link:hover::after {
    width: 80%;
}

.nav-auth {
    display: flex;
    gap: 1rem;
}

.mobile-auth {
    display: none;
}

.auth-link {
    color: white;
    text-decoration: none;
    padding: 0.5rem 1.5rem;
    border-radius: 25px;
    font-weight: 500;
    transition: all 0.3s ease;
    border: 2px solid transparent;
}

.auth-link:hover {
    border-color: #fbbf24;
    background: rgba(251, 191, 36, 0.1);
    transform: translateY(-2px);
}

.login-btn {
    background: linear-gradient(45deg, #fbbf24, #f59e0b);
    color: #dc2626;
    font-weight: 600;
    border-color: #fbbf24;
}

.login-btn:hover {
    background: linear-gradient(45deg, #f59e0b, #d97706);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(251, 191, 36, 0.5);
    border-color: #f59e0b;
}

/* Main Content */
.main-content {
    margin-top: 0;
}

/* Main Layout */
.main-layout {
    max-width: 1400px;
    margin: 0 auto;
    padding: 2rem 20px;
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 3rem;
    background: #ffffff;
}

/* Slider Section */
.slider-section {
    position: relative;
    height: 60vh;
    min-height: 400px;
    overflow: hidden;
    border-radius: 15px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    background: #ffffff;
}

.slider-container {
    position: relative;
    width: 100%;
    height: 100%;
    border-radius: 15px;
    overflow: hidden;
}

.slider-wrapper {
    position: relative;
    width: 100%;
    height: 100%;
}

.slide {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    transition: all 1s cubic-bezier(0.4, 0, 0.2, 1);
    transform: scale(1.05);
}

.slide.active {
    opacity: 1;
    transform: scale(1);
}

.slide-image {
    width: 100%;
    height: 100%;
    object-fit: cover;
    background: linear-gradient(135deg, #f1f5f9 0%, #e2e8f0 50%, #cbd5e1 100%);
    filter: brightness(0.9);
}

.slide-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(30, 41, 59, 0.6) 0%, rgba(51, 65, 85, 0.7) 100%);
    display: flex;
    align-items: center;
    justify-content: center;
}

.slide-content {
    text-align: center;
    color: white;
    max-width: 600px;
    padding: 0 20px;
    transform: translateY(20px);
    animation: slideUp 1s ease-out forwards;
}

.slide-content h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1rem;
    text-shadow: 2px 2px 8px rgba(0, 0, 0, 0.3);
    background: linear-gradient(45deg, #ffffff, #f1f5f9);
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
}

.slide-content p {
    font-size: 1.2rem;
    font-weight: 400;
    text-shadow: 1px 1px 4px rgba(0, 0, 0, 0.3);
    opacity: 0.95;
}

/* Slider Navigation */
.slider-nav {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    width: 100%;
    display: flex;
    justify-content: space-between;
    padding: 0 20px;
    pointer-events: none;
}

.slider-btn {
    background: rgba(220, 38, 38, 0.8);
    color: white;
    border: none;
    width: 50px;
    height: 50px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.2rem;
    transition: all 0.3s ease;
    pointer-events: all;
    display: flex;
    align-items: center;
    justify-content: center;
}

.slider-btn:hover {
    background: #dc2626;
    transform: scale(1.1);
    box-shadow: 0 5px 15px rgba(220, 38, 38, 0.4);
}

/* Slider Dots */
.slider-dots {
    position: absolute;
    bottom: 20px;
    left: 50%;
    transform: translateX(-50%);
    display: flex;
    gap: 10px;
}

.dot {
    width: 12px;
    height: 12px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.5);
    cursor: pointer;
    transition: all 0.3s ease;
}

.dot.active,
.dot:hover {
    background: #fbbf24;
    transform: scale(1.2);
}

/* Latest News Section */
.latest-news {
    margin-top: 3rem;
}

.section-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 2rem;
    padding-bottom: 1rem;
    border-bottom: 3px solid #dc2626;
}

.section-header h2 {
    color: #1e293b;
    font-size: 1.8rem;
    font-weight: 700;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.section-header h2 i {
    color: #dc2626;
}

.view-all {
    color: #dc2626;
    text-decoration: none;
    font-weight: 500;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    transition: all 0.3s ease;
}

.view-all:hover {
    color: #b91c1c;
    transform: translateX(5px);
}

.news-grid {
    display: grid;
    gap: 1.5rem;
}

.news-card {
    background: white;
    border-radius: 12px;
    overflow: hidden;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    border: 1px solid #e2e8f0;
    display: flex;
    gap: 1rem;
}

.news-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.15);
    border-color: #dc2626;
}

.news-card.featured {
    flex-direction: column;
    grid-column: 1 / -1;
}

.news-image {
    position: relative;
    overflow: hidden;
    flex-shrink: 0;
}

.news-card.featured .news-image {
    height: 250px;
}

.news-card:not(.featured) .news-image {
    width: 150px;
    height: 120px;
}

.news-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    background: linear-gradient(135deg, #f1f5f9, #e2e8f0);
    transition: transform 0.3s ease;
}

.news-card:hover .news-image img {
    transform: scale(1.05);
}

.news-category {
    position: absolute;
    top: 10px;
    left: 10px;
    background: linear-gradient(135deg, #dc2626, #b91c1c);
    color: white;
    padding: 0.3rem 0.8rem;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 500;
}

.news-content {
    padding: 1.5rem;
    flex: 1;
}

.news-card:not(.featured) .news-content {
    padding: 1rem;
}

.news-content h3 {
    color: #1e293b;
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 0.8rem;
    line-height: 1.4;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-card.featured .news-content h3 {
    font-size: 1.5rem;
    -webkit-line-clamp: 3;
}

.news-content p {
    color: #64748b;
    line-height: 1.6;
    margin-bottom: 1rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.news-meta {
    display: flex;
    gap: 1rem;
    font-size: 0.85rem;
    color: #94a3b8;
}

.news-meta span {
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

/* Sidebar Styles */
.sidebar {
    display: flex;
    flex-direction: column;
    gap: 2rem;
}

.widget {
    background: white;
    border-radius: 12px;
    padding: 1.5rem;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.08);
    border: 1px solid #e2e8f0;
    transition: all 0.3s ease;
}

.widget:hover {
    box-shadow: 0 8px 25px rgba(0, 0, 0, 0.12);
    transform: translateY(-2px);
}

.widget-title {
    color: #1e293b;
    font-size: 1.2rem;
    font-weight: 600;
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding-bottom: 0.8rem;
    border-bottom: 2px solid #dc2626;
}

.widget-title i {
    color: #dc2626;
}

/* Quick Links */
.quick-links {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.quick-link {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 0.8rem;
    color: #475569;
    text-decoration: none;
    border-radius: 8px;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.quick-link:hover {
    background: linear-gradient(135deg, #fef2f2, #fee2e2);
    color: #dc2626;
    border-color: #fecaca;
    transform: translateX(5px);
}

.quick-link i {
    color: #dc2626;
    width: 20px;
    text-align: center;
}

/* Popular Articles */
.popular-articles {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.popular-item {
    display: flex;
    gap: 0.8rem;
    padding: 0.8rem;
    border-radius: 8px;
    transition: all 0.3s ease;
    border: 1px solid transparent;
}

.popular-item:hover {
    background: #f8fafc;
    border-color: #e2e8f0;
}

.popular-image {
    width: 60px;
    height: 60px;
    border-radius: 8px;
    overflow: hidden;
    flex-shrink: 0;
}

.popular-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    background: linear-gradient(135deg, #f1f5f9, #e2e8f0);
}

.popular-content h4 {
    color: #1e293b;
    font-size: 0.9rem;
    font-weight: 500;
    line-height: 1.4;
    margin-bottom: 0.5rem;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.popular-views {
    color: #94a3b8;
    font-size: 0.8rem;
    display: flex;
    align-items: center;
    gap: 0.3rem;
}

/* Statistics */
.stats-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 1rem;
}

.stat-item {
    text-align: center;
    padding: 1rem;
    background: linear-gradient(135deg, #fef2f2, #fee2e2);
    border-radius: 8px;
    border: 1px solid #fecaca;
}

.stat-number {
    color: #dc2626;
    font-size: 1.5rem;
    font-weight: 700;
    margin-bottom: 0.3rem;
}

.stat-label {
    color: #64748b;
    font-size: 0.8rem;
    font-weight: 500;
}

/* Contact Widget */
.contact-widget .contact-info {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.contact-widget .contact-item {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 0.5rem;
    border-radius: 6px;
    transition: background 0.3s ease;
}

.contact-widget .contact-item:hover {
    background: #f8fafc;
}

.contact-widget .contact-item i {
    color: #dc2626;
    width: 20px;
    text-align: center;
}

/* Animations */
@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

@keyframes fadeInScale {
    from {
        opacity: 0;
        transform: scale(0.9);
    }
    to {
        opacity: 1;
        transform: scale(1);
    }
}

.widget {
    animation: fadeInScale 0.6s ease-out;
}

.news-card {
    animation: slideUp 0.6s ease-out;
}

/* Footer */
.footer {
    background: linear-gradient(135deg, #1f2937 0%, #111827 100%);
    color: white;
    padding: 3rem 0 1rem;
}

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

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

.footer-section h3 {
    color: #fbbf24;
    font-size: 1.3rem;
    font-weight: 600;
    margin-bottom: 1rem;
    border-bottom: 2px solid #dc2626;
    padding-bottom: 0.5rem;
    display: inline-block;
}

.contact-info {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.contact-item {
    display: flex;
    align-items: center;
    gap: 0.8rem;
}

.contact-item i {
    color: #dc2626;
    width: 20px;
}

.social-links {
    display: flex;
    flex-direction: column;
    gap: 0.8rem;
}

.social-link {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    color: white;
    text-decoration: none;
    padding: 0.5rem;
    border-radius: 5px;
    transition: all 0.3s ease;
}

.social-link:hover {
    background: rgba(220, 38, 38, 0.2);
    transform: translateX(5px);
}

.social-link.facebook:hover { background: rgba(24, 119, 242, 0.2); }
.social-link.zalo:hover { background: rgba(0, 162, 255, 0.2); }
.social-link.gmail:hover { background: rgba(234, 67, 53, 0.2); }
.social-link.youtube:hover { background: rgba(255, 0, 0, 0.2); }

.footer-links {
    list-style: none;
}

.footer-links li {
    margin-bottom: 0.5rem;
}

.footer-links a {
    color: #d1d5db;
    text-decoration: none;
    transition: color 0.3s ease;
}

.footer-links a:hover {
    color: #fbbf24;
}

.footer-bottom {
    border-top: 1px solid #374151;
    padding-top: 1rem;
    text-align: center;
    color: #9ca3af;
}

/* Responsive Design */
@media (max-width: 768px) {
    .banner-slogan {
        font-size: 1.8rem;
    }
    
    .mobile-menu-toggle {
        display: block;
    }
    
    .nav-menu {
        display: none;
        position: absolute;
        top: 100%;
        left: 0;
        right: 0;
        background: linear-gradient(135deg, #dc2626 0%, #b91c1c 100%);
        flex-direction: column;
        gap: 0;
        padding: 1rem 0;
        box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);
    }
    
    .nav-menu.mobile-open {
        display: flex;
    }
    
    .nav-link {
        padding: 1rem 2rem;
        border-bottom: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    .nav-link:last-child {
        border-bottom: none;
    }
    
    .desktop-auth {
        display: none;
    }
    
    .mobile-auth {
        display: flex;
        flex-direction: column;
        gap: 0.5rem;
        margin-top: 1rem;
        padding: 1rem 2rem 0;
        border-top: 1px solid rgba(255, 255, 255, 0.1);
    }
    
    .mobile-auth .auth-link {
        padding: 0.75rem 1rem;
        text-align: center;
        border-radius: 5px;
        border: 1px solid rgba(255, 255, 255, 0.2);
    }
    
    .main-layout {
        grid-template-columns: 1fr;
        gap: 2rem;
        padding: 1rem;
    }
    
    .slide-content h2 {
        font-size: 2rem;
    }
    
    .slide-content p {
        font-size: 1.1rem;
    }
    
    .slider-btn {
        width: 40px;
        height: 40px;
        font-size: 1rem;
    }
    
    .news-card {
        flex-direction: column;
    }
    
    .news-card:not(.featured) .news-image {
        width: 100%;
        height: 150px;
    }
    
    .section-header {
        flex-direction: column;
        align-items: flex-start;
        gap: 1rem;
    }
    
    .stats-grid {
        grid-template-columns: 1fr;
    }
    
    .footer-content {
        grid-template-columns: 1fr;
        text-align: center;
    }
    
    .social-links {
        align-items: center;
    }
}

@media (max-width: 480px) {
    .banner-slogan {
        font-size: 1.4rem;
    }
    
    .nav-link {
        font-size: 1rem;
        padding: 0.4rem 0.8rem;
    }
    
    .slide-content h2 {
        font-size: 1.5rem;
    }
    
    .slide-content p {
        font-size: 1rem;
    }
    
    .content-card {
        padding: 1.5rem;
    }
    
    .card-icon {
        width: 60px;
        height: 60px;
        font-size: 1.5rem;
    }
}

/* Profile Menu Styles */
.nav-auth-container {
    position: relative;
}

.profile-menu {
    position: relative;
}

.profile-toggle {
    background: none;
    border: none;
    cursor: pointer;
    padding: 0;
    border-radius: 50%;
    display: flex;
    align-items: center;
}

.profile-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 2px solid #fbbf24;
    transition: transform 0.3s ease;
}

.profile-toggle:hover .profile-avatar {
    transform: scale(1.1);
}

.profile-dropdown {
    display: none;
    position: absolute;
    top: 120%;
    right: 0;
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    width: 220px;
    overflow: hidden;
    z-index: 1001;
    border: 1px solid #e2e8f0;
    animation: fadeInScale 0.3s ease-out;
}

.profile-dropdown.show {
    display: block;
}

.dropdown-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.8rem 1.2rem;
    color: #334155;
    text-decoration: none;
    font-size: 0.95rem;
    transition: background-color 0.2s ease, color 0.2s ease;
}

.dropdown-item i {
    width: 20px;
    color: #94a3b8;
    transition: color 0.2s ease;
}

.dropdown-item:hover {
    background-color: #f1f5f9;
    color: #dc2626;
}

.dropdown-item:hover i {
    color: #dc2626;
}

.dropdown-divider {
    height: 1px;
    background-color: #e2e8f0;
    margin: 0.5rem 0;
}
