/* GENERATED by build_frontend.py from the <style> block in index.html's <head>. DO NOT EDIT: edit index.html and rerun. */
*, *::before, *::after { margin: 0; padding: 0; box-sizing: border-box; }
body { font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', system-ui, sans-serif; color: #1a1a1a; background: #fff; line-height: 1.6; }
a { color: #2563eb; text-decoration: none; }
a:hover { text-decoration: underline; }
code { background: #f3f4f6; padding: 2px 6px; border-radius: 4px; font-size: 0.9em; }
pre { background: #1e1e1e; color: #d4d4d4; padding: 16px 20px; border-radius: 8px; overflow-x: auto; font-size: 0.85em; line-height: 1.5; }

/* Header — scoped to the site header: a bare `header` selector also made
   the plugin page's <header class="plugin-header"> card sticky, so it
   pinned over the nav and covered ~40% of the viewport on scroll. */
body > header { border-bottom: 1px solid #e5e7eb; background: #fff; position: sticky; top: 0; z-index: 100; }
.header-inner { max-width: 960px; margin: 0 auto; padding: 12px 24px; display: flex; align-items: center; gap: 24px; flex-wrap: wrap; }
.logo { font-weight: 700; font-size: 1.1em; color: #1a1a1a; white-space: nowrap; display: flex; align-items: center; gap: 8px; }
.logo:hover { text-decoration: none; }
.logo img { flex-shrink: 0; }
nav { display: flex; gap: 16px; }
nav a { color: #6b7280; font-size: 0.9em; padding: 4px 0; border-bottom: 2px solid transparent; }
nav a:hover { color: #1a1a1a; text-decoration: none; }
nav a.active { color: #1a1a1a; border-bottom-color: #2563eb; }
.nav-search { margin-left: auto; }
.nav-search input { border: 1px solid #e5e7eb; border-radius: 6px; padding: 6px 12px; font-size: 0.85em; width: 200px; outline: none; }
.nav-search input:focus { border-color: #2563eb; box-shadow: 0 0 0 2px rgba(37,99,235,0.1); }

/* Layout */
.container { max-width: 960px; margin: 0 auto; padding: 32px 24px; }
main { min-height: calc(100vh - 160px); }

/* Footer */
footer { border-top: 1px solid #e5e7eb; color: #9ca3af; font-size: 0.85em; padding: 24px 0; }

/* Typography */
h1 { font-size: 1.5em; font-weight: 600; margin-bottom: 8px; }
h2 { font-size: 1.15em; font-weight: 600; margin: 28px 0 12px; }
h3 { font-size: 1em; font-weight: 600; margin: 20px 0 8px; }
.subtitle { color: #6b7280; margin-bottom: 24px; }

/* Stats row */
.stats-row { display: flex; gap: 32px; margin: 24px 0; flex-wrap: wrap; }
.stat { text-align: center; }
.stat-value { font-size: 1.8em; font-weight: 700; }
.stat-label { color: #6b7280; font-size: 0.85em; }

/* Risk distribution mini bars */
.risk-bars { display: flex; gap: 8px; align-items: flex-end; }
.risk-bar-item { display: flex; flex-direction: column; align-items: center; gap: 2px; font-size: 0.7em; color: #6b7280; }
.risk-bar-level { text-transform: capitalize; color: #9ca3af; }
/* Risk score explanation and per-plugin factor breakdown */
details.score-help { margin: 12px 0 4px; font-size: 0.9em; color: #4b5563; }
details.score-help summary { cursor: pointer; color: #2563eb; }
details.score-help p { margin: 8px 0; }
.factor-table { width: auto; min-width: 280px; margin: 8px 0; font-size: 0.95em; }
.factor-table td { padding: 4px 12px 4px 0; }
.factor-table td:last-child { text-align: right; font-variant-numeric: tabular-nums; }
.muted-note { color: #6b7280; font-size: 0.85em; margin: 4px 0 12px; }
.na { color: #9ca3af; font-weight: 400; }
.risk-bar-fill { width: 24px; border-radius: 2px; min-height: 2px; }

/* Search */
.search-box { display: flex; gap: 8px; margin: 24px 0; }
.search-box input { flex: 1; border: 1px solid #e5e7eb; border-radius: 6px; padding: 10px 14px; font-size: 1em; outline: none; }
.search-box input:focus { border-color: #2563eb; box-shadow: 0 0 0 2px rgba(37,99,235,0.1); }
.search-box button { background: #2563eb; color: #fff; border: none; border-radius: 6px; padding: 10px 20px; font-size: 0.9em; cursor: pointer; white-space: nowrap; }
.search-box button:hover { background: #1d4ed8; }
.search-filters { display: flex; gap: 12px; align-items: center; margin-bottom: 16px; flex-wrap: wrap; }
.search-filters select { border: 1px solid #e5e7eb; border-radius: 6px; padding: 6px 10px; font-size: 0.85em; outline: none; }
.search-filters .result-count { color: #6b7280; font-size: 0.85em; margin-left: auto; }

/* Tables */
table { width: 100%; border-collapse: collapse; font-size: 0.9em; }
th { text-align: left; padding: 8px 12px; border-bottom: 2px solid #e5e7eb; font-weight: 600; font-size: 0.85em; color: #6b7280; text-transform: uppercase; letter-spacing: 0.05em; }
td { padding: 8px 12px; border-bottom: 1px solid #e5e7eb; }
tr:hover { background: #f9fafb; }
td a { font-weight: 500; }

/* Badges */
.badge { display: inline-block; padding: 2px 8px; border-radius: 10px; font-size: 0.75em; font-weight: 600; text-transform: capitalize; }
.risk-critical { background: #fef2f2; color: #dc2626; }
.risk-high { background: #fff7ed; color: #ea580c; }
.risk-medium { background: #fefce8; color: #ca8a04; }
.risk-low { background: #eff6ff; color: #2563eb; }
.risk-minimal { background: #f0fdf4; color: #16a34a; }
.risk-unknown { background: #f3f4f6; color: #6b7280; }
.as-none { background: #f0fdf4; color: #16a34a; }
.as-minimal { background: #eff6ff; color: #2563eb; }
.as-medium { background: #fefce8; color: #ca8a04; }
.as-large { background: #fef2f2; color: #dc2626; }
.dir-withdrawn { background: #f3f4f6; color: #6b7280; margin-left: 6px; font-size: 0.7em; }
.dir-closed { background: #fef2f2; color: #991b1b; margin-left: 6px; font-size: 0.7em; }
.dir-commercial { background: #eff6ff; color: #1e40af; margin-left: 6px; font-size: 0.7em; }
.dir-exact { background: #eef2ff; color: #3730a3; margin-left: 6px; font-size: 0.7em; text-transform: none; }
tr.exact-match { background: #f8faff; }

/* Risk bar (horizontal) */
.risk-bar { height: 6px; background: #e5e7eb; border-radius: 3px; overflow: hidden; width: 100%; max-width: 200px; }
.risk-bar-inner { height: 100%; border-radius: 3px; transition: width 0.3s; }

/* Metrics grid */
.metrics-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; margin: 16px 0; }
.metric-card { border: 1px solid #e5e7eb; border-radius: 8px; padding: 16px; }
.metric-value { font-size: 1.4em; font-weight: 700; }
.metric-label { font-size: 0.85em; color: #6b7280; }

/* Cards */
.card { border: 1px solid #e5e7eb; border-radius: 8px; padding: 20px; margin: 16px 0; }
.card-header { display: flex; justify-content: space-between; align-items: center; flex-wrap: wrap; gap: 12px; }

/* Plugin header */
.plugin-header { background: #f9fafb; border: 1px solid #e5e7eb; border-radius: 8px; padding: 24px; margin-bottom: 24px; }
.plugin-header h1 { margin-bottom: 4px; }
.plugin-slug { font-family: monospace; font-size: 0.85em; color: #6b7280; }
.version-picker select { border: 1px solid #d1d5db; border-radius: 6px; padding: 1px 6px; font-size: 1em; color: inherit; background: #fff; max-width: 220px; }
.plugin-meta { display: flex; gap: 16px; align-items: center; flex-wrap: wrap; color: #6b7280; font-size: 0.9em; }

/* Breadcrumb */
.breadcrumb { font-size: 0.85em; color: #6b7280; margin-bottom: 16px; }
.breadcrumb a { color: #6b7280; }
.breadcrumb a:hover { color: #2563eb; }

/* Pagination */
.pagination { display: flex; gap: 8px; align-items: center; justify-content: center; margin-top: 24px; }
.pagination button { border: 1px solid #e5e7eb; background: #fff; border-radius: 6px; padding: 6px 14px; font-size: 0.85em; cursor: pointer; }
.pagination button:hover:not(:disabled) { background: #f9fafb; border-color: #d1d5db; }
.pagination button:disabled { opacity: 0.4; cursor: default; }
.pagination .page-info { font-size: 0.85em; color: #6b7280; }

/* Loading spinner */
.loading { text-align: center; padding: 48px 0; color: #6b7280; }
.spinner { display: inline-block; width: 24px; height: 24px; border: 3px solid #e5e7eb; border-top-color: #2563eb; border-radius: 50%; animation: spin 0.6s linear infinite; }
@keyframes spin { to { transform: rotate(360deg); } }

/* API docs */
.endpoint { display: flex; gap: 8px; align-items: baseline; padding: 6px 0; }
.method { font-weight: 600; font-size: 0.8em; padding: 2px 8px; border-radius: 4px; font-family: monospace; }
.get { background: #dbeafe; color: #1d4ed8; }
.post { background: #dcfce7; color: #166534; }
.path { font-family: monospace; font-size: 0.9em; }
.desc { color: #6b7280; font-size: 0.85em; }

/* Executive summary block */
.exec-summary { background: #fffbeb; border-left: 3px solid #f59e0b; padding: 16px 20px; border-radius: 0 8px 8px 0; margin: 16px 0; font-size: 0.95em; line-height: 1.7; white-space: pre-wrap; }

/* OWASP severity */
.severity-critical { color: #dc2626; font-weight: 600; }
.severity-high { color: #ea580c; font-weight: 600; }
.severity-medium { color: #ca8a04; }
.severity-low { color: #2563eb; }
.severity-info { color: #6b7280; }

/* Section headers with icons */
.section-title { display: flex; align-items: center; gap: 8px; margin: 28px 0 12px; }
.section-title h2 { margin: 0; }
.ic { font-style: normal; font-size: 1.1em; line-height: 1; }

/* Info banner (closed plugin, KEV) */
.info-banner { padding: 12px 16px; border-radius: 6px; font-size: 0.9em; margin: 12px 0; }
.info-banner.warn { background: #fef2f2; border-left: 3px solid #dc2626; color: #991b1b; }
.info-banner.info { background: #eff6ff; border-left: 3px solid #2563eb; color: #1e40af; }
.info-banner.ok { background: #f0fdf4; border-left: 3px solid #16a34a; color: #166534; }

/* Risk breakdown grid */
.risk-breakdown { display: grid; grid-template-columns: repeat(3, 1fr); gap: 12px; margin: 12px 0; }
.risk-breakdown .rb-item { display: flex; align-items: center; gap: 8px; font-size: 0.9em; padding: 8px 12px; background: #f9fafb; border-radius: 6px; }
.rb-dot { width: 8px; height: 8px; border-radius: 50%; flex-shrink: 0; }

/* Findings detail */
.finding-group { border: 1px solid #e5e7eb; border-radius: 8px; margin: 12px 0; overflow: hidden; }
.finding-group-header { background: #f9fafb; padding: 12px 16px; display: flex; justify-content: space-between; align-items: center; cursor: pointer; }
.finding-group-header:hover { background: #f3f4f6; }
.finding-group-body { padding: 12px 16px; border-top: 1px solid #e5e7eb; display: none; }
.finding-group.open .finding-group-body { display: block; }
.finding-group .toggle { color: #6b7280; transition: transform 0.2s; }
.finding-group.open .toggle { transform: rotate(90deg); }

/* Recommendation list */
.rec-list { list-style: none; padding: 0; margin: 8px 0; }
.rec-list li { padding: 4px 0 4px 20px; position: relative; font-size: 0.9em; }
.rec-list li::before { content: '\2192'; position: absolute; left: 0; color: #2563eb; }

/* Finding items */
.finding-item { padding: 6px 0; font-size: 0.85em; color: #4b5563; border-bottom: 1px solid #f3f4f6; }
.finding-item:last-child { border-bottom: none; }
.finding-location { font-family: monospace; font-size: 0.85em; color: #6b7280; }

/* Module chips */
.module-chips { display: flex; flex-wrap: wrap; gap: 8px; margin: 12px 0; }
.module-chip { display: inline-block; padding: 4px 12px; background: #f3f4f6; border-radius: 14px; font-size: 0.8em; color: #4b5563; }
.module-chip:hover { background: #e5e7eb; text-decoration: none; }

/* Endpoint list */
.endpoint-list { max-height: 500px; overflow-y: auto; }
.endpoint-list tr.ep-row { cursor: pointer; }
.endpoint-list tr.ep-row:hover { background: #f3f4f6; }
.ep-detail { display: none; }
.ep-row.open + .ep-detail { display: table-row; }
.ep-detail td { padding: 8px 12px; background: #f9fafb; border-top: none; }
.ep-detail pre { margin: 4px 0; padding: 8px; background: #1e293b; color: #e2e8f0; border-radius: 4px; font-size: 0.8em; overflow-x: auto; white-space: pre-wrap; word-break: break-all; max-height: 200px; }
.ep-detail .ep-file { font-family: monospace; font-size: 0.8em; color: #6b7280; }
.ep-detail .ep-params { display: flex; gap: 6px; flex-wrap: wrap; margin-top: 4px; }
.ep-detail .ep-param { background: #e0e7ff; color: #3730a3; padding: 1px 6px; border-radius: 4px; font-size: 0.75em; font-family: monospace; }

/* Code snippet */
.snippet { font-family: monospace; font-size: 0.85em; background: #f3f4f6; padding: 1px 4px; border-radius: 3px; }

/* Responsive */
@media (max-width: 640px) {
    .header-inner { gap: 12px; }
    .nav-search { margin-left: 0; width: 100%; order: 10; }
    .nav-search input { width: 100%; }
    .metrics-grid { grid-template-columns: 1fr; }
    .risk-breakdown { grid-template-columns: 1fr; }
    .stats-row { gap: 16px; }
    table { font-size: 0.82em; }
    th, td { padding: 6px 8px; }
    .plugin-header { padding: 16px; }
}
