/*
 * G21 / regressões da conversão estático -> Gutenberg.
 * Referência: dist/ @ a90cb88; mudanças aditivas e escopadas.
 * Não sobrescreve o conteúdo do banco nem o mecanismo do carrossel.
 */

/* R02: restaurar o invólucro e o respiro do bloco "Por que a Technolife".
   O estático limita o conteúdo a 1360px e centraliza a seção. */
body.wp-theme-technolife .tl-portal-reasons.wp-block-group {
  padding-block: 108px 96px;
  padding-inline: max(48px, calc((100vw - 1360px) / 2));
}
body.wp-theme-technolife .tl-portal-reasons > .tl-section-heading.wp-block-group,
body.wp-theme-technolife .tl-portal-reasons > .tl-reason-grid.wp-block-group {
  box-sizing: border-box;
  width: 100%;
  max-width: 1360px;
  margin-inline: auto !important;
}
body.wp-theme-technolife .tl-portal-reasons > .tl-section-heading.wp-block-group {
  margin-block: 0 52px !important;
}

/* R03: o WP aplica margem de fluxo no main e no post-content após header.
   A primeira seção deve começar imediatamente após o menu. */
body.wp-theme-technolife .wp-site-blocks > header.tl-a-header-wrap + main.tl-a-main,
body.wp-theme-technolife .wp-site-blocks > header.tl-a-header-wrap + main,
body.wp-theme-technolife main.tl-a-main > .wp-block-post-content,
body.wp-theme-technolife .tl-a-main .wp-block-post-content > .tl-a-hero.wp-block-group {
  margin-block-start: 0 !important;
}
body.wp-theme-technolife .tl-a-main .wp-block-post-content > .tl-a-hero.wp-block-group {
  margin-block-end: 0 !important;
}
/* A imagem da hero da Assistência começa na borda superior da seção,
   reproduzindo o fundo contínuo da referência (sem corte no topo). */
@media (min-width: 1180px) {
  body.wp-theme-technolife .tl-a-main .tl-a-hero > figure.tl-a-hero-image img {
    top: 0;
    left: 0;
    right: auto;
    width: 100%;
    max-width: none;
    height: 100%;
    object-fit: cover;
    object-position: center;
  }
}

/* R04/R05: na referência original o termo <dt> é sr-only.
   O dado relevante permanece visível e o rótulo acessível ao leitor de tela.
   O WordPress armazena os rótulos como parágrafos: não alterar banco. */
body.wp-theme-technolife .tl-ti-main .tl-ti-hero-stats > .tl-ti-stat:first-child > p.tl-ti-stat-label,
body.wp-theme-technolife .tl-ti-main .tl-ti-about-stats > .tl-ti-stat:nth-child(2) > p.tl-ti-stat-label {
  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;
  clip-path: inset(50%) !important;
  white-space: nowrap !important;
  border: 0 !important;
}

/* R01 / G24-R2: paridade com dist/portal-review.css @ a90cb88.
   A referencia final REV-CLIENTE-001 muda a grade de 700 para 1050px,
   centraliza os cards e reformula por completo sua hierarquia visual.
   Mantem a estrutura Gutenberg editavel e o CTA como unico link por card. */
