/*
Theme Name: BlankSlate News
Theme URI: https://opencollective.com/blankslate
Author: Web Guy
Author URI: https://opencollective.com/blankslate#section-contributors
Description: BlankSlate customized as a clean and responsive financial news portal starter.
Tags: accessibility-ready, custom-menu, featured-images, translation-ready
Version: 2026.2
Requires at least: 5.2
Tested up to: 6.8
Requires PHP: 7.4
License: GNU General Public License v3 or Later
License URI: https://www.gnu.org/licenses/gpl.html
Text Domain: blankslate
*/

:root {
	--bg: #ffffff;
	--surface: #ffffff;
	--text: #0f172a;
	--muted: #64748b;
	--line: #e2e8f0;
	--dark: #08111f;
	--dark-soft: #0f1b2b;
	--green: #0ea55f;
	--green-dark: #0b8a4f;
	--radius: 16px;
	--radius-sm: 12px;
	--shadow: 0 4px 14px rgba(8, 17, 31, 0.06);
}

* {
	box-sizing: border-box;
}

html,
body {
	margin: 0;
	padding: 0;
	background: var(--bg);
	color: var(--text);
	font-family: "Inter", "Segoe UI", Arial, sans-serif;
	overflow-y: auto !important;
	overflow-x: hidden;
}

a {
	color: inherit;
	text-decoration: none;
}

img {
	display: block;
	max-width: 100%;
	height: auto;
}

.site-shell {
	max-width: 1360px;
	margin: 0 auto;
	padding: 0 16px 20px;
}

