/* Shared by the application, authentication and public pages. */
@font-face {
    font-family: "Noto Sans";
    src: url("fonts/noto-sans/noto-sans-latin-ext-standard-normal.woff2") format("woff2");
    font-style: normal;
    font-weight: 100 900;
    font-stretch: 87.5%;
    font-variation-settings: "wdth" 87.5;
    font-display: swap;
    unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
}

@font-face {
    font-family: "Noto Sans";
    src: url("fonts/noto-sans/noto-sans-latin-standard-normal.woff2") format("woff2");
    font-style: normal;
    font-weight: 100 900;
    font-stretch: 87.5%;
    font-variation-settings: "wdth" 87.5;
    font-display: swap;
    unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
}

@font-face {
    font-family: "Noto Sans";
    src: url("fonts/noto-sans/noto-sans-latin-ext-standard-italic.woff2") format("woff2");
    font-style: italic;
    font-weight: 100 900;
    font-stretch: 87.5%;
    font-variation-settings: "wdth" 87.5;
    font-display: swap;
    unicode-range: U+0100-02BA,U+02BD-02C5,U+02C7-02CC,U+02CE-02D7,U+02DD-02FF,U+0304,U+0308,U+0329,U+1D00-1DBF,U+1E00-1E9F,U+1EF2-1EFF,U+2020,U+20A0-20AB,U+20AD-20C0,U+2113,U+2C60-2C7F,U+A720-A7FF;
}

@font-face {
    font-family: "Noto Sans";
    src: url("fonts/noto-sans/noto-sans-latin-standard-italic.woff2") format("woff2");
    font-style: italic;
    font-weight: 100 900;
    font-stretch: 87.5%;
    font-variation-settings: "wdth" 87.5;
    font-display: swap;
    unicode-range: U+0000-00FF,U+0131,U+0152-0153,U+02BB-02BC,U+02C6,U+02DA,U+02DC,U+0304,U+0308,U+0329,U+2000-206F,U+20AC,U+2122,U+2191,U+2193,U+2212,U+2215,U+FEFF,U+FFFD;
}

html:root {
    font-size: 95%;
    --emo-font: "Noto Sans", system-ui, sans-serif;
    --emo-text: #333;
    --emo-hint: #444;
}

body:is(.dark, .layout-dark), [data-bs-theme="dark"] {
    --emo-text: #ccc;
    --emo-hint: #bbb;
}

/* These panels have a dark backdrop in either theme. */
.profile-banner, .dashboard-principle-card, .bg-dark, .text-bg-dark {
    --emo-text: #eee;
    --emo-hint: #ccc;
}

html body, html body.dark {
    --bs-font-sans-serif: var(--emo-font);
    --bs-body-font-family: var(--emo-font);
    --bs-body-color: var(--emo-text);
    --bs-secondary-color: var(--emo-hint);
    --bs-tertiary-color: var(--emo-hint);
    font-family: var(--emo-font);
    font-stretch: 87.5%;
    font-size: 1rem;
    letter-spacing: normal;
    color: var(--emo-text);
}

body :is(button, input, textarea, select, .tooltip, .popover) {
    font-family: var(--emo-font);
    font-stretch: inherit;
}

/* EMO26 page headings use Bootstrap's responsive h3 size. The same rules
   apply before and after inline navigation and when a page has no actions. */
.emo26-company-page-header h1, #emo26-page-content h1.h3 {
    color: var(--emo-text);
    font-weight: 700;
    line-height: 1.2;
}

.emo26-company-page-eyebrow {
    margin: 0 0 .3rem;
    color: var(--emo-text);
    font-size: 1rem;
    font-weight: 700;
    line-height: 1.5;
    letter-spacing: .12em;
    text-transform: uppercase;
}

.emo26-company-page-header p.text-muted {
    font-size: 1rem;
    line-height: 1.5;
}

/* Explanations above the productive-hours and hourly-rate calculations. */
.bk1-intro.alert .bk1-intro-text {
    font-size: max(16px, 1rem);
    line-height: 1.5;
}

/* The theme also sets compact pixel sizes directly on these components. */
body :is(.form-label, .form-check-label, .form-group label,
    .tagify, .select2-container, .select2-drop, .select2-dropdown,
    .page-link) {
    font-size: max(12px, .875rem);
}

body :is(small, .small, .badge, .dropdown-header, .form-text, .invalid-feedback,
    .valid-feedback, .breadcrumb-item, .input-group-text, .btn-xs, .btn-sm, sub, sup) {
    font-size: max(12px, .875em);
}

