body {
    font-family: Arial, sans-serif;
    background-color: #f4f8fb;
    margin: 0;
    padding: 0;
}

header {
    background-color: #003366;
    color: #FFD700;
    padding: 15px;
    text-align: center;
}

h1, h2 {
    margin: 10px 0;
}

main {
    padding: 20px;
}

/* ADR-054: las tablas se unifican al final de este archivo (las reglas
   genéricas viejas de table/th/td se retiraron para no pelear con Bootstrap). */

.btn {
    display: inline-block;
    padding: 8px 12px;
    margin: 5px;
    text-decoration: none;
    color: white;
    border-radius: 5px;
}

.btn-primary {
    background-color: #0055aa;
}

.btn-secondary {
    background-color: #FFD700;
    color: black;
}

.btn-warning {
    background-color: #ff9900;
}

.btn-info {
    background-color: #17a2b8;
}

.btn-sm {
    padding: 5px 8px;
    font-size: 0.8em;
}

.filter-form input, .filter-form select {
    padding: 8px;
    margin-right: 5px;
}

.btn-container {
    margin: 10px 0;
}

.filtro-alto {
    height: 38px; /* altura estándar de los botones bootstrap */
}

/* Asegura misma altura y alineación entre filtros y botones */
.filtro-uniforme {
    height: 38px !important;      /* misma altura que btn Bootstrap */
    line-height: 1.5 !important;  /* alineación interna */
    padding: 0.375rem 0.75rem;    /* padding estándar */
    min-width: 95px;              /* todos tienen al menos este ancho */
}

/* =========================
   LOGIN
   ========================= */

.login-container {
    max-width: 380px;
    margin: 80px auto;
    background-color: white;
    padding: 40px;
    border-radius: 10px;
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.15);
    text-align: center;
}

.login-container h1 {
    color: #003366;
    margin-bottom: 10px;
}

.login-container .subtitle {
    color: #555;
    margin-bottom: 30px;
    font-weight: normal;
}

.login-container label {
    display: block;
    text-align: left;
    font-weight: bold;
    margin-bottom: 5px;
    color: #003366;
}

.login-container input {
    width: 100%;
    padding: 10px;
    margin-bottom: 20px;
    border-radius: 5px;
    border: 1px solid #ccc;
    font-size: 14px;
}

.login-container input:focus {
    outline: none;
    border-color: #0055aa;
}

.btn-login {
    width: 100%;
    padding: 12px;
    background-color: #0055aa;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 16px;
    cursor: pointer;
}

.btn-login:hover {
    background-color: #003366;
}

/* =========================
   FLASH MESSAGES
   ========================= */

.flash {
    padding: 10px;
    margin-bottom: 20px;
    border-radius: 5px;
    font-size: 14px;
    text-align: center;
}

.flash-danger {
    background-color: #f8d7da;
    color: #842029;
}

.flash-success {
    background-color: #d1e7dd;
    color: #0f5132;
}

/* ====== Navbar Gimnasio Freire ====== */
.gf-navbar{
    background-color: #003366 !important; /* azul institucional */
    padding-top: 10px;
    padding-bottom: 10px;
}

/* ====== Navbar layout (3 zonas: izq / centro / der) ====== */
.gf-nav-grid{
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    width: 100%;
}

.gf-nav-center{
    justify-self: center;
    font-weight: 700;
    white-space: nowrap;
    padding: 0.25rem 0.75rem;
    border-radius: 10px;
}

.gf-nav-center:hover{
    background: rgba(255,255,255,0.12);
}

/* Botón visual para "Inicio" en navbar */
.gf-nav-btn{
    border: 1px solid rgba(255,255,255,0.35);
    padding: 6px 14px !important;
    border-radius: 12px;
    line-height: 1.2;
}

.gf-nav-btn:hover{
    background: rgba(255,255,255,0.12);
}

/* ====== Dashboard ====== */
.dashboard-wrap{
    margin-top: 10px;
}

