/* =====================================================================
   GoPentest × Xantus — dashboard.css
   Komponen khusus halaman "Dashboard Saya". File ini TIDAK berdiri
   sendiri — selalu dimuat SETELAH /public/css/style.css karena semua
   nilai warna/font/radius di sini pakai custom property (--attack,
   --ink-900, --font-mono, dst) yang didefinisikan di style.css :root.
   Tab (.tabs-nav/.tab-btn/.tab-panel), form (.input-control), dan alert
   (.form-alert) SENGAJA tidak diulang di sini — itu sudah ada di
   style.css dan dipakai apa adanya supaya dashboard konsisten dengan
   halaman tools/create lain.
   ===================================================================== */

/* ---------- Kartu profil ---------- */
.profile-card {
  background: var(--ink-900);
  border: 1px solid var(--line);
  border-radius: var(--radius-lg);
  padding: clamp(20px, 3vw, 28px);
  margin-bottom: 28px;
}

.profile-top {
  display: flex; align-items: center; gap: 16px;
  margin-bottom: 24px; flex-wrap: wrap;
}

.profile-avatar {
  width: 60px; height: 60px; border-radius: 50%; flex-shrink: 0;
  display: flex; align-items: center; justify-content: center;
  font-family: var(--font-display); font-weight: 700; font-size: 22px;
  color: #fff; background: var(--attack);
}

.profile-info { flex: 1; min-width: 160px; }
.profile-email { font-size: 14px; font-weight: 700; color: var(--text-1); word-break: break-all; }
.profile-since { font-family: var(--font-mono); font-size: 10.5px; color: var(--text-3); margin-top: 3px; }

.logout-btn {
  display: inline-flex; align-items: center; gap: 8px;
  font-family: var(--font-mono); font-size: 10.5px; font-weight: 700;
  letter-spacing: 0.06em; text-transform: uppercase;
  color: var(--text-2); background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--line-strong); border-radius: var(--radius-sm);
  padding: 10px 14px; flex-shrink: 0; margin-left: auto;
  transition: color 0.2s ease, border-color 0.2s ease;
}
.logout-btn:hover { color: var(--attack); border-color: var(--attack-border); }

/* ---------- Statistik ringkas (Postingan / Komentar) ---------- */
.profile-stats {
  display: grid; grid-template-columns: repeat(2, 1fr); gap: 1px;
  background: var(--line); border: 1px solid var(--line);
  border-radius: var(--radius-md); overflow: hidden; margin-bottom: 24px;
}
.profile-stat { background: var(--ink-950); padding: 16px 10px; text-align: center; }
.profile-stat-num { font-family: var(--font-display); font-weight: 700; font-size: 22px; color: var(--text-1); }
.profile-stat-label { font-family: var(--font-mono); font-size: 9.5px; letter-spacing: 0.08em; text-transform: uppercase; color: var(--text-3); margin-top: 4px; }

/* ---------- Form edit profil ---------- */
.profile-form {
  border-top: 1px solid var(--line);
  padding-top: 22px;
  display: flex; flex-direction: column; gap: 16px;
}
.form-field label {
  display: block; font-family: var(--font-mono); font-size: 10.5px;
  letter-spacing: 0.06em; text-transform: uppercase; color: var(--text-3);
  margin-bottom: 8px;
}
.form-hint { font-size: 11.5px; color: var(--text-3); margin-top: 6px; }
.w-full { width: 100%; }
textarea.input-control { resize: vertical; min-height: 88px; font-family: var(--font-body); }

/* ---------- Tab panels: reuse .tabs-nav/.tab-btn dari style.css,
   tapi tambah margin supaya tidak nempel ke kartu profil ---------- */
.dash-tabs { margin-top: 8px; }

/* ---------- List postingan / komentar milik user ---------- */
.dash-list { display: flex; flex-direction: column; gap: 12px; }

.dash-row {
  display: flex; align-items: flex-start; gap: 14px;
  background: var(--ink-900); border: 1px solid var(--line);
  border-radius: var(--radius-md); padding: 16px 18px;
  transition: border-color 0.2s ease;
}
.dash-row:hover { border-color: var(--attack-border); }
.dash-row-body { flex: 1; min-width: 0; }
.dash-row-title {
  font-size: 13.5px; font-weight: 700; color: var(--text-1);
  text-decoration: none; display: block;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap;
}
.dash-row-title:hover { color: var(--attack); }
.dash-row-excerpt { font-size: 12.5px; color: var(--text-2); line-height: 1.6; margin-top: 5px; }
.dash-row-meta { font-family: var(--font-mono); font-size: 10.5px; color: var(--text-3); margin-top: 8px; }
.dash-row-ref { color: var(--attack); font-size: 11.5px; text-decoration: none; }
.dash-row-ref:hover { text-decoration: underline; }

.dash-row-actions { display: flex; align-items: center; gap: 14px; flex-shrink: 0; padding-top: 2px; }
.dash-row-actions a, .dash-row-actions button {
  color: var(--text-3); font-size: 13px; transition: color 0.2s ease;
}
.dash-row-actions a:hover, .dash-row-actions button:hover { color: var(--attack); }

/* ---------- Loading / empty state di dalam tab ---------- */
.dash-state { text-align: center; padding: 48px 20px; font-size: 13px; color: var(--text-2); }
.dash-state a { color: var(--attack); text-decoration: none; }
.dash-state a:hover { text-decoration: underline; }
.dash-state.is-loading { font-family: var(--font-mono); font-size: 11.5px; color: var(--text-3); }
.dash-state i { margin-right: 6px; }

@media (min-width: 640px) {
  .profile-top { flex-wrap: nowrap; }
}