/* Dia do Estagiário - IEL | v1
   Baseline estrutural: Instituto Integrador v18.
   Alterações: identidade IEL, hero do mockup aprovado, remoção visual dos painéis
   de estratégia/objetivos, barra de filtros azul/verde e ajustes responsivos. */
:root {
  --iel-blue: #174ea6;
  --iel-blue-deep: #0d3f91;
  --iel-cyan: #0b9ec0;
  --iel-aqua: #63c8c4;
  --iel-mint: #69d6a0;
  --iel-ink: #15365f;
  --iel-muted: #5f6f85;
}

header.instituto-hero {
  min-height: 42rem;
  color: var(--iel-ink) !important;
  background:
    linear-gradient(115deg, rgba(255,255,255,.98) 0%, rgba(250,254,255,.96) 32%, rgba(226,248,251,.90) 62%, rgba(240,252,247,.90) 100%) !important;
  background-color: #f8fdff !important;
  isolation: isolate;
}

header.instituto-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 0;
  pointer-events: none;
  background:
    linear-gradient(128deg, transparent 0 56%, rgba(0,164,219,.12) 56% 60%, transparent 60% 64%, rgba(78,209,208,.16) 64% 68%, transparent 68%),
    radial-gradient(circle at 7% 15%, rgba(101,200,196,.17), transparent 24%),
    radial-gradient(circle at 92% 20%, rgba(105,214,160,.15), transparent 28%),
    radial-gradient(circle at 84% 86%, rgba(23,78,166,.08), transparent 35%);
}

