/*
Theme Name: baidu.tokyo
Theme URI: https://baidu.tokyo/
Author: loveapple
Description: News portal theme for 100°東京 / baidu.tokyo.
Version: 0.1.0
Text Domain: baidu-tokyo
*/

:root {
	--bt-bg: #f3f4f5;
	--bt-surface: #fff;
	--bt-ink: #1e2428;
	--bt-muted: #667078;
	--bt-line: #e2e6e8;
	--bt-brand: #9b1c31;
	--bt-accent: #0f766e;
	--bt-gold: #b9852f;
	--bt-night: #263238;
	--bt-content: min(1120px, calc(100vw - 24px));
}

* {
	box-sizing: border-box;
}

body {
	margin: 0;
	background: var(--bt-bg);
	color: var(--bt-ink);
	font-family: "Hiragino Sans", "Yu Gothic", "Meiryo", system-ui, sans-serif;
	line-height: 1.65;
}

a {
	color: inherit;
	text-decoration: none;
}

img {
	max-width: 100%;
	height: auto;
}

.bt-site-header {
	position: sticky;
	top: 0;
	z-index: 20;
	border-bottom: 1px solid rgba(30, 36, 40, 0.08);
	background: rgba(255, 255, 255, 0.98);
}

.bt-site-header-inner,
.bt-topic-tabs,
.bt-feed-shell,
.bt-article-shell {
	width: var(--bt-content);
	margin-inline: auto;
}

.bt-site-header-inner {
	display: flex;
	align-items: center;
	justify-content: space-between;
	min-height: 50px;
	gap: 16px;
}

.bt-brand {
	display: grid;
	line-height: 1.1;
}

.bt-brand-name {
	font-size: 20px;
	font-weight: 800;
}

.bt-brand-note {
	display: none;
	color: var(--bt-muted);
	font-size: 11px;
}

.bt-search-link {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 32px;
	padding: 0 14px;
	border: 1px solid #dde1e4;
	border-radius: 999px;
	background: #f6f7f8;
	color: var(--bt-muted);
	font-size: 13px;
}

.bt-topic-tabs {
	display: flex;
	gap: 18px;
	overflow-x: auto;
	padding: 0 0 10px;
	scrollbar-width: none;
}

.bt-topic-tabs::-webkit-scrollbar {
	display: none;
}

.bt-topic-tabs a {
	position: relative;
	flex: 0 0 auto;
	padding: 2px 0 8px;
	color: #525c63;
	font-size: 15px;
	white-space: nowrap;
}

.bt-topic-tabs a.active {
	color: var(--bt-brand);
	font-weight: 800;
}

.bt-topic-tabs a.active::after {
	position: absolute;
	right: 12%;
	bottom: 0;
	left: 12%;
	height: 3px;
	border-radius: 999px;
	background: var(--bt-brand);
	content: "";
}

.bt-feed-shell {
	display: grid;
	gap: 14px;
	padding: 10px 0 34px;
}

.bt-feed-shell-list {
	max-width: 760px;
}

.bt-feed-main {
	display: grid;
	gap: 1px;
	overflow: hidden;
	border: 1px solid #e7eaec;
	border-radius: 8px;
	background: #e7eaec;
}

.bt-compact-title,
.bt-feed-card,
.bt-load-marker,
.bt-empty {
	background: var(--bt-surface);
}

.bt-compact-title {
	padding: 14px 12px;
}

.bt-compact-title h1 {
	margin: 0 0 3px;
	font-size: 22px;
	line-height: 1.25;
}

.bt-compact-title p {
	margin: 0;
	color: var(--bt-muted);
	font-size: 13px;
}

.bt-feed-card {
	display: grid;
	grid-template-columns: minmax(0, 1fr) 112px;
	gap: 12px;
	min-height: 112px;
	padding: 12px;
}

.bt-feed-card-feature {
	border-top: 3px solid var(--bt-brand);
}

