﻿body {
    background: #07111f;
    font-family: "Segoe UI", Arial, sans-serif;
    color: #eaf2ff;
}

.ia-page {
    min-height: 100vh;
    display: flex;
    justify-content: center;
    padding: 60px 20px;
}

.ia-shell {
    width: 100%;
    max-width: 980px;
}

.ia-header {
    display: flex;
    gap: 24px;
    align-items: center;
    margin-bottom: 30px;
}

.ia-label {
    font-size: 12px;
    letter-spacing: 3px;
    color: #73d7ff;
    margin-bottom: 8px;
}

.ia-header h1 {
    margin: 0;
    font-size: 36px;
    font-weight: 600;
}

.ia-header p {
    color: #94a8c4;
    margin-top: 10px;
    font-size: 16px;
}

.ia-progress {
    width: 100%;
    height: 4px;
    background: #14263a;
    border-radius: 10px;
    overflow: hidden;
    margin-top: 28px;
    margin-bottom: 24px;
}

.ia-progress-bar {
    height: 100%;
    width: 20%;
    border-radius: 10px;
    background: linear-gradient( 90deg, #168cff 0%, #61e6f5 100% );
    box-shadow: 0 0 12px rgba(56, 190, 255, .35);
    transition: width .45s ease;
}

.ia-card {
    background: rgba(12, 27, 48, .88);
    border: 1px solid rgba(112, 166, 215, .16);
    border-radius: 22px;
    padding: 34px;
    box-shadow: 0 20px 80px rgba(0, 0, 0, .25);
    backdrop-filter: blur(18px);
}

.ia-question {
    font-size: 21px;
    margin-bottom: 28px;
    color: #ffffff;
}

.ia-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 22px;
}

.field {
    display: flex;
    flex-direction: column;
}

.field-wide {
    grid-column: 1 / -1;
}

.field label {
    color: #9bb1cc;
    font-size: 13px;
    margin-bottom: 8px;
}

.ia-input {
    width: 100%;
    box-sizing: border-box;
    background: #091828;
    color: #edf7ff;
    border: 1px solid #203752;
    border-radius: 12px;
    padding: 13px 14px;
    outline: none;
    transition: .2s;
}

    .ia-input:focus {
        border-color: #37baff;
        box-shadow: 0 0 0 3px rgba(55, 186, 255, .12);
    }

.ia-actions {
    margin-top: 24px;
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.ia-button {
    border: 0;
    border-radius: 12px;
    padding: 14px 26px;
    background: linear-gradient(135deg, #168cff, #38d6ff);
    color: white;
    font-weight: 600;
    cursor: pointer;
}

    .ia-button:hover {
        filter: brightness(1.08);
    }

.ia-message {
    color: #7fe5ae;
}

.ia-orb {
    width: 84px;
    height: 84px;
    border-radius: 50%;
    position: relative;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(74, 180, 255, .06);
    border: 1px solid rgba(109, 208, 255, .25);
    box-shadow: 0 0 30px rgba(42, 164, 255, .12), inset 0 0 30px rgba(42, 164, 255, .08);
    animation: iaFloat 4s ease-in-out infinite;
}

    .ia-orb::before {
        content: "";
        position: absolute;
        inset: 8px;
        border-radius: 50%;
        border: 1px solid rgba(103, 220, 255, .25);
        animation: iaRing 3s linear infinite;
    }

    .ia-orb::after {
        content: "";
        position: absolute;
        inset: -8px;
        border-radius: 50%;
        border: 1px solid rgba(49, 172, 255, .10);
        animation: iaPulse 2.8s ease-in-out infinite;
    }

.ia-orb-core {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: radial-gradient( circle at 35% 30%, #d7fbff 0%, #70e7ff 25%, #168cff 65%, #0759b5 100% );
    box-shadow: 0 0 12px rgba(116, 231, 255, .9), 0 0 26px rgba(30, 151, 255, .75), 0 0 45px rgba(30, 151, 255, .35);
    animation: iaCore 2.2s ease-in-out infinite;
}

.ia-subcard {
    margin-top: 26px;
    padding: 24px;
    border-radius: 16px;
    background: rgba(5, 18, 32, .55);
    border: 1px solid rgba(83, 181, 255, .15);
}

.ia-subtitle {
    margin-bottom: 20px;
    font-size: 15px;
    font-weight: 600;
    color: #70ddff;
}

.ia-help {
    margin-top: 7px;
    font-size: 12px;
    color: #6f87a5;
}

.ia-summary-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 18px;
}

.ia-summary-card {
    padding: 22px;
    border-radius: 16px;
    background: rgba(7, 22, 38, .72);
    border: 1px solid rgba(87, 185, 255, .16);
}

.ia-summary-title {
    color: #69dcff;
    font-weight: 600;
    margin-bottom: 14px;
}

.ia-summary-line {
    margin: 7px 0;
    color: #d8e7f7;
}

.ia-summary-label {
    color: #7f96b1;
}

.ia-review-note {
    margin-top: 24px;
    padding: 16px 18px;
    border-radius: 12px;
    background: rgba(36, 151, 255, .08);
    border: 1px solid rgba(70, 186, 255, .14);
    color: #9fc2df;
}

.ia-doc-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 18px;
}

.ia-doc-card {
    position: relative;
    min-height: 230px;
    padding: 24px;
    border-radius: 18px;
    background: linear-gradient( 145deg, rgba(10, 30, 50, .9), rgba(6, 20, 35, .9) );
    border: 1px solid rgba(88, 190, 255, .14);
    transition: transform .2s ease, border-color .2s ease, box-shadow .2s ease;
    text-decoration-line: none;
    color: black;
}

    .ia-doc-card:hover {
        transform: translateY(-3px);
        border-color: rgba(88, 210, 255, .35);
        box-shadow: 0 18px 40px rgba(0, 0, 0, .20);
    }

.ia-doc-icon {
    width: 42px;
    height: 42px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    background: rgba(47, 177, 255, .12);
    border: 1px solid rgba(79, 202, 255, .22);
    color: #6fe1ff;
    font-weight: 700;
    margin-bottom: 18px;
}

.ia-doc-title {
    color: #ffffff;
    font-size: 17px;
    font-weight: 600;
    margin-bottom: 8px;
}

.ia-doc-description {
    color: #829bb7;
    font-size: 13px;
    line-height: 1.5;
    min-height: 58px;
    margin-bottom: 16px;
}

.ia-file {
    width: 100%;
    color: #a9bfd6;
    font-size: 12px;
}

.ia-doc-status {
    display: inline-block;
    margin-top: 14px;
    font-size: 12px;
    padding: 6px 10px;
    border-radius: 20px;
    background: rgba(255, 255, 255, .05);
    color: #879cb4;
}

.ia-doc-status-ok {
    background: rgba(60, 220, 150, .10);
    color: #72e6ad;
}


/*Detalle*/
.documento-card {
    display: flex;
    align-items: center;
    gap: 16px;
    padding: 18px 20px;
    margin-bottom: 14px;
    border-radius: 16px;
    background: rgba(10, 26, 45, .78);
    border: 1px solid rgba(79, 181, 255, .14);
}

.documento-icono {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 12px;
    background: rgba(52, 184, 255, .10);
    color: #6cddff;
    font-weight: bold;
}

.documento-info {
    flex: 1;
    display: flex;
    flex-direction: column;
}

    .documento-info strong {
        color: #f3f8ff;
        font-size: 15px;
    }

    .documento-info span {
        margin-top: 4px;
        color: #7f97b2;
        font-size: 12px;
    }

.documento-estado {
    padding: 6px 11px;
    border-radius: 20px;
    font-size: 11px;
    font-weight: 600;
    background: rgba(255,255,255,.06);
    color: #9fb2c7;
}

.documento-estado-ok {
    background: rgba(56, 210, 140, .10);
    color: #69e0a7;
}

.documento-estado-pendiente {
    background: rgba(255, 190, 65, .10);
    color: #f3c66b;
}

.documento-estado-error {
    background: rgba(255, 80, 80, .10);
    color: #ff8e8e;
}

.ia-resultado {
    margin-top: 32px;
    padding: 26px;
    background: rgba(8, 25, 43, .82);
    border: 1px solid rgba(72, 181, 255, .18);
    border-radius: 18px;
}

.ia-resultado-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 24px;
}

    .ia-resultado-header h2 {
        margin: 5px 0 5px;
        color: #edf6ff;
    }

    .ia-resultado-header p {
        margin: 0;
        color: #8298ad;
    }

