﻿/* ==========================================================================
   УСУГ · Хэрэглэгчийн онлайн систем — app.css
   Bootstrap 3 дээр давхарлан ачаалагдах шинэ дизайн.
   Зөвхөн харагдах байдлыг өөрчилнө; JS, серверийн логикт нөлөөлөхгүй.
   ========================================================================== */

:root {
  --c-ink: #0c2236;
  --c-text: #1d2d3d;
  --c-muted: #64768a;
  --c-faint: #93a3b4;
  --c-bg: #f2f5f9;
  --c-surface: #ffffff;
  --c-surface-2: #f7f9fc;
  --c-border: #e2e8f0;
  --c-border-strong: #cfd8e3;

  --c-primary: #0a6cb4;
  --c-primary-600: #085b98;
  --c-primary-700: #074a7c;
  --c-primary-50: #eaf3fb;
  --c-primary-100: #d3e6f6;
  --c-accent: #14b0c6;

  --c-success: #12855a;
  --c-success-50: #e7f6ef;
  --c-danger: #cf3f57;
  --c-danger-50: #fdeef1;
  --c-warning: #b7740a;
  --c-warning-50: #fff5e2;
  --c-info: #2a72c4;
  --c-info-50: #ebf3fd;

  --radius-sm: 8px;
  --radius: 12px;
  --radius-lg: 16px;
  --shadow-sm: 0 1px 2px rgba(12, 34, 54, .06);
  --shadow: 0 1px 2px rgba(12, 34, 54, .05), 0 4px 16px rgba(12, 34, 54, .06);
  --shadow-lg: 0 10px 40px rgba(12, 34, 54, .14);

  --topbar-h: 64px;
  --font: "Inter", "Segoe UI", -apple-system, BlinkMacSystemFont, Roboto, "Helvetica Neue", Arial, sans-serif;
  --font-display: "Manrope", "Inter", "Segoe UI", Arial, sans-serif;
}

/* ---------- Base ---------- */
html { -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale; }
body {
  font-family: var(--font);
  font-size: 14px;
  line-height: 1.55;
  color: var(--c-text);
  background: var(--c-bg);
  padding-top: var(--topbar-h);
}
h1, h2, h3, h4, h5, h6, .h1, .h2, .h3, .h4, .h5, .h6 {
  font-family: var(--font-display);
  color: var(--c-ink);
  font-weight: 700;
  letter-spacing: -.01em;
}
a { color: var(--c-primary); }
a:hover, a:focus { color: var(--c-primary-700); }
hr { border-top-color: var(--c-border); margin: 22px 0; }
::selection { background: var(--c-primary-100); }
.text-muted { color: var(--c-muted); }
.text-info { color: var(--c-info); }
.text-success { color: var(--c-success); }
.text-danger { color: var(--c-danger); }
.num, .tabular { font-variant-numeric: tabular-nums; }

/* ---------- Top bar ---------- */
.app-topbar.navbar {
  min-height: var(--topbar-h);
  height: var(--topbar-h);
  background: rgba(255, 255, 255, .92);
  -webkit-backdrop-filter: saturate(180%) blur(12px);
  backdrop-filter: saturate(180%) blur(12px);
  border: 0;
  border-bottom: 1px solid var(--c-border);
  border-radius: 0;
  margin: 0;
  box-shadow: none;
}
.app-topbar .container-fluid { max-width: 1440px; margin: 0 auto; padding: 0 24px; }
.app-topbar .navbar-header { float: left; }
.app-brand.navbar-brand {
  display: flex;
  align-items: center;
  gap: 12px;
  height: var(--topbar-h);
  padding: 0;
  margin-left: 0 !important;
  color: var(--c-ink);
}
.app-brand img { height: 40px; width: auto; }
.app-brand-text { display: flex; flex-direction: column; line-height: 1.15; }
.app-brand-text strong { font-family: var(--font-display); font-size: 15px; font-weight: 800; color: var(--c-ink); letter-spacing: .01em; }
.app-brand-text small { font-size: 12px; color: var(--c-muted); font-weight: 500; }
.app-brand:hover, .app-brand:focus { color: var(--c-ink); }

.app-topbar .navbar-collapse { border: 0; box-shadow: none; }
.app-topbar .navbar-nav > li > a {
  color: var(--c-muted);
  font-weight: 600;
  font-size: 13.5px;
  padding: 0 14px;
  line-height: var(--topbar-h);
  height: var(--topbar-h);
  transition: color .15s ease;
}
.app-topbar .navbar-nav > li > a .fa { color: var(--c-faint); margin-right: 4px; transition: color .15s ease; }
.app-topbar .navbar-nav > li > a:hover,
.app-topbar .navbar-nav > li > a:focus { color: var(--c-primary); background: transparent; }
.app-topbar .navbar-nav > li > a:hover .fa { color: var(--c-primary); }
.app-topbar .navbar-nav > .open > a,
.app-topbar .navbar-nav > .open > a:hover,
.app-topbar .navbar-nav > .open > a:focus { background: transparent; color: var(--c-primary); }
.app-topbar .navbar-nav > li.app-user > a {
  display: flex; align-items: center; gap: 8px;
  height: 40px; line-height: 40px;
  margin: 12px 0 12px 8px;
  padding: 0 14px 0 6px;
  border-radius: 999px;
  border: 1px solid var(--c-border);
  background: var(--c-surface);
  color: var(--c-ink);
}
.app-topbar .navbar-nav > li.app-user > a:hover { border-color: var(--c-primary-100); background: var(--c-primary-50); }
.app-avatar-sm {
  width: 28px; height: 28px; border-radius: 50%;
  display: inline-flex; align-items: center; justify-content: center;
  background: var(--c-primary-50); color: var(--c-primary);
}
.app-avatar-sm .fa { color: var(--c-primary) !important; margin: 0 !important; }

/* ---------- Dropdowns ---------- */
.dropdown-menu {
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  box-shadow: var(--shadow-lg);
  padding: 6px;
  min-width: 220px;
}
.dropdown-menu > li > a {
  border-radius: var(--radius-sm);
  padding: 9px 12px;
  color: var(--c-text);
  font-weight: 500;
  text-align: left;
}
.dropdown-menu > li > a .fa { width: 18px; color: var(--c-faint); text-align: center; margin-right: 6px; }
.dropdown-menu > li > a:hover,
.dropdown-menu > li > a:focus { background: var(--c-primary-50); color: var(--c-primary-700); }
.dropdown-menu > li > a:hover .fa { color: var(--c-primary); }
.dropdown-menu .divider { background: var(--c-border); margin: 6px 0; }

/* ---------- Shell ---------- */
.app-shell {
  display: flex;
  align-items: flex-start;
  gap: 24px;
  max-width: 1440px;
  margin: 0 auto;
  padding: 24px;
}
.app-sidebar-wrap { flex: 0 0 auto; }
.app-main { flex: 1 1 auto; min-width: 0; }
.app-card {
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  padding: 28px 32px 32px;
  min-height: 420px;
}
.app-card:after { content: ""; display: table; clear: both; }

/* ---------- Sidebar ---------- */
.app-sidebar {
  width: 280px;
  position: -webkit-sticky;
  position: sticky;
  top: calc(var(--topbar-h) + 24px);
  background: var(--c-surface);
  border: 1px solid var(--c-border);
  border-radius: var(--radius-lg);
  box-shadow: var(--shadow);
  overflow: hidden;
}
.app-profile {
  position: relative;
  padding: 22px 20px 18px;
  color: #fff;
  background:
    radial-gradient(120% 140% at 100% 0%, rgba(20, 176, 198, .55) 0%, rgba(20, 176, 198, 0) 55%),
    linear-gradient(135deg, #0a6cb4 0%, #074a7c 100%);
  overflow: hidden;
}
.app-profile:after {
  /* усны долгион */
  content: "";
  position: absolute; left: -10%; right: -10%; bottom: -1px; height: 26px;
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 600 26' preserveAspectRatio='none'%3E%3Cpath d='M0 14 C 75 0 150 0 225 12 S 375 26 450 12 S 560 2 600 10 V26 H0Z' fill='%23ffffff'/%3E%3C/svg%3E") no-repeat bottom / 100% 100%;
}
.app-profile-head { display: flex; align-items: center; gap: 12px; margin-bottom: 14px; position: relative; z-index: 1; }
.app-avatar {
  width: 44px; height: 44px; border-radius: 50%;
  background: rgba(255, 255, 255, .18);
  border: 1px solid rgba(255, 255, 255, .35);
  display: flex; align-items: center; justify-content: center;
  font-size: 18px;
}
.app-profile-name { font-family: var(--font-display); font-weight: 800; font-size: 16px; line-height: 1.2; }
.app-profile-name small { display: block; font-family: var(--font); font-weight: 500; font-size: 12px; opacity: .8; margin-top: 2px; }
.app-profile-meta { list-style: none; margin: 0 0 12px; padding: 0; position: relative; z-index: 1; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; }
.app-profile-meta li { background: rgba(255, 255, 255, .12); border-radius: 10px; padding: 7px 10px; }
.app-profile-meta li.wide { grid-column: 1 / -1; }
.app-profile-meta span { display: block; font-size: 11px; text-transform: uppercase; letter-spacing: .06em; opacity: .75; }
.app-profile-meta b { font-size: 13.5px; font-weight: 700; word-break: break-word; font-variant-numeric: tabular-nums; }

.app-nav { padding: 6px 12px 14px; }
.app-nav-label { font-size: 11px; font-weight: 700; text-transform: uppercase; letter-spacing: .08em; color: var(--c-faint); padding: 10px 10px 6px; }
.app-nav.nav-stacked > li + li { margin-top: 2px; }
.app-nav > li > a {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 9px 12px;
  border-radius: 10px;
  color: var(--c-text);
  font-weight: 600;
  font-size: 13.5px;
  transition: background .15s ease, color .15s ease;
}
.app-nav > li > a .fa {
  width: 20px; text-align: center; font-size: 15px; color: var(--c-faint);
  transition: color .15s ease;
}
.app-nav > li > a:hover,
.app-nav > li > a:focus { background: var(--c-surface-2); color: var(--c-primary-700); }
.app-nav > li > a:hover .fa { color: var(--c-primary); }
.app-nav > li.active > a,
.app-nav > li.active > a:hover,
.app-nav > li.active > a:focus {
  background: var(--c-primary-50);
  color: var(--c-primary-700);
  box-shadow: inset 3px 0 0 var(--c-primary);
}
.app-nav > li.active > a .fa { color: var(--c-primary); }
.app-nav > li > a .badge { margin-left: auto; }
.app-nav > li > a .badge:empty { display: none; }
.app-nav > li.app-nav-logout { margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--c-border); }
.app-nav > li.app-nav-logout > a { color: var(--c-danger); }
.app-nav > li.app-nav-logout > a .fa { color: var(--c-danger); }
.app-nav > li.app-nav-logout > a:hover { background: var(--c-danger-50); color: var(--c-danger); }