.bt-feed-card-no-thumb,
.bt-feed-card-three {
	grid-template-columns: 1fr;
}

.bt-feed-text {
	min-width: 0;
}

.bt-feed-badges {
	display: flex;
	flex-wrap: wrap;
	gap: 5px;
	align-items: center;
	margin-bottom: 5px;
	color: #9aa2a8;
	font-size: 12px;
}

.bt-badge {
	display: inline-flex;
	align-items: center;
	min-height: 20px;
	padding: 1px 6px;
	border-radius: 4px;
	background: #eef0f2;
	color: #68727a;
	font-size: 12px;
	font-weight: 700;
}

.bt-badge-review {
	background: #fff1f3;
	color: var(--bt-brand);
}

.bt-badge-news {
	background: #eef5ff;
	color: #2463a6;
}

.bt-badge-brief {
	background: #fff7e6;
	color: #95650f;
}

.bt-badge-full {
	background: #eaf8f4;
	color: var(--bt-accent);
}

.bt-badge-book {
	background: #f4efff;
	color: #6548a3;
}

.bt-badge-story,
.bt-badge-zone {
	background: #f1f3f2;
	color: var(--bt-night);
}

.bt-badge-video {
	background: #fff0ec;
	color: #b24527;
}

.bt-feed-card h1,
.bt-feed-card h2 {
	display: -webkit-box;
	margin: 0;
	overflow: hidden;
	color: #182027;
	font-size: 18px;
	font-weight: 800;
	line-height: 1.36;
	letter-spacing: 0;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 2;
}

.bt-feed-card h1 {
	font-size: 19px;
}

.bt-feed-card p {
	display: -webkit-box;
	margin: 6px 0 0;
	overflow: hidden;
	color: #646f77;
	font-size: 13px;
	-webkit-box-orient: vertical;
	-webkit-line-clamp: 2;
}

.bt-feed-meta {
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
	margin-top: 7px;
	color: #9aa2a8;
	font-size: 12px;
}

