﻿/* ==================================================
   BusinessOS - Site Styles
   ================================================== */

/* Base styles */
:root {
    --bs-border-color: #c0c7ce !important;
    --bs-nav-tabs-border-color: #c0c7ce !important;
}
html {
    font-size: 14px;
}

@media (min-width: 768px) {
    html {
        font-size: 12px;

    }
}
.kpi-label {
    font-size: 14px;
}
.login-form .form-control, .form-control, .input-group:not(.has-validation) > .dropdown-toggle:nth-last-child(n+3), .input-group:not(.has-validation) > .form-floating:not(:last-child) > .form-control, .input-group:not(.has-validation) > .form-floating:not(:last-child) > .form-select, .input-group:not(.has-validation) > :not(:last-child):not(.dropdown-toggle):not(.dropdown-menu):not(.form-floating) {
    padding: 8px 16px !important;
    border: 1px solid #D0D7DE !important;
    border-radius: 4px;
}
.input-group > :not(:first-child):not(.dropdown-menu):not(.valid-tooltip):not(.valid-feedback):not(.invalid-tooltip):not(.invalid-feedback) {
    border: 1px solid #D0D7DE;
}
body {
    font-family: var(--bos-font-family);
    background-color: var(--bos-bg-secondary);
    color: var(--bos-text-primary);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    font-size: 14px;
    overflow-x:hidden;
}

/* Focus styles */
.btn:focus, 
.btn:active:focus, 
.btn-link.nav-link:focus, 
.form-control:focus, 
.form-check-input:focus {
    box-shadow:none !important;
}

/* Page background */
body {
    position: relative;
    min-height: 100vh;
}

/* Card Styles */
.card {
    border: 1px solid var(--bos-border-color);
    border-radius: var(--bos-border-radius-lg);
    box-shadow: var(--bos-shadow);
    transition: var(--bos-transition);
}

.card-header {
    background-color: var(--bos-bg-primary);
    border-bottom: 1px solid var(--bos-border-color);
    padding: 16px;
}

.card-footer {
    background-color: var(--bos-bg-secondary);
    border-top: 1px solid var(--bos-border-color);
    padding: 16px;
}

/* Button Styles */
.btn-bos-primary {
    background-color: #0074E8;
    border-color: #0074E8;
    color: #ffffff;
    border-radius: 6px;
    padding: 8px 16px;
    font-weight: 500;
    font-size: 14px;
    cursor: pointer;
}

.btn-bos-secondary {
    background-color: #ffffff;
    border: 1px solid #0074E8;
    color: #0074E8;
    border-radius: 6px;
    padding: 8px 16px;
    font-weight: 500;
    font-size: 14px;
    cursor: pointer;
}

/* Table Styles */
.table-bos {
    --bs-table-bg: var(--bos-bg-primary);
    --bs-table-striped-bg: var(--bos-gray-50);
    --bs-table-hover-bg: var(--bos-primary-light);
}

    .table-bos th {
        font-weight: var(--bos-font-weight-semibold);
        color: var(--bos-text-primary);
        border-bottom: 2px solid var(--bos-border-color);
       
    }

.table-bos td {
    color: var(--bos-text-secondary);
}

/* Badge styles */
.badge-bos-primary {
    background-color: var(--bos-primary-light);
    color: var(--bos-primary-dark);
}

.badge-bos-success {
    background-color: var(--bos-success-light);
    color: #16a34a;
}

.badge-bos-danger {
    background-color: var(--bos-danger-light);
    color: #dc2626;
}

.badge-bos-warning {
    background-color: var(--bos-warning-light);
    color: #d97706;
}

/* Form Styles */
.form-control-bos {
    border-radius: var(--bos-border-radius);
    border: 1px solid var(--bos-border-color);
    padding: 8px 16px;
}

.form-control-bos:focus {
    border-color: var(--bos-primary);
    box-shadow: 0 0 0 0.25rem rgba(var(--bos-primary-rgb), 0.25);
}

