/* synarete-shell.css — unified admin shell across the Synarete app suite.
 * Canonical copy lives in jugal1990/fleet. Copy verbatim to any consumer app.
 * Owns: layout, sidebar, topbar, primary/accent buttons, cards, tables,
 * status pills, focus rings, typography. Domain-specific styles (checkpoint
 * tiles in Fleet, assessment chips in SHEQ, PDF print in SHEQ) stay in each
 * app's own static/css/style.css. */

@font-face {
  font-family: 'Verdana';
  src: url('/static/fonts/verdana/Verdana.ttf') format('truetype');
  font-weight: normal;
  font-style: normal;
}
@font-face {
  font-family: 'Verdana';
  src: url('/static/fonts/verdana/Verdana_Bold.ttf') format('truetype');
  font-weight: bold;
  font-style: normal;
}
@font-face {
  font-family: 'Verdana';
  src: url('/static/fonts/verdana/Verdana_Italic.ttf') format('truetype');
  font-weight: normal;
  font-style: italic;
}
@font-face {
  font-family: 'Verdana';
  src: url('/static/fonts/verdana/Verdana_Bold_Italic.ttf') format('truetype');
  font-weight: bold;
  font-style: italic;
}

:root {
  --syn-primary: #1e3a5f;   /* navy */
  --syn-accent:  #f59e0b;   /* amber */
  --syn-bg:      #f8fafc;
  --syn-ink:     #1e293b;
}

html { font-size: 87.5%; }   /* shrink Bootstrap rem-scale by ~12.5%: 16→14 baseline */

body {
  font-family: Verdana, Geneva, Tahoma, sans-serif;
}

/* ===== Layout ===== */
.admin-layout { display: flex; min-height: 100vh; background: var(--syn-bg); }

.admin-sidebar {
  width: 220px; flex-shrink: 0; background: var(--syn-primary); color: #fff;
  display: flex; flex-direction: column; padding: 20px 14px; position: sticky;
  top: 0; height: 100vh; overflow-y: auto;
}
.admin-sidebar-logo { margin-bottom: 18px; padding-bottom: 14px;
  border-bottom: 1px solid rgba(255,255,255,0.10); }
.admin-sidebar-logo .logo-name { font-weight: 700; font-size: 14px; opacity: 0.78; }
.admin-sidebar-logo .logo-sub  { font-weight: 600; font-size: 20px; }

.admin-nav-section { font-size: 10px; letter-spacing: 0.08em; text-transform: uppercase;
  color: rgba(255,255,255,0.50); margin: 14px 0 6px; padding: 0 6px; }
