/*
Theme Name: Vías Verdes Theme
Description: Tema modular basado en bloques para las Vías Verdes de la Región de Murcia.
Version: 1.5
Author: Antigravity
*/

:root {
  --green-dark: #1a4d2e;
  --green: #4a8c3f;
  --green-light: #62a855;
  --gold: #d4af37;
  --gold-light: #eac64f;
  --orange: #e89520;
  --cream: #f9fbf2;
  --charcoal: #222;
  --dark: #111;
  --muted: #666;
  --border: #ddd;
  
  /* Colores Vías Verdes */
  --vv1: #4a8c3f; --vv2: #c0392b; --vv3: #2980b9; --vv4: #d35400;
  --vv5: #27ae60; --vv6: #16a085; --vv7: #8e6914; --vv8: #6c3483;
}

body { font-family: 'Lato', sans-serif; color: var(--charcoal); margin: 0; line-height: 1.6; }
h1, h2, h3, h4 { font-family: 'Playfair Display', serif; font-weight: 700; margin: 0; }

/* ── TOP BAR ── */
.top-bar { display: flex; justify-content: space-between; align-items: center; padding: 10px 32px; border-bottom: 1px solid var(--border); }
.logo-vv { border-left: 4px solid var(--gold); padding-left: 12px; }
.logo-vv-top { font-family: 'Playfair Display', serif; font-weight: 700; font-size: 15px; text-transform: uppercase; line-height: 1.2; color: var(--gold); }
.logo-vv-bottom { font-size: 11px; text-transform: uppercase; letter-spacing: 2px; }

