/* ==========================================================================
   HuffPost-Style Digital News — theme stylesheet
   ========================================================================== */

:root {
	--hp-black: #0d0d0d;
	--hp-gray: #6b6b6b;
	--hp-gray-light: #a3a3a3;
	--hp-border: #e6e6e6;
	--hp-bg: #ffffff;
	--hp-bg-soft: #f7f7f7;
	--hp-purple: #6236ff;

	--hp-font-display: 'Poppins', 'Inter', -apple-system, sans-serif;
	--hp-font-sans: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', Helvetica, Arial, sans-serif;

	--hp-container: 1300px;
}

* { box-sizing: border-box; }

html { overflow-x: hidden; max-width: 100%; }

body {
	margin: 0;
	overflow-x: hidden;
	max-width: 100%;
	font-family: var(--hp-font-sans);
	color: var(--hp-black);
	background: var(--hp-bg);
	line-height: 1.55;
}

img { max-width: 100%; height: auto; display: block; }
a { color: inherit; text-decoration: none; }
ul { list-style: none; margin: 0; padding: 0; }
button { font: inherit; cursor: pointer; }

.hp-media-fallback {
	display: block;
	width: 100%;
	height: 100%;
	min-height: 140px;
	background: var(--hp-bg-soft);
}

/* ---------- Masthead ---------- */

.hp-masthead { position: relative; border-bottom: 1px solid var(--hp-border); }
.hp-masthead-inner {
	max-width: var(--hp-container);
	margin: 0 auto;
	padding: 1.1rem 1.25rem;
	display: flex;
	align-items: center;
	gap: 1rem;
}
.hp-logo,
.hp-logo-wrap a {
	font-family: var(--hp-font-display);
	font-weight: 900;
	font-size: clamp(1.9rem, 5vw, 2.4rem);
	color: var(--hp-black);
}
.hp-logo, .hp-logo-wrap { flex: 1; text-align: center; }

.hp-search {
	display: flex;
	align-items: center;
	background: var(--hp-bg-soft);
	border-radius: 999px;
	padding: 0.35rem 0.4rem 0.35rem 0.9rem;
	flex-shrink: 0;
}
.hp-search input { background: none; border: 0; outline: none; width: 150px; font-size: 0.85rem; font-family: var(--hp-font-sans); }
.hp-search button { background: none; border: 0; color: var(--hp-black); display: flex; padding: 0.3rem; }

/* ---------- Primary nav strip ---------- */

