/*
 * WHYATT Framework
 * Base styles
 */

:root {
    --wf-background: #ffffff;
    --wf-surface: #f5f7fa;
    --wf-text: #243746;
    --wf-heading: #142635;
    --wf-primary: #214b69;
    --wf-border: #dce5ed;
    --wf-focus: #006da6;
    /* Layout widths */
    --wf-width: 1200px;
    --wf-width-narrow: 800px;
    --wf-width-wide: 1440px;

    /* Responsive spacing */
    --wf-gutter-mobile: 18px;
    --wf-space-xs: 8px;
    --wf-space-sm: 16px;
    --wf-space-md: 24px;
    --wf-space-lg: 40px;
    --wf-space-xl: 48px;
    --wf-space-2xl: 64px;

    /* Typography */
    --wf-font-size: 16px;
    --wf-line-height: 1.65;
    --wf-heading-font: inherit;
    --wf-heading-line-height: 1.2;
    --wf-link-color: var(--wf-primary);

    /* Layout components */
    --wf-main-padding: var(--wf-space-2xl);
    --wf-main-padding-mobile: var(--wf-space-lg);
    --wf-main-min-height: 50vh;

    /* Page presentation */
    --wf-page-padding-compact: 32px;
    --wf-page-padding-generous: 96px;
    --wf-page-padding-compact-mobile: 24px;
    --wf-page-padding-generous-mobile: 64px;
    --wf-content-spacing: var(--wf-space-xl);
    --wf-grid-gap: var(--wf-space-md);
    --wf-flex-gap: var(--wf-space-sm);

    /* Header */
    --wf-header-background: var(--wf-background);
    --wf-header-height: 90px;
    --wf-header-padding: 12px;
    --wf-header-gap: var(--wf-space-md);
    --wf-brand-size: 24px;
    --wf-brand-weight: 700;
    --wf-logo-width: 180px;

    /* Navigation */
    --wf-nav-row-gap: var(--wf-space-sm);
    --wf-nav-column-gap: var(--wf-space-md);
    --wf-nav-weight: 600;
    --wf-submenu-indent: var(--wf-space-sm);

    /* Footer */
    --wf-footer-background: var(--wf-surface);
    --wf-footer-color: var(--wf-text);
    --wf-footer-padding: var(--wf-space-lg);
    --wf-footer-text-spacing: var(--wf-space-sm);

    /* Form controls */
    --wf-control-padding-block: 10px;
    --wf-control-padding-inline: 12px;
    --wf-toggle-padding-block: 8px;
    --wf-toggle-padding-inline: 16px;

    /* Keyboard focus */
    --wf-focus-width: 3px;
    --wf-focus-offset: 4px;
    --wf-gutter: 24px;
    --wf-radius: 8px;
    --wf-font: Arial, Helvetica, sans-serif;
}

*,
*::before,
*::after {
    box-sizing: border-box;
}

body {
    margin: 0;
    background: var(--wf-background);
    color: var(--wf-text);
    font-family: var(--wf-font);
    font-size: var(--wf-font-size);
    line-height: var(--wf-line-height);
    overflow-wrap: break-word;
}

h1, h2, h3, h4, h5, h6 {
    margin-top: 0;
    color: var(--wf-heading);
    font-family: var(--wf-heading-font, inherit);
    line-height: var(--wf-heading-line-height);
}

p {
    margin-top: 0;
}

a {
    color: var(--wf-link-color);
}

img,
video {
    max-width: 100%;
    height: auto;
}

iframe {
    max-width: 100%;
}

button,
input,
textarea,
select {
    font: inherit;
}

:focus-visible {
    outline: var(--wf-focus-width) solid var(--wf-focus);
    outline-offset: var(--wf-focus-offset);
}

[hidden] {
    display: none !important;
}

.screen-reader-text,
.wf-skip-link:not(:focus) {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    overflow: hidden;
    clip-path: inset(50%);
    white-space: nowrap;
}

.wf-skip-link:focus {
    position: fixed;
    top: 50px;
    left: 16px;
    z-index: 99999;
    padding: 12px 20px;
    background: white;
    color: #142635;
}

@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: .01ms !important;
        transition-duration: .01ms !important;
        scroll-behavior: auto !important;
    }
}

/* ==================================================
   NATIVE SMOOTH SCROLLING
   ================================================== */

:root {
    --wf-anchor-offset: 32px;
}

html {
    scroll-behavior: smooth;
    scroll-padding-top: var(--wf-anchor-offset);
}

@media (prefers-reduced-motion: reduce) {
    html {
        scroll-behavior: auto;
    }
}
