/* Maria for Senate CMS — components added on top of styles.css */
[hidden] { display: none !important; }
.admin-notice { background: var(--red); color: #fff; text-align: center; font-size: .8rem; padding: .45rem 1rem; font-weight: 700; }
.admin-notice a { color: #fff; }

/* Header fits extra menu items */
nav a { white-space: nowrap; }
@media (min-width: 861px) and (max-width: 1280px) { nav { gap: .85rem; } nav a { font-size: .84rem; } .brand img { width: 130px; } .brand span { display: none; } }

/* Numbers strip */
.stats-strip { padding: 3.2rem max(4vw, calc((100vw - 1140px)/2)); background: white; border-bottom: 1px solid var(--line); }
.stats-strip .eyebrow { color: var(--red); }
.stats-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(170px, 1fr)); border-top: 1px solid var(--line); }
.stat-item { display: flex; flex-direction: column; gap: .35rem; padding: 1.5rem 1.5rem .5rem 0; border-right: 1px solid var(--line); }
.stat-item + .stat-item { padding-left: 1.5rem; }
.stat-item:last-child { border-right: 0; }
.stat-item strong { font: 800 clamp(2.4rem, 4.5vw, 3.8rem)/1 "Manrope", sans-serif; letter-spacing: -.06em; color: var(--forest); font-variant-numeric: tabular-nums; }
.stat-item span { color: var(--muted); font-size: .85rem; font-weight: 600; }

