@charset "utf-8";

/* ==========================================================================
   Modern Hard Reset (Final Production Version)
   ========================================================================== */

/* 1. REM Base Setup
   - Sets root font-size to 10px (62.5% of 16px).
   - e.g., 1.4rem = 14px, 2.0rem = 20px. */
html {
    font-size: 62.5%;
    -webkit-text-size-adjust: 100%; /* Prevent font scaling in landscape on iOS */
}

/* 2. Box Sizing & Universal Reset
   - Forces border-box for easier layout calculations.
   - Resets all margins, paddings, and borders. */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
    border: 0;
    vertical-align: baseline;
}

/* 3. HTML5 Block Semantics */
article, aside, details, figcaption, figure,
footer, header, hgroup, menu, nav, section, main {
    display: block;
}

/* 4. Body Defaults
   - Restores base font-size to 16px (1.6rem). */
body {
    min-height: 100vh;
    font-size: 1.6rem;
    line-height: 1.6;
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Helvetica Neue", Arial, sans-serif;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

/* 5. Typography Reset
   - Fixes sub/sup alignment broken by universal baseline reset. */
sub, sup {
    font-size: 75%;
    line-height: 0;
    position: relative;
    vertical-align: baseline;
}
sup { top: -0.5em; }
sub { bottom: -0.25em; }

/* 6. List Reset */
ol, ul, li {
    /* list-style: none; */
    list-style-position: inside;
}

/* 7. Link Reset */
a {
    text-decoration: none;
    color: inherit;
}

/* 8. Media Elements (Responsive) */
img, picture, video, canvas, svg {
    display: block;
    max-width: 100%;
    height: auto;
}

/* 9. Form Elements Hard Reset */
button, input, select, textarea {
    font: inherit; /* Inherit 1.6rem from body */
    background-color: transparent;
    border: 0;
    border-radius: 0;
    box-shadow: none;
    appearance: none;
    -webkit-appearance: none;
}

/* 10. Specific Form Fixes */
button {
    cursor: pointer;
    padding: 0;
}

textarea {
    resize: vertical;
}

/* Removes the default 'X' clear button in Webkit search inputs */
input[type="search"]::-webkit-search-decoration,
input[type="search"]::-webkit-search-cancel-button,
input[type="search"]::-webkit-search-results-button,
input[type="search"]::-webkit-search-results-decoration {
    -webkit-appearance: none;
}

/* 11. Accessibility */
[hidden] {
    display: none !important;
}

:focus-visible {
    outline: 2px solid #000;
    outline-offset: 2px;
}

/* 12. Table Reset */
table {
    border-collapse: collapse;
    border-spacing: 0;
}

/* 13. Quote Reset */
blockquote, q {
    quotes: none;
}
blockquote::before, blockquote::after,
q::before, q::after {
    content: '';
    content: none;
}