.form-check-input:checked {
    background-color: var(--bos-primary);
    border-color: var(--bos-primary);
}

/* Animation Styles */
@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideInUp {
    from {
        transform: translateY(20px);
        opacity: 0;
    }
    to {
        transform: translateY(0);
        opacity: 1;
    }
}

.fade-in {
    animation: fadeIn var(--bos-transition-slow) ease-in-out;
}

.slide-in-up {
    animation: slideInUp var(--bos-transition-slow) ease-in-out;
}

/* Scrollbar Styles */
::-webkit-scrollbar {
    width: 5px;
    height: 5px;
}

::-webkit-scrollbar-track {
    background: var(--bos-gray-100);
    border-radius: 3px;
}

::-webkit-scrollbar-thumb {
    background: #9EB0C7 !important;
    border-radius: 8px;
}

::-webkit-scrollbar-thumb:hover {
    background: #8A9DB5 !important;
}

/* Utility Classes */
.text-bos-primary {
    color: var(--bos-primary) !important;
}

.text-bos-success {
    color: var(--bos-success) !important;
}

.text-bos-danger {
    color: var(--bos-danger) !important;
}

.text-bos-warning {
    color: var(--bos-warning) !important;
}

.bg-bos-primary {
    background-color: var(--bos-primary) !important;
}

.bg-bos-secondary {
    background-color: var(--bos-secondary) !important;
}

.rounded-bos {
    border-radius: var(--bos-border-radius) !important;
}

.rounded-bos-lg {
    border-radius: var(--bos-border-radius-lg) !important;
}

.shadow-bos {
    box-shadow: var(--bos-shadow) !important;
}

.shadow-bos-md {
    box-shadow: var(--bos-shadow-md) !important;
}

.shadow-bos-lg {
    box-shadow: var(--bos-shadow-lg) !important;
}

/* Loading overlay */
.loading-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(255, 255, 255, 0.8);
    display: flex;
    justify-content: center;
    align-items: center;
    z-index: var(--bos-z-dropdown);
}

