/* =========================
   NAVBAR LINKS
========================= */

#mainNav .nav-link {
    position: relative;
    color: #fff !important;
    opacity: 0.55;
    transition: all 0.25s ease;
}

/* ACTIVO */
#mainNav .nav-link.active {
    opacity: 1;
}

/* HOVER */
#mainNav .nav-link:hover {
    opacity: 1;
}

/* SUBRAYADO */
#mainNav .nav-link::after {
    content: "";
    position: absolute;
    left: 50%;
    bottom: 4px;
    width: 0%;
    height: 2px;
    background: #1cc88a;
    transition: all 0.3s ease;
    transform: translateX(-50%);
    border-radius: 2px;
}

#mainNav .nav-link.active::after {
    width: 60%;
    opacity: 1;
}

#mainNav .nav-link:hover::after {
    width: 40%;
    opacity: 0.6;
}

.brand-wrapper {
    display: flex;
    flex-direction: column;
    line-height: 1.1;
}

.brand-subtitle {
    font-size: 0.72rem;
    font-weight: 400;
    letter-spacing: 0.5px;
    color: rgba(255, 255, 255, 0.78);
    text-transform: none;
    margin-top: 2px;
}

@media (min-width: 992px) {

    #mainNav .navbar-nav > li.nav-item > a.nav-link.active {
        background: transparent !important;
    }

    #mainNav .navbar-brand {
        font-size: 1.75em;
        transition: font-size 0.3s;
    }
}

/* =========================
   NAVBAR BASE
========================= */

#mainNav {
    position: fixed;
    top: 0;
    width: 100%;
    z-index: 999;
    backdrop-filter: blur(12px);
    background: rgba(44, 62, 80, 0.65) !important;
    transition: all 0.3s ease;
    padding: 18px 0;
}

#mainNav.shrink {
    padding: 8px 0;
    background: rgba(44, 62, 80, 0.9) !important;
}

/* =========================
   MOBILE
========================= */

@media (max-width: 991.98px) {

    #mainNav .navbar-collapse {
        background: transparent;
        backdrop-filter: blur(10px);
        border-top: 1px solid rgba(255, 255, 255, 0.08);
        margin-top: 15px;
        margin-left: 10px;
        margin-right: 10px;
        border-radius: 5px;
    }

    #mainNav .nav-link {
        padding: 12px 16px;
        margin: 4px 10px;
        border-radius: 10px;
        opacity: 0.55;
    }

    #mainNav .nav-link:hover {
        opacity: 1;
        background: rgba(255, 255, 255, 0.06);
    }

    #mainNav .nav-link.active {
        opacity: 1;
        font-weight: 600;
        background: rgba(28, 200, 138, 0.18);
        border-left: 4px solid #1cc88a;
        border-right: 4px solid #1cc88a;
        color: #fff !important;
    }

    #mainNav .nav-link::after {
        display: none;
    }
}

/* ======================================================
   LAYOUT FIX (SIN SOLAPAMIENTO)
====================================================== */

/* ======================================================
   BACKGROUND PREMIUM (NUEVO)
====================================================== */

/* ======================================================
   BACKGROUND LIMPIO SIN CORTES
====================================================== */

html,
body {
    margin: 0;
    padding: 0;
    overflow-x: hidden;

    background: linear-gradient(
        180deg,
        #67b7ff 0%,
        #7ad7ff 35%,
        #9be7d8 100%
    );

    background-attachment: fixed;
}

/* FONDO GLOBAL */
body {

    background:

        radial-gradient(
            circle at 15% 20%,
            rgba(255, 255, 255, 0.45),
            transparent 35%
        ),

        radial-gradient(
            circle at 85% 25%,
            rgba(0, 255, 255, 0.20),
            transparent 40%
        ),

        radial-gradient(
            circle at 40% 85%,
            rgba(255, 255, 255, 0.25),
            transparent 45%
        ),

        radial-gradient(
            circle at 75% 75%,
            rgba(147, 197, 253, 0.18),
            transparent 48%
        );

    background-repeat: no-repeat;
    background-size: cover;
    height: 100dvh;
}

/* CAPA SUAVE SUPERPUESTA */
body::after {
    content: "";
    position: fixed;
    inset: 0;
    pointer-events: none;
    z-index: -1;

    background: linear-gradient(
        to bottom,
        rgba(255, 255, 255, 0.03),
        rgba(0, 0, 0, 0.10)
    );
}

/* =========================
   TITULOS
========================= */

.titulo {
    text-align: center;
    color: #fff;
    font-weight: 600;
    margin-bottom: 25px;
}

/* =========================
   PAGE WRAPPER
========================= */

.page-wrapper {
    padding-top: 120px;
    padding-bottom: 40px;
}

@supports (-webkit-touch-callout: none) {

    body {
        min-height: -webkit-fill-available;
    }
}

@media (max-width: 768px) {

    .page-wrapper {
        padding-top: 100px;
    }
}

/* ======================================================
   CARD
====================================================== */

