﻿:root {
    --color-common: #2e369d;
    --color-hover: #e54333;
}

.text-banner {
    font-size: 24px;
    font-weight: 700;
    position: absolute;
    padding-left: 20px;
}

.text-banner::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 30px;
    background-color: #264596;
}

/* Search Bar */
.news-search-wrapper {
    display: flex;
    margin: 0 auto;
}

.news-search-input {
    flex: 1;
    padding: 12px 20px;
    border: 1px solid #ddd;
    border-radius: 8px 0 0 8px;
    font-size: 15px;
    transition: all 0.3s;
    border-right: none;
}

.news-search-input:focus {
    outline: none;
    border-color: #264596;
    box-shadow: 0 0 0 3px rgba(38, 69, 150, 0.1);
}

.news-search-btn {
    padding: 12px 30px;
    background-color: #264596;
    color: white;
    border: 1px solid #264596;
    border-radius: 0 8px 8px 0;
    font-size: 15px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.3s;
    white-space: nowrap;
}

.news-search-btn:hover {
    background-color: #1b3472;
    border-color: #1b3472;
}


.text-banner {
    font-size: 24px;
    font-weight: 700;
    position: absolute;
    padding-left: 20px;
}

.text-banner::before {
    content: '';
    position: absolute;
    left: 0;
    top: 50%;
    transform: translateY(-50%);
    width: 4px;
    height: 30px;
    background-color: #264596;
}

/* News Card */
.news-card {
    background: #fff;
    border-radius: 20px;
    overflow: hidden;
    height: 100%;
    display: flex;
    flex-direction: column;
    border: 1px solid #e9ecef;
}

.news-card:hover {
    border: 1px solid var(--color-common);
}

.news-card-image {
    width: 100%;
    height: 220px;
    overflow: hidden;
    position: relative;
}

.news-card-image img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.news-card-content {
    padding: 20px;
    flex: 1;
    display: flex;
    flex-direction: column;
}

.news-card-title {
    margin: 0 0 12px 0;
    line-height: 1.4;
    color: #2e369d;
}

.news-card-title a {
    color: #2e369d;
    text-decoration: none;
    font-size: 18px;
    font-weight: 600;
    display: -webkit-box;
    -webkit-line-clamp: 2;
    -webkit-box-orient: vertical;
    overflow: hidden;
    transition: color 0.3s;
}

.news-card-meta {
    display: flex;
    align-items: center;
    gap: 8px;
    color: #999;
    font-size: 14px;
    margin-bottom: 12px;
}

.news-card-meta i {
    font-size: 14px;
}

.news-card-description {
    color: #000;
    font-size: 14px;
    line-height: 1.7;
    display: -webkit-box;
    -webkit-line-clamp: 5;
    -webkit-box-orient: vertical;
    overflow: hidden;
    margin-top: 8px;
    text-align: justify;
}

.news-card-description p {
    margin: 0;
    line-height: inherit;
}

/* Empty State */
.news-empty {
    text-align: center;
    padding: 60px 20px;
    color: #999;
}

.news-empty h4 {
    margin-top: 15px;
    color: #999;
    font-weight: 400;
}

/* Pagination */
.news-pagination {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px 0;
}

/* List layout (image left, content right) */
.news-list-item {
    display: flex;
    gap: 24px;
    background: #eef3ff;
    border-radius: 16px;
    margin-bottom: 20px;
    outline: none;
    border: 1px solid transparent; /* prevent layout shift on hover */
    box-sizing: border-box;
}

.news-list-item:hover {
    border-color: #264596; /* only change color to avoid shifting */
}

.news-list-thumb {
    flex: 0 0 300px;
    max-width: 300px
}

.news-list-thumb img {
    width: 100%;
    height: 180px;
    object-fit: cover;
    border-top-left-radius: 16px;
    border-bottom-left-radius: 16px;
}

.news-list-content {
    flex: 1;
    padding: 16px 0;
}

.news-list-title {
    display: block;
    font-weight: 700;
    font-size: 16px;
    color: #264596;
    text-decoration: none;
    margin-bottom: 10px
}

.news-list-title:hover {
    color: #1b3472
}

.news-list-meta {
    color: #6b7a99;
    font-size: 14px;
    margin-bottom: 8px;
    display: flex;
    align-items: center;
    gap: 8px
}

.news-list-desc {
    color: #2b2b2b
}

@media (max-width: 767.98px) {
    .news-list-item {
        flex-direction: column
    }

    .news-list-thumb {
        flex: unset;
        max-width: 100%
    }

    .news-list-thumb img {
        height: 200px
    }
}

/* Responsive */
@media (max-width: 768px) {
    .news-card-image {
        height: 180px;
    }

    .news-card-title a {
        font-size: 16px;
    }

    .news-search-wrapper {
        flex-direction: column;
    }

    .news-search-btn {
        width: 100%;
    }
}

@media (max-width: 576px) {
    .news-card-content {
        padding: 15px;
    }
}

/* Legacy Styles - Keep for compatibility */
.TinTuc-banner {
    background-image: url(https://nic.gov.vn/wp-content/uploads/2023/03/17-1-scaled.jpg);
    background-position: center center;
    background-repeat: no-repeat;
    background-size: cover;
    transition: background 0.3s, border 0.3s, border-radius 0.3s, box-shadow 0.3s;
    margin-top: 0px;
    margin-bottom: 0px;
    padding: 320px 0px 100px 0px;
    z-index: 0;
}

.TinTuc-content-list-img {
    width: 100%;
}

.TinTuc-content-list {
    margin: 20px 0;
}

.TinTuc-content-item {
    border-bottom: 1px solid #ccc;
}

.Tintuc-des {
    font-size: 16px;
    opacity: 0.8;
}

.Tintuc-createdate {
    margin: 4px 0;
}

.TinTuc-content-sreach {
    border-bottom: 1px solid #000 !important;
    border: none;
    width: 100%;
    margin-bottom: 30px;
}

.TinTuc-dangky {
    text-align: center;
    background-color: #e4eaf8;
    padding-top: 30px;
}

.TinTuc-dangky-email {
    padding: 10px 30px 10px 30px;
    border-radius: 30px;
}

.TinTuc-dangky-btn {
    margin: 12px 0 30px 0;
    width: 100%;
    padding: 10px 30px 10px 30px;
    border-radius: 30px;
    background-color: var(--color-common);
    border: none;
    color: #fff;
}

.TinTuc-dangky-name {
    color: var(--color-common);
}

.TinTuc-content-common {
    padding: 30px 0;
}

.TinTuc-lienhe {
    margin-top: 30px;
}

.TinTuc-lienhe-title {
    color: var(--color-common);
}

.TinTuc-lienhe-item {
    text-align: center;
}

.TinTuc-lienhe-item i {
    border: 1px solid #ccc;
    font-size: 30px;
    padding: 12px 12px;
    border-radius: 50%;
}

.TinTuc-lienhe-item i:hover {
    cursor: pointer;
    color: var(--color-hover);
    border: 1px solid var(--color-hover);
}