/**
 * Health News & Views — front-end + editor theme styles
 *
 * Holds CSS that can't be expressed in theme.json: hover transitions,
 * sticky header positioning, audio player skin, waveform decoration,
 * block-style variants.
 */

/* ---------- Sticky header ---------- */
.wp-site-blocks > .wp-block-template-part.site-header,
.hnv-sticky-header {
	position: sticky;
	top: 0;
	z-index: 50;
	backdrop-filter: blur(10px);
	-webkit-backdrop-filter: blur(10px);
}

/* ---------- Button block-style: Listen Now (orange pill w/ play icon) ---------- */
.wp-block-button.is-style-listen-now > .wp-block-button__link {
	background-color: #FF7043;
	color: #FFFFFF;
	border-radius: 9999px;
	padding: 0.875rem 2rem;
	box-shadow: 0 8px 24px rgba(255, 112, 67, 0.25);
	transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
}
.wp-block-button.is-style-listen-now > .wp-block-button__link::before {
	content: "▶";
	font-size: 0.75em;
	line-height: 1;
}
.wp-block-button.is-style-listen-now > .wp-block-button__link:hover {
	background-color: #E65100;
	transform: scale(1.03);
	box-shadow: 0 12px 32px rgba(255, 112, 67, 0.35);
}

/* ---------- Read-more block-style: Listen Now (used inside Query Loop, where core/button cannot resolve the post URL) ---------- */
.wp-block-read-more.is-style-listen-now,
a.wp-block-read-more.is-style-listen-now {
	background-color: #FF7043;
	color: #FFFFFF;
	border-radius: 9999px;
	padding: 0.875rem 2rem;
	box-shadow: 0 8px 24px rgba(255, 112, 67, 0.25);
	transition: transform 0.2s ease, box-shadow 0.2s ease, background-color 0.2s ease;
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	font-family: var(--wp--preset--font-family--montserrat);
	font-weight: 600;
	font-size: 0.9375rem;
	letter-spacing: 0.02em;
	text-decoration: none;
	text-align: center;
	justify-content: center;
}
.wp-block-read-more.is-style-listen-now::before {
	content: "▶";
	font-size: 0.75em;
	line-height: 1;
}
.wp-block-read-more.is-style-listen-now:hover {
	background-color: #E65100;
	color: #FFFFFF;
	transform: scale(1.03);
	box-shadow: 0 12px 32px rgba(255, 112, 67, 0.35);
	text-decoration: none;
}
.wp-block-read-more.is-style-listen-now.is-full-width {
	display: flex;
	width: 100%;
}
/* Rectangular, centered Listen Now button for card contexts
 * (Recent Episodes grid + blog sidebar podcast CTA).
 * Uses block-level flex + max-content + auto margins so it centers
 * in both flex parents (cards) and block parents (sidebar group). */
.wp-block-read-more.is-style-listen-now.is-in-card {
	border-radius: 8px;
	padding: 0.75rem 1.5rem;
	display: flex;
	align-items: center;
	justify-content: center;
	gap: 0.5rem;
	width: max-content;
	max-width: 100%;
	margin-left: auto;
	margin-right: auto;
	align-self: center;
}

/* ---------- Button block-style: Outline Green ---------- */
.wp-block-button.is-style-outline-green > .wp-block-button__link {
	background-color: transparent;
	color: #2E7D32;
	border: 2px solid #2E7D32;
	border-radius: 9999px;
	transition: background-color 0.2s ease, color 0.2s ease;
}
.wp-block-button.is-style-outline-green > .wp-block-button__link:hover {
	background-color: #2E7D32;
	color: #FFFFFF;
}

/* ---------- Group block-style: Card Lift on Hover ---------- */
.wp-block-group.is-style-card-lift {
	background-color: #FFFFFF;
	border-radius: 12px;
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
	border: 1px solid #E5E2E1;
	overflow: hidden;
	transition: transform 0.3s ease, box-shadow 0.3s ease;
}
.wp-block-group.is-style-card-lift:hover {
	transform: translateY(-4px) scale(1.02);
	box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
}