.ia-etiqueta {
    color: #55d9ff;
    font-size: 11px;
    letter-spacing: 3px;
}

.ia-indicador {
    padding: 7px 13px;
    border-radius: 20px;
    background: rgba(50, 220, 150, .10);
    color: #65e4ad;
    font-size: 11px;
}

.ia-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.ia-dato {
    padding: 16px;
    background: rgba(255,255,255,.025);
    border: 1px solid rgba(255,255,255,.055);
    border-radius: 12px;
}

    .ia-dato span {
        display: block;
        margin-bottom: 6px;
        color: #728aa2;
        font-size: 11px;
    }

    .ia-dato strong {
        color: #dfeeff;
        font-size: 14px;
        font-weight: 500;
    }

.ia-dato-ancho {
    grid-column: span 3;
}

.validacion-panel {
    margin-top: 28px;
    padding: 26px;
    border-radius: 18px;
    background: rgba(8, 25, 43, .82);
    border: 1px solid rgba(72, 181, 255, .18);
}

.validacion-header {
    margin-bottom: 24px;
}

.validacion-eyebrow {
    color: #55d9ff;
    font-size: 11px;
    letter-spacing: 3px;
}

.validacion-header h2 {
    margin: 6px 0 5px;
    color: #edf6ff;
}

.validacion-header p {
    margin: 0;
    color: #8298ad;
}

.validacion-bloque {
    padding: 20px;
    margin-top: 16px;
    border-radius: 14px;
    background: rgba(255,255,255,.025);
    border: 1px solid rgba(255,255,255,.055);
}

.validacion-titulo {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 16px;
    color: #edf6ff;
    font-weight: 600;
}

    .validacion-titulo > span:first-of-type {
        flex: 1;
    }

.validacion-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 12px;
}

.validacion-dato {
    padding: 14px;
    border-radius: 12px;
    background: rgba(7, 22, 38, .7);
    border: 1px solid rgba(255,255,255,.05);
}

    .validacion-dato span {
        display: block;
        margin-bottom: 5px;
        color: #728aa2;
        font-size: 11px;
    }

    .validacion-dato strong {
        color: #dfeeff;
        font-size: 14px;
        font-weight: 500;
    }

.validacion-estado {
    padding: 6px 10px;
    border-radius: 18px;
    font-size: 10px;
    font-weight: 600;
}

.validacion-ok {
    background: rgba(48, 210, 145, .10);
    color: #63e1a7;
}

.validacion-alerta {
    background: rgba(255, 183, 70, .12);
    color: #f5c76f;
}

.validacion-grid-dos {
    grid-template-columns: repeat(2, 1fr);
}

.resultado-global {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-bottom: 24px;
    padding: 20px;
    border-radius: 15px;
    background: rgba(255, 183, 70, .045);
    border: 1px solid rgba(255, 183, 70, .14);
}

.resultado-global-icono {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    border-radius: 14px;
    background: rgba(255, 183, 70, .10);
    color: #f5c76f;
    font-size: 20px;
}

.resultado-global-info {
    flex: 1;
}

.resultado-global-etiqueta {
    display: block;
    margin-bottom: 4px;
    color: #728aa2;
    font-size: 10px;
    letter-spacing: 2px;
}

.resultado-global-info strong {
    display: block;
    color: #edf6ff;
    font-size: 17px;
    font-weight: 600;
}

.resultado-global-info p {
    margin: 5px 0 0;
    color: #8298ad;
    font-size: 12px;
}

.resultado-global-estado {
    padding: 7px 12px;
    border-radius: 20px;
    font-size: 10px;
    font-weight: 600;
    white-space: nowrap;
}

.resultado-global-ok {
    background: rgba(48, 210, 145, .10);
    color: #63e1a7;
}

.resultado-global-alerta {
    background: rgba(255, 183, 70, .12);
    color: #f5c76f;
}

.alertas-panel {
    margin-top: 28px;
    padding: 26px;
    border-radius: 18px;
    background: rgba(8, 25, 43, .82);
    border: 1px solid rgba(255, 183, 70, .14);
}

.alertas-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 20px;
}

.alertas-eyebrow {
    color: #f5c76f;
    font-size: 11px;
    letter-spacing: 3px;
}

.alertas-header h2 {
    margin: 6px 0 5px;
    color: #edf6ff;
}

.alertas-header p {
    margin: 0;
    color: #8298ad;
}

.alertas-contador {
    padding: 7px 12px;
    border-radius: 20px;
    background: rgba(255, 183, 70, .11);
    color: #f5c76f;
    font-size: 11px;
    font-weight: 600;
}

.alerta-card {
    display: flex;
    gap: 16px;
    align-items: flex-start;
    padding: 18px;
    margin-top: 12px;
    border-radius: 14px;
}

.alerta-card-pendiente {
    background: rgba(255, 183, 70, .045);
    border: 1px solid rgba(255, 183, 70, .12);
}

.alerta-card-resuelta {
    background: rgba(48, 210, 145, .045);
    border: 1px solid rgba(48, 210, 145, .12);
}

.alerta-icono {
    width: 38px;
    height: 38px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 11px;
    background: rgba(255,255,255,.04);
}

.alerta-contenido {
    flex: 1;
}

.alerta-titulo {
    color: #edf6ff;
    font-weight: 600;
    margin-bottom: 5px;
}

.alerta-descripcion {
    color: #8298ad;
    font-size: 12px;
}

