/* =========================================================
   FLID UI theme — AdminLTE-compatible polish
   Brand accent: teal (#0a5b68) kept from existing app
   ========================================================= */

:root {
    --flid-primary: #0a5b68;
    --flid-primary-dark: #074851;
    --flid-primary-soft: #e6f3f5;
    --flid-success: #1f7a4d;
    --flid-success-soft: #e8f6ef;
    --flid-info: #1a6f8a;
    --flid-muted: #5c6b73;
    --flid-text: #1f2a30;
    --flid-border: #d8e0e4;
    --flid-surface: #ffffff;
    --flid-bg: #eef2f4;
    --flid-radius: 8px;
    --flid-shadow: 0 1px 3px rgba(20, 40, 50, 0.08);
    --flid-shadow-md: 0 6px 18px rgba(20, 40, 50, 0.08);
    --flid-focus: 0 0 0 0.2rem rgba(10, 91, 104, 0.22);
    --flid-font: "Source Sans Pro", "Noto Sans Bengali", system-ui, -apple-system, sans-serif;
}

html {
    scroll-behavior: smooth;
}

body {
    font-family: var(--flid-font);
    color: var(--flid-text);
    background-color: var(--flid-bg);
    font-size: 15px;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
}

a {
    color: var(--flid-primary);
}

a:hover {
    color: var(--flid-primary-dark);
}

/* ---------- Layout shell ---------- */
.content-wrapper {
    background-color: var(--flid-bg) !important;
}

.content-header {
    padding: 1.1rem 0.5rem 0.4rem;
}

.content-header h1.header,
.content-header h1,
.page-title {
    font-size: 1.45rem;
    font-weight: 700;
    color: var(--flid-text);
    letter-spacing: 0.01em;
    margin-bottom: 0.25rem;
}

.content-header .breadcrumb {
    background: transparent;
    padding: 0.25rem 0;
    margin: 0;
    font-size: 0.875rem;
}

.content-header .breadcrumb-item + .breadcrumb-item::before {
    color: #9aa7ae;
}

.content-header .breadcrumb a {
    color: var(--flid-primary);
}

.brand-hero {
    position: relative;
    text-align: center;
    padding: 0.75rem 0.5rem 1rem;
}

.brand-hero .brand-seal,
.brand-hero img.brand-seal,
.brand-hero img {
    display: block;
    width: 110px;
    height: 110px;
    max-width: 110px;
    margin: 0 auto;
    object-fit: contain;
    border-radius: 0;
    background: transparent;
}

.brand-hero .org-title {
    color: #1f7a4d;
    font-weight: 700;
    font-size: clamp(1.2rem, 2.4vw, 1.55rem);
    margin: 0.75rem 0 0.2rem;
    line-height: 1.4;
}

.brand-hero .org-subtitle {
    color: #248c24;
    font-weight: 700;
    font-size: clamp(1rem, 2vw, 1.15rem);
    margin: 0.15rem 0;
    line-height: 1.4;
}

.brand-hero .org-tagline {
    color: #1a5fb4;
    font-weight: 600;
    font-size: clamp(0.92rem, 1.8vw, 1.05rem);
    margin: 0.65rem auto 0;
    max-width: 46rem;
    line-height: 1.5;
}

.brand-hero--public {
    padding-top: 0.35rem;
}

.brand-hero--public .public-top-actions {
    position: absolute;
    top: 0;
    right: 0;
    width: auto;
    margin: 0;
    z-index: 3;
}

/* ---------- Sidebar ---------- */
[class*=sidebar-dark-] {
    background: linear-gradient(180deg, rgba(7, 40, 48, 0.92), rgba(7, 40, 48, 0.88)),
        url('../../dashboard/img/bg.jpg') center top / cover no-repeat !important;
}

.main-sidebar {
    box-shadow: 2px 0 12px rgba(0, 0, 0, 0.12);
}

.main-sidebar .brand-link {
    display: flex !important;
    align-items: center;
    justify-content: flex-start;
    gap: 0.55rem;
    height: auto !important;
    min-height: 57px;
    padding: 0.7rem 0.85rem !important;
    background: rgba(0, 0, 0, 0.45) !important;
    border-bottom: 1px solid rgba(255, 255, 255, 0.08) !important;
    overflow: hidden;
}

