/*
 * ╔═══════════════════════════════════════════════════════════════════════════╗
 * ║                     CastraPET - Sistema de Controle                        ║
 * ║                         CSS Reset / Normalização                           ║
 * ╚═══════════════════════════════════════════════════════════════════════════╝
 * 
 * Reset moderno para garantir consistência entre navegadores.
 */

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

/* Previne ajustes de tamanho de fonte em iOS */
html {
    -webkit-text-size-adjust: 100%;
    -moz-text-size-adjust: 100%;
    text-size-adjust: 100%;
    scroll-behavior: smooth;
}

/* Remove margens padrão e define altura mínima */
body {
    min-height: 100vh;
    line-height: 1.5;
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
    text-rendering: optimizeLegibility;
}

/* Remove estilos de lista */
ul,
ol {
    list-style: none;
}

/* Reset de imagens e mídia */
img,
picture,
video,
canvas,
svg {
    display: block;
    max-width: 100%;
    height: auto;
}

/* Herda fontes em elementos de formulário */
input,
button,
textarea,
select {
    font: inherit;
    color: inherit;
}

/* Remove estilos de botão padrão */
button {
    background: none;
    border: none;
    cursor: pointer;
    -webkit-appearance: none;
    appearance: none;
}

/* Remove decoração de links */
a {
    color: inherit;
    text-decoration: none;
}

/* Quebra de texto em parágrafos */
p,
h1,
h2,
h3,
h4,
h5,
h6 {
    overflow-wrap: break-word;
}

/* Remove aparência padrão de inputs */
input::-webkit-outer-spin-button,
input::-webkit-inner-spin-button {
    -webkit-appearance: none;
    margin: 0;
}

input[type="number"] {
    -moz-appearance: textfield;
}

/* Remove outline padrão - será personalizado depois */
:focus {
    outline: none;
}

/* Garante cores de impressão */
@media print {

    *,
    *::before,
    *::after {
        -webkit-print-color-adjust: exact !important;
        print-color-adjust: exact !important;
    }
}

/* Scrollbar customizada para WebKit */
::-webkit-scrollbar {
    width: 8px;
    height: 8px;
}

::-webkit-scrollbar-track {
    background: var(--bg-primary);
}

::-webkit-scrollbar-thumb {
    background: var(--border-color);
    border-radius: var(--border-radius-full);
}

::-webkit-scrollbar-thumb:hover {
    background: var(--border-color-light);
}

/* Scrollbar para Firefox */
* {
    scrollbar-width: thin;
    scrollbar-color: var(--border-color) var(--bg-primary);
}

/* Seleção de texto customizada */
::selection {
    background-color: var(--color-primary);
    color: var(--text-primary);
}