/* ==========================================================
   POWERCHINA DELIVERY RESOURCE DATABASE - PROTOTYPE
   Built by Lesibo Technologies
   Primary: #0B4CA3 (PowerChina Blue) | Secondary: #CA124A (PowerChina Red)
   ========================================================== */

:root {
  --primary: #0b4ca3;
  --primary-dark: #083a7e;
  --primary-soft: #e6efff;
  --primary-hover: #094090;
  --secondary: #ca124a;
  --secondary-dark: #9c0e3a;
  --secondary-soft: #fde7ed;
  --secondary-hover: #b50f43;
  --ink: #1a1a1a;
  --ink-2: #2d3142;
  --muted: #5b6275;
  --muted-2: #8a91a3;
  --line: #e3e6ee;
  --line-soft: #f1f3f9;
  --bg: #ffffff;
  --bg-app: #f5f6fa;
  --bg-alt: #f7f8fc;
  --bg-card: #ffffff;
  --risk-low: #1d7a3d;
  --risk-low-bg: #e3f5e9;
  --risk-med: #c98306;
  --risk-med-bg: #fef4e0;
  --risk-high: #d97706;
  --risk-high-bg: #fde7d0;
  --risk-crit: #b91c1c;
  --risk-crit-bg: #fde0e0;
  --shadow-sm: 0 1px 3px rgba(11, 76, 163, 0.06);
  --shadow-md: 0 4px 12px rgba(11, 76, 163, 0.08);
  --shadow-lg: 0 12px 30px rgba(11, 76, 163, 0.14);
  --shadow-xl: 0 25px 50px rgba(11, 76, 163, 0.22);
  --radius-sm: 4px;
  --radius-md: 8px;
  --radius-lg: 12px;
  --radius-pill: 999px;
  --sidebar-w: 248px;
  --topbar-h: 60px;
  --transition: all 0.2s ease;
}
* { box-sizing: border-box; }
html, body {
  margin: 0; padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", "Helvetica Neue", Arial, sans-serif;
  color: var(--ink); background: var(--bg-app); line-height: 1.55; font-size: 14px;
  -webkit-font-smoothing: antialiased;
}
a { color: var(--primary); text-decoration: none; }
a:hover { text-decoration: underline; }
button { font-family: inherit; cursor: pointer; }
input, select, textarea { font-family: inherit; }

.screen { display: none; }
.screen.active { display: block; }
#app-shell, #login-screen { overflow: hidden; height: 100vh; }
#landing-screen.active { overflow-y: auto; height: 100vh; }

/* ============== LANDING PAGE ============== */
#landing-screen { background: white; }
.landing-nav {
  position: sticky; top: 0;
  background: rgba(255, 255, 255, 0.95);
  backdrop-filter: blur(12px);
  border-bottom: 1px solid var(--line);
  padding: 14px 40px;
  display: flex; align-items: center; justify-content: space-between;
  z-index: 100;
}
.landing-nav .nav-brand { display: flex; align-items: center; gap: 12px; }
.landing-nav .nav-brand img { height: 32px; }
.landing-nav .nav-brand .nav-title { font-weight: 700; color: var(--primary); font-size: 15px; line-height: 1.2; }
.landing-nav .nav-brand .nav-subtitle { font-size: 11px; color: var(--muted); display: block; letter-spacing: 0.5px; }
.landing-nav .nav-links { display: flex; align-items: center; gap: 28px; }
.landing-nav .nav-link { font-size: 13px; color: var(--ink-2); font-weight: 500; }
.landing-nav .nav-link:hover { color: var(--primary); text-decoration: none; }
.landing-hero {
  padding: 60px 40px 80px; text-align: center;
  background: linear-gradient(180deg, white 0%, var(--primary-soft) 100%);
  position: relative; overflow: hidden;
}
.landing-hero::before {
  content: ""; position: absolute; top: -100px; right: -100px;
  width: 400px; height: 400px;
  background: radial-gradient(circle, rgba(202, 18, 74, 0.08) 0%, transparent 70%);
  pointer-events: none;
}
.landing-hero::after {
  content: ""; position: absolute; bottom: -150px; left: -150px;
  width: 500px; height: 500px;
  background: radial-gradient(circle, rgba(11, 76, 163, 0.10) 0%, transparent 70%);
  pointer-events: none;
}
.hero-content { max-width: 820px; margin: 0 auto; position: relative; }
.hero-eyebrow {
  display: inline-block; background: white; color: var(--secondary);
  padding: 6px 14px; border-radius: var(--radius-pill);
  font-size: 11px; font-weight: 700; letter-spacing: 1.5px; text-transform: uppercase;
  margin-bottom: 18px; border: 1px solid var(--secondary-soft);
}
.hero-title {
  font-size: 52px; font-weight: 800; color: var(--primary);
  line-height: 1.1; margin: 0 0 18px; letter-spacing: -1px;
}
.hero-title .accent { color: var(--secondary); }
.hero-subtitle {
  font-size: 19px; color: var(--ink-2); line-height: 1.5;
  margin: 0 auto 36px; max-width: 680px;
}
.hero-cta-group {
  display: flex; gap: 12px; justify-content: center;
  flex-wrap: wrap; margin-bottom: 50px;
}
.hero-trust {
  display: flex; align-items: center; justify-content: center;
  gap: 30px; margin-top: 20px; flex-wrap: wrap;
}
.hero-trust-item {
  display: flex; align-items: center; gap: 8px;
  color: var(--muted); font-size: 13px;
}
.hero-trust-item .check { color: var(--risk-low); font-weight: 800; }