.hp-nav {
	background: var(--hp-black);
	position: sticky;
	top: 0;
	z-index: 40;
}
.hp-nav-inner { max-width: var(--hp-container); margin: 0 auto; padding: 0 1.25rem; display: flex; align-items: center; }
.hp-nav-menu-wrap {
	flex: 1;
	min-width: 0;
	overflow-x: auto;
	overflow-y: hidden;
	-ms-overflow-style: none;
	scrollbar-width: none;
}
.hp-nav-menu-wrap::-webkit-scrollbar { display: none; }
.hp-menu { display: flex; flex-wrap: nowrap; min-width: 0; width: max-content; }
.hp-menu > li { flex: 0 0 auto; }
.hp-menu li a {
	display: block;
	white-space: nowrap;
	padding: 0.8rem 0.85rem;
	color: #fff;
	font-family: var(--hp-font-display);
	font-weight: 700;
	font-size: 0.85rem;
}
.hp-menu li a:hover,
.hp-menu li.current-menu-item a { color: #b794ff; }

.hp-nav-toggle { display: flex; order: -1; flex-shrink: 0; flex-direction: column; gap: 4px; background: none; border: 0; padding: 0.75rem 0.25rem; }
.hp-nav-toggle span { display: block; width: 20px; height: 2px; background: var(--hp-black); }

.hp-mobile-menu-wrap {
	display: none;
	position: absolute;
	top: 100%;
	left: 0;
	right: 0;
	background: #fff;
	border-bottom: 1px solid var(--hp-border);
	box-shadow: 0 12px 20px rgba(0,0,0,0.15);
	max-height: 70vh;
	overflow-y: auto;
	z-index: 50;
	padding: 0.5rem 1.25rem 0.75rem;
}
.hp-mobile-menu-wrap.is-open { display: block; }
.hp-mobile-menu { display: flex; flex-direction: column; }
.hp-mobile-menu li a {
	display: block;
	padding: 0.7rem 0;
	color: var(--hp-black);
	font-family: var(--hp-font-display);
	font-weight: 700;
	font-size: 0.9rem;
	border-bottom: 1px solid var(--hp-border);
}
.hp-mobile-menu li:last-child a { border-bottom: 0; }
.hp-mobile-menu li a:hover { color: var(--hp-purple); }

/* ---------- Shared layout ---------- */

.hp-main { max-width: var(--hp-container); margin: 0 auto; padding: 1.75rem 1.25rem 3.5rem; }

.hp-chip {
	display: inline-block;
	color: #fff;
	font-family: var(--hp-font-display);
	font-weight: 700;
	font-size: 0.72rem;
	text-transform: uppercase;
	letter-spacing: 0.04em;
	padding: 0.28rem 0.75rem;
	border-radius: 999px;
	margin-bottom: 0.6rem;
}

.hp-dek { font-size: 1.08rem; color: var(--hp-gray); line-height: 1.55; margin: 0.4rem 0 0.8rem; max-width: 680px; }
.hp-dek-single { font-size: 1.2rem; margin: 0.6rem 0 1rem; }

.hp-meta { font-size: 0.8rem; color: var(--hp-gray); }
.hp-dot { margin: 0 0.35rem; color: var(--hp-gray-light); }

.hp-section-heading { margin-bottom: 1.25rem; }
.hp-section-heading h2 { font-family: var(--hp-font-display); font-weight: 800; font-size: 1.3rem; margin: 0; }

/* ---------- Trending strip ---------- */

.hp-trending-strip {
	display: flex;
	align-items: center;
	gap: 1rem;
	padding: 0.9rem 1.25rem;
	max-width: var(--hp-container);
	margin: 0 auto;
	overflow: hidden;
}
.hp-trending-label {
	font-family: var(--hp-font-display);
	font-weight: 800;
	font-size: 0.85rem;
	text-transform: uppercase;
	color: var(--hp-black);
	flex-shrink: 0;
}
.hp-trending-marquee { flex: 1; min-width: 0; overflow: hidden; }
.hp-trending-track {
	display: inline-flex;
	gap: 0.6rem;
	animation: hp-marquee 26s linear infinite;
	width: max-content;
}
.hp-trending-strip:hover .hp-trending-track { animation-play-state: paused; }

@keyframes hp-marquee {
	from { transform: translateX(0); }
	to { transform: translateX(-50%); }
}

@media (prefers-reduced-motion: reduce) {
	.hp-trending-track { animation: none; }
	.hp-trending-marquee { overflow-x: auto; }
}
.hp-trending-pill {
	white-space: nowrap;
	color: #fff;
	font-weight: 600;
	font-size: 0.82rem;
	padding: 0.4rem 0.9rem;
	border-radius: 999px;
	flex-shrink: 0;
}
.hp-trending-pill:hover { opacity: 0.85; }

/* ---------- Hero ---------- */

.hp-hero-section { margin-bottom: 2.5rem; }
.hp-hero-title {
	font-family: var(--hp-font-display);
	font-weight: 900;
	font-size: clamp(2rem, 5.6vw, 3.4rem);
	line-height: 1.05;
	margin: 0 0 0.6rem;
	max-width: 900px;
}
.hp-hero-title a:hover { color: var(--hp-purple); }
.hp-hero-media { display: block; aspect-ratio: 16 / 9; overflow: hidden; margin-top: 1rem; border-radius: 6px; background: var(--hp-bg-soft); }
.hp-hero-media img { width: 100%; height: 100%; object-fit: cover; }

/* ---------- Card grid ---------- */

.hp-grid-section { margin-bottom: 2rem; }
.hp-card-grid { display: flex; flex-wrap: wrap; gap: 2rem; }
.hp-card-grid > .hp-card { flex: 1 1 220px; }
.hp-card-media { display: block; aspect-ratio: 3 / 2; overflow: hidden; margin-bottom: 0.75rem; border-radius: 6px; background: var(--hp-bg-soft); }
.hp-card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform 0.3s ease; }
.hp-card:hover .hp-card-media img { transform: scale(1.04); }
.hp-card-title { font-family: var(--hp-font-display); font-weight: 800; font-size: 1.2rem; line-height: 1.25; margin: 0 0 0.4rem; }
.hp-card-title a:hover { color: var(--hp-purple); }

