/* ==========================================================================
 * START: assets/css/nahse-news-common.css
 * NAHSE DFW News: shared tokens, Avada resets, story cards, newsletter form
 * Loaded on single news posts and on pages using [nahse_news_page].
 * Version: 5.0.0
 * v5.0.0 (pre-launch audit): Gravity Forms newsletter kept legible on the
 *   dark newsletter panels (labels, links, validation messages); sticky
 *   offset follows the admin bar height at 782px / 600px.
 * ==========================================================================
 * TO-DO NOTES
 * 1. Hero top space is --nahse-nw-hero-top (140 / 128 / 112). Change it here
 *    if the Avada header height changes.
 * 2. Sticky offset for the listing toolbar and article rail is
 *    --nahse-nw-sticky-top. It assumes a sticky header about 88px tall.
 * ======================================================================== */

.nahse-news {
	--nw-navy: #0a1433;
	--nw-blue: #003194;
	--nw-gold: #f2c14e;
	--nw-deep: #07163f;
	--nw-muted: #7a8199;
	--nw-text: #4a5373;
	--nw-body: #2a3252;
	--nw-line: #eceef4;
	--nw-line2: #dfe3ee;
	--nw-soft: #eef1fb;
	--nw-paper: #f6f5f2;
	--nw-imgbg: #e4e8f3;
	--nw-sans: 'Instrument Sans', system-ui, -apple-system, 'Segoe UI', Roboto, Arial, sans-serif;
	--nw-serif: 'Instrument Serif', Georgia, 'Times New Roman', serif;
	--nw-mono: 'JetBrains Mono', ui-monospace, SFMono-Regular, Menlo, Consolas, monospace;
	--nw-ease: cubic-bezier(.2, .7, .2, 1);
	--nahse-nw-hero-top: 140px;
	--nahse-nw-sticky-top: 88px;
	font-family: var(--nw-sans);
	color: var(--nw-navy);
	-webkit-font-smoothing: antialiased;
	width: 100%;
	overflow-x: clip;
	text-align: left;
}
body.admin-bar .nahse-news { --nahse-nw-sticky-top: 120px; }
@media (max-width: 782px) { body.admin-bar .nahse-news { --nahse-nw-sticky-top: 134px; } }
/* At 600px and below the admin bar scrolls away (position: absolute). */
@media (max-width: 600px) { body.admin-bar .nahse-news { --nahse-nw-sticky-top: 88px; } }
@media (max-width: 1100px) { .nahse-news { --nahse-nw-hero-top: 128px; } }
@media (max-width: 767px)  { .nahse-news { --nahse-nw-hero-top: 112px; } }

.nahse-news *, .nahse-news *::before, .nahse-news *::after { box-sizing: border-box; }
.nahse-news [hidden] { display: none !important; }
.nahse-news img { max-width: 100%; height: auto; border: 0; }
.nahse-news h1, .nahse-news h2, .nahse-news h3, .nahse-news p, .nahse-news figure, .nahse-news ul, .nahse-news blockquote {
	margin: 0; padding: 0; font-family: var(--nw-sans); text-transform: none;
}
.nahse-news h1, .nahse-news h2, .nahse-news h3 { color: inherit; font-weight: 600; }

/* Links: explicit states so Avada globals never leak in */
.nahse-news a, .nahse-news a:link, .nahse-news a:visited { color: var(--nw-blue); text-decoration: none; box-shadow: none; }
.nahse-news a:hover { color: var(--nw-navy); }
/* Focus: blue on light sections, gold on dark sections (both pass 3:1 contrast). */
.nahse-news a:focus-visible, .nahse-news button:focus-visible, .nahse-news input:focus-visible, .nahse-news select:focus-visible, .nahse-news [tabindex]:focus-visible {
	outline: 2px solid var(--nw-blue); outline-offset: 3px; border-radius: 8px;
}
.nahse-news :is(.nahse-ns-hero, .nahse-np-hero, .nahse-ns-nl, .nahse-np-nlbox) :focus-visible { outline-color: var(--nw-gold); }

/* Buttons: full reset because Avada styles buttons globally. Embedded forms keep their own styles. */
.nahse-news button:not(.nahse-nw-nl__embed button) {
	-webkit-appearance: none; appearance: none; margin: 0; font-family: var(--nw-sans);
	text-transform: none; letter-spacing: normal; box-shadow: none; text-shadow: none;
	background-image: none; min-height: 0; line-height: 1.2; cursor: pointer;
}

.nahse-nw-sr {
	position: absolute !important; width: 1px; height: 1px; padding: 0; margin: -1px;
	overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0;
}

