:root {
    --b:#0e374e;
    --g:#f5f7fb;
}
*{
    box-sizing:border-box
}
body{
    font-family:system-ui,-apple-system,Segoe UI,Roboto,Ubuntu;
    background:var(--g);
    color:#222;
    margin:0
}
.contenedor{
    max-width:1100px;
    margin:auto;
    padding:20px
}
.card{
    background:#fff;
    border:1px solid #e8ebf1;
    border-radius:14px;
    padding:16px;
    box-shadow:0 2px 10px rgba(0,0,0,.03)
}
.h{
    display:flex;
    align-items:center;
    justify-content:space-between;
    gap:10px
}
.h h1{
    font-size:20px;
    margin:0
}
.btn{
    border:0;
    padding:10px 14px;
    border-radius:10px;
    cursor:pointer
}
.btn-prim{
    background:var(--b);
    color:#fff
}
.btn-sec{
    background:#eef2f7
}
.grid{
    display:grid;
    gap:14px
}
.grid-3{
    grid-template-columns:repeat(auto-fit,minmax(260px,1fr))
}
.table{
    width:100%;
    border-collapse:collapse;
    font-size:14px
}
.table th,.table td{
    padding:8px 10px;
    border-bottom:1px solid #edf0f6
}
.badge{
    display:inline-block;
    padding:3px 8px;
    border-radius:10px;
    background:#eef2f7
}
.input,select,textarea{
    width:100%;
    padding:10px 12px;
    border:1px solid #e0e6ef;
    border-radius:10px;
    background:#fff
}
.row{
    display:flex;
    gap:10px;
    align-items:center
}
.muted{
    color:#667085;
    font-size:12px
}
.kpi{
    font-weight:600;
    font-size:18px
}
.overlay{
    position:fixed;
    inset:0;
    background:rgba(255,255,255,.7);
    display:none;
    align-items:center;
    justify-content:center;
    z-index:9999
}
.spinner{
    width:44px;
    height:44px;
    border-radius:50%;
    border:4px solid #d0d7e2;
    border-top-color:var(--b);
    animation:spin 1s linear infinite
}
@keyframes spin {
    to{
        transform:rotate(360deg)
    }
}


/* Toast minimalista */
.toast{
    position:fixed;
    right:16px;
    top:16px;
    z-index:10000;
    background:#111;
    color:#fff;
    padding:10px 14px;
    border-radius:10px;
    box-shadow:0 8px 24px rgba(0,0,0,.18);
    opacity:0;
    transform:translateY(-10px);
    transition:.25s ease;
    pointer-events:none;
    font-size:14px;
}
.toast.show{
    opacity:1;
    transform:translateY(0)
}

/* Alarma visual (parpadeo) */
.flash{
    animation:flashBorder .8s linear infinite
}
@keyframes flashBorder {
    0% {
        box-shadow:0 0 0 0 rgba(255,0,0,.0), 0 0 0 2px rgba(255,0,0,.0)
    }
    50%{
        box-shadow:0 0 0 6px rgba(255,0,0,.20), 0 0 0 2px rgba(255,0,0,.35)
    }
    100%{
        box-shadow:0 0 0 0 rgba(255,0,0,.0), 0 0 0 2px rgba(255,0,0,.0)
    }
}
/* Modal */
.modal{
    position:fixed;
    inset:0;
    background:rgba(0,0,0,.35);
    display:none;
    align-items:center;
    justify-content:center;
    z-index:10001
}
.modal.show{
    display:flex
}
.modal-box{
    background:#fff;
    border-radius:14px;
    box-shadow:0 20px 60px rgba(0,0,0,.25);
    width:min(720px,92%);
    max-height:86vh;
    display:flex;
    flex-direction:column
}
.modal-head{
    display:flex;
    align-items:center;
    justify-content:space-between;
    padding:14px 16px;
    border-bottom:1px solid #eef0f4
}
.modal-body{
    padding:16px;
    overflow:auto
}
.progress{
    height:8px;
    background:#eef2f7;
    border-radius:999px;
    overflow:hidden
}
.progress>div{
    height:100%;
    width:0%;
    background:#0e374e;
    transition:width .2s
}









a{
    color:#0e374e;
    text-decoration:none
}
a:hover{
    text-decoration:underline
}
h1,h2,h3{
    line-height:1.2
}




/* Encabezado */
.header {
  background: var(--b);
  color: #fff;
  padding: 10px 20px;
  position: sticky;
  top: 0;
  z-index: 1000;
}
.header-inner {
  max-width: 1100px;
  margin: auto;
  display: flex;
  align-items: center;
  justify-content: space-between;
}
.header .logo img {
  display: block;
}
.header .nav a {
  color: #fff;
  margin-left: 20px;
  text-decoration: none;
  font-size: 14px;
}
.header .nav a:hover {
  text-decoration: underline;
}

/* Pie de página */
.footer {
  background: #f0f2f6;
  padding: 20px;
  margin-top: 40px;
  border-top: 1px solid #e0e4ea;
}
.footer-inner {
  max-width: 1100px;
  margin: auto;
  text-align: center;
  font-size: 14px;
  color: #444;
}
.footer .muted {
  font-size: 12px;
  color: #777;
}
