/*
 * Design tokens: the only place colours are written down
 * (TemplateConventionsTest refuses hex colours anywhere else).
 *
 * The owner's brand, redrawn on the design canvas on 2026-11-21
 * (docs/design/boards/Main.dc.html): a white header with the blue logo; Ocean
 * Blue for the logo, the main buttons and the bar under the active item; Deep
 * Ocean for links and blue lettering on light grounds; Ice Sky for soft
 * banners and selected items; Warm Coral for child tags and onboarding accents;
 * gold for the logo's check and the one key action. Gold and coral are always
 * behind Navy Slate lettering, never text on white. Navy Slate is the heading
 * and body colour, Slate the secondary text, Line the borders, Porcelain the
 * page ground and white the cards and the header. Status tones are Mint
 * (success), Amber (attention), Rose (problems), Sky (on file) and Slate (off).
 * TokenContrastTest checks every pair that is put one on the other.
 */
:root {
    color-scheme: light;

    /* Ocean Blue: the logo, the bar under the active item, progress bars, the edge of a secondary button */
    --color-ocean: #0284C7;
    --color-on-ocean: #FFFFFF;

    /*
     * The main button. Ocean Blue as drawn; white lettering on it measures 4.10:1, under the 4.5:1 AA asks, and awaits the
     * owner's ruling (2026-11-21; TokenContrastTest lists the pair apart). Whatever he picks is this one line.
     */
    --color-button-primary: var(--color-ocean);
    --color-button-primary-hover: #0369A1;

    /* Deep Ocean: links and blue lettering on light grounds */
    --color-link: #0369A1;
    --color-link-hover: #075985;

    /* Ice Sky: soft banners, the hero, selected items */
    --color-ice: #F0F9FF;
    --color-ice-border: #BAE6FD;

    /* Warm Coral: child tags and onboarding accents. Navy Slate lettering only. */
    --color-coral: #F26444;
    --color-on-coral: #0F172A;

    /* Gold: the logo's check and the one key action. Navy Slate lettering on it; never text on white. */
    --color-accent: #DDA51F;
    --color-accent-strong: #C9972B;
    --color-on-accent: #0F172A;

    /* Text: Navy Slate for headings and body, Slate for the rest */
    --color-ink: #0F172A;
    --color-heading: var(--color-ink);
    --color-muted: #475569;
    --color-faint: #8A94A6;

    /* Ground, cards, rules: Porcelain, white, Line */
    --color-canvas: #F8FAFC;
    --color-surface: #FFFFFF;
    --color-surface-sunken: var(--color-canvas);
    --color-border: #E2E8F0;
    --color-border-input: #8A94A6;

    /* Rose: problems, removing, errors. #E11D48 is the edge and the solid confirm button (white on it 4.70:1). */
    --color-danger: #E11D48;
    --color-danger-strong: #BE123C;
    --color-danger-tint: #FFE4E6;
    --color-on-danger: #FFFFFF;
    --color-on-danger-tint: #BE123C;

    /* Notices: Amber for attention, Mint for success (Ice Sky, above, for the soft banner) */
    --color-notice-tint: #FEF3C7;
    --color-on-notice: #78350F;
    --color-success: #047857;
    --color-success-tint: #ECFDF5;
    --color-on-success-tint: #047857;

    /* The scrim behind anything that sits over the page */
    --color-scrim: rgb(15 23 42 / 55%);

    /*
     * Status pills: the app's four tones. Words always; colour never alone.
     * Sky is "copy on file", Amber attention and "nothing yet", Slate "not shared". The boards draw no exemption pill, so
     * exemptions are Sky as well for now (provisional, put to the owner).
     */
    --pill-copy-bg: #E0F2FE;
    --pill-copy-ink: #075985;
    --pill-exemption-bg: var(--pill-copy-bg);
    --pill-exemption-ink: var(--pill-copy-ink);
    --pill-attention-bg: #FEF3C7;
    --pill-attention-ink: #92400E;
    --pill-neutral-bg: #E2E8F0;
    --pill-neutral-ink: #334155;

    /* The same statuses in the child care centre's portal, in its own palette (StatusLabels::portalTone) */
    --portal-green-bg: #E7EFE4;
    --portal-green-ink: #3F5238;
    --portal-blue-bg: #E6EFF3;
    --portal-blue-ink: #3D6072;
    --portal-plum-bg: #EFE9F1;
    --portal-plum-ink: #56425F;
    --portal-amber-bg: #F4EAD9;
    --portal-amber-ink: #7A5524;
    --portal-grey-bg: #F1ECE3;
    --portal-grey-ink: #5E566A;

    /* The ring that shows where the keyboard is: Navy Slate. 17:1 on white, and still 3:1 or more beside an Ocean Blue button. */
    --focus-ring: var(--color-ink);

    --font-heading: 'Nunito Sans', system-ui, -apple-system, 'Segoe UI', sans-serif;
    --font-body: 'Inter', system-ui, -apple-system, 'Segoe UI', Roboto, sans-serif;

    --text-xs: 0.8125rem;
    --text-sm: 0.875rem;
    --text-md: 0.9375rem;
    --text-base: 1rem;

    --space-1: 0.25rem;
    --space-2: 0.5rem;
    --space-3: 0.75rem;
    --space-4: 1rem;
    --space-5: 1.25rem;
    --space-6: 1.5rem;
    --space-8: 2rem;
    --space-10: 2.5rem;
    --space-12: 3rem;
    --space-16: 4rem;

    --radius-control: 10px;
    --radius-card: 14px;
    --radius-pill: 999px;
    --radius: var(--radius-control);

    --target-min: 44px;
    --target-button: 48px;
    --target-hero: 52px;

    --page-gutter: 1.5rem;
    --page-max: 70rem;
}
