/* Design system EAB — paleta "Céu de Brasília" (tokens.css + Manrope) */
:root {
  --portal-primary: var(--eab-primary);
  --portal-primary-dark: var(--eab-azul-800);
  --portal-primary-light: var(--eab-azul-400);
  --portal-accent: var(--eab-accent);
  --portal-accent-bright: var(--eab-ouro-400);
  --portal-bg: var(--eab-bg);
  --portal-surface: var(--eab-surface);
  --portal-text: var(--eab-text);
  --portal-text-muted: var(--eab-text-muted);
  --portal-border: var(--eab-border);
  --portal-hero-from: var(--eab-azul-900);
  --portal-hero-to: var(--eab-azul-700);
  --portal-hero-text: #F4F1E8;
  --portal-font: var(--eab-sans);
  --portal-focus-ring: rgba(45, 79, 176, 0.25);
  --portal-active-bg: rgba(22, 38, 92, 0.08);
}

.portal-body {
  font-family: var(--portal-font);
  color: var(--portal-text);
  background: var(--portal-bg);
  min-height: 100vh;
  display: flex;
  flex-direction: column;
}

.portal-top {
  position: sticky;
  top: 0;
  z-index: 100;
  background: var(--portal-surface);
  border-bottom: 1px solid var(--portal-border);
}

.portal-top-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  padding: 0.65rem 0;
}

.portal-top-end {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.portal-nav-wrap {
  border-top: 1px solid var(--portal-border);
}

.portal-logo {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.05rem;
  color: var(--portal-primary);
  text-decoration: none;
  font-weight: 700;
  letter-spacing: -0.02em;
  line-height: 1.25;
  min-width: 0;
}

.portal-logo-short {
  display: none;
}

.portal-nav-toggle {
  display: none;
  flex-direction: column;
  justify-content: center;
  gap: 5px;
  width: 2.75rem;
  height: 2.75rem;
  padding: 0;
  border: 1px solid var(--portal-border);
  border-radius: 0.5rem;
  background: var(--portal-surface);
  cursor: pointer;
  flex-shrink: 0;
}

.portal-nav-toggle-bar {
  display: block;
  width: 1.25rem;
  height: 2px;
  margin: 0 auto;
  background: var(--portal-text);
  border-radius: 1px;
  transition: transform 0.2s ease, opacity 0.2s ease;
}

.portal-nav-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  top: 3.5rem;
  background: rgba(15, 23, 42, 0.45);
  z-index: 90;
}

.portal-nav {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.35rem 1rem;
  font-size: 0.9rem;
  padding: 0.5rem 0;
}

.portal-nav a {
  color: var(--portal-text);
  text-decoration: none;
  padding: 0.35rem 0;
}

.portal-nav a:hover,
.portal-nav a:focus-visible {
  color: var(--portal-primary);
}

.portal-nav a.is-active {
  color: var(--portal-primary);
  font-weight: 600;
}

.portal-nav-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.15rem;
  height: 1.15rem;
  margin-left: 0.35rem;
  padding: 0 0.3rem;
  border-radius: 999px;
  font-size: 0.65rem;
  font-weight: 700;
  line-height: 1;
  background: #fbbf24;
  color: #78350f;
  vertical-align: middle;
}

.portal-nav-cta {
  padding: 0.45rem 0.85rem !important;
  border-radius: 0.5rem;
  background: var(--portal-primary);
  color: #fff !important;
  font-weight: 600;
}

.portal-nav-cta:hover,
.portal-nav-cta:focus-visible {
  background: var(--portal-primary-dark);
  color: #fff !important;
}

.portal-page-welcome {
  margin: 0 0 1.25rem;
  font-size: 1.05rem;
  line-height: 1.4;
  text-align: center;
  color: var(--portal-text-muted);
}

.portal-page-welcome strong {
  color: var(--portal-primary);
  font-weight: 600;
}

.portal-perfil-layout,
.portal-conta-layout {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 1.25rem;
  align-items: start;
}

@media (min-width: 992px) {
  .portal-perfil-layout,
  .portal-conta-layout {
    grid-template-columns: 16rem minmax(0, 1fr);
    gap: 1.5rem;
  }

  .portal-conta-layout--single {
    grid-template-columns: minmax(0, 1fr);
  }
}

.portal-perfil-nav,
.portal-conta-nav {
  padding: 1rem;
  display: flex;
  flex-direction: column;
}

.portal-perfil-nav-list,
.portal-conta-nav-list {
  flex: 1 1 auto;
}

.portal-perfil-nav-header,
.portal-conta-nav-header {
  margin-bottom: 1rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid var(--portal-border);
}

.portal-perfil-nav-greeting,
.portal-conta-nav-greeting {
  font-size: 0.95rem;
  color: var(--portal-text-muted);
  line-height: 1.35;
}

.portal-perfil-nav-greeting strong,
.portal-conta-nav-greeting strong {
  color: var(--portal-primary);
  font-weight: 600;
}

.portal-conta-nav-label,
.portal-perfil-nav-label {
  margin: 0.75rem 0 0.35rem;
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--portal-muted, #64748b);
}

.portal-conta-nav-label:first-of-type,
.portal-perfil-nav-label:first-of-type {
  margin-top: 0;
}

.portal-perfil-nav-list li + li,
.portal-conta-nav-list li + li {
  margin-top: 0.25rem;
}

.portal-perfil-nav-link,
.portal-conta-nav-link {
  display: block;
  padding: 0.55rem 0.75rem;
  border-radius: 0.5rem;
  color: var(--portal-text);
  text-decoration: none;
  font-size: 0.9rem;
  font-weight: 500;
}