body.wp-theme-technolife .tl-portal-hero.wp-block-group {
  box-sizing:border-box;
  display:flex;
  align-items:center;
  justify-content:center;
  min-height:740px;
  padding:70px 48px;
}
body.wp-theme-technolife .tl-portal-hero > .tl-journeys.wp-block-columns {
  box-sizing:border-box;
  position:relative;
  z-index:3;
  inset:auto;
  top:auto; right:auto; bottom:auto; left:auto;
  transform:none;
  display:grid;
  grid-template-columns:repeat(2,minmax(0,1fr));
  gap:26px;
  align-items:stretch;
  width:min(100%,1050px);
  max-width:1050px;
  min-height:0;
  height:auto;
  margin:0 auto !important;
  padding:0;
}
body.wp-theme-technolife .tl-portal-hero .tl-journeys > .wp-block-column {
  display:flex;
  flex-direction:column;
  flex-basis:auto !important;
  flex-grow:0;
  max-width:none;
  width:auto !important;
  min-width:0;
  margin:0;
}
body.wp-theme-technolife .tl-portal-hero .tl-journey-card.wp-block-group {
  box-sizing:border-box;
  position:relative;
  isolation:isolate;
  display:flex;
  flex:1 1 auto;
  flex-direction:column;
  min-height:570px;
  height:auto;
  width:100%;
  padding:34px 30px 28px;
  margin:0 !important;
  overflow:hidden;
  border-radius:18px;
  color:#121c39;
  background:rgba(255,255,255,.97);
  box-shadow:0 24px 58px rgba(14,21,53,.15);
  backdrop-filter:blur(10px);
  transition:transform 240ms cubic-bezier(.22,1,.36,1),box-shadow 240ms cubic-bezier(.22,1,.36,1);
}
/* A animação original é um gradiente sobreposto, não uma troca abrupta
   de cor. O pseudo-elemento não intercepta o link estendido P-02. */