.landing-stats {
  padding: 50px 40px; background: var(--primary); color: white;
}
.stats-row {
  max-width: 1100px; margin: 0 auto;
  display: grid; grid-template-columns: repeat(4, 1fr);
  gap: 30px; text-align: center;
}
.stat-block .stat-num {
  font-size: 44px; font-weight: 800; color: white;
  line-height: 1; margin-bottom: 8px;
}
.stat-block .stat-num .accent { color: #ff7b9c; }
.stat-block .stat-label {
  font-size: 13px; color: rgba(255, 255, 255, 0.85); letter-spacing: 0.6px;
}

.landing-section { padding: 80px 40px; }
.section-head { text-align: center; margin-bottom: 50px; }
.section-eyebrow {
  display: inline-block; color: var(--secondary);
  font-size: 11px; font-weight: 700; letter-spacing: 1.5px;
  text-transform: uppercase; margin-bottom: 8px;
}
.section-title {
  font-size: 36px; font-weight: 800; color: var(--primary);
  margin: 0 0 12px; letter-spacing: -0.5px;
}
.section-lead {
  font-size: 16px; color: var(--muted);
  max-width: 700px; margin: 0 auto;
}
.feature-grid {
  max-width: 1100px; margin: 0 auto;
  display: grid; grid-template-columns: repeat(3, 1fr); gap: 20px;
}
.feature-card {
  background: white; border: 1px solid var(--line);
  border-radius: var(--radius-lg); padding: 28px 24px;
  transition: var(--transition); text-align: left;
  position: relative; overflow: hidden;
}
.feature-card:hover {
  transform: translateY(-4px); box-shadow: var(--shadow-lg); border-color: var(--primary);
}
.feature-card::before {
  content: ""; position: absolute; top: 0; left: 0;
  width: 100%; height: 4px;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
  opacity: 0; transition: var(--transition);
}
.feature-card:hover::before { opacity: 1; }
.feature-icon {
  width: 48px; height: 48px; border-radius: var(--radius-md);
  background: var(--primary-soft); color: var(--primary);
  display: flex; align-items: center; justify-content: center;
  font-size: 22px; margin-bottom: 16px;
}
.feature-icon.secondary { background: var(--secondary-soft); color: var(--secondary); }
.feature-title { font-size: 17px; font-weight: 700; color: var(--primary); margin: 0 0 8px; }
.feature-desc { font-size: 13px; color: var(--muted); line-height: 1.55; }

.landing-section.alt { background: var(--bg-alt); }
.use-cases {
  max-width: 1100px; margin: 0 auto;
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 40px; align-items: center;
}
.use-case-text h3 {
  font-size: 28px; color: var(--primary);
  margin: 0 0 14px; font-weight: 700;
}
.use-case-text p {
  color: var(--muted); font-size: 15px; line-height: 1.65;
  margin-bottom: 12px;
}
.use-case-text ul { margin: 16px 0; padding: 0; list-style: none; }
.use-case-text ul li {
  padding: 6px 0 6px 28px; position: relative;
  color: var(--ink-2); font-size: 14px;
}
.use-case-text ul li::before {
  content: ""; position: absolute; left: 4px; top: 9px;
  width: 8px; height: 8px; background: var(--primary);
  border-radius: 50%;
}
.use-case-visual {
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  border-radius: var(--radius-lg); padding: 40px;
  color: white; position: relative; overflow: hidden;
  box-shadow: var(--shadow-xl);
}
.use-case-visual::before {
  content: ""; position: absolute; top: -50px; right: -50px;
  width: 200px; height: 200px;
  background: radial-gradient(circle, rgba(202, 18, 74, 0.3) 0%, transparent 70%);
}
.visual-stat-block {
  position: relative; padding: 18px 0;
  border-bottom: 1px solid rgba(255, 255, 255, 0.15);
}
.visual-stat-block:last-child { border-bottom: none; }
.visual-stat-num {
  font-size: 32px; font-weight: 800; color: white;
  line-height: 1; margin-bottom: 4px;
}
.visual-stat-label {
  font-size: 12px; color: rgba(255, 255, 255, 0.8); letter-spacing: 0.5px;
}

.cta-strip {
  padding: 70px 40px;
  background: linear-gradient(135deg, var(--secondary), var(--secondary-dark));
  color: white; text-align: center;
}
.cta-strip h2 {
  font-size: 34px; font-weight: 800; margin: 0 0 14px;
  color: white; letter-spacing: -0.5px;
}
.cta-strip p {
  font-size: 16px; color: rgba(255, 255, 255, 0.9);
  margin: 0 auto 28px; max-width: 600px;
}
.cta-strip .btn-cta-primary {
  background: white; color: var(--secondary);
  font-size: 14px; padding: 13px 26px; font-weight: 700;
  border: 2px solid white;
}
.cta-strip .btn-cta-primary:hover { background: var(--secondary-soft); color: var(--secondary); }
.cta-strip .btn-outline-white {
  background: transparent; color: white; border: 2px solid white;
  font-size: 14px; padding: 13px 26px; font-weight: 700;
}
.cta-strip .btn-outline-white:hover { background: white; color: var(--secondary); }

.landing-footer {
  background: var(--ink-2); color: white;
  padding: 50px 40px 30px;
}
.footer-grid {
  max-width: 1100px; margin: 0 auto;
  display: grid; grid-template-columns: 2fr 1fr 1fr;
  gap: 40px; margin-bottom: 30px;
}
.footer-brand img { height: 36px; margin-bottom: 14px; filter: brightness(0) invert(1); }
.footer-brand p { color: rgba(255, 255, 255, 0.7); font-size: 13px; line-height: 1.6; margin: 0; }
.footer-col h4 {
  color: white; font-size: 13px; text-transform: uppercase;
  letter-spacing: 1px; margin: 0 0 14px;
}
.footer-col a {
  display: block; color: rgba(255, 255, 255, 0.7);
  font-size: 13px; padding: 4px 0;
}
.footer-col a:hover { color: white; text-decoration: none; }
.footer-bottom {
  max-width: 1100px; margin: 0 auto; padding-top: 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.15);
  display: flex; justify-content: space-between; align-items: center;
  flex-wrap: wrap; gap: 14px;
  color: rgba(255, 255, 255, 0.5); font-size: 12px;
}
.footer-bottom .built-by { display: flex; align-items: center; gap: 8px; }
.footer-bottom .built-by img { height: 18px; filter: brightness(0) invert(1); opacity: 0.7; }

