:root {
    --app-navy: #172033;
    --app-blue: #2f65d9;
    --app-bg: #f4f6f9;
    --app-border: #dfe4eb;
}

body {
    background: var(--app-bg);
    color: #263043;
}

.navbar-app {
    background: var(--app-navy);
    box-shadow: 0 2px 12px rgba(13, 25, 48, .18);
}

.app-shell {
    padding-bottom: 48px;
    padding-top: 88px;
}

.page-heading {
    font-weight: 700;
    letter-spacing: -.02em;
}

.card,
.btn,
.form-control,
.form-select,
.input-group-text,
.modal-content {
    border-radius: .35rem;
}

.card {
    border-color: var(--app-border);
    box-shadow: 0 2px 10px rgba(28, 39, 60, .04);
}

.table > :not(caption) > * > * {
    padding: .8rem .65rem;
}

.project-row,
.customer-row {
    cursor: pointer;
}

.project-row:hover,
.customer-row:hover {
    background: #f1f5ff;
}

.detail-label {
    color: #6c7686;
    font-size: .75rem;
    font-weight: 700;
    letter-spacing: .06em;
    text-transform: uppercase;
}

.detail-value {
    margin-bottom: 1rem;
}

.empty-state {
    color: #788395;
    padding: 3rem 1rem !important;
    text-align: center;
}

.login-page {
    background: #fafbfe;
    min-height: 100vh;
}

.login-shell {
    margin-top: 60px;
    padding: 1rem;
}

.login-card {
    border-radius: 0;
    box-shadow: 0 8px 30px rgba(14, 34, 62, .1);
    max-width: 100%;
    width: 340px;
}

.login-card-header {
    background: #fff;
    border-bottom: 1px solid var(--app-border);
    padding: 1.25rem 1.5rem 1rem;
}

.login-logo {
    display: block;
    height: 110px;
    margin: 0 auto .35rem;
    max-width: 230px;
    object-fit: contain;
    width: 100%;
}

.app-wordmark {
    align-items: baseline;
    display: inline-flex;
    gap: .35em;
    letter-spacing: .01em;
    white-space: nowrap;
}

.app-wordmark strong {
    font-weight: 700;
}

.app-wordmark span {
    font-weight: 300;
}

.login-wordmark {
    color: #263043;
    display: flex;
    font-size: 1.25rem;
    justify-content: center;
}

.brand-mark {
    align-items: center;
    background: var(--app-blue);
    border-radius: .45rem;
    color: #fff;
    display: inline-flex;
    height: 38px;
    justify-content: center;
    width: 38px;
}

.mobile-shell {
    max-width: 760px;
}

.mobile-topbar {
    background: var(--app-navy);
}

.mobile-project-card {
    border-left: 4px solid var(--app-blue);
    color: inherit;
    text-decoration: none;
}

.mobile-project-card:active {
    transform: scale(.995);
}

.mobile-card-meta {
    color: #6c757d;
    font-size: .82rem;
}

.required::after {
    color: #dc3545;
    content: " *";
}

.form-details-field {
    display: flex;
    flex-direction: column;
}

.form-details-field > div {
    display: flex;
    flex: 1 1 auto;
    flex-direction: column;
    margin-bottom: 0 !important;
}

.form-details-field textarea {
    flex: 1 1 auto;
    min-height: 18rem;
    resize: vertical;
}

.project-details-text {
    line-height: 1.65;
    min-height: 12rem;
    overflow-wrap: anywhere;
}

.project-meta-column {
    border-left: 1px solid var(--app-border);
}

.report-table {
    min-width: 38rem;
    table-layout: fixed;
}

.report-amount-column {
    width: 8rem;
}

.report-hours-column {
    width: 6rem;
}

.report-table-header th {
    padding: .5rem .65rem !important;
    vertical-align: middle;
}

.report-entry-row:hover {
    background: #f1f5ff;
}

.report-entry-edit-button {
    opacity: 0;
    pointer-events: none;
    transition: opacity .15s ease-in-out;
}

.report-entry-row:hover .report-entry-edit-button,
.report-entry-row:focus-within .report-entry-edit-button {
    opacity: 1;
    pointer-events: auto;
}

@media (hover: none) {
    .report-entry-edit-button {
        opacity: 1;
        pointer-events: auto;
    }
}

.report-details-clamp {
    display: -webkit-box;
    overflow: hidden;
    overflow-wrap: anywhere;
    -webkit-box-orient: vertical;
    -webkit-line-clamp: 2;
}

.deadline-input-group {
    flex-wrap: nowrap;
    overflow-x: auto;
}

.nav-pills {
    background: #eef2f7;
    border-radius: .6rem;
    gap: .25rem;
    padding: .3rem;
}

.nav-pills .nav-link {
    border-radius: .4rem;
    color: #56657a;
    font-weight: 600;
}

.nav-pills .nav-link:not(.active):hover {
    background: rgba(255, 255, 255, .65);
    color: var(--app-blue);
}

.nav-pills .nav-link.active {
    background: #fff;
    box-shadow: 0 1px 4px rgba(28, 39, 60, .12);
    color: var(--app-blue);
}

@media (min-width: 1200px) {
    .form-layout-main {
        flex: 0 0 60%;
        max-width: 60%;
    }

    .form-layout-side {
        flex: 0 0 40%;
        max-width: 40%;
    }
}

.app-wrapper {
    display: flex;
    min-height: 100vh;
}

#sidebar {
    background: #0e223e;
    display: flex;
    flex-direction: column;
    height: 100vh;
    left: 0;
    min-width: 70px;
    position: fixed;
    top: 0;
    transition: width .25s ease-in-out, min-width .25s ease-in-out;
    width: 70px;
    z-index: 1040;
}

