/* /templates/cassiopeia/css/user.css */
@import url('https://fonts.googleapis.com/css2?family=Inter:wght=300;400;500;600;700;800;900&display=swap');

/* 1. DEFINE GLOBAL SYSTEM VARIABLES */
:root {
    --body-bg: transparent !important;   /* Force structural transparency so parallax image peeks through */
    --card-bg: #1e293b !important;      /* Slate 800 Block Modules */
    --text-primary: #f8fafc !important;  /* High Contrast Off-White */
    --text-muted: #94a3b8 !important;    /* Clean Slate Gray */
    --colour-primary: #dc2626 !important; /* Crimson Accent Red */
    --colour-border: #334155 !important;
    --font-family-sans-serif: 'Inter', system-ui, -apple-system, sans-serif !important;
    --cassiopeia-font-family-headings: 'Inter', system-ui, -apple-system, sans-serif !important;
    --cassiopeia-font-weight-headings: 800 !important;
}

/* ==========================================================================
   2. RE-ANCHOR FIXED BACKGROUND LAYER & REMOVE OVERLAY BLOCKS
   ========================================================================== */

/* Force the base layers to be perfectly transparent */
html, 
body, 
body.site, 
.site-placeholder, 
.bodywrap, 
#top,
.grid-fluid,
main {
    background: transparent !important;
    background-color: transparent !important;
}

/* 🎯 THE ACCELERATED BACKDROP FIX: Target the root site wrapper element */
.site-placeholder::before, 
body.site::before {
    content: "";
    position: fixed; /* Locks the backdrop securely to the glass viewport viewport */
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: -9999 !important; /* Send it back past all components */
    
    /* 🎯 ROOT PATH ABSOLUTE CALL: Pulls straight from domain root /images/ bypassing folder nest logic */
    background-image: 00700080;
    background: linear-gradient(to bottom, rgba(15, 42, 16, 0.82) 0%, rgba(15, 42, 16, 0.82) 50%, rgba(15, 42, 16, 0.82) 100%), url('/images/isfl_primarybg.webp') !important;
    
    background-size: cover !important;
    background-position: center center !important;
    background-repeat: no-repeat !important;
    background-attachment: scroll !important; /* Pinned via 'fixed' position instead to protect mobile processors */
    
    will-change: transform;
}

/* ==========================================================================
   3. GENERALIZED SYSTEM MODULE TILES & TEXT HANDLING
   ========================================================================== */

.card, .module, .well, .sidebar .card, [class*="mod-"], .login-wrap, #login-form {
 /*   background-color: #1e293b !important; */
    color: #f8fafc !important;
    border: 0px none transparent !important;
    border-radius: 12px !important;
}

.mod-login-logout__button { margin-top: 14px; }

label, .form-label, .form-check-label, .card-title, .module-title, h1, h2, h3, h4, h5, h6, .text-muted, p, header p {
    color: #f8fafc !important;
    font-weight: 600;
}
p.text-muted, .text-white-50, .card-text {
    color: #94a3b8 !important;
    font-weight: 400 !important;
}

/* Login inputs */
input.form-control, input, select, textarea {
    background-color: #0f172a !important;
    color: #ffffff !important;
    border: 1px solid #334155 !important;
}
input.form-control:focus {
    border-color: #dc2626 !important;
    box-shadow: 0 0 0 0.25rem rgba(220, 38, 36, 0.25) !important;
}