/* ---------- Mobile bottom bar ---------- */
.app-bottombar { display: none; }
@media (max-width: 991px) {
  body { padding-bottom: 84px; }
  .app-shell { padding: 16px; display: block; }
  .app-card { padding: 20px 16px 24px; border-radius: var(--radius); }
  .app-topbar .container-fluid { padding: 0 16px; }
  .app-bottombar {
    display: block;
    position: fixed; left: 12px; right: 12px; bottom: 12px;
    z-index: 1030;
    background: rgba(255, 255, 255, .96);
    -webkit-backdrop-filter: blur(12px);
    backdrop-filter: blur(12px);
    border: 1px solid var(--c-border);
    border-radius: 18px;
    box-shadow: var(--shadow-lg);
  }
  .app-bottombar > ul { display: flex; margin: 0; padding: 6px; list-style: none; }
  .app-bottombar > ul > li { flex: 1 1 0; position: relative; }
  .app-bottombar > ul > li > a {
    display: flex; flex-direction: column; align-items: center; gap: 2px;
    padding: 8px 4px; border-radius: 12px;
    color: var(--c-muted); font-size: 12px; font-weight: 600;
    text-decoration: none;
  }
  .app-bottombar > ul > li > a .fa { font-size: 18px; }
  .app-bottombar > ul > li.open > a,
  .app-bottombar > ul > li > a:hover { background: var(--c-primary-50); color: var(--c-primary); }
  .app-bottombar .dropdown-menu {
    top: auto; bottom: calc(100% + 12px);
    max-height: 70vh; overflow-y: auto;
  }
  .app-bottombar > ul > li:first-child .dropdown-menu { left: 0; }
  .app-bottombar > ul > li:last-child .dropdown-menu { left: auto; right: 0; }
  .app-bottombar > ul > li:nth-child(2) .dropdown-menu { left: 50%; transform: translateX(-50%); }
  .app-bottombar .dropdown-menu > li > a { display: block; }
  .app-bottombar .dropdown-menu .badge:empty { display: none; }
}
@media (max-width: 767px) {
  .app-brand-text small { display: none; }
  .app-brand img { height: 34px; }
}

/* ---------- Page headings ---------- */
/* asp:Panel GroupingText -> <fieldset><legend> : хуудасны гарчиг */
.app-card fieldset { min-width: 0; }
.app-card legend,
.page-title {
  display: block;
  width: 100%;
  border: 0;
  margin: 0 0 22px;
  padding: 0 0 16px;
  font-family: var(--font-display);
  font-size: 22px;
  font-weight: 800;
  line-height: 1.25;
  color: var(--c-ink);
  letter-spacing: -.015em;
  border-bottom: 1px solid var(--c-border);
}
.page-head {
  display: flex; align-items: flex-start; justify-content: space-between; gap: 16px;
  flex-wrap: wrap;
  margin: 0 0 22px; padding: 0 0 16px;
  border-bottom: 1px solid var(--c-border);
}
.page-head .page-title { border: 0; margin: 0; padding: 0; width: auto; }
.page-head .page-sub { color: var(--c-muted); margin: 4px 0 0; font-size: 13.5px; }
.page-actions { margin: 0 0 16px; display: flex; justify-content: flex-end; gap: 8px; }
.page-actions + fieldset legend, .page-actions + div > fieldset > legend { margin-top: -6px; }
.section-title {
  display: flex; align-items: center; gap: 10px;
  font-size: 15px; font-weight: 800;
  color: var(--c-ink);
  margin: 26px 0 12px;
}
.section-title:first-child { margin-top: 0; }
.section-title:before {
  content: ""; width: 4px; height: 16px; border-radius: 4px;
  background: linear-gradient(180deg, var(--c-accent), var(--c-primary));
}
.section-title .fa { color: var(--c-primary); }

/* ---------- Buttons ---------- */
.btn {
  border-radius: var(--radius-sm);
  font-weight: 600;
  font-size: 14px;
  padding: 9px 18px;
  line-height: 1.4;
  border-width: 1px;
  box-shadow: none;
  text-shadow: none;
  background-image: none;
  transition: background-color .15s ease, border-color .15s ease, color .15s ease, box-shadow .15s ease, transform .05s ease;
}
.btn:active, .btn.active { box-shadow: none; transform: translateY(1px); }
.btn:focus, .btn:active:focus, .btn.focus { outline: 0; box-shadow: 0 0 0 3px rgba(10, 108, 180, .22); }
.btn .fa { margin-right: 6px; }
.btn-sm, .btn-group-sm > .btn { padding: 7px 14px; font-size: 13px; border-radius: var(--radius-sm); }
.btn-lg, .btn-large { padding: 12px 22px; font-size: 15px; }
.btn-block { display: block; width: 100%; }

.btn-default, .btn:not([class*="btn-"]) {
  background: var(--c-surface); color: var(--c-text); border-color: var(--c-border-strong);
}
.btn-default:hover, .btn-default:focus, .btn:not([class*="btn-"]):hover { background: var(--c-surface-2); color: var(--c-ink); border-color: var(--c-faint); }