/* ============== LOGIN SCREEN ============== */
#login-screen {
  background: linear-gradient(135deg, var(--primary) 0%, var(--primary-dark) 100%);
  position: relative;
}
.login-watermark {
  position: absolute; inset: 0;
  background-image:
    radial-gradient(circle at 20% 30%, rgba(202, 18, 74, 0.15) 0%, transparent 50%),
    radial-gradient(circle at 80% 70%, rgba(202, 18, 74, 0.08) 0%, transparent 50%);
  pointer-events: none;
}
.login-watermark::after {
  content: "POWERCHINA"; position: absolute;
  top: 50%; left: 50%;
  transform: translate(-50%, -50%) rotate(-15deg);
  font-size: 220px; font-weight: 900;
  color: rgba(255, 255, 255, 0.025);
  letter-spacing: 18px; white-space: nowrap; pointer-events: none;
}
.login-back-link {
  position: absolute; top: 24px; left: 24px;
  color: white; font-size: 13px; font-weight: 500;
  z-index: 10; background: rgba(255, 255, 255, 0.15);
  padding: 8px 14px; border-radius: var(--radius-pill);
  display: inline-flex; align-items: center; gap: 6px;
}
.login-back-link:hover { background: rgba(255, 255, 255, 0.25); text-decoration: none; }
.login-container {
  min-height: 100vh; display: flex; align-items: center; justify-content: center;
  padding: 40px 20px; position: relative; z-index: 1;
}
.login-card {
  background: white; border-radius: var(--radius-lg);
  padding: 40px 38px 28px; width: 100%; max-width: 440px;
  box-shadow: var(--shadow-xl); position: relative; overflow: hidden;
}
.login-card::before {
  content: ""; position: absolute; top: 0; left: 0; right: 0; height: 5px;
  background: linear-gradient(90deg, var(--primary), var(--secondary));
}
.login-brand { text-align: center; margin-bottom: 28px; }
.login-logo-wrap img { height: 50px; margin-bottom: 14px; }
.login-tagline { font-size: 20px; font-weight: 700; color: var(--primary); margin-bottom: 4px; }
.login-subtag { font-size: 12px; color: var(--muted); }
.login-form .form-group { margin-bottom: 16px; }
.login-form label {
  display: block; font-size: 12px; font-weight: 600;
  color: var(--primary); margin-bottom: 6px;
  text-transform: uppercase; letter-spacing: 0.5px;
}
.login-form input[type="email"],
.login-form input[type="password"] {
  width: 100%; padding: 11px 14px;
  border: 1.5px solid var(--line); border-radius: var(--radius-md);
  font-size: 14px; background: var(--bg-alt); transition: var(--transition);
}
.login-form input:focus {
  outline: none; border-color: var(--primary); background: white;
  box-shadow: 0 0 0 3px rgba(11, 76, 163, 0.1);
}
.login-meta {
  display: flex; justify-content: space-between; align-items: center;
  margin-bottom: 20px; font-size: 12px;
}
.checkbox {
  display: inline-flex; align-items: center; gap: 6px;
  cursor: pointer; color: var(--muted);
}

/* ============== BUTTONS ============== */
.btn {
  display: inline-flex; align-items: center; justify-content: center;
  gap: 6px; padding: 10px 18px;
  border-radius: var(--radius-md); font-size: 13px; font-weight: 600;
  border: 1.5px solid transparent; cursor: pointer;
  transition: var(--transition); white-space: nowrap; text-decoration: none;
}
.btn-primary {
  background: var(--primary); color: white; border-color: var(--primary);
}
.btn-primary:hover {
  background: var(--primary-hover); border-color: var(--primary-hover); text-decoration: none;
}
.btn-secondary {
  background: var(--secondary); color: white; border-color: var(--secondary);
}
.btn-secondary:hover {
  background: var(--secondary-hover); border-color: var(--secondary-hover); text-decoration: none;
}
.btn-outline {
  background: white; color: var(--primary); border-color: var(--line);
}
.btn-outline:hover { border-color: var(--primary); background: var(--primary-soft); text-decoration: none; }
.btn-outline-primary {
  background: white; color: var(--primary); border-color: var(--primary);
}
.btn-outline-primary:hover { background: var(--primary); color: white; text-decoration: none; }
.btn-outline-secondary {
  background: white; color: var(--secondary); border-color: var(--secondary);
}
.btn-outline-secondary:hover { background: var(--secondary); color: white; text-decoration: none; }
.btn-ghost {
  background: transparent; color: var(--muted); border: none;
}
.btn-ghost:hover { color: var(--primary); background: var(--bg-alt); }
.btn-danger {
  background: var(--risk-crit); color: white; border-color: var(--risk-crit);
}
.btn-sm { padding: 6px 12px; font-size: 12px; }
.btn-lg { padding: 14px 24px; font-size: 14px; font-weight: 700; }
.btn-xl { padding: 16px 32px; font-size: 15px; font-weight: 700; }
.btn-block { width: 100%; }

.login-lang-toggle {
  display: flex; justify-content: center; gap: 4px;
  margin: 18px auto 4px; padding: 4px;
  background: var(--bg-alt); border-radius: var(--radius-pill);
  width: fit-content;
}
.lang-btn {
  background: transparent; border: none;
  padding: 5px 14px; border-radius: var(--radius-pill);
  font-size: 11px; font-weight: 600; color: var(--muted); transition: var(--transition);
}
.lang-btn.active { background: var(--primary); color: white; }

.login-demo-roles {
  margin-top: 20px; padding-top: 18px;
  border-top: 1px dashed var(--line);
}
.demo-label {
  font-size: 10px; text-transform: uppercase; letter-spacing: 1px;
  color: var(--muted-2); text-align: center; margin-bottom: 8px;
}
.demo-role-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 6px;
}
.role-btn {
  background: var(--bg-alt); border: 1px solid var(--line);
  padding: 7px 10px; border-radius: var(--radius-sm);
  font-size: 11px; color: var(--primary); transition: var(--transition);
}
.role-btn:hover {
  background: var(--primary); color: white; border-color: var(--primary);
}
.login-footer {
  margin-top: 22px; text-align: center;
  font-size: 11px; color: var(--muted-2);
  padding-top: 12px; border-top: 1px solid var(--line-soft);
}
.login-footer strong { color: var(--primary); }
.login-footer em { color: var(--secondary); font-style: italic; }

/* ============== APP SHELL ============== */
#app-shell.active {
  display: block; height: 100vh; position: relative; overflow: hidden;
}
.bg-watermark {
  position: fixed; inset: 0;
  background-image: url("assets/logo-powerchina.png");
  background-repeat: no-repeat; background-position: 96% 96%;
  background-size: 120px; opacity: 0.04;
  pointer-events: none; z-index: 0;
}

.topbar {
  position: fixed; top: 0; left: 0; right: 0;
  height: var(--topbar-h); background: white;
  border-bottom: 1px solid var(--line);
  display: flex; align-items: center;
  padding: 0 18px; gap: 14px;
  z-index: 100; box-shadow: var(--shadow-sm);
}
.topbar-left {
  display: flex; align-items: center; gap: 12px;
  width: var(--sidebar-w); flex-shrink: 0;
}
.sidebar-toggle {
  background: transparent; border: none; color: var(--primary);
  padding: 6px; border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center;
}
.sidebar-toggle:hover { background: var(--bg-alt); }
.brand-mini img { height: 28px; display: block; }
.page-title { display: none; font-weight: 700; color: var(--primary); font-size: 15px; }

