/* ===== ESTILOS ADICIONAIS PARA MENU MOBILE E ANIMAÇÕES ===== */

/* Menu Mobile */
@media (max-width: 768px) {
    .nav {
        position: fixed;
        top: 100%;
        left: 0;
        width: 100%;
        height: calc(100vh - 100px);
        background: rgba(255, 255, 255, 0.98);
        backdrop-filter: blur(20px);
        -webkit-backdrop-filter: blur(20px);
        border-top: 1px solid rgba(211, 168, 111, 0.2);
        transition: var(--transicao-suave);
        z-index: 999;
    }
    
    .nav.active {
        top: 100px;
    }
    
    .nav-list {
        flex-direction: column;
        gap: 0;
        padding: 40px 20px;
        height: 100%;
        align-items: center;
        justify-content: flex-start;
    }
    
    .nav-list li {
        width: 100%;
        border-bottom: 1px solid rgba(211, 168, 111, 0.1);
    }
    
    .nav-link {
        display: block;
        padding: 20px 0;
        text-align: center;
        font-size: 1.1rem;
        font-weight: 500;
    }
    
    .mobile-menu-btn.active span:nth-child(1) {
        transform: rotate(45deg) translate(5px, 5px);
    }
    
    .mobile-menu-btn.active span:nth-child(2) {
        opacity: 0;
    }
    
    .mobile-menu-btn.active span:nth-child(3) {
        transform: rotate(-45deg) translate(7px, -6px);
    }
}

/* Animações de entrada */
.animate-in {
    animation: fadeInUp 0.8s ease forwards;
}

.tratamento-card {
    opacity: 0;
    transform: translateY(30px);
    transition: var(--transicao-suave);
}

.tratamento-card.animate-in {
    opacity: 1;
    transform: translateY(0);
}

.valor-item {
    opacity: 0;
    transform: translateX(-30px);
    transition: var(--transicao-suave);
}

.valor-item.animate-in {
    opacity: 1;
    transform: translateX(0);
}

.historia-image {
    opacity: 0;
    transform: scale(0.9);
    transition: var(--transicao-suave);
}

.historia-image.animate-in {
    opacity: 1;
    transform: scale(1);
}

/* Animação de carregamento */
.loading {
    overflow: hidden;
}

.loading::before {
    content: '';
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: var(--cor-branco);
    z-index: 9999;
    display: flex;
    align-items: center;
    justify-content: center;
}

.loading::after {
    content: '';
    position: fixed;
    top: 50%;
    left: 50%;
    width: 50px;
    height: 50px;
    border: 3px solid var(--cor-cinza-claro);
    border-top: 3px solid var(--cor-dourado);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    animation: spin 1s linear infinite;
    z-index: 10000;
}

@keyframes spin {
    0% { transform: translate(-50%, -50%) rotate(0deg); }
    100% { transform: translate(-50%, -50%) rotate(360deg); }
}

/* Dark Mode (Opcional) */
.dark-mode {
    --cor-branco: #1a1a1a;
    --cor-bege-claro: #2d2d2d;
    --cor-texto: #e0e0e0;
    --cor-cinza-claro: #404040;
    --cor-cinza-medio: #b0b0b0;
}

/* Melhorias de acessibilidade */
.btn:focus,
.nav-link:focus,
input:focus,
select:focus,
textarea:focus {
    outline: 2px solid var(--cor-dourado);
    outline-offset: 2px;
}

/* Modo de alto contraste */
@media (prefers-contrast: high) {
    :root {
        --cor-dourado: #b8860b;
        --cor-azul-acinzentado: #4a5568;
        --cor-texto: #000000;
    }
}

/* Redução de movimento para usuários sensíveis */
@media (prefers-reduced-motion: reduce) {
    * {
        animation-duration: 0.01ms !important;
        animation-iteration-count: 1 !important;
        transition-duration: 0.01ms !important;
    }
    
    .whatsapp-float a {
        animation: none;
    }
}

/* Print styles */
@media print {
    .header,
    .whatsapp-float,
    .slider-controls {
        display: none;
    }
    
    .hero {
        min-height: auto;
        page-break-after: always;
    }
    
    section {
        page-break-inside: avoid;
    }
}

/* Hover effects aprimorados */
.tratamento-card {
    position: relative;
    overflow: hidden;
}

.tratamento-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255,255,255,0.4), transparent);
    transition: var(--transicao-suave);
}

.tratamento-card:hover::after {
    left: 100%;
}

/* Microinterações */
.btn {
    position: relative;
    overflow: hidden;
}

.btn::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    width: 0;
    height: 0;
    background: rgba(255, 255, 255, 0.2);
    border-radius: 50%;
    transform: translate(-50%, -50%);
    transition: width 0.6s, height 0.6s;
}

.btn:active::before {
    width: 300px;
    height: 300px;
}

/* Scrollbar personalizada */
::-webkit-scrollbar {
    width: 8px;
}

::-webkit-scrollbar-track {
    background: var(--cor-cinza-claro);
}

::-webkit-scrollbar-thumb {
    background: var(--cor-dourado);
    border-radius: 4px;
}

::-webkit-scrollbar-thumb:hover {
    background: var(--cor-dourado-escuro);
}

/* Seleção de texto personalizada */
::selection {
    background: var(--cor-dourado);
    color: var(--cor-branco);
}

::-moz-selection {
    background: var(--cor-dourado);
    color: var(--cor-branco);
}

/* Estados de erro em formulários */
.form-group.error input,
.form-group.error select,
.form-group.error textarea {
    border-color: #e74c3c;
    box-shadow: 0 0 0 3px rgba(231, 76, 60, 0.1);
}

.form-group.error::after {
    content: 'Campo obrigatório';
    color: #e74c3c;
    font-size: 0.85rem;
    margin-top: 4px;
    display: block;
}

/* Loading state para botões */
.btn.loading {
    opacity: 0.7;
    cursor: not-allowed;
    pointer-events: none;
}

.btn.loading::after {
    content: '';
    position: absolute;
    width: 16px;
    height: 16px;
    border: 2px solid transparent;
    border-top: 2px solid currentColor;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

/* Skeleton loading para cards */
.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;
    }
}

/* Tooltip personalizado */
.tooltip {
    position: relative;
    cursor: help;
}

.tooltip::before {
    content: attr(data-tooltip);
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    background: var(--cor-cinza-escuro);
    color: var(--cor-branco);
    padding: 8px 12px;
    border-radius: 6px;
    font-size: 0.85rem;
    white-space: nowrap;
    opacity: 0;
    visibility: hidden;
    transition: var(--transicao-suave);
    z-index: 1000;
}

.tooltip::after {
    content: '';
    position: absolute;
    bottom: 100%;
    left: 50%;
    transform: translateX(-50%);
    border: 5px solid transparent;
    border-top-color: var(--cor-cinza-escuro);
    opacity: 0;
    visibility: hidden;
    transition: var(--transicao-suave);
}

.tooltip:hover::before,
.tooltip:hover::after {
    opacity: 1;
    visibility: visible;
}

/* Badge de notificação */
.badge {
    position: absolute;
    top: -8px;
    right: -8px;
    background: #e74c3c;
    color: white;
    border-radius: 50%;
    width: 20px;
    height: 20px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.75rem;
    font-weight: bold;
}