.portal-perfil-nav-link:hover,
.portal-perfil-nav-link:focus-visible,
.portal-conta-nav-link:hover,
.portal-conta-nav-link:focus-visible {
  background: rgba(22, 38, 92, 0.06);
  color: var(--portal-primary);
}

.portal-perfil-nav-link.is-active,
.portal-conta-nav-link.is-active {
  background: rgba(22, 38, 92, 0.1);
  color: var(--portal-primary);
  font-weight: 600;
}

.portal-perfil-nav-footer,
.portal-conta-nav-footer {
  margin-top: 0.75rem;
  padding-top: 0.75rem;
  border-top: 1px solid var(--portal-border);
}

.portal-perfil-nav-footer form,
.portal-conta-nav-footer form {
  margin: 0;
}

button.portal-perfil-nav-link,
button.portal-conta-nav-link {
  appearance: none;
  -webkit-appearance: none;
}

.portal-perfil-nav-link--logout,
.portal-conta-nav-link--logout {
  width: 100%;
  text-align: left;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  color: var(--portal-text);
}

.portal-perfil-nav-link--logout:hover,
.portal-perfil-nav-link--logout:focus-visible,
.portal-conta-nav-link--logout:hover,
.portal-conta-nav-link--logout:focus-visible {
  background: rgba(220, 38, 38, 0.08);
  color: #b91c1c;
}

.portal-main {
  flex: 1;
}

.portal-hero {
  background: linear-gradient(135deg, var(--portal-hero-from), var(--portal-hero-to));
  color: var(--portal-hero-text);
  padding: 4rem 0;
}

.portal-hero--compact {
  padding: 3rem 0;
}

.portal-hero-title {
  font-size: clamp(1.75rem, 4vw, 2.5rem);
  font-weight: 700;
  letter-spacing: -0.03em;
  margin-bottom: 0.75rem;
}

.portal-hero-lead {
  font-size: 1.1rem;
  color: rgba(255, 255, 255, 0.92);
  max-width: 36rem;
  margin: 0 auto 1rem;
}

.portal-hero--compact .portal-hero-lead {
  margin-left: 0;
}

.portal-card {
  background: var(--portal-surface);
  border-radius: var(--r-card);
  padding: 1.5rem;
  box-shadow: var(--shadow-card);
  color: var(--portal-text);
  border: 1px solid var(--portal-border);
}

.portal-card--inline {
  text-align: left;
}

.portal-btn {
  display: inline-block;
  padding: 0.65rem 1.25rem;
  min-height: 2.75rem;
  line-height: 1.35;
  border-radius: 0.5rem;
  font-weight: 600;
  text-decoration: none;
  border: 2px solid transparent;
  text-align: center;
}

.portal-btn--block-sm {
  display: inline-block;
}

.portal-hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem;
  justify-content: center;
}

.portal-hero-actions--center {
  justify-content: center;
}

.portal-hero--welcome .portal-hero-title {
  max-width: none;
}

.portal-section--welcome {
  padding-top: 0;
}

.portal-btn--primary {
  background: var(--portal-accent);
  color: var(--eab-accent-ink);
}

.portal-btn--primary:hover {
  background: var(--portal-accent-bright);
  color: var(--eab-accent-ink);
}

.portal-hero .portal-btn--outline {
  border-color: rgba(255, 255, 255, 0.6);
  color: #fff;
}

.portal-hero .portal-btn--outline:hover {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

.portal-footer {
  background: var(--portal-surface);
  border-top: 1px solid var(--portal-border);
  padding: 1.5rem 0;
  margin-top: auto;
}

.portal-section {
  padding: 2.5rem 0;
}

.portal-card-title {
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--portal-primary);
}

.portal-section .text-primary {
  color: var(--portal-primary) !important;
}

.portal-link-btn {
  background: none;
  border: none;
  padding: 0.35rem 0;
  min-height: 2.75rem;
  color: var(--portal-text);
  font-size: 0.9rem;
  cursor: pointer;
  text-decoration: none;
  text-align: left;
  width: 100%;
}

.portal-link-btn:hover {
  color: var(--portal-primary);
}

.portal-nav-logout {
  margin: 0;
}

.form-label {
  font-weight: 600;
  font-size: 0.9rem;
}

.form-control:focus {
  border-color: var(--portal-primary);
  box-shadow: 0 0 0 0.2rem var(--portal-focus-ring);
}

.portal-section--alt {
  background: var(--portal-surface);
}

.portal-section-title {
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--portal-text);
}

.portal-course-card {
  position: relative;
}

.portal-course-title {
  font-size: clamp(1.2rem, 2.5vw, 1.45rem);
  font-weight: 700;
  line-height: 1.3;
  letter-spacing: -0.02em;
}

.portal-course-title-link {
  color: var(--portal-text);
  text-decoration: none;
}

.portal-course-title-link:hover,
.portal-course-title-link:focus-visible {
  color: var(--portal-primary);
}

.portal-instrutor-link {
  color: var(--portal-primary);
  font-weight: 600;
  text-decoration: none;
}

.portal-instrutor-link:hover,
.portal-instrutor-link:focus-visible {
  color: var(--portal-primary-dark);
  text-decoration: underline;
}

.portal-professor-photo {
  width: min(100%, 288px);
  max-width: 288px;
  height: auto;
  aspect-ratio: 1;
  object-fit: cover;
  border-radius: 1rem;
  border: 3px solid var(--portal-border);
  box-shadow: 0 8px 24px rgba(16, 38, 92, 0.14);
}