body.wp-theme-technolife .tl-portal-hero .tl-journey-card.wp-block-group::before {
  content:"";
  position:absolute;
  z-index:-1;
  pointer-events:none;
  inset:0;
  border-radius:inherit;
  background:linear-gradient(145deg,#4a55a0 0%,#3a4386 62%,#303873 100%);
  opacity:0;
  transform:scale(.975);
  transition:opacity 180ms ease,transform 240ms cubic-bezier(.22,1,.36,1);
}
body.wp-theme-technolife .tl-portal-hero .tl-journey-card.wp-block-group:hover,
body.wp-theme-technolife .tl-portal-hero .tl-journey-card.wp-block-group:focus-within {
  color:#fff;
  background:rgba(255,255,255,.97);
  box-shadow:0 30px 72px rgba(18,25,67,.24);
  transform:translateY(-4px);
}
body.wp-theme-technolife .tl-portal-hero .tl-journey-card.wp-block-group:hover::before,
body.wp-theme-technolife .tl-portal-hero .tl-journey-card.wp-block-group:focus-within::before {
  opacity:1;
  transform:scale(1);
}
/* Evita que a folha global is-layout-flow do Gutenberg introduza gaps
   não existentes no HTML estático. Não posicionar o bloco CTA: seu link
   usa ::after absoluto ancorado no card inteiro. */
body.wp-theme-technolife .tl-portal-hero .tl-journey-card.wp-block-group > :is(figure,h2,p,ul,div) {
  max-width:100%;
}
body.wp-theme-technolife .tl-portal-hero .tl-journey-card > figure.tl-icon.wp-block-image {
  display:grid;
  place-items:center;
  box-sizing:border-box;
  flex:0 0 70px;
  width:70px;
  height:70px;
  padding:0;
  margin:0 0 28px !important;
  border-radius:18px;
  background:#eef0fa;
  transition:background-color 180ms ease,transform 240ms cubic-bezier(.22,1,.36,1);
}
body.wp-theme-technolife .tl-portal-hero .tl-journey-card > figure.tl-icon.wp-block-image img {
  display:block;
  width:43px;
  height:43px;
  object-fit:contain;
  margin:0 auto;
  transition:filter 180ms ease;
}
body.wp-theme-technolife .tl-portal-hero .tl-journey-card.wp-block-group:hover > figure.tl-icon,
body.wp-theme-technolife .tl-portal-hero .tl-journey-card.wp-block-group:focus-within > figure.tl-icon {
  background:rgba(255,255,255,.14);
  transform:translateY(-2px);
}
body.wp-theme-technolife .tl-portal-hero .tl-journey-card.wp-block-group:hover > figure.tl-icon img,
body.wp-theme-technolife .tl-portal-hero .tl-journey-card.wp-block-group:focus-within > figure.tl-icon img {
  filter:brightness(0) invert(1);
}
body.wp-theme-technolife .tl-portal-hero .tl-journey-card h2.tl-journey-audience {
  min-height:0;
  margin:0 0 10px !important;
  font-size:clamp(32px,3.2vw,39px);
  font-weight:800;
  line-height:1.12;
  letter-spacing:-1px;
  color:#3a4386;
}
body.wp-theme-technolife .tl-portal-hero .tl-journey-card p.tl-service-title {
  min-height:0;
  margin:0 !important;
  font-size:18px;
  font-weight:700;
  line-height:1.32;
  color:#121c39;
}
body.wp-theme-technolife .tl-portal-hero .tl-journey-card p.tl-journey-description {
  min-height:0;
  margin:16px 0 20px !important;
  font-size:14.5px;
  line-height:1.48;
  color:#5c6579;
}
body.wp-theme-technolife .tl-portal-hero .tl-journey-card ul.tl-journey-benefits {
  display:grid;
  gap:11px;
  padding:0;
  margin:0 0 24px !important;
  list-style:none;
}
body.wp-theme-technolife .tl-portal-hero .tl-journey-card ul.tl-journey-benefits li {
  padding-left:17px;
  font-size:13.3px;
  line-height:1.4;
  color:#424a61;
}
body.wp-theme-technolife .tl-portal-hero .tl-journey-card ul.tl-journey-benefits li::before {
  top:.45em;
}
body.wp-theme-technolife .tl-portal-hero .tl-journey-card.wp-block-group:hover :is(h2.tl-journey-audience,p.tl-service-title,p.tl-journey-description,ul.tl-journey-benefits li),
body.wp-theme-technolife .tl-portal-hero .tl-journey-card.wp-block-group:focus-within :is(h2.tl-journey-audience,p.tl-service-title,p.tl-journey-description,ul.tl-journey-benefits li) {
  color:#fff;
}
body.wp-theme-technolife .tl-portal-hero .tl-journey-card .tl-buttons.wp-block-buttons {
  display:flex;
  width:100%;
  margin: auto 0 0 !important;
  padding:0;
}
body.wp-theme-technolife .tl-portal-hero .tl-journey-card .tl-buttons .wp-block-button {
  width:100%;
  margin:0;
}
body.wp-theme-technolife .tl-portal-hero .tl-journey-card .wp-block-button__link {
  box-sizing:border-box;
  display:flex;
  align-items:center;
  justify-content:center;
  width:100%;
  min-height:52px;
  padding:0 18px;
  border-radius:8px;
  font-size:14px;
  line-height:1.3;
  font-weight:750;
  text-align:center;
  color:#3a4386;
  background:#eef0fa;
  transition:background-color 180ms ease,color 180ms ease;
}
body.wp-theme-technolife .tl-portal-hero .tl-journey-card.wp-block-group:hover .wp-block-button__link,
body.wp-theme-technolife .tl-portal-hero .tl-journey-card.wp-block-group:focus-within .wp-block-button__link {
  color:#252d68;
  background:#fff;
}
@media (min-width:960px) and (max-width:1179px) {
  body.wp-theme-technolife .tl-portal-hero.wp-block-group {min-height:0;padding:64px 32px 76px;}
  body.wp-theme-technolife .tl-portal-hero > .tl-journeys.wp-block-columns {
    width:min(100%,1080px);
    max-width:1080px;
    grid-template-columns:repeat(2,minmax(0,1fr));
    gap:20px;
  }
  body.wp-theme-technolife .tl-portal-hero .tl-journey-card.wp-block-group {min-height:570px;}
  body.wp-theme-technolife .tl-portal-hero .tl-journey-card h2.tl-journey-audience {font-size:clamp(32px,3.5vw,38px);}
  body.wp-theme-technolife .tl-portal-hero .tl-journey-card p.tl-service-title {font-size:17px;}
}
@media (min-width:768px) and (max-width:959px) {
  body.wp-theme-technolife .tl-portal-hero.wp-block-group {min-height:0;padding:64px 32px 76px;}
  body.wp-theme-technolife .tl-portal-hero > .tl-journeys.wp-block-columns {
    width:min(100%,760px);
    max-width:760px;
    grid-template-columns:minmax(0,1fr);
    gap:24px;
  }
  body.wp-theme-technolife .tl-portal-hero .tl-journey-card.wp-block-group {min-height:0;}
}
@media (max-width:767px) {
  body.wp-theme-technolife .tl-portal-hero.wp-block-group {
    display:block;
    min-height:0;
    padding:52px 18px 64px;
  }
  body.wp-theme-technolife .tl-portal-hero > .tl-journeys.wp-block-columns {
    width:100%;
    max-width:520px;
    grid-template-columns:minmax(0,1fr);
    gap:18px;
    margin:0 auto !important;
  }
  body.wp-theme-technolife .tl-portal-hero .tl-journey-card.wp-block-group {min-height:0;}
  body.wp-theme-technolife .tl-portal-hero .tl-journey-card h2.tl-journey-audience {font-size:clamp(30px,9vw,36px);}
  body.wp-theme-technolife .tl-portal-hero .tl-journey-card p.tl-service-title {font-size:16px;}
}
@media (prefers-reduced-motion: reduce) {
  body.wp-theme-technolife .tl-portal-hero .tl-journey-card.wp-block-group,
  body.wp-theme-technolife .tl-portal-hero .tl-journey-card.wp-block-group::before {transition:none;}
}

/* R06: a fonte de verdade usa duas colunas, cartões claros com contornos
   leves e texto em duas hierarquias. Respeitar o carrossel WP vigente. */
@media (min-width: 960px) {
  body.wp-theme-technolife .tl-ti-main .tl-ti-carousel.is-enhanced
  .tl-ti-feature-grid.wp-block-group {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 18px;
    border-top: 0;
    padding-top: 0;
  }
  body.wp-theme-technolife .tl-ti-main .tl-ti-carousel.is-enhanced
  .tl-ti-feature.wp-block-group {
    min-height: 164px;
    padding: 24px;
    border: 1px solid rgba(58, 67, 134, .10);
    border-radius: 14px;
    background: #f7f9fd;
  }
  body.wp-theme-technolife .tl-ti-main .tl-ti-carousel.is-enhanced
  .tl-ti-feature :is(h4,h3).tl-ti-feature-title {
    margin-bottom: 12px !important;
    font-size: 15px;
    font-weight: 760;
    line-height: 1.4;
  }
  body.wp-theme-technolife .tl-ti-main .tl-ti-carousel.is-enhanced
  .tl-ti-feature p.tl-ti-feature-desc {
    font-size: 14px;
    line-height: 1.55;
  }
  body.wp-theme-technolife .tl-ti-main .tl-ti-carousel.is-enhanced
  .tl-ti-detail-closing {
    border-left: 3px solid #3a4386;
    border-radius: 0;
    background: rgba(233, 237, 249, .66);
    font-size: 14px;
  }
}

/* O carrossel T.I. mantém a navegação; apenas o painel visual é ajustado. */

@media (min-width: 768px) and (max-width: 1179px) {
  body.wp-theme-technolife .tl-portal-reasons.wp-block-group {
    padding: 86px 32px 84px;
  }
}
@media (max-width: 767px) {
  body.wp-theme-technolife .tl-portal-reasons.wp-block-group {
    padding: 72px 18px 76px;
  }
  body.wp-theme-technolife .tl-portal-reasons > .tl-section-heading.wp-block-group {
    margin-bottom: 34px !important;
  }
}

/* G24-R3: ordem aprovada dos dois publicos.
   classes existentes nos blocos Gutenberg persistidos; funciona em
   grid desktop, tablet e pilha mobile sem alterar post_content. */
body.wp-theme-technolife .tl-portal-hero .tl-journeys > .tl-column-first {
  order: 2;
}
body.wp-theme-technolife .tl-portal-hero .tl-journeys > .tl-column-second {
  order: 1;
}
