/*
 * News band + partner logo marquee (inc/news-partners.php).
 * Self-contained: own shell widths, AMC tokens from theme.json vars.
 */

/* ---------- News band ---------- */
.amc-newsband { background: var(--wp--preset--color--surface, #FDFBF7); padding: clamp(3rem, 7vw, 5.5rem) 0; }
.amc-newsband__shell { max-width: 1410px; margin: 0 auto; padding: 0 var(--wp--custom--container--gutter); }
.amc-newsband__head { display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem 2rem; flex-wrap: wrap; margin-bottom: clamp(1.4rem, 3vw, 2.2rem); }
.amc-newsband__h2 { margin: 0.6rem 0 0; color: var(--wp--preset--color--secondary, #114E46); font-size: var(--wp--preset--font-size--h-2-sm); font-weight: 700; letter-spacing: -0.02em; line-height: 1.15; }
.amc-newsband__all { color: var(--wp--preset--color--accent, #18675C); font-weight: 700; text-decoration: none; white-space: nowrap; }
.amc-newsband__all:hover { text-decoration: underline; }
.amc-newsband__grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: clamp(1rem, 2vw, 1.6rem); }
.amc-newsband__card { display: flex; flex-direction: column; gap: 0.55rem; background: #fff; border: 1px solid var(--wp--preset--color--border, #E2DFDA); border-radius: 20px; padding: 1.4rem 1.5rem 1.5rem; box-shadow: var(--wp--preset--shadow--card); transition: transform 0.3s ease, box-shadow 0.3s ease; }
.amc-newsband__card:hover { transform: translateY(-4px); box-shadow: 0 26px 54px -26px rgba(17, 78, 70, 0.55); }
.amc-newsband__date { color: var(--wp--preset--color--muted, #6B7473); font-size: 0.82rem; font-weight: 600; letter-spacing: 0.04em; text-transform: uppercase; }
.amc-newsband__title { margin: 0; font-size: 1.12rem; line-height: 1.3; }
.amc-newsband__title a { color: var(--wp--preset--color--secondary, #114E46); text-decoration: none; }
.amc-newsband__title a:hover { color: var(--wp--preset--color--accent, #18675C); }
.amc-newsband__title::after { content: ""; display: block; width: 34px; height: 3px; border-radius: 2px; background: var(--wp--preset--color--primary, #F5C233); margin-top: 0.5rem; }
.amc-newsband__excerpt { margin: 0; color: var(--wp--preset--color--foreground, #5F6463); font-size: 0.95rem; line-height: 1.6; flex: 1; }
.amc-newsband__more { color: var(--wp--preset--color--accent, #18675C); font-weight: 700; font-size: 0.9rem; text-decoration: none; }
.amc-newsband__more:hover { text-decoration: underline; }
@media (max-width: 900px) { .amc-newsband__grid { grid-template-columns: 1fr 1fr; } }
@media (max-width: 620px) { .amc-newsband__grid { grid-template-columns: 1fr; } }

/* ---------- Partner logo marquee ---------- */
.amc-partners { background: var(--wp--preset--color--base, #fff); padding: clamp(1.8rem, 4vw, 2.8rem) 0; border-top: 1px solid var(--wp--preset--color--border, #E2DFDA); border-bottom: 1px solid var(--wp--preset--color--border, #E2DFDA); }
/* .amc-partners prefix + element: on the homepage `.amc-home p { margin: 0 }`
   out-ranks a bare class and was zeroing this margin. */
.amc-partners p.amc-partners__label { margin: 0 auto clamp(2rem, 4vw, 2.6rem); text-align: center; color: var(--wp--preset--color--muted, #6B7473); font-size: 0.74rem; font-weight: 800; letter-spacing: 0.14em; text-transform: uppercase; padding: 0 var(--wp--custom--container--gutter); }
.amc-partners__viewport { overflow: hidden; -webkit-mask-image: linear-gradient(to right, transparent, #000 8%, #000 92%, transparent); mask-image: linear-gradient(to right, transparent, #000 8%, #000 92%, transparent); }
.amc-partners__track { display: flex; width: max-content; animation: amc-partners-scroll 100s linear infinite; }
/* Touch: the marquee runs (owner call, 2026-08-22) — a tap anywhere on the
   strip pauses/resumes it, which is the WCAG 2.2.2 pause mechanism there.
   Reduced-motion still stops it entirely (block at the end of this file). */
.amc-partners.is-paused .amc-partners__track { animation-play-state: paused; }
/* Pause rules kept separate: an unsupported :has() in a combined list would
   invalidate the hover rule with it. :focus-within pauses the moment keyboard
   focus enters, before any link could sit off-screen. */
.amc-partners:hover .amc-partners__track { animation-play-state: paused; }
.amc-partners__viewport:focus-within .amc-partners__track { animation-play-state: paused; }
/* padding-block gives the hover lift (translateY(-2px)) headroom inside the
   overflow-hidden viewport, so logo tops never clip mid-hover. */
.amc-partners__set { display: flex; align-items: center; gap: clamp(2.2rem, 5vw, 4.5rem); padding: 8px clamp(2.2rem, 5vw, 4.5rem) 8px 0; }
/* Dim only the logo image, never the text — name at 72% deep green fails AA
   contrast on the cream band; full-strength ink passes easily.
   Column layout: the relationship note sits UNDER the logo/name, not beside. */
.amc-partners__item { display: inline-flex; flex-direction: column; align-items: center; gap: 0.5rem; text-decoration: none; color: var(--wp--preset--color--secondary, #114E46); text-align: center; transition: transform 0.25s ease; }
.amc-partners__brand { display: inline-flex; align-items: center; gap: 0.6rem; }
.amc-partners__item:hover, .amc-partners__item:focus-visible { transform: translateY(-2px); }
.amc-partners__item img { display: block; height: 52px; width: auto; opacity: 0.72; filter: grayscale(1); transition: opacity 0.25s ease, filter 0.25s ease; }
.amc-partners__item:hover img, .amc-partners__item:focus-visible img { opacity: 1; filter: grayscale(0); }
.amc-partners__mark { color: var(--wp--preset--color--primary, #F5C233); font-size: 0.72em; }
.amc-partners__name { font-weight: 700; font-size: 1.05rem; white-space: nowrap; letter-spacing: -0.01em; }
/* Badges rest grey like the grayscaled logos, then turn brand gold on hover —
   in step with the logo regaining its colour. */
.amc-partners__note { font-size: 0.72rem; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: var(--wp--preset--color--muted, #6B7473); background: var(--wp--preset--color--surface-alt, #EFECE5); border: 1px solid var(--wp--preset--color--border, #E2DFDA); border-radius: 999px; padding: 0.25em 0.7em; margin-top: 0.35rem; white-space: nowrap; transition: background 0.25s ease, color 0.25s ease; }
.amc-partners__item:hover .amc-partners__note,
.amc-partners__item:focus-visible .amc-partners__note { background: var(--wp--preset--color--primary, #F5C233); color: var(--wp--preset--color--gold-ink); }

@keyframes amc-partners-scroll {
	from { transform: translateX(0); }
	to { transform: translateX(-50%); }
}

@media (prefers-reduced-motion: reduce) {
	.amc-partners__track { animation: none; width: auto; flex-wrap: wrap; justify-content: center; }
	.amc-partners__set { flex-wrap: wrap; justify-content: center; padding-right: 0; }
	.amc-partners__set[aria-hidden="true"] { display: none; }
	.amc-partners__viewport { -webkit-mask-image: none; mask-image: none; }
	.amc-newsband__card { transition: none; }
}

/* News cards reveal with motion only, never an opacity fade: Lighthouse's
   deterministic mobile pass samples this band mid-transition, and blended
   text (~0.75 opacity) fails AA contrast that the settled colors pass. */
.js .amc-newsband__grid .amc-reveal { opacity: 1; }