header.instituto-hero::after {
  content: "";
  position: absolute;
  z-index: 1;
  pointer-events: none;
  width: clamp(20rem, 28vw, 30rem);
  height: 39rem;
  left: 50%;
  bottom: -1.5rem;
  transform: translateX(-50%);
  background: url("./estagiaria-hero-v1.png") center bottom / contain no-repeat;
  -webkit-mask-image: radial-gradient(ellipse 82% 72% at 50% 50%, #000 60%, transparent 88%);
  mask-image: radial-gradient(ellipse 82% 72% at 50% 50%, #000 60%, transparent 88%);
  filter: drop-shadow(0 18px 28px rgba(23,78,166,.10));
}

.instituto-hero-shell,
.instituto-page-shell {
  width: min(92%, 96rem);
  max-width: none;
}

.instituto-hero-shell {
  padding-block: 2.5rem 7.2rem;
  z-index: 2;
}

.instituto-hero-top {
  grid-template-columns: minmax(25rem, 1fr) minmax(28rem, 1fr);
  column-gap: clamp(13rem, 17vw, 20rem);
  align-items: start;
}

.instituto-hero-intro {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: .65rem;
  min-width: 0;
}

.instituto-system-logo-window {
  position: relative;
  width: 16.5rem;
  height: 5.1rem;
  overflow: visible;
  flex: 0 0 auto;
}

.instituto-system-logo-original {
  position: static !important;
  width: 100% !important;
  height: 100% !important;
  max-width: none;
  object-fit: contain !important;
  object-position: left center;
  filter: none;
}

.instituto-plan-badge {
  display: inline-flex !important;
  width: fit-content !important;
  max-width: max-content;
  align-self: flex-start;
  margin-top: 1rem;
  white-space: nowrap;
  color: #087f9d !important;
  background: #dff7f7 !important;
  border: 1px solid rgba(11,158,192,.15) !important;
  letter-spacing: .24em !important;
  text-transform: uppercase;
}

.instituto-hero-title {
  max-width: 30rem;
  color: var(--iel-blue) !important;
  font-size: clamp(3.15rem, 4.55vw, 5rem);
  line-height: .91;
  letter-spacing: -.045em;
  text-shadow: none !important;
}

.instituto-hero-tagline {
  color: var(--iel-blue) !important;
  font-weight: 800;
  max-width: 29rem !important;
  font-size: clamp(1.15rem, 1.55vw, 1.55rem) !important;
  line-height: 1.04;
}

.instituto-hero-description {
  color: #52647a !important;
  line-height: 1.55;
  max-width: 28rem !important;
}

/* Panels removed from the approved hero direction. */
.instituto-hero-panels { display: none !important; }

.instituto-stats-grid {
  position: relative;
  z-index: 3;
}

.instituto-hero-top > div:last-child > p {
  color: rgba(23,78,166,.55) !important;
}

.instituto-stats-grid > div {
  min-height: 5.25rem;
  padding: 1rem 1.05rem !important;
  border: 1px solid rgba(23,78,166,.10) !important;
  background: rgba(255,255,255,.82) !important;
  box-shadow: 0 12px 32px rgba(32,87,137,.08);
  backdrop-filter: blur(13px);
}

.instituto-stats-grid svg { color: #097fce !important; }
.instituto-stats-grid dt { color: var(--iel-blue) !important; font-weight: 800 !important; }
.instituto-stats-grid dd { color: #50617a !important; }

/* Search + filters become one floating bar, matching the approved mockup. */
.instituto-hero + .sticky {
  position: sticky;
  top: 0;
  z-index: 40;
  margin-top: -5.8rem;
  background: transparent !important;
  border: 0 !important;
}

.instituto-hero + .sticky .instituto-page-shell {
  padding: 1.15rem 1.4rem !important;
  border-radius: 1.55rem;
  background: linear-gradient(110deg, #0b9ec0 0%, #13a8c7 34%, #14b8a6 73%, #69d6a0 100%);
  box-shadow: 0 18px 40px rgba(16,90,132,.15);
  border: 1px solid rgba(255,255,255,.45);
}

.instituto-search-row {
  grid-template-columns: minmax(32rem, 1fr) auto;
}

.instituto-search-wrap input {
  display: block;
  width: 100%;
  min-width: 0;
  height: 3rem !important;
  border: 1px solid rgba(255,255,255,.68) !important;
  border-radius: .9rem !important;
  background: rgba(255,255,255,.96) !important;
  color: #41536f !important;
  box-shadow: none !important;
}

.instituto-search-wrap svg {
  top: .95rem !important;
  left: .95rem !important;
  color: var(--iel-blue) !important;
}

.instituto-search-row p { color: rgba(255,255,255,.92) !important; }

.instituto-export-pdf {
  height: 3rem !important;
  border-radius: .85rem !important;
  background-color: #174ea6 !important;
  border: 1px solid rgba(255,255,255,.7) !important;
  box-shadow: 0 8px 18px rgba(219,82,13,.18) !important;
}
.instituto-export-pdf:hover { background-color: #0d3f91 !important; }

.instituto-hero + .sticky .instituto-page-shell > div:nth-child(2) {
  background: transparent !important;
  border-radius: 0 !important;
  overflow: visible !important;
}
.instituto-hero + .sticky .instituto-page-shell > div:nth-child(2) > div:last-child {
  padding: .3rem 0 0 !important;
}
.instituto-hero + .sticky .instituto-page-shell > div:nth-child(2) > div:first-child {
  display: none !important;
}

main.instituto-page-shell {
  padding-top: 7rem !important;
}

main section {
  border-radius: 1rem !important;
  box-shadow: 0 10px 30px rgba(24,54,115,.05);
}

main section h2 { color: #20395e; }
main section h3 { color: #17345d; }

@media (max-width: 1279px) {
  .instituto-hero-top {
    grid-template-columns: minmax(23rem, 1fr) minmax(26rem, 1fr);
    column-gap: clamp(8rem, 12vw, 11rem);
  }
  header.instituto-hero::after { width: 23rem; opacity: .96; }
}

@media (max-width: 1023px) {
  header.instituto-hero { min-height: auto; }
  .instituto-hero-shell { padding-bottom: 6.4rem; }
  .instituto-hero-top { grid-template-columns: 1fr; gap: 2rem; }
  header.instituto-hero::after {
    width: 21rem;
    height: 31rem;
    left: auto;
    right: -1.5rem;
    transform: none;
    opacity: .30;
  }
  .instituto-hero-top > div:last-child { width: min(100%, 44rem); }
  .instituto-stats-grid { grid-template-columns: repeat(3, minmax(0,1fr)) !important; }
  .instituto-hero + .sticky { margin-top: -4.8rem; }
  .instituto-search-row { grid-template-columns: 1fr; }
  .instituto-search-row > div:last-child { margin-left: 0 !important; justify-content: space-between; }
}

@media (max-width: 767px) {
  .instituto-hero-shell,
  .instituto-page-shell { width: calc(100% - 1.25rem); }
  .instituto-hero-shell { padding-block: 1.25rem 5.6rem; }
  .instituto-system-logo-window { width: 12.2rem; height: 3.8rem; }
  .instituto-plan-badge { margin-top: .5rem; }
  .instituto-hero-title { font-size: clamp(2.4rem, 12vw, 3.75rem); max-width: 22rem; }
  .instituto-hero-tagline { max-width: 21rem !important; }
  .instituto-hero-description { max-width: 22rem !important; }
  header.instituto-hero::after { display: none; }
  .instituto-stats-grid { grid-template-columns: repeat(2, minmax(0,1fr)) !important; gap: .65rem !important; }
  .instituto-stats-grid > div { min-height: 4.4rem; padding: .75rem !important; }
  .instituto-stats-grid dt { font-size: 1.1rem !important; }
  .instituto-stats-grid dd { font-size: .7rem !important; }
  .instituto-hero + .sticky {
    position: relative;
    top: auto;
    margin-top: -4.2rem;
  }
  .instituto-hero + .sticky .instituto-page-shell { padding: .85rem !important; border-radius: 1.1rem; }
  .instituto-search-row > div:last-child { gap: .6rem !important; }
  .instituto-search-row p { width: 100%; }
  .instituto-export-pdf { width: 100%; justify-content: center; }
  main.instituto-page-shell { padding-top: 2.3rem !important; }
}

/* v1.1: compact filter composition and intentional portrait framing */
@media (min-width: 1024px) {
  header.instituto-hero::after {
    border: 3px solid rgba(213, 224, 0, .82);
    border-radius: 2.25rem;
    -webkit-mask-image: none;
    mask-image: none;
    box-shadow: 0 18px 38px rgba(23,78,166,.10);
  }

  .instituto-hero + .sticky .instituto-page-shell > div:nth-child(2) > div:last-child {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    align-items: end;
    gap: .75rem 1.25rem;
    padding-top: .25rem !important;
  }

  .instituto-hero + .sticky .instituto-page-shell > div:nth-child(2) > div:last-child > div:nth-child(2) {
    display: none !important;
  }

  .instituto-hero + .sticky .instituto-page-shell > div:nth-child(2) > div:last-child > div:nth-child(3) {
    min-width: 0;
  }

  .instituto-hero + .sticky .instituto-page-shell > div:nth-child(2) > div:last-child > div:nth-child(3) > p {
    margin-bottom: .5rem !important;
  }

  main.instituto-page-shell {
    padding-top: 4.8rem !important;
  }
}

/* v2 - ajustes cirúrgicos aprovados em 28/09/2026
   Fonte visual do hero: mockup aprovado pelo usuário.
   Alterações limitadas ao fundo do hero, cor da faixa de filtros e botão PDF. */
:root {
  --iel-filter-aqua: #82e2d6;
  --iel-filter-aqua-deep: #75d9cf;
  --iel-export-blue: #174ea6;
  --iel-export-blue-hover: #0d3f91;
}

/* Fundo fotográfico fornecido, preservado sem conversão ou recompressão. */
header.instituto-hero {
  background-color: #f6fcfd !important;
  background-image: url("./hero-background-v3.png") !important;
  background-size: cover !important;
  background-position: center top !important;
  background-repeat: no-repeat !important;
}

/* v3: fundo limpo, sem textos ou componentes incorporados. */
header.instituto-hero::before {
  background: none !important;
}

/* A própria imagem aprovada já contém a estudante e sua moldura; evita
   sobreposição/duplicação do recorte anterior. */
header.instituto-hero::after {
  display: none !important;
}

/* Cards ficam suficientemente opacos para preservar apenas os dados atuais. */
.instituto-stats-grid > div {
  background: rgba(255,255,255,.94) !important;
  border-color: rgba(23,78,166,.11) !important;
  box-shadow: 0 10px 28px rgba(32,87,137,.08) !important;
  backdrop-filter: blur(10px) !important;
}

/* Faixa de filtros no verde-água exato da amostra enviada (#82E2D6). */
.instituto-hero + .sticky .instituto-page-shell {
  background: linear-gradient(110deg, var(--iel-filter-aqua) 0%, #7fe0d5 52%, var(--iel-filter-aqua-deep) 100%) !important;
  box-shadow: 0 18px 40px rgba(56,147,142,.15) !important;
  border-color: rgba(255,255,255,.62) !important;
}

/* Botão PDF em azul institucional IEL; sem laranja. */
.instituto-export-pdf {
  background-color: var(--iel-export-blue) !important;
  border-color: rgba(255,255,255,.72) !important;
  box-shadow: 0 8px 18px rgba(23,78,166,.18) !important;
  color: #fff !important;
}
.instituto-export-pdf:hover,
.instituto-export-pdf:focus-visible {
  background-color: var(--iel-export-blue-hover) !important;
}

/* Em telas menores o mockup permanece como fundo, mas com crop controlado
   para não inserir artefatos laterais nem afetar a responsividade existente. */
@media (max-width: 1023px) {
  header.instituto-hero {
    background-size: cover !important;
    background-position: 48% top !important;
  }
  header.instituto-hero::before {
    background:
      linear-gradient(90deg, rgba(255,255,255,.985) 0%, rgba(255,255,255,.95) 48%, rgba(248,253,254,.54) 70%, rgba(248,253,254,.14) 100%) !important;
  }
}

@media (max-width: 767px) {
  header.instituto-hero {
    background-position: 38% top !important;
  }
  header.instituto-hero::before {
    background: rgba(248,253,254,.84) !important;
  }
}