.topbar-search { flex: 1; max-width: 540px; position: relative; }
.topbar-search input {
  width: 100%; padding: 9px 38px;
  border: 1.5px solid var(--line); border-radius: var(--radius-md);
  font-size: 13px; background: var(--bg-alt); transition: var(--transition);
}
.topbar-search input:focus {
  outline: none; border-color: var(--primary); background: white;
  box-shadow: 0 0 0 3px rgba(11, 76, 163, 0.1);
}
.search-icon {
  position: absolute; left: 12px; top: 50%;
  transform: translateY(-50%); color: var(--muted);
}
.topbar-search kbd {
  position: absolute; right: 10px; top: 50%;
  transform: translateY(-50%); font-size: 10px;
  background: white; border: 1px solid var(--line);
  border-radius: var(--radius-sm); padding: 2px 6px;
  color: var(--muted); font-family: ui-monospace, monospace;
}
.topbar-right { display: flex; align-items: center; gap: 10px; margin-left: auto; }
.lang-switch {
  display: flex; padding: 3px;
  background: var(--bg-alt); border-radius: var(--radius-pill);
}
.lang-pill {
  background: transparent; border: none;
  padding: 4px 11px; border-radius: var(--radius-pill);
  font-size: 11px; font-weight: 600; color: var(--muted);
}
.lang-pill.active { background: var(--primary); color: white; }
.icon-btn {
  background: transparent; border: none; color: var(--primary);
  padding: 8px; border-radius: var(--radius-sm);
  display: flex; align-items: center; justify-content: center; position: relative;
}
.icon-btn:hover { background: var(--bg-alt); }
.notif-dot {
  position: absolute; top: 3px; right: 3px;
  background: var(--secondary); color: white; font-size: 9px;
  font-weight: 700; width: 16px; height: 16px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center; border: 2px solid white;
}
.user-chip {
  display: flex; align-items: center; gap: 8px;
  padding: 4px 10px 4px 4px;
  border-radius: var(--radius-pill); background: var(--bg-alt);
  transition: var(--transition); cursor: pointer;
}
.user-chip:hover { background: var(--primary-soft); }
.user-avatar {
  width: 32px; height: 32px; border-radius: 50%;
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: white; display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 12px;
}
.user-info { line-height: 1.2; }
.user-name { font-size: 12px; font-weight: 600; color: var(--primary); }
.user-role { font-size: 10px; color: var(--muted); }

/* ============== SIDEBAR ============== */
.sidebar {
  position: fixed; top: var(--topbar-h); left: 0; bottom: 0;
  width: var(--sidebar-w); background: white;
  border-right: 1px solid var(--line); overflow-y: auto;
  z-index: 50; display: flex; flex-direction: column; transition: var(--transition);
}
.sidebar.collapsed { transform: translateX(-100%); }
.nav-menu { flex: 1; padding: 14px 10px; }
.nav-section { margin-bottom: 18px; }
.nav-section-title {
  font-size: 10px; font-weight: 700; color: var(--muted-2);
  text-transform: uppercase; letter-spacing: 1.2px;
  padding: 8px 14px 6px;
}
.nav-item {
  display: flex; align-items: center; gap: 10px;
  padding: 8px 14px; margin: 1px 0;
  border-radius: var(--radius-md); color: var(--ink-2);
  font-size: 13px; font-weight: 500; text-decoration: none;
  transition: var(--transition);
}
.nav-item:hover { background: var(--primary-soft); color: var(--primary); text-decoration: none; }
.nav-item.active { background: var(--primary); color: white; }
.nav-item.active .nav-count { background: rgba(255,255,255,0.25); color: white; }
.nav-item svg { flex-shrink: 0; }
.nav-item span:first-of-type { flex: 1; }
.nav-count {
  background: var(--bg-alt); color: var(--muted);
  font-size: 10px; font-weight: 700;
  padding: 2px 8px; border-radius: var(--radius-pill);
  min-width: 22px; text-align: center;
}
.nav-count.critical { background: var(--risk-crit-bg); color: var(--risk-crit); }
.sidebar-footer {
  padding: 12px 14px; border-top: 1px solid var(--line); background: var(--bg-alt);
}
.sidebar-watermark { display: flex; align-items: center; gap: 8px; }
.sidebar-watermark img { height: 18px; opacity: 0.7; }
.sb-footer-text { font-size: 10px; color: var(--muted); line-height: 1.2; }
.sb-footer-tag { color: var(--secondary); font-style: italic; font-weight: 600; }
.admin-only.hidden { display: none; }

/* ============== MAIN CONTENT ============== */
.main-content {
  margin-left: var(--sidebar-w); margin-top: var(--topbar-h);
  height: calc(100vh - var(--topbar-h));
  overflow-y: auto; padding: 22px 28px 60px;
  position: relative; z-index: 1;
}
.sidebar.collapsed + .main-content { margin-left: 0; }

.view-header {
  display: flex; justify-content: space-between; align-items: flex-start;
  margin-bottom: 20px; gap: 16px; flex-wrap: wrap;
}
.view-header-text h1 {
  font-size: 22px; color: var(--primary);
  margin: 0 0 4px; font-weight: 800;
}
.view-header-text .subtitle { color: var(--muted); font-size: 13px; margin: 0; }
.view-header-actions { display: flex; gap: 8px; flex-wrap: wrap; }

/* ============== STAT CARDS ============== */
.stats-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 14px; margin-bottom: 22px;
}
.stat-card {
  background: white; border-radius: var(--radius-lg);
  padding: 18px; border: 1px solid var(--line);
  position: relative; overflow: hidden; transition: var(--transition);
}
.stat-card:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.stat-card::before {
  content: ""; position: absolute; top: 0; left: 0;
  width: 4px; height: 100%; background: var(--primary);
}
.stat-card.navy::before { background: var(--primary-dark); }
.stat-card.success::before { background: var(--risk-low); }
.stat-card.warn::before { background: var(--risk-high); }
.stat-card.crit::before { background: var(--risk-crit); }
.stat-card.secondary::before { background: var(--secondary); }
.stat-card-head {
  display: flex; justify-content: space-between; align-items: flex-start;
  margin-bottom: 8px;
}
.stat-card-label {
  font-size: 11px; font-weight: 600; color: var(--muted);
  text-transform: uppercase; letter-spacing: 0.6px;
}
.stat-card-icon { color: var(--primary); opacity: 0.6; }
.stat-card-value {
  font-size: 28px; font-weight: 800; color: var(--primary);
  margin: 4px 0; line-height: 1.1;
}
.stat-card-trend { font-size: 11px; color: var(--muted); }
.stat-card-trend .up { color: var(--risk-low); font-weight: 600; }
.stat-card-trend .down { color: var(--risk-crit); font-weight: 600; }