.loading-spinner {
    width: 40px;
    height: 40px;
    border: 4px solid var(--bos-gray-200);
    border-top-color: var(--bos-primary);
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

/* Breadcrumb Styles */
.breadcrumb-bos {
    margin-bottom: 16px;
}

.breadcrumb-bos .breadcrumb-item + .breadcrumb-item::before {
    content: ">";
    color: var(--bos-gray-500);
}

/* Empty state */
.empty-state {
    text-align: center;
    padding: 16px;
    color: var(--bos-text-light);
}

.empty-state-icon {
    font-size: 3rem;
    color: var(--bos-gray-300);
    margin-bottom: 16px;
}
.btn-outline-secondary {
    height: 40px;
    padding-inline: 25px;
    padding-block: 8px;
    border-radius: 4px;
    color: black;
    border-color: black;
}
.btn-outline-secondary>i{
    margin-right:5px;
}
.btn-group, .btn-group-vertical{
    gap:8px;
}
    .btn-group .btn-sm {
        border-radius: 4px !important;
        font-size: 10px;
    }
.btn:hover {
    color: white;
}
.btn-check:checked + .btn, .btn.active, .btn.show, .btn:first-child:active, :not(.btn-check) + .btn:active {
    color: white;
}
table > thead > tr > th, th, table th {
    color: #1E252C !important;
    padding: 1rem !important;
    word-wrap: normal !important;
    text-align: start;
    font-weight: 600 !important;
    border: 1px solid #E9ECEE !important;
    background-color: #F0F4F8 !important;
    text-shadow: none;
    white-space: nowrap;
}
.filter-container {
    padding: 0;
    float: inline-start;
    width: 100%;
    background-color: #fff;
    margin-bottom:16px;
}
.view-selection {
    margin-inline-end: inherit;
    padding-inline: 10px !important;
    flex-wrap: wrap;
    background-color: #E5F0FF;
    margin: 0;
    padding-block-start: 10px !important;
    padding-block-end: 10px !important;
    border-radius:6px;
}
    .view-selection:has(+ #filterCard[style*="display: block"]) {
        border-start-start-radius: 6px !important;
        border-start-end-radius: 6px !important;
        border-end-end-radius: 0px !important;
        border-end-start-radius: 0px !important;
    }
.btn-reset > .bi-arrow-clockwise::before {
    content: "\f116";
    font-size: 16px;
    vertical-align: middle;
    margin-inline-start: 4px;
    color: #000000;
    font-weight: 900 !important;
    --bs-gutter-x: 0px;
    line-height: 0px !important;
    margin-top: -4px;
}
.btn-filter {  
    color: #0062ff;
    text-decoration: none;
    display: flex;
    gap: 6px;
    font-size: 14px;
    font-weight: 500;
}
#filterCard {
    border-start-start-radius: 0 !important;
    border-start-end-radius: 0 !important;
    border-end-end-radius: 6px !important;
    border-end-start-radius: 6px !important;
    border: 1px solid #E7ECF1;
    padding: 16px;
    margin: 0px !important;
}
.filter-btn-group {
    gap: 16px;
    display: flex;
    flex-direction: row;
    align-items: center;
    justify-content: flex-end;
}
.gap-16{
    gap:16px;
}
.bi-funnel::before {
    font-weight: 600 !important;
    color: #000000;
}
.lblsearch {
    color: #474C51;
    white-space: nowrap !important;
    font-weight: 600 !important;
}
.rowRecordPerPage {
    padding-inline: 16px;
    margin: 0px;
    margin-top: 12px;
    margin-bottom: 12px;
}
.table > :not(caption) > * > * {
    padding: 8px !important;
}
.table-responsive {
    min-width: 100%;
    width: 100px;
    margin-bottom: 16px !important;
}
.rowRecordPerPage .form-select-sm {
    min-width: 60px;
    padding: 6px 12px;
}
.form-switch .form-check-input {
    height: 22px;
    width: 44px;
    margin-right:8px;
}
select.bos-form-control[disabled], .bos-form-control[readonly] {
    color: black;
    background-image: none !important;
}
.form-check-input:disabled {
    opacity:1 !important
}
.main-content {
    min-height: 500px;
}

.pagination {
    gap: 16px;
    margin-right: 16px;
}
.page-item:first-child .page-link, .page-item:last-child .page-link {
    border-radius: 4px !important;
}
.active > .page-link, .page-link.active {
    z-index: 3;
    color: black;
    background-color: white;
    border-color: black;
}
.Page.navigation ul.pagination.justify-content-center {
    justify-content: end !important;
}
.page-link:hover {
    z-index: 2;
    color: black;
    background-color: white;
    border-color: black;
    border-radius: 4px !important;
}
.page-link {
    color: #a4a4a4;
    border-color: #a4a4a4;
    border-radius: 4px !important;
    font-size: 14px;
}
    .page-item:last-child .page-link, .disabled > .page-link, .page-link.disabled {
        color: black !important;
        font-size: 14px;
    }
        .page-item:last-child .page-link::after {
            content: "🠆";
            color: black;
            margin-left: 5px;
        }
.page-item:first-child .page-link::before {
    content: "🠄";
    color: black;
    margin-right: 5px;
}

/*scan now ssl btn*/
.spin {
    animation: spin 1s linear infinite;
}

@keyframes spin {

    from {
        transform: rotate(0deg);
    }

    to {
        transform: rotate(360deg);
    }
}

