/* ============================================================================
   brand.css - EXAGRES INTERNATIONAL - THE ONE PLACE THE BRAND COLOURS LIVE
   ============================================================================
   Picked from the company logo (2026-10-17):

       BLUE   #1773C8      YELLOW #FFF73B      GREY   #8D8D8D      ORANGE #F4A000

   Loaded straight after the template's style.css on every page (the layouts, the
   login / error pages and the public pages), so the variables below win. Everything
   that is "the brand colour" reads one of them: change a hex HERE and the whole
   site follows. Do not write the hex of a brand colour anywhere else - not in a
   stylesheet, not in a view's <style>, not in a style="" attribute:
       CSS / inline style   var(--primary)  var(--accent)  rgba(var(--primary-rgb), .12)
       JavaScript           BrandColors.primary  (wwwroot/js/brand-colors.js)
       e-mail / PDF (C#)    BrandColors.Primary  (Common/BrandColors.cs) - keep it in step with this file

   WHAT EACH COLOUR IS FOR
       BLUE    primary   buttons, links, active menu item, focus ring, selected state, main chart series
       ORANGE  accent    quick actions, the avatar ring, highlights. TEXT ON ORANGE IS ALWAYS THE DARK INK
       YELLOW  highlight a search match, a "look here" marker. Never text, never a thin line on white
       GREY    neutral   secondary buttons, muted text, borders, icons, disabled

   CONTRAST (WCAG 2.x, measured, not guessed)
       white on blue          4.9 : 1   AA        blue-dark on white     6.4 : 1   AA
       ink    on orange       7.9 : 1   AAA       ink on yellow         15.3 : 1   AAA
       white  on orange       2.1 : 1   FAILS  -> never put white text on orange or yellow
       orange-text on white   5.7 : 1   AA        (orange as TEXT uses --accent-text, not --accent)
       grey on white          3.3 : 1   large text / icons only; small text uses --brand-grey-dark (6.1 : 1)

   STATUS colours (success green, danger red, warning amber, info cyan) are NOT brand
   colours and stay as the template has them: a green tick must stay green.
   ============================================================================ */

:root {
    /* ---- 1. THE FOUR LOGO COLOURS ----------------------------------------- */
    --brand-blue:   #1773C8;
    --brand-orange: #F4A000;
    --brand-yellow: #FFF73B;
    --brand-grey:   #8D8D8D;

    /* ---- 2. THEIR SHADES (derived from the four above) --------------------- */
    --brand-blue-rgb:     23, 115, 200;
    --brand-blue-light:   #1A80DF;   /* gradient end - never a text colour */
    --brand-blue-dark:    #1361A8;   /* hover / pressed; text on a soft blue tint */
    --brand-blue-darker:  #0F4C83;   /* deep gradient stop */
    --brand-blue-soft:    #F2F7FC;   /* tinted backgrounds, badges */
    --brand-blue-tint:    #DFEBF7;   /* chips, selected rows, borders of soft blue */

    --brand-orange-rgb:   244, 160, 0;
    --brand-orange-light: #FFB323;
    --brand-orange-dark:  #D08900;   /* hover */
    --brand-orange-soft:  #FEF4E0;   /* tinted backgrounds */
    --brand-orange-ink:   #2A1A00;   /* the ONLY text colour on orange (7.9 : 1) */
    --brand-orange-text:  #8E5D00;   /* orange-coloured text on white / on soft orange (5.7 : 1) */

    --brand-yellow-rgb:   255, 247, 59;
    --brand-yellow-soft:  #FFFEDC;
    --brand-yellow-ink:   #1B1B1B;   /* text on yellow */

    --brand-grey-rgb:        141, 141, 141;
    --brand-grey-light:      #CDCDCD;
    --brand-grey-dark:       #626262;   /* small text, secondary buttons (6.1 : 1) */
    --brand-grey-dark-rgb:   98, 98, 98;
    --brand-grey-darker:     #414141;
    --brand-grey-soft:       #F1F1F1;

    /* ---- 3. ROLES: the template's own variable names (assets/css/style.css) - */
    --primary:               var(--brand-blue);
    --primary-rgb:           var(--brand-blue-rgb);
    --primary-hover:         var(--brand-blue-dark);
    --primary-transparent:   var(--brand-blue-soft);
    --primary-light:         var(--brand-blue-light);    /* new: gradient / lighter accent */
    --primary-dark:          var(--brand-blue-darker);   /* new: deep gradient stop */

    --secondary:             var(--brand-grey-dark);
    --secondary-rgb:         var(--brand-grey-dark-rgb);
    --secondary-hover:       var(--brand-grey-darker);
    --secondary-transparent: var(--brand-grey-soft);

    --gray-400:              var(--brand-grey);          /* icons, placeholders, disabled */

    /* new roles the template has no name for */
    --accent:                var(--brand-orange);
    --accent-rgb:            var(--brand-orange-rgb);
    --accent-light:          var(--brand-orange-light);
    --accent-hover:          var(--brand-orange-dark);
    --accent-soft:           var(--brand-orange-soft);
    --accent-ink:            var(--brand-orange-ink);
    --accent-text:           var(--brand-orange-text);

    --highlight:             var(--brand-yellow);
    --highlight-rgb:         var(--brand-yellow-rgb);
    --highlight-soft:        var(--brand-yellow-soft);
    --highlight-ink:         var(--brand-yellow-ink);

    /* ---- 4. BOOTSTRAP 5.3's own variables, so a page that only loads Bootstrap agrees */
    --bs-primary:                  var(--brand-blue);
    --bs-primary-rgb:              var(--brand-blue-rgb);
    --bs-link-color:               var(--brand-blue);
    --bs-link-color-rgb:           var(--brand-blue-rgb);
    --bs-link-hover-color:         var(--brand-blue-dark);
    --bs-link-hover-color-rgb:     19, 97, 168;
    --bs-primary-bg-subtle:        var(--brand-blue-tint);
    --bs-primary-border-subtle:    #B9D4F0;
    --bs-primary-text-emphasis:    var(--brand-blue-darker);
    --bs-focus-ring-color:         rgba(var(--brand-blue-rgb), .25);
}

/* ---- 5. SMALL UTILITIES for the colours the template has no class for ------ */
.bg-accent        { background-color: var(--accent) !important; color: var(--accent-ink) !important; }
.bg-accent-soft   { background-color: var(--accent-soft) !important; }
.text-accent      { color: var(--accent-text) !important; }
.border-accent    { border-color: var(--accent) !important; }
.btn-accent       { background-color: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn-accent:hover, .btn-accent:focus, .btn-accent:active {
    background-color: var(--accent-hover); border-color: var(--accent-hover); color: var(--accent-ink);
}

/* A search match / "look here": the highlight yellow, with dark text. */
mark, .mark {
    background-color: rgba(var(--highlight-rgb), .65);
    color: var(--highlight-ink);
    padding: 0 .15em;
    border-radius: 2px;
}