/* ============== PANELS ============== */
.panel {
  background: white; border-radius: var(--radius-lg);
  border: 1px solid var(--line); margin-bottom: 20px; overflow: hidden;
}
.panel-header {
  padding: 14px 18px; border-bottom: 1px solid var(--line);
  display: flex; justify-content: space-between; align-items: center;
  background: var(--bg-alt);
}
.panel-title { font-size: 14px; font-weight: 700; color: var(--primary); margin: 0; }
.panel-actions { display: flex; gap: 6px; }
.panel-body { padding: 18px; }
.panel-body.tight { padding: 0; }
.grid-2 { display: grid; grid-template-columns: 2fr 1fr; gap: 16px; }
.grid-2.even { grid-template-columns: 1fr 1fr; }
.grid-3 { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; }

/* ============== TABLES ============== */
.data-table {
  width: 100%; border-collapse: collapse;
  font-size: 13px; background: white;
}
.data-table th {
  background: var(--bg-alt); text-align: left;
  padding: 11px 14px; font-size: 11px; font-weight: 700;
  color: var(--muted); text-transform: uppercase; letter-spacing: 0.5px;
  border-bottom: 1px solid var(--line); white-space: nowrap;
  position: sticky; top: 0;
}
.data-table th.sortable { cursor: pointer; }
.data-table th.sortable:hover { color: var(--primary); }
.data-table td {
  padding: 12px 14px; border-bottom: 1px solid var(--line-soft); vertical-align: middle;
}
.data-table tbody tr { transition: var(--transition); cursor: pointer; }
.data-table tbody tr:hover { background: var(--primary-soft); }
.data-table tbody tr.blacklisted { background: rgba(185, 28, 28, 0.04); }
.data-table tbody tr.blacklisted:hover { background: rgba(185, 28, 28, 0.08); }
.data-table .resource-name { display: flex; flex-direction: column; gap: 2px; }
.data-table .resource-name .name { font-weight: 600; color: var(--primary); }
.data-table .resource-name .meta { font-size: 11px; color: var(--muted); }
.data-table .num { text-align: right; font-variant-numeric: tabular-nums; }
.data-table .center { text-align: center; }
.empty-row td {
  text-align: center; padding: 40px;
  color: var(--muted); font-style: italic;
}

/* ============== BADGES ============== */
.badge {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 3px 9px; border-radius: var(--radius-pill);
  font-size: 10.5px; font-weight: 600;
  text-transform: uppercase; letter-spacing: 0.4px; white-space: nowrap;
}
.badge-dot {
  width: 6px; height: 6px; border-radius: 50%; display: inline-block;
}
.risk-low { background: var(--risk-low-bg); color: var(--risk-low); }
.risk-low .badge-dot { background: var(--risk-low); }
.risk-med { background: var(--risk-med-bg); color: var(--risk-med); }
.risk-med .badge-dot { background: var(--risk-med); }
.risk-high { background: var(--risk-high-bg); color: var(--risk-high); }
.risk-high .badge-dot { background: var(--risk-high); }
.risk-crit { background: var(--risk-crit-bg); color: var(--risk-crit); }
.risk-crit .badge-dot { background: var(--risk-crit); }
.badge-primary { background: var(--primary-soft); color: var(--primary); }
.badge-navy { background: var(--primary-soft); color: var(--primary); }
.badge-secondary { background: var(--secondary-soft); color: var(--secondary); }
.badge-bee { background: #e0e7ff; color: #3730a3; font-weight: 700; }

.tag-chip {
  display: inline-flex; align-items: center;
  padding: 3px 9px; background: var(--primary-soft); color: var(--primary);
  font-size: 11px; border-radius: var(--radius-pill);
  margin: 2px 4px 2px 0; border: 1px solid var(--line);
}
.tag-chip.featured {
  background: var(--secondary-soft); color: var(--secondary);
  border-color: rgba(202, 18, 74, 0.25); font-weight: 600;
}

/* ============== FILTERS ============== */
.filter-bar {
  display: flex; gap: 10px; flex-wrap: wrap;
  padding: 14px 18px; background: white;
  border: 1px solid var(--line); border-radius: var(--radius-lg);
  margin-bottom: 14px; align-items: center;
}
.filter-bar .search-box { flex: 1; min-width: 200px; position: relative; }
.filter-bar input[type="text"],
.filter-bar select {
  width: 100%; padding: 7px 12px 7px 32px;
  border: 1px solid var(--line); border-radius: var(--radius-md);
  font-size: 12.5px; background: var(--bg-alt);
}
.filter-bar select { padding-left: 12px; min-width: 130px; flex: 0; }
.filter-bar .search-icon { position: absolute; left: 10px; top: 50%; transform: translateY(-50%); }
.filter-label {
  font-size: 11px; font-weight: 600; color: var(--muted);
  text-transform: uppercase; letter-spacing: 0.5px;
}

/* ============== MODAL ============== */
.modal-backdrop {
  position: fixed; inset: 0;
  background: rgba(11, 76, 163, 0.45);
  backdrop-filter: blur(4px); z-index: 200;
  opacity: 0; pointer-events: none; transition: opacity 0.2s;
}
.modal-backdrop.active { opacity: 1; pointer-events: all; }
.modal {
  position: fixed; top: 50%; left: 50%;
  transform: translate(-50%, -45%) scale(0.97);
  background: white; border-radius: var(--radius-lg);
  box-shadow: var(--shadow-xl); z-index: 201;
  width: min(960px, calc(100vw - 40px)); max-height: 90vh;
  overflow: hidden; display: flex; flex-direction: column;
  opacity: 0; pointer-events: none; transition: all 0.2s;
}
.modal.active {
  opacity: 1; pointer-events: all;
  transform: translate(-50%, -50%) scale(1);
}
.modal-header {
  padding: 18px 22px; border-bottom: 1px solid var(--line);
  display: flex; justify-content: space-between; align-items: flex-start;
  background: linear-gradient(180deg, var(--bg-alt), white);
}
.modal-header-text h2 { margin: 0 0 4px; font-size: 18px; color: var(--primary); }
.modal-header-text .sub { font-size: 12px; color: var(--muted); }
.modal-close {
  background: transparent; border: none; color: var(--muted);
  font-size: 20px; padding: 4px 8px; cursor: pointer; border-radius: var(--radius-sm);
}
.modal-close:hover { background: var(--bg-alt); color: var(--ink); }
.modal-body { padding: 22px; overflow-y: auto; flex: 1; }
.modal-footer {
  padding: 14px 22px; border-top: 1px solid var(--line);
  display: flex; justify-content: space-between; gap: 8px;
  background: var(--bg-alt); align-items: center;
}
.modal-footer .footer-left,
.modal-footer .footer-right { display: flex; gap: 8px; align-items: center; }

/* ============== WIZARD ============== */
.wizard-progress {
  display: flex; gap: 0; margin-bottom: 24px;
  background: var(--bg-alt); padding: 4px;
  border-radius: var(--radius-md); position: relative;
}
.wizard-step {
  flex: 1; padding: 10px 8px; text-align: center;
  font-size: 11px; font-weight: 600; color: var(--muted);
  position: relative; border-radius: var(--radius-sm);
  transition: var(--transition); cursor: default;
}
.wizard-step .step-num {
  display: inline-flex; align-items: center; justify-content: center;
  width: 22px; height: 22px; border-radius: 50%;
  background: white; border: 2px solid var(--line);
  color: var(--muted); font-weight: 700; font-size: 11px; margin-bottom: 4px;
}
.wizard-step.active { background: white; color: var(--primary); box-shadow: var(--shadow-sm); }
.wizard-step.active .step-num { background: var(--primary); color: white; border-color: var(--primary); }
.wizard-step.complete .step-num { background: var(--risk-low); color: white; border-color: var(--risk-low); }
.wizard-step.complete { color: var(--risk-low); }
.wizard-step-name { display: block; font-size: 11px; }
.wizard-pane { display: none; }
.wizard-pane.active { display: block; }
.wizard-pane-title { font-size: 18px; font-weight: 700; color: var(--primary); margin-bottom: 4px; }
.wizard-pane-sub { color: var(--muted); font-size: 13px; margin-bottom: 18px; }

/* ============== FORMS ============== */
.form-row {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 14px; margin-bottom: 4px;
}
.form-row.three { grid-template-columns: 1fr 1fr 1fr; }
.form-row.full { grid-template-columns: 1fr; }
.form-group { margin-bottom: 14px; }
.form-group label {
  display: block; font-size: 12px; font-weight: 600;
  color: var(--primary); margin-bottom: 6px;
}
.form-group label .required { color: var(--secondary); margin-left: 2px; }
.form-group .help-text { font-size: 11px; color: var(--muted); margin-top: 4px; }
.form-group input[type="text"],
.form-group input[type="number"],
.form-group input[type="email"],
.form-group input[type="tel"],
.form-group input[type="date"],
.form-group select,
.form-group textarea {
  width: 100%; padding: 9px 12px;
  border: 1.5px solid var(--line); border-radius: var(--radius-md);
  font-size: 13px; background: var(--bg-alt);
  transition: var(--transition); color: var(--ink);
}
.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none; border-color: var(--primary); background: white;
  box-shadow: 0 0 0 3px rgba(11, 76, 163, 0.08);
}
.form-group textarea { resize: vertical; min-height: 80px; }