.btn-primary { background: var(--c-primary); border-color: var(--c-primary); color: #fff; }
.btn-primary:hover, .btn-primary:focus, .btn-primary:active, .btn-primary.active, .open > .dropdown-toggle.btn-primary { background: var(--c-primary-600); border-color: var(--c-primary-600); color: #fff; }

.btn-success { background: var(--c-success); border-color: var(--c-success); color: #fff; }
.btn-success:hover, .btn-success:focus, .btn-success:active { background: #0e6e4a; border-color: #0e6e4a; color: #fff; }

.btn-info { background: var(--c-accent); border-color: var(--c-accent); color: #fff; }
.btn-info:hover, .btn-info:focus, .btn-info:active { background: #0f97aa; border-color: #0f97aa; color: #fff; }

.btn-warning { background: #f0a01e; border-color: #f0a01e; color: #2b1a00; }
.btn-warning:hover, .btn-warning:focus, .btn-warning:active { background: #db8f12; border-color: #db8f12; color: #2b1a00; }

.btn-danger { background: var(--c-danger); border-color: var(--c-danger); color: #fff; }
.btn-danger:hover, .btn-danger:focus, .btn-danger:active { background: #b5334a; border-color: #b5334a; color: #fff; }

/* "Буцах" товч — саармаг outline */
.btn-back { background: var(--c-surface); color: var(--c-text); border-color: var(--c-border-strong); }
.btn-back:before { content: "\f104"; font-family: FontAwesome; margin-right: 8px; font-weight: normal; }
.btn-back:hover, .btn-back:focus { background: var(--c-surface-2); color: var(--c-ink); border-color: var(--c-faint); }

/* Тайлангийн товчлуурууд — "soft" хувилбар */
.btn-soft { background: var(--c-primary-50); color: var(--c-primary-700); border-color: var(--c-primary-100); }
.btn-soft:hover, .btn-soft:focus { background: var(--c-primary-100); color: var(--c-primary-700); border-color: var(--c-primary-100); }

.btn.disabled, .btn[disabled], .btn.aspNetDisabled { opacity: .55; cursor: not-allowed; }

/* ---------- Forms ---------- */
.form-control,
.app-card input[type="text"],
.app-card input[type="password"],
.app-card input[type="number"],
.app-card input[type="tel"],
.app-card input[type="email"],
.app-card input[type="search"],
.app-card textarea,
.app-card select:not([class*="rad"]) {
  display: inline-block;
  max-width: 100%;
  min-height: 40px;
  padding: 8px 12px;
  font-size: 14px;
  line-height: 1.45;
  color: var(--c-text);
  background-color: var(--c-surface);
  border: 1px solid var(--c-border-strong);
  border-radius: var(--radius-sm);
  box-shadow: none;
  transition: border-color .15s ease, box-shadow .15s ease;
}
.form-control { display: block; width: 100%; height: 40px; }
.app-card textarea, textarea.form-control { min-height: 96px; height: auto; resize: vertical; }
.form-control:focus,
.app-card input[type="text"]:focus,
.app-card input[type="password"]:focus,
.app-card input[type="number"]:focus,
.app-card input[type="tel"]:focus,
.app-card textarea:focus,
.app-card select:focus {
  outline: 0;
  border-color: var(--c-primary);
  box-shadow: 0 0 0 3px rgba(10, 108, 180, .15);
}
.form-control[disabled], .form-control[readonly],
.app-card input[disabled], .app-card textarea[disabled], .app-card input.aspNetDisabled, .app-card textarea.aspNetDisabled {
  background-color: var(--c-surface-2);
  color: var(--c-muted);
  cursor: not-allowed;
}
.form-control::placeholder, .app-card input::placeholder, .app-card textarea::placeholder { color: var(--c-faint); }
.control-label, .form-label, .app-card label {
  font-weight: 600; font-size: 13px; color: var(--c-ink);
}
.form-label { display: block; margin: 0 0 6px; }
.form-field { margin-bottom: 16px; }
.form-hint { color: var(--c-muted); font-size: 12.5px; margin-top: 6px; }
.form-grid { display: grid; grid-template-columns: repeat(auto-fit, minmax(220px, 1fr)); gap: 16px; }
.app-card input[type="checkbox"], .app-card input[type="radio"] {
  width: 18px; height: 18px; margin: 0 8px 0 0; vertical-align: -4px;
  accent-color: var(--c-primary);
  cursor: pointer;
}
.app-card input[type="checkbox"] + label { cursor: pointer; margin: 0; font-weight: 500; color: var(--c-text); }
.app-card input[type="file"] {
  display: block; width: 100%;
  padding: 14px; border: 1.5px dashed var(--c-border-strong); border-radius: var(--radius);
  background: var(--c-surface-2); color: var(--c-muted); font-size: 13px; cursor: pointer;
}
.app-card input[type="file"]:hover { border-color: var(--c-primary); background: var(--c-primary-50); }
.app-card input[type="file"]::file-selector-button {
  margin-right: 12px; padding: 7px 14px; border: 0; border-radius: var(--radius-sm);
  background: var(--c-primary); color: #fff; font-weight: 600; cursor: pointer;
}
.form-horizontal .control-label { padding-top: 10px; }
.form-group { margin-bottom: 16px; }

/* Telerik / DevExpress контролуудыг уялдуулах */
.app-card .RadComboBox, .app-card .RadPicker { vertical-align: middle; }
.app-card .RadComboBox .rcbInputCell input, .app-card .RadPicker input {
  min-height: 0; border: 0; box-shadow: none; padding: 0 6px; background: transparent;
}
.app-card .riTextBox { border-radius: var(--radius-sm) !important; }

/* ---------- Tables ---------- */
.table { margin-bottom: 0; color: var(--c-text); }
.table > thead > tr > th, .table > tbody > tr > th {
  border-bottom: 1px solid var(--c-border);
  border-top: 0;
  color: var(--c-muted);
  font-size: 12px;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: .05em;
  padding: 12px 16px;
  background: var(--c-surface-2);
}
.table > tbody > tr > td, .table > tfoot > tr > td {
  border-top: 1px solid var(--c-border);
  padding: 12px 16px;
  vertical-align: middle;
}
.table > tbody > tr:first-child > td { border-top: 0; }
.table-striped > tbody > tr:nth-of-type(odd) { background: transparent; }
.table-striped > tbody > tr:hover { background: var(--c-surface-2); }

.table-wrap {
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  overflow: hidden;
  overflow-x: auto;
  background: var(--c-surface);
  margin-bottom: 8px;
}
.table-wrap .table > thead > tr:first-child > th { border-top: 0; }

/* Нэр-утга хүснэгт */
.kv-table > tbody > tr > td:first-child { color: var(--c-muted); font-weight: 500; width: 45%; }
.kv-table > tbody > tr > td:last-child, .kv-table .text-muted { color: var(--c-ink); font-weight: 600; }
.kv-table > tbody > tr > td b { font-weight: 700; color: var(--c-ink); }
.kv-table .amount-row > td { background: var(--c-primary-50); }
.kv-table .amount-row > td:last-child b { font-size: 16px; color: var(--c-primary-700); }

/* Өргөдлийн маягт: checkbox-той талбарууд */
.form-table > tbody > tr > td { padding: 10px 16px; }
.form-table > tbody > tr > td:first-child { width: 44%; }
.form-table > tbody > tr > td:first-child label { font-weight: 500; }
.form-table .text-muted { display: block; color: inherit; }
.form-table .RadComboBox { width: 100% !important; }

/* ---------- Panels & cards ---------- */
.panel {
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  box-shadow: none;
  margin-bottom: 14px;
  background: var(--c-surface);
}
.panel-default > .panel-heading, .panel-primary > .panel-heading {
  background: var(--c-surface-2);
  border-bottom: 1px solid var(--c-border);
  color: var(--c-ink);
  border-radius: var(--radius) var(--radius) 0 0;
  padding: 14px 18px;
}
.panel-primary { border-color: var(--c-border); }
.panel-title { font-size: 14px; font-weight: 700; color: var(--c-ink); }
.panel-body { padding: 18px; }
.panel-body:after { content: ""; display: table; clear: both; }

/* Жагсаалтын карт (өргөдөл, тоолуур, төлөлт...) */
a.item-link, a.item-link:hover, a.item-link:focus { display: block; color: inherit; text-decoration: none; }
.item-card {
  position: relative;
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  background: var(--c-surface);
  padding: 16px 18px 16px 22px;
  margin-bottom: 12px;
  transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}
.item-card:before {
  content: ""; position: absolute; left: 0; top: 12px; bottom: 12px; width: 4px;
  border-radius: 0 4px 4px 0; background: var(--c-border-strong);
}
.item-card.is-success:before { background: var(--c-success); }
.item-card.is-danger:before { background: var(--c-danger); }
.item-card.is-info:before { background: var(--c-primary); }
a.item-link:hover .item-card, .item-card.is-hover:hover { border-color: var(--c-primary-100); box-shadow: var(--shadow); transform: translateY(-1px); }
.item-card:after { content: ""; display: table; clear: both; }
.item-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-bottom: 8px; }
.item-title { font-family: var(--font-display); font-weight: 800; font-size: 15.5px; color: var(--c-ink); }
.item-sub { color: var(--c-muted); font-size: 13px; }
.item-body { color: var(--c-text); margin: 6px 0; }
.item-foot { display: flex; align-items: center; justify-content: space-between; gap: 12px; flex-wrap: wrap; margin-top: 10px; padding-top: 10px; border-top: 1px dashed var(--c-border); color: var(--c-muted); font-size: 13px; }
.item-meta { display: flex; flex-wrap: wrap; gap: 8px 18px; margin: 8px 0 4px; }
.item-meta > span { display: inline-flex; flex-direction: column; font-size: 13.5px; color: var(--c-ink); font-weight: 600; }
.item-meta > span > small { font-size: 11px; text-transform: uppercase; letter-spacing: .05em; color: var(--c-faint); font-weight: 700; }
.item-person { display: flex; align-items: center; gap: 12px; margin-bottom: 10px; }
.item-person img { width: 40px; height: 40px; border-radius: 50%; background: var(--c-surface-2); border: 1px solid var(--c-border); }
.item-person b { color: var(--c-ink); }
.item-index {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 26px; height: 26px; padding: 0 6px; border-radius: 999px;
  background: var(--c-primary-50); color: var(--c-primary-700); font-weight: 800; font-size: 12px;
}
.item-desc { color: var(--c-muted); margin: 6px 0 0; }
.status-text.is-success { color: var(--c-success); }
.status-text.is-danger { color: var(--c-danger); }

/* Хугацааны шугам (шийдвэрлэлтийн явц) */
.timeline { position: relative; margin: 0; padding: 0 0 0 26px; }
.timeline:before { content: ""; position: absolute; left: 8px; top: 6px; bottom: 6px; width: 2px; background: var(--c-border); border-radius: 2px; }
.timeline .item-card { margin-bottom: 14px; }
.timeline .item-card > .tl-dot {
  position: absolute; left: -24px; top: 18px; width: 14px; height: 14px; border-radius: 50%;
  background: var(--c-surface); border: 3px solid var(--c-primary);
}

/* ---------- Wells / info boxes ---------- */
.well {
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  box-shadow: none;
  padding: 16px 18px;
  margin-bottom: 18px;
}
.well-sm { padding: 12px 16px; border-radius: var(--radius); }
.well:empty { display: none; }

/* Төлбөрийн үлдэгдлийн самбар */
.balance-board {
  display: grid;
  grid-template-rows: auto auto;
  grid-auto-flow: column;
  grid-auto-columns: minmax(0, 1fr);
  column-gap: 16px;
  row-gap: 2px;
  padding: 20px 22px;
  margin-bottom: 20px;
  border: 0;
  border-radius: var(--radius-lg);
  color: #fff;
  background:
    radial-gradient(120% 160% at 100% 0%, rgba(20, 176, 198, .5) 0%, rgba(20, 176, 198, 0) 55%),
    linear-gradient(135deg, #0a6cb4 0%, #074a7c 100%);
  box-shadow: 0 10px 30px rgba(7, 74, 124, .25);
}
.balance-board > span { display: block; }
.balance-board > span:nth-child(odd) { font-size: 12.5px; font-weight: 600; letter-spacing: .02em; opacity: .85; align-self: end; }
.balance-board > span:nth-child(even) {
  font-family: var(--font-display); font-size: 28px; font-weight: 800; letter-spacing: -.02em;
  font-variant-numeric: tabular-nums; align-self: start;
}
/* Сервер талаас өгсөн өнгийг (улаан/ногоон) цайвар дэвсгэр дээр уншигдахуйц болгох */
.balance-board > span[style*="Red"], .balance-board > span[style*="red"] { color: #ffd2d9 !important; }
.balance-board > span[style*="Green"], .balance-board > span[style*="green"] { color: #b8f5d7 !important; }
.balance-board > span:empty { display: none; }
.balance-board:empty { display: none; }
@media (max-width: 600px) {
  .balance-board { grid-template-rows: none; grid-auto-flow: row; }
  .balance-board > span:nth-child(even) { font-size: 24px; margin-bottom: 8px; }
}

/* Toolbar (огноо + үйлдлүүд) */
.toolbar {
  display: flex; flex-wrap: wrap; align-items: flex-end; gap: 12px;
  padding: 16px; margin-bottom: 16px;
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
}
.toolbar .tb-field { display: flex; flex-direction: column; gap: 6px; min-width: 160px; }
.toolbar .tb-field > label { margin: 0; font-size: 12px; text-transform: uppercase; letter-spacing: .05em; color: var(--c-muted); font-weight: 700; }
.toolbar .tb-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.toolbar .tb-spacer { flex: 1 1 auto; }
.toolbar .btn { width: auto !important; }

.cta-row { display: flex; flex-wrap: wrap; gap: 10px; margin: 0 0 18px; }
.cta-row .btn { width: auto !important; }

.qr-row { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin-bottom: 8px; }
.qr-row img:not([src]), .qr-row img[src=""] { display: none; }
.qr-row img { border-radius: var(--radius); border: 1px solid var(--c-border); padding: 6px; background: #fff; }
.qr-row label:empty { display: none; }

.viewer-wrap { margin-top: 8px; }
.viewer-wrap .dxrd-preview, .viewer-wrap table { max-width: 100%; }

/* ---------- Alerts ---------- */
.alert {
  border: 1px solid transparent;
  border-radius: var(--radius);
  padding: 12px 16px 12px 44px;
  position: relative;
  font-weight: 500;
  margin-bottom: 18px;
}
.alert:before {
  font-family: FontAwesome;
  position: absolute; left: 16px; top: 12px;
  font-size: 16px; line-height: 1.4;
}
.alert-danger { background: var(--c-danger-50); border-color: #f6cdd5; color: #8f2337; }
.alert-danger:before { content: "\f06a"; color: var(--c-danger); }
.alert-success { background: var(--c-success-50); border-color: #bfe6d3; color: #0c5b3d; }
.alert-success:before { content: "\f058"; color: var(--c-success); }
.alert-warning { background: var(--c-warning-50); border-color: #f3dcae; color: #7a4d05; }
.alert-warning:before { content: "\f071"; color: var(--c-warning); }
.alert-info { background: var(--c-info-50); border-color: #cbe0f8; color: #194f8c; }
.alert-info:before { content: "\f05a"; color: var(--c-info); }
.alert .close { opacity: .5; text-shadow: none; }
.error:empty { display: none; }
.error:not(:empty) {
  background: var(--c-danger-50); border: 1px solid #f6cdd5; color: #8f2337;
  border-radius: var(--radius); padding: 12px 16px; margin-bottom: 16px; font-weight: 500;
}

/* ---------- Labels & badges ---------- */
.label {
  display: inline-block;
  padding: 3px 9px;
  border-radius: 999px;
  font-size: 11.5px;
  font-weight: 700;
  line-height: 1.5;
  letter-spacing: .01em;
  vertical-align: middle;
}
.label-default { background: var(--c-surface-2); color: var(--c-muted); border: 1px solid var(--c-border); }
.label-primary { background: var(--c-primary-50); color: var(--c-primary-700); }
.label-info { background: var(--c-info-50); color: var(--c-info); }
.label-success { background: var(--c-success-50); color: var(--c-success); }
.label-danger { background: var(--c-danger-50); color: var(--c-danger); }
.label-warning { background: var(--c-warning-50); color: var(--c-warning); }
.badge {
  background: var(--c-danger);
  color: #fff;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  min-width: 20px;
}

/* ---------- List group ---------- */
.list-group { margin-bottom: 0; }
.list-group-item {
  border: 1px solid var(--c-border);
  border-radius: var(--radius) !important;
  margin-bottom: 10px;
  padding: 14px 18px;
  transition: border-color .15s ease, box-shadow .15s ease, transform .15s ease;
}
a.list-group-item:hover, a.list-group-item:focus { background: var(--c-surface); border-color: var(--c-primary-100); box-shadow: var(--shadow); transform: translateY(-1px); }

/* Банк сонгох */
.bank-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(260px, 1fr)); gap: 14px; }
.bank-grid .list-group-item { margin: 0; display: flex; align-items: center; justify-content: center; min-height: 96px; padding: 16px; }
.bank-grid .list-group-item img { max-width: 100%; height: auto; max-height: 56px; width: auto !important; padding: 0 !important; }
.bank-qr.list-group-item {
  grid-column: 1 / -1;
  justify-content: flex-start;
  gap: 18px;
  padding: 22px 24px;
  border: 0;
  color: #fff;
  background:
    radial-gradient(120% 160% at 100% 0%, rgba(255, 255, 255, .18) 0%, rgba(255, 255, 255, 0) 55%),
    linear-gradient(135deg, #12855a 0%, #0b5e3f 100%);
}
.bank-qr.list-group-item:hover, .bank-qr.list-group-item:focus { background: linear-gradient(135deg, #0f7a52 0%, #094f35 100%); color: #fff; }
.bank-qr-icon { flex: 0 0 auto; width: 56px; height: 56px; border-radius: 14px; background: rgba(255, 255, 255, .16); display: flex; align-items: center; justify-content: center; font-size: 26px; }
.bank-qr b { display: block; font-family: var(--font-display); font-size: 18px; font-weight: 800; }
.bank-qr span { opacity: .85; }
.bank-qr .bank-qr-go { margin-left: auto; font-size: 22px; opacity: .8; }

/* QPay апп-ууд */
.app-tiles { display: grid; grid-template-columns: repeat(auto-fill, minmax(84px, 1fr)); gap: 10px; margin-top: 10px; }
.app-tiles .list-group-item { margin: 0; display: flex; align-items: center; justify-content: center; padding: 14px; }
.app-tiles .list-group-item img { border-radius: 12px; }

/* Нөхцөлийн текст */
.terms-box {
  max-height: 240px; overflow-y: auto;
  padding: 16px 18px;
  margin: 10px 0 14px;
  background: var(--c-surface-2);
  border: 1px solid var(--c-border);
  border-radius: var(--radius);
  color: var(--c-muted);
  font-size: 13px; line-height: 1.6;
}
.terms-box b { color: var(--c-ink); }
.terms-box ul { padding-left: 18px; }
.agree-row {
  display: flex; align-items: center; gap: 4px;
  padding: 12px 14px; border-radius: var(--radius);
  background: var(--c-success-50); color: var(--c-success); font-weight: 600;
}
.agree-row .confirm_box { display: inline; }
.form-actions { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin-top: 20px; padding-top: 18px; border-top: 1px solid var(--c-border); }
.form-actions.start { justify-content: flex-start; }
.form-actions.end { justify-content: flex-end; }
.form-actions .btn { width: auto !important; }

/* ---------- Tabs ---------- */
.nav-tabs { border-bottom: 1px solid var(--c-border); display: flex; flex-wrap: wrap; gap: 4px; }
.nav-tabs > li { float: none; margin-bottom: -1px; }
.nav-tabs > li > a {
  border: 0; border-bottom: 2px solid transparent; border-radius: 0;
  color: var(--c-muted); font-weight: 600; padding: 10px 14px; margin: 0;
}
.nav-tabs > li > a:hover { background: transparent; color: var(--c-ink); border-bottom-color: var(--c-border-strong); }
.nav-tabs > li.active > a, .nav-tabs > li.active > a:hover, .nav-tabs > li.active > a:focus {
  border: 0; border-bottom: 2px solid var(--c-primary); color: var(--c-primary-700); background: transparent;
}

/* ---------- Pager (asp:DataPager) ---------- */
.pager-wrap { display: flex; justify-content: center; margin-top: 18px; }
.pager-wrap > span { display: inline-flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.pager-wrap a, .pager-wrap span > span {
  display: inline-flex; align-items: center; justify-content: center;
  min-width: 36px; height: 36px; padding: 0 12px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--c-border);
  background: var(--c-surface);
  color: var(--c-text); font-weight: 600; font-size: 13px;
  text-decoration: none;
}
.pager-wrap a:hover { border-color: var(--c-primary); color: var(--c-primary); }
.pager-wrap span > span, .pager-wrap .active { background: var(--c-primary); border-color: var(--c-primary); color: #fff; }
.pager-wrap a.aspNetDisabled { opacity: .45; pointer-events: none; }

/* Хоосон мэдээлэл */
.empty-state {
  text-align: center; color: var(--c-muted);
  padding: 40px 16px;
  border: 1.5px dashed var(--c-border); border-radius: var(--radius);
  background: var(--c-surface-2);
}
.empty-state:before { content: "\f187"; font-family: FontAwesome; display: block; font-size: 30px; color: var(--c-faint); margin-bottom: 8px; }

/* Мэдээлэл, зөвлөгөөний текст */
.prose { color: var(--c-text); font-size: 15px; line-height: 1.7; }
.prose img { max-width: 100%; height: auto; border-radius: var(--radius); }
.article-card h4 { margin: 0 0 8px; }
.article-card h4 a { color: var(--c-ink); }
.article-card h4 a:hover { color: var(--c-primary); text-decoration: none; }
.read-more { display: inline-flex; align-items: center; gap: 6px; font-weight: 700; margin-top: 8px; }
.read-more:after { content: "\f178"; font-family: FontAwesome; }

/* Газрын зураг */
.map-frame { border-radius: var(--radius); overflow: hidden; border: 1px solid var(--c-border); }

/* Утасны түүх (code-behind well-үүд) */
.history-list .well { display: flex; align-items: center; padding: 10px 14px; margin-bottom: 8px; background: var(--c-surface); }
.history-list .well table td { padding: 0; }
.history-list .well p { margin: 0; }

/* Төлбөрийн баримт */
.receipt {
  max-width: 560px; margin: 0 auto;
  border: 1px solid var(--c-border); border-radius: var(--radius-lg);
  background: var(--c-surface); overflow: hidden;
}
.receipt td { padding: 10px 18px !important; border-bottom: 1px solid var(--c-border) !important; }
.receipt tr:first-child td { background: var(--c-surface-2); font-family: var(--font-display); padding: 16px !important; }
.receipt tr:last-child td { border-bottom: 0 !important; }
.receipt tr td:first-child { color: var(--c-muted); }

/* QPay мэдээлэл */
.pay-summary {
  border: 1px solid #f3dcae; background: var(--c-warning-50);
  border-radius: var(--radius); padding: 16px 18px; margin-bottom: 16px;
}
.pay-summary .row-kv { display: flex; justify-content: space-between; gap: 12px; padding: 4px 0; }
.pay-summary .row-kv b { font-weight: 600; color: var(--c-muted); font-size: 12.5px; letter-spacing: .04em; }
.pay-summary .row-kv span { font-weight: 800; color: var(--c-primary-700); font-variant-numeric: tabular-nums; }
.qr-card { text-align: center; padding: 16px; border: 1px solid var(--c-border); border-radius: var(--radius); background: #fff; }
.qr-card img { max-width: 100%; }

/* Стат карт (Тоолуурын заалт гэх мэт) */
.stat-pill { display: inline-flex; align-items: center; justify-content: center; min-height: 40px; border-radius: var(--radius-sm); }

/* ---------- Utilities ---------- */
.mt-0 { margin-top: 0 !important; }
.mb-0 { margin-bottom: 0 !important; }
.mb-2 { margin-bottom: 8px !important; }
.mb-3 { margin-bottom: 16px !important; }
.gap-2 { gap: 8px; }
.d-flex { display: flex; }
.flex-wrap { flex-wrap: wrap; }
.align-center { align-items: center; }
.justify-between { justify-content: space-between; }

/* RadAjax loading panel */
.loading-panel { background: rgba(255, 255, 255, .7) !important; }

/* ==========================================================================
   Горим солих (цайвар / бараан)
   html[data-theme] — толгой хэсгийн жижиг script тохируулна
   ========================================================================== */
:root[data-theme="dark"] {
  color-scheme: dark;
  --c-ink: #e8f0f7;
  --c-text: #cdd9e5;
  --c-muted: #8ea2b5;
  --c-faint: #687d92;
  --c-bg: #0a141e;
  --c-surface: #101d2a;
  --c-surface-2: #152536;
  --c-border: #1f3347;
  --c-border-strong: #2c4661;
  --c-primary: #3a98de;
  --c-primary-600: #2d88cc;
  --c-primary-700: #9fd0f5;
  --c-primary-50: rgba(58, 152, 222, .14);
  --c-primary-100: rgba(58, 152, 222, .26);
  --c-accent: #2fc6d8;
  --c-success: #36c98b;
  --c-success-50: rgba(54, 201, 139, .13);
  --c-danger: #ff6f86;
  --c-danger-50: rgba(255, 111, 134, .13);
  --c-warning: #f2b445;
  --c-warning-50: rgba(242, 180, 69, .13);
  --c-info: #64aaf5;
  --c-info-50: rgba(100, 170, 245, .13);
  --shadow: 0 1px 2px rgba(0, 0, 0, .3), 0 6px 20px rgba(0, 0, 0, .25);
  --shadow-lg: 0 16px 48px rgba(0, 0, 0, .5);
}
html, body, .app-card, .app-sidebar, .app-topbar.navbar, .item-card, .table-wrap, .panel, .well, .toolbar, .form-control {
  transition: background-color .3s ease, border-color .3s ease, color .3s ease;
}
:root[data-theme="dark"] body { background: var(--c-bg); color: var(--c-text); }
:root[data-theme="dark"] .app-topbar.navbar { background: rgba(10, 20, 30, .88); }
:root[data-theme="dark"] .app-profile { background: radial-gradient(120% 140% at 100% 0%, rgba(47, 198, 216, .35) 0%, rgba(47, 198, 216, 0) 55%), linear-gradient(135deg, #0d4a7c 0%, #082f52 100%); }
:root[data-theme="dark"] .app-profile:after { background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 600 26' preserveAspectRatio='none'%3E%3Cpath d='M0 14 C 75 0 150 0 225 12 S 375 26 450 12 S 560 2 600 10 V26 H0Z' fill='%23101d2a'/%3E%3C/svg%3E"); }
:root[data-theme="dark"] .balance-board { background: radial-gradient(120% 160% at 100% 0%, rgba(47, 198, 216, .35) 0%, rgba(47, 198, 216, 0) 55%), linear-gradient(135deg, #0d4a7c 0%, #082f52 100%); box-shadow: 0 10px 30px rgba(0, 0, 0, .35); }
:root[data-theme="dark"] .list-group-item, :root[data-theme="dark"] .dropdown-menu, :root[data-theme="dark"] .nav-tabs > li.active > a { background-color: var(--c-surface); }
:root[data-theme="dark"] .bank-grid .list-group-item:not(.bank-qr) { background: #f4f7fa; }   /* банкны лого цагаан дээр л уншигдана */
:root[data-theme="dark"] .alert-danger, :root[data-theme="dark"] .error:not(:empty) { color: #ffc3cd; border-color: rgba(255, 111, 134, .3); }
:root[data-theme="dark"] .alert-success { color: #b3f0d4; border-color: rgba(54, 201, 139, .3); }
:root[data-theme="dark"] .alert-warning { color: #ffdc9c; border-color: rgba(242, 180, 69, .3); }
:root[data-theme="dark"] .alert-info { color: #c2defc; border-color: rgba(100, 170, 245, .3); }
:root[data-theme="dark"] .pay-summary { border-color: rgba(242, 180, 69, .3); }
:root[data-theme="dark"] .app-bottombar { background: rgba(16, 29, 42, .96); }
:root[data-theme="dark"] .loading-panel { background: rgba(10, 20, 30, .7) !important; }
:root[data-theme="dark"] .close { color: var(--c-ink); }
:root[data-theme="dark"] .text-muted { color: var(--c-muted); }
:root[data-theme="dark"] img[src*="person.png"] { background: #e9eef3; }
:root[data-theme="dark"] .viewer-wrap { background: #fff; border-radius: 12px; }   /* тайлан цаасан дээр */
:root[data-theme="dark"] .RadComboBox, :root[data-theme="dark"] .RadPicker { filter: invert(.88) hue-rotate(180deg); }

/* Горим солих товч */
.theme-toggle {
  position: relative;
  display: inline-flex; align-items: center; justify-content: center;
  width: 40px; height: 40px; padding: 0;
  border-radius: 50%;
  border: 1px solid var(--c-border);
  background: var(--c-surface);
  color: var(--c-ink);
  cursor: pointer;
  overflow: hidden;
  transition: background-color .2s ease, border-color .2s ease, transform .2s ease;
}
.theme-toggle:hover { border-color: var(--c-primary); color: var(--c-primary); }
.theme-toggle:active { transform: scale(.94); }
.theme-toggle .fa { position: absolute; font-size: 17px; transition: transform .45s cubic-bezier(.2, .8, .2, 1), opacity .3s ease; }
.theme-toggle .fa-moon-o { transform: translateY(0) rotate(0); opacity: 1; }
.theme-toggle .fa-sun-o { transform: translateY(26px) rotate(-90deg); opacity: 0; }
:root[data-theme="dark"] .theme-toggle .fa-moon-o { transform: translateY(-26px) rotate(90deg); opacity: 0; }
:root[data-theme="dark"] .theme-toggle .fa-sun-o { transform: translateY(0) rotate(0); opacity: 1; color: #ffd36b; }
.app-topbar .theme-toggle-li { display: flex; align-items: center; height: var(--topbar-h); padding-left: 6px; }

/* ==========================================================================
   Усны loading
   ========================================================================== */
.water-loader {
  position: fixed; inset: 0; z-index: 3000;
  display: flex; flex-direction: column; align-items: center; justify-content: center; gap: 18px;
  background: rgba(242, 245, 249, .72);
  -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px);
  opacity: 0; visibility: hidden;
  transition: opacity .25s ease, visibility 0s linear .25s;
}
:root[data-theme="dark"] .water-loader { background: rgba(10, 20, 30, .72); }
.water-loader.is-on { opacity: 1; visibility: visible; transition: opacity .25s ease; }
.wl-stage { position: relative; width: 84px; height: 104px; }
.wl-drop {
  position: absolute; left: 10px; top: 0;
  width: 64px; height: 80px;
  -webkit-clip-path: path("M32 0 C32 0 4 33 4 52 A28 28 0 0 0 60 52 C60 33 32 0 32 0 Z");
  clip-path: path("M32 0 C32 0 4 33 4 52 A28 28 0 0 0 60 52 C60 33 32 0 32 0 Z");
  background: var(--c-primary-50);
  box-shadow: inset 0 0 0 2px var(--c-primary-100);
}
.wl-level { position: absolute; left: 0; right: 0; top: 0; bottom: 0; animation: wl-fill 2.6s cubic-bezier(.45, 0, .55, 1) infinite alternate; will-change: transform; }
.wl-wave {
  position: absolute; left: 50%; top: 0;
  width: 160px; height: 160px; margin-left: -80px;
  border-radius: 43%;
  background: linear-gradient(180deg, #2fc6d8 0%, #0a6cb4 60%);
  animation: wl-spin 3.4s linear infinite;
  will-change: transform;
}
.wl-wave.w2 { border-radius: 40%; opacity: .45; background: #7fdcea; animation-duration: 5.2s; animation-direction: reverse; margin-top: -4px; }
.wl-shine { position: absolute; left: 20px; top: 34px; width: 7px; height: 16px; border-radius: 8px; background: rgba(255, 255, 255, .7); transform: rotate(20deg); }
.wl-ripple { position: absolute; left: 50%; bottom: 0; width: 84px; height: 18px; margin-left: -42px; }
.wl-ripple i {
  position: absolute; inset: 0; border-radius: 50%;
  border: 2px solid var(--c-accent);
  opacity: 0; transform: scale(.3);
  animation: wl-ring 2s ease-out infinite;
}
.wl-ripple i:nth-child(2) { animation-delay: .65s; }
.wl-ripple i:nth-child(3) { animation-delay: 1.3s; }
.wl-text { font-weight: 600; font-size: 14px; color: var(--c-ink); letter-spacing: .01em; }
.wl-text:after { content: ""; display: inline-block; width: 1.2em; text-align: left; animation: wl-dots 1.4s steps(4, end) infinite; }
@keyframes wl-spin { to { transform: rotate(360deg); } }
@keyframes wl-fill { from { transform: translateY(74px); } to { transform: translateY(14px); } }
@keyframes wl-ring { 0% { opacity: .7; transform: scale(.3); } 100% { opacity: 0; transform: scale(1.25); } }
@keyframes wl-dots { 0% { content: ""; } 25% { content: "."; } 50% { content: ".."; } 75%, 100% { content: "..."; } }

/* Telerik RadAjaxLoadingPanel → усан дусал */
.RadAjax .raDiv, .loading-panel .raDiv {
  background: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 64 80'%3E%3Cdefs%3E%3CclipPath id='d'%3E%3Cpath d='M32 0C32 0 4 33 4 52a28 28 0 0 0 56 0C60 33 32 0 32 0z'/%3E%3C/clipPath%3E%3ClinearGradient id='g' x1='0' y1='0' x2='0' y2='1'%3E%3Cstop offset='0' stop-color='%232fc6d8'/%3E%3Cstop offset='1' stop-color='%230a6cb4'/%3E%3C/linearGradient%3E%3C/defs%3E%3Cpath d='M32 0C32 0 4 33 4 52a28 28 0 0 0 56 0C60 33 32 0 32 0z' fill='%230a6cb4' fill-opacity='.12'/%3E%3Cg clip-path='url(%23d)'%3E%3Cpath fill='url(%23g)' d='M-64 50 q16 -8 32 0 t32 0 t32 0 t32 0 t32 0 V90 H-64z'%3E%3CanimateTransform attributeName='transform' type='translate' from='0 0' to='64 0' dur='1.4s' repeatCount='indefinite'/%3E%3Canimate attributeName='d' dur='2.6s' repeatCount='indefinite' values='M-64 62 q16 -8 32 0 t32 0 t32 0 t32 0 t32 0 V90 H-64z;M-64 24 q16 -8 32 0 t32 0 t32 0 t32 0 t32 0 V90 H-64z;M-64 62 q16 -8 32 0 t32 0 t32 0 t32 0 t32 0 V90 H-64z'/%3E%3C/path%3E%3C/g%3E%3C/svg%3E") center / 48px 60px no-repeat !important;
}

/* Товчны усан долгион (ripple) */
.btn, .app-nav > li > a, .list-group-item { position: relative; overflow: hidden; }
.ripple-ink {
  position: absolute; border-radius: 50%; pointer-events: none;
  background: currentColor; opacity: .22;
  transform: scale(0);
  animation: ripple-ink .6s cubic-bezier(.2, .8, .2, 1) forwards;
}
@keyframes ripple-ink { to { transform: scale(1); opacity: 0; } }

@media (prefers-reduced-motion: reduce) {
  .wl-level, .wl-wave, .wl-ripple i, .wl-text:after, .ripple-ink, .ls-waves use, .ls-bubbles i, .ls-drop-ring { animation: none !important; }
  .wl-level { transform: translateY(40px); }
}

/* ==========================================================================
   Нэвтрэх хуудас (v3 · усны үзэгдэл)
   ========================================================================== */
body.auth-body { padding-top: 0; min-height: 100vh; background: var(--ls-sky-2); }
:root {
  --ls-sky-1: #eaf7fc; --ls-sky-2: #cdeaf6; --ls-sky-3: #a9d9ee;
  --ls-wave-1: rgba(10, 108, 180, .18); --ls-wave-2: rgba(10, 108, 180, .28); --ls-wave-3: rgba(20, 176, 198, .35); --ls-wave-4: #0a6cb4;
  --ls-card: rgba(255, 255, 255, .78); --ls-card-border: rgba(255, 255, 255, .9);
  --ls-chip: rgba(255, 255, 255, .6); --ls-bubble: rgba(255, 255, 255, .7);
}
:root[data-theme="dark"] {
  --ls-sky-1: #04101c; --ls-sky-2: #071c30; --ls-sky-3: #0b2d4b;
  --ls-wave-1: rgba(47, 198, 216, .10); --ls-wave-2: rgba(47, 198, 216, .16); --ls-wave-3: rgba(58, 152, 222, .26); --ls-wave-4: #0b3a63;
  --ls-card: rgba(16, 29, 42, .78); --ls-card-border: rgba(255, 255, 255, .08);
  --ls-chip: rgba(255, 255, 255, .06); --ls-bubble: rgba(159, 231, 242, .35);
}
.login-scene {
  position: relative; min-height: 100vh; overflow: hidden;
  display: flex; flex-direction: column;
  background:
    radial-gradient(900px 500px at 85% -10%, rgba(255, 255, 255, .55), transparent 60%),
    linear-gradient(180deg, var(--ls-sky-1) 0%, var(--ls-sky-2) 55%, var(--ls-sky-3) 100%);
  color: var(--c-ink);
}
:root[data-theme="dark"] .login-scene {
  background:
    radial-gradient(800px 420px at 80% -5%, rgba(47, 198, 216, .16), transparent 60%),
    radial-gradient(600px 400px at 0% 30%, rgba(58, 152, 222, .12), transparent 60%),
    linear-gradient(180deg, var(--ls-sky-1) 0%, var(--ls-sky-2) 55%, var(--ls-sky-3) 100%);
}
/* доод долгионууд */
.ls-waves { position: absolute; left: 0; right: 0; bottom: 0; width: 100%; height: 22vh; min-height: 120px; max-height: 220px; pointer-events: none; }
.ls-waves use { animation: ls-wave 18s cubic-bezier(.55, .5, .45, .5) infinite; will-change: transform; }
.ls-waves use:nth-child(1) { fill: var(--ls-wave-1); animation-delay: -2s; animation-duration: 11s; }
.ls-waves use:nth-child(2) { fill: var(--ls-wave-2); animation-delay: -3s; animation-duration: 14s; }
.ls-waves use:nth-child(3) { fill: var(--ls-wave-3); animation-delay: -4s; animation-duration: 18s; }
.ls-waves use:nth-child(4) { fill: var(--ls-wave-4); animation-delay: -5s; animation-duration: 26s; }
@keyframes ls-wave { 0% { transform: translate3d(-90px, 0, 0); } 100% { transform: translate3d(85px, 0, 0); } }
.ls-water { position: absolute; left: 0; right: 0; bottom: 0; height: 2px; background: var(--ls-wave-4); }
/* хөөсөнцөр */
.ls-bubbles { position: absolute; inset: 0; pointer-events: none; }
.ls-bubbles i {
  position: absolute; bottom: -20px; border-radius: 50%;
  border: 1px solid var(--ls-bubble);
  background: radial-gradient(circle at 30% 30%, var(--ls-bubble), transparent 60%);
  animation: ls-rise linear infinite; will-change: transform, opacity;
}
.ls-bubbles i:nth-child(1) { left: 6%;  width: 10px; height: 10px; animation-duration: 13s; animation-delay: -2s; }
.ls-bubbles i:nth-child(2) { left: 18%; width: 6px;  height: 6px;  animation-duration: 10s; animation-delay: -6s; }
.ls-bubbles i:nth-child(3) { left: 31%; width: 14px; height: 14px; animation-duration: 16s; animation-delay: -1s; }
.ls-bubbles i:nth-child(4) { left: 47%; width: 8px;  height: 8px;  animation-duration: 12s; animation-delay: -9s; }
.ls-bubbles i:nth-child(5) { left: 63%; width: 12px; height: 12px; animation-duration: 15s; animation-delay: -4s; }
.ls-bubbles i:nth-child(6) { left: 76%; width: 6px;  height: 6px;  animation-duration: 9s;  animation-delay: -3s; }
.ls-bubbles i:nth-child(7) { left: 88%; width: 10px; height: 10px; animation-duration: 14s; animation-delay: -7s; }
.ls-bubbles i:nth-child(8) { left: 95%; width: 7px;  height: 7px;  animation-duration: 11s; animation-delay: -5s; }
@keyframes ls-rise {
  0% { transform: translate3d(0, 0, 0); opacity: 0; }
  10% { opacity: 1; }
  50% { transform: translate3d(12px, -45vh, 0); }
  100% { transform: translate3d(-8px, -95vh, 0); opacity: 0; }
}

.ls-top {
  position: relative; z-index: 2;
  display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap;
  padding: 22px max(20px, 4vw);
}
.ls-brand { display: flex; align-items: center; gap: 12px; color: var(--c-ink); text-decoration: none; }
.ls-brand:hover, .ls-brand:focus { color: var(--c-ink); text-decoration: none; }
.ls-brand img { width: 48px; height: 48px; border-radius: 50%; background: #fff; padding: 3px; box-shadow: 0 6px 18px rgba(10, 108, 180, .2); }
.ls-brand strong { display: block; font-family: var(--font-display); font-size: 16px; font-weight: 800; line-height: 1.2; }
.ls-brand small { display: block; color: var(--c-muted); font-size: 12.5px; }
.ls-nav { display: flex; align-items: center; gap: 8px; flex-wrap: wrap; margin: 0; padding: 0; list-style: none; }
.ls-nav a {
  display: inline-flex; align-items: center; gap: 8px;
  padding: 9px 14px; border-radius: 999px;
  background: var(--ls-chip); border: 1px solid var(--ls-card-border);
  color: var(--c-ink); font-weight: 600; font-size: 13px; text-decoration: none;
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  transition: background-color .2s ease, transform .2s ease;
}
.ls-nav a .fa { color: var(--c-primary); }
.ls-nav a:hover { background: var(--ls-card); transform: translateY(-1px); color: var(--c-ink); }
.ls-nav .theme-toggle { background: var(--ls-chip); border-color: var(--ls-card-border); -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px); }

.ls-main {
  position: relative; z-index: 2;
  flex: 1 1 auto;
  display: grid; grid-template-columns: minmax(0, 1.05fr) minmax(0, 440px);
  align-items: center; gap: 56px;
  width: 100%; max-width: 1180px; margin: 0 auto;
  padding: 12px max(20px, 4vw) calc(22vh + 10px);
}
.ls-intro { min-width: 0; animation: ls-in .8s cubic-bezier(.2, .8, .2, 1) both; }
.ls-eyebrow { display: inline-flex; align-items: center; gap: 8px; padding: 6px 12px; border-radius: 999px; background: var(--ls-chip); border: 1px solid var(--ls-card-border); font-size: 12px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--c-primary-700); }
.ls-eyebrow .fa { color: var(--c-accent); }
.ls-intro h1 { font-family: var(--font-display); font-size: clamp(30px, 4.2vw, 50px); line-height: 1.08; font-weight: 800; letter-spacing: -.035em; margin: 18px 0 14px; text-wrap: balance; color: var(--c-ink); }
.ls-intro h1 em { font-style: normal; background: linear-gradient(90deg, #0a6cb4, #14b0c6); -webkit-background-clip: text; background-clip: text; color: transparent; }
:root[data-theme="dark"] .ls-intro h1 em { background: linear-gradient(90deg, #6cc0f5, #4fe0ee); -webkit-background-clip: text; background-clip: text; }
.ls-intro p { font-size: 16px; color: var(--c-muted); margin: 0 0 26px; max-width: 46ch; }
.ls-features { list-style: none; margin: 0; padding: 0; display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 10px; max-width: 560px; }
.ls-features li {
  display: flex; align-items: center; gap: 10px;
  padding: 11px 14px; border-radius: 14px;
  background: var(--ls-chip); border: 1px solid var(--ls-card-border);
  -webkit-backdrop-filter: blur(8px); backdrop-filter: blur(8px);
  font-weight: 600; font-size: 13.5px; color: var(--c-ink);
}
.ls-features .fa { width: 30px; height: 30px; flex: 0 0 auto; border-radius: 9px; display: inline-flex; align-items: center; justify-content: center; background: linear-gradient(135deg, #14b0c6, #0a6cb4); color: #fff; font-size: 13px; }

.ls-card {
  min-width: 0;
  position: relative;
  background: var(--ls-card);
  border: 1px solid var(--ls-card-border);
  border-radius: 24px;
  padding: 30px 30px 24px;
  -webkit-backdrop-filter: blur(20px) saturate(150%); backdrop-filter: blur(20px) saturate(150%);
  box-shadow: 0 30px 70px -30px rgba(7, 74, 124, .45);
  animation: ls-in .8s .12s cubic-bezier(.2, .8, .2, 1) both;
}
:root[data-theme="dark"] .ls-card { box-shadow: 0 30px 80px -30px rgba(0, 0, 0, .8); }
@keyframes ls-in { from { opacity: 0; transform: translate3d(0, 18px, 0); } to { opacity: 1; transform: none; } }
.ls-card-head { display: flex; align-items: center; gap: 14px; margin-bottom: 20px; }
.ls-drop {
  position: relative; flex: 0 0 auto; width: 52px; height: 52px; border-radius: 16px;
  display: flex; align-items: center; justify-content: center;
  background: linear-gradient(135deg, #14b0c6, #0a6cb4); color: #fff; font-size: 22px;
  box-shadow: 0 10px 22px -8px rgba(10, 108, 180, .7);
}
.ls-drop-ring { position: absolute; inset: -6px; border-radius: 20px; border: 2px solid rgba(20, 176, 198, .45); animation: ls-ring 2.8s ease-out infinite; }
@keyframes ls-ring { 0% { transform: scale(.9); opacity: .9; } 100% { transform: scale(1.25); opacity: 0; } }
.ls-card h2 { font-size: 24px; margin: 0; letter-spacing: -.02em; }
.ls-card .lead-sm { margin: 2px 0 0; color: var(--c-muted); font-size: 13.5px; }
.ls-card .nav-tabs {
  display: grid; grid-template-columns: 1fr 1fr; gap: 4px;
  padding: 4px; margin: 0 0 20px;
  border: 0; border-radius: 14px;
  background: var(--c-surface-2);
}
.ls-card .nav-tabs > li { margin: 0; }
.ls-card .nav-tabs > li > a { text-align: center; border: 0 !important; border-radius: 10px; padding: 9px 10px; color: var(--c-muted); font-weight: 600; transition: background-color .2s ease, color .2s ease, box-shadow .2s ease; }
.ls-card .nav-tabs > li > a:hover { background: transparent; color: var(--c-ink); }
.ls-card .nav-tabs > li.active > a, .ls-card .nav-tabs > li.active > a:hover, .ls-card .nav-tabs > li.active > a:focus {
  background: var(--c-surface); color: var(--c-primary-700); box-shadow: 0 2px 8px rgba(10, 31, 51, .1);
}
.ls-card .tab-pane.active { animation: ls-fade .35s ease both; }
@keyframes ls-fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }
.ls-card .login-box-msg { margin: 0 0 14px; padding: 0; text-align: left; color: var(--c-muted) !important; font-size: 13.5px; }
.ls-field { position: relative; margin-bottom: 12px; }
.ls-field > .fa { position: absolute; left: 15px; top: 50%; transform: translateY(-50%); color: var(--c-faint); pointer-events: none; transition: color .2s ease; }
.ls-field .form-control {
  height: 50px; padding-left: 42px; border-radius: 13px; font-size: 15px;
  background: var(--c-surface); border: 1.5px solid var(--c-border);
  color: var(--c-ink);
}
.ls-field .form-control:focus { border-color: var(--c-primary); box-shadow: 0 0 0 4px rgba(10, 108, 180, .14); }
.ls-field:focus-within > .fa { color: var(--c-primary); }
.ls-card .btn { height: 50px; border-radius: 13px; font-size: 15px; font-weight: 700; }
.ls-card .btn-primary {
  margin-top: 4px;
  background: linear-gradient(135deg, #0b78c6 0%, #0a64a8 55%, #14b0c6 130%);
  border: 0; box-shadow: 0 12px 24px -12px rgba(10, 108, 180, .8);
}
.ls-card .btn-primary:hover { filter: brightness(1.06); }
.ls-actions { display: flex; flex-wrap: wrap; gap: 8px; }
.ls-actions .btn { flex: 1 1 auto; }
.ls-notes { display: grid; gap: 8px; margin-top: 18px; }
.ls-notes .alert { margin: 0; font-size: 12.5px; padding: 10px 12px 10px 38px; border-radius: 12px; }
.ls-notes .alert:before { left: 13px; top: 10px; font-size: 14px; }
.ls-foot { position: absolute; left: 0; right: 0; bottom: 14px; z-index: 3; text-align: center; font-size: 12.5px; color: rgba(255, 255, 255, .85); }

@media (max-width: 991px) {
  .ls-main { grid-template-columns: 1fr; gap: 28px; padding-bottom: 150px; }
  .ls-intro { text-align: left; }
  .ls-intro p { display: none; }
  .ls-card { max-width: 480px; width: 100%; justify-self: center; padding: 24px 20px 20px; }
  .ls-waves { height: 120px; }
}
@media (max-width: 560px) {
  .ls-nav li:not(.ls-theme) { display: none; }
  .ls-features { grid-template-columns: 1fr; }
  .ls-features li:nth-child(n+4) { display: none; }
  .ls-intro h1 { font-size: 28px; margin-top: 12px; }
}

/* Logout */
.logout-wrap { min-height: 100vh; display: flex; align-items: center; justify-content: center; background: var(--c-bg); padding: 24px; }
.logout-card { background: var(--c-surface); border: 1px solid var(--c-border); border-radius: var(--radius-lg); box-shadow: var(--shadow); padding: 36px 32px; text-align: center; max-width: 380px; width: 100%; }
.logout-card .ico { width: 56px; height: 56px; border-radius: 50%; margin: 0 auto 14px; background: var(--c-primary-50); color: var(--c-primary); display: flex; align-items: center; justify-content: center; font-size: 24px; }
.logout-card p:first-of-type { font-family: var(--font-display); font-size: 20px; font-weight: 800; color: var(--c-ink); }

@media print {
  .app-topbar, .app-sidebar-wrap, .app-bottombar, .water-loader { display: none !important; }
  body { padding: 0; background: #fff; }
  .app-shell { padding: 0; }
  .app-card { border: 0; box-shadow: none; padding: 0; }
}

/* Карт бүхэлдээ дарагдах холбоос (дотор нь өөр товчтой үед) */
.stretched-link { color: var(--c-ink); text-decoration: none; }
.stretched-link:hover, .stretched-link:focus { color: var(--c-primary); text-decoration: none; }
.stretched-link:after { content: ""; position: absolute; inset: 0; z-index: 1; border-radius: inherit; }
.above-link { position: relative; z-index: 2; }
.qr-card:not(:has(img)) { display: none; }

/* Хэрэглээний график — шүүлтүүр */
.usage-filters { display: flex; flex-wrap: wrap; align-items: center; gap: 12px 20px; margin: 0; }
.usage-filter { display: inline-flex; align-items: center; gap: 10px; }
.usage-filter-label { font-size: 12px; font-weight: 700; text-transform: uppercase; letter-spacing: .05em; color: var(--c-muted); }

/* Гарчгийн мөрөнд байрлах үйлдлийн товч */
.app-card { position: relative; }
@media (min-width: 768px) {
  .page-actions { position: absolute; top: 24px; right: 32px; margin: 0; z-index: 2; }
  .page-actions + fieldset legend, .page-actions + div > fieldset > legend { margin-top: 0; padding-right: 180px; }
}

/* Шинжилгээний мэдээлэл — файлын карт */
.file-card { display: flex; gap: 16px; align-items: flex-start; }
.file-card .file-icon {
  flex: 0 0 auto; width: 44px; height: 44px; border-radius: 12px;
  display: flex; align-items: center; justify-content: center;
  background: var(--c-primary-50); color: var(--c-primary); font-size: 18px;
}
.file-card .file-main { flex: 1 1 auto; min-width: 0; }
.file-card .item-desc { margin: 2px 0 0; }

/* Bootstrap clearfix pseudo-элементүүд flex/grid таб дээр илүү нүд үүсгэхээс сэргийлэх */
.nav-tabs:before, .nav-tabs:after { display: none; }

@media (max-width: 560px) {
  .ls-features { display: none; }
  .ls-main { gap: 18px; padding-top: 0; }
  .ls-intro h1 { font-size: 26px; margin: 10px 0 0; }
}
.ls-card .nav-tabs > li.active > a { box-shadow: 0 2px 10px rgba(10, 31, 51, .14); }
@media (max-width: 991px) {
  .app-bottombar > ul > li:nth-child(3) .dropdown-menu { left: auto; right: 0; }
}

/* ==========================================================================
   Хялбар бүртгэл (попап + хуудас)
   ========================================================================== */
.easy-types { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; margin-bottom: 16px; }
.easy-type { position: relative; margin: 0; cursor: pointer; font-weight: 500; }
.easy-type input[type="radio"] { position: absolute; opacity: 0; width: 1px; height: 1px; margin: 0; }
.easy-type-card {
  display: flex; flex-direction: column; align-items: flex-start; gap: 2px;
  padding: 14px 16px; border-radius: var(--radius);
  border: 1.5px solid var(--c-border-strong); background: var(--c-surface);
  transition: border-color .15s ease, background-color .15s ease, box-shadow .15s ease;
}
.easy-type-card .fa { font-size: 18px; color: var(--c-faint); margin-bottom: 6px; transition: color .15s ease; }
.easy-type-card b { color: var(--c-ink); font-size: 15px; }
.easy-type-card small { color: var(--c-muted); font-size: 12.5px; }
.easy-type:hover .easy-type-card { border-color: var(--c-primary-100); }
.easy-type input:checked + .easy-type-card { border-color: var(--c-primary); background: var(--c-primary-50); box-shadow: 0 0 0 3px rgba(10, 108, 180, .12); }
.easy-type input:checked + .easy-type-card .fa { color: var(--c-primary); }
.easy-type input:focus-visible + .easy-type-card { outline: 2px solid var(--c-accent); outline-offset: 2px; }
.easy-regno { font-size: 17px !important; font-weight: 600; letter-spacing: .06em; text-transform: uppercase; height: 48px !important; }
.easy-form { max-width: 520px; }

.easy-current {
  display: flex; gap: 16px; align-items: flex-start;
  padding: 18px 20px; margin-bottom: 8px;
  border-radius: var(--radius); border: 1px solid #bfe6d3;
  background: var(--c-success-50);
}
:root[data-theme="dark"] .easy-current { border-color: rgba(54, 201, 139, .3); }
.easy-current-icon { flex: 0 0 auto; width: 42px; height: 42px; border-radius: 50%; display: flex; align-items: center; justify-content: center; background: var(--c-success); color: #fff; font-size: 18px; }
.easy-current-title { font-weight: 800; color: var(--c-ink); font-size: 15.5px; display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }

/* Попап */
.easy-modal { position: fixed; inset: 0; z-index: 2500; display: flex; align-items: center; justify-content: center; padding: 16px; visibility: hidden; pointer-events: none; }
.easy-modal.is-open { visibility: visible; pointer-events: auto; }
.easy-modal-backdrop { position: absolute; inset: 0; background: rgba(8, 22, 38, .55); -webkit-backdrop-filter: blur(4px); backdrop-filter: blur(4px); opacity: 0; transition: opacity .25s ease; }
.easy-modal.is-open .easy-modal-backdrop { opacity: 1; }
.easy-modal-card {
  position: relative; width: 100%; max-width: 480px; max-height: calc(100vh - 32px); overflow-y: auto;
  background: var(--c-surface); border: 1px solid var(--c-border); border-radius: 20px;
  box-shadow: var(--shadow-lg); padding: 26px 24px 22px;
  opacity: 0; transform: translateY(16px) scale(.98);
  transition: opacity .25s ease, transform .3s cubic-bezier(.2, .8, .2, 1);
}
.easy-modal.is-open .easy-modal-card { opacity: 1; transform: none; }
.easy-modal-head { display: flex; gap: 14px; align-items: flex-start; margin-bottom: 18px; }
.easy-modal-head h3 { margin: 2px 0 4px; font-size: 20px; }
.easy-modal-head p { margin: 0; color: var(--c-muted); font-size: 13.5px; }
.easy-modal-icon { flex: 0 0 auto; width: 46px; height: 46px; border-radius: 14px; display: flex; align-items: center; justify-content: center; background: linear-gradient(135deg, #14b0c6, #0a6cb4); color: #fff; font-size: 20px; }
.easy-modal-msg { margin: -4px 0 14px; padding: 10px 12px; border-radius: 10px; font-size: 13.5px; font-weight: 500; }
.easy-modal-msg.is-ok { background: var(--c-success-50); color: var(--c-success); }
.easy-modal-msg.is-err { background: var(--c-danger-50); color: var(--c-danger); }
.easy-modal-msg[hidden] { display: none; }
.easy-modal-actions { display: flex; justify-content: flex-end; gap: 8px; flex-wrap: wrap; }
.btn.is-busy { pointer-events: none; opacity: .85; }
.btn.is-busy .fa { animation: wl-spin .9s linear infinite; }
.btn.is-busy .fa:before { content: "\f110"; }
body.easy-lock { overflow: hidden; }
@media (max-width: 480px) {
  .easy-types { grid-template-columns: 1fr; }
  .easy-modal { align-items: flex-end; padding: 0; }
  .easy-modal-card { max-width: none; border-radius: 20px 20px 0 0; padding-bottom: calc(22px + env(safe-area-inset-bottom, 0px)); }
}
@media (prefers-reduced-motion: reduce) { .easy-modal-card, .easy-modal-backdrop { transition: none; } }

/* Хялбар бүртгэл — 2 алхам */
.easy-steps { list-style: none; display: grid; grid-template-columns: 1fr 1fr; gap: 8px; margin: 0 0 16px; padding: 0; counter-reset: es; }
.easy-steps li { counter-increment: es; display: flex; align-items: center; gap: 8px; font-size: 12.5px; font-weight: 700; color: var(--c-faint); padding-bottom: 8px; border-bottom: 3px solid var(--c-border); transition: color .2s ease, border-color .2s ease; }
.easy-steps li:before { content: counter(es); width: 22px; height: 22px; border-radius: 50%; display: inline-flex; align-items: center; justify-content: center; font-size: 12px; background: var(--c-surface-2); border: 1px solid var(--c-border); color: var(--c-muted); }
.easy-steps li.is-active { color: var(--c-primary-700); border-color: var(--c-primary); }
.easy-steps li.is-active:before { background: var(--c-primary); border-color: var(--c-primary); color: #fff; }
.easy-check-row { display: flex; gap: 8px; }
.easy-check-row .form-control { flex: 1 1 auto; min-width: 0; }
.easy-check-btn { flex: 0 0 auto; height: 48px; padding: 0 18px; }
.easy-result {
  display: flex; flex-direction: column; align-items: center; gap: 2px; text-align: center;
  margin: 0 0 16px; padding: 16px; border-radius: var(--radius);
  border: 1.5px dashed var(--c-success); background: var(--c-success-50);
  animation: ls-fade .3s ease both;
}
.easy-result[hidden] { display: none; }
.easy-result-label { font-size: 11.5px; font-weight: 700; letter-spacing: .08em; text-transform: uppercase; color: var(--c-muted); }
.easy-result-code { font-family: var(--font-display); font-size: 26px; font-weight: 800; letter-spacing: .04em; color: var(--c-ink); font-variant-numeric: tabular-nums; word-break: break-all; }
.easy-result-reg { font-size: 12.5px; color: var(--c-muted); }
.easy-modal-actions { justify-content: space-between; align-items: center; }
.easy-logout { color: var(--c-muted); font-size: 13px; font-weight: 600; }
.easy-logout:hover { color: var(--c-danger); text-decoration: none; }
.easy-modal-actions .btn[disabled] { opacity: .45; cursor: not-allowed; box-shadow: none; }
@keyframes ls-fade { from { opacity: 0; transform: translateY(6px); } to { opacity: 1; transform: none; } }

/* Мэдээлэл өөрчлөх үеийн анхааруулга */
.easy-confirm .easy-modal-card { max-width: 560px; }
.easy-warn-icon { background: linear-gradient(135deg, #f2a524, #d9770b) !important; }
.easy-compare { display: grid; grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr); align-items: stretch; gap: 10px; margin-bottom: 16px; }
.easy-compare-col { position: relative; border-radius: 14px; padding: 14px 14px 10px; border: 1px solid var(--c-border); background: var(--c-surface-2); min-width: 0; }
.easy-compare-col.is-new { border-color: var(--c-warning); background: var(--c-warning-50); }
.easy-compare-tag { display: inline-block; margin-bottom: 8px; font-size: 11px; font-weight: 800; letter-spacing: .08em; text-transform: uppercase; color: var(--c-muted); }
.easy-compare-col.is-new .easy-compare-tag { color: var(--c-warning); }
.easy-compare dl { margin: 0; display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 4px 10px; font-size: 13px; }
.easy-compare dt { color: var(--c-muted); font-weight: 500; }
.easy-compare dd { margin: 0; color: var(--c-ink); font-weight: 700; word-break: break-all; font-variant-numeric: tabular-nums; }
.easy-compare-col.is-old dd { text-decoration: line-through; text-decoration-color: rgba(207, 63, 87, .55); }
.easy-compare-arrow { display: flex; align-items: center; color: var(--c-warning); font-size: 20px; }
.easy-warn-list { list-style: none; margin: 0 0 16px; padding: 14px 16px; display: grid; gap: 10px; border-radius: 14px; background: var(--c-danger-50); border: 1px solid #f6cdd5; }
:root[data-theme="dark"] .easy-warn-list { border-color: rgba(255, 111, 134, .3); }
.easy-warn-list li { display: flex; gap: 10px; align-items: flex-start; font-size: 13.5px; line-height: 1.5; color: var(--c-text); }
.easy-warn-list li .fa { flex: 0 0 auto; width: 18px; margin-top: 3px; text-align: center; color: var(--c-danger); }
.easy-warn-list li b { color: var(--c-ink); }
.easy-agree { display: flex; gap: 10px; align-items: flex-start; margin: 0 0 18px; padding: 12px 14px; border-radius: 12px; border: 1.5px solid var(--c-border-strong); cursor: pointer; font-weight: 500; font-size: 13.5px; color: var(--c-text); transition: border-color .15s ease, background-color .15s ease; }
.easy-agree input { flex: 0 0 auto; width: 18px; height: 18px; margin: 1px 0 0; accent-color: var(--c-warning); cursor: pointer; }
.easy-agree:has(input:checked) { border-color: var(--c-warning); background: var(--c-warning-50); }
.easy-confirm .easy-modal-actions { justify-content: flex-end; }
@media (max-width: 560px) {
  .easy-compare { grid-template-columns: 1fr; }
  .easy-compare-arrow { justify-content: center; transform: rotate(90deg); }
}
.easy-compare dl { grid-template-columns: 1fr; gap: 0; }
.easy-compare dt { font-size: 11.5px; margin-top: 6px; }
.easy-compare dt:first-child { margin-top: 0; }
.easy-compare dd { font-size: 14px; }
.easy-confirm .btn-warning[disabled], .easy-confirm .btn-warning[disabled]:hover {
  background: var(--c-surface-2); border-color: var(--c-border-strong); color: var(--c-faint); opacity: 1; box-shadow: none;
}