/* ---------- Generic post-card hover inside Query Loop on home ---------- */
.hnv-episode-card {
	background: #FFFFFF;
	border-radius: 12px;
	box-shadow: 0 10px 30px rgba(0, 0, 0, 0.05);
	border: 1px solid #E5E2E1;
	overflow: hidden;
	transition: transform 0.3s ease, box-shadow 0.3s ease;
	display: flex;
	flex-direction: column;
	height: 100%;
}
.hnv-episode-card:hover {
	transform: translateY(-4px) scale(1.02);
	box-shadow: 0 20px 40px rgba(0, 0, 0, 0.08);
}
.hnv-episode-card .wp-block-post-featured-image {
	margin: 0;
}
.hnv-episode-card .wp-block-post-featured-image img {
	width: 100%;
	height: 220px;
	object-fit: cover;
	display: block;
}

/* ---------- Audio player skin ---------- */
.hnv-audio-player {
	background: rgba(255, 255, 255, 0.08);
	backdrop-filter: blur(20px);
	-webkit-backdrop-filter: blur(20px);
	border: 1px solid rgba(255, 255, 255, 0.18);
	border-radius: 16px;
	padding: 1.5rem 2rem;
}
.hnv-audio-player audio {
	width: 100%;
}
.hnv-audio-player__row { margin-bottom: 1rem; }
.hnv-audio-player__meta {
	display: flex;
	justify-content: flex-end;
	margin-top: 0.75rem;
	font-family: 'Open Sans', sans-serif;
	font-size: 0.8125rem;
	color: rgba(255, 255, 255, 0.7);
	letter-spacing: 0.05em;
	text-transform: uppercase;
	font-weight: 600;
}
.hnv-audio-player__missing {
	color: rgba(255, 255, 255, 0.75);
	font-style: italic;
	text-align: center;
	margin: 0;
}
.hnv-episode-meta {
	font-family: 'Open Sans', sans-serif;
	font-size: 1.0625rem;
	font-weight: 500;
	color: #d4e4d4;
	margin: 0 0 2rem;
}

/* ---------- Waveform decoration (purely cosmetic) ---------- */
.hnv-waveform {
	display: flex;
	align-items: flex-end;
	gap: 3px;
	height: 48px;
	width: 100%;
}
.hnv-waveform span {
	flex: 1;
	background: rgba(255, 255, 255, 0.4);
	border-radius: 1px;
	min-width: 2px;
}
.hnv-waveform span:nth-child(3n)   { height: 80%; }
.hnv-waveform span:nth-child(3n+1) { height: 45%; }
.hnv-waveform span:nth-child(3n+2) { height: 65%; }
.hnv-waveform span:nth-child(5n)   { height: 100%; }
.hnv-waveform span:nth-child(7n)   { height: 30%; }

/* ---------- Blockquote pull-quote (matches blog mock) ---------- */
.wp-block-quote.is-style-pull-quote,
.hnv-pullquote {
	border-left: 4px solid #FF7043;
	padding: 1.5rem 2rem;
	margin: 2.5rem 0;
	background: #F4F8F4;
	border-radius: 0 12px 12px 0;
	font-family: 'Montserrat', sans-serif;
	font-weight: 600;
	font-size: 1.5rem;
	line-height: 1.4;
	font-style: italic;
}

/* ---------- Label-caps utility (small uppercase eyebrow text) ---------- */
.hnv-eyebrow {
	font-family: 'Open Sans', sans-serif;
	font-weight: 600;
	font-size: 0.875rem;
	letter-spacing: 0.05em;
	text-transform: uppercase;
	color: #2E7D32;
}
.has-deep-green-background-color .hnv-eyebrow,
.hnv-eyebrow.is-on-dark {
	color: #FF7043;
}

