/**
 * CSS for standalone authentication pages (login, register, forgot-password)
 * These pages need to appear standalone despite being rendered in App.razor
 */

/* Make the body wrapper full-width when auth pages are present */
body.auth-page > .body,
body > .body:has(> section.body-sign) {
    width: 100% !important;
    max-width: 100% !important;
    margin: 0 !important;
    padding: 0 !important;
    position: relative !important;
    min-height: 100vh !important;
}

/* Override any Porto theme container constraints */
body.auth-page > .body > section.body-sign,
body > .body > section.body-sign {
    position: fixed !important;
    top: 0 !important;
    left: 0 !important;
    right: 0 !important;
    bottom: 0 !important;
    width: 100vw !important;
    height: 100vh !important;
    max-width: 100vw !important;
    margin: 0 !important;
    padding: 2rem !important;
    overflow: auto !important;
    background: #f5f5f5 !important;
    z-index: 9999 !important;
    display: flex !important;
    align-items: center !important;
    justify-content: center !important;
    box-sizing: border-box !important;
}

/* Center the sign form container */
section.body-sign .center-sign {
    width: 100% !important;
    max-width: 450px !important;
    margin: 0 auto !important;
    flex-shrink: 0;
    flex-grow: 0;
}

/* Ensure Porto Admin styles work on auth pages */
.body-sign .panel.card-sign {
    background: #fff !important;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1) !important;
    width: 100% !important;
    max-width: 100% !important;
}

/* Override any Porto theme boxed layout constraints */
body.auth-page,
body.auth-page html {
    overflow-x: hidden !important;
}

/* Ensure viewport units work correctly */
body.auth-page {
    margin: 0 !important;
    padding: 0 !important;
}

/* Hide any headers, navbars, or top bars on auth pages */
body.auth-page header,
body.auth-page .header,
body.auth-page .navbar,
body.auth-page nav[class*="header"] {
    display: none !important;
}

/* Ensure the logo link doesn't float and is properly positioned */
body.auth-page .center-sign .logo {
    display: block !important;
    text-align: center !important;
    margin-bottom: 2rem !important;
    float: none !important;
}