.bt-thumb,
.bt-video-thumb {
	position: relative;
	display: grid;
	place-items: center;
	min-height: 84px;
	overflow: hidden;
	border-radius: 6px;
	background: linear-gradient(135deg, var(--bt-brand), #305f72);
	background-position: center;
	background-size: cover;
	color: #fff;
	font-size: 13px;
	font-weight: 800;
	text-align: center;
	aspect-ratio: 4 / 3;
}

.bt-thumb.no-image {
	background: linear-gradient(135deg, var(--bt-night), var(--bt-gold));
}

.bt-thumb-row {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 6px;
	margin-top: 8px;
}

.bt-video-thumb {
	background: linear-gradient(135deg, #111827, var(--bt-gold));
}

.bt-video-thumb .bt-thumb-image {
	position: absolute;
	inset: 0;
	background-position: center;
	background-size: cover;
}

.bt-video-thumb::after {
	position: absolute;
	inset: 0;
	background: rgba(17, 24, 39, 0.35);
	content: "";
}

.bt-play {
	position: relative;
	z-index: 1;
	display: grid;
	place-items: center;
	width: 42px;
	height: 42px;
	border-radius: 50%;
	background: rgba(255, 255, 255, 0.24);
}

.bt-load-marker,
.bt-empty {
	padding: 16px 12px;
	color: var(--bt-muted);
	text-align: center;
}

.bt-load-marker a,
.bt-page-numbers .page-numbers {
	display: inline-flex;
	min-height: 34px;
	align-items: center;
	margin: 2px;
	padding: 0 14px;
	border: 1px solid #dde1e4;
	border-radius: 999px;
	background: #fff;
	color: #34424b;
	font-size: 14px;
	font-weight: 700;
}

.bt-rail {
	display: none;
}

.bt-rail-card {
	display: grid;
	gap: 8px;
	padding: 14px;
	border: 1px solid var(--bt-line);
	border-radius: 8px;
	background: #fff;
}

.bt-rail-card h2 {
	margin: 0 0 4px;
	font-size: 16px;
	line-height: 1.35;
}

.bt-mini-link,
.bt-mini-promo,
.bt-rail-card a {
	color: #3c4850;
	font-size: 14px;
	line-height: 1.45;
}

.bt-article-shell {
	display: grid;
	gap: 18px;
	padding: 18px 0 34px;
}

.bt-article-main {
	min-width: 0;
}

.bt-article-header {
	padding-bottom: 18px;
	border-bottom: 1px solid #ded8cb;
}

.bt-article-title {
	margin: 8px 0 12px;
	font-size: clamp(29px, 8vw, 48px);
	line-height: 1.18;
	letter-spacing: 0;
}

.bt-article-lead {
	margin: 16px 0;
	padding: 16px;
	border-left: 4px solid var(--bt-brand);
	background: #faf8f3;
	color: #343c42;
	font-size: 16px;
	line-height: 1.75;
}

.bt-source-card {
	padding: 16px;
	margin: 20px 0;
	border: 1px solid #ded8cb;
	border-radius: 8px;
	background: #fff;
}

.bt-source-card h2 {
	margin: 0 0 8px;
	font-size: 18px;
	line-height: 1.4;
}

.bt-source-card p,
.bt-article-body {
	color: #253039;
	font-size: 16px;
	line-height: 1.9;
}

.bt-button {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	min-height: 38px;
	padding: 8px 13px;
	border-radius: 999px;
	background: var(--bt-brand);
	color: #fff;
	font-size: 13px;
	font-weight: 700;
}

.bt-article-body h2,
.bt-article-body h3 {
	margin: 30px 0 10px;
	line-height: 1.35;
}

.bt-related-section {
	margin-top: 28px;
}

.bt-related-grid,
.bt-article-sidebar {
	display: grid;
	gap: 10px;
}

.bt-article-sidebar .bt-rail {
	position: static;
	display: grid;
	gap: 12px;
}

.bt-site-footer {
	padding: 28px 0 40px;
	border-top: 1px solid var(--bt-line);
	color: var(--bt-muted);
	font-size: 12px;
	text-align: center;
}

@media (min-width: 720px) {
	:root {
		--bt-content: min(1120px, calc(100vw - 48px));
	}

	.bt-brand-note {
		display: block;
	}

	.bt-feed-shell {
		padding-top: 16px;
	}

	.bt-feed-main {
		gap: 8px;
		border: 0;
		background: transparent;
	}

	.bt-feed-card,
	.bt-compact-title,
	.bt-load-marker,
	.bt-empty {
		border: 1px solid var(--bt-line);
		border-radius: 8px;
	}

	.bt-feed-card h1,
	.bt-feed-card h2 {
		font-size: 20px;
	}

	.bt-feed-card-feature,
	.bt-feed-card-one,
	.bt-feed-card-video {
		grid-template-columns: minmax(0, 1fr) 170px;
	}

	.bt-thumb,
	.bt-video-thumb {
		min-height: 112px;
	}

	.bt-article-shell {
		grid-template-columns: minmax(0, 1fr) 280px;
	}
}

@media (min-width: 1040px) {
	.bt-feed-shell {
		grid-template-columns: 190px minmax(0, 1fr) 280px;
		align-items: start;
	}

	.bt-feed-shell-list {
		grid-template-columns: minmax(0, 760px);
		justify-content: center;
	}

	.bt-rail {
		position: sticky;
		top: 92px;
		display: grid;
		gap: 12px;
	}

	.bt-feed-main {
		gap: 10px;
	}

	.bt-feed-card {
		padding: 14px;
	}

	.bt-feed-card h1 {
		font-size: 22px;
	}

	.bt-article-shell {
		grid-template-columns: minmax(0, 760px) 300px;
	}
}