.alerta-valores {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
    margin-top: 14px;
}

    .alerta-valores div {
        padding: 11px;
        border-radius: 10px;
        background: rgba(5, 18, 31, .6);
    }

    .alerta-valores span {
        display: block;
        color: #728aa2;
        font-size: 10px;
        margin-bottom: 4px;
    }

    .alerta-valores strong {
        color: #dfeeff;
        font-size: 12px;
        font-weight: 500;
    }

.alerta-estado {
    padding: 6px 9px;
    border-radius: 15px;
    background: rgba(255,255,255,.05);
    color: #9cafc1;
    font-size: 9px;
    font-weight: 600;
}

.alerta-acciones {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 8px;
}

.alerta-boton {
    display: inline-block;
    padding: 7px 11px;
    border-radius: 10px;
    background: rgba(56, 190, 255, .10);
    border: 1px solid rgba(56, 190, 255, .18);
    color: #71dcff;
    font-size: 10px;
    font-weight: 600;
    text-decoration: none;
    transition: .2s;
}

    .alerta-boton:hover {
        background: rgba(56, 190, 255, .18);
        color: #b9efff;
    }

.resolver-alerta-panel {
    margin-top: 20px;
}

.resolver-alerta-card {
    padding: 24px;
    border-radius: 16px;
    background: rgba(8, 25, 43, .92);
    border: 1px solid rgba(56, 190, 255, .16);
}

.resolver-alerta-header {
    margin-bottom: 20px;
}

    .resolver-alerta-header h3 {
        margin: 0 0 6px 0;
        color: #edf6ff;
        font-size: 20px;
    }

    .resolver-alerta-header p {
        margin: 0;
        color: #8298ad;
        font-size: 13px;
    }

.resolver-alerta-campo {
    margin-top: 16px;
}

.resolver-modal-overlay {
    position: fixed;
    inset: 0;
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 24px;
    background: rgba(2, 10, 20, .78);
    backdrop-filter: blur(7px);
}

.resolver-modal {
    width: min(680px, 100%);
    padding: 26px;
    border-radius: 18px;
    background: #0a192b;
    border: 1px solid rgba(56, 190, 255, .22);
    box-shadow: 0 24px 70px rgba(0,0,0,.45), 0 0 35px rgba(56,190,255,.05);
}

.resolver-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 20px;
    margin-bottom: 22px;
}

    .resolver-modal-header h3 {
        margin: 6px 0 6px;
        color: #edf6ff;
        font-size: 21px;
    }

    .resolver-modal-header p {
        margin: 0;
        color: #8298ad;
        font-size: 13px;
        line-height: 1.5;
    }

.resolver-modal-cerrar {
    width: 34px;
    height: 34px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    border-radius: 10px;
    background: rgba(255,255,255,.04);
    border: 1px solid rgba(255,255,255,.08);
    color: #9cafc1;
    font-size: 22px;
    line-height: 1;
    text-decoration: none;
}

    .resolver-modal-cerrar:hover {
        background: rgba(255,255,255,.08);
        color: #ffffff;
    }

.resolver-alerta-eyebrow {
    display: block;
    color: #71dcff;
    font-size: 10px;
    letter-spacing: 3px;
}

.resolver-alerta-campo label {
    display: block;
    margin-bottom: 8px;
    color: #a8bdd0;
    font-size: 12px;
}

.resolver-alerta-texto {
    box-sizing: border-box;
    width: 100%;
    min-height: 120px;
    padding: 14px 15px;
    resize: vertical;
    border-radius: 12px;
    border: 1px solid rgba(120,160,190,.18);
    background: rgba(5,18,31,.78);
    color: #edf6ff;
    font-family: inherit;
    font-size: 13px;
    line-height: 1.5;
    outline: none;
}

    .resolver-alerta-texto:focus {
        border-color: rgba(56,190,255,.48);
        box-shadow: 0 0 0 3px rgba(56,190,255,.06);
    }

    .resolver-alerta-texto::placeholder {
        color: #60788d;
    }

.resolver-alerta-error {
    display: block;
    min-height: 18px;
    margin-top: 9px;
    color: #ff8d8d;
    font-size: 12px;
}

.resolver-alerta-botones {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 18px;
}

.resolver-alerta-cancelar,
.resolver-alerta-confirmar {
    padding: 10px 16px;
    border-radius: 10px;
    font-family: inherit;
    font-size: 11px;
    cursor: pointer;
}

.resolver-alerta-cancelar {
    background: transparent;
    border: 1px solid rgba(150,175,195,.20);
    color: #9cafc1;
}

.resolver-alerta-confirmar {
    background: rgba(56,190,255,.12);
    border: 1px solid rgba(56,190,255,.30);
    color: #71dcff;
}

    .resolver-alerta-confirmar:hover {
        background: rgba(56,190,255,.20);
    }

.resolver-alerta-cancelar:hover {
    background: rgba(255,255,255,.04);
}

.continuar-borrador {
    display: flex;
    justify-content: flex-end;
    margin-top: 28px;
}

.btn-continuar-borrador {
    padding: 12px 20px;
    border: 1px solid rgba(56,190,255,.30);
    border-radius: 12px;
    background: linear-gradient( 135deg, rgba(43,150,255,.22), rgba(71,214,255,.18) );
    color: #eaf8ff;
    font-family: inherit;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
}

    .btn-continuar-borrador:hover {
        background: linear-gradient( 135deg, rgba(43,150,255,.32), rgba(71,214,255,.26) );
    }

.btn-continuar-deshabilitado {
    opacity: .35;
    cursor: not-allowed;
}

/*PREPARAR BORRADOR*/

.borrador-container {
    max-width: 1400px;
    margin: 0 auto;
}

.borrador-encabezado {
    margin-bottom: 28px;
}

.borrador-eyebrow {
    display: block;
    margin-bottom: 8px;
    color: #71dcff;
    font-size: 10px;
    letter-spacing: 3px;
}

.borrador-encabezado h1 {
    margin: 0 0 10px;
    color: #edf6ff;
    font-size: 30px;
}

.borrador-encabezado p {
    margin: 0;
    color: #8ba0b4;
    font-size: 14px;
}

.borrador-estado {
    display: flex;
    align-items: center;
    gap: 14px;
    padding: 18px 20px;
    border: 1px solid rgba(76, 220, 170, .18);
    border-radius: 14px;
    background: rgba(15, 39, 48, .55);
}

.borrador-estado-icono {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 42px;
    height: 42px;
    border-radius: 12px;
    background: rgba(54, 211, 153, .12);
    color: #65e6b4;
    font-size: 18px;
}

.borrador-estado span {
    display: block;
    margin-bottom: 3px;
    color: #7991a5;
    font-size: 9px;
    letter-spacing: 2px;
}

.borrador-estado strong {
    color: #e9f8f2;
    font-size: 14px;
}

