/* ============================================================
   BARÇA NIT — Design System
   Palette : noir profond + bleu Barça + rouge Barça
   ============================================================ */

/* ─── VARIABLES ─────────────────────────────────────────── */
:root {
  --bg-base:       #0a0a0a;
  --bg-surface:    #111111;
  --bg-elevated:   #1a1a1a;
  --bg-hover:      #202020;

  --barca-blue:    #004D98;
  --barca-red:     #A50044;
  --barca-gold:    #EDBB00;

  --text-primary:  #f0f0f0;
  --text-secondary:#9a9a9a;
  --text-muted:    #555555;

  --border:        rgba(255,255,255,0.07);
  --border-strong: rgba(255,255,255,0.14);

  --radius-sm:     4px;
  --radius-md:     8px;
  --radius-lg:     16px;

  --shadow-card:   0 4px 24px rgba(0,0,0,0.6);
  --shadow-hero:   0 8px 40px rgba(0,0,0,0.8);

  --font-title:    'Oswald', sans-serif;
  --font-body:     'Inter', sans-serif;

  --max-width:     1200px;
  --nav-height:    64px;

  /* Zones compétition */
  --ucl:    #1e88e5;
  --uel:    #e67e22;
  --uecl:   #27ae60;

  /* Tags statut */
  --ok:      #27ae60;
  --warning: #f39c12;
  --danger:  #e74c3c;
  --expired: #7f8c8d;
}

/* ─── RESET ─────────────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

html { font-size: 16px; scroll-behavior: smooth; }

body {
  background-color: var(--bg-base);
  color: var(--text-primary);
  font-family: var(--font-body);
  font-weight: 400;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; display: block; }
ul { list-style: none; }
button { cursor: pointer; border: none; background: none; font-family: inherit; }

/* ─── CONTAINER ─────────────────────────────────────────── */
.container {
  max-width: var(--max-width);
  margin: 0 auto;
  padding: 0 20px;
}

/* ─── HEADER ─────────────────────────────────────────────── */
.site-header {
  position: sticky;
  top: 0;
  z-index: 100;
  height: var(--nav-height);
  background: rgba(10,10,10,0.92);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--border);
}

.header-inner {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
}

/* Brand */
.site-brand { display: flex; align-items: center; gap: 10px; flex-shrink: 0; }
.brand-text { display: flex; align-items: baseline; gap: 6px; }
.brand-fc {
  font-family: var(--font-title);
  font-size: 13px;
  font-weight: 700;
  color: var(--barca-gold);
  letter-spacing: 2px;
  text-transform: uppercase;
}
.brand-name {
  font-family: var(--font-title);
  font-size: 20px;
  font-weight: 700;
  color: var(--text-primary);
  text-transform: uppercase;
  letter-spacing: 1px;
}

/* Nav desktop */
.primary-nav { display: flex; }
.nav-list { display: flex; gap: 4px; }
.nav-list li a {
  display: block;
  padding: 6px 14px;
  font-size: 13px;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  color: var(--text-secondary);
  border-radius: var(--radius-sm);
  transition: color .2s, background .2s;
}
.nav-list li a:hover,
.nav-list li.current-menu-item a {
  color: var(--text-primary);
  background: var(--bg-elevated);
}

/* Burger */
.burger {
  display: none;
  flex-direction: column;
  gap: 5px;
  padding: 8px;
}
.burger span {
  display: block;
  width: 22px;
  height: 2px;
  background: var(--text-primary);
  border-radius: 2px;
  transition: transform .3s, opacity .3s;
}
.burger.is-active span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
.burger.is-active span:nth-child(2) { opacity: 0; }
.burger.is-active span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

/* Mobile nav */
.mobile-nav {
  display: none;
  position: fixed;
  top: var(--nav-height);
  left: 0; right: 0; bottom: 0;
  background: rgba(10,10,10,0.97);
  backdrop-filter: blur(16px);
  z-index: 99;
  padding: 32px 24px;
  overflow-y: auto;
}
.mobile-nav.is-open { display: block; }
.mobile-nav-list { display: flex; flex-direction: column; gap: 4px; }
.mobile-nav-list li a {
  display: block;
  padding: 16px 0;
  font-family: var(--font-title);
  font-size: 28px;
  font-weight: 600;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border);
  text-transform: uppercase;
  letter-spacing: 1px;
  transition: color .2s, padding-left .2s;
}
.mobile-nav-list li a:hover { color: var(--text-primary); padding-left: 12px; }

/* ─── HERO HOMEPAGE ──────────────────────────────────────── */
.hero {
  position: relative;
  min-height: 70vh;
  display: flex;
  align-items: flex-end;
  background-color: var(--bg-surface);
  background-size: cover;
  background-position: center;
}

.hero-content {
  padding: 48px 20px;
  max-width: 780px;
}

.hero-title {
  font-family: var(--font-title);
  font-size: clamp(28px, 5vw, 52px);
  font-weight: 700;
  line-height: 1.1;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin: 12px 0 16px;
}
.hero-title a { color: var(--text-primary); }
.hero-title a:hover { color: var(--barca-gold); }

.hero-excerpt {
  color: var(--text-secondary);
  font-size: 16px;
  margin-bottom: 20px;
  max-width: 560px;
}

.hero-meta { margin-bottom: 24px; }
.meta-date, .meta-author, .meta-time {
  font-size: 13px;
  color: var(--text-muted);
  margin-right: 16px;
}

