/* ==================== */
/* Responsividade Mobile */
/* ==================== */

/* Geral <=768px */
/* Garante que no mobile o header não desapareça mesmo com .hidden */
@media (max-width: 768px) {
  header.hidden {
    display: flex !important;
  }
}
@media (max-width: 768px) {
  .content {
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 1.25rem;
  }

  .column-txt {
    align-items: center;
    text-align: center;
  }

  .column-img img {
    width: 100%;
    height: auto;
    max-width: 25rem;
  }

  .image-content {
    justify-content: center;
    margin-top: 1.25rem;
  }

  .additional-image img {
    max-width: 80%;
  }

  .text-container {
    width: 90%;
    margin: 0 auto;
    text-align: center;
  }

  h1,
  h2 {
    font-size: 1.8rem;
    margin-top: 2.5rem;
  }

  p {
    font-size: 1rem;
  }

  .btn {
    margin: 0 auto;
  }

  .section {
    padding: 1.25rem 1.5rem 0.625rem 1.5rem;
  }

  .dr-marcelo-section {
    background-color: #fdfaf3;
    position: relative;
    z-index: 1;
  }

  /* HEADER fixo com fundo branco */
  header {
    background-color: white;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0 1.25rem; /* 20px */
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 3.75rem; /* 60px */
    z-index: 1000;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
  }

/* Ajusta o logo (centralizado em altura, alinhado à direita) */
.logo {
  position: absolute;
  right: 1rem;
  top: 50%;
  transform: translateY(-50%);
}

  .logo img {
    content: url("https://drmarceloolivan.com/image/dr-marcelo-olivan-logo.png");
    max-height: 2.5rem;
    max-width: 140px;
  }

  #logo-header {
    content: url("https://drmarceloolivan.com/image/dr-marcelo-olivan-logo.png");
    background-color: white;
    padding: 0.625rem 0;
    width: 100%;
    max-width: none;
    display: block;
    margin: 0 auto;
    height: auto;
  }

  .menu-toggle {
    position: absolute;
    left: 1rem;
    top: 50%;
    transform: translateY(-50%);
  }

  .hero {
    height: 100vh;
    min-height: 37.5rem;
    position: relative;
    overflow: hidden;
    background: none !important;
    margin-top: 3.75rem;
  }

  .video-container iframe {
    width: 100vw;
    height: 100vh;
    min-height: 37.5rem;
  }

  .hero-content {
    max-width: 90%;
    left: 5%;
    right: 5%;
    text-align: center;
    z-index: 2;
    padding: 0 0.625rem;
  }

  .hero-content p {
    font-size: 1rem;
    line-height: 1.6;
    color: #fff;
  }

  nav.mobile-menu {
    position: absolute;
    top: 3.75rem;
    right: 0.9375rem;
  }

  img[src="https://institutoolivan.com.br/image/Dr-Marcelo-Olivan-2024-cirurgia-v2.png"] {
    display: none;
  }

  .microlift-container {
    flex-direction: column;
    gap: 1.25rem;
  }

  .microlift-video {
    order: 2;
  }

  .microlift-content {
    max-width: 100%;
    text-align: center;
    order: 1;
  }

  .microlift-accordion p,
  .microlift-accordion ul {
    font-size: 0.95rem;
    line-height: 1.5;
    margin-bottom: 0.9375rem;
  }

  .tratamentos-section {
    padding-bottom: 3.75rem;
  }

  .treatment-card {
    flex: 1 1 100%;
    max-width: 100%;
  }

  .treatment-cards {
    display: flex;
    flex-direction: column;
    gap: 1.875rem;
  }

  .agendamento-section {
    padding-bottom: 3.75rem;
    position: relative;
    z-index: 2;
    background-image: url('https://www.drmarceloolivan.com.br/image/agendamento-2.jpg');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-direction: column;
  }

  .agendamento-content {
    position: relative;
    z-index: 2;
    color: white;
    max-width: 50rem;
    width: 100%;
    padding: 15vh 5vw;
    text-align: center;
    margin: 0 auto;
  }

  .microlift-video video,
  .blefaroplastia-video video,
  .fallback-image {
    width: 100%;
    max-width: 100%;
    height: auto;
    border-radius: 10px;
  }

  .button {
    font-size: 1rem;
    padding: 0.75rem 1.25rem;
    width: 100%;
    max-width: 15.625rem;
    margin: 0.625rem auto;
    display: block;
    word-wrap: break-word;
    white-space: normal;
  }

  .footer-grid {
    grid-template-columns: 1fr;
    text-align: center;
    gap: 1.25rem;
  }

  .footer-col h4::after {
    margin-left: auto;
    margin-right: auto;
  }

  .footer-col p,
  .footer-col a {
    font-size: 0.95rem;
  }

  .copyright-section {
    padding: 1.25rem 0.625rem;
    font-size: 0.85rem;
    text-align: center;
  }

