/* Shared production UI foundation */
main > :not(.ui-header-stack) { animation: ui-content-enter .14s ease-out both; }
@keyframes ui-content-enter { from { opacity: .72; transform: translateY(2px); } }
@media (prefers-reduced-motion: reduce) { main > :not(.ui-header-stack) { animation: none !important; } }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 400; font-display: swap; src: url("../fonts/inter-latin-400-normal.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 500; font-display: swap; src: url("../fonts/inter-latin-500-normal.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 600; font-display: swap; src: url("../fonts/inter-latin-600-normal.woff2") format("woff2"); }
@font-face { font-family: "Inter"; font-style: normal; font-weight: 700; font-display: swap; src: url("../fonts/inter-latin-700-normal.woff2") format("woff2"); }
@font-face { font-family: "Material Symbols Outlined"; font-style: normal; font-weight: 100 700; font-display: block; src: url("../fonts/material-symbols-outlined.woff2") format("woff2"); }

.material-symbols-outlined {
    font-family: "Material Symbols Outlined";
    font-weight: normal; font-style: normal; font-size: 24px; line-height: 1;
    letter-spacing: normal; text-transform: none; display: inline-block;
    white-space: nowrap; word-wrap: normal; direction: ltr;
    -webkit-font-smoothing: antialiased; font-feature-settings: "liga";
}