/* ─── BUTTONS ────────────────────────────────────────────── */
.btn-primary {
  display: inline-block;
  padding: 12px 28px;
  background: var(--barca-blue);
  color: #fff;
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  border-radius: var(--radius-sm);
  transition: background .2s, transform .1s;
}
.btn-primary:hover { background: #0060bb; transform: translateY(-1px); }

/* ─── TAGS ───────────────────────────────────────────────── */
.tag-cat {
  display: inline-block;
  padding: 4px 10px;
  background: var(--barca-red);
  color: #fff;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  border-radius: var(--radius-sm);
}
.tag-sm { font-size: 10px; padding: 3px 8px; }

.tag-ok      { display:inline-block; padding:3px 8px; border-radius:var(--radius-sm); background:rgba(39,174,96,.15);  color:var(--ok);      font-size:12px; font-weight:600; }
.tag-warning { display:inline-block; padding:3px 8px; border-radius:var(--radius-sm); background:rgba(243,156,18,.15); color:var(--warning); font-size:12px; font-weight:600; }
.tag-danger  { display:inline-block; padding:3px 8px; border-radius:var(--radius-sm); background:rgba(231,76,60,.15);  color:var(--danger);  font-size:12px; font-weight:600; }
.tag-expired { display:inline-block; padding:3px 8px; border-radius:var(--radius-sm); background:rgba(127,140,141,.15);color:var(--expired); font-size:12px; font-weight:600; }
.tag-unknown { display:inline-block; padding:3px 8px; border-radius:var(--radius-sm); background:var(--bg-elevated);   color:var(--text-muted); font-size:12px; }

/* ─── SECTIONS ───────────────────────────────────────────── */
.section-news     { padding: 60px 20px; }
.section-widgets  { padding: 0 20px 60px; }
.section-table    { padding: 48px 20px 80px; }

.section-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 32px;
}
.section-title {
  font-family: var(--font-title);
  font-size: 24px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.section-link {
  font-size: 13px;
  color: var(--barca-blue);
  font-weight: 500;
  transition: color .2s;
}
.section-link:hover { color: #0060bb; }

.subsection-title {
  font-family: var(--font-title);
  font-size: 20px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  margin: 40px 0 20px;
  padding-bottom: 10px;
  border-bottom: 1px solid var(--border);
  color: var(--text-secondary);
}
.subsection-title--poste { color: var(--barca-gold); }

/* ─── CARD NEWS ──────────────────────────────────────────── */
.news-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 20px;
}

.card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: transform .2s, border-color .2s, box-shadow .2s;
}
.card:hover {
  transform: translateY(-3px);
  border-color: var(--border-strong);
  box-shadow: var(--shadow-card);
}

.card-thumb { display: block; aspect-ratio: 16/9; overflow: hidden; }
.card-thumb img { width: 100%; height: 100%; object-fit: cover; object-position: center top; transition: transform .3s; }
.card:hover .card-thumb img { transform: scale(1.04); }

.card-body { padding: 16px; display: flex; flex-direction: column; gap: 8px; }
.card-title { font-family: var(--font-title); font-size: 17px; font-weight: 600; line-height: 1.3; text-transform: uppercase; }
.card-title a { color: var(--text-primary); transition: color .2s; }
.card-title a:hover { color: var(--barca-blue); }
.card-excerpt { font-size: 13px; color: var(--text-secondary); line-height: 1.5; }
.card-date { font-size: 12px; color: var(--text-muted); margin-top: auto; }

/* ─── WIDGETS ACCUEIL ────────────────────────────────────── */
.widgets-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 20px;
}

.widget-box {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 20px;
}

.widget-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 16px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border);
}
.widget-header h3 { font-family: var(--font-title); font-size: 16px; font-weight: 600; text-transform: uppercase; }
.widget-header a { font-size: 12px; color: var(--barca-blue); }

.widget-list { display: flex; flex-direction: column; gap: 10px; }
.widget-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 8px 0;
  border-bottom: 1px solid var(--border);
  font-size: 14px;
}
.widget-row:last-child { border-bottom: none; }
.player-name { font-weight: 500; }
.widget-empty { color: var(--text-muted); font-size: 14px; padding: 12px 0; }

/* Match widget */
.match-card { display: flex; flex-direction: column; gap: 12px; }
.match-competition { font-size: 11px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 1px; }
.match-teams {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 8px;
}
.team { font-family: var(--font-title); font-size: 16px; font-weight: 600; text-transform: uppercase; }
.team.home { color: var(--barca-blue); }
.match-vs { font-size: 12px; color: var(--text-muted); }
.match-info { display: flex; justify-content: space-between; font-size: 12px; color: var(--text-secondary); }
.match-lieu { font-weight: 600; }
.match-lieu.home { color: var(--barca-blue); }
.match-lieu.away { color: var(--barca-red); }

/* ─── PAGE HERO ──────────────────────────────────────────── */
.page-hero {
  min-height: 280px;
  display: flex;
  align-items: flex-end;
  background: var(--bg-surface);
  background-size: cover;
  background-position: center;
  background-attachment: fixed;
}
.page-hero .container { padding-bottom: 40px; padding-top: 100px; }
.page-title {
  font-family: var(--font-title);
  font-size: clamp(32px, 6vw, 56px);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 2px;
  line-height: 1.1;
}
.page-subtitle { color: var(--text-secondary); font-size: 16px; margin-top: 8px; }

