/* Seção de recursos com o container desktop alinhado ao frame de 1280px do Figma. */
.features-section {
  padding: 68px 0 104px;
}

/* Bloco central da seção, responsável por segurar título, grade e CTA. */
.features-shell {
  width: min(1280px, calc(100% - 48px));
  margin: 0 auto;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 108px;
}

/* Cabeçalho com largura fixa e alinhamento central como no desktop do Figma. */
.features-header {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 30px;
  text-align: center;
}

/* Título com gradiente ciano-roxo e destaque da marca em peso maior. */
.features-title {
  margin: 0;
  font-family: "Muring Display", system-ui, sans-serif;
  font-size: 38px;
  font-weight: 400;
  line-height: 1.356;
  letter-spacing: 0.76px;
  background: linear-gradient(175.6deg, #57d4ff 0%, #845cff 100%);
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

/* Peso extra apenas para o nome da plataforma dentro do título. */
.features-title strong {
  font-weight: 700;
}

/* Texto de apoio centralizado e limitado à largura do frame. */
.features-description {
  width: 720px;
  max-width: 100%;
  margin: 0;
  color: var(--text);
  font-family: "Muring Text", system-ui, sans-serif;
  font-size: 20px;
  font-weight: 600;
  line-height: 1.47;
}

/* Grade desktop em duas linhas de três cards, com respiro do Figma. */
.features-grid {
  width: 100%;
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  column-gap: 36px;
  row-gap: 112px;
}

/* Card roxo com ícone avançando para fora do topo, como no frame desktop. */
.features-card {
  position: relative;
  min-height: 250px;
  padding: 0 32px 31px;
  border-radius: 25px;
  background: var(--violet);
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  overflow: visible;
}

/* Bloco ciano do ícone, destacado acima do texto e fora do fluxo. */
.features-card__icon {
  width: 104px;
  height: 104px;
  position: absolute;
  top: -52px;
  left: 30px;
  border-radius: 20px;
  background: var(--cyan);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

/* SVGs dos ícones mantêm proporção e escala semelhantes ao Figma. */
.features-card__icon img {
  display: block;
  width: 50px;
  height: 50px;
  object-fit: contain;
}

/* Área interna do conteúdo com o respiro necessário para o ícone flutuante. */
.features-card__content {
  display: flex;
  flex-direction: column;
  gap: 20px;
  padding-top: 98px;
}

/* Título do card em branco com peso semibold e largura próxima à do Figma. */
.features-card__title {
  margin: 0;
  color: #fff;
  font-family: "Muring Display", system-ui, sans-serif;
  font-size: 20px;
  font-weight: 600;
  line-height: 1.47;
  max-width: 310px;
}

/* Texto descritivo do card com mancha mais controlada dentro da caixa roxa. */
.features-card__body {
  margin: 0;
  color: #fff;
  font-family: "Muring Text", system-ui, sans-serif;
  font-size: 20px;
  font-weight: 400;
  line-height: 1.47;
  max-width: 310px;
}

/* CTA centralizado no rodapé da seção, reaproveitando o componente global. */
.features-cta {
  align-self: center;
}

/* O rótulo do CTA mantém a largura do componente original do Figma. */
.features-cta__label {
  width: 240px;
}

/* Breakpoint tablet: a seção passa para duas colunas e reduz a tipografia. */
@media (max-width: 1024px) {
  .features-section {
    padding: 64px 0 88px;
  }

  .features-shell {
    width: min(100%, calc(100% - 40px));
    gap: 96px;
  }

  .features-header {
    gap: 24px;
  }

  .features-title {
    max-width: 760px;
    font-size: 34px;
  }

  .features-description {
    width: 680px;
    font-size: 18px;
  }

  .features-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    column-gap: 28px;
    row-gap: 92px;
  }

  .features-card {
    min-height: 232px;
    padding: 0 26px 26px;
  }

  .features-card__icon {
    width: 92px;
    height: 92px;
    top: -46px;
    left: 24px;
    border-radius: 18px;
  }

  .features-card__icon img {
    width: 28px;
    height: 28px;
  }

  .features-card__content {
    gap: 16px;
    padding-top: 86px;
  }

  .features-card__title,
  .features-card__body {
    max-width: 100%;
    font-size: 18px;
  }
}

/* Breakpoint mobile: cards empilhados e medidas extraídas do frame 924:3423. */
@media (max-width: 480px) {
  .features-section {
    padding: 64px 0 72px;
  }

  .features-shell {
    width: min(327px, calc(100% - 32px));
    gap: 45px;
  }

  .features-header {
    gap: 9px;
  }

  .features-title {
    width: 327px;
    max-width: 100%;
    font-size: 28px;
    line-height: 1.356;
    letter-spacing: 0.56px;
  }

  .features-description {
    width: 319px;
    max-width: 100%;
    font-size: 16px;
    font-weight: 500;
    line-height: 1.47;
  }

  .features-grid {
    gap: 44px;
    grid-template-columns: 1fr;
  }

  .features-card:nth-child(1) {
    order: 1;
  }

  .features-card:nth-child(2) {
    order: 3;
  }

  .features-card:nth-child(3) {
    order: 2;
  }

  .features-card:nth-child(4) {
    order: 6;
  }

  .features-card:nth-child(5) {
    order: 5;
  }

  .features-card:nth-child(6) {
    order: 4;
  }

  .features-card {
    min-height: 143px;
    padding: 0 17.291px 17.291px;
    border-radius: 17.291px;
  }

  .features-card__icon {
    width: 71.932px;
    height: 71.932px;
    top: -30px;
    left: 13px;
    border-radius: 13.833px;
  }

  .features-card__icon img {
    width: 34px;
    height: 34px;
  }

  .features-card:nth-child(1) .features-card__icon img {
    width: 33px;
    height: 29px;
  }

  .features-card:nth-child(2) .features-card__icon img,
  .features-card:nth-child(3) .features-card__icon img,
  .features-card:nth-child(4) .features-card__icon img {
    width: 34px;
    height: 34px;
  }

  .features-card:nth-child(5) .features-card__icon img {
    width: 40px;
    height: 40px;
  }

  .features-card:nth-child(6) .features-card__icon img {
    width: 35px;
    height: 30px;
  }

  .features-card__content {
    gap: 12.45px;
    padding-top: 66px;
  }

  .features-card__title,
  .features-card__body {
    font-size: 13.833px;
    line-height: 1.47;
    max-width: 235.161px;
  }

  .features-cta {
    width: 272.308px;
    height: 66.294px;
    padding: 12.43px;
    gap: 7.136px;
  }

  .features-cta__label {
    width: 198.879px;
    font-size: 14.92px;
    letter-spacing: 0.2984px;
  }

  .features-cta__icon,
  .features-cta__icon img {
    width: 41.433px;
    height: 41.433px;
    flex-basis: 41.433px;
  }
}