.main-sidebar .brand-link .brand-image {
    float: none !important;
    display: block;
    width: 40px !important;
    height: 40px !important;
    max-height: 40px !important;
    max-width: 40px !important;
    margin: 0 !important;
    object-fit: contain !important;
    border-radius: 0 !important;
    opacity: 1 !important;
    flex-shrink: 0;
    background: transparent;
    padding: 0;
    box-sizing: border-box;
}

.main-sidebar .brand-link .brand-text {
    float: none !important;
    display: inline-block;
    font-family: "Odibee Sans", "Source Sans Pro", sans-serif;
    font-size: 1.65rem !important;
    line-height: 1 !important;
    letter-spacing: 0.06em;
    color: #fff !important;
    font-weight: 400 !important;
    margin: 0 !important;
    white-space: nowrap;
}

.user-panel {
    border-bottom: 1px solid rgba(255, 255, 255, 0.1) !important;
    padding-bottom: 0.85rem !important;
}

.user-panel .image img {
    width: 2.2rem;
    height: 2.2rem;
    object-fit: cover;
    border-radius: 50%;
    border: 2px solid rgba(255, 255, 255, 0.25);
}

.user-panel .info a {
    color: #f2f7f8 !important;
    font-weight: 600;
    font-size: 0.95rem;
}

.nav-sidebar .nav-link {
    border-radius: 6px !important;
    margin: 0.15rem 0.45rem;
    color: rgba(255, 255, 255, 0.88) !important;
    transition: background-color 0.15s ease, color 0.15s ease;
}

.nav-sidebar .nav-link:hover {
    background: rgba(255, 255, 255, 0.1) !important;
    color: #fff !important;
}

.nav-sidebar .nav-link p {
    margin: 0;
}

.sidebar-dark-primary .nav-sidebar > .nav-item > .nav-link.active,
.sidebar-light-primary .nav-sidebar > .nav-item > .nav-link.active,
.nav-sidebar .nav-treeview > .nav-item > .nav-link.active {
    background-color: var(--flid-primary) !important;
    color: #fff !important;
    box-shadow: inset 0 0 0 1px rgba(255, 255, 255, 0.08);
}

.nav-sidebar .nav-icon {
    width: 1.4rem;
    text-align: center;
    margin-right: 0.35rem;
}

/* ---------- Header ---------- */
.main-header.navbar {
    border-bottom: 1px solid var(--flid-border);
    box-shadow: var(--flid-shadow);
    min-height: 56px;
}

.main-header .nav-link {
    color: var(--flid-muted) !important;
}

.main-header .nav-link:hover,
.main-header .nav-link:focus {
    color: var(--flid-primary) !important;
}