/* ─── ARTICLE ────────────────────────────────────────────── */
.article-hero {
  min-height: 55vh;
  display: flex;
  align-items: flex-end;
  background-size: cover;
  background-position: center;
}
.article-hero-content { padding: 48px 20px; max-width: 800px; }
.article-header-simple { padding: 80px 20px 40px; }
.article-title {
  font-family: var(--font-title);
  font-size: clamp(26px, 4vw, 44px);
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  line-height: 1.1;
  margin: 12px 0 16px;
}
.article-meta { display: flex; flex-wrap: wrap; gap: 16px; font-size: 13px; color: var(--text-muted); }

.article-body { padding: 48px 20px 80px; max-width: 720px; margin: 0 auto; }
.article-content { font-size: 17px; line-height: 1.8; color: var(--text-secondary); }
.article-content h2 { font-family: var(--font-title); font-size: 26px; color: var(--text-primary); margin: 36px 0 16px; text-transform: uppercase; }
.article-content h3 { font-family: var(--font-title); font-size: 20px; color: var(--text-primary); margin: 28px 0 12px; text-transform: uppercase; }
.article-content p { margin-bottom: 20px; }
.article-content a { color: var(--barca-blue); border-bottom: 1px solid transparent; transition: border-color .2s; }
.article-content a:hover { border-color: var(--barca-blue); }
.article-content blockquote {
  border-left: 3px solid var(--barca-red);
  padding: 16px 24px;
  margin: 28px 0;
  background: var(--bg-surface);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-style: italic;
  color: var(--text-primary);
}
.article-content img { border-radius: var(--radius-md); margin: 28px 0; }

.article-tags { margin-top: 40px; display: flex; flex-wrap: wrap; gap: 8px; }
.article-tags a { padding: 5px 12px; background: var(--bg-elevated); border-radius: var(--radius-sm); font-size: 12px; color: var(--text-secondary); transition: background .2s; }
.article-tags a:hover { background: var(--bg-hover); }

/* Nav article prev/next */
.article-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 48px; padding-top: 32px; border-top: 1px solid var(--border); }
.article-nav-link { display: flex; flex-direction: column; gap: 6px; padding: 16px; background: var(--bg-surface); border: 1px solid var(--border); border-radius: var(--radius-md); transition: border-color .2s; }
.article-nav-link:hover { border-color: var(--border-strong); }
.article-nav-link.next { text-align: right; }
.nav-label { font-size: 11px; color: var(--text-muted); text-transform: uppercase; letter-spacing: 1px; }
.nav-title { font-size: 14px; font-weight: 500; color: var(--text-primary); }

/* ─── TABLES ─────────────────────────────────────────────── */
.table-responsive { overflow-x: auto; }

.data-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}
.data-table th {
  padding: 12px 16px;
  text-align: left;
  font-family: var(--font-title);
  font-size: 12px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
  border-bottom: 2px solid var(--border-strong);
  white-space: nowrap;
}
.data-table td {
  padding: 14px 16px;
  border-bottom: 1px solid var(--border);
  vertical-align: middle;
}
.data-table tbody tr { transition: background .15s; }
.data-table tbody tr:hover { background: var(--bg-surface); }

/* Classement zones */
.row-barca { background: rgba(0,77,152,0.08) !important; }
.row-barca:hover { background: rgba(0,77,152,0.14) !important; }
.zone-ucl  td:first-child, .pos-dot.zone-ucl  { border-left: 3px solid var(--ucl);  }
.zone-uel  td:first-child, .pos-dot.zone-uel  { border-left: 3px solid var(--uel);  }
.zone-uecl td:first-child, .pos-dot.zone-uecl { border-left: 3px solid var(--uecl); }

.pos-cell { font-weight: 700; text-align: center; width: 40px; }
.pos-dot { display: inline-block; width: 28px; height: 28px; border-radius: 50%; background: var(--bg-elevated); line-height: 28px; text-align: center; font-size: 13px; }
.pts-cell { font-size: 16px; color: var(--text-primary); text-align: center; }
.diff-pos { color: var(--ok); }
.diff-neg { color: var(--danger); }
.club-cell { font-weight: 500; }

/* Légende classement */
.classement-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  margin-top: 20px;
}
.legend-item {
  font-size: 12px;
  padding: 4px 12px;
  border-radius: var(--radius-sm);
  color: var(--text-primary);
}
.legend-item.zone-ucl  { background: rgba(30,136,229,.2);  border-left: 3px solid var(--ucl);  }
.legend-item.zone-uel  { background: rgba(230,126,34,.2);  border-left: 3px solid var(--uel);  }
.legend-item.zone-uecl { background: rgba(39,174,96,.2);   border-left: 3px solid var(--uecl); }

.table-note { font-size: 12px; color: var(--text-muted); margin-top: 16px; }

/* ─── BLESSURES TABLE ────────────────────────────────────── */
.player-cell { display: flex; align-items: center; gap: 12px; }
.player-avatar { width: 36px; height: 36px; border-radius: 50%; overflow: hidden; flex-shrink: 0; }
.player-avatar img { width: 100%; height: 100%; object-fit: cover; }

