:root {
  --primary: #1a6fc4;
  --primary-dark: #145da0;
  --accent: #f0a500;
  --bg: #f4f6f9;
  --sidebar-w: 240px;
}

body { font-family: 'Segoe UI', system-ui, sans-serif; background: var(--bg); }

/* ── Auth page ── */
.auth-card {
  max-width: 420px;
  margin: 80px auto;
  border-radius: 16px;
  box-shadow: 0 8px 32px rgba(0,0,0,.12);
}
.auth-logo { font-size: 2rem; font-weight: 800; color: var(--primary); }
.auth-logo span { color: var(--accent); }

/* ── App shell ── */
.app-wrapper { display: flex; min-height: 100vh; }

.sidebar {
  width: var(--sidebar-w);
  background: #1e2533;
  color: #c9d1d9;
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; left: 0; bottom: 0;
  z-index: 100;
}
.sidebar-brand {
  padding: 20px 18px 14px;
  font-weight: 800;
  font-size: 1.1rem;
  color: #fff;
  border-bottom: 1px solid #2d3748;
}
.sidebar-brand span { color: var(--accent); }

.sidebar-nav { flex: 1; padding: 10px 0; }
.sidebar-nav a {
  display: flex; align-items: center; gap: 10px;
  padding: 10px 20px;
  color: #a0aec0;
  text-decoration: none;
  border-radius: 0;
  transition: all .15s;
  font-size: .93rem;
}
.sidebar-nav a:hover, .sidebar-nav a.active {
  background: rgba(255,255,255,.08);
  color: #fff;
}
.sidebar-nav a .icon { font-size: 1.1rem; width: 22px; }

.sidebar-user {
  padding: 14px 18px;
  border-top: 1px solid #2d3748;
  font-size: .82rem;
  color: #718096;
}
.sidebar-user strong { display: block; color: #e2e8f0; margin-bottom: 4px; }

.main-content {
  margin-left: var(--sidebar-w);
  flex: 1;
  padding: 28px 32px;
  max-width: calc(100vw - var(--sidebar-w));
}

.page-title {
  font-size: 1.4rem;
  font-weight: 700;
  margin-bottom: 20px;
  color: #1a202c;
}

/* ── Cards ── */
.stat-card {
  background: #fff;
  border-radius: 12px;
  padding: 20px;
  box-shadow: 0 1px 6px rgba(0,0,0,.07);
}
.stat-card .label { font-size: .8rem; color: #718096; text-transform: uppercase; letter-spacing: .05em; }
.stat-card .value { font-size: 1.8rem; font-weight: 700; color: #1a202c; }

/* ── Drop zone ── */
.drop-zone {
  border: 2px dashed #b0c4de;
  border-radius: 14px;
  padding: 50px 20px;
  text-align: center;
  cursor: pointer;
  transition: all .2s;
  background: #fff;
}
.drop-zone:hover, .drop-zone.drag-over {
  border-color: var(--primary);
  background: #eef5ff;
}
.drop-zone .icon { font-size: 3rem; color: #a0aec0; }
.drop-zone p { margin: 10px 0 0; color: #4a5568; }

/* ── Progress ── */
.progress-section { display: none; }
.analysis-result { display: none; }

/* ── Buttons ── */
.btn-primary-custom {
  background: var(--primary);
  color: #fff;
  border: none;
  border-radius: 8px;
  padding: 10px 24px;
  font-weight: 600;
  cursor: pointer;
  transition: background .15s;
}
.btn-primary-custom:hover { background: var(--primary-dark); }

/* ── Work type tabs ── */
.work-tabs { overflow-x: auto; white-space: nowrap; padding-bottom: 4px; }
.work-tabs .nav-link { white-space: nowrap; }

/* ── Result table ── */
.result-table th { background: #f7fafc; font-weight: 600; }
.total-row td { font-weight: 700; background: #eef5ff; }

/* ── Mobile ── */
@media (max-width: 768px) {
  .sidebar { width: 60px; }
  .sidebar-brand, .sidebar-nav a span, .sidebar-user { display: none; }
  .sidebar-nav a .icon { margin: 0 auto; }
  .main-content { margin-left: 60px; padding: 16px; }
}

/* ── Utils ── */
.badge-trial { background: #ed8936; color: #fff; }
.badge-pro   { background: #38a169; color: #fff; }
.badge-free  { background: #718096; color: #fff; }
.text-muted-sm { font-size: .82rem; color: #718096; }
.spinner-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.35);
  display: flex; align-items: center; justify-content: center;
  z-index: 9999;
}