/* Links */
.nav-link, .menu a, .mod-menu a { color: #94a3b8 !important; font-weight: 600 !important; }
.nav-link:hover, .menu a:hover, .mod-menu a:hover { color: #ffffff !important; }
.active > .nav-link, .current > a {
    color: #ffffff !important;
    background-color: rgba(220, 38, 36, 0.2) !important;
    border-left: 4px solid #dc2626 !important;
    padding-left: 4px;
}
.mod-login a, form a, .small-text a { color: #94a3b8 !important; text-decoration: underline !important; }
.mod-login a:hover, form a:hover { color: #ffffff !important; }

/* ==========================================================================
   4. MODULAR TOP LINK MENU NAVIGATION TRACK
   ========================================================================== */

.container-nav, .navbar {
    background-color: #1e293b !important;
    padding: 0.5rem 1rem !important;
    border-radius: 12px !important;
    margin-bottom: 1.5rem !important;
}
.navbar-nav .nav-link, .container-nav .nav-link, .menu.nav-pills .nav-link {
    color: var(--text-muted) !important;
    font-weight: 600 !important;
    font-size: 0.95rem !important;
    padding: 0.5rem 1.25rem !important;
    margin: 0 0.25rem;
    border-radius: 8px !important;
    transition: all 0.2s ease-in-out !important;
}
.navbar-nav .nav-link:hover, .container-nav .nav-link:hover, .menu.nav-pills .nav-link:hover {
    color: #ffffff !important;
    background-color: rgba(255, 255, 255, 0.05) !important;
}
.navbar-nav .active > .nav-link, .container-nav .active > .nav-link, .menu.nav-pills .active > .nav-link, .navbar-nav .current > a, .menu.nav-pills .current > a {
    color: #ffffff !important;
    background-color: #dc2626 !important;
    box-shadow: 0 4px 12px rgba(220, 38, 38, 0.3) !important;
}
@media (min-width: 992px) { .mod-menu, .menu { display: flex !important; flex-direction: row !important; align-items: center !important; } }
.navbar-toggler { border: 0px none transparent !important; background-color: rgba(255,255,255,0.05) !important; padding: 0.5rem !important; }
.navbar-toggler-icon { filter: invert(1) grayscale(1) brightness(2); }

/* Transparent Core Header Container formatting */
header.header, .header {
    background: transparent !important;
    max-width: 1200px !important;
    margin: 0 auto !important;
    padding: 2rem 1rem !important;
    border: 0px none transparent !important;
    box-shadow: none !important;
}
header.header .brand-title a, header.header .site-title {
    font-size: 2.25rem !important;
    font-weight: 900 !important;
    letter-spacing: -0.03em !important;
    text-transform: uppercase !important;
    color: #ffffff !important;
    text-shadow: 0 4px 16px rgba(0, 0, 0, 0.9) !important;
}

.mod-custom .custom {
  background-color:none;
  text-align:right;
}

.btn-isfl-signin {
  
}

/* ==========================================================================
   5. NATIVE SLOGAN EMBED CODE (MATCHING ENCLOSED GRAPHIC LOOK)
   ========================================================================== */

.isfl-slogan-container {
    display: inline-block;
    position: relative;
    padding: 0.75rem 2rem;
    margin-top: 1rem;
    border-left: 3px solid #dc2626 !important;
    border-right: 3px solid #dc2626 !important;
    background: rgba(30, 41, 59, 0.45); 
    border-radius: 6px;
    white-space: nowrap;
}
.isfl-slogan-container::before, .isfl-slogan-container::after {
    content: ""; position: absolute; width: 15px; height: 3px; background-color: #dc2626;
}
.isfl-slogan-container::before { top: 0; left: 0; }
.isfl-slogan-container::after { bottom: 0; right: 0; }

.isfl-slogan-container .slogan-top {
    display: block; font-size: 1.1rem !important; font-weight: 500 !important; color: #ffffff !important; letter-spacing: 0.05em; line-height: 1.2;
}
.isfl-slogan-container .slogan-main {
    display: block; font-family: 'Inter', sans-serif !important; font-size: 2.25rem !important; font-weight: 900 !important; color: #dc2626 !important; text-transform: uppercase !important; letter-spacing: -0.02em !important; line-height: 1.1; margin: 0.15rem 0 !important; text-shadow: 0 2px 4px rgba(0, 0, 0, 0.5);
}
.isfl-slogan-container .slogan-bottom {
    display: block; font-size: 1.4rem !important; font-weight: 700 !important; color: #ffffff !important; text-align: right; letter-spacing: -0.01em; line-height: 1.2;
}

/* ==========================================================================
   FINAL MOBILE VIEWPORT DESIGN FIXES (MAX-WIDTH: 768px)
   ========================================================================== */

@media (max-width: 425px) {
    /* 1. Prevent any element from breaking the screen bounds */
    html, body {
        max-width: 100% !important;
        overflow-x: hidden !important;
        width: 100% !important;
    }

    /* 2. OPTIMIZED MOBILE BACKGROUND SCALING
       Shifts position and forces containment so the graphic elements fit a narrow screen */
    body::before,
    .site-placeholder::before {
        width: 100% !important;
        height: 100vh !important;
        background-image: 
            linear-gradient(to bottom, rgba(15, 23, 42, 0.7) 0%, rgba(15, 23, 42, 0.4) 100%), 
            url('/images/isfl_primarybg.webp') !important;
        
        /* Pulls the main graphic detail down into the phone view */
        background-position: left top !important; 
        background-size: cover !important;
    }

    /* 3. CRITICAL TEXT RE-WRAP SHIELD
       Forces the long header text link to drop down onto multiple lines elegantly */
    header.header .brand-title a, 
    header.header .site-title,
    .navbar-brand,
    h1, h2 {
        font-size: 1.8rem !important; /* Balanced size for mobile reading */
        line-height: 1.2 !important;
        white-space: normal !important; /* Breaks Joomla's rigid single-line rule */
        display: block !important;
        width: 100% !important;
        word-wrap: break-word !important;
        overflow-wrap: break-word !important;
    }
    
    header.header .brand-title {
        width: 100% !important;
        display: block !important;
    }

    /* 4. Fix the navigation bar row spacing on mobile */
    .container-nav, .navbar {
        margin: 0.5rem !important;
        padding: 0.5rem !important;
        width: auto !important;
    }
}

@media (min-width: 992px) {
  .com-users-login.login {
    width:30%;
  }
  .com-users-login .com-users-login__form fieldset {
    padding: 1.5rem !important;
    border: 1px solid var(--colour-border) !important;
    display: flex;
    flex-direction: column;
    gap: 1rem;
  }
}

/* ==========================================================================
   DEDICATED LOGIN PAGE PORTAL ALIGNMENT (COMPLETE CARD CONTAINMENT)
   ========================================================================== */

/* 1. Target the master container box and turn it into the single primary layout card */
.com-users-login.login {
    display: block !important;
    max-width: 460px !important;            /* Tight desktop layout focus width */
    margin: 0rem auto !important;          /* Centers it perfectly on the screen with upper breathing room */
    padding: 2.5rem 2rem !important;       /* Shifts the card padding to wrap EVERYTHING */
    background-color: #1e293b !important;  /* Your theme's Slate 800 box color */
    border: 1px solid #334155 !important;  /* Clean border layout edge */
    border-radius: 16px !important;        /* Elegant modern rounded corner curve */
    box-shadow: 0 20px 25px -5px rgba(0, 0, 0, 0.5), 
                0 10px 10px -5px rgba(0, 0, 0, 0.5) !important; /* Premium drop shadow depth */
}

/* 2. Strip background, borders, and shadows completely from the form element */
#com-users-login__form {
    width: 100% !important;
    background: transparent !important;
    background-color: transparent !important;
    border: 0px none transparent !important;
    box-shadow: none !important;
    padding: 0 !important;
    margin: 0 !important;
}

/* 3. Strip structural backgrounds and borders completely from the nested fieldset */
#com-users-login__form fieldset {
    background: transparent !important;
    background-color: transparent !important;
    border: 0px none transparent !important;
    padding: 0 !important;
    margin: 0 !important;
    box-shadow: none !important;
}

/* 4. Format layout row margins for the input fields */
#com-users-login__form .control-group {
  /*  margin-bottom: 1.25rem !important; */
}

/* 5. Stretch the log-in action execution button across the layout card */
.com-users-login__submit.control-group {
  /*  margin-top: 1.75rem !important; */
    margin-bottom: 0rem !important; /* Flatten bottom margin to keep card balanced */
}
.com-users-login__submit.control-group button {
    width: 100% !important;
    padding: 0.75rem !important;
    font-weight: 700 !important;
}

/* 6. Securely style the recovery links box inside the base card frame */
.com-users-login.login ul {
    list-style: none !important;
    padding: 0 !important;
    margin: 1.5rem 0 0 0 !important; /* Comfortable distance below the crimson action button */
    width: 100% !important;
    text-align: center !important;
    display: flex !important;
    flex-direction: column !important;
    gap: 0.5rem !important;
    border-top: 1px solid #334155 !important; /* Subtle inner divider line */
    padding-top: 1.25rem !important;
}

/* Clear list bullet boxes and custom padding rules */
.com-users-login.login ul li {
    background: transparent !important;
    border: 0px none transparent !important;
    padding: 0 !important;
    margin: 0 !important;
}
.com-users-login.login ul li a {
    color: #94a3b8 !important; /* Visible clean light slate gray */
    font-size: 0.9rem !important;
    font-weight: 500 !important;
    text-decoration: none !important;
    transition: color 0.2s ease !important;
}
.com-users-login.login ul li a:hover {
    color: #ffffff !important; /* Pure white highlight hover */
    text-decoration: underline !important;
}
.com-users-login__reset.list-group-item {
  border:none;
  color:#ffffff;
  padding:0em;
  padding-bottom:1em;
}
.com-users-login__remind.list-group-item {
  border:none;
  color:#ffffff;
  padding:0em;
}

/* ==========================================================================
   SAFETY SHIELD: RECONSTRUCT GHOST HEADER DELETIONS ON THIS VIEWPORT
   ========================================================================== */
.com-users-login.login h1,
.com-users-login.login .page-header {
    display: none !important; /* Forcefully eliminates "Home page" headings on this specific viewport screen */
}