body { background-color: #F4F6FA; color: #0b1c30; font-family: 'Inter', sans-serif; font-size: 14px; line-height: 1.5; font-feature-settings: 'cv02','cv03','cv04','cv11'; text-rendering: optimizeLegibility; }
h1, h2, h3, h4, strong { letter-spacing: -.015em; }
button, input, select, textarea { font: inherit; }
html { scroll-behavior: smooth; max-width: 100%; overflow-x: clip; }
body { overflow-x: clip; }
[hidden] { display: none !important; }
img { max-width: 100%; }
button, a, input, select, textarea { -webkit-tap-highlight-color: transparent; }
:where(a, button, input, select, textarea, [tabindex]):focus-visible {
    outline: 3px solid rgba(53, 37, 205, 0.35); outline-offset: 2px;
}
button:disabled, [aria-disabled="true"] { cursor: not-allowed; opacity: .55; }
[aria-busy="true"] { cursor: progress; }
.skip-link { position: fixed; left: 1rem; top: -5rem; z-index: 1000; background: #3525cd; color: white; padding: .65rem 1rem; border-radius: .5rem; }
.skip-link:focus { top: 1rem; }

/* ===== SHARED COMPONENT PATTERNS ===== */
.ui-btn { display: inline-flex; min-height: 2.5rem; align-items: center; justify-content: center; gap: .5rem; border-radius: .5rem; padding: .5rem 1rem; font-size: .8125rem; font-weight: 650; letter-spacing: -.005em; line-height: 1.2; transition: all .15s ease; }
.ui-btn:active { transform: scale(.98); }
.ui-btn-primary { background: #4f46e5; color: #fff; }
.ui-btn-primary:hover { background: #3525cd; box-shadow: 0 4px 12px rgba(79,70,229,.3); }
.ui-btn-secondary { background: #fff; color: #0b1c30; border: 1px solid #c7c4d8; }
.ui-btn-secondary:hover { background: #eff4ff; border-color: #4f46e5; }
.ui-field { width: 100%; min-height: 2.5rem; border: 1px solid #c7c4d8; border-radius: .5rem; background: #fff; padding: .55rem .75rem; color: #0b1c30; transition: all .15s ease; }
.ui-field:focus { border-color: #3525cd; box-shadow: 0 0 0 3px rgba(53,37,205,.12); outline: 0; }
.ui-table-wrap { width: 100%; overflow-x: auto; overscroll-behavior-inline: contain; scrollbar-gutter: stable; }
.ui-table { width: 100%; border-collapse: collapse; }
.ui-table-wrap thead th { position: sticky; top: 0; z-index: 2; background: #f8f9ff; }
.ui-table tbody tr:focus-within { background: #eef2ff; }
.ui-table th { white-space: nowrap; text-align: left; font-size: .6875rem; text-transform: uppercase; letter-spacing: .04em; color: #464555; }
.ui-table th, .ui-table td { padding: .625rem .75rem; border-bottom: 1px solid #e2e8f0; }
.ui-modal-backdrop { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: 1rem; background: rgba(11,28,48,.55); backdrop-filter: blur(4px); }
.ui-modal { width: min(100%, 36rem); max-height: calc(100dvh - 2rem); overflow: auto; border-radius: .75rem; background: white; padding: 1.5rem; box-shadow: 0 24px 64px rgba(11,28,48,.25); }
.ui-status { display: flex; min-height: 12rem; flex-direction: column; align-items: center; justify-content: center; gap: .75rem; padding: 2rem; text-align: center; color: #464555; }
.ui-skeleton { border-radius: .35rem; background: linear-gradient(90deg,#eff4ff 25%,#dce9ff 37%,#eff4ff 63%); background-size: 400% 100%; animation: ui-shimmer 1.4s ease infinite; }
.ui-role-switcher { display: inline-flex; align-items: center; gap: .4rem; border: 1px solid #c7c4d8; border-radius: .5rem; background: #fff; padding: .25rem .5rem; color: #464555; }
.ui-role-switcher select { max-width: 10rem; border: 0; background: transparent; padding: .25rem 1.5rem .25rem .25rem; font-size: .75rem; font-weight: 600; color: #0b1c30; }
.ui-role-switcher select:focus { outline: 0; box-shadow: none; }
.ui-toast { position: fixed; right: 1rem; top: 5rem; z-index: 110; max-width: 22rem; border-radius: .75rem; background: #213145; color: #fff; padding: .875rem 1rem; box-shadow: 0 12px 32px rgba(11,28,48,.2); font-size: .8125rem; animation: toast-in .2s ease; }
@keyframes toast-in { from { opacity: 0; transform: translateY(-8px); } to { opacity: 1; transform: translateY(0); } }
@keyframes ui-shimmer { 0% { background-position: 100% 0; } 100% { background-position: 0 0; } }

/* ===== SIDEBAR NAV ===== */
.nav-section-label { font-size: 10px; font-weight: 700; letter-spacing: 0.08em; text-transform: uppercase; color: #aaa; padding: 0.875rem 0.75rem 0.25rem; user-select: none; }
.nav-link { display: flex; align-items: center; gap: 0.625rem; padding: 0.5rem 0.75rem; border-radius: 0.5rem; color: #464555; font-size: 0.8125rem; font-weight: 500; transition: all .15s ease; text-decoration: none; }
.nav-link:hover { background-color: #EEF2FF; color: #3525cd; }
.nav-link .nav-icon { font-size: 20px; flex-shrink: 0; opacity: 0.7; transition: opacity .15s; }
.nav-link:hover .nav-icon { opacity: 1; }
.nav-link.active { background-color: #4f46e5; color: #ffffff; font-weight: 600; box-shadow: 0 2px 8px rgba(79,70,229,.3); }
.nav-link.active .nav-icon { opacity: 1; }
.nav-link.active:hover { background-color: #4338ca; color: #fff; }
.sidebar-user-card { display: flex; align-items: center; gap: 0.625rem; padding: 0.625rem 0.75rem; border-radius: 0.5rem; border: 1px solid #e8eaf0; background: #f8f9ff; cursor: pointer; transition: all .15s ease; text-decoration: none; }
.sidebar-user-card:hover { background: #eef2ff; border-color: #c7c4d8; }
.sidebar-user-avatar { width: 2rem; height: 2rem; border-radius: 50%; background: linear-gradient(135deg, #4f46e5, #7c3aed); color: white; display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 700; flex-shrink: 0; }
.sidebar-user-name { font-size: 12px; font-weight: 600; color: #0b1c30; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.sidebar-user-role { font-size: 10px; color: #777587; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
aside[data-ui-drawer] > div:first-child { height: 52px !important; min-height: 52px; padding-top: 10px !important; padding-bottom: 10px !important; box-sizing: border-box; }

/* ===== CARDS ===== */
.card-level-1 { background-color: #ffffff; border: 1px solid #E8EAF0; box-shadow: 0 2px 8px rgba(0,0,0,0.06), 0 1px 2px rgba(0,0,0,0.04); border-radius: 0.625rem; transition: box-shadow .2s ease; }
.card-level-1:hover { box-shadow: 0 4px 16px rgba(0,0,0,0.09), 0 1px 4px rgba(0,0,0,0.05); }
.kpi-card { background: #fff; border: 1px solid #E8EAF0; border-radius: 0.625rem; padding: 1rem 1.125rem; box-shadow: 0 2px 8px rgba(0,0,0,0.06); transition: all .2s ease; position: relative; overflow: hidden; }
.kpi-card:hover { box-shadow: 0 6px 20px rgba(0,0,0,0.1); transform: translateY(-1px); }
.kpi-card-label { font-size: 10px; font-weight: 700; letter-spacing: 0.06em; text-transform: uppercase; color: #777587; margin-bottom: 0.5rem; }
.kpi-card-value { font-size: 1.875rem; font-weight: 700; color: #0b1c30; line-height: 1; }
.kpi-card-sub { font-size: 11px; color: #aaa; margin-top: 0.5rem; }
.kpi-card-icon { position: absolute; top: 0.875rem; right: 0.875rem; opacity: 0.1; font-size: 28px; color: #4f46e5; }
.kpi-card-trend-up { display: inline-flex; align-items: center; gap: 2px; background: #dcfce7; color: #15803d; font-size: 10px; font-weight: 700; padding: 2px 6px; border-radius: 99px; }
.kpi-card-trend-neutral { display: inline-flex; align-items: center; gap: 2px; background: #f1f5f9; color: #64748b; font-size: 10px; font-weight: 700; padding: 2px 6px; border-radius: 99px; }
.kpi-card-revenue { background: linear-gradient(135deg, #4f46e5 0%, #6366f1 60%, #818cf8 100%); border: none; color: white; }
.kpi-card-revenue .kpi-card-label { color: rgba(255,255,255,0.7); }
.kpi-card-revenue .kpi-card-value { color: white; }
.kpi-card-revenue .kpi-card-icon { color: white; opacity: 0.18; }

/* ===== HEADER ===== */
.breadcrumb { display: flex; align-items: center; gap: 0.375rem; font-size: 11px; font-weight: 600; color: #aaa; text-transform: uppercase; letter-spacing: 0.05em; }
.breadcrumb-sep { opacity: 0.5; font-size: 14px; }
.breadcrumb-current { color: #0b1c30; }
.header-search { position: relative; }
.header-search input { height: 34px; padding: 0 2.75rem 0 2rem; border: 1px solid #e8eaf0; border-radius: 8px; font-size: 12px; background: #f8f9ff; color: #0b1c30; transition: all .2s ease; }
.header-search input:focus { outline: none; border-color: #4f46e5; background: #fff; box-shadow: 0 0 0 3px rgba(79,70,229,.12); }
.header-search input::placeholder { color: #bbb; }
.header-search-icon { position: absolute; left: 0.5rem; top: 50%; transform: translateY(-50%); font-size: 16px; color: #bbb; pointer-events: none; }
.header-search-kbd { position: absolute; right: 0.5rem; top: 50%; transform: translateY(-50%); font-size: 9px; font-weight: 600; color: #bbb; background: #eee; border-radius: 3px; padding: 1px 4px; font-family: monospace; }
.header-role-pill { display: inline-flex; align-items: center; gap: 0.4rem; font-size: 12px; font-weight: 600; color: #464555; background: #f4f6fa; border: 1px solid #e8eaf0; border-radius: 99px; padding: 4px 10px 4px 6px; cursor: pointer; transition: all .15s ease; }
.header-role-pill:hover { background: #eef2ff; border-color: #c7c4d8; }
.ui-header-stack { position: sticky !important; inset: auto !important; top: 0 !important; z-index: 45; flex: 0 0 auto; width: 100%; background: #fff; }
.ui-header-stack > .ui-global-header, .ui-header-stack > .ui-subheader { position: relative !important; inset: auto !important; top: auto !important; }
.ui-global-header { position: sticky !important; inset: auto !important; top: 0 !important; z-index: 45 !important; height: 52px; flex: 0 0 52px; align-self: stretch; display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 0 1.25rem; background: #fff; border-bottom: 1px solid #e8eaf0; box-shadow: 0 1px 4px rgba(0,0,0,.05); }
.ui-global-header-main { display: flex; min-width: 0; flex: 1; align-items: center; gap: .75rem; }
.ui-global-header-actions { display: flex; flex-shrink: 0; align-items: center; gap: .5rem; }
.ui-header-icon-button { position: relative; display: inline-flex; width: 2rem; height: 2rem; align-items: center; justify-content: center; border: 0; border-radius: .5rem; background: transparent; color: #777587; }
.ui-header-icon-button:hover { background: #f4f6fa; color: #3525cd; }
.ui-quick-create { min-height: 2rem; align-items: center; justify-content: center; gap: .3rem; border: 1px solid #c7c4d8; border-radius: .5rem; padding: .35rem .7rem; background: #f8f9ff; color: #3525cd; font-size: .75rem; font-weight: 700; text-decoration: none; }
.ui-quick-create:hover { background: #eef2ff; border-color: #4f46e5; }
.ui-quick-create .material-symbols-outlined { font-size: 16px; }
.ui-demo-launcher { display: inline-flex; width: 2rem; height: 2rem; align-items: center; justify-content: center; border-radius: .5rem; background: #4f46e5; color: #fff; box-shadow: 0 2px 6px rgba(79,70,229,.25); }
.ui-demo-launcher:hover { background: #3525cd; }
.ui-demo-launcher .material-symbols-outlined { font-size: 18px; }
body > .ui-demo-launcher { position: fixed; right: .75rem; top: .65rem; z-index: 70; }
.ui-subheader { position: sticky !important; inset: auto !important; top: 52px !important; z-index: 40 !important; width: 100% !important; min-height: 52px; height: auto !important; flex: 0 0 auto; align-self: stretch; background: #fff !important; border-bottom: 1px solid #e8eaf0 !important; box-shadow: none !important; }
.ui-contextual-module-header { display: grid !important; grid-template-columns: minmax(180px,1fr) minmax(280px,460px) minmax(180px,1fr); min-height: 64px !important; align-items: center; gap: 1.25rem; padding: .5rem 1.5rem !important; }
.ui-contextual-module-title { font-size: 1rem; color: #0b1c30; }
.ui-contextual-module-title-group { display: grid; min-width: 0; gap: .1rem; }
.ui-contextual-module-title-group .ui-contextual-module-title { line-height: 1.1; }
.ui-contextual-module-title-group p { overflow: hidden; color: #777587; font-size: .65rem; line-height: 1.15; text-overflow: ellipsis; white-space: nowrap; }
.ui-contextual-module-search { display: flex; min-width: 0; align-items: center; }
.ui-contextual-module-actions { display: flex; justify-content: flex-end; align-items: center; gap: .75rem; }
.ui-contextual-module-header:has(.ui-contextual-filter-row) { grid-template-rows: auto auto; padding-bottom: .7rem !important; }
.ui-contextual-filter-row { grid-column: 1 / -1 !important; justify-self: stretch; display: grid !important; grid-template-columns: repeat(3,minmax(150px,190px)) minmax(260px,1fr) auto; align-items: center; gap: .55rem !important; box-sizing: border-box; width: 100% !important; min-width: 100% !important; max-width: none !important; margin: 0 !important; padding: .55rem !important; border-radius: .7rem !important; background: #fff; box-shadow: 0 1px 3px rgba(11,28,48,.05) !important; }
.ui-contextual-filter-row > * { min-height: 42px; margin: 0 !important; }
.ui-application-filter-control { width: 100% !important; min-width: 0 !important; max-width: none !important; }
.ui-application-filter-control > div { min-height: 42px; padding-top: .4rem !important; padding-bottom: .4rem !important; }
.ui-application-filter-search { width: 100% !important; min-width: 0 !important; padding: 0 !important; }
.ui-application-filter-search > div,.ui-application-filter-search input { min-height: 42px; }
.ui-application-filter-actions { display: flex; min-height: 42px; align-items: center; justify-content: flex-end; gap: .45rem; }
.ui-filter-count { display: inline-flex; min-height: 28px; align-items: center; border-radius: 999px; padding: .25rem .55rem; background: #eef2ff; color: #3525cd; font-size: .68rem; font-weight: 700; white-space: nowrap; }
.ui-filter-count[hidden] { display: none; }
.ui-context-content { padding-top: 1.25rem !important; }
.ui-page-shell { min-width: 0; flex: 1 1 0%; display: flex; flex-direction: column; }
.ui-page-shell-offset { margin-left: 220px; width: calc(100% - 220px); }
.ui-page-shell > .ui-contained-native-offset { margin-left: 0 !important; width: 100% !important; }
.ui-sidebar-collapse { position: absolute; top: 13px; right: -13px; z-index: 55; display: none; width: 26px; height: 26px; align-items: center; justify-content: center; border: 1px solid #e8eaf0; border-radius: 50%; background: #fff; color: #777587; box-shadow: 0 2px 8px rgba(11,28,48,.12); }
.ui-sidebar-collapse:hover { color: #3525cd; border-color: #c7c4d8; }
.ui-sidebar-collapse .material-symbols-outlined { font-size: 16px; transition: transform .2s ease; }
@media (min-width: 1024px) {
    .ui-sidebar-collapse { display: flex; }
    body.sidebar-collapsed aside[data-ui-drawer] { width: 64px !important; }
    body.sidebar-collapsed .ui-page-shell-offset, body.sidebar-collapsed .ui-native-offset { margin-left: 64px !important; width: calc(100% - 64px) !important; padding-left: 0 !important; }
    body.sidebar-collapsed aside > div:first-child > div:last-child,
    body.sidebar-collapsed aside > div:first-child > div > div:last-child,
    body.sidebar-collapsed aside nav > div,
    body.sidebar-collapsed aside nav a > span:last-child,
    body.sidebar-collapsed aside > div:last-child a > span:last-child,
    body.sidebar-collapsed aside > div:last-child .sidebar-user-card > span:last-child { display: none !important; }
    body.sidebar-collapsed aside nav { padding-left: 8px !important; padding-right: 8px !important; }
    body.sidebar-collapsed aside nav a, body.sidebar-collapsed aside > div:last-child a, body.sidebar-collapsed aside > div:last-child .sidebar-user-card { justify-content: center; padding-left: 8px !important; padding-right: 8px !important; }
    body.sidebar-collapsed aside > div:nth-child(2) :is(.ui-btn, button) { gap: 0 !important; font-size: 0 !important; padding-left: 8px !important; padding-right: 8px !important; }
    body.sidebar-collapsed aside > div:nth-child(2) :is(.ui-btn, button) .material-symbols-outlined { font-size: 18px !important; }
    body.sidebar-collapsed .ui-sidebar-collapse .material-symbols-outlined { transform: rotate(180deg); }
}
.ui-menu-anchor { position: relative; }
.ui-popover { position: absolute; z-index: 120; width: 15.5rem; overflow: hidden; border: 1px solid #e8eaf0; border-radius: .75rem; background: #fff; box-shadow: 0 14px 36px rgba(11,28,48,.16); color: #464555; }
.ui-popover[hidden] { display: none; }
.ui-role-menu { right: 0; top: calc(100% + .55rem); padding: .4rem; }
.ui-header-profile-anchor { flex: 0 0 auto; }
.ui-header-profile { display: inline-flex; width: 34px; height: 34px; align-items: center; justify-content: center; overflow: hidden; border: 1px solid #d9d8e5; border-radius: 50%; padding: 2px; background: #fff; color: #0b1c30; }
.ui-header-profile:hover { background: #f8f9ff; border-color: #c7c4d8; }
.ui-header-profile .sidebar-user-avatar { width: 28px; height: 28px; }
.ui-header-profile-copy { display: grid; line-height: 1.05; }
.ui-header-profile-copy strong { font-size: .72rem; }
.ui-header-profile-copy small { margin-top: .15rem; color: #777587; font-size: .58rem; }
.ui-account-menu { right: 0; top: calc(100% + .55rem); }
.ui-menu-item { width: 100%; display: flex; align-items: center; gap: .7rem; padding: .65rem .75rem; border-radius: .5rem; border: 0; background: transparent; color: #464555; text-align: left; font-size: .78rem; font-weight: 600; }
.ui-menu-item:hover, .ui-menu-item[aria-checked="true"] { background: #f4f6fa; color: #3525cd; }
.ui-menu-item .material-symbols-outlined { font-size: 18px; color: #4f46e5; }
.ui-menu-separator { height: 1px; margin: .35rem 0; background: #eef0f5; }
.ui-account-heading { padding: .8rem 1rem .65rem; border-bottom: 1px solid #eef0f5; }
.ui-account-heading strong { display: block; color: #0b1c30; font-size: .82rem; }
.ui-account-heading span { display: block; margin-top: .1rem; color: #777587; font-size: .7rem; }
.ui-account-menu .ui-menu-item { border-radius: 0; padding: .75rem 1rem; font-weight: 500; }
.ui-account-menu .ui-menu-item.danger { color: #dc2626; }
.ui-account-menu .ui-menu-item.danger .material-symbols-outlined { color: #dc2626; }
.eco-page { width: 100%; max-width: 1600px; margin: 0 auto; padding: 2rem; }
.eco-page-heading { display: flex; align-items: flex-end; justify-content: space-between; gap: 1rem; margin-bottom: 1.5rem; }
.eco-page-heading h1 { font-size: 1.75rem; line-height: 1.2; font-weight: 700; color: #0b1c30; }
.eco-page-heading h1:has(.eco-heading-icon) { display: flex; align-items: center; gap: .65rem; }
.eco-heading-icon { display: grid; width: 38px; height: 38px; place-items: center; border-radius: .65rem; background: #eef2ff; color: #4f46e5; font-size: 22px; }
.eco-section-title { display: flex; align-items: center; gap: .55rem; margin-bottom: 1rem; padding-bottom: .75rem; border-bottom: 1px solid #eef0f5; color: #0b1c30; font-size: 1rem; font-weight: 700; }
.eco-section-title .material-symbols-outlined { display: grid; width: 30px; height: 30px; place-items: center; border-radius: .5rem; background: #f4f6ff; color: #4f46e5; font-size: 18px; }
.ui-field-with-icon { position: relative !important; display: block; }
.ui-field-with-icon > .material-symbols-outlined { position: absolute !important; z-index: 2; left: .75rem; top: 50%; margin: 0 !important; transform: translateY(-50%); color: #777587; font-size: 18px; pointer-events: none; }
.ui-field-with-icon > .ui-field { padding-left: 2.35rem !important; }
.ui-field-with-icon:focus-within > .material-symbols-outlined { color: #4f46e5; }
.eco-page-heading p { margin-top: .3rem; color: #64748b; font-size: .875rem; }
.eco-card { border: 1px solid #d9d8e5; border-radius: .75rem; background: #fff; padding: 1.25rem; box-shadow: 0 1px 3px rgba(11,28,48,.05); }
.settings-detail-layout { display: grid; grid-template-columns: 250px minmax(0,1fr); gap: 2rem; align-items: start; }
.settings-detail-nav { display: grid; gap: .35rem; }
.settings-detail-tab { display: flex; align-items: center; gap: .75rem; min-height: 44px; padding: .65rem 1rem; border: 1px solid transparent; border-radius: .65rem; color: #464555; font-size: .875rem; text-decoration: none; }
.settings-detail-tab:hover { background: #fff; border-color: #e8eaf0; }
.settings-detail-tab.active { background: #fff; border-color: #c7c4d8; color: #3525cd; box-shadow: 0 1px 2px rgba(11,28,48,.04); }
.settings-detail-tab .material-symbols-outlined { font-size: 20px; }
.settings-detail-content label:not(.settings-toggle) { display: grid; gap: .35rem; color: #464555; font-size: .75rem; font-weight: 600; }
.settings-toggle { display: flex; align-items: center; justify-content: space-between; gap: 1rem; border: 1px solid #e8eaf0; border-radius: .65rem; padding: 1rem; }
.settings-toggle span { display: grid; gap: .2rem; }
.settings-toggle small { color: #777587; font-weight: 400; }
.settings-plan { display: flex; align-items: flex-start; justify-content: space-between; gap: 1rem; border-radius: .75rem; padding: 1.25rem; background: #f4f6ff; }
.settings-plan div { display: grid; gap: .25rem; }
.settings-plan strong { font-size: 1.5rem; color: #3525cd; }
.settings-plan small { color: #64748b; }
.country-grid { display: grid; grid-template-columns: repeat(auto-fit,minmax(260px,1fr)); gap: 1rem; }
.country-card { position: relative; overflow: hidden; border: 1px solid #d9d8e5; border-radius: .85rem; padding: 1.2rem; background: #fff; box-shadow: 0 2px 8px rgba(11,28,48,.05); }
.country-card::before { position: absolute; inset: 0 auto 0 0; width: 4px; background: var(--country-color); content: ''; }
.country-card-head,.country-card-actions { display: flex; align-items: center; justify-content: space-between; gap: .75rem; }
.country-flag { display: grid; width: 46px; height: 46px; place-items: center; border-radius: .75rem; background: #f4f6ff; font-size: 1.65rem; }
.country-card h2 { margin-top: .75rem; font-size: 1.1rem; font-weight: 700; }
.country-meta { display: grid; grid-template-columns: 1fr 1fr; gap: .8rem; margin: 1rem 0; }
.country-meta span { display: grid; gap: .1rem; }.country-meta small { color: #777587; font-size: .65rem; }.country-meta strong { font-size: .78rem; }
.eco-card h2 { font-size: 1rem; font-weight: 700; }
.eco-form-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 1rem; margin-top: 1rem; }
.eco-compact-form { padding-top: 1rem; padding-bottom: 1rem; }
.eco-form-card-heading { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding-bottom: .9rem; border-bottom: 1px solid #eef0f5; }
.eco-form-card-heading h1 { display: flex; align-items: center; gap: .55rem; font-size: 1rem; font-weight: 700; }
.eco-form-card-heading h1 .material-symbols-outlined { display: grid; width: 30px; height: 30px; place-items: center; border-radius: .5rem; background: #eef2ff; color: #4f46e5; font-size: 18px; }
.eco-form-card-heading p { margin-top: .2rem; color: #64748b; font-size: .7rem; }
.eco-compact-form .eco-form-grid { gap: .75rem 1rem; margin-top: .9rem; }
.eco-compact-form .ui-field { min-height: 42px; }
#class-add-form, #event-add-form, #academic-add-form { width: min(100%,64rem); max-width: 64rem; margin-inline: auto; }
.academic-form-tools { display:flex; flex-wrap:wrap; align-items:center; gap:.5rem; margin-top:1rem; border-radius:.6rem; padding:.65rem .75rem; background:#f4f6ff; color:#64748b; font-size:.72rem; }
.academic-form-tools a { border-radius:999px; padding:.3rem .65rem; background:#fff; color:#3525cd; font-weight:700; text-decoration:none; }
.academic-form-tools a:hover { background:#eef2ff; }
.academic-record-row { display:flex; align-items:center; justify-content:space-between; gap:.75rem; border:1px solid #eef0f5; border-radius:.6rem; padding:.65rem .75rem; background:#fafbff; }
.academic-record-row strong, .academic-record-row small { display:block; }
.academic-record-row strong { color:#0b1c30; font-size:.78rem; }
.academic-record-row small { margin-top:.15rem; color:#777587; font-size:.66rem; }
.eco-toolbar:has(> :nth-child(3):last-child) { grid-template-columns:minmax(16rem,1fr) 13rem 13rem; }
.student-create-page { max-width: 64rem; padding-top:1.5rem; }
.student-create-intro { display:flex; align-items:flex-end; justify-content:space-between; gap:1.5rem; margin-bottom:1.25rem; }
.student-create-intro h1 { margin-top:.2rem; color:#0b1c30; font-size:1.65rem; font-weight:700; }
.student-create-intro p { margin-top:.25rem; color:#64748b; font-size:.82rem; }
.student-create-eyebrow { color:#4f46e5; font-size:.68rem; font-weight:700; letter-spacing:.06em; text-transform:uppercase; }
.student-create-form { overflow:hidden; border:1px solid #e1e5ec; border-radius:.9rem; background:#fff; box-shadow:0 4px 18px rgba(11,28,48,.045); }
.student-form-section { padding:1.8rem 2rem; }
.student-form-section + .student-form-section { border-top:1px solid #eef0f5; }
.student-form-section-heading { display:flex; align-items:center; gap:.7rem; }
.student-form-section-heading > .material-symbols-outlined { color:#697386; font-size:18px; }
.student-form-section-heading h2 { color:#0b1c30; font-size:1rem; font-weight:700; }
.student-form-section-heading p { margin-top:.15rem; color:#7c8799; font-size:.72rem; }
.student-create-form label > span:first-child { color:#334155; font-size:.72rem; font-weight:650; letter-spacing:.005em; }
.student-create-form .ui-field { color:#0f253d; font-size:.84rem; line-height:1.35; }
.student-create-form .ui-field::placeholder { color:#9299a8; font-weight:400; }
.student-form-actions { display:flex; align-items:center; justify-content:space-between; gap:1rem; border-top:1px solid #edf0f4; padding:1.15rem 2rem; background:#fff; }
.student-form-actions > span strong, .student-form-actions > span small { display:block; }
.student-form-actions > span strong { font-size:.78rem; }
.student-form-actions > span small { margin-top:.15rem; color:#777587; font-size:.66rem; }
.student-form-actions > div { display:flex; gap:.6rem; }
@media (max-width:767px) { .student-create-intro, .student-form-actions { align-items:stretch; flex-direction:column; } .student-form-section { padding:1rem; } .student-form-actions > div { display:grid; grid-template-columns:1fr 1fr; } }

/* Calm, retail-inspired creation form language: filled fields and restrained chrome. */
.student-create-form .eco-form-grid,
#class-add-form .eco-form-grid,
#event-add-form .eco-form-grid,
#academic-add-form .eco-form-grid { gap:1.15rem 1.25rem; }
.student-create-form .ui-field-with-icon > .material-symbols-outlined,
#class-add-form .ui-field-with-icon > .material-symbols-outlined,
#event-add-form .ui-field-with-icon > .material-symbols-outlined,
#academic-add-form .ui-field-with-icon > .material-symbols-outlined { display:none; }
.student-create-form .ui-field-with-icon > .ui-field,
#class-add-form .ui-field-with-icon > .ui-field,
#event-add-form .ui-field-with-icon > .ui-field,
#academic-add-form .ui-field-with-icon > .ui-field { min-height:50px; border-color:#e3e7ed; border-radius:.65rem; padding:.75rem .85rem!important; background:#f7f8fa; box-shadow:none; }
.student-create-form .ui-field:focus,
#class-add-form .ui-field:focus,
#event-add-form .ui-field:focus,
#academic-add-form .ui-field:focus { border-color:#7169ef; background:#fff; box-shadow:0 0 0 3px rgba(79,70,229,.1); }
#class-add-form, #event-add-form, #academic-add-form { border-color:#e1e5ec; border-radius:.9rem; padding:2rem; box-shadow:0 4px 18px rgba(11,28,48,.045); }
#class-add-form .eco-form-card-heading,
#event-add-form .eco-form-card-heading,
#academic-add-form .eco-form-card-heading { align-items:flex-start; padding-bottom:1.25rem; }
#class-add-form .eco-form-card-heading h1,
#event-add-form .eco-form-card-heading h1,
#academic-add-form .eco-form-card-heading h1 { font-size:1.35rem; }
#class-add-form .eco-form-card-heading h1 .material-symbols-outlined,
#event-add-form .eco-form-card-heading h1 .material-symbols-outlined,
#academic-add-form .eco-form-card-heading h1 .material-symbols-outlined { display:none; }
#class-add-form label > span:first-child,
#event-add-form label > span:first-child,
#academic-add-form label > span:first-child { margin-bottom:.4rem; color:#405066; font-size:.72rem; font-weight:650; }
#class-add-form > .flex:last-child,
#event-add-form > .flex:last-child,
#academic-add-form > .flex:last-child { align-items:center; gap:.7rem; margin-top:1.75rem; }
.create-form-cancel { margin-right:auto; border-color:transparent; background:transparent; }
#event-add-form textarea.ui-field { min-height:120px; border-color:#e3e7ed; border-radius:.65rem; padding:.85rem; background:#f7f8fa; box-shadow:none; }
#class-add-form .ui-btn-primary,
#event-add-form .ui-btn-primary,
#academic-add-form .ui-btn-primary,
.student-form-actions .ui-btn { min-height:46px; padding-inline:1.25rem; }
.eco-intake-picker { min-width: 0; }
.eco-intake-picker legend { margin-bottom: .35rem; color: #0b1c30; font-size: .75rem; font-weight: 600; }
.eco-intake-picker > div { display: flex; flex-wrap: wrap; gap: .4rem; }
.eco-intake-picker label { cursor: pointer; }
.eco-intake-picker input { position: absolute; opacity: 0; pointer-events: none; }
.eco-intake-picker label span { display: inline-flex; min-height: 34px; align-items: center; border: 1px solid #c7c4d8; border-radius: 999px; padding: .35rem .7rem; background: #fff; color: #464555; font-size: .72rem; }
.eco-intake-picker input:checked + span { border-color: #4f46e5; background: #eef2ff; color: #3525cd; font-weight: 700; }
.eco-intake-picker input:focus-visible + span { outline: 3px solid rgba(53,37,205,.25); outline-offset: 2px; }
.eco-intake-picker small { display: block; margin-top: .35rem; color: #777587; font-size: .65rem; }
.eco-toolbar { display: grid; grid-template-columns: minmax(16rem,1fr) 12rem 12rem auto; gap: .75rem; margin-bottom: 1rem; }
.eco-kanban { display: grid; grid-template-columns: repeat(5,minmax(15rem,1fr)); gap: 1rem; overflow-x: auto; padding-bottom: .75rem; }
.eco-kanban > section { border-radius: .75rem; background: #eef2ff; padding: .75rem; }
.eco-kanban > section > h2 { display: flex; justify-content: space-between; margin-bottom: .75rem; font-size: .8rem; font-weight: 700; }
.eco-kanban > section > h2 span, .ui-badge { display: inline-flex; align-items: center; border: 1px solid #c7c4d8; border-radius: 999px; background: #f8f9ff; padding: .15rem .5rem; font-size: .68rem; font-weight: 600; }
.eco-kanban-card { display: block; margin-bottom: .6rem; border: 1px solid #e2e8f0; border-radius: .6rem; background: #fff; padding: .75rem; }
.eco-kanban-card span, .eco-kanban-card small { display: block; margin-top: .25rem; color: #64748b; }
@media (max-width: 767px) { .eco-page { padding: 1rem; } .eco-page-heading { align-items: stretch; flex-direction: column; } .eco-form-grid { grid-template-columns: 1fr; } .eco-toolbar { grid-template-columns: 1fr; } }

@media (max-width: 767px) {
    .ui-contextual-module-header { grid-template-columns: auto minmax(0,1fr); }
    .ui-contextual-module-actions { display: none; }
    .ui-contextual-filter-row { overflow-x: auto; }
    .ui-context-content { padding-top: 1rem !important; }
    .settings-detail-layout { grid-template-columns: 1fr; gap: 1rem; }
    .settings-detail-nav { display: flex; overflow-x: auto; padding-bottom: .25rem; }
    .settings-detail-tab { flex: 0 0 auto; }
    button, .ui-btn, .nav-link, input, select { min-height: 44px; }
    .ui-table th, .ui-table td { padding: .7rem .75rem; }
}
@media (max-width: 1199px) {
    .dashboard-primary-grid,
    .dashboard-ops-grid { grid-template-columns: 1fr !important; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* ===== REFERENCE-LED PRODUCT REFRESH ===== */
:root {
    --ui-canvas: #f6f7fa;
    --ui-card: #ffffff;
    --ui-field-bg: #f5f6f8;
    --ui-border: #e1e5eb;
    --ui-border-strong: #d5dae3;
    --ui-text: #10243b;
    --ui-muted: #708096;
    --ui-primary: #4f46e5;
    --ui-primary-hover: #4038cf;
    --ui-radius: 12px;
}
body { background:var(--ui-canvas); color:var(--ui-text); }
.ui-page-shell, main { min-width:0; }
.eco-page { max-width:1440px; padding:1.75rem 2rem 2.5rem; }
.eco-page-heading { align-items:center; margin-bottom:1.25rem; }
.eco-page-heading h1 { font-size:1.45rem; letter-spacing:-.025em; }
.eco-page-heading p { max-width:46rem; color:var(--ui-muted); font-size:.78rem; line-height:1.5; }
.card-level-1, .eco-card, .kpi-card { border-color:var(--ui-border); border-radius:var(--ui-radius); box-shadow:0 2px 10px rgba(16,36,59,.045); }
.card-level-1:hover, .eco-card:hover { box-shadow:0 5px 18px rgba(16,36,59,.065); }
.ui-btn { min-height:44px; border-radius:10px; padding:.65rem 1.05rem; }
.ui-btn-primary { background:var(--ui-primary); box-shadow:0 4px 10px rgba(79,70,229,.16); }
.ui-btn-primary:hover { background:var(--ui-primary-hover); box-shadow:0 6px 16px rgba(79,70,229,.22); }
.ui-btn-secondary { border-color:var(--ui-border-strong); background:#fff; }
.ui-field { min-height:48px; border-color:transparent; border-radius:10px; padding:.72rem .85rem; background:var(--ui-field-bg); color:var(--ui-text); font-size:.84rem; box-shadow:inset 0 0 0 1px rgba(213,218,227,.7); }
.ui-field:hover { background:#f2f4f7; box-shadow:inset 0 0 0 1px var(--ui-border-strong); }
.ui-field:focus { border-color:transparent; background:#fff; box-shadow:0 0 0 3px rgba(79,70,229,.11),inset 0 0 0 1px #7169ef; }
.ui-field::placeholder { color:#9aa4b4; }
.eco-page .ui-field-with-icon > .material-symbols-outlined { display:none; }
.eco-page .ui-field-with-icon > .ui-field { padding-left:.85rem!important; }
.eco-form-grid { gap:1.15rem 1.25rem; }
.eco-form-grid label > span:first-child, .settings-detail-content label:not(.settings-toggle) { color:#405066; font-size:.72rem; font-weight:650; }
.eco-form-card-heading { align-items:flex-start; padding-bottom:1.2rem; }
.eco-form-card-heading h1 { font-size:1.3rem; letter-spacing:-.025em; }
.eco-form-card-heading p { margin-top:.3rem; color:var(--ui-muted); font-size:.73rem; line-height:1.5; }
.eco-form-card-heading h1 .material-symbols-outlined { display:none; }
.eco-toolbar { grid-template-columns:minmax(18rem,1fr) 13rem 13rem auto; gap:.65rem; }
.eco-toolbar .ui-field { background:#fff; box-shadow:inset 0 0 0 1px var(--ui-border-strong); }
.ui-table-wrap { border-radius:inherit; }
.ui-table-wrap thead th { background:#f6f7fa; }
.ui-table th { padding:.75rem .9rem; color:#536279; font-size:.65rem; letter-spacing:.055em; }
.ui-table td { padding:.85rem .9rem; border-color:#e8ebf0; font-size:.78rem; }
.ui-table tbody tr { transition:background .12s ease; }
.ui-table tbody tr:hover { background:#fafbff; }
.ui-badge { border-color:#d8dce5; background:#f8f9fb; padding:.22rem .55rem; color:#435168; }
.ui-global-header { border-color:var(--ui-border); box-shadow:0 1px 5px rgba(16,36,59,.04); }
.ui-subheader { border-color:var(--ui-border)!important; }
.ui-contextual-module-header { min-height:68px!important; padding:.65rem 1.65rem!important; }
.ui-contextual-module-title { font-size:.92rem; letter-spacing:-.015em; }
.ui-contextual-module-title-group p { color:var(--ui-muted); font-size:.65rem; }
.nav-link { min-height:40px; border-radius:9px; padding:.55rem .7rem; color:#415068; }
.nav-link.active { background:var(--ui-primary); box-shadow:0 4px 12px rgba(79,70,229,.18); }
.nav-section-label { padding:1rem .7rem .35rem; color:#9aa4b2; font-size:9px; }
.settings-detail-tab { border-radius:10px; }
.settings-detail-content { padding:1.6rem; }
.student-create-intro { max-width:60rem; margin-inline:auto; }
.student-create-form { max-width:60rem; margin-inline:auto; }
@media (max-width:1023px) {
    .eco-page { padding:1.25rem; }
    .eco-toolbar { grid-template-columns:1fr 1fr; }
    .eco-toolbar > :first-child { grid-column:1/-1; }
}
@media (max-width:767px) {
    .eco-page { padding:1rem; }
    .eco-page-heading { align-items:stretch; }
    .eco-toolbar { grid-template-columns:1fr; }
    .eco-toolbar > :first-child { grid-column:auto; }
    .student-create-intro { margin-bottom:1rem; }
}

/* ===== TABLES ===== */
.compact-table th { padding: 9px 12px; }
.compact-table td { padding: 9px 12px; }
.compact-table tbody tr { transition: background .15s; }
.compact-table tbody tr:hover { background: #f0f4ff; }
.compact-table tbody tr.priority-high { background: #fff8f8; }
.compact-table tbody tr.priority-high:hover { background: #fee8e8; }

/* ===== PIPELINE ===== */
.pipeline-bar-track { height: 8px; background: #f0f4ff; border-radius: 99px; overflow: hidden; flex: 1; }
.pipeline-bar-fill { height: 100%; border-radius: 99px; transition: width .7s cubic-bezier(.4,0,.2,1); }

/* ===== ALERTS ===== */
.alert-item { display: flex; align-items: flex-start; gap: 0.75rem; padding: 0.75rem; border-radius: 0.5rem; border: 1px solid transparent; position: relative; transition: all .15s ease; }
.alert-item:hover { box-shadow: 0 2px 8px rgba(0,0,0,0.07); }
.alert-dismiss { position: absolute; top: 0.5rem; right: 0.5rem; width: 18px; height: 18px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-size: 12px; color: #aaa; cursor: pointer; transition: all .15s; opacity: 0; }
.alert-item:hover .alert-dismiss { opacity: 1; }
.alert-dismiss:hover { background: rgba(0,0,0,.08); color: #464555; }

/* ===== BADGES ===== */
.badge { display: inline-flex; align-items: center; gap: 3px; font-size: 10px; font-weight: 700; padding: 2px 7px; border-radius: 99px; }
.badge-success { background: #dcfce7; color: #15803d; }
.badge-warning { background: #fef3c7; color: #b45309; }
.badge-error { background: #fee2e2; color: #dc2626; }
.badge-info { background: #dbeafe; color: #1d4ed8; }
.badge-neutral { background: #f1f5f9; color: #475569; }

/* ===== DRAWER & MOBILE ===== */
[data-ui-drawer] { transition: transform .2s ease, visibility .2s; }
.ui-drawer-backdrop { position: fixed; inset: 0; z-index: 45; background: rgba(11,28,48,.42); backdrop-filter: blur(2px); }
.ui-bottom-nav { padding-bottom: max(.5rem, env(safe-area-inset-bottom)); min-height: calc(4rem + env(safe-area-inset-bottom)); }
body:has(.ui-bottom-nav) { padding-bottom: calc(4.5rem + env(safe-area-inset-bottom)); }

/* ===== SCROLLBAR ===== */
.custom-scrollbar::-webkit-scrollbar { width: 5px; height: 5px; }
.custom-scrollbar::-webkit-scrollbar-track { background: transparent; }
.custom-scrollbar::-webkit-scrollbar-thumb { background-color: #d0d5e0; border-radius: 9999px; }
.custom-scrollbar::-webkit-scrollbar-thumb:hover { background-color: #9095a0; }
.hide-scrollbar::-webkit-scrollbar { display: none; }
.hide-scrollbar { -ms-overflow-style: none; scrollbar-width: none; }
.scrollbar-hide::-webkit-scrollbar { display: none; }
.scrollbar-hide { -ms-overflow-style: none; scrollbar-width: none; }

@media (max-width: 767px) {
    main { min-width: 0; }
    header { padding-left: 1rem !important; padding-right: 1rem !important; }
    table { font-size: .75rem; }
    [data-ui-drawer]:not(.ui-drawer-open) { display: none !important; }
    [data-ui-drawer].ui-drawer-open { display: flex !important; width: min(19rem, 86vw) !important; position: fixed !important; inset: 0 auto 0 0 !important; z-index: 60 !important; background: white !important; box-shadow: 16px 0 40px rgba(11,28,48,.2); }
    .ui-account-menu { position: fixed; left: 1rem; right: 1rem; top: 3.6rem; width: auto; }
    .ui-header-profile-copy { display: none; }
    .ui-global-header { padding: 0 .75rem !important; }
    .ui-global-header .header-search, .ui-global-header .breadcrumb { display: none !important; }
    .ui-subheader { top: 52px !important; overflow-x: auto; padding: .65rem 1rem !important; }
}
@media (max-width: 1023px) { .ui-page-shell-offset { margin-left: 0; width: 100%; } }
@media (min-width: 768px) and (max-width: 1199px) {
    .ui-contextual-filter-row { grid-template-columns: repeat(3,minmax(140px,1fr)); }
    .ui-application-filter-search { grid-column: 1 / 3; }
}
@media (min-width: 768px) and (max-width: 1023px) {
    .tablet-no-sidebar-offset { margin-left: 0 !important; }
    [data-ui-drawer][class*="lg:flex"]:not(.ui-drawer-open) { display: none !important; }
}
@media (prefers-reduced-motion: reduce) {
    *, *::before, *::after { scroll-behavior: auto !important; animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

