/* ============================================================
   Portal Grupo LC — tema visual
   Paleta extraída do site oficial (grupolclog.com.br) e do logo:
     navy da marca (fundo escuro):     #05314E
     laranja vivo (marca/CTA):         #F99B1D
     laranja acessível (links/texto):  #B56900
     vermelho de destaque (do logo):   #EE2A26 — usado só no selo de atenção
   Estrutura de componentes idêntica ao tema InfraDB, para manter o
   mesmo "look and feel" de portal entre os clientes MSP.
   ============================================================ */

:root {
  --lc-orange: #F99B1D;
  --lc-orange-strong: #B56900;
  --lc-orange-dark: #8F5300;
  --lc-orange-bg: #FFF3E0;

  --lc-navy-900: #05314E;
  --lc-navy-700: #0A4A73;
  --lc-navy-dark: #03233A;

  --lc-red: #EE2A26;
  --lc-red-bg: #FDECEC;

  --lc-gray-900: #202B36;
  --lc-gray-700: #55606B;
  --lc-gray-500: #869097;
  --lc-gray-300: #CBD2D8;
  --lc-gray-200: #E4E8EB;
  --lc-gray-100: #F5F7F8;
  --lc-white: #FFFFFF;

  --radius: 10px;
  --shadow: 0 1px 3px rgba(5, 49, 78, 0.08), 0 1px 2px rgba(5, 49, 78, 0.06);
  --font: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, Helvetica, Arial, sans-serif;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  font-family: var(--font);
  background: var(--lc-gray-100);
  color: var(--lc-gray-900);
  line-height: 1.5;
}

a { color: var(--lc-orange-strong); text-decoration: none; }
a:hover { color: var(--lc-orange-dark); text-decoration: underline; }

h1, h2, h3 { color: var(--lc-gray-900); margin: 0 0 0.5em; }

/* Topbar */
.topbar {
  background: var(--lc-navy-900);
  border-bottom: 3px solid var(--lc-orange);
}
.topbar-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 20px;
  display: flex;
  align-items: center;
  gap: 24px;
  height: 64px;
}
.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  color: var(--lc-white);
}
.brand:hover { text-decoration: none; color: var(--lc-white); }
.brand-logo {
  height: 36px;
  width: auto;
  border-radius: 4px;
  object-fit: contain;
}
.brand-text { display: flex; flex-direction: column; line-height: 1.1; }
.brand-text strong { font-size: 15px; letter-spacing: 0.5px; }
.brand-text small { font-size: 11px; color: var(--lc-gray-300); }

.topnav { display: flex; gap: 20px; flex: 1; }
.topnav a {
  color: var(--lc-gray-200);
  font-size: 14px;
  font-weight: 500;
  padding: 8px 0;
  border-bottom: 2px solid transparent;
}
.topnav a:hover, .topnav a.active {
  color: var(--lc-white);
  text-decoration: none;
  border-bottom-color: var(--lc-orange);
}

.user-box { display: flex; align-items: center; gap: 12px; margin-left: auto; }
.user-name { color: var(--lc-gray-200); font-size: 13px; }

/* Layout */
.content {
  max-width: 1100px;
  margin: 0 auto;
  padding: 32px 20px 60px;
  min-height: calc(100vh - 64px - 56px);
}

.page-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 24px;
  flex-wrap: wrap;
  gap: 12px;
}

/* Cards */
.card {
  background: var(--lc-white);
  border: 1px solid var(--lc-gray-200);
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 24px;
  margin-bottom: 20px;
}

/* Formulários */
label { display: block; font-size: 13px; font-weight: 600; color: var(--lc-gray-700); margin: 16px 0 6px; }
label:first-child { margin-top: 0; }
input[type=text], input[type=password], input[type=email], input[type=file],
select, textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--lc-gray-300);
  border-radius: 8px;
  font-size: 14px;
  font-family: var(--font);
  color: var(--lc-gray-900);
  background: var(--lc-white);
}
input:focus, select:focus, textarea:focus {
  outline: none;
  border-color: var(--lc-orange-strong);
  box-shadow: 0 0 0 3px var(--lc-orange-bg);
}
textarea { resize: vertical; min-height: 120px; }