/* Grid style variant — smaller cards, more columns, for the "Editor's
   Picks" block so the main column reads as a distinct section. */
.hp-grid-dense { gap: 1.1rem; }
.hp-grid-dense > .hp-card { flex: 1 1 175px; }
.hp-grid-dense .hp-card-title { font-size: 1.02rem; }

.hp-home-feed { width: 100%; }
.hp-grid-standard, .hp-grid-wide2, .hp-grid-compact, .hp-grid-mosaic { display: flex; flex-wrap: wrap; }
.hp-grid-standard { gap: 2rem; }
.hp-grid-wide2    { gap: 2rem; }
.hp-grid-compact  { gap: 1rem; }
.hp-grid-mosaic   { gap: 1.25rem; }
.hp-grid-standard > * { flex: 1 1 220px; }
.hp-grid-wide2 > *    { flex: 1 1 300px; }
.hp-grid-compact > *  { flex: 1 1 145px; }
.hp-grid-mosaic > *   { flex: 1 1 195px; }
.hp-grid-mosaic > *:first-child { flex-basis: 400px; }
.hp-hlist { display: flex; flex-direction: column; gap: 0.9rem; }
.hp-hlist > .hp-card { display: flex; flex-direction: row; align-items: center; gap: 1.1rem; border-bottom: 1px solid var(--hp-border, rgba(0,0,0,0.1)); border-radius: 0; padding: 0 0 0.9rem; }
.hp-hlist > .hp-card .hp-card-media { width: 150px; flex-shrink: 0; aspect-ratio: 4 / 3; margin-bottom: 0; border-radius: 6px; }
.hp-hlist > .hp-card .hp-card-body { flex: 1; min-width: 0; }

/* ---------- Body layout: main column + sidebar ---------- */

.hp-columns { display: grid; grid-template-columns: 1fr; gap: 2.5rem; align-items: start; }
.hp-body-main { min-width: 0; }

