/*
    CSS Reset - A combination of Lazzzer00 and Josh's custom resets
    https://github.com/Lazzzer00/Best-CSS-Reset-2024/blob/main/css_reset.css
    https://www.joshwcomeau.com/css/custom-css-reset
*/

*, *::before, *::after {
    box-sizing: border-box; /* Include padding and border in the element's total width and height */
}

/* Default margins and paddings to 0 */
* {
    margin: 0; 
    padding: 0;
}

body {
    line-height: 1.5; /* WCAG criteria states that line-height should be at least 1.5: improve readability */
    -webkit-font-smoothing: antialiased; /* Fonts anti-aliasing for WebKit-based browsers */
    font-smooth: antialiased; /* Fonts anti-aliasing for non-WebKit-based browsers */
}

body, html {
    height: 100%; /* Make the body element full screen */
    scroll-behavior: smooth; /* Enable smooth scrolling */
}

ul[role='list'], ol[role='list'] {
    list-style: none; /* Turn off list decoration for semantic lists */
}

html:focus-within {
    scroll-behavior: smooth; /* Make the scrolling inside of any scrollable element smooth */
}

a:not([class]) {
    text-decoration-skip-ink: auto; /* Improve link underline appearance */
}

img, picture, svg, video, canvas {
    max-width: 100%; /* Make media elements responsive */
    height: auto;
    vertical-align: middle; /* Improve text alignment next to inline images */
    font-style: italic; /* Style alt text for images that don't load */
    background-repeat: no-repeat; /* Background repeat and size for loading placeholder images */
    background-size: cover;
}

input, button, textarea, select {
    font: inherit; /* Inherit font styles for consistency */
}

p, h1, h2, h3, h4, h5, h6 {
    overflow-wrap: break-word; /* Allow long words to break across multiple lines */
}

/* Disable certain styles for users who prefer reduced motion */
@media (prefers-reduced-motion: reduce) {
    html:focus-within {
        scroll-behavior: auto;
    }
    *, *::before, *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
        transition: none;
    }
}