:root {
    --navy: #071b34;
    --blue: #000000;
    --green: #000000;
    --orange: #000000;
    --bg: #f8f8f8;
    --text: #172033;
    --muted: #667085;
    --card: #fff;
    --border: #e7ebf2
}

* {
    box-sizing: border-box
}

body {
    margin: 0;
    font-family: Inter, Arial, sans-serif;
    background: var(--bg);
    color: var(--text)
}

button,
input,
select,
textarea {
    font: inherit
}

button {
    cursor: pointer
}

.app {
    display: flex;
    min-height: 100vh
}

.side {
    width: 260px;
    background: linear-gradient(180deg, #061a31, #092544);
    color: #fff;
    padding: 22px 18px;
    position: fixed;
    inset: 0 auto 0 0;
    overflow: auto
}

.brand {
    background: #fff;
    border-radius: 12px;
    padding: 0 0 0 8px;
    margin-bottom: 24px;
    text-align: left;
}

.brand img {
    height: 100px;
    width: auto;
    object-fit: contain;
    background: transparent !important;
    box-shadow: none !important;
}

.navtitle {
    font-size: 12px;
    color: #9db0c9;
    margin: 22px 6px 8px;
    text-transform: uppercase;
    font-weight: 700;
    letter-spacing: .06em
}

.nav button {
    width: 100%;
    border: 0;
    background: transparent;
    color: #fff;
    text-align: left;
    padding: 12px 12px;
    border-radius: 9px;
    margin: 2px 0
}

.nav button:hover,
.nav button.active {
    background: #1268e8
}

.contact {
    margin-top: 25px;
    padding: 15px;
    border: 1px solid #36506d;
    border-radius: 12px;
    background: #102e4d;
    font-size: 12px;
    line-height: 1.6
}

.contact b {
    font-size: 15px
}

.main {
    margin-left: 260px;
    width: calc(100% - 260px)
}

.top {
    height: 76px;
    background: #fff;
    border-bottom: 1px solid var(--border);
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 30px
}

.user {
    display: flex;
    gap: 10px;
    align-items: center
}

.avatar {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    background: #3b5479;
    color: #fff;
    display: grid;
    place-items: center;
    font-weight: 800
}

.content {
    padding: 30px;
    max-width: 1500px;
    margin: auto
}

.welcome {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 24px
}

.welcome h1 {
    font-size: 38px;
    margin: 0 0 8px
}

.welcome h1 span {
    color: var(--blue)
}

.welcome p {
    color: var(--muted);
    font-size: 17px;
    margin: 0
}


.cards {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 20px
}

.card {
    background: var(--card);
    border: 1px solid var(--border);
    border-radius: 16px;
    padding: 24px;
    box-shadow: 0 4px 18px rgba(20, 40, 80, .05)
}

.service {
    min-height: 225px
}

.service h3 {
    margin: 0 0 10px
}

.service p {
    color: var(--muted);
    min-height: 45px;
    line-height: 1.5
}

.icon {
    width: 56px;
    height: 56px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    font-size: 28px;
    margin-bottom: 15px
}

.blue {
    color: #0761df
}

.blue .icon {
    background: #eaf2ff
}

.green {
    color: #0761df
}

.green .icon {
    background: #eaf2ff
        /* Cambiado al mismo azul claro */
}

.orange {
    color: #0761df
}

.orange .icon {
    background: #eaf2ff
        /* Cambiado al mismo azul claro */
}

.primary {
    background: var(--blue);
    color: #fff;
    border: 0;
    padding: 12px 18px;
    border-radius: 8px;
    font-weight: 700
}

.greenbtn {
    background: var(--green)
}

.orangebtn {
    background: var(--orange)
}

.grid2 {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 20px;
    margin-top: 20px
}

.sectionhead {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 15px
}

.sectionhead h2 {
    font-size: 18px;
    margin: 0
}

.link {
    color: var(--blue);
    background: none;
    border: 0;
    font-weight: 700
}

table {
    width: 100%;
    border-collapse: collapse;
    font-size: 13px
}

th,
td {
    padding: 13px 8px;
    border-bottom: 1px solid var(--border);
    text-align: left
}

th {
    color: #667085;
    font-size: 12px
}

.pill {
    padding: 5px 8px;
    border-radius: 6px;
    font-size: 11px;
    font-weight: 800;
    display: inline-block
}

.p-yellow {
    background: #fff1d6;
    color: #ed5b07
}

.p-blue {
    background: #e7f0ff;
    color: #1268e8
}

.p-green {
    background: #e7f8ed;
    color: #07df24
}

.p-red {
    background: #ffe9e7;
    color: #c52f24
}

.metrics {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px
}

.metric {
    padding: 15px;
    border-radius: 10px;
    text-align: center
}

.metric strong {
    font-size: 28px;
    display: block
}

.metric span {
    font-size: 12px;
    color: var(--muted)
}

.metric.bluebg {
    background: #eef5ff
}

.metric.greenbg {
    background: #eefaf2
}

.metric.orangebg {
    background: #fff3ea
}

.bar {
    height: 10px;
    background: #e6eaf0;
    border-radius: 10px;
    overflow: hidden
}

.bar i {
    display: block;
    height: 100%;
    background: #12a84a;
    width: 96.8%
}

.view {
    display: none
}

.view.active {
    display: block
}

.formcard {
    max-width: 900px
}

.formgrid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px
}