.hp-sidebar { display: flex; flex-direction: column; gap: 2rem; align-self: start; }
.hp-widget-title { font-family: var(--hp-font-display); font-weight: 800; font-size: 1rem; margin: 0 0 0.6rem; }
.hp-widget-list { display: flex; flex-direction: column; gap: 0.6rem; }
.hp-widget-list li { border-bottom: 1px solid var(--hp-border); padding-bottom: 0.6rem; }
.hp-widget-list li:last-child { border-bottom: 0; padding-bottom: 0; }
.hp-widget-item { display: flex; align-items: center; gap: 0.75rem; }
.hp-widget-thumb { flex: 0 0 56px; width: 56px; height: 56px; border-radius: 4px; overflow: hidden; background: var(--hp-bg-soft); }
.hp-widget-thumb img { width: 100%; height: 100%; object-fit: cover; display: block; }
.hp-widget-thumb-fallback { display: block; width: 100%; height: 100%; background: var(--hp-bg-soft); }
.hp-widget-text { flex: 1; min-width: 0; }
.hp-widget-item:hover .hp-widget-text { color: var(--hp-purple); }
.hp-widget-list a { font-size: 0.92rem; line-height: 1.35; }
.hp-widget-list a:hover { color: var(--hp-purple); }
.hp-widget-pills { display: flex; flex-wrap: wrap; gap: 0.4rem; }
.hp-widget-pill { font-size: 0.76rem; background: var(--hp-bg-soft); border-radius: 999px; padding: 0.25rem 0.65rem; font-weight: 600; }
.hp-widget-pill:hover { background: var(--hp-purple); color: #fff; }
.hp-widget-pill-tag { color: var(--hp-purple); }

/* ---------- Archive / search headers ---------- */

.hp-archive-header { border-bottom: 1px solid var(--hp-border); margin-bottom: 1.75rem; padding-bottom: 1rem; }
.hp-archive-title { font-family: var(--hp-font-display); font-weight: 900; font-size: clamp(1.5rem, 3vw, 2.1rem); margin: 0; }
.hp-archive-title span { color: var(--hp-purple); }
.hp-archive-desc { color: var(--hp-gray); margin-top: 0.4rem; }
.hp-no-results { color: var(--hp-gray); }
.hp-archive { margin-bottom: 2rem; }

/* ---------- Pagination ---------- */

.pagination,
.navigation.pagination { display: flex; gap: 0.5rem; margin-top: 2rem; flex-wrap: wrap; }
.pagination .page-numbers {
	display: inline-block;
	padding: 0.5rem 0.9rem;
	border: 1px solid var(--hp-border);
	border-radius: 999px;
	font-family: var(--hp-font-display);
	font-weight: 600;
	font-size: 0.9rem;
	color: var(--hp-black);
}
.pagination .page-numbers.current { background: var(--hp-purple); color: #fff; border-color: var(--hp-purple); }
.pagination .page-numbers:hover:not(.current) { border-color: var(--hp-purple); }

/* ---------- Single article ---------- */

.hp-single { max-width: 740px; margin: 0 auto; }
.hp-single-header { text-align: center; margin-bottom: 1.5rem; }
.hp-single-title { font-family: var(--hp-font-display); font-weight: 900; font-size: clamp(2rem, 5vw, 2.9rem); line-height: 1.08; margin: 0.3rem 0 0; }
.hp-byline-row { margin-top: 1rem; padding: 0.6rem 0; border-top: 1px solid var(--hp-border); border-bottom: 1px solid var(--hp-border); font-size: 0.85rem; color: var(--hp-gray); }

.hp-single-media { margin: 1.75rem 0; border-radius: 8px; overflow: hidden; }
.hp-single-media img { width: 100%; }

.hp-single-content { font-size: 1.1rem; line-height: 1.75; }
.hp-single-content p { margin: 0 0 1.35rem; }
.hp-single-content blockquote {
	background: var(--hp-bg-soft);
	border-left: 4px solid var(--hp-purple);
	margin: 1.75rem 0;
	padding: 1rem 1.25rem;
	font-style: italic;
	font-size: 1.2rem;
	border-radius: 0 8px 8px 0;
}
.hp-single-content h2,
.hp-single-content h3 { font-family: var(--hp-font-display); font-weight: 800; }

.hp-single-footer { margin-top: 1.75rem; }
.hp-tags { display: flex; flex-wrap: wrap; gap: 0.5rem; justify-content: center; }
.hp-tag { background: var(--hp-bg-soft); border-radius: 999px; padding: 0.3rem 0.8rem; font-size: 0.8rem; color: var(--hp-black); font-weight: 600; }
.hp-tag:hover { background: var(--hp-purple); color: #fff; }

.hp-related { max-width: var(--hp-container); margin: 3rem auto 0; }

/* ---------- Page ---------- */

.hp-page { max-width: 740px; margin: 0 auto; }
.hp-page-title { font-family: var(--hp-font-display); font-weight: 900; font-size: clamp(1.8rem, 3.8vw, 2.4rem); border-bottom: 1px solid var(--hp-border); padding-bottom: 0.75rem; margin-bottom: 1.5rem; }

/* ---------- 404 ---------- */

.hp-404 { text-align: center; padding: 4rem 1rem; max-width: 560px; margin: 0 auto; }
.hp-404-code { display: block; font-family: var(--hp-font-display); font-weight: 900; font-size: 5rem; color: var(--hp-purple); line-height: 1; }
.hp-404 h1 { font-family: var(--hp-font-display); }
.hp-404-search { justify-content: center; margin: 1.5rem auto; }
.hp-404-search button { color: var(--hp-purple); font-weight: 700; padding: 0 0.75rem; }
.hp-404-home { display: inline-block; margin-top: 1rem; color: var(--hp-purple); font-weight: 700; text-decoration: underline; }

/* ---------- Comments ---------- */

.comment-respond,
.comments-area { max-width: 740px; margin: 2.5rem auto 0; }
.comment-reply-title,
.comments-title { font-family: var(--hp-font-display); }
.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
	width: 100%;
	padding: 0.6rem 0.75rem;
	border: 1px solid var(--hp-border);
	border-radius: 6px;
	font-family: var(--hp-font-sans);
	margin-bottom: 0.75rem;
}
.comment-form input[type="submit"] {
	background: var(--hp-purple);
	color: #fff;
	border: 0;
	padding: 0.65rem 1.5rem;
	border-radius: 999px;
	font-weight: 700;
}

/* ---------- Footer (dense, mega-footer) ---------- */

.hp-footer { background: var(--hp-black); color: #cfcfcf; margin-top: 3rem; }

.hp-footer-nav { border-bottom: 1px solid #2c2c2c; }
.hp-footer-nav-list {
	max-width: var(--hp-container);
	margin: 0 auto;
	padding: 1rem 1.25rem;
	display: flex;
	flex-wrap: wrap;
	gap: 0.4rem 0.25rem;
}
.hp-footer-nav-list a {
	display: inline-block;
	padding: 0.3rem 0.8rem;
	font-family: var(--hp-font-display);
	font-size: 0.78rem;
	font-weight: 600;
	color: #cfcfcf;
	border-right: 1px solid #2c2c2c;
}
.hp-footer-nav-list li:last-child a { border-right: 0; }
.hp-footer-nav-list a:hover { color: #fff; }

.hp-footer-rows {
	max-width: var(--hp-container);
	margin: 0 auto;
	padding: 1.5rem 1.25rem;
	display: flex;
	flex-direction: column;
}
.hp-footer-row {
	display: flex;
	flex-wrap: wrap;
	align-items: baseline;
	gap: 0.3rem 0;
	padding: 0.85rem 0;
	border-bottom: 1px solid #2c2c2c;
}
.hp-footer-row:last-child { border-bottom: 0; }
.hp-footer-row-label {
	font-family: var(--hp-font-display);
	text-transform: uppercase;
	letter-spacing: 0.04em;
	font-size: 0.76rem;
	color: #b794ff;
	flex-shrink: 0;
	margin-right: 0.9rem;
}
.hp-footer-row-links { display: flex; flex-wrap: wrap; }
.hp-footer-row-links a { color: #cfcfcf; font-size: 0.88rem; }
.hp-footer-row-links a:hover { color: #fff; text-decoration: underline; }
.hp-footer-row-links a:not(:last-child)::after { content: "|"; color: rgba(255,255,255,0.25); margin: 0 0.6rem; }

.hp-footer-about {
	max-width: var(--hp-container);
	margin: 0 auto;
	padding: 1.5rem 1.25rem;
	border-top: 1px solid #2c2c2c;
	text-align: center;
}
.hp-footer-logo,
.hp-footer-about-logo { font-family: var(--hp-font-display); font-weight: 900; font-size: 1.4rem; color: #fff; margin: 0 0 0.4rem; }
.hp-footer-about-desc { color: #8a8a8a; max-width: 640px; margin: 0 auto; font-size: 0.9rem; }

.hp-footer-compliance {
	max-width: var(--hp-container);
	margin: 0 auto;
	padding: 0 1.25rem 1.5rem;
	text-align: center;
}
.hp-footer-menu { display: flex; flex-wrap: wrap; justify-content: center; }
.hp-footer-menu li:not(:last-child)::after { content: "|"; color: rgba(255,255,255,0.25); margin: 0 0.7rem; }
.hp-footer-menu a { color: #cfcfcf; font-size: 0.84rem; }
.hp-footer-menu a:hover { color: #fff; text-decoration: underline; }

.hp-footer-bottom { border-top: 1px solid #2c2c2c; text-align: center; padding: 1rem; font-size: 0.78rem; color: #8a8a8a; }

/* ==========================================================================
   Responsive
   ========================================================================== */

@media (max-width: 1300px) {
	.hp-footer-row { flex-direction: column; align-items: flex-start; gap: 0.4rem; }
}

@media (max-width: 480px) {
	.hp-search input { width: 90px; }
}

@media (min-width: 900px) {
	.hp-columns { grid-template-columns: 2.2fr 1fr; }
	.hp-sidebar { position: sticky; top: 90px; }
}
