:root {
  --primary: #0b5ed7;
  --primary-dark: #0948a8;
  --accent: #ff7a18;
  --bg1: #e6f0ff;
  --bg2: #fdfbfb;
  --muted: #6b7280;
  --radius: 14px;
  --shadow: 0 8px 24px rgba(0,0,0,0.08);
  --maxw: 1100px;
}

/* Reset */
* { box-sizing: border-box; font-family: "Poppins", Inter, ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial; }
html, body { height: 100%; margin: 0; }
body {
  background: linear-gradient(135deg, rgba(11,94,215,0.08), rgba(255,122,24,0.03)),
              linear-gradient(45deg, #fdfbfb, #ebedee);
  color: #0f172a;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
  padding-bottom: 48px;
}

/* header */
.header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 16px 24px;
  border-bottom: 1px solid rgba(15,23,42,0.06);
  background: rgba(255,255,255,0.75);
  backdrop-filter: blur(6px);
  box-shadow: var(--shadow);
  position: sticky;
  top: 0;
  z-index: 20;
}
.brand { display: flex; gap: 12px; align-items: center; font-weight: 700; color: var(--primary); }
.logo {
  width: 64px; height: 64px; border-radius: 12px;
  background: linear-gradient(135deg, var(--primary), var(--accent));
  display:flex; align-items:center; justify-content:center;
  overflow:hidden;
  box-shadow: 0 8px 20px rgba(11,94,215,0.12);
}
.brand .text strong { display:block; font-size:18px; color:var(--primary); }
.brand .small { font-size:12px; color:var(--muted); margin-top:2px; }

/* actions */
.actions { display:flex; gap:8px; align-items:center; }

/* BOTÕES */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 8px 14px;
  font-weight: 600;
  font-size: 14px;
  border-radius: var(--radius);
  border: none;
  cursor: pointer;
  background: linear-gradient(90deg, var(--primary), var(--primary-dark));
  color: #fff;
  box-shadow: 0 4px 12px rgba(11,94,215,0.15);
  transition: transform .12s ease, box-shadow .12s ease, background .2s ease;
}
.btn:hover { transform: translateY(-2px); box-shadow: 0 6px 20px rgba(11,94,215,0.22); }

/* variantes */
.btn.small { padding: 6px 12px; font-size: 13px; border-radius: 10px; }
.btn.danger { background: linear-gradient(90deg, #dc2626, #b91c1c); box-shadow: 0 4px 12px rgba(220,38,38,0.2); }
.btn.danger:hover { background: linear-gradient(90deg, #ef4444, #b91c1c); }
.btn.secondary { background: #fff; color: var(--primary); border: 1px solid rgba(11,94,215,0.2); }
.btn.secondary:hover { background: var(--bg1); }
.btn.ghost { background: transparent; border: 1px dashed rgba(11,94,215,0.25); color: var(--primary); }
.btn.ghost:hover { background: rgba(11,94,215,0.04); }
.btn.outline { background: transparent; border: 1px solid rgba(11,94,215,0.25); color: var(--primary); }
.btn.outline:hover { background: var(--bg1); }

/* container */
.container { max-width: var(--maxw); margin: 28px auto; padding: 20px; }

/* cards */
.card {
  background: #fff;
  border-radius: var(--radius);
  box-shadow: var(--shadow);
  padding: 20px;
  margin-bottom: 16px;
  transition: transform .12s ease;
}
.card:hover { transform: translateY(-2px); }

/* inputs */
.input, textarea, select {
  width:100%;
  padding: 12px 14px;
  border-radius: 10px;
  border: 1px solid #eef4ff;
  background: #fbfdff;
  font-size: 14px;
  transition: box-shadow .12s ease, border-color .12s ease;
}
.input:focus, textarea:focus, select:focus {
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(11,94,215,0.1);
}
textarea { min-height:120px; resize:vertical; }

/* tabelas */
.table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
  margin-top: 14px;
}
.table th, .table td {
  padding: 10px 12px;
  border-bottom: 1px solid #f2f2f2;
  text-align: center;
}
.table tr:nth-child(even) { background: #fafafa; }
.table td.actions { display: flex; gap: 6px; justify-content: center; }

/* split layout */
.split {
  display: grid;
  grid-template-columns: 1fr 340px;
  gap: 20px;
  margin-top: 16px;
}

/* status pills/badges */
.status-badge, .status-pill {
  display: inline-block;
  padding: 6px 12px;
  border-radius: 999px;
  font-weight: 700;
  font-size: 12px;
  min-width: 80px;
}
.status-new { background: rgba(11,94,215,0.14); color: var(--primary); }
.status-in_progress { background: rgba(255,122,24,0.12); color: var(--accent); }
.status-resolved { background: rgba(16,185,129,0.12); color: #059669; }
.status-closed { background: #f1f5f9; color: #6b7280; }

/* footer */
.footer { max-width: var(--maxw); margin: 20px auto; color: var(--muted); text-align:center; font-size: .9rem; }

/* responsivo */
@media (max-width: 900px) {
  .split { grid-template-columns: 1fr; }
  .form-row { flex-direction: column; }
  .btn, .input, select { width: 100%; }
}

/* ----------------------------
   ADIÇÕES: pequenas correções para não quebrar layout
   (preservando TODO o CSS acima)
   ---------------------------- */

@media (max-width:1150px){
  /* manter comportamento semelhante ao inline CSS */
  .dashboard-grid { grid-template-columns: 360px 1fr; }
}

@media (max-width:900px){
  /* garantir cartões do hero e login ocupem a largura */
  .hero-right, .login-card, #registerCard { width: 100% !important; max-width: 100% !important; box-sizing: border-box; }
  /* header buttons wrap */
  .header .actions { flex-wrap: wrap; gap: 8px; }
  /* adaptar lista/detalhe */
  .tickets-list { max-height: 30vh !important; padding-right: 6px; }
  .ticket-detail { max-height: 50vh !important; }
  /* garantir inputs e botões em fullwidth */
  .btn, .input, select, textarea { width: 100% !important; box-sizing: border-box; }
  .ticket-meta .title { white-space: normal; overflow: visible; }
  .status-badge { min-width: 64px; padding:6px 6px; font-size:11px; }
}

/* Fim das alterações (compatíveis) */