/* Material cards */
.mgrid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.1rem; }
.mcard { display: flex; flex-direction: column; background: white; border: 1px solid var(--line); box-shadow: 0 12px 32px rgba(4,59,43,.06); transition: transform .22s, box-shadow .22s; min-width: 0; }
.mcard:hover { transform: translateY(-4px); box-shadow: 0 18px 42px rgba(4,59,43,.12); }
.mcard.is-featured { border-color: var(--lime); box-shadow: 0 0 0 2px var(--lime), 0 14px 36px rgba(4,59,43,.1); }
.mcard-media { position: relative; aspect-ratio: 4 / 3; background: #0b2e23; overflow: hidden; }
.mcard-media > a, .mcard-media > button { display: block; width: 100%; height: 100%; padding: 0; border: 0; background: none; cursor: pointer; }
.mcard-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.mcard:hover .mcard-media img { transform: scale(1.04); }
.mcard-media[data-kind="image"] img { object-fit: contain; background: repeating-conic-gradient(#f1f1ec 0 25%, #fff 0 50%) 0 0 / 20px 20px; }
.mcard-media video, .mcard-media .video-embed { width: 100%; height: 100%; background: #000; }
.mcard-media video { object-fit: contain; }
.mcard-tile { width: 100%; height: 100%; display: flex; flex-direction: column; justify-content: flex-end; gap: .25rem; padding: 1.2rem; color: white; text-decoration: none; background: linear-gradient(140deg, var(--forest) 0%, var(--forest-2) 100%); position: relative; }
.mcard-tile::before { content: ""; position: absolute; right: -20%; top: -30%; width: 75%; aspect-ratio: 1; border-radius: 50%; border: 18px solid rgba(167,214,61,.22); }
.mcard-media[data-kind="audio"] .mcard-tile { background: linear-gradient(140deg, var(--red), #8f1621); }
.mcard-media[data-kind="video"] .mcard-tile, .mcard-media[data-kind="youtube"] .mcard-tile { background: linear-gradient(140deg, #13231d, #2b4238); }
.mcard-media[data-kind="pdf"] .mcard-tile { background: linear-gradient(140deg, #3a2a24, #6b4a3e); }
.mcard-media > .mcard-tile, .mcard-play .mcard-tile { display: flex; }
.mcard-tile b { font: 800 clamp(1.8rem, 3.2vw, 2.6rem)/1 "Manrope", sans-serif; letter-spacing: -.04em; position: relative; }
.mcard-tile i { font-style: normal; font-size: .68rem; font-weight: 700; letter-spacing: .12em; text-transform: uppercase; color: var(--lime); position: relative; }
.mcard-tile.large { min-height: 420px; }
.mcard-badge, .mcard-flag { position: absolute; left: .75rem; top: .75rem; padding: .25rem .6rem; border-radius: 999px; background: rgba(4,59,43,.85); color: white; font-size: .62rem; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.mcard-flag { left: auto; right: .75rem; background: var(--lime); color: var(--forest); }
.mcard-badge { opacity: 0; transition: opacity .2s; }
.mcard:hover .mcard-badge, .mcard-zoom:focus-visible .mcard-badge { opacity: 1; }
.play-icon { position: absolute; left: 50%; top: 50%; width: 64px; height: 64px; margin: -32px 0 0 -32px; border-radius: 50%; background: rgba(255,255,255,.94); box-shadow: 0 10px 30px rgba(0,0,0,.3); transition: transform .2s; }
.play-icon::after { content: ""; position: absolute; left: 26px; top: 20px; border-left: 20px solid var(--forest); border-top: 12px solid transparent; border-bottom: 12px solid transparent; }
.mcard-play:hover .play-icon { transform: scale(1.08); }
.mcard-body { flex: 1; padding: 1rem 1.1rem .4rem; min-width: 0; }
.mcard-body small { color: var(--red); font-weight: 800; text-transform: uppercase; letter-spacing: .08em; font-size: .63rem; }
.mcard-body h3, .mcard-body h2 { margin: .3rem 0 .25rem; font-size: 1.05rem; line-height: 1.25; overflow-wrap: anywhere; }
.mcard-body h3 a, .mcard-body h2 a { text-decoration: none; }
.mcard-body h3 a:hover, .mcard-body h2 a:hover { color: var(--forest-2); text-decoration: underline; }
.mcard-body p { margin: 0; color: var(--muted); font-size: .74rem; }
.mcard-body audio { width: 100%; height: 38px; margin-top: .8rem; }
.mcard-actions { display: flex; align-items: center; gap: .5rem; margin: .5rem 1.1rem 0; padding: .8rem 0 1rem; border-top: 1px solid var(--line); }
.mcard-download { margin-right: auto; display: inline-flex; align-items: center; gap: .35rem; padding: .55rem .95rem; border-radius: 999px; background: var(--forest); color: white; font-size: .76rem; font-weight: 800; text-decoration: none; }
.mcard-download:hover { background: var(--forest-2); }
.mcard-link { padding: .5rem .7rem; border: 1px solid var(--line); border-radius: 999px; background: transparent; color: var(--forest); font: 800 .72rem "DM Sans", sans-serif; text-decoration: none; cursor: pointer; }
.mcard-link:hover { border-color: var(--forest); }
.mgrid .materials-empty { grid-column: 1 / -1; }
.materials-more { margin-top: 2rem; text-align: center; }
.materials-filters a { flex: 0 0 auto; white-space: nowrap; display: inline-flex; align-items: center; gap: .35rem; min-height: 42px; padding: .55rem 1rem; border: 1px solid var(--line); border-radius: 999px; color: var(--forest); font: 800 .75rem "DM Sans", sans-serif; text-decoration: none; }
.materials-filters a span { font-size: .65rem; opacity: .6; }
.materials-filters a[aria-current="page"] { color: white; background: var(--forest); border-color: var(--forest); }

/* Inner page banner */
.page-banner { background: var(--forest); color: white; padding: 5rem max(4vw, calc((100vw - 1140px)/2)) 4rem; position: relative; overflow: hidden; }
.page-banner::after { content: ""; position: absolute; right: -6vw; bottom: -18vw; width: 38vw; aspect-ratio: 1; border-radius: 50%; border: 3vw solid rgba(167,214,61,.16); }
.page-banner-inner { position: relative; z-index: 1; max-width: 820px; }
.page-banner .eyebrow { color: var(--lime); }
.page-banner h1 { font-size: clamp(2.6rem, 6vw, 5rem); margin-bottom: 1rem; }
.page-banner p:last-child { color: #b9cbc4; font-size: 1.08rem; max-width: 640px; margin: 0; }
.is-inner .section { padding-top: 4rem; padding-bottom: 5.5rem; }
.materials-toolbar { display: flex; flex-wrap: wrap; justify-content: space-between; align-items: center; gap: 1rem; margin-bottom: 1.5rem; }
.materials-toolbar .materials-filters { margin: 0; }
.materials-search { display: flex; border: 1px solid var(--line); border-radius: 999px; background: white; overflow: hidden; }
.materials-search input { border: 0; padding: .7rem 1rem; font: inherit; min-width: 200px; background: transparent; }
.materials-search button { border: 0; padding: 0 1.1rem; background: var(--forest); color: white; font-weight: 800; cursor: pointer; }
.materials-count { color: var(--muted); }
.pager { display: flex; justify-content: center; align-items: center; gap: 1.2rem; margin-top: 2.5rem; font-weight: 700; }
.pager a { color: var(--forest); }
.pager span { color: var(--muted); font-size: .85rem; }

/* Material detail */
.crumbs { font-size: .8rem; color: var(--muted); margin-bottom: 1.5rem; }
.crumbs a { color: var(--forest); font-weight: 700; text-decoration: none; }
.material-detail-grid { display: grid; grid-template-columns: 1.25fr .75fr; gap: clamp(1.5rem, 4vw, 4rem); align-items: start; }
.material-preview { background: #0b2e23; border: 1px solid var(--line); box-shadow: var(--shadow); min-height: 300px; display: grid; place-items: center; overflow: hidden; }
.material-preview > button { border: 0; padding: 0; background: none; cursor: zoom-in; width: 100%; }
.material-preview img { width: 100%; max-height: 78vh; object-fit: contain; background: #fff; }
.material-preview video { width: 100%; max-height: 78vh; background: #000; }
.video-embed { position: relative; width: 100%; aspect-ratio: 16 / 9; }
.video-embed iframe { position: absolute; inset: 0; width: 100%; height: 100%; border: 0; }
.audio-stage { width: 100%; display: grid; }
.audio-stage > img, .audio-stage > .mcard-tile { aspect-ratio: 16 / 10; height: auto; object-fit: cover; }
.audio-stage audio { width: 100%; background: white; }
.pdf-frame { width: 100%; height: 78vh; min-height: 520px; background: white; }
.pdf-fallback { padding: 2rem; color: white; }
.material-info h1 { font-size: clamp(2rem, 4vw, 3.2rem); letter-spacing: -.05em; margin-bottom: 1rem; overflow-wrap: anywhere; }
.material-info .eyebrow { color: var(--red); }
.material-desc { color: var(--muted); margin-bottom: 1.5rem; }
.material-meta { display: grid; grid-template-columns: 1fr 1fr; margin: 0 0 1.5rem; border-top: 1px solid var(--line); }
.material-meta div { padding: .8rem 0; border-bottom: 1px solid var(--line); }
.material-meta dt { font-size: .65rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--muted); }
.material-meta dd { margin: 0; font-weight: 700; }
.material-actions { display: flex; flex-wrap: wrap; gap: .6rem; }
.share-row { display: flex; flex-wrap: wrap; align-items: center; gap: .5rem; margin-top: 1.6rem; }
.share-row span { font-size: .7rem; font-weight: 800; letter-spacing: .12em; text-transform: uppercase; color: var(--muted); margin-right: .3rem; }
.share-row a, .share-row button { padding: .5rem .85rem; border: 1px solid var(--line); border-radius: 999px; background: white; color: var(--forest); font: 700 .78rem "DM Sans", sans-serif; text-decoration: none; cursor: pointer; }
.share-row a:hover, .share-row button:hover { border-color: var(--forest); }
.related { margin-top: 4.5rem; }
.related h2, .related-news h2 { font-size: clamp(1.8rem, 3vw, 2.5rem); letter-spacing: -.04em; }

/* News */
.news-home { background: white; }
.news-home .materials-heading { margin-bottom: 2.5rem; }
.news-grid { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 1.5rem; }
.news-card { display: flex; flex-direction: column; background: white; border: 1px solid var(--line); }
.news-card-media { aspect-ratio: 16 / 10; overflow: hidden; background: var(--forest); display: block; }
.news-card-media img { width: 100%; height: 100%; object-fit: cover; transition: transform .5s; }
.news-card:hover .news-card-media img { transform: scale(1.04); }
.news-card-media span { display: block; width: 100%; height: 100%; background: radial-gradient(circle at 80% 20%, rgba(167,214,61,.35), transparent 45%), linear-gradient(140deg, var(--forest), var(--forest-2)); }
.news-card > div { padding: 1.2rem 1.3rem 1.5rem; }
.news-card time { font-size: .7rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--red); }
.news-card h2, .news-card h3 { margin: .45rem 0 .5rem; font-size: 1.25rem; line-height: 1.2; }
.news-card h2 a, .news-card h3 a { text-decoration: none; }
.news-card h2 a:hover, .news-card h3 a:hover { text-decoration: underline; }
.news-card p { margin: 0; color: var(--muted); font-size: .92rem; }
.article { max-width: 860px; margin: 0 auto; }
.article-head h1 { font-size: clamp(2.4rem, 5vw, 4rem); letter-spacing: -.055em; margin: .6rem 0 1rem; }
.article-head time { font-size: .75rem; font-weight: 800; letter-spacing: .1em; text-transform: uppercase; color: var(--red); }
.article-lead { font-size: 1.2rem; color: var(--muted); }
.article-image { margin: 2rem 0; }
.article-image img { width: 100%; max-height: 560px; object-fit: cover; }
.prose { font-size: 1.07rem; line-height: 1.8; }
.prose h2 { font-size: 1.8rem; margin: 2.2rem 0 .8rem; letter-spacing: -.03em; }
.prose h3 { font-size: 1.35rem; margin: 1.8rem 0 .6rem; }
.prose img { height: auto; margin: 1.5rem 0; }
.prose a { color: var(--forest-2); font-weight: 700; }
.prose blockquote { margin: 1.8rem 0; padding: .5rem 0 .5rem 1.4rem; border-left: 4px solid var(--lime); font: 700 1.3rem/1.45 "Manrope", sans-serif; color: var(--forest); }
.prose iframe { width: 100%; aspect-ratio: 16 / 9; height: auto; border: 0; }
.prose table { width: 100%; border-collapse: collapse; }
.prose td, .prose th { border: 1px solid var(--line); padding: .55rem .7rem; text-align: left; }
.draft-flag { display: inline-block; padding: .35rem .8rem; background: #fff3cd; color: #7a5a00; font-weight: 700; font-size: .8rem; border-radius: 4px; }
.notfound { display: flex; flex-wrap: wrap; gap: .8rem; justify-content: center; }

/* Contact */
.contact-layout { display: grid; grid-template-columns: .8fr 1.2fr; gap: clamp(1.5rem, 5vw, 5rem); align-items: start; }
.contact-aside { display: grid; gap: .75rem; }
.contact-aside > a, .contact-aside > div { display: flex; flex-direction: column; padding: 1.1rem 1.3rem; background: white; border: 1px solid var(--line); text-decoration: none; }
.contact-aside > a:hover { border-color: var(--forest); }
.contact-aside small { color: var(--muted); }
.contact-aside strong { font: 800 1.05rem "Manrope", sans-serif; color: var(--forest); overflow-wrap: anywhere; }
.contact-card { background: white; border: 1px solid var(--line); box-shadow: var(--shadow); padding: clamp(1.4rem, 4vw, 2.6rem); }
.contact-form { display: grid; gap: 1rem; }
.contact-form label { display: grid; gap: .35rem; font-weight: 700; font-size: .88rem; color: var(--forest); }
.contact-form label em { font-style: normal; font-weight: 500; color: var(--muted); }
.contact-form input, .contact-form select, .contact-form textarea { width: 100%; padding: .85rem .95rem; border: 1px solid rgba(4,59,43,.22); border-radius: 6px; font: 1rem "DM Sans", sans-serif; background: #fbfaf6; color: var(--ink); }
.contact-form input:focus, .contact-form select:focus, .contact-form textarea:focus { outline: 2px solid var(--lime); border-color: var(--forest); }
.form-row { display: grid; grid-template-columns: 1fr 1fr; gap: 1rem; }
.contact-form .button { justify-self: start; border: 0; cursor: pointer; font: 800 1rem "DM Sans", sans-serif; }
.form-success { text-align: center; padding: 2rem 0; }
.form-success .home-success-mark { margin: 0 auto 1rem; }

/* Lightbox & toast */
.lightbox { position: fixed; inset: 0; z-index: 2000; display: grid; place-items: center; padding: 4vh 4vw; background: rgba(2,24,17,.92); }
.lightbox figure { margin: 0; max-width: 100%; max-height: 100%; display: flex; flex-direction: column; align-items: center; gap: 1rem; }
.lightbox img { max-width: 92vw; max-height: 76vh; object-fit: contain; background: white; box-shadow: 0 30px 80px rgba(0,0,0,.5); }
.lightbox figcaption { display: flex; flex-wrap: wrap; align-items: center; justify-content: center; gap: 1rem; color: white; }
.lightbox figcaption .button-primary { background: var(--lime); color: var(--forest); }
.lightbox-close { position: absolute; top: 1rem; right: 1rem; width: 48px; height: 48px; border: 0; border-radius: 50%; background: white; color: var(--forest); font-size: 1.8rem; line-height: 1; cursor: pointer; }
.toast { position: fixed; left: 50%; bottom: 1.5rem; z-index: 2100; transform: translate(-50%, 150%); padding: .7rem 1.2rem; border-radius: 999px; background: var(--forest); color: white; font-weight: 700; transition: transform .25s; }
.toast.show { transform: translate(-50%, 0); }

@media (max-width: 1120px) and (min-width: 861px) { .mgrid, .news-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 860px) {
  .mgrid, .news-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .material-detail-grid, .contact-layout { grid-template-columns: 1fr; }
  .stat-item { padding-left: 0 !important; border-right: 0; border-bottom: 1px solid var(--line); padding-bottom: 1.2rem; }
  .stats-grid { grid-template-columns: repeat(2, 1fr); column-gap: 1.2rem; }
}
@media (max-width: 560px) {
  .mgrid, .news-grid { grid-template-columns: 1fr; }
  .form-row { grid-template-columns: 1fr; }
  .materials-search { width: 100%; }
  .materials-search input { min-width: 0; flex: 1; }
  .materials-toolbar .materials-filters { width: 100%; }
  .page-banner { padding-top: 3.5rem; padding-bottom: 3rem; }
  .material-meta { grid-template-columns: 1fr; }
  .pdf-frame { height: 60vh; min-height: 380px; }
}