/* Fresh Toast UI — gradient style (Success / Info / Warning / Error) */
#toastContainer {
    z-index: 11000 !important;
    top: 72px !important;
    right: 16px !important;
    display: flex;
    flex-direction: column;
    gap: 12px;
    pointer-events: none;
}
.fresh-toast {
    pointer-events: auto;
    position: relative;
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 340px;
    max-width: 460px;
    padding: 14px 44px 14px 14px;
    border-radius: 10px;
    color: #ffffff;
    box-shadow: 0 12px 28px rgba(15, 23, 42, 0.22);
    opacity: 0;
    transform: translateX(24px) scale(0.98);
    transition: opacity .25s ease, transform .25s ease;
    overflow: hidden;
}
.fresh-toast.show { opacity: 1; transform: translateX(0) scale(1); }
.fresh-toast.hide { opacity: 0; transform: translateX(24px) scale(0.98); }

.fresh-toast-success { background: linear-gradient(90deg, #34d399 0%, #059669 100%); }
.fresh-toast-info    { background: linear-gradient(90deg, #38bdf8 0%, #2563eb 100%); }
.fresh-toast-warning { background: linear-gradient(90deg, #fbbf24 0%, #ea580c 100%); }
.fresh-toast-error   { background: linear-gradient(90deg, #f87171 0%, #dc2626 100%); }

.fresh-toast-accent { display: none; }

.fresh-toast-icon {
    width: 36px;
    height: 36px;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1.05rem;
    background: rgba(0, 0, 0, 0.22);
    color: #ffffff;
}
.fresh-toast-success .fresh-toast-icon,
.fresh-toast-error .fresh-toast-icon,
.fresh-toast-warning .fresh-toast-icon,
.fresh-toast-info .fresh-toast-icon {
    background: rgba(0, 0, 0, 0.22);
    color: #ffffff;
}

.fresh-toast-content { flex: 1; min-width: 0; }
.fresh-toast-title {
    font-weight: 700;
    font-size: .9rem;
    letter-spacing: .01em;
    margin-bottom: 2px;
    color: #ffffff;
}
.fresh-toast-msg {
    font-size: .82rem;
    line-height: 1.35;
    color: rgba(255, 255, 255, 0.92);
}
.fresh-toast-action {
    flex-shrink: 0;
    border: 1px solid rgba(255, 255, 255, 0.85);
    background: transparent;
    color: #fff;
    border-radius: 6px;
    padding: 4px 12px;
    font-size: .78rem;
    font-weight: 600;
    cursor: pointer;
}
.fresh-toast-action:hover {
    background: rgba(255, 255, 255, 0.15);
}
.fresh-toast-close {
    position: absolute;
    top: 8px;
    right: 10px;
    border: 0;
    background: transparent;
    color: rgba(255, 255, 255, 0.9);
    font-size: 1.25rem;
    line-height: 1;
    cursor: pointer;
}
.fresh-toast-close:hover { color: #fff; }
.fresh-toast-progress {
    position: absolute;
    left: 0;
    right: 0;
    bottom: 0;
    height: 3px;
    background: rgba(255, 255, 255, 0.2);
}
.fresh-toast-progress span {
    display: block;
    height: 100%;
    width: 100%;
    background: rgba(255, 255, 255, 0.85);
}
.fresh-toast-success .fresh-toast-progress span,
.fresh-toast-error .fresh-toast-progress span,
.fresh-toast-warning .fresh-toast-progress span,
.fresh-toast-info .fresh-toast-progress span {
    background: rgba(255, 255, 255, 0.85);
}

/* ==================================================
   Toast customization hooks (edit these freely)
   Classes used by showToast() in site.js:
   - #toastContainer
   - .fresh-toast / .fresh-toast.show / .fresh-toast.hide
   - .fresh-toast-success | -error | -warning | -info
   - .fresh-toast-icon
   - .fresh-toast-title
   - .fresh-toast-msg
   - .fresh-toast-action
   - .fresh-toast-close
   - .fresh-toast-progress > span
   ================================================== */
.bos-toast-container { }
.bos-toast { }
.bos-toast-success { }
.bos-toast-error { }
.bos-toast-warning { }
.bos-toast-info { }
.bos-toast-title { }
.bos-toast-message { }
.bos-toast-close { }
.bos-toast-progress { }

/* ==================================================
   Tooltip customization hooks (see also bos-tooltip.css)
   ================================================== */
.bos-tooltip-target { }
.bos-tooltip-bubble { }
.bos-tooltip-arrow { }

/* List row click + action dropdown — keep Actions on the right */
tr.bos-row-click { cursor: pointer; }
tr.bos-row-click:hover > td { background-color: rgba(0, 29, 79, 0.04); }
table.table th:last-child,
table.data-table th:last-child,
table.table td:last-child,
table.data-table td:last-child,
.bos-row-actions {
    text-align: right !important;
    white-space: nowrap;
    cursor: default;
}
.bos-row-actions .btn-group,
.bos-row-actions .dropdown {
    display: inline-flex;
    justify-content: flex-end;
}
.table-responsive { overflow-x: auto; overflow-y: visible; }
.card .table-responsive .dropdown-menu {
    z-index: 1080;
}
.bos-actions-dropdown .dropdown-menu {
    min-width: 200px;
    box-shadow: 0 10px 30px rgba(15, 23, 42, 0.15);
    border: 1px solid #e2e8f0;
    border-radius: 10px;
    padding: 6px;
}
.bos-actions-dropdown .dropdown-item {
    border-radius: 8px;
    font-size: 0.875rem;
    padding: 0.45rem 0.75rem;
}

.email-mx-status {
    min-width: 42px;
    justify-content: center;
    background: #fff;
}
.email-mx-status .bi { font-size: 1.1rem; }
.summary-icon {
    padding: 4px 8px;
    border-radius: 6px;
    color: white;
}
.summary-title {
    font-weight: 600;
    color: #001d4f;
}
.bos-btn-secondary {
    gap: 8px;
}
.data-table {
    font-size: 14px;
}

/* ==================================================
   Document layout: card + sticky action rail (outside card)
   ================================================== */
.bos-doc-layout {
    display: flex;
    align-items: flex-start;
    gap: 12px;
}
.bos-doc-main {
    flex: 1;
    min-width: 0;
    gap: 12px;
    display: flex;
    flex-direction: column;
}

/* Report pages: rail as last child of main-content (not body — JS also toggles body class) */
.main-content.has-bos-action-rail {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: start;
    column-gap: 12px;
}
.main-content.has-bos-action-rail > *:not(.bos-action-rail) {
    grid-column: 1;
}
.main-content.has-bos-action-rail > .bos-action-rail {
    grid-column: 2;
    grid-row: 1 / -1;
}

.bos-action-rail {
    position: sticky;
    top: 12px;
    z-index: 20;
    align-self: flex-start;
    flex-shrink: 0;
    display: flex;
    flex-direction: column;
    gap: 8px;
    padding: 10px 8px;
    background: #f1f5f9;
    border: 1px solid #e2e8f0;
    border-radius: 12px;
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.08);
    width: 52px;
}
.bos-action-rail-form {
    margin: 0;
    display: block;
}
.bos-action-rail-btn {
    width: 36px;
    height: 36px;
    border-radius: 10px;
    border: 1px solid #e2e8f0;
    background: #ffffff;
    color: #001d4f;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-decoration: none;
    cursor: pointer;
    padding: 0;
    font-size: 1.2rem;
    font-weight: 700;
    transition: background .15s ease, border-color .15s ease, color .15s ease;
}
.bos-action-rail-btn .bi {
    font-weight: 700 !important;
    -webkit-text-stroke: 0.4px currentColor;
}
.bos-action-rail-btn:hover {
    background: #001d4f;
    color: #ffffff;
    border-color: #001d4f;
}
.bos-action-rail-danger:hover {
    background: #dc2626;
    border-color: #dc2626;
    color: #fff;
}
.bos-action-rail-muted {
    color: #64748b;
}

/* Hide icons inside primary/secondary buttons project-wide */
.bos-btn-primary > i,
.bos-btn-primary > .bi,
.bos-btn-secondary > i,
.bos-btn-secondary > .bi,
a.bos-btn-primary > i,
a.bos-btn-secondary > i,
button.bos-btn-primary > i,
button.bos-btn-secondary > i {
    display: none !important;
}

@media (max-width: 768px) {
    .bos-doc-layout {
        flex-direction: column;
    }
    .main-content.has-bos-action-rail {
        display: block;
    }
    .bos-action-rail {
        position: sticky;
        top: auto;
        bottom: 10px;
        width: 100%;
        flex-direction: row;
        justify-content: flex-end;
        overflow-x: auto;
        order: 99;
    }
    .main-content.has-bos-action-rail > .bos-action-rail {
        grid-column: auto;
        grid-row: auto;
        margin-top: 12px;
    }
}

@media print {
    .bos-action-rail,
    .no-print {
        display: none !important;
    }
    .bos-doc-layout,
    .main-content.has-bos-action-rail {
        display: block;
    }
}
[data-bos-tooltip]::after {
    border: 1.6px solid #0d6efd !important;
    font-size: 14px !important;
    background: #fff !important;
    color: black !important;
}
[data-bos-tooltip-placement="bottom"]::before {
    border-bottom: 7px solid #0d6efd !important;
}
[data-bos-tooltip-placement="top"]::before {
    border-top: 7px solid #0d6efd !important;
}
[data-bos-tooltip-placement="left"]::before {
    border-left: 7px solid #0d6efd !important;
}
[data-bos-tooltip-placement="right"]::before {
    border-right: 7px solid #0d6efd !important;
}
.fresh-toast-info.show .bi-info-lg::before, .bi-x-lg::before, .bi-exclamation-lg::before, .bi-check-lg::before {
    font-weight: 900 !important;
    font-size: 14px;
}
.fresh-toast-close {
    color: #000000;
    font-size: 16px;
    font-weight: 900;
}
.fresh-toast-info {
    background: #b5f9c4 !important;
}
        .fresh-toast-success .fresh-toast-icon, .fresh-toast-error .fresh-toast-icon, .fresh-toast-warning .fresh-toast-icon, .fresh-toast-info .fresh-toast-icon {
            background: #ffffff00 !important;
            border: 2px solid;
            border-radius: 50px;
            color: #000000;
        }
.fresh-toast-icon {
    width: 26px !important;
    height: 26px !important;
}
.fresh-toast-close:hover {
    color: #1301016b;
}
.fresh-toast-title {
    font-size: 16px;
    color: #000000;
}
.fresh-toast-msg {
    font-size: 14px;
    color: #000000;
}
.fresh-toast-progress {
    background: rgb(12 0 0 / 50%);
}
.fresh-toast-error {
    background: #ffb7b7 !important;
}
.fresh-toast-warning {
    background: #ffdda5 !important;
}
.fresh-toast-success {
    background: #b6f8c4;
}


/*tabs designs*/

.nav-tabs {
    border-bottom: 1px solid #c0c7ce !important;
    gap: 8px;
}
    .nav-tabs .nav-item.show .nav-link, .nav-tabs .nav-link.active, .nav-tabs .nav-link:focus, .nav-tabs .nav-link:hover {
        background-color: var(--bos-primary-light);
        color: var(--bos-primary);
        border: none;
        border-bottom: 4px solid var(--bos-primary);
        padding: 8px 16px;
        font-size: 14px;
        font-weight: 700;
        outline: none;
        box-shadow: none;
    }
.nav-link:focus-visible {
    box-shadow: none;
}
.nav-tabs .nav-link {
    padding: 8px 16px;
    color: #000;
}