.borrador-bloqueado {
    max-width: 900px;
    margin: 60px auto;
    padding: 28px;
    display: flex;
    gap: 20px;
    align-items: flex-start;
    border-radius: 18px;
    background: rgba(255, 183, 70, .05);
    border: 1px solid rgba(255, 183, 70, .18);
}

.borrador-bloqueado-icono {
    width: 48px;
    height: 48px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    border-radius: 14px;
    background: rgba(255, 183, 70, .12);
    color: #f5c76f;
    font-size: 20px;
}

.borrador-bloqueado span {
    color: #f5c76f;
    font-size: 10px;
    letter-spacing: 3px;
}

.borrador-bloqueado h2 {
    margin: 7px 0 7px;
    color: #edf6ff;
    font-size: 21px;
}

.borrador-bloqueado p {
    margin: 0 0 18px;
    color: #8298ad;
    font-size: 13px;
}

.btn-volver-revision {
    display: inline-block;
    padding: 9px 14px;
    border-radius: 10px;
    background: rgba(56, 190, 255, .10);
    border: 1px solid rgba(56, 190, 255, .22);
    color: #71dcff;
    font-size: 11px;
    text-decoration: none;
}

    .btn-volver-revision:hover {
        background: rgba(56, 190, 255, .18);
        color: #bcefff;
    }

.resumen-borrador {
    margin-top: 28px;
}

.resumen-borrador-header {
    margin-bottom: 18px;
}

    .resumen-borrador-header h2 {
        margin: 5px 0;
        color: #edf6ff;
        font-size: 22px;
    }

    .resumen-borrador-header p {
        margin: 0;
        color: #8298ad;
        font-size: 13px;
    }

.resumen-grid {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
}

.resumen-card {
    padding: 18px;
    border-radius: 14px;
    background: rgba(8,25,43,.82);
    border: 1px solid rgba(72,181,255,.14);
}

    .resumen-card span {
        display: block;
        margin-bottom: 7px;
        color: #708aa2;
        font-size: 10px;
        letter-spacing: 1.5px;
    }

    .resumen-card strong {
        display: block;
        color: #eaf4ff;
        font-size: 14px;
        font-weight: 600;
    }

    .resumen-card p {
        margin: 7px 0 0;
        color: #8ba0b4;
        font-size: 12px;
    }

.resumen-card-ancho {
    grid-column: span 2;
}

.antecedentes-registrales {
    margin-top: 30px;
}

.antecedentes-header {
    margin-bottom: 18px;
}

    .antecedentes-header h2 {
        margin: 5px 0;
        color: #edf6ff;
        font-size: 22px;
    }

    .antecedentes-header p {
        margin: 0;
        color: #8298ad;
        font-size: 13px;
    }

.antecedentes-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
}

.antecedente-card {
    padding: 17px;
    border-radius: 14px;
    background: rgba(8, 25, 43, .82);
    border: 1px solid rgba(72, 181, 255, .14);
}

    .antecedente-card span {
        display: block;
        margin-bottom: 7px;
        color: #708aa2;
        font-size: 10px;
        letter-spacing: 1.2px;
    }

    .antecedente-card strong {
        display: block;
        color: #eaf4ff;
        font-size: 13px;
        font-weight: 600;
        line-height: 1.45;
    }

.antecedente-card-ancho {
    grid-column: span 3;
}

.inscripciones-titulo {
    margin-top: 22px;
    margin-bottom: 10px;
    color: #9fb2c7;
    font-size: 11px;
    letter-spacing: 2px;
}

.inscripcion-card {
    margin-top: 12px;
    padding: 18px;
    border-radius: 14px;
    background: rgba(8, 25, 43, .82);
    border: 1px solid rgba(255, 183, 70, .14);
}

.inscripcion-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 14px;
}

    .inscripcion-header strong {
        color: #edf6ff;
        font-size: 14px;
    }

    .inscripcion-header span {
        padding: 5px 9px;
        border-radius: 15px;
        background: rgba(255, 183, 70, .10);
        color: #f5c76f;
        font-size: 9px;
        font-weight: 600;
    }

.inscripcion-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 10px;
}

    .inscripcion-grid div {
        padding: 11px;
        border-radius: 10px;
        background: rgba(5, 18, 31, .65);
    }

    .inscripcion-grid span {
        display: block;
        margin-bottom: 4px;
        color: #708aa2;
        font-size: 10px;
    }

    .inscripcion-grid strong {
        color: #eaf4ff;
        font-size: 12px;
        font-weight: 500;
    }

.inscripcion-card p {
    margin: 14px 0 0;
    color: #879db1;
    font-size: 12px;
    line-height: 1.5;
}

.decisiones-revision {
    width: 100%;
    margin-top: 30px;
    padding: 0;
}

.decision-card {
    margin-top: 14px;
    padding: 18px;
    border-radius: 14px;
    background: rgba(8,25,43,.82);
    border: 1px solid rgba(76,220,170,.16);
}

.decision-header {
    display: flex;
    justify-content: space-between;
    gap: 20px;
    margin-bottom: 14px;
}

.decision-tipo {
    display: block;
    margin-bottom: 5px;
    color: #dfeeff;
    font-size: 13px;
}

.decision-header strong {
    color: #63e1a7;
    font-size: 10px;
}

.decision-fecha {
    color: #708aa2;
    font-size: 10px;
}

.decision-valores {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
}

    .decision-valores div {
        padding: 11px;
        border-radius: 10px;
        background: rgba(5,18,31,.65);
    }

    .decision-valores span {
        display: block;
        margin-bottom: 4px;
        color: #708aa2;
        font-size: 9px;
    }

    .decision-valores strong {
        color: #eaf4ff;
        font-size: 11px;
        font-weight: 500;
    }

.decision-resolucion {
    margin-top: 14px;
    padding: 13px;
    border-radius: 10px;
    background: rgba(48,210,145,.045);
    border: 1px solid rgba(48,210,145,.09);
}

    .decision-resolucion span {
        display: block;
        margin-bottom: 5px;
        color: #63e1a7;
        font-size: 9px;
        letter-spacing: 1.5px;
    }

    .decision-resolucion p {
        margin: 0;
        color: #cddce8;
        font-size: 12px;
        line-height: 1.5;
    }

.json-consolidado {
    width: 100%;
    margin-top: 30px;
}

.json-consolidado-contenedor {
    width: 100%;
    overflow: hidden;
    border-radius: 14px;
}

.json-consolidado-texto {
    display: block;
    box-sizing: border-box;
    width: 100%;
    height: 460px;
    min-height: 460px;
    max-width: 100%;
    margin: 0;
    padding: 18px;
    border-radius: 14px;
    border: 1px solid rgba(72, 181, 255, .14);
    background: rgba(5, 18, 31, .86);
    color: #9edcff;
    font-family: Consolas, "Courier New", monospace;
    font-size: 11px;
    line-height: 1.6;
    white-space: pre;
    overflow: auto;
    resize: vertical;
    outline: none;
}

