/* e-SIC 2026 — Área pública */

body.esic-2026 {
  min-height: 100vh;
}

body.esic-2026 > #principal {
  width: 100%;
  max-width: none;
  min-height: 100vh;
  display: flex;
  flex-direction: column;
  margin: 0;
}

body.esic-2026 #conteudo {
  flex: 1;
  display: flex;
  flex-direction: column;
}

body.esic-2026 #out {
  border-top: none;
  margin-top: 0;
  overflow: visible;
  flex: 1;
  display: flex;
  flex-direction: column;
}

body.esic-2026 #conteudo,
body.esic-2026 #corpo {
  height: auto;
  min-height: auto;
}

/* Header institucional */
.esic-header {
  background: linear-gradient(90deg, var(--esic-primary-dark) 0%, var(--esic-primary) 100%);
  color: #fff;
  box-shadow: 0 2px 12px rgba(12, 50, 111, 0.2);
}

.esic-header__top {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1rem 1.25rem;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.esic-header__brand {
  display: flex;
  align-items: center;
  gap: 1rem;
  text-decoration: none;
  color: inherit;
}

.esic-header__brand img {
  display: block;
  height: auto;
  max-height: 48px;
  width: auto;
  max-width: 220px;
  object-fit: contain;
  object-position: left center;
  border-radius: var(--esic-radius-sm);
  background: #fff;
  padding: 6px 8px;
  flex-shrink: 0;
}

.esic-header__titles h1 {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 700;
  border: none;
  padding: 0;
  color: #fff;
  font-family: var(--esic-font);
}

.esic-header__titles p {
  margin: 0.15rem 0 0;
  font-size: 0.85rem;
  opacity: 0.9;
}

.esic-header__badge {
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  background: #fff;
  border-radius: var(--esic-radius-sm);
  padding: 6px 10px;
  line-height: 0;
}

.esic-header__badge img {
  display: block;
  height: auto;
  width: auto;
  max-height: 32px;
  max-width: 110px;
  object-fit: contain;
  object-position: center;
}

/* Navegação */
.esic-nav {
  background: var(--esic-surface);
  border-bottom: 1px solid var(--esic-border);
}

.esic-nav__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 1rem;
}

.esic-nav__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-wrap: wrap;
  gap: 0.25rem;
}

.esic-nav__list a {
  display: block;
  padding: 0.85rem 1rem;
  color: var(--esic-text);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 600;
  border-bottom: 3px solid transparent;
  transition: color var(--esic-transition), border-color var(--esic-transition);
}

.esic-nav__list a:hover,
.esic-nav__list a:focus-visible {
  color: var(--esic-primary);
  border-bottom-color: var(--esic-primary);
}

/* Esconder header legado */
body.esic-2026 #cabecalho {
  display: none;
}

body.esic-2026 .page-header {
  display: none;
}

/* Layout da página inicial (banner + login) */
body.esic-2026 #principal #banner {
  display: flex;
  width: 100%;
  height: auto;
  min-height: 0;
  padding: 0;
  vertical-align: initial;
}

body.esic-2026 #corpo .esic-home {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 1.5rem 1.25rem 3rem;
  display: grid;
  grid-template-columns: 1fr;
  gap: 1.5rem;
}

body.esic-2026 #corpo .esic-home #banner {
  width: 100%;
  height: auto;
  min-height: 0;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  align-self: start;
  line-height: 0;
  border-radius: var(--esic-radius);
  overflow: hidden;
  box-shadow: var(--esic-shadow);
  background: transparent;
}

body.esic-2026 #corpo .esic-home #banner img {
  width: 100%;
  height: auto;
  max-width: 100%;
  margin: 0;
  padding: 0;
  vertical-align: top;
  display: block;
  border-radius: var(--esic-radius);
}

/* Login */
body.esic-2026 #corpo .esic-home #caixa_login {
  width: 100%;
  min-height: auto;
  background: var(--esic-surface);
  border: 1px solid var(--esic-border);
  border-radius: var(--esic-radius);
  box-shadow: var(--esic-shadow);
  padding: 1.5rem;
  color: var(--esic-text);
}

body.esic-2026 .titulo_caixa_login {
  color: var(--esic-primary-dark);
  font-size: 1.35rem;
  font-weight: 700;
  margin: 0 0 0.35rem;
}

body.esic-2026 .esic-login-subtitle {
  color: var(--esic-text-muted);
  font-size: 0.9rem;
  margin-bottom: 1.25rem;
  position: static;
  width: auto;
}

body.esic-2026 .Mensagem {
  position: static;
  width: auto;
  color: var(--esic-text-muted);
  font-size: 0.9rem;
  margin: 0 0 1rem;
}

body.esic-2026 #corpo .esic-home #caixa_login #campos {
  margin: 0;
  padding: 0;
  text-align: left;
  width: 100%;
}

body.esic-2026 #corpo .esic-home #caixa_login table {
  width: 100%;
  border-collapse: collapse;
}