.field {
    display: flex;
    flex-direction: column;
    gap: 7px
}

.field.full {
    grid-column: 1/-1
}

.field label {
    font-size: 13px;
    font-weight: 700
}

.field input,
.field select,
.field textarea {
    border: 1px solid #d8dee8;
    border-radius: 8px;
    padding: 11px;
    background: #fff
}

.field textarea {
    min-height: 100px;
    resize: vertical
}

.actions {
    margin-top: 20px;
    display: flex;
    gap: 10px
}

.secondary {
    border: 1px solid #d8dee8;
    background: #fff;
    padding: 11px 18px;
    border-radius: 8px
}

.notice {
    padding: 12px 14px;
    border-radius: 9px;
    background: #eef5ff;
    color: #165fc5;
    margin-bottom: 18px;
    font-size: 13px
}

.login {
    min-height: 100vh;
    display: grid;
    place-items: center;
    background: linear-gradient(135deg, #061a31, #1268e8)
}

.loginbox {
    width: min(420px, 92vw);
    background: #fff;
    border-radius: 18px;
    padding: 32px;
    box-shadow: 0 20px 60px #0004
}

.loginbox img {
    width: 100%;
    height: 90px;
    object-fit: contain
}

.loginbox h1 {
    margin: 10px 0 4px
}

.loginbox p {
    color: var(--muted)
}

.loginbox .field {
    margin-top: 14px
}

.loginbtn {
    width: 100%;
    margin-top: 18px;
    padding: 13px;
    border: 0;
    border-radius: 9px;
    background: var(--blue);
    color: #fff;
    font-weight: 800
}

.demo {
    font-size: 12px;
    color: #667085;
    margin-top: 12px
}

.modal {
    position: fixed;
    inset: 0;
    background: #0007;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px
}

.modal.open {
    display: flex
}

.modalbox {
    background: #fff;
    border-radius: 16px;
    max-width: 800px;
    width: 100%;
    max-height: 90vh;
    overflow: auto;
    padding: 24px
}

.close {
    float: right;
    border: 0;
    background: #eee;
    border-radius: 50%;
    width: 32px;
    height: 32px
}

footer {
    padding: 25px;
    text-align: center;
    color: #8993a5;
    font-size: 12px
}

@media(max-width:1000px) {
    .side {
        width: 220px
    }

    .main {
        margin-left: 220px;
        width: calc(100% - 220px)
    }

    .cards {
        grid-template-columns: 1fr
    }

    .grid2 {
        grid-template-columns: 1fr
    }
}

@media(max-width:720px) {
    .side {
        position: relative;
        width: 100%;
        height: auto
    }

    .app {
        display: block
    }

    .main {
        margin: 0;
        width: 100%
    }

    .content {
        padding: 18px
    }

    .top {
        padding: 0 18px
    }

    .welcome {
        display: block
    }

    .s4l {
        margin-top: 15px
    }

    .grid2,
    .formgrid {
        grid-template-columns: 1fr
    }

    .field.full {
        grid-column: auto
    }

    .cards {
        grid-template-columns: 1fr
    }

    .side .nav {
        display: grid;
        grid-template-columns: 1fr 1fr
    }

    .contact {
        display: none
    }
}

.dangerbtn {
    background: #ffe9e7;
    color: #c52f24;
    border: 1px solid #f2b8b5;
    padding: 6px 10px;
    border-radius: 6px;
    font-size: 12px;
    transition: background 0.2s;
}

.dangerbtn:hover {
    background: #f82b2b;
    color: #fff;
}