/* ─── CALENDRIER ─────────────────────────────────────────── */
.filter-tabs {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 32px;
}
.filter-btn {
  padding: 8px 18px;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: 99px;
  font-size: 13px;
  color: var(--text-secondary);
  transition: all .2s;
}
.filter-btn:hover,
.filter-btn.active {
  background: var(--barca-blue);
  border-color: var(--barca-blue);
  color: #fff;
}

.matches-list { display: flex; flex-direction: column; gap: 12px; }

.match-row {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 20px;
  transition: border-color .2s;
}
.match-row:hover { border-color: var(--border-strong); }

.match-competition-badge {
  font-size: 11px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
  margin-bottom: 12px;
}
.match-competition-badge.la-liga       { color: #f39c12; }
.match-competition-badge.champions-league { color: #1e88e5; }
.match-competition-badge.copa-del-rey  { color: #e74c3c; }

.match-teams-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  margin-bottom: 12px;
}
.team-block { flex: 1; }
.team-block.team-home .team-name { color: var(--barca-blue); }
.team-block.team-away { text-align: right; }
.team-name { font-family: var(--font-title); font-size: 18px; font-weight: 600; text-transform: uppercase; }
.match-center { text-align: center; flex-shrink: 0; }
.match-vs-big { font-family: var(--font-title); font-size: 13px; font-weight: 700; color: var(--text-muted); display: block; }
.match-datetime { font-size: 13px; color: var(--text-secondary); }
.match-score { font-family: var(--font-title); font-size: 28px; font-weight: 700; color: var(--barca-gold); padding: 0 16px; }

.match-meta-row { display: flex; gap: 12px; }
.match-lieu-tag { font-size: 12px; font-weight: 600; }
.match-lieu-tag.home { color: var(--barca-blue); }
.match-lieu-tag.away { color: var(--barca-red); }

.match-row--result { opacity: .8; }
.match-row--result:hover { opacity: 1; }
.match-date-past { font-size: 12px; color: var(--text-muted); }
.result-win  { border-left: 3px solid var(--ok); }
.result-draw { border-left: 3px solid var(--warning); }
.result-loss { border-left: 3px solid var(--danger); }

/* Competition badges */
.match-competition-badge.primera-division    { color: #f39c12; }
.match-competition-badge.uefa-champions-league { color: #1e88e5; }
.match-competition-badge.copa-del-rey        { color: #e74c3c; }

/* ─── EFFECTIF ───────────────────────────────────────────── */
.effectif-section { margin-bottom: 48px; }

.players-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 16px;
}

.player-card {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
  transition: transform .2s, border-color .2s;
}
.player-card:hover { transform: translateY(-3px); border-color: var(--border-strong); }

.player-card-header {
  position: relative;
  background: var(--bg-elevated);
  padding: 16px;
  display: flex;
  align-items: center;
  gap: 12px;
}
.player-number {
  font-family: var(--font-title);
  font-size: 32px;
  font-weight: 700;
  color: var(--border-strong);
  line-height: 1;
  min-width: 40px;
}
.player-photo { width: 56px; height: 56px; border-radius: 50%; overflow: hidden; border: 2px solid var(--border-strong); }
.player-photo img { width: 100%; height: 100%; object-fit: cover; object-position: center top; }
.player-photo--placeholder {
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-hover);
  font-family: var(--font-title);
  font-size: 22px;
  font-weight: 700;
  color: var(--text-muted);
}

.player-card-body { padding: 14px; }
.player-card-name { font-family: var(--font-title); font-size: 15px; font-weight: 600; text-transform: uppercase; margin-bottom: 8px; }
.player-card-info { display: flex; flex-direction: column; gap: 4px; margin-bottom: 12px; }
.info-row { font-size: 12px; color: var(--text-secondary); }

.player-contrat {
  padding-top: 12px;
  border-top: 1px solid var(--border);
}
.contrat-label { font-size: 10px; text-transform: uppercase; letter-spacing: 1px; color: var(--text-muted); margin-bottom: 4px; display: block; }
.contrat-info { display: flex; align-items: center; justify-content: space-between; }
.contrat-date { font-size: 12px; color: var(--text-secondary); }

/* ─── EMPTY STATE ────────────────────────────────────────── */
.empty-state {
  text-align: center;
  padding: 80px 20px;
  color: var(--text-secondary);
}
.empty-icon { font-size: 48px; display: block; margin-bottom: 16px; }
.empty-sub { font-size: 14px; color: var(--text-muted); margin-top: 8px; }

/* ─── EFFECTIF TABLE ─────────────────────────────────────── */
.effectif-intro {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  padding: 24px 28px;
  margin-bottom: 40px;
  line-height: 1.8;
  color: var(--text-secondary);
  font-size: 15px;
}
.effectif-intro strong { color: var(--text-primary); }
.effectif-intro a { color: var(--barca-blue); }
.effectif-source { margin-top: 10px; font-size: 13px; color: var(--text-muted); }

.poste-count {
  font-size: 13px;
  font-weight: 400;
  color: var(--text-muted);
  margin-left: 10px;
  text-transform: none;
  letter-spacing: 0;
}

.effectif-table .player-name-cell {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 160px;
}
.player-mini-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  overflow: hidden;
  flex-shrink: 0;
  border: 1px solid var(--border-strong);
}
.player-mini-avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  object-position: top;
}

.valeur-badge {
  display: inline-block;
  padding: 3px 10px;
  background: rgba(237,187,0,.1);
  color: var(--barca-gold);
  border-radius: var(--radius-sm);
  font-size: 13px;
  font-weight: 600;
}
.valeur-cell { white-space: nowrap; }

/* ─── SECTION STANDINGS (homepage) ──────────────────────── */
.section-standings {
  padding: 0 20px 48px;
}
.section-standings .data-table { margin-top: 0; }
.section-standings .classement-legend { margin-top: 12px; }

/* ─── FOOTER ─────────────────────────────────────────────── */
.site-footer {
  background: var(--bg-surface);
  border-top: 1px solid var(--border);
  padding: 60px 20px 32px;
  margin-top: 40px;
}
.footer-grid {
  display: grid;
  grid-template-columns: 2fr 1fr 1fr;
  gap: 48px;
  margin-bottom: 48px;
}
.footer-desc { font-size: 14px; color: var(--text-muted); margin-top: 12px; line-height: 1.6; }

.footer-nav h4,
.footer-info h4 {
  font-family: var(--font-title);
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-secondary);
  margin-bottom: 16px;
}
.footer-nav-list li { margin-bottom: 8px; }
.footer-nav-list a { font-size: 14px; color: var(--text-muted); transition: color .2s; }
.footer-nav-list a:hover { color: var(--text-primary); }

