/* T151 (client revision 2026-11-15). Loaded after t149-polish.css. Classes t151-* are added by t151-polish.js. */

/* ---------- section titles: one icon, always visible ---------- */
html body .page_main .t151-head.t151-head {
    display: flex !important;
    align-items: center !important;
    gap: .45em !important;
}
html body .page_main .t151-head.t151-head--center { justify-content: center !important; }
html body .page_main .t151-head > i.t151-hicon.t151-hicon {
    flex: 0 0 auto;
    width: auto !important;
    height: auto !important;
    margin: 0 !important;
    position: static !important;
    font-size: 1.1em;
    line-height: 1 !important;
    color: var(--t149-accent, #0f75bb) !important;
    visibility: visible !important;
    opacity: 1 !important;
}
html body .page_main .t151-head.t149-head--sec > i.t151-hicon.t151-hicon { font-size: 24px; }
html body .page_main .t151-head.t149-head--sub > i.t151-hicon.t151-hicon { font-size: 20px; }
html body .page_main .t151-head.t149-head--negative > i.t151-hicon.t151-hicon { color: #c0504d !important; }
html body .page_main .t151-head.t149-head--positive > i.t151-hicon.t151-hicon { color: #2e8b6e !important; }
/* Titles whose icon used to be drawn by the page style (社會共融 chapter): the drawn icon is replaced. */
html body .page_main .t151-no-before.t151-no-before::before,
html body[class] .page_main [data-report-module] :is(h2, h3, h4, h5).t151-no-before.t151-no-before.t151-no-before.t151-no-before.t151-no-before::before,
html body[class] .page_main [data-report-module] .t151-no-before.t151-no-before.t151-no-before.t151-no-before.t151-no-before.t151-no-before::before { content: none !important; display: none !important; }

/* ---------- number cards and process steps ---------- */
html body .page_main .report-kpi__icon-wrap > i.t151-kicon {
    display: inline-block !important;
    width: auto !important;
    height: auto !important;
    font-size: 25px;
    line-height: 1;
}
html body .page_main .report-kpi__pillar-header > i.t151-picon {
    display: inline-block !important;
    width: auto !important;
    height: auto !important;
    font-size: 38px;
    line-height: 1;
}
html body .page_main .report-flow__icon > i.t151-ficon {
    display: inline-block !important;
    font-size: 26px;
    line-height: 1;
    color: inherit;
}
/* Units and counts stay with their number ("(NT$ thousand)", "16 cases"). */
html body .page_main .t151-nowrap { white-space: nowrap; }
/* Figures sit at the bottom of the label area so a row of cards lines up (label heights are set by JS). */
html body .page_main .report-kpi__item .report-kpi__content > h4,
html body .page_main .ppt-editorial__block--metric > h4 { box-sizing: border-box; }

/* ---------- main menu: the chapter of the current page ---------- */
body > header .menu .menu_item.t151-current > .menu_btn,
.menu .menu_item.t151-current > .menu_btn {
    position: relative;
    color: #0f75bb !important;
    font-weight: 700;
    background: #e6f1f9;
    border-radius: 6px;
    padding: 5px 10px 9px !important;
    margin: -5px -10px 0;
}
.menu .menu_item.t151-current > .menu_btn::after {
    position: absolute;
    content: "";
    left: 10px;
    right: 10px;
    bottom: 0;
    height: 3px;
    border-radius: 2px;
    background-color: #0086d1;
}
@media (max-width: 1199.98px) {
    .menu .menu_item.t151-current > .menu_btn { margin: 0; padding: 10px 12px !important; }
    .menu .menu_item.t151-current > .menu_btn::after { left: 0; right: auto; top: 8px; bottom: 8px; width: 3px; height: auto; }
}

/* ---------- diagram icons replaced in page order (風險管理組織架構 etc.) ---------- */
html body .page_main i.t151-oicon { display: inline-block !important; line-height: 1; width: auto !important; height: auto !important; }

/* ---------- energy / water / waste tables: real tables on phones and small laptops (client 2026-11-17) ---------- */
@media (max-width: 1199.98px) {
    html body .page_main :is(.energy-register, .waste-register) .energy-register__mobile,
    html body .page_main :is(.energy-register, .waste-register) .waste-register__mobile { display: none !important; }
    html body .page_main :is(.energy-register, .waste-register) table:is(.energy-register__table, .waste-register__table) {
        display: block !important;
        width: 100%;
        max-width: 100%;
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        overscroll-behavior-x: contain;
    }
    html body .page_main table:is(.energy-register__table, .waste-register__table) .t151-col1 {
        position: sticky;
        left: 0;
        z-index: 2;
        background: #fff;
        box-shadow: 5px 0 7px -5px rgb(31 50 59 / 32%);
    }
    html body .page_main table:is(.energy-register__table, .waste-register__table) thead .t151-col1 { z-index: 3; background: var(--table-v2-header-bg, #eef4ea); }
    html body .page_main table:is(.energy-register__table, .waste-register__table) .t151-short { white-space: nowrap; }
    html body .page_main table:is(.energy-register__table, .waste-register__table) .t151-long { min-width: 12em; }
    /* Labels spanning the whole row ("一般廢棄物") are centred in the visible part of the table, not in the full scroll width. */
    html body .page_main table:is(.energy-register__table, .waste-register__table) .t151-span-label {
        position: sticky;
        left: 8px;
        display: block;
        width: min(100%, calc(100vw - 64px));
        text-align: center;
    }
}
@media (max-width: 767.98px) {
    html body .page_main table:is(.energy-register__table, .waste-register__table) { font-size: 14px !important; line-height: 1.5; }
    html body .page_main table:is(.energy-register__table, .waste-register__table) :is(th, td) { padding: 9px 8px !important; }
    html body .page_main table:is(.energy-register__table, .waste-register__table) thead th { font-size: 13px !important; line-height: 1.4; }
    html body .page_main table:is(.energy-register__table, .waste-register__table) .t151-col1 { min-width: 7em; max-width: 40vw; overflow-wrap: normal; word-break: normal; }
    html body .page_main table:is(.energy-register__table, .waste-register__table) :is(th, td) { overflow-wrap: normal; word-break: normal; }
}

/* ---------- climate risk / opportunity matrices: chart kept on phones (client 2026-11-17) ---------- */
html body .page_main .t151-matrix-scroll { width: 100%; max-width: 100%; }
@media (max-width: 767.98px) {
    html body .page_main .t151-matrix-scroll {
        overflow-x: auto;
        -webkit-overflow-scrolling: touch;
        overscroll-behavior-x: contain;
        margin-bottom: 8px;
    }
    html body .page_main .t151-matrix-scroll > svg.climate-assessment__diagram.climate-assessment__diagram {
        display: block !important;
        width: 900px !important;
        max-width: none !important;
        height: auto !important;
    }
}
