/* LifeLabo — ajustes do banner principal e dos cards de acesso rápido */

/* Cada tema define a cor de fundo usada no mobile */
.hero-slide-checkup { --slide-bg: var(--navy); }
.hero-slide-medical { --slide-bg: var(--red-dark); }
.hero-slide-home { --slide-bg: var(--turquoise-dark); }

.hero-arrow { cursor: pointer; transition: background .18s, transform .18s; }
.hero-arrow:hover { background: #fff !important; }

/* ---------- Desktop / tablet ----------
   Os cards sobem 46px sobre o banner; setas e paginação ficam acima
   dessa faixa, com folga. */
@media (width > 760px) {
  .hero-slide,
  .hero-slide-copy { min-height: 560px; }
  .hero-slide-copy { padding-bottom: 130px; }
  .hero-arrow { bottom: 82px !important; }
  .hero-pagination { bottom: 97px; }
}

/* ---------- Mobile ----------
   A foto passa a ser o fundo do banner e o texto fica sobre ela,
   com um degradê na cor do tema para garantir a leitura. */
@media (width <= 760px) {
  .hero-carousel-content { align-items: stretch; }
  .hero-carousel-item { display: flex; }

  .hero-slide {
    display: block;
    width: 100%;
    min-height: 600px;
    background: var(--slide-bg) !important;
    border-radius: 20px;
  }

  .hero-slide-visual {
    position: absolute !important;
    inset: 0 0 auto 0 !important;
    height: 330px !important;
    width: 100%;
    background: #f4f6f6;
  }
  .hero-slide-medical .hero-slide-visual { background: #f7f4ef; }
  .hero-slide-visual img {
    object-fit: cover !important;
    object-position: 78% center !important;
    width: 100%;
    height: 100%;
  }
  .hero-slide-medical .hero-slide-visual img { object-position: 62% center !important; }
  .hero-slide-home .hero-slide-visual img { object-position: 85% bottom !important; }

  .hero-slide-visual::after {
    content: "";
    position: absolute;
    inset: 0;
    background: linear-gradient(180deg, transparent 0%, transparent 45%, var(--slide-bg) 100%);
    pointer-events: none;
  }

  .hero-slide-copy,
  .hero-slide-medical .hero-slide-copy,
  .hero-slide-home .hero-slide-copy {
    position: relative;
    z-index: 2;
    background: transparent !important;
    min-height: 600px;
    justify-content: flex-end;
    padding: 270px 24px 96px !important;
  }
  .hero-slide-copy:before { top: 252px; left: 24px; }
  .hero-slide-copy h1 { font-size: 36px; margin: 14px 0; }
  .hero-slide-copy p { margin-bottom: 20px; }

  .doctor-signature { inset: 18px 14px auto auto !important; }

  /* Setas e paginação dentro do banner, na base, sem encostar em nada */
  .hero-arrow { bottom: 24px !important; }
  .hero-arrow-prev { right: 70px !important; }
  .hero-arrow-next { right: 22px !important; }
  .hero-pagination { bottom: 39px; left: 24px; }

  /* Cards abaixo do banner, sem sobrepor */
  .shortcut-section { margin-top: 18px; }
  .shortcut-card { min-height: 150px; }
}

/* Espaço reservado para a seta no rodapé dos cards (texto não encosta nela) */
.shortcut-card { padding-bottom: 58px; }

/* Mobile: no banner de atendimento domiciliar o carro fica na base da foto,
   então a imagem é encurtada para o carro aparecer acima do texto */
@media (width <= 760px) {
  .hero-slide-home .hero-slide-visual { height: 262px !important; }
  .hero-slide-home .hero-slide-visual::after {
    background: linear-gradient(180deg, transparent 0%, transparent 72%, var(--slide-bg) 100%);
  }
}

/* Seção Coleta domiciliar: nova foto da fachada com o carro */
.unit-photo { aspect-ratio: 1312 / 919; }
.unit-photo img { object-fit: cover; }

/* =========================================================
   Botão "Agendar check-up" em verde (desktop e mobile)
   ========================================================= */
.hero-slide-checkup .hero-slide-copy .button-light,
.hero-slide-checkup .hero-slide-copy .button {
  color: #fff !important;
  background: var(--turquoise-dark) !important;
  box-shadow: 0 12px 28px #238c9147 !important;
}
.hero-slide-checkup .hero-slide-copy .button:hover { background: #1d7a7f !important; }

/* =========================================================
   Assinatura da Dra. Camila na altura do ombro
   ========================================================= */
@media (width > 760px) {
  .doctor-signature { top: 49% !important; right: 2.5% !important; }
}

/* =========================================================
   Menu mobile
   ========================================================= */
.menu-toggle { display: none; }
.mobile-nav[hidden] { display: none !important; }

@media (width <= 1020px) {
  .header-inner { gap: 10px; position: relative; }
  .menu-toggle {
    display: inline-flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
    gap: 5px;
    width: 42px;
    height: 42px;
    padding: 0;
    border: 1px solid #17313a1f;
    border-radius: 12px;
    background: #fff;
    cursor: pointer;
    flex-shrink: 0;
  }
  .menu-toggle span {
    display: block;
    width: 18px;
    height: 2px;
    border-radius: 2px;
    background: var(--navy);
    transition: transform .2s, opacity .2s;
  }
  .menu-toggle[aria-expanded="true"] span:nth-child(1) { transform: translateY(7px) rotate(45deg); }
  .menu-toggle[aria-expanded="true"] span:nth-child(2) { opacity: 0; }
  .menu-toggle[aria-expanded="true"] span:nth-child(3) { transform: translateY(-7px) rotate(-45deg); }

  .mobile-nav {
    position: absolute;
    left: 0;
    right: 0;
    top: 100%;
    background: #fff;
    border-bottom: 1px solid #0a314512;
    box-shadow: 0 24px 40px #17313a24;
    max-height: calc(100vh - 72px);
    overflow-y: auto;
  }
  .mobile-nav-inner { display: flex; flex-direction: column; padding: 8px 0 22px; }
  .mobile-nav-inner a {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 15px 4px;
    border-bottom: 1px solid #17313a14;
    color: var(--navy);
    font-size: 16px;
    font-weight: 700;
  }
  .mobile-nav-inner a span { color: var(--red-dark); font-size: 16px; }
  .mobile-nav-inner .mobile-nav-cta {
    justify-content: center;
    margin-top: 18px;
    border: 0;
    border-radius: 10px;
    background: var(--turquoise-dark);
    color: #fff;
    min-height: 52px;
    font-size: 14px;
  }
  html.menu-aberto .whatsapp-float { display: none; }
}

/* =========================================================
   Rediagramação mobile (até 760px)
   ========================================================= */
@media (width <= 760px) {
  /* Cabeçalho */
  .header-inner { min-height: 68px; }
  .brand-link { width: 128px; margin-right: auto; }
  .result-button { margin-left: 0; min-height: 40px; padding-inline: 14px; font-size: 12px; }
  .mobile-menu { width: 38px; height: 38px; }
  .mobile-menu img { width: 30px; height: 30px; }

  /* Banner: setas à esquerda, longe do botão flutuante do WhatsApp */
  .hero-arrow-prev { left: 24px !important; right: auto !important; }
  .hero-arrow-next { left: 70px !important; right: auto !important; }
  .hero-pagination { left: auto; right: 24px; bottom: 39px; }

  /* Mobile: Dra. Camila — assinatura sobre o ombro */
  .doctor-signature { inset: 196px 12px auto auto !important; min-width: 0; padding: 8px 11px 9px; }
  .doctor-signature strong { font-size: 13px; }

  /* Atalhos: linhas compactas */
  .shortcut-section { margin-top: 16px; }
  .shortcut-grid { gap: 10px; }
  .shortcut-card {
    min-height: 0;
    grid-template-columns: 36px 1fr;
    gap: 12px;
    padding: 18px 50px 18px 16px;
    border-width: 3px;
    border-radius: 16px;
  }
  .shortcut-card:hover { transform: none; }
  .shortcut-icon { width: 36px; height: 36px; }
  .shortcut-icon svg { width: 28px; height: 28px; }
  .shortcut-icon .whatsapp-outline { width: 30px; height: 30px; }
  .shortcut-card h2 { font-size: 16px; margin: 4px 0 4px; }
  .shortcut-card p { font-size: 13px; line-height: 1.5; }
  .shortcut-card .arrow { top: 50%; bottom: auto; right: 18px; transform: translateY(-50%); }

  /* Seções: respiro proporcional ao celular */
  .section { padding: 64px 0; }
  .section-title.centered { margin-bottom: 32px; }
  .section-title h2, .exam-copy h2, .unit-copy h2, .about-copy h2, .contact-inner h2 {
    font-size: 32px;
    line-height: 1.1;
    margin: 12px 0;
  }
  .section-title p { font-size: 14px; }

  /* Serviços */
  .differential-grid { gap: 16px; }
  .differential-visual { min-height: 120px; }
  .differential-visual:before { width: 190px; height: 190px; }
  .differential-visual:after { width: 120px; height: 120px; }
  .differential-visual svg { width: 44px; height: 44px; }
  .differential-visual span { font-size: 26px; bottom: 10px; right: 16px; }
  .differential-content { padding: 22px; }
  .differential-content h3 { font-size: 19px; }
  .differential-content p { margin-bottom: 18px; }
  .differential-content a { padding-top: 14px; }

  /* Exames */
  .exam-section { padding: 16px 0 48px; }
  .exam-panel { gap: 28px; padding: 36px 22px 22px; border-radius: 22px; min-height: 0; }
  .exam-copy p { font-size: 14px; margin-bottom: 22px; }
  .exam-search-card { padding: 22px; border-radius: 16px; }

  /* Coleta domiciliar: texto primeiro, foto depois */
  .unit-section.section { padding: 56px 0; }
  .unit-grid { gap: 28px; }
  .unit-copy { order: -1; }
  .unit-mark.unit-photo { border-radius: 20px; min-height: 0; }
  .unit-copy > p { font-size: 14px; margin-bottom: 24px; }
  .unit-copy .button { width: 100%; min-height: 52px; font-size: 13px; text-align: center; }
  .contact-list { gap: 0; margin-top: 22px; }
  .contact-list a { padding: 12px 0; display: flex; justify-content: space-between; align-items: center; }
  .contact-list small { margin: 0; }
  .contact-list strong { font-size: 13px; }

  /* Sobre */
  .about-section { padding: 60px 0; }
  .about-grid { gap: 14px; }
  .about-text { padding-top: 0; }
  .about-text .about-lead { font-size: 18px; line-height: 1.5; }
  .about-text p { font-size: 14px; }

  /* Chamada final */
  .contact-inner { min-height: 0; padding: 60px 0; gap: 26px; }
  .contact-inner .button { width: 100%; }

  /* Rodapé */
  footer { padding: 48px 0 96px; }
  .footer-main { gap: 30px; padding-bottom: 34px; }
  .footer-brand img { width: 160px; }
  .footer-links { gap: 11px; font-size: 13px; }

  /* Página de exames */
  .catalog-hero { padding: 44px 0 40px; }
  .catalog-hero h1 { font-size: 38px; margin: 12px 0 14px; }
  .catalog-hero p { font-size: 14px; }
}

/* Página de exames — cards compactos no celular */
@media (width <= 760px) {
  .catalog-grid { gap: 12px !important; }
  .exam-card { min-height: 0; padding: 20px 20px 16px; border-radius: 16px; }
  .exam-card h2 { font-size: 19px; margin: 10px 0 6px; }
  .exam-card p { margin-bottom: 14px; }
  .exam-card a { padding-top: 12px; }
}
.catalog-empty-msg { color: var(--muted); font-size: 14px; text-align: center; padding: 30px 0; }

/* Chamada final: botão nunca quebra linha */
.contact-inner .button { white-space: nowrap; flex-shrink: 0; }

/* =========================================================
   Ajustes v3 (04/10 – 20h)
   ========================================================= */
.doctor-signature { display: none !important; }

@media (width <= 760px) {
  /* Coleta domiciliar: texto + botão → foto → telefones/endereço */
  .unit-grid { display: flex !important; flex-direction: column; align-items: stretch !important; gap: 0 !important; text-align: left; }
  .unit-copy { display: contents; }
  .unit-copy > .eyebrow,
  .unit-copy > h2,
  .unit-copy > p,
  .unit-copy > .button { order: 1; }
  .unit-copy > .eyebrow { align-self: flex-start; margin-bottom: 4px; }
  .unit-copy > .contact-list { width: 100%; }
  .unit-copy > .contact-list small { min-width: 90px; }
  .unit-mark.unit-photo { order: 2; margin-top: 28px; width: 100%; }
  .unit-copy > .contact-list { order: 3; margin-top: 24px; }
  .unit-copy > .unit-address { order: 4; }

  /* Banner: bolinhas ao lado das setas (fora do alcance do botão do WhatsApp) */
  .hero-pagination { left: 124px !important; right: auto !important; bottom: 39px !important; }

  /* Banner médico: os dois profissionais maiores e centralizados */
  .hero-slide-medical .hero-slide-visual { height: calc((100vw - 30px) * 0.86) !important; overflow: hidden; }
  .hero-slide-medical .hero-slide-visual img {
    position: absolute;
    max-width: none;
    width: calc((100vw - 30px) * 1.5) !important;
    height: auto !important;
    left: calc((100vw - 30px) * -0.47);
    top: 0;
    object-fit: fill !important;
  }
  .hero-slide-medical .hero-slide-copy { padding-top: calc((100vw - 30px) * 0.74) !important; }
  .hero-slide-medical .hero-slide-copy:before { top: calc((100vw - 30px) * 0.74 - 18px); }

  /* Banner domiciliar: carro maior e no centro */
  .hero-slide-home .hero-slide-visual { height: calc((100vw - 30px) * 0.74) !important; overflow: hidden; background: #f2ece7; }
  .hero-slide-home .hero-slide-visual img {
    position: absolute;
    max-width: none;
    width: calc((100vw - 30px) * 1.72) !important;
    height: auto !important;
    left: calc((100vw - 30px) * -0.74);
    top: calc((100vw - 30px) * -0.36);
    object-fit: fill !important;
    transform: none !important;
  }
  .hero-slide-home .hero-slide-visual::after {
    background: linear-gradient(180deg, transparent 0%, transparent 76%, var(--slide-bg) 100%) !important;
  }
  .hero-slide-home .hero-slide-copy { padding-top: calc((100vw - 30px) * 0.76) !important; }
  .hero-slide-home .hero-slide-copy:before { top: calc((100vw - 30px) * 0.76 - 18px); }
}

/* Cards de serviços com foto (Clínico geral, Nutrólogo, Coleta domiciliar) */
.differential-photo { display: block; min-height: 0 !important; aspect-ratio: 3 / 2; padding: 0; background: #eef3f3; }
.differential-photo:before, .differential-photo:after { display: none !important; }
.differential-photo img { display: block; width: 100%; height: 100%; object-fit: cover; object-position: center 30%; transition: transform .4s; }
.differential-card:hover .differential-photo img { transform: scale(1.04); }
.differential-photo.visual-location img { object-position: center 40%; }
@media (width <= 1020px) and (width > 760px) {
  .differential-photo { aspect-ratio: auto; height: 100%; min-height: 220px !important; }
}
@media (width <= 760px) {
  .differential-photo { aspect-ratio: 16 / 10; min-height: 0 !important; }
}

/* =========================================================
   Ajustes v5 (04/10 – 20h40)
   ========================================================= */
/* Novo banner dos médicos: imagem preenche o banner no desktop */
@media (width > 760px) {
  .hero-slide-medical .hero-slide-visual img { object-fit: cover !important; object-position: right center !important; }
}

/* Coleta veio para antes de "Encontre a orientação": ajusta respiros */
.unit-section.section { padding-top: 24px; }
.exam-section { padding-top: 40px; }

/* Ícone do WhatsApp e miniatura do mapa: só no mobile */
.wa-ico { display: none; }
.unit-map { display: none; }

@media (width <= 760px) {
  .unit-section.section { padding-top: 8px; }
  .exam-section { padding: 40px 0 48px; }

  .wa-number { display: inline-flex; align-items: center; gap: 7px; }
  .wa-ico { display: inline-block; width: 17px; height: 17px; color: #25d366; flex-shrink: 0; }

  /* "Ver no mapa" vira miniatura do Google Maps */
  .unit-copy > .contact-list a:nth-child(3) { display: none; }
  .unit-copy > .unit-map {
    display: block;
    order: 3;
    position: relative;
    margin-top: 16px;
    border-radius: 16px;
    overflow: hidden;
    border: 1px solid #17313a1f;
    box-shadow: 0 10px 24px #17313a14;
    background: #eef3f3;
  }
  .unit-map iframe { display: block; width: 100%; height: 190px; border: 0; }
  .unit-map-link {
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 46px;
    background: #fff;
    color: var(--navy);
    font-size: 13px;
    font-weight: 780;
    border-top: 1px solid #17313a14;
  }
  .unit-copy > .unit-address { order: 4; margin-top: 14px; }

  /* Novo banner dos médicos no mobile: dupla centralizada e em destaque */
  .hero-slide-medical .hero-slide-visual { height: calc((100vw - 30px) * 0.74) !important; background: #f3f2ef; }
  .hero-slide-medical .hero-slide-visual img {
    width: calc((100vw - 30px) * 1.7) !important;
    left: calc((100vw - 30px) * -0.67);
    top: 0;
  }
  .hero-slide-medical .hero-slide-visual::after {
    background: linear-gradient(180deg, transparent 0%, transparent 62%, var(--slide-bg) 100%) !important;
  }
  .hero-slide-medical .hero-slide-copy { padding-top: calc((100vw - 30px) * 0.70) !important; }
  .hero-slide-medical .hero-slide-copy:before { top: calc((100vw - 30px) * 0.70 - 18px); }
}
@media (width > 760px) {
  .hero-slide-medical .hero-slide-copy h1 { max-width: 450px !important; }
  .hero-slide-medical .hero-slide-copy p { max-width: 420px !important; }
}
.about-text .about-lead { margin-bottom: 16px; }

/* Fim da página: sem faixa branca ao rolar além do rodapé (iPhone) */
html { background: #f8fbfb; overscroll-behavior-y: none; }
body { background: #fff; }
@media (width <= 760px) {
  footer { padding-bottom: 28px; }
  .footer-bottom { padding-right: 80px; }
}

/* Fim da página: a área "elástica" do celular usa a cor do final de cada página */
html.pg-home, html.pg-home body { background: #f8fbfb !important; }
html.pg-exames, html.pg-exames body { background: var(--navy) !important; }
html.pg-privacidade, html.pg-privacidade body { background: var(--mist) !important; }
html.pg-home main, html.pg-exames main { background: #fff; }
.shortcut-section { background: transparent; }
footer { box-shadow: 0 60vh 0 60vh #f8fbfb; }
.catalog-footer { box-shadow: 0 60vh 0 60vh var(--navy); }

/* Crédito Onda Criative */
.footer-right { display: inline-flex; align-items: center; gap: 18px; flex-wrap: wrap; justify-content: flex-end; }
.footer-dev { opacity: .9; }
.dev-credit { font-weight: 700; color: var(--turquoise-dark); }
.dev-credit:hover { text-decoration: underline; }
.catalog-footer .dev-credit { color: #8fe0dc; }
.catalog-footer .footer-dev { display: inline-block; margin-top: 4px; font-size: 10px; color: #c6dce2; }
@media (width <= 760px) {
  .footer-right { flex-direction: column; align-items: flex-start; gap: 7px; }
}
html.pg-exames .catalog-section { background: var(--mist); }