/* Accent underline — used beneath section headings for visual rhythm */
.hnv-accent-underline::after {
	content: "";
	display: block;
	width: 64px;
	height: 4px;
	background-color: #FF7043;
	margin-top: 1rem;
	border-radius: 2px;
}
.has-text-align-center.hnv-accent-underline::after {
	margin-left: auto;
	margin-right: auto;
}

/* Host bio card on Home hero */
.hnv-host-card {
	text-align: center;
}
.hnv-host-card img {
	border-radius: 9999px;
	width: 180px;
	height: 180px;
	object-fit: cover;
	margin: 0 auto 1rem;
	display: block;
}

/* Multi-line pullquote / proverb (used in hero) */
.hnv-proverb p {
	margin: 0 0 0.25rem;
}
.hnv-proverb cite {
	display: block;
	margin-top: 1rem;
	font-style: normal;
	opacity: 0.75;
	font-size: 0.9375rem;
}

/* ---------- Feature cards on dark backgrounds (About page) ---------- */
.hnv-feature-card {
	background: rgba(255, 255, 255, 0.03);
	border: 1px solid rgba(255, 255, 255, 0.12);
	border-radius: 12px;
	padding: 2rem 1.75rem;
	height: 100%;
	backdrop-filter: blur(6px);
	-webkit-backdrop-filter: blur(6px);
}
.hnv-feature-card h3 {
	margin-top: 0;
	color: #FFFFFF;
}
.hnv-feature-card p {
	color: #d4e4d4;
	font-size: 0.9375rem;
	line-height: 1.65;
}

/* ---------- Meta row (New Episodes / Guest / Listen) on About page ---------- */
.hnv-meta-row .hnv-meta-item {
	padding: 0 1rem;
}
.hnv-meta-row .hnv-meta-label {
	text-transform: uppercase;
	letter-spacing: 0.08em;
	font-weight: 700;
	font-size: 0.875rem;
	margin: 0 0 0.25rem;
}
.hnv-meta-row .hnv-meta-value {
	color: #FF7043;
	font-weight: 600;
	margin: 0;
}
.hnv-meta-row .hnv-meta-value a {
	color: #FF7043;
	text-decoration: none;
}
.hnv-meta-row .hnv-meta-value a:hover {
	text-decoration: underline;
}

/* ---------- Platform pill buttons (Listen Now CTA) ---------- */
.hnv-platform-row {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
	justify-content: center;
	align-items: center;
}
.hnv-platform-pill {
	display: inline-flex;
	align-items: center;
	gap: 0.5rem;
	padding: 0.75rem 1.25rem;
	background: #1B3A1B;
	color: #FFFFFF;
	border-radius: 9999px;
	font-family: 'Montserrat', sans-serif;
	font-weight: 600;
	font-size: 0.9375rem;
	text-decoration: none;
	transition: background-color 0.2s ease, transform 0.2s ease;
}
.hnv-platform-pill:hover {
	background: #0d2a0d;
	color: #FFFFFF;
	transform: translateY(-2px);
	text-decoration: none;
}
.hnv-platform-pill::before {
	content: "▶";
	font-size: 0.75em;
	opacity: 0.9;
}

/* Home page hero — cover block with kitchen photo + left-fade overlay + real text */
.hnv-hero-cover {
	padding: 0;
}
.hnv-hero-cover .wp-block-cover__inner-container {
	width: 100%;
	max-width: none;
	padding: 0;
}
.hnv-hero-cover h1,
.hnv-hero-cover .hnv-proverb p {
	text-shadow: 0 1px 2px rgba(0, 0, 0, 0.25);
}
/* Outline button variant sitting on a dark hero — border and label go white */
.hnv-hero-cover .wp-block-button.is-style-outline-green.is-on-dark > .wp-block-button__link,
.wp-block-button.is-style-outline-green.is-on-dark > .wp-block-button__link {
	background-color: transparent;
	color: #FFFFFF;
	border: 2px solid #FFFFFF;
}
.hnv-hero-cover .wp-block-button.is-style-outline-green.is-on-dark > .wp-block-button__link:hover,
.wp-block-button.is-style-outline-green.is-on-dark > .wp-block-button__link:hover {
	background-color: #FFFFFF;
	color: #1B3A1B;
}
/* Scale the hero's 200px left indent down on smaller viewports */
@media (max-width: 1200px) {
	.hnv-hero-cover .wp-block-cover__inner-container > .wp-block-group {
		padding-left: 96px !important;
	}
}
@media (max-width: 768px) {
	.hnv-hero-cover .wp-block-cover__gradient-background {
		background: rgba(27, 58, 27, 0.92) !important;
	}
	.hnv-hero-cover {
		min-height: 420px !important;
	}
	.hnv-hero-cover .wp-block-cover__inner-container > .wp-block-group {
		padding-left: 1.5rem !important;
	}
}