.footer-info p { font-size: 13px; color: var(--text-muted); line-height: 1.6; }
.footer-copy { margin-top: 8px; }

.footer-bottom {
  padding-top: 24px;
  border-top: 1px solid var(--border);
  text-align: center;
}
.footer-badge { font-size: 13px; color: var(--text-muted); }

/* ─── PAGINATION ─────────────────────────────────────────── */
.pagination { margin-top: 48px; display: flex; justify-content: center; }
.pagination .page-numbers {
  display: flex;
  gap: 4px;
  flex-wrap: wrap;
}
.pagination .page-numbers li a,
.pagination .page-numbers li span {
  display: block;
  padding: 8px 14px;
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  font-size: 14px;
  color: var(--text-secondary);
  transition: all .2s;
}
.pagination .page-numbers li .current,
.pagination .page-numbers li a:hover {
  background: var(--barca-blue);
  border-color: var(--barca-blue);
  color: #fff;
}

/* ─── META BOXES ADMIN ───────────────────────────────────── */
.barca-meta-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; padding: 8px 0; }
.barca-meta-grid p { margin: 0; }
.barca-meta-grid label { font-weight: 600; font-size: 13px; display: block; margin-bottom: 4px; }
.barca-meta-grid input,
.barca-meta-grid select {
  width: 100%;
  padding: 6px 10px;
  border: 1px solid #ddd;
  border-radius: 4px;
  font-size: 14px;
}

/* ─── RESPONSIVE ─────────────────────────────────────────── */
@media (max-width: 768px) {
  :root { --nav-height: 56px; }

  /* Nav */
  .primary-nav { display: none; }
  .burger { display: flex; }

  /* Hero */
  .hero { min-height: 60vw; }
  .hero-content { padding: 24px 0; }
  .hero-title { font-size: clamp(22px, 6vw, 32px); }
  .hero-excerpt { display: none; }

  /* Homepage 3 colonnes → 1 colonne sur mobile */
  .homepage-top-grid {
    grid-template-columns: 1fr;
    min-height: auto;
  }
  .hw-col { border-right: none; border-bottom: 1px solid var(--border-strong); }
  .featured-col {
    min-height: 280px;
    border-left: none;
    border-right: none;
    border-bottom: 1px solid var(--border);
  }
  .featured-inner { padding: 24px 16px; }
  .news-feed { max-height: 320px; border-top: 1px solid var(--border); }

  /* Bande match */
  .match-strip-inner { gap: 10px; }
  .match-strip-cta { margin-left: 0; }

  /* Articles section mobile */
  .homepage-articles { padding: 28px 12px 60px; }

  /* Layout 2 colonnes → 1 colonne sur mobile */
  .content-sidebar-layout {
    grid-template-columns: 1fr;
    gap: 32px;
    padding: 28px 12px 60px;
  }
  .sidebar { position: static; }

  /* Sections */
  .section-news, .section-widgets, .section-table,
  .section-standings { padding-left: 12px; padding-right: 12px; }

  /* Grilles */
  .news-grid { grid-template-columns: 1fr; gap: 14px; }
  .widgets-row { grid-template-columns: 1fr; gap: 14px; }
  .footer-grid { grid-template-columns: 1fr; gap: 28px; }

  /* Cards */
  .card-title { font-size: 15px; }
  .card-excerpt { font-size: 13px; }

  /* Match */
  .match-teams-row { gap: 6px; }
  .team-name { font-size: 14px; }
  .match-score { font-size: 20px; padding: 0 8px; }
  .match-row { padding: 14px 12px; }

  /* Tables — scroll horizontal sur mobile */
  .table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    margin: 0 -12px;
    padding: 0 12px;
  }
  .table-responsive::after {
    content: '← swipe →';
    display: block;
    font-size: 11px;
    color: var(--text-muted);
    text-align: center;
    padding: 6px 0;
  }
  .data-table { min-width: 520px; }
  .data-table th, .data-table td { padding: 10px 10px; font-size: 13px; }

  /* Effectif — masquer colonnes secondaires sur mobile */
  .effectif-table th:nth-child(2),
  .effectif-table td:nth-child(2),
  .effectif-table th:nth-child(4),
  .effectif-table td:nth-child(4) { display: none; }

  /* Classement — masquer BP/BC sur mobile */
  .classement-table th:nth-child(7),
  .classement-table td:nth-child(7),
  .classement-table th:nth-child(8),
  .classement-table td:nth-child(8) { display: none; }

  /* Intro effectif */
  .effectif-intro { padding: 16px; font-size: 14px; }

  /* Article */
  .article-nav { grid-template-columns: 1fr; }
  .article-nav-link.next { text-align: left; }
  .article-body { padding: 28px 12px 60px; }
  .article-content { font-size: 16px; }

  /* Page hero */
  .page-hero { min-height: 200px; background-attachment: scroll; }
  .page-title { font-size: clamp(26px, 7vw, 40px); }

  /* Touch targets minimum 44px */
  .nav-list li a, .filter-btn, .btn-primary,
  .mobile-nav-list li a { min-height: 44px; display: flex; align-items: center; justify-content: center; }
  .mobile-nav-list li a { justify-content: flex-start; }

  /* Pagination */
  .pagination .page-numbers li a,
  .pagination .page-numbers li span { padding: 10px 14px; }

  .barca-meta-grid { grid-template-columns: 1fr; }
}

