@import url('https://fonts.googleapis.com/css2?family=Montserrat:wght@400;500;600;700&family=Open+Sans:wght@400;500;600&display=swap');

:root {
  /* Colores institucionales */
  --primary:      #45a9ff;   /* azul institucional */
  --primary-dark: #0d3b6e;   /* azul oscuro — fondos nav/footer/header */
  --primary-mid:  #1a7fd4;   /* azul medio — links, hover */
  --gold:         #C8960C;   /* dorado accent */
  --gold-light:   #F0B429;
  /* Eslogan / texto secundario */
  --slogan:       #a6a6a6;
  /* Estructura */
  --white:        #FFFFFF;
  --bg:           #f4f7fb;
  --text:         #1a2a3a;
  --text-muted:   #a6a6a6;   /* mismo que --slogan */
  --border:       #c8ddf0;
  --shadow:       0 2px 12px rgba(13,59,110,0.10);
  --radius:       10px;
}

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

body {
  font-family: 'Open Sans', Arial, sans-serif;
  background-color: var(--bg);
  background-image: url('../img/1.png');
  background-size: cover;
  background-attachment: fixed;
  background-position: center top;
  color: var(--text);
  line-height: 1.65;
}


.container {
  width: min(1140px, 100% - 2rem);
  margin: 0 auto;
}