/* =================================== */
/* Ajuste Carrossel Antes/Depois Mobile */
/* =================================== */

.resultado-caso {
  padding: 0 1.25rem; /* Alinha o padding com o resto do site mobile */
}

.resultado-container {
  flex-direction: column; /* Empilha os itens verticalmente */
  gap: 1.25rem; /* Espaçamento entre imagem, thumbs e info */
}

/* Força os itens a ocupar 100% da largura no mobile */
.carousel-principal,
.carousel-thumbs,
.info-paciente {
  flex-basis: 100% !important; 
  width: 100%;
}

/* Transforma as miniaturas em um scroller horizontal */
.carousel-thumbs {
  flex-direction: row; /* Deixa as thumbs lado a lado */
  overflow-x: auto;   /* Adiciona barra de rolagem horizontal se necessário */
  gap: 0.5rem;
  padding-bottom: 5px; /* Espaço para a barra de rolagem não colar na info */
}

.carousel-thumbs img {
  width: 100px; /* Define um tamanho fixo para as miniaturas */
  height: auto;
  flex-shrink: 0; /* Impede que as miniaturas encolham */
}

/* Ajusta o bloco de informações do paciente */
.info-paciente {
  text-align: left; /* Parágrafos longos ficam melhores alinhados à esquerda */
  font-size: 0.95rem;
}

.info-paciente p {
  margin-bottom: 15px; /* Espaçamento padrão entre os parágrafos */
}

/* Estiliza os novos botões para o mobile */
.info-paciente .microlift-btn,
.info-paciente .blefaroplastia-btn {
  display: block; /* Faz o botão ocupar a largura disponível */
  text-align: center; /* Centraliza o texto do botão */
  width: 100%;
  max-width: 300px; /* Limita a largura máxima (opcional) */
  margin-left: auto; /* Centraliza o botão */
  margin-right: auto; /* Centraliza o botão */
  padding: 12px 20px; /* Garante um bom padding */
}

  .animate-underline::after {
    display: none;
  }

  #back-to-top {
    display: none !important;
  }
}

/* Esconde menu desktop e ativa o menu mobile */
@media (max-width: 769px) {
  nav.desktop-menu {
    display: none;
  }
}
@media (min-width: 769px) {
  .menu-toggle {
    display: none;
  }
}

/* Seção Microlift Deep Plane - Cards Explicativos */
/* === MOBILE CAROUSEL - Microlift Cards === */

@media (max-width: 768px) {
  .microlift-deep-cards {
    margin: 0;
    padding: 0;
    padding-top: 60px;
    background: #fff;
  }

  .cards-container {
    display: flex;
    flex-direction: row;
    overflow-x: auto;
    scroll-snap-type: x mandatory;
    scroll-behavior: smooth;
    padding: 0;
    margin: 0;
  }

  .card {
    flex: 0 0 100vw;
    width: 100vw;
    scroll-snap-align: start;
    border-radius: 0 !important;
    margin: 0;
    transform: none !important;
  }

  .card img,
  .card video {
    width: 100vw;
    height: auto;
    max-width: 100vw;
    border-radius: 0 !important;
    object-fit: contain;
    display: block;
  }

  .card:hover {
    transform: none !important;
  }

  /* Dots (paginador) */
.carousel-dots {
  display: flex;
  justify-content: center;
  margin-top: 12px;
  margin-bottom: 24px;
  gap: 6px;
}

.carousel-dots .dot {
  height: 8px;
  width: 8px;
  background-color: #999;
  border-radius: 50%;
  display: inline-block;
  transition: background-color 0.3s ease;
}

.carousel-dots .dot.active {
  background-color: #3c65f5; /* Azul institucional */
}
}

/* Esconde no desktop */
@media screen and (min-width: 768px) {
  .carousel-dots {
    display: none;
  }
}