@media (max-width: 480px) {
  .container { padding: 0 12px; }
  .filter-tabs { gap: 6px; flex-wrap: nowrap; overflow-x: auto; padding-bottom: 4px; }
  .filter-btn { padding: 8px 14px; font-size: 12px; white-space: nowrap; flex-shrink: 0; min-height: 40px; }
  .section-title { font-size: 20px; }
  .widget-box { padding: 14px; }
  .hero-title { font-size: 22px; }
  .match-competition-badge { font-size: 10px; }
}

/* ═══════════════════════════════════════════════════════════
   HOMEPAGE — SECTION 1 : 3 COLONNES (LIGA | À LA UNE | FEED)
   ═══════════════════════════════════════════════════════════ */
.homepage-top {
  background: var(--bg-surface);
  border-bottom: 2px solid var(--border-strong);
}

.homepage-top-grid {
  display: grid;
  grid-template-columns: 260px 1fr 300px;
  gap: 0;
  min-height: 460px;
}

/* ── Colonne gauche : classement ── */
.hw-col {
  display: flex;
  flex-direction: column;
  border-right: 1px solid var(--border);
  background: var(--bg-elevated);
}

.hw-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 11px 16px;
  background: rgba(255,255,255,.03);
  border-bottom: 1px solid var(--border);
}
.hw-card-header h3 {
  font-family: var(--font-title);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
}
.hw-card-more {
  font-size: 11px;
  color: var(--barca-blue);
  font-weight: 500;
  transition: color .15s;
}
.hw-card-more:hover { color: #0060bb; }

.hw-card-body { flex: 1; }

/* Standings compact dans hw-card */
.hw-card-body--standings .data-table th { padding: 7px 10px; font-size: 10px; }
.hw-card-body--standings .data-table td { padding: 8px 10px; font-size: 12px; }
.hw-card-body--standings .classement-legend,
.hw-card-body--standings .table-note,
.hw-card-body--standings .table-responsive::after { display: none; }
.hw-card-body--standings .pos-dot { width: 20px; height: 20px; line-height: 20px; font-size: 10px; }
.hw-card-body--standings .data-table { min-width: 0; }
/* Afficher seulement : #, Club, +/-, Pts — masquer J,G,N,P,BP,BC */
.hw-card-body--standings .classement-table th:nth-child(3),
.hw-card-body--standings .classement-table td:nth-child(3),
.hw-card-body--standings .classement-table th:nth-child(4),
.hw-card-body--standings .classement-table td:nth-child(4),
.hw-card-body--standings .classement-table th:nth-child(5),
.hw-card-body--standings .classement-table td:nth-child(5),
.hw-card-body--standings .classement-table th:nth-child(6),
.hw-card-body--standings .classement-table td:nth-child(6),
.hw-card-body--standings .classement-table th:nth-child(7),
.hw-card-body--standings .classement-table td:nth-child(7),
.hw-card-body--standings .classement-table th:nth-child(8),
.hw-card-body--standings .classement-table td:nth-child(8) { display: none; }

.hw-card-footer {
  display: block;
  text-align: center;
  padding: 10px 16px;
  font-size: 12px;
  font-weight: 600;
  color: var(--barca-blue);
  border-top: 1px solid var(--border);
  background: rgba(0,77,152,.06);
  transition: background .2s, color .2s;
  letter-spacing: 0.3px;
}
.hw-card-footer:hover { background: var(--barca-blue); color: #fff; }

/* ── Prochain match — affichage grand ── */
.hw-match {
  padding: 20px 16px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 14px;
  text-align: center;
}
.hw-match-comp {
  font-size: 10px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--text-muted);
  display: block;
}
.hw-match-teams {
  display: flex;
  align-items: center;
  gap: 10px;
  width: 100%;
}
.hw-team {
  flex: 1;
  text-align: center;
}
.hw-team--barca .hw-team-name { color: var(--barca-blue); }
.hw-team-name {
  font-family: var(--font-title);
  font-size: 17px;
  font-weight: 700;
  text-transform: uppercase;
  line-height: 1.1;
  display: block;
}
.hw-match-center {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 2px;
  flex-shrink: 0;
  min-width: 64px;
}
.hw-vs {
  font-family: var(--font-title);
  font-size: 20px;
  font-weight: 900;
  color: var(--barca-gold);
  display: block;
}
.hw-match-date {
  font-size: 11px;
  font-weight: 600;
  color: var(--text-secondary);
  white-space: nowrap;
}
.hw-match-time {
  font-size: 16px;
  font-weight: 700;
  font-family: var(--font-title);
  color: var(--text-primary);
  letter-spacing: 1px;
}
.hw-match-lieu {
  font-size: 13px;
  font-weight: 600;
  padding: 5px 14px;
  border-radius: 99px;
  display: inline-block;
}
.hw-match-lieu.home { background: rgba(0,77,152,.15); color: var(--barca-blue); }
.hw-match-lieu.away { background: rgba(165,0,68,.15);  color: var(--barca-red);  }

/* ── Feed d'actualités ── */
.news-feed {
  background: var(--bg-surface);
  display: flex;
  flex-direction: column;
}

.news-feed-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 13px 18px;
  border-bottom: 2px solid var(--barca-red);
  background: var(--bg-elevated);
  flex-shrink: 0;
}
.news-feed-header h3 {
  font-family: var(--font-title);
  font-size: 13px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
}
.news-feed-more { font-size: 11px; color: var(--barca-blue); font-weight: 500; transition: color .2s; }
.news-feed-more:hover { color: #0060bb; }

.news-feed-list {
  overflow-y: auto;
  flex: 1;
  scrollbar-width: thin;
  scrollbar-color: var(--border-strong) transparent;
}
.news-feed-list::-webkit-scrollbar { width: 4px; }
.news-feed-list::-webkit-scrollbar-thumb { background: var(--border-strong); border-radius: 4px; }

.news-feed-item { border-bottom: 1px solid var(--border); }
.news-feed-item:last-child { border-bottom: none; }

.news-feed-link {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 11px 18px;
  transition: background .15s;
}
.news-feed-link:hover { background: var(--bg-elevated); }

.news-feed-thumb {
  flex-shrink: 0;
  width: 60px;
  height: 44px;
  border-radius: var(--radius-sm);
  overflow: hidden;
}
.news-feed-thumb img { width: 100%; height: 100%; object-fit: cover; }

.news-feed-text { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.news-feed-cat { font-size: 10px; font-weight: 700; text-transform: uppercase; letter-spacing: 0.8px; color: var(--barca-red); }
.news-feed-title {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-primary);
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.news-feed-time { font-size: 11px; color: var(--text-muted); margin-top: 1px; }

/* ── Colonne centrale : article à la une ── */
.featured-col {
  position: relative;
  background: var(--bg-base) center/cover no-repeat;
  display: flex;
  align-items: flex-end;
  border-left: 1px solid var(--border);
  border-right: 1px solid var(--border);
}
.featured-inner {
  padding: 32px 28px;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 12px;
}
.featured-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--barca-gold);
  background: rgba(237,187,0,.12);
  border: 1px solid rgba(237,187,0,.3);
  padding: 4px 10px;
  border-radius: var(--radius-sm);
  width: fit-content;
}
.featured-title {
  font-family: var(--font-title);
  font-size: clamp(20px, 2.4vw, 34px);
  font-weight: 700;
  line-height: 1.1;
  text-transform: uppercase;
}
.featured-title a { color: var(--text-primary); transition: color .2s; }
.featured-title a:hover { color: var(--barca-gold); }
.featured-excerpt { font-size: 14px; color: var(--text-secondary); line-height: 1.6; }
.featured-meta { display: flex; gap: 14px; font-size: 12px; color: var(--text-muted); align-items: center; }
.featured-time { color: var(--barca-gold); font-weight: 600; }

