
/* ============================================================
   OrtaLegal · Buttons v1.0
   Botones premium: ayuda ?, modo oscuro y login.
   ============================================================ */

/* Grupo de botones superior más fino */
.top-actions{
    display:flex;
    align-items:center;
    gap:10px;
}

/* Base brillante para botones tipo pill */
.pill{
    position:relative;
    overflow:hidden;
    isolation:isolate;
    border:1px solid rgba(189,146,80,.30)!important;
    background:
        linear-gradient(135deg,rgba(255,255,255,.92),rgba(255,253,248,.72))!important;
    color:var(--auth-navy, #0b2845)!important;
    box-shadow:
        0 10px 24px rgba(16,32,51,.07),
        inset 0 1px 0 rgba(255,255,255,.85)!important;
    transition:transform .18s ease, box-shadow .18s ease, border-color .18s ease;
}

.pill::after{
    content:"";
    position:absolute;
    inset:-42% auto -42% -60%;
    width:48%;
    transform:skewX(-18deg);
    background:linear-gradient(90deg,transparent,rgba(255,255,255,.72),transparent);
    opacity:0;
    z-index:-1;
}

.pill:hover{
    transform:translateY(-1px);
    border-color:rgba(189,146,80,.72)!important;
    box-shadow:
        0 14px 30px rgba(16,32,51,.11),
        0 0 0 4px rgba(189,146,80,.08),
        inset 0 1px 0 rgba(255,255,255,.9)!important;
}

.pill:hover::after{
    animation:olButtonShine .72s ease;
    opacity:1;
}

@keyframes olButtonShine{
    from{left:-65%}
    to{left:130%}
}

body.dark .pill{
    background:
        linear-gradient(135deg,rgba(255,255,255,.10),rgba(255,255,255,.035))!important;
    color:#fff!important;
    border-color:rgba(215,189,124,.28)!important;
    box-shadow:
        0 10px 24px rgba(0,0,0,.18),
        inset 0 1px 0 rgba(255,255,255,.08)!important;
}

/* Botón de ayuda: solo ? */
.pill.support-pill{
    width:42px;
    height:42px;
    min-width:42px;
    padding:0!important;
    border-radius:999px!important;
    display:inline-flex;
    align-items:center;
    justify-content:center;
    font-size:19px;
    font-weight:900;
    line-height:1;
    letter-spacing:0;
    color:#fff!important;
    border-color:rgba(189,146,80,.58)!important;
    background:
        radial-gradient(circle at 30% 22%,rgba(255,255,255,.72),transparent 20%),
        linear-gradient(135deg,var(--auth-gold,#bd9250),var(--auth-gold-2,#d7bd7c))!important;
    box-shadow:
        0 12px 24px rgba(189,146,80,.24),
        inset 0 1px 0 rgba(255,255,255,.42)!important;
    text-shadow:0 1px 1px rgba(11,40,69,.24);
}

.pill.support-pill:hover{
    transform:translateY(-1px) scale(1.025);
    box-shadow:
        0 16px 32px rgba(189,146,80,.31),
        0 0 0 5px rgba(189,146,80,.12),
        inset 0 1px 0 rgba(255,255,255,.50)!important;
}

body.dark .pill.support-pill{
    color:#0b2845!important;
}

/* Modo oscuro más elegante */
.pill.ol-dark-toggle{
    min-height:42px;
    padding:0 16px 0 13px!important;
    gap:8px;
    font-weight:800;
}

.pill.ol-dark-toggle::before{
    content:"";
    width:16px;
    height:16px;
    flex:0 0 16px;
    border-radius:999px;
    background:
        radial-gradient(circle at 62% 38%,transparent 0 38%,var(--auth-navy,#0b2845) 40% 100%);
    box-shadow:0 0 0 3px rgba(189,146,80,.11);
}

body.dark .pill.ol-dark-toggle::before{
    background:
        radial-gradient(circle at 35% 35%,#fff 0 16%,transparent 18%),
        radial-gradient(circle at 66% 62%,#fff 0 10%,transparent 12%),
        radial-gradient(circle,#d7bd7c 0 100%);
}

/* Botón de salir conserva jerarquía, también brillante */
.pill.gold{
    color:#0e2035!important;
    border-color:rgba(189,146,80,.52)!important;
    background:
        radial-gradient(circle at 30% 22%,rgba(255,255,255,.62),transparent 20%),
        linear-gradient(135deg,var(--auth-gold,#bd9250),var(--auth-gold-2,#d7bd7c))!important;
}

/* Botón login premium */
.secure-form .btn.gold,
.login-card .btn.gold,
.login-card .btn,
.secure-form .btn{
    position:relative;
    overflow:hidden;
    isolation:isolate;
    min-height:50px!important;
    border-radius:16px!important;
    border:1px solid rgba(189,146,80,.55)!important;
    background:
        radial-gradient(circle at 30% 10%,rgba(255,255,255,.55),transparent 19%),
        linear-gradient(135deg,#b88a43 0%,#d9bd76 54%,#caa15a 100%)!important;
    color:#0b2035!important;
    box-shadow:
        0 14px 28px rgba(189,146,80,.24),
        inset 0 1px 0 rgba(255,255,255,.50)!important;
    text-shadow:0 1px 0 rgba(255,255,255,.28);
    transition:transform .18s ease, box-shadow .18s ease, filter .18s ease;
}

.secure-form .btn.gold::after,
.login-card .btn.gold::after,
.login-card .btn::after,
.secure-form .btn::after{
    content:"";
    position:absolute;
    inset:-45% auto -45% -70%;
    width:55%;
    transform:skewX(-18deg);
    background:linear-gradient(90deg,transparent,rgba(255,255,255,.58),transparent);
    z-index:-1;
    opacity:0;
}

.secure-form .btn.gold:hover:not(:disabled),
.login-card .btn.gold:hover:not(:disabled),
.login-card .btn:hover:not(:disabled),
.secure-form .btn:hover:not(:disabled){
    transform:translateY(-1px);
    filter:saturate(1.04);
    box-shadow:
        0 18px 34px rgba(189,146,80,.30),
        0 0 0 5px rgba(189,146,80,.10),
        inset 0 1px 0 rgba(255,255,255,.52)!important;
}

.secure-form .btn.gold:hover:not(:disabled)::after,
.login-card .btn.gold:hover:not(:disabled)::after,
.login-card .btn:hover:not(:disabled)::after,
.secure-form .btn:hover:not(:disabled)::after{
    animation:olButtonShine .75s ease;
    opacity:1;
}

.secure-form .btn.gold:disabled,
.login-card .btn.gold:disabled,
.login-card .btn:disabled,
.secure-form .btn:disabled{
    opacity:.52;
    cursor:not-allowed;
    filter:saturate(.65) grayscale(.08);
    box-shadow:none!important;
    transform:none!important;
}

/* Accesibilidad */
.pill:focus-visible,
.secure-form .btn:focus-visible,
.login-card .btn:focus-visible{
    outline:3px solid rgba(189,146,80,.26);
    outline-offset:3px;
}

@media(max-width:640px){
    .top-actions{
        gap:8px;
    }

    .pill.support-pill{
        width:40px;
        height:40px;
        min-width:40px;
    }

    .pill.ol-dark-toggle{
        min-height:40px;
        padding:0 12px!important;
    }
}