.generar-borrador-panel {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 30px;
    margin-top: 32px;
    padding: 24px;
    border-radius: 16px;
    background: rgba(12, 32, 52, .86);
    border: 1px solid rgba(72, 181, 255, .18);
}

.generar-borrador-info {
    flex: 1;
}

    .generar-borrador-info h2 {
        margin: 6px 0 7px;
        color: #edf6ff;
        font-size: 21px;
    }

    .generar-borrador-info p {
        margin: 0;
        color: #8298ad;
        font-size: 13px;
        line-height: 1.5;
    }

.btn-generar-borrador {
    padding: 12px 20px;
    border-radius: 12px;
    border: 1px solid rgba(56, 190, 255, .30);
    background: linear-gradient( 135deg, rgba(43, 150, 255, .26), rgba(71, 214, 255, .20) );
    color: #edfaff;
    font-family: inherit;
    font-size: 12px;
    font-weight: 600;
    cursor: pointer;
}

    .btn-generar-borrador:hover {
        background: linear-gradient( 135deg, rgba(43, 150, 255, .38), rgba(71, 214, 255, .28) );
    }

.mensaje-generacion {
    display: block;
    margin-top: 12px;
    color: #8ddcff;
    font-size: 12px;
}

.borrador-generado-panel {
    width: 100%;
    margin-top: 28px;
    text-align:justify;

}

.borrador-generado-texto {
    display: block;
    box-sizing: border-box;
    width: 100%;
    min-height: 600px;
    padding: 22px;
    border-radius: 16px;
    border: 1px solid rgba(72,181,255,.18);
    background: rgba(5,18,31,.90);
    color: #e7f2ff;
    font-family: "Segoe UI", Arial, sans-serif;
    font-size: 13px;
    line-height: 1.7;
    resize: vertical;
    outline: none;
}

    .borrador-generado-texto:focus {
        border-color: rgba(56,190,255,.45);
        box-shadow: 0 0 0 3px rgba(56,190,255,.06);
    }

.borrador-generado-acciones {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    margin-top: 16px;
}

.btn-borrador-secundario {
    padding: 12px 18px;
    border-radius: 12px;
    border: 1px solid rgba(150,175,195,.20);
    background: transparent;
    color: #a9bdcf;
    font-family: inherit;
    font-size: 12px;
    cursor: pointer;
}

    .btn-borrador-secundario:hover {
        background: rgba(255,255,255,.04);
    }

.decision-borrador {
    display: flex;
    align-items: center;
    gap: 18px;
    margin-top: 20px;
    padding: 20px 24px;
    border: 1px solid #183b52;
    border-radius: 16px;
    background: #0b1d2b;
}

.decision-icon {
    width: 46px;
    height: 46px;
    min-width: 46px;
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 22px;
}

.decision-contenido h3 {
    margin: 3px 0 5px;
    font-size: 18px;
}

.decision-contenido p {
    margin: 0;
    opacity: .78;
}

.decision-etiqueta {
    font-size: 10px;
    letter-spacing: 3px;
    opacity: .65;
}

.decision-automatico {
    border-color: #12564f;
}

    .decision-automatico .decision-icon {
        background: #0b403b;
        color: #63e6be;
    }

.decision-revisar {
    border-color: #665322;
}

    .decision-revisar .decision-icon {
        background: #3b321c;
        color: #ffd43b;
    }

.decision-bloqueado {
    border-color: #633131;
}

    .decision-bloqueado .decision-icon {
        background: #402020;
        color: #ff8787;
    }

.borrador-auto-panel {
    width: 100%;
    margin-top: 26px;
}

.borrador-auto-header {
    margin-bottom: 16px;
}

    .borrador-auto-header h2 {
        margin: 5px 0;
        color: #edf6ff;
        font-size: 22px;
    }

    .borrador-auto-header p {
        margin: 0;
        color: #8298ad;
        font-size: 13px;
    }

.borrador-auto-aviso {
    margin-bottom: 14px;
    padding: 12px 14px;
    border-radius: 10px;
    background: rgba(255, 183, 70, .07);
    border: 1px solid rgba(255, 183, 70, .16);
    color: #e8c877;
    font-size: 12px;
}

.borrador-auto-texto {
    display: block;
    box-sizing: border-box;
    width: 100%;
    min-height: 580px;
    padding: 20px;
    border-radius: 14px;
    border: 1px solid rgba(72, 181, 255, .14);
    background: rgba(5,18,31,.90);
    color: #e7f2ff;
    font-family: "Segoe UI", Arial, sans-serif;
    font-size: 13px;
    line-height: 1.7;
    resize: vertical;
    outline: none;
}

.borrador-editor-juridico {
    min-height: 650px;
    max-height: 850px;
    overflow-y: auto;
    padding: 32px 36px;
    background: #ffffff;
    border: 1px solid #d7e0e8;
    border-radius: 14px;
    font-family: Arial, sans-serif;
    font-size: 15px;
    line-height: 1.7;
    color: #172635;
    text-align: justify;
    white-space: normal;
    outline: none;
}

    .borrador-editor-juridico:focus {
        border-color: #22749a;
        box-shadow: 0 0 0 3px rgba(34, 116, 154, 0.08);
    }

    .borrador-editor-juridico .titulo-documento {
        text-align: center;
        font-weight: 700;
        margin-bottom: 4px;
    }

    .borrador-editor-juridico .encabezado-documento {
        text-align: center;
        font-weight: 700;
        margin: 2px 0;
    }

    .borrador-editor-juridico .parrafo-juridico {
        text-align: justify;
        margin: 0 0 12px 0;
    }

    .borrador-editor-juridico .facultad-juridica {
        text-align: justify;
        margin: 0 0 10px 0;
    }

        .borrador-editor-juridico .facultad-juridica strong {
            font-weight: 700;
        }

/* =========================================================
   LOADER GLOBAL
   ========================================================= */

.global-loading-overlay {
    position: fixed;
    inset: 0;
    display: none;
    align-items: center;
    justify-content: center;
    background: rgba(244, 248, 251, 0.82);
    backdrop-filter: blur(2px);
    z-index: 99999;
}

    .global-loading-overlay.visible {
        display: flex;
    }

.global-loading-box {
    min-width: 290px;
    max-width: 420px;
    padding: 28px 32px;
    background: #ffffff;
    border: 1px solid #d8e2ea;
    border-radius: 16px;
    box-shadow: 0 18px 50px rgba(11, 32, 51, 0.16);
    text-align: center;
}

.global-loading-spinner {
    width: 42px;
    height: 42px;
    margin: 0 auto 18px auto;
    border: 4px solid #dbe7ee;
    border-top-color: #16759b;
    border-radius: 50%;
    animation: global-loading-spin 0.8s linear infinite;
}

.global-loading-title {
    margin-bottom: 6px;
    font-size: 18px;
    font-weight: 700;
    color: #0b2033;
}

.global-loading-message {
    font-size: 14px;
    line-height: 1.5;
    color: #5e6f7e;
}

