/* ============================================================
   ANPA Quintán — Web navegable · layout RESPONSIVE
   (úsase xunto a ../styles.css, que aporta os tokens)
   ============================================================ */

html, body { margin: 0; padding: 0; background: var(--bg); scroll-behavior: smooth; }
body { font-family: var(--font-body); color: var(--ink); }
.site a { color: inherit; text-decoration: none; }
.site a:hover { text-decoration: none; }
.site { min-height: 100vh; display: flex; flex-direction: column; }
.site main { flex: 1; }

/* contedor */
.wrap { width: 100%; max-width: 1180px; margin: 0 auto; padding-inline: 28px; }
@media (max-width: 600px) { .wrap { padding-inline: 18px; } }

.section { padding-block: 64px; }
.section-sm { padding-block: 44px; }
@media (max-width: 700px) { .section { padding-block: 44px; } .section-sm { padding-block: 32px; } }

/* ---------- Barra de avisos ---------- */
.aviso {
  background: var(--gold-100); border-bottom: 1px solid var(--gold);
  display: flex; align-items: center; gap: 11px; padding: 10px 0;
}
.aviso .wrap { display: flex; align-items: center; gap: 11px; }
.aviso-txt { font-size: 14.5px; font-weight: 600; color: var(--gold-600); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.aviso-more { margin-left: auto; font-size: 14px; font-weight: 700; color: var(--gold-600); display: flex; align-items: center; gap: 5px; flex-shrink: 0; }
@media (max-width: 600px) { .aviso-txt { font-size: 13px; } .aviso-more span { display: none; } }

/* ---------- Header ---------- */
.hdr { position: sticky; top: 0; z-index: 50; background: rgba(255,255,255,.92); backdrop-filter: blur(10px); border-bottom: 1px solid var(--line-soft); }
.hdr-inner { display: flex; align-items: center; justify-content: space-between; height: 72px; }
.hdr-brand { display: flex; align-items: center; gap: 11px; }
.hdr-brand .bt { font-family: var(--font-display); font-weight: 800; font-size: 19px; color: var(--blue-900); letter-spacing: -.01em; line-height: 1.05; }
.hdr-brand .bs { font-size: 11px; font-weight: 600; color: var(--ink-mute); }
.hdr-nav { display: flex; align-items: center; gap: 26px; }
.hdr-nav a { font-size: 15.5px; font-weight: 600; color: var(--ink-soft); padding-bottom: 3px; border-bottom: 2px solid transparent; transition: color .12s; white-space: nowrap; }
.hdr-nav a:hover { color: var(--blue-700); }
.hdr-nav a.active { color: var(--blue-700); font-weight: 700; border-bottom-color: var(--gold); }
.hdr-cta { display: inline-flex; }
.hdr-right { display: flex; align-items: center; gap: 14px; }
.burger { display: none; width: 44px; height: 44px; border-radius: 11px; background: var(--bg); color: var(--blue-700); border: 0; cursor: pointer; align-items: center; justify-content: center; }

@media (max-width: 1000px) {
  .hdr-nav, .hdr-right { display: none; }
  .burger { display: inline-flex; }
  .hdr-brand .bs { display: none; }
}

/* menú móbil */
.msheet { position: fixed; inset: 0; z-index: 60; background: rgba(15,50,69,.4); opacity: 0; pointer-events: none; transition: opacity .2s; }
.msheet.open { opacity: 1; pointer-events: auto; }
.msheet-panel { position: absolute; top: 0; right: 0; height: 100%; width: min(82vw, 340px); background: #fff; box-shadow: var(--sh-lg); transform: translateX(100%); transition: transform .24s ease; display: flex; flex-direction: column; padding: 20px; }
.msheet.open .msheet-panel { transform: translateX(0); }
.msheet-panel a { font-size: 18px; font-weight: 600; color: var(--ink); padding: 14px 8px; border-bottom: 1px solid var(--line-soft); display: flex; align-items: center; justify-content: space-between; }
.msheet-panel a.active { color: var(--blue-700); font-weight: 800; }

/* ---------- Hero (Variante A) ---------- */
.hero { background: var(--paper); }
.hero-grid { display: grid; grid-template-columns: 1.05fr 1fr; gap: 50px; align-items: center; padding-block: 56px; }
.hero h1 { font-size: clamp(34px, 5vw, 58px); font-weight: 800; line-height: 1.02; }
.hero-media { position: relative; }
@media (max-width: 860px) {
  .hero-grid { grid-template-columns: 1fr; gap: 30px; padding-block: 36px; }
  .hero-media { order: -1; }
}

/* ---------- Grellas ---------- */
.svc-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
@media (max-width: 940px) { .svc-grid { grid-template-columns: repeat(2, 1fr); gap: 14px; } }

.news-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 20px; }
.news-grid.cols-3 { grid-template-columns: repeat(3, 1fr); }
@media (max-width: 940px) { .news-grid, .news-grid.cols-3 { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 560px) { .news-grid, .news-grid.cols-3 { grid-template-columns: 1fr; } }

.grid-2 { display: grid; grid-template-columns: 1fr 1fr; gap: 40px; align-items: center; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px; }
@media (max-width: 860px) { .grid-2 { grid-template-columns: 1fr; gap: 28px; } .grid-3 { grid-template-columns: repeat(2,1fr); } }
@media (max-width: 560px) { .grid-3 { grid-template-columns: 1fr; } .asemblea-card { grid-column: span 1 !important; } }

/* contido + lateral pegañento */
.with-aside { display: grid; grid-template-columns: 1fr 350px; gap: 38px; align-items: start; }
.aside { position: sticky; top: 92px; display: flex; flex-direction: column; gap: 18px; }
@media (max-width: 900px) { .with-aside { grid-template-columns: 1fr; } .aside { position: static; } }

.doc-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
@media (max-width: 900px) { .doc-grid { grid-template-columns: repeat(2,1fr); } }
@media (max-width: 560px) { .doc-grid { grid-template-columns: 1fr; } }

.act-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 18px; }
@media (max-width: 1000px) { .act-grid { grid-template-columns: repeat(3,1fr); } }
@media (max-width: 760px) { .act-grid { grid-template-columns: repeat(2,1fr); } }
@media (max-width: 460px) { .act-grid { grid-template-columns: 1fr; } }

/* ---------- Cabeceira de páxina interior ---------- */
.phero { color: #fff; position: relative; overflow: hidden; }
.phero.blue { background: var(--blue-700); }
.phero.green { background: var(--green-600); }
.phero-body { padding-block: 46px 54px; position: relative; max-width: 720px; }
.phero h1 { color: #fff; font-size: clamp(30px, 4.6vw, 46px); margin-top: 12px; }
.phero .deco { position: absolute; border-radius: 50%; background: rgba(255,255,255,.06); }

/* ---------- helpers ---------- */
.row { display: flex; align-items: center; gap: 12px; }
.col { display: flex; flex-direction: column; }
.stat-num { font-family: var(--font-display); font-weight: 800; font-size: 30px; color: var(--green-600); line-height: 1; }
.flbadge { position: absolute; bottom: -22px; left: -18px; background: var(--paper); border-radius: var(--r-md); padding: 13px 17px; box-shadow: var(--sh-lg); display: flex; align-items: center; gap: 12px; }
@media (max-width: 860px) { .flbadge { left: 16px; } }
.cta-band { background: var(--green-600); border-radius: var(--r-xl); padding: 40px 44px; display: grid; grid-template-columns: 1.3fr 1fr; gap: 40px; align-items: center; color: #fff; }
@media (max-width: 820px) { .cta-band { grid-template-columns: 1fr; padding: 30px; gap: 26px; } }
.feat-news { display: grid; grid-template-columns: 1.1fr 1fr; background: var(--paper); border-radius: var(--r-lg); overflow: hidden; border: 1px solid var(--line-soft); box-shadow: var(--sh-md); }
@media (max-width: 820px) { .feat-news { grid-template-columns: 1fr; } }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }
@media (max-width: 560px) { .form-grid { grid-template-columns: 1fr; } }
.contact-grid { display: grid; grid-template-columns: 1.2fr 1fr; gap: 40px; }
@media (max-width: 860px) { .contact-grid { grid-template-columns: 1fr; gap: 26px; } }

a.cardlink { display: block; transition: transform .14s ease, box-shadow .14s ease; }
a.cardlink:hover { transform: translateY(-3px); }
a.cardlink:hover .svc-card, a.cardlink:hover .news-card { box-shadow: var(--sh-lg); }
.hide-720 { display: initial; }
@media (max-width: 720px) { .hide-720 { display: none; } }