/* Circular author portrait used on About + Meet The Host */
.hnv-portrait-round img {
	border-radius: 9999px;
	width: 220px;
	height: 220px;
	object-fit: cover;
	display: block;
	margin: 0 auto;
}

/* ---------- Legal page template (Privacy Policy, Terms, Disclaimer) ---------- */
/* Reading-optimized typography for long legal copy. */
.hnv-legal__updated::before {
	content: "Last updated: ";
	opacity: 0.85;
}
.hnv-legal__content {
	font-size: 1.0625rem;
	line-height: 1.75;
	color: #1B1B1B;
}
.hnv-legal__content p {
	margin: 0 0 1.25rem;
}
.hnv-legal__content h2 {
	font-size: 1.5rem;
	line-height: 1.3;
	letter-spacing: -0.01em;
	font-weight: 800;
	margin: 2.5rem 0 1rem;
	color: #1B3A1B;
}
.hnv-legal__content h3 {
	font-size: 1.1875rem;
	line-height: 1.35;
	font-weight: 700;
	margin: 2rem 0 0.75rem;
	color: #1B3A1B;
}
.hnv-legal__content h4 {
	font-size: 1.0625rem;
	font-weight: 700;
	margin: 1.5rem 0 0.5rem;
}
.hnv-legal__content ul,
.hnv-legal__content ol {
	margin: 0 0 1.25rem 1.25rem;
	padding: 0;
}
.hnv-legal__content li {
	margin: 0 0 0.5rem;
}
.hnv-legal__content a {
	color: #2E7D32;
	text-decoration: underline;
	text-underline-offset: 2px;
}
.hnv-legal__content a:hover {
	color: #FF7043;
}
.hnv-legal__content blockquote {
	margin: 1.5rem 0;
	padding: 0.5rem 1.25rem;
	border-left: 3px solid #FF7043;
	background: #F4F8F4;
	font-style: italic;
}
.hnv-legal__content hr {
	border: 0;
	height: 1px;
	background: #E5E2E1;
	margin: 2.5rem 0;
}
.hnv-legal__content strong {
	color: #1B3A1B;
}

/* ---------- Subscribe form (rendered by [hnpm_subscribe_form]) ---------- */
.hnv-subscribe-form__row {
	display: flex;
	flex-wrap: wrap;
	gap: 0.75rem;
	max-width: 480px;
	margin: 0 auto;
}
.hnv-subscribe-form__row input[type="email"],
.hnv-subscribe-form__row input[type="text"] {
	flex: 1 1 240px;
	min-width: 0;
	padding: 0.875rem 1rem;
	border-radius: 9999px;
	border: 0;
	background: rgba(255, 255, 255, 0.95);
	color: #1B1B1B;
	font-family: 'Open Sans', sans-serif;
	font-size: 1rem;
	outline-offset: 2px;
}
.hnv-subscribe-form__row input[type="email"]:focus,
.hnv-subscribe-form__row input[type="text"]:focus {
	outline: 2px solid #FF7043;
}
/* Stacked form variant — fields sit on top of each other with a full-width button */
.hnv-subscribe-form.is-stacked .hnv-subscribe-form__row {
	flex-direction: column;
	max-width: 520px;
	gap: 0.875rem;
	margin: 0;
}
.hnv-subscribe-form.is-stacked .hnv-subscribe-form__row input[type="email"],
.hnv-subscribe-form.is-stacked .hnv-subscribe-form__row input[type="text"] {
	flex: 0 0 auto;
	width: 100%;
	border-radius: 8px;
	padding: 1rem 1.25rem;
	margin: 0;
}
.hnv-subscribe-form.is-stacked .hnv-subscribe-form__button {
	width: 100%;
	border-radius: 8px;
	padding: 1rem 1.25rem;
	text-transform: uppercase;
	letter-spacing: 0.08em;
	margin: 0;
}
/* Defensive: a sibling <br/> or stray <p> injected by wpautop should not add height. */
.hnv-subscribe-form br {
	display: none;
}
.hnv-subscribe-form > p:empty {
	display: none;
	margin: 0;
}

