:root {
  --v17-navy: #12324b;
  --v17-teal: #087b75;
  --v17-blue: #1769aa;
  --v17-green: #197a55;
  --v17-amber: #a85d12;
  --v17-red: #b53b45;
  --v17-bg: #eef3f7;
  --v17-card: #ffffff;
  --v17-line: #d8e2ea;
  --v17-text: #17324a;
  --v17-muted: #657789;
  --v17-shadow: 0 16px 42px rgba(16, 47, 71, .09);
}

.v17-page { margin: 0; min-height: 100vh; background: var(--v17-bg); color: var(--v17-text); font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif; }
.v17-shell { max-width: 1480px; margin: 0 auto; padding: 24px; }
.v17-header { display: flex; align-items: center; justify-content: space-between; gap: 18px; margin-bottom: 22px; }
.v17-header h1 { margin: 0; font-size: clamp(25px, 3vw, 40px); letter-spacing: -.035em; }
.v17-header p { margin: 7px 0 0; color: var(--v17-muted); max-width: 900px; }
.v17-actions { display: flex; flex-wrap: wrap; gap: 9px; }
.v17-btn { appearance: none; border: 1px solid var(--v17-line); background: white; color: var(--v17-text); border-radius: 11px; padding: 10px 14px; font-weight: 750; cursor: pointer; text-decoration: none; display: inline-flex; align-items: center; gap: 8px; }
.v17-btn:hover { transform: translateY(-1px); box-shadow: 0 8px 18px rgba(16, 47, 71, .09); }
.v17-btn.primary { color: white; background: var(--v17-navy); border-color: var(--v17-navy); }
.v17-btn.danger { color: white; background: var(--v17-red); border-color: var(--v17-red); }
.v17-btn:disabled { opacity: .5; cursor: not-allowed; transform: none; }
.v17-statusbar { display: flex; align-items: center; gap: 10px; padding: 12px 15px; background: #e3f4ef; color: #165c49; border: 1px solid #b9ddcf; border-radius: 13px; margin-bottom: 18px; font-weight: 680; }
.v17-statusbar.warn { background: #fff5e8; color: #80501c; border-color: #edd3ad; }
.v17-statusbar.error { background: #fff0f1; color: #8b2d38; border-color: #efc0c5; }
.v17-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 15px; }
.v17-capability { background: var(--v17-card); border: 1px solid var(--v17-line); border-radius: 17px; padding: 18px; box-shadow: var(--v17-shadow); min-height: 185px; position: relative; overflow: hidden; }
.v17-capability::after { content: ""; position: absolute; width: 90px; height: 90px; border-radius: 50%; right: -28px; top: -28px; background: rgba(23, 105, 170, .08); }
.v17-capability .icon { width: 42px; height: 42px; display: grid; place-items: center; border-radius: 12px; background: #eaf2f8; color: var(--v17-blue); font-size: 19px; }
.v17-capability h3 { margin: 15px 0 7px; font-size: 17px; }
.v17-capability p { margin: 0; color: var(--v17-muted); line-height: 1.55; font-size: 13px; }
.v17-capability .state { margin-top: 14px; display: inline-flex; align-items: center; gap: 7px; border-radius: 999px; padding: 6px 9px; background: #eef3f7; font-size: 12px; font-weight: 800; }
.v17-capability .state.ok { background: #e3f4ef; color: var(--v17-green); }
.v17-capability .state.warn { background: #fff1df; color: var(--v17-amber); }
.v17-section { background: white; border: 1px solid var(--v17-line); border-radius: 17px; padding: 20px; box-shadow: var(--v17-shadow); margin-top: 18px; }
.v17-section-head { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; margin-bottom: 15px; }
.v17-section h2 { margin: 0; font-size: 20px; }
.v17-section .sub { margin: 5px 0 0; color: var(--v17-muted); font-size: 13px; }
.v17-table-wrap { overflow: auto; border: 1px solid var(--v17-line); border-radius: 13px; }
.v17-table { width: 100%; border-collapse: collapse; min-width: 860px; }
.v17-table th, .v17-table td { padding: 11px 12px; border-bottom: 1px solid var(--v17-line); text-align: left; font-size: 13px; vertical-align: top; }
.v17-table th { background: #f3f7fa; color: #40566a; font-size: 11px; text-transform: uppercase; letter-spacing: .05em; position: sticky; top: 0; z-index: 1; }
.v17-table tbody tr:hover { background: #f8fbfd; }
.v17-table tr:last-child td { border-bottom: 0; }
.v17-pill { display: inline-flex; align-items: center; border-radius: 999px; padding: 5px 8px; font-size: 11px; font-weight: 850; white-space: nowrap; }
.v17-pill.p1 { background: #fee6e8; color: #a92635; }
.v17-pill.p2 { background: #fff0dc; color: #96520d; }
.v17-pill.p3 { background: #fff8d8; color: #79610d; }
.v17-pill.p4 { background: #e9f1fb; color: #276398; }
.v17-pill.p5 { background: #e8f5ef; color: #247151; }
.v17-kpis { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 12px; margin-bottom: 16px; }
.v17-kpi { border: 1px solid var(--v17-line); background: #f8fbfd; border-radius: 13px; padding: 13px; }
.v17-kpi small { color: var(--v17-muted); font-weight: 700; }
.v17-kpi strong { display: block; margin-top: 5px; font-size: 24px; }
.v17-form-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 12px; }
.v17-field { display: grid; gap: 6px; }
.v17-field label { font-size: 12px; font-weight: 750; color: #526679; }
.v17-field input, .v17-field select, .v17-field textarea { width: 100%; box-sizing: border-box; border: 1px solid var(--v17-line); border-radius: 10px; padding: 10px 11px; background: white; color: var(--v17-text); }
.v17-field textarea { min-height: 88px; resize: vertical; }
.v17-log { background: #102a3e; color: #d9edf9; border-radius: 13px; padding: 14px; max-height: 290px; overflow: auto; font: 12px/1.55 ui-monospace, SFMono-Regular, Menlo, Consolas, monospace; white-space: pre-wrap; }
.v17-tenant-badge { display: inline-flex; align-items: center; gap: 7px; padding: 7px 10px; border-radius: 999px; background: #e8f4f2; color: #0b665f; font-size: 12px; font-weight: 850; border: 1px solid #c6e5e1; }
.v17-empty { padding: 30px; color: var(--v17-muted); text-align: center; }

@media (max-width: 1100px) { .v17-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } .v17-kpis { grid-template-columns: repeat(3, 1fr); } .v17-form-grid { grid-template-columns: repeat(2, 1fr); } }
@media (max-width: 700px) { .v17-shell { padding: 15px; } .v17-header { align-items: flex-start; flex-direction: column; } .v17-grid, .v17-kpis, .v17-form-grid { grid-template-columns: 1fr; } .v17-section { padding: 15px; } .v17-actions { width: 100%; } .v17-btn { justify-content: center; flex: 1; } }
