/* ==========================================================================
   INSTITUTO REVIVER: POLISH LAYER (ALTA COSTURA DIGITAL)
   Passagem Final de Acabamento: Estados de Botões, Microinterações,
   Balanceamento Tipográfico (text-wrap), Feedback Tátil e Alinhamentos
   ========================================================================== */

/* 1. Balanceamento Tipográfico Moderno (Elimina Palavras Órfãs) */
h1, h2, h3 {
  text-wrap: balance;
}

p.lead,
.hero-description {
  text-wrap: pretty;
}

/* 2. Refinamento de Estados dos Botões (Feedback de Luxo) */
.btn {
  will-change: transform, box-shadow;
  user-select: none;
  -webkit-tap-highlight-color: transparent;
}

.btn:active {
  transform: translateY(1px) scale(0.98) !important;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1) !important;
}

.btn-gold {
  position: relative;
  overflow: hidden;
  letter-spacing: 0.16em;
}

.btn-gold::after {
  content: '';
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: linear-gradient(180deg, rgba(255, 255, 255, 0.15) 0%, transparent 100%);
  pointer-events: none;
}

.btn-outline:active {
  background: var(--color-gold-dark);
}

/* 3. Foco Acessível Elegante (Sem Anel Azul Genérico do Navegador) */
a:focus-visible,
button:focus-visible,
input:focus-visible,
select:focus-visible,
textarea:focus-visible {
  outline: 1.5px solid var(--color-gold) !important;
  outline-offset: 3px !important;
}

/* 4. Suavização de Imagens e Carregamento */
img {
  image-rendering: -webkit-optimize-contrast;
  backface-visibility: hidden;
}

/* 5. Alinhamento de Baseline nos Cards de Tecnologia */
.tech-grid {
  align-items: stretch;
}

.tech-card {
  display: flex;
  flex-direction: column;
}

.tech-content {
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  justify-content: flex-start;
}

.tech-title {
  margin-top: 0.4rem;
}

.tech-desc {
  margin-top: auto;
  padding-top: 0.4rem;
}

/* 6. Polimento do Rodapé: Alinhamento das Colunas */
.footer-top {
  align-items: start;
}

.footer-link {
  position: relative;
}

.footer-link::after {
  content: '';
  position: absolute;
  bottom: -2px;
  left: 0;
  width: 0;
  height: 1px;
  background-color: var(--color-gold);
  transition: width var(--transition-fast);
}

.footer-link:hover::after {
  width: 100%;
}

/* 7. Feedback Tátil no WhatsApp Flutuante */
.whatsapp-floating {
  -webkit-tap-highlight-color: transparent;
  will-change: transform;
}

.whatsapp-floating:active {
  transform: scale(0.92) !important;
}

/* 8. Transição Ultra-Suave do Header Sticky */
.site-header {
  transform: translateZ(0);
}

/* 9. Polimento em Telas de Smartphone */
@media (max-width: 480px) {
  .hero-actions .btn {
    letter-spacing: 0.12em;
    font-size: 0.74rem;
  }
  
  .intro-main-image,
  .hero-visual-frame,
  .doctor-editorial-portrait {
    box-shadow: 0 10px 25px rgba(0, 0, 0, 0.05);
  }
}