.navbar-logout {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.4rem 0.85rem;
    margin-right: 0.35rem;
    border-radius: 6px;
    border: 1px solid var(--flid-border);
    background: #fff;
    color: var(--flid-text) !important;
    font-weight: 600;
    font-size: 0.9rem;
    text-decoration: none !important;
    transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.navbar-logout:hover,
.navbar-logout:focus {
    background: var(--flid-primary-soft);
    border-color: #b7d4d9;
    color: var(--flid-primary-dark) !important;
    outline: none;
}

.navbar-logout:focus-visible {
    box-shadow: var(--flid-focus);
}

/* ---------- Cards / content ---------- */
.card {
    border: 1px solid var(--flid-border);
    border-radius: var(--flid-radius);
    box-shadow: var(--flid-shadow);
    background: var(--flid-surface);
}

.card-header {
    background: #f8fafb;
    border-bottom: 1px solid var(--flid-border);
    padding: 0.85rem 1.1rem;
    border-top-left-radius: var(--flid-radius);
    border-top-right-radius: var(--flid-radius);
}

.card-body {
    padding: 1.15rem 1.2rem;
}

.card-header .actions .btn.create-new,
.actions .btn.create-new {
    background: var(--flid-primary);
    border-color: var(--flid-primary);
    color: #fff;
    font-weight: 600;
    border-radius: 6px;
    padding: 0.4rem 0.9rem;
    box-shadow: none;
}

.card-header .actions .btn.create-new:hover,
.actions .btn.create-new:hover {
    background: var(--flid-primary-dark);
    border-color: var(--flid-primary-dark);
    color: #fff;
}

.card-header .actions .btn.create-new:focus-visible,
.actions .btn.create-new:focus-visible {
    box-shadow: var(--flid-focus);
}

/* ---------- Forms ---------- */
.form-group {
    margin-bottom: 1rem;
}

.form-group label.control-label {
    text-align: right;
    font-weight: 600;
    color: #334148;
    padding-top: 0.55rem;
}

.form-control {
    border-radius: 6px;
    border-color: #c9d4d9;
    min-height: calc(1.5em + 0.85rem + 2px);
    color: var(--flid-text);
}

.form-control:focus {
    border-color: #4f9aa5;
    box-shadow: var(--flid-focus);
}

.form-control::placeholder {
    color: #8a9aa3;
}

.text-danger {
    color: #c0392b !important;
    font-size: 0.875rem;
}

.select2-selection {
    height: 40px !important;
    border-radius: 6px !important;
    border-color: #c9d4d9 !important;
}

.select2-container--default .select2-selection--single .select2-selection__rendered {
    line-height: 38px !important;
    padding-left: 12px;
}

.select2-container--default .select2-selection--single .select2-selection__arrow {
    height: 38px !important;
}

.select2-container--default .select2-selection--single .select2-selection__arrow b {
    margin-top: 5px;
}

.select2-container--default.select2-container--focus .select2-selection--single,
.select2-container--default.select2-container--open .select2-selection--single {
    border-color: #4f9aa5 !important;
    box-shadow: var(--flid-focus);
}

.select2-results__options::-webkit-scrollbar {
    width: 8px;
}

.select2-results__options::-webkit-scrollbar-track {
    -webkit-box-shadow: inset 0 0 3px rgba(0, 0, 0, 0.3);
    border-radius: 5px;
}

.select2-results__options::-webkit-scrollbar-thumb {
    border-radius: 5px;
    -webkit-box-shadow: inset 0 0 3px rgba(0, 0, 0, 0.5);
}

.btn {
    border-radius: 6px;
    font-weight: 600;
}

.btn:focus-visible {
    outline: none;
    box-shadow: var(--flid-focus);
}

.btn-primary {
    background-color: var(--flid-primary);
    border-color: var(--flid-primary);
}

.btn-primary:hover,
.btn-primary:focus {
    background-color: var(--flid-primary-dark);
    border-color: var(--flid-primary-dark);
}

.btn-default {
    background: #fff;
    border-color: var(--flid-border);
    color: var(--flid-text);
}

.btn-xs.btn-icon-only,
.btn-sm.btn-icon-only {
    min-width: 2rem;
    padding: 0.28rem 0.5rem;
    line-height: 1.2;
}

.deleteForm {
    display: inline-flex;
    align-items: center;
    gap: 0.25rem;
    margin: 0;
}

/* ---------- Tables ---------- */
.table-responsive {
    width: 100%;
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
}

.table {
    margin-bottom: 0;
    color: var(--flid-text);
}

.table thead th,
thead {
    background: var(--flid-primary) !important;
    color: #ffffff !important;
    border-color: var(--flid-primary-dark) !important;
    font-weight: 600;
    font-size: 0.9rem;
    white-space: nowrap;
    vertical-align: middle;
}

.table-bordered {
    border-color: var(--flid-border);
}

.table-bordered td,
.table-bordered th {
    border-color: #e3eaed;
}

.table-striped tbody tr:nth-of-type(odd) {
    background-color: #f7fafb;
}

.table tbody tr:hover {
    background-color: var(--flid-primary-soft);
}

.table td,
.table th {
    padding: 0.7rem 0.75rem;
    vertical-align: middle;
}

#userTabel.table td,
#userTabel.table th {
    padding: 0.65rem 0.7rem !important;
}

