/* Configurações específicas do projeto */
:root {
    --primary-color: #ffd700;
    --secondary-color: #c0c0c0;
    --background-dark: #1a1a2e;
    --background-medium: #16213e;
    --background-light: #0f3460;
    --text-light: #f0f0f0;
    --text-muted: #c0c0c0;
    --border-gold: rgba(255, 215, 0, 0.3);
    --shadow-gold: rgba(255, 215, 0, 0.2);
    --error-color: #ff6b6b;
    --success-color: #51cf66;
    --warning-color: #ffd43b;
}

/* Otimizações de performance */
* {
    -webkit-font-smoothing: antialiased;
    -moz-osx-font-smoothing: grayscale;
}

/* Lazy loading para imagens */
img[data-src] {
    opacity: 0;
    transition: opacity 0.3s ease;
}

img[data-src].loaded {
    opacity: 1;
}

/* REMOVIDO TODAS AS REFERÊNCIAS ÀS FONTES LOCAIS */
/* Usar apenas fontes do Google Fonts ou do sistema */

/* Usar fonte do sistema em vez de baixar */
body {
    font-family: 'Crimson Pro', 'Georgia', 'Times New Roman', serif;
}

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

/* Estados de loading melhorados */
.loading-skeleton {
    background: linear-gradient(90deg, #f0f0f0 25%, #e0e0e0 50%, #f0f0f0 75%);
    background-size: 200% 100%;
    animation: loading 1.5s infinite;
}

@keyframes loading {
    0% { background-position: 200% 0; }
    100% { background-position: -200% 0; }
}

/* Melhorias de contraste para acessibilidade */
@media (prefers-contrast: high) {
    :root {
        --primary-color: #ffff00;
        --border-gold: #ffff00;
    }
    
    .consulta-card {
        border: 2px solid var(--primary-color);
    }
    
    .nav-menu a {
        font-weight: bold;
    }
}

/* Modo escuro forçado */
@media (prefers-color-scheme: dark) {
    body {
        background: linear-gradient(135deg, #0a0a0a 0%, #1a1a2e 50%, #16213e 100%);
    }
}

/* Otimizações para impressão */
@media print {
    .nav-menu,
    .footer,
    .payment-methods,
    .security-badges {
        display: none !important;
    }
    
    body {
        background: white !important;
        color: black !important;
    }
}

/* Melhorias de performance */
.consulta-card {
    will-change: transform;
    transform: translateZ(0);
}

/* Animações otimizadas */
@keyframes fadeIn {
    from { opacity: 0; transform: translateY(20px); }
    to { opacity: 1; transform: translateY(0); }
}

.fade-in {
    animation: fadeIn 0.6s ease-out;
}

/* Melhorias de responsividade */
@media (max-width: 768px) {
    .container {
        padding: 0 15px;
    }
    
    .consulta-grid {
        grid-template-columns: 1fr;
        gap: 20px;
    }
}

/* Melhorias de SEO e acessibilidade */
.visually-hidden {
    position: absolute !important;
    width: 1px !important;
    height: 1px !important;
    padding: 0 !important;
    margin: -1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
}

/* Melhorias de foco para acessibilidade */
button:focus,
input:focus,
textarea:focus,
select:focus {
    outline: 2px solid var(--primary-color);
    outline-offset: 2px;
}

/* Melhorias de hover */
.consulta-card:hover {
    transform: translateY(-5px);
    box-shadow: 0 10px 25px rgba(255, 215, 0, 0.3);
}

/* Melhorias de loading */
.loading {
    position: relative;
    overflow: hidden;
}

.loading::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    animation: loading-shimmer 1.5s infinite;
}

@keyframes loading-shimmer {
    0% { left: -100%; }
    100% { left: 100%; }
}