body.esic-2026 .labelLogin label {
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--esic-text);
}

body.esic-2026 .inputLogin input {
  width: 100%;
  min-height: 44px;
  padding: 0.65rem 0.85rem;
  border: 1px solid var(--esic-border);
  border-radius: var(--esic-radius-sm);
  font: inherit;
}

body.esic-2026 .inputLogin input:focus {
  outline: none;
  border-color: var(--esic-primary);
  box-shadow: 0 0 0 3px rgba(19, 81, 180, 0.15);
}

body.esic-2026 .inputBotao,
body.esic-2026 .esic-btn-login {
  width: 100%;
  min-height: 44px;
  margin-top: 0.5rem;
  background: var(--esic-primary);
  color: #fff;
  border: none;
  border-radius: var(--esic-radius-sm);
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
}

body.esic-2026 .inputBotao:hover,
body.esic-2026 .esic-btn-login:hover {
  background: var(--esic-primary-dark);
}

body.esic-2026 .esic-login-links {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px solid var(--esic-border);
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1.25rem;
  font-size: 0.875rem;
}

body.esic-2026 .esic-login-links a {
  color: var(--esic-primary);
  font-weight: 600;
}

body.esic-2026 .login-erro {
  margin: 0 0 1rem;
}

body.esic-2026 .esic-welcome {
  padding: 1rem;
  background: var(--esic-primary-light);
  border-radius: var(--esic-radius-sm);
  color: var(--esic-primary-dark);
}

body.esic-2026 .esic-welcome a {
  color: var(--esic-danger);
  font-weight: 600;
}

/* Rodapé */
.esic-footer {
  background: var(--esic-primary-dark);
  color: rgba(255, 255, 255, 0.9);
  margin-top: auto;
  width: 100%;
}

.esic-footer__inner {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1.5rem 1.25rem;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.esic-footer__text {
  font-size: 0.85rem;
  line-height: 1.5;
  max-width: 640px;
}

.esic-footer__badges {
  display: flex;
  gap: 0.5rem;
  align-items: center;
}

.esic-footer__badges img {
  height: 28px;
  width: auto;
  opacity: 0.85;
}

body.esic-2026 #rodape {
  display: none;
}

/* Captcha */
body.esic-2026 .esic-captcha {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}

body.esic-2026 .esic-captcha img {
  border-radius: var(--esic-radius-sm);
  border: 1px solid var(--esic-border);
}

body.esic-2026 .esic-captcha__refresh {
  min-width: 44px;
  min-height: 44px;
  border: 1px solid var(--esic-border);
  border-radius: var(--esic-radius-sm);
  background: var(--esic-surface);
  color: var(--esic-primary);
  font-size: 1.25rem;
  cursor: pointer;
}

body.esic-2026 .esic-captcha__refresh:hover {
  background: var(--esic-primary-light);
}

/* Conteúdo interno (#corpo) */
body.esic-2026 #corpo {
  max-width: 1200px;
  margin: 0 auto;
  padding: 1.5rem 1.25rem 2rem;
}

body.esic-2026 #corpo > h1 {
  color: var(--esic-primary-dark);
  font-size: 1.5rem;
  font-weight: 700;
  margin: 0 0 1rem;
  padding: 0;
  border: none;
  font-family: var(--esic-font);
}

body.esic-2026 #corpo form {
  background: var(--esic-surface);
  border: 1px solid var(--esic-border);
  border-radius: var(--esic-radius);
  box-shadow: var(--esic-shadow);
  padding: 1.5rem;
  max-width: 100%;
}

body.esic-2026 #corpo table {
  border-collapse: collapse;
  width: 100%;
}

body.esic-2026 #corpo table td,
body.esic-2026 #corpo table th {
  padding: 0.5rem;
}

body.esic-2026 #corpo input[type="text"],
body.esic-2026 #corpo input[type="password"],
body.esic-2026 #corpo input[type="email"],
body.esic-2026 #corpo select,
body.esic-2026 #corpo textarea {
  min-height: 40px;
  padding: 0.5rem 0.75rem;
  border: 1px solid var(--esic-border);
  border-radius: var(--esic-radius-sm);
  font: inherit;
}

body.esic-2026 #corpo input:focus,
body.esic-2026 #corpo select:focus,
body.esic-2026 #corpo textarea:focus {
  outline: none;
  border-color: var(--esic-primary);
  box-shadow: 0 0 0 3px rgba(19, 81, 180, 0.15);
}

/* Desktop: banner + login lado a lado */
@media (min-width: 900px) {
  body.esic-2026 #corpo .esic-home {
    grid-template-columns: 1.2fr 0.8fr;
    align-items: start;
  }

}

@media (max-width: 599px) {
  .esic-header__titles h1 {
    font-size: 1rem;
  }

  .esic-nav__list a {
    padding: 0.65rem 0.75rem;
    font-size: 0.82rem;
  }
}