/*
 * Humanitas · revisão institucional · 19/09/2026
 * Camada final: azul #1E91D0, verde #7FC360, amarelo #FEC12B.
 * Apenas componentes decorativos. Fotografias, marcas oficiais, formulários
 * e cores semânticas de validação mantêm os respectivos estilos originais.
 */
:root {
  --hu-blue-ink: #126b9a;
  --hu-blue-soft: #f0f8fc;
  --hu-blue-end: #deeff8;
  --hu-blue-border: #bddbea;
  --hu-green-ink: #37683b;
  --hu-green-soft: #f2f8ec;
  --hu-green-end: #e2efd8;
  --hu-green-border: #c5dcb4;
  --hu-yellow-ink: #765a16;
  --hu-yellow-soft: #fffaf0;
  --hu-yellow-end: #fff0c3;
  --hu-yellow-border: #ebd79c;
  --hu-seal-bg: #2e3563;
  --hu-seal-ink: #ffffff;
}

html[data-theme="dark"] {
  --hu-blue-ink: #97d8f8;
  --hu-blue-soft: #1c3045;
  --hu-blue-end: #213d52;
  --hu-blue-border: #385c73;
  --hu-green-ink: #b0df96;
  --hu-green-soft: #23382d;
  --hu-green-end: #2b4433;
  --hu-green-border: #49654a;
  --hu-yellow-ink: #fec12b;
  --hu-yellow-soft: #353225;
  --hu-yellow-end: #423b27;
  --hu-yellow-border: #685c36;
}

/* Acesso rápido: três famílias cromáticas, com contraste próprio por tema. */
html[data-theme] .quick-section--vivid .quick-card[data-color] {
  --qc-a: var(--hu-blue-soft);
  --qc-b: var(--hu-blue-end);
  --qc-accent: var(--hu-blue-ink);
  --qc-border: var(--hu-blue-border);
  --qc-badge-a: #1e91d0;
  --qc-badge-b: #126b9a;
  --qc-shadow: 18 107 154;
  --qc-glyph: #fff;
  --qc-secondary: #fec12b;
  background: linear-gradient(145deg, var(--qc-a), var(--qc-b));
  border-color: var(--qc-border);
  box-shadow: inset 0 1px 0 rgb(255 255 255 / .12);
}

html[data-theme] .quick-section--vivid .quick-card:is([data-color="green"], [data-color="forest"]) {
  --qc-a: var(--hu-green-soft);
  --qc-b: var(--hu-green-end);
  --qc-accent: var(--hu-green-ink);
  --qc-border: var(--hu-green-border);
  --qc-badge-a: #599943;
  --qc-badge-b: #37683b;
  --qc-shadow: 55 104 59;
}

html[data-theme] .quick-section--vivid .quick-card[data-color="yellow"] {
  --qc-a: var(--hu-yellow-soft);
  --qc-b: var(--hu-yellow-end);
  --qc-accent: var(--hu-yellow-ink);
  --qc-border: var(--hu-yellow-border);
  --qc-badge-a: #fec12b;
  --qc-badge-b: #f3b723;
  --qc-shadow: 118 90 22;
  --qc-glyph: #2e3563;
  --qc-secondary: #2e3563;
}

html[data-theme] .quick-section--vivid .quick-card .quick-icon {
  border-radius: 16px;
  box-shadow: 0 5px 12px rgb(var(--qc-shadow) / .14);
}

/* Cards da Home, graduação, documentos e caminhos institucionais. */
html[data-theme] body :is(.h-card, .course-extras--featured .h-card)[data-hue] {
  --h-a: var(--hu-blue-soft);
  --h-b: var(--hu-blue-end);
  --h-line: var(--hu-blue-border);
  --h-accent: var(--hu-blue-ink);
  --h-badge-a: #1e91d0;
  --h-badge-b: #126b9a;
  --h-shadow: 18 107 154;
  --h-glyph: #fff;
  --h-detail: #fec12b;
  background: linear-gradient(145deg, var(--h-a), var(--h-b));
}

html[data-theme] body :is(.h-card, .course-extras--featured .h-card):is([data-hue="green"], [data-hue="forest"]) {
  --h-a: var(--hu-green-soft);
  --h-b: var(--hu-green-end);
  --h-line: var(--hu-green-border);
  --h-accent: var(--hu-green-ink);
  --h-badge-a: #599943;
  --h-badge-b: #37683b;
  --h-shadow: 55 104 59;
}

