/* ITAPREVI · páginas internas (institucional, benefícios, transparência, simulador) */
@layer sections {

/* ---------- Abertura das páginas: a marca em órbita, sem foto ---------- */
.ph { position: relative; overflow: hidden; margin-top: calc(var(--a11y-h) * -1); padding: calc(var(--a11y-h) + var(--hdr-h) + clamp(48px, 7vw, 100px)) 0 clamp(64px, 8vw, 110px); background: radial-gradient(70% 90% at 82% 30%, #133A6E 0%, var(--night) 62%); }
.ph-art { position: absolute; right: max(-60px, calc((100vw - var(--w)) / 2 - 140px)); top: 50%; width: min(640px, 52vw); aspect-ratio: 640 / 520; transform: translateY(-46%); pointer-events: none; }
.ph-orbit { position: absolute; inset: 0; width: 100%; height: 100%; }
.ph-sym { position: absolute; left: 34%; top: 14%; width: 34%; filter: drop-shadow(0 30px 60px rgba(0,0,0,.45)); opacity: .95; }
.ph-in { position: relative; z-index: 1; }
.ph .t-hero { font-size: clamp(2.6rem, 5.4vw, 5.2rem); max-width: 12ch; }
.crumbs { display: flex; gap: 10px; align-items: center; margin-bottom: 26px; color: var(--fg-3); font-size: .9375rem; }
.crumbs a { text-decoration: none; color: var(--fg-2); }
.crumbs a:hover { color: #fff; text-decoration: underline; }
.ph-lead { margin-top: 24px; max-width: 50ch; font-size: var(--fs-lead); color: var(--fg-2); }
.ph-chips { display: flex; flex-wrap: wrap; gap: 10px; margin-top: 32px; }
.ph-chip { display: inline-flex; align-items: center; gap: 10px; min-height: 44px; padding: 0 16px 0 12px; border-radius: 99px; background: rgba(255,255,255,.07); border: 1px solid var(--line-dark); font-size: .9688rem; color: #fff; text-decoration: none; }
.ph-chip .ico { color: var(--sky-on-dark); }
.ph-chip.link { background: var(--sun); color: var(--sun-ink); border-color: var(--sun); }
.ph-chip.link .ico { color: var(--sun-ink); }

/* ---------- Leitura com índice ---------- */
.pagina-interna { display: grid; grid-template-columns: 260px 1fr; gap: clamp(32px, 5vw, 80px); align-items: start; padding-block: clamp(56px, 7vw, 100px) clamp(80px, 9vw, 130px); }
.indice { position: sticky; top: calc(var(--hdr-h) + 24px); display: grid; gap: 2px; padding: 20px; border-radius: var(--r-lg); background: var(--paper-2); }
.indice h4, .ix-t { font-family: var(--font-display); font-weight: 640; font-size: .9375rem; color: var(--ink-3); margin-bottom: 8px; }
.indice a { position: relative; display: block; padding: 10px 12px 10px 18px; border-radius: 12px; text-decoration: none; color: var(--ink-2); font-size: 1rem; line-height: 1.3; transition: background .2s, color .2s; }
.indice a::before { content: ""; position: absolute; left: 6px; top: 50%; width: 6px; height: 6px; margin-top: -3px; border-radius: 50%; background: var(--orbit); transition: background .2s, transform .3s var(--ease); }
.indice a:hover { background: #fff; color: var(--ink); }
.indice a[aria-current] { background: #fff; color: var(--ink); font-weight: 700; box-shadow: var(--sh-ui); }
.indice a[aria-current]::before { background: var(--sun); transform: scale(1.5); }
.conteudo-legal { display: grid; gap: clamp(40px, 5vw, 64px); min-width: 0; }
.bloco-legal { scroll-margin-top: calc(var(--hdr-h) + 24px); max-width: 78ch; }
.bloco-legal h2 { font-size: clamp(1.8rem, 3vw, 2.6rem); margin-bottom: 10px; }
.bloco-legal .ref { display: inline-flex; align-items: center; gap: 8px; margin-bottom: 18px; color: var(--brand); font-weight: 700; font-size: .9375rem; }
.bloco-legal .ref::before { content: ""; width: 18px; height: 8px; border: 1.5px solid var(--orbit); border-radius: 50%; transform: rotate(-14deg); }
.bloco-legal > p:not(.ref):not(.art) { color: var(--ink-2); margin-bottom: 14px; }
.bloco-legal b { color: var(--ink); }
.resumo { position: relative; margin: 6px 0 22px; padding: 22px 24px 22px 26px; border-radius: var(--r-md); background: #FFF6EA; border: 1px solid #F8D8AE; color: var(--ink); font-size: 1.0625rem; }
.resumo::before { content: ""; position: absolute; left: -1px; top: 18px; bottom: 18px; width: 4px; border-radius: 4px; background: var(--sun); }
.resumo b { color: #8A4B05; }
.bloco-legal .art { margin: 22px 0 6px; font-family: var(--font-display); font-weight: 680; font-stretch: 108%; color: var(--ink); font-size: 1.05rem; }
.bloco-legal .art + p { color: var(--ink-2); }
.mt { margin-top: 16px; }
.pessoas { display: grid; grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); gap: 12px; margin-top: 18px; }
.pessoa { display: grid; grid-template-columns: 52px 1fr; grid-template-rows: auto auto; column-gap: 14px; align-items: center; padding: 16px; border-radius: var(--r-md); background: #fff; border: 1px solid var(--line); }
.pessoa b { align-self: end; font-family: var(--font-display); font-weight: 620; font-size: 1rem; line-height: 1.2; }
.pessoa span { grid-column: 2; color: var(--ink-3); font-size: .9375rem; line-height: 1.3; }
.avatarp { grid-row: 1 / 3; width: 52px; height: 52px; border-radius: 50%; display: grid; place-items: center; background: linear-gradient(140deg, var(--brand-sky), var(--brand-deep)); color: #fff; font-family: var(--font-display); font-weight: 680; position: relative; }
.avatarp::after { content: ""; position: absolute; right: -2px; top: -2px; width: 14px; height: 14px; border-radius: 50%; background: var(--sun); border: 2px solid #fff; }
table.orgao { width: 100%; border-collapse: separate; border-spacing: 0; margin-top: 18px; border: 1px solid var(--line); border-radius: var(--r-md); overflow: hidden; font-size: 1rem; }
table.orgao th { text-align: left; background: var(--paper-2); font-family: var(--font-display); font-weight: 640; padding: 14px 16px; font-size: .9375rem; color: var(--ink-2); }
table.orgao td { padding: 14px 16px; border-top: 1px solid var(--line); vertical-align: top; }
table.orgao td:first-child { color: var(--ink-3); width: 26%; }
.stats-pro { display: grid; grid-template-columns: repeat(3, 1fr); gap: 10px; margin-top: 18px; }
.stat { padding: 18px; border-radius: var(--r-md); background: var(--night); color: #fff; }
.stat:first-child { background: var(--sun); color: var(--sun-ink); }
.stat b { display: block; font-family: var(--font-display); font-weight: 680; font-stretch: 110%; font-size: 2rem; letter-spacing: -.03em; color: inherit; }
.stat span { font-size: .9375rem; opacity: .8; }

/* ---------- Portal da transparência ---------- */
.portal { display: grid; grid-template-columns: 280px 1fr; gap: clamp(28px, 4vw, 64px); align-items: start; padding-block: clamp(56px, 7vw, 100px) clamp(80px, 9vw, 130px); }
.pt-menu { position: sticky; top: calc(var(--hdr-h) + 24px); display: grid; gap: 2px; padding: 18px; border-radius: var(--r-lg); background: var(--paper-2); max-height: calc(100vh - var(--hdr-h) - 48px); overflow: auto; }
.pt-menu .grupo { font-family: var(--font-display); font-weight: 640; font-size: .875rem; color: var(--ink-3); padding: 14px 10px 6px; }
.pt-menu .grupo:first-child { padding-top: 0; }
.pt-menu a { display: flex; justify-content: space-between; padding: 10px 12px; border-radius: 12px; text-decoration: none; color: var(--ink-2); font-size: 1rem; }
.pt-menu a:hover { background: #fff; color: var(--ink); }
.pt-menu a.ativo { background: var(--ink); color: #fff; font-weight: 700; }
.pt-menu .m { opacity: .6; }
#ptConteudo { min-width: 0; }
.pt-painel h2 { font-size: clamp(1.9rem, 3.2vw, 2.8rem); margin-bottom: 12px; }
.pt-desc { color: var(--ink-2); max-width: 64ch; margin-bottom: 16px; }
.chip-up { display: inline-flex; align-items: center; gap: 8px; padding: 6px 14px 6px 10px; border-radius: 99px; background: #E3F4EA; color: var(--ok); font-weight: 700; font-size: .875rem; }
.chip-up i { width: 8px; height: 8px; border-radius: 50%; background: currentColor; }
.pt-filtros { display: grid; grid-template-columns: 200px 1fr; gap: 10px; margin: 22px 0 14px; }
.pt-filtros select, .pt-filtros input { height: 54px; padding: 0 16px; border-radius: 14px; border: 1.5px solid var(--line); background: #fff; font-size: 1rem; }
.pt-filtros select:focus, .pt-filtros input:focus { border-color: var(--brand); outline: none; }
.tabela-scroll { overflow-x: auto; border: 1px solid var(--line); border-radius: var(--r-md); }
table.docs { width: 100%; border-collapse: collapse; font-size: 1rem; }
table.docs th { position: sticky; top: 0; text-align: left; padding: 14px 16px; background: var(--paper-2); font-family: var(--font-display); font-weight: 640; font-size: .875rem; color: var(--ink-2); }
table.docs td { padding: 14px 16px; border-top: 1px solid var(--line); vertical-align: middle; }
table.docs tr:hover td { background: #FAFCFE; }
table.docs .num, table.docs .dt { font-family: var(--font-display); font-weight: 600; white-space: nowrap; color: var(--ink-2); }
table.docs .tit { display: block; font-weight: 700; }
table.docs .dsc { display: block; color: var(--ink-3); font-size: .9375rem; }
.btn-baixar { display: inline-flex; align-items: center; min-height: 40px; padding: 0 14px; border-radius: 99px; background: var(--ink); color: #fff; font-family: var(--font-display); font-weight: 620; font-size: .875rem; text-decoration: none; white-space: nowrap; }
.btn-baixar:hover { background: var(--brand-deep); }
.btn-baixar.sec { background: var(--paper-2); color: var(--ink); box-shadow: inset 0 0 0 1px var(--line); }
.pt-nota { margin-top: 14px; color: var(--ink-3); font-size: .9375rem; }
.pt-vazio { display: grid; gap: 4px; padding: 28px; border-radius: var(--r-md); background: var(--paper-2); color: var(--ink-2); }
.pt-vazio b { font-family: var(--font-display); color: var(--ink); }
.pt-links { display: grid; grid-template-columns: repeat(2, 1fr); gap: 10px; margin-top: 18px; }
.pt-links .tr { display: flex; justify-content: space-between; align-items: center; gap: 16px; padding: 18px 20px; border-radius: var(--r-md); border: 1px solid var(--line); background: #fff; text-decoration: none; transition: border-color .2s, transform .3s var(--ease), box-shadow .3s; }
.pt-links .tr:hover { border-color: var(--ink); transform: translateY(-2px); box-shadow: var(--sh-ui); }
.pt-links .tr > div:first-child { font-family: var(--font-display); font-weight: 640; line-height: 1.25; }
.pt-links .tr span { display: block; font-family: var(--font-body); font-weight: 400; color: var(--ink-3); font-size: .9375rem; margin-top: 4px; }
.pt-links .ext { flex: none; width: 40px; height: 40px; border-radius: 50%; display: grid; place-items: center; background: var(--paper-2); color: var(--brand); font-weight: 700; }

/* ---------- Simulador completo ---------- */
.simpage { background: var(--paper-2); padding-block: clamp(48px, 6vw, 90px) clamp(80px, 9vw, 130px); }
.simpage-grid { display: grid; grid-template-columns: .95fr 1.05fr; gap: clamp(24px, 4vw, 56px); align-items: start; }
.simform { padding: clamp(22px, 3vw, 36px); display: grid; gap: 20px; border-radius: var(--r-xl); box-shadow: var(--sh-ui); }
.sf-t { font-size: clamp(1.5rem, 2.2vw, 2rem); }
.sf-row { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; align-items: start; }
.sf-row.three { grid-template-columns: 1fr 1fr 1.3fr; align-items: end; }
.sf-f { display: grid; gap: 8px; }
.sf-f label, .sf-l { font-weight: 700; font-size: 1rem; }
.sf-f input { height: 56px; padding: 0 16px; border-radius: 14px; border: 1.5px solid var(--line); background: var(--paper-2); font-size: 1.0625rem; width: 100%; }
.sf-f input:focus { border-color: var(--brand); background: #fff; outline: none; }
.sf-f small, .sf-hint { color: var(--ink-3); font-size: .9375rem; line-height: 1.4; }
.sf-hint { margin-top: -10px; }
.seg.wide { grid-template-columns: 1fr 1fr; }
.sf-group { display: grid; gap: 10px; padding: 18px; border-radius: var(--r-md); background: var(--paper-2); }
.sf-group .sf-f input { background: #fff; }
.sf-group .seg span { background: #fff; }
.sf-group .sf-hint { margin-top: 0; }
.sf-adv summary { cursor: pointer; font-weight: 700; color: var(--brand); min-height: 44px; display: flex; align-items: center; }
.sf-adv .sf-f { margin-top: 8px; }
.sf-err { padding: 14px 16px; border-radius: 14px; background: #FDECEA; color: #9B1C1C; font-weight: 600; }
.simform .btn { justify-self: start; }
.sf-priv { display: flex; gap: 10px; align-items: center; color: var(--ink-3); font-size: .9375rem; }
.simpage-out { position: sticky; top: calc(var(--hdr-h) + 20px); display: grid; gap: 16px; }
.sim-detail { padding: clamp(22px, 3vw, 32px); display: grid; gap: 14px; border-radius: var(--r-xl); }
.det { display: grid; gap: 8px; }
.det details { border: 1px solid var(--line); border-radius: 16px; background: #fff; }
.det summary { display: flex; justify-content: space-between; align-items: center; gap: 12px; min-height: 56px; padding: 0 18px; cursor: pointer; list-style: none; }
.det summary::-webkit-details-marker { display: none; }
.det summary b { font-family: var(--font-display); font-weight: 640; }
.det summary span { font-family: var(--font-display); font-weight: 640; color: var(--brand); }
.det details[open] summary { border-bottom: 1px solid var(--line); }
.det .hoje { padding: 12px 18px 0; color: var(--ink-3); font-size: .9375rem; }
.det ul { list-style: none; margin: 0; padding: 8px 18px 16px; display: grid; gap: 8px; }
.det li { display: grid; grid-template-columns: 24px 1fr; gap: 8px; font-size: 1rem; color: var(--ink-2); }
.det li .st { width: 22px; height: 22px; border-radius: 50%; display: grid; place-items: center; font-size: .8125rem; font-weight: 800; background: var(--paper-2); color: var(--ink-3); }
.det li.ok .st { background: #E3F4EA; color: var(--ok); }
.det li b { color: var(--ink); }
.sim-legal { color: var(--ink-3); font-size: .9375rem; }
.sim-detail .btn { justify-self: start; }

@media (max-width: 1100px) {
  .pagina-interna, .portal, .simpage-grid { grid-template-columns: 1fr; }
  .indice, .pt-menu { position: sticky; top: var(--hdr-h); z-index: 5; display: flex; overflow-x: auto; gap: 6px; padding: 10px; border-radius: 18px; max-height: none; scrollbar-width: none; box-shadow: var(--sh-ui); background: rgba(242,245,249,.96); backdrop-filter: blur(10px); }
  .indice::-webkit-scrollbar, .pt-menu::-webkit-scrollbar { display: none; }
  .ix-t, .indice h4, .pt-menu .grupo { display: none; }
  .indice a, .pt-menu a { flex: none; white-space: nowrap; background: #fff; }
  .indice a::before { display: none; }
  .indice a { padding-left: 12px; }
  .simpage-out { position: relative; top: auto; }
  .ph-art { opacity: .35; right: -120px; width: 90vw; }
}
@media (max-width: 720px) {
  .stats-pro { grid-template-columns: 1fr 1fr; }
  .pt-links { grid-template-columns: 1fr; }
  .pt-filtros { grid-template-columns: 1fr; }
  .sf-row, .sf-row.three { grid-template-columns: 1fr; }
  table.orgao, table.orgao tbody, table.orgao tr, table.orgao td { display: block; width: 100%; }
  table.orgao tr:first-child { display: none; }
  table.orgao tr { padding: 12px 16px; border-top: 1px solid var(--line); }
  table.orgao td { border: 0; padding: 2px 0; width: auto !important; }
  table.orgao td:nth-child(2)::before { content: "Titular: "; color: var(--ink-3); }
  table.orgao td:nth-child(3)::before { content: "Suplente: "; color: var(--ink-3); }
  .ph { padding-top: calc(var(--a11y-h) + var(--hdr-h) + 36px); }
}
}
@layer sections {
@media (max-width: 720px) {
  .ph-art { display: none; }
  .ph .t-hero { font-size: clamp(2.3rem, 10.4vw, 2.9rem); max-width: none; }
  .ph-lead { font-size: 1.0625rem; margin-top: 18px; }
  .ph-chips { gap: 8px; margin-top: 26px; }
  .ph-chip { min-height: 40px; font-size: .875rem; }
  .pagina-interna, .portal { padding-block: 28px 80px; gap: 28px; }
  .bloco-legal h2 { font-size: 1.85rem; }
  .resumo { padding: 18px 18px 18px 22px; font-size: 1rem; }
  /* tabela de documentos vira lista de cartões */
  .tabela-scroll { border: 0; overflow: visible; }
  table.docs, table.docs tbody, table.docs tr, table.docs td { display: block; width: 100%; }
  table.docs thead { display: none; }
  table.docs tr { position: relative; margin-bottom: 10px; padding: 16px 16px 18px; border: 1px solid var(--line); border-radius: 18px; background: #fff; }
  table.docs td { padding: 0; border: 0; }
  table.docs td.num { display: inline; font-size: .875rem; color: var(--brand); }
  table.docs td.dt { display: inline; font-size: .875rem; }
  table.docs td.dt { display: block; margin-top: -6px; margin-bottom: 12px; color: var(--ink-3); }
  table.docs td:nth-child(2) { margin: 8px 0 12px; }
  table.docs tr:hover td { background: none; }
  .btn-baixar { min-height: 44px; padding: 0 18px; }
  .simpage { padding-block: 28px 80px; }
  .simform { padding: 22px 18px; border-radius: 28px; }
}
}

/* ---------- Pró-Gestão ---------- */
@layer sections {
.pg { padding-block: clamp(70px, 8vw, 120px); }
.pg-grid { display: grid; grid-template-columns: 1.1fr .9fr; gap: clamp(32px, 5vw, 80px); align-items: center; }
.pg-intro { display: grid; gap: 18px; }
.pg-intro p { color: var(--ink-2); font-size: 1.0625rem; max-width: 58ch; }
.pg-levels { display: flex; gap: 8px; margin-top: 8px; }
.pg-levels span { display: grid; place-items: center; gap: 2px; min-width: 76px; min-height: 76px; padding: 8px; border-radius: 18px; border: 1px solid var(--line); color: var(--ink-3); font-size: .75rem; font-weight: 700; text-align: center; }
.pg-levels b { font-family: var(--font-display); font-weight: 700; font-size: 1.6rem; color: var(--ink-3); line-height: 1; }
.pg-levels .on { background: var(--sun); border-color: var(--sun); color: var(--sun-ink); }
.pg-levels .on b { color: var(--sun-ink); }
.pg-seal { position: relative; aspect-ratio: 1; display: grid; place-items: center; border-radius: 50%; background: radial-gradient(circle at 50% 35%, #173D72, var(--night) 70%); box-shadow: 0 60px 100px -50px rgba(7,19,39,.8); overflow: hidden; }
.pg-ring { position: absolute; inset: 0; width: 100%; height: 100%; animation: spin 60s linear infinite; }
.pg-seal-in { position: relative; text-align: center; display: grid; justify-items: center; gap: 6px; padding: 18%; color: #fff; }
.pg-seal .pg-badge { width: 64px; height: 64px; border-radius: 20px; display: grid; place-items: center; background: var(--sun); color: var(--sun-ink); }
.pg-seal .pg-badge .ico { width: 34px; height: 34px; }
.pg-seal .pg-badge .ic-d { fill: #fff; }
.pg-k { font-family: var(--font-display); font-weight: 640; letter-spacing: .02em; color: rgba(255,255,255,.8); }
.pg-lv { font-family: var(--font-display); font-weight: 600; font-size: 1.4rem; }
.pg-lv b { font-weight: 720; font-size: 4.2rem; letter-spacing: -.04em; vertical-align: -10px; margin-left: 6px; }
.pg-who { font-size: .875rem; color: rgba(255,255,255,.65); max-width: 26ch; }
.pg-dims { background: var(--paper-2); padding-block: clamp(70px, 8vw, 120px); }
.dim-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; }
.dim { padding: 28px; border-radius: var(--r-lg); display: grid; gap: 12px; align-content: start; box-shadow: var(--sh-ui); }
.dim-ic { width: 52px; height: 52px; border-radius: 16px; display: grid; place-items: center; background: #E6F0FA; color: var(--brand); }
.dim-ic .ico { width: 26px; height: 26px; }
.dim-n { font-family: var(--font-display); color: var(--ink-3); font-weight: 600; }
.dim-n b { font-weight: 720; font-size: 3rem; letter-spacing: -.04em; color: var(--ink); margin-right: 4px; }
.dim h3 { font-size: 1.4rem; }
.dim p:not(.dim-n) { color: var(--ink-2); }
.dim-bar { display: block; height: 6px; border-radius: 6px; margin-top: 6px; background: linear-gradient(90deg, var(--brand) calc(var(--v) / 16 * 100%), var(--paper-3) 0); }
.pg-panel { background: radial-gradient(90% 120% at 90% 0%, #173D72, var(--night) 65%); padding-block: clamp(70px, 8vw, 120px); }
.pg-panel-grid { display: grid; grid-template-columns: 1fr 1fr; gap: clamp(32px, 5vw, 80px); align-items: center; }
.pg-panel-grid > div:first-child { display: grid; gap: 20px; }
.pg-panel-grid > div:first-child p { color: var(--fg-2); max-width: 46ch; font-size: 1.0625rem; }
.pg-panel .btn { justify-self: start; }
.pg-nums { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.pg-nums div { padding: 22px; border-radius: 20px; background: rgba(255,255,255,.06); border: 1px solid var(--line-dark); }
.pg-nums div:first-child { grid-column: 1 / -1; background: var(--sun); color: var(--sun-ink); border-color: var(--sun); }
.pg-nums b { display: block; font-family: var(--font-display); font-weight: 720; font-size: 3.4rem; letter-spacing: -.04em; line-height: 1; }
.pg-nums span { font-size: .9375rem; opacity: .85; }
.pg-links { padding-block: clamp(70px, 8vw, 110px); }
.pg-links .t-h2 { margin-bottom: 20px; }
@media (max-width: 1100px) { .pg-grid, .pg-panel-grid { grid-template-columns: 1fr; } .pg-seal { max-width: 420px; justify-self: center; width: 100%; } .dim-grid { grid-template-columns: 1fr; } }
@media (max-width: 720px) { .pg-levels span { min-width: 64px; min-height: 64px; } .pg-nums b { font-size: 2.6rem; } }
}
