/* Estilos adicionales del CMS, pensados para integrarse visualmente con el tema original */

.cms-section-title {
  text-align: center;
  margin-bottom: 2.5rem;
  max-width: 760px;
  margin-left: auto;
  margin-right: auto;
}
.cms-section-title h3 {
  font-weight: 700;
  margin-bottom: 0.6rem;
}
.cms-section-title p {
  color: #666;
  margin: 0;
}

.novedades-section {
  padding: 5rem 0;
}
.novedades-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 30px;
}
@media (max-width: 991px) {
  .novedades-grid { grid-template-columns: repeat(2, 1fr); }
}
@media (max-width: 600px) {
  .novedades-grid { grid-template-columns: 1fr; }
}
.novedad-card {
  background: #fff;
  border-radius: 10px;
  overflow: hidden;
  box-shadow: 0 6px 24px rgba(0,0,0,.08);
  transition: transform .2s ease, box-shadow .2s ease;
  display: flex;
  flex-direction: column;
  height: 100%;
}
.novedad-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 30px rgba(0,0,0,.14);
}
.novedad-card img {
  width: 100%;
  height: 200px;
  object-fit: cover;
}
.novedad-card .body {
  padding: 20px 22px 24px;
  flex: 1;
  display: flex;
  flex-direction: column;
}
.novedad-card .date {
  font-size: 12px;
  text-transform: uppercase;
  letter-spacing: .05em;
  color: #999;
  margin-bottom: 8px;
}
.novedad-card h4 {
  font-size: 1.15rem;
  margin: 0 0 10px;
  font-weight: 700;
}
.novedad-card p {
  color: #555;
  font-size: .95rem;
  flex: 1;
}
.novedad-card a.leer-mas {
  margin-top: 12px;
  font-weight: 600;
  text-decoration: none;
}

.extra-gallery {
  padding: 4rem 0;
}
.extra-gallery-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 14px;
}
@media (max-width: 991px) {
  .extra-gallery-grid { grid-template-columns: repeat(2, 1fr); }
}
.extra-gallery-grid figure {
  margin: 0;
  border-radius: 6px;
  overflow: hidden;
  position: relative;
  cursor: pointer;
  background: #000;
}
.extra-gallery-grid img,
.extra-gallery-grid video {
  width: 100%;
  height: 220px;
  object-fit: cover;
  display: block;
  transition: transform .3s ease;
}
.extra-gallery-grid figure:hover img { transform: scale(1.06); }

.cms-media-item {
  position: relative;
  cursor: pointer;
}
.play-badge {
  position: absolute;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  color: #fff;
  font-size: 2.4rem;
  background: rgba(0,0,0,.25);
  pointer-events: none;
}

.cms-lightbox {
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,.9);
  display: none;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  padding: 20px;
}
.cms-lightbox.open { display: flex; }
.cms-lightbox img, .cms-lightbox iframe, .cms-lightbox video {
  max-width: 100%;
  max-height: 90vh;
  border: 0;
}
.cms-lightbox .close-btn {
  position: absolute;
  top: 20px;
  right: 30px;
  color: #fff;
  font-size: 2rem;
  cursor: pointer;
}

.breadcrumb-bar {
  background: var(--site-primary, #00174d);
  color: #fff;
  padding: 140px 0 40px;
  text-align: center;
}
.breadcrumb-bar h1 { color: #fff; font-weight: 700; }
.breadcrumb-bar a { color: #cfe0ff; }

.yt-bg-wrapper {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
  pointer-events: none;
}
.yt-bg-wrapper iframe {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 100vw;
  height: 56.25vw; /* 16:9 */
  min-height: 100vh;
  min-width: 177.78vh; /* 16:9 */
  transform: translate(-50%, -50%);
  border: 0;
}

.article-body {
  max-width: 800px;
  margin: 0 auto;
  padding: 3rem 15px;
  line-height: 1.8;
  font-size: 1.05rem;
}
.article-body img { max-width: 100%; height: auto; border-radius: 8px; }
.article-cover {
  width: 100%;
  max-height: 420px;
  object-fit: cover;
}

/* Descargas */
.downloads-list { display: flex; flex-direction: column; gap: 14px; max-width: 820px; margin: 0 auto; }
.download-row {
  display: flex;
  align-items: center;
  gap: 18px;
  background: #fff;
  border-radius: 10px;
  padding: 14px 20px;
  box-shadow: 0 4px 16px rgba(0,0,0,.06);
}
.download-thumb { width: 60px; height: 60px; flex-shrink: 0; border-radius: 8px; overflow: hidden; }
.download-thumb img { width: 100%; height: 100%; object-fit: cover; }
.download-thumb-placeholder {
  width: 100%; height: 100%; display: flex; align-items: center; justify-content: center;
  background: #f1f4f9; color: var(--site-primary, #00174d); font-size: 1.6rem;
}
.download-info { flex: 1; min-width: 0; }
.download-info h4 { margin: 0 0 2px; font-size: 1.05rem; font-weight: 700; }
.download-date { font-size: 12.5px; color: #999; }
.btn-download {
  flex-shrink: 0;
  background: var(--site-primary, #00174d);
  color: #fff !important;
  padding: 10px 18px;
  border-radius: 8px;
  font-weight: 600;
  font-size: .9rem;
  text-decoration: none;
  white-space: nowrap;
}
.btn-download:hover { background: var(--site-secondary, #002680); }
@media (max-width: 600px) {
  .download-row { flex-wrap: wrap; }
  .btn-download { width: 100%; text-align: center; }
}

.pagination-bar { display: flex; justify-content: center; gap: 6px; margin-top: 2.5rem; flex-wrap: wrap; }
.pagination-bar a {
  padding: 8px 14px; border-radius: 6px; background: #fff; border: 1px solid #e4e8f0;
  color: #333; font-size: .9rem; text-decoration: none;
}
.pagination-bar a.active { background: var(--site-primary, #00174d); color: #fff; border-color: var(--site-primary, #00174d); }
.pagination-bar a:hover:not(.active) { background: #f1f4f9; }