/* ─── Bande prochain match ──────────────────────────────── */
.homepage-match-strip {
  background: linear-gradient(90deg, rgba(0,77,152,.18) 0%, rgba(0,77,152,.06) 100%);
  border-top: 1px solid rgba(0,77,152,.3);
  border-bottom: 1px solid rgba(0,77,152,.3);
}
.match-strip-inner {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 14px 20px;
  flex-wrap: wrap;
}
.match-strip-label {
  font-size: 11px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 1px;
  color: var(--text-muted);
  flex-shrink: 0;
}
.match-strip-comp {
  font-size: 11px;
  color: var(--text-muted);
  flex-shrink: 0;
}
.match-strip-teams {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-shrink: 0;
}
.match-strip-team {
  font-family: var(--font-title);
  font-size: 16px;
  font-weight: 700;
  text-transform: uppercase;
  color: var(--text-primary);
}
.match-strip-barca { color: var(--barca-blue); }
.match-strip-vs {
  font-family: var(--font-title);
  font-size: 13px;
  font-weight: 900;
  color: var(--barca-gold);
  padding: 0 4px;
}
.match-strip-datetime {
  font-size: 14px;
  font-weight: 600;
  color: var(--text-secondary);
  flex-shrink: 0;
}
.match-strip-lieu {
  font-size: 12px;
  font-weight: 600;
  padding: 3px 10px;
  border-radius: 99px;
  flex-shrink: 0;
}
.match-strip-lieu.home { background: rgba(0,77,152,.18); color: var(--barca-blue); }
.match-strip-lieu.away { background: rgba(165,0,68,.18);  color: var(--barca-red);  }
.match-strip-cta {
  margin-left: auto;
  font-size: 12px;
  font-weight: 600;
  color: var(--barca-blue);
  flex-shrink: 0;
  transition: color .2s;
}
.match-strip-cta:hover { color: #0060bb; }

/* ═══════════════════════════════════════════════════════════
   HOMEPAGE — SECTION 3 : GRILLE D'ARTICLES
   ═══════════════════════════════════════════════════════════ */
.homepage-articles {
  padding: 48px 20px 80px;
}

/* ─── LAYOUT: CONTENT + SIDEBAR ────────────────────────── */
.content-sidebar-layout {
  display: grid;
  grid-template-columns: 1fr 320px;
  gap: 40px;
  padding: 48px 20px 80px;
  align-items: start;
}

/* ─── SIDEBAR ────────────────────────────────────────────── */
.sidebar {
  position: sticky;
  top: calc(var(--nav-height) + 16px);
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.sidebar-widget {
  background: var(--bg-surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-md);
  overflow: hidden;
}

.sidebar-widget-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 12px 16px;
  background: var(--bg-elevated);
  border-bottom: 1px solid var(--border);
}
.sidebar-widget-header h3 {
  font-family: var(--font-title);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.8px;
}
.sidebar-widget-link {
  font-size: 11px;
  color: var(--barca-blue);
  font-weight: 500;
  transition: color .2s;
}
.sidebar-widget-link:hover { color: #0060bb; }

.sidebar-widget-body { padding: 16px; }

/* Standings compact dans sidebar */
.sidebar-widget-body--standings { padding: 0; }
.sidebar-widget-body--standings .data-table th { padding: 7px 8px; font-size: 10px; }
.sidebar-widget-body--standings .data-table td { padding: 7px 8px; font-size: 12px; }
.sidebar-widget-body--standings .classement-legend,
.sidebar-widget-body--standings .table-note,
.sidebar-widget-body--standings .table-responsive::after { display: none; }
.sidebar-widget-body--standings .pos-dot { width: 22px; height: 22px; line-height: 22px; font-size: 11px; }
.sidebar-widget-body--standings .data-table { min-width: 0; }

/* File d'actualité sidebar */
.sidebar-news-list { display: flex; flex-direction: column; }
.sidebar-news-item { border-bottom: 1px solid var(--border); }
.sidebar-news-item:last-child { border-bottom: none; }
.sidebar-news-item a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 0;
  transition: opacity .2s;
}
.sidebar-news-item a:hover { opacity: .7; }
.sidebar-news-thumb {
  flex-shrink: 0;
  width: 56px;
  height: 42px;
  border-radius: var(--radius-sm);
  overflow: hidden;
}
.sidebar-news-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}
.sidebar-news-text { display: flex; flex-direction: column; gap: 3px; min-width: 0; }
.sidebar-news-title {
  font-size: 13px;
  font-weight: 500;
  color: var(--text-primary);
  line-height: 1.35;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
}
.sidebar-news-date { font-size: 11px; color: var(--text-muted); }

