@charset "utf-8";
/* /hm/user_content/themes/tirWH1.09/sf-mobile-header.css */
/* Mobile header (<=799px, the theme's mobile breakpoint). Built by js/sf-mobile-header.js from the
   existing top-bar and primary menus; loaded by functions.php on every theme header. Desktop untouched.
   Layout follows the usual news-site pattern (NTD, LTN, CNA, BBC 中文): utility links row, logo bar with one
   CTA + menu icon, text section tabs with an underline, full menu in a drawer. */

/* Hidden on desktop. The theme forces `.header .nav_row .container > div` visible, so match its specificity. */
.sfm-util, .sfm-tabs, .sfm-drawer, .sfm-overlay,
.header .nav_row .container > .sfm-actions { display: none !important; }

@media (max-width: 799px) {
	/* 2026-11-03 CLS: the header is rebuilt by sf-mobile-header.js after load; give it its final height from the
	   first paint so the page below does not jump up 77px when the script runs (measured 137px at 360-799px). */
	header.header:not([data-sfm]) { height: 137px; overflow: hidden; }
	/* 2026-11-05: the script also inserts the 32px utility row ABOVE the logo bar, so before it runs the logo sat 32px
	   higher and jumped down on every load. Reserve that row (same colour) from the first paint. */
	header.header:not([data-sfm]) { border-top: 32px solid #142652; box-sizing: border-box; }
	/* replaced by the rows below */
	.header .navigation-wrap, .header .top_row { display: none !important; }

	/* 1. utility row: same gold links as the desktop top row */
	.sfm-util {
		display: flex !important; align-items: center; height: 32px; padding: 0 12px; background: #142652;
		border-bottom: 1px solid rgba(255,255,255,.12); font-size: 13px; line-height: 32px;
	}
	.sfm-util nav { display: flex; flex: 1; overflow-x: auto; scrollbar-width: none; }
	.sfm-util nav::-webkit-scrollbar { display: none; }
	.sfm-util a { color: #F8C623 !important; font-weight: bold; text-decoration: none; white-space: nowrap; padding-right: 16px; }
	.sfm-util button {
		flex: 0 0 auto; background: none; border: 0; padding: 0 0 0 12px; color: #fff; font-size: 13px;
		line-height: 32px; cursor: pointer; border-left: 1px solid rgba(255,255,255,.25);
	}

	/* 2. logo bar */
	.header .nav_row { display: block; height: auto; line-height: normal; margin: 0; }
	.header .nav_row .container {
		display: flex !important; align-items: center; justify-content: space-between; width: 100%;
		height: 60px; padding: 0 4px 0 12px; box-sizing: border-box;
	}
	.header .ntd_logo { float: none !important; width: auto !important; height: auto !important; margin: 0; }
	.header .ntd_logo a { display: block; line-height: 0; }
	.header .ntd_logo img { width: auto !important; height: 38px !important; max-width: 50vw; }
	.header .nav_row .container > .sfm-actions { display: flex !important; float: none !important; align-items: center; }
	.sfm-sub {
		display: block; background: #F8C623; color: #192f65 !important; font-size: 15px; font-weight: bold;
		line-height: 32px; height: 32px; padding: 0 14px; border-radius: 3px; text-decoration: none; white-space: nowrap;
	}
	.sfm-burger {
		display: flex; flex-direction: column; justify-content: center; align-items: center; gap: 5px;
		width: 48px; height: 48px; margin-left: 4px; padding: 0; background: none; border: 0; cursor: pointer;
	}
	.sfm-burger span { display: block; width: 22px; height: 2px; background: #fff; }

	/* 3. section tabs */
	.sfm-tabs {
		display: flex !important; overflow-x: auto; scrollbar-width: none; -webkit-overflow-scrolling: touch;
		border-top: 1px solid rgba(255,255,255,.12); padding: 0 4px; line-height: normal;
	}
	.sfm-tabs::-webkit-scrollbar { display: none; }
	.sfm-tabs a {
		flex: 0 0 auto; display: block; padding: 11px 10px 9px; color: #fff !important; font-size: 15px;
		text-decoration: none; white-space: nowrap; border-bottom: 3px solid transparent;
	}
	.sfm-tabs a[aria-current] { border-bottom-color: #F8C623; font-weight: bold; }
	/* fade the right edge while more tabs are off-screen (class set by the script) */
	.sfm-tabs.sfm-more { -webkit-mask-image: linear-gradient(to right, #000 calc(100% - 36px), transparent); mask-image: linear-gradient(to right, #000 calc(100% - 36px), transparent); }

	/* 4. drawer */
	.sfm-overlay {
		display: block !important; position: fixed; inset: 0; z-index: 100002; background: rgba(0,0,0,.45);
		opacity: 0; visibility: hidden; transition: opacity .2s, visibility .2s;
	}
	.sfm-drawer {
		display: flex !important; flex-direction: column; position: fixed; top: 0; right: 0; bottom: 0; z-index: 100003;
		width: min(86vw, 360px); background: #fff; box-shadow: -4px 0 20px rgba(0,0,0,.25);
		transform: translateX(100%); visibility: hidden; transition: transform .25s ease, visibility .25s;
		line-height: normal; font-size: 16px;
	}
	html.sfm-open { overflow: hidden; }
	html.sfm-open .sfm-overlay { opacity: 1; visibility: visible; }
	html.sfm-open .sfm-drawer { transform: translateX(0); visibility: visible; }

	.sfm-head { display: flex; align-items: center; justify-content: space-between; background: #192f65; padding: 0 4px 0 16px; height: 60px; }
	.sfm-head img { height: 32px; width: auto; }
	.sfm-close { width: 48px; height: 48px; background: none; border: 0; color: #fff; font-size: 30px; line-height: 1; cursor: pointer; padding: 0; }
	.sfm-date { padding: 10px 16px; font-size: 13px; color: #6b7280; border-bottom: 1px solid #e6e9f0; }
	.sfm-body { flex: 1; overflow-y: auto; -webkit-overflow-scrolling: touch; padding-bottom: 24px; }

	.sfm-menu, .sfm-menu ul { list-style: none; margin: 0; padding: 0; }
	.sfm-menu > li { border-bottom: 1px solid #e6e9f0; }
	.sfm-row { display: flex; align-items: stretch; }
	.sfm-row > a { flex: 1; display: block; padding: 15px 16px; color: #192f65 !important; font-size: 17px; font-weight: bold; text-decoration: none; }
	.sfm-menu .current-menu-item > .sfm-row > a,
	.sfm-menu .current-menu-parent > .sfm-row > a,
	.sfm-menu .current-menu-ancestor > .sfm-row > a { box-shadow: inset 4px 0 0 #F8C623; }
	.sfm-toggle { width: 52px; background: none; border: 0; border-left: 1px solid #eef0f5; cursor: pointer; color: #192f65; font-size: 0; }
	.sfm-toggle::before {
		content: ""; display: inline-block; width: 9px; height: 9px; border-right: 2px solid currentColor;
		border-bottom: 2px solid currentColor; transform: rotate(45deg); margin-top: -4px; transition: transform .2s;
	}
	.sfm-toggle[aria-expanded="true"]::before { transform: rotate(-135deg); margin-top: 4px; }
	.sfm-menu ul { display: none; background: #f5f7fb; padding: 4px 0; }
	.sfm-menu ul.sfm-shown { display: block; }
	.sfm-menu ul a { display: block; padding: 11px 16px 11px 30px; color: #333 !important; font-size: 15px; text-decoration: none; }
	.sfm-menu ul .current-menu-item > a { color: #192f65 !important; font-weight: bold; }

	.sfm-section { padding: 20px 0 0; }
	.sfm-section h2 { font-size: 13px; color: #6b7280; font-weight: normal; margin: 0; padding: 0 16px 6px; }
	.sfm-links { list-style: none; margin: 0; padding: 0; border-top: 1px solid #e6e9f0; }
	.sfm-links li { border-bottom: 1px solid #e6e9f0; }
	.sfm-links a, .sfm-links button {
		display: block; width: 100%; text-align: left; padding: 13px 16px; background: none; border: 0;
		color: #192f65 !important; font-size: 16px; text-decoration: none; cursor: pointer; font-family: inherit;
	}
}

/* 2026-11-04 site search. Desktop: 「搜尋」 button at the right end of the nav row. Phones: magnifier next to 訂報.
   Both open #sf-spanel, a full-width strip under the header with a large field (search.js part of sf-mobile-header.js). */
.sf-spanel { background: #f3f5f9; border-bottom: 1px solid #dfe3ea; }
.sf-spanel[hidden] { display: none !important; }
.sf-spanel-in { display: flex; align-items: center; gap: 16px; max-width: 1000px; margin: 0 auto; padding: 16px 0; box-sizing: border-box; }
.sf-spanel form { display: flex; flex: 1; min-width: 0; margin: 0; }
.sf-spanel input[type=search] {
	flex: 1; min-width: 0; height: 50px; margin: 0; padding: 0 14px; box-sizing: border-box; font-size: 18px; color: #1d2230;
	background: #fff; border: 1px solid #b9c0cc; border-right: 0; border-radius: 4px 0 0 4px; -webkit-appearance: none; appearance: none;
}
.sf-spanel input[type=search]:focus { outline: none; border-color: #192f65; box-shadow: 0 0 0 3px rgba(25, 47, 101, .18); }
.sf-spanel form button { height: 50px; padding: 0 28px; font-size: 18px; font-weight: 700; color: #fff; background: #192f65; border: 1px solid #192f65; border-radius: 0 4px 4px 0; cursor: pointer; }
.sf-spanel form button:hover { background: #10224d; }
.sf-sclose { flex: none; height: 50px; padding: 0 4px; font-size: 16px; color: #3c4250; background: none; border: 0; text-decoration: underline; text-underline-offset: 3px; cursor: pointer; }
.sf-sclose:hover { color: #192f65; }
.sf-spanel button:focus-visible, .sf-sbtn:focus-visible { outline: 3px solid #f8c623; outline-offset: 2px; }
.screen-reader-text { position: absolute !important; width: 1px; height: 1px; overflow: hidden; clip: rect(1px, 1px, 1px, 1px); white-space: nowrap; }

@media (min-width: 800px) {
	.nav_row > .container { position: relative; }
	.navigation .search.sf-sbox { position: absolute; right: 0; top: 2px; transform: none; /* level with the menu text (menu links are 42px tall at the top of the row) */ float: none; margin: 0; padding: 0; display: flex; line-height: 1; }
	.sf-sbox .sf-sbtn {
		display: inline-flex; align-items: center; gap: 8px; height: 38px; padding: 0 14px; cursor: pointer;
		font-size: 16px; font-weight: 700; color: #fff; background: transparent; border: 1px solid rgba(255, 255, 255, .55); border-radius: 4px;
	}
	.sf-sbox .sf-sbtn:hover, .sf-sbox .sf-sbtn[aria-expanded=true] { color: #192f65; background: #fff; border-color: #fff; }
	.sf-sbox .sf-sbtn .fa-search { font-size: 15px; color: inherit; }
	.sfm-sbtn { display: none !important; }
}
@media (max-width: 799px) {
	.sf-sbox { display: none !important; }
	.sfm-sbtn { display: inline-flex; align-items: center; justify-content: center; width: 44px; height: 44px; padding: 0; color: #fff; background: none; border: 0; cursor: pointer; }
	.sfm-sbtn[aria-expanded=true] { color: #f8c623; }
	.sf-spanel-in { padding: 12px 16px; gap: 10px; }
	.sf-spanel input[type=search], .sf-spanel form button { height: 48px; font-size: 17px; }
	.sf-spanel form button { padding: 0 18px; }
	.sf-sclose { height: 48px; font-size: 15px; }
}

/* search panel 類別 select (2026-11-05) — sits flush left of the search box */
.sf-spanel .sf-sc { flex: 0 0 auto; height: 50px; margin: 0; padding: 0 30px 0 12px; font-size: 16px; color: #1d2230; background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8'%3E%3Cpath d='M1 1l5 5 5-5' fill='none' stroke='%23192f65' stroke-width='2'/%3E%3C/svg%3E") no-repeat right 10px center; border: 1px solid #b9c0cc; border-right: 0; border-radius: 4px 0 0 4px; -webkit-appearance: none; appearance: none; cursor: pointer; }
.sf-spanel .sf-sc:focus { outline: none; border-color: #192f65; box-shadow: 0 0 0 3px rgba(25, 47, 101, .18); }
.sf-spanel .sf-sc + input[type=search] { border-radius: 0; }
@media (max-width: 799px) { .sf-spanel .sf-sc { height: 48px; max-width: 92px; padding: 0 24px 0 8px; font-size: 15px; background-position: right 7px center; } }

/* /hm/user_content/themes/tirWH1.09/sf-lists.css */
/* Sidebar rankings (熱帖週排行 / 網站週排行: .ns-list in sidebar-front.php, sidebar-tv.php), 2026-11-05.
   Was: every title bold and coloured, rows touching, the rank number glued to the title ("1.董軍…") — too crowded,
   especially on phones. Now: number in its own column (top 3 red), dark normal-weight title (2 lines max), a divider
   and breathing room per row. Loaded site-wide from functions.php (wp_head). */
.nTab1 .ns-list { margin: 4px 0 0 !important; padding: 0 !important; }
.nTab1 .ns-list .height1 { margin: 0 !important; padding: 0 !important; height: auto !important; }
.nTab1 .ns-list .height1 > li {
	display: block !important; height: auto !important; min-height: 0 !important; margin: 0 !important; padding: 11px 0 !important;
	overflow: visible !important; -webkit-line-clamp: unset !important; border-bottom: 1px solid #eceef2; background: none !important; list-style: none;
}
.nTab1 .ns-list .height1:last-child > li { border-bottom: 0; }
.nTab1 .ns-list li a {
	display: grid !important; grid-template-columns: 26px minmax(0, 1fr); gap: 0 6px; align-items: start;
	font-weight: 500 !important; color: #1d2230 !important; text-decoration: none;
}
.nTab1 .ns-list li a:hover .ns-t { color: #192f65; text-decoration: underline; text-underline-offset: 3px; }
.nTab1 .ns-list .ns-n { font-weight: 700; color: #8c929c; font-variant-numeric: tabular-nums; text-align: left; }
.nTab1 .ns-list .top1 .ns-n, .nTab1 .ns-list .top2 .ns-n, .nTab1 .ns-list .top3 .ns-n { color: #c8102e; }
.nTab1 .ns-list .ns-t { display: -webkit-box; -webkit-box-orient: vertical; -webkit-line-clamp: 2; overflow: hidden; }
@media (max-width: 800px) {
	.nTab1 .ns-list .height1 > li { padding: 13px 0 !important; }
	.nTab1 .ns-list li a, .main .nTab1 .ns-list li a { font-size: 17px !important; line-height: 1.55 !important; grid-template-columns: 30px minmax(0, 1fr); }
}

/* 2026-11-05 phones: the sidebar stacks under the content but kept its 15px desktop gutter (padding-left), so sidebar
   lists sat 30px from the left edge and 15px from the right. Even both sides, and run the 推薦文章 divider across the
   whole row (it was only above the title, not the photo). */
@media (max-width: 800px) {
	.sidebar { padding-left: 0 !important; }
	.more_post .one_post { display: flow-root; margin: 0 0 12px !important; padding: 12px 0 0 !important; border-top: 1px solid #ddd; }
	.more_post .subcat_title + .one_post { padding-top: 4px !important; border-top: 0; }
	.news-single .more_post .one_post .text, .news .more_post .one_post .text { border-top: 0 !important; }
	.more_post + .right-panel { margin-top: 28px; }
	/* 網站月排行: was capped at 350px with a 15% number column, so rows were inset 5px left and 13px right */
	.sidebar .ns-listmon { max-width: none; margin: 10px 0 0 !important; padding: 0 !important; }
	.sidebar .ns-listmon li[class*="top"] .numb { width: 36px; }
	.sidebar .ns-listmon li[class*="top"] .text { width: calc(100% - 36px); padding-left: 6px; }
}

/* 2026-11-05 mobile audit: text under 12px and tap targets under ~32px tall. Hit areas grow with padding offset by
   negative margins, so nothing moves visually. */
footer .copyright { font-size: 13px !important; }
.pri-inline-ad__sponsor { font-size: 12px !important; }
.sfw-fine, .sfw-fine a { font-size: 12.5px !important; }
@media (max-width: 800px) {
	.top_row #menu-topbar-menu > li > a { display: inline-block; padding-top: 6px !important; padding-bottom: 6px !important; margin-top: -6px; margin-bottom: -6px; }
	footer .links li > a, .breadcrumb a, .sf-sec-crumb a { display: inline-block; padding-top: 7px; padding-bottom: 7px; margin-top: -7px; margin-bottom: -7px; }
	.sf-fs-dot { position: relative; }
	.sf-fs-dot::before { content: ""; position: absolute; left: -2px; right: -2px; top: -14px; bottom: -14px; }
}

/* /hm/user_content/themes/tirWH1.09/sf-nav.css */
/* Desktop main menu dropdowns (>=800px), 2026-11-05.
   Before: hovering a section revealed its sub-links as a loose second row of text across the header, anchored to the
   left of the menu (not to the item), and moving the mouse down crossed other sections and swapped the row.
   Now: each section opens its own panel directly under it — white, gold top rule, vertical list, ▾ on sections that
   have sub-links. Opens on hover or keyboard focus; closing waits 0.25 s so the pointer can travel into the panel.
   Phones keep the drawer (sf-mobile-header.css). Loaded from functions.php (wp_head). */
@media (min-width: 800px) {
	/* the city strip below the header has z-index 100000; the open panel must sit above it */
	header.header { z-index: 100001; }
	.header .navigation .menu > li { position: relative; }
	/* room for the ▾ markers (the last item used to run under the 搜尋 button) */
	.header .navigation .menu > li > a { padding-left: 18px !important; padding-right: 18px !important; }
	.header .navigation .menu > li.menu-item-has-children > a::after {
		content: ""; display: inline-block; width: 0; height: 0; margin: 0 0 3px 6px; vertical-align: middle;
		border-style: solid; border-width: 5px 4px 0 4px; border-color: currentColor transparent transparent transparent; opacity: .7;
	}
	.header .navigation .menu > li > ul.sub-menu {
		position: absolute; top: 100%; left: 50%; z-index: 1000; display: block; width: auto; min-width: 168px;
		margin: 0; padding: 8px 0; background: #fff; border-top: 3px solid #f8c623; border-radius: 0;
		box-shadow: 0 10px 28px rgba(16, 24, 48, .18); transform: translate(-50%, 6px);
		visibility: hidden; opacity: 0; pointer-events: none;
		transition: opacity .15s ease, transform .15s ease, visibility 0s linear .25s;
		transition-delay: .25s;   /* closing waits, so the pointer can move into the panel */
	}
	/* invisible bridge over the gap between the section name and its panel */
	.header .navigation .menu > li > ul.sub-menu::before { content: ""; position: absolute; left: 0; right: 0; top: -14px; height: 14px; }
	.header .navigation .menu > li:hover > ul.sub-menu,
	.header .navigation .menu > li:focus-within > ul.sub-menu,
	.header .navigation .menu > li.sfn-open > ul.sub-menu {
		visibility: visible; opacity: 1; pointer-events: auto; transform: translate(-50%, 0);
		transition: opacity .15s ease, transform .15s ease, visibility 0s;
		transition-delay: .06s;
	}
	.header .navigation .menu > li.sfn-closed > ul.sub-menu { visibility: hidden !important; opacity: 0 !important; pointer-events: none !important; }
	.header .navigation .menu > li > ul.sub-menu > li { float: none; display: block; width: auto; margin: 0; padding: 0; border: 0; background: none; }
	.header .navigation .menu > li > ul.sub-menu > li > a {
		display: block; margin: 0; padding: 9px 20px !important; font-size: 16px;   /* !important: an old first-child rule added 25px */ font-weight: 500; line-height: 1.4;
		color: #1d2230 !important; background: none; white-space: nowrap; text-align: left; text-decoration: none; border: 0;
	}
	.header .navigation .menu > li > ul.sub-menu > li > a:hover,
	.header .navigation .menu > li > ul.sub-menu > li > a:focus-visible { color: #192f65 !important; background: #f1f4fa; outline: none; box-shadow: inset 3px 0 0 #192f65; }
	.header .navigation .menu > li > ul.sub-menu > li.current-menu-item > a { color: #192f65 !important; font-weight: 700; }
	@media (prefers-reduced-motion: reduce) { .header .navigation .menu > li > ul.sub-menu { transition: none; transform: translate(-50%, 0); } }
}

/* 2026-11-07: with the old second row of sub-links gone, the menu and 搜尋 sat in the top half of the header band.
   Move them down to the logo's centre line, and nudge the menu right so it sits midway between the logo and 搜尋. */
@media (min-width: 800px) {
	.header .nav_row .navigation-wrap { padding-top: 16px; }
	.header .nav_row .navigation .search.sf-sbox { top: 18px; }   /* sf-mobile-header.css puts it at 2px; same 16px shift */
}
@media (min-width: 800px) and (max-width: 1023px) {
	/* narrower screens: tighter items so 商品推薦 does not run under 搜尋 */
	.header .navigation .menu > li > a { padding-left: 10px !important; padding-right: 10px !important; }
}
@media (min-width: 1024px) {
	.header .nav_row .navigation .menu { margin-left: 21px; }
}