/* Designed image placeholder */
.nahse-nw-ph {
	position: absolute; inset: 0; display: flex; flex-direction: column; gap: 8px;
	align-items: center; justify-content: center; color: #a5b0cf;
	background: linear-gradient(135deg, #e9edf8, #dde3f2);
	font-size: 13px; font-weight: 500;
}

/* Category label with dot */
.nahse-nw-cat {
	display: inline-flex; align-items: center; gap: 6px; font-size: 12px; font-weight: 600;
	letter-spacing: .08em; text-transform: uppercase; color: var(--nw-blue);
}
.nahse-nw-dot { width: 7px; height: 7px; border-radius: 50%; flex: none; background: var(--nw-blue); }

/* ---------- Story card (grid by default) ---------- */
.nahse-news a.nahse-nw-card,
.nahse-news a.nahse-nw-card:link,
.nahse-news a.nahse-nw-card:visited { display: flex; flex-direction: column; gap: 14px; color: var(--nw-navy); min-width: 0; }
.nahse-news a.nahse-nw-card:hover { color: var(--nw-blue); }
.nahse-nw-card__dshort { display: none; }
.nahse-nw-card__media {
	position: relative; display: block; aspect-ratio: 16 / 10; border-radius: 20px; overflow: hidden;
	background: var(--nw-imgbg); transition: transform .4s var(--nw-ease), box-shadow .4s var(--nw-ease);
}
.nahse-nw-card:hover .nahse-nw-card__media { transform: translateY(-4px); box-shadow: 0 24px 48px rgba(0, 49, 148, .12); }
.nahse-nw-card__media img { position: absolute; inset: 0; width: 100%; height: 100%; object-fit: cover; }
.nahse-nw-card__video {
	position: absolute; top: 14px; left: 14px; padding: 6px 12px; border-radius: 999px;
	background: var(--nw-blue); color: #fff; font-size: 12px; font-weight: 600; line-height: 1.2; pointer-events: none;
}
.nahse-nw-card__body { display: flex; flex-direction: column; gap: 14px; min-width: 0; }
.nahse-nw-card__meta { display: flex; gap: 10px; align-items: center; flex-wrap: wrap; padding: 0 2px; }
.nahse-nw-card__dr { font-size: 13px; color: var(--nw-muted); }
.nahse-news .nahse-nw-card__title {
	padding: 0 2px; font-size: 21px; font-weight: 600; letter-spacing: -.015em; line-height: 1.25;
	text-wrap: balance; color: inherit; transition: color .2s;
}
.nahse-news .nahse-nw-card__excerpt { padding: 0 2px; font-size: 15px; line-height: 1.55; color: var(--nw-text); }
.nahse-nw-card__by { display: block; padding: 0 2px; font-size: 13px; font-weight: 500; color: var(--nw-muted); }

/* ---------- Newsletter ---------- */
.nahse-news a.nahse-nw-nl__btn, .nahse-news a.nahse-nw-nl__btn:link, .nahse-news a.nahse-nw-nl__btn:visited {
	display: inline-flex; align-items: center; justify-content: center; gap: 8px; align-self: flex-start;
	padding: 14px 24px; border-radius: 999px; background: #fff; color: var(--nw-blue);
	font-size: 15px; font-weight: 600; line-height: 1.2; transition: background .2s, color .2s;
}
.nahse-news a.nahse-nw-nl__btn:hover { background: var(--nw-gold); color: var(--nw-navy); }
.nahse-news a.nahse-nw-nl__btn--box { padding: 12px 20px; font-size: 14px; }
.nahse-nw-nl__embed { position: relative; width: 100%; }
/* Gravity Forms sits on a dark panel: keep its text, links and errors readable.
   Only colors are set; GF layout, spacing and field styles are left alone. */
.nahse-news .nahse-nw-nl__embed .gform_wrapper :is(.gfield_label, .gform-field-label, legend, .gfield_description, .gform_description, .gfield_consent_label, .ginput_complex label),
.nahse-news .nahse-nw-nl__embed .gform_confirmation_message { color: #fff; }
.nahse-news .nahse-nw-nl__embed a, .nahse-news .nahse-nw-nl__embed a:link, .nahse-news .nahse-nw-nl__embed a:visited { color: #fff; text-decoration: underline; text-underline-offset: 3px; }
.nahse-news .nahse-nw-nl__embed a:hover { color: var(--nw-gold); }
.nahse-news .nahse-nw-nl__embed .gfield_required { color: var(--nw-gold); }
.nahse-news .nahse-nw-nl__embed :is(.gfield_validation_message, .validation_message) {
	margin-top: 6px; padding: 6px 10px; border-radius: 8px; background: #fff; color: #b3261e; font-size: 13px; line-height: 1.4;
}
.nahse-news .nahse-nw-nl__embed .gform_validation_errors { margin: 0 0 12px; }
.nahse-news .nahse-nw-nl__embed .gform_validation_errors :is(h2, .gform_submission_error) { font-size: 14px; line-height: 1.4; }
@media (max-width: 480px) {
	.nahse-news a.nahse-nw-nl__btn { width: 100%; }
}

/* ---------- Motion (only after JS adds .is-motion) ---------- */
.nahse-news.is-motion [data-ns-rev]:not(.is-in),
.nahse-news.is-motion [data-ns-item]:not(.is-in),
.nahse-news.is-motion [data-np-rev]:not(.is-in) { opacity: 0; transform: translateY(24px); }
.nahse-news.is-motion [data-ns-rev],
.nahse-news.is-motion [data-ns-item],
.nahse-news.is-motion [data-np-rev] { transition: opacity .8s var(--nw-ease), transform .8s var(--nw-ease); }
@media (prefers-reduced-motion: reduce) {
	.nahse-news *, .nahse-news *::before, .nahse-news *::after { transition: none !important; animation: none !important; }
}

/* ==========================================================================
 * END: assets/css/nahse-news-common.css
 * ======================================================================== */
