/* Google Fonts Import for Raleway and Open Sans */
@import url('https://fonts.googleapis.com/css2?family=Raleway:wght@400;600;700&family=Open+Sans:wght@300;400;500;600&display=swap');

/* Heading font styles - Raleway */
h1, .h1, 
h2, .h2, 
h3, .h3, 
h4, .h4, 
h5, .h5,
h6, .h6,
.section-landing-heading,
.section-landing-sub-heading,
h1.siteTitle,
.static-top.navbar-dark .navbar-brand a h1.siteTitle {
    font-family: 'Raleway', sans-serif !important;
}

/* General text font styles - Open Sans */
body,
p, .p, .p2,
a, .a,
button, .btn,
.btn-primary,
.button1, .button2,
.navbar-dark .navbar-nav > li > a,
.navbar-dark .navbar-nav > li.dropdown > a,
.static-top.navbar .menu-bar > .navbar-nav > li > a,
footer,
p.smallText,
li,
input, 
select, 
textarea, 
.form-control {
    font-family: 'Open Sans', sans-serif !important;
}

/* Specific overrides for elements that might need different weights */
h1, .h1, .section-landing-heading, h1.siteTitle {
    font-weight: 700 !important;
}

h2, .h2, .section-landing-sub-heading {
    font-weight: 600 !important;
}

.btn-primary, .button1, .button2 {
    font-weight: 500 !important;
}

/* Ensure dropdown menus and navigation items use Open Sans */
.dropdown-menu > li > a, 
.nav > li > a,
.navbar-dark .navbar-nav .show.dropdown-menu > li > a,
.msos-container,
.msos-option,
.msos-selection-container {
    font-family: 'Open Sans', sans-serif !important;
}

/******* Basic page layout **********************************************/
/* Ensure footer stays at the bottom of the page */
body {
    display: flex;
    flex-direction: column;
}
  
.wrapper-body {
    min-height: unset;
    padding-bottom: 15px;
}

/************* Footer *************/
.footer {
    margin-top: auto;
}

.footer-bottom {
    padding: 20px 0;
}

/****** Search bar ***************/
.form-search > .input group {
    align-items: stretch;
}

.form-search .input-group-btn {
    align-self: stretch;
}

.form-search .btn-primary {
    height: 100%;
}

/****** General styling ************/
li.breadcrumb-item > a {
    font-size: 16px;
}

/******* Utility Classes ************************************************/
/* Note, some of these statements override the default Bootstrap styles */
.bg-dark {
    background: #071736 !important;
}

.bg-light {
    background: white !important;
}

.bg-dark,
.bg-dark h1,
.bg-dark h2,
.bg-dark p {
    color: white;
}

.bg-light,
.bg-light h1,
.bg-light h2,
.bg-light p {
    color: #071736;
}

.text-center {
    text-align: center;
}

.text-dark {
    color: #071736 !important;
}

.text-muted {
    color: rgba(255, 255, 255, 0.8) !important;
}

.text-primary {
    color: #071736 !important;
}

.text-secondary {
    color: #616e85  !important;
}

.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 500;
    text-align: center;
    vertical-align: middle;
    cursor: pointer;
    padding: 0.5rem 1.25rem;
    border-radius: 6px;
    transition: all 0.2s ease;
    text-decoration: none;
}

.btn-primary {
    background: #071736;
    color: white;
    border: none;
}

.btn-primary:hover {
    background: #0a2450;
    transform: translateY(-1px);
}

.btn-outline-light {
    background: transparent;
    border: 2px solid rgba(255, 255, 255, 0.5);
    color: white;
}

.btn-outline-light:hover {
    background: rgba(255, 255, 255, 0.1);
    transform: translateY(-1px);
}

.btn-lg {
    padding: 1rem 2rem;
    font-size: 1.1rem;
}

/* Default button on dark backgrounds */
.bg-dark .btn-primary {
    background: white;
    color: #071736;
}

