/* OH!CON look for Admidio, following ohcon.info: Lato for text and headings,
   Encode Sans Semi Condensed for buttons, golden-yellow highlights with near-black
   text. The OH!CON blue stays the main colour (header, links); it is set in
   Admidio's preferences (color_primary #2F5496, color_secondary #1F3864).
   Fonts are self-hosted in ../fonts (SIL OFL, licences alongside).
   Linked from templates/index.tpl and index.reduced.tpl after admidio.css. */

@font-face { font-family: "Lato"; font-style: normal; font-weight: 400; font-display: swap; src: url("../fonts/lato-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Lato"; font-style: italic; font-weight: 400; font-display: swap; src: url("../fonts/lato-latin-400-italic.woff2") format("woff2"); }
@font-face { font-family: "Lato"; font-style: normal; font-weight: 700; font-display: swap; src: url("../fonts/lato-latin-700-normal.woff2") format("woff2"); }
@font-face { font-family: "Lato"; font-style: italic; font-weight: 700; font-display: swap; src: url("../fonts/lato-latin-700-italic.woff2") format("woff2"); }
@font-face { font-family: "Encode Sans Semi Condensed"; font-style: normal; font-weight: 500; font-display: swap; src: url("../fonts/encode-sans-semi-condensed-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Encode Sans Semi Condensed"; font-style: normal; font-weight: 600; font-display: swap; src: url("../fonts/encode-sans-semi-condensed-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Encode Sans Semi Condensed"; font-style: normal; font-weight: 700; font-display: swap; src: url("../fonts/encode-sans-semi-condensed-latin-700-normal.woff2") format("woff2"); }

:root {
    --ohcon-yellow: #f2ca3d;
    --ohcon-yellow-hover: #f0a616;
    --ohcon-yellow-soft: #f9d17a;
    --ohcon-ink: #0d0c0c;
    --ohcon-ui-font: "Encode Sans Semi Condensed", "Lato", "Helvetica Neue", Arial, sans-serif;

    --bs-body-font-family: "Lato", "Helvetica Neue", Helvetica, Arial, sans-serif;
    --bs-body-color: #2c3e50;
    --admidio-header-font-color: #ffffff;
    --admidio-header-link-color: #ffffff;
    --admidio-header-link-color-hover: var(--ohcon-yellow);
    --admidio-menu-bg-color-hover: #2f5496;
    --admidio-menu-font-color-hover: #ffffff;
    --bs-focus-ring-color: rgba(242, 202, 61, 0.55);
}

body, input, select, textarea, .form-control, .form-select {
    font-family: var(--bs-body-font-family);
}

h1, h2, h3, h4, h5, h6, .h1, .h2, .h3, .h4, .h5, .h6, .navbar-brand {
    font-family: var(--bs-body-font-family);
    font-weight: 700;
}

/* Buttons and navigation in the site's button font */
.btn, .nav-link, .navbar, .dropdown-item, .page-link, .badge {
    font-family: var(--ohcon-ui-font);
    font-weight: 600;
}

/* Primary actions: golden yellow, like ohcon.info's buttons */
.btn-primary {
    background-color: var(--ohcon-yellow);
    border-color: var(--ohcon-yellow);
    color: var(--ohcon-ink);
}
.btn-primary:hover, .btn-primary:focus, .btn-primary:active, .btn-primary.active {
    background-color: var(--ohcon-yellow-hover) !important;
    border-color: var(--ohcon-yellow-hover) !important;
    color: var(--ohcon-ink) !important;
}
.btn-primary.disabled, .btn-primary:disabled {
    background-color: var(--ohcon-yellow-soft);
    border-color: var(--ohcon-yellow-soft);
    color: var(--ohcon-ink);
}

/* Selected toggles and active menu items get a yellow marker */
.btn-check:checked + .btn {
    color: var(--ohcon-ink) !important;
    background-color: var(--ohcon-yellow);
    border-color: var(--ohcon-yellow) !important;
}
.admidio-sidebar .nav-link.active, .admidio-sidebar .active > .nav-link {
    box-shadow: inset 4px 0 0 var(--ohcon-yellow);
}
.nav-tabs .nav-link.active {
    border-top: 3px solid var(--ohcon-yellow);
}
.page-item.active .page-link {
    background-color: var(--ohcon-yellow);
    border-color: var(--ohcon-yellow);
    color: var(--ohcon-ink);
}

/* Focus outline and text selection in yellow */
.form-control:focus, .form-select:focus, .form-check-input:focus, .btn:focus-visible {
    border-color: var(--ohcon-yellow);
    box-shadow: 0 0 0 0.25rem var(--bs-focus-ring-color);
}
::selection { background: var(--ohcon-yellow-soft); color: var(--ohcon-ink); }