.checkbox-grid {
  display: grid; grid-template-columns: 1fr 1fr; gap: 8px;
}
.checkbox-item {
  display: flex; align-items: center; gap: 8px;
  padding: 10px 12px; background: var(--bg-alt);
  border: 1.5px solid var(--line); border-radius: var(--radius-md);
  cursor: pointer; font-size: 12px; font-weight: 500;
  color: var(--ink-2); transition: var(--transition);
}
.checkbox-item:hover { border-color: var(--primary); background: var(--primary-soft); }
.checkbox-item input { margin: 0; accent-color: var(--primary); }
.checkbox-item.checked {
  background: var(--primary-soft); border-color: var(--primary);
  color: var(--primary); font-weight: 600;
}

.rating-input { display: flex; gap: 6px; }
.rating-pill {
  flex: 1; text-align: center; padding: 9px 0;
  border: 1.5px solid var(--line); border-radius: var(--radius-md);
  background: var(--bg-alt); cursor: pointer;
  font-weight: 600; font-size: 13px; color: var(--muted);
  transition: var(--transition);
}
.rating-pill:hover { border-color: var(--primary); color: var(--primary); }
.rating-pill.selected { background: var(--primary); color: white; border-color: var(--primary); }

.yesno-input { display: flex; gap: 8px; }
.yesno-input button {
  flex: 1; padding: 9px;
  background: var(--bg-alt); border: 1.5px solid var(--line);
  border-radius: var(--radius-md); font-weight: 600;
  font-size: 12px; color: var(--muted);
}
.yesno-input button.selected.yes {
  background: var(--risk-low-bg); border-color: var(--risk-low); color: var(--risk-low);
}
.yesno-input button.selected.no {
  background: var(--risk-crit-bg); border-color: var(--risk-crit); color: var(--risk-crit);
}

.upload-zone {
  border: 2px dashed var(--line); border-radius: var(--radius-md);
  padding: 24px; text-align: center; cursor: pointer;
  transition: var(--transition); background: var(--bg-alt);
}
.upload-zone:hover { border-color: var(--primary); background: var(--primary-soft); }
.upload-zone-icon { font-size: 32px; margin-bottom: 8px; }
.upload-zone-text { font-size: 13px; color: var(--ink-2); font-weight: 600; }
.upload-zone-hint { font-size: 11px; color: var(--muted); margin-top: 4px; }
.upload-file-list {
  margin-top: 12px; display: flex; flex-wrap: wrap;
  gap: 6px; justify-content: center;
}

.review-section {
  margin-bottom: 18px; padding: 14px;
  background: var(--bg-alt); border-radius: var(--radius-md);
  border-left: 4px solid var(--primary);
}
.review-section-title {
  font-weight: 700; color: var(--primary); font-size: 13px;
  margin-bottom: 8px; display: flex;
  justify-content: space-between; align-items: center;
}
.review-edit {
  color: var(--secondary); font-size: 11px; cursor: pointer;
  background: transparent; border: none; font-weight: 600;
}
.review-section-grid {
  display: grid; grid-template-columns: 1fr 1fr;
  gap: 8px; font-size: 12px;
}
.review-field { padding: 6px 0; }
.review-field-label {
  font-size: 10px; color: var(--muted);
  text-transform: uppercase; letter-spacing: 0.4px;
  margin-bottom: 2px;
}
.review-field-value { color: var(--ink); font-weight: 500; }

.review-success { text-align: center; padding: 30px 20px; }
.review-success-icon {
  width: 60px; height: 60px; margin: 0 auto 14px;
  background: var(--risk-low); color: white;
  border-radius: 50%; display: flex; align-items: center; justify-content: center;
  font-size: 30px;
}
.review-success h3 { color: var(--primary); margin: 0 0 8px; font-size: 20px; }
.review-success p { color: var(--muted); font-size: 14px; margin-bottom: 18px; }

