/* ============================================
   RESET CSS - Normalização cross-browser
   ============================================ */

/* Box-sizing border-box para todos os elementos */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* Prevenir ajuste de fonte no iOS */
html {
    -webkit-text-size-adjust: 100%;
    -webkit-tap-highlight-color: transparent;
    font-size: 16px;
    scroll-behavior: smooth;
}

/* Reset básico de body */
body {
    margin: 0;
    padding: 0;
    font-family: var(--font-family-base);
    font-size: var(--font-size-base);
    font-weight: var(--font-weight-normal);
    line-height: var(--line-height-normal);
    color: var(--color-text-primary);
    background-color: var(--color-bg-primary);
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

/* Headings */
h1, h2, h3, h4, h5, h6 {
    margin: 0;
    font-weight: var(--font-weight-bold);
    line-height: var(--line-height-tight);
    color: var(--color-text-primary);
}

/* Paragraphs */
p {
    margin: 0;
    line-height: var(--line-height-relaxed);
}

/* Links */
a {
    color: inherit;
    text-decoration: none;
    background-color: transparent;
}

/* Lists */
ul, ol {
    list-style: none;
    margin: 0;
    padding: 0;
}

/* Images */
img {
    max-width: 100%;
    height: auto;
    display: block;
    border-style: none;
}

/* Buttons */
button {
    font-family: inherit;
    font-size: inherit;
    line-height: inherit;
    color: inherit;
    background-color: transparent;
    border: none;
    cursor: pointer;
    padding: 0;
}

button:focus {
    outline: none;
}

/* Inputs */
input,
textarea,
select {
    font-family: inherit;
    font-size: inherit;
    line-height: inherit;
    color: inherit;
    background-color: transparent;
    border: none;
    padding: 0;
}

input:focus,
textarea:focus,
select:focus {
    outline: none;
}

/* Remove default appearance */
input[type="search"]::-webkit-search-decoration,
input[type="search"]::-webkit-search-cancel-button {
    -webkit-appearance: none;
}

/* Tables */
table {
    border-collapse: collapse;
    border-spacing: 0;
}

/* Accessibility */
:focus-visible {
    outline: 2px solid var(--color-primary);
    outline-offset: 2px;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
    *,
    *::before,
    *::after {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
        scroll-behavior: auto !important;
    }
}