/* Botões — laranja com texto navy escuro, igual ao site institucional
   (grupolclog.com.br usa exatamente essa combinação nos CTAs). */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 10px 18px;
  border-radius: 8px;
  border: 1px solid transparent;
  font-size: 14px;
  font-weight: 700;
  cursor: pointer;
  text-decoration: none;
}
.btn:hover { text-decoration: none; }
.btn-primary { background: var(--lc-orange); color: var(--lc-navy-900); }
.btn-primary:hover { background: #E08A00; color: var(--lc-navy-900); }
.btn-ghost { background: transparent; color: var(--lc-gray-200); border-color: var(--lc-gray-700); }
.btn-ghost:hover { background: rgba(255,255,255,0.08); color: var(--lc-white); }
.btn-sm { padding: 6px 12px; font-size: 13px; }
.btn-block { width: 100%; }

/* Alertas */
.alert { padding: 12px 16px; border-radius: 8px; font-size: 14px; margin-bottom: 16px; }
.alert-error { background: var(--lc-red-bg); color: #A32320; border: 1px solid #F5C6C4; }
.alert-success { background: var(--lc-orange-bg); color: var(--lc-orange-dark); border: 1px solid #F5D9A8; }

/* Login */
.login-wrap {
  min-height: 100vh;
  display: flex;
  align-items: center;
  justify-content: center;
  background: linear-gradient(160deg, var(--lc-navy-dark) 0%, var(--lc-navy-900) 45%, var(--lc-navy-700) 220%);
  padding: 20px;
}
.login-card {
  background: var(--lc-white);
  border-radius: 16px;
  box-shadow: 0 20px 50px rgba(0,0,0,0.25);
  padding: 40px;
  width: 100%;
  max-width: 400px;
}
.login-logo { text-align: center; margin-bottom: 18px; }
.login-logo img { width: 100%; max-width: 260px; height: auto; border-radius: 12px; }
.login-title { text-align: center; margin-bottom: 4px; }
.login-subtitle { text-align: center; color: var(--lc-gray-500); font-size: 13px; margin-bottom: 24px; }

/* Tabela de chamados */
.ticket-list { display: flex; flex-direction: column; gap: 10px; }
.ticket-row {
  display: flex;
  align-items: center;
  gap: 16px;
  padding: 16px;
  background: var(--lc-white);
  border: 1px solid var(--lc-gray-200);
  border-radius: var(--radius);
  transition: border-color .15s;
}
.ticket-row:hover { border-color: var(--lc-orange-strong); text-decoration: none; }
.ticket-id { color: var(--lc-gray-500); font-size: 12px; width: 56px; flex-shrink: 0; }
.ticket-title { flex: 1; color: var(--lc-gray-900); font-weight: 600; font-size: 14px; }
.ticket-date { color: var(--lc-gray-500); font-size: 12px; flex-shrink: 0; width: 140px; text-align: right; }

/* Badges de status */
.badge {
  display: inline-block;
  padding: 4px 10px;
  border-radius: 20px;
  font-size: 12px;
  font-weight: 600;
  white-space: nowrap;
}
.status-novo { background: #E7EEFB; color: #2A56C6; }
.status-atendimento { background: var(--lc-orange-bg); color: var(--lc-orange-dark); }
.status-pendente { background: #FCF3D8; color: #92670B; }
.status-solucionado { background: #E1F5E4; color: #1E7A31; }
.status-fechado { background: var(--lc-gray-200); color: var(--lc-gray-700); }
.status-default { background: var(--lc-gray-200); color: var(--lc-gray-700); }

/* Selo "aguardando sua resposta": aparece quando o último comentário do
   chamado foi feito pelo técnico e o usuário ainda não respondeu.
   Usa o vermelho do próprio logo do Grupo LC como cor de alerta — fica
   claramente distinto do laranja de marca usado no resto da interface. */
.ticket-row.needs-reply { border-left: 4px solid var(--lc-red); background: var(--lc-red-bg); }
.ticket-row.needs-reply:hover { border-color: var(--lc-orange-strong); border-left-color: var(--lc-red); }
.badge-attention {
  background: #FCDEDD;
  color: #A32320;
  border: 1px solid #F3B7B4;
  display: inline-flex;
  align-items: center;
  gap: 6px;
}
.badge-attention::before {
  content: "";
  width: 7px;
  height: 7px;
  border-radius: 50%;
  background: var(--lc-red);
  display: inline-block;
  flex-shrink: 0;
}

/* Detalhe do chamado */
.followup { padding: 14px 16px; border-left: 3px solid var(--lc-orange); background: var(--lc-gray-100); border-radius: 0 8px 8px 0; margin-bottom: 12px; }
.followup-meta { font-size: 12px; color: var(--lc-gray-500); margin-bottom: 6px; }

/* Empty state */
.empty-state { text-align: center; padding: 60px 20px; color: var(--lc-gray-500); }

/* Footer */
.footer { border-top: 1px solid var(--lc-gray-200); background: var(--lc-white); }
.footer-inner {
  max-width: 1100px;
  margin: 0 auto;
  padding: 18px 20px;
  display: flex;
  justify-content: space-between;
  font-size: 12px;
  color: var(--lc-gray-500);
}

@media (max-width: 640px) {
  .topnav { display: none; }
  .ticket-date { display: none; }
}