/* ============== RESOURCE DETAIL ============== */
.resource-detail-header {
  display: flex; gap: 18px; margin-bottom: 22px;
  padding-bottom: 18px; border-bottom: 1px solid var(--line);
  align-items: flex-start;
}
.resource-detail-avatar {
  width: 64px; height: 64px; border-radius: var(--radius-md);
  background: linear-gradient(135deg, var(--primary), var(--primary-dark));
  color: white; display: flex; align-items: center; justify-content: center;
  font-weight: 800; font-size: 22px; flex-shrink: 0;
}
.resource-detail-info { flex: 1; }
.resource-detail-name {
  font-size: 22px; font-weight: 800; color: var(--primary); margin: 0 0 4px;
}
.resource-detail-meta {
  display: flex; gap: 16px; flex-wrap: wrap;
  font-size: 12px; color: var(--muted); margin-bottom: 10px;
}
.resource-detail-meta span { display: inline-flex; align-items: center; gap: 4px; }
.resource-detail-badges { display: flex; gap: 6px; flex-wrap: wrap; }

.tabs {
  display: flex; gap: 2px;
  border-bottom: 2px solid var(--line); margin-bottom: 18px;
}
.tab {
  background: transparent; border: none;
  padding: 10px 16px; font-size: 13px; font-weight: 600;
  color: var(--muted); border-bottom: 3px solid transparent;
  margin-bottom: -2px; transition: var(--transition);
}
.tab:hover { color: var(--primary); }
.tab.active { color: var(--secondary); border-bottom-color: var(--secondary); }
.tab-pane { display: none; }
.tab-pane.active { display: block; }

.field-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 14px; margin-bottom: 18px;
}
.field-item {
  background: var(--bg-alt); padding: 10px 14px;
  border-radius: var(--radius-md); border-left: 3px solid var(--primary);
}
.field-item.accent { border-left-color: var(--secondary); }
.field-label {
  font-size: 10px; font-weight: 700; color: var(--muted);
  text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 3px;
}
.field-value { font-size: 14px; color: var(--ink); font-weight: 600; }
.field-value.small { font-size: 13px; font-weight: 500; }

/* ============== WARNING BANNERS ============== */
.warning-banner {
  padding: 14px 18px; border-radius: var(--radius-md);
  margin-bottom: 18px; display: flex;
  align-items: flex-start; gap: 12px; border-left: 4px solid;
}
.warning-banner.greylist {
  background: var(--risk-high-bg); border-left-color: var(--risk-high); color: #92400e;
}
.warning-banner.blacklist {
  background: var(--risk-crit-bg); border-left-color: var(--risk-crit); color: var(--risk-crit);
}
.warning-banner.info {
  background: var(--primary-soft); border-left-color: var(--primary); color: var(--primary);
}
.warning-banner-icon { font-size: 22px; flex-shrink: 0; }
.warning-banner-content { flex: 1; }
.warning-banner-title {
  font-weight: 800; font-size: 14px;
  text-transform: uppercase; letter-spacing: 0.5px; margin-bottom: 4px;
}
.warning-banner-body { font-size: 12.5px; }
.warning-banner-meta { font-size: 11px; margin-top: 6px; opacity: 0.8; }

/* ============== EVAL CARDS ============== */
.eval-card {
  background: white; border: 1px solid var(--line);
  border-radius: var(--radius-md); padding: 14px 16px;
  margin-bottom: 10px; border-left: 4px solid var(--primary);
}
.eval-card-head {
  display: flex; justify-content: space-between;
  align-items: flex-start; margin-bottom: 8px;
}
.eval-card-title { font-weight: 700; color: var(--primary); font-size: 13px; }
.eval-card-date { font-size: 11px; color: var(--muted); }
.eval-score-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(110px, 1fr));
  gap: 8px; margin: 10px 0;
}
.eval-score-item {
  background: var(--bg-alt); padding: 6px 10px;
  border-radius: var(--radius-sm); text-align: center;
}
.eval-score-label {
  font-size: 10px; color: var(--muted);
  text-transform: uppercase; letter-spacing: 0.4px;
}
.eval-score-value { font-weight: 700; color: var(--primary); font-size: 14px; }
.eval-score-value.high { color: var(--risk-low); }
.eval-score-value.mid { color: var(--risk-med); }
.eval-score-value.low { color: var(--risk-crit); }
.eval-comments {
  font-size: 12px; color: var(--muted);
  padding-top: 8px; border-top: 1px dashed var(--line);
  margin-top: 8px; font-style: italic;
}

/* ============== AUDIT ============== */
.audit-list .audit-item {
  display: flex; gap: 12px; padding: 10px 14px;
  border-bottom: 1px solid var(--line-soft); align-items: flex-start;
}
.audit-list .audit-item:hover { background: var(--bg-alt); }
.audit-icon {
  width: 28px; height: 28px; border-radius: 50%;
  display: flex; align-items: center; justify-content: center;
  font-weight: 700; font-size: 12px; flex-shrink: 0; color: white;
}
.audit-icon.create { background: var(--risk-low); }
.audit-icon.update { background: var(--primary); }
.audit-icon.delete { background: var(--risk-crit); }
.audit-detail { flex: 1; }
.audit-action { font-size: 13px; color: var(--ink); }
.audit-action strong { color: var(--primary); }
.audit-meta { font-size: 11px; color: var(--muted); margin-top: 2px; }

/* ============== TOAST ============== */
.toast-container {
  position: fixed; top: 80px; right: 24px; z-index: 300;
  display: flex; flex-direction: column; gap: 8px;
}
.toast {
  background: white; border-radius: var(--radius-md);
  padding: 12px 16px; box-shadow: var(--shadow-lg);
  border-left: 4px solid var(--primary);
  display: flex; align-items: center; gap: 10px;
  min-width: 280px; animation: toastIn 0.25s ease-out;
}
.toast.success { border-left-color: var(--risk-low); }
.toast.warn { border-left-color: var(--risk-high); }
.toast.error { border-left-color: var(--risk-crit); }
.toast-icon { font-size: 18px; }
.toast-msg { font-size: 13px; font-weight: 500; color: var(--primary); flex: 1; }
@keyframes toastIn {
  from { opacity: 0; transform: translateX(20px); }
  to { opacity: 1; transform: translateX(0); }
}

/* ============== EXPORT GROUP ============== */
.export-btn-group {
  display: inline-flex; border-radius: var(--radius-md);
  overflow: hidden; border: 1px solid var(--line);
}
.export-btn-group .btn {
  border-radius: 0; border: none;
  border-right: 1px solid var(--line);
  background: white; color: var(--primary);
}
.export-btn-group .btn:last-child { border-right: none; }
.export-btn-group .btn:hover { background: var(--bg-alt); }

