/* ==========================================================================
   Tokens: the brand's colours, typeface and shared sizes.
   Every other stylesheet uses these variables. Change a value here, not there.
   ========================================================================== */

@font-face { font-family: 'TT Commons Pro'; font-weight: 400; font-style: normal; font-display: swap; src: url('../fonts/tt-commons-pro-400.woff2') format('woff2'); }
@font-face { font-family: 'TT Commons Pro'; font-weight: 500; font-style: normal; font-display: swap; src: url('../fonts/tt-commons-pro-500.woff2') format('woff2'); }
@font-face { font-family: 'TT Commons Pro'; font-weight: 600; font-style: normal; font-display: swap; src: url('../fonts/tt-commons-pro-600.woff2') format('woff2'); }
@font-face { font-family: 'TT Commons Pro'; font-weight: 700; font-style: normal; font-display: swap; src: url('../fonts/tt-commons-pro-700.woff2') format('woff2'); }

:root {
    color-scheme: light;

    /* Primary palette */
    --color-deep-blue: #0E1B64;
    --color-funding-blue: #0592E8;
    /* Funding Blue is too light to carry white text (3.3:1; accessibility guidance asks for 4.5:1).
       Wherever white text sits on blue (buttons, pills, initials) this deeper blue is used instead,
       the same one the FundingConnect app uses for its buttons (4.6:1). */
    --color-button-blue: #3375C9;
    --color-magnolia: #E8F7FD;
    --color-grey: #EDEFF4;
    --color-white: #fff;

    /* Secondary palette, with a pale tint of each for backgrounds */
    --color-sky: #81BDEA;
    --color-lavender: #BBA8EB;
    --color-pistachio: #A3CB8B;
    --color-salmon: #EFA381;
    --color-pink: #E89BD3;
    --color-lavender-pale: #F6EDFC;
    --color-pistachio-pale: #F1F8E3;
    --color-salmon-pale: #FDEFEC;
    --color-pink-pale: #FDEDF9;

    /* Text */
    --color-text: var(--color-deep-blue);
    --color-text-muted: rgba(14, 27, 100, .74);
    --color-error: #B42318;

    /* Form fields: dark enough to be seen clearly against white (accessibility) */
    --color-field-border: rgba(14, 27, 100, .5);
    --font-family: 'TT Commons Pro', system-ui, -apple-system, 'Segoe UI', sans-serif;

    /* Type scale: every heading, title and paragraph size on the site comes from this list.
       The first four shrink on small screens. */
    --text-display: clamp(40px, 5.2vw, 66px);     /* The page heading, one per page */
    --text-heading: clamp(30px, 3.4vw, 44px);     /* Section headings */
    --text-subheading: clamp(24px, 2.2vw, 30px);  /* Headings inside a section: panels, pop-ups, long text */
    --text-lead: clamp(18px, 1.6vw, 22px);        /* Introductions under a heading */
    --text-title: 22px;                           /* Card, list and quote titles */
    --text-title-small: 18px;                     /* Titles in compact lists */
    --text-body: 18px;                            /* Ordinary text */
    --text-small: 16px;                           /* Descriptions inside cards, lists and steps */
    --text-x-small: 14px;                         /* Captions, labels and notes */
    --text-number: clamp(40px, 4.5vw, 60px);      /* Large statistics */

    /* Layout */
    --container-width: 1240px;
    --measure-width: 860px;       /* The widest a narrow column of text should be (questions and answers) */
    --section-space: 80px;        /* Space above and below the content of every section */
    --band-radius: 40px;          /* Rounded top corners of the call-to-action band */
    --container-padding: 32px;
    --header-height: 80px;

    /* Shape */
    --radius-pill: 999px;
    --radius-large: 24px;
    --radius-medium: 16px;
    --radius-small: 10px;
    --shadow-panel: 0 16px 40px rgba(14, 27, 100, .12);

    /* Two-tone icons: the accent part of an icon uses this colour */
    --icon-accent: var(--color-funding-blue);
}

/*
   Breakpoints (media queries cannot use variables, so they are written out):
   1024px and below: tablet
   820px and below:  mobile
*/

@media (max-width: 820px) {
    :root {
        --container-padding: 20px;
        --section-space: 64px;
        --band-radius: 28px;
    }
}