.dash-tile{
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    text-align: center !important;

    text-decoration: none;
    background: #ffffff;
    border: 2px solid #00336633;
    border-radius: 16px;
    padding: 22px 16px;
    font-weight: 700;
    font-size: 1.15rem;
    color: #003366;
    min-height: 70px;
    transition: transform .1s ease, box-shadow .1s ease, border-color .1s ease;
}

.dash-tile:hover{
    transform: translateY(-2px);
    box-shadow: 0 12px 22px rgba(0,0,0,0.12);
    border-color: #003366;
    color: #003366;
}

/* ✅ Estado deshabilitado para tiles (cuando se usen con <span>) */
span.dash-tile{
    cursor: not-allowed;
    user-select: none;
}

span.dash-tile:hover{
    transform: none !important;
    box-shadow: none !important;
    border-color: #00336633 !important;
}

/* Centro escudo */
.escudo-box{
    background: #ffffff;
    border-radius: 18px;
    padding: 26px 18px;
    border: 2px dashed #00336633;
}

.escudo-img{
    max-width: 240px;
    width: 70%;
    height: auto;
}

.escudo-fallback{
    display: none;
}

.escudo-placeholder{
    display: inline-block;
    padding: 18px 20px;
    border-radius: 14px;
    background: #f4f8fb;
    border: 2px dashed #00336633;
    color: #003366;
    font-weight: 700;
}

/* (Opcional: si algún día vuelves a usar Inicio como botón en el cuerpo) */
.inicio-link{
    display: inline-block;
    padding: 10px 26px;
    border-radius: 30px;
    background-color: #003366;
    color: #ffffff;
    font-weight: 700;
    font-size: 1.05rem;
    text-decoration: none;
    transition: background-color .15s ease, transform .1s ease;
}

.inicio-link:hover{
    background-color: #0055aa;
    color: #ffffff;
    transform: translateY(-1px);
}
/* =========================
   ACCIONES TABLA – TEXTO SIEMPRE NEGRO
   ========================= */

.acciones-texto-negro .btn {
    color: #000 !important;
}

.acciones-texto-negro .btn:hover,
.acciones-texto-negro .btn:focus,
.acciones-texto-negro .btn:active {
    color: #000 !important;
}

.acciones-texto-negro .btn:disabled {
    color: #000 !important;
    opacity: 0.65; /* mantiene apariencia de deshabilitado */
}

/* ============ Marco del área privada: menú lateral (tarea 2) ============ */
.gf-layout { min-height: calc(100vh - 90px); }

.gf-sidebar {
  width: 240px;
  flex: 0 0 240px;
  background: #fff;
  border-right: 1px solid #e3e6ea;
}