html[data-theme] body :is(.h-card, .course-extras--featured .h-card)[data-hue="amber"] {
  --h-a: var(--hu-yellow-soft);
  --h-b: var(--hu-yellow-end);
  --h-line: var(--hu-yellow-border);
  --h-accent: var(--hu-yellow-ink);
  --h-badge-a: #fec12b;
  --h-badge-b: #f3b723;
  --h-shadow: 118 90 22;
  --h-glyph: #2e3563;
  --h-detail: #2e3563;
}

html[data-theme] .h-card .h-icon {
  box-shadow: 0 5px 13px rgb(var(--h-shadow) / .14);
}

/* Pós-graduação, atendimento e documentos: componentes explicitamente
 * decorativos. admission-status e mensagens de erro não entram neste grupo. */
html[data-theme] .v8-page :is(.inner-hero, .course-section, .course-fact, .v8-card, .admission-last, .ombudsman-card, .doc-feature, .registration-block)[data-tone] {
  --v8-soft: var(--hu-blue-end);
  --v8-accent: var(--hu-blue-ink);
  --v8-edge: var(--hu-blue-border);
  --v8-ink: var(--hu-blue-ink);
}

html[data-theme] .v8-page :is(.inner-hero, .course-section, .course-fact, .v8-card, .admission-last, .ombudsman-card, .doc-feature, .registration-block):is([data-tone="green"], [data-tone="forest"]) {
  --v8-soft: var(--hu-green-end);
  --v8-accent: var(--hu-green-ink);
  --v8-edge: var(--hu-green-border);
  --v8-ink: var(--hu-green-ink);
}

html[data-theme] .v8-page :is(.inner-hero, .course-section, .course-fact, .v8-card, .admission-last, .ombudsman-card, .doc-feature, .registration-block)[data-tone="amber"] {
  --v8-soft: var(--hu-yellow-end);
  --v8-accent: var(--hu-yellow-ink);
  --v8-edge: var(--hu-yellow-border);
  --v8-ink: var(--hu-yellow-ink);
}

/* Ícones dos dados do curso e da infraestrutura. */
html[data-theme] .medicine-page .course-fact .course-fact-icon,
html[data-theme] .medicine-page .course-fact:nth-child(4) .course-fact-icon,
html[data-theme] .infra-card[data-color="coral"] .infra-card-icon {
  color: var(--hu-blue-ink);
  background: var(--hu-blue-end);
}

html[data-theme] .medicine-page .course-fact:nth-child(2) .course-fact-icon,
html[data-theme] .infra-card[data-color="green"] .infra-card-icon {
  color: var(--hu-green-ink);
  background: var(--hu-green-end);
}

html[data-theme] .medicine-page .course-fact:nth-child(3) .course-fact-icon,
html[data-theme] .infra-card[data-color="amber"] .infra-card-icon {
  color: var(--hu-yellow-ink);
  background: var(--hu-yellow-end);
}

/* Conteúdo institucional: mantém os agrupamentos e muda somente a paleta. */
html[data-theme] .institutional-page[data-institutional-group="extensao"] {
  --inst-accent: var(--hu-blue-ink);
}

html[data-theme] .institutional-tile:nth-child(n) {
  --tile-accent: var(--hu-blue-ink);
  --tile-bg: var(--hu-blue-end);
}

html[data-theme] .institutional-tile:nth-child(3n + 2) {
  --tile-accent: var(--hu-green-ink);
  --tile-bg: var(--hu-green-end);
}

html[data-theme] .institutional-tile:nth-child(3n) {
  --tile-accent: var(--hu-yellow-ink);
  --tile-bg: var(--hu-yellow-end);
}

/* Moldura dos serviços oficiais; os arquivos de logotipo permanecem intactos. */
.official-card--salary {
  --official-accent: #fec12b;
}