@keyframes global-loading-spin {

    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}



@media(max-width:800px) {

    .borrador-generado-acciones {
        flex-direction: column;
    }

    .btn-borrador-secundario,
    .btn-generar-borrador {
        width: 100%;
    }
}

@media(max-width: 800px) {

    .generar-borrador-panel {
        flex-direction: column;
        align-items: stretch;
    }

    .btn-generar-borrador {
        width: 100%;
    }
}


@media(max-width: 900px) {
    .decision-valores {
        grid-template-columns: 1fr;
    }
}

@media(max-width: 900px) {
    .inscripcion-grid {
        grid-template-columns: 1fr;
    }
}

@media(max-width: 900px) {

    .antecedentes-grid {
        grid-template-columns: 1fr;
    }

    .antecedente-card-ancho {
        grid-column: span 1;
    }
}

@media(max-width: 800px) {

    .resumen-grid {
        grid-template-columns: 1fr;
    }

    .resumen-card-ancho {
        grid-column: span 1;
    }
}

@media (max-width: 700px) {
    .resolver-modal-overlay {
        padding: 14px;
    }

    .resolver-modal {
        padding: 20px;
    }

    .resolver-alerta-botones {
        flex-direction: column-reverse;
    }

    .resolver-alerta-cancelar,
    .resolver-alerta-confirmar {
        width: 100%;
    }
}


@media(max-width: 800px) {
    .alerta-valores {
        grid-template-columns: 1fr;
    }

    .alerta-card {
        flex-wrap: wrap;
    }
}


@media(max-width: 800px) {

    .resultado-global {
        align-items: flex-start;
        flex-wrap: wrap;
    }

    .resultado-global-estado {
        margin-left: 66px;
    }
}


@media(max-width: 800px) {
    .validacion-grid-dos {
        grid-template-columns: 1fr;
    }
}

@media(max-width: 800px) {
    .validacion-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 800px) {
    .ia-grid {
        grid-template-columns: 1fr;
    }

    .ia-dato-ancho {
        grid-column: span 1;
    }
}

@media(max-width: 800px) {
    .ia-doc-grid {
        grid-template-columns: 1fr;
    }
}

@media(max-width: 700px) {
    .ia-summary-grid {
        grid-template-columns: 1fr;
    }
}


@keyframes iaFloat {
    0%, 100% {
        transform: translateY(0);
    }

    50% {
        transform: translateY(-5px);
    }
}

@keyframes iaCore {
    0%, 100% {
        transform: scale(.92);
        filter: brightness(.95);
    }

    50% {
        transform: scale(1.08);
        filter: brightness(1.18);
    }
}

@keyframes iaPulse {
    0%, 100% {
        transform: scale(.92);
        opacity: .2;
    }

    50% {
        transform: scale(1.12);
        opacity: .65;
    }
}

