/*
Theme Name: El Precio del Gol
Theme URI: https://dailycodedrops.com/
Author: El Precio del Gol
Author URI: https://dailycodedrops.com/
Description: Tema editorial ligero para un medio profesional de fútbol financiero.
Version: 1.5.0
Requires at least: 6.4
Tested up to: 7.0
Requires PHP: 7.4
Text Domain: el-precio-del-gol
*/

:root {
  --epg-navy: #071826;
  --epg-navy-soft: #10283b;
  --epg-paper: #f4f6f7;
  --epg-white: #ffffff;
  --epg-text: #17212b;
  --epg-muted: #64717d;
  --epg-border: #dfe4e8;
  --epg-green: #0b7557;
  --epg-green-dark: #075b43;
  --epg-gold: #d0a23a;
  --epg-blue: #2c6f9e;
  --epg-red: #ae3f45;
  --epg-accent: var(--epg-green);
  --epg-max: 1480px;
  --epg-page: 1320px;
  --epg-reading: 760px;
  --epg-radius: 5px;
  --epg-shadow: 0 12px 32px rgba(7, 24, 38, 0.07);
  --epg-font: -apple-system, BlinkMacSystemFont, "Segoe UI", Arial, Helvetica, sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

body {
  margin: 0;
  background: var(--epg-paper);
  color: var(--epg-text);
  font-family: var(--epg-font);
  font-size: 16.5px;
  line-height: 1.72;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

img {
  display: block;
  max-width: 100%;
  height: auto;
}

a {
  color: inherit;
  text-decoration: none;
}

a:hover {
  color: var(--epg-green);
}

button,
input,
textarea,
select {
  font: inherit;
}

button,
a {
  -webkit-tap-highlight-color: transparent;
}

.screen-reader-text {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.epg-container {
  width: min(calc(100% - 56px), var(--epg-max));
  margin-inline: auto;
}

.epg-reading {
  width: min(calc(100% - 36px), var(--epg-reading));
  margin-inline: auto;
}

/* Category accents */
.epg-category-salarios { --epg-accent: #0b7557; }
.epg-category-fichajes { --epg-accent: #2c6f9e; }
.epg-category-finanzas-clubes { --epg-accent: #8a6a16; }
.epg-category-contratos-clausulas { --epg-accent: #614f9a; }
.epg-category-patrocinios-negocios { --epg-accent: #ad5a25; }
.epg-category-rankings { --epg-accent: #ae3f45; }
.epg-category-opinion-datos { --epg-accent: #455464; }

/* Header */
.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.98);
  border-bottom: 1px solid var(--epg-border);
  box-shadow: 0 3px 14px rgba(7, 24, 38, 0.04);
  backdrop-filter: blur(12px);
}

.admin-bar .site-header {
  top: 32px;
}

.epg-utility-bar {
  min-height: 30px;
  background: var(--epg-navy);
  color: #cfd7dd;
  font-size: 0.72rem;
  letter-spacing: 0.025em;
}

.epg-utility-inner {
  min-height: 30px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
}

.epg-utility-tagline {
  color: #ffffff;
  font-weight: 700;
}

.epg-header-top {
  min-height: 76px;
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  align-items: center;
  gap: 30px;
}

.epg-branding {
  display: flex;
  align-items: center;
  gap: 11px;
  min-width: 220px;
}

.epg-brand-logo img,
.custom-logo-link img {
  width: auto;
  max-height: 44px;
}

.site-title {
  display: inline-flex;
  flex-direction: column;
  color: var(--epg-navy);
  line-height: 1;
}

.site-title:hover {
  color: var(--epg-navy);
}

.site-title-main {
  font-size: clamp(1.22rem, 1.8vw, 1.62rem);
  font-weight: 850;
  letter-spacing: -0.045em;
  white-space: nowrap;
}

.site-title-main strong {
  color: var(--epg-green);
  font-weight: 900;
}

.site-title-sub {
  margin-top: 7px;
  color: var(--epg-muted);
  font-size: 0.62rem;
  font-weight: 800;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.primary-navigation {
  justify-self: center;
  min-width: 0;
}

.primary-navigation ul {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-wrap: wrap;
  gap: 0 19px;
  margin: 0;
  padding: 0;
  list-style: none;
}

.primary-navigation a {
  position: relative;
  display: block;
  padding: 27px 0 24px;
  color: var(--epg-navy);
  font-size: 0.79rem;
  font-weight: 780;
  line-height: 1;
  white-space: nowrap;
}

.primary-navigation a::after {
  content: "";
  position: absolute;
  left: 0;
  right: 100%;
  bottom: 17px;
  height: 2px;
  background: var(--epg-green);
  transition: right 0.2s ease;
}

.primary-navigation a:hover::after,
.primary-navigation .current-menu-item > a::after,
.primary-navigation .current-menu-parent > a::after {
  right: 0;
}

.epg-header-actions {
  display: flex;
  align-items: center;
  gap: 8px;
}

.epg-icon-button {
  width: 40px;
  height: 40px;
  display: inline-grid;
  place-items: center;
  border: 1px solid var(--epg-border);
  border-radius: 50%;
  background: var(--epg-white);
  color: var(--epg-navy);
  cursor: pointer;
  transition: border-color 0.2s ease, background-color 0.2s ease;
}

.epg-icon-button:hover {
  border-color: var(--epg-green);
  background: #f4fbf8;
}

.epg-icon-button svg {
  width: 19px;
  height: 19px;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.8;
  stroke-linecap: round;
}

.epg-menu-toggle {
  display: none;
}

.epg-search-panel {
  display: none;
  padding: 16px 0;
  border-top: 1px solid var(--epg-border);
  background: #f9fafb;
}

.epg-search-panel.is-open {
  display: block;
}

.search-form {
  display: flex;
  gap: 10px;
}

.search-form label {
  flex: 1;
}

.search-field {
  width: 100%;
  min-height: 46px;
  padding: 11px 14px;
  border: 1px solid #cdd5db;
  border-radius: var(--epg-radius);
  outline: none;
  background: #ffffff;
}

.search-field:focus {
  border-color: var(--epg-green);
  box-shadow: 0 0 0 3px rgba(11, 117, 87, 0.12);
}

.search-submit,
.epg-button {
  min-height: 46px;
  padding: 11px 19px;
  border: 0;
  border-radius: var(--epg-radius);
  background: var(--epg-green);
  color: #ffffff;
  font-weight: 800;
  cursor: pointer;
}

/* Topic strip */
.epg-topic-strip {
  background: #ffffff;
  border-bottom: 1px solid var(--epg-border);
}

.epg-topic-strip-inner {
  min-height: 42px;
  display: flex;
  align-items: center;
  gap: 22px;
  overflow-x: auto;
  scrollbar-width: none;
  white-space: nowrap;
}

.epg-topic-strip-inner::-webkit-scrollbar {
  display: none;
}

.epg-topic-strip a {
  color: var(--epg-muted);
  font-size: 0.77rem;
  font-weight: 720;
}

.epg-topic-strip a:hover {
  color: var(--epg-green);
}

.epg-topic-label {
  position: relative;
  padding-right: 22px;
  color: var(--epg-navy);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.09em;
  text-transform: uppercase;
}

.epg-topic-label::after {
  content: "";
  position: absolute;
  top: 50%;
  right: 0;
  width: 1px;
  height: 18px;
  background: var(--epg-border);
  transform: translateY(-50%);
}

/* General editorial layout */
.site-main {
  min-height: 60vh;
}

.epg-section {
  padding: 46px 0;
}

.epg-section + .epg-section {
  border-top: 1px solid var(--epg-border);
}

.epg-lead-section {
  padding-top: 30px;
}

.epg-section-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 22px;
  padding-bottom: 12px;
  border-bottom: 2px solid var(--epg-navy);
}

.epg-section-heading > div:first-child {
  position: relative;
  padding-left: 13px;
}

.epg-section-heading > div:first-child::before {
  content: "";
  position: absolute;
  top: 3px;
  bottom: 3px;
  left: 0;
  width: 4px;
  background: var(--epg-accent, var(--epg-green));
}

.epg-section-overline {
  display: block;
  margin-bottom: 4px;
  color: var(--epg-muted);
  font-size: 0.68rem;
  font-weight: 850;
  letter-spacing: 0.09em;
  line-height: 1.2;
  text-transform: uppercase;
}

.epg-section-title {
  margin: 0;
  color: var(--epg-navy);
  font-size: clamp(1.55rem, 2.5vw, 2.15rem);
  font-weight: 850;
  letter-spacing: -0.035em;
  line-height: 1.07;
}

.epg-section-link {
  color: var(--epg-green);
  font-size: 0.78rem;
  font-weight: 850;
  white-space: nowrap;
}

.epg-section-link span {
  margin-left: 5px;
}

.epg-kicker {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 9px;
  color: var(--epg-accent, var(--epg-green));
  font-size: 0.69rem;
  font-weight: 900;
  letter-spacing: 0.085em;
  line-height: 1.2;
  text-transform: uppercase;
}

.epg-kicker::before {
  content: "";
  width: 14px;
  height: 3px;
  background: currentColor;
}

.epg-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 15px;
  color: var(--epg-muted);
  font-size: 0.73rem;
  line-height: 1.35;
}

.epg-meta span {
  position: relative;
}

.epg-meta span + span::before {
  content: "·";
  position: absolute;
  left: -9px;
  color: #a6b0b7;
}

/* Lead news */
.epg-lead-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.62fr) minmax(310px, 0.88fr);
  gap: 22px;
}

.epg-lead-main,
.epg-card,
.epg-side-story {
  position: relative;
  overflow: hidden;
  border: 1px solid var(--epg-border);
  border-radius: var(--epg-radius);
  background: var(--epg-white);
}

.epg-lead-main::before,
.epg-card::before,
.epg-side-story::before {
  content: "";
  position: absolute;
  z-index: 3;
  top: 0;
  left: 0;
  width: 100%;
  height: 4px;
  background: var(--epg-accent, var(--epg-green));
}

.epg-lead-main {
  background: var(--epg-navy);
  box-shadow: var(--epg-shadow);
}

.epg-lead-link,
.epg-card-link {
  display: block;
  height: 100%;
}

.epg-card-image {
  position: relative;
  overflow: hidden;
  background: #dce3e7;
}

.epg-lead-main .epg-card-image {
  aspect-ratio: 16 / 8.7;
}

.epg-card-image img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.epg-card:hover .epg-card-image img,
.epg-lead-main:hover .epg-card-image img,
.epg-side-story:hover .epg-card-image img {
  transform: scale(1.025);
}

.epg-image-placeholder {
  min-height: 140px;
  display: grid;
  place-items: center;
  background:
    radial-gradient(circle at center, transparent 0 34px, rgba(255,255,255,.30) 35px 36px, transparent 37px),
    linear-gradient(90deg, transparent 49.7%, rgba(255,255,255,.30) 49.8% 50.2%, transparent 50.3%),
    linear-gradient(135deg, #0b7557, #07523e);
}

.epg-image-placeholder::before {
  content: "";
  position: absolute;
  inset: 16px;
  border: 1px solid rgba(255, 255, 255, 0.3);
}

.epg-placeholder-mark {
  position: relative;
  z-index: 2;
  color: rgba(255, 255, 255, 0.9);
  font-size: clamp(1rem, 2vw, 1.5rem);
  font-weight: 900;
  letter-spacing: 0.18em;
}

.epg-lead-content {
  padding: clamp(24px, 3.2vw, 38px);
  color: #ffffff;
}

.epg-lead-main .epg-kicker {
  color: #e0b956;
}

.epg-lead-title {
  max-width: 880px;
  margin: 0 0 12px;
  color: #ffffff;
  font-size: clamp(2rem, 4vw, 3.75rem);
  font-weight: 880;
  letter-spacing: -0.055em;
  line-height: 1.01;
}

.epg-lead-excerpt {
  max-width: 780px;
  margin: 0 0 18px;
  color: #cad4db;
  font-size: 1rem;
  line-height: 1.55;
}

.epg-lead-main .epg-meta {
  color: #aebcc6;
}

.epg-side-stack {
  display: grid;
  grid-template-rows: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.epg-side-story {
  min-height: 126px;
  display: grid;
  grid-template-columns: 126px minmax(0, 1fr);
  align-items: stretch;
}

.epg-side-story .epg-card-image {
  min-height: 126px;
}

.epg-side-content {
  min-width: 0;
  padding: 15px 15px 13px;
}

.epg-side-content h2 {
  margin: 0 0 9px;
  color: var(--epg-navy);
  font-size: 1rem;
  font-weight: 820;
  letter-spacing: -0.02em;
  line-height: 1.22;
}

.epg-side-content .epg-meta span:nth-child(n + 2) {
  display: none;
}

/* Empty newsroom */
.epg-empty-newsroom {
  min-height: 470px;
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
  grid-template-rows: 1fr auto;
  overflow: hidden;
  border-radius: var(--epg-radius);
  background: var(--epg-navy);
  box-shadow: var(--epg-shadow);
  color: #ffffff;
}

.epg-empty-main {
  align-self: center;
  padding: clamp(42px, 7vw, 84px);
}

.epg-empty-main .epg-kicker {
  color: #e0b956;
}

.epg-empty-main h1 {
  max-width: 740px;
  margin: 0 0 18px;
  font-size: clamp(2.5rem, 5vw, 5rem);
  font-weight: 900;
  letter-spacing: -0.065em;
  line-height: 0.98;
}

.epg-empty-main p {
  max-width: 680px;
  margin: 0;
  color: #c8d2d9;
  font-size: clamp(1rem, 1.5vw, 1.15rem);
}

.epg-empty-visual {
  position: relative;
  min-height: 340px;
  display: grid;
  place-items: center;
  overflow: hidden;
  background:
    linear-gradient(90deg, transparent 49.8%, rgba(255,255,255,.25) 49.9% 50.1%, transparent 50.2%),
    radial-gradient(circle at center, transparent 0 60px, rgba(255,255,255,.25) 61px 63px, transparent 64px),
    linear-gradient(145deg, #0d8664, #07513d);
}

.epg-empty-visual::before {
  content: "";
  position: absolute;
  inset: 28px;
  border: 2px solid rgba(255,255,255,.28);
}

.epg-empty-visual span {
  position: relative;
  z-index: 2;
  width: 114px;
  height: 114px;
  display: grid;
  place-items: center;
  border: 2px solid rgba(255,255,255,.58);
  border-radius: 50%;
  background: rgba(7,24,38,.35);
  font-size: 3.2rem;
  font-weight: 850;
}

.epg-pitch-mark {
  position: absolute;
  width: 56px;
  height: 145px;
  border: 2px solid rgba(255,255,255,.26);
}

.epg-pitch-mark-one {
  left: 28px;
}

.epg-pitch-mark-two {
  right: 28px;
}

.epg-empty-topics {
  grid-column: 1 / -1;
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  border-top: 1px solid rgba(255,255,255,.15);
}

.epg-empty-topics div {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 18px 24px;
  border-right: 1px solid rgba(255,255,255,.15);
}

.epg-empty-topics div:last-child {
  border-right: 0;
}

.epg-empty-topics strong {
  color: #e0b956;
  font-size: 0.72rem;
  letter-spacing: 0.08em;
}

.epg-empty-topics span {
  font-size: 0.82rem;
  font-weight: 800;
  text-transform: uppercase;
}

/* Cards and sidebar */
.epg-content-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 320px;
  gap: 34px;
  align-items: start;
}

.epg-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 20px;
}

.epg-card {
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.epg-card:hover {
  transform: translateY(-3px);
  box-shadow: var(--epg-shadow);
}

.epg-card .epg-card-image {
  aspect-ratio: 16 / 10;
}

.epg-card-body {
  padding: 18px 18px 19px;
}

.epg-card-title {
  margin: 0 0 9px;
  color: var(--epg-navy);
  font-size: 1.19rem;
  font-weight: 840;
  letter-spacing: -0.025em;
  line-height: 1.19;
}

.epg-card-excerpt {
  margin: 0 0 14px;
  color: var(--epg-muted);
  font-size: 0.88rem;
  line-height: 1.55;
}

.epg-sidebar {
  position: sticky;
  top: 130px;
}

.epg-sidebar-box {
  padding: 22px;
  border-top: 4px solid var(--epg-green);
  background: var(--epg-navy);
  color: #d7e0e6;
}

.epg-sidebar-title {
  margin: 3px 0 14px;
  color: #ffffff;
  font-size: 1.45rem;
  font-weight: 850;
  letter-spacing: -0.035em;
  line-height: 1.08;
}

.epg-sidebar-box .epg-section-overline {
  color: #91a4b1;
}

.epg-ranked-list {
  margin: 0;
  padding: 0;
  list-style: none;
  counter-reset: ranking;
}

.epg-ranked-list li {
  counter-increment: ranking;
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 11px;
  padding: 14px 0;
  border-top: 1px solid rgba(255,255,255,.13);
}

.epg-ranked-list li:first-child {
  border-top: 0;
}

.epg-ranked-list li::before {
  content: counter(ranking, decimal-leading-zero);
  color: #e0b956;
  font-size: 0.77rem;
  font-weight: 900;
  letter-spacing: 0.04em;
}

.epg-ranked-list a {
  color: #ffffff;
  font-size: 0.88rem;
  font-weight: 730;
  line-height: 1.35;
}

.epg-ranked-list a:hover {
  color: #e0b956;
}

/* Breadcrumbs */
.epg-breadcrumbs {
  padding-top: 23px;
  color: var(--epg-muted);
  font-size: 0.73rem;
}

.epg-breadcrumbs,
.epg-breadcrumbs p {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 7px;
  margin-bottom: 0;
}

.epg-breadcrumbs a {
  color: var(--epg-green);
  font-weight: 700;
}

/* Archives */
.epg-archive-header {
  padding: 56px 0 25px;
  background: var(--epg-navy);
  color: #ffffff;
}

.epg-archive-title {
  max-width: 900px;
  margin: 0;
  color: #ffffff;
  font-size: clamp(2.2rem, 5vw, 4.4rem);
  font-weight: 900;
  letter-spacing: -0.06em;
  line-height: 0.98;
}

.epg-archive-description {
  max-width: 760px;
  margin-top: 13px;
  color: #c9d3da;
}

.epg-archive-description p {
  margin: 0;
}

.epg-pagination {
  margin-top: 30px;
}

.nav-links {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.page-numbers {
  min-width: 42px;
  height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid var(--epg-border);
  border-radius: var(--epg-radius);
  background: #ffffff;
  font-size: 0.82rem;
  font-weight: 750;
}

.page-numbers.current {
  border-color: var(--epg-green);
  background: var(--epg-green);
  color: #ffffff;
}

/* Single articles and pages */
.single-post .site-main,
.page .site-main {
  background: #ffffff;
}

.epg-single-article,
.epg-page-article {
  --epg-accent: var(--epg-green);
}

.epg-article-header,
.epg-page-header {
  padding: 34px 0 28px;
}

.epg-article-header {
  text-align: left;
}

.epg-page-header {
  max-width: 1000px;
  margin-inline: auto;
  padding-top: 42px;
  border-bottom: 1px solid var(--epg-border);
}

.entry-title {
  max-width: 1000px;
  margin: 6px 0 17px;
  color: var(--epg-navy);
  font-size: clamp(2.35rem, 5.4vw, 4.9rem);
  font-weight: 900;
  letter-spacing: -0.065em;
  line-height: 0.99;
}

.epg-page-header .entry-title {
  max-width: 850px;
  font-size: clamp(2.25rem, 4.5vw, 4rem);
}

.epg-entry-deck {
  max-width: 820px;
  margin: 0 0 18px;
  color: #52616d;
  font-size: clamp(1.06rem, 1.8vw, 1.3rem);
  line-height: 1.5;
}

.epg-article-meta .epg-meta {
  font-size: 0.78rem;
}

.epg-featured-image {
  width: min(calc(100% - 36px), 1120px);
  margin: 8px auto 42px;
}

.epg-featured-image img {
  width: 100%;
  max-height: 680px;
  border-radius: var(--epg-radius);
  object-fit: cover;
}

.entry-content {
  font-family: var(--epg-font);
  font-size: 1.075rem;
  line-height: 1.78;
}

.entry-content > * {
  max-width: var(--epg-reading);
  margin-left: auto;
  margin-right: auto;
}

.entry-content > .alignwide {
  max-width: 1120px;
}

.entry-content > .alignfull {
  max-width: none;
}

.entry-content p {
  margin-top: 0;
  margin-bottom: 1.35em;
}

.entry-content h2,
.entry-content h3,
.entry-content h4 {
  color: var(--epg-navy);
  font-weight: 860;
  letter-spacing: -0.035em;
  line-height: 1.12;
}

.entry-content h2 {
  position: relative;
  margin-top: 2.1em;
  margin-bottom: 0.7em;
  padding-left: 14px;
  font-size: clamp(1.72rem, 3vw, 2.35rem);
}

.entry-content h2::before {
  content: "";
  position: absolute;
  top: 0.08em;
  bottom: 0.08em;
  left: 0;
  width: 4px;
  background: var(--epg-accent, var(--epg-green));
}

.entry-content h3 {
  margin-top: 1.8em;
  font-size: 1.38rem;
}

.entry-content a {
  color: var(--epg-green-dark);
  font-weight: 650;
  text-decoration: underline;
  text-decoration-thickness: 1px;
  text-underline-offset: 3px;
}

.entry-content strong {
  color: #0d1e2b;
}

.entry-content blockquote {
  margin-top: 1.8em;
  margin-bottom: 1.8em;
  padding: 18px 22px;
  border-left: 4px solid var(--epg-gold);
  background: #f7f5ed;
  color: #34424d;
  font-size: 1.08rem;
  font-weight: 620;
}

.entry-content ul,
.entry-content ol {
  padding-left: 1.3em;
}

.entry-content li {
  margin-bottom: 0.45em;
}

.entry-content table {
  width: 100%;
  border-collapse: collapse;
  font-family: var(--epg-font);
  font-size: 0.9rem;
}

.entry-content th,
.entry-content td {
  padding: 12px;
  border: 1px solid var(--epg-border);
  text-align: left;
}

.entry-content th {
  background: var(--epg-navy);
  color: #ffffff;
}

.entry-content tbody tr:nth-child(even) {
  background: #f7f9fa;
}

.entry-content .wp-block-group.is-style-epg-key-facts,
.entry-content .epg-key-facts {
  padding: 22px;
  border-top: 4px solid var(--epg-gold);
  background: #f8f5ec;
}

.epg-page-content {
  padding: 36px 0 70px;
}

.epg-page-content > p:first-child {
  color: #3f4f5b;
  font-size: 1.15rem;
  font-weight: 520;
}

/* Wide editorial pages on desktop */
.page .epg-breadcrumbs,
.page .epg-page-header,
.page .epg-page-content {
  width: min(calc(100% - 56px), var(--epg-page));
  max-width: none;
  margin-inline: auto;
}

.page .epg-page-header {
  padding-top: 48px;
  padding-bottom: 34px;
}

.page .epg-page-header .entry-title {
  max-width: 1120px;
}

.page .epg-page-content {
  padding-top: 42px;
}

.page .epg-page-content > * {
  max-width: 1040px;
  margin-left: 0;
  margin-right: 0;
}

.page .epg-page-content > .alignwide,
.page .epg-page-content > .epg-about,
.page .epg-page-content > div[class^="epg-"],
.page .epg-page-content > div[class*=" epg-"] {
  width: 100%;
  max-width: none;
}

.page .epg-page-content .epg-about > p,
.page .epg-page-content .epg-about > h2,
.page .epg-page-content .epg-about > blockquote {
  max-width: 1080px;
  margin-left: 0;
  margin-right: 0;
}

.page .epg-page-content .epg-about .epg-about-intro {
  position: relative;
  min-height: 360px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  overflow: hidden;
  padding: clamp(42px, 5vw, 72px);
  padding-right: min(48%, 620px);
  border-left-width: 6px;
}

.page .epg-page-content .epg-about .epg-about-intro::after {
  content: "";
  position: absolute;
  top: 34px;
  right: 38px;
  bottom: 34px;
  width: min(39%, 500px);
  border: 2px solid rgba(255,255,255,.24);
  background:
    linear-gradient(90deg, transparent 49.7%, rgba(255,255,255,.22) 49.8% 50.2%, transparent 50.3%),
    radial-gradient(circle at center, transparent 0 54px, rgba(255,255,255,.22) 55px 57px, transparent 58px);
  pointer-events: none;
}

.page .epg-page-content .epg-about .epg-about-intro::before {
  content: "€";
  position: absolute;
  z-index: 1;
  right: clamp(78px, 12vw, 190px);
  top: 50%;
  width: 96px;
  height: 96px;
  display: grid;
  place-items: center;
  border: 2px solid rgba(255,255,255,.45);
  border-radius: 50%;
  background: rgba(7,24,38,.38);
  color: #e1bd72;
  font-size: 2.8rem;
  font-weight: 900;
  transform: translateY(-50%);
  pointer-events: none;
}

.page .epg-page-content .epg-about .epg-about-intro > * {
  position: relative;
  z-index: 2;
}

.page .epg-page-content .epg-about .epg-about-grid {
  max-width: none;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 18px;
}

.page .epg-page-content .epg-about .epg-about-card {
  min-height: 185px;
}

.page .epg-page-content .epg-about .epg-about-principles,
.page .epg-page-content .epg-about .epg-about-note {
  max-width: none;
}

.epg-article-footer {
  padding: 28px 0 56px;
}

.epg-tags {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.epg-tags a {
  padding: 7px 11px;
  border: 1px solid var(--epg-border);
  border-radius: 999px;
  background: #f8fafb;
  font-size: 0.75rem;
  font-weight: 750;
}

.epg-related {
  padding: 44px 0;
  border-top: 1px solid var(--epg-border);
  background: var(--epg-paper);
}

/* Comments */
.comments-area {
  padding: 46px 0 74px;
  border-top: 1px solid var(--epg-border);
}

.comments-title,
.comment-reply-title {
  color: var(--epg-navy);
  font-size: 1.7rem;
  font-weight: 850;
  letter-spacing: -0.035em;
}

.comment-list {
  margin: 0;
  padding: 0;
  list-style: none;
}

.comment-body {
  padding: 23px 0;
  border-top: 1px solid var(--epg-border);
}

.comment-meta {
  color: var(--epg-muted);
  font-size: 0.78rem;
}

.comment-content p {
  margin-bottom: 0;
}

.comment-form input[type="text"],
.comment-form input[type="email"],
.comment-form input[type="url"],
.comment-form textarea {
  width: 100%;
  padding: 12px;
  border: 1px solid #cfd7dd;
  border-radius: var(--epg-radius);
  background: #ffffff;
}

.form-submit .submit {
  padding: 12px 19px;
  border: 0;
  border-radius: var(--epg-radius);
  background: var(--epg-green);
  color: #ffffff;
  font-weight: 800;
  cursor: pointer;
}

/* Generic empty states */
.epg-empty {
  padding: 40px;
  border-left: 5px solid var(--epg-green);
  background: #ffffff;
}

.epg-empty h1,
.epg-empty h2 {
  margin-top: 0;
  color: var(--epg-navy);
  font-weight: 870;
  letter-spacing: -0.04em;
}

/* Footer */
.site-footer {
  position: relative;
  padding: 54px 0 22px;
  background: var(--epg-navy);
  color: #c8d2d9;
}

.epg-footer-accent {
  position: absolute;
  top: 0;
  right: 0;
  left: 0;
  height: 5px;
  background: linear-gradient(90deg, var(--epg-green) 0 46%, var(--epg-gold) 46% 66%, var(--epg-blue) 66% 100%);
}

.epg-footer-grid {
  display: grid;
  grid-template-columns: 1.25fr 1fr 1fr;
  gap: 40px;
}

.epg-footer-brand {
  color: #ffffff;
  font-size: 1.55rem;
  font-weight: 850;
  letter-spacing: -0.04em;
}

.epg-footer-brand strong {
  color: #5bc49f;
}

.epg-footer-grid p {
  max-width: 430px;
  margin: 10px 0 0;
}

.epg-footer-note {
  color: #8fa0ac;
  font-size: 0.78rem;
}

.epg-footer-title {
  margin: 0 0 13px;
  color: #ffffff;
  font-size: 0.75rem;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.site-footer ul {
  margin: 0;
  padding: 0;
  list-style: none;
}

.site-footer li {
  margin: 7px 0;
}

.site-footer a {
  font-size: 0.85rem;
}

.site-footer a:hover {
  color: #ffffff;
}

.epg-footer-bottom {
  margin-top: 36px;
  padding-top: 18px;
  border-top: 1px solid rgba(255,255,255,.12);
  color: #93a2ad;
  font-size: 0.74rem;
}

/* Responsive */
@media (max-width: 1120px) {
  .epg-header-top {
    gap: 20px;
  }

  .primary-navigation ul {
    gap: 0 13px;
  }

  .primary-navigation a {
    font-size: 0.75rem;
  }
}

@media (max-width: 980px) {
  .epg-header-top {
    grid-template-columns: minmax(0, 1fr) auto;
  }

  .primary-navigation {
    display: none;
    grid-column: 1 / -1;
    justify-self: stretch;
    padding-bottom: 16px;
  }

  .primary-navigation.is-open {
    display: block;
  }

  .primary-navigation ul {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0;
    border-top: 1px solid var(--epg-border);
  }

  .primary-navigation li {
    border-bottom: 1px solid var(--epg-border);
  }

  .primary-navigation li:nth-child(odd) {
    border-right: 1px solid var(--epg-border);
  }

  .primary-navigation a {
    padding: 13px 12px;
  }

  .primary-navigation a::after {
    display: none;
  }

  .epg-menu-toggle {
    display: inline-grid;
  }

  .epg-lead-grid,
  .epg-content-grid {
    grid-template-columns: 1fr;
  }

  .epg-side-stack {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    grid-template-rows: none;
  }

  .epg-sidebar {
    position: static;
  }

  .epg-empty-newsroom {
    grid-template-columns: 1fr;
  }

  .epg-empty-visual {
    min-height: 280px;
  }

  .epg-cards {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 980px) {
  .page .epg-breadcrumbs,
  .page .epg-page-header,
  .page .epg-page-content {
    width: min(calc(100% - 36px), var(--epg-page));
  }

  .page .epg-page-content .epg-about .epg-about-intro {
    min-height: 300px;
    padding-right: 42%;
  }

  .page .epg-page-content .epg-about .epg-about-intro::after {
    right: 24px;
    width: 34%;
  }

  .page .epg-page-content .epg-about .epg-about-intro::before {
    right: 10%;
  }

  .page .epg-page-content .epg-about .epg-about-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 640px) {
  .page .epg-breadcrumbs,
  .page .epg-page-header,
  .page .epg-page-content {
    width: min(calc(100% - 24px), var(--epg-page));
  }

  .page .epg-page-content .epg-about .epg-about-intro {
    min-height: 0;
    padding: 28px 22px;
  }

  .page .epg-page-content .epg-about .epg-about-intro::before,
  .page .epg-page-content .epg-about .epg-about-intro::after {
    display: none;
  }

  .page .epg-page-content .epg-about .epg-about-grid {
    grid-template-columns: 1fr;
  }
  .admin-bar .site-header {
    top: 46px;
  }

  .epg-container,
  .epg-reading {
    width: min(calc(100% - 24px), var(--epg-max));
  }

  .epg-utility-inner {
    justify-content: center;
  }

  .epg-utility-inner > span:first-child {
    display: none;
  }

  .epg-header-top {
    min-height: 68px;
    gap: 10px;
  }

  .epg-branding {
    min-width: 0;
  }

  .epg-brand-logo {
    display: none;
  }

  .site-title-main {
    font-size: 1.22rem;
  }

  .site-title-sub {
    font-size: 0.54rem;
    letter-spacing: 0.09em;
  }

  .epg-icon-button {
    width: 38px;
    height: 38px;
  }

  .epg-search-toggle {
    display: none;
  }

  .primary-navigation ul {
    grid-template-columns: 1fr;
  }

  .primary-navigation li:nth-child(odd) {
    border-right: 0;
  }

  .epg-section {
    padding: 33px 0;
  }

  .epg-lead-section {
    padding-top: 18px;
  }

  .epg-lead-title {
    font-size: 2.25rem;
  }

  .epg-lead-content {
    padding: 22px;
  }

  .epg-side-stack {
    grid-template-columns: 1fr;
  }

  .epg-side-story {
    grid-template-columns: 104px minmax(0, 1fr);
  }

  .epg-side-story .epg-card-image {
    min-height: 116px;
  }

  .epg-side-content {
    padding: 13px;
  }

  .epg-empty-newsroom {
    min-height: 0;
  }

  .epg-empty-main {
    padding: 36px 24px;
  }

  .epg-empty-main h1 {
    font-size: 2.55rem;
  }

  .epg-empty-visual {
    min-height: 230px;
  }

  .epg-empty-topics {
    grid-template-columns: 1fr;
  }

  .epg-empty-topics div {
    border-right: 0;
    border-bottom: 1px solid rgba(255,255,255,.15);
  }

  .epg-empty-topics div:last-child {
    border-bottom: 0;
  }

  .epg-section-heading {
    align-items: start;
  }

  .epg-section-link {
    padding-top: 3px;
  }

  .epg-cards {
    grid-template-columns: 1fr;
  }

  .epg-card .epg-card-image {
    aspect-ratio: 16 / 9;
  }

  .entry-title {
    font-size: 2.55rem;
  }

  .epg-article-header,
  .epg-page-header {
    padding-top: 26px;
  }

  .entry-content {
    font-size: 1rem;
  }

  .entry-content h2 {
    font-size: 1.65rem;
  }

  .epg-footer-grid {
    grid-template-columns: 1fr;
  }

  .search-form {
    flex-direction: column;
  }
}


/* =========================================================
   Version 1.4 — portada funcional, estadísticas y footer
   ========================================================= */

/* Compact editorial launch state used before the first articles exist */
.epg-launch {
  display: grid;
  grid-template-columns: minmax(0, 1.35fr) minmax(330px, 0.65fr);
  overflow: hidden;
  border: 1px solid var(--epg-border);
  border-top: 5px solid var(--epg-green);
  border-radius: var(--epg-radius);
  background: var(--epg-white);
  box-shadow: var(--epg-shadow);
}

.epg-launch-copy {
  padding: clamp(36px, 5vw, 64px);
  background:
    radial-gradient(circle at 90% 15%, rgba(11, 117, 87, 0.09), transparent 32%),
    var(--epg-white);
}

.epg-launch-copy h1 {
  max-width: 820px;
  margin: 0 0 18px;
  color: var(--epg-navy);
  font-size: clamp(2.45rem, 5vw, 4.65rem);
  font-weight: 900;
  letter-spacing: -0.065em;
  line-height: 0.98;
}

.epg-launch-copy > p {
  max-width: 760px;
  margin: 0;
  color: #52616d;
  font-size: clamp(1rem, 1.35vw, 1.14rem);
  line-height: 1.68;
}

.epg-launch-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 18px;
  margin-top: 28px;
}

.epg-launch-actions .epg-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
}

.epg-text-link {
  color: var(--epg-green);
  font-size: 0.84rem;
  font-weight: 850;
}

.epg-launch-briefing {
  padding: clamp(30px, 4vw, 48px);
  background: var(--epg-navy);
  color: #ffffff;
}

.epg-launch-briefing-label {
  display: block;
  margin-bottom: 20px;
  color: #e0b956;
  font-size: 0.69rem;
  font-weight: 900;
  letter-spacing: 0.11em;
  text-transform: uppercase;
}

.epg-launch-point {
  display: grid;
  grid-template-columns: 34px minmax(0, 1fr);
  gap: 14px;
  padding: 19px 0;
  border-top: 1px solid rgba(255, 255, 255, 0.13);
}

.epg-launch-point:first-of-type {
  border-top: 0;
}

.epg-launch-point > strong {
  color: #e0b956;
  font-size: 0.72rem;
  letter-spacing: 0.07em;
}

.epg-launch-point span {
  display: block;
  margin-bottom: 4px;
  color: #ffffff;
  font-size: 0.94rem;
  font-weight: 820;
}

.epg-launch-point p {
  margin: 0;
  color: #aebdc7;
  font-size: 0.8rem;
  line-height: 1.55;
}

/* Public site statistics supplied by the EPG Editorial Stats plugin */
.epg-public-stats {
  border-top: 1px solid var(--epg-border);
  border-bottom: 1px solid var(--epg-border);
  background: var(--epg-white);
}

.epg-public-stats-inner {
  min-height: 118px;
  display: grid;
  grid-template-columns: minmax(250px, 1.4fr) repeat(3, minmax(135px, 0.6fr));
  align-items: center;
  gap: 0;
}

.epg-public-stats-heading {
  padding-right: 34px;
}

.epg-public-stats-heading strong {
  display: block;
  color: var(--epg-navy);
  font-size: clamp(1.15rem, 2vw, 1.55rem);
  font-weight: 850;
  letter-spacing: -0.035em;
}

.epg-stat-item {
  min-height: 72px;
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 0 26px;
  border-left: 1px solid var(--epg-border);
}

.epg-stat-value {
  color: var(--epg-navy);
  font-size: clamp(1.65rem, 3vw, 2.4rem);
  font-weight: 900;
  letter-spacing: -0.055em;
  line-height: 1;
}

.epg-stat-item:first-of-type .epg-stat-value {
  color: var(--epg-green);
}

.epg-stat-label {
  margin-top: 8px;
  color: var(--epg-muted);
  font-size: 0.69rem;
  font-weight: 820;
  letter-spacing: 0.07em;
  text-transform: uppercase;
}

/* Always-visible editorial directory so the homepage remains useful when empty */
.epg-directory-section {
  background: #eef2f3;
}

.epg-category-directory {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 16px;
}

.epg-directory-card {
  --epg-accent: var(--epg-green);
  position: relative;
  min-height: 220px;
  display: flex;
  flex-direction: column;
  padding: 25px 24px;
  overflow: hidden;
  border: 1px solid var(--epg-border);
  border-top: 4px solid var(--epg-accent);
  border-radius: var(--epg-radius);
  background: var(--epg-white);
  transition: transform 0.18s ease, box-shadow 0.18s ease;
}

.epg-directory-card:hover {
  color: inherit;
  transform: translateY(-3px);
  box-shadow: 0 12px 28px rgba(7, 24, 38, 0.08);
}

.epg-directory-number {
  margin-bottom: 24px;
  color: #c3cdd3;
  font-size: 1.85rem;
  font-weight: 900;
  letter-spacing: -0.05em;
  line-height: 1;
}

.epg-directory-card h3 {
  margin: 0 0 9px;
  color: var(--epg-navy);
  font-size: 1.08rem;
  font-weight: 850;
  letter-spacing: -0.03em;
  line-height: 1.15;
}

.epg-directory-card p {
  margin: 0 0 22px;
  color: var(--epg-muted);
  font-size: 0.84rem;
  line-height: 1.6;
}

.epg-directory-link {
  margin-top: auto;
  color: var(--epg-accent);
  font-size: 0.74rem;
  font-weight: 880;
  letter-spacing: 0.03em;
}

/* Archive title refinement: the template now prints only the category name */
.epg-archive-header .epg-kicker {
  color: #4f9c82;
}

.epg-archive-header.epg-category-salarios,
.epg-archive-header.epg-category-fichajes,
.epg-archive-header.epg-category-finanzas-clubes,
.epg-archive-header.epg-category-contratos-clausulas,
.epg-archive-header.epg-category-patrocinios-negocios,
.epg-archive-header.epg-category-rankings,
.epg-archive-header.epg-category-opinion-datos {
  border-bottom: 4px solid var(--epg-accent);
}

/* Coherent footer: brand, real sections, and institutional information */
.epg-footer-grid {
  grid-template-columns: minmax(280px, 1.2fr) minmax(250px, 0.8fr) minmax(300px, 1fr);
  gap: clamp(34px, 5vw, 76px);
}

.epg-footer-sections-menu {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  column-gap: 24px;
}

.epg-information-menu {
  columns: 2;
  column-gap: 28px;
}

.epg-information-menu li {
  break-inside: avoid;
}

.epg-footer-bottom {
  display: flex;
  flex-wrap: wrap;
  justify-content: space-between;
  gap: 10px 24px;
}

@media (max-width: 1120px) {
  .epg-category-directory {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .epg-public-stats-inner {
    grid-template-columns: 1fr repeat(3, minmax(120px, 0.55fr));
  }
}

@media (max-width: 980px) {
  .epg-launch {
    grid-template-columns: 1fr;
  }

  .epg-public-stats-inner {
    grid-template-columns: 1fr 1fr 1fr;
    padding: 24px 0;
  }

  .epg-public-stats-heading {
    grid-column: 1 / -1;
    padding: 0 0 20px;
  }

  .epg-stat-item {
    padding: 0 20px;
  }

  .epg-stat-item:nth-of-type(2) {
    border-left: 0;
  }

  .epg-category-directory {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .epg-footer-grid {
    grid-template-columns: 1fr 1fr;
  }

  .epg-footer-about {
    grid-column: 1 / -1;
  }
}

@media (max-width: 640px) {
  .epg-launch-copy,
  .epg-launch-briefing {
    padding: 28px 22px;
  }

  .epg-launch-copy h1 {
    font-size: 2.65rem;
  }

  .epg-launch-actions {
    align-items: stretch;
    flex-direction: column;
  }

  .epg-launch-actions .epg-button,
  .epg-launch-actions .epg-text-link {
    width: 100%;
    text-align: center;
  }

  .epg-public-stats-inner {
    grid-template-columns: 1fr;
  }

  .epg-public-stats-heading {
    padding-bottom: 12px;
  }

  .epg-stat-item,
  .epg-stat-item:nth-of-type(2) {
    min-height: 82px;
    padding: 18px 0;
    border-top: 1px solid var(--epg-border);
    border-left: 0;
  }

  .epg-category-directory {
    grid-template-columns: 1fr;
  }

  .epg-directory-card {
    min-height: 0;
  }

  .epg-footer-grid {
    grid-template-columns: 1fr;
  }

  .epg-footer-about {
    grid-column: auto;
  }

  .epg-footer-sections-menu {
    grid-template-columns: 1fr 1fr;
  }

  .epg-information-menu {
    columns: 1;
  }

  .epg-footer-bottom {
    flex-direction: column;
  }
}


/* =========================================================
   Version 1.5 — portada sin columnas vacías y entradas amplias
   ========================================================= */

/* Cuando solo existe una entrada, la portada usa todo el ancho disponible. */
.epg-lead-grid--solo {
  grid-template-columns: minmax(0, 1fr);
}

.epg-lead-grid--solo .epg-lead-main {
  width: 100%;
}

.epg-lead-grid--solo .epg-lead-link {
  min-height: 520px;
  display: grid;
  grid-template-columns: minmax(0, 1.18fr) minmax(390px, 0.82fr);
}

.epg-lead-grid--solo .epg-lead-main .epg-card-image {
  min-height: 100%;
  aspect-ratio: auto;
}

.epg-lead-grid--solo .epg-lead-content {
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: clamp(38px, 5vw, 76px);
}

.epg-lead-grid--solo .epg-lead-title {
  max-width: 760px;
  font-size: clamp(2.35rem, 4.6vw, 4.65rem);
}

.epg-lead-grid--solo .epg-lead-excerpt {
  max-width: 680px;
  font-size: clamp(1rem, 1.25vw, 1.12rem);
  line-height: 1.65;
}

/* La columna secundaria se adapta al número real de noticias. */
.epg-side-stack--count-1 {
  grid-template-rows: minmax(0, 1fr);
}

.epg-side-stack--count-2 {
  grid-template-rows: repeat(2, minmax(0, 1fr));
}

.epg-side-stack--count-3 {
  grid-template-rows: repeat(3, minmax(0, 1fr));
}

.epg-side-stack--count-4 {
  grid-template-rows: repeat(4, minmax(0, 1fr));
}

/* Cabecera de entrada más amplia, sin encajonar el titular. */
.single-post .epg-article-header {
  width: min(calc(100% - 56px), var(--epg-max));
}

.single-post .entry-title {
  max-width: 1320px;
}

.single-post .epg-entry-deck {
  max-width: 1080px;
}

.single-post .epg-featured-image {
  width: min(calc(100% - 56px), var(--epg-page));
  max-width: none;
}

/* Los diseños editoriales completos pegados en una entrada aprovechan 1320 px.
   El texto corriente que no tenga un diseño propio conserva el ancho de lectura. */
.single-post .entry-content > article[class^="epg-"],
.single-post .entry-content > article[class*=" epg-"],
.single-post .entry-content > div[class^="epg-"],
.single-post .entry-content > div[class*=" epg-"] {
  width: min(calc(100% - 56px), var(--epg-page));
  max-width: none;
  margin-left: auto;
  margin-right: auto;
}


@media (max-width: 980px) {
  .epg-lead-grid--solo .epg-lead-link {
    min-height: 0;
    grid-template-columns: minmax(0, 1fr);
  }

  .epg-lead-grid--solo .epg-lead-main .epg-card-image {
    min-height: 360px;
    aspect-ratio: 16 / 9;
  }
}

@media (max-width: 640px) {
  .single-post .epg-article-header,
  .single-post .epg-featured-image,
  .single-post .entry-content > article[class^="epg-"],
  .single-post .entry-content > article[class*=" epg-"],
  .single-post .entry-content > div[class^="epg-"],
  .single-post .entry-content > div[class*=" epg-"] {
    width: min(calc(100% - 28px), var(--epg-page));
  }

  .epg-lead-grid--solo .epg-lead-main .epg-card-image {
    min-height: 230px;
  }

  .epg-lead-grid--solo .epg-lead-content {
    padding: 28px 23px 31px;
  }
}
