﻿/*
===============================================================================
 URENWIJZER - BASE STYLESHEET
===============================================================================

 File        : uw-base.css
 Purpose     : Global UrenWijzer design foundation
 Project     : UrenWijzer
 Environment : Development / Acceptance / Production

 Contains:
 - Design tokens / brand colours
 - Global reset
 - Typography
 - Basic HTML elements
 - Shared containers
 - Accessibility foundations

 Naming convention:
 - UrenWijzer custom classes use the prefix: uw-

 IMPORTANT:
 Page-specific styling does NOT belong in this file.

===============================================================================
*/


/* ==========================================================================
   1. URENWIJZER DESIGN TOKENS
   ========================================================================== */

:root {
    /* --------------------------------------------------------------
       Brand colours
       -------------------------------------------------------------- */

    --uw-blue: #002b62;
    --uw-blue-dark: #001f49;
    --uw-red: #ed0016;
    /* --------------------------------------------------------------
       Neutral colours
       -------------------------------------------------------------- */

    --uw-black: #1d1d1b;
    --uw-text: #242424;
    --uw-text-secondary: #555555;
    --uw-white: #ffffff;
    --uw-grey-050: #fafafa;
    --uw-grey-100: #f3f3f3;
    --uw-grey-200: #e8e8e8;
    --uw-grey-300: #d8d8d8;
    /* --------------------------------------------------------------
       Functional colours
       -------------------------------------------------------------- */

    --uw-background: var(--uw-white);
    --uw-surface: var(--uw-white);
    --uw-border: var(--uw-grey-300);
    --uw-link: var(--uw-blue);
    --uw-link-hover: var(--uw-red);
    /* --------------------------------------------------------------
       Typography
       -------------------------------------------------------------- */

    --uw-font-family: Arial, Helvetica, sans-serif;
    --uw-font-size-base: 16px;
    --uw-line-height-base: 1.5;
    --uw-line-height-reading: 1.65;
    /* --------------------------------------------------------------
       Layout
       -------------------------------------------------------------- */

    --uw-content-width: 1440px;
    --uw-reading-width: 760px;
    --uw-page-padding: 5vw;
    /* --------------------------------------------------------------
       Spacing
       -------------------------------------------------------------- */

    --uw-space-xs: 0.5rem;
    --uw-space-sm: 1rem;
    --uw-space-md: 1.5rem;
    --uw-space-lg: 2rem;
    --uw-space-xl: 3rem;
    --uw-space-2xl: 5rem;
    --uw-space-3xl: 7rem;
    /* --------------------------------------------------------------
       Borders
       -------------------------------------------------------------- */

    --uw-border-width: 1px;
}


/* ==========================================================================
   2. DOCUMENT RESET
   ========================================================================== */

*,
*::before,
*::after {
    box-sizing: border-box;
}

html {
    margin: 0;
    padding: 0;
    font-size: var(--uw-font-size-base);
    -webkit-text-size-adjust: 100%;
    scroll-behavior: smooth;
}

body {
    margin: 0;
    padding: 0;
    min-height: 100vh;
    background: var(--uw-background);
    color: var(--uw-text);
    font-family: var(--uw-font-family);
    font-size: 1rem;
    font-weight: 400;
    line-height: var(--uw-line-height-base);
    text-rendering: optimizeLegibility;
    -webkit-font-smoothing: antialiased;
}


/* ==========================================================================
   3. TYPOGRAPHY
   ========================================================================== */

h1,
h2,
h3,
h4,
h5,
h6 {
    margin-top: 0;
    color: var(--uw-blue-dark);
    font-family: var(--uw-font-family);
    font-weight: 700;
    line-height: 1.12;
}

h1 {
    margin-bottom: var(--uw-space-lg);
    font-size: clamp(2.5rem, 4vw, 4.75rem);
    letter-spacing: -0.04em;
}

h2 {
    margin-bottom: var(--uw-space-md);
    font-size: clamp(2rem, 3vw, 3.25rem);
    letter-spacing: -0.03em;
}

h3 {
    margin-bottom: var(--uw-space-sm);
    font-size: clamp(1.5rem, 2vw, 2rem);
}

h4 {
    margin-bottom: var(--uw-space-sm);
    font-size: 1.25rem;
}

p {
    margin-top: 0;
    margin-bottom: var(--uw-space-md);
}

strong,
b {
    font-weight: 700;
}


/* ==========================================================================
   4. LINKS
   ========================================================================== */

a {
    color: var(--uw-link);
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 0.18em;
}

    a:hover {
        color: var(--uw-link-hover);
    }

    a:focus-visible {
        outline: 3px solid var(--uw-red);
        outline-offset: 4px;
    }


/* ==========================================================================
   5. MEDIA
   ========================================================================== */

img,
picture,
svg,
video {
    display: block;
    max-width: 100%;
}

img {
    height: auto;
}


/* ==========================================================================
   6. FORM ELEMENTS
   ========================================================================== */

button,
input,
select,
textarea {
    font: inherit;
}

button {
    cursor: pointer;
}


/* ==========================================================================
   7. SHARED URENWIJZER CONTAINERS
   ========================================================================== */

.uw-container {
    width: min( calc(100% - (var(--uw-page-padding) * 2)), var(--uw-content-width) );
    margin-right: auto;
    margin-left: auto;
}

.uw-reading-width {
    max-width: var(--uw-reading-width);
}


/* ==========================================================================
   8. URENWIJZER TYPOGRAPHIC UTILITIES
   ========================================================================== */

.uw-kicker {
    margin-bottom: var(--uw-space-md);
    color: var(--uw-red);
    font-size: 0.8125rem;
    font-weight: 700;
    letter-spacing: 0.14em;
    line-height: 1.2;
    text-transform: uppercase;
}

.uw-lead {
    max-width: var(--uw-reading-width);
    color: var(--uw-text);
    font-size: clamp(1.125rem, 1.4vw, 1.375rem);
    line-height: var(--uw-line-height-reading);
}

.uw-text-secondary {
    color: var(--uw-text-secondary);
}


/* ==========================================================================
   9. ACCESSIBILITY
   ========================================================================== */

.uw-visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

::selection {
    background: var(--uw-blue);
    color: var(--uw-white);
}


/* ==========================================================================
   10. RESPONSIVE BASE
   ========================================================================== */

@media (max-width: 900px) {

    :root {
        --uw-page-padding: 6vw;
    }
}

@media (max-width: 600px) {

    :root {
        --uw-page-padding: 5vw;
    }

    h1 {
        font-size: 2.5rem;
    }

    h2 {
        font-size: 2rem;
    }
}