#emo26-page-content .emo26-list-filters :is(.small, .btn-sm) {
    font-size: max(13px, .875rem);
    line-height: 1.4;
}

#emo26-page-content .emo26-list-filters .btn-sm {
    padding: .25rem .5rem;
}

/* CORK uses important text utilities with different specificity in each theme. */
@layer readability {
    /* CORK sets smaller sizes on tabs in forms and compact layouts. */
    :is(.nav-tabs, .nav-pills) .nav-link,
    [role="tab"], [data-bs-toggle="tab"], [data-bs-toggle="pill"] {
        font-size: max(16px, 1rem) !important;
        letter-spacing: normal !important;
    }

    /* DataTables sets its own cell sizes. Keep text and controls on the
       same scale, including the action menu when moved outside the table. */
    :is(table.table, table.dataTable, #emo26-page-content table) :is(th, td),
    :is(table.table, table.dataTable, #emo26-page-content table) :is(th, td)
        :is(a, button, span, p, small, strong, label, input, select, .small),
    .emo26-action-menu .dropdown-item {
        font-size: max(12px, .875rem) !important;
        letter-spacing: normal !important;
    }

    :is(table.table, table.dataTable, #emo26-page-content table) :is(th, td) {
        color: var(--emo-text) !important;
    }

    :is(table.table, table.dataTable) :is(th, td) .badge[class*="badge-light-"],
    :is(table.table, table.dataTable) :is(th, td) a[href]:not(.btn, .badge, .dropdown-item, [role="button"]) {
        color: var(--emo-text) !important;
    }

    :is(table.table, table.dataTable) :is(th, td) a[href]:not(.btn, .badge, .dropdown-item, [role="button"]) {
        text-decoration: underline !important;
        text-underline-offset: .15em;
    }

    :is(p, label, .text-body, .text-muted, .text-body-secondary, .form-text,
        .card-text, .card-subtitle, .dropdown-header, .quick-create-heading,
        .quick-create-text small, .menu-heading span):not(.btn, .btn *, .text-white) {
        color: var(--emo-text) !important;
    }

    :is(.nav-link .badge, .badge.counter, .avatar-chip span.text, .progress-bar,
        .form-float label, .form-float .form-text, .list-icon .list-text,
        .media-body .media-text, .media-body .media-heading, blockquote footer,
        .invalid-feedback, .valid-feedback),
    .form-control-file::file-selector-button, .file-upload-input::file-selector-button {
        font-size: max(12px, .875em) !important;
    }

    :is(.form-control, .form-select, .select2-choice, .select2-selection,
        .select2-results, .select2-search input, .tagify__input, .dropdown-item) {
        font-size: max(12px, .875rem) !important;
    }

    body :is(.form-control.form-control-lg, .form-select.form-select-lg) {
        font-size: max(12px, 1.125rem) !important;
    }

    :is(.form-control, .form-select, .select2-choice, .select2-selection__rendered,
        .select2-search input, .tagify__input, .form-label) {
        color: var(--emo-text) !important;
    }
}

body :is(.form-control, .form-select, .table, .dropdown-menu) {
    --bs-table-color: var(--emo-text);
    --bs-table-striped-color: var(--emo-text);
    --bs-table-hover-color: var(--emo-text);
    --bs-dropdown-link-color: var(--emo-text);
    color: var(--emo-text);
}

body :is(input, textarea)::placeholder {
    color: var(--emo-hint) !important;
    opacity: 1;
}

body :is(.header .btn, .header .dropdown-item, .profile-sidebar .profile-mail,
    .profile-sidebar li a, .profile-sidebar .btn, .pbanner-content p, .emo26-footer-line span) {
    font-size: max(12px, .875rem) !important;
}

body :is(.apexcharts-xaxis-label, .apexcharts-yaxis-label) {
    font: 12px var(--emo-font);
    fill: var(--emo-text);
}

body :is(.dashboard-section-heading small, .quick-create-text strong,
    .select2-chosen, .select2-selection__rendered, .profile-sidebar li a),
#emo26-page-content .nav-pills .nav-link,
body.dark #emo26-page-content .nav-pills .nav-link.active {
    color: var(--emo-text) !important;
}

#sidebar .menu-categories :is(a, button, .menu-heading) :is(span:not(.badge), h6),
#sidebar .menu-categories :is(a, button):not(.btn),
body :is(.nav-tabs, .breadcrumb) :is(.nav-link, .breadcrumb-item, a) {
    color: var(--emo-text) !important;
}

#sidebar .menu-categories :is(a, button, .menu-heading, .menu-heading span, a span, button span) {
    font-size: max(12px, .875rem) !important;
}