/* ---------- Success state: replaces the form on successful submit ---------- */
.hnv-subscribe-form.is-submitted .hnv-subscribe-form__row,
.hnv-subscribe-form.is-submitted .hnv-subscribe-form__message {
	display: none;
}
.hnv-subscribe-form__success {
	display: flex;
	flex-direction: column;
	align-items: center;
	text-align: center;
	gap: 0.75rem;
	padding: 2rem 1.5rem;
	border-radius: 12px;
	background: rgba(255, 255, 255, 0.06);
	border: 1px solid rgba(255, 255, 255, 0.15);
	max-width: 520px;
	margin: 0 auto;
	outline: none;
	animation: hnvFadeInUp 0.35s ease;
}
.hnv-subscribe-form__success[hidden] {
	display: none;
}
.hnv-subscribe-form__success-icon {
	display: inline-flex;
	align-items: center;
	justify-content: center;
	width: 48px;
	height: 48px;
	border-radius: 9999px;
	background: #FF7043;
	color: #FFFFFF;
	font-size: 1.5rem;
	line-height: 1;
	font-weight: 700;
	box-shadow: 0 10px 24px rgba(255, 112, 67, 0.35);
}
.hnv-subscribe-form__success-title {
	margin: 0;
	font-family: 'Montserrat', sans-serif;
	font-weight: 800;
	font-size: 1.5rem;
	color: inherit;
	letter-spacing: -0.01em;
}
.hnv-subscribe-form__success-body {
	margin: 0;
	font-size: 1rem;
	line-height: 1.55;
	color: inherit;
	opacity: 0.9;
}
@keyframes hnvFadeInUp {
	from { opacity: 0; transform: translateY(8px); }
	to   { opacity: 1; transform: translateY(0); }
}
/* On light backgrounds (e.g. inline use on a white section) invert the success card */
.hnv-subscribe-form.is-on-light .hnv-subscribe-form__success {
	background: rgba(27, 58, 27, 0.04);
	border-color: rgba(27, 58, 27, 0.12);
	color: #1B1B1B;
}
.hnv-subscribe-form__button {
	padding: 0.875rem 1.75rem;
	border-radius: 9999px;
	border: 0;
	background: #FF7043;
	color: #FFFFFF;
	font-family: 'Montserrat', sans-serif;
	font-weight: 600;
	font-size: 0.9375rem;
	letter-spacing: 0.02em;
	cursor: pointer;
	transition: background-color 0.2s ease, transform 0.2s ease;
}
.hnv-subscribe-form__button:hover {
	background: #E65100;
	transform: scale(1.03);
}
.hnv-subscribe-form__message {
	margin: 0.75rem 0 0;
	min-height: 1.25rem;
	font-size: 0.875rem;
	text-align: center;
}
.hnv-subscribe-form__message.is-error { color: #ffd1cc; }
.hnv-subscribe-form__message.is-success { color: #c7f0c7; }

/* ---------- Navigation hover underline (orange) ---------- */
.wp-block-navigation .wp-block-navigation-item__content:hover {
	color: #2E7D32;
}
.wp-block-navigation .current-menu-item > .wp-block-navigation-item__content {
	border-bottom: 2px solid #FF7043;
	padding-bottom: 2px;
}