.portal-professor-photo--sm {
  width: 96px;
  max-width: 96px;
  flex-shrink: 0;
}

.portal-professor-photo--placeholder {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  background: var(--portal-primary-light);
  color: #fff;
  font-size: 2.5rem;
  font-weight: 700;
}

.portal-professor-meta li + li {
  margin-top: 0.35rem;
}

.portal-professor-meta a {
  word-break: break-word;
}

.portal-professor-bio {
  line-height: 1.6;
}

.portal-professor-card {
  text-align: left;
}

.portal-quote p {
  font-style: italic;
}

.portal-carousel {
  max-width: 40rem;
  margin: 0 auto;
  position: relative;
}

.portal-carousel .carousel-inner {
  overflow: hidden;
}

.portal-carousel .carousel-item {
  padding: 0 0.25rem;
}

.portal-quote--carousel {
  text-align: center;
  min-height: 12rem;
  display: flex;
  flex-direction: column;
  justify-content: center;
}

.portal-carousel-indicators {
  position: static;
  margin: 1.25rem 0 0;
  gap: 0.35rem;
}

.portal-carousel-indicators [data-bs-target] {
  width: 0.55rem;
  height: 0.55rem;
  border-radius: 50%;
  background-color: var(--portal-border);
  border: none;
  opacity: 1;
  margin: 0;
}

.portal-carousel-indicators .active {
  background-color: var(--portal-primary);
}

.portal-carousel-control {
  width: 2.75rem;
  opacity: 1;
}

.portal-carousel-control-icon {
  display: block;
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  background-color: var(--portal-surface);
  border: 1px solid var(--portal-border);
  box-shadow: 0 2px 8px rgba(33, 33, 33, 0.12);
  background-repeat: no-repeat;
  background-position: center;
  background-size: 0.85rem;
}

.carousel-control-prev .portal-carousel-control-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%2316265C'%3e%3cpath d='M11.354 1.646a.5.5 0 0 1 0 .708L5.707 8l5.647 5.646a.5.5 0 0 1-.708.708l-6-6a.5.5 0 0 1 0-.708l6-6a.5.5 0 0 1 .708 0'/%3e%3c/svg%3e");
}

.carousel-control-next .portal-carousel-control-icon {
  background-image: url("data:image/svg+xml,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 16 16' fill='%2316265C'%3e%3cpath d='M4.646 1.646a.5.5 0 0 1 .708 0l6 6a.5.5 0 0 1 0 .708l-6 6a.5.5 0 0 1-.708-.708L10.293 8 4.646 2.354a.5.5 0 0 1 0-.708'/%3e%3c/svg%3e");
}

.portal-carousel-control:hover .portal-carousel-control-icon,
.portal-carousel-control:focus-visible .portal-carousel-control-icon {
  border-color: var(--portal-primary);
  box-shadow: 0 2px 12px rgba(16, 38, 92, 0.2);
}

@media (max-width: 575.98px) {
  .portal-carousel {
    padding: 0 2.5rem;
  }

  .portal-quote--carousel {
    min-height: 10rem;
  }
}

.portal-prose {
  line-height: 1.7;
}

.portal-prose--narrow {
  max-width: 42rem;
}

.portal-prose h2 {
  font-size: 1.15rem;
  font-weight: 700;
  margin-top: 1.75rem;
  margin-bottom: 0.75rem;
}

.portal-course-cover {
  max-height: 320px;
  object-fit: cover;
  width: 100%;
}

.portal-course-header__cta {
  margin-top: 0.25rem;
}

.portal-course-lead {
  font-size: 1.05rem;
  line-height: 1.65;
  margin-bottom: 0;
}

.portal-course-topics {
  padding-left: 1.25rem;
  margin-bottom: 0;
}

.portal-course-topics li + li {
  margin-top: 0.35rem;
}

.portal-course-sidebar .portal-btn {
  justify-content: center;
}

.portal-footer-links a {
  color: var(--portal-text);
  text-decoration: none;
}

.portal-footer-links a:hover {
  color: var(--portal-primary);
}

.portal-whatsapp {
  position: fixed;
  right: 1.25rem;
  bottom: 1.25rem;
  z-index: 200;
  width: 3.25rem;
  height: 3.25rem;
  border-radius: 50%;
  background: #25d366;
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
  transition: transform 0.15s ease;
}

.portal-whatsapp:hover {
  color: #fff;
  transform: scale(1.06);
}

.portal-questao-resumo {
  margin: 0;
  font-size: 0.9375rem;
  line-height: 1.45;
  color: var(--portal-text);
}

.portal-questao-resumo .text-muted {
  font-weight: 600;
}

.portal-section--painel {
  padding-top: 1.5rem;
}

.portal-aula-form-head {
  max-width: 42rem;
}

.portal-aula-form-title {
  font-size: clamp(1.35rem, 3vw, 1.75rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--portal-text);
}

.portal-aula-form-subtitle {
  font-size: 0.9375rem;
  color: var(--portal-muted, #6c757d);
}

.portal-aula-form-card {
  max-width: 42rem;
  padding: 1.5rem;
}

.portal-aula-form .mb-3:last-child {
  margin-bottom: 0 !important;
}

.portal-form-section {
  margin-bottom: 1.75rem;
  padding-bottom: 1.75rem;
  border-bottom: 1px solid var(--portal-border);
}

.portal-form-section--last {
  margin-bottom: 0;
  padding-bottom: 0;
  border-bottom: none;
}

.portal-form-section-title {
  margin: 0 0 1rem;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  color: var(--portal-muted, #6c757d);
}

.portal-aula-pdf-box {
  padding: 1rem 1.15rem;
  border: 1px solid var(--portal-border);
  border-radius: 0.5rem;
  background: rgba(22, 38, 92, 0.03);
}

.portal-aula-pdf-nome {
  margin: 0;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--portal-text);
  word-break: break-word;
}

.portal-form-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.75rem;
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--portal-border);
}