/* ── MEGA MENU ── */
.main-nav { height: 44px; border-bottom: 1px solid var(--border); background: #fff; position: relative; z-index: 300; display: flex; align-items: center; padding: 0 32px; }
.main-nav ul { list-style: none; display: flex; height: 100%; margin: 0; padding: 0; }
.main-nav .has-dropdown:hover .dropdown-panel { display: block; }
.dropdown-panel {
  display: none; position: fixed; top: 104px; left: 0; width: 100vw;
  background: #fff; border-top: 3px solid var(--gold); border-bottom: 1px solid var(--border);
  box-shadow: 0 12px 32px rgba(0,0,0,.13); z-index: 200; padding: 28px 48px;
}
.dropdown-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px 20px; }
.dropdown-item { display: flex; align-items: center; gap: 12px; text-decoration: none; padding: 10px; border-radius: 4px; transition: background .2s; }
.dropdown-item:hover { background: #f9f9f9; }
.dropdown-thumb-placeholder { width: 36px; height: 36px; border-radius: 50%; flex-shrink: 0; }
.dropdown-label { font-size: 13px; font-weight: 700; color: var(--dark); }

/* ── HERO GRID ── */
.vias-verdes-hero { margin-bottom: 60px; }
.vias-verdes-hero-top { background-size: cover; background-position: center; color: white; padding: 120px 0 60px; position: relative; }
.vias-verdes-hero-title { font-size: 4em; text-shadow: 2px 2px 6px rgba(0,0,0,0.5); }
.vias-verdes-hero-grid { display: grid; grid-template-columns: repeat(8, 1fr); gap: 1px; background: var(--border); border-top: 1px solid var(--border); }
.vias-verdes-hero-item { background: #fff; padding: 20px 15px; cursor: pointer; transition: all .2s; display: flex; flex-direction: column; align-items: center; text-align: center; gap: 8px; }
.vias-verdes-hero-item:hover, .vias-verdes-hero-item.vias-verdes-item-active { background: var(--cream); }
.vias-verdes-item-icon { font-size: 24px; }
.vias-verdes-item-title { font-family: 'Playfair Display', serif; font-size: 13px; font-weight: 700; color: var(--green-dark); }
.vias-verdes-item-desc { font-size: 10px; color: var(--muted); margin: 0; line-height: 1.2; }

/* --- BANNERS CTA --- */
.cta-strip { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; max-width: 1060px; margin: 52px auto; padding: 0 16px; }
.cta-banner { position: relative; height: 220px; overflow: hidden; display: flex; flex-direction: column; justify-content: flex-end; text-decoration: none; }
.cta-banner-bg { position: absolute; inset: 0; background-size: cover; transition: transform .4s; }
.cta-banner:hover .cta-banner-bg { transform: scale(1.04); }

/* --- SECCIONES GENERALES --- */
.hs-inner { max-width: 1060px; margin: 0 auto; padding: 52px 16px; }
.section-header { display: flex; justify-content: space-between; border-bottom: 2px solid var(--border); margin-bottom: 28px; padding-bottom: 14px; }

/* ── NOTICIAS ── */
.news-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }
.news-card { background: #fff; border: 1px solid var(--border); overflow: hidden; display: flex; flex-direction: column; text-decoration: none; transition: all .15s; }
.news-card:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(0,0,0,.1); }
.news-card-img { height: 160px; background-size: cover; background-position: center; }
.news-card-body { padding: 16px 18px; flex: 1; display: flex; flex-direction: column; }
.news-card-title { font-size: 1rem; color: var(--green-dark); line-height: 1.3; margin-bottom: 8px; }

/* ── INSTITUCIONES ── */
.inst-strip { border-top: 1px solid var(--border); padding: 28px 0; margin-top: 52px; }
.inst-logos { display: flex; flex-wrap: wrap; }
.inst-logo-item { flex: 1; min-width: 120px; border-right: 1px solid var(--border); padding: 14px; text-align: center; }
.inst-logo-item:last-child { border-right: none; }

/* --- FOOTER --- */
footer { background: #111a11; color: #fff; padding: 60px 40px 40px; }
.footer-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 40px; max-width: 1200px; margin: 0 auto; }
.footer-logo-circle { border-left: 3px solid var(--gold); padding-left: 15px; margin-bottom: 20px; }
.fl-main { display: block; font-family: 'Playfair Display', serif; font-size: 24px; font-weight: 900; line-height: 1; }
.fl-sub { display: block; font-family: 'Lato', sans-serif; font-size: 14px; text-transform: uppercase; letter-spacing: 2px; }
.fl-tag { font-size: 10px; color: var(--gold); }
.footer-tagline { font-size: 13px; color: #8a9a8a; margin-bottom: 15px; }
.footer-email a { color: var(--gold); text-decoration: none; font-size: 12px; }
.footer-links, .footer-legal { display: flex; flex-direction: column; gap: 10px; }
.footer-links a, .footer-legal a { color: #8a9a8a; text-decoration: none; font-size: 12px; transition: color .2s; }
.footer-links a:hover, .footer-legal a:hover { color: #fff; }
.gov-badge { background: #fff; color: #000; padding: 10px; border-radius: 4px; display: inline-block; margin-top: 20px; }
.footer-divider { border: 0; border-top: 1px solid #2d3d2d; margin: 40px 0 30px; }
.footer-bottom { display: flex; justify-content: space-between; align-items: center; max-width: 1200px; margin: 0 auto; }
.footer-credits { font-size: 11px; color: #5a6a5a; }
.social-icons { display: flex; gap: 15px; }
.social-icon { width: 32px; height: 32px; border-radius: 50%; border: 1px solid #2d3d2d; display: flex; align-items: center; justify-content: center; color: #fff; text-decoration: none; font-size: 14px; }

/* --- ACTUALIDAD Y AGENDA --- */
.section-block { margin-bottom: 56px; }
.section-header { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: 20px; padding-bottom: 14px; border-bottom: 2px solid var(--border); }
.section-header h2 { font-family: 'Playfair Display', serif; font-size: 1.9rem; font-weight: 700; color: var(--green-dark); }
.vv-filter-bar { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; background: #fff; border: 1px solid var(--border); border-radius: 8px; padding: 14px 18px; margin-bottom: 24px; }
.vv-chip { display: inline-flex; align-items: center; gap: 5px; font-family: 'Lato', sans-serif; font-size: 11px; font-weight: 700; padding: 5px 12px; border-radius: 999px; cursor: pointer; border: 2px solid transparent; transition: all .18s; background: #f2f5f2; color: var(--charcoal); }
.vv-chip.active { color: #fff; background: var(--green-dark); }
.chip-dot { width: 8px; height: 8px; border-radius: 50%; }
.event-card { background: #fff; border: 1px solid var(--border); display: grid; grid-template-columns: 72px 1fr auto; align-items: stretch; margin-bottom: 8px; transition: box-shadow .2s; overflow: hidden; }
.event-date { display: flex; flex-direction: column; align-items: center; justify-content: center; padding: 16px 8px; border-right: 1px solid var(--border); }
.event-day { font-family: 'Lato', sans-serif; font-size: 2rem; font-weight: 900; line-height: 1; }
.event-body { padding: 14px 18px; }
.event-type-tag { display: inline-flex; padding: 2px 8px; border-radius: 3px; color: #fff; font-size: 9px; font-weight: 700; text-transform: uppercase; margin-bottom: 7px; }
.news-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.news-card { background: #fff; border: 1px solid var(--border); overflow: hidden; display: flex; flex-direction: column; transition: all .2s; }
.news-card.featured { grid-column: span 2; flex-direction: row; }
.news-img { width: 100%; height: 180px; background-size: cover; background-position: center; }
.news-card.featured .news-img { width: 45%; height: auto; }
.news-body { padding: 18px 20px; flex: 1; }
.news-title { font-family: 'Playfair Display', serif; font-size: 1.1rem; font-weight: 700; color: var(--green-dark); margin-bottom: 8px; }

/* --- EL CONSORCIO --- */
.legal-intro { background: #fff; border: 1px solid var(--border); border-left: 4px solid var(--green); padding: 28px 32px; margin-bottom: 32px; }
.docs-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.doc-card { background: #fff; border: 1px solid var(--border); display: flex; align-items: flex-start; gap: 14px; padding: 16px 18px; transition: box-shadow .2s; }
.doc-icon { width: 36px; height: 36px; border-radius: 50%; flex-shrink: 0; display: flex; align-items: center; justify-content: center; }
.nosotros-layout { display: grid; grid-template-columns: 1fr 340px; gap: 32px; align-items: start; }
.nosotros-text { background: #fff; border: 1px solid var(--border); padding: 32px 36px; }
.kpi-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.kpi-cell { background: #fff; border: 1px solid var(--border); padding: 18px 16px; text-align: center; }
.kpi-val { font-family: 'Playfair Display', serif; font-size: 2rem; font-weight: 700; color: var(--green-dark); }
.contacto-card { background: #fff; border: 1px solid var(--border); border-top: 4px solid var(--green); padding: 22px; }

/* --- DETALLE DE NOTICIA --- */
.news-hero { position: relative; width: 100%; height: 500px; overflow: hidden; background: #0a1a0a; }
.news-hero-bg { position: absolute; inset: 0; background-size: cover; background-position: center; opacity: .7; transition: transform 8s ease; }
.news-hero-overlay { position: absolute; inset: 0; background: linear-gradient(to top, rgba(0,0,0,.9) 0%, rgba(0,0,0,.5) 45%, rgba(0,0,0,.1) 100%); }
.news-hero-content { position: absolute; inset: 0; z-index: 10; display: flex; flex-direction: column; justify-content: flex-end; padding: 0 40px 40px; max-width: 860px; }
.news-hero-title { font-family: 'Playfair Display', serif; font-size: 2.9rem; font-weight: 700; color: #fff; line-height: 1.15; text-shadow: 1px 2px 12px rgba(0,0,0,.4); }
.page-layout { max-width: 1020px; margin: 0 auto; padding: 36px 16px 64px; display: grid; grid-template-columns: 1fr 288px; gap: 32px; }
.article-lead { background: var(--vv-light); border-left: 4px solid var(--vv-color); padding: 18px 22px; margin-bottom: 28px; font-family: 'Lato', sans-serif; font-size: 15px; }
.article-body { background: #fff; border: 1px solid var(--border); padding: 32px 36px; }
.pull-quote { border-left: 4px solid var(--vv-color); padding: 16px 24px; background: var(--vv-light); margin: 24px 0; }
.vv-side-card { background: var(--vv-light); border: 1px solid var(--border); border-left: 4px solid var(--vv-color); padding: 16px 18px; }
.share-btns { display: flex; gap: 8px; }
.share-btn { flex: 1; padding: 9px 6px; border: 1px solid var(--border); background: #fff; font-family: 'Lato', sans-serif; font-size: 10px; font-weight: 700; }

/* --- MEJORAS CONSORCIO --- */
.subnav { background: #fff; border-bottom: 1px solid var(--border); position: sticky; top: 44px; z-index: 450; display: flex; overflow-x: auto; }
.subnav-btn { display: flex; align-items: center; gap: 7px; padding: 0 26px; height: 48px; white-space: nowrap; font-family: 'Lato', sans-serif; font-size: 11px; font-weight: 700; letter-spacing: 1.2px; text-transform: uppercase; color: var(--muted); border: none; border-bottom: 3px solid transparent; background: none; cursor: pointer; }
.subnav-btn.active { color: var(--green-dark); border-bottom-color: var(--orange); }
.section-num { font-family: 'Playfair Display', serif; font-size: 4rem; font-weight: 700; color: var(--border); line-height: 1; flex-shrink: 0; margin-left: 20px; }
.enlaces-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.enlace-card { background: #fff; border: 1px solid var(--border); padding: 16px 18px; display: flex; align-items: flex-start; gap: 14px; }
.enlace-escudo { width: 44px; height: 44px; flex-shrink: 0; background: var(--cream); border: 1px solid var(--border); border-radius: 4px; display: flex; align-items: center; justify-content: center; }
.pagination { display: flex; align-items: center; justify-content: center; gap: 6px; margin-top: 28px; }
.pag-btn { width: 32px; height: 32px; border: 1px solid var(--border); background: #fff; font-weight: 700; cursor: pointer; display: flex; align-items: center; justify-content: center; }
.pag-btn.active { background: var(--green-dark); color: #fff; }

/* --- MULTIMEDIA --- */
.section-anchors { background: #fff; border-bottom: 1px solid var(--border); display: flex; position: sticky; top: 44px; z-index: 450; }
.anchor-btn { padding: 0 24px; height: 46px; font-family: 'Lato', sans-serif; font-size: 11px; font-weight: 700; color: var(--muted); cursor: pointer; border: none; border-bottom: 3px solid transparent; background: none; }
.anchor-btn.active { color: var(--green-dark); border-bottom-color: var(--orange); }
.gallery-vv-tabs { display: flex; flex-wrap: wrap; gap: 6px; margin-bottom: 20px; }
.gvv-tab { display: flex; align-items: center; gap: 5px; padding: 6px 14px; border-radius: 999px; border: 2px solid var(--border); font-size: 10.5px; font-weight: 700; cursor: pointer; background: #fff; }
.gallery-grid { columns: 3; column-gap: 8px; }
.gallery-item { break-inside: avoid; margin-bottom: 8px; overflow: hidden; }
.gallery-item img { width: 100%; display: block; transition: transform .45s; }
.video-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; }
.video-card { background: #fff; border: 1px solid var(--border); overflow: hidden; display: flex; flex-direction: column; }
.video-thumb-wrap { position: relative; aspect-ratio: 16/9; overflow: hidden; }
.video-duration { position: absolute; bottom: 7px; right: 8px; background: rgba(0,0,0,.78); color: #fff; padding: 2px 6px; font-size: 10px; }

/* --- HOME HERO GRID --- */
.vias-verdes-hero-top { background-size: cover; background-position: center; color: white; padding: 120px 0 60px; transition: background-image 0.4s ease-in-out; }
.vias-verdes-hero-title { font-family: 'Playfair Display', serif; font-size: 4em; font-weight: 700; text-shadow: 2px 2px 6px rgba(0,0,0,0.5); }
.vias-verdes-hero-bottom { background-color: #1a2e1a; border-top: 1px solid #3a5a3a; }
.vias-verdes-hero-grid { display: grid; grid-template-columns: repeat(4, 1fr); }
.vias-verdes-hero-item { background-color: #1a2e1a; display: flex; align-items: flex-start; padding: 20px; border-right: 1px solid #3a5a3a; border-bottom: 1px solid #3a5a3a; cursor: pointer; transition: all .3s; }
.vias-verdes-hero-item.vias-verdes-item-active { background-color: var(--gold); color: #fff; }
.vias-verdes-item-icon { width: 35px; height: 35px; margin-right: 15px; background-color: rgba(255,255,255,0.2); border-radius: 50%; display: flex; align-items: center; justify-content: center; }
.vias-verdes-item-title { font-family: 'Lato', sans-serif; font-size: 1em; font-weight: 700; color: #ffffff; text-transform: uppercase; }
