:root { --sidebar-w: 240px; --bg: #f5f6fa; }
body { background: var(--bg); }
.app { display: flex; min-height: 100vh; }
.sidebar { width: var(--sidebar-w); background: #1e293b; color: #cbd5e1; position: fixed; inset: 0 auto 0 0; z-index: 1040; transition: transform .2s; }
.sidebar .brand { display: flex; align-items: center; gap: .6rem; padding: 1.1rem 1.25rem; color: #fff; font-weight: 600; text-decoration: none; font-size: 1.05rem; border-bottom: 1px solid rgba(255,255,255,.08); }
.sidebar .nav-item { display: flex; align-items: center; gap: .75rem; padding: .6rem 1.25rem; color: #cbd5e1; text-decoration: none; font-size: .95rem; }
.sidebar .nav-item:hover { background: rgba(255,255,255,.06); color: #fff; }
.sidebar .nav-item.active { background: #0d6efd; color: #fff; }
.sidebar .nav-item i { width: 1.2rem; text-align: center; }
.content { flex: 1; margin-left: var(--sidebar-w); min-width: 0; }
body:not(:has(.sidebar)) .content { margin-left: 0; }
.topbar { background: #fff; border-bottom: 1px solid #e5e7eb; padding: .75rem 1.5rem; position: sticky; top: 0; z-index: 1020; }
.page { padding: 1.5rem; }
.stat-card { border: 0; box-shadow: 0 1px 2px rgba(0,0,0,.04); color: inherit; transition: transform .1s; }
.stat-card:hover { transform: translateY(-2px); box-shadow: 0 4px 12px rgba(0,0,0,.06); }
.card { border-color: #e5e7eb; }
.card-header { background: #fff; font-weight: 600; }
.field-label { font-size: .75rem; text-transform: uppercase; letter-spacing: .04em; color: #6b7280; }
.field-value { word-break: break-word; }
.companies-table td { vertical-align: middle; }
.login-body { background: linear-gradient(135deg, #1e293b, #0d6efd); min-height: 100vh; display: flex; align-items: center; justify-content: center; padding: 1rem; }
.login-card { width: 100%; max-width: 400px; border: 0; }
.docs h2 { margin-top: 2.5rem; padding-top: .5rem; border-top: 1px solid #e5e7eb; }
.docs h3 { margin-top: 1.75rem; font-size: 1.15rem; }
.docs pre { background: #0f172a; color: #e2e8f0; padding: 1rem; border-radius: .5rem; font-size: .85rem; overflow: auto; }
.docs code:not(pre code) { background: #eef2ff; color: #3730a3; padding: .1em .35em; border-radius: .25rem; }
.docs table { font-size: .9rem; }
.docs .toc a { display: block; padding: .15rem 0; text-decoration: none; }
.custom-row .form-control[readonly] { background: #f8fafc; }
@media (max-width: 991.98px) {
  .sidebar { transform: translateX(-100%); }
  .sidebar.open { transform: none; box-shadow: 0 0 0 100vw rgba(0,0,0,.3); }
  .content { margin-left: 0; }
  .page { padding: 1rem; }
}