/* ── MAIN NAV ── */
.main-nav {
  background: var(--primary-dark);
  position: sticky;
  top: 0;
  z-index: 100;
  box-shadow: 0 2px 8px rgba(0,0,0,0.25);
}
.main-nav .container {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 60px;
}
/* Logo dentro del nav */
.nav-logo {
  display: flex;
  align-items: center;
  flex-shrink: 0;
  line-height: 0;
  padding: 0.4rem 0.75rem 0.4rem 0;
  border-right: 1px solid rgba(255,255,255,0.15);
  margin-right: 0.25rem;
}
.nav-logo img {
  height: 46px;
  width: auto;
  transition: opacity 0.2s;
}
.nav-logo:hover img { opacity: 0.85; }
.nav-links {
  display: flex;
  align-items: stretch;
  list-style: none;
  flex: 1;
  flex-wrap: wrap;
}
.nav-links a {
  display: flex;
  align-items: center;
  padding: 0 0.9rem;
  height: 60px;
  color: rgba(255,255,255,0.82);
  text-decoration: none;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.8rem;
  font-weight: 500;
  border-bottom: 3px solid transparent;
  transition: background 0.18s, color 0.18s;
  white-space: nowrap;
}
.nav-links a:hover, .nav-links a.active {
  background: rgba(69,169,255,0.12);
  color: var(--primary);
  border-bottom-color: var(--primary);
}
.nav-end {
  display: flex;
  align-items: center;
  padding: 0 0.75rem;
  gap: 0.5rem;
}
.nav-end a {
  background: var(--primary);
  color: var(--primary-dark);
  padding: 0.35rem 0.85rem;
  border-radius: 6px;
  text-decoration: none;
  font-family: 'Montserrat', sans-serif;
  font-size: 0.77rem;
  font-weight: 700;
  white-space: nowrap;
  transition: background 0.18s;
}
.nav-end a:hover { background: #6ec4ff; }
.nav-end a.nav-logout { background: #c0392b; color: #fff; }
.nav-end a.nav-logout:hover { background: #96281b; }

/* ── HERO ── */
.hero {
  background: linear-gradient(135deg, var(--primary-dark) 0%, #1a5a9a 55%, var(--primary-mid) 100%);
  color: var(--white);
  padding: 3rem 0 2.5rem;
}
.hero-badge {
  display: inline-block;
  background: var(--primary);
  color: var(--primary-dark);
  font-family: 'Montserrat', sans-serif;
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.22rem 0.75rem;
  border-radius: 20px;
  margin-bottom: 0.75rem;
  text-transform: uppercase;
  letter-spacing: 0.06em;
}
.hero h1 {
  font-family: 'Montserrat', sans-serif;
  font-size: 1.85rem;
  font-weight: 700;
  margin-bottom: 0.6rem;
  line-height: 1.25;
}
/* Eslogan del hero */
.hero p { font-size: 1rem; color: var(--slogan); max-width: 580px; }

/* ── PAGE MAIN ── */
main.page-main { padding: 1.75rem 0 3rem; background: rgba(244, 247, 251, 0.82); }

/* ── FLASH ── */
.flash-wrap { margin-bottom: 1.25rem; }
.alert {
  padding: 0.85rem 1.1rem;
  border-radius: 8px;
  margin-bottom: 0.5rem;
  font-size: 0.92rem;
  border-left: 4px solid;
}
.alert-success { background: #e8f5e9; color: #1B5E20; border-color: #2E7D32; }
.alert-danger  { background: #fce4e4; color: #7f1d1d; border-color: #c0392b; }
.alert-warning { background: #fef9e7; color: #7d6608; border-color: var(--gold); }
.alert-info    { background: #e8f4ff; color: var(--primary-dark); border-color: var(--primary); }

/* ── BREADCRUMB ── */
.breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  font-size: 0.82rem;
  color: var(--slogan);
  margin-bottom: 1.25rem;
  flex-wrap: wrap;
}
.breadcrumb a { color: var(--primary-mid); text-decoration: none; }
.breadcrumb a:hover { color: var(--primary-dark); text-decoration: underline; }
.breadcrumb-sep { color: var(--border); }

/* ── CARDS ── */
.card-grid {
  display: grid;
  gap: 1.25rem;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  margin-top: 1.25rem;
}
.card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  border-left: 4px solid var(--primary);
  padding: 1.5rem;
  display: flex;
  flex-direction: column;
  transition: transform 0.2s, box-shadow 0.2s;
}
.card:hover { transform: translateY(-3px); box-shadow: 0 8px 24px rgba(69,169,255,0.20); }
.card h2 { font-family: 'Montserrat', sans-serif; font-size: 0.97rem; font-weight: 600; margin-bottom: 0.5rem; }
.card h2 a { color: var(--primary-dark); text-decoration: none; }
.card h2 a:hover { color: var(--primary-mid); }
.card p { color: var(--slogan); font-size: 0.9rem; flex: 1; }
/* Meta / eslogan de la card */
.meta { font-size: 0.8rem; color: var(--slogan); margin-top: 0.75rem; padding-top: 0.75rem; border-top: 1px solid var(--border); }

/* ── PAGE HEADER ── */
.page-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
}
.page-header h1 { font-family: 'Montserrat', sans-serif; font-size: 1.35rem; color: var(--primary-dark); }
.page-subtitle { font-family: 'Montserrat', sans-serif; font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.08em; color: var(--slogan); margin: 0; }

/* ── DETAIL ── */
.detail {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 2rem;
  margin-bottom: 1.25rem;
}
.detail h1 {
  font-family: 'Montserrat', sans-serif;
  font-size: 1.35rem;
  color: var(--primary-dark);
  margin-bottom: 0.75rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--border);
}
.detail h2 { font-family: 'Montserrat', sans-serif; font-size: 1.02rem; color: var(--primary-mid); margin: 1.5rem 0 0.75rem; }
.detail > p { color: var(--slogan); }

/* ── LIST ── */
.item-list { list-style: none; border: 1px solid var(--border); border-radius: 8px; overflow: hidden; }
.item-list li {
  padding: 0.78rem 1rem;
  border-bottom: 1px solid var(--border);
  display: flex;
  align-items: center;
  gap: 0.6rem;
  background: var(--white);
  transition: background 0.12s;
}
.item-list li:last-child { border-bottom: none; }
.item-list li:hover { background: #edf5ff; }
.item-list li::before { content: ''; display: inline-block; width: 7px; height: 7px; background: var(--primary); border-radius: 50%; flex-shrink: 0; }
.item-list a { color: var(--primary-dark); text-decoration: none; font-weight: 500; font-size: 0.92rem; }
.item-list a:hover { color: var(--primary-mid); }

/* ── DETAIL GRID ── */
.detail-grid {
  display: grid;
  grid-template-columns: max-content 1fr;
  gap: 0.5rem 1.25rem;
  background: var(--bg);
  border-radius: 8px;
  padding: 1rem 1.25rem;
  margin: 1.25rem 0;
}
.detail-grid dt { font-weight: 600; color: var(--primary-dark); font-size: 0.87rem; }
.detail-grid dd { font-size: 0.87rem; color: var(--text); }

/* ── BUTTONS ── */
.btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.62rem 1.25rem;
  border-radius: 8px;
  border: none;
  font-family: 'Montserrat', sans-serif;
  font-weight: 600;
  font-size: 0.87rem;
  text-decoration: none;
  cursor: pointer;
  transition: background 0.18s, transform 0.12s;
  line-height: 1;
}
.btn:active { transform: scale(0.97); }
.btn-primary { background: var(--primary-dark); color: var(--white); }
.btn-primary:hover { background: #0a2d55; }
.btn-gold { background: var(--gold); color: #fff; }
.btn-gold:hover { background: var(--gold-light); color: var(--primary-dark); }
.btn-outline { background: transparent; color: var(--primary-mid); border: 2px solid var(--primary); }
.btn-outline:hover { background: var(--primary); color: var(--primary-dark); }
.btn-danger { background: #c0392b; color: var(--white); }
.btn-danger:hover { background: #96281b; }
.btn-sm { padding: 0.38rem 0.8rem; font-size: 0.77rem; }
.button { display: inline-flex; align-items: center; gap: 0.35rem; padding: 0.62rem 1.25rem; background: var(--primary-dark); color: var(--white); text-decoration: none; border-radius: 8px; font-family: 'Montserrat', sans-serif; font-weight: 600; font-size: 0.87rem; transition: background 0.18s; }
.button:hover { background: #0a2d55; }

/* ── FORMS ── */
.form-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 2rem;
  max-width: 820px;
  margin: 0 auto;
}
.form-card h1 {
  font-family: 'Montserrat', sans-serif;
  font-size: 1.25rem;
  color: var(--primary-dark);
  margin-bottom: 1.5rem;
  padding-bottom: 0.75rem;
  border-bottom: 2px solid var(--border);
}
.form-group { margin-bottom: 1.1rem; }
label {
  display: block;
  font-family: 'Montserrat', sans-serif;
  font-weight: 600;
  font-size: 0.84rem;
  color: var(--primary-dark);
  margin-bottom: 0.35rem;
}
input[type=text], input[type=password], input[type=date], input[type=url], input[type=email], textarea, select {
  width: 100%;
  padding: 0.7rem 0.9rem;
  border: 1.5px solid var(--border);
  border-radius: 7px;
  font-family: 'Open Sans', sans-serif;
  font-size: 0.92rem;
  color: var(--text);
  background: var(--white);
  transition: border-color 0.2s, box-shadow 0.2s;
}
input:focus, textarea:focus, select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(69,169,255,0.18);
}
textarea { min-height: 110px; resize: vertical; }
.form-actions { display: flex; gap: 0.75rem; margin-top: 1.5rem; flex-wrap: wrap; }
button[type=submit] {
  padding: 0.7rem 2rem;
  background: var(--primary-dark);
  color: var(--white);
  border: none;
  border-radius: 8px;
  font-family: 'Montserrat', sans-serif;
  font-weight: 700;
  font-size: 0.92rem;
  cursor: pointer;
  transition: background 0.18s;
  width: auto;
}
button[type=submit]:hover { background: #0a2d55; }
.form-errors { margin-bottom: 1rem; }
.form-error { color: #c0392b; display: block; margin-top: 0.25rem; font-size: 0.81rem; }

/* ── Formulario cascada artículo → fracción ── */
.cascade-label { display: flex; align-items: center; gap: 0.45rem; font-weight: 600; margin-bottom: 0.35rem; }
.cascade-step { display: inline-flex; align-items: center; justify-content: center; width: 1.4rem; height: 1.4rem; border-radius: 50%; background: var(--primary-dark); color: #fff; font-size: 0.72rem; font-weight: 700; flex-shrink: 0; }
.cascade-select { width: 100%; }
.cascade-hint { font-size: 0.8rem; color: var(--text-muted); margin-top: 0.3rem; }
.periodicidad-badge { display: inline-block; background: #e8f1fb; color: var(--primary-dark); border: 1.5px solid var(--primary); border-radius: 2rem; padding: 0.3rem 0.9rem; font-size: 0.82rem; font-weight: 600; }

/* ── LOGIN ── */
.login-page { display: flex; align-items: center; justify-content: center; min-height: calc(100vh - 280px); padding: 2rem 1rem; }
.login-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: 0 8px 32px rgba(13,59,110,0.15);
  padding: 2.5rem 2rem;
  width: 100%;
  max-width: 420px;
  border-top: 5px solid var(--primary);
}
.login-card h1 { font-family: 'Montserrat', sans-serif; font-size: 1.2rem; color: var(--primary-dark); text-align: center; margin-bottom: 0.2rem; }
/* Eslogan del login */
.login-subtitle { text-align: center; color: var(--slogan); font-size: 0.81rem; margin-bottom: 1.5rem; }
.login-card button[type=submit] { width: 100%; margin-top: 1.25rem; }

/* ── ADMIN TABLE ── */
.table-container { background: var(--white); border-radius: var(--radius); box-shadow: var(--shadow); overflow: hidden; }
.table-wrap { overflow-x: auto; }
.admin-table { width: 100%; border-collapse: collapse; font-size: 0.87rem; }
.admin-table thead th {
  background: var(--primary-dark);
  color: var(--white);
  padding: 0.8rem 1rem;
  text-align: left;
  font-family: 'Montserrat', sans-serif;
  font-weight: 600;
  font-size: 0.76rem;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  white-space: nowrap;
}
.admin-table tbody tr { background: var(--white); transition: background 0.12s; }
.admin-table tbody tr:nth-child(even) { background: #f4f8ff; }
.admin-table tbody tr:hover { background: #edf5ff; }
.admin-table tbody td { padding: 0.78rem 1rem; border-bottom: 1px solid var(--border); vertical-align: middle; }
.admin-table tbody tr:last-child td { border-bottom: none; }
/* Fracciones: filtro y agrupación por artículo */
.fraccion-filter-bar { display: flex; align-items: center; gap: 0.75rem; margin-bottom: 1.25rem; flex-wrap: wrap; }
.filter-label { font-size: 0.85rem; font-weight: 600; color: var(--primary-dark); white-space: nowrap; }
.filter-select { padding: 0.42rem 0.75rem; border: 1.5px solid var(--border); border-radius: var(--radius); font-size: 0.87rem; color: var(--text); background: var(--white); min-width: 220px; cursor: pointer; }
.filter-select:focus { outline: none; border-color: var(--primary); box-shadow: 0 0 0 3px rgba(69,169,255,0.15); }
.table-group-header td { background: #e8f1fb; color: var(--primary-dark); font-family: 'Montserrat', sans-serif; font-weight: 700; font-size: 0.8rem; text-transform: uppercase; letter-spacing: 0.05em; padding: 0.55rem 1rem; border-bottom: 2px solid var(--primary); }
.table-group-header:hover td { background: #ddeaf8 !important; }
.table-subgroup-header td { background: #f4f8ff; color: var(--primary-mid, #1a6bb5); font-family: 'Montserrat', sans-serif; font-weight: 600; font-size: 0.77rem; padding: 0.4rem 1rem 0.4rem 2rem; border-bottom: 1px solid var(--border); border-top: none; }
.table-subgroup-header:hover td { background: #eaf2ff !important; }
.group-count { display: inline-block; background: var(--primary-dark); color: #fff; border-radius: 2rem; padding: 0.05rem 0.55rem; font-size: 0.7rem; font-weight: 700; margin-left: 0.6rem; vertical-align: middle; text-transform: none; letter-spacing: 0; }
.subgroup-count { display: inline-flex; align-items: center; justify-content: center; background: var(--primary); color: #fff; border-radius: 50%; width: 1.25rem; height: 1.25rem; font-size: 0.68rem; font-weight: 700; margin-left: 0.4rem; vertical-align: middle; }
.filter-select--narrow { min-width: 90px; }
.filter-count { margin-left: auto; font-size: 0.8rem; color: var(--text-muted); white-space: nowrap; }
.col-id { color: var(--text-muted); font-size: 0.8rem; width: 2.5rem; }
.col-fecha { font-size: 0.8rem; color: var(--text-muted); white-space: nowrap; }
.col-contenido { max-width: 280px; }
.per-pill { display: inline-block; border-radius: 2rem; padding: 0.18rem 0.65rem; font-size: 0.72rem; font-weight: 700; text-transform: uppercase; letter-spacing: 0.03em; }
.per-pill.per-mensual    { background: #e8f5e9; color: #2e7d32; }
.per-pill.per-trimestral { background: #e3f2fd; color: #1565c0; }
.per-pill.per-semestral  { background: #fff3e0; color: #e65100; }
.per-pill.per-anual      { background: #f3e5f5; color: #6a1b9a; }
.fraccion-list { list-style: none; padding: 0; margin: 0; display: flex; flex-direction: column; gap: 0.2rem; }
.fraccion-list li { font-size: 0.83rem; color: var(--text); padding: 0.15rem 0; border-bottom: 1px dashed var(--border); }
.fraccion-list li:last-child { border-bottom: none; }
.action-group { display: flex; align-items: center; gap: 0.5rem; }
.inline-form { display: inline-flex; }
.inline-form button {
  background: none;
  border: none;
  padding: 0.32rem 0.6rem;
  cursor: pointer;
  color: #c0392b;
  font-size: 0.77rem;
  font-weight: 600;
  font-family: 'Montserrat', sans-serif;
  border-radius: 5px;
  transition: background 0.15s;
  width: auto;
  margin-top: 0;
}
.inline-form button:hover { background: #fce4e4; }

/* ── STAT CARDS ── */
.stats-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 1rem; margin-bottom: 2rem; }
.stat-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.4rem;
  display: flex;
  align-items: center;
  gap: 1rem;
  border-top: 4px solid var(--primary);
}
.stat-icon { font-size: 1.8rem; width: 50px; height: 50px; display: flex; align-items: center; justify-content: center; background: #e8f4ff; border-radius: 10px; flex-shrink: 0; }
.stat-info p {
  font-size: 0.74rem;
  color: var(--slogan);
  font-family: 'Montserrat', sans-serif;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  margin-bottom: 0.1rem;
}
.stat-info strong { font-size: 1.9rem; font-family: 'Montserrat', sans-serif; font-weight: 700; color: var(--primary-dark); line-height: 1; }

/* ── QUICK LINKS ── */
.quick-links { display: grid; grid-template-columns: repeat(auto-fill, minmax(175px, 1fr)); gap: 1rem; margin-bottom: 2rem; }
.quick-link-card {
  background: var(--white);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 1.1rem 1.2rem;
  text-decoration: none;
  color: var(--primary-dark);
  font-family: 'Montserrat', sans-serif;
  font-weight: 600;
  font-size: 0.84rem;
  border-left: 4px solid var(--primary);
  transition: transform 0.18s, box-shadow 0.18s;
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.quick-link-card:hover { transform: translateY(-2px); box-shadow: 0 6px 18px rgba(69,169,255,0.20); color: var(--primary-mid); }

/* ── EMPTY STATE ── */
.empty-state { text-align: center; padding: 3rem 1rem; color: var(--slogan); }

/* ── FOOTER ── */
.site-footer {
  background: var(--primary-dark);
  color: rgba(255,255,255,0.76);
  padding: 2.5rem 0 1.25rem;
  margin-top: 3rem;
}
/* Identidad institucional: escudo | texto | eslogan */
.footer-identity {
  display: flex;
  align-items: center;
  gap: 2rem;
  padding-bottom: 1.75rem;
  border-bottom: 1px solid rgba(69,169,255,0.20);
  margin-bottom: 1.5rem;
}
.footer-armas {
  height: 90px;
  width: auto;
  flex-shrink: 0;
  filter: drop-shadow(0 2px 8px rgba(0,0,0,0.40));
}
.footer-brand { flex: 1; }
.footer-brand h3 {
  font-family: 'Montserrat', sans-serif;
  font-size: 1rem;
  font-weight: 700;
  color: var(--white);
  margin-bottom: 0.35rem;
}
.footer-brand p { font-size: 0.79rem; line-height: 1.75; color: var(--slogan); }
.footer-eslogan {
  height: 64px;
  width: auto;
  flex-shrink: 0;
  opacity: 0.88;
  filter: brightness(1.15) drop-shadow(0 1px 4px rgba(0,0,0,0.30));
}
/* Links row */
.footer-links-row {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1.5rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid rgba(69,169,255,0.12);
  margin-bottom: 1rem;
}
.footer-links h4 {
  font-family: 'Montserrat', sans-serif;
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--primary);
  text-transform: uppercase;
  letter-spacing: 0.06em;
  margin-bottom: 0.6rem;
}
.footer-links ul { list-style: none; }
.footer-links li { margin-bottom: 0.32rem; }
.footer-links a { color: rgba(255,255,255,0.66); font-size: 0.79rem; text-decoration: none; }
.footer-links a:hover { color: var(--primary); }
.footer-bottom { text-align: center; font-size: 0.75rem; color: var(--slogan); }

/* ── GRUPO FILTER CARDS ── */
.grupo-filter { margin: 1.5rem 0 2rem; }
.grupo-filter-label {
  font-family: 'Montserrat', sans-serif;
  font-size: 0.72rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.08em;
  color: var(--slogan);
  margin-bottom: 0.85rem;
}
.grupo-cards {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(140px, 1fr));
  gap: 0.85rem;
}
.grupo-card {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 0.55rem;
  padding: 1.1rem 0.75rem;
  background: var(--white);
  border: 2px solid var(--border);
  border-radius: var(--radius);
  text-decoration: none;
  color: var(--primary-dark);
  font-family: 'Montserrat', sans-serif;
  font-weight: 600;
  font-size: 0.78rem;
  text-align: center;
  line-height: 1.3;
  transition: transform 0.18s, box-shadow 0.18s, border-color 0.18s, background 0.18s;
  box-shadow: var(--shadow);
  cursor: pointer;
}
.grupo-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 8px 24px rgba(13,59,110,0.16);
  border-color: var(--primary);
}
.grupo-card .gc-icon {
  font-size: 2rem;
  line-height: 1;
  display: block;
}
.grupo-card .gc-name { display: block; }
.grupo-card .gc-count {
  display: block;
  font-size: 0.72rem;
  font-weight: 500;
  color: var(--slogan);
  margin-top: 0.1rem;
}
/* "Todos" button — filled dark */
.grupo-card.gc-todos {
  background: var(--primary-dark);
  border-color: var(--primary-dark);
  color: var(--white);
}
.grupo-card.gc-todos:hover {
  background: var(--primary-mid);
  border-color: var(--primary-mid);
}
/* Accent top-border per group (colored stripe) */
.grupo-card.gc-1 { border-top: 4px solid #45a9ff; }
.grupo-card.gc-2 { border-top: 4px solid #4caf89; }
.grupo-card.gc-3 { border-top: 4px solid #f0b429; }
.grupo-card.gc-4 { border-top: 4px solid #9c5dcd; }
.grupo-card.gc-5 { border-top: 4px solid #e87a5d; }
.grupo-card.gc-6 { border-top: 4px solid #2bbfdb; }
.grupo-card.gc-7 { border-top: 4px solid #6dbf5d; }
.grupo-card.gc-8 { border-top: 4px solid #f06292; }

/* ── RESPONSIVE ── */
@media (max-width: 768px) {
  .hero h1 { font-size: 1.4rem; }
  .top-bar .container { flex-direction: column; align-items: center; text-align: center; gap: 0.25rem; }
  .page-header { flex-direction: column; align-items: flex-start; }
  .stats-grid { grid-template-columns: 1fr 1fr; }
  .footer-identity { flex-direction: column; align-items: center; text-align: center; gap: 1.25rem; }
  .footer-eslogan { height: 48px; }
  .footer-armas { height: 70px; }
  /* En móvil el fondo fixed se ve mejor con scroll */
  body { background-attachment: scroll; }
  .nav-logo img { height: 36px; }
  .nav-logo { padding-right: 0.5rem; margin-right: 0; }
}
@media (max-width: 480px) {
  .stats-grid { grid-template-columns: 1fr; }
  .card-grid { grid-template-columns: 1fr; }
  .grupo-cards { grid-template-columns: repeat(2, 1fr); }
  .detail { padding: 1.25rem; }
  .form-card { padding: 1.25rem; }
  .login-card { padding: 1.75rem 1.25rem; }
}
