/* ==========================================================================
   STEELCONTROL - BASE GLOBAL
   Tipografia neutra e componentes compartilhados
   ========================================================================== */

:root {
  --sc-font: "Segoe UI", Arial, Helvetica, sans-serif;
}

html,
body,
button,
input,
select,
textarea {
  font-family: var(--sc-font);
}

body {
  font-style: normal;
  text-rendering: optimizeLegibility;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

/* Mantém Font Awesome funcionando sem sobrescrever a fonte dos ícones. */
.fa,
.fas,
.far,
.fal,
.fab,
.fa-solid,
.fa-regular,
.fa-brands {
  font-family: "Font Awesome 6 Free", "Font Awesome 6 Brands" !important;
}


/* ==========================================================================
   TIPOGRAFIA GLOBAL - VISUAL NATURAL E PROFISSIONAL
   ========================================================================== */

body {
  font-weight: 400;
}

p,
span,
li,
label,
input,
textarea,
select {
  font-weight: 400;
}

button,
a,
nav,
.nav-link,
.menu-link,
.sidebar a {
  font-weight: 600;
}

h1,
h2,
h3,
h4,
h5,
h6 {
  font-family: var(--sc-font);
  font-weight: 700;
  letter-spacing: -0.015em;
}

strong,
b {
  font-weight: 600;
}

/* Seletor global de idioma. É criado automaticamente por config.js. */
.steel-language-switcher {
  position: fixed;
  right: 16px;
  bottom: 16px;
  z-index: 99999;
  display: inline-flex;
  align-items: center;
  gap: 5px;
  min-height: 34px;
  padding: 5px 8px;
  border: 1px solid rgba(148, 163, 184, 0.26);
  border-radius: 10px;
  background: rgba(17, 24, 28, 0.96);
  box-shadow: 0 8px 22px rgba(2, 6, 23, 0.18);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.steel-language-switcher .steel-language-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 18px;
  height: 18px;
  color: #d58a16;
  font-size: 12px;
  line-height: 1;
}

.steel-language-switcher select {
  width: 38px;
  min-width: 38px;
  height: 24px;
  padding: 0 2px;
  border: 0;
  outline: 0;
  color: #f8fafc;
  background: transparent;
  font-family: inherit;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: .02em;
  cursor: pointer;
}

.steel-language-switcher select option {
  color: #1d2124;
  background: #fff;
}

/* Na Home o idioma faz parte do cabeçalho, evitando o botão flutuante grande. */
.home-page .header-actions .steel-language-switcher {
  position: static;
  right: auto;
  bottom: auto;
  z-index: auto;
  min-height: 42px;
  padding: 6px 9px;
  border-color: rgba(71, 85, 105, 0.18);
  background: #ffffff;
  box-shadow: none;
  backdrop-filter: none;
  -webkit-backdrop-filter: none;
}

.home-page .header-actions .steel-language-switcher .steel-language-icon {
  color: #52606a;
}

.home-page .header-actions .steel-language-switcher select {
  width: 36px;
  min-width: 36px;
  color: #1c252b;
}

html[data-theme="escuro"] .home-page .header-actions .steel-language-switcher {
  border-color: rgba(148, 163, 184, 0.22);
  background: #171d21;
}

html[data-theme="escuro"] .home-page .header-actions .steel-language-switcher .steel-language-icon {
  color: #d9a34c;
}

html[data-theme="escuro"] .home-page .header-actions .steel-language-switcher select {
  color: #f8fafc;
}

@media (max-width: 720px) {
  .steel-language-switcher {
    right: 10px;
    bottom: 10px;
    min-height: 32px;
    padding: 4px 7px;
  }

  .steel-language-switcher select {
    width: 34px;
    min-width: 34px;
    font-size: 10.5px;
  }

  .home-page .header-actions .steel-language-switcher {
    min-height: 38px;
    padding: 5px 7px;
  }
}


/* ==========================================================================
   MARCA STEELCONTROL - TIPOGRAFIA CORPORATIVA
   ========================================================================== */

/* Mantém o símbolo original e padroniza apenas a tipografia da marca. */
.brand-name,
.logo-name,
.logo-text,
.brand-text,
.navbar-brand strong,
.header-brand strong,
.brand strong {
  font-family: "Segoe UI", Arial, Helvetica, sans-serif !important;
  font-size: 21px !important;
  font-weight: 600 !important;
  line-height: 1.1 !important;
  letter-spacing: -0.35px !important;
  text-transform: none !important;
  font-style: normal !important;
}

.brand-subtitle,
.logo-subtitle,
.logo-tagline,
.brand-tagline,
.navbar-brand small,
.header-brand small,
.brand small {
  font-family: "Segoe UI", Arial, Helvetica, sans-serif !important;
  font-size: 11px !important;
  font-weight: 400 !important;
  line-height: 1.25 !important;
  letter-spacing: 0.35px !important;
  text-transform: none !important;
  font-style: normal !important;
  opacity: 0.72;
}

/* Classes de marca encontradas no projeto */
.cta-primary { font-family: "Segoe UI", Arial, Helvetica, sans-serif !important; }
.login-description { font-family: "Segoe UI", Arial, Helvetica, sans-serif !important; }


/* ===== STEELCONTROL UI — TOASTS E CONFIRMAÇÃO ===== */

.sc-toast-region {
  position: fixed;
  top: 22px;
  right: 22px;
  z-index: 99999;
  display: grid;
  gap: 10px;
  width: min(390px, calc(100vw - 32px));
  pointer-events: none;
}

.sc-toast {
  display: grid;
  grid-template-columns: 38px 1fr auto;
  align-items: start;
  gap: 11px;
  padding: 14px;
  border: 1px solid var(--sc-border);
  border-radius: 14px;
  background: var(--sc-surface);
  color: var(--sc-text);
  box-shadow: 0 18px 55px rgba(15, 23, 42, .16);
  opacity: 0;
  transform: translateY(-8px);
  animation: sc-toast-in .22s ease forwards;
  pointer-events: auto;
}

.sc-toast-icon {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  background: var(--sc-primary-soft);
  color: var(--sc-primary);
}

.sc-toast strong {
  display: block;
  margin: 1px 0 3px;
  font-size: 12px;
}

.sc-toast p {
  margin: 0;
  color: var(--sc-text-muted);
  font-size: 11px;
  line-height: 1.45;
}

.sc-toast-close {
  border: 0;
  background: transparent;
  color: var(--sc-text-muted);
  cursor: pointer;
}

.sc-toast.success .sc-toast-icon {
  background: rgba(22, 163, 74, .12);
  color: #16a34a;
}

.sc-toast.error .sc-toast-icon {
  background: rgba(220, 38, 38, .11);
  color: #dc2626;
}

.sc-toast.warning .sc-toast-icon {
  background: rgba(245, 158, 11, .13);
  color: #d97706;
}

.sc-confirm-backdrop {
  position: fixed;
  inset: 0;
  z-index: 99998;
  display: grid;
  place-items: center;
  padding: 20px;
  background: rgba(2, 6, 23, .68);
  backdrop-filter: blur(7px);
  animation: sc-confirm-backdrop-in .18s ease both;
}

.sc-confirm-card {
  position: relative;
  overflow: hidden;
  width: min(460px, 100%);
  padding: 28px;
  border: 1px solid var(--sc-border);
  border-radius: 24px;
  background: var(--sc-surface);
  color: var(--sc-text);
  box-shadow: 0 30px 90px rgba(0, 0, 0, .34);
  animation: sc-confirm-card-in .22s cubic-bezier(.2, .8, .2, 1) both;
}

.sc-confirm-card::before {
  content: "";
  position: absolute;
  inset: 0 0 auto;
  height: 4px;
  background: var(--sc-primary);
}

.sc-confirm-card.is-danger::before {
  background: linear-gradient(90deg, #ef4444, #dc2626);
}

.sc-confirm-icon {
  width: 58px;
  height: 58px;
  display: grid;
  place-items: center;
  margin-bottom: 14px;
  border-radius: 18px;
  background: rgba(245, 158, 11, .13);
  color: #d97706;
}

.sc-confirm-card.is-danger .sc-confirm-icon {
  background: rgba(220, 38, 38, .11);
  color: #dc2626;
}

.sc-confirm-card h3 {
  margin: 0 0 9px;
  font-size: 20px;
  line-height: 1.2;
  letter-spacing: -.25px;
}

.sc-confirm-card p {
  margin: 0;
  color: var(--sc-text-muted);
  font-size: 13px;
  line-height: 1.6;
}

.sc-confirm-actions {
  display: flex;
  justify-content: flex-end;
  gap: 9px;
  margin-top: 26px;
}

.sc-confirm-actions button {
  min-height: 44px;
  padding: 0 18px;
  border-radius: 12px;
  border: 1px solid var(--sc-border);
  cursor: pointer;
  font-weight: 750;
  transition: transform .18s ease, filter .18s ease, background-color .18s ease;
}

.sc-confirm-actions button:hover {
  transform: translateY(-1px);
  filter: brightness(.97);
}

.sc-confirm-actions button:focus-visible {
  outline: 3px solid rgba(196, 123, 18, .22);
  outline-offset: 2px;
}

.sc-confirm-cancel {
  background: var(--sc-surface);
  color: var(--sc-text);
}

.sc-confirm-ok {
  border-color: #dc2626 !important;
  background: #dc2626;
  color: #fff;
}

@keyframes sc-confirm-backdrop-in {
  from { opacity: 0; }
  to { opacity: 1; }
}

@keyframes sc-confirm-card-in {
  from { opacity: 0; transform: translateY(12px) scale(.98); }
  to { opacity: 1; transform: translateY(0) scale(1); }
}

@keyframes sc-toast-in {
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

@media (max-width: 640px) {
  .sc-toast-region {
    inset: 12px 12px auto;
    width: auto;
  }
}

/* =========================================================
   STEELCONTROL — UI GLOBAL OPACA (DASHBOARDS / MÁQUINAS)
   Garante que confirmações e avisos SteelUI nunca herdem
   fundo transparente quando a página não define --sc-*.
========================================================= */
:root {
  --sc-surface: #ffffff;
  --sc-text: #1d2124;
  --sc-text-muted: #64748b;
  --sc-border: #dbe2ea;
  --sc-primary: #c47b12;
  --sc-primary-soft: #f7efe1;
}

html[data-theme="escuro"] {
  --sc-surface: #202529;
  --sc-text: #f8fafc;
  --sc-text-muted: #cbd5e1;
  --sc-border: #41494f;
  --sc-primary: #d79b3c;
  --sc-primary-soft: #2c2923;
}

.sc-toast,
.sc-confirm-card {
  opacity: 1;
  background-color: var(--sc-surface, #ffffff) !important;
  color: var(--sc-text, #1d2124) !important;
  border-color: var(--sc-border, #dbe2ea) !important;
  backdrop-filter: none !important;
  -webkit-backdrop-filter: none !important;
}

.sc-toast {
  /* Mantém somente a animação de entrada, sem efeito de vidro. */
  animation: sc-toast-in .22s ease forwards;
}

.sc-confirm-card h3,
.sc-toast strong {
  color: var(--sc-text, #1d2124) !important;
}

.sc-confirm-card p,
.sc-toast p,
.sc-toast-close {
  color: var(--sc-text-muted, #64748b) !important;
}

.sc-confirm-cancel {
  background-color: var(--sc-surface, #ffffff) !important;
  color: var(--sc-text, #1d2124) !important;
  border-color: var(--sc-border, #dbe2ea) !important;
}

html[data-theme="escuro"] .sc-confirm-backdrop {
  background: rgba(2, 6, 23, .78);
}