/* Article dans le layout 2 colonnes */
.article-main { min-width: 0; }
.article-main .article-content {
  font-size: 17px;
  line-height: 1.8;
  color: var(--text-secondary);
}
.article-main .article-content h2 { font-family: var(--font-title); font-size: 24px; color: var(--text-primary); margin: 32px 0 14px; text-transform: uppercase; }
.article-main .article-content h3 { font-family: var(--font-title); font-size: 18px; color: var(--text-primary); margin: 24px 0 10px; text-transform: uppercase; }
.article-main .article-content p { margin-bottom: 20px; }
.article-main .article-content a { color: var(--barca-blue); border-bottom: 1px solid transparent; transition: border-color .2s; }
.article-main .article-content a:hover { border-color: var(--barca-blue); }
.article-main .article-content blockquote {
  border-left: 3px solid var(--barca-red);
  padding: 16px 24px;
  margin: 28px 0;
  background: var(--bg-surface);
  border-radius: 0 var(--radius-sm) var(--radius-sm) 0;
  font-style: italic;
  color: var(--text-primary);
}
.article-main .article-content img { border-radius: var(--radius-md); margin: 28px 0; }
.article-main .article-tags { margin-top: 40px; display: flex; flex-wrap: wrap; gap: 8px; }
.article-main .article-tags a { padding: 5px 12px; background: var(--bg-elevated); border-radius: var(--radius-sm); font-size: 12px; color: var(--text-secondary); transition: background .2s; }
.article-main .article-tags a:hover { background: var(--bg-hover); }
.article-main .article-nav { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; margin-top: 48px; padding-top: 32px; border-top: 1px solid var(--border); }

/* ─── RESPONSIVE SIDEBAR ─────────────────────────────────── */
@media (max-width: 1024px) {
  .content-sidebar-layout { grid-template-columns: 1fr 280px; gap: 28px; }
}

/* Safe area pour iPhone (notch, home bar) */
@supports (padding: max(0px)) {
  .site-header .header-inner { padding-left: max(20px, env(safe-area-inset-left)); padding-right: max(20px, env(safe-area-inset-right)); }
  .site-footer { padding-bottom: max(32px, env(safe-area-inset-bottom)); }
  .mobile-nav { padding-bottom: max(32px, env(safe-area-inset-bottom)); }
}
