:root {
  --brand-950: #21104f;
  --brand-900: #2c1767;
  --brand-800: #39208b;
  --brand-700: #4f2bd6;
  --brand-600: #6942ee;
  --brand-500: #805cf5;
  --brand-100: #eee9ff;
  --brand-50: #f7f5ff;
  --blue-600: #315fd6;
  --ink-950: #171526;
  --ink-800: #302d42;
  --ink-700: #454156;
  --ink-500: #777287;
  --ink-400: #9893a5;
  --surface: #ffffff;
  --canvas: #f6f6f9;
  --line: #e8e6ed;
  --line-strong: #d9d6e1;
  --success: #16815d;
  --success-bg: #e9f8f2;
  --warning: #a3600b;
  --warning-bg: #fff5df;
  --danger: #bd3f4d;
  --danger-bg: #fff0f2;
  --info: #315fd6;
  --info-bg: #edf3ff;
  --shadow-sm: 0 .0625rem .125rem rgba(32, 20, 63, .04), 0 .25rem .75rem rgba(32, 20, 63, .03);
  --shadow-md: 0 .75rem 2.25rem rgba(32, 20, 63, .1);
  --radius-sm: .5625rem;
  --radius-md: .875rem;
  --radius-lg: 1.25rem;
  --sidebar-width: clamp(15.5rem, 18vw, 17.5rem);
  --space-page: clamp(1rem, 2.4vw, 2.25rem);
  --touch-target: 2.75rem;
  --environment-offset: 0rem;
  --font-body: "DM Sans", system-ui, sans-serif;
  --font-display: "Manrope", var(--font-body);
}

* { box-sizing: border-box; }
html { scroll-behavior: smooth; font-size: clamp(.875rem, .22vw + .8125rem, 1rem); }
body { margin: 0; min-width: 0; min-height: 100dvh; background: var(--canvas); color: var(--ink-950); font: 1rem/1.5 var(--font-body); -webkit-font-smoothing: antialiased; overflow-x: clip; }
button, input, select, textarea { font: inherit; }
button, a { -webkit-tap-highlight-color: transparent; }
button { border: 0; }
a { color: inherit; text-decoration: none; }
img { max-width: 100%; height: auto; }
:focus-visible { outline: .1875rem solid rgba(105, 66, 238, .28); outline-offset: .125rem; }
.skip-link { position: fixed; top: -3.75rem; left: 1rem; z-index: 1000; background: var(--surface); padding: .625rem .875rem; border-radius: .5rem; box-shadow: var(--shadow-md); }
.skip-link:focus { top: 1rem; }

