﻿/* AM Club v708 - Fix real franja superior login móvil
   Causa detectada:
   afterman-ui-system.css agrega en móvil:
   body.am-body { padding-top: calc(var(--am-mobile-fixed-header-h) + env(safe-area-inset-top)) !important; }
   Aunque el header se oculte, ese padding sigue dejando una franja arriba.
*/

html,
html body.am-body{
    background:
        linear-gradient(180deg, rgba(5,7,20,.10), rgba(5,7,20,.16)),
        url('../Content/images/amclub-login-bg-mobile-v705.png') center top / 100% 100% no-repeat !important;
    background-color:#050714!important;
}

html body.am-body .am-topbar{
    display:none!important;
    visibility:hidden!important;
    opacity:0!important;
    height:0!important;
    min-height:0!important;
    max-height:0!important;
    padding:0!important;
    margin:0!important;
    border:0!important;
    overflow:hidden!important;
}

/* Reset del espacio reservado por el header fijo móvil */
html body.am-body{
    padding-top:0!important;
    margin-top:0!important;
}

html body.am-body form,
html body.am-body .am-page-shell{
    padding-top:0!important;
    margin-top:0!important;
    top:0!important;
}

html body.am-body .am-page-shell{
    min-height:100vh!important;
    height:100vh!important;
    max-height:100vh!important;
    width:100%!important;
    max-width:none!important;
    overflow:hidden!important;
    background:
        linear-gradient(180deg, rgba(5,7,20,.10), rgba(5,7,20,.16)),
        url('../Content/images/amclub-login-bg-mobile-v705.png') center top / 100% 100% no-repeat !important;
    background-color:#050714!important;
}

@supports (height:100dvh){
    html body.am-body .am-page-shell{
        min-height:100dvh!important;
        height:100dvh!important;
        max-height:100dvh!important;
    }
}

html body.am-body .am-page-shell > .am-login-v700{
    min-height:100vh!important;
    height:100vh!important;
    max-height:100vh!important;
    margin:0!important;
    padding:0!important;
    background:transparent!important;
}

@supports (height:100dvh){
    html body.am-body .am-page-shell > .am-login-v700{
        min-height:100dvh!important;
        height:100dvh!important;
        max-height:100dvh!important;
    }
}

/* El fondo interno parte desde el pixel 0, sin offset heredado */
html body.am-body .am-login-v700 .am-login-v482__bg{
    position:absolute!important;
    inset:0!important;
    width:100%!important;
    height:100%!important;
    min-height:100%!important;
    background:
        linear-gradient(180deg, rgba(5,7,20,.10), rgba(5,7,20,.16)),
        url('../Content/images/amclub-login-bg-mobile-v705.png') center top / 100% 100% no-repeat !important;
    filter:saturate(1.28) contrast(1.12) brightness(.96)!important;
}

/* Reubicar el formulario después de eliminar el padding fantasma del header */
html body.am-body .am-login-v700 .am-login-v482__shell{
    padding-top:14px!important;
    padding-bottom:14px!important;
    margin-top:0!important;
}

/* Desktop también sin header, pero sin forzar fondo móvil si no corresponde */
@media (min-width:821px){
    html,
    html body.am-body{
        background:#030511!important;
    }

    html body.am-body .am-page-shell{
        background:transparent!important;
    }
}
