/* NEWS MENU - Diamond MMORPG Style */
/* =========================
   NEWS LINE
========================= */

.news-line {
    position: absolute;
    top: 1200px; /* ปรับตำแหน่งเอง */
    left: 50%;
    transform: translateX(-50%);

    width: 1220px;
    text-align: center;
}

.news-line img {
    display: block;
    margin: 0 auto;
    width: 100%;      /* หรือกำหนดเป็น px เช่น 1220px */
    max-width: 1220px;
}

.news-section {
    position: absolute;
    top: 1250px;
    left: 50%;
    width: 1220px;
    transform: translateX(-50%);
    font-family: "IBM Plex Sans Thai", "Kanit", sans-serif;
}

/* Tabs */
.news-tabs {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 12px;
    margin-bottom: 22px;
}

.news-tab {
    width: auto;
    height: auto;
    padding: 0;
    border: none;
    background: transparent;
    box-shadow: none;
    cursor: pointer;
    transition: .25s;
}

.news-tab::before,
.news-tab::after {
    display: none;
}

.news-tab img {
    width: 201px;
    display: block;
    transition: .25s;
}

.news-tab:hover,
.news-tab.active {
    transform: translateY(-3px);
    filter: drop-shadow(0 0 12px #5de6ff);
}

/* Content Frame */
.news-content {
    display: none;

    grid-template-columns: repeat(3, 380px);
    grid-auto-rows: 282px;
    justify-content: center;
    gap: 20px;

    padding: 24px;

    border: 1px solid rgba(60,150,255,.35);
    border-radius: 0;

    background: rgba(8,16,35,.35);

    box-shadow:
        0 0 20px rgba(40,120,255,.18);

    backdrop-filter: blur(3px);
    overflow: hidden;
}

.news-content.active {
    display: grid;
}

/* Card */
.news-card {
    position: relative;
    display: none;

    width: 380px;
    height: 282px;

    padding: 8px;

    overflow: hidden;
    text-decoration: none;
    color: inherit;

    background: rgba(10,20,40,.55);

    box-shadow:
        0 0 12px rgba(40,120,255,.18);

    transition: .25s;
}

.news-card.show {
    display: block;
}

.news-card::before {
    display: none;
}

.news-card::after {
    content: "◆";
    position: absolute;
    top: 4px;
    right: 12px;
    z-index: 4;

    color: #eaffff;
    font-size: 15px;

    text-shadow:
        0 0 6px #ffffff,
        0 0 12px #5de6ff,
        0 0 20px #1faeff;

    pointer-events: none;
}

.news-card:hover {
    transform: translateY(-3px);

    border-color: rgba(120,210,255,.7);

    box-shadow:
        0 0 18px rgba(70,170,255,.35);
}


/* Image 380x228 */
.news-card img {
    width: 100%;
    height: 228px;

    object-fit: cover;
    display: block;

    border: 1px solid rgba(80,160,255,.35);
    border-radius: 0;

    box-shadow: none;
}

.news-card:hover img {
    transform: scale(1.025);
    filter: brightness(1.08) contrast(1.05);
}

/* Title under image */
.news-title {
    margin-top: 8px;
    height: 34px;

    display: flex;
    align-items: center;
    justify-content: center;

    border: 1px solid rgba(70,160,255,.45);
    border-radius: 0;

    background: rgba(20,45,90,.75);

    color: #fff;
    font-size: 14px;
    font-weight: 600;

    text-shadow: none;

    box-shadow:
        0 0 8px rgba(40,120,255,.18);

    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

/* Pagination */
.news-pagination {
    display: flex;
    justify-content: center;
    gap: 8px;
    margin-top: 18px;
}

.news-page-btn {
    width: 34px;
    height: 34px;
    padding: 0;

    border: 1px solid rgba(70,160,255,.45);
    border-radius: 0;

    background: rgba(12,28,58,.75);

    color: #dff4ff;
    font-size: 13px;
    font-weight: 700;

    text-shadow: none;

    box-shadow:
        0 0 8px rgba(40,120,255,.18);

    cursor: pointer;
    transition: .2s ease;
}

.news-page-btn:hover {
    border-color: rgba(120,210,255,.8);

    background: rgba(22,55,110,.85);

    color: #ffffff;

    box-shadow:
        0 0 14px rgba(70,170,255,.45);
}

.news-page-btn.active {
    border-color: rgba(120,220,255,.9);

    background: linear-gradient(
        180deg,
        #3ba9ff 0%,
        #1d7ae5 50%,
        #0b4fa8 100%
    );

    color: #ffffff;

    box-shadow:
        0 0 18px rgba(80,190,255,.55);
}

/* Responsive */
@media (max-width: 1250px) {
    .news-section {
        width: 95%;
    }

    .news-content {
        grid-template-columns: repeat(2, 380px);
    }
}

@media (max-width: 850px) {
    .news-tabs {
        flex-wrap: wrap;
    }

    .news-content {
        grid-template-columns: 1fr;
    }

    .news-card {
        width: 100%;
        height: 282px;
    }

    .news-card img {
        width: 100%;
        height: 228px;
    }
}