.admin-nav-item {
  display: flex; align-items: center; gap: 10px; padding: 8px 10px;
  color: rgba(255,255,255,0.85); border-radius: 5px; text-decoration: none;
  font-size: 13px; line-height: 1.2; margin-bottom: 2px;
}
.admin-nav-item .icon { width: 18px; text-align: center; }
.admin-nav-item:hover { background: rgba(255,255,255,0.07); color: #fff; }
.admin-nav-item.active { background: rgba(255,255,255,0.12); color: #fff; font-weight: 600; }
.admin-nav-item .nav-count {
  margin-left: auto; background: rgba(255,255,255,0.12); color: #fff;
  font-size: 11px; padding: 1px 7px; border-radius: 10px;
}
.admin-sidebar-spacer { flex: 1; }
.admin-sidebar-user {
  display: flex; gap: 8px; align-items: center; padding: 10px 6px;
  border-top: 1px solid rgba(255,255,255,0.10); margin-top: 8px;
}
.admin-sidebar-user .user-icon { font-size: 18px; }
.admin-sidebar-user .user-name  { font-size: 12px; font-weight: 600; line-height: 1.2; }
.admin-sidebar-user .user-email { font-size: 10px; opacity: 0.7; line-height: 1.2; }

/* ===== Main ===== */
.admin-main    { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.admin-topbar  {
  background: #fff; border-bottom: 1px solid #e2e8f0; padding: 14px 24px;
  display: flex; align-items: center; gap: 16px; min-height: 60px;
}
.admin-topbar h1 { font-size: 16px; font-weight: 600; margin: 0; color: var(--syn-ink); }
.admin-topbar .topbar-meta { color: #64748b; font-size: 13px; }
.admin-topbar-actions { margin-left: auto; display: flex; gap: 8px; align-items: center; }
.cycle-label {
  font-size: 13px; font-weight: 700; color: var(--syn-primary);
  margin-top: 2px;
}
.admin-content { padding: 22px 24px; flex: 1; }

/* ===== Hamburger / drawer (mobile) ===== */
.syn-hamburger {
  display: none; background: none; border: 1px solid #e2e8f0; border-radius: 6px;
  width: 38px; height: 38px; align-items: center; justify-content: center;
  font-size: 18px; color: var(--syn-ink); cursor: pointer;
}
.syn-drawer-overlay {
  display: none; position: fixed; inset: 0; background: rgba(0,0,0,0.4);
  z-index: 1040;
}
@media (max-width: 768px) {
  .admin-sidebar {
    position: fixed; top: 0; left: 0; height: 100vh; z-index: 1050;
    transform: translateX(-100%); transition: transform 0.2s ease;
  }
  body.syn-drawer-open .admin-sidebar { transform: translateX(0); }
  body.syn-drawer-open .syn-drawer-overlay { display: block; }
  .syn-hamburger { display: inline-flex; }
  .admin-content { padding: 16px; }
  .admin-topbar  { padding: 12px 16px; }
}

/* ===== Stat grid ===== */
.admin-stat-grid {
  display: grid; gap: 14px; margin-bottom: 22px;
  grid-template-columns: repeat(5, minmax(0, 1fr));
}
@media (max-width: 1100px) { .admin-stat-grid { grid-template-columns: repeat(3, 1fr); } }
@media (max-width: 640px)  { .admin-stat-grid { grid-template-columns: repeat(2, 1fr); } }
.admin-stat-card {
  background: #fff; border: 1px solid #e2e8f0; border-radius: 8px;
  padding: 14px; display: flex; flex-direction: column; gap: 4px;
}
.admin-stat-card .stat-label { font-size: 11px; color: #64748b; text-transform: uppercase; letter-spacing: 0.06em; }
.admin-stat-card .stat-value { font-size: 26px; font-weight: 700; color: var(--syn-ink); line-height: 1.1; }
.admin-stat-card .stat-sub   { font-size: 11px; color: #94a3b8; }
.stat-submitted .stat-value { color: #854d0e; }
.stat-reviewed  .stat-value { color: #16a34a; }
.stat-pending   .stat-value { color: #f59e0b; }
.stat-overdue   .stat-value { color: #dc2626; }
.stat-total     .stat-value { color: var(--syn-primary); }

.admin-section-title { font-size: 12px; font-weight: 700; color: #64748b;
  text-transform: uppercase; letter-spacing: 0.08em; margin: 18px 0 10px; }

/* ===== Status pills ===== */
.status-pill {
  display: inline-block; padding: 2px 9px; border-radius: 11px;
  font-size: 11px; font-weight: 600;
}
.pill-green { background: #dcfce7; color: #16a34a; }
.pill-amber { background: #fef9c3; color: #854d0e; }
.pill-red   { background: #fee2e2; color: #b91c1c; }
.pill-gray  { background: #f1f5f9; color: #64748b; }

/* ===== Buttons (brand) ===== */
.btn-primary, .bg-primary { background: var(--syn-primary) !important; border-color: var(--syn-primary) !important; }
.btn-primary:hover { background: #15294a !important; border-color: #15294a !important; }
.text-primary { color: var(--syn-primary) !important; }
.btn-accent {
  background: var(--syn-accent); color: var(--syn-primary); border: 1px solid var(--syn-accent);
  font-weight: 600;
}
.btn-accent:hover { background: #d97706; border-color: #d97706; color: #fff; }
.btn-touch { /* desktop: natural button height — touch target only on small screens */ }
@media (max-width: 768px) { .btn-touch { min-height: 44px; } }
.filter-pill {
  font-size: 12px; padding: 4px 12px;
}

/* ===== Tables ===== */
.table tbody tr:hover { background: #f1f5f9; }

/* ===== Focus rings ===== */
a:focus-visible, button:focus-visible { outline: 2px solid var(--syn-accent); outline-offset: 2px; }
