﻿/*!
 * ==========================================================
 *  AdminLTE Compact Azure Theme v1.0.0
 *  © 2025 SimfaniDigital — All rights reserved.
 *
 *  Description : Compact top-nav AdminLTE layout with
 *                Azure Blue color palette and fixed header/footer.
 *  Compatible  : AdminLTE 3.x / Bootstrap 4.x+
 *  Author      : Srini P.
 *  Date        : 2025-10-18
 * ==========================================================
 */


/* ==========================================================
   Compact Header & Footer + Full-Height Flex Layout
   (Azure Blue Color Theme)
   ========================================================== */

:root {
    --azure-primary: #0078D4; /* Azure Blue */
    --azure-hover: #106EBE; /* Darker hover blue */
    --azure-border: #D0E7F9; /* Light border tint */
    --azure-bg-light: #F8FAFC; /* Body light background */
    --azure-text: #0B0C0C; /* Neutral dark text */
}

/* --- General background overrides --- */
html, body {
    height: 100%;
    background-color: var(--azure-bg-light) !important;
    color: var(--azure-text);
}

body {
    background-color: var(--azure-bg-light) !important;
}

.content-wrapper {
    background-color: var(--azure-bg-light) !important;
}

/* --- Wrapper and flex layout adjustments --- */
.wrapper {
    min-height: 100dvh;
    display: flex;
    flex-direction: column;
}

/* Make content area fill viewport below header */
.content-wrapper {
    display: flex;
    flex-direction: column;
    flex: 1 1 auto;
    min-height: 0 !important;
    padding-bottom: 45px;
}

/* Ensure content fills the wrapper space */
.content {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
    padding-bottom: 0;
}

    .content > .container-fluid {
        flex: 1 1 auto;
        min-height: 0;
        display: flex;
        flex-direction: column;
    }

/* ==========================================================
   Compact NAVBAR / HEADER (layout-top-nav)
   ========================================================== */

.layout-top-nav .main-header.navbar {
    min-height: 42px !important;
    padding: 0 0.5rem !important;
    background-color: var(--azure-primary) !important;
    color: #fff !important;
    box-shadow: 0 1px 2px rgba(0,0,0,0.08);
}

.layout-top-nav .brand-link {
    height: 42px !important;
    line-height: 42px !important;
    padding: 0 10px !important;
    display: flex;
    align-items: center;
    color: #fff !important;
    font-weight: 600;
}

.layout-top-nav .brand-image {
    height: 28px !important;
    margin-top: -0.2rem !important;
    margin-right: .3rem !important;
    border-radius: 50%;
}

.layout-top-nav .navbar-nav > .nav-item > .nav-link {
    padding-top: 0.35rem !important;
    padding-bottom: 0.35rem !important;
    line-height: 1.2 !important;
    font-size: 0.95rem;
    color: #fff !important;
    transition: background-color 0.2s ease;
}

    .layout-top-nav .navbar-nav > .nav-item > .nav-link:hover {
        background-color: var(--azure-hover) !important;
    }

.layout-top-nav .navbar-toggler {
    padding: 0.15rem 0.4rem !important;
    font-size: 1rem !important;
    color: #fff !important;
    border: none;
}

.layout-top-nav .navbar-nav .dropdown-menu {
    margin-top: 0.4rem !important;
    border-radius: 8px;
    border: 1px solid var(--azure-border);
}

/* Align content with reduced navbar height */
.layout-top-nav.layout-navbar-fixed .wrapper .content-wrapper {
    padding-top: 42px !important;
}

/* Slightly taller on mobile for touch targets */
@media (max-width: 575.98px) {
    .layout-top-nav .main-header.navbar {
        min-height: 46px !important;
    }

    .layout-top-nav.layout-navbar-fixed .wrapper .content-wrapper {
        padding-top: 46px !important;
    }
}

/* ==========================================================
   Compact FOOTER (fixed)
   ========================================================== */

.main-footer {
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 36px;
    line-height: 36px;
    padding: 0 20px;
    background: #fff;
    border-top: 2px solid var(--azure-primary);
    z-index: 1030;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 0.9rem;
    color: var(--azure-text);
}

.layout-top-nav.layout-footer-fixed .wrapper .content-wrapper {
    padding-bottom: 36px !important;
}

/* ==========================================================
   Equal-height row & card helpers
   ========================================================== */
.row.equal-height {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
}

    .row.equal-height > [class*="col-"] {
        display: flex;
        min-height: 0;
    }

section.connectedSortable {
    display: flex;
    flex-direction: column;
    min-height: 0;
}

.row.equal-height .card {
    flex: 1 1 auto;
    min-height: 0;
    display: flex;
    flex-direction: column;
}

.row.equal-height .card-body {
    flex: 1 1 auto;
    min-height: 0;
    overflow: auto;
}

/* ==========================================================
   Utilities
   ========================================================== */
.hidden {
    display: none !important;
}

/* Footer link colors */
.main-footer strong a {
    color: var(--azure-primary);
    text-decoration: none;
}

    .main-footer strong a:hover {
        color: var(--azure-hover);
        text-decoration: underline;
    }

/* ==========================================================
   Navbar alignment & spacing fixes
   ========================================================== */
.layout-top-nav .main-header.navbar .navbar-nav > .nav-item > .nav-link {
    display: flex;
    align-items: center;
    height: 42px;
    padding-top: 0 !important;
    padding-bottom: 0 !important;
    line-height: 1 !important;
}

.layout-top-nav .main-header.navbar .navbar-brand,
.layout-top-nav .main-header.navbar .navbar-toggler {
    display: flex;
    align-items: center;
    height: 42px;
}

/* ==========================================================
   White space and final alignment fixes
   ========================================================== */
.layout-top-nav.layout-navbar-fixed .wrapper .content-wrapper {
    padding-top: 0 !important;
    margin-top: 44px !important;
}

.content,
.content > .container-fluid {
    margin-top: 0 !important;
    padding-top: 0 !important;
}

.content-wrapper {
    background-color: var(--azure-bg-light) !important;
}

    .content-wrapper > .content,
    .content-wrapper > .content-header {
        margin-top: 0 !important;
        padding-top: 0 !important;
    }

.content-header {
    background: transparent !important;
    padding-top: 0.25rem !important;
    padding-bottom: 0.25rem !important;
}

.content > .container-fluid > h1,
.content > .container-fluid > .page-title {
    margin-top: 0.5rem !important;
}

/* Hide toggler on desktop (≥ 768px) */
@media (min-width: 768px) {
    .layout-top-nav .main-header .navbar-toggler {
        display: none !important;
    }
}

/* Show toggler on mobile (< 768px) */
@media (max-width: 767.98px) {
    .layout-top-nav .main-header .navbar-toggler {
        display: flex !important;
        align-items: center;
        height: 44px;
        padding: 0.15rem 0.4rem !important;
        font-size: 1rem !important;
    }
}
