/* QESTIT branding for GLPI: logos, font and login page.
   Loaded on every page (incl. login) by the qestit plugin.
   Colours: branding/themes/qestit.scss (the "QESTIT" palette). */

@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 400; font-display: swap; src: url('fonts/poppins-latin-400-normal.woff2') format('woff2'); }
@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 500; font-display: swap; src: url('fonts/poppins-latin-500-normal.woff2') format('woff2'); }
@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 600; font-display: swap; src: url('fonts/poppins-latin-600-normal.woff2') format('woff2'); }
@font-face { font-family: 'Poppins'; font-style: normal; font-weight: 700; font-display: swap; src: url('fonts/poppins-latin-700-normal.woff2') format('woff2'); }

/* Logos, for every palette. GLPI picks "light" logos for dark menus and
   "dark" logos for light backgrounds. Absolute paths on purpose: url()
   inside custom properties resolves against the stylesheet that uses it. */
:root,
:root[data-glpi-theme] {
    --glpi-logo-light: url("/plugins/qestit/img/qestit-logo-white.svg");
    --glpi-logo-light-reduced: url("/plugins/qestit/img/qestit-q.svg");
    --glpi-logo-dark: url("/plugins/qestit/img/qestit-logo.svg");
    --glpi-logo-dark-reduced: url("/plugins/qestit/img/qestit-q.svg");
    --glpi-logo-dark-login: url("/plugins/qestit/img/qestit-logo.svg");
    --glpi-logo-light-login: url("/plugins/qestit/img/qestit-logo-white.svg");
    --tblr-font-sans-serif: 'Poppins', -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', sans-serif;
}

body {
    font-family: var(--tblr-font-sans-serif);
}

/* Expanded sidebar / top bar: the wordmark is ~6:1, so give it width
   instead of GLPI's 100x55 box and keep it centred. */
.page .glpi-logo {
    background-size: contain !important;
    background-position: center !important;
    width: 150px;
    height: 55px;
}

/* ---------------------------------------------------------------- Login */
body.welcome-anonymous {
    background: #000811 url("img/login-bg.svg") center / cover no-repeat fixed;
}

/* The login logo is drawn with `content: url()`, so size it explicitly.
   White wordmark: it sits on the navy background, not on the card. */
.page-anonymous .glpi-logo {
    --logo: var(--glpi-logo-light-login) !important;
    width: 280px;
    height: 46px;
    margin-bottom: 2rem !important;
}

.page-anonymous .main-content-card {
    border: 0;
    border-top: 4px solid #d50032;
    box-shadow: 0 1.5rem 3rem rgba(0, 0, 0, .35);
}

.page-anonymous .card-header h2 {
    font-weight: 600;
}

/* "Help" link under the card sits on the dark background */
.page-anonymous > div > .container-tight > .text-center a,
.page-anonymous .text-muted {
    color: rgba(255, 255, 255, .75) !important;
}
