/* IntegraGov 291 — interface de Encaminhamentos baseada no desenho aprovado. */
#main:has(.ig291-view){max-width:none;padding:24px 26px 52px}
.ig291-view{color:#0b2d52;display:grid;gap:17px;width:100%;font-size:15px}
.ig291-view *{box-sizing:border-box}
.ig291-hero{position:relative;overflow:hidden;display:flex;align-items:center;gap:17px;min-height:100px;padding:16px 22px;background:linear-gradient(110deg,#fff 55%,#edf7ff 100%);border-radius:16px}
.ig291-hero:after{content:"";position:absolute;right:-70px;top:-90px;width:300px;height:230px;border-radius:50%;background:#d6ecff9c;pointer-events:none}
.ig291-hero-icon{width:64px;height:64px;border-radius:16px;background:linear-gradient(145deg,#1d93e1,#0c4e99);display:grid;place-items:center;color:white;flex:none;font-size:38px}
.ig291-hero h1{margin:0 0 4px;font-size:clamp(24px,2.2vw,34px);font-weight:850;color:#082b51;line-height:1.12;position:relative;z-index:1}
.ig291-hero p{margin:0;color:#36536f;line-height:1.5;position:relative;z-index:1;font-size:14px}
.ig291-box{background:#fff;border:1px solid #d6e5f4;border-radius:16px;padding:17px 19px;box-shadow:0 6px 20px #1c54820b}
.ig291-view h2{font-size:24px;margin:0 0 14px;color:#0b315a;font-weight:850}
.ig291-steps{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px}
.ig291-step{display:flex;gap:12px;align-items:flex-start;min-height:96px;padding:15px 12px;border:1px solid #cfe1f2;border-radius:13px;background:#fbfdff;position:relative}
.ig291-step strong{display:block;font-weight:850;line-height:1.22;margin:3px 0 5px;font-size:14px}
.ig291-step small{display:block;font-size:12px;line-height:1.4;color:#536d86}
.ig291-ico{flex:none;border-radius:13px;display:inline-grid;place-items:center;width:52px;height:52px;background:#e2f2ff;color:#087ec8}
.ig291-ico svg{width:30px;height:30px;fill:none;stroke:currentColor;stroke-width:2;stroke-linecap:round;stroke-linejoin:round}
.ig291-ico.purple{background:#f0e9ff;color:#8341c1}
.ig291-ico.green{background:#dff5e6;color:#159247}
.ig291-ico.pink{background:#ffe4ec;color:#d72358}
.ig291-steps .ig291-step:not(:last-child):after{content:"›";position:absolute;right:-12px;top:30%;font-size:28px;color:#0b3a70;z-index:1}
.ig291-metrics{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px}
.ig291-metric{text-align:left;border:1px solid #cde5f6;border-radius:14px;padding:18px 17px;min-width:0;background:#edfbff;display:flex;align-items:center;gap:14px;color:#0b315a;cursor:pointer;min-height:98px}
.ig291-metric:nth-child(2){background:#faf7ff;border-color:#e1d4fa}
.ig291-metric:nth-child(3){background:#f1f7ff;border-color:#cddff8}
.ig291-metric:nth-child(4){background:#fff3f6;border-color:#f5d6df}
.ig291-metric:hover,.ig291-action:hover{box-shadow:0 5px 20px #0a4a7e20;transform:translateY(-1px)}
.ig291-metric-label{font-size:13px;display:block;line-height:1.35}
.ig291-metric-number{font-size:31px;font-weight:850;display:block;line-height:1.25;margin-top:3px}
.ig291-actions{display:grid;grid-template-columns:repeat(4,minmax(0,1fr));gap:14px}
.ig291-action{border:1px solid #d6e3f0;border-radius:14px;background:#fff;padding:18px 15px 16px;min-height:180px;display:flex;flex-direction:column;align-items:flex-start;transition:transform .15s,box-shadow .15s}
.ig291-action:first-child{border-color:#8bc5fd}
.ig291-action h3{font-size:17px;color:#0a315a;margin:13px 0 5px;font-weight:850}
.ig291-action p{font-size:13px;color:#47617b;line-height:1.45;margin:0 0 14px;flex:1}
.ig291-view button.ig291-action-btn{align-self:center;width:min(138px,100%);padding:8px 12px;background:linear-gradient(180deg,#0876c4,#074b92);color:#fff;border:0;border-radius:8px;font-size:14px;font-weight:800}
.ig291-bottom{display:grid;grid-template-columns:1.65fr 1fr;gap:16px}
.ig291-bottom h3{font-size:20px;margin:0 0 4px;font-weight:850}
.ig291-muted{color:#607992;font-size:12px}
.ig291-flow{display:grid;grid-template-columns:repeat(4,1fr);margin-top:26px;text-align:center;position:relative;gap:6px}
.ig291-flow:before{content:"";height:3px;background:#2b77bd;position:absolute;top:14px;left:12%;right:12%;z-index:0}
.ig291-flow-item{position:relative;z-index:1}
.ig291-dot{display:grid;place-items:center;width:30px;height:30px;border:2px solid #1176c4;border-radius:50%;background:#fff;margin:0 auto 7px;color:#fff;font-weight:800}
.ig291-dot.done{background:#10a75b;border-color:#10a75b}
.ig291-flow-item strong{display:block;font-size:13px;margin:0 0 6px}
.ig291-flow-item small{display:block;font-size:11px;line-height:1.3;color:#4a6782}
.ig291-help{background:linear-gradient(120deg,#f8fcff,#edf6ff)}
.ig291-help ul{list-style:none;margin:14px 0 0;padding:0;display:grid;gap:11px}
.ig291-help li{position:relative;padding-left:20px;font-size:13px;line-height:1.4}
.ig291-help li:before{content:"";position:absolute;left:0;top:7px;width:8px;height:8px;border-radius:100%;background:#0e76bf}
.ig291-subnav{display:flex;align-items:center;justify-content:space-between;gap:12px;flex-wrap:wrap;margin:2px 0}
.ig291-view .ig291-back{border:1px solid #bed7ed!important;background:#eff7ff!important;color:#0b4d86!important;border-radius:9px!important;padding:11px 15px!important}
.ig291-view #protobody>.card{border-radius:14px}
.ig291-view #protobody h3{color:#0a315a}
.ig291-view #protobody input,.ig291-view #protobody textarea,.ig291-view #protobody select{background:white}
.ig291-view .ig291-error{padding:14px 16px;border:1px solid #fecaca;color:#7f1d1d;background:#fff1f2;border-radius:10px}
@media(max-width:1200px){.ig291-steps,.ig291-metrics,.ig291-actions{grid-template-columns:repeat(2,minmax(0,1fr))}.ig291-step:nth-child(2):after{display:none}}
@media(max-width:780px){#main:has(.ig291-view){padding:12px}.ig291-steps,.ig291-metrics,.ig291-actions,.ig291-bottom{grid-template-columns:1fr}.ig291-step:after{display:none!important}.ig291-hero{align-items:flex-start;padding:15px}.ig291-hero-icon{width:50px;height:50px;font-size:30px}.ig291-hero h1{font-size:23px}.ig291-flow-item small{font-size:10px}}
.ig291-bottom h3 svg{display:inline-block;width:23px;height:23px;fill:none;stroke:#087ac7;stroke-width:2;stroke-linecap:round;stroke-linejoin:round;vertical-align:-5px;margin-right:6px}

/* Central de encaminhamentos — cartões internos, cores e acessibilidade */
.ig291-metrics{grid-template-columns:repeat(3,minmax(0,1fr))}
.ig291-metric:nth-child(5){background:#eef6ff;border-color:#aacff0}
.ig291-metric:nth-child(6){background:#ebfaf1;border-color:#a7dfbf}
.ig291-action{border-width:2px;min-height:205px;box-shadow:0 5px 15px #17476b0b}
.ig291-action:nth-child(1){border-color:#70b5fa;background:linear-gradient(155deg,#f4faff,#fff 70%)}
.ig291-action:nth-child(2){border-color:#a98bea;background:linear-gradient(155deg,#f7f2ff,#fff 70%)}
.ig291-action:nth-child(3){border-color:#70d4a1;background:linear-gradient(155deg,#f0fff6,#fff 70%)}
.ig291-action:nth-child(4){border-color:#ecb47f;background:linear-gradient(155deg,#fff6ed,#fff 70%)}
.ig291-action:nth-child(2) .ig291-ico{background:#eee6ff;color:#7740c5}
.ig291-action:nth-child(3) .ig291-ico{background:#d9f8e7;color:#159247}
.ig291-action:nth-child(4) .ig291-ico{background:#ffecd9;color:#b86211}
.ig291-action h3{font-size:18px}
.ig291-action p{font-size:14px}
.ig291-view .ig291-action-btn:focus-visible,.ig291-view .ig291-back:focus-visible{outline:3px solid #f6a52b;outline-offset:3px}
.ig291-preview{border:1px solid #d5e5f5;border-radius:16px;background:#fff;padding:22px;box-shadow:0 8px 24px #173e6211}
.ig291-preview h2{margin:0 0 10px}
.ig291-preview-steps{display:grid;grid-template-columns:repeat(5,1fr);gap:7px;margin:20px 0}
.ig291-preview-steps span{border-radius:22px;padding:10px 7px;text-align:center;background:#eaf4ff;color:#17578b;font-weight:700;font-size:12px}
.ig291-preview-steps span:first-child{background:#0b73c4;color:white}
.ig291-preview-fields{display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:15px}
.ig291-preview-fields label{font-weight:700;font-size:14px;color:#21496f}
.ig291-preview-fields input,.ig291-preview-fields textarea{display:block;width:100%;margin-top:6px;border:1px solid #cbddeb;border-radius:9px;padding:12px;color:#647b92;background:#f3f7fa!important}
.ig291-preview-wide{grid-column:1/-1}
.ig291-preview-notice{margin:20px 0 0;padding:12px;border-radius:10px;background:#fff6e7;color:#704b15}
.ig291-case-tools{display:flex;gap:12px;align-items:center;flex-wrap:wrap;margin:16px 0}
.ig291-case-tools input{flex:1;min-width:240px;padding:11px;border:1px solid #b9d1e9;border-radius:10px}
.ig291-case-tools small{color:#526f88}
.ig291-view .tablewrap tbody tr[hidden]{display:none}
@media(max-width:1200px){.ig291-metrics{grid-template-columns:repeat(2,minmax(0,1fr))}}
@media(max-width:780px){.ig291-metrics,.ig291-preview-fields,.ig291-preview-steps{grid-template-columns:1fr}.ig291-preview-wide{grid-column:auto}.ig291-preview{padding:14px}}