.tableFixHead {
    overflow-y: auto;
    height: 50px;
}

.tableFixHead table {
    border-collapse: collapse;
    width: 100%;
}

.tableFixHead th,
.tableFixHead td {
    padding: 8px 16px;
}

.tableFixHead th {
    background: #eee;
}

#userTabel_wrapper div.row div.col-md-6:first-child {
    display: none;
}

#userTabel_wrapper ul.pagination {
    float: right;
}

/* ---------- Dashboard metric boxes ---------- */
.small-box {
    border-radius: var(--flid-radius);
    box-shadow: var(--flid-shadow);
    overflow: hidden;
}

.small-box .inner {
    padding: 1rem 1.1rem !important;
}

.small-box h3 {
    font-weight: 700;
    font-size: 2rem;
}

.small-box p {
    font-size: 0.95rem;
    margin-bottom: 0.35rem;
}

.small-box .small-box-footer {
    background: rgba(0, 0, 0, 0.08);
    font-weight: 600;
}

.small-box.bg-info {
    background-color: var(--flid-info) !important;
}

.small-box.bg-success {
    background-color: var(--flid-success) !important;
}

.small-box.bg-secondary {
    background-color: #5f6f78 !important;
}

.section-heading {
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--flid-text);
    margin: 1rem 0 0.85rem;
    padding-bottom: 0.35rem;
    border-bottom: 2px solid var(--flid-primary-soft);
}

/* ---------- Alerts ---------- */
.alert {
    border-radius: 6px;
    border: none;
    box-shadow: var(--flid-shadow);
}

.alert-success {
    background: var(--flid-success-soft);
    color: #145a38;
}

.alert-danger {
    background: #fdecea;
    color: #8a1f18;
}

/* ---------- Pagination / misc ---------- */
.page-item.active .page-link {
    background-color: var(--flid-primary);
    border-color: var(--flid-primary);
}

.page-link {
    color: var(--flid-primary);
}

.page-link:focus {
    box-shadow: var(--flid-focus);
}

.filter-submit {
    max-width: 250px;
}

.cz-paginator ul {
    float: right;
}

.lang-en,
.lang-bn {
    color: #6c757d;
}

.width-100p {
    width: 100%;
}

.bg-head {
    background: #F4F6F9 !important;
}

.abstruct-label {
    position: relative;
    margin-top: -35px;
    top: 10px;
}

.note-editor.card {
    margin-bottom: 0;
}

.note-toolbar div.note-btn-group .note-btn {
    font-size: 8px;
}

.bootstrap-switch .bootstrap-switch-handle-off,
.bootstrap-switch .bootstrap-switch-handle-on,
.bootstrap-switch .bootstrap-switch-label {
    padding: 9px 24px;
}

.d-slide-img {
    width: 80px;
    max-height: 80px;
}

.mv-border::after {
    content: '';
    position: absolute;
    height: calc(100% - 25px);
    width: 1px;
    left: calc(50% + 0px);
    box-shadow: 0 0 5px 1px #cccccc;
    top: 25px;
}

.public-shell {
    background: var(--flid-bg);
    min-height: 100vh;
    padding: 1.25rem 0 2rem;
}

.public-shell .container {
    max-width: 1140px;
}

.public-top-actions {
    display: flex;
    justify-content: flex-end;
    align-items: center;
}

.public-top-actions .btn.create-new {
    min-width: 5.5rem;
}

/* ---------- Login polish ---------- */
body.login-page {
    margin: 0;
    background: transparent !important;
    color: #fff;
}

body.login-page a {
    color: #8fdef0;
}

.login-shell {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 1.5rem 1rem;
    background: linear-gradient(160deg, rgba(7, 40, 48, 0.72), rgba(10, 91, 104, 0.55)),
        url('../../dashboard/img/bg.jpg') center / cover no-repeat fixed;
}