.container {
    max-width: 900px;
}

.card {
    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);

    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 22px;

    box-shadow:
        0 10px 30px rgba(0, 0, 0, 0.18),
        0 2px 10px rgba(255, 255, 255, 0.08) inset;

    padding: 24px;
}

/* ======================================================
   INFO BOX
====================================================== */

.form-info {
    /*background: rgba(255,255,255,0.72);
    border-left: 4px solid #1cc88a;*/

    padding: 14px 16px;
    border-radius: 14px;

    font-size: 13px;
    margin-bottom: 18px;
    line-height: 1.5;

    /*backdrop-filter: blur(8px);*/
}

/* ======================================================
   BLOQUES
====================================================== */

.form-block {
    margin-bottom: 25px;
}

.block-title {
    font-size: 14px;
    font-weight: 600;
    background: #f1f3f5;
    padding: 8px 12px;
    border-radius: 8px;
    margin-bottom: 12px;
    border-left: 4px solid #4e73df;
}

/* ======================================================
   INPUTS + ICONOS
====================================================== */

.input-icon {
    position: relative;
}

.input-icon i {
    position: absolute;
    left: 12px;
    top: 50%;
    transform: translateY(-50%);
    color: #6c757d;
    transition: 0.2s;
}

.input-icon.active i {
    color: #04D9FF;
}

.input-icon input,
.input-icon select,
.input-icon textarea {
    padding-left: 38px;
    border-radius: 10px;
    transition: 0.25s;
}

/* FOCUS */

input:focus,
select:focus,
textarea:focus {
    border-color: #04D9FF !important;
    box-shadow: 0 0 0 0.15rem rgba(28, 200, 138, 0.25) !important;
    transform: scale(1.01);
}

/* ======================================================
   VALIDACIÓN
====================================================== */

.is-invalid {
    border-color: #dc3545 !important;
}

.is-valid {
    border-color: #1cc88a !important;
}

/* ======================================================
   SHAKE ERROR
====================================================== */

@keyframes shake {

    0% {
        transform: translateX(0);
    }

    20% {
        transform: translateX(-6px);
    }

    40% {
        transform: translateX(6px);
    }

    60% {
        transform: translateX(-4px);
    }

    80% {
        transform: translateX(4px);
    }

    100% {
        transform: translateX(0);
    }
}

.shake {
    animation: shake 0.35s;
}

/* ======================================================
   IMÁGENES
====================================================== */

.preview-img {
    width: 90px;
    height: 90px;
    object-fit: cover;
    border-radius: 10px;
}

.img-wrapper {
    position: relative;
    display: inline-block;
    margin: 5px;
}

.remove-btn {
    position: absolute;
    top: -6px;
    right: -6px;
    background: #dc3545;
    color: #fff;
    border: none;
    border-radius: 50%;
    width: 22px;
    height: 22px;
    font-size: 12px;
}

/* =========================
   HONEYPOT
========================= */

.claseimportante {
    display: none;
}

/* =========================
   BOTONES
========================= */

.btn-primary {
    background-color: #1cc88a !important;
    border-color: #1cc88a !important;
}

.btn-primary:hover {
    background-color: #17a673 !important;
    border-color: #17a673 !important;
}

/* =========================
   UTILIDADES
========================= */

.c-white {
    color: rgba(255, 255, 255, 0.92);
}

/* =========================
   BLOCK TITLE CUSTOM
========================= */

.block-title {

    /*border-left: none;
    background: rgba(241, 243, 245 , 0.25);*/

    background: rgba(255, 255, 255, 0.88);
    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);

    border: 1px solid rgba(255, 255, 255, 0.35);
    border-radius: 15px;

    box-shadow:
        0 10px 30px rgba(0, 0, 0, 0.18),
        0 2px 10px rgba(255, 255, 255, 0.08) inset;

    color: inherit;
    font-weight: lighter;
    font-style: italic;
}

/* =========================
   LOADING OVERLAY
========================= */

.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(15, 23, 42, 0.6);
    backdrop-filter: blur(6px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
    transition: opacity 0.3s ease;
}

.loading-overlay.hidden {
    opacity: 0;
    pointer-events: none;
}

.loading-content {
    text-align: center;
    color: #fff;
    font-family: sans-serif;
}

.spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255, 255, 255, 0.2);
    border-top: 4px solid #38bdf8;
    border-radius: 50%;
    animation: spin 0.8s linear infinite;
    margin: 0 auto 10px;
}

@keyframes spin {

    to {
        transform: rotate(360deg);
    }
}

/* =========================
   ENDIDURA
========================= */

.endidura {
    background: rgba(255, 255, 255, 0.10);
    border-radius: 18px;

    box-shadow:
        inset 0 4px 10px rgba(0, 0, 0, 0.18),
        inset 0 -3px 6px rgba(255, 255, 255, 0.55),
        0 1px 2px rgba(255, 255, 255, 0.2);

    border: 1px solid rgba(255, 255, 255, 0.4);
    padding: 20px;
}