/* ==========================================================================
   News & Updates (shortcodes in inc/news.php)
   Uses the "Academic Proceedings" tokens and Elementor Global Fonts/Colors
   ========================================================================== */

.evo-news { display: grid; gap: var(--sp-40); }

/* Topic filter */
.evo-news-filters {
	display: flex; flex-wrap: wrap; gap: 8px;
	padding-bottom: var(--sp-24); border-bottom: 1px solid var(--c-navy-100);
}
.evo-filter {
	display: inline-flex; align-items: center; gap: .55rem;
	padding: .6rem .9rem; border-radius: var(--r-xs);
	background: var(--c-white); color: var(--c-navy);
	box-shadow: inset 0 0 0 1px var(--c-navy-200);
	font-family: var(--e-global-typography-label-font-family), ui-monospace, monospace;
	font-size: var(--e-global-typography-label-font-size);
	font-weight: 500; letter-spacing: .06em; text-transform: uppercase; line-height: 1;
	text-decoration: none; transition: box-shadow .2s, background-color .2s, color .2s;
}
.evo-filter span {
	display: inline-grid; place-items: center; min-width: 1.5rem; height: 1.5rem; padding: 0 .35rem;
	background: var(--c-navy-50); color: var(--c-muted); border-radius: var(--r-xs);
	font-size: .7rem; letter-spacing: 0;
}
.evo-filter:hover { box-shadow: inset 0 0 0 1px var(--c-navy); color: var(--c-navy); }
.evo-filter.is-active { background: var(--c-navy); color: var(--c-white); box-shadow: inset 0 -3px 0 var(--c-accent); }
.evo-filter.is-active span { background: rgba(255, 255, 255, .14); color: var(--c-white); }

/* Card */
.evo-news-card {
	position: relative; display: flex; flex-direction: column; overflow: hidden;
	background: var(--c-white); border: 1px solid var(--c-navy-100); border-radius: var(--r-lg);
	transition: border-color .25s, transform .25s, box-shadow .25s;
}
.evo-news-card::after {
	content: ""; position: absolute; left: 0; right: 0; bottom: 0; height: 3px;
	background: var(--c-accent); transform: scaleX(0); transform-origin: left; transition: transform .3s;
	pointer-events: none;
}
.evo-news-card:hover { border-color: var(--c-navy-200); transform: translateY(-2px); box-shadow: var(--shadow-soft); }
.evo-news-card:hover::after { transform: scaleX(1); }

.evo-news-media { display: block; aspect-ratio: 3 / 2; overflow: hidden; background: var(--c-navy-50); border-bottom: 1px solid var(--c-navy-100); }
.evo-news-media img { width: 100%; height: 100%; object-fit: cover; display: block; transition: transform .6s ease; }
.evo-news-card:hover .evo-news-media img { transform: scale(1.03); }
.evo-news-placeholder { display: block; width: 100%; height: 100%; background: var(--c-navy-50); }

.evo-news-body { display: grid; gap: .75rem; align-content: start; flex: 1; padding: var(--sp-24); }
.evo-news-meta { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem .8rem; }
.evo-news-meta .evo-chip { text-decoration: none; }
.evo-news-meta .evo-chip:hover { box-shadow: inset 0 0 0 1px var(--c-navy); }
.evo-news-date {
	color: var(--c-muted);
	font-family: var(--e-global-typography-label-font-family), ui-monospace, monospace;
	font-size: var(--e-global-typography-label-font-size);
	letter-spacing: .04em; text-transform: uppercase;
}

.evo-news-title {
	margin: 0; color: var(--c-navy); text-wrap: balance;
	font-family: var(--e-global-typography-h3-font-family), sans-serif;
	font-size: var(--e-global-typography-h3-font-size);
	font-weight: var(--e-global-typography-h3-font-weight);
	line-height: var(--e-global-typography-h3-line-height);
	letter-spacing: var(--e-global-typography-h3-letter-spacing);
}
.evo-news-title a {
	color: inherit; text-decoration: none;
	background-image: linear-gradient(var(--c-accent), var(--c-accent));
	background-size: 0 2px; background-position: 0 100%; background-repeat: no-repeat;
	transition: background-size .3s;
}
.evo-news-card:hover .evo-news-title a,
.evo-news-title a:focus-visible { background-size: 100% 2px; }
.evo-news-excerpt {
	margin: 0; color: var(--c-muted);
	font-size: var(--e-global-typography-bodysm-font-size); line-height: 1.6;
	display: -webkit-box; -webkit-line-clamp: 3; -webkit-box-orient: vertical; overflow: hidden;
}
.evo-news-body .evo-link { justify-self: start; margin-top: auto; }

