/* ══════════════════════════════════════════════════════════════════════════
   Vadiando Na Net — Tickets de Suporte
   UI compartilhada entre o tema (usuário) e o wp-admin (administração).
   Escopo: .vdt-app
   ══════════════════════════════════════════════════════════════════════════ */

.vdt-app {
  --vdt-bg: var(--bg-base, #0a0a0f);
  --vdt-surface: var(--bg-card, #1a1a26);
  --vdt-surface-2: var(--bg-surface, #12121a);
  --vdt-elevated: var(--bg-elevated, #22222e);
  --vdt-hover: var(--bg-hover, #2a2a3a);
  --vdt-text: var(--text-primary, rgba(255, 255, 255, .92));
  --vdt-text-2: var(--text-secondary, rgba(255, 255, 255, .65));
  --vdt-muted: var(--text-muted, rgba(255, 255, 255, .38));
  --vdt-border: var(--border-subtle, rgba(255, 255, 255, .08));
  --vdt-accent: var(--accent, #e50914);
  --vdt-accent-2: var(--accent-hover, #ff1a25);
  --vdt-gold: var(--gold, #f5c518);
  --vdt-radius: 16px;
  --vdt-radius-sm: 10px;
  --vdt-shadow: 0 12px 34px rgba(0, 0, 0, .28);
  --vdt-open: #f59e0b;
  --vdt-pending: #3b82f6;
  --vdt-resolved: #22c55e;
  --vdt-closed: #94a3b8;
  --vdt-danger: #ef4444;

  max-width: 1120px;
  margin: 0 auto;
  padding: 8px 0 48px;
  color: var(--vdt-text);
  font-size: 15px;
  line-height: 1.55;
  text-align: left;
}

.vdt-app *,
.vdt-app *::before,
.vdt-app *::after { box-sizing: border-box; }

.vdt-app h1,
.vdt-app h2,
.vdt-app h3,
.vdt-app h4 {
  color: var(--vdt-text);
  margin: 0;
  font-weight: 800;
  letter-spacing: -.02em;
  line-height: 1.2;
}
.vdt-app p { margin: 0; }
.vdt-app a { color: var(--vdt-accent); text-decoration: none; }
.vdt-app a:hover { color: var(--vdt-accent-2); }
.vdt-app small { font-size: .8rem; }
.vdt-app strong { color: var(--vdt-text); }

.vdt-sr-only {
  position: absolute !important;
  width: 1px; height: 1px;
  padding: 0; margin: -1px;
  overflow: hidden; clip: rect(0, 0, 0, 0);
  white-space: nowrap; border: 0;
}
.vdt-muted { color: var(--vdt-muted); }
.vdt-hint { color: var(--vdt-muted); font-size: .82rem; }

.vdt-icon {
  width: 18px;
  height: 18px;
  flex: 0 0 auto;
  display: inline-block;
  vertical-align: -.18em;
}

/* ─── Hero ──────────────────────────────────────────────────────────────── */
.vdt-hero {
  position: relative;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 24px;
  padding: 28px 30px;
  margin-bottom: 20px;
  border: 1px solid var(--vdt-border);
  border-radius: var(--vdt-radius);
  background:
    radial-gradient(120% 160% at 100% 0%, rgba(229, 9, 20, .16), transparent 55%),
    linear-gradient(135deg, var(--vdt-surface), var(--vdt-surface-2));
  box-shadow: var(--vdt-shadow);
  overflow: hidden;
}
.vdt-hero::after {
  content: "";
  position: absolute;
  inset: auto -40px -80px auto;
  width: 220px;
  height: 220px;
  border-radius: 50%;
  background: radial-gradient(circle, rgba(229, 9, 20, .18), transparent 65%);
  pointer-events: none;
}
.vdt-eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 10px;
  color: var(--vdt-gold);
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .12em;
  text-transform: uppercase;
}
.vdt-eyebrow .vdt-icon { width: 15px; height: 15px; }
.vdt-hero h1 { font-size: clamp(1.5rem, 3vw, 2rem); }
.vdt-hero p {
  margin-top: 8px;
  max-width: 62ch;
  color: var(--vdt-text-2);
  font-size: .95rem;
}
.vdt-hero__actions {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

/* ─── Botões ────────────────────────────────────────────────────────────── */
.vdt-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  min-height: 42px;
  padding: 10px 18px;
  border: 1px solid transparent;
  border-radius: 999px;
  background: var(--vdt-elevated);
  color: var(--vdt-text);
  font: inherit;
  font-size: .88rem;
  font-weight: 700;
  line-height: 1;
  text-decoration: none;
  cursor: pointer;
  white-space: nowrap;
  transition: transform .15s ease, background .15s ease, border-color .15s ease, color .15s ease, box-shadow .15s ease;
}
.vdt-btn:hover { transform: translateY(-1px); color: var(--vdt-text); }
.vdt-btn:active { transform: translateY(0); }
.vdt-btn:focus-visible { outline: 2px solid var(--vdt-accent); outline-offset: 2px; }
.vdt-btn:disabled { opacity: .55; cursor: progress; transform: none; }
.vdt-btn .vdt-icon { width: 17px; height: 17px; }

.vdt-btn--primary {
  background: linear-gradient(135deg, var(--vdt-accent), #b80710);
  color: #fff !important;
  box-shadow: 0 8px 20px rgba(229, 9, 20, .28);
}
.vdt-btn--primary span,
.vdt-btn--primary .vdt-icon { color: inherit; }
.vdt-btn--primary:hover { background: linear-gradient(135deg, var(--vdt-accent-2), #d40812); color: #fff; }

.vdt-btn--ghost {
  background: transparent;
  border-color: var(--vdt-border);
  color: var(--vdt-text-2);
}
.vdt-btn--ghost:hover { border-color: var(--vdt-accent); color: var(--vdt-text); background: rgba(229, 9, 20, .06); }

.vdt-btn--subtle { background: var(--vdt-elevated); border-color: var(--vdt-border); color: var(--vdt-text); }
.vdt-btn--subtle:hover { border-color: var(--vdt-accent); background: var(--vdt-hover); }

.vdt-btn--success { background: rgba(34, 197, 94, .14); border-color: rgba(34, 197, 94, .4); color: #4ade80; }
.vdt-btn--success:hover { background: rgba(34, 197, 94, .22); color: #86efac; }

.vdt-btn--danger { background: rgba(239, 68, 68, .12); border-color: rgba(239, 68, 68, .35); color: #f87171; }
.vdt-btn--danger:hover { background: rgba(239, 68, 68, .2); color: #fca5a5; }

.vdt-btn--sm { min-height: 34px; padding: 7px 13px; font-size: .8rem; }
.vdt-btn--block { width: 100%; }

/* ─── Alertas ───────────────────────────────────────────────────────────── */
.vdt-alert {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  padding: 14px 16px;
  margin-bottom: 18px;
  border: 1px solid var(--vdt-border);
  border-radius: var(--vdt-radius-sm);
  background: var(--vdt-surface);
  font-size: .9rem;
  animation: vdt-fade .25s ease both;
}
.vdt-alert > .vdt-icon { width: 20px; height: 20px; margin-top: 1px; }
.vdt-alert strong { display: block; margin-bottom: 2px; }
.vdt-alert p { margin: 0; color: var(--vdt-text-2); }
.vdt-alert--success { border-color: rgba(34, 197, 94, .3); background: rgba(34, 197, 94, .09); color: #4ade80; }
.vdt-alert--error { border-color: rgba(239, 68, 68, .3); background: rgba(239, 68, 68, .09); color: #f87171; }
.vdt-alert--warning { border-color: rgba(245, 158, 11, .32); background: rgba(245, 158, 11, .09); color: #fbbf24; }
.vdt-alert .vdt-link { display: inline-flex; align-items: center; gap: 4px; margin-top: 8px; font-weight: 700; }
.vdt-alert .vdt-link .vdt-icon { width: 14px; height: 14px; }

/* ─── Estatísticas ──────────────────────────────────────────────────────── */
.vdt-stats {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(158px, 1fr));
  gap: 12px;
  margin-bottom: 20px;
}
.vdt-stat {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 16px 18px;
  border: 1px solid var(--vdt-border);
  border-radius: var(--vdt-radius-sm);
  background: var(--vdt-surface);
  transition: transform .15s ease, border-color .15s ease;
}
.vdt-stat--link:hover { transform: translateY(-2px); border-color: var(--vdt-accent); }
.vdt-stat__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  flex: 0 0 auto;
  border-radius: 12px;
  background: var(--vdt-elevated);
  color: var(--vdt-text-2);
}
.vdt-stat__icon--open { background: rgba(245, 158, 11, .14); color: var(--vdt-open); }
.vdt-stat__icon--pending { background: rgba(59, 130, 246, .14); color: #60a5fa; }
.vdt-stat__icon--resolved { background: rgba(34, 197, 94, .14); color: #4ade80; }
.vdt-stat__icon--total { background: rgba(148, 163, 184, .14); color: #cbd5e1; }
.vdt-stat strong { display: block; font-size: 1.45rem; font-weight: 800; line-height: 1.1; }
.vdt-stat div > span { color: var(--vdt-muted); font-size: .74rem; font-weight: 700; text-transform: uppercase; letter-spacing: .06em; }

/* ─── Painéis / cartões ─────────────────────────────────────────────────── */
.vdt-panel {
  border: 1px solid var(--vdt-border);
  border-radius: var(--vdt-radius);
  background: var(--vdt-surface);
  box-shadow: 0 1px 0 rgba(255, 255, 255, .02);
}
.vdt-section-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 20px 14px;
}
.vdt-section-head h2 {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 1rem;
  font-weight: 800;
}
.vdt-section-head h2 .vdt-icon { color: var(--vdt-accent); }
.vdt-count { color: var(--vdt-muted); font-size: .8rem; font-weight: 600; }

.vdt-new { margin-bottom: 20px; overflow: hidden; }
.vdt-new__summary {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 18px 20px;
  list-style: none;
  cursor: pointer;
  user-select: none;
}
.vdt-new__summary::-webkit-details-marker { display: none; }
.vdt-new__summary > span:nth-child(2) { flex: 1; min-width: 0; }
.vdt-new__summary strong { display: block; font-size: .98rem; }
.vdt-new__summary small { display: block; margin-top: 2px; color: var(--vdt-muted); font-size: .82rem; }
.vdt-new__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 40px; height: 40px;
  flex: 0 0 auto;
  border-radius: 12px;
  background: rgba(229, 9, 20, .12);
  color: var(--vdt-accent);
}
.vdt-new__chevron { color: var(--vdt-muted); transition: transform .2s ease; }
.vdt-new[open] .vdt-new__chevron { transform: rotate(90deg); }
.vdt-new[open] .vdt-new__summary { border-bottom: 1px solid var(--vdt-border); }

/* ─── Formulários ───────────────────────────────────────────────────────── */
.vdt-form { padding: 20px; }
.vdt-form__grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  margin-bottom: 16px;
}
.vdt-field { display: flex; flex-direction: column; gap: 6px; min-width: 0; }
.vdt-field label {
  color: var(--vdt-text-2);
  font-size: .78rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .05em;
  margin: 0;
}
.vdt-app input[type="text"],
.vdt-app input[type="search"],
.vdt-app input[type="email"],
.vdt-app input[type="url"],
.vdt-app select,
.vdt-app textarea {
  width: 100%;
  min-height: 44px;
  padding: 11px 13px;
  border: 1px solid var(--vdt-border);
  border-radius: var(--vdt-radius-sm);
  background: var(--vdt-surface-2);
  color: var(--vdt-text);
  font: inherit;
  font-size: .88rem;
  line-height: 1.4;
  transition: border-color .15s ease, box-shadow .15s ease, background .15s ease;
}
.vdt-app textarea { resize: vertical; min-height: 120px; }
.vdt-app input::placeholder,
.vdt-app textarea::placeholder { color: var(--vdt-muted); opacity: .8; }
.vdt-app input:focus,
.vdt-app select:focus,
.vdt-app textarea:focus {
  outline: none;
  border-color: var(--vdt-accent);
  box-shadow: 0 0 0 3px rgba(229, 9, 20, .14);
  background: var(--vdt-surface);
}
.vdt-app select {
  appearance: none;
  -webkit-appearance: none;
  background-image: linear-gradient(45deg, transparent 50%, var(--vdt-muted) 50%), linear-gradient(135deg, var(--vdt-muted) 50%, transparent 50%);
  background-position: calc(100% - 18px) 19px, calc(100% - 13px) 19px;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
  padding-right: 34px;
}
.vdt-field__foot { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.vdt-form__actions { display: flex; justify-content: flex-end; margin-top: 16px; }

.vdt-check {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--vdt-text-2);
  font-size: .8rem;
  font-weight: 600;
  cursor: pointer;
}
.vdt-check input { width: 16px; height: 16px; accent-color: var(--vdt-gold); }
.vdt-check .vdt-icon { width: 15px; height: 15px; color: var(--vdt-gold); }

/* ─── Filtros ───────────────────────────────────────────────────────────── */
.vdt-toolbar {
  display: flex;
  align-items: flex-end;
  gap: 10px;
  flex-wrap: wrap;
  padding: 18px 20px;
  border-bottom: 1px solid var(--vdt-border);
}
.vdt-toolbar .vdt-field { flex: 1 1 170px; }
.vdt-toolbar .vdt-field--search { flex: 2 1 260px; position: relative; }
.vdt-toolbar__actions { display: flex; gap: 8px; margin-left: auto; }
.vdt-field__icon {
  position: absolute;
  left: 13px;
  bottom: 13px;
  color: var(--vdt-muted);
  pointer-events: none;
}
.vdt-field--search input { padding-left: 40px; }

/* ─── Lista de tickets (usuário) ────────────────────────────────────────── */
.vdt-ticket-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  padding: 0 20px 20px;
}
.vdt-ticket-card {
  display: flex;
  flex-direction: column;
  gap: 8px;
  padding: 16px;
  border: 1px solid var(--vdt-border);
  border-radius: var(--vdt-radius-sm);
  background: var(--vdt-surface-2);
  color: var(--vdt-text);
  transition: transform .15s ease, border-color .15s ease, background .15s ease;
}
.vdt-ticket-card:hover {
  transform: translateY(-2px);
  border-color: var(--vdt-accent);
  background: var(--vdt-elevated);
  color: var(--vdt-text);
}
.vdt-ticket-card.is-unread { border-color: rgba(59, 130, 246, .45); box-shadow: inset 3px 0 0 var(--vdt-pending); }
.vdt-ticket-card__top { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; }
.vdt-ticket-card h3 { font-size: .98rem; font-weight: 800; }
.vdt-ticket-card p { color: var(--vdt-text-2); font-size: .84rem; line-height: 1.5; }
.vdt-ticket-card__foot {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-top: auto;
  padding-top: 8px;
  border-top: 1px solid var(--vdt-border);
  color: var(--vdt-muted);
  font-size: .74rem;
  font-weight: 600;
}
.vdt-ticket-card__foot span { display: inline-flex; align-items: center; gap: 4px; }
.vdt-ticket-card__foot .vdt-icon { width: 13px; height: 13px; }
.vdt-ticket-card__go { margin-left: auto; color: var(--vdt-accent); }
.vdt-ticket-card__go .vdt-icon { width: 14px; height: 14px; }

.vdt-id {
  display: inline-flex;
  align-items: center;
  padding: 2px 8px;
  border-radius: 999px;
  background: var(--vdt-elevated);
  color: var(--vdt-text-2);
  font-size: .72rem;
  font-weight: 800;
  letter-spacing: .02em;
}
.vdt-cat { color: var(--vdt-muted); font-size: .76rem; font-weight: 600; }
.vdt-unread {
  margin-left: auto;
  padding: 2px 8px;
  border-radius: 999px;
  background: rgba(59, 130, 246, .16);
  color: #93c5fd;
  font-size: .68rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .05em;
}

/* ─── Badges ────────────────────────────────────────────────────────────── */
.vdt-badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  padding: 3px 9px;
  border-radius: 999px;
  background: var(--vdt-elevated);
  color: var(--vdt-text-2);
  font-size: .7rem;
  font-weight: 800;
  letter-spacing: .02em;
  white-space: nowrap;
}
.vdt-badge .vdt-icon { width: 13px; height: 13px; }
.vdt-badge--open { background: rgba(245, 158, 11, .14); color: #fbbf24; }
.vdt-badge--pending { background: rgba(59, 130, 246, .15); color: #93c5fd; }
.vdt-badge--resolved { background: rgba(34, 197, 94, .14); color: #86efac; }
.vdt-badge--closed { background: rgba(148, 163, 184, .14); color: #cbd5e1; }
.vdt-badge--danger { background: rgba(239, 68, 68, .14); color: #fca5a5; }
.vdt-badge--team { background: rgba(229, 9, 20, .12); color: #fda4af; }
.vdt-badge--internal { background: rgba(245, 197, 24, .13); color: var(--vdt-gold); }

.vdt-priority {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: .72rem;
  font-weight: 700;
  color: var(--vdt-muted);
}
.vdt-priority::before {
  content: "";
  width: 7px; height: 7px;
  border-radius: 50%;
  background: currentColor;
}
.vdt-priority--low { color: #94a3b8; }
.vdt-priority--normal { color: #60a5fa; }
.vdt-priority--high { color: #fb923c; }
.vdt-priority--urgent { color: #f87171; }

/* ─── Detalhe ───────────────────────────────────────────────────────────── */
.vdt-back {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  margin-bottom: 14px;
  color: var(--vdt-text-2);
  font-size: .84rem;
  font-weight: 700;
}
.vdt-back:hover { color: var(--vdt-accent); }
.vdt-back .vdt-icon { width: 16px; height: 16px; }

.vdt-detail-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  padding: 22px 24px;
  margin-bottom: 16px;
}
.vdt-detail-head__main { min-width: 0; }
.vdt-detail-head__meta { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; margin-bottom: 8px; }
.vdt-detail-head h1 { font-size: clamp(1.2rem, 2.4vw, 1.55rem); }
.vdt-detail-head__sub {
  display: flex;
  align-items: center;
  gap: 5px;
  flex-wrap: wrap;
  margin-top: 8px;
  color: var(--vdt-muted);
  font-size: .78rem;
}
.vdt-detail-head__sub .vdt-icon { width: 14px; height: 14px; }
.vdt-detail-head__badges { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; flex: 0 0 auto; }

.vdt-detail-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 310px;
  gap: 16px;
  align-items: start;
}

.vdt-thread-panel { overflow: hidden; }
.vdt-thread {
  display: flex;
  flex-direction: column;
  gap: 12px;
  max-height: 560px;
  overflow-y: auto;
  padding: 0 20px 18px;
  scrollbar-width: thin;
}
.vdt-thread::-webkit-scrollbar { width: 9px; }
.vdt-thread::-webkit-scrollbar-thumb { background: var(--vdt-hover); border-radius: 99px; }

.vdt-msg {
  display: flex;
  align-items: flex-start;
  gap: 10px;
  animation: vdt-fade .22s ease both;
}
.vdt-msg__avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 38px; height: 38px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--vdt-elevated);
  color: var(--vdt-text-2);
  font-size: .9rem;
  font-weight: 800;
  text-transform: uppercase;
}
.vdt-msg__body {
  flex: 1;
  min-width: 0;
  padding: 12px 14px;
  border: 1px solid var(--vdt-border);
  border-radius: 4px 14px 14px 14px;
  background: var(--vdt-surface-2);
}
.vdt-msg--admin .vdt-msg__body { border-left: 3px solid var(--vdt-accent); background: rgba(229, 9, 20, .05); }
.vdt-msg--admin .vdt-msg__avatar { background: rgba(229, 9, 20, .14); color: #fda4af; }
.vdt-msg--internal .vdt-msg__body { border-left-color: var(--vdt-gold); background: rgba(245, 197, 24, .06); }
.vdt-msg--internal .vdt-msg__avatar { background: rgba(245, 197, 24, .14); color: var(--vdt-gold); }
.vdt-msg__head { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin-bottom: 5px; }
.vdt-msg__head strong { font-size: .82rem; }
.vdt-msg__head time { margin-left: auto; color: var(--vdt-muted); font-size: .72rem; }
.vdt-msg__text { color: var(--vdt-text); font-size: .9rem; line-height: 1.65; word-break: break-word; }

.vdt-system {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  flex-wrap: wrap;
  padding: 8px 12px;
  color: var(--vdt-muted);
  font-size: .76rem;
  text-align: center;
}
.vdt-system::before { content: ""; flex: 1; height: 1px; background: var(--vdt-border); }
.vdt-system::after { content: ""; flex: 1; height: 1px; background: var(--vdt-border); }
.vdt-system__time { opacity: .7; }

.vdt-divider { border: 0; border-top: 1px solid var(--vdt-border); margin: 0; }

.vdt-composer { padding: 18px 20px 20px; }
.vdt-composer__label {
  display: block;
  margin-bottom: 8px;
  color: var(--vdt-text-2);
  font-size: .8rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .05em;
}
.vdt-composer textarea { min-height: 130px; }
.vdt-composer__foot {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  margin-top: 10px;
}
.vdt-composer__tools { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; }
.vdt-counter { color: var(--vdt-muted); font-size: .74rem; font-variant-numeric: tabular-nums; }

.vdt-closed-note {
  display: flex;
  align-items: center;
  gap: 12px;
  flex-wrap: wrap;
  margin: 0 20px 20px;
  padding: 14px 16px;
  border: 1px solid var(--vdt-border);
  border-radius: var(--vdt-radius-sm);
  background: var(--vdt-surface-2);
  color: var(--vdt-text-2);
  font-size: .85rem;
}
.vdt-closed-note > .vdt-icon { color: var(--vdt-muted); }
.vdt-closed-note div { flex: 1; }
.vdt-closed-note strong { display: block; }
.vdt-closed-note p { color: var(--vdt-muted); }

/* ─── Sidebar / ações ───────────────────────────────────────────────────── */
.vdt-aside { display: flex; flex-direction: column; gap: 12px; position: sticky; top: 24px; }
.vdt-aside__card { padding: 18px; }
.vdt-aside__card h3 {
  display: flex;
  align-items: center;
  gap: 7px;
  margin-bottom: 14px;
  font-size: .82rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: .06em;
  color: var(--vdt-text-2);
}
.vdt-aside__card h3 .vdt-icon { width: 16px; height: 16px; color: var(--vdt-accent); }
.vdt-dl { display: flex; flex-direction: column; gap: 9px; margin: 0; }
.vdt-dl > div { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.vdt-dl dt { color: var(--vdt-muted); font-size: .76rem; font-weight: 600; }
.vdt-dl dd { margin: 0; color: var(--vdt-text); font-size: .82rem; font-weight: 700; text-align: right; }
.vdt-stack { display: flex; flex-direction: column; gap: 8px; }

.vdt-inline-form { margin-bottom: 12px; }
.vdt-inline-form:last-child { margin-bottom: 0; }
.vdt-inline-form label {
  display: block;
  margin-bottom: 5px;
  color: var(--vdt-muted);
  font-size: .74rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .05em;
}
.vdt-inline-form__row { display: flex; gap: 8px; }
.vdt-inline-form__row select { flex: 1; min-width: 0; }
.vdt-inline-form__row .vdt-btn { flex: 0 0 auto; border-radius: var(--vdt-radius-sm); }

.vdt-user-card { display: flex; flex-direction: column; gap: 12px; }
.vdt-user-card__avatar {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 46px; height: 46px;
  border-radius: 50%;
  background: rgba(229, 9, 20, .14);
  color: #fda4af;
  font-size: 1.1rem;
  font-weight: 800;
  text-transform: uppercase;
}
.vdt-user-card__info { display: flex; flex-direction: column; gap: 1px; min-width: 0; }
.vdt-user-card__info strong { font-size: .95rem; }
.vdt-user-card__info span { color: var(--vdt-text-2); font-size: .8rem; overflow-wrap: anywhere; }
.vdt-user-card .vdt-badge { align-self: flex-start; }

/* ─── Tabela administrativa ─────────────────────────────────────────────── */
.vdt-section-head--table { border-bottom: 1px solid var(--vdt-border); }
.vdt-table-wrap { overflow-x: auto; }
.vdt-table { width: 100%; border-collapse: collapse; font-size: .85rem; }
.vdt-table th {
  padding: 11px 16px;
  border-bottom: 1px solid var(--vdt-border);
  background: var(--vdt-surface-2);
  color: var(--vdt-muted);
  font-size: .7rem;
  font-weight: 800;
  text-align: left;
  text-transform: uppercase;
  letter-spacing: .06em;
  white-space: nowrap;
}
.vdt-table td {
  padding: 13px 16px;
  border-bottom: 1px solid var(--vdt-border);
  vertical-align: middle;
  color: var(--vdt-text-2);
}
.vdt-table tbody tr { transition: background .12s ease; }
.vdt-table tbody tr:hover { background: var(--vdt-hover); }
.vdt-table tbody tr:last-child td { border-bottom: 0; }
.vdt-table tbody tr.is-unread { background: rgba(59, 130, 246, .05); }
.vdt-table__subject {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  color: var(--vdt-text);
  font-weight: 700;
  font-size: .86rem;
}
.vdt-table__subject:hover { color: var(--vdt-accent); }
.vdt-table__excerpt { display: block; max-width: 360px; margin-top: 2px; color: var(--vdt-muted); font-size: .76rem; }
.vdt-table td small { display: block; color: var(--vdt-muted); font-size: .74rem; }
.vdt-table__actions { text-align: right; white-space: nowrap; }
.vdt-unread-dot {
  width: 8px; height: 8px;
  flex: 0 0 auto;
  border-radius: 50%;
  background: var(--vdt-pending);
  box-shadow: 0 0 0 3px rgba(59, 130, 246, .16);
}

/* ─── Paginação ─────────────────────────────────────────────────────────── */
.vdt-pagination {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  flex-wrap: wrap;
  padding: 16px 20px 20px;
  border-top: 1px solid var(--vdt-border);
}
.vdt-page {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 36px;
  height: 36px;
  padding: 0 10px;
  border: 1px solid var(--vdt-border);
  border-radius: 9px;
  background: var(--vdt-surface-2);
  color: var(--vdt-text-2);
  font-size: .82rem;
  font-weight: 700;
}
.vdt-page:hover { border-color: var(--vdt-accent); color: var(--vdt-text); }
.vdt-page--current { background: var(--vdt-accent); border-color: var(--vdt-accent); color: #fff; }
.vdt-page--gap { border-color: transparent; background: transparent; color: var(--vdt-muted); }

/* ─── Estado vazio ──────────────────────────────────────────────────────── */
.vdt-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 6px;
  padding: 48px 24px;
  text-align: center;
  color: var(--vdt-muted);
}
.vdt-empty .vdt-icon { width: 40px; height: 40px; opacity: .5; margin-bottom: 4px; }
.vdt-empty h3 { font-size: 1rem; color: var(--vdt-text); }
.vdt-empty p { max-width: 44ch; font-size: .85rem; }
.vdt-empty--thread { padding: 32px 16px; }

/* ─── Light theme ───────────────────────────────────────────────────────── */
[data-theme="light"] .vdt-app {
  --vdt-shadow: 0 10px 30px rgba(0, 0, 0, .07);
}
[data-theme="light"] .vdt-msg__body { background: #f8f8fa; }
[data-theme="light"] .vdt-msg--admin .vdt-msg__body { background: rgba(229, 9, 20, .04); }
[data-theme="light"] .vdt-msg--internal .vdt-msg__body { background: rgba(245, 197, 24, .08); }
[data-theme="light"] .vdt-stat__icon { background: #f0f0f2; }
[data-theme="light"] .vdt-btn--ghost { color: #4a4a4a; }
[data-theme="light"] .vdt-table td { color: #4a4a4a; }
[data-theme="light"] .vdt-badge { background: #ececf0; color: #4a4a4a; }

/* ─── wp-admin: neutraliza estilos globais do core que vazam ────────────── */
.vadiando-admin .vdt-app { margin: 0; }
.vadiando-admin .vdt-app .vdt-btn { box-shadow: none; }
.vadiando-admin .vdt-app .vdt-btn--primary { color: #fff !important; box-shadow: 0 8px 20px rgba(229, 9, 20, .28); }
.vadiando-admin .vdt-app input[type="checkbox"] { min-height: 0; }
body.wp-admin .vdt-aside { top: 40px; }

/* ─── Responsivo ────────────────────────────────────────────────────────── */
@media (max-width: 980px) {
  .vdt-detail-grid { grid-template-columns: minmax(0, 1fr); }
  .vdt-aside { position: static; flex-direction: row; flex-wrap: wrap; }
  .vdt-aside__card { flex: 1 1 260px; }
  .vdt-ticket-list { grid-template-columns: minmax(0, 1fr); }
}

@media (max-width: 760px) {
  .vdt-app { font-size: 14px; padding-bottom: 32px; }
  .vdt-hero { grid-template-columns: minmax(0, 1fr); padding: 22px 20px; }
  .vdt-hero__actions { width: 100%; }
  .vdt-hero__actions .vdt-btn { flex: 1 1 auto; }
  .vdt-form__grid { grid-template-columns: minmax(0, 1fr); }
  .vdt-toolbar { padding: 16px; }
  .vdt-toolbar .vdt-field { flex: 1 1 100%; }
  .vdt-toolbar__actions { width: 100%; margin-left: 0; }
  .vdt-toolbar__actions .vdt-btn { flex: 1; }
  .vdt-detail-head { flex-direction: column; padding: 18px; }
  .vdt-detail-head__badges { width: 100%; }
  .vdt-section-head { padding: 16px 16px 12px; }
  .vdt-thread { padding: 0 14px 14px; max-height: none; }
  .vdt-composer { padding: 16px; }
  .vdt-composer__foot { align-items: stretch; }
  .vdt-composer__foot .vdt-btn { width: 100%; }
  .vdt-aside { flex-direction: column; }
  .vdt-form { padding: 16px; }
  .vdt-ticket-list { padding: 0 16px 16px; }
  .vdt-msg__avatar { width: 32px; height: 32px; font-size: .8rem; }
  .vdt-msg__head time { margin-left: 0; }

  /* Tabela vira cartões */
  .vdt-table thead { display: none; }
  .vdt-table, .vdt-table tbody, .vdt-table tr, .vdt-table td { display: block; width: 100%; }
  .vdt-table tr {
    padding: 12px 14px;
    border-bottom: 1px solid var(--vdt-border);
  }
  .vdt-table td { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 5px 0; border: 0; text-align: right; }
  .vdt-table td::before {
    content: attr(data-label);
    flex: 0 0 auto;
    color: var(--vdt-muted);
    font-size: .68rem;
    font-weight: 800;
    text-transform: uppercase;
    letter-spacing: .05em;
    text-align: left;
  }
  .vdt-table td[data-label="Ticket"] { display: block; text-align: left; }
  .vdt-table td[data-label="Ticket"]::before { display: none; }
  .vdt-table__excerpt { max-width: none; }
  .vdt-table__actions { justify-content: flex-end; }
}

@media (max-width: 480px) {
  .vdt-stats { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .vdt-stat { padding: 13px; gap: 10px; }
  .vdt-stat__icon { width: 36px; height: 36px; }
  .vdt-stat strong { font-size: 1.2rem; }
  .vdt-stat div > span { font-size: .66rem; }
  .vdt-ticket-card__foot { gap: 10px; }
  .vdt-ticket-card__go { width: 100%; margin-left: 0; }
}

/* ─── Movimento reduzido ────────────────────────────────────────────────── */
@media (prefers-reduced-motion: reduce) {
  .vdt-app *, .vdt-app *::before, .vdt-app *::after {
    animation-duration: .01ms !important;
    transition-duration: .01ms !important;
    scroll-behavior: auto !important;
  }
}

@keyframes vdt-fade {
  from { opacity: 0; transform: translateY(6px); }
  to { opacity: 1; transform: translateY(0); }
}