.login-shell .login-form {
    width: 100%;
    max-width: 400px;
    margin: 0 auto;
    border: 1px solid rgba(255, 255, 255, 0.14) !important;
    background: rgba(12, 28, 34, 0.78) !important;
    backdrop-filter: blur(10px);
    border-radius: 14px !important;
    box-shadow: 0 18px 44px rgba(0, 0, 0, 0.32);
    padding: 1.5rem 1.35rem 1.5rem;
}

.login-brand {
    text-align: center;
    margin-bottom: 0.85rem;
}

.login-brand-mark {
    display: block;
    width: 110px !important;
    height: 110px !important;
    max-width: 110px !important;
    margin: 0 auto 0.85rem;
    object-fit: contain;
    border-radius: 0;
    background: transparent;
    padding: 0;
    box-sizing: border-box;
    box-shadow: none;
}

.login-shell .login-page-title {
    font-family: "Odibee Sans", "Source Sans Pro", sans-serif;
    font-size: 2.5rem;
    line-height: 1;
    color: #ffffff;
    font-weight: 400;
    letter-spacing: 0.14em;
}

.login-shell .login-wrap {
    padding: 0.35rem 0 0;
}

.login-shell .login-form .input-group {
    margin-bottom: 0.85rem;
    padding-bottom: 0 !important;
}

.login-shell .login-btn {
    background-color: var(--flid-primary) !important;
    border: 1px solid var(--flid-primary) !important;
    color: #fff !important;
    font-weight: 700;
    border-radius: 6px;
    margin-top: 0.35rem;
    min-height: 44px;
}

.login-shell .login-btn:hover,
.login-shell .login-btn:focus {
    background-color: var(--flid-primary-dark) !important;
    border-color: var(--flid-primary-dark) !important;
    color: #fff !important;
}

.login-shell input.form-control,
.login-shell .login-form input[type="text"],
.login-shell .login-form input[type="password"] {
    background-color: rgba(255, 255, 255, 0.1) !important;
    border: 1px solid rgba(255, 255, 255, 0.25) !important;
    color: #fff !important;
    min-height: 44px;
    box-shadow: none !important;
}

.login-shell input.form-control::placeholder {
    color: rgba(255, 255, 255, 0.65);
}

.login-shell input.form-control:focus {
    background-color: rgba(255, 255, 255, 0.14) !important;
    border-color: #7ec4cf !important;
    box-shadow: var(--flid-focus) !important;
    color: #fff !important;
}

.login-shell .login-form .input-group-addon {
    background-color: rgba(255, 255, 255, 0.14) !important;
    border-color: rgba(255, 255, 255, 0.25) !important;
    color: #fff !important;
    min-width: 42px;
}

.login-field-error {
    color: #ffb4a8;
    font-size: 0.875rem;
    font-weight: 600;
    margin: -0.45rem 0 0.75rem;
}

.login-shell .register-link {
    margin-top: 0.95rem;
    color: #e8eef0;
    text-align: center;
}

.login-shell .register-link a {
    color: #8fdef0 !important;
    font-weight: 600;
}

.login-shell .invalid-feedback,
.login-shell .text-danger {
    color: #ffb4a8 !important;
}

/* ---------- Responsive ---------- */
@media only screen and (max-width: 991.98px) {
    .content-header .row.mb-2 {
        flex-direction: column;
    }

    .content-header .breadcrumb {
        float: none !important;
        margin-top: 0.35rem;
    }

    .brand-hero .brand-seal,
    .brand-hero img.brand-seal,
    .brand-hero img {
        width: 96px;
        height: 96px;
        max-width: 96px;
    }

    .brand-hero--public {
        padding-top: 2.5rem;
    }

    .brand-hero--public .public-top-actions {
        top: 0.15rem;
        right: 0.15rem;
    }
}

@media only screen and (max-width: 768px) {
    .form-group label.control-label {
        text-align: left;
        margin-bottom: 0.35rem;
    }

    .mv-border::after {
        display: none;
    }

    .content-header h1.header,
    .content-header h1 {
        font-size: 1.25rem;
        text-align: left !important;
    }

    .card-header .actions {
        width: 100%;
    }

    .card-header .actions .btn.create-new {
        width: 100%;
        text-align: center;
    }

    .navbar-logout span {
        display: none;
    }
}