.site-header {
	background: linear-gradient(180deg, #0a1728 0%, #091321 100%);
	border-radius: 0;
	box-shadow: 0 4px 12px rgba(7, 17, 32, 0.2);
	overflow: hidden;
	position: relative;
	z-index: 20;
}

.header-main {
	display: flex;
	align-items: center;
	justify-content: space-between;
	gap: 18px;
	padding: 12px 18px;
}

.brand-wrap {
	display: flex;
	align-items: center;
	min-height: 64px;
}

.brand-wrap .custom-logo-link {
	display: inline-block;
}

.brand-wrap .custom-logo {
	max-height: 68px;
	width: auto;
}

.site-title {
	margin: 0;
	font-size: 1.7rem;
	font-weight: 800;
	color: #fff;
}

.site-description {
	margin: 4px 0 0;
	color: #9fb0c2;
}

.header-actions {
	display: flex;
	align-items: center;
	gap: 12px;
}

.mobile-menu-toggle {
	display: none;
	width: 42px;
	height: 42px;
	border: 1px solid rgba(255, 255, 255, 0.22);
	background: rgba(255, 255, 255, 0.04);
	border-radius: 10px;
	padding: 0;
	align-items: center;
	justify-content: center;
	flex-direction: column;
	gap: 5px;
	cursor: pointer;
}

.mobile-menu-toggle span {
	display: block;
	width: 19px;
	height: 2px;
	background: #ffffff;
	border-radius: 999px;
	transition: transform 0.2s ease, opacity 0.2s ease;
}

.site-header.menu-open .mobile-menu-toggle span:nth-child(1) {
	transform: translateY(7px) rotate(45deg);
}

.site-header.menu-open .mobile-menu-toggle span:nth-child(2) {
	opacity: 0;
}

.site-header.menu-open .mobile-menu-toggle span:nth-child(3) {
	transform: translateY(-7px) rotate(-45deg);
}

.header-search {
	display: flex;
	align-items: center;
	border: 1px solid rgba(255, 255, 255, 0.16);
	background: rgba(255, 255, 255, 0.02);
	border-radius: 999px;
	padding: 0 8px 0 10px;
	min-height: 38px;
}

.header-search input[type="search"] {
	width: 0;
	opacity: 0;
	border: 0;
	background: transparent;
	color: #e2e8f0;
	padding: 0;
	font-size: 0.9rem;
	transition: width 0.2s ease, opacity 0.2s ease;
}

.header-search input[type="search"]::placeholder {
	color: #9fb0c2;
}

.header-search:focus-within input[type="search"] {
	width: 180px;
	opacity: 1;
	padding-right: 8px;
}

.header-search:hover input[type="search"] {
	width: 180px;
	opacity: 1;
	padding-right: 8px;
}

.header-search button {
	background: transparent;
	border: 0;
	padding: 0;
	width: 22px;
	height: 22px;
	display: inline-flex;
	align-items: center;
	justify-content: center;
	cursor: pointer;
}

.header-search button svg {
	width: 19px;
	height: 19px;
	fill: #ffffff;
}

.newsletter-cta {
	background: linear-gradient(180deg, #11bf6a 0%, var(--green-dark) 100%);
	color: #fff;
	font-weight: 800;
	padding: 9px 14px;
	border-radius: 999px;
	white-space: nowrap;
	font-size: 0.9rem;
	display: inline-flex;
	align-items: center;
	gap: 8px;
	min-height: 38px;
}

.newsletter-cta svg {
	width: 16px;
	height: 16px;
	fill: #ffffff;
}

.newsletter-cta:hover {
	filter: brightness(1.08);
}

.main-nav {
	border-top: 1px solid rgba(255, 255, 255, 0.08);
	padding: 0 18px;
}

.main-nav ul {
	display: flex;
	list-style: none;
	gap: 6px;
	margin: 0;
	padding: 7px 0;
	flex-wrap: wrap;
}

.main-nav li a {
	display: inline-block;
	color: #e2e8f0;
	font-weight: 700;
	padding: 10px 10px;
	border-radius: 10px;
	font-size: 0.94rem;
	letter-spacing: 0.01em;
}

.main-nav li.current-menu-item a,
.main-nav li a:hover {
	background: rgba(14, 165, 95, 0.2);
	color: #fff;
}

.main-nav .menu-item-home.current-menu-item a {
	color: #12c071;
	background: transparent;
}

.site-content {
	margin-top: 18px;
}

.hero-news-grid {
	display: grid;
	grid-template-columns: minmax(0, 1.55fr) minmax(275px, 1fr) minmax(300px, 0.9fr);
	gap: 12px;
	align-items: stretch;
}

.hero-main-card,
.hero-side-card,
.highlights-box,
.newsletter-box,
.latest-news-section {
	background: var(--surface);
	border: 1px solid var(--line);
	border-radius: 10px;
	box-shadow: var(--shadow);
	overflow: hidden;
}

.hero-main-card {
	position: relative;
	min-height: 100%;
}

.hero-main-image img {
	width: 100%;
	height: 100%;
	min-height: 410px;
	object-fit: cover;
}

.hero-main-content {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	padding: 18px 20px;
	color: #fff;
	background: linear-gradient(180deg, rgba(7, 10, 18, 0) 0%, rgba(7, 10, 18, 0.95) 85%);
}

.hero-main-content h2 {
	margin: 8px 0;
	font-size: clamp(1.8rem, 2.4vw, 3rem);
	line-height: 1.08;
	font-weight: 800;
}

.hero-main-content p {
	margin: 0;
	color: rgba(255, 255, 255, 0.92);
	line-height: 1.42;
	font-size: 1.08rem;
}

.hero-side-stack {
	display: flex;
	flex-direction: column;
	gap: 12px;
}

.hero-side-card {
	position: relative;
	flex: 1;
}

.hero-side-image img {
	width: 100%;
	height: 100%;
	min-height: 198px;
	object-fit: cover;
}

.hero-side-content {
	position: absolute;
	left: 0;
	right: 0;
	bottom: 0;
	padding: 14px;
	color: #fff;
	background: linear-gradient(180deg, rgba(7, 10, 18, 0) 0%, rgba(7, 10, 18, 0.95) 88%);
}

.hero-side-content h3 {
	margin: 8px 0;
	font-size: 1.85rem;
	line-height: 1.12;
	font-weight: 800;
}

.home-sidebar {
	display: flex;
	flex-direction: column;
	gap: 14px;
}

.badge {
	display: inline-block;
	margin: 0;
	padding: 5px 10px;
	border-radius: 999px;
	background: rgba(14, 165, 95, 0.2);
	color: #d1fae5;
	font-weight: 700;
	font-size: 0.7rem;
	text-transform: uppercase;
	letter-spacing: 0.04em;
}

.meta-line {
	margin-top: 10px;
	display: flex;
	gap: 16px;
	font-size: 0.82rem;
	color: rgba(255, 255, 255, 0.85);
}

.meta-line span + span {
	position: relative;
}

.meta-line span + span::before {
	content: "";
	position: absolute;
	left: -9px;
	top: 50%;
	width: 4px;
	height: 4px;
	transform: translateY(-50%);
	border-radius: 50%;
	background: currentColor;
	opacity: 0.7;
}

.highlights-box {
	padding: 14px 16px;
}

.highlights-box h2 {
	margin: 0 0 8px;
	font-size: 1.85rem;
	text-transform: uppercase;
	letter-spacing: -0.01em;
}

.highlights-box ol {
	list-style: none;
	margin: 0;
	padding: 0;
}

.highlights-box li {
	display: grid;
	grid-template-columns: 34px 1fr;
	gap: 10px;
	padding: 13px 0;
	border-top: 1px solid var(--line);
}

.highlights-box li:first-child {
	border-top: 0;
}

.highlight-index {
	font-size: 1.75rem;
	font-weight: 800;
	color: var(--green);
	line-height: 1;
}

.highlights-box a {
	display: block;
	font-weight: 800;
	line-height: 1.28;
}

.highlights-box small {
	display: block;
	margin-top: 6px;
	color: var(--muted);
	font-size: 0.82rem;
	text-transform: lowercase;
}

.newsletter-box {
	background: linear-gradient(180deg, #effdf5 0%, #e8fbf1 100%);
	padding: 14px 16px 16px;
}

.newsletter-box h3 {
	margin: 0;
	font-size: 1.75rem;
	line-height: 1.12;
	text-transform: uppercase;
}

.newsletter-box p {
	color: #3f4b5b;
	margin: 8px 0 12px;
	font-size: 0.98rem;
}

.newsletter-box form {
	display: flex;
	flex-direction: column;
	gap: 10px;
}

.newsletter-box input {
	border: 1px solid #d2f3e2;
	background: #fff;
	border-radius: 10px;
	padding: 12px;
}

.newsletter-box button {
	border: none;
	border-radius: 10px;
	background: var(--green);
	color: #fff;
	font-weight: 800;
	padding: 12px;
	cursor: pointer;
}

.latest-news-section {
	margin-top: 18px;
	padding: 10px 0;
	border: 0;
	background: transparent;
	box-shadow: none;
}

.section-header {
	display: flex;
	justify-content: space-between;
	align-items: center;
	gap: 12px;
}

.section-header h2 {
	margin: 0;
	font-size: 2.15rem;
	text-transform: uppercase;
	letter-spacing: -0.01em;
	display: inline-flex;
	align-items: center;
	gap: 10px;
}

.section-header h2::before {
	content: "";
	width: 14px;
	height: 14px;
	background: linear-gradient(180deg, #14c56f 0%, #0b8a4f 100%);
	clip-path: polygon(45% 0, 100% 0, 60% 46%, 100% 46%, 20% 100%, 40% 54%, 0 54%);
}

.section-header a {
	color: var(--green-dark);
	font-weight: 800;
	font-size: 1.08rem;
}

.quick-filters {
	margin: 10px 0 12px;
	display: flex;
	flex-wrap: wrap;
	gap: 8px;
}

.quick-filters a {
	display: inline-block;
	border: 1px solid var(--line);
	background: #f8fafc;
	border-radius: 999px;
	padding: 5px 12px;
	font-size: 0.82rem;
	font-weight: 700;
}

.quick-filters a.active,
.quick-filters a:hover {
	background: #dff7eb;
	border-color: #bae7d1;
	color: #0b8a4f;
}

.latest-news-list {
	display: flex;
	flex-direction: column;
}

.latest-news-item {
	display: grid;
	grid-template-columns: 162px 1fr;
	gap: 14px;
	padding: 12px 0;
	border-top: 1px solid var(--line);
}

.latest-news-item:first-child {
	border-top: 0;
	padding-top: 4px;
}

.latest-thumb img {
	width: 100%;
	height: 96px;
	object-fit: cover;
	border-radius: 8px;
}

.latest-head {
	display: flex;
	gap: 10px;
	justify-content: space-between;
	align-items: center;
}

.latest-head h3 {
	margin: 0;
	font-size: 2rem;
	line-height: 1.06;
	font-weight: 800;
}

.latest-content p {
	margin: 6px 0;
	color: #475569;
	font-size: 1.08rem;
	line-height: 1.4;
}

.latest-content .meta-line {
	margin-top: 0;
	color: var(--muted);
	font-size: 0.85rem;
}

.tag-pill {
	background: #ecfdf3;
	color: #0b8a4f;
	border-radius: 999px;
	padding: 5px 10px;
	font-size: 0.72rem;
	font-weight: 700;
	white-space: nowrap;
	text-transform: uppercase;
	letter-spacing: 0.02em;
}

.archive-grid {
	display: grid;
	grid-template-columns: repeat(3, minmax(0, 1fr));
	gap: 14px;
}

.news-card {
	background: var(--surface);
	border: 1px solid var(--line);
	border-radius: var(--radius);
	box-shadow: var(--shadow);
	overflow: hidden;
}

.news-card-media img {
	width: 100%;
	aspect-ratio: 16 / 9;
	object-fit: cover;
}

.news-card-content {
	padding: 14px;
}

.entry-title {
	margin: 0 0 8px;
	font-size: 1.2rem;
	line-height: 1.3;
}

.entry-meta {
	display: flex;
	gap: 8px;
	color: var(--muted);
	font-size: 0.82rem;
}

.site-footer {
	margin-top: 24px;
	border-radius: 0;
	overflow: hidden;
	background: linear-gradient(180deg, #0b1726 0%, #060d18 100%);
	color: #d9e3ef;
}

.footer-grid {
	display: grid;
	grid-template-columns: 1.1fr 1fr 1fr;
	gap: 28px;
	padding: 26px 24px;
}

.footer-brand .custom-logo {
	max-height: 58px;
	width: auto;
	margin-bottom: 10px;
}

.footer-title {
	font-size: 1.2rem;
	font-weight: 800;
	margin: 0;
}

.footer-column h3 {
	margin: 0 0 10px;
	font-size: 1rem;
	color: #ffffff;
}

.footer-column ul {
	list-style: none;
	padding: 0;
	margin: 0;
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.footer-column li a {
	color: #a8bbcf;
	font-size: 0.95rem;
}

.footer-column li a:hover {
	color: #fff;
}

.footer-bottom {
	padding: 12px 24px;
	border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.footer-bottom p {
	margin: 0;
	font-size: 0.9rem;
	color: #a8bbcf;
}

.screen-reader-text {
	position: absolute !important;
	width: 1px;
	height: 1px;
	padding: 0;
	margin: -1px;
	overflow: hidden;
	clip: rect(0, 0, 0, 0);
	white-space: nowrap;
	border: 0;
}

body.single .site-content,
body.page .site-content {
	max-width: 980px;
	margin: 18px auto 0;
}

body.single .news-card,
body.page .news-card {
	border: 0;
	box-shadow: none;
	background: transparent;
}

body.single .news-card-content,
body.page .news-card-content {
	background: #fff;
	border: 1px solid var(--line);
	border-radius: 14px;
	padding: 24px;
}

body.single .entry-title,
body.page .entry-title {
	font-size: clamp(1.8rem, 2.8vw, 2.7rem);
	line-height: 1.1;
	margin-bottom: 12px;
}

body.single .entry-content > a,
body.page .entry-content > a {
	display: block;
	margin: 16px 0;
}

body.single .entry-content img,
body.page .entry-content img {
	border-radius: 12px;
	width: 100%;
	height: auto;
}

body.single .entry-content p,
body.page .entry-content p {
	font-size: 1.08rem;
	line-height: 1.75;
	color: #1e293b;
}

.search-results-section {
	max-width: 1040px;
	margin: 0 auto;
}

.search-results-header {
	padding: 6px 2px 14px;
	border-bottom: 2px solid var(--line);
	margin-bottom: 6px;
}

.search-results-header h1 {
	margin: 0;
	font-size: clamp(1.5rem, 2.5vw, 2.2rem);
	line-height: 1.15;
}

.search-results-header p {
	margin: 8px 0 0;
	color: var(--muted);
	font-size: 0.95rem;
}

.search-results-list {
	display: flex;
	flex-direction: column;
}

.search-result-item {
	display: grid;
	grid-template-columns: 220px 1fr;
	gap: 16px;
	padding: 16px 0;
	border-bottom: 1px solid var(--line);
	margin: 0;
}

.search-result-thumb {
	display: block;
	border-radius: 10px;
	overflow: hidden;
	background: #f1f5f9;
}

.search-result-thumb img {
	width: 100%;
	height: 132px;
	object-fit: cover;
}

.search-result-thumb-fallback {
	display: grid;
	place-items: center;
	width: 100%;
	height: 132px;
	font-size: 0.85rem;
	color: #64748b;
	background: #e2e8f0;
	font-weight: 700;
}

.search-result-content h2 {
	margin: 0 0 8px;
	font-size: clamp(1.2rem, 2vw, 1.6rem);
	line-height: 1.2;
	font-weight: 800;
}

.search-result-content .entry-meta {
	margin-bottom: 10px;
}

.search-result-content p {
	margin: 0;
	color: #334155;
	line-height: 1.55;
}

.search-read-more {
	display: inline-flex;
	margin-top: 10px;
	font-weight: 700;
	color: var(--green-dark);
}

.search-no-results {
	background: #fff;
	border: 1px solid var(--line);
	border-radius: 12px;
	padding: 18px;
	margin-top: 14px;
}

.search-no-results h2 {
	margin: 0 0 6px;
	font-size: 1.4rem;
}

.search-no-results p {
	margin: 0 0 14px;
	color: var(--muted);
}

@media (max-width: 1220px) {
	.hero-news-grid {
		grid-template-columns: 1.45fr 1fr;
	}

	.home-sidebar {
		grid-column: 1 / -1;
		flex-direction: row;
	}

	.home-sidebar > * {
		flex: 1;
	}
}

@media (max-width: 920px) {
	.header-main {
		flex-wrap: wrap;
	}

	.mobile-menu-toggle {
		display: inline-flex;
	}

	.header-actions {
		display: none;
		width: 100%;
		flex-direction: column;
		align-items: stretch;
		justify-content: flex-start;
		gap: 10px;
		padding-top: 10px;
		border-top: 1px solid rgba(255, 255, 255, 0.1);
	}

	.site-header.menu-open .header-actions {
		display: flex;
	}

	.header-search {
		flex: 1;
	}

	.header-search input[type="search"],
	.header-search:hover input[type="search"],
	.header-search:focus-within input[type="search"] {
		width: 100%;
		opacity: 1;
		padding-right: 8px;
	}

	.main-nav {
		display: none;
		padding: 0 0 12px;
	}

	.site-header.menu-open .main-nav {
		display: block;
	}

	.main-nav ul {
		flex-direction: column;
		gap: 5px;
		padding: 8px 0 0;
	}

	.main-nav li a {
		display: block;
	}

	.site-header.menu-open .newsletter-cta {
		width: 100%;
		justify-content: center;
	}

	.hero-news-grid {
		grid-template-columns: 1fr;
	}

	.hero-side-content h3 {
		font-size: 1.35rem;
	}

	.latest-head h3 {
		font-size: 1.24rem;
		line-height: 1.2;
	}

	.latest-news-item {
		grid-template-columns: 1fr;
	}

	.latest-thumb img {
		height: 190px;
	}

	.footer-grid {
		grid-template-columns: 1fr;
	}

	body.single .site-content,
	body.page .site-content {
		margin-top: 12px;
	}

	.search-result-item {
		grid-template-columns: 1fr;
		gap: 10px;
	}

	.search-result-thumb img,
	.search-result-thumb-fallback {
		height: 190px;
	}
}

@media (max-width: 640px) {
	.site-shell {
		padding: 0 8px 14px;
	}

	.main-nav li a {
		padding: 9px 11px;
		font-size: 0.88rem;
	}

	.newsletter-cta span {
		display: none;
	}

	.hero-main-image img {
		min-height: 330px;
	}

	.hero-main-content h2 {
		font-size: 1.55rem;
	}

	.hero-side-content h3 {
		font-size: 1.2rem;
	}

	.section-header h2 {
		font-size: 1.4rem;
	}

	.latest-head {
		flex-wrap: wrap;
	}

	.latest-head h3 {
		font-size: 1.17rem;
	}

	.latest-content p {
		font-size: 0.95rem;
	}
}