.bg-dark .btn-primary:hover {
    background: #f8f9fa;
}

/**** These ensure input groups are aligned vertically with the same height ****/
.input-group {
    height: 40px;
}

.input-group div,
.input-group select,
.input-group input,
.input-group .btn {
    height: inherit;
}

.dashboard-wrapper {
    min-height: 100vh;
    background-color: white;
}

.container {
    max-width: 1400px;
    margin: 0 auto;
    padding: 0 1.5rem;
}

.align-center {
    align-items: center;
}

/*** Home page styling ***********************/
.section {
    padding: 4rem 0;
}

.section-title {
    font-size: 2rem;
    font-weight: 700;
    text-align: center;
    margin-bottom: 0.5rem;
}

.section-subtitle {
    text-align: center;
    margin-bottom: 3rem;
    font-size: 1.1rem;
}

.section-content {
    max-width: 800px;
    margin: 0 auto;
    text-align: center;
    padding: 2rem;
    position: relative;
    z-index: 1;
}

.section-content h1 {
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 1rem;
    line-height: 1.2;
}

.section-flex {
    gap: 1rem;
    max-width: 1000px;
    margin: auto;
}

.section-subtitle,
.section-subtitle > a {
    font-size: 1.25rem;
    opacity: 0.9;
    margin-bottom: 2rem;
    font-weight: 300;
    color: rgba(255, 255, 255, 0.9);
}

.section-subtitle > a {
    text-decoration: underline;
}

.section-actions {
    display: flex;
    gap: 1rem;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
}

.section-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 4rem;
    max-width: 1200px;
    margin: 0 auto;
}

.section-grid-center {
    align-items: center;
}

.section-grid-content {
    padding: 2rem;
}

.section-grid-content h2 {
    font-size: 2.5rem;
    font-weight: 700;
    margin-bottom: 1.5rem;
    line-height: 1.2;
}

.section-grid-content p {
    font-size: 1.1rem;
    margin-bottom: 2rem;
    line-height: 1.6;
}

.feature-list {
    list-style: none;
    padding: 0;
    margin: 0;
}

.feature-list li {
    display: flex;
    align-items: center;
    margin-bottom: 1.25rem;
    font-size: 1.1rem;
    line-height: 1.4;
}

.feature-list li i {
    margin-right: 1rem;
    font-size: 1.25rem;
    width: 24px;
    flex-shrink: 0;
    text-align: center;
}

.section-image {
    position: relative;
    border-radius: 12px;
    overflow: hidden;
}

.section-image img {
    width: 100%;
    height: auto;
    border-radius: 12px;
    box-shadow: 0 4px 6px rgba(0,0,0,0.1);
}

.section-grid-3 {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 2rem;
    max-width: 1200px;
    margin: 3rem auto 0;
    padding: 0 1rem;
}

.section-card {
    text-align: center;
    padding: 2.5rem 2rem;
    background: white;
    border-radius: 12px;
    transition: transform 0.2s ease-in-out;
    border: 1px solid #e9ecef;
    box-shadow: 0 4px 6px rgba(0,0,0,0.05);
}

.section-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 20px rgba(0,0,0,0.1);
}

.section-icon {
    font-size: 2.5rem;
    margin-bottom: 1.5rem;
    height: 2.5rem;
    width: 2.5rem;
}

.section-card h3 {
    font-size: 1.5rem;
    font-weight: 600;
    margin-bottom: 1rem;
}

.section-card p {
    font-size: 1rem;
    line-height: 1.6;
    margin: 0;
}

.sectionBlockLayout {
    display: flex;
    flex-wrap: wrap;
    padding: 8px;
    margin: 0px;
    min-height: 15px;
}

.section-landing-mostpopular {
    font-family: Segoe UI;
    font-weight: 700;
    font-size: 24px;
    line-height: 52px;
    letter-spacing: 0px;
    text-align: left;
}

.columnBlockLayout {
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    min-width: 310px;
    word-break: break-word;
    padding: 24px;
}

