/* ===== Variables base ===== */
:root {
    --nk-bg: #f7f9fc;
    --nk-bg-grad-start: #f5f9ff;
    --nk-bg-grad-end: #eef2f7;
    --nk-primary: #0d6efd;
    --nk-dark: #1b1f24;
}

/* Soporte dark mode */
@media (prefers-color-scheme: dark) {
    :root {
        --nk-bg: #0e1116;
        --nk-bg-grad-start: #0f1420;
        --nk-bg-grad-end: #0b0f19;
        --nk-dark: #eaeef7;
    }

    .navbar,
    .bg-white {
        background-color: #121722 !important;
    }

    .navbar .nav-link,
    .nk-footer .nk-link {
        color: #cbd5e1 !important;
    }

    .nk-card,
    .nk-card-blur {
        background: #121722 !important;
    }

    .card {
        border-color: rgba(255, 255, 255, .06) !important;
    }

    .table {
        color: #cbd5e1;
    }
}

/* ===== Global ===== */
body.nk-bg {
    background: linear-gradient(180deg, var(--nk-bg-grad-start), var(--nk-bg-grad-end));
}

.nk-blur {
    backdrop-filter: saturate(1.2) blur(6px);
}

.nk-logo {
    height: 34px;
    object-fit: contain;
}

.nk-logo-sm {
    height: 24px;
}

.nk-brand {
    letter-spacing: .2px;
}

.nk-header .nav-link {
    font-weight: 500;
}

.nk-link {
    text-decoration: none;
}

.nk-link:hover {
    text-decoration: underline;
}

.nk-shadow-sm {
    box-shadow: 0 10px 30px rgba(0, 0, 0, .06);
}

.nk-card {
    border: 1px solid rgba(0, 0, 0, .06);
    border-radius: 16px;
    overflow: hidden;
    transition: transform .2s ease, box-shadow .2s ease;
}

.nk-card:hover {
    transform: translateY(-3px);
    box-shadow: 0 12px 36px rgba(0, 0, 0, .08);
}

.nk-card-blur {
    border-radius: 14px;
    background: rgba(255, 255, 255, .7);
    backdrop-filter: blur(8px);
}

.nk-hero {
    position: relative;
}

.nk-mask::before {
    content: "";
    position: absolute;
    inset: 0;
    pointer-events: none;
    background: radial-gradient(600px 200px at 20% -10%, rgba(13, 110, 253, .25), transparent 60%);
}

.nk-hero-ill {
    height: 280px;
    border-radius: 20px;
    background: url('../../assets/img/casa.jpg') center/cover no-repeat;
    box-shadow: inset 0 -100px 120px rgba(0, 0, 0, .15), 0 10px 30px rgba(0, 0, 0, .08);
}

/* ===== Skeletons ===== */
.nk-skeleton .nk-skel-img {
    height: 200px;
    background: linear-gradient(90deg, #eee, #f6f6f6, #eee);
    animation: nkShine 1.4s infinite linear;
}

.nk-skeleton .nk-skel-line {
    height: 12px;
    border-radius: 6px;
    background: linear-gradient(90deg, #eee, #f6f6f6, #eee);
    animation: nkShine 1.4s infinite linear;
}

@keyframes nkShine {
    0% {
        background-position: -200px 0
    }

    100% {
        background-position: 200px 0
    }
}

/* ===== KPIs ===== */
.nk-kpi {
    background: #fff;
    border: 1px solid rgba(0, 0, 0, .06);
    border-radius: 14px;
    padding: 14px 16px;
}

.nk-kpi-label {
    font-size: 12px;
    color: #6b7280;
    text-transform: uppercase;
    letter-spacing: .04em;
}

.nk-kpi-value {
    font-weight: 700;
}

/* ===== Tables ===== */
.nk-table-wrap {
    border-radius: 14px;
    overflow: hidden;
    box-shadow: 0 8px 24px rgba(0, 0, 0, .05);
}

.nk-table thead th {
    background: #f4f7fb;
    font-size: 12px;
    text-transform: uppercase;
    letter-spacing: .04em;
    color: #6b7280;
}

.nk-table tbody tr:hover {
    background: rgba(13, 110, 253, .03);
}

/* ===== Badges ===== */
.badge.text-bg-info {
    background: linear-gradient(135deg, #0dcaf0, #58e0ff);
}

.badge.text-bg-secondary {
    background: linear-gradient(135deg, #6c757d, #9aa3ab);
}