:root {
  --ink: #102f36;
  --deep: #092f36;
  --deep-soft: #123e46;
  --gold: #e0aa31;
  --gold-soft: #fff5dc;
  --paper: #f6f3ec;
  --line: #e6dfd2;
  --muted: #748287;
  --green: #247a4b;
  --green-soft: #eaf6ee;
  --orange: #a96b17;
  --orange-soft: #fff3df;
  --red: #a13d34;
  --red-soft: #fcecea;
  --shadow: 0 14px 34px rgba(16, 47, 54, 0.055);
}

* { box-sizing: border-box; }
html, body { min-height: 100%; }
body { margin: 0; font-family: "DM Sans", sans-serif; color: var(--ink); background: var(--paper); }
button, input, select, textarea { font: inherit; }
button { color: inherit; }
.hidden { display: none !important; }
.eyebrow { margin: 0; color: #9b741f; font-size: 9px; font-weight: 800; letter-spacing: .14em; text-transform: uppercase; }
.muted { color: var(--muted); line-height: 1.65; }
.error { margin: 0; color: var(--red); font-size: 11px; font-weight: 700; }
code { font-family: ui-monospace, SFMono-Regular, Menlo, monospace; }

.primary, .secondary, .manage, .text-button, .icon-button {
  border-radius: 11px;
  font-weight: 800;
  cursor: pointer;
  transition: .18s ease;
}
.primary { height: 44px; border: 0; padding: 0 18px; background: var(--deep); color: white; box-shadow: 0 8px 18px rgba(9, 47, 54, .12); }
.primary:hover { background: #124650; transform: translateY(-1px); }
.secondary { min-height: 40px; border: 1px solid var(--line); padding: 0 15px; background: white; color: var(--ink); }
.secondary:hover, .manage:hover { border-color: #cdbf9f; background: #fffdf8; }
button:disabled { cursor: not-allowed; opacity: .45; transform: none !important; }

/* Authentication */
.mark { display: grid; width: 54px; height: 54px; place-items: center; border-radius: 16px; background: var(--gold); color: var(--deep); font: 800 26px Manrope; box-shadow: 0 12px 28px rgba(224, 170, 49, .25); }
.mark.small { width: 40px; height: 40px; border-radius: 12px; font-size: 18px; box-shadow: none; }
.login-page { min-height: 100vh; display: grid; grid-template-columns: minmax(430px, 42%) 1fr; background: white; }
.login-card { display: flex; max-width: 650px; flex-direction: column; justify-content: center; padding: clamp(45px, 8vw, 120px); }
.login-card > .eyebrow { margin-top: 28px; }
.login-card h1 { margin: 8px 0 12px; font: 800 clamp(34px, 4vw, 50px)/1.05 Manrope; letter-spacing: -.04em; }
.login-card form { display: grid; gap: 16px; margin-top: 26px; }
.login-fields { display: grid; gap: 16px; }
.login-card label, .form-grid label { color: #4d6368; font-size: 10px; font-weight: 800; }
.login-card input, .form-grid input, .form-grid select {
  display: block; width: 100%; height: 46px; margin-top: 7px; border: 1px solid var(--line); border-radius: 11px; padding: 0 13px; background: #fdfcf9; color: var(--ink); outline: none; transition: .18s;
}
.login-card input:focus, .form-grid input:focus, .form-grid select:focus { border-color: var(--gold); background: white; box-shadow: 0 0 0 3px rgba(224, 170, 49, .12); }
.demo { margin-top: 17px; color: #938f86; font-size: 10px; }
.demo code { padding: 2px 4px; border-radius: 4px; background: #f6f3ec; color: #615d54; }
.forgot-password { align-self: flex-start; margin-top: 11px; padding: 0; }
.sso-login { display: grid; gap: 9px; margin-top: 14px; text-align: center; }
.sso-login span { display: flex; align-items: center; gap: 9px; color: var(--muted); font-size: 8px; text-transform: uppercase; }
.sso-login span::before, .sso-login span::after { height: 1px; flex: 1; background: var(--line); content: ""; }
.sso-login button { width: 100%; }
.mfa-login { border: 1px solid #dfe9e6; border-radius: 15px; padding: 15px; background: #f8fcfa; }
.mfa-login-heading { display: flex; align-items: center; gap: 11px; }
.mfa-login-heading b, .mfa-login-heading small { display: block; }
.mfa-login-heading b { font: 800 11px Manrope; }
.mfa-login-heading small { margin-top: 3px; color: var(--muted); font-size: 8.5px; line-height: 1.5; }
.security-icon { display: grid; width: 32px; height: 32px; flex: none; place-items: center; border-radius: 10px; background: var(--green-soft); color: var(--green); font-size: 13px; font-weight: 900; }
.security-icon.large { width: 47px; height: 47px; border-radius: 13px; font-size: 18px; }
.login-back { justify-self: start; padding: 0; }
.login-visual { position: relative; display: flex; overflow: hidden; flex-direction: column; justify-content: center; padding: clamp(65px, 9vw, 145px); background: linear-gradient(145deg, #06282f, #0d444c); color: white; }
.login-visual::after { position: absolute; top: -140px; right: -110px; width: 500px; height: 500px; border: 1px solid rgba(255,255,255,.08); border-radius: 50%; box-shadow: 0 0 0 90px rgba(255,255,255,.025), 0 0 0 180px rgba(255,255,255,.018); content: ""; }
.login-visual h2 { z-index: 1; max-width: 680px; margin: 26px 0 0; font: 700 clamp(38px, 5vw, 66px)/1.08 Manrope; letter-spacing: -.035em; }
.pill { z-index: 1; align-self: flex-start; border: 1px solid rgba(255,255,255,.15); border-radius: 99px; padding: 8px 13px; color: #c0d0d3; font-size: 10px; }
.preview { z-index: 1; width: min(420px, 100%); margin-top: 48px; border: 1px solid rgba(255,255,255,.1); border-radius: 18px; padding: 22px; background: rgba(255,255,255,.045); backdrop-filter: blur(8px); }
.preview span, .preview small { color: #a6bcc0; font-size: 10px; }
.preview strong { display: block; margin: 8px 0 13px; font: 800 36px Manrope; color: white; }
.preview small { display: block; margin-top: 10px; }
.bar { height: 6px; border-radius: 8px; background: rgba(255,255,255,.09); }
.bar i { display: block; width: 92%; height: 100%; border-radius: inherit; background: var(--gold); }

/* Shell */
.app { display: flex; overflow: hidden; height: 100vh; }
.sidebar { z-index: 20; display: flex; width: 256px; flex: none; flex-direction: column; padding: 17px 13px 13px; background: #072c33; color: white; }
.brand { display: flex; align-items: center; gap: 11px; padding: 0 4px 18px; border-bottom: 1px solid rgba(255,255,255,.07); }
.brand b { font: 800 15px Manrope; }
.brand span { display: block; margin-top: 2px; color: #7f999f; font-size: 8px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; }
.nav-close { display: none; margin-left: auto; border: 0; background: none; color: #9db2b7; font-size: 23px; }
.sidebar nav { min-height: 0; flex: 1; overflow-y: auto; padding: 8px 0; }
.sidebar nav > p { margin: 16px 9px 7px; color: #607e85; font-size: 8px; font-weight: 800; letter-spacing: .16em; }
.nav-link { display: flex; width: 100%; height: 41px; align-items: center; gap: 10px; margin: 2px 0; border: 0; border-radius: 10px; padding: 0 10px; background: transparent; color: #94acb1; text-align: left; cursor: pointer; transition: .16s; }
.nav-link > span { display: grid; width: 25px; height: 25px; place-items: center; border-radius: 7px; background: rgba(255,255,255,.035); color: var(--gold); font-size: 14px; }
.nav-link b { min-width: 0; flex: 1; font-size: 10.5px; }
.nav-link em { min-width: 18px; border-radius: 99px; padding: 2px 5px; background: rgba(255,255,255,.06); color: #7f999f; font: 700 7.5px ui-monospace, monospace; text-align: center; }
.nav-link:hover { background: rgba(255,255,255,.045); color: white; }
.nav-link.active { background: rgba(255,255,255,.09); color: white; box-shadow: inset 3px 0 0 var(--gold); }
.nav-link.active > span { background: var(--gold); color: var(--deep); }
.operator { display: flex; align-items: center; gap: 9px; border-radius: 12px; padding: 8px; background: rgba(255,255,255,.055); }
.operator > span { display: grid; width: 36px; height: 36px; flex: none; place-items: center; border-radius: 9px; background: var(--gold); color: var(--deep); font: 800 12px Manrope; }
.operator div { min-width: 0; flex: 1; }
.operator b, .operator small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.operator b { font-size: 10px; }
.operator small { margin-top: 2px; color: #829da3; font-size: 8.5px; }
.operator button { width: 31px; height: 31px; border: 1px solid rgba(255,255,255,.07); border-radius: 8px; background: rgba(255,255,255,.035); color: #94acb1; cursor: pointer; }
.content { display: flex; min-width: 0; flex: 1; flex-direction: column; }
.topbar { display: flex; height: 72px; flex: none; align-items: center; justify-content: space-between; border-bottom: 1px solid var(--line); padding: 0 26px; background: rgba(255,255,255,.94); }
.topbar-title h1 { margin: 2px 0 0; font: 800 20px Manrope; letter-spacing: -.025em; }
.topbar-actions { display: flex; align-items: center; gap: 9px; }
.health { border-radius: 99px; padding: 9px 13px; background: var(--green-soft); color: var(--green); font-size: 9.5px; font-weight: 800; }
.health i { display: inline-block; width: 6px; height: 6px; margin-right: 6px; border-radius: 50%; background: #37aa68; box-shadow: 0 0 0 3px rgba(55,170,104,.1); }
.icon-button { display: grid; width: 36px; height: 36px; place-items: center; border: 1px solid var(--line); background: white; font-size: 18px; }
.icon-button:hover { transform: rotate(25deg); border-color: #cdbf9f; }
.mobile-nav { display: none; }
.page { min-height: 0; flex: 1; overflow-y: auto; padding: 25px; }
.view { max-width: 1500px; margin: 0 auto; animation: enter .25s ease both; }
@keyframes enter { from { opacity: 0; transform: translateY(5px); } to { opacity: 1; transform: none; } }

/* Shared page components */
.hero { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; }
.hero h2 { margin: 4px 0 4px; font: 800 27px Manrope; letter-spacing: -.03em; }
.hero p:not(.eyebrow) { margin: 0; color: var(--muted); font-size: 11px; }
.hero-actions { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 8px; }
.dashboard-hero { align-items: flex-end; }
.updated { color: #938f86; font-size: 9px; }
.metrics { display: grid; grid-template-columns: repeat(4, 1fr); gap: 12px; margin: 20px 0; }
.metric { position: relative; overflow: hidden; min-height: 112px; border: 1px solid var(--line); border-radius: 15px; padding: 17px; background: white; box-shadow: var(--shadow); }
.metric::after { position: absolute; right: -20px; bottom: -26px; width: 78px; height: 78px; border: 14px solid rgba(9,47,54,.025); border-radius: 50%; content: ""; }
.metric > span { color: #8d8980; font-size: 8px; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; }
.metric strong { display: block; margin-top: 8px; font: 800 24px Manrope; letter-spacing: -.03em; }
.metric small { display: block; margin-top: 4px; color: #899397; font-size: 8.5px; }
.metric.gold strong { color: #a6750d; }
.metric.green strong { color: var(--green); }
.metric.red strong { color: var(--red); }
.compact-metrics .metric { min-height: 96px; }
.compact-metrics .metric strong { font-size: 21px; }
.panel { overflow: hidden; border: 1px solid var(--line); border-radius: 16px; background: white; box-shadow: var(--shadow); }
.panel > header { display: flex; min-height: 65px; align-items: center; justify-content: space-between; border-bottom: 1px solid #eee8dd; padding: 13px 17px; }
.panel h3 { margin: 3px 0 0; font: 800 15px Manrope; }
.panel-actions { display: flex; align-items: center; gap: 9px; }
.counter { display: grid; min-width: 25px; height: 25px; place-items: center; border-radius: 99px; background: var(--gold-soft); color: #92670c; font: 800 9px ui-monospace, monospace; }
.text-button { border: 0; background: none; color: #906a18; font-size: 9px; }
.empty-state { display: flex; min-height: 130px; align-items: center; justify-content: center; flex-direction: column; gap: 5px; padding: 20px; color: var(--muted); text-align: center; }
.empty-state b { color: var(--ink); font-size: 11px; }
.empty-state span { font-size: 9px; }
.empty-state.wide { grid-column: 1 / -1; border: 1px dashed #d8cebb; border-radius: 15px; background: rgba(255,255,255,.55); }

/* Dashboard */
.dashboard-grid { display: grid; grid-template-columns: .85fr 1.15fr; gap: 13px; }
.alert-list, .health-list { padding: 7px 16px; }
.alert-row { display: flex; width: 100%; align-items: center; gap: 10px; border: 0; border-bottom: 1px solid #f0ebe2; padding: 11px 0; background: none; text-align: left; cursor: pointer; }
.alert-row:last-child { border-bottom: 0; }
.alert-icon { display: grid; width: 30px; height: 30px; flex: none; place-items: center; border-radius: 9px; font-weight: 800; }
.alert-row.critical .alert-icon { background: var(--red-soft); color: var(--red); }
.alert-row.warning .alert-icon { background: var(--orange-soft); color: var(--orange); }
.alert-row > span:nth-child(2) { min-width: 0; flex: 1; }
.alert-row b, .alert-row small { display: block; }
.alert-row b { font-size: 10px; }
.alert-row small { margin-top: 2px; color: var(--muted); font-size: 8.5px; }
.alert-row em { color: #98721e; font-size: 8px; font-style: normal; font-weight: 800; }
.health-row { display: flex; align-items: center; gap: 10px; border-bottom: 1px solid #f0ebe2; padding: 9px 0; }
.health-row:last-child { border-bottom: 0; }
.tenant-avatar { display: grid; width: 31px; height: 31px; flex: none; place-items: center; border-radius: 9px; background: #edf3f4; font: 800 9px Manrope; }
.tenant-name { min-width: 0; flex: 1; }
.tenant-name b, .tenant-name small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.tenant-name b { font-size: 9.5px; }
.tenant-name small { margin-top: 2px; color: var(--muted); font-size: 8px; }
.health-status { display: flex; align-items: center; gap: 5px; border-radius: 99px; padding: 5px 7px; font-size: 7.5px; font-weight: 800; }
.health-status i { width: 5px; height: 5px; border-radius: 50%; background: currentColor; }
.health-status.healthy { background: var(--green-soft); color: var(--green); }
.health-status.warning { background: var(--orange-soft); color: var(--orange); }
.health-status.critical { background: var(--red-soft); color: var(--red); }

/* Analytics */
.analytics-actions { align-items: flex-end; }
.analytics-actions label { color: var(--muted); font-size: 8px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.analytics-actions select { display: block; height: 40px; margin-top: 5px; border: 1px solid var(--line); border-radius: 10px; padding: 0 34px 0 12px; background: white; color: var(--ink); font-size: 9.5px; font-weight: 700; }
.analytics-metrics { grid-template-columns: repeat(3, 1fr); }
.analytics-chart-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 13px; margin-bottom: 13px; }
.analytics-insight-grid { display: grid; grid-template-columns: .85fr 1.15fr; gap: 13px; margin-bottom: 13px; }
.analytics-panel { min-width: 0; }
.chart-legend { display: flex; align-items: center; gap: 6px; color: var(--muted); font-size: 7.5px; }
.chart-legend i { width: 7px; height: 7px; border-radius: 2px; }
.chart-legend .invoiced { background: #d8c69f; }
.chart-legend .collected { background: var(--deep); }
.chart-area { position: relative; display: flex; min-height: 245px; padding: 22px 18px 15px 48px; background: linear-gradient(to bottom, transparent 24%, #f1ece3 25%, transparent 25.5%, transparent 49%, #f1ece3 50%, transparent 50.5%, transparent 74%, #f1ece3 75%, transparent 75.5%); }
.chart-scale { position: absolute; top: 21px; bottom: 45px; left: 14px; display: flex; flex-direction: column; justify-content: space-between; color: #9a9b94; font-size: 7px; }
.chart-columns { display: flex; min-width: 0; flex: 1; align-items: flex-end; justify-content: space-around; gap: 7px; }
.chart-column { display: grid; min-width: 0; height: 205px; flex: 1; grid-template-rows: 1fr 14px 16px; align-items: end; text-align: center; }
.chart-track { position: relative; width: min(28px, 75%); height: 160px; align-self: end; justify-self: center; border-radius: 6px 6px 3px 3px; background: #f1eee8; }
.chart-track i { position: absolute; right: 0; bottom: 0; left: 0; height: var(--metric-percent, 0%); border-radius: inherit; background: linear-gradient(180deg, #e6b64c, #cc9217); }
.chart-column b { overflow: hidden; color: #52696e; font-size: 7px; text-overflow: ellipsis; white-space: nowrap; }
.chart-column > span { color: #8e9695; font-size: 7px; text-transform: capitalize; white-space: nowrap; }
.chart-pair { display: flex; width: min(45px, 92%); height: 160px; align-items: flex-end; justify-self: center; gap: 3px; }
.chart-pair i { width: 50%; height: var(--metric-percent, 0%); min-height: 0; border-radius: 5px 5px 2px 2px; }
.chart-pair .invoiced { background: #d8c69f; }
.chart-pair .collected { background: linear-gradient(180deg, #165560, var(--deep)); }
.financial-activity-panel { margin-bottom: 13px; }
.financial-activity-panel > header { border-bottom: 1px solid var(--line); }
.financial-activity-panel > footer { border-top: 1px solid var(--line); padding: 10px 18px; color: var(--muted); font-size: 7.5px; line-height: 1.5; }
.financial-activity-layout { display: grid; grid-template-columns: minmax(300px,.8fr) minmax(0,1.2fr); align-items: stretch; }
.financial-activity-layout > div { min-width: 0; }
.financial-activity-layout > div + div { border-left: 1px solid var(--line); }
.financial-chart-title { margin: 15px 18px 0; color: var(--muted); font-size: 8px; font-weight: 800; letter-spacing: .06em; text-transform: uppercase; }
.financial-breakdown { display: grid; align-content: center; gap: 14px; padding: 22px; }
.financial-row > div:first-child { display: flex; align-items: baseline; justify-content: space-between; gap: 12px; }
.financial-row > div:first-child span { display: flex; align-items: center; gap: 7px; color: #53696e; font-size: 8px; font-weight: 700; }
.financial-row > div:first-child span i { width: 7px; height: 7px; border-radius: 2px; }
.financial-row > div:first-child b { font-size: 9px; }
.financial-row > small { display: block; margin-top: 4px; color: var(--muted); font-size: 7px; }
.financial-track { height: 6px; margin-top: 7px; overflow: hidden; border-radius: 99px; background: #edf0ee; }
.financial-track i { display: block; width: var(--metric-percent, 0%); height: 100%; min-width: 0; border-radius: inherit; }
.financial-row i.deposits { background: #207756; }.financial-row i.withdrawals { background: #d36d58; }.financial-row i.collections { background: #d9a12b; }.financial-row i.local { background: #2c7380; }.financial-row i.international { background: #765b9b; }
.financial-chart { min-height: 225px; padding-top: 10px; }
.financial-chart .chart-scale { top: 10px; }.financial-chart .chart-column { height: 190px; }.financial-chart .chart-track { height: 148px; }
.financial-chart .chart-track .financial-volume-bar { background: linear-gradient(180deg,#2b7b83,var(--deep)); }
.plan-analytics { display: grid; min-height: 230px; grid-template-columns: 150px minmax(0, 1fr); align-items: center; gap: 25px; padding: 22px; }
.donut { display: grid; width: 145px; height: 145px; place-items: center; border-radius: 50%; }
.donut svg { grid-area: 1 / 1; width: 100%; height: 100%; transform: rotate(-90deg); }
.donut circle { fill: none; stroke-width: 16; }
.donut .plan-base { stroke: #edf0ee; }
.donut circle.plan-color-0 { stroke: #0b3f47; }.donut circle.plan-color-1 { stroke: #e1aa31; }.donut circle.plan-color-2 { stroke: #4d8b6b; }
.donut span { z-index: 1; grid-area: 1 / 1; text-align: center; }
.donut b,.donut small { display: block; }.donut b { font: 800 24px Manrope; }.donut small { color: var(--muted); font-size: 8px; }
.analytics-legend { display: grid; gap: 12px; }
.analytics-legend > div { display: grid; grid-template-columns: 9px 1fr; align-items: start; gap: 8px; }
.analytics-legend i { width: 9px; height: 9px; margin-top: 2px; border-radius: 3px; }
.analytics-legend .plan-color-0 { background: #0b3f47; }.analytics-legend .plan-color-1 { background: #e1aa31; }.analytics-legend .plan-color-2 { background: #4d8b6b; }
.analytics-legend b,.analytics-legend small { display: block; }.analytics-legend b { font-size: 9px; }.analytics-legend small { margin-top: 2px; color: var(--muted); font-size: 7.5px; line-height: 1.45; }
.module-analytics { display: grid; gap: 11px; padding: 18px; }
.adoption-row { display: grid; grid-template-columns: 105px minmax(70px,1fr) 38px; align-items: center; gap: 10px; }
.adoption-row > div:first-child b,.adoption-row > div:first-child span { display: block; }.adoption-row > div:first-child b { font-size: 8.5px; }.adoption-row > div:first-child span { margin-top: 2px; color: var(--muted); font-size: 7px; }
.adoption-track { height: 7px; overflow: hidden; border-radius: 99px; background: #edf0ee; }.adoption-track i { display: block; width: var(--metric-percent, 0%); height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--deep), #2d7078); }
.adoption-row strong { font-size: 8px; text-align: right; }
.analytics-tenants { margin-bottom: 18px; }
.tenant-usage { display: flex; align-items: center; gap: 7px; }.tenant-usage > div { width: 70px; height: 6px; overflow: hidden; border-radius: 99px; background: #edf0ee; }.tenant-usage i { display: block; width: var(--metric-percent, 0%); height: 100%; border-radius: inherit; background: var(--gold); }.tenant-usage span { color: var(--muted); font-size: 7.5px; }

.metric-pct-0 { --metric-percent: 0%; }.metric-pct-5 { --metric-percent: 5%; }.metric-pct-10 { --metric-percent: 10%; }.metric-pct-15 { --metric-percent: 15%; }.metric-pct-20 { --metric-percent: 20%; }.metric-pct-25 { --metric-percent: 25%; }.metric-pct-30 { --metric-percent: 30%; }.metric-pct-35 { --metric-percent: 35%; }.metric-pct-40 { --metric-percent: 40%; }.metric-pct-45 { --metric-percent: 45%; }.metric-pct-50 { --metric-percent: 50%; }.metric-pct-55 { --metric-percent: 55%; }.metric-pct-60 { --metric-percent: 60%; }.metric-pct-65 { --metric-percent: 65%; }.metric-pct-70 { --metric-percent: 70%; }.metric-pct-75 { --metric-percent: 75%; }.metric-pct-80 { --metric-percent: 80%; }.metric-pct-85 { --metric-percent: 85%; }.metric-pct-90 { --metric-percent: 90%; }.metric-pct-95 { --metric-percent: 95%; }.metric-pct-100 { --metric-percent: 100%; }

/* Clients */
.toolbar { display: flex; flex-wrap: wrap; gap: 9px; margin-top: 14px; border: 1px solid var(--line); border-radius: 14px; padding: 10px; background: white; box-shadow: var(--shadow); }
.advanced-toolbar .search-field { min-width: 320px; }
.toolbar input, .toolbar select { height: 39px; border: 1px solid var(--line); border-radius: 9px; padding: 0 11px; background: #fdfcf9; color: var(--ink); font-size: 9.5px; outline: none; }
.toolbar input:focus, .toolbar select:focus { border-color: var(--gold); background: white; box-shadow: 0 0 0 3px rgba(224,170,49,.1); }
.toolbar select { width: 160px; }
.search-field { position: relative; flex: 1; }
.search-field span { position: absolute; top: 10px; left: 11px; color: #8f918c; }
.search-field input { width: 100%; padding-left: 31px; }
.clients { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); gap: 12px; margin-top: 13px; }
.client-card { display: flex; min-width: 0; flex-direction: column; border: 1px solid var(--line); border-radius: 16px; padding: 16px; background: white; box-shadow: var(--shadow); }
.client-head { display: flex; align-items: flex-start; gap: 10px; }
.avatar { display: grid; width: 39px; height: 39px; flex: none; place-items: center; border-radius: 11px; background: #eaf1f2; font: 800 11px Manrope; }
.client-head > div { min-width: 0; flex: 1; }
.client-head h3 { overflow: hidden; margin: 1px 0 3px; font: 800 13px Manrope; text-overflow: ellipsis; white-space: nowrap; }
.client-head p { margin: 0; color: #8a877f; font-size: 8.5px; }
.badge { display: inline-flex; align-items: center; border-radius: 99px; padding: 4px 7px; font-size: 7px; font-weight: 800; text-transform: uppercase; }
.active-badge { background: var(--green-soft); color: var(--green); }
.trial-badge, .invited-badge, .pending-badge { background: var(--orange-soft); color: var(--orange); }
.suspended-badge, .disabled-badge, .overdue-badge { background: var(--red-soft); color: var(--red); }
.paid-badge { background: var(--green-soft); color: var(--green); }
.cancelled-badge { background: #f0efec; color: #77736b; }
.usage { margin: 15px 0 12px; border-radius: 11px; padding: 10px; background: #f8f6f1; }
.usage > div:first-child { display: flex; justify-content: space-between; font-size: 8px; }
.usage b { font: 800 10px Manrope; }
.progress { overflow: hidden; height: 5px; margin: 8px 0 6px; border-radius: 5px; background: #e9e3d8; }
.progress i { display: block; width: var(--metric-percent, 0%); height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--gold), #c88719); }
.usage small { color: #8b8b83; font-size: 7.5px; }
.tags { display: flex; min-height: 25px; flex-wrap: wrap; gap: 4px; }
.tags span { border-radius: 99px; padding: 4px 7px; background: #edf3f4; color: var(--deep); font-size: 7px; font-weight: 700; }
.tags b { color: #73898e; font-size: 6.5px; }
.contract-summary { display: grid; grid-template-columns: 1fr 1fr; gap: 7px; margin-top: 10px; }
.contract-summary > span { min-width: 0; border-radius: 9px; padding: 8px 9px; background: #f8f6f1; }
.contract-summary small, .contract-summary b { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.contract-summary small { color: var(--muted); font-size: 6.5px; text-transform: uppercase; }
.contract-summary b { margin-top: 3px; color: var(--ink); font-size: 7.5px; }
.provisioning-status { display: flex; align-items: center; gap: 7px; margin-top: 10px; border-radius: 9px; padding: 7px 9px; }
.provisioning-status > i { width: 7px; height: 7px; flex: none; border-radius: 50%; background: currentColor; }
.provisioning-status b, .provisioning-status small { display: block; }
.provisioning-status b { font-size: 7.5px; }
.provisioning-status small { overflow: hidden; max-width: 230px; margin-top: 1px; font-size: 6.7px; text-overflow: ellipsis; white-space: nowrap; opacity: .72; }
.provisioning-status.synced { background: var(--green-soft); color: var(--green); }
.provisioning-status.failed { background: var(--red-soft); color: var(--red); }
.provisioning-status.pending { background: var(--orange-soft); color: var(--orange); }
.client-contact { display: flex; align-items: flex-end; justify-content: space-between; gap: 8px; margin-top: 13px; border-top: 1px solid #eee9df; padding-top: 11px; }
.client-contact > span { min-width: 0; }
.client-contact b, .client-contact small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.client-contact b { font-size: 8.5px; }
.client-contact small { margin-top: 2px; color: #89867e; font-size: 7.5px; }
.client-contact .expiry { flex: none; text-align: right; }
.client-card footer { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 11px; }
.manage { min-height: 30px; border: 1px solid var(--line); padding: 0 9px; background: white; font-size: 8px; }
.manage.core-sync { border-color: #b9d3d3; color: #176368; }
.danger-link { margin-left: auto; border: 0; background: none; color: var(--red); font-size: 8px; font-weight: 800; cursor: pointer; }
.pagination { display: flex; align-items: center; justify-content: space-between; margin-top: 13px; color: var(--muted); font-size: 8.5px; }
.pagination > div { display: flex; gap: 7px; }
.pagination .secondary { min-height: 33px; font-size: 8.5px; }

/* Plans */
.plan-grid { display: grid; grid-template-columns: repeat(3, 1fr); gap: 13px; margin-top: 20px; }
.plan-card { position: relative; overflow: hidden; border: 1px solid var(--line); border-radius: 17px; padding: 20px; background: white; box-shadow: var(--shadow); }
.plan-card.featured { border-color: #d9b45b; box-shadow: 0 18px 40px rgba(165,119,22,.11); }
.recommended { position: absolute; top: 15px; right: 15px; border-radius: 99px; padding: 5px 8px; background: var(--gold-soft); color: #92670c; font-size: 7px; font-weight: 800; }
.plan-card h3 { margin: 5px 0 12px; font: 800 19px Manrope; }
.price { min-height: 35px; font: 800 20px Manrope; color: var(--deep); }
.price small { color: var(--muted); font: 600 8px "DM Sans"; }
.plan-card ul { display: grid; gap: 9px; margin: 16px 0; border-top: 1px solid #eee8dd; padding: 16px 0 0; color: var(--muted); font-size: 9px; list-style: none; }
.plan-card li::before { margin-right: 7px; color: var(--green); content: "✓"; font-weight: 800; }
.plan-card .secondary { width: 100%; font-size: 9px; }
.module-panel { margin-top: 13px; }
.module-catalog { display: grid; grid-template-columns: repeat(2, 1fr); gap: 0 14px; padding: 7px 17px; }
.module-catalog article { display: flex; align-items: center; gap: 9px; border-bottom: 1px solid #f0ebe2; padding: 10px 0; }
.module-symbol { display: grid; width: 29px; height: 29px; flex: none; place-items: center; border-radius: 8px; background: #edf3f4; font: 800 9px Manrope; }
.module-catalog article > span:nth-child(2) { min-width: 0; flex: 1; }
.module-catalog b, .module-catalog small { display: block; }
.module-catalog b { font-size: 9.5px; }
.module-catalog small { margin-top: 2px; color: var(--muted); font-size: 7.5px; }
.module-catalog em { color: #9b741f; font-size: 7px; font-style: normal; font-weight: 700; }

/* Monitoring */
.service-banner { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 17px; border: 1px solid #cde4d5; border-radius: 13px; padding: 11px 14px; background: var(--green-soft); color: var(--green); }
.service-banner.down { border-color: #efcbc7; background: var(--red-soft); color: var(--red); }
.service-banner span { display: flex; align-items: center; gap: 7px; }
.service-banner i, .connectivity i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }
.service-banner b { font-size: 9.5px; }
.service-banner small { font-size: 8px; }
.monitoring-grid { display: grid; grid-template-columns: minmax(0, 1.45fr) minmax(310px, .55fr); gap: 13px; }
.monitoring-grid .table-panel { margin-top: 0; }
.connectivity { display: inline-flex; align-items: center; gap: 5px; border-radius: 99px; padding: 5px 7px; font-size: 7px; font-weight: 800; }
.connectivity.up { background: var(--green-soft); color: var(--green); }
.connectivity.suspended { background: var(--red-soft); color: var(--red); }
.connectivity.not_provisioned { background: var(--orange-soft); color: var(--orange); }
.incident-list { max-height: 480px; overflow-y: auto; padding: 5px 15px; }
.incident-row { border-bottom: 1px solid #eee8dd; padding: 12px 0; }
.incident-row:last-child { border-bottom: 0; }
.incident-row > div { display: grid; grid-template-columns: auto 1fr; align-items: center; gap: 5px 7px; }
.incident-row > div b { font-size: 9px; }
.incident-row > div small { grid-column: 2; color: var(--muted); font-size: 7px; }
.severity { grid-row: 1 / 3; border-radius: 6px; padding: 5px 6px; background: #f0efec; color: #77736b; font-size: 6.5px; font-weight: 800; }
.incident-row.major .severity { background: var(--orange-soft); color: var(--orange); }
.incident-row.critical .severity { background: var(--red-soft); color: var(--red); }
.incident-row p { margin: 9px 0; color: var(--muted); font-size: 8px; line-height: 1.5; }
.incident-row footer { display: flex; align-items: center; justify-content: space-between; gap: 8px; color: #827e75; font-size: 7px; }
.alert-delivery-panel { margin-top: 13px; }
.alert-delivery-panel .severity.warning { background: var(--orange-soft); color: var(--orange); }
.alert-delivery-panel .severity.critical { background: var(--red-soft); color: var(--red); }
.alert-delivery-panel .severity.info { background: #edf3f4; color: var(--deep); }

/* Operators and audit */
.account-security { display: grid; grid-template-columns: auto minmax(210px, 1fr) auto auto; align-items: center; gap: 14px; margin-top: 18px; padding: 16px; }
.account-security h3 { margin: 3px 0; font: 800 14px Manrope; }
.account-security p:not(.eyebrow) { margin: 0; color: var(--muted); font-size: 8.5px; }
.security-actions { display: flex; gap: 7px; }
.security-actions button { min-height: 38px; height: 38px; font-size: 8px; }
.danger-outline { border-color: #eccbc7; color: var(--red); }
.mfa-badge { display: inline-flex; align-items: center; gap: 5px; border-radius: 99px; padding: 5px 7px; background: #f0efec; color: #7d7a72; font-size: 7px; font-weight: 800; }
.mfa-badge.enabled { background: var(--green-soft); color: var(--green); }
.role-strip { display: flex; flex-wrap: wrap; gap: 6px; margin: 18px 0 12px; }
.role-strip span { border: 1px solid var(--line); border-radius: 99px; padding: 6px 9px; background: white; color: var(--muted); font-size: 7.5px; }
.role-strip b { margin-right: 4px; color: var(--deep); font-size: 7px; }
.table-panel { margin-top: 15px; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; text-align: left; }
th { padding: 11px 14px; background: #faf8f3; color: #8a877f; font-size: 7.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
td { border-top: 1px solid #eee8dd; padding: 12px 14px; color: #68777b; font-size: 8.5px; vertical-align: middle; }
td b { color: var(--ink); }
.cell-subtitle { display: block; margin-top: 3px; color: var(--muted); font-size: 7px; }
td.actions { text-align: right; }
.table-user { display: flex; min-width: 210px; align-items: center; gap: 9px; }
.table-user i { display: grid; width: 33px; height: 33px; flex: none; place-items: center; border-radius: 9px; background: var(--gold-soft); color: #92670c; font-style: normal; font-weight: 800; }
.table-user b, .table-user small { display: block; }
.table-user small { margin-top: 2px; color: var(--muted); font-size: 7.5px; }
.role-badge { border-radius: 6px; padding: 5px 7px; background: #edf3f4; color: var(--deep); font: 700 7px ui-monospace, monospace; }
.action-code { color: var(--deep); font: 700 7.5px ui-monospace, monospace; }
.detail-code { display: block; overflow: hidden; max-width: 280px; color: #69777a; font-size: 7px; text-overflow: ellipsis; white-space: nowrap; }
.integrity { border-radius: 99px; padding: 4px 6px; font-size: 7px; font-weight: 800; }
.integrity.verified { background: var(--green-soft); color: var(--green); }
.integrity.legacy { background: #f0efec; color: #827f77; }

/* Customer support */
.support-priority { display: inline-flex; border-radius: 99px; padding: 4px 7px; font-size: 7px; font-weight: 800; text-transform: uppercase; }
.support-priority.low { background: #edf3f4; color: #55737a; }
.support-priority.normal { background: var(--green-soft); color: var(--green); }
.support-priority.high { background: var(--orange-soft); color: var(--orange); }
.support-priority.urgent { background: var(--red-soft); color: var(--red); }
.support-dialog { width: min(760px, calc(100vw - 28px)); }
.support-request-summary { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; margin-top: 17px; }
.support-request-summary > div { border-radius: 10px; padding: 10px 12px; background: var(--paper); }
.support-request-summary span, .support-request-summary b { display: block; }
.support-request-summary span { color: var(--muted); font-size: 7px; text-transform: uppercase; }
.support-request-summary b { margin-top: 4px; font-size: 9px; }
.support-request-summary article { grid-column: 1 / -1; border: 1px solid var(--line); border-radius: 11px; padding: 13px; background: #fffdf9; }
.support-request-summary article b { font-size: 10px; }
.support-request-summary article p { margin: 7px 0 0; color: #5d7074; font-size: 9px; line-height: 1.65; white-space: pre-wrap; }
.support-conversation { border-top: 1px solid var(--line); padding-top: 15px; }
.support-conversation > div { display: grid; max-height: 220px; gap: 8px; overflow-y: auto; border-radius: 11px; padding: 11px; background: var(--paper); }
.support-conversation article { width: min(82%, 530px); border: 1px solid var(--line); border-radius: 10px; padding: 10px 12px; background: white; }
.support-conversation article.customer { justify-self: end; border-color: var(--deep); background: var(--deep); color: white; }
.support-conversation article > div { display: flex; justify-content: space-between; gap: 12px; font-size: 8px; }
.support-conversation article time { color: var(--muted); font-size: 7px; }
.support-conversation article.customer time { color: #9db3b7; }
.support-conversation article p { margin: 6px 0 0; font-size: 9px; line-height: 1.55; white-space: pre-wrap; }
.support-history { border-top: 1px solid var(--line); padding-top: 15px; }
.support-history > div { max-height: 145px; overflow-y: auto; }
.support-history > div > div { display: grid; grid-template-columns: 110px 120px 1fr; gap: 9px; border-bottom: 1px solid #f0ebe2; padding: 8px 0; font-size: 8px; }
.support-history span, .support-history small { color: var(--muted); }

/* Dialogs */
dialog { width: min(650px, calc(100vw - 28px)); max-height: calc(100vh - 35px); overflow-y: auto; border: 0; border-radius: 19px; padding: 0; color: var(--ink); box-shadow: 0 30px 90px rgba(9,44,51,.32); }
dialog::backdrop { background: rgba(6,42,50,.58); backdrop-filter: blur(3px); }
dialog form, .credential-dialog > div { padding: 23px; }
dialog form > header { display: flex; align-items: flex-start; justify-content: space-between; }
dialog h2 { margin: 5px 0; font: 800 21px Manrope; }
.icon-btn { display: grid; width: 34px; height: 34px; place-items: center; border: 1px solid var(--line); border-radius: 9px; background: white; color: #7c817c; font-size: 18px; cursor: pointer; }
.form-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 12px; margin: 19px 0; }
.form-grid .wide-field { grid-column: 1 / -1; }
.form-grid textarea { display: block; width: 100%; min-height: 100px; resize: vertical; margin-top: 7px; border: 1px solid var(--line); border-radius: 11px; padding: 12px 13px; background: #fdfcf9; color: var(--ink); outline: none; }
.form-grid textarea:focus { border-color: var(--gold); background: white; box-shadow: 0 0 0 3px rgba(224, 170, 49, .12); }
fieldset { border: 0; margin: 0; padding: 0; }
fieldset legend { font-size: 10px; font-weight: 800; }
fieldset > p, .form-note { margin: 4px 0 10px; color: var(--muted); font-size: 8.5px; }
.module-grid { display: grid; grid-template-columns: repeat(2, 1fr); gap: 7px; }
.contract-fieldset { margin-bottom: 17px; border-bottom: 1px solid var(--line); padding-bottom: 4px; }
.contract-grid { margin: 12px 0; }
.usage-pricing-fieldset { margin-bottom: 17px; border-bottom: 1px solid var(--line); padding-bottom: 17px; }
.field-help { display: block; margin-top: 5px; color: var(--muted); font-size: 7px; font-weight: 500; line-height: 1.45; }
.pricing-preview { border: 1px solid #e7d8b5; border-radius: 10px; padding: 10px 12px; background: #fffaf0; color: #775b1c; font-size: 8px; font-weight: 700; line-height: 1.55; }
.pricing-preview.invalid { border-color: #eccbc7; background: #fff4f2; color: var(--red); }
.notification-panel, .credit-note-panel, .usage-panel, .quote-panel { margin-top: 13px; }
.quote-preview { display: grid; grid-template-columns: repeat(4, 1fr); gap: 8px; margin-top: 12px; }
.quote-preview span { border: 1px solid var(--line); border-radius: 10px; padding: 11px; background: #faf8f3; color: var(--muted); font-size: 7.5px; }
.quote-preview b { display: block; margin-top: 5px; color: var(--ink); font: 800 12px Manrope; }
.module-option { display: flex; align-items: flex-start; gap: 8px; border: 1px solid var(--line); border-radius: 10px; padding: 9px; cursor: pointer; }
.module-option:has(input:checked) { border-color: #d9ba72; background: #fffbf0; }
.module-option input { flex: none; margin: 2px 0 0; accent-color: var(--gold); }
.module-option > span { min-width: 0; flex: 1; }
.module-option select { width: 62px; height: 27px; flex: none; border: 1px solid var(--line); border-radius: 7px; padding: 0 5px; background: white; color: var(--ink); font-size: 7px; outline: none; }
.module-option b, .module-option small { display: block; }
.module-option b { color: var(--ink); font-size: 8.5px; }
.module-option small { margin-top: 2px; color: var(--muted); font-size: 7px; font-weight: 500; }
.client-admin-fieldset { margin-top: 18px; border-top: 1px solid var(--line); padding-top: 17px; }
.fieldset-heading { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.fieldset-heading legend { padding: 0; }
.fieldset-heading p { margin: 3px 0 0; color: var(--muted); font-size: 8px; }
.client-administrators { display: grid; gap: 7px; margin-top: 11px; }
.client-administrators article { display: flex; align-items: center; gap: 9px; border: 1px solid var(--line); border-radius: 10px; padding: 9px; }
.client-administrators article > span:nth-child(2) { min-width: 0; flex: 1; }
.client-administrators article b, .client-administrators article small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.client-administrators article b { font-size: 8.5px; }
.client-administrators article small { margin-top: 2px; color: var(--muted); font-size: 7px; }
.empty-admin { border: 1px dashed var(--line); border-radius: 10px; padding: 13px; color: var(--muted); text-align: center; }
.empty-admin b, .empty-admin span { display: block; }
.empty-admin b { color: var(--ink); font-size: 8.5px; }
.empty-admin span { margin-top: 3px; font-size: 7.5px; }
dialog form > footer { display: flex; justify-content: flex-end; gap: 8px; margin-top: 19px; border-top: 1px solid var(--line); padding-top: 17px; }
.credential-dialog { width: min(430px, calc(100vw - 28px)); text-align: center; }
.credential-dialog p:not(.eyebrow) { color: var(--muted); font-size: 9px; }
.credential-dialog dl { display: grid; gap: 8px; margin: 18px 0; text-align: left; }
.credential-dialog dl div { border-radius: 10px; padding: 10px 12px; background: #f6f3ec; }
.credential-dialog dt { color: var(--muted); font-size: 7.5px; text-transform: uppercase; }
.credential-dialog dd { margin: 4px 0 0; font: 800 11px ui-monospace, monospace; }
.credential-dialog button { width: 100%; margin-top: 7px; }
.mfa-dialog { width: min(500px, calc(100vw - 28px)); }
.mfa-dialog .form-note { margin: 13px 0 16px; font-size: 9px; line-height: 1.6; }
.mfa-secret { position: relative; display: grid; gap: 5px; border: 1px dashed #d8c595; border-radius: 11px; padding: 12px; background: #fffaf0; }
.mfa-secret span { color: #88713b; font-size: 7.5px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; }
.mfa-secret code { overflow-wrap: anywhere; color: var(--deep); font-size: 11px; font-weight: 800; line-height: 1.5; }
.mfa-secret button { position: absolute; top: 10px; right: 10px; }
.mfa-code-label { display: block; margin-top: 15px; color: #4d6368; font-size: 9px; font-weight: 800; }
.mfa-code-label input { display: block; width: 100%; height: 46px; margin-top: 7px; border: 1px solid var(--line); border-radius: 11px; padding: 0 13px; background: #fdfcf9; color: var(--ink); font: 800 15px ui-monospace, monospace; letter-spacing: .12em; outline: none; }
.mfa-code-label input:focus { border-color: var(--gold); box-shadow: 0 0 0 3px rgba(224,170,49,.12); }
.recovery-dialog { width: min(460px, calc(100vw - 28px)); }
.recovery-codes { display: grid; grid-template-columns: repeat(2, 1fr); gap: 7px; margin: 17px 0; }
.recovery-codes code { border: 1px solid var(--line); border-radius: 8px; padding: 9px; background: #f8f6f1; color: var(--deep); font-size: 10px; font-weight: 800; }
.account-recovery-dialog { width: min(500px, calc(100vw - 28px)); }
.toast { position: fixed; z-index: 100; right: 22px; bottom: 22px; max-width: min(390px, calc(100vw - 30px)); border-radius: 11px; padding: 12px 16px; background: var(--deep); color: white; box-shadow: 0 16px 40px rgba(9,47,54,.25); font-size: 9.5px; font-weight: 700; opacity: 0; pointer-events: none; transform: translateY(10px); transition: .2s; }
.toast.show { opacity: 1; transform: none; }
.toast.error { background: #8e3028; }
.toast.info { background: #956b13; }
.mobile-backdrop { display: none; }

@media (max-width: 1180px) {
  .clients { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .metric strong { font-size: 20px; }
}

@media (max-width: 900px) {
  .sidebar { position: fixed; inset: 0 auto 0 0; width: min(310px, 88vw); transform: translateX(-105%); transition: transform .24s ease; }
  .sidebar.mobile-open { transform: none; }
  .nav-close { display: block; }
  .mobile-backdrop { position: fixed; z-index: 19; inset: 0; display: block; border: 0; background: rgba(4,32,38,.55); backdrop-filter: blur(2px); }
  .mobile-nav { display: grid; width: 36px; height: 36px; place-items: center; border: 1px solid var(--line); border-radius: 10px; background: white; }
  .topbar { justify-content: flex-start; gap: 12px; }
  .topbar-actions { margin-left: auto; }
  .metrics { grid-template-columns: repeat(2, 1fr); }
  .dashboard-grid { grid-template-columns: 1fr; }
  .analytics-chart-grid, .analytics-insight-grid, .financial-activity-layout { grid-template-columns: 1fr; }
  .financial-activity-layout > div + div { border-top: 1px solid var(--line); border-left: 0; }
  .monitoring-grid { grid-template-columns: 1fr; }
  .account-security { grid-template-columns: auto 1fr auto; }
  .security-actions { grid-column: 1 / -1; }
}

@media (max-width: 640px) {
  .login-page { grid-template-columns: 1fr; }
  .login-card { padding: 36px 24px; }
  .login-visual { display: none; }
  .topbar { height: 64px; padding: 0 14px; }
  .topbar-title .eyebrow, .health { display: none; }
  .topbar-title h1 { font-size: 16px; }
  .page { padding: 17px 14px 28px; }
  .hero { align-items: stretch; flex-direction: column; }
  .hero h2 { font-size: 23px; }
  .hero-actions, .hero-actions button { width: 100%; }
  .hero-actions { flex-direction: column-reverse; }
  .analytics-actions label,.analytics-actions select { width: 100%; }
  .analytics-metrics { grid-template-columns: 1fr 1fr; }
  .metrics { gap: 8px; margin: 15px 0; }
  .metric { min-height: 96px; padding: 13px; }
  .metric strong { font-size: 18px; }
  .toolbar { flex-direction: column; }
  .toolbar select { width: 100%; }
  .clients, .plan-grid, .module-catalog { grid-template-columns: 1fr; }
  .form-grid, .module-grid { grid-template-columns: 1fr; }
  .support-request-summary { grid-template-columns: 1fr; }
  .support-request-summary article { grid-column: auto; }
  .support-history > div > div { grid-template-columns: 1fr; gap: 2px; }
  .pagination { align-items: flex-start; flex-direction: column; gap: 9px; }
  .pagination > div, .pagination button { width: 100%; }
  .updated { display: none; }
  .chart-area { min-height: 220px; padding-right: 8px; padding-left: 38px; }
  .chart-column { height: 185px; }
  .chart-track,.chart-pair { height: 140px; }
  .plan-analytics { grid-template-columns: 1fr; justify-items: center; }.analytics-legend { width: 100%; }
  .adoption-row { grid-template-columns: 85px minmax(50px,1fr) 34px; }
  .financial-breakdown { padding: 16px; }
  .role-strip { overflow-x: auto; flex-wrap: nowrap; padding-bottom: 4px; }
  .role-strip span { flex: none; }
  .account-security { grid-template-columns: auto 1fr; }
  .account-security > .badge { justify-self: start; }
  .security-actions { flex-direction: column; }
  .security-actions button { width: 100%; }
}

/* PASS 2: prévisualisation de réconciliation */
.reconciliation-notice { margin: 8px 20px 14px; line-height: 1.55; color: var(--muted, #526367); font-size: .9rem; }
.reconciliation-summary { margin: 10px 20px; font-weight: 600; }

/* Rattachement d'un Core historique, sans reprovisionnement */
#adoption-dialog { width: min(680px, calc(100vw - 2rem)); max-height: 88vh; overflow: auto; }
#adoption-dialog .adoption-modules { display: flex; flex-wrap: wrap; gap: .55rem; padding: .75rem; background: #f7f6f2; border: 1px solid #e3e1d9; border-radius: 12px; }
#adoption-dialog .adoption-modules label { display: inline-flex; flex-direction: row; gap: .4rem; align-items: center; font-weight: 500; }
#adoption-dialog .adoption-modules input { width: auto; }
