:root {
  --ink: #1d1846; --ink2: #4a4670; --muted: #8580a8; --line: #e7e4f5; --bg: #f6f5fd; --card: #fff;
  --indigo: #3b2fc9; --indigo2: #6b4dff; --coral: #ff6b4a; --amber: #ffb020; --teal: #13b5a0; --green: #1fa86b; --red: #e5484d;
  --radius: 14px; --shadow: 0 1px 2px rgba(29,24,70,.05), 0 6px 22px rgba(59,47,201,.07);
}
* { box-sizing: border-box; }
body { margin: 0; font-family: 'Plus Jakarta Sans', system-ui, -apple-system, Segoe UI, Roboto, sans-serif; color: var(--ink); background: var(--bg); font-size: 14px; }
a { color: var(--indigo); }
.boot { padding: 80px; text-align: center; color: var(--muted); }
.muted { color: var(--muted); } .small { font-size: 12.5px; } .tiny { font-size: 11px; margin-top: 2px; }
.red { color: var(--red); } .strong { font-weight: 700; } .mono { font-variant-numeric: tabular-nums; font-family: ui-monospace, 'SFMono-Regular', Menlo, monospace; font-size: 12.5px; }
.nowrap { white-space: nowrap; }

/* Top bar */
.topbar { position: sticky; top: 0; z-index: 20; display: flex; align-items: center; gap: 24px; padding: 12px 28px;
  background: linear-gradient(100deg, #2a1fa8 0%, #3b2fc9 45%, #6b4dff 100%); color: #fff; box-shadow: 0 4px 20px rgba(42,31,168,.25); flex-wrap: wrap; }
.brand { display: flex; align-items: center; gap: 12px; }
.brand-name { font-weight: 800; font-size: 20px; letter-spacing: -.3px; }
.tagline { font-size: 11.5px; opacity: .8; }
.topbar nav { display: flex; gap: 2px; flex: 1; flex-wrap: wrap; }
.topbar nav a { color: #fff; text-decoration: none; padding: 8px 11px; white-space: nowrap; border-radius: 10px; font-weight: 600; opacity: .82; }
.topbar nav a:hover { background: rgba(255,255,255,.12); opacity: 1; }
.topbar nav a.active { background: #fff; color: var(--indigo); opacity: 1; }
.me { display: flex; align-items: center; gap: 12px; }
.who { display: flex; flex-direction: column; align-items: flex-end; line-height: 1.25; }
.who small { opacity: .75; font-size: 11px; }
.who .role { margin-top: 2px; }
.mode { font-size: 11px; font-weight: 700; padding: 4px 10px; border-radius: 99px; letter-spacing: .4px; text-transform: uppercase; }
.mode.demo { background: var(--amber); color: #3b2600; } .mode.live { background: #5ee6c8; color: #003b30; }

main { max-width: 1480px; margin: 0 auto; padding: 24px 28px 60px; }
.page-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 16px; margin-bottom: 18px; flex-wrap: wrap; }
.page-head h1 { margin: 4px 0 4px; font-size: 26px; letter-spacing: -.5px; }
.page-head p { margin: 0; }
.back { font-size: 12.5px; text-decoration: none; font-weight: 600; }

.card { background: var(--card); border-radius: var(--radius); box-shadow: var(--shadow); border: 1px solid var(--line); padding: 18px; margin-bottom: 18px; }
.card.error { color: var(--red); }

/* Buttons */
.btn { border: 0; border-radius: 10px; padding: 10px 16px; font: inherit; font-weight: 700; cursor: pointer; transition: transform .05s, box-shadow .15s; }
.btn:active { transform: translateY(1px); }
.btn.primary { background: linear-gradient(135deg, var(--coral), #ff8f3f); color: #fff; box-shadow: 0 4px 14px rgba(255,107,74,.35); }
.btn.ghost { background: #f0eefc; color: var(--indigo); }
.topbar .btn.ghost { background: rgba(255,255,255,.15); color: #fff; }
.btn.danger { background: #fdecec; color: var(--red); }
.btn.link { background: none; color: var(--indigo); padding: 4px 6px; }
.btn.sm { padding: 6px 12px; font-size: 12.5px; }

/* KPIs */
.kpis { display: grid; grid-template-columns: repeat(auto-fit, minmax(190px, 1fr)); gap: 14px; margin-bottom: 18px; }
.kpi { border-radius: var(--radius); padding: 16px 18px; color: #fff; box-shadow: var(--shadow); }
.kv { font-size: 30px; font-weight: 800; letter-spacing: -.5px; } .kl { font-size: 12.5px; opacity: .92; font-weight: 600; }
.k-indigo { background: linear-gradient(135deg, #3b2fc9, #6b4dff); }
.k-coral { background: linear-gradient(135deg, #ff6b4a, #ff9a5a); }
.k-teal { background: linear-gradient(135deg, #0f9e8c, #2fd1b5); }
.k-amber { background: linear-gradient(135deg, #f59e0b, #ffc94a); color: #3b2600; }
.k-red { background: linear-gradient(135deg, #e5484d, #ff7b7f); }
.k-green { background: linear-gradient(135deg, #1fa86b, #4fd393); }

/* Toolbar & inputs */
.toolbar { display: flex; gap: 10px; align-items: center; margin-bottom: 14px; flex-wrap: wrap; }
.toolbar .count { margin-left: auto; font-size: 12.5px; }
input, select, textarea { font: inherit; color: var(--ink); border: 1.5px solid var(--line); border-radius: 10px; padding: 9px 11px; background: #fff; outline: none; }
input:focus, select:focus, textarea:focus { border-color: var(--indigo2); box-shadow: 0 0 0 3px rgba(107,77,255,.14); }
.search { min-width: 280px; }
label { display: flex; flex-direction: column; gap: 5px; font-size: 12px; font-weight: 600; color: var(--ink2); }
label.check { flex-direction: row; align-items: center; gap: 8px; font-weight: 500; }

/* Tables */
.table-wrap { overflow-x: auto; }
table.grid { width: 100%; border-collapse: separate; border-spacing: 0; }
.grid th { text-align: left; font-size: 11.5px; text-transform: uppercase; letter-spacing: .5px; color: var(--ink2); background: #f3f1fd; padding: 11px 12px; white-space: nowrap; border-bottom: 2px solid var(--coral); }
.grid th:first-child { border-top-left-radius: 10px; } .grid th:last-child { border-top-right-radius: 10px; }
.grid td { padding: 12px; border-bottom: 1px solid var(--line); vertical-align: top; }
.grid tbody tr:hover td { background: #fbfaff; }
.grid td.wrap { min-width: 170px; max-width: 260px; }
.empty { text-align: center; color: var(--muted); padding: 30px !important; }

.bar-wrap { display: inline-flex; align-items: center; gap: 8px; min-width: 150px; }
.bar { flex: 1; height: 9px; background: #eeecf8; border-radius: 99px; overflow: hidden; min-width: 90px; }
.fill { display: block; height: 100%; border-radius: 99px; }
.fill.low { background: linear-gradient(90deg, #e5484d, #ff7b7f); } .fill.mid { background: linear-gradient(90deg, #f59e0b, #ffc94a); }
.fill.good { background: linear-gradient(90deg, #3b2fc9, #6b4dff); } .fill.done { background: linear-gradient(90deg, #1fa86b, #4fd393); }
.fill.exec { background: linear-gradient(90deg, #0f9e8c, #2fd1b5); }
.bar-wrap b { font-size: 13px; min-width: 40px; }
.noc-link { display: inline-flex; flex-direction: column; text-decoration: none; color: inherit; padding: 6px 8px; margin: -6px -8px; border-radius: 10px; border: 1.5px dashed transparent; }
.noc-link:hover { border-color: var(--indigo2); background: #f3f0ff; }
.noc-link .frac { font-size: 11px; color: var(--indigo); font-weight: 700; margin-top: 2px; }
.noc-link .frac::after { content: '  View NOCs \2192'; opacity: 0; transition: opacity .15s; }
.noc-link:hover .frac::after { opacity: 1; }

/* Badges */
.badge { display: inline-block; padding: 4px 10px; border-radius: 99px; font-size: 11.5px; font-weight: 700; white-space: nowrap; background: #eee; color: #444; }
.b-approved, .b-completed, .b-insert, .b-done, .b-resolved { background: #dcf7ea; color: #0c7a48; }
.b-in-execution, .b-under-review, .b-in-progress, .b-update, .b-scheduled { background: #e7e3ff; color: #3b2fc9; }
.b-submitted, .b-resubmitted { background: #dff3ff; color: #0a6aa1; }
.b-noc-stage, .b-comments-received, .b-planning, .b-open, .b-pending { background: #fff1d6; color: #8a5a00; }
.b-rejected, .b-expired, .b-delete { background: #fde3e3; color: #b42318; }
.b-on-hold { background: #ffe4d6; color: #b2410f; }
.b-not-started, .b-closed, .b-not-applicable, .b-waived { background: #eceaf3; color: #6b6790; }
.tag { font-size: 10.5px; background: #f0eefc; color: var(--indigo); padding: 2px 7px; border-radius: 6px; font-weight: 700; }
.role { font-size: 10.5px; font-weight: 800; text-transform: uppercase; letter-spacing: .5px; padding: 3px 8px; border-radius: 6px; }
.r-admin { background: #ff6b4a; color: #fff; } .r-manager { background: #ffb020; color: #3b2600; }
.r-engineer { background: #5ee6c8; color: #003b30; } .r-viewer { background: #e3e0f5; color: #4a4670; }

/* NOC summary */
.noc-summary { display: grid; grid-template-columns: auto 1fr auto; gap: 22px; align-items: center; background: linear-gradient(120deg, #fff 55%, #fff4ef); }
.sum-text h3 { margin: 0 0 6px; } .sum-text p { margin: 3px 0; }
.filters { display: flex; gap: 12px; flex-wrap: wrap; } .filters select { min-width: 220px; }

.noc-row { cursor: pointer; }
.noc-row.open td { background: #f6f3ff !important; border-bottom-color: transparent; }
.noc-row.na td { opacity: .6; }
.chev { border: 0; background: #f0eefc; color: var(--indigo); width: 26px; height: 26px; border-radius: 8px; cursor: pointer; font-size: 12px; }
.detail-row > td { background: #f6f3ff; padding: 0 12px 16px !important; }
.detail { background: #fff; border-radius: 12px; border: 1px solid var(--line); overflow: hidden; }
.tabs { display: flex; gap: 2px; background: #faf9ff; border-bottom: 1px solid var(--line); overflow-x: auto; padding: 6px 6px 0; }
.tab { border: 0; background: none; padding: 10px 14px; font: inherit; font-weight: 600; font-size: 12.5px; color: var(--ink2); cursor: pointer; border-radius: 9px 9px 0 0; white-space: nowrap; }
.tab.on { background: #fff; color: var(--coral); box-shadow: inset 0 -3px 0 var(--coral); }
.cnt { background: #ece9ff; color: var(--indigo); border-radius: 99px; padding: 1px 7px; font-size: 10.5px; margin-left: 3px; }
.tab-body { padding: 16px; }
.ov { display: grid; grid-template-columns: repeat(auto-fit, minmax(210px, 1fr)); gap: 10px; }
.kvp { background: #faf9ff; border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; display: flex; flex-direction: column; gap: 3px; }
.kvp span { font-size: 11px; color: var(--muted); text-transform: uppercase; letter-spacing: .4px; font-weight: 700; }
.row-actions { display: flex; gap: 8px; margin-top: 14px; }
table.mini { width: 100%; border-collapse: collapse; margin-top: 10px; }
.mini th { font-size: 11px; text-transform: uppercase; color: var(--muted); text-align: left; padding: 8px; border-bottom: 1px solid var(--line); }
.mini td { padding: 9px 8px; border-bottom: 1px solid #f1eff9; vertical-align: top; }
.mini select, .mini input { padding: 5px 8px; font-size: 12.5px; }
.add-form { display: flex; flex-wrap: wrap; gap: 10px; align-items: flex-end; background: #fff8f4; border: 1px dashed #ffc6b4; border-radius: 10px; padding: 12px; }
.add-form label { min-width: 140px; } .add-form label.wide { flex: 1 1 260px; }

/* Modal */
.overlay { position: fixed; inset: 0; background: rgba(29,24,70,.45); display: grid; place-items: center; z-index: 50; padding: 20px; }
.modal { width: min(760px, 100%); max-height: 90vh; overflow: auto; margin: 0; }
.modal-head { display: flex; justify-content: space-between; align-items: center; margin-bottom: 10px; } .modal-head h3 { margin: 0; }
.x { border: 0; background: #f0eefc; width: 32px; height: 32px; border-radius: 9px; font-size: 20px; cursor: pointer; color: var(--indigo); }
.stack { display: flex; flex-direction: column; gap: 12px; }
.grid2 { display: grid; grid-template-columns: 1fr 1fr; gap: 12px 14px; }
.grid2 .wide, .grid2 fieldset, .grid2 .modal-foot { grid-column: 1 / -1; }
.modal-foot { display: flex; justify-content: flex-end; gap: 8px; margin-top: 6px; }
fieldset { border: 1.5px solid var(--line); border-radius: 10px; padding: 10px 14px; } legend { font-weight: 700; font-size: 12px; color: var(--ink2); padding: 0 6px; }
.auth-pick { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }

/* Audit & users */
.chg { font-size: 12px; } .role-legend { display: grid; gap: 8px; } .role-legend div { display: flex; gap: 10px; align-items: center; }

/* Login */
.login-wrap { min-height: 100vh; display: grid; grid-template-columns: 1.1fr 1fr; }
.login-hero { background: radial-gradient(circle at 20% 20%, #6b4dff 0, #3b2fc9 45%, #241a8f 100%); color: #fff; padding: 60px 56px; display: flex; flex-direction: column; justify-content: center; gap: 22px; }
.login-hero h1 { font-size: 34px; line-height: 1.15; letter-spacing: -.8px; margin: 0; max-width: 520px; }
.brand.big .brand-name { font-size: 30px; } .brand.big .tagline { font-size: 14px; }
.hero-points { margin: 0; padding-left: 20px; line-height: 2; opacity: .92; }
.login-card { align-self: center; justify-self: center; width: min(440px, 92%); }
.login-card h2 { margin-top: 0; }
.demo-users { display: grid; gap: 8px; margin: 12px 0 16px; }
.demo-user { display: flex; justify-content: space-between; align-items: center; border: 1.5px solid var(--line); background: #fff; border-radius: 12px; padding: 12px 14px; font: inherit; cursor: pointer; }
.demo-user:hover { border-color: var(--indigo2); background: #f7f5ff; }
.connect summary { cursor: pointer; font-weight: 700; color: var(--indigo); margin-bottom: 10px; }

/* Toast */
.toast { position: fixed; bottom: 22px; left: 50%; transform: translate(-50%, 20px); padding: 12px 18px; border-radius: 12px; color: #fff; font-weight: 600; opacity: 0; transition: all .2s; z-index: 99; pointer-events: none; }
.toast.ok { background: #1d1846; } .toast.err { background: var(--red); }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

@media (max-width: 900px) {
  .login-wrap { grid-template-columns: 1fr; } .login-hero { padding: 36px 24px; }
  .noc-summary { grid-template-columns: 1fr; } .grid2 { grid-template-columns: 1fr; }
  main { padding: 16px; } .topbar { padding: 12px 16px; } .search { min-width: 0; flex: 1; }
  .who small { display: none; }
  .kpis { grid-template-columns: 1fr 1fr; gap: 10px; } .kpi { padding: 12px 14px; } .kv { font-size: 24px; }
}

/* Contract context */
.contract-chip { display: flex; flex-direction: column; text-decoration: none; color: #fff; background: rgba(255,255,255,.13); border: 1px solid rgba(255,255,255,.25); border-radius: 12px; padding: 6px 12px; line-height: 1.25; max-width: 300px; }
.contract-chip small { font-size: 10px; text-transform: uppercase; letter-spacing: .6px; opacity: .75; }
.contract-chip b { font-size: 13px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.contract-chip span { font-size: 10.5px; color: #ffcf9e; font-weight: 700; }
.contract-chip:hover { background: rgba(255,255,255,.22); }
.contract-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(320px, 1fr)); gap: 16px; }
.contract-card { text-align: left; font: inherit; color: inherit; background: #fff; border: 1.5px solid var(--line); border-radius: 16px; padding: 18px; cursor: pointer; box-shadow: var(--shadow); position: relative; overflow: hidden; transition: transform .12s, border-color .12s; }
.contract-card::before { content: ''; position: absolute; inset: 0 0 auto 0; height: 5px; background: linear-gradient(90deg, var(--coral), var(--indigo2)); }
.contract-card:hover { transform: translateY(-2px); border-color: var(--indigo2); }
.contract-card.on { border-color: var(--coral); }
.contract-card h3 { margin: 10px 0 4px; font-size: 17px; } .contract-card p { margin: 0 0 14px; font-size: 12.5px; }
.cc-top { display: flex; justify-content: space-between; align-items: center; }
.cc-stats { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.cc-stats div { background: #f7f5ff; border-radius: 10px; padding: 8px 10px; display: flex; flex-direction: column; }
.cc-stats b { font-size: 18px; color: var(--indigo); } .cc-stats span { font-size: 11px; color: var(--muted); font-weight: 600; }
.cc-go { display: block; margin-top: 12px; font-weight: 700; color: var(--coral); font-size: 13px; }
.access { display: flex; flex-wrap: wrap; gap: 4px 12px; } .access label { font-size: 12px; }

/* New NOC statuses / helpers */
.b-awaiting-response { background: #dff3ff; color: #0a6aa1; } .b-follow-up-ongoing { background: #ece6ff; color: #5b3fc4; }
.b-need-modification { background: #fff1d6; color: #8a5a00; }
.tag.urg { background: #fde3dc; color: #c43d22; }
.k-navy { background: linear-gradient(135deg, #1f4e79, #3a78b5); }
.fill.ovr { background: linear-gradient(90deg, #1f4e79, #3a78b5); }

/* ===== Scheme NOC dashboard (Freiburg tracker style) ===== */
.fx { --c: #e2573b; --cd: #b8392a; --pe: #fde4d9; --pe2: #fdf1ea; --nv: #2c5b8a; --nvd: #1f4568; --nvl: #dce7f3; --ch: #2b2d31;
  font-family: Cambria, 'Noto Serif', Georgia, serif; color: #2b2d31; background: #fbf8f4; margin: -24px -28px; padding-bottom: 30px; }
.fx-head { background: var(--c); color: #fff; padding: 22px 28px; display: flex; justify-content: space-between; align-items: center; gap: 16px; }
.fx-head h1 { margin: 0; font-size: 28px; } .fx-head p { margin: 6px 0 0; opacity: .92; font-size: 13.5px; }
.fx-logo { background: #fff; border-radius: 8px; padding: 8px 14px; } .fx-logo img { height: 56px; display: block; }
.fx-meta { background: var(--pe); padding: 10px 28px; display: flex; gap: 28px; flex-wrap: wrap; font-size: 13px; }
.fx-meta-act { margin-left: auto; } .fx-meta a { color: var(--cd); font-weight: 700; text-decoration: none; }
.fx > section, .fx > .fx-tiles, .fx > h2, .fx > .fx-2col, .fx > .fx-note { margin-left: 28px; margin-right: 28px; }
.fx-h2 { font-size: 17px; letter-spacing: .4px; text-transform: uppercase; margin: 22px 0 12px; }
.fx-hero { display: grid; grid-template-columns: 1fr 1fr 1.6fr; gap: 14px; margin-top: 20px; }
.fx-big { border-radius: 10px; padding: 18px 20px; color: #fff; }
.fx-big.c { background: linear-gradient(135deg, var(--cd), var(--c)); } .fx-big.n { background: linear-gradient(135deg, var(--nvd), var(--nv)); }
.fx-big .l { font-weight: 700; font-size: 13px; text-transform: uppercase; letter-spacing: .5px; } .fx-big .v { font-size: 44px; font-weight: 800; margin: 4px 0; } .fx-big .s { font-size: 12.5px; opacity: .92; }
.fx-stages { background: #fff; border: 1px solid #eadfd6; border-radius: 10px; padding: 12px 16px; display: flex; flex-direction: column; gap: 10px; justify-content: center; }
.fx-stage { display: grid; grid-template-columns: 30px 1fr auto; gap: 12px; align-items: center; }
.fx-stage .no { width: 28px; height: 28px; border-radius: 50%; background: var(--c); color: #fff; display: grid; place-items: center; font-weight: 800; }
.fx-stage .t small { display: block; color: #8a7f78; font-size: 11.5px; margin-bottom: 4px; } .fx-stage .val { font-weight: 800; font-size: 16px; }
.fx-tiles { display: grid; grid-template-columns: repeat(auto-fit, minmax(150px, 1fr)); gap: 12px; }
.fx-tile { background: var(--pe); border-radius: 8px; padding: 14px 10px; text-align: center; }
.fx-tile .l { font-size: 12px; font-weight: 700; color: #6b5d55; } .fx-tile .v { font-size: 28px; font-weight: 800; margin: 4px 0; } .fx-tile .s { font-size: 11.5px; color: #6b5d55; }
.fx-tile.alert { background: var(--cd); color: #fff; } .fx-tile.alert .l, .fx-tile.alert .s { color: #fff; opacity: .92; }
.fx-tile.hl { background: #fff; border: 2px solid var(--c); } .fx-tile.hl .v { color: var(--cd); }
.fx-tile.hl2 { background: #fff; border: 2px solid var(--nv); } .fx-tile.hl2 .v { color: var(--nvd); }
.fx-sec { border: 3px solid var(--c); border-radius: 12px; background: #fff; margin-top: 24px; overflow: hidden; }
.fx-sec > .fx-tiles, .fx-sec > .fx-tw { margin: 16px; }
.fx-sec-h { background: var(--c); color: #fff; padding: 10px 16px; font-weight: 700; letter-spacing: .6px; }
.fx-sec.mn { border-color: var(--nv); } .fx-sec.mn .fx-sec-h { background: var(--nv); }
.fx-sec.mn .fx-tile { background: var(--nvl); } .fx-sec.mn .fx-tile.alert { background: var(--nvd); } .fx-sec.mn .fx-bar span { background: var(--nv); }
.fx-tw { overflow-x: auto; } .fx-tw.tall { max-height: 520px; overflow-y: auto; }
.fx-t { width: 100%; border-collapse: collapse; font-size: 13px; }
.fx-t th { background: var(--ch); color: #fff; text-align: left; padding: 10px 8px; border-bottom: 3px solid var(--c); position: sticky; top: 0; white-space: nowrap; }
.fx-t td { padding: 8px; border-bottom: 1px solid #ece5df; vertical-align: top; }
.fx-sec.pb .fx-app td { background: var(--pe2); } .fx-sec.pb .fx-app td:first-child { box-shadow: inset 4px 0 0 var(--c); }
.fx-app { cursor: pointer; } .fx-app:hover td { background: #fff3ec !important; } .fx-app.open td { background: #ffe9de !important; font-weight: 600; }
.fx-chev { border: 0; background: var(--c); color: #fff; width: 26px; height: 26px; border-radius: 6px; cursor: pointer; }
.fx-sec.mn .fx-chev { background: var(--nv); }
.fx-sub > td { background: #fffaf7; padding: 4px 8px 14px 36px !important; }
.fx-detail { border-left: 4px solid var(--c); background: #fff; border-radius: 0 8px 8px 0; padding: 10px 12px; box-shadow: 0 2px 10px rgba(0,0,0,.05); }
.fx-sec.mn .fx-detail { border-left-color: var(--nv); }
.fx-detail-h { display: flex; justify-content: space-between; gap: 10px; flex-wrap: wrap; align-items: center; margin-bottom: 8px; }
.fx-stg { display: flex; gap: 14px; align-items: center; flex-wrap: wrap; font-size: 12.5px; }
.fx-t.inner th { background: #4a4d53; border-bottom-width: 2px; font-size: 12px; position: static; }
.fx-bar { height: 12px; background: #ece5df; border-radius: 6px; overflow: hidden; min-width: 120px; } .fx-bar span { display: block; height: 100%; background: var(--c); border-radius: 6px; }
.fx-bar.c span { background: var(--c); }
.red { color: var(--cd, #b8392a); } .b { font-weight: 700; } td.ovc { color: var(--nvd); }
.fx-done { background: #fde68a; color: #6b4c00; padding: 4px 8px; border-radius: 4px; font-weight: 700; font-size: 12px; margin-top: 4px; display: inline-block; }
.fx-stage-tag { display: inline-block; font-size: 11px; font-weight: 700; background: #2b2d31; color: #fff; padding: 2px 8px; border-radius: 4px; margin-bottom: 4px; }
.fx-pill { display: inline-block; padding: 3px 9px; border-radius: 99px; font-size: 11.5px; font-weight: 700; white-space: nowrap; background: #eee; color: #555; }
.p-approved, .p-not-required { background: #dcf7ea; color: #0c7a48; } .p-awaiting-response { background: #dff3ff; color: #0a6aa1; }
.p-follow-up-ongoing { background: #ece6ff; color: #5b3fc4; } .p-need-modification, .p-in-progress { background: #fff1d6; color: #8a5a00; }
.p-rejected, .p-expired { background: #fde3e3; color: #b42318; }
.fx-tp { background: #8a5a00; color: #fff; font-size: 10px; font-weight: 800; padding: 2px 6px; border-radius: 4px; }
.fx-urg { background: var(--c); color: #fff; font-size: 10px; font-weight: 800; padding: 2px 7px; border-radius: 4px; }
.fx-t tr.urg td { background: var(--pe2); } .fx-t tr.urg td:first-child { box-shadow: inset 4px 0 0 var(--c); }
.fx-2col { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-top: 24px; }
.fx-card { background: #fff; border: 1px solid #eadfd6; border-radius: 10px; padding: 4px 18px 16px; margin-top: 24px; }
.fx-2col .fx-card { margin-top: 0; }
.fx-hb { display: grid; grid-template-columns: 150px 1fr 70px; gap: 10px; align-items: center; margin: 6px 0; font-size: 12.5px; }
.fx-hb .fx-bar span { background: var(--nv); } .fx-hb .fx-bar.c span { background: var(--c); }
.fx-stack { display: flex; height: 14px; } .fx-stack i { display: block; height: 100%; }
.fx-leg { font-size: 12px; color: #6b5d55; margin-bottom: 8px; } .fx-leg i { display: inline-block; width: 10px; height: 10px; border-radius: 2px; margin: 0 4px 0 10px; vertical-align: -1px; }
.fx-leg i.c { background: var(--c); } .fx-leg i.n { background: var(--nv); }
.fx-stack i.p-awaiting-response, .fx-leg i.p-awaiting-response { background: #2c5b8a; } .fx-stack i.p-follow-up-ongoing, .fx-leg i.p-follow-up-ongoing { background: #7d5bd6; }
.fx-stack i.p-need-modification, .fx-leg i.p-need-modification { background: #e0a100; } .fx-stack i.p-rejected, .fx-leg i.p-rejected { background: #c0392b; }
.fx-chips { display: flex; gap: 6px; margin-bottom: 10px; } .fx-chips button { font: inherit; font-size: 12.5px; border: 1px solid #ccc; background: #fff; border-radius: 99px; padding: 5px 12px; cursor: pointer; }
.fx-chips button.on { background: var(--ch); color: #fff; border-color: var(--ch); }
.fx-note { font-style: italic; font-size: 12px; color: #7a6f68; margin-top: 18px; }
@media (max-width: 900px) { .fx { margin: -16px; } .fx-hero, .fx-2col { grid-template-columns: 1fr; } .fx > section, .fx > .fx-tiles, .fx > h2, .fx > .fx-2col, .fx > .fx-note { margin-left: 12px; margin-right: 12px; } .fx-head { padding: 16px; } .fx-head h1 { font-size: 20px; } .fx-logo img { height: 38px; } }

.fx { margin-top: -24px; }
.fx-stagebar { margin: 14px 28px 0; background: #fff; border: 1px solid #eadfd6; border-radius: 8px; padding: 10px 14px; display: flex; gap: 22px; flex-wrap: wrap; align-items: center; font-size: 13px; }
.fx-stagebar i { font-style: normal; display: inline-grid; place-items: center; width: 20px; height: 20px; border-radius: 50%; background: #e2573b; color: #fff; font-weight: 800; font-size: 11px; margin-right: 4px; }
@media (max-width: 900px) { .fx-stagebar { margin: 12px; } }

/* Permits and NOC bars (v8) */
.grid th small, .fx-t th small { font-weight: 600; opacity: .75; font-size: 10px; margin-left: 3px; }
.frac { font-size: 11px; color: var(--muted); font-weight: 600; margin-top: 2px; }
.fill.mun { background: linear-gradient(90deg, #b7791f, #f0b429); } .fill.itc { background: linear-gradient(90deg, #6b3fa0, #9f7aea); }
.fx-pb { display: flex; align-items: center; gap: 8px; min-width: 150px; padding: 6px 8px; border-radius: 8px; }
.fx-pb .fx-bar { flex: 1; min-width: 80px; height: 10px; } .fx-pb b { min-width: 48px; font-size: 13.5px; text-align: right; }
.fx-pb.con { background: #fdece6; border: 1.5px solid #f5b6a5; } .fx-pb.con .fx-bar span { background: #e2573b !important; } .fx-pb.con b { color: #b8392a; }
.fx-pb.ovr { background: #e4edf7; border: 1.5px solid #9dbbdc; } .fx-pb.ovr .fx-bar span { background: #1f4568 !important; } .fx-pb.ovr b { color: #1f4568; }
.fx-permit { min-width: 120px; padding: 6px 8px; border-radius: 8px; background: #f4f1ee; border: 1.5px solid #e2dbd5; }
.fx-permit .fx-bar { height: 8px; min-width: 0; margin-bottom: 4px; } .fx-permit b { font-size: 11.5px; }
.fx-permit.p-approved, .fx-permit.p-not-required { background: #e3f6ec; border-color: #9ed9b9; } .fx-permit.p-approved .fx-bar span, .fx-permit.p-not-required .fx-bar span { background: #1fa86b !important; }
.fx-permit.p-approved b, .fx-permit.p-not-required b { color: #0c7a48; }
.fx-permit.p-in-progress { background: #fff4dc; border-color: #f2cc7a; } .fx-permit.p-in-progress .fx-bar span { background: #e0a100 !important; } .fx-permit.p-in-progress b { color: #8a5a00; }
.fx-permit.p-not-started b { color: #8a7f78; }
.fx-t th.h-con { border-bottom-color: #e2573b; } .fx-t th.h-mun { border-bottom-color: #f0b429; } .fx-t th.h-itc { border-bottom-color: #9f7aea; } .fx-t th.h-ovr { border-bottom-color: #3a78b5; }
.fx-stagebar .sb { padding: 5px 10px; border-radius: 6px; font-weight: 600; }
.fx-stagebar .sb.c { background: #fdece6; color: #b8392a; } .fx-stagebar .sb.m { background: #fff4dc; color: #8a5a00; }
.fx-stagebar .sb.i { background: #efe8fb; color: #5b3fc4; } .fx-stagebar .sb.o { background: #1f4568; color: #fff; font-size: 15px; font-weight: 800; }

/* ===== Scheme NOC dashboard in InfraOrbit blue theme (v9) ===== */
.fx { --c: #ff6b4a; --cd: #e5484d; --pe: #f0eefc; --pe2: #fff6f2; --nv: #3b2fc9; --nvd: #2a1fa8; --nvl: #ece9ff; --ch: #1d1846;
  font-family: 'Plus Jakarta Sans', system-ui, -apple-system, Segoe UI, Roboto, sans-serif; color: #1d1846; background: #f6f5fd; }
.fx-head { background: linear-gradient(100deg, #2a1fa8 0%, #3b2fc9 45%, #6b4dff 100%); }
.fx-head h1 { font-size: 26px; letter-spacing: -.4px; }
.fx-meta { background: #ece9ff; color: #4a4670; } .fx-meta a { color: #3b2fc9; }
.fx-h2 { color: #1d1846; font-size: 15px; letter-spacing: .6px; }
.fx-tile { background: #fff; border: 1px solid #e7e4f5; box-shadow: 0 4px 16px rgba(59,47,201,.06); border-radius: 12px; }
.fx-tile .l, .fx-tile .s { color: #6b6790; }
.fx-tile.alert { background: linear-gradient(135deg, #ff6b4a, #ff9a5a); border: 0; }
.fx-tile.hl { background: #fff; border: 2px solid #ff6b4a; } .fx-tile.hl .v { color: #e5484d; }
.fx-tile.hl2 { background: #fff; border: 2px solid #3b2fc9; } .fx-tile.hl2 .v { color: #3b2fc9; }
.fx-sec { border-width: 2px; border-radius: 14px; box-shadow: 0 6px 22px rgba(59,47,201,.07); }
.fx-sec.pb { border-color: #ff6b4a; } .fx-sec.pb .fx-sec-h { background: linear-gradient(90deg, #ff6b4a, #ff9a5a); }
.fx-sec.mn { border-color: #3b2fc9; } .fx-sec.mn .fx-sec-h { background: linear-gradient(90deg, #3b2fc9, #6b4dff); }
.fx-sec.mn .fx-tile { background: #fff; } .fx-sec.mn .fx-tile.alert { background: linear-gradient(135deg, #3b2fc9, #6b4dff); }
.fx-sec.pb .fx-tile.alert { background: linear-gradient(135deg, #ff6b4a, #ff9a5a); }
.fx-t th { background: #1d1846; border-bottom-color: #ff6b4a; }
.fx-sec.pb .fx-app td { background: #fff8f5; }
.fx-app:hover td { background: #f6f3ff !important; } .fx-app.open td { background: #efeaff !important; }
.fx-chev { background: #ff6b4a; } .fx-sec.mn .fx-chev { background: #3b2fc9; }
.fx-detail { border-left-color: #ff6b4a; } .fx-sec.mn .fx-detail { border-left-color: #3b2fc9; }
.fx-t.inner th { background: #4a4670; }
.fx-pb.con { background: #fff1ec; border-color: #ffc2b2; } .fx-pb.con .fx-bar span { background: #ff6b4a !important; } .fx-pb.con b { color: #e5484d; }
.fx-pb.ovr { background: #efecff; border-color: #c3b8ff; } .fx-pb.ovr .fx-bar span { background: #3b2fc9 !important; } .fx-pb.ovr b { color: #3b2fc9; }
.fx-bar { background: #eeecf8; }
.fx-hb .fx-bar span { background: #3b2fc9; } .fx-hb .fx-bar.c span { background: #ff6b4a; }
.fx-leg i.n { background: #3b2fc9; } .fx-leg i.c { background: #ff6b4a; }
.fx-card { border-color: #e7e4f5; border-radius: 14px; box-shadow: 0 6px 22px rgba(59,47,201,.06); }
.fx-stagebar { border-color: #e7e4f5; border-radius: 12px; }
.fx-stagebar .sb.o { background: #3b2fc9; }
.fx-urg { background: #ff6b4a; }
.fx-note { color: #8580a8; }
.fx-tile .v { font-size: 26px; overflow-wrap: anywhere; } .fx-sec .fx-tile .v { font-size: 24px; }

/* Stage dropdowns in application detail (v11) */
.fx-sg-h { width: 100%; display: flex; align-items: center; gap: 10px; text-align: left; font: inherit; border: 1px solid #e7e4f5; background: #faf9ff; border-radius: 10px; padding: 10px 12px; margin-top: 8px; cursor: pointer; color: #1d1846; }
.fx-sg-h:hover { background: #f3f0ff; } .fx-sg-h.on { border-bottom-left-radius: 0; border-bottom-right-radius: 0; }
.fx-sg-h .ar { width: 14px; color: #6b6790; } .fx-sg-h .no { width: 24px; height: 24px; border-radius: 50%; display: grid; place-items: center; color: #fff; font-weight: 800; font-size: 12px; }
.fx-sg-h.c .no { background: #ff6b4a; } .fx-sg-h.m .no { background: #e0a100; } .fx-sg-h.i .no { background: #7d5bd6; }
.fx-sg-h.c { border-left: 4px solid #ff6b4a; } .fx-sg-h.m { border-left: 4px solid #e0a100; } .fx-sg-h.i { border-left: 4px solid #7d5bd6; }
.fx-sg-h small { color: #8580a8; } .fx-sg-h .st { margin-left: auto; font-size: 12.5px; }
.fx-sg-b { border: 1px solid #e7e4f5; border-top: 0; border-radius: 0 0 10px 10px; padding: 10px 12px; background: #fff; display: flex; flex-wrap: wrap; gap: 12px; align-items: center; }
.fx-sg-b .fx-t { width: 100%; }
.fx-kv { display: flex; flex-direction: column; gap: 3px; background: #faf9ff; border: 1px solid #eeecf8; border-radius: 8px; padding: 8px 12px; min-width: 170px; }
.fx-kv span { font-size: 10.5px; text-transform: uppercase; letter-spacing: .4px; color: #8580a8; font-weight: 700; } .fx-kv.wide { flex: 1 1 320px; }
.fx-meta-act select { padding: 4px 8px; font-size: 12.5px; }
.empty-state { text-align: center; padding: 60px 20px; } .empty-state .es-ic { font-size: 40px; } .empty-state h3 { margin: 10px 0 6px; }
.fx-kv .fx-pill { align-self: flex-start; }

/* Edit mode (v13) */
.fx-edit-tg { font: inherit; font-size: 12.5px; font-weight: 700; border: 1.5px solid #3b2fc9; color: #3b2fc9; background: #fff; border-radius: 99px; padding: 5px 14px; cursor: pointer; margin-left: 8px; }
.fx-edit-tg.on { background: #3b2fc9; color: #fff; }
.fx-editbar { margin: 12px 28px 0; background: #fff8e6; border: 1.5px dashed #f0b429; border-radius: 10px; padding: 10px 14px; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; font-size: 13px; color: #6b4c00; font-weight: 600; }
.fx-in { font: inherit; font-size: 12.5px; padding: 6px 8px; border: 1.5px solid #ddd8f3; border-radius: 7px; width: 100%; min-width: 110px; background: #fff; }
.fx-in:focus { border-color: #6b4dff; box-shadow: 0 0 0 3px rgba(107,77,255,.15); outline: none; }
.fx-in.sm { margin-top: 4px; font-size: 11.5px; padding: 4px 6px; }
.fx-t tr.ed td { background: #fffdf5; }
.fx-acts { white-space: nowrap; } .fx-acts .btn { margin: 2px; }
.btn.link.red { color: #e5484d; }
label.check.tiny { font-size: 11.5px; margin-top: 4px; flex-direction: row; }
@media (max-width: 900px) { .fx-editbar { margin: 12px; } }
.fx-search { font: inherit; font-size: 13px; padding: 7px 12px; border: 1.5px solid #c9c2f2; border-radius: 99px; min-width: 330px; background: #fff; }
.fx-search:focus { outline: none; border-color: #6b4dff; box-shadow: 0 0 0 3px rgba(107,77,255,.15); }
.fx-t tr.hit td { background: #fff3c4 !important; }
@media (max-width: 900px) { .fx-search { min-width: 0; width: 100%; margin: 6px 0; } }
.b-approved-with-condition, .p-approved-with-condition { background: #e6f4d7; color: #3f6b12; }