.removemargin {
    margin: 0;
}

.columnBlockLayout.removemargin {
    background-color: rgb(244, 248, 255);
    background-image: url("/C 1.png");
    background-position: center center;
    background-repeat: no-repeat;
    background-size: contain;
    background-origin: content-box;
}

/*** Home page --- Responsive Design *****/
@media (max-width: 991px) {
    .section-grid-3 {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .section-grid {
        grid-template-columns: 1fr;
        gap: 2rem;
    }

    .section-grid-content {
        text-align: center;
        padding: 1rem;
    }

    .feature-list {
        display: inline-block;
        text-align: left;
        margin: 0 auto;
    }

    .section-content h1 {
        font-size: 2.5rem;
    }
}

@media (max-width: 767px) {
    .section {
        padding: var(--section-padding-mobile);
    }

    .section-content h1 {
        font-size: 2rem;
    }

    .section-title,
    .section-grid-content h2 {
        font-size: 1.75rem;
    }

    .section-actions {
        flex-direction: column;
        gap: 1rem;
    }

    .section-grid-3 {
        grid-template-columns: 1fr;
        gap: 1.5rem;
    }

    .section-card {
        padding: 1.5rem;
    }

    .section-grid-content {
        padding: 0;
    }
}

/******* Entity list styling ********/
div.view-grid, div.view-toolbar, div.crmEntityFormView {
    border: none;
}
div.entity-grid {
    padding: 10px 5px 0px 5px;
    border: 1px solid #f2f2f2;
    box-shadow: 0 .125rem .25rem rgba(0, 0, 0, .075) !important;
}
.view-select a {
    font-size: 18px;
}
.view-grid thead a {
    font-size: 16px;
}
.view-grid tr {
    vertical-align: middle;
}
.entity-grid .message {
    padding: 0 10px 10px 10px;
}

/******* Allow actions to be inline for entity lists ****/
.view-grid .dropdown.action>.btn {
    display: none;
}
.view-grid .dropdown.action .dropdown-menu {
    display: block;
    position: static !important;
    position: initial !important;
    border: 0;
    background: transparent;
    box-shadow: none;
    text-align: center;
    max-width: 95px;
    min-width: 95px;
    width: 95px;
    left: auto !important;
    top: auto !important;
}
.view-grid .dropdown.action .dropdown-menu li {
    display: inline-block;
    text-align: center;
}
.view-grid .dropdown.action .dropdown-menu li a {
    padding: 5px;
    margin: 2px;
    background: white;
    border: #071736 1px solid;
    border-radius: 5px;
}
.view-grid .dropdown.action .dropdown-menu li a>span {
    font-size: 18px;
}
.view-grid .dropdown.action .dropdown-menu li a:hover {
    color: unset;
    background: transparent;
}
.view-grid .dropdown.action .dropdown-menu li a .fa:before {
    padding-right: 5px;
}
/*** The following stops the last column from incorrectly calculating the width of the td*****/
.view-grid .table td:last-child {
    padding-right: 16px;
    width: auto;       /* Remove fixed width */
    min-width: max-content;  /* Ensure it fits the content */
    white-space: nowrap;  /* Prevent wrapping */
}
.view-grid .table td:last-child .dropdown {
    width: 100%;
}

.view-grid .table td:last-child .dropdown .dropdown-menu {
    min-width: fit-content;
}
.view-grid .table td:last-child .btn {
    max-width: 100%;
}
.view-grid .table td:last-child .dropdown-item {
    white-space: nowrap;
}

/** Home page Print Styles ************************/
@media print {
    .section {
        background: none !important;
        color: #071736;
    }

    .section h1,
    .section h2,
    .feature-list li {
        color: #071736;
    }

    .btn {
        display: none !important;
    }

    .section-card {
        break-inside: avoid;
        border: 1px solid #071736;
    }

    .section-grid-3,
    .section-grid {
        gap: 1rem;
    }
}