/* ============== RISK MATRIX ============== */
.risk-matrix {
  display: grid; grid-template-columns: 1fr 1fr 1fr 1fr;
  gap: 10px; margin-bottom: 16px;
}
.risk-tile {
  padding: 16px; border-radius: var(--radius-md);
  text-align: center; cursor: pointer;
  transition: var(--transition); border: 2px solid transparent;
}
.risk-tile:hover { transform: translateY(-2px); box-shadow: var(--shadow-md); }
.risk-tile.low { background: var(--risk-low-bg); color: var(--risk-low); border-color: var(--risk-low); }
.risk-tile.med { background: var(--risk-med-bg); color: var(--risk-med); border-color: var(--risk-med); }
.risk-tile.high { background: var(--risk-high-bg); color: var(--risk-high); border-color: var(--risk-high); }
.risk-tile.crit { background: var(--risk-crit-bg); color: var(--risk-crit); border-color: var(--risk-crit); }
.risk-tile-count { font-size: 32px; font-weight: 800; line-height: 1; }
.risk-tile-label {
  font-size: 11px; font-weight: 700;
  text-transform: uppercase; letter-spacing: 1px; margin-top: 4px;
}

/* ============== EMPTY / PAGINATION ============== */
.empty-state {
  text-align: center; padding: 60px 20px; color: var(--muted);
}
.empty-state h3 { color: var(--primary); margin-bottom: 8px; }
.pagination {
  display: flex; justify-content: space-between; align-items: center;
  padding: 12px 18px; border-top: 1px solid var(--line);
  background: var(--bg-alt); font-size: 12px; color: var(--muted);
}
.pagination-controls { display: flex; gap: 4px; }
.pagination-btn {
  padding: 5px 10px; background: white; border: 1px solid var(--line);
  border-radius: var(--radius-sm); font-size: 12px; color: var(--primary); cursor: pointer;
}
.pagination-btn.active { background: var(--primary); color: white; border-color: var(--primary); }
.pagination-btn:disabled { opacity: 0.4; cursor: not-allowed; }

/* ============== CHARTS ============== */
.bar-chart-list .bar-row {
  display: flex; align-items: center; gap: 10px; margin-bottom: 10px;
}
.bar-row-label {
  width: 140px; font-size: 12px; color: var(--primary);
  font-weight: 600; flex-shrink: 0;
}
.bar-row-bar-wrap {
  flex: 1; background: var(--bg-alt);
  border-radius: var(--radius-sm); height: 22px;
  position: relative; overflow: hidden;
}
.bar-row-bar {
  background: linear-gradient(90deg, var(--primary), var(--primary-dark));
  height: 100%; border-radius: var(--radius-sm);
  display: flex; align-items: center; padding-left: 8px;
  color: white; font-size: 11px; font-weight: 700;
  transition: width 0.4s ease;
}
.bar-row-bar.secondary {
  background: linear-gradient(90deg, var(--secondary), var(--secondary-dark));
}
.bar-row-value {
  width: 50px; text-align: right;
  font-weight: 700; color: var(--primary);
  font-size: 13px; font-variant-numeric: tabular-nums;
}

.tag-cloud { display: flex; flex-wrap: wrap; gap: 6px; }
.tag-cloud .tag-chip { cursor: pointer; }
.tag-cloud .tag-chip:hover {
  background: var(--primary); color: white; border-color: var(--primary);
}

/* ============== QUICK ACTIONS GRID ============== */
.quick-actions-grid {
  display: grid; grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}
.quick-action-card {
  background: white; border: 1px solid var(--line);
  border-radius: var(--radius-lg); padding: 18px;
  cursor: pointer; transition: var(--transition);
  text-align: center; position: relative; overflow: hidden;
}
.quick-action-card:hover {
  transform: translateY(-3px); box-shadow: var(--shadow-md); border-color: var(--primary);
}
.quick-action-card::after {
  content: "+"; position: absolute; top: 8px; right: 12px;
  font-size: 20px; font-weight: 700; color: var(--primary);
  opacity: 0; transition: var(--transition);
}
.quick-action-card:hover::after { opacity: 1; }
.quick-action-icon {
  width: 44px; height: 44px; margin: 0 auto 10px;
  background: var(--primary-soft); color: var(--primary);
  border-radius: var(--radius-md); display: flex;
  align-items: center; justify-content: center; font-size: 22px;
}
.quick-action-card:nth-child(2n) .quick-action-icon {
  background: var(--secondary-soft); color: var(--secondary);
}
.quick-action-title {
  font-size: 13px; font-weight: 700;
  color: var(--primary); margin-bottom: 2px;
}
.quick-action-desc { font-size: 11px; color: var(--muted); }

/* ============== RESPONSIVE ============== */
@media (max-width: 900px) {
  .sidebar { transform: translateX(-100%); }
  .sidebar.open { transform: translateX(0); }
  .main-content { margin-left: 0; }
  .topbar-left { width: auto; }
  .page-title { display: block; }
  .topbar-search { display: none; }
  .grid-2, .grid-2.even, .grid-3 { grid-template-columns: 1fr; }
  .user-info { display: none; }
  .risk-matrix { grid-template-columns: 1fr 1fr; }
  .feature-grid { grid-template-columns: 1fr; }
  .use-cases { grid-template-columns: 1fr; }
  .stats-row { grid-template-columns: 1fr 1fr; }
  .footer-grid { grid-template-columns: 1fr; }
  .hero-title { font-size: 36px; }
  .form-row, .form-row.three { grid-template-columns: 1fr; }
  .checkbox-grid { grid-template-columns: 1fr; }
  .review-section-grid { grid-template-columns: 1fr; }
}
@media (max-width: 600px) {
  .main-content { padding: 14px; }
  .lang-switch { display: none; }
  .field-grid { grid-template-columns: 1fr; }
  .landing-nav { padding: 12px 16px; }
  .landing-nav .nav-links { gap: 14px; }
  .landing-hero, .landing-section, .cta-strip { padding-left: 16px; padding-right: 16px; }
}

/* utils */
.text-muted { color: var(--muted); }
.text-primary { color: var(--primary); }
.text-secondary { color: var(--secondary); }
.text-success { color: var(--risk-low); }
.text-warn { color: var(--risk-high); }
.text-danger { color: var(--risk-crit); }
.text-center { text-align: center; }
.text-right { text-align: right; }
.font-bold { font-weight: 700; }
.mt-0 { margin-top: 0 !important; }
.mb-0 { margin-bottom: 0 !important; }
.mb-2 { margin-bottom: 12px; }
.mb-3 { margin-bottom: 18px; }
.flex { display: flex; }
.flex-1 { flex: 1; }
.gap-2 { gap: 8px; }
.items-center { align-items: center; }
.justify-between { justify-content: space-between; }
.hidden { display: none !important; }