#sidebar.expand {
    min-width: 260px;
    width: 260px;
}

.sidebar-header {
    position: relative;
}

.sidebar-brand-row {
    align-items: center;
    border-bottom: 2px solid #fff;
    box-sizing: border-box;
    display: flex;
    height: 64px;
}

.sidebar-grid-toggle {
    background: transparent;
    border: 0;
    color: #fff;
    flex: 0 0 70px;
    font-size: 1.4rem;
    height: 64px;
}

.sidebar-logo {
    align-items: center;
    color: #fff;
    display: flex;
    min-width: 0;
    text-decoration: none;
    white-space: nowrap;
}

.sidebar-logo:hover {
    color: #fff;
}

.sidebar-logo .app-wordmark {
    font-size: 1.15rem;
}

.sidebar-edge-toggle {
    align-items: center;
    background: #0e223e;
    border: 0;
    color: #fff;
    cursor: pointer;
    display: none;
    height: 64px;
    justify-content: center;
    left: 70px;
    position: absolute;
    top: 0;
    transition: left .25s ease-in-out;
    width: 30px;
}

#sidebar.expand .sidebar-edge-toggle {
    left: 260px;
}

.sidebar-header:hover .sidebar-edge-toggle {
    display: flex;
}

.sidebar-toggled-closed {
    display: inline;
}

.sidebar-toggled-open {
    display: none;
}

#sidebar.expand .sidebar-toggled-closed {
    display: none;
}

#sidebar.expand .sidebar-toggled-open {
    display: inline;
}

.sidebar-nav {
    flex: 1 1 auto;
    padding: .35rem 0;
}

.sidebar-menu {
    list-style: none;
    margin: 0;
    padding: 0;
}

.sidebar-item {
    position: relative;
}

.sidebar-separator {
    border-top: 1px solid rgba(255, 255, 255, .28);
    margin: .4rem 0;
}

.sidebar-link {
    align-items: center;
    border-left: 3px solid transparent;
    color: #fff;
    display: flex;
    font-size: .9rem;
    gap: .75rem;
    min-height: 44px;
    padding: .625rem 1.4rem;
    text-decoration: none;
    white-space: nowrap;
}

.sidebar-link i {
    flex: 0 0 20px;
    font-size: 1.1rem;
    text-align: center;
}

.sidebar-link:hover,
.sidebar-link.active {
    background: rgba(255, 255, 255, .075);
    border-left-color: #3b7ddd;
    color: #fff;
}

.sidebar-logout-form {
    margin: 0;
}

.sidebar-logout-button {
    background: transparent;
    border-bottom: 0;
    border-right: 0;
    border-top: 0;
    cursor: pointer;
    font-family: inherit;
    text-align: left;
    width: 100%;
}

.sidebar-flyout {
    background: #0e2238;
    box-shadow: 5px 6px 14px rgba(8, 20, 37, .18);
    display: none;
    left: 70px;
    list-style: none;
    margin: 0;
    min-width: 15rem;
    padding: 0;
    position: absolute;
    top: 0;
}

.sidebar-flyout-link {
    align-items: center;
    color: #fff;
    display: flex;
    font-size: .9rem;
    gap: .65rem;
    min-height: 44px;
    padding: .625rem 1.25rem;
    text-decoration: none;
    white-space: nowrap;
}

.sidebar-flyout-link i {
    font-size: .9rem;
}

.sidebar-flyout-link:hover,
.sidebar-flyout-link:focus {
    background: rgba(255, 255, 255, .075);
    color: #fff;
}

#sidebar:not(.expand) .sidebar-item:hover > .sidebar-flyout,
#sidebar:not(.expand) .sidebar-item:focus-within > .sidebar-flyout {
    display: block;
}

.sidebar-footer {
    border-top: 1px solid rgba(255, 255, 255, .16);
    padding: .35rem 0 .5rem;
}

.sidebar-user {
    align-items: center;
    border-left: 3px solid transparent;
    color: #aebbd0;
    display: flex;
    gap: .75rem;
    min-height: 42px;
    overflow: hidden;
    padding: .55rem 1.4rem;
    text-decoration: none;
    white-space: nowrap;
}

.sidebar-user i {
    flex: 0 0 20px;
    font-size: 1.1rem;
    text-align: center;
}

.sidebar-user:hover,
.sidebar-user.active {
    background: rgba(255, 255, 255, .075);
    border-left-color: #3b7ddd;
    color: #fff;
}

#sidebar:not(.expand) .sidebar-logo,
#sidebar:not(.expand) .sidebar-link span,
#sidebar:not(.expand) .sidebar-user span {
    display: none;
}

#main {
    background: #fafbfe;
    margin-left: 70px;
    min-height: 100vh;
    overflow: hidden;
    padding: 1.5rem;
    transition: margin-left .25s ease-in-out;
    width: 100%;
}

#main.expand {
    margin-left: 260px;
}

.mobile-wordmark {
    color: #fff;
    font-size: 1rem;
}

@media (max-width: 767.98px) {
    #sidebar.expand {
        min-width: 220px;
        width: 220px;
    }

    #sidebar.expand .sidebar-edge-toggle {
        left: 220px;
    }

    #main.expand {
        margin-left: 220px;
    }

    #main {
        padding: 1rem;
    }

    .app-shell {
        padding-top: 76px;
    }

    .desktop-only {
        display: none !important;
    }

    .table-responsive .table {
        min-width: 760px;
    }
}

@media (max-width: 991.98px) {
    .project-meta-column {
        border-left: 0;
        border-top: 1px solid var(--app-border);
        padding-top: 1.5rem;
    }
}