/* Featured (latest) post */
.evo-news-card--featured { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(0, 1fr); }
.evo-news-card--featured .evo-news-media { aspect-ratio: auto; min-height: 360px; height: 100%; border-bottom: 0; border-right: 1px solid var(--c-navy-100); }
.evo-news-card--featured .evo-news-body { padding: var(--sp-48); align-content: center; gap: 1rem; }
.evo-news-card--featured .evo-news-title {
	font-family: var(--e-global-typography-h2-font-family), sans-serif;
	font-size: var(--e-global-typography-h2-font-size);
	font-weight: var(--e-global-typography-h2-font-weight);
	line-height: var(--e-global-typography-h2-line-height);
	letter-spacing: var(--e-global-typography-h2-letter-spacing);
}
.evo-news-card--featured .evo-news-excerpt {
	font-size: var(--e-global-typography-lead-font-size); line-height: 1.65; -webkit-line-clamp: 4;
}
@media (max-width: 900px) {
	.evo-news-card--featured { grid-template-columns: minmax(0, 1fr); }
	.evo-news-card--featured .evo-news-media { aspect-ratio: 16 / 9; min-height: 0; border-right: 0; border-bottom: 1px solid var(--c-navy-100); }
	.evo-news-card--featured .evo-news-body { padding: var(--sp-28); }
}

/* Pagination */
.evo-pagination { display: flex; flex-wrap: wrap; justify-content: center; gap: 6px; }
.evo-page {
	min-width: 44px; height: 44px; padding: 0 .9rem;
	display: inline-grid; place-items: center;
	background: var(--c-white); color: var(--c-navy); text-decoration: none;
	box-shadow: inset 0 0 0 1px var(--c-navy-200); border-radius: var(--r-xs);
	font-family: var(--e-global-typography-label-font-family), ui-monospace, monospace;
	font-size: .85rem; font-weight: 500;
	transition: box-shadow .2s, background-color .2s, color .2s;
}
a.evo-page:hover { box-shadow: inset 0 0 0 1px var(--c-navy); }
.evo-page.is-current { background: var(--c-navy); color: var(--c-white); box-shadow: inset 0 -3px 0 var(--c-accent); }

/* ==========================================================================
   Single post template
   ========================================================================== */

/* Navy header band */
.e-con.evo-post-hero { background-color: var(--c-navy); --padding-top: var(--sp-64); --padding-bottom: var(--sp-64); position: relative; }
.e-con.evo-post-hero::after { content: ""; position: absolute; left: 0; bottom: 0; width: min(38%, 420px); height: var(--tab); background: var(--c-accent); }
.evo-post-head { display: grid; gap: 1rem; max-width: 860px; }
.evo-post-crumbs { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; font-size: var(--e-global-typography-bodysm-font-size); color: var(--on-dark-72); }
.evo-post-crumbs a { color: var(--c-white); font-weight: 600; text-decoration: none; }
.evo-post-crumbs a:hover { text-decoration: underline; text-decoration-color: var(--c-accent); text-underline-offset: .2em; }
.evo-post-head .evo-chip { background: rgba(255, 255, 255, .1); color: var(--c-white); box-shadow: inset 0 0 0 1px rgba(255, 255, 255, .22); text-decoration: none; }
.evo-post-head .evo-chip:hover { box-shadow: inset 0 0 0 1px var(--c-accent); }
.evo-post-head .evo-news-date { color: var(--on-dark-72); }
.evo-post-head h1.evo-post-title,
.evo-post-title {
	margin: 0; color: var(--c-white); text-wrap: balance;
	font-family: var(--e-global-typography-h1-font-family), sans-serif;
	font-size: var(--e-global-typography-h1-font-size);
	font-weight: var(--e-global-typography-h1-font-weight);
	line-height: var(--e-global-typography-h1-line-height);
	letter-spacing: var(--e-global-typography-h1-letter-spacing);
}
.evo-post-lead { margin: 0; max-width: 62ch; color: var(--on-dark-86); font-size: var(--e-global-typography-lead-font-size); line-height: 1.65; }
/* Text on the navy post header must stay light, whatever Site Settings set for h1/p/a */
.evo-post-head h1.evo-post-title { color: var(--c-white); }
.evo-post-head p.evo-post-lead { color: var(--on-dark-86); }
.evo-post-head .evo-post-crumbs a { color: var(--c-white); }
.evo-post-head .evo-news-date { color: var(--on-dark-72); }

/* Featured image */
.evo-post-figure { margin: 0; }
.evo-post-figure img { width: 100%; aspect-ratio: 16 / 9; height: auto; object-fit: cover; border-radius: var(--r-lg); display: block; }
.evo-post-figure figcaption { margin-top: .6rem; color: var(--c-muted); font-size: var(--e-global-typography-bodysm-font-size); }