.app-shell { display: grid; grid-template-columns: var(--sidebar-width) minmax(0, 1fr); min-height: calc(100dvh - var(--environment-offset)); }
.sidebar { position: fixed; inset: 0 auto 0 0; z-index: 50; width: var(--sidebar-width); display: flex; flex-direction: column; background: var(--brand-950); color: #fff; overflow: hidden; }
.sidebar-header { flex: 0 0 auto; }
.sidebar-admin-banner { display:flex;align-items:center;gap:.55rem;height:2.125rem;padding:0 1rem;border-bottom:.0625rem solid rgba(255,255,255,.08);background:rgba(128,92,245,.14);color:#c9bbff;font-size:.66rem;font-weight:800;letter-spacing:.055em;text-transform:uppercase; }
.brand { display: flex; align-items: center; gap: .75rem; min-width: 0; height: 5rem; padding: .75rem 1.125rem; border-bottom: .0625rem solid rgba(255,255,255,.09); overflow: hidden; }
.brand-mark { position: relative; width: 2.4375rem; height: 2.4375rem; flex: 0 0 auto; overflow: hidden; border-radius: .6875rem; }
.brand-mark img { position: absolute; width: 4.875rem; max-width: none; left: -1.1875rem; top: -.375rem; }
.brand-identity { display:flex;min-width:0;flex-direction:column;align-items:flex-start;gap:.35rem; }
.brand-copy { display:block;font: 800 1.25rem/1 var(--font-display); letter-spacing: .4375rem; white-space:nowrap; }
.brand-copy span { color: #a992ff; }
.sidebar-brand-context { display:inline-flex;max-width:100%;align-items:center;padding:.18rem .42rem;border:.0625rem solid rgba(255,255,255,.12);border-radius:99em;background:rgba(255,255,255,.045);color:rgba(255,255,255,.58);font-size:.54rem;font-weight:800;line-height:1.2;letter-spacing:.07em;text-transform:uppercase;white-space:nowrap; }
.nav-block { flex:1 1 auto;min-height:0;padding: .8125rem .8125rem .5rem;overflow-y:auto;overscroll-behavior:contain;scrollbar-width:thin;scrollbar-color:rgba(255,255,255,.2) transparent; }
.nav-block > .nav-section-label:first-child { margin-top:0; }
.nav-label { padding: 0 .75rem .4375rem; color: rgba(255,255,255,.44); font-size: .625rem; font-weight: 700; letter-spacing: .11em; text-transform: uppercase; }
.nav-section-label { margin-top: 1.0625rem; }
.nav-link { position: relative; display: flex; align-items: center; gap: .75rem; width: 100%; min-height: 2.6875rem; margin: .125rem 0; padding: .5625rem .75rem; border-radius: .625rem; color: rgba(255,255,255,.7); background: transparent; cursor: pointer; text-align: left; transition: .16s ease; }
.nav-link i { width: 1.1875rem; color: rgba(255,255,255,.58); text-align: center; }
.nav-link:hover { color: #fff; background: rgba(255,255,255,.07); }
.nav-link.active { color: #fff; background: rgba(132, 94, 246, .25); }
.nav-link.active i { color: #b7a3ff; }
.nav-link-emphasis { margin-block:.65rem;border:.0625rem solid rgba(181,160,255,.3);background:linear-gradient(135deg,rgba(105,66,238,.45),rgba(128,92,245,.2));color:#fff; }
.nav-link-emphasis i { color:#cfc2ff; }
.nav-link-emphasis:hover { background:linear-gradient(135deg,rgba(105,66,238,.65),rgba(128,92,245,.32)); }
.nav-link.active::before { position: absolute; left: -.8125rem; width: .1875rem; height: 1.4375rem; border-radius: 0 .1875rem .1875rem 0; background: #9d7eff; content: ""; }
.nav-count { margin-left: auto; min-width: 1.3125rem; padding: .0625rem .375rem; border-radius: 1.25rem; background: #7453e4; color: white; font-size: .6875rem; text-align: center; }
.advanced-toggle { margin-top:.75rem;border:.0625rem solid rgba(255,255,255,.08);background:rgba(255,255,255,.035); }
.advanced-toggle .toggle-chevron { width:auto;margin-left:auto;font-size:.65rem; }
.advanced-navigation { margin-top:.35rem;padding-top:.1rem;border-top:.0625rem solid rgba(255,255,255,.06); }
.advanced-navigation .nav-section-label { margin-top:.8rem; }
.sidebar-footer { margin-top: auto; padding: .875rem .8125rem 1.125rem; border-top: .0625rem solid rgba(255,255,255,.09); }
.sidebar-profile { display: flex; align-items: center; gap: .625rem; padding: .5rem .625rem; border-radius: .75rem; }
.avatar { display: inline-grid; width: 2.375rem; height: 2.375rem; flex: 0 0 auto; place-items: center; border-radius: 50%; background: var(--brand-100); color: var(--brand-700); font-weight: 800; }
.avatar.sm { width: 2rem; height: 2rem; font-size: .75rem; }
.avatar.dark { background: rgba(255,255,255,.14); color: #fff; }
.profile-meta { min-width: 0; }
.profile-meta strong, .profile-meta small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.profile-meta strong { font-size: .8125rem; }
.profile-meta small { color: rgba(255,255,255,.5); font-size: .6875rem; }

.main-area { grid-column: 2; width: 100%; min-width: 0; }
.main-header { position:sticky;top:var(--environment-offset);z-index:40;box-shadow:0 .0625rem 0 rgba(32,20,63,.02); }
.topbar { display: flex; align-items: center; justify-content: space-between; min-height: 4.75rem; padding: 0 2.125rem; background: rgba(255,255,255,.96); border-bottom: .0625rem solid var(--line); backdrop-filter: blur(.75rem); }
.topbar-left, .topbar-actions, .inline, .actions { display: flex; align-items: center; }
.topbar-left { gap: .875rem; }
.topbar-actions { gap: .5625rem; }
.icon-btn.mobile-toggle { display: none; }
.org-switcher { display: flex; align-items: center; gap: .5rem; color: var(--ink-700); font-weight: 600; }
.org-switcher i { color: var(--brand-600); }
.icon-btn { position: relative; display: inline-grid; width: 2.5rem; height: 2.5rem; flex: 0 0 auto; place-items: center; border: .0625rem solid var(--line); border-radius: .6875rem; background: var(--surface); color: var(--ink-700); cursor: pointer; transition: .16s ease; }
.icon-btn:hover { border-color: var(--line-strong); background: var(--brand-50); color: var(--brand-700); }
.notification-dot { position: absolute; top: .5rem; right: .5rem; width: .4375rem; height: .4375rem; border: .125rem solid #fff; border-radius: 50%; background: #f65d6d; }
.quick-add { gap: .5rem; }
.header-profile { display: flex; align-items: center; gap: .5625rem; margin-left: .25rem; padding-left: .8125rem; border-left: .0625rem solid var(--line); }
.header-profile strong { display: block; font-size: .8125rem; }
.header-profile small { display: block; color: var(--ink-500); font-size: .6875rem; }

.page { width: min(91.25rem, 100%); margin: 0 auto; padding: clamp(1.25rem, 2.2vw, 2rem) var(--space-page) clamp(2.5rem, 5vw, 4rem); animation: pageIn .25s ease both; }
@keyframes pageIn { from { opacity: 0; transform: translateY(.25rem); } }
.page-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 1.5rem; margin-bottom: 1.5rem; }
.page-title h1 { margin: 0 0 .3125rem; font: 800 clamp(1.5625rem, 3vw, 2rem)/1.2 var(--font-display); letter-spacing: .5rem; }
.page-title p { margin: 0; color: var(--ink-500); }
.eyebrow { display: block; margin-bottom: .4375rem; color: var(--brand-700); font-size: .6875rem; font-weight: 800; letter-spacing: .09em; text-transform: uppercase; }
.breadcrumbs { display: flex; align-items: center; gap: .5rem; margin-bottom: .75rem; color: var(--ink-500); font-size: .75rem; }
.breadcrumbs i { font-size: .5rem; color: var(--ink-400); }
h2, h3, h4 { font-family: var(--font-display); }
.section-title { display: flex; align-items: center; justify-content: space-between; gap: 1.125rem; margin: 1.75rem 0 .875rem; }
.section-title h2 { margin: 0; font-size: 1.125rem; letter-spacing: -.2.1875rem; }
.section-title p { margin: .1875rem 0 0; color: var(--ink-500); font-size: .8125rem; }

.btn { display: inline-flex; align-items: center; justify-content: center; gap: .5rem; min-height: 2.5rem; padding: .5625rem .9375rem; border: .0625rem solid transparent; border-radius: .625rem; cursor: pointer; font-weight: 700; transition: .16s ease; }
.btn:hover { transform: translateY(-.0625rem); }
.btn-primary { background: var(--brand-700); color: #fff; box-shadow: 0 .3125rem .875rem rgba(79,43,214,.18); }
.btn-primary:hover { background: var(--brand-800); }
.btn-secondary { border-color: var(--line-strong); background: #fff; color: var(--ink-800); }
.btn-secondary:hover { border-color: #c9c3d7; background: var(--brand-50); color: var(--brand-700); }
.btn-danger { background: var(--danger-bg); color: var(--danger); }
.btn-ghost { padding-inline: .5rem; background: transparent; color: var(--brand-700); }
.btn-sm { min-height: 2.125rem; padding: .375rem .6875rem; font-size: .8125rem; }
.btn-block { width: 100%; }
.link { color: var(--brand-700); font-weight: 700; cursor: pointer; }
.link:hover { text-decoration: underline; }
.actions { flex-wrap: wrap; gap: .5rem; }

.grid { display: grid; gap: 1rem; }
.grid-2 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.grid-3 { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.grid-4 { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.dashboard-layout { grid-template-columns: minmax(0, 1.65fr) minmax(19.375rem, .75fr); align-items: start; }
.card { background: var(--surface); border: .0625rem solid var(--line); border-radius: var(--radius-md); box-shadow: var(--shadow-sm); }
.card-pad { padding: 1.25rem; }
.card-header { display: flex; align-items: center; justify-content: space-between; gap: .875rem; padding: 1.125rem 1.25rem; border-bottom: .0625rem solid var(--line); }
.card-header h2, .card-header h3 { margin: 0; font-size: 1rem; }
.card-body { padding: 1.25rem; }
.metric-card { position: relative; min-height: 8.25rem; padding: 1.125rem; overflow: hidden; }
.metric-top { display: flex; align-items: center; justify-content: space-between; margin-bottom: 1.125rem; }
.metric-icon, .quick-icon, .product-icon, .doc-icon { display: inline-grid; place-items: center; border-radius: .6875rem; background: var(--brand-100); color: var(--brand-700); }
.metric-icon { width: 2.3125rem; height: 2.3125rem; }
.metric-card small { color: var(--ink-500); font-weight: 600; }
.metric-value { display: block; margin-bottom: .125rem; font: 800 1.5625rem/1.1 var(--font-display); letter-spacing: .375rem; }
.metric-note { color: var(--ink-500); font-size: .75rem; }
.tone-warning .metric-icon { background: var(--warning-bg); color: var(--warning); }
.tone-danger .metric-icon { background: var(--danger-bg); color: var(--danger); }
.tone-success .metric-icon { background: var(--success-bg); color: var(--success); }
.tone-info .metric-icon { background: var(--info-bg); color: var(--info); }

.alert { display: flex; align-items: flex-start; gap: .8125rem; padding: .9375rem 1.0625rem; border: .0625rem solid #f2d59f; border-radius: .75rem; background: var(--warning-bg); color: #72450d; }
.alert > div { min-width: 0; overflow-wrap: anywhere; }
.alert i { margin-top: .1875rem; }
.alert strong { display: block; margin-bottom: .125rem; color: #623b09; }
.alert p { margin: 0; font-size: .8125rem; }
.alert .btn { margin-left: auto; background: #fff; color: #72450d; }
.alert-danger { border-color: #f5c7cd; background: var(--danger-bg); color: var(--danger); }
.alert-info { border-color: #cfdcff; background: var(--info-bg); color: #234aaf; }
.two-factor-recommendation { margin-bottom: 1.25rem; border-width: .125rem; box-shadow: 0 .375rem 1rem rgba(163,96,11,.08); }
.status-overview { display: flex; align-items: center; gap: .625rem; padding: .875rem 1rem; border-radius: .75rem; background: var(--success-bg); color: var(--success); font-weight: 700; }
.pulse { width: .5625rem; height: .5625rem; border-radius: 50%; background: var(--success); box-shadow: 0 0 0 .3125rem rgba(22,129,93,.1); }

.quick-actions { grid-template-columns: repeat(5, 1fr); }
.quick-card { padding: 1.0625rem .8125rem; text-align: left; cursor: pointer; transition: .18s ease; }
.quick-card:hover { transform: translateY(-.125rem); border-color: #d8cff8; box-shadow: 0 .625rem 1.375rem rgba(59,36,120,.07); }
.quick-icon { width: 2.375rem; height: 2.375rem; margin-bottom: .9375rem; }
.quick-card strong { display: block; font-size: .8125rem; }
.quick-card small { display: block; margin-top: .1875rem; color: var(--ink-500); font-size: .6875rem; }

.table-wrap { width: 100%; overflow-x: auto; }
.table { width: 100%; border-collapse: collapse; }
.table th { padding: .6875rem .9375rem; border-bottom: .0625rem solid var(--line); color: var(--ink-500); font-size: .6875rem; font-weight: 700; letter-spacing: .04em; text-align: left; text-transform: uppercase; white-space: nowrap; }
.table td { padding: .875rem .9375rem; border-bottom: .0625rem solid var(--line); color: var(--ink-700); vertical-align: middle; }
.table tbody tr:last-child td { border-bottom: 0; }
.table tbody tr:hover { background: #fbfaff; }
.table strong { color: var(--ink-950); }
.table small { display: block; margin-top: .125rem; color: var(--ink-500); }
.badge { display: inline-flex; align-items: center; gap: .375rem; min-height: 1.5625rem; padding: .1875rem .5rem; border-radius: .4375rem; font-size: .6875rem; font-weight: 700; white-space: nowrap; }
.badge::before { width: .375rem; height: .375rem; border-radius: 50%; background: currentColor; content: ""; }
.badge-success { background: var(--success-bg); color: var(--success); }
.badge-warning { background: var(--warning-bg); color: var(--warning); }
.badge-danger { background: var(--danger-bg); color: var(--danger); }
.badge-info { background: var(--info-bg); color: var(--info); }
.badge-neutral { background: #f0eff3; color: var(--ink-500); }
.badge-purple { background: var(--brand-100); color: var(--brand-700); }

.toolbar { display: flex; align-items: center; gap: .625rem; margin-bottom: 1.125rem; }
.search-box { position: relative; flex: 1; min-width: 13.75rem; }
.search-box i { position: absolute; top: 50%; left: .8125rem; transform: translateY(-50%); color: var(--ink-400); }
.search-box input { width: 100%; height: 2.625rem; padding: .5rem .75rem .5rem 2.4375rem; border: .0625rem solid var(--line-strong); border-radius: .625rem; background: #fff; color: var(--ink-950); }
.select, .input, .textarea { width: 100%; border: .0625rem solid var(--line-strong); border-radius: .625rem; background: #fff; color: var(--ink-950); transition: .15s ease; }
.select, .input { height: 2.625rem; padding: .5rem .6875rem; }
.textarea { min-height: 7rem; padding: .6875rem; resize: vertical; }
.select:focus, .input:focus, .textarea:focus, .search-box input:focus { border-color: var(--brand-500); outline: .1875rem solid rgba(105,66,238,.11); }
.field { display: grid; gap: .4375rem; }
.field label { color: var(--ink-700); font-size: .8125rem; font-weight: 700; }
.field-hint { color: var(--ink-500); font-size: .6875rem; }
.form-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 1rem; }
.filter-chips { display: flex; flex-wrap: wrap; gap: .4375rem; margin-bottom: 1.125rem; }
.chip { padding: .4375rem .6875rem; border: .0625rem solid var(--line); border-radius: 1.875rem; background: #fff; color: var(--ink-500); cursor: pointer; font-size: .75rem; font-weight: 700; }
.chip.active, .chip:hover { border-color: #d8cff8; background: var(--brand-50); color: var(--brand-700); }
.view-toggle { display: flex; padding: .1875rem; border: .0625rem solid var(--line); border-radius: .625rem; background: #fff; }
.view-toggle button { width: 2.125rem; height: 2rem; border-radius: .4375rem; background: transparent; color: var(--ink-400); cursor: pointer; }
.view-toggle button.active { background: var(--brand-100); color: var(--brand-700); }

.service-grid, .product-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.service-card, .product-card { display: flex; flex-direction: column; padding: 1.25rem; }
.service-card-head, .product-card-head { display: flex; align-items: flex-start; justify-content: space-between; gap: .75rem; }
.service-card h3, .product-card h3 { margin: .875rem 0 .25rem; font-size: 1rem; }
.service-card p, .product-card p { margin: 0; color: var(--ink-500); font-size: .8125rem; }
.service-meta { display: grid; grid-template-columns: 1fr 1fr; gap: .8125rem; margin: 1.1875rem 0; padding: .9375rem 0; border-block: .0625rem solid var(--line); }
.meta-label { display: block; color: var(--ink-500); font-size: .6875rem; }
.meta-value { display: block; margin-top: .1875rem; color: var(--ink-800); font-size: .8125rem; font-weight: 700; }
.service-footer, .product-footer { display: flex; align-items: center; justify-content: space-between; gap: .625rem; margin-top: auto; }
.progress { height: .4375rem; margin-top: .5rem; overflow: hidden; border-radius: .375rem; background: #eeecf2; }
.progress > span { display: block; height: 100%; border-radius: inherit; background: var(--brand-600); }
.product-icon { width: 2.75rem; height: 2.75rem; font-size: 1.0625rem; }
.product-card { min-height: 22.25rem; }
.product-card h3 { margin-top: 1.125rem; }
.product-price { margin: 1.125rem 0; }
.product-price strong { font: 800 1.5rem/1 var(--font-display); }
.product-price span { color: var(--ink-500); font-size: .75rem; }
.feature-list { display: grid; gap: .5rem; margin: 0 0 1.25rem; padding: 0; list-style: none; }
.feature-list li { color: var(--ink-700); font-size: .75rem; }
.feature-list i { width: 1.125rem; color: var(--success); }

.notification-list { display: grid; }
.notification-preferences { margin-top:1.5rem; }
.notification-preferences>.section-title { align-items:flex-end; }
.security-notification-row { display:flex;align-items:center;gap:1rem;margin-bottom:1rem;padding:1rem 1.1rem;border:.0625rem solid #b9ddcf;border-radius:.85rem;background:#f1faf6; }
.security-notification-row>span:first-child { display:grid;place-items:center;flex:0 0 2.6rem;width:2.6rem;height:2.6rem;border-radius:.7rem;background:#dff3eb;color:var(--success); }
.security-notification-row>div { flex:1;min-width:0; }
.security-notification-row strong,.security-notification-row p { display:block;margin:0; }
.security-notification-row p { margin-top:.25rem;color:var(--ink-500);font-size:.8125rem;line-height:1.45; }
.notification-preference-grid { display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:1rem; }
.notification-preference-card { overflow:hidden;border:.0625rem solid var(--line);border-radius:.85rem;background:var(--surface);box-shadow:var(--shadow-sm); }
.notification-preference-head { display:flex;align-items:flex-start;gap:.8rem;min-height:7.5rem;padding:1rem;border-bottom:.0625rem solid var(--line); }
.notification-preference-head>span:first-child { display:grid;place-items:center;flex:0 0 2.4rem;width:2.4rem;height:2.4rem;border-radius:.7rem;background:var(--brand-100);color:var(--brand-700); }
.notification-preference-head>div { flex:1;min-width:0; }
.notification-preference-head h3 { margin:0;font-size:.95rem; }
.notification-preference-head p { margin:.3rem 0 0;color:var(--ink-500);font-size:.78rem;line-height:1.45; }
.notification-channel-row { display:flex;align-items:center;justify-content:space-between;gap:1rem;padding:.85rem 1rem;border-bottom:.0625rem solid var(--line); }
.notification-channel-row strong,.notification-channel-row small { display:block; }
.notification-channel-row strong { font-size:.8125rem; }
.notification-channel-row small { margin-top:.15rem;color:var(--ink-500);font-size:.7rem; }
.notification-essential-note { margin:0;padding:.65rem 1rem;color:var(--info);font-size:.7rem;background:#f4f8fc; }
.notification-essential-note i { margin-right:.3rem; }
.notification-unsubscribe-note { margin-top:1rem; }
.notification-item { display: grid; grid-template-columns: 2.375rem 1fr auto; gap: .75rem; padding: .9375rem 1.25rem; border-bottom: .0625rem solid var(--line); cursor: pointer; }
.notification-item:last-child { border-bottom: 0; }
.notification-item.unread { background: #fcfbff; }
.notification-icon { display: grid; width: 2.375rem; height: 2.375rem; place-items: center; border-radius: .625rem; background: var(--brand-100); color: var(--brand-700); }
.notification-item h4 { margin: 0 0 .1875rem; font-size: .8125rem; }
.notification-item p { margin: 0; color: var(--ink-500); font-size: .75rem; }
.notification-item time { color: var(--ink-400); font-size: .625rem; white-space: nowrap; }
.activity-list { display: grid; gap: .125rem; }
.activity-item { position: relative; display: grid; grid-template-columns: 1.5625rem 1fr; gap: .625rem; padding: .5625rem 0; }
.activity-item::after { position: absolute; left: .75rem; top: 2.125rem; bottom: -.5rem; width: .0625rem; background: var(--line); content: ""; }
.activity-item:last-child::after { display: none; }
.activity-dot { z-index: 1; display: grid; width: 1.5625rem; height: 1.5625rem; place-items: center; border: .25rem solid #fff; border-radius: 50%; background: var(--brand-600); box-shadow: 0 0 0 .0625rem var(--brand-100); color: white; font-size: .4375rem; }
.activity-item strong { display: block; font-size: .75rem; }
.activity-item p { margin: .125rem 0; color: var(--ink-500); font-size: .6875rem; }

.detail-hero { display: grid; grid-template-columns: 1.5fr 1fr; gap: 1.125rem; }
.detail-summary { display: flex; gap: .9375rem; }
.detail-icon { display: grid; width: 3rem; height: 3rem; flex: 0 0 auto; place-items: center; border-radius: .8125rem; background: var(--brand-100); color: var(--brand-700); font-size: 1.1875rem; }
.detail-summary h2 { margin: 0 0 .25rem; font-size: 1.25rem; }
.detail-summary p { margin: 0; color: var(--ink-500); }
.definition-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: .9375rem; }
.definition-grid > div { padding-bottom: .75rem; border-bottom: .0625rem solid var(--line); }
.usage-ring { display: grid; grid-template-columns: 5.875rem 1fr; gap: 1.125rem; align-items: center; }
.ring { display: grid; width: 5.625rem; height: 5.625rem; place-items: center; border-radius: 50%; background: conic-gradient(var(--brand-600) calc(var(--value) * 1%), #ebe8f1 0); }
.ring::before { grid-area: 1/1; width: 4.25rem; height: 4.25rem; border-radius: 50%; background: #fff; content: ""; }
.ring strong { z-index: 1; grid-area: 1/1; font: 800 1.0625rem var(--font-display); }
.tabs { display: flex; gap: .25rem; margin-bottom: 1.125rem; padding-bottom: .0625rem; border-bottom: .0625rem solid var(--line); overflow-x: auto; }
.tab { min-width: max-content; padding: .625rem .8125rem; border-bottom: .125rem solid transparent; background: transparent; color: var(--ink-500); cursor: pointer; font-weight: 700; }
.tab.active { border-color: var(--brand-700); color: var(--brand-700); }

.invoice-paper { max-width: 57.5rem; margin: auto; padding: clamp(1.5rem, 6vw, 3.375rem); background: #fff; border: .0625rem solid var(--line); border-radius: var(--radius-md); box-shadow: var(--shadow-sm); }
.invoice-head { display: flex; justify-content: space-between; gap: 1.875rem; margin-bottom: 2.625rem; }
.invoice-brand { font: 800 1.375rem var(--font-display); color: var(--brand-700); }
.invoice-title { text-align: right; }
.invoice-title h2 { margin: 0; font-size: 1.75rem; }
.invoice-parties { display: grid; grid-template-columns: 1fr 1fr; gap: 1.875rem; margin-bottom: 2rem; }
.invoice-parties h4 { margin: 0 0 .4375rem; color: var(--ink-500); font-size: .6875rem; text-transform: uppercase; }
.invoice-totals { width: min(21.25rem, 100%); margin: 1.5rem 0 0 auto; }
.total-row { display: flex; justify-content: space-between; padding: .5rem 0; }
.total-row.grand { margin-top: .5rem; padding-top: .8125rem; border-top: .125rem solid var(--ink-950); font-size: 1.125rem; font-weight: 800; }

.ticket-layout { grid-template-columns: minmax(16.25rem, .68fr) minmax(0, 1.32fr); }
.ticket-list-item { display: block; width: 100%; padding: 1rem 1.125rem; border-bottom: .0625rem solid var(--line); background: #fff; text-align: left; cursor: pointer; }
.ticket-list-item.active { border-left: .1875rem solid var(--brand-600); background: var(--brand-50); }
.ticket-list-item strong { display: block; margin: .25rem 0; }
.ticket-list-item small { color: var(--ink-500); }
.conversation { min-height: 26.25rem; }
.message { display: flex; gap: .6875rem; margin-bottom: 1.25rem; }
.message.support { flex-direction: row-reverse; }
.message-bubble { max-width: 78%; padding: .8125rem .9375rem; border-radius: .375rem .875rem .875rem .875rem; background: #f0eef5; }
.message.support .message-bubble { border-radius: .875rem .375rem .875rem .875rem; background: var(--brand-100); }
.message-bubble strong { display: block; margin-bottom: .3125rem; font-size: .75rem; }
.message-bubble p { margin: 0; color: var(--ink-700); font-size: .8125rem; white-space:pre-wrap;overflow-wrap:anywhere; }
.message-bubble time { display: block; margin-top: .5rem; color: var(--ink-400); font-size: .625rem; }
.message-attachments { display:flex;flex-wrap:wrap;gap:.4rem;margin-top:.7rem; }
.admin-resource-row,.admin-ticket-row { cursor:pointer; }
.admin-resource-row:hover,.admin-ticket-row:hover { background:var(--brand-50); }
.admin-resource-row:focus-visible,.admin-ticket-row:focus-visible { outline:.125rem solid var(--brand-500);outline-offset:-.125rem; }
.admin-record-context,.admin-detail-grid { display:grid;grid-template-columns:repeat(2,minmax(0,1fr));gap:1rem;margin-bottom:1.25rem;padding:1rem;border:.0625rem solid var(--line);border-radius:var(--radius-sm);background:var(--canvas); }
.admin-record-context>div,.admin-detail-grid>div { min-width:0; }
.admin-record-context-wide { grid-column:1/-1; }
.admin-record-context p { margin:.4rem 0 0;color:var(--ink-600);white-space:pre-wrap;overflow-wrap:anywhere; }
.admin-detail-value strong,.admin-detail-value small { display:block;overflow-wrap:anywhere; }
.admin-detail-value small { margin-top:.25rem;color:var(--ink-500); }
.technical-details { margin-top:1.25rem;padding-top:.8rem;border-top:.0625rem solid var(--line);color:var(--ink-500); }
.technical-details summary { cursor:pointer;font-size:.75rem;font-weight:700; }
.technical-details code { display:block;margin-top:.5rem;padding:.6rem;overflow-wrap:anywhere;white-space:normal;background:var(--canvas);border-radius:.5rem; }
@media (max-width:42rem) { .admin-record-context,.admin-detail-grid { grid-template-columns:1fr; } .admin-record-context-wide { grid-column:auto; } }
.admin-ticket-meta { display:flex;align-items:center;justify-content:space-between;gap:1rem;margin-bottom:1rem; }
.admin-ticket-meta>div { display:flex;flex-wrap:wrap;gap:.5rem; }
.admin-ticket-meta .select { width:min(17rem,100%); }
.admin-conversation { min-height:15rem;max-height:45dvh;overflow-y:auto;padding:1rem;border:.0625rem solid var(--line);border-radius:var(--radius-sm);background:var(--canvas); }
.admin-ticket-reply { margin-top:1rem; }

.profile-section-card { scroll-margin-top:7rem;transition:border-color .2s ease,box-shadow .2s ease; }
.profile-section-card.active-section { border-color:var(--brand-500);box-shadow:0 0 0 .125rem var(--brand-100),var(--shadow-sm); }

.totp-setup { display:grid;grid-template-columns:minmax(13rem,.75fr) minmax(0,1.25fr);align-items:start;gap:1.5rem; }
.totp-qr { display:grid;justify-items:center;gap:.55rem;padding:1rem;border:.0625rem solid var(--line);border-radius:var(--radius-md);background:#fff;text-align:center; }
.totp-qr img { display:block;width:min(15rem,100%);height:auto;image-rendering:crisp-edges; }
.totp-qr small { color:var(--ink-500);font-size:.75rem;line-height:1.5; }
.totp-secret { margin:.35rem 0 0;font-family:monospace;letter-spacing:.1em;overflow-wrap:anywhere;user-select:all; }

.incident-card { padding: 1.25rem; }
.grid-5 { grid-template-columns:repeat(5,minmax(0,1fr)); }
.client-status-hero,.incident-command-hero { display:flex;align-items:center;gap:1rem;margin-bottom:1.25rem;padding:1.25rem;border:.0625rem solid var(--line);border-radius:var(--radius);background:var(--surface);box-shadow:var(--shadow-sm); }
.client-status-hero>div,.incident-command-hero>div { flex:1;min-width:0; }
.client-status-hero h2,.incident-command-hero h2 { margin:.25rem 0;font-size:clamp(1.05rem,1.5vw,1.35rem); }
.client-status-hero p,.incident-command-hero p { margin:0;color:var(--ink-500);font-size:.875rem; }
.client-status-hero.is-operational,.incident-command-hero.operational { border-color:#b9e3d2;background:linear-gradient(135deg,#f4fcf8,#fff); }
.client-status-hero.has-impact,.incident-command-hero.degraded { border-color:#ead3a1;background:linear-gradient(135deg,#fffaf0,#fff); }
.incident-command-hero.critical { border-color:#e5b3bb;background:linear-gradient(135deg,#fff4f5,#fff); }
.client-status-icon,.incident-command-icon { display:grid;place-items:center;flex:0 0 3rem;width:3rem;height:3rem;border-radius:.9rem;background:var(--success-bg);color:var(--success);font-size:1.25rem; }
.has-impact .client-status-icon,.degraded .incident-command-icon { background:var(--warning-bg);color:var(--warning); }
.critical .incident-command-icon { background:var(--danger-bg);color:var(--danger); }
.client-service-status { margin-bottom:1.5rem; }
.client-service-status small { display:block;margin-top:.25rem;color:var(--ink-500); }
.client-service-status p { margin:.8rem 0 0;color:var(--warning);font-size:.8125rem; }
.incident-maintenance-notice { margin-bottom:1.5rem; }
.incident-affects-client { border-color:#e4c478;box-shadow:0 0 0 .0625rem #f1dfb2,var(--shadow-sm); }
.incident-public-message { margin:.9rem 0;color:var(--ink-700);line-height:1.6;white-space:pre-wrap; }
.incident-timeline { position:relative;margin-top:1rem; }
.incident-timeline-item { position:relative;display:grid;grid-template-columns:1rem minmax(0,1fr);gap:.75rem;padding-bottom:1rem; }
.incident-timeline-item>span { position:relative;width:.7rem;height:.7rem;margin-top:.25rem;border:.15rem solid var(--brand-300);border-radius:50%;background:var(--surface);z-index:1; }
.incident-timeline-item:not(:last-child)>span:after { content:"";position:absolute;top:.65rem;left:.18rem;width:.08rem;height:calc(100% + 1rem);background:var(--line-strong); }
.incident-timeline-item.latest>span { border-color:var(--brand-700);background:var(--brand-700); }
.incident-timeline-item strong,.incident-timeline-item time { display:block; }
.incident-timeline-item time { margin:.15rem 0;color:var(--ink-500);font-size:.72rem; }
.incident-timeline-item p { margin:0;color:var(--ink-600);font-size:.8125rem;line-height:1.5;white-space:pre-wrap; }
.incident-metrics { margin-bottom:1.25rem; }
.incident-tabs { display:flex;gap:.35rem;margin-bottom:1.25rem;padding:.3rem;border:.0625rem solid var(--line);border-radius:.8rem;background:var(--surface);width:max-content;max-width:100%;overflow-x:auto; }
.incident-tabs button { display:flex;align-items:center;gap:.45rem;padding:.65rem .9rem;border:0;border-radius:.6rem;background:transparent;color:var(--ink-600);font:inherit;font-size:.8125rem;font-weight:700;white-space:nowrap;cursor:pointer; }
.incident-tabs button span { display:grid;place-items:center;min-width:1.4rem;height:1.4rem;padding:0 .3rem;border-radius:2rem;background:var(--canvas);font-size:.7rem; }
.incident-tabs button.active { background:var(--brand-100);color:var(--brand-700); }
.incident-command-card { overflow:hidden; }
.incident-command-head { display:flex;align-items:flex-start;justify-content:space-between;gap:1.25rem;padding:1.25rem; }
.incident-command-head h3 { margin:.65rem 0 .3rem;font-size:1.15rem; }
.incident-command-head p { max-width:55rem;margin:0;color:var(--ink-600);font-size:.875rem;line-height:1.55;white-space:pre-wrap; }
.incident-kind { padding:.3rem .55rem;border-radius:.45rem;background:var(--canvas);color:var(--ink-600);font-size:.7rem;font-weight:800;text-transform:uppercase;letter-spacing:.04em; }
.incident-impact-summary { display:grid;grid-template-columns:auto auto;align-items:baseline;gap:.1rem .4rem;flex:0 0 auto;padding:.7rem .9rem;border-radius:.7rem;background:var(--canvas); }
.incident-impact-summary strong { font-size:1.15rem; }
.incident-impact-summary small { color:var(--ink-500);font-size:.7rem; }
.incident-command-meta,.incident-affected-services { display:flex;flex-wrap:wrap;gap:.65rem 1rem;padding:0 1.25rem 1rem;color:var(--ink-500);font-size:.75rem; }
.incident-command-meta i { width:1rem;color:var(--brand-600); }
.incident-affected-services { gap:.4rem;padding-top:.85rem;border-top:.0625rem solid var(--line); }
.incident-affected-services span { display:inline-flex;align-items:center;gap:.35rem;padding:.35rem .55rem;border-radius:2rem;background:var(--brand-50);color:var(--brand-700);font-weight:700; }
.incident-command-body { display:grid;grid-template-columns:minmax(0,1.5fr) minmax(18rem,.75fr);gap:1.25rem;padding:1.25rem;border-top:.0625rem solid var(--line);background:#fdfdfe; }
.incident-command-body h4,.incident-actions-panel h4 { margin:0 0 .8rem;font-size:.875rem; }
.admin-incident-timeline { max-height:25rem;overflow-y:auto;padding-right:.5rem; }
.incident-actions-panel { padding:1rem;border:.0625rem solid var(--line);border-radius:.8rem;background:var(--surface); }
.incident-quick-actions { display:flex;flex-wrap:wrap;gap:.5rem;margin-bottom:1rem; }
.incident-actions-panel .textarea { min-height:6.5rem; }
.incident-publish-options { display:grid;gap:.5rem;margin:1rem 0; }
.incident-create-layout { display:grid;gap:1.25rem; }
.incident-service-picker { padding:1rem;border:.0625rem solid var(--line);border-radius:.8rem;background:var(--canvas); }
.incident-service-picker .section-title { margin:0 0 .8rem; }
.incident-all-services { margin-bottom:.8rem;font-weight:800; }
.incident-service-picker .search-box { width:100%;margin-bottom:.7rem;background:var(--surface); }
.incident-service-options { display:grid;gap:.35rem;max-height:17rem;overflow-y:auto; }
.incident-service-options>label { display:flex;align-items:center;gap:.7rem;padding:.65rem;border:.0625rem solid transparent;border-radius:.6rem;background:var(--surface);cursor:pointer; }
.incident-service-options>label:hover { border-color:var(--brand-300); }
.incident-service-options>label:has(input:checked) { border-color:var(--brand-500);background:var(--brand-50); }
.incident-service-options strong,.incident-service-options small { display:block; }
.incident-service-options small { margin-top:.18rem;color:var(--ink-500);font-size:.72rem; }
.incident-create-preview { padding:1rem;border:.0625rem solid var(--brand-300);border-radius:.8rem;background:var(--brand-50); }
.incident-create-preview h3 { margin:.5rem 0;font-size:1rem; }
.incident-create-preview p { margin:.4rem 0;color:var(--ink-600);white-space:pre-wrap; }
.incident-create-preview small { color:var(--ink-500); }
.incident-head { display: flex; justify-content: space-between; gap: .875rem; }
.incident-head h3 { margin: 0 0 .3125rem; font-size: 1rem; }
.incident-head p { margin: 0; color: var(--ink-500); font-size: .75rem; }
.incident-meta { display: flex; flex-wrap: wrap; gap: .875rem 1.375rem; margin: 1.125rem 0; color: var(--ink-500); font-size: .75rem; }

.settings-layout { grid-template-columns: 14.375rem minmax(0, 1fr); align-items: start; }
.settings-nav { padding: .5rem; }
.settings-nav button { display: flex; align-items: center; gap: .5625rem; width: 100%; padding: .625rem .6875rem; border-radius: .5rem; background: transparent; color: var(--ink-500); text-align: left; cursor: pointer; }
.settings-nav button.active { background: var(--brand-50); color: var(--brand-700); font-weight: 700; }
.member-row, .session-row, .document-row { display: flex; align-items: center; gap: .8125rem; padding: .9375rem 0; border-bottom: .0625rem solid var(--line); }
.member-row:last-child, .session-row:last-child, .document-row:last-child { border-bottom: 0; }
.member-row .member-info, .session-row .member-info, .document-row .member-info { flex: 1; min-width: 0; }
.member-info strong { display: block; }
.member-info small { color: var(--ink-500); }
.doc-icon { width: 2.5rem; height: 2.5rem; }
.switch { position: relative; width: 2.625rem; height: 1.5rem; flex: 0 0 auto; }
.switch input { position: absolute; opacity: 0; }
.switch span { position: absolute; inset: 0; border-radius: 1.25rem; background: #cbc7d4; cursor: pointer; transition: .18s; }
.switch span::after { position: absolute; top: .1875rem; left: .1875rem; width: 1.125rem; height: 1.125rem; border-radius: 50%; background: #fff; box-shadow: 0 .125rem .3125rem rgba(0,0,0,.16); content: ""; transition: .18s; }
.switch input:checked + span { background: var(--brand-600); }
.switch input:checked + span::after { transform: translateX(1.125rem); }

.modal-backdrop { position: fixed; inset: 0; z-index: 200; display: grid; place-items: center; padding: 1.125rem; background: rgba(24,18,41,.56); animation: fadeIn .15s ease; }
@keyframes fadeIn { from { opacity: 0; } }
.modal { display:flex;flex-direction:column;width: min(35rem, 100%); max-height: min(51.25rem, 92dvh); overflow: hidden; border-radius: 1.125rem; background: #fff; box-shadow: 0 1.5rem 5rem rgba(18,10,42,.28); animation: modalIn .18s ease; }
.modal-lg { width: min(57.5rem, 100%); }
@keyframes modalIn { from { opacity: 0; transform: translateY(.5rem) scale(.985); } }
.modal-head { display: flex; align-items: flex-start; justify-content: space-between; gap: .9375rem; padding: 1.25rem 1.375rem; border-bottom: .0625rem solid var(--line); }
.modal-head h2 { margin: 0; font-size: 1.1875rem; }
.modal-head p { margin: .25rem 0 0; color: var(--ink-500); font-size: .75rem; }
.modal-body { padding: clamp(1rem, 2vw, 1.375rem); overflow-y:auto; overscroll-behavior:contain; }
.modal-footer { display: flex; justify-content: flex-end; gap: .5625rem; padding: 1rem clamp(1rem, 2vw, 1.375rem); border-top: .0625rem solid var(--line); background:#fff; }
.checkout-steps { display: grid; grid-template-columns: repeat(4, 1fr); gap: .375rem; margin-bottom: 1.5rem; }
.checkout-step { position: relative; color: var(--ink-400); font-size: .6875rem; font-weight: 700; text-align: center; }
.checkout-step::before { display: block; height: .25rem; margin-bottom: .4375rem; border-radius: .3125rem; background: #e7e4ec; content: ""; }
.checkout-step.active { color: var(--brand-700); }
.checkout-step.active::before { background: var(--brand-600); }
.quote-layout { display: grid; grid-template-columns: 1fr 18.75rem; gap: 1.25rem; align-items: start; }
.quote-box { padding: 1.125rem; border-radius: .75rem; background: var(--brand-50); }
.quote-row { display: flex; justify-content: space-between; gap: 1.125rem; padding: .375rem 0; color: var(--ink-700); font-size: .8125rem; }
.quote-row.total { margin-top: .5rem; padding-top: .8125rem; border-top: .0625rem solid #d9d2f4; color: var(--ink-950); font-size: 1.0625rem; font-weight: 800; }
.check-row { display: flex; align-items: flex-start; gap: .5625rem; margin: .6875rem 0; color: var(--ink-700); font-size: .75rem; }
.check-row input { margin-top: .1875rem; accent-color: var(--brand-700); }

.toast-stack { position: fixed; right: 1.25rem; bottom: 1.25rem; z-index: 400; display: grid; gap: .5625rem; width: min(22.5rem, calc(100vw - 2.5rem)); }
.toast { display: grid; grid-template-columns: 2.0625rem 1fr auto; gap: .625rem; align-items: center; padding: .8125rem .875rem; border: .0625rem solid var(--line); border-radius: .75rem; background: #fff; box-shadow: var(--shadow-md); animation: toastIn .22s ease; }
@keyframes toastIn { from { opacity: 0; transform: translateY(.5rem); } }
.toast-icon { display: grid; width: 2.0625rem; height: 2.0625rem; place-items: center; border-radius: .5625rem; background: var(--success-bg); color: var(--success); }
.toast.error .toast-icon { background: var(--danger-bg); color: var(--danger); }
.toast strong { display: block; font-size: .75rem; }
.toast span { color: var(--ink-500); font-size: .6875rem; }
.toast button { background: transparent; color: var(--ink-400); cursor: pointer; }

.skeleton { position: relative; overflow: hidden; border-radius: .5rem; background: #eceaf0; }
.skeleton::after { position: absolute; inset: 0; transform: translateX(-100%); background: linear-gradient(90deg, transparent, rgba(255,255,255,.65), transparent); content: ""; animation: shimmer 1.25s infinite; }
@keyframes shimmer { to { transform: translateX(100%); } }
.skeleton-card { height: 8.25rem; }
.empty { padding: 2.875rem 1.25rem; text-align: center; }
.empty i { display: grid; width: 3rem; height: 3rem; margin: 0 auto .8125rem; place-items: center; border-radius: .875rem; background: var(--brand-100); color: var(--brand-700); font-size: 1.125rem; }
.empty h3 { margin: 0 0 .3125rem; font-size: 1rem; }
.empty p { margin: 0 0 .9375rem; color: var(--ink-500); font-size: .8125rem; }

.auth-shell { min-height: calc(100dvh - var(--environment-offset)); display: grid; grid-template-columns: minmax(23.75rem, .86fr) minmax(30rem, 1.14fr); background: #fff; }
.auth-panel { display: grid; place-items: center; padding: 2.25rem; }
.auth-form { width: min(26.875rem, 100%); }
.auth-logo { display: flex; align-items: center; gap: .75rem; margin-bottom: 2.8125rem; }
.auth-logo .brand-copy { color: var(--ink-950); font-size: 1.5rem; }
.auth-form h1 { margin: 0 0 .5625rem; font: 800 1.9375rem/1.2 var(--font-display); letter-spacing: .5rem; }
.auth-subtitle { margin: 0 0 1.875rem; color: var(--ink-500); }
.password-wrap { position: relative; }
.password-wrap input { padding-right: 2.75rem; }
.password-toggle { position: absolute; top: 0; right: 0; width: 2.625rem; height: 2.625rem; background: transparent; color: var(--ink-500); cursor: pointer; }
.auth-options { display: flex; justify-content: space-between; gap: 1rem; margin: .9375rem 0 1.375rem; font-size: .75rem; }
.auth-options label { display: flex; align-items: center; gap: .4375rem; color: var(--ink-700); }
.auth-options input { accent-color: var(--brand-700); }
.auth-footer { margin-top: 1.375rem; color: var(--ink-500); font-size: .8125rem; text-align: center; }
.auth-showcase { position: relative; display: flex; align-items: center; justify-content: center; overflow: hidden; margin: 1rem; border-radius: 1.5rem; background: var(--brand-950); color: #fff; }
.auth-showcase::before, .auth-showcase::after { position: absolute; border-radius: 50%; content: ""; }
.auth-showcase::before { width: 32.5rem; height: 32.5rem; top: -15rem; right: -11.875rem; border: .0625rem solid rgba(255,255,255,.09); box-shadow: 0 0 0 5rem rgba(255,255,255,.025), 0 0 0 10rem rgba(255,255,255,.02); }
.auth-showcase::after { width: 20rem; height: 20rem; left: -11.25rem; bottom: -8.75rem; background: rgba(111,73,237,.17); filter: blur(.125rem); }
.showcase-content { position: relative; z-index: 1; width: min(32.5rem, 75%); }
.showcase-logo { position: relative; width: 8.125rem; height: 5.375rem; margin-bottom: 2.1875rem; overflow: hidden; border-radius: .9375rem; opacity: .9; }
.showcase-logo img { position: absolute; width: 11.5625rem; max-width: none; left: -1.6875rem; top: -1.125rem; }
.showcase-content h2 { margin: 0 0 .9375rem; font-size: clamp(1.75rem, 4vw, 2.625rem); line-height: 1.16; letter-spacing: -.08125rem; }
.showcase-content > p { margin: 0 0 2.1875rem; color: rgba(255,255,255,.65); font-size: 1rem; }
.trust-row { display: grid; grid-template-columns: repeat(3, 1fr); gap: .875rem; }
.trust-row div { padding: .9375rem; border: .0625rem solid rgba(255,255,255,.11); border-radius: .8125rem; background: rgba(255,255,255,.05); }
.trust-row i { color: #b29fff; }
.trust-row strong { display: block; margin-top: .5625rem; font-size: .75rem; }

.admin-shell .sidebar { background: #171820; }
.admin-banner { display: flex; align-items: center; justify-content: center; gap: .5rem; min-height: 2.125rem; padding: .4375rem .9375rem; background: #fff1cd; color: #6d490c; font-size: .75rem; font-weight: 700; }
.admin-banner strong { font-weight:800; }
.kpi-trend { font-size: .6875rem; font-weight: 700; }
.kpi-trend.success { color: var(--success); }
.admin-table-avatar { display: flex; align-items: center; gap: .5625rem; }
.environment-ribbon { position: fixed; inset: 0 0 auto; z-index: 1000; display: flex; align-items: center; justify-content: center; gap: .45rem; height: 1.75rem; color: #fff; font-size: .7rem; font-weight: 800; letter-spacing: .035em; text-transform: uppercase; }
.environment-ribbon.demo { background: linear-gradient(90deg, #7144d8, #4f2bd6); }
body.has-environment-ribbon { --environment-offset: 1.75rem; padding-top: var(--environment-offset); }
.sidebar { top: var(--environment-offset); }
.auth-shell { min-height: calc(100dvh - var(--environment-offset)); }
.admin-mini-metrics article { min-height: 6.5rem; display: flex; flex-direction: column; justify-content: center; }
.admin-sale-callout { display:grid;grid-template-columns:auto minmax(0,1fr) auto;align-items:center;gap:1.25rem;margin-bottom:1.25rem;padding:clamp(1rem,2vw,1.5rem);border-color:#d9cffc;background:linear-gradient(120deg,#fff 55%,var(--brand-50)); }
.admin-sale-callout h2 { margin:.15rem 0 .35rem;font-size:clamp(1.1rem,2vw,1.35rem); }
.admin-sale-callout p { max-width:55rem;margin:0;color:var(--ink-500); }
.sale-callout-icon { display:grid;width:3.25rem;height:3.25rem;place-items:center;border-radius:1rem;background:var(--brand-700);color:#fff;font-size:1.25rem;box-shadow:0 .6rem 1.5rem rgba(79,43,214,.2); }
.admin-mini-metrics strong { margin-top: .375rem; color: var(--ink-900); font-family: var(--font-display); font-size: 1.5625rem; }
.order-card .card-header h2 { margin: .3125rem 0 .1875rem; font-size: 1.0625rem; }
.order-card .card-header p { margin: 0; color: var(--ink-500); font-size: .75rem; }
.order-total { display: block; margin-top: .625rem; font-family: var(--font-display); font-size: 1.25rem; }
.order-progress { height: .4375rem; overflow: hidden; border-radius: 6.1875rem; background: var(--brand-100); }
.order-progress span { display: block; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--brand-600), #8b68ef); }
.order-meta { justify-content: space-between; margin-top: .8125rem; color: var(--ink-600); font-size: .75rem; }
.order-meta i { margin-right: .3125rem; color: var(--brand-600); }
.privacy-card { display: flex; min-height: 15.625rem; flex-direction: column; align-items: flex-start; }
.privacy-card h2 { margin: 1.125rem 0 .4375rem; font-size: 1.125rem; }
.privacy-card p { flex: 1; margin: 0 0 1.125rem; color: var(--ink-500); font-size: .8125rem; line-height: 1.65; }

.optional-label { color:var(--ink-400);font-size:.75rem;font-weight:500; }
.admin-combobox { position:relative; }
.admin-combobox-control { position:relative; }
.admin-combobox-control>i { position:absolute;left:.85rem;top:50%;z-index:1;transform:translateY(-50%);color:var(--ink-400);pointer-events:none; }
.admin-combobox-control .input { padding-left:2.45rem;padding-right:2.5rem; }
.admin-combobox-clear { position:absolute;right:.35rem;top:50%;display:grid;width:2rem;height:2rem;place-items:center;transform:translateY(-50%);border-radius:.5rem;background:transparent;color:var(--ink-400);cursor:pointer; }
.admin-combobox-clear:hover { background:var(--brand-50);color:var(--brand-700); }
.admin-combobox-results { position:absolute;inset:calc(100% + .35rem) 0 auto;z-index:25;max-height:min(18rem,42vh);overflow-y:auto;border:.0625rem solid var(--line-strong);border-radius:.75rem;background:#fff;box-shadow:var(--shadow-md); }
.admin-combobox-option { display:flex;width:100%;align-items:center;justify-content:space-between;gap:1rem;padding:.75rem .85rem;border-bottom:.0625rem solid var(--line);background:#fff;color:var(--ink-800);text-align:left;cursor:pointer; }
.admin-combobox-option:last-child { border-bottom:0; }
.admin-combobox-option:hover,.admin-combobox-option:focus-visible { background:var(--brand-50); }
.admin-combobox-option span { min-width:0; }
.admin-combobox-option strong,.admin-combobox-option small { display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap; }
.admin-combobox-option small { margin-top:.12rem;color:var(--ink-500);font-size:.74rem; }
.admin-combobox-option code { flex:0 1 42%;overflow:hidden;color:var(--ink-400);font-size:.65rem;text-overflow:ellipsis;white-space:nowrap; }
.admin-combobox-state { padding:1rem;color:var(--ink-500);font-size:.82rem;text-align:center; }
.admin-combobox-state.error { color:var(--danger); }
.sale-flow { display:grid;gap:1rem; }
.sale-step { padding:clamp(1rem,2.5vw,1.35rem);border:.0625rem solid var(--line);border-radius:var(--radius-md);background:linear-gradient(145deg,#fff 70%,var(--brand-50)); }
.sale-step-head { display:flex;align-items:flex-start;gap:.8rem;margin-bottom:1rem; }
.sale-step-head>span { display:grid;width:2rem;height:2rem;flex:0 0 auto;place-items:center;border-radius:.65rem;background:var(--brand-700);color:#fff;font-weight:800; }
.sale-step-head h3 { margin:.05rem 0 0;font-size:1rem; }
.sale-step-head p { margin:.15rem 0 0;color:var(--ink-500);font-size:.8rem; }
.sale-main-fields { grid-template-columns:minmax(0,1.4fr) minmax(10rem,.7fr) minmax(10rem,.7fr); }
.sale-advanced { grid-column:1/-1;margin-top:.25rem;border:.0625rem solid var(--line);border-radius:.75rem;background:#fff; }
.sale-advanced summary { display:flex;align-items:center;gap:.6rem;padding:.8rem 1rem;color:var(--ink-700);cursor:pointer;font-weight:700;list-style:none; }
.sale-advanced summary::-webkit-details-marker { display:none; }
.sale-advanced summary i { color:var(--brand-600); }
.sale-advanced summary small { margin-left:auto;color:var(--ink-400);font-weight:500; }
.sale-advanced[open] summary { border-bottom:.0625rem solid var(--line); }
.sale-advanced>.form-grid { padding:1rem; }
.sale-description-field { grid-column:1/-1; }
.sale-result { display:flex;align-items:flex-start;gap:.85rem;padding:1rem;border:.0625rem solid #cfdcff;border-radius:.85rem;background:var(--info-bg);color:#234aaf; }
.sale-result>span { display:grid;width:2rem;height:2rem;flex:0 0 auto;place-items:center;border-radius:.65rem;background:#fff; }
.sale-result strong { display:block;margin-bottom:.15rem; }
.sale-result p { margin:0;font-size:.82rem; }
.input-suffix { position:relative; }
.input-suffix .input { padding-right:2.5rem; }
.input-suffix>span { position:absolute;right:.9rem;top:50%;transform:translateY(-50%);color:var(--ink-500);font-weight:700; }
.sale-summary { display:grid;grid-template-columns:repeat(3,minmax(0,1fr));gap:.65rem;margin-top:1rem;padding:.85rem;border-radius:.75rem;background:var(--brand-50); }
.sale-summary div { min-width:0; }
.sale-summary span,.sale-summary strong { display:block;overflow-wrap:anywhere; }
.sale-summary span { color:var(--ink-500);font-size:.72rem; }
.sale-summary strong { margin-top:.15rem;color:var(--ink-950);font-family:var(--font-display);font-size:.95rem; }

@media (max-width: 73.75em) {
  .grid-4 { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .grid-5 { grid-template-columns:repeat(3,minmax(0,1fr)); }
  .incident-command-body { grid-template-columns:1fr; }
  .quick-actions { grid-template-columns: repeat(3, 1fr); }
  .service-grid, .product-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .dashboard-layout { grid-template-columns: 1fr; }
}

@media (max-width: 56.25em) {
  .app-shell { grid-template-columns: 1fr; }
  .sidebar { transform: translateX(-100%); box-shadow: 1.125rem 0 3.125rem rgba(20,10,44,.22); transition: transform .22s ease; }
  .sidebar.open { transform: translateX(0); }
  .sidebar-scrim { position: fixed; inset: 0; z-index: 45; background: rgba(22,16,38,.42); }
  .main-area { grid-column: 1; }
  .icon-btn.mobile-toggle { display: inline-grid; }
  .topbar { padding: 0 1.25rem; }
  .page { padding: 1.5625rem 1.25rem 2.8125rem; }
  .auth-shell { grid-template-columns: 1fr; }
  .auth-showcase { display: none; }
  .ticket-layout, .settings-layout, .detail-hero { grid-template-columns: 1fr; }
}

@media (max-width: 42.5em) {
  .main-area { width: 100%; overflow-x: clip; }
  .topbar { width: 100%; min-height: 4.125rem; overflow: clip; }
  .org-switcher span, .header-profile .profile-meta, .quick-add span { display: none; }
  .header-profile { display: none; }
  .page { width: 100%; margin: 0; padding: clamp(1rem, 4vw, 1.3125rem) var(--space-page) 2.375rem; overflow-x: clip; }
  .page > *, .page .grid, .page .card, .page .alert { min-width: 0; max-width: 100%; }
  .page .alert { width: 100%; }
  .page-header { align-items: stretch; flex-direction: column; }
  .page-header .actions { width: 100%; }
  .page-header .actions .btn { flex: 1 1 100%; }
  .grid-2, .grid-3, .grid-4, .grid-5, .service-grid, .product-grid, .quick-actions, .form-grid, .quote-layout, .invoice-parties { grid-template-columns: 1fr; }
  .client-status-hero,.incident-command-hero,.incident-command-head { align-items:flex-start;flex-wrap:wrap; }
  .client-status-hero .btn { width:100%; }
  .incident-impact-summary { width:100%;grid-template-columns:auto 1fr auto 1fr; }
  .incident-command-body { padding:1rem; }
  .notification-preference-grid { grid-template-columns:1fr; }
  .notification-preferences>.section-title,.security-notification-row { align-items:flex-start;flex-wrap:wrap; }
  .notification-preferences>.section-title .actions { width:100%; }
  .notification-preferences>.section-title .btn { flex:1; }
  .quick-actions { grid-template-columns: repeat(2, 1fr); }
  .metric-card { min-height: 7.375rem; }
  .toolbar { align-items: stretch; flex-wrap: wrap; }
  .search-box { flex-basis: 100%; }
  .toolbar > .select { flex: 1; width: auto; }
  .alert { flex-wrap: wrap; overflow: hidden; }
  .alert > div { flex: 1 1 15rem; }
  .alert .btn { width: 100%; margin-left: 0; }
  .auth-panel { padding: 1.5625rem 1.25rem; }
  .auth-logo { margin-bottom: 2rem; }
  .checkout-steps { grid-template-columns: repeat(2, 1fr); row-gap: .75rem; }
  .invoice-head { flex-direction: column; }
  .invoice-title { text-align: left; }
  .notification-item { grid-template-columns: 2.25rem 1fr; }
  .notification-item time { grid-column: 2; }
  .modal-footer { flex-wrap: wrap; }
  .modal-footer .btn { flex: 1; }
  .trust-row { grid-template-columns: 1fr; }
  .admin-banner-detail { display:none; }
  .admin-combobox-option { align-items:flex-start;flex-direction:column;gap:.25rem; }
  .admin-combobox-option code { max-width:100%; }
  .sale-summary { grid-template-columns:minmax(0,1fr); }
  .sale-main-fields { grid-template-columns:minmax(0,1fr); }
  .sale-advanced summary { align-items:flex-start;flex-wrap:wrap; }
  .sale-advanced summary small { width:100%;margin-left:1.6rem; }
}

/* Responsive fluide : tablette, mobile et écrans très étroits. */
@media (max-width: 56.25em) {
  .sidebar { width:min(86vw,20rem);height:calc(100dvh - var(--environment-offset)); }
  .topbar { min-height:4.25rem;padding-inline:var(--space-page);gap:.75rem; }
  .admin-banner { min-height:2.25rem;padding:.45rem 1rem;font-size:.72rem;text-align:center; }
  .page { min-height:calc(100dvh - 6rem); }
  .grid-3,.service-grid,.product-grid { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .quick-actions { grid-template-columns:repeat(3,minmax(0,1fr)); }
  .table-wrap { max-width:100%;overscroll-behavior-inline:contain;scrollbar-width:thin; }
  .table { min-width:46rem; }
  .modal-backdrop { padding:clamp(.5rem,2vw,1rem); }
}

@media (max-width: 42.5em) {
  :root { --space-page:clamp(.85rem,4vw,1.25rem); }
  .topbar-actions { gap:.4rem; }
  .topbar .icon-btn,.mobile-toggle { width:var(--touch-target);height:var(--touch-target); }
  .org-switcher { max-width:42vw; }
  .org-switcher span { display:block;overflow:hidden;text-overflow:ellipsis;white-space:nowrap; }
  .quick-add span,.header-profile { display:none; }
  .page { width:100%;margin:0;padding:clamp(1rem,4vw,1.4rem) var(--space-page) 3rem; }
  .page-header { gap:1rem;margin-bottom:1.25rem; }
  .page-title h1 { font-size:clamp(1.45rem,7vw,2rem);overflow-wrap:anywhere; }
  .page-title p { font-size:.9rem; }
  .page-header .actions { display:grid;grid-template-columns:1fr;width:100%; }
  .page-header .actions .btn { width:100%; }
  .grid-2,.grid-3,.grid-4,.service-grid,.product-grid,.form-grid,.quote-layout,.invoice-parties,.detail-hero,.settings-layout,.ticket-layout { grid-template-columns:minmax(0,1fr); }
  .quick-actions { grid-template-columns:repeat(2,minmax(0,1fr));gap:.75rem; }
  .quick-card { min-height:7.5rem;padding:1rem; }
  .card-pad,.card-body { padding:clamp(.9rem,4vw,1.2rem); }
  .admin-sale-callout { grid-template-columns:auto minmax(0,1fr); }
  .admin-sale-callout .btn { grid-column:1/-1;width:100%; }
  .card-header { align-items:flex-start;flex-direction:column;padding:1rem; }
  .card-header>.inline { width:100%;flex-wrap:wrap; }
  .card-header .search-box { flex-basis:100%;min-width:0; }
  .section-title { align-items:flex-start;flex-direction:column;margin:1.5rem 0 .8rem; }
  .section-title>.btn { width:100%; }
  .metric-card { min-height:7rem;padding:1rem; }
  .metric-top { margin-bottom:.9rem; }
  .service-meta,.definition-grid { grid-template-columns:minmax(0,1fr); }
  .service-footer,.product-footer { align-items:stretch;flex-direction:column; }
  .service-footer .btn,.product-footer .btn { width:100%; }
  .member-row,.session-row,.document-row { align-items:flex-start;flex-wrap:wrap; }
  .member-row .member-info,.session-row .member-info,.document-row .member-info { flex:1 1 calc(100% - 4rem); }
  .notification-item { padding:1rem; }
  .message-bubble { max-width:88%; }
  .admin-ticket-meta { align-items:stretch;flex-direction:column; }
  .admin-ticket-meta .select { width:100%; }
  .totp-setup { grid-template-columns:minmax(0,1fr); }
  .invoice-paper { padding:clamp(1rem,5vw,1.5rem);border-radius:.75rem; }
  .invoice-head { gap:1rem;margin-bottom:2rem; }
  .invoice-paper .table { min-width:39rem; }
  .modal-backdrop { align-items:end;padding:0; }
  .modal,.modal-lg { width:100%;max-width:none;max-height:calc(100dvh - var(--environment-offset));border-radius:1.25rem 1.25rem 0 0; }
  .modal-head { padding:1rem var(--space-page); }
  .modal-footer { position:sticky;bottom:0;z-index:2;display:grid;grid-template-columns:repeat(2,minmax(0,1fr));padding:.85rem var(--space-page) max(.85rem,env(safe-area-inset-bottom)); }
  .modal-footer .btn { width:100%;min-width:0; }
  .modal-footer>span[style] { display:none; }
  .quote-row { gap:1rem; }
  .toast-stack { right:var(--space-page);left:var(--space-page);bottom:max(var(--space-page),env(safe-area-inset-bottom));width:auto; }
  .auth-panel { min-height:calc(100dvh - var(--environment-offset));padding:clamp(1.25rem,6vw,2rem); }
  .auth-form h1 { font-size:clamp(1.65rem,8vw,2rem); }
  .auth-options { align-items:flex-start;flex-direction:column; }
}

@media (max-width: 31em) {
  .org-switcher { max-width:34vw;font-size:.82rem; }
  .quick-actions { grid-template-columns:minmax(0,1fr); }
  .grid-4.admin-mini-metrics,.admin-mini-metrics { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .actions { width:100%; }
  .actions>.btn { flex:1 1 100%; }
  .usage-ring { grid-template-columns:minmax(0,1fr);justify-items:center;text-align:center; }
  .invoice-title { text-align:left; }
  .checkout-steps { grid-template-columns:repeat(2,minmax(0,1fr)); }
  .modal-footer { grid-template-columns:minmax(0,1fr); }
  .table { min-width:40rem; }
}

@media print {
  .sidebar, .topbar, .page-header, .breadcrumbs, .no-print { display: none !important; }
  .app-shell, .main-area { display: block; }
  .page { width: 100%; padding: 0; }
  .invoice-paper { max-width: none; padding: 0; border: 0; box-shadow: none; }
}

/* Thème connecté apaisé. Les écrans d'authentification conservent leur identité actuelle. */
body.connected-theme {
  --brand-950: #242833;
  --brand-900: #303644;
  --brand-800: #51448d;
  --brand-700: #6252a6;
  --brand-600: #715fc0;
  --brand-500: #8777cb;
  --brand-100: #eeebf8;
  --brand-50: #f6f4fb;
  --ink-950: #20242d;
  --ink-800: #303640;
  --ink-700: #474e5b;
  --ink-500: #606674;
  --ink-400: #666d79;
  --surface: #fff;
  --canvas: #f5f6f8;
  --line: #dfe2e8;
  --line-strong: #cdd2db;
  --success: #23765b;
  --success-bg: #eaf6f1;
  --warning: #825313;
  --warning-bg: #fff4df;
  --danger: #a33a4a;
  --danger-bg: #fceff1;
  --info: #315f8d;
  --info-bg: #ecf4fb;
  --shadow-sm: 0 .0625rem .125rem rgba(32, 36, 45, .035), 0 .25rem .75rem rgba(32, 36, 45, .035);
  --shadow-md: 0 .875rem 2.5rem rgba(32, 36, 45, .12);
  background: var(--canvas);
}

body.connected-theme :focus-visible {
  outline: .1875rem solid rgba(98, 82, 166, .52);
  outline-offset: .1875rem;
}

body.connected-theme .sidebar,
body.connected-theme .admin-shell .sidebar { background: var(--brand-950); }
body.connected-theme .sidebar-admin-banner { border-color: rgba(255,255,255,.1); background: rgba(255,255,255,.055); color: #d8dbe2; }
body.connected-theme .brand { border-color: rgba(255,255,255,.1); }
body.connected-theme .brand-copy { letter-spacing: .12em; }
body.connected-theme .brand-copy span { color: #c9c1e5; }
body.connected-theme .sidebar-brand-context { border-color: rgba(255,255,255,.2); color: #c8ccd6; }
body.connected-theme .nav-label { color: #aeb4c0; font-size: .6875rem; }
body.connected-theme .nav-link { min-height: 2.75rem; color: #c8ccd6; }
body.connected-theme .nav-link i { color: #adb3c0; }
body.connected-theme .nav-link:hover { background: rgba(255,255,255,.07); color: #fff; }
body.connected-theme .nav-link.active { background: rgba(98,82,166,.42); color: #fff; box-shadow: inset .1875rem 0 #c9c1e5; }
body.connected-theme .nav-link.active::before { display: none; }
body.connected-theme .nav-link.active i { color: #e4dff3; }
body.connected-theme .nav-link-emphasis { border-color: rgba(201,193,229,.3); background: rgba(98,82,166,.22); }
body.connected-theme .nav-link-emphasis:hover { background: rgba(98,82,166,.34); }
body.connected-theme .nav-count { background: #6f5bbd; }
body.connected-theme .advanced-toggle { border-color: rgba(255,255,255,.12); background: rgba(255,255,255,.04); }
body.connected-theme .sidebar-footer { border-color: rgba(255,255,255,.1); }
body.connected-theme .profile-meta small { color: #c8ccd6; font-size: .75rem; }

body.connected-theme .main-header { box-shadow: 0 .0625rem 0 rgba(32,36,45,.035); }
body.connected-theme .topbar { background: rgba(255,255,255,.97); }
body.connected-theme .org-switcher { color: var(--ink-700); }
body.connected-theme .org-switcher i { color: var(--brand-700); }
body.connected-theme .header-profile small { font-size: .75rem; }
body.connected-theme .icon-btn { min-width: 2.75rem; min-height: 2.75rem; border-color: var(--line-strong); }
body.connected-theme .icon-btn:hover { background: var(--brand-50); }

body.connected-theme .page { animation-duration: .18s; }
body.connected-theme .page-title h1 { letter-spacing: -.025em; }
body.connected-theme .section-title h2 { letter-spacing: -.01em; }
body.connected-theme .page-title p,
body.connected-theme .section-title p { color: var(--ink-500); font-size: .875rem; }
body.connected-theme .eyebrow { color: var(--brand-700); font-size: .75rem; }
body.connected-theme .breadcrumbs { font-size: .8125rem; }

body.connected-theme .btn { min-height: 2.75rem; transition: background-color .16s ease, border-color .16s ease, color .16s ease, box-shadow .16s ease; }
body.connected-theme .btn:hover { transform: none; }
body.connected-theme .btn-primary { background: var(--brand-700); box-shadow: 0 .25rem .625rem rgba(98,82,166,.14); }
body.connected-theme .btn-primary:hover { background: var(--brand-800); box-shadow: none; }
body.connected-theme .btn-secondary { border-color: var(--line-strong); color: var(--ink-800); }
body.connected-theme .btn-secondary:hover { border-color: #b9bec8; background: var(--brand-50); }
body.connected-theme .btn-ghost { color: var(--brand-700); }
body.connected-theme .btn-sm { min-height: 2.375rem; font-size: .8125rem; }
body.connected-theme .link { color: var(--brand-700); }

body.connected-theme .card { border-color: var(--line); box-shadow: var(--shadow-sm); }
body.connected-theme .card-header { border-color: var(--line); }
body.connected-theme .metric-card { min-height: 8rem; }
body.connected-theme .metric-top { margin-bottom: 1rem; }
body.connected-theme .metric-value { letter-spacing: 0; }
body.connected-theme .metric-card small { color: var(--ink-500); font-size: .8125rem; }
body.connected-theme .metric-note { color: var(--ink-500); font-size: .8125rem; line-height: 1.45; }
body.connected-theme .metric-icon,
body.connected-theme .quick-icon,
body.connected-theme .product-icon,
body.connected-theme .doc-icon { background: var(--brand-50); color: var(--brand-700); }
body.connected-theme .quick-card { transition: border-color .16s ease, box-shadow .16s ease, background-color .16s ease; }
body.connected-theme .quick-card:hover { transform: none; border-color: #c9c2df; background: #fdfcff; box-shadow: 0 .375rem 1rem rgba(32,36,45,.055); }
body.connected-theme .quick-card strong { font-size: .875rem; }
body.connected-theme .quick-card small { color: var(--ink-500); font-size: .8125rem; line-height: 1.4; }

body.connected-theme .alert { border-color: #e8c886; color: var(--warning); }
body.connected-theme .alert strong { color: #6f470f; }
body.connected-theme .alert-danger { border-color: #e7b9c0; color: var(--danger); }
body.connected-theme .alert-info { border-color: #bfd3e5; color: var(--info); }
body.connected-theme .status-overview { color: var(--success); }
body.connected-theme .badge { min-height: 1.75rem; font-size: .75rem; }
body.connected-theme .badge-neutral { background: #eef0f3; color: var(--ink-700); }
body.connected-theme .badge-purple { background: var(--brand-100); color: var(--brand-700); }

body.connected-theme .table th { color: var(--ink-500); font-size: .75rem; }
body.connected-theme .table td { color: var(--ink-700); }
body.connected-theme .table tbody tr:hover { background: #f8f8fb; }
body.connected-theme .table small { color: var(--ink-500); font-size: .8125rem; }
body.connected-theme .field label { font-size: .875rem; }
body.connected-theme .field-hint,
body.connected-theme .meta-label { color: var(--ink-500); font-size: .8125rem; line-height: 1.45; }
body.connected-theme .select,
body.connected-theme .input,
body.connected-theme .textarea,
body.connected-theme .search-box input { border-color: var(--line-strong); }
body.connected-theme .select:focus,
body.connected-theme .input:focus,
body.connected-theme .textarea:focus,
body.connected-theme .search-box input:focus { border-color: var(--brand-700); outline-color: rgba(98,82,166,.18); }
body.connected-theme .chip { border-color: var(--line-strong); color: var(--ink-700); }
body.connected-theme .chip.active,
body.connected-theme .chip:hover { border-color: #bdb4d8; background: var(--brand-50); color: var(--brand-700); }

body.connected-theme .notification-item { width: 100%; border-bottom: .0625rem solid var(--line); background: var(--surface); color: var(--ink-950); text-align: left; }
body.connected-theme .notification-item:hover { background: #f8f8fb; }
body.connected-theme .notification-item.unread { background: var(--brand-50); box-shadow: inset .1875rem 0 var(--brand-700); }
body.connected-theme .notification-copy { min-width: 0; }
body.connected-theme .notification-copy strong { display: block; margin-bottom: .1875rem; font-family: var(--font-display); font-size: .875rem; }
body.connected-theme .notification-copy > span { display: block; color: var(--ink-500); font-size: .8125rem; line-height: 1.45; }
body.connected-theme .notification-item time { color: var(--ink-500); font-size: .75rem; }
body.connected-theme .activity-item strong { font-size: .8125rem; }
body.connected-theme .activity-item p { color: var(--ink-500); font-size: .75rem; }

body.connected-theme .modal { border: .0625rem solid var(--line); box-shadow: var(--shadow-md); }
body.connected-theme .modal-backdrop { background: rgba(32,36,45,.52); }
body.connected-theme .toast { border-color: var(--line-strong); box-shadow: var(--shadow-md); }
body.connected-theme .toast strong { font-size: .8125rem; }
body.connected-theme .toast span { color: var(--ink-500); font-size: .75rem; }
body.connected-theme .skeleton { background: #e6e8ec; }
body.connected-theme .admin-banner { border-bottom: .0625rem solid #e2c88f; background: #fff7e5; color: #684812; }
body.connected-theme .admin-sale-callout { border-color: #d8d2e8; background: var(--surface); }
body.connected-theme .sale-callout-icon { background: var(--brand-700); box-shadow: none; }
body.connected-theme .sale-summary { background: var(--brand-50); }

@media (prefers-reduced-motion: reduce) {
  body.connected-theme *,
  body.connected-theme *::before,
  body.connected-theme *::after {
    scroll-behavior: auto !important;
    animation-duration: .01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: .01ms !important;
  }
}

@media (prefers-contrast: more) {
  body.connected-theme { --line: #b7bcc6; --line-strong: #9299a6; }
  body.connected-theme .card,
  body.connected-theme .btn,
  body.connected-theme .icon-btn,
  body.connected-theme .input,
  body.connected-theme .select,
  body.connected-theme .textarea { border-width: .125rem; }
}

@media (forced-colors: active) {
  body.connected-theme .nav-link.active,
  body.connected-theme .notification-item.unread { outline: .125rem solid ButtonText; outline-offset: -.125rem; }
}

@media (max-width: 30em) {
  body.connected-theme .topbar-left { min-width: 0; }
  body.connected-theme .topbar-actions { flex: 0 0 auto; margin-left: auto; }
  body.connected-theme .topbar .quick-add { display: none; }
  body.connected-theme .org-switcher { width: min(48vw, 11rem); max-width: none; min-width: 0; }
  body.connected-theme .org-switcher span { min-width: 0; }
  body.connected-theme .page .grid,
  body.connected-theme .page .card,
  body.connected-theme .page .alert { width: 100%; min-width: 0; }
  body.connected-theme .alert strong { overflow-wrap: anywhere; }
}