.portal-section--aluno {
  padding-top: 1.5rem;
}

.portal-aluno-page-head {
  max-width: 40rem;
}

.portal-aluno-page-title {
  font-size: clamp(1.5rem, 3vw, 1.85rem);
  font-weight: 700;
  letter-spacing: -0.02em;
  color: var(--portal-text);
}

.portal-aluno-curso-card {
  padding: 1.35rem;
  transition: box-shadow 0.2s ease, border-color 0.2s ease;
}

.portal-aluno-curso-card:hover {
  border-color: rgba(22, 38, 92, 0.18);
  box-shadow: 0 10px 28px rgba(16, 38, 92, 0.1);
}

.portal-aluno-curso-card-title {
  font-size: 1.15rem;
  font-weight: 700;
  line-height: 1.35;
  letter-spacing: -0.01em;
  margin-bottom: 0.35rem;
}

.portal-aluno-curso-card-meta {
  margin: 0;
  font-size: 0.875rem;
  color: var(--portal-muted, #6c757d);
}

.portal-aluno-empty {
  padding: 2.5rem 1.5rem;
}

.portal-aluno-empty-text {
  margin: 0;
  color: var(--portal-muted, #6c757d);
}

.portal-aluno-layout {
  display: block;
  width: 100%;
}

.portal-aula-contexto a {
  color: var(--portal-primary);
  text-decoration: none;
  font-weight: 600;
}

.portal-aula-contexto a:hover {
  text-decoration: underline;
}

.portal-aula-proximo {
  margin-top: 1.5rem;
  padding-top: 1.25rem;
  border-top: 1px solid var(--portal-border);
}

.portal-aluno-main--narrow {
  max-width: 42rem;
  margin: 0 auto;
}

body.portal-nav-open {
  overflow: hidden;
}

body.portal-nav-open .portal-nav-backdrop {
  display: block;
}

.form-control,
.form-select,
textarea.form-control {
  min-height: 2.75rem;
  font-size: 1rem;
}

textarea.form-control {
  min-height: 6rem;
}

.portal-aluno-main {
  min-width: 0;
}

.portal-aula-page {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.portal-aula-header {
  padding-bottom: 0.25rem;
}

.portal-aula-kicker {
  margin: 0 0 0.35rem;
  font-size: 0.8rem;
  font-weight: 600;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  color: var(--portal-primary);
}

.portal-aula-title {
  margin: 0 0 0.5rem;
  font-size: clamp(1.35rem, 2.5vw, 1.75rem);
  font-weight: 700;
  line-height: 1.25;
  color: var(--portal-primary);
}

.portal-aula-intro {
  margin: 0;
  font-size: 1rem;
  line-height: 1.6;
  color: var(--portal-text-muted);
}

.portal-aula-video-card {
  background: var(--portal-surface);
  border: 1px solid var(--portal-border);
  border-radius: 1rem;
  padding: 1rem;
  box-shadow: 0 10px 28px rgba(22, 38, 92, 0.08);
}

.portal-aula-video-card-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  margin-bottom: 0.85rem;
}

.portal-aula-badge {
  display: inline-block;
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
  letter-spacing: 0.03em;
  text-transform: uppercase;
  color: var(--portal-primary);
  background: rgba(217, 164, 65, 0.18);
}

.portal-aula-status {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--portal-text-muted);
}

.portal-aula-status--done {
  color: #198754;
}

.portal-video-stage {
  padding: 0.35rem;
  border-radius: 0.85rem;
  background: linear-gradient(145deg, #0a1024 0%, #16265c 100%);
}

.portal-aula-material {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.15rem;
  border: 1px solid var(--portal-border);
  border-radius: 0.85rem;
  background: var(--portal-surface);
}

.portal-aula-material-text {
  display: flex;
  flex-direction: column;
  gap: 0.15rem;
  font-size: 0.9rem;
  color: var(--portal-text-muted);
}

.portal-aula-material-text strong {
  color: var(--portal-text);
  font-size: 0.95rem;
}

.portal-aula-tarefa-card {
  padding: 1.25rem;
}

.portal-aula-tarefa-title {
  margin: 0 0 0.75rem;
  font-size: 1rem;
  font-weight: 700;
  color: var(--portal-primary);
}

.portal-tarefa-form {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.portal-tarefa-page-header .h4 {
  margin-bottom: 0.5rem;
}

.portal-tarefa-questoes {
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.portal-tarefa-questao-card {
  padding: 1.25rem 1.35rem;
  border: 1px solid var(--portal-border);
  border-radius: 0.75rem;
  background: var(--portal-surface);
  box-shadow: 0 1px 2px rgba(22, 38, 92, 0.04);
}

.portal-tarefa-questao-card--enviada {
  margin-bottom: 0;
}

.portal-tarefa-questao-head {
  display: flex;
  align-items: flex-start;
  gap: 0.875rem;
}

.portal-tarefa-questao-head-content {
  flex: 1;
  min-width: 0;
}

.portal-tarefa-questao-card:not(.portal-tarefa-anexos) .portal-tarefa-questao-head {
  margin-bottom: 1rem;
  padding-bottom: 0.875rem;
  border-bottom: 1px solid var(--portal-border);
}

.portal-tarefa-questao-card:not(.portal-tarefa-anexos) .portal-tarefa-questao-body {
  padding-top: 0.125rem;
}

.portal-tarefa-questao-num {
  flex-shrink: 0;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2rem;
  height: 2rem;
  padding: 0 0.5rem;
  border-radius: 999px;
  background: rgba(22, 38, 92, 0.08);
  color: var(--portal-primary);
  font-size: 0.875rem;
  font-weight: 700;
  line-height: 1;
}

.portal-tarefa-questao-body .form-label,
.portal-tarefa-questao-body .portal-tarefa-enunciado {
  margin-bottom: 0.75rem;
}

.portal-tarefa-form-actions {
  padding-top: 0.25rem;
}

.portal-tarefa-enunciado {
  margin: 0;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.45;
  color: var(--portal-text);
}

.portal-tarefa-opcoes-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.portal-tarefa-opcoes-list li {
  margin: 0;
}

.portal-tarefa-opcoes-list label {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 0.875rem 1rem;
  margin: 0;
  border: 1px solid var(--portal-border);
  border-radius: 0.625rem;
  background: var(--portal-surface);
  cursor: pointer;
  transition: border-color 0.15s ease, background 0.15s ease, box-shadow 0.15s ease;
  font-weight: 400;
  line-height: 1.45;
  color: var(--portal-text);
}

.portal-tarefa-opcoes-list label:hover {
  border-color: rgba(22, 38, 92, 0.35);
}

.portal-tarefa-opcoes-list label:has(input:checked) {
  border-color: var(--portal-primary);
  background: rgba(22, 38, 92, 0.05);
  box-shadow: 0 0 0 1px var(--portal-primary);
}

.portal-tarefa-opcoes-list input[type="radio"],
.portal-tarefa-opcoes-list input[type="checkbox"] {
  flex-shrink: 0;
  margin: 0.15rem 0 0;
  width: 1.125rem;
  height: 1.125rem;
  accent-color: var(--portal-primary);
}

.portal-tarefa-questao-anexos {
  margin-top: 1rem;
  padding-top: 1rem;
  border-top: 1px dashed var(--portal-border);
}

.portal-tarefa-anexo-titulo {
  margin: 0;
  font-size: 0.9375rem;
  font-weight: 600;
  color: var(--portal-text);
}

.portal-tarefa-anexo-ajuda {
  margin: 0;
  line-height: 1.45;
}

.portal-tarefa-anexo-picker {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.625rem;
}

.portal-tarefa-anexo-input {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.portal-tarefa-anexo-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  margin: 0;
  padding: 0.4rem 0.875rem;
  font-size: 0.8125rem;
  font-weight: 500;
  line-height: 1.4;
  color: var(--portal-primary);
  background: #fff;
  border: 1px solid rgba(22, 38, 92, 0.18);
  border-radius: 999px;
  cursor: pointer;
  transition: background-color 0.15s ease, border-color 0.15s ease, color 0.15s ease;
}

.portal-tarefa-anexo-btn:hover {
  color: var(--portal-primary);
  background: rgba(22, 38, 92, 0.04);
  border-color: rgba(22, 38, 92, 0.28);
}

.portal-tarefa-anexo-btn:focus-visible {
  outline: 2px solid rgba(217, 164, 65, 0.55);
  outline-offset: 2px;
}

.portal-tarefa-anexo-nome {
  max-width: 100%;
  line-height: 1.4;
}

.portal-tarefa-questao-anexos--enviados {
  margin-top: 1rem;
  padding-top: 0;
  border-top: none;
}

.portal-tarefa-anexos .form-control {
  margin-top: 0.25rem;
}

.portal-tarefa-enviada {
  padding: 1.25rem;
}

.portal-tarefa-resposta-aluno {
  padding: 0.875rem 1rem;
  border: 1px solid var(--portal-primary);
  border-radius: 0.625rem;
  background: rgba(22, 38, 92, 0.05);
  font-weight: 500;
  line-height: 1.45;
}

.portal-aula-footnote {
  margin: 0;
  font-size: 0.875rem;
}

.portal-progress {
  height: 0.5rem;
  background: var(--portal-border);
  border-radius: 999px;
  overflow: hidden;
}

.portal-progress-bar {
  height: 100%;
  background: var(--portal-primary);
  border-radius: 999px;
  transition: width 0.3s ease;
}

.portal-aula-list-item {
  margin-bottom: 0.35rem;
}

.portal-aula-list-item a {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.65rem;
  padding: 0.55rem 0.65rem;
  border-radius: 0.5rem;
  text-decoration: none;
  color: var(--portal-text);
  font-size: 0.875rem;
  line-height: 1.4;
}

.portal-aula-list-label {
  flex: 1;
  min-width: 0;
}

.portal-aula-list-status {
  flex-shrink: 0;
  font-size: 0.68rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.02em;
  padding: 0.15rem 0.4rem;
  border-radius: 999px;
}

.portal-aula-list-status--done {
  background: rgba(22, 163, 74, 0.12);
  color: #15803d;
}

.portal-aula-list-status--pending {
  background: rgba(251, 191, 36, 0.2);
  color: #92400e;
}

.portal-aula-list-item.is-active a {
  background: var(--portal-active-bg);
  color: var(--portal-primary);
  font-weight: 600;
}

.portal-aula-list-item.is-done a {
  opacity: 0.92;
}

.portal-video {
  background: #000;
  border-radius: 0.65rem;
  overflow: hidden;
  box-shadow: 0 12px 32px rgba(0, 0, 0, 0.35);
}

.portal-video-poster {
  position: absolute;
  inset: 0;
  z-index: 2;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1rem;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  border: 0;
  cursor: pointer;
  background: #000;
  color: #fff;
  transition: opacity 0.2s ease;
}

.portal-video-poster:hover .portal-video-play-icon {
  transform: scale(1.08);
  box-shadow: 0 12px 32px rgba(217, 164, 65, 0.45);
}

.portal-video-poster:hover img {
  opacity: 0.85;
}

.portal-video-poster.is-hidden {
  display: none;
}

.portal-video-poster img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.78;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.portal-video-play-icon {
  position: relative;
  z-index: 1;
  width: 5rem;
  height: 5rem;
  border-radius: 50%;
  background: var(--eab-ouro, #d9a441);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.portal-video-play-icon::after {
  content: "";
  position: absolute;
  top: 50%;
  left: 54%;
  transform: translate(-50%, -50%);
  border-style: solid;
  border-width: 0.65rem 0 0.65rem 1.1rem;
  border-color: transparent transparent transparent #16265c;
}

.portal-video-play-label {
  position: relative;
  z-index: 1;
  font-size: 1rem;
  font-weight: 700;
  letter-spacing: 0.02em;
  text-shadow: 0 2px 12px rgba(0, 0, 0, 0.75);
}

.portal-video-player,
.portal-video-player iframe {
  border: 0;
  width: 100%;
  height: 100%;
}

.portal-video-player.is-hidden {
  display: none;
}

.ratio > .portal-video-poster,
.ratio > .portal-video-player {
  position: absolute;
  inset: 0;
}

@media (min-width: 992px) {
  .portal-aula-video-card {
    padding: 1.25rem 1.35rem 1.35rem;
  }
}

.portal-card--muted {
  background: var(--eab-areia-100);
  border: 1px dashed var(--portal-border);
}

/* --- Mobile (sec. 16 — desde ~360px) --- */
@media (max-width: 991.98px) {
  .portal-nav-toggle {
    display: flex;
  }

  .portal-logo-full {
    display: none;
  }

  .portal-logo-short {
    display: inline;
  }

  .portal-nav-wrap {
    border-top: none;
    padding: 0;
  }

  .portal-nav {
    position: fixed;
    top: 3.35rem;
    left: 0;
    right: 0;
    z-index: 95;
    flex-direction: column;
    align-items: stretch;
    gap: 0;
    max-height: 0;
    overflow: hidden;
    padding: 0;
    background: var(--portal-surface);
    border-bottom: 1px solid transparent;
    box-shadow: none;
    transition: max-height 0.25s ease, border-color 0.2s ease, box-shadow 0.2s ease;
  }

  .portal-nav.is-open {
    max-height: min(80vh, 28rem);
    overflow-y: auto;
    border-bottom-color: #e2e8f0;
    box-shadow: 0 12px 32px rgba(15, 23, 42, 0.12);
    -webkit-overflow-scrolling: touch;
  }

  .portal-nav a,
  .portal-nav-logout {
    display: block;
    width: 100%;
    padding: 0.85rem 1rem;
    border-top: 1px solid #f1f5f9;
  }

  .portal-nav-logout {
    margin: 0;
  }

  .portal-nav-toggle[aria-expanded="true"] .portal-nav-toggle-bar:nth-child(1) {
    transform: translateY(7px) rotate(45deg);
  }

  .portal-nav-toggle[aria-expanded="true"] .portal-nav-toggle-bar:nth-child(2) {
    opacity: 0;
  }

  .portal-nav-toggle[aria-expanded="true"] .portal-nav-toggle-bar:nth-child(3) {
    transform: translateY(-7px) rotate(-45deg);
  }

  .portal-aula-list-item a {
    padding: 0.65rem 0.75rem;
    min-height: 2.75rem;
  }

  .portal-hero {
    padding: 2.5rem 0;
  }

  .portal-hero--compact {
    padding: 2rem 0;
  }

  .portal-section {
    padding: 2rem 0;
  }

  .portal-card {
    padding: 1.15rem;
  }

  .portal-hero-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .portal-hero-actions .portal-btn {
    width: 100%;
  }

  .portal-btn--block-sm {
    display: block;
    width: 100%;
  }

  .portal-footer-links {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
  }

  .portal-footer-sep {
    display: none;
  }

  .portal-whatsapp {
    right: 1rem;
    bottom: calc(1rem + env(safe-area-inset-bottom, 0px));
    width: 3rem;
    height: 3rem;
  }

  .portal-whatsapp svg {
    width: 24px;
    height: 24px;
  }

  .portal-main {
    padding-bottom: calc(4.5rem + env(safe-area-inset-bottom, 0px));
  }
}

@media (max-width: 575.98px) {
  .portal-course-cover {
    max-height: 220px;
  }

  .container {
    padding-left: 1rem;
    padding-right: 1rem;
  }
}

.portal-painel-nav {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  gap: 1rem 1.5rem;
  padding: 0.85rem 1rem;
  background: var(--white);
  border: 1px solid var(--gray-mid);
  border-radius: var(--radius-md);
}

.portal-painel-nav-section {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.25rem;
  min-width: 9rem;
}

.portal-painel-nav-section--curso {
  padding-left: 1rem;
  border-left: 1px solid var(--gray-mid);
}

.portal-painel-nav-label {
  font-size: 0.7rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--portal-muted, #64748b);
  margin-bottom: 0.15rem;
}

.portal-painel-nav a {
  font-size: 14px;
  font-weight: 600;
  color: var(--primary);
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
}

.portal-painel-nav a:hover {
  text-decoration: underline;
}

.portal-painel-nav a.is-active {
  color: var(--portal-primary, var(--primary));
  text-decoration: underline;
}

.portal-painel-nav-child {
  padding-left: 0.75rem;
  font-weight: 500;
}

.portal-painel-nav-child::before {
  content: "↳ ";
  opacity: 0.55;
}

.portal-painel-nav-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.25rem;
  height: 1.25rem;
  padding: 0 0.35rem;
  border-radius: 999px;
  font-size: 0.7rem;
  font-weight: 700;
  line-height: 1;
  background: #fbbf24;
  color: #78350f;
}

.portal-painel-breadcrumb {
  color: var(--portal-muted, #64748b);
}

.portal-painel-breadcrumb a {
  color: var(--portal-primary, var(--primary));
  text-decoration: none;
}

.portal-painel-breadcrumb a:hover {
  text-decoration: underline;
}

.portal-painel-breadcrumb-sep {
  margin: 0 0.35rem;
  opacity: 0.5;
}

.portal-painel-breadcrumb-current {
  color: var(--portal-text, #1e293b);
  font-weight: 600;
}

.portal-painel-curso-list {
  display: flex;
  flex-direction: column;
  gap: 0;
}

.portal-painel-curso-item {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 0;
  border-bottom: 1px solid var(--portal-border, #e2e8f0);
}

.portal-painel-curso-item:last-child {
  border-bottom: none;
  padding-bottom: 0;
}

.portal-painel-curso-item:first-child {
  padding-top: 0;
}

.portal-painel-curso-item-title {
  font-weight: 700;
  color: var(--portal-text);
}

.portal-painel-curso-item-actions {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
  flex-shrink: 0;
}

.portal-btn--secondary {
  border-color: var(--portal-border, #e2e8f0);
  color: var(--portal-text);
  background: transparent;
}

.portal-btn--secondary:hover {
  background: rgba(22, 38, 92, 0.06);
  color: var(--portal-primary);
}

.portal-section--listagem {
  padding-top: 2rem;
  padding-bottom: 3rem;
}

.portal-card--listagem {
  padding: 1.75rem 1.5rem;
}

.portal-matriculas-card {
  overflow: hidden;
}

.portal-matriculas-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem 1.25rem;
  margin-bottom: 1.5rem;
  padding-bottom: 1.25rem;
  border-bottom: 1px solid var(--portal-border);
}

.portal-matriculas-count {
  font-size: 0.875rem;
  color: var(--portal-text-muted);
}

.portal-matriculas-filtro {
  min-width: min(100%, 18rem);
}

.portal-matriculas-filtro-row {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.5rem;
}

.portal-matriculas-filtro .form-select {
  flex: 1 1 12rem;
  border-color: var(--portal-border);
  font-size: 0.875rem;
}

.portal-matriculas-header-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 0.75rem;
  min-width: min(100%, 18rem);
}

.portal-matriculas-por-curso {
  display: flex;
  flex-direction: column;
  gap: 1.75rem;
}

.portal-matriculas-curso-block {
  border: 1px solid var(--portal-border);
  border-radius: 0.65rem;
  overflow: hidden;
  background: var(--portal-surface);
}

.portal-matriculas-curso-title {
  margin: 0;
  padding: 0.85rem 1rem;
  background: rgba(22, 38, 92, 0.05);
  border-bottom: 1px solid var(--portal-border);
  color: var(--portal-primary);
  font-weight: 700;
}

.portal-matriculas-curso-block .portal-matriculas-list {
  padding: 0 0.25rem;
}

.portal-matriculas-row-clickable {
  cursor: pointer;
  transition: background 0.15s ease;
}

.portal-matriculas-row-clickable:hover,
.portal-matriculas-row-clickable:focus-visible {
  background: rgba(22, 38, 92, 0.05);
  outline: none;
}

.portal-matriculas-hint {
  font-style: italic;
}

.portal-btn--danger {
  border-color: #fecaca;
  color: #b91c1c;
  background: #fff;
}

.portal-btn--danger:hover {
  background: #fef2f2;
  color: #991b1b;
  border-color: #fca5a5;
}

.portal-matriculas-list {
  width: 100%;
}

.portal-matriculas-table {
  width: 100%;
  table-layout: auto;
}

.portal-matriculas-table thead th {
  font-size: 0.8rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.03em;
  color: var(--portal-muted, #64748b);
  border-bottom-width: 2px;
  white-space: nowrap;
}

.portal-matriculas-table tbody td {
  vertical-align: middle;
  padding-top: 0.85rem;
  padding-bottom: 0.85rem;
}

.portal-matricula-aluno {
  min-width: 10rem;
  max-width: 22rem;
}

.portal-matricula-aluno-nome {
  display: block;
  font-weight: 600;
  color: var(--portal-text);
  line-height: 1.35;
}

.portal-matricula-aluno-meta {
  display: block;
  margin-top: 0.15rem;
  font-size: 0.82rem;
  color: var(--portal-muted, #64748b);
  line-height: 1.4;
  word-break: break-word;
}

.portal-matriculas-table td:nth-child(2) {
  min-width: 8rem;
  max-width: 16rem;
}

.portal-btn--sm {
  padding: 0.35rem 0.75rem;
  min-height: auto;
  font-size: 0.85rem;
}

.portal-btn--outline {
  border-color: var(--portal-border, #e2e8f0);
  color: var(--portal-primary);
  background: transparent;
}

.portal-btn--outline:hover {
  background: rgba(22, 38, 92, 0.06);
  color: var(--portal-primary);
}

@media (max-width: 991.98px) {
  .portal-matriculas-table thead {
    display: none;
  }

  .portal-matriculas-table,
  .portal-matriculas-table tbody,
  .portal-matriculas-table tr,
  .portal-matriculas-table td {
    display: block;
    width: 100%;
  }

  .portal-matriculas-table tbody tr {
    padding: 1rem 0;
    border-bottom: 1px solid var(--portal-border, #e2e8f0);
  }

  .portal-matriculas-table tbody tr:last-child {
    border-bottom: none;
  }

  .portal-matriculas-table tbody td {
    padding: 0.35rem 0;
    border: none;
    text-align: left !important;
  }

  .portal-matriculas-table tbody td::before {
    content: attr(data-label);
    display: block;
    font-size: 0.72rem;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    color: var(--portal-muted, #64748b);
    margin-bottom: 0.15rem;
  }

  .portal-matricula-aluno {
    max-width: none;
  }

  .portal-matriculas-table td[data-label="Ações"] {
    padding-top: 0.65rem;
  }

  .portal-matriculas-table td[data-label="Ações"]::before {
    display: none;
  }
}

.portal-correcoes-card {
  padding: 1.35rem 1.5rem;
}

.portal-correcoes-header {
  display: flex;
  flex-wrap: wrap;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem 1.25rem;
  margin-bottom: 1.25rem;
}

.portal-correcoes-curso-form {
  min-width: min(100%, 16rem);
}

.portal-correcoes-curso-form .form-select {
  border-color: var(--portal-border);
  font-size: 0.875rem;
}

.portal-correcoes-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
}

.portal-correcoes-tab {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 0.45rem 0.85rem;
  border: 1px solid var(--portal-border);
  border-radius: 999px;
  font-size: 0.875rem;
  font-weight: 600;
  color: var(--portal-text);
  text-decoration: none;
  background: var(--portal-surface);
  transition: border-color 0.15s ease, background 0.15s ease, color 0.15s ease;
}

.portal-correcoes-tab:hover {
  border-color: rgba(22, 38, 92, 0.35);
  color: var(--portal-primary);
}

.portal-correcoes-tab.is-active {
  border-color: var(--portal-primary);
  background: rgba(22, 38, 92, 0.08);
  color: var(--portal-primary);
}

.portal-correcoes-tab-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 1.25rem;
  height: 1.25rem;
  padding: 0 0.35rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 700;
  background: #fbbf24;
  color: #78350f;
}

.portal-correcoes-list {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.portal-correcoes-item {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.1rem;
  border: 1px solid var(--portal-border);
  border-radius: 0.75rem;
  background: var(--portal-surface);
}

.portal-correcoes-item-aluno {
  margin: 0;
  font-size: 1rem;
  font-weight: 700;
  color: var(--portal-text);
}

.portal-correcoes-item-side {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 0.65rem 0.85rem;
}

.portal-correcoes-badge {
  display: inline-block;
  padding: 0.2rem 0.55rem;
  border-radius: 999px;
  font-size: 0.75rem;
  font-weight: 700;
}

.portal-correcoes-badge--ok {
  background: rgba(22, 163, 74, 0.12);
  color: #15803d;
}

.portal-correcoes-badge--wait {
  background: rgba(251, 191, 36, 0.2);
  color: #92400e;
}

.portal-correcoes-nota {
  font-weight: 700;
  color: var(--portal-primary);
}

.portal-tarefa-correcao {
  padding: 1rem 1.15rem;
  border: 1px solid rgba(22, 163, 74, 0.25);
  border-radius: 0.75rem;
  background: rgba(22, 163, 74, 0.06);
}

.portal-tarefa-correcao-titulo {
  margin: 0;
  font-weight: 700;
  color: #15803d;
}

.portal-tarefa-comentario-professor {
  margin-top: 0.75rem;
  padding: 0.875rem 1rem;
  border-radius: 0.625rem;
  border: 1px solid var(--portal-border);
  background: var(--portal-surface);
}

.portal-tarefa-comentario-professor--compact {
  margin-top: 0;
  padding: 0.75rem 0.875rem;
}

.portal-correcoes-empty {
  padding: 1rem 0 0.25rem;
}

/* --- Auth (login, cadastro, reset senha) — tela limpa, sem menu mobile --- */
.portal-body--auth {
  background: var(--portal-bg);
}

.portal-auth-header {
  padding: 1rem 0 0.5rem;
  border-bottom: 1px solid var(--portal-border);
  background: var(--portal-surface);
}

.portal-logo--auth {
  display: inline-block;
  font-weight: 700;
  font-size: 0.95rem;
  color: var(--portal-primary-dark);
  text-decoration: none;
  line-height: 1.35;
}

.portal-auth-main {
  min-height: calc(100dvh - 4.5rem);
  display: flex;
  flex-direction: column;
  justify-content: center;
  padding: 1.25rem 0 2rem;
}

.portal-body--auth .portal-section {
  padding: 0;
  flex: 1;
  display: flex;
  align-items: center;
}

.portal-body--auth .portal-card {
  box-shadow: 0 8px 28px rgba(15, 23, 42, 0.08);
}