/* Faixas decorativas da identidade, sem interferir nos arquivos de marca. */
.inner-hero::after,
.medicine-hero::after {
  background: linear-gradient(90deg, #1e91d0 0 40%, #7fc360 40% 75%, #fec12b 75%);
}

.hero-color-rail {
  grid-template-columns: 1.2fr 1fr 1fr .6fr;
}

.hero-color-rail span:nth-child(4) {
  background: #1e91d0;
}

/* Respeita a visibilidade do canal até a confirmação da URL oficial. */
[data-social-tiktok][hidden] {
  display: none !important;
}

/* Selos editoriais padronizados: conteúdo original, leitura direta,
 * contorno limpo e nenhum giro, flutuação ou círculo pontilhado. */
html[data-theme] :is(.about-seal, .medicine-seal) {
  background: var(--hu-seal-bg);
  color: var(--hu-seal-ink);
  border: 4px solid var(--surface, #fff);
  border-radius: 20px;
  box-shadow: 0 7px 22px rgb(19 24 44 / .16);
  transform: none;
  animation: none;
}

html[data-theme] :is(.about-seal, .medicine-seal)::before {
  content: none;
  animation: none;
}

html[data-theme] .about-seal {
  width: 138px;
  height: 150px;
  right: -8px;
  top: 26px;
  gap: 10px;
  padding: 16px 12px;
}

html[data-theme] .about-seal strong .icon {
  width: 30px;
  height: 30px;
  color: #7fc360;
  stroke-width: 1.8;
  margin: 0;
}

html[data-theme] .about-seal span {
  color: #fff;
  font-size: 13px;
  line-height: 1.5;
  font-weight: 650;
}

html[data-theme] .medicine-seal {
  width: 114px;
  height: 134px;
  gap: 3px;
  padding: 10px 7px;
}

html[data-theme] .medicine-seal > .icon {
  color: #7fc360;
}

html[data-theme] .medicine-seal strong {
  color: #fec12b;
  font-size: 42px;
  font-weight: 700;
}

html[data-theme] .medicine-seal span {
  color: #fff;
  font-size: 11px;
  letter-spacing: .08em;
}

html[data-theme] .medicine-seal small {
  color: #e7edf6;
  font-size: 10px;
  font-weight: 500;
}

/* Avaliações institucionais: a mesma linguagem nas três páginas principais. */
.recognition,
.course-recognition,
.vest-score,
.recognition-score {
  background: var(--hu-seal-bg);
}

.course-recognition-rating,
.course-recognition-stat {
  background: rgb(255 255 255 / .045);
  border-color: rgb(255 255 255 / .22);
  box-shadow: none;
}

.vest-score::after,
.recognition-score::after {
  border-color: rgb(30 145 208 / .16);
}

html[data-theme] .vest-recognition-list li .icon,
html[data-theme] .vest-recognition-list li:nth-child(4) .icon {
  color: var(--hu-blue-ink);
}

html[data-theme] .vest-recognition-list li:nth-child(2) .icon {
  color: var(--hu-green-ink);
}

html[data-theme] .vest-recognition-list li:nth-child(3) .icon {
  color: var(--hu-yellow-ink);
}

@media (max-width: 760px) {
  html[data-theme] .about-seal {
    right: 12px;
    top: 16px;
    width: 116px;
    height: 132px;
    border-radius: 17px;
    gap: 7px;
    padding: 12px 8px;
  }

  html[data-theme] .about-seal span {
    font-size: 12px;
  }

  html[data-theme] .about-seal strong .icon {
    width: 26px;
    height: 26px;
  }

  html[data-theme] .medicine-seal {
    width: 98px;
    height: 116px;
    border-radius: 17px;
    gap: 2px;
    padding: 8px 5px;
    right: 0;
  }

  html[data-theme] .medicine-seal strong {
    font-size: 35px;
  }

  html[data-theme] .medicine-seal span {
    font-size: 10px;
  }

  html[data-theme] .medicine-seal small {
    font-size: 9px;
  }
}

@media (prefers-reduced-motion: reduce) {
  html[data-theme] :is(.quick-card, .h-card, .v8-card, .institutional-tile),
  html[data-theme] :is(.quick-card, .h-card, .v8-card, .institutional-tile) :is(.quick-icon, .quick-arrow, .h-icon, .h-route, .h-wave, .v8-icon, .v8-arrow) {
    animation: none !important;
    transition: none !important;
    transform: none !important;
  }
}

@media (forced-colors: active) {
  html[data-theme] body :is(.quick-card, .h-card, .v8-icon, .tile-symbol, .quick-icon, .quick-arrow, .h-icon, .h-route) {
    background: Canvas !important;
    color: LinkText !important;
    border: 1px solid LinkText !important;
    box-shadow: none !important;
  }

  html[data-theme] :is(.about-seal, .medicine-seal, .recognition, .course-recognition, .vest-score, .recognition-score, .course-recognition-rating, .course-recognition-stat) {
    background: Canvas;
    color: CanvasText;
    border: 1px solid CanvasText;
    box-shadow: none;
  }

  html[data-theme] :is(.about-seal, .medicine-seal) :is(strong, span, small, .icon) {
    color: CanvasText;
  }
}