@keyframes iaRing {
    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

@media(max-width: 700px) {
    .ia-grid {
        grid-template-columns: 1fr;
    }

    .field-wide {
        grid-column: auto;
    }

    .ia-header {
        align-items: flex-start;
    }
}


/* ============================================================
   TEMA CLARO - SUBETUDOCTO
   IMPORTANTE:
   Este bloque debe permanecer AL FINAL de ia.css.
   No elimina ni modifica las clases originales.
   ============================================================ */

:root {
    --notaria-navy: #0b2033;
    --notaria-navy-2: #12334e;
    --notaria-blue: #1f5c7a;
    --notaria-accent: #2d7896;
    --notaria-ice: #edf4f7;
    --notaria-bg: #f4f6f8;
    --notaria-border: #dbe2e8;
    --notaria-text: #1f2933;
    --notaria-muted: #667784;
    --notaria-success: #197447;
    --notaria-warning: #9a6700;
    --notaria-danger: #b42318;
}


/* ============================================================
   GENERAL
   ============================================================ */

html,
body {
    min-height: 100%;
}

body {
    margin: 0;
    background: radial-gradient( circle at 12% 20%, rgba(45,120,150,.05), transparent 28% ), radial-gradient( circle at 85% 62%, rgba(11,32,51,.04), transparent 30% ), var(--notaria-bg);
    color: var(--notaria-text);
    font-family: "Segoe UI", Arial, Helvetica, sans-serif;
}


.ia-page {
    min-height: 100vh;
    padding: 42px 20px 56px;
}


.ia-shell {
    max-width: 1100px;
}


/* ============================================================
   HEADER IA
   ============================================================ */

.ia-label,
.ia-etiqueta,
.validacion-eyebrow,
.resolver-alerta-eyebrow,
.borrador-eyebrow,
.decision-etiqueta {
    color: var(--notaria-accent);
}


.ia-header h1,
.ia-resultado-header h2,
.validacion-header h2,
.resolver-alerta-header h3,
.borrador-encabezado h1,
.resumen-borrador-header h2,
.antecedentes-header h2,
.generar-borrador-info h2,
.borrador-auto-header h2,
.decision-contenido h3 {
    color: var(--notaria-navy);
}


.ia-header p,
.ia-resultado-header p,
.validacion-header p,
.resolver-alerta-header p,
.borrador-encabezado p,
.resumen-borrador-header p,
.antecedentes-header p,
.generar-borrador-info p,
.borrador-auto-header p,
.decision-contenido p {
    color: var(--notaria-muted);
}


/* ============================================================
   PROGRESO
   ============================================================ */

.ia-progress {
    height: 6px;
    background: #dfe8ed;
    box-shadow: inset 0 1px 2px rgba(11,32,51,.04);
}


.ia-progress-bar {
    background: linear-gradient( 90deg, var(--notaria-blue) 0%, var(--notaria-accent) 100% );
    box-shadow: none;
}


/* ============================================================
   CARD PRINCIPAL
   ============================================================ */

.ia-card {
    background: #ffffff;
    border: 1px solid rgba(11,32,51,.08);
    box-shadow: 0 18px 45px rgba(11,32,51,.08);
    backdrop-filter: none;
}


.ia-question {
    color: var(--notaria-navy);
}


/* ============================================================
   FORMULARIOS
   ============================================================ */

.field label,
.resolver-alerta-campo label {
    color: var(--notaria-navy);
    font-weight: 650;
}


.ia-input,
.resolver-alerta-texto {
    background: #ffffff;
    color: var(--notaria-text);
    border: 1px solid #ccd7df;
}


    .ia-input:focus,
    .resolver-alerta-texto:focus {
        border-color: var(--notaria-accent);
        box-shadow: 0 0 0 .2rem rgba(45,120,150,.14);
    }


    .ia-input::placeholder,
    .resolver-alerta-texto::placeholder {
        color: #8b98a3;
    }


.ia-help {
    color: var(--notaria-muted);
}


/* ============================================================
   BOTONES
   ============================================================ */

.ia-button,
.btn-continuar-borrador,
.btn-generar-borrador {
    border: 1px solid var(--notaria-navy);
    background: var(--notaria-navy);
    color: #ffffff;
    box-shadow: none;
}


    .ia-button:hover,
    .btn-continuar-borrador:hover,
    .btn-generar-borrador:hover {
        background: var(--notaria-navy-2);
        border-color: var(--notaria-navy-2);
        color: #ffffff;
        filter: none;
    }


.btn-borrador-secundario,
.btn-volver-revision,
.alerta-boton,
.resolver-alerta-confirmar {
    background: #ffffff;
    border: 1px solid #b9c7d1;
    color: var(--notaria-navy);
}


    .btn-borrador-secundario:hover,
    .btn-volver-revision:hover,
    .alerta-boton:hover,
    .resolver-alerta-confirmar:hover {
        background: var(--notaria-navy);
        border-color: var(--notaria-navy);
        color: #ffffff;
    }


.resolver-alerta-cancelar {
    background: #ffffff;
    border: 1px solid #cbd5dc;
    color: var(--notaria-muted);
}


    .resolver-alerta-cancelar:hover {
        background: #f1f5f7;
        color: var(--notaria-navy);
    }


/* ============================================================
   ORBE IA
   ============================================================ */

.ia-orb {
    background: #f1f7f9;
    border: 1px solid #c8dce5;
    box-shadow: 0 8px 24px rgba(11,32,51,.06);
}


    .ia-orb::before {
        border-color: rgba(45,120,150,.28);
    }


    .ia-orb::after {
        border-color: rgba(45,120,150,.10);
    }


.ia-orb-core {
    background: radial-gradient( circle at 35% 30%, #ffffff 0%, #dceff5 25%, #5a9ab3 65%, #1f5c7a 100% );
    box-shadow: 0 0 12px rgba(45,120,150,.18), 0 0 28px rgba(45,120,150,.12);
}


/* ============================================================
   TARJETAS SECUNDARIAS
   ============================================================ */

.ia-subcard,
.ia-summary-card,
.ia-doc-card,
.documento-card,
.ia-resultado,
.validacion-panel,
.validacion-bloque,
.validacion-dato,
.alertas-panel,
.alerta-card-pendiente,
.alerta-card-resuelta,
.resolver-alerta-card,
.resumen-card,
.antecedente-card,
.inscripcion-card,
.decision-card,
.generar-borrador-panel,
.decision-borrador {
    background: #ffffff;
    border: 1px solid var(--notaria-border);
    box-shadow: 0 10px 28px rgba(11,32,51,.05);
}


/* ============================================================
   TEXTOS DE TARJETAS
   ============================================================ */

.ia-subtitle,
.ia-summary-title,
.ia-doc-icon {
    color: var(--notaria-accent);
}


.ia-summary-line,
.ia-doc-title,
.documento-info strong,
.ia-dato strong,
.validacion-titulo,
.validacion-dato strong,
.resultado-global-info strong,
.alerta-titulo,
.alerta-valores strong,
.resumen-card strong,
.antecedente-card strong,
.inscripcion-header strong,
.inscripcion-grid strong,
.decision-tipo,
.decision-valores strong,
.decision-resolucion p {
    color: var(--notaria-text);
}


.ia-summary-label,
.ia-doc-description,
.documento-info span,
.ia-dato span,
.validacion-dato span,
.resultado-global-etiqueta,
.resultado-global-info p,
.alerta-descripcion,
.alerta-valores span,
.resumen-card span,
.resumen-card p,
.antecedente-card span,
.inscripcion-grid span,
.inscripcion-card p,
.decision-fecha,
.decision-valores span {
    color: var(--notaria-muted);
}


/* ============================================================
   DOCUMENTOS
   ============================================================ */

.ia-doc-card {
    background: #ffffff;
    border: 1px solid var(--notaria-border);
}


    .ia-doc-card:hover {
        transform: translateY(-2px);
        border-color: #a9bfcc;
        box-shadow: 0 12px 25px rgba(11,32,51,.08);
    }


.ia-doc-icon,
.documento-icono {
    background: var(--notaria-ice);
    border: 1px solid #d6e5eb;
    color: var(--notaria-accent);
}


.ia-file {
    color: var(--notaria-muted);
}


/* ============================================================
   ESTADOS DE DOCUMENTOS
   ============================================================ */

.ia-doc-status,
.documento-estado,
.alerta-estado {
    background: #edf1f4;
    color: #536572;
}


.ia-doc-status-ok,
.documento-estado-ok,
.validacion-ok,
.resultado-global-ok {
    background: #e6f5ec;
    color: #2e6846;
    border-color: #c3dfcf;
}


.documento-estado-pendiente,
.validacion-alerta,
.resultado-global-alerta {
    background: #fff5db;
    color: #7a5a14;
    border-color: #eedca9;
}


.documento-estado-error {
    background: #fdecec;
    color: #8a4343;
    border-color: #efcaca;
}


/* ============================================================
   RESULTADO GLOBAL
   ============================================================ */

.resultado-global {
    background: #fff9e8;
    border: 1px solid #ead596;
}


.resultado-global-icono {
    background: #fff2cc;
    color: var(--notaria-warning);
}


/* ============================================================
   ALERTAS
   ============================================================ */

.alertas-panel {
    background: #ffffff;
    border: 1px solid #ead596;
}


.alertas-header h2 {
    color: var(--notaria-navy);
}


.alertas-header p {
    color: var(--notaria-muted);
}


.alertas-eyebrow {
    color: var(--notaria-warning);
}


.alertas-contador {
    background: #fff5db;
    color: #7a5a14;
    border: 1px solid #eedca9;
}


.alerta-card-pendiente {
    background: #fffaf0;
    border: 1px solid #ead596;
}


.alerta-card-resuelta {
    background: #f1f8f4;
    border: 1px solid #acd6bf;
}


.alerta-icono {
    background: #f1f5f7;
}


/* ============================================================
   MODAL RESOLVER ALERTA
   ============================================================ */

.resolver-modal-overlay {
    background: rgba(11,32,51,.32);
    backdrop-filter: blur(4px);
}


.resolver-modal {
    background: #ffffff;
    border: 1px solid #cfdde4;
    box-shadow: 0 24px 70px rgba(11,32,51,.18);
}


.resolver-modal-cerrar {
    background: #f3f6f8;
    border: 1px solid #d8e0e5;
    color: var(--notaria-muted);
}


    .resolver-modal-cerrar:hover {
        background: var(--notaria-navy);
        color: #ffffff;
    }


.resolver-alerta-error {
    color: var(--notaria-danger);
}


/* ============================================================
   PREPARAR BORRADOR
   ============================================================ */

.borrador-estado {
    background: #edf8f2;
    border: 1px solid #acd6bf;
}


.borrador-estado-icono {
    background: #dff2e7;
    color: var(--notaria-success);
}


.borrador-estado span {
    color: var(--notaria-muted);
}


.borrador-estado strong {
    color: #145f3b;
}


.borrador-bloqueado {
    background: #fff9e8;
    border: 1px solid #ead596;
}


.borrador-bloqueado-icono {
    background: #fff2cc;
    color: var(--notaria-warning);
}


.borrador-bloqueado span {
    color: var(--notaria-warning);
}


.borrador-bloqueado h2 {
    color: var(--notaria-navy);
}


.borrador-bloqueado p {
    color: var(--notaria-muted);
}


/* ============================================================
   INSCRIPCIONES
   ============================================================ */

.inscripcion-card {
    border-color: #e3d6ae;
}


.inscripcion-header span {
    background: #fff5db;
    color: #7a5a14;
}


/* ============================================================
   DECISIONES
   ============================================================ */

.decision-resolucion {
    background: #edf8f2;
    border: 1px solid #acd6bf;
}


    .decision-resolucion span,
    .decision-header strong {
        color: var(--notaria-success);
    }


.decision-borrador {
    background: #ffffff;
}


.decision-automatico {
    border-color: #acd6bf;
    background: #f1f8f4;
}


    .decision-automatico .decision-icon {
        background: #dff2e7;
        color: var(--notaria-success);
    }


.decision-revisar {
    border-color: #ead596;
    background: #fff9e8;
}


    .decision-revisar .decision-icon {
        background: #fff2cc;
        color: var(--notaria-warning);
    }


.decision-bloqueado {
    border-color: #efcaca;
    background: #fff5f5;
}


    .decision-bloqueado .decision-icon {
        background: #fdecec;
        color: var(--notaria-danger);
    }


/* ============================================================
   JSON
   ============================================================ */

.json-consolidado-texto {
    background: #fbfcfd;
    border: 1px solid var(--notaria-border);
    color: #28576d;
}


/* ============================================================
   BORRADOR GENERADO
   ============================================================ */

.borrador-generado-texto,
.borrador-auto-texto {
    background: #ffffff;
    border: 1px solid var(--notaria-border);
    color: var(--notaria-text);
}


    .borrador-generado-texto:focus {
        border-color: var(--notaria-accent);
        box-shadow: 0 0 0 .2rem rgba(45,120,150,.10);
    }


.mensaje-generacion {
    color: var(--notaria-accent);
}


.borrador-auto-aviso {
    background: #fff9e8;
    border: 1px solid #ead596;
    color: #765300;
}


/* ============================================================
   NOTA DE REVISIÓN
   ============================================================ */

.ia-review-note {
    background: #f1f7f9;
    border: 1px solid #d6e5eb;
    color: #284b5e;
}


/* ============================================================
   INPUT FILE
   ============================================================ */

input[type="file"]::file-selector-button {
    margin-right: 10px;
    padding: 8px 12px;
    border: 1px solid #b9c7d1;
    border-radius: 8px;
    background: #ffffff;
    color: var(--notaria-navy);
    font-weight: 650;
    cursor: pointer;
}


    input[type="file"]::file-selector-button:hover {
        background: var(--notaria-navy);
        color: #ffffff;
    }


/* ============================================================
   RESPONSIVE TEMA CLARO
   ============================================================ */

@media(max-width: 800px) {

    .ia-page {
        padding: 24px 14px 36px;
    }


    .ia-card {
        padding: 22px;
        border-radius: 16px;
    }


    .ia-header {
        gap: 16px;
    }


        .ia-header h1 {
            font-size: 28px;
        }
}



/* ============================================================
   ESTRUCTURA PARA FONDO AMBIENTAL
   ============================================================ */

.site-frame {
    position: relative;
    z-index: 1;
    min-height: 100vh;
    display: flex;
    flex-direction: column;
}

.ambient-bg {
    position: fixed;
    inset: 0;
    z-index: 0;
    overflow: hidden;
    pointer-events: none;
    background: radial-gradient( circle at 12% 20%, rgba(45,120,150,.055), transparent 28% ), radial-gradient( circle at 85% 62%, rgba(11,32,51,.045), transparent 30% );
}


/* ============================================================
   ROMBOS ANIMADOS
   ============================================================ */

/*
    Se mantiene exactamente la estructura existente:

    ambient-bg
        ambient-diamond diamond-1
        ambient-diamond diamond-2
        ...
*/


.ambient-diamond {
    position: absolute;
    display: block;
    border: 1px solid rgba(45,120,150,.20);
    background: rgba(255,255,255,.18);
    box-shadow: 0 0 22px rgba(45,120,150,.03);
    transform: rotate(45deg);
    opacity: .38;
    animation-name: diamondFloatVisible;
    animation-timing-function: ease-in-out;
    animation-iteration-count: infinite;
    animation-direction: alternate;
    will-change: transform, opacity;
}


/* ============================================================
   ROMBO 1
   Superior izquierdo
   ============================================================ */

.diamond-1 {
    left: 5%;
    top: 20%;
    width: 78px;
    height: 78px;
    animation-duration: 11s;
    animation-delay: -2s;
}


/* ============================================================
   ROMBO 2
   Inferior izquierdo
   ============================================================ */

.diamond-2 {
    left: 20%;
    top: 72%;
    width: 38px;
    height: 38px;
    animation-duration: 14s;
    animation-delay: -7s;
}


/* ============================================================
   ROMBO 3
   Superior derecho
   ============================================================ */

.diamond-3 {
    right: 8%;
    top: 21%;
    width: 64px;
    height: 64px;
    animation-duration: 13s;
    animation-delay: -4s;
}


/* ============================================================
   ROMBO 4
   Inferior derecho
   ============================================================ */

.diamond-4 {
    right: 24%;
    top: 72%;
    width: 92px;
    height: 92px;
    animation-duration: 16s;
    animation-delay: -10s;
}


/* ============================================================
   ROMBO 5
   Superior central
   ============================================================ */

.diamond-5 {
    left: 48%;
    top: 17%;
    width: 30px;
    height: 30px;
    animation-duration: 10s;
    animation-delay: -5s;
}


/* ============================================================
   ROMBO 6
   Centro derecho
   ============================================================ */

.diamond-6 {
    left: 58%;
    top: 58%;
    width: 48px;
    height: 48px;
    animation-duration: 12s;
    animation-delay: -8s;
}


/* ============================================================
   ANIMACIÓN MÁS VISIBLE
   ============================================================ */

@keyframes diamondFloatVisible {

    0% {
        transform: translate3d( 0, 0, 0 ) rotate(45deg);
        opacity: .22;
    }


    20% {
        transform: translate3d( 18px, -18px, 0 ) rotate(55deg);
        opacity: .36;
    }


    40% {
        transform: translate3d( 34px, -40px, 0 ) rotate(68deg);
        opacity: .50;
    }


    60% {
        transform: translate3d( 12px, -62px, 0 ) rotate(82deg);
        opacity: .58;
    }


    80% {
        transform: translate3d( -28px, -22px, 0 ) rotate(98deg);
        opacity: .42;
    }


    100% {
        transform: translate3d( -42px, 34px, 0 ) rotate(115deg);
        opacity: .25;
    }
}


