
:root {
  --ink: #172635;
  --muted: #55677a;
  --subtle: #647688;
  --bg: #f4f7fa;
  --white: #fff;
  --line: #e0e7ef;
  --brand-blue: #105886;
  --brand-blue-dark: #0b4268;
  --brand-cyan: #30afdf;
  --brand-cyan-dark: #0b779e;
  --brand-cyan-light: #ddf3fd;
  --brand-orange: #f37d32;
  --brand-orange-dark: #b74d13;
  --brand-soft: #eaf4fb;
  --brand-border: #b5d4e8;
  --nav: #102b45;
  --nav-active: #173f64;
  --nav-border: #35536d;
  --nav-text: #c6d8e6;
  --blue: var(--brand-blue);
  --blue-dark: var(--brand-blue-dark);
  --mint: var(--brand-cyan);
  --radius: 13px;
  --side: 240px;
  font: 14px/1.5 "Inter", "Segoe UI", sans-serif;
  color: var(--ink);
  background: var(--bg);
}
*, *::before, *::after { box-sizing: border-box; }
body { margin: 0; min-width: 300px; }
a { color: var(--blue-dark); text-decoration: none; }
a:hover { text-decoration: underline; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
:focus-visible { outline: 3px solid var(--brand-blue); outline-offset: 3px; }
h1,h2,h3,p { margin: 0; }
h1 { font-size: clamp(25px,3.1vw,35px); line-height: 1.22; letter-spacing: -.045em; }
h2 { font-size: 18px; line-height: 1.35; letter-spacing: -.025em; }
h3 { font-size: 15px; }
p { color: var(--muted); }
.hou-registration-note { white-space: pre-wrap; overflow-wrap: anywhere; }
.sidebar {
  width: var(--side); position: fixed; inset: 0 auto 0 0; z-index: 5;
  display: flex; flex-direction: column; padding: 28px 17px 18px;
  color: var(--white); background: var(--nav); overflow-y: auto;
}
.brand { display: flex; gap: 11px; align-items: center; font-size: 24px; font-weight: 800; letter-spacing: -.055em; line-height: 1; color: white; }
.sidebar .brand { margin: 0 7px 27px; }
.brand:hover { text-decoration: none; }
.brand small { font-size: 15px; color: #c5d6df; font-weight: 600; letter-spacing: .02em; }
.brand-mark { width: 43px; height: 43px; display: grid; place-items: center; background: var(--brand-blue); border: 1px solid var(--brand-cyan); border-radius: 11px; color: white; flex: none; }
.brand-accent { color: var(--mint); }
.brand-label { display: block; color: #a3b8c7; font-size: 9px; letter-spacing: .14em; margin-top: 7px; font-weight: 700; }
.brand-identity { flex-direction: column; align-items: stretch; gap: 0; min-width: 0; max-width: 100%; }
.brand-logo-plate { display: grid; place-items: center; width: 100%; min-width: 0; height: 94px; padding: 8px 10px; background: white; border: 1px solid var(--brand-border); border-radius: 11px; }
.brand-logo { display: block; width: 100%; height: 100%; min-width: 0; min-height: 0; max-width: 100%; max-height: 100%; object-fit: contain; }
.sidebar .brand-identity { width: 100%; margin: 0 0 24px; }
.brand-identity .brand-label { color: var(--nav-text); text-align: center; font-size: 10px; line-height: 1.5; letter-spacing: .14em; margin-top: 8px; }
.sidebar .brand-identity:focus-visible, .nav-link:focus-visible, .sidebar .menu-close:focus-visible { outline-color: var(--brand-cyan); }
.nav-section { margin-top: 17px; }
.nav-heading { font-size: 11px; line-height: 1.5; letter-spacing: .095em; text-transform: uppercase; font-weight: 750; color: #b8cad6; padding-left: 12px; margin-bottom: 5px; }
.nav-utilities { border-top: 1px solid var(--nav-border); padding-top: 13px; }
.nav-utilities .nav-heading { color: #9cb1c0; }
.nav-link { display: flex; align-items: center; gap: 12px; padding: 11px 12px; margin-bottom: 3px; border-radius: 8px; color: var(--nav-text); font-weight: 500; }
.nav-link:hover { color: white; background: var(--nav-active); text-decoration: none; }
.nav-link.active { color: white; background: var(--nav-active); box-shadow: inset 3px 0 var(--brand-orange); font-weight: 650; }
.sidebar-bottom { margin-top: auto; display: flex; align-items: center; gap: 10px; padding: 14px 12px 6px; border-top: 1px solid var(--nav-border); }
.sidebar-bottom small, .sidebar-bottom strong { display: block; }
.sidebar-bottom small { color: #a8becb; margin-top: 3px; }
.environment-dot { height: 8px; width: 8px; border-radius: 50%; background: #64dfb9; box-shadow: 0 0 0 4px #22534f; flex: none; }
.workspace { margin-left: var(--side); min-width: 0; }
.topbar { height: 67px; background: white; border-bottom: 1px solid var(--line); display: flex; align-items: center; justify-content: space-between; padding: 0 31px; gap: 12px; }
.breadcrumb, .account { display: flex; align-items: center; gap: 11px; }
.breadcrumb { color: #6a7a8a; font-size: 13px; }
.breadcrumb a { color: #43596c; }
.breadcrumb span { font-weight: 600; color: var(--ink); }
.account { margin-left: auto; }
.avatar { width: 34px; height: 34px; border-radius: 50%; background: var(--brand-soft); display: grid; place-items: center; color: var(--brand-blue); font-weight: 750; }
.account-name strong, .account-name small { display: block; font-size: 12px; white-space: nowrap; }
.account-name small { color: var(--muted); font-size: 11px; }
.icon-button { display: inline-flex; padding: 6px; color: #4c6577; background: transparent; border: 0; border-radius: 6px; align-items: center; }
.icon-button:hover { background: #edf3f5; color: #12293a; }
.menu-toggle { display: none; }
.main { max-width: 1540px; margin: auto; padding: 30px 30px 18px; }
.app-footer { color: var(--subtle); padding: 8px 30px 25px; font-size: 11px; max-width: 1540px; margin: auto; }
.overview-header, .page-header { display: flex; gap: 15px; justify-content: space-between; align-items: flex-start; margin-bottom: 22px; }
.overview-header p, .page-header p { margin-top: 6px; }
.page-header > *, .overview-header > * { min-width: 0; }
.date-chip { border: 1px solid var(--line); background: white; border-radius: 8px; padding: 8px 11px; display: inline-flex; gap: 8px; align-items: center; white-space: nowrap; color: #355365; font-size: 12px; }
.hero { background: linear-gradient(108deg,var(--nav) 0%,var(--brand-blue-dark) 54%,var(--brand-blue) 100%); color: white; min-height: 225px; border-radius: 16px; position: relative; overflow: hidden; display: flex; align-items: center; padding: 32px 34px; }
.hero-copy { z-index: 1; max-width: 68%; }
.hero-eyebrow { font-size: 10px; letter-spacing: .15em; color: var(--brand-cyan-light); font-weight: 700; display: flex; gap: 9px; align-items: center; }
.hero-eyebrow span { width: 6px; height: 6px; border-radius: 50%; background: var(--brand-orange); }
.hero h2 { font-size: clamp(26px,4vw,43px); line-height: 1.12; margin: 12px 0 9px; letter-spacing: -.055em; }
.hero p { color: #d2e4eb; margin-bottom: 20px; }
.hero .hero-button { background: var(--brand-cyan-light); color: var(--brand-blue-dark); border-color: var(--brand-cyan-light); }
.hero .hero-button:hover { background: white; }
.hero-art { position: absolute; inset: 0 0 0 auto; width: 41%; display: grid; place-items: center; }
.hero-art::before { content: ""; position: absolute; inset: 0; opacity: .27; background-image: radial-gradient(var(--brand-cyan) 1px, transparent 1px); background-size: 13px 13px; mask-image: linear-gradient(90deg,transparent,#000); }
.hero-art i { position: absolute; width: 205px; height: 205px; border: 1px solid rgb(48 175 223 / 28%); border-radius: 50%; }
.hero-art i:nth-child(2) { width: 265px; height: 265px; }
.hero-art i:nth-child(3) { width: 325px; height: 325px; }
.hero-emblem { width: 135px; height: 135px; border: 1px solid rgb(48 175 223 / 45%); border-radius: 35px; transform: rotate(-10deg); display: grid; place-items: center; color: var(--brand-cyan-light); background: linear-gradient(145deg,var(--brand-blue),var(--brand-blue-dark)); box-shadow: 0 19px 42px #092b3f88; }
.hero-emblem svg { transform: rotate(10deg); }
.hero-art b { position: absolute; height: 7px; width: 7px; border-radius: 50%; background: var(--brand-orange); top: 24%; right: 22%; }
.hero-art b:nth-last-child(2) { top: 74%; right: 79%; width: 5px; height: 5px; }
.hero-art b:last-child { top: 63%; right: 15%; width: 4px; height: 4px; }
.overview-stats, .stat-grid { display: grid; grid-template-columns: repeat(4,minmax(0,1fr)); gap: 15px; margin: 19px 0; }
.metric-card, .card { background: var(--white); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: 0 2px 3px #15365205; }
.metric-card { display: grid; justify-items: start; padding: 16px 17px; min-width: 0; }
.metric-card strong { font-size: 30px; line-height: 1.15; letter-spacing: -.045em; margin-top: 4px; }
.metric-card small { color: var(--subtle); margin-top: 5px; font-size: 11px; }
a.metric-card { color: inherit; text-decoration: none; }
a.metric-card:hover { border-color: var(--brand-border); text-decoration: none; }
.metric-label { color: var(--muted); font-weight: 600; font-size: 12px; margin-top: 9px; }
.academic-review-link { position: relative; color: var(--ink); padding-right: 42px; }
.academic-review-link:hover, .academic-review-link[aria-current] { border-color: var(--brand-border); text-decoration: none; }
.academic-review-link[aria-current] { background: var(--brand-soft); }
.academic-review-link-arrow { position: absolute; right: 16px; bottom: 18px; color: var(--blue-dark); }
#danh-sach-phu-luc { scroll-margin-top: 16px; }
.academic-appendix-student-code > a { display: block; }
.tile-icon { width: 35px; height: 35px; border-radius: 8px; display: inline-grid; place-items: center; flex: none; }
.tile-icon.blue { background: var(--brand-soft); color: var(--brand-blue); }
.tile-icon.green { background: #dff5ed; color: #08765d; }
.tile-icon.amber { background: #fff0d9; color: #875109; }
.tile-icon.violet { background: #eee9fa; color: #654996; }
.overview-panels { display: grid; grid-template-columns: 1.14fr 1fr; gap: 17px; }
.card { padding: 18px; margin-bottom: 16px; min-width: 0; }
.card h2 + p, .card-heading p { margin-top: 4px; font-size: 12px; }
.card h2:not(:last-child), .card h3:not(:last-child) { margin-bottom: 7px; }
.card-heading { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; margin-bottom: 14px; }
.card-heading h2 { margin-bottom: 0 !important; }
.distribution { display: grid; gap: 14px; }
.bar-item > div:first-child { display: flex; justify-content: space-between; gap: 10px; font-size: 12px; margin-bottom: 4px; }
.bar { height: 6px; background: #edf3f6; border-radius: 20px; overflow: hidden; }
.bar i { height: 100%; display: block; background: linear-gradient(90deg,var(--brand-blue),var(--brand-cyan-dark)); border-radius: 20px; }
.quick-list a { display: flex; align-items: center; gap: 10px; color: var(--ink); padding: 8px 0; border-bottom: 1px solid #ecf1f5; }
.quick-list a:last-child { border: 0; }
.quick-list a > span:nth-child(2) { flex: 1; }
.quick-list strong, .quick-list small { display: block; font-size: 12px; }
.quick-list small { color: var(--muted); font-size: 11px; }
.quick-list a:hover { color: var(--blue); text-decoration: none; }
.button { border: 1px solid #cfdae4; background: white; color: #234458; padding: 8px 12px; border-radius: 7px; font-weight: 650; font-size: 13px; line-height: 1.45; display: inline-flex; justify-content: center; align-items: center; gap: 7px; text-decoration: none; min-height: 36px; }
.button:hover { background: var(--brand-soft); color: var(--brand-blue-dark); text-decoration: none; }
.button.primary, button.primary { background: var(--brand-blue); border-color: var(--brand-blue); color: white; }
.button.primary:hover, button.primary:hover { background: var(--brand-blue-dark); border-color: var(--brand-blue-dark); }
.button.compact { min-height: 31px; padding: 6px 8px; font-size: 11px; }
.button.danger { color: #982e35; }
.toolbar, .actions, .row-actions { display: flex; gap: 8px; flex-wrap: wrap; align-items: center; }
.toolbar { margin: 0 0 14px; }
.toolbar form { display: flex; gap: 8px; flex-wrap: wrap; align-items: end; }
.table-pagination { display: flex; flex-wrap: wrap; align-items: center; gap: 8px 12px; margin: 12px 0; font-size: 12px; }
.table-pagination-range { margin-inline-end: auto; }
.table-pagination-size, .table-pagination-size label, .table-pagination-pages, .table-pagination-jump, .table-pagination-jump label { display: flex; flex-wrap: wrap; align-items: center; gap: 7px; }
.table-pagination select { width: auto; min-height: 31px; margin: 0; padding-block: 4px; }
.table-pagination-jump { margin: 0; }
.table-pagination-pages { white-space: nowrap; }
.table-pagination .button:disabled { opacity: .55; cursor: default; background: white; }
.table-row-number { width: 1%; text-align: right; white-space: nowrap; font-variant-numeric: tabular-nums; }
@media screen {
  tr.table-pagination-hidden { display: none; }
}
@media print {
  .table-pagination { display: none; }
}
.student-roster-metrics.stat-grid { gap: 8px; margin: 12px 0; }
.student-roster-metrics > .metric-card {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
  gap: 8px;
  min-height: 46px;
  padding: 8px 12px;
}
.student-roster-metrics .metric-label { margin: 0; line-height: 1.35; }
.student-roster-metrics .metric-card > strong {
  margin: 0;
  font-size: 22px;
  letter-spacing: -.025em;
  white-space: nowrap;
  font-variant-numeric: tabular-nums;
}
@media (min-width: 1024px) {
  .student-roster-metrics.stat-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); }
}
.card.student-roster { padding-block-start: 12px; }
.student-roster-heading.card-heading {
  align-items: center;
  flex-wrap: wrap;
  gap: 6px 12px;
  margin-bottom: 8px;
}
.student-roster-heading > .toolbar { gap: 6px; margin-bottom: 0; }
.student-list-filters {
  container-name: student-list-filters;
  container-type: inline-size;
  padding: 8px 10px;
  margin-bottom: 8px;
  background: #f7f9fb;
  border: 1px solid var(--line);
  border-radius: 9px;
}
.student-filter-profile {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 6px 8px;
  align-items: start;
}
.student-filter-search { grid-column: 1 / -1; }
.student-filter-controls {
  display: grid;
  grid-template-columns: minmax(0, 1fr);
  gap: 6px 12px;
  align-items: end;
  border-top: 1px solid var(--line);
  margin-top: 6px;
  padding-top: 5px;
}
.workflow-mobile .student-filter-dates, .student-filter-dates {
  min-width: 0;
  border: 0;
  margin: 0;
  padding: 0;
}
.workflow-mobile .student-filter-dates legend, .student-filter-dates legend {
  padding: 0;
  margin: 0 0 2px;
  color: var(--ink);
  font-size: 12px;
  font-weight: 700;
}
.student-filter-dates > div, .student-filter-actions {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 8px;
  align-items: start;
}
.student-filter-actions { grid-template-columns: minmax(0, 1fr) auto; align-items: end; }
.student-filter-dates .student-time-order { grid-column: 1 / -1; }
.student-filter-time-help { margin-top: 4px; }
.student-list-filters label { min-width: 0; }
#danh-sach-sinh-vien .student-list-filters :is(.button, input:not([type="hidden"]), select) {
  min-height: 34px;
  padding-block: 5px;
}
#danh-sach-sinh-vien .student-list-filters :is(input:not([type="hidden"]), select) { margin-top: 2px; }
.student-list-filters .button { padding-inline: 16px; }
@container student-list-filters (min-width: 430px) {
  .student-filter-dates > div { grid-template-columns: repeat(3, minmax(0, 1fr)); }
  .student-filter-dates .student-time-order { grid-column: auto; }
}
@container student-list-filters (min-width: 680px) {
  .student-filter-controls { grid-template-columns: minmax(0, 1fr) auto; }
  .student-filter-actions { grid-template-columns: minmax(110px, 140px) auto; }
}
@container student-list-filters (min-width: 700px) {
  .student-filter-profile { grid-template-columns: minmax(210px, 1.55fr) minmax(134px, 1fr) minmax(134px, 1fr) minmax(74px, .55fr) minmax(75px, .55fr); }
  .student-filter-search { grid-column: auto; }
}
@container student-list-filters (max-width: 290px) {
  .student-filter-dates > div { grid-template-columns: minmax(0, 1fr); }
}
@media (max-width: 800px), (pointer: coarse) {
  #danh-sach-sinh-vien .student-list-filters :is(.button, input:not([type="hidden"]), select) { min-height: 44px; }
  .student-roster-heading .button { min-height: 44px; }
}
.badge, .tag { display: inline-flex; align-items: center; background: #e8f0f5; color: #294b61; border-radius: 25px; padding: 3px 8px; font-size: 11px; font-weight: 650; white-space: nowrap; }
.badge.good, .badge.success { background: #def3ec; color: #12684f; }
.badge.warning, .badge.amber { background: #fff1d9; color: #804d10; }
.badge.danger { background: #fdebec; color: #932b36; }
.table-wrap { width: 100%; overflow: auto; border: 1px solid #e9eef2; border-radius: 8px; }
@media screen {
  .table-wrap:has(> table > thead) {
    max-block-size: min(68vh, 42rem);
    overflow-y: auto;
    scrollbar-gutter: stable;
    scrollbar-color: #91a6b4 #edf2f6;
  }
  .table-wrap > table > thead {
    position: sticky;
    top: 0;
    z-index: 3;
  }
}
table { width: 100%; border-collapse: collapse; background: white; text-align: left; font-size: 13px; }
th { padding: 9px 11px; background: #f2f6f8; color: #3f5666; font-size: 11px; font-weight: 700; text-align: left; }
td { padding: 9px 11px; border-top: 1px solid #eaf0f4; vertical-align: middle; }
tbody tr:hover { background: #f9fbfc; }
td .button { font-size: 11px; min-height: 27px; padding: 3px 7px; }
.code, .amount { font-variant-numeric: tabular-nums; }
.amount { text-align: right; white-space: nowrap; }
.empty { color: var(--subtle); padding: 20px 13px; text-align: center; }
.muted, .help-text { color: var(--muted); }
.help-text, .small { font-size: 12px; }
label { display: block; font-size: 12px; font-weight: 650; color: #284658; }
input:not([type="checkbox"]):not([type="radio"]):not([type="hidden"]), select, textarea { display: block; width: 100%; min-height: 37px; border: 1px solid #cdd9e4; border-radius: 7px; padding: 7px 9px; background: #fff; color: #142735; margin-top: 4px; }
input:disabled, select:disabled, textarea:disabled { opacity: .6; }
input[type=checkbox], input[type=radio] { accent-color: var(--blue); }
textarea { min-height: 70px; resize: vertical; }
.form-grid { display: grid; grid-template-columns: repeat(auto-fit,minmax(min(100%,170px),1fr)); gap: 12px; align-items: end; }
.form-grid .wide, .form-grid .full, .form-grid .span-all { grid-column: 1 / -1; }
.hou-profile-preview .form-grid > div { min-width: 0; }
.hou-profile-preview dd { overflow-wrap: anywhere; white-space: pre-wrap; }
.crm-shell-header { padding: 22px 24px; }
.crm-shell-header .eyebrow { margin: 0 0 6px; }
.crm-tabs { display: flex; gap: 7px; overflow-x: auto; padding: 10px; }
.crm-tab { flex: none; padding: 9px 14px; border-radius: 8px; background: #eff4f6; color: #3a5164; font-weight: 700; white-space: nowrap; }
.crm-tab:hover { background: #e3edef; text-decoration: none; }
.crm-tab.active { background: var(--blue-dark); color: white; }
.crm-student-summary { margin-bottom: 12px; }
.crm-student-summary thead th:first-child { width: 36%; }
.crm-student-summary tbody th { border-top: 1px solid #eaf0f4; font-size: inherit; font-weight: 600; }
#crm-leads .crm-records { min-width: 64rem; }
#crm-application-list .crm-records { min-width: 86rem; }
:is(#crm-leads, #crm-application-list) .crm-records :is(.code, .button) { white-space: nowrap; }
.crm-registration-contact { overflow-wrap: anywhere; }
.crm-stage-badges { display: grid; justify-items: start; gap: 4px; }
.admin-tabs { flex-wrap: wrap; }
.admin-tabs .crm-tab { display: inline-flex; gap: 7px; align-items: center; }
.admin-panel-heading { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px 18px; }
.admin-panel-heading p { margin-bottom: 0; }
.admin-account-filters, .admin-activity-filters { align-items: end; }
.admin-account-filters label, .admin-activity-filters label { flex: 1 1 135px; min-width: 0; }
.admin-account-counts { margin-top: 0; }
.admin-account-roles { display: flex; flex-wrap: wrap; gap: 5px; }
.admin-account-editor[open] { min-width: min(58vw, 225px); }
.admin-account-editor .form-grid > label { min-width: 0; }
.admin-account-editor form + form, .admin-account-editor form + p { margin-top: 12px; }
.admin-role-picker { min-width: 0; margin: 0; border: 1px solid var(--line); border-radius: 8px; padding: 8px 11px; }
.admin-role-picker legend { padding-inline: 4px; color: #284658; font-size: 12px; font-weight: 650; }
.admin-role-picker .help-text { display: block; margin-top: 4px; }
.admin-role-options { display: flex; flex-wrap: wrap; gap: 4px 16px; }
.admin-role-options label { display: inline-flex; align-items: center; gap: 6px; min-height: 30px; cursor: pointer; }
.admin-role-options input { width: 16px; height: 16px; margin: 0; }
.admin-permission-table { min-width: 760px; }
.admin-permission-table thead th:not(:first-child), .admin-permission-cell { text-align: center; }
.admin-permission-action { min-width: 168px; font-size: 12px; }
.admin-permission-table tbody th { border-top: 1px solid #eaf0f4; }
.admin-permission-table .admin-permission-action { background: transparent; color: var(--ink); }
.admin-permission-table .admin-permission-cell .badge { justify-content: center; }
.admin-permission-cell input[type="checkbox"] { width: 18px; height: 18px; vertical-align: middle; cursor: pointer; }
.admin-permission-cell label { display: inline-grid; place-items: center; min-width: 32px; min-height: 28px; cursor: pointer; }
.crm-kpis { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 12px; margin: 0 0 16px; }
.crm-kpi { display: grid; gap: 7px; align-content: start; color: var(--ink); }
a.crm-kpi:hover { border-color: var(--brand-border); text-decoration: none; }
.crm-kpi-heading { display: flex; align-items: center; gap: 8px; color: #41576a; font-size: 13px; font-weight: 700; }
.crm-kpi-icon { flex: none; }
.crm-kpi-value { font-size: 30px; line-height: 1.1; font-variant-numeric: tabular-nums; }
.crm-kpi-hint { color: var(--subtle); }
.crm-record-summary-students { gap: 12px; }
.crm-record-summary-total { display: grid; gap: 7px; color: var(--ink); }
a.crm-record-summary-total:hover { text-decoration: none; color: var(--blue-dark); }
.crm-record-summary-breakdown { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(100%, 145px), 1fr)); gap: 8px 16px; border-top: 1px solid var(--line); padding-top: 9px; }
.crm-record-summary-breakdown > * { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; color: var(--muted); font-size: 13px; }
.crm-record-summary-breakdown > :is(a, span) > strong { color: var(--ink); font-size: 15px; font-variant-numeric: tabular-nums; }
.crm-report { scroll-margin-top: 16px; }
.crm-report td a { font-weight: 650; text-decoration: underline; text-underline-offset: 2px; }
.crm-referral-link { font-weight: 650; text-decoration: underline; text-underline-offset: 2px; }
.crm-workspace-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 15px; align-items: start; }
.crm-workspace-grid > .card { min-width: 0; }
.crm-workspace-header { margin-bottom: 13px; }
.crm-workspace-header p { margin-top: 4px; }
.crm-workspace-empty { color: var(--subtle); font-size: 13px; padding: 16px 0; }
.crm-pipeline { overflow-x: auto; padding: 2px 0 9px; }
.crm-pipeline-columns { display: flex; gap: 12px; min-height: 230px; }
.crm-pipeline-column { flex: 0 0 235px; align-self: start; min-width: 0; min-height: 158px; padding: 10px; border: 1px solid #e0e9ee; border-radius: 10px; background: #f2f6f8; }
.crm-pipeline-header { display: flex; gap: 8px; align-items: center; justify-content: space-between; margin-bottom: 10px; }
.crm-pipeline-item { margin-bottom: 8px; padding: 11px; border: 1px solid #e0e9ee; border-radius: 8px; background: white; }
.crm-pipeline-item:last-child { margin-bottom: 0; }
.crm-pipeline-item form { margin-top: 9px; }
.crm-pipeline-meta { margin-top: 4px; overflow-wrap: anywhere; font-size: 12px; color: var(--muted); }
.crm-followup-stats { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; }
.crm-followup-cards { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.crm-followup-card { border-top: 3px solid var(--care-color, #66788b); }
.crm-followup-card.rose { --care-color: #aa4055; --care-fill: #fff3f5; }
.crm-followup-card.amber { --care-color: #97601e; --care-fill: #fff7e8; }
.crm-followup-card.blue { --care-color: #226c96; --care-fill: #eef7fc; }
.crm-followup-card.slate { --care-color: #627487; --care-fill: #eff3f7; }
.crm-followup-card .tile-icon { color: var(--care-color); background: var(--care-fill); }
.crm-followup-card[aria-current] { background: var(--care-fill); border-color: var(--care-color); }
#crm-followup, #crm-followup-quick, #lich-su-tu-van { scroll-margin-top: 72px; }
.crm-followup-records { min-width: 62rem; }
.crm-followup-actions { min-width: 15rem; }
.crm-care-selected > td { background: var(--brand-soft); }
:is(.crm-care-form, #lich-su-tu-van > .toolbar) { display: grid; gap: 12px; margin: 12px 0 16px; }
:is(.crm-care-form, #lich-su-tu-van > .toolbar) .button { justify-self: start; }
.crm-care-notes { grid-template-columns: repeat(2, minmax(0, 1fr)); }
.crm-care-completion { margin: 12px 0 20px; padding: 12px; border: 1px solid var(--brand-border); border-radius: var(--radius); background: var(--brand-soft); }
.crm-care-completion > summary { width: fit-content; }
.crm-care-completion[open] > summary { margin-bottom: 12px; }
.crm-care-completion .crm-care-form { margin-bottom: 0; }
.crm-care-history { min-width: 38rem; }
.crm-care-history td { vertical-align: top; overflow-wrap: anywhere; }
.crm-care-history td:nth-child(3), .crm-care-history td:nth-child(4) { white-space: pre-wrap; }
@media (max-width: 920px) { .crm-followup-cards { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 560px) { .crm-care-notes { grid-template-columns: 1fr; } }
.crm-workspace-filters { align-items: end; }
.crm-workspace-filters > label { flex: 1 1 155px; min-width: 0; }
.crm-period-filters { display: flex; flex: 1 1 100%; flex-wrap: wrap; align-items: end; gap: 8px; }
.crm-period-filters > label { flex: 0 1 170px; min-width: 0; }
.crm-period-filters > label:first-child { flex-basis: 205px; }
.crm-period-filters [hidden] { display: none; }
.crm-period-error { flex-basis: 100%; margin: 0; }
.crm-workspace-details { margin-top: 3px; }
.crm-workspace-details[open] { flex-basis: 100%; }
@media (max-width: 680px) {
  .crm-kpis { grid-template-columns: minmax(0, 1fr); }
  .crm-workspace-grid { grid-template-columns: 1fr; }
  .crm-shell-header { padding: 16px; }
}
.crm-registration { margin-top: 12px; }
.crm-form-section { padding: 12px 0; }
.crm-form-section + .crm-form-section { border-top: 1px solid var(--line); }
.crm-form-section h3 { margin-bottom: 9px; }
.crm-form-section > label { max-width: 420px; }
.crm-contact-fields { min-width: 0; margin: 12px 0; border: 0; padding: 0; }
.crm-contact-fields[hidden] { display: none; }
.crm-history-row { min-width: 0; border: 1px solid var(--line); border-radius: 7px; margin: 0 0 10px; padding: 8px 10px 12px; }
.crm-history-row legend { font-size: 12px; color: var(--muted); padding: 0 4px; }
.crm-history-row .button { justify-self: start; }
form + h2, form + .table-wrap, h2 + .form-grid, .card > form + form { margin-top: 13px; }
details { border: 1px solid var(--line); border-radius: 8px; padding: 10px 12px; margin: 10px 0; }
details[open] > summary { margin-bottom: 12px; }
summary { font-weight: 700; color: #25475b; cursor: pointer; }
.flash, .notice, .alert { padding: 11px 13px; border-radius: 8px; margin-bottom: 15px; background: #e6f4f2; border: 1px solid #ccebe5; color: #165d56; }
.flash.error, .alert.error { background: #fcebed; border-color: #f2cbd0; color: #8b2e39; }
.notice.warning, .alert.warning, .flash.warning { color: #7b4b13; background: #fff5e2; border-color: #f1dfb8; }
.flash p, .notice p { color: inherit; }
.error-panel { padding: 28px; }
.error-panel p { margin: 9px 0 16px; }
.guest { display: grid; place-items: center; min-height: 100dvh; padding: 24px; background: #eaf1f5; }
.login-layout { display: grid; grid-template-columns: 1.08fr 1fr; width: min(100%,820px); min-height: 400px; border-radius: 18px; overflow: hidden; box-shadow: 0 16px 55px #193d4e23; }
.login-brand { position: relative; overflow: hidden; padding: 32px; background: linear-gradient(135deg,var(--nav),var(--brand-blue)); display: flex; flex-direction: column; justify-content: space-between; color: white; }
.login-brand > div { z-index: 1; }
.login-brand .brand-identity { width: min(100%,320px); margin-bottom: 24px; }
.login-brand .brand-logo-plate { height: 135px; padding: 10px 12px; }
.login-brand h1 { font-size: 37px; }
.login-brand p { color: #d4e7ed; margin-top: 10px; }
.login-orbit { position: absolute; top: -64px; right: -62px; width: 225px; height: 225px; border-radius: 50%; border: 1px solid rgb(48 175 223 / 32%); box-shadow: 0 0 0 25px rgb(48 175 223 / 13%),0 0 0 50px rgb(48 175 223 / 8%),0 0 0 75px rgb(243 125 50 / 6%); z-index: 0 !important; }
.login-box { background: #fff; padding: 35px; display: grid; align-content: center; gap: 10px; }
.login-box h2 { font-size: 26px; }
.login-box form { display: grid; gap: 12px; margin-top: 9px; }
.login-box .button { margin-top: 5px; }
.academic-layout { display: grid; grid-template-columns: minmax(0,1.18fr) minmax(0,1fr); gap: 16px; }
.academic-layout .card { align-self: start; }
.issue-list { margin: 10px 0 0; padding-left: 22px; }
.issue-list li { margin: 4px 0; }
.stat-grid .card { margin-bottom: 0; }
.overview-summary { margin-bottom: 28px; }
.overview-header-actions { display: flex; align-items: center; flex-wrap: wrap; gap: 9px; }
.overview-section { margin-bottom: 16px; }
.overview-kpis { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 10px; }
.overview-kpis.overview-annual-kpis { grid-template-columns: repeat(4, minmax(0, 1fr)); }
.overview-year-comparison { margin-top: 12px; }
.overview-year-comparison > .table-wrap { margin-top: 8px; }
.overview-commission-comparison { display: grid; grid-template-columns: minmax(0, 1fr) minmax(0, 1.3fr); gap: 16px; margin-top: 14px; padding: 14px; border: 1px solid var(--line); border-radius: 8px; background: var(--brand-soft); }
.overview-commission-comparison > * { min-width: 0; }
.overview-commission-comparison h4 { margin: 0; }
.overview-comparison-percentage { display: block; margin-top: 8px; color: var(--brand-blue); font-size: clamp(28px, 3vw, 36px); line-height: 1.15; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.overview-comparison-operands { display: grid; gap: 10px; margin: 0; }
.overview-comparison-operands dt { color: var(--muted); font-size: 12px; }
.overview-comparison-operands dd { margin: 4px 0 0; font-size: 18px; font-weight: 700; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.overview-comparison-formula { overflow-wrap: anywhere; }
@media (max-width: 600px) { .overview-commission-comparison { grid-template-columns: 1fr; } }
@media (max-width: 1100px) { .overview-kpis.overview-annual-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); } }
@media (max-width: 600px) { .overview-kpis.overview-annual-kpis { grid-template-columns: 1fr; } }
.overview-kpi { min-height: 94px; padding: 12px 14px; color: var(--ink); }
.overview-kpi .metric-label { margin-top: 0; }
.overview-kpi strong { font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.overview-money strong { font-size: clamp(17px, 2.2vw, 28px); }
.overview-details { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; margin-top: 16px; }
.overview-breakdown { display: grid; gap: 7px; margin: 9px 0 0; padding: 0; list-style: none; }
.overview-breakdown li { display: grid; gap: 4px; }
.overview-breakdown li > div:first-child { display: flex; align-items: baseline; justify-content: space-between; gap: 10px; }
.overview-metric-actions { margin-top: 14px; }
.overview-term-form { align-items: flex-end; }
.student-summary-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 14px; }
.student-summary { margin: 0; }
.student-summary .card-heading { align-items: flex-start; flex-wrap: wrap; }
.student-summary-metrics { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 8px; margin: 0; }
.student-credit-metrics { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.student-summary-metric { min-width: 0; padding: 10px 12px; background: var(--bg); border-radius: 8px; }
.student-summary-metric dt { color: var(--muted); font-size: 12px; font-weight: 600; }
.student-summary-metric dd { margin: 4px 0 0; font-size: 20px; line-height: 1.2; font-weight: 700; font-variant-numeric: tabular-nums; overflow-wrap: anywhere; }
.student-summary-metric dd.student-summary-empty { color: var(--subtle); font-size: 13px; font-weight: 500; }
.student-info-table { table-layout: fixed; border: 1px solid var(--line); }
.student-info-table :is(th,td) {
  padding: 8px 12px;
  border-top: 1px solid var(--line);
  vertical-align: top;
  overflow-wrap: anywhere;
}
.student-info-table th { width: 36%; font-size: inherit; font-weight: 600; }
.student-info-table td { white-space: pre-wrap; }
@media (min-width: 900px) { .student-info-table th { width: 248px; } }
.student-info-table + h3 { margin-top: 16px; }
h3 + .student-info-table { margin-top: 8px; }
.student-admission .student-info-table + p { margin-top: 10px; }
.student-admission .card-heading { flex-wrap: wrap; }
.student-admission-group { margin-top: 16px; padding-top: 14px; border-top: 1px solid var(--line); }
@media (max-width: 1000px) {
  .student-summary-grid { grid-template-columns: 1fr; }
}
@media (max-width: 520px) { .student-credit-metrics { grid-template-columns: 1fr; } }
@media(max-width: 1100px) { .overview-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); } }
@media(max-width: 760px) {
  .overview-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
  .overview-details { grid-template-columns: 1fr; }
}
@media(max-width:1100px) { :root { --side: 209px; } .main { padding: 24px 20px; } .topbar { padding: 0 20px; } .overview-stats, .stat-grid { grid-template-columns: repeat(2,minmax(0,1fr)); } }
@media(max-width:800px) { .sidebar { transform: translateX(-100%); transition: transform .18s ease; } .menu-open .sidebar { transform: translateX(0); box-shadow: 0 0 0 100vmax #182c3f66; } .workspace { margin-left: 0; } .menu-toggle { display: inline-flex; } .topbar { padding: 0 13px; height: 56px; } .main { padding: 20px 13px; } .overview-panels, .academic-layout { grid-template-columns: 1fr; gap: 0; } }
@media(max-width:520px) { .date-chip,.account-name { display: none; } .overview-header,.page-header { flex-direction: column; margin-bottom: 15px; } .hero { padding: 22px 17px; min-height: 210px; } .hero-copy { max-width: 100%; } .hero-art { opacity: .25; width: 60%; } .metric-card,.card { padding: 13px; } .overview-stats,.stat-grid { gap: 9px; } .login-layout { grid-template-columns: 1fr; } .login-brand,.login-box { padding: 22px; } .login-brand { min-height: 210px; } }
@media(prefers-reduced-motion: reduce) { *,*::before,*::after { scroll-behavior: auto !important; transition: none !important; } }

.statistics-back { display: inline-block; margin-bottom: 6px; font-size: 13px; font-weight: 650; }
.academic-statistics .page-header { flex-wrap: wrap; }
.academic-statistics .page-header .toolbar { margin: 0; }
.statistics-empty { max-width: 540px; padding: 26px; }
.statistics-empty .tile-icon { margin-bottom: 10px; }
.statistics-empty .button { margin-top: 14px; }
.statistics-filters { margin-bottom: 14px; }
.statistics-filters .actions { align-self: end; }
.statistics-scope { margin: 8px 0; font-size: 12px; font-weight: 600; }
.statistics-kpis { grid-template-columns: repeat(5,minmax(0,1fr)); gap: 12px; margin: 14px 0; }
.statistics-print-only { display: none; }
.statistics-kpi { border-top: 3px solid #c1d3df; }
.statistics-kpi .metric-label { margin-top: 0; }
.statistics-kpi-primary { border-top-color: var(--brand-blue); }
.statistics-kpi-active { border-top-color: #218374; }
.statistics-kpi-remaining { border-top-color: #6572a5; }
.statistics-kpi-warning { border-top-color: #b88337; }
.statistics-kpi-exit { border-top-color: #ac5c66; }
.statistics-charts, .statistics-reference {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 16px;
  align-items: start;
  margin-bottom: 16px;
}
.statistics-charts > .card, .statistics-reference > .card { margin-bottom: 0; }
.statistics-group, .statistics-major, .statistics-status { grid-column: 1 / -1; }
.statistics-lead { margin-top: 5px; font-size: 13px; }
.statistics-admission-scroll { margin-top: 12px; }
.statistics-admission-table th, .statistics-admission-table td { padding: 8px 10px; }
.statistics-admission-table .statistics-admission-number { text-align: center; font-variant-numeric: tabular-nums; }
.statistics-admission-table .statistics-admission-major { min-width: 170px; }
.statistics-admission-table tbody th { font-weight: 550; }
.statistics-admission-table tfoot :is(th, td), .statistics-admission-total { background: #f2f6f8; font-weight: 700; }
.statistics-admission-table a { display: inline-block; min-width: 24px; }
.statistics-column-scroll { overflow-x: auto; margin-top: 15px; border-radius: 6px; }
.statistics-columns {
  --axis-width: 35px;
  --labels-height: 51px;
  --category-width: 44px;
  position: relative;
  min-width: calc(var(--axis-width) + var(--category-count) * var(--category-width));
  margin-top: 24px;
  padding-left: var(--axis-width);
  color: #43596c;
  font-variant-numeric: tabular-nums;
}
.statistics-group .statistics-columns { --category-width: 63px; }
.statistics-cohort .statistics-columns { --category-width: 30px; }
.statistics-axis { position: absolute; inset: 0 0 var(--labels-height) 0; }
.statistics-axis span {
  position: absolute;
  bottom: var(--level);
  width: 100%;
  padding-right: calc(100% - var(--axis-width) + 5px);
  transform: translateY(50%);
  text-align: right;
  font-size: 10px;
}
.statistics-axis span::after {
  content: "";
  position: absolute;
  inset: 50% 0 auto var(--axis-width);
  border-top: 1px solid #dbe7ed;
}
.statistics-column-list {
  position: relative;
  display: grid;
  grid-template-columns: repeat(var(--category-count), minmax(0, 1fr));
  grid-template-rows: 190px var(--labels-height);
  margin: 0;
  padding: 0;
  list-style: none;
}
.statistics-column-list li { display: grid; grid-template-rows: subgrid; grid-row: span 2; justify-items: center; min-width: 0; }
.statistics-column-track { position: relative; align-self: end; width: min(62%, 46px); height: var(--height); }
.statistics-column-bar { display: block; height: 100%; background: var(--brand-blue); border-radius: 5px 5px 0 0; }
.statistics-column-list li:nth-child(5n + 2) .statistics-column-bar { background: var(--brand-cyan-dark); }
.statistics-column-list li:nth-child(5n + 3) .statistics-column-bar { background: #5274a5; }
.statistics-column-list li:nth-child(5n + 4) .statistics-column-bar { background: var(--brand-orange-dark); }
.statistics-column-list li:nth-child(5n + 5) .statistics-column-bar { background: #875b91; }
.statistics-column-bar strong {
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  color: var(--ink);
  font-size: 12px;
}
.statistics-category { padding: 6px 3px 0; text-align: center; overflow-wrap: anywhere; font-size: 10px; line-height: 1.3; }
.statistics-exact { margin: 14px 0 0; }
.academic-statistics tbody th { background: transparent; font-size: 13px; color: inherit; border-top: 1px solid #eaf0f4; }
.statistics-reference h3 { margin: 14px 0 6px; }
.statistics-reference .statistics-lead { margin-bottom: 10px; }
.statistics-annotation { margin-top: 10px; padding: 10px 12px; background: #edf5f8; border-radius: 7px; font-size: 13px; }
@media (max-width: 1100px) {
  .statistics-kpis { grid-template-columns: repeat(3, minmax(0, 1fr)); }
}
@media (max-width: 850px) {
  .statistics-charts, .statistics-reference { grid-template-columns: 1fr; }
}
@media (max-width: 520px) {
  .statistics-kpis { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}
@media print {
  body:has(.academic-statistics) :is(.sidebar, .topbar, .app-footer, .statistics-screen, .statistics-back) { display: none; }
  body:has(.academic-statistics) .workspace { margin: 0; }
  body:has(.academic-statistics) .main { max-width: none; padding: 0; }
  .academic-statistics { print-color-adjust: exact; }
  .statistics-kpis { grid-template-columns: repeat(5, minmax(0, 1fr)); }
  .statistics-print-only { display: grid; }
  .statistics-charts, .statistics-reference { grid-template-columns: 1fr; }
  .statistics-admission-scroll { overflow: visible; }
  .statistics-admission-table th, .statistics-admission-table td { padding: 4px; font-size: 10px; }
  .statistics-admission-table .statistics-admission-major, .statistics-admission-table a { min-width: 0; }
  .statistics-columns { --category-width: 31px; min-width: 0; }
  .statistics-column-scroll { overflow: visible; }
  .statistics-column-list { grid-template-rows: 138px var(--labels-height); }
  .academic-statistics :is(.card, .metric-card) { break-inside: avoid; box-shadow: none; }
  .statistics-exact { display: none; }
}


.notification-bell { position: relative; text-decoration: none; }
.notification-badge { position: absolute; top: -4px; right: -5px; min-width: 17px; padding: 1px 4px; border-radius: 12px; background: #a82e3b; color: #fff; text-align: center; font-size: 10px; font-weight: 750; }
.notification-badge[hidden] { display: none; }
.notification-list { margin: 0; padding: 0; list-style: none; }
.notification-list li { display: flex; flex-wrap: wrap; gap: 12px; align-items: center; justify-content: space-between; border-top: 1px solid #eaf0f4; padding: 12px 4px; }
.notification-list li p { margin: 0 0 4px; }
.notification-dispatch { margin-top: 14px; margin-bottom: 0; }
.notification-rules { min-width: 630px; }
.notification-rules th:nth-child(n+3), .notification-rules td:nth-child(n+3) { text-align: center; }
.notification-rules th[scope=row] { background: transparent; color: var(--ink); }
.notification-rules + .button, .notification-rules select { margin-top: 0; }
.notification-channel { display: inline-grid; place-items: center; width: 32px; height: 30px; }
.notification-channel input { width: 17px; height: 17px; }
[aria-labelledby=notification-settings] form > .button { margin-top: 12px; }