/* Article text (Elementor Pro Post Content widget with class evo-prose) */
.evo-prose { max-width: 72ch; }
.evo-prose .elementor-widget-container > * { margin-top: 0; margin-bottom: 0; }
.evo-prose .elementor-widget-container > * + * { margin-top: 1.1em; }
.evo-prose p, .evo-prose li { color: var(--c-text); font-size: 1.0625rem; line-height: 1.75; }
.evo-prose h2, .evo-prose h3, .evo-prose h4 { color: var(--c-navy); margin-top: 1.8em !important; }
.evo-prose h2 { font-family: var(--e-global-typography-h2-font-family), sans-serif; font-size: var(--e-global-typography-h2-font-size); font-weight: var(--e-global-typography-h2-font-weight); line-height: var(--e-global-typography-h2-line-height); letter-spacing: var(--e-global-typography-h2-letter-spacing); }
.evo-prose h3 { font-family: var(--e-global-typography-h3-font-family), sans-serif; font-size: var(--e-global-typography-h3-font-size); font-weight: var(--e-global-typography-h3-font-weight); line-height: var(--e-global-typography-h3-line-height); }
.evo-prose h4 { font-family: var(--e-global-typography-h4-font-family), sans-serif; font-size: var(--e-global-typography-h4-font-size); font-weight: var(--e-global-typography-h4-font-weight); }
.evo-prose a { color: var(--c-blue); font-weight: 600; text-decoration: underline; text-decoration-thickness: 1px; text-underline-offset: .2em; }
.evo-prose a:hover { color: var(--c-navy); text-decoration-color: var(--c-accent); text-decoration-thickness: 2px; }
.evo-prose strong { color: var(--c-navy); }
.evo-prose ul, .evo-prose ol { padding-left: 1.4rem; }
.evo-prose ul { list-style: none; padding-left: 0; }
.evo-prose ul li { position: relative; padding-left: 1.4rem; }
.evo-prose ul li + li, .evo-prose ol li + li { margin-top: .45em; }
.evo-prose ul li::before { content: ""; position: absolute; left: 0; top: .72em; width: 8px; height: 8px; background: var(--c-accent); border-radius: 1px; }
.evo-prose blockquote { margin: 1.6em 0; padding: .2em 0 .2em 1.25rem; border-left: var(--tab) solid var(--c-accent); color: var(--c-navy); font-family: var(--e-global-typography-quote-font-family), sans-serif; font-size: var(--e-global-typography-quote-font-size); line-height: 1.45; }
.evo-prose img { border-radius: var(--r-lg); height: auto; }
.evo-prose em { color: var(--c-navy); }

/* Share and back link */
.evo-post-share {
	display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 1rem 2rem;
	max-width: 72ch; padding-top: var(--sp-24); border-top: 1px solid var(--c-navy-100);
}
.evo-post-share-group { display: flex; flex-wrap: wrap; align-items: center; gap: .75rem 1rem; }
.evo-post-share-label {
	font-family: var(--e-global-typography-label-font-family), ui-monospace, monospace;
	font-size: var(--e-global-typography-label-font-size); letter-spacing: .08em; text-transform: uppercase; color: var(--c-muted);
}
.evo-post-share-links { display: flex; gap: 6px; }
.evo-share {
	width: 40px; height: 40px; display: grid; place-items: center;
	background: var(--c-white); color: var(--c-navy); border-radius: var(--r-xs);
	box-shadow: inset 0 0 0 1px var(--c-navy-200); transition: background-color .2s, color .2s, box-shadow .2s;
}
.evo-share svg { width: 18px; height: 18px; fill: currentColor; }
.evo-share:hover { background: var(--c-navy); color: var(--c-white); box-shadow: inset 0 -3px 0 var(--c-accent); }

/* Sidebar */
.e-con.evo-post-aside { position: relative; }
@media (min-width: 1025px) { .evo-post-sidebar { position: sticky; top: 110px; } }
.evo-post-sidebar { display: grid; gap: var(--sp-24); }
.evo-side-block { display: grid; gap: .9rem; padding-top: var(--sp-16); border-top: 2px solid var(--c-navy); }
.evo-side-title {
	margin: 0; color: var(--c-navy);
	font-family: var(--e-global-typography-h4-font-family), sans-serif;
	font-size: var(--e-global-typography-h4-font-size);
	font-weight: var(--e-global-typography-h4-font-weight);
	line-height: var(--e-global-typography-h4-line-height);
}
.evo-side-list { list-style: none; margin: 0; padding: 0; display: grid; }
.evo-side-list li + li { border-top: 1px solid var(--c-navy-100); }
.evo-side-item { display: grid; grid-template-columns: 72px minmax(0, 1fr); gap: .85rem; align-items: center; padding: .8rem 0; text-decoration: none; }
.evo-side-item img, .evo-side-item .evo-news-placeholder { width: 72px; height: 54px; object-fit: cover; border-radius: var(--r-xs); display: block; }
.evo-side-item > span { display: grid; gap: .25rem; }
.evo-side-item-title { color: var(--c-navy); font-weight: 600; font-size: .95rem; line-height: 1.35; }
.evo-side-item:hover .evo-side-item-title { color: var(--c-blue); }
.evo-side-topics { display: flex; flex-wrap: wrap; gap: 6px; }
.evo-side-cta { display: grid; gap: .75rem; padding: var(--sp-24); background: var(--c-navy-50); border-left: var(--tab) solid var(--c-accent); border-radius: var(--r-xs); }
.evo-side-cta p { margin: 0; color: var(--c-muted); font-size: var(--e-global-typography-bodysm-font-size); }

@media (prefers-reduced-motion: reduce) {
	.evo-news-card, .evo-news-card::after, .evo-news-media img, .evo-news-title a, .evo-filter, .evo-page, .evo-share { transition: none; }
}
