﻿@charset "utf-8";

/* ==========================================================
   ESG / News
   只放最新消息專用樣式。
   Header、Title、次選單、Footer、主 RWD 由 ESG 共用 CSS 負責。
   ========================================================== */

.news-page {
    width: 95%;
    margin: 0 auto;
}

/* ==========================================================
   News Index
   ========================================================== */

.news-toolbar {
    display: flex;
    margin-bottom: 18px;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.news-toolbar-title {
    display: flex;
    align-items: center;
    gap: 7px;
    white-space: nowrap;
}

    .news-toolbar-title img {
        width: 18px;
        height: 18px;
    }

/* ---------- 搜尋 ---------- */

.news-search {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 6px;
    flex-wrap: wrap;
}

.news-search-label {
    color: #666;
    font-size: 13px;
}

.news-search-year {
    width: 88px;
    height: 30px;
    box-sizing: border-box;
}

.news-search-keyword {
    width: 180px;
    height: 30px;
    padding: 3px 7px;
    box-sizing: border-box;
}

.news-search-button {
    height: 30px;
    padding: 0 14px;
    border: 1px solid #2e3289;
    border-radius: 3px;
    background: #2e3289;
    color: #fff;
    cursor: pointer;
    font-family: "微軟正黑體", Arial, Helvetica, sans-serif;
    font-size: 13px;
}

    .news-search-button:hover,
    .news-search-button:focus {
        border-color: #636bda;
        background: #636bda;
        outline: 0;
    }

/* ---------- 列表 ---------- */

.news-list-wrap {
    width: 100%;
    overflow: hidden;
}

.news-list-table {
    width: 100%;
    border-collapse: separate;
    border-spacing: 0;
    table-layout: fixed;
    border-bottom: 2px solid #adcfef;
    background: #fff;
}

    .news-list-table thead th {
        height: 36px;
        padding: 7px 10px;
        border-top: 1px solid #c2dbef;
        border-right: 1px solid rgba(255, 255, 255, .75);
        border-bottom: 1px solid #9fbdd8;
        background-color: #dceefa;
        background-image: linear-gradient( to bottom, #f7fbff 0%, #edf7fd 30%, #dceefa 65%, #c7e1f1 100% );
        color: #2e3289;
        font-size: 13px;
        font-weight: bold;
        line-height: 22px;
        text-align: center;
        box-shadow: inset 0 1px 0 rgba(255, 255, 255, .95), 0 2px 2px rgba(0, 0, 0, .15);
    }

        .news-list-table thead th:first-child {
            border-left: 1px solid #c2dbef;
            border-radius: 7px 0 0 7px;
        }

        .news-list-table thead th:last-child {
            border-right: 1px solid #c2dbef;
            border-radius: 0 7px 7px 0;
        }

.news-col-no {
    width: 90px;
}

.news-col-date {
    width: 130px;
}

.news-col-title {
    width: auto;
}

.news-list-table tbody td {
    padding: 10px;
    border-bottom: 1px dotted #d0d0d0;
    background: #fff;
    color: #555;
    font-size: 13px;
    line-height: 1.6;
    vertical-align: middle;
}

.news-list-table tbody tr:last-child td {
    border-bottom: 0;
}

.news-list-table tbody tr:hover td {
    background: #f7fbff;
}

.news-list-no,
.news-list-date {
    text-align: center;
}

.news-list-date {
    color: #636bda;
    white-space: nowrap;
}

.news-list-title {
    text-align: left;
    overflow-wrap: break-word;
}

    .news-list-title a,
    .news-list-title a:link,
    .news-list-title a:visited {
        color: #222;
        text-decoration: none;
    }

        .news-list-title a:hover,
        .news-list-title a:focus {
            color: #636bda;
            text-decoration: underline;
        }

.news-new {
    margin-left: 6px;
    vertical-align: middle;
}

.news-empty {
    padding: 28px 10px !important;
    color: #777;
    text-align: center;
}

.news-pager {
    margin-top: 15px;
    text-align: center;
}

    .news-pager table {
        max-width: 100%;
    }

/* ==========================================================
   News Detail
   ========================================================== */

.news-detail-header {
    margin-bottom: 12px;
    padding: 0 0 12px;
    border-bottom: 1px solid #d9e0e8;
    background: none;
}

.news-detail-title {
    margin: 0 0 8px;
    padding-left: 0;
    border-left: 0;
    color: #2e3289 !important;
    font-size: 21px !important;
    font-weight: bold;
    line-height: 1.55;
    letter-spacing: 0;
}

.news-detail-meta {
    display: flex;
    align-items: center;
    gap: 6px;
    flex-wrap: wrap;
    padding-left: 16px;
    color: #d97800;
    font-size: 12px;
    line-height: 1.7;
}

.news-detail-meta-separator {
    color: #ccc;
}

.news-detail-line {
    height: 1px;
    margin: 10px 0 14px;
}

.news-detail-content {
    width: 100%;
    min-height: 32px;
    padding: 4px 2px 2px;
    color: #444;
    font-size: 14px;
    line-height: 1.9;
    overflow-wrap: break-word;
}

    .news-detail-content p {
        margin: 0 0 8px;
    }

    .news-detail-content img {
        max-width: 100%;
        height: auto;
    }

    .news-detail-content table {
        max-width: 100%;
    }

.news-related-row {
    display: flex;
    margin-top: 20px;
    align-items: flex-start;
    gap: 6px;
    line-height: 20px;
    overflow-wrap: anywhere;
}

    .news-related-row img {
        margin-top: 3px;
        flex: 0 0 auto;
    }

    .news-related-row a {
        overflow-wrap: anywhere;
    }







.news-back {
    margin-top: 34px;
    padding-top: 4px;
    text-align: center;
}

/* ==========================================================
   RWD
   ========================================================== */

@media screen and (max-width: 768px) {
    .news-page {
        width: 100%;
        margin: 0;
    }

    .news-toolbar {
        display: block;
    }

    .news-toolbar-title {
        margin-bottom: 12px;
    }

    .news-search {
        width: 100%;
        justify-content: flex-start;
    }

    .news-search-keyword {
        width: min(220px, 45vw);
    }

    .news-list-table {
        width: 100% !important;
        table-layout: fixed;
    }

        .news-list-table thead th {
            height: 34px;
            padding: 6px 5px;
            font-size: 12px;
        }

        .news-list-table tbody td {
            padding: 8px 5px;
            font-size: 12px;
        }

    .news-col-no {
        width: 52px;
    }

    .news-col-date {
        width: 105px;
    }

    .news-list-title {
        overflow-wrap: anywhere;
        word-break: break-word;
    }

    .news-detail-title {
        font-size: 19px !important;
        padding-left: 0;
        border-left: 0;
    }

    .news-detail-meta {
        padding-left: 13px;
    }

    .news-detail-meta {
        display: block;
    }

    .news-detail-meta-separator {
        display: none;
    }

    .news-detail-meta > span {
        display: block;
    }

    .news-related-row {
        width: 100%;
        flex-wrap: wrap;
    }
}

@media screen and (max-width: 500px) {
    .news-toolbar-title {
        margin-bottom: 10px;
    }

    .news-search {
        display: grid;
        grid-template-columns: 52px minmax(0, 1fr);
        gap: 8px;
    }

    .news-search-year,
    .news-search-keyword {
        width: 100%;
        max-width: none;
    }

    .news-search-button {
        grid-column: 2;
        width: 90px;
    }

    .news-list-table thead th {
        height: 32px;
        padding: 5px 3px;
        font-size: 11px;
    }

    .news-list-table tbody td {
        padding: 7px 3px;
        font-size: 11px;
        line-height: 1.45;
    }

    .news-col-no {
        width: 40px;
    }

    .news-col-date {
        width: 86px;
    }

    .news-list-date {
        white-space: normal;
        line-height: 1.35;
    }

    .news-detail-title {
        font-size: 18px !important;
        padding-left: 9px;
        border-left-width: 3px;
        line-height: 1.5;
    }

    .news-detail-meta {
        padding-left: 12px;
    }

    .news-detail-content {
        font-size: 13px;
        line-height: 1.75;
    }

    .news-related-row {
        font-size: 12px;
    }

    .news-back {
        margin-top: 22px;
    }
}