.gf-menu-item {
  display: flex;
  align-items: center;
  gap: .55rem;
  padding: .55rem .8rem;
  border-radius: .5rem;
  color: #333;
  text-decoration: none;
  font-size: .95rem;
}
.gf-menu-item:hover { background: #eef2f7; color: #111; }
.gf-menu-item.active { background: #0d2c54; color: #fff; }
.gf-menu-item.disabled { color: #9aa3ad; cursor: default; }
.gf-menu-icon { width: 1.4rem; text-align: center; }

/* ADR-116: categorías desplegables del menú administrativo */
.gf-menu-grupo {
  display: flex;
  align-items: center;
  width: 100%;
  gap: .4rem;
  padding: .5rem .8rem .3rem;
  margin-top: .35rem;
  border: 0;
  background: none;
  text-align: left;
  text-transform: uppercase;
  font-size: .78rem;
  font-weight: 600;
  letter-spacing: .02em;
  color: #6c757d;
  border-radius: .5rem;
}
.gf-menu-grupo:hover { color: #0d2c54; background: #eef2f7; }
.gf-menu-flecha { transition: transform .2s ease; font-size: .85rem; }
.gf-menu-grupo.collapsed .gf-menu-flecha { transform: rotate(-90deg); }
.gf-menu-sub {
  flex-direction: column;
  gap: .25rem;
  padding-left: .35rem;
}
.gf-menu-sub.show { display: flex; }

.gf-main { min-width: 0; padding-top: .25rem; padding-bottom: 2rem; }

.gf-nav-logo {
  height: 36px;
  width: 36px;
  object-fit: cover;
  border-radius: 50%;
  background: #fff;
}

.gf-offcanvas { max-width: 280px; }

/* Accesos del panel que aún no existen */
.dash-tile-off { opacity: .55; cursor: default; }


/* ============ Acciones de tablas: tres columnas planas y homogéneas ============ */
.gf-acciones {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: .25rem;
  align-items: stretch;
}
.gf-acciones form { display: contents; }
.gf-accion {
  border: 0;
  background: transparent;
  color: #212529;
  font-size: .85rem;
  padding: .35rem .4rem;
  border-radius: .4rem;
  text-align: center;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  line-height: 1.2;
}
.gf-accion:hover { background: #eef2f7; color: #0d2c54; }

/* ================================================================
   ADR-033: letra NEGRA y sin negrilla en el cuerpo de los cuadros
   (tablas y acciones); los encabezados de tabla conservan su estilo.
   ================================================================ */
.table tbody td {
  color: #000;
  font-weight: 400;
}
.table tbody td b,
.table tbody td strong {
  font-weight: 400;
}
.table tbody td a,
.table tbody td .btn,
.gf-acciones .gf-accion,
.gf-acciones a,
.gf-acciones button {
  color: #000 !important;
}
/* Las insignias conservan su contraste propio */
.table tbody td .badge { font-weight: 600; }

/* ADR-036: todos los botones con letra negra (la barra superior conserva blanco) */
.btn { color: #000 !important; }
.gf-navbar .btn, .gf-navbar .nav-link { color: #fff !important; }

/* ADR-039: campos con problema en rojo suave, todos a la vez */
.gf-campo-invalido {
  background-color: #fdeaea !important;
  border-color: #e08a8a !important;
}

/* ADR-050: fila del momento de matrícula vigente, resaltada en azul muy suave */
.gf-fila-vigente td { background-color: #eaf2fb; }

/* ================================================================
   ADR-054: ESTILO UNIFICADO DE TABLAS Y PÁGINAS
   Una sola apariencia en todo el sistema: encabezado de tabla azul
   institucional, cuerpo con rayado suave, tarjetas iguales.
   ================================================================ */

/* Encabezado de TODA tabla: azul institucional con letra blanca
   (da igual si la plantilla trae table-light: aquí se unifica). */
.table thead th {
  background-color: #0d2c54 !important;
  color: #fff !important;
  font-weight: 600;
  border-color: #0d2c54 !important;
  vertical-align: middle;
}

/* Cuerpo: bordes tenues, rayado suave y resaltado al pasar el mouse */
.table { --bs-table-hover-bg: #eef4fb; }
.table tbody td { border-color: #eef1f4; }
.table > tbody > tr:nth-child(even) > td { background-color: #f8fafc; }

/* La fila del momento vigente (ADR-050) gana al rayado */
.gf-fila-vigente td { background-color: #eaf2fb !important; }

/* Tarjetas uniformes: borde tenue, esquinas redondeadas y
   encabezado blanco con la línea azul institucional. */
.card {
  border: 1px solid #e3e6ea;
  border-radius: .75rem;
}
.card > .card-header {
  background-color: #fff;
  border-bottom: 2px solid #0d2c54;
  color: #0d2c54;
  font-weight: 600;
  border-radius: .75rem .75rem 0 0 !important;
}

/* Tabla pegada al borde de su tarjeta (sin doble marco) */
.card .table { margin-bottom: 0; }
.card .table-responsive { border-radius: 0 0 .75rem .75rem; }

/* Encabezado de sección (macro _ui.html) */
.gf-encabezado h2, h2, h3 { color: #0d2c54; }
