:root {
  --azul: #2272b5;
  --azul-oscuro: #0e2a43;
  --verde: #67b346;
  --verde-oscuro: #3e7a26;
  --fondo: #f4f7fa;
  --superficie: #ffffff;
  --borde: #e8eef3;
  --texto: #0e2a43;
  --texto-suave: #5b6b7b;
  --texto-tenue: #8b98a5;
  --radio: 12px;
  --espacio: clamp(1rem, 0.8rem + 1vw, 1.5rem);
}
* { box-sizing: border-box; }
body {
  margin: 0; background: var(--fondo); color: var(--texto);
  font: 16px/1.55 -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}
img { max-width: 100%; }
a { color: var(--azul); }
h1 { font-size: clamp(1.7rem, 1.2rem + 2.5vw, 2.6rem); line-height: 1.15; margin: 0 0 .5rem; }
h2 { font-size: 1.25rem; margin: 0 0 .75rem; }

.cabecera {
  display: flex; justify-content: space-between; align-items: center; gap: 1rem;
  padding: .6rem var(--espacio); background: var(--superficie); border-bottom: 1px solid var(--borde);
}
.cabecera .logo { height: 56px; width: auto; display: block; }
.cabecera nav { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; }
.cabecera nav a { color: var(--texto-suave); text-decoration: none; font-size: .95rem; }
.contenido { max-width: 1080px; margin: 0 auto; padding: var(--espacio); }
.pie { text-align: center; padding: 2rem 1rem; color: var(--texto-tenue); font-size: .85rem; }
.pie .sello { height: 84px; width: auto; }

.boton {
  display: inline-block; border: 0; cursor: pointer; text-decoration: none;
  font-weight: 700; font-size: 1rem; padding: .7rem 1.4rem; border-radius: 10px;
}
.boton-verde { background: var(--verde); color: #fff !important; box-shadow: 0 4px 14px rgba(103,179,70,.35); }
.boton-verde:hover { background: var(--verde-oscuro); }
.boton-azul { background: var(--azul); color: #fff !important; }
.boton-borde { border: 1.5px solid #d3dce4; color: var(--texto) !important; background: transparent; }

.heroe {
  background: linear-gradient(180deg, #f4f9fd 0%, #ffffff 100%);
  border: 1px solid var(--borde); border-radius: var(--radio);
  padding: clamp(1.5rem, 1rem + 3vw, 3rem);
  display: flex; justify-content: space-between; align-items: center; gap: 2rem; flex-wrap: wrap;
}
.heroe .insignia {
  background: #e7f3e2; color: var(--verde-oscuro); font-size: .75rem; font-weight: 700;
  padding: .25rem .8rem; border-radius: 99px; letter-spacing: .5px;
}
.heroe .destacado { color: var(--azul); }
.metricas { display: flex; gap: 1.5rem; margin-top: 1.5rem; flex-wrap: wrap; }
.metricas strong { display: block; color: var(--azul); font-size: 1.3rem; }
.metricas span { color: var(--texto-tenue); font-size: .8rem; }

.tarjetas { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: .8rem; margin: 1rem 0; }
.tarjeta { background: var(--superficie); border: 1px solid var(--borde); border-radius: var(--radio); padding: 1rem; }
.tarjeta .cifra { font-size: 1.5rem; font-weight: 800; }
.tarjeta .rotulo { color: var(--texto-tenue); font-size: .75rem; font-weight: 700; letter-spacing: .5px; text-transform: uppercase; }
.tarjeta-accion { display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, var(--verde), var(--verde-oscuro)); }
.tarjeta-accion a { color: #fff; font-weight: 800; text-decoration: none; font-size: 1.05rem; }

.panel { background: var(--superficie); border: 1px solid var(--borde); border-radius: var(--radio); padding: 1.2rem; margin-bottom: 1rem; }
.tabla-envoltura { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; font-size: .92rem; }
th { text-align: left; color: var(--texto-tenue); font-size: .75rem; text-transform: uppercase; letter-spacing: .5px; }
th, td { padding: .6rem .5rem; border-bottom: 1px solid var(--borde); }

.etiqueta { font-size: .78rem; font-weight: 700; padding: .15rem .7rem; border-radius: 99px; white-space: nowrap; }
.etiqueta-verde { background: #e7f3e2; color: var(--verde-oscuro); }
.etiqueta-azul { background: #dbeafe; color: #1d4ed8; }
.etiqueta-ambar { background: #fef3c7; color: #b45309; }
.etiqueta-gris { background: #eef2f6; color: var(--texto-suave); }

form.formulario { max-width: 460px; }
.campo { margin-bottom: 1rem; }
.campo label { display: block; font-weight: 600; font-size: .9rem; margin-bottom: .3rem; }
.campo input, .campo select {
  width: 100%; padding: .65rem .8rem; border: 1.5px solid #d3dce4; border-radius: 10px;
  font-size: 1rem; background: #fff; color: var(--texto);
}
.campo input:focus, .campo select:focus { outline: 2px solid var(--azul); border-color: var(--azul); }
.error { background: #fdecec; color: #b91c1c; border: 1px solid #f5c2c2; border-radius: 10px; padding: .7rem 1rem; margin-bottom: 1rem; }
.exito { background: #e7f3e2; color: var(--verde-oscuro); border: 1px solid #cde6c2; border-radius: 10px; padding: .7rem 1rem; margin-bottom: 1rem; }
.aviso { background: #fef3c7; color: #b45309; border: 1px solid #fde68a; border-radius: 10px; padding: .7rem 1rem; margin-bottom: 1rem; }

.pasos { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: .8rem; margin: 1.5rem 0; }
.paso { background: var(--superficie); border: 1px solid var(--borde); border-radius: var(--radio); padding: 1rem; }
.paso .numero {
  background: var(--azul); color: #fff; width: 26px; height: 26px; border-radius: 99px;
  display: flex; align-items: center; justify-content: center; font-weight: 800; margin-bottom: .5rem;
}

.admin-distribucion { display: flex; gap: 1rem; align-items: flex-start; }
.admin-menu { flex: 0 0 190px; background: var(--azul-oscuro); border-radius: var(--radio); padding: .8rem 0; }
.admin-menu a { display: block; color: #9fb3c8; text-decoration: none; padding: .55rem 1rem; font-size: .92rem; }
.admin-menu a.activo, .admin-menu a:hover { background: var(--azul); color: #fff; }
.admin-cuerpo { flex: 1; min-width: 0; }
@media (max-width: 760px) {
  .admin-distribucion { flex-direction: column; }
  .admin-menu { width: 100%; flex: none; display: flex; overflow-x: auto; padding: .3rem; }
  .admin-menu a { white-space: nowrap; }
  .cabecera .logo { height: 44px; }
}
