:root {
  color-scheme: light;
  --page: #f4f6f8;
  --surface: #ffffff;
  --surface-soft: #f8fafb;
  --ink: #19272f;
  --muted: #697b86;
  --muted-light: #94a2aa;
  --line: #e2e8eb;
  --line-strong: #ccd8dd;
  --teal: #117d89;
  --teal-soft: #e6f4f5;
  --cyan: #38aeba;
  --blue: #3478c7;
  --blue-soft: #eaf2fb;
  --amber: #c98727;
  --amber-soft: #fff4df;
  --green: #27845c;
  --green-soft: #e8f5ef;
  --violet: #7168c9;
  --pink: #b95b7f;
  --danger: #b64942;
  --danger-soft: #fbecea;
  --shadow: 0 14px 38px rgba(31, 51, 61, .07);
}

* { box-sizing: border-box; }
html, body { margin: 0; min-width: 320px; min-height: 100%; background: var(--page); color: var(--ink); font-family: Inter, ui-sans-serif, -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif; font-size: 14px; }
body { min-height: 100vh; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
.sr-only { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0, 0, 0, 0); white-space: nowrap; border: 0; }
.is-hidden { display: none !important; }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible { outline: 3px solid rgba(17,125,137,.26); outline-offset: 2px; }
.eyebrow, .panel-kicker { margin: 0; color: var(--teal); font-size: 12px; font-weight: 750; letter-spacing: .12em; }
.brand-mark { width: 54px; height: 54px; display: grid; place-items: center; border: 1px solid rgba(17,125,137,.24); border-radius: 15px 5px 15px 5px; background: linear-gradient(145deg, #ffffff, #e8f6f7); color: var(--teal); font: 700 25px Georgia, serif; box-shadow: 0 10px 28px rgba(17,125,137,.1); }
.brand-mark.small { width: 40px; height: 40px; border-radius: 11px 4px 11px 4px; font-size: 19px; }

/* Login */
.login-shell { --mx: 30%; --my: 75%; min-height: 100vh; display: grid; grid-template-columns: minmax(420px, 1.08fr) minmax(420px, .92fr); overflow: hidden; background: var(--surface); }
.login-return { position: fixed; z-index: 5; top: 30px; right: 38px; display: inline-flex; align-items: center; gap: 8px; min-height: 36px; color: #607581; font-size: 13px; font-weight: 600; text-decoration: none; }
.login-return:hover { color: var(--teal); }
.login-return span { color: var(--teal); }
.login-brand-panel { position: relative; z-index: 1; min-height: 100vh; overflow: hidden; padding: 54px 6vw; border-right: 1px solid var(--line); background: linear-gradient(145deg, rgba(238,248,249,.9) 0%, rgba(247,250,251,.91) 68%, rgba(242,245,247,.92) 100%); }
.login-grid { position: absolute; inset: 0; opacity: .55; background-image: linear-gradient(rgba(17,125,137,.08) 1px, transparent 1px), linear-gradient(90deg, rgba(17,125,137,.08) 1px, transparent 1px); background-size: 56px 56px; mask-image: linear-gradient(to bottom right, black, transparent 78%); }
.login-brand-panel::before { content: ""; position: absolute; width: 520px; height: 520px; left: -260px; top: -280px; border: 1px solid rgba(17,125,137,.1); border-radius: 50%; box-shadow: 0 0 0 82px rgba(17,125,137,.025), 0 0 0 164px rgba(17,125,137,.015); }
.cursor-glow { position: fixed; z-index: 0; left: var(--mx); top: var(--my); width: 560px; height: 560px; transform: translate(-50%, -50%); border-radius: 50%; pointer-events: none; background: radial-gradient(circle, rgba(81,207,214,.3) 0%, rgba(74,173,186,.13) 30%, transparent 68%); filter: blur(8px); transition: left .08s linear, top .08s linear; }
.brand-lockup { position: relative; z-index: 2; display: flex; align-items: center; gap: 15px; }
.brand-lockup strong, .brand-lockup span { display: block; }
.brand-lockup strong { font: 500 21px Georgia, serif; }
.brand-lockup span { margin-top: 5px; color: #76909a; font-size: 12px; font-weight: 700; letter-spacing: .1em; }
.login-brand-copy { position: absolute; z-index: 2; left: 6vw; bottom: 13vh; }
.login-brand-copy h1 { margin: 14px 0 14px; font: 400 clamp(54px, 6vw, 82px)/1.08 Georgia, "Songti SC", serif; letter-spacing: -.035em; }
.login-brand-copy > p:not(.eyebrow) { margin: 0; color: #58717d; font-size: 18px; letter-spacing: .04em; }
.signal-line { display: flex; align-items: center; gap: 9px; margin-top: 48px; color: #78909a; font-size: 12px; font-weight: 650; text-transform: uppercase; letter-spacing: .1em; }
.signal-line i { width: 8px; height: 8px; border-radius: 50%; background: var(--green); box-shadow: 0 0 12px rgba(39,132,92,.34); }
.login-form-panel { position: relative; z-index: 1; display: grid; place-items: center; min-height: 100vh; padding: 100px 7vw 50px; background: rgba(255,255,255,.92); }
.login-form { width: min(410px, 100%); display: grid; gap: 21px; }
.form-title { margin-bottom: 16px; }
.form-title h2 { margin: 10px 0 0; font: 500 32px Georgia, "Songti SC", serif; }
label { display: grid; gap: 8px; color: #526873; font-size: 13px; font-weight: 650; }
input, select, textarea { width: 100%; border: 1px solid var(--line-strong); border-radius: 9px; background: #ffffff; color: var(--ink); outline: 0; transition: border .2s, box-shadow .2s, background .2s; }
input { height: 46px; padding: 0 14px; }
select { height: 44px; padding: 0 36px 0 12px; }
textarea { padding: 13px 14px; resize: vertical; line-height: 1.65; }
input::placeholder, textarea::placeholder { color: #a0adb3; }
input:focus, select:focus, textarea:focus { border-color: rgba(17,125,137,.62); box-shadow: 0 0 0 3px rgba(17,125,137,.09); }
label small { color: #82929a; font-size: 12px; font-weight: 450; line-height: 1.55; }
.login-options { display: flex; align-items: center; justify-content: space-between; min-height: 24px; }
.checkbox-row { display: flex; align-items: center; gap: 8px; color: #697f8a; font-weight: 500; }
.checkbox-row input { width: 16px; height: 16px; accent-color: var(--teal); }
.security-hint { color: #899aa2; font-size: 12px; letter-spacing: .06em; }
.primary-button, .ghost-button, .danger-button { border-radius: 9px; font-size: 13px; font-weight: 700; }
.primary-button { min-height: 44px; padding: 0 18px; border: 1px solid var(--teal); background: var(--teal); color: white; box-shadow: 0 10px 24px rgba(17,125,137,.16); }
.primary-button:hover { border-color: #0c6f79; background: #0c6f79; }
.primary-button:disabled, .ghost-button:disabled, .danger-button:disabled { cursor: wait; opacity: .58; box-shadow: none; }
.primary-button.compact { min-height: 40px; }
.login-button { display: flex; align-items: center; justify-content: space-between; margin-top: 2px; padding: 0 18px 0 20px; }
.login-button b { font-size: 18px; }
.ghost-button { min-height: 40px; padding: 0 15px; border: 1px solid var(--line-strong); background: white; color: #5d717c; }
.ghost-button:hover { color: var(--teal); border-color: rgba(17,125,137,.42); background: #f8fcfc; }
.danger-button { min-height: 40px; padding: 0 15px; border: 1px solid #e5b9b5; background: var(--danger-soft); color: var(--danger); }
.form-hint { min-height: 18px; margin: -6px 0 0; color: var(--danger); font-size: 12px; line-height: 1.5; }

/* App shell */
.app-shell { min-height: 100vh; display: grid; grid-template-columns: 230px minmax(0, 1fr); background: var(--page); }
.sidebar { position: sticky; top: 0; height: 100vh; display: flex; flex-direction: column; padding: 28px 18px; border-right: 1px solid var(--line); background: rgba(255,255,255,.94); backdrop-filter: blur(18px); }
.sidebar-brand { display: flex; align-items: center; gap: 12px; padding: 0 7px; margin-bottom: 46px; }
.sidebar-brand strong, .sidebar-brand span { display: block; }
.sidebar-brand strong { font: 500 17px Georgia, serif; }
.sidebar-brand span { margin-top: 4px; color: #7b8d96; font-size: 12px; }
nav { display: grid; gap: 7px; }
.nav-item { width: 100%; min-height: 46px; display: flex; align-items: center; gap: 12px; padding: 0 14px; border: 1px solid transparent; border-radius: 9px; background: transparent; color: #657985; text-align: left; font-size: 14px; font-weight: 600; }
.nav-item i { width: 21px; color: #79909a; font-style: normal; font-size: 19px; text-align: center; }
.nav-item:hover { border-color: var(--line); background: var(--surface-soft); color: #405761; }
.nav-item.active { border-color: #cde4e6; background: var(--teal-soft); color: #0d6872; box-shadow: inset 3px 0 0 var(--teal); }
.nav-item.active i { color: var(--teal); }
.sidebar-foot { display: grid; gap: 11px; margin-top: auto; padding-top: 18px; border-top: 1px solid var(--line); }
.sidebar-account { min-width: 0; display: flex; align-items: center; gap: 10px; padding: 0 8px; }
.sidebar-account > span { width: 36px; height: 36px; display: grid; place-items: center; flex: none; border: 1px solid #cde4e6; border-radius: 9px; background: var(--teal-soft); color: var(--teal); font-size: 12px; font-weight: 800; }
.sidebar-account div { min-width: 0; }.sidebar-account strong, .sidebar-account small { display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }.sidebar-account strong { color: #40545e; font-size: 12px; }.sidebar-account small { margin-top: 3px; color: #8a99a0; font-size: 12px; }
.sidebar-actions { display: grid; grid-template-columns: 1fr 1fr; gap: 6px; }
.sidebar-actions a, .sidebar-actions button { min-width: 0; min-height: 38px; display: flex; align-items: center; justify-content: center; gap: 6px; padding: 0 8px; border: 1px solid transparent; border-radius: 7px; background: transparent; color: #71858f; font-size: 12px; font-weight: 600; text-align: center; text-decoration: none; white-space: nowrap; }
.sidebar-actions a:hover, .sidebar-actions button:hover { border-color: var(--line); background: var(--surface-soft); color: var(--teal); }
.sidebar-actions i { color: var(--teal); font-style: normal; font-size: 14px; }
.workspace { min-width: 0; padding: 0 3.5vw 60px; }
.topbar { min-height: 104px; display: flex; align-items: center; border-bottom: 1px solid var(--line); }
.breadcrumb { margin: 0 0 8px; color: #8a9aa2; font-size: 12px; font-weight: 700; letter-spacing: .1em; }
.breadcrumb span { color: #607a85; }
.topbar h1 { margin: 0; font: 500 26px Georgia, "Songti SC", serif; }
.admin-profile { display: flex; align-items: center; gap: 10px; }
.admin-profile > span { width: 40px; height: 40px; display: grid; place-items: center; border: 1px solid #cde4e6; border-radius: 10px; background: var(--teal-soft); color: var(--teal); font-weight: 800; }
.admin-profile strong, .admin-profile small { display: block; }
.admin-profile strong { font-size: 13px; }
.admin-profile small { margin-top: 3px; color: #87969d; font-size: 12px; }
.content-section { padding-top: 32px; }
.dashboard-module + .dashboard-module { margin-top: 38px; padding-top: 34px; border-top: 1px solid var(--line); }
.module-index { margin: 0 0 8px !important; color: var(--teal) !important; font-size: 12px !important; font-weight: 750; letter-spacing: .1em; }
.data-note, .usage-basis { padding: 6px 9px; border: 1px solid #cbdcdf; border-radius: 99px; background: #f5fafb; color: #66808b; font-size: 12px; font-weight: 600; }
.section-heading { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin-bottom: 22px; }
.section-heading h2 { margin: 0 0 6px; font: 500 24px Georgia, "Songti SC", serif; }
.section-heading p { margin: 0; color: var(--muted); font-size: 13px; }
.section-heading > button { flex: none; }
.metric-grid.five { display: grid; grid-template-columns: repeat(5, minmax(156px, 1fr)); gap: 13px; }
.metric-card { min-height: 150px; padding: 20px; border: 1px solid var(--line); border-radius: 11px; background: var(--surface); box-shadow: 0 8px 24px rgba(31,51,61,.04); }
.metric-top { display: flex; align-items: center; justify-content: space-between; color: #657b86; font-size: 13px; font-weight: 650; }
.metric-dot { width: 7px; height: 7px; border-radius: 50%; box-shadow: 0 0 9px currentColor; }
.metric-dot.amber { background: var(--amber); color: var(--amber); }.metric-dot.cyan { background: var(--cyan); color: var(--cyan); }.metric-dot.violet { background: var(--violet); color: var(--violet); }.metric-dot.green { background: var(--green); color: var(--green); }.metric-dot.pink { background: var(--pink); color: var(--pink); }
.metric-card strong { display: block; margin: 19px 0 8px; font: 500 35px Georgia, serif; letter-spacing: -.02em; }
.metric-card small { color: #88979e; font-size: 12px; }
.model-usage-metrics { display: grid; grid-template-columns: repeat(4, minmax(160px, 1fr)); gap: 13px; }
.model-usage-panel { margin-top: 14px; overflow: hidden; }
.model-usage-panel > .panel-heading { padding: 20px 20px 17px; border-bottom: 1px solid var(--line); }
.model-usage-table { min-width: 760px; }
.usage-model-cell strong, .usage-model-cell small, .token-split { display: block; }.usage-model-cell strong { color: #334851; font-size: 13px; }.usage-model-cell small, .token-split { margin-top: 4px; color: #87979f; font-size: 12px; font-weight: 450; }
.usage-number { color: #344a54; font-size: 14px; }
.model-usage-empty { padding: 48px 24px; }
.usage-disclaimer { margin: 0; padding: 13px 18px; border-top: 1px solid var(--line); background: var(--surface-soft); color: #7c8f98; font-size: 12px; line-height: 1.55; }
.panel { border: 1px solid var(--line); border-radius: 11px; background: var(--surface); box-shadow: var(--shadow); }
.chart-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; margin-top: 14px; }
.chart-panel { min-height: 340px; padding: 22px 22px 17px; }
.panel-heading { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; }
.panel-heading h3 { margin: 7px 0 0; font-size: 16px; }
.chart-legend { padding: 5px 9px; border: 1px solid currentColor; border-radius: 99px; font-size: 12px; font-weight: 600; }
.chart-legend.amber { color: var(--amber); background: var(--amber-soft); }.chart-legend.cyan { color: var(--teal); background: var(--teal-soft); }
.canvas-wrap { position: relative; height: 235px; margin-top: 20px; }
.canvas-wrap canvas { width: 100%; height: 100%; }

/* Users */
.user-panel { overflow: hidden; }
.toolbar { display: flex; align-items: center; padding: 16px 18px; border-bottom: 1px solid var(--line); background: var(--surface-soft); }
.search-box { position: relative; display: block; width: min(430px, 100%); }
.search-box span { position: absolute; left: 13px; top: 8px; color: #83969f; font-size: 19px; }
.search-box input { height: 42px; padding-left: 40px; background: white; }
.table-wrap { overflow-x: auto; }
table { width: 100%; min-width: 940px; border-collapse: collapse; }
th, td { padding: 15px 17px; border-bottom: 1px solid #edf1f3; text-align: left; }
th { height: 58px; color: #687d87; font-size: 12px; font-weight: 700; letter-spacing: .02em; }
td { color: #5f737e; font-size: 13px; }
tbody tr:hover { background: #fbfcfd; }
tr.disabled-row { background: #f1f3f4; }
tr.disabled-row:hover { background: #eceff1; }
tr.disabled-row td, tr.disabled-row .user-cell strong, tr.disabled-row .user-cell small { color: #8a959b; }
tr.disabled-row .user-avatar { border-color: #d5dadd; background: #e7eaec; color: #7f8b91; }
tr.disabled-row .badge { border-color: #bfc7cb; background: #e5e9eb; color: #78858c; }
tr.disabled-row .mini-button { border-color: #d2d8db; background: #f7f8f8; color: #728087; }
.table-filter { position: relative; width: max-content; display: flex; align-items: center; gap: 7px; color: inherit; font-size: inherit; font-weight: inherit; cursor: pointer; }
.filter-trigger { position: relative; width: 28px; height: 28px; display: grid; place-items: center; flex: none; border: 1px solid transparent; border-radius: 7px; background: transparent; transition: border-color .18s, background .18s, color .18s; }
.filter-trigger::before { content: ""; width: 13px; height: 12px; background: #7a8d96; clip-path: polygon(0 8%, 100% 8%, 62% 48%, 62% 91%, 38% 75%, 38% 48%); transition: background .18s; }
.table-filter select { position: absolute; z-index: 2; right: 0; top: 50%; width: 28px; height: 28px; padding: 0; border: 0; opacity: 0; transform: translateY(-50%); cursor: pointer; }
.table-filter:hover .filter-trigger, .table-filter:focus-within .filter-trigger { border-color: var(--line-strong); background: white; }
.table-filter.is-filtered .filter-trigger { border-color: #9dcfd3; background: var(--teal-soft); }
.table-filter.is-filtered .filter-trigger::before { background: var(--teal); }
.user-cell { display: flex; align-items: center; gap: 11px; }
.user-avatar { width: 36px; height: 36px; display: grid; place-items: center; flex: none; border: 1px solid #cde4e6; border-radius: 9px; background: var(--teal-soft); color: var(--teal); font-weight: 800; }
.user-cell strong, .user-cell small { display: block; }.user-cell strong { color: #263840; font-size: 13px; }.user-cell small { margin-top: 4px; color: #82939b; font-size: 12px; }
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 5px 9px; border: 1px solid currentColor; border-radius: 99px; font-size: 12px; font-weight: 700; }
.badge::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: currentColor; }.badge.paid { color: var(--blue); background: var(--blue-soft); }.badge.free { color: #687d87; background: #f1f4f5; }.badge.active { color: var(--green); background: var(--green-soft); }.badge.disabled { color: #78858c; background: #e8ecee; }
.plan-cell { min-width: 0; display: flex; align-items: center; white-space: nowrap; }
.plan-access-badge { max-width: 180px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.plan-access-badge.incomplete { border-color: #b9c4c9; background: #eef1f2; color: #77858c; }
.action-group { display: flex; gap: 7px; }
.mini-button { min-height: 34px; padding: 0 11px; border: 1px solid var(--line-strong); border-radius: 7px; background: white; color: #607580; font-size: 12px; font-weight: 650; white-space: nowrap; }
.mini-button:hover { border-color: rgba(17,125,137,.42); color: var(--teal); background: #f8fcfc; }.mini-button.danger:hover { border-color: #dfa9a5; color: var(--danger); background: var(--danger-soft); }
.empty-state { padding: 58px; color: var(--muted); text-align: center; }
.table-footer { display: flex; justify-content: space-between; padding: 14px 17px; color: #82939b; font-size: 12px; }

/* Models */
.model-layout { display: grid; grid-template-columns: 320px minmax(0, 1fr); gap: 14px; align-items: start; }
.model-list-panel { overflow: hidden; }
.model-list-head { display: flex; justify-content: space-between; padding: 17px; border-bottom: 1px solid var(--line); color: #4e636e; font-size: 13px; font-weight: 700; }.model-list-head small { color: #83939b; font-size: 12px; font-weight: 500; }
.model-list { display: grid; padding: 8px; }
.model-item { width: 100%; display: grid; grid-template-columns: 38px 1fr auto; align-items: center; gap: 11px; padding: 12px; border: 1px solid transparent; border-radius: 9px; background: transparent; color: inherit; text-align: left; }
.model-item:hover { background: var(--surface-soft); }.model-item.active { border-color: #cde4e6; background: var(--teal-soft); }
.model-logo { width: 36px; height: 36px; display: grid; place-items: center; border: 1px solid var(--line); border-radius: 50%; background: white; color: #263b45; font-weight: 800; font-size: 12px; }
.model-item strong, .model-item small { display: block; }.model-item strong { color: #31454e; font-size: 13px; }.model-item small { margin-top: 4px; color: #82939b; font-size: 12px; line-height: 1.45; }.model-status { width: 8px; height: 8px; border-radius: 50%; background: #bdc7cb; }.model-status.ready { background: var(--green); box-shadow: 0 0 8px rgba(39,132,92,.32); }.model-status.pending { background: var(--amber); }
.model-editor-panel { padding: 24px; }
.model-form { display: grid; gap: 19px; }
.model-editor-head { display: flex; align-items: center; justify-content: space-between; padding-bottom: 17px; border-bottom: 1px solid var(--line); }.model-editor-head h3 { margin: 7px 0 0; font-size: 19px; }
.config-badge { padding: 6px 9px; border: 1px solid #dfaaa6; border-radius: 99px; background: var(--danger-soft); color: var(--danger); font-size: 12px; font-weight: 650; }.config-badge.configured { border-color: #a9d7c1; background: var(--green-soft); color: var(--green); }
.form-grid.two { display: grid; grid-template-columns: 1fr 1fr; gap: 14px; }
.form-grid.two > label { align-self: start; align-content: start; }
.model-assignment-grid > label { grid-template-rows: auto 44px auto; }
.model-assignment-grid select {
  height: 44px;
  padding-right: 52px;
  appearance: none;
  -webkit-appearance: none;
  background-image:
    linear-gradient(45deg, transparent 50%, #6b7f89 50%),
    linear-gradient(135deg, #6b7f89 50%, transparent 50%);
  background-position:
    calc(100% - 26px) 50%,
    calc(100% - 21px) 50%;
  background-size: 5px 5px, 5px 5px;
  background-repeat: no-repeat;
}
.model-assignment-grid select:focus-visible { outline: 0; }
.model-assignment-grid small { min-height: 38px; }
.password-field { display: grid; grid-template-columns: 1fr 64px; }.password-field input { border-radius: 9px 0 0 9px; }.password-field button { border: 1px solid var(--line-strong); border-left: 0; border-radius: 0 9px 9px 0; background: var(--surface-soft); color: #617681; font-size: 12px; font-weight: 650; }
.model-custom-input { margin-top: 2px; }
.model-switches { display: grid; grid-template-columns: 1fr 1fr; gap: 11px; }
.switch-row { position: relative; min-height: 68px; display: flex; align-items: center; justify-content: space-between; padding: 12px 15px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface-soft); cursor: pointer; }.switch-row span { display: block; }.switch-row strong, .switch-row small { display: block; }.switch-row strong { color: #526873; font-size: 13px; }.switch-row small { margin-top: 4px; color: #87979f; font-size: 12px; }.switch-row input { position: absolute; opacity: 0; }.switch-row i { width: 38px; height: 22px; position: relative; flex: none; border-radius: 99px; background: #ced7db; transition: .2s; }.switch-row i::after { content: ""; position: absolute; width: 16px; height: 16px; left: 3px; top: 3px; border-radius: 50%; background: white; box-shadow: 0 1px 4px rgba(0,0,0,.18); transition: .2s; }.switch-row input:checked + i { background: var(--teal); }.switch-row input:checked + i::after { left: 19px; }
.model-actions { display: flex; justify-content: flex-end; gap: 10px; padding-top: 2px; }.model-actions .danger-button { margin-right: auto; }

/* Dialogs */
dialog { width: min(480px, calc(100% - 28px)); max-height: calc(100dvh - 28px); overflow-y: auto; padding: 0; border: 1px solid var(--line-strong); border-radius: 14px; background: white; color: var(--ink); box-shadow: 0 35px 100px rgba(31,51,61,.24); }
#planDialog { width: min(600px, calc(100% - 28px)); }
dialog::backdrop { background: rgba(28,40,47,.45); backdrop-filter: blur(4px); }
.dialog-card { display: grid; gap: 18px; padding: 27px; }.dialog-heading { display: flex; justify-content: space-between; }.dialog-heading h2 { margin: 8px 0 0; font: 500 26px Georgia, "Songti SC", serif; }.icon-button { width: 40px; height: 40px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface-soft); color: #6f828c; font-size: 21px; }.dialog-actions { display: flex; justify-content: flex-end; gap: 10px; }.confirm-card { text-align: center; }.confirm-card h2 { margin: 0; font: 500 24px Georgia, "Songti SC", serif; }.confirm-card p { margin: -5px 0 5px; color: #667b86; font-size: 13px; line-height: 1.7; }.confirm-icon { width: 46px; height: 46px; display: grid; place-items: center; margin: 0 auto; border: 1px solid #e7c88f; border-radius: 50%; background: var(--amber-soft); color: var(--amber); font-weight: 800; }.confirm-card .dialog-actions { justify-content: center; }
.plan-dialog-card { width: 100%; }
.plan-user-summary { display: flex; align-items: center; gap: 11px; padding: 12px; border: 1px solid var(--line); border-radius: 9px; background: var(--surface-soft); }.plan-user-summary strong, .plan-user-summary small { display: block; }.plan-user-summary strong { color: #32464f; }.plan-user-summary small { margin-top: 4px; color: #82939b; font-size: 12px; }
.plan-tier-fieldset { min-width: 0; margin: 0; padding: 0; border: 0; }
.plan-tier-fieldset legend { margin-bottom: 9px; color: #526873; font-size: 13px; font-weight: 650; }
.plan-tier-fieldset > p { margin: 8px 0 0; color: #82929a; font-size: 12px; line-height: 1.55; }
.plan-tier-options { display: grid; grid-template-columns: 1fr 1fr; gap: 10px; }
.plan-tier-options label { position: relative; min-width: 0; cursor: pointer; }
.plan-tier-options input { position: absolute; opacity: 0; pointer-events: none; }
.plan-tier-options span { min-height: 62px; display: flex; flex-direction: column; justify-content: center; padding: 10px 16px; border: 1px solid var(--line-strong); border-radius: 9px; background: white; transition: border-color .18s, background .18s, box-shadow .18s; }
.plan-tier-options strong, .plan-tier-options small { display: block; }
.plan-tier-options strong { color: #40545e; font-size: 13px; }
.plan-tier-options small { margin-top: 4px; color: #87979f; font-size: 12px; font-weight: 450; }
.plan-tier-options label:hover span { border-color: #a9cfd3; background: #fbfefe; }
.plan-tier-options input:checked + span { border-color: #70b4bb; background: var(--teal-soft); box-shadow: inset 0 0 0 1px rgba(17,125,137,.08); }
.plan-tier-options input:checked + span strong { color: #0d6872; }
.plan-tier-options input:focus-visible + span { outline: 3px solid rgba(17,125,137,.26); outline-offset: 2px; }
.entitlement-fieldset { min-width: 0; margin: 0; padding: 0; border: 0; }.entitlement-fieldset legend { margin-bottom: 9px; color: #526873; font-size: 13px; font-weight: 650; }
.plan-model-options { display: grid; gap: 8px; max-height: min(336px, 42dvh); overflow-y: auto; padding-right: 4px; }
.plan-model-option { position: relative; grid-template-columns: 20px minmax(0,1fr) auto; align-items: center; gap: 10px; min-height: 64px; padding: 10px 12px; border: 1px solid var(--line); border-radius: 9px; background: white; cursor: pointer; }.plan-model-option:hover { border-color: #bedadd; background: #fbfefe; }.plan-model-option input { position: absolute; opacity: 0; pointer-events: none; }.plan-model-check { width: 18px; height: 18px; display: grid; place-items: center; border: 1px solid #afbec5; border-radius: 5px; background: white; }.plan-model-option input:checked + .plan-model-check { border-color: var(--teal); background: var(--teal); }.plan-model-option input:checked + .plan-model-check::after { content: ""; width: 8px; height: 4px; border-left: 2px solid white; border-bottom: 2px solid white; transform: translateY(-1px) rotate(-45deg); }
.plan-model-copy strong, .plan-model-copy small { display: block; }.plan-model-copy strong { color: #334851; font-size: 13px; }.plan-model-copy small { margin-top: 4px; color: #82939b; font-size: 12px; font-weight: 450; }.permission-status { padding: 4px 7px; border-radius: 99px; background: #f1f4f5; color: #788b94; font-size: 12px; font-style: normal; font-weight: 600; white-space: nowrap; }.permission-status.ready { background: var(--green-soft); color: var(--green); }.plan-model-empty { padding: 18px; border: 1px dashed var(--line-strong); border-radius: 9px; color: #7d8f98; font-size: 12px; line-height: 1.6; text-align: center; }
.toast { position: fixed; z-index: 20; right: 27px; bottom: 27px; max-width: 360px; padding: 13px 16px; border: 1px solid #bcdadd; border-radius: 9px; background: #f2fbfb; color: #225b62; box-shadow: 0 16px 45px rgba(31,51,61,.16); font-size: 13px; opacity: 0; transform: translateY(12px); pointer-events: none; transition: .2s; }.toast.show { opacity: 1; transform: translateY(0); }.toast.error { border-color: #e2b2ae; background: var(--danger-soft); color: var(--danger); }

@media (max-width: 1180px) { .metric-grid.five { grid-template-columns: repeat(3, 1fr); }.model-usage-metrics { grid-template-columns: repeat(2, 1fr); }.model-layout { grid-template-columns: 275px minmax(0,1fr); } }
@media (max-width: 900px) { .login-shell { grid-template-columns: 1fr; }.login-brand-panel { min-height: 42vh; }.login-brand-copy { bottom: 7vh; }.login-brand-copy h1 { font-size: 48px; }.login-form-panel { min-height: 58vh; padding: 70px 8vw; }.app-shell { grid-template-columns: 76px minmax(0,1fr); }.sidebar { padding: 23px 11px; }.sidebar-brand { justify-content: center; padding: 0; }.sidebar-brand > div:last-child, .nav-item span, .sidebar-account div, .sidebar-actions span { display: none; }.nav-item { justify-content: center; padding: 0; }.sidebar-account { justify-content: center; padding: 0; }.sidebar-actions { grid-template-columns: 1fr; }.sidebar-actions a, .sidebar-actions button { padding: 0; }.sidebar-actions i { font-size: 18px; }.chart-grid { grid-template-columns: 1fr; }.model-layout { grid-template-columns: 1fr; }.model-list { grid-template-columns: repeat(2,1fr); } }
@media (max-width: 650px) { .login-return { top: 20px; right: 20px; }.login-brand-panel { padding: 35px 24px; }.login-brand-copy { left: 24px; }.app-shell { display: block; }.sidebar { position: static; width: 100%; height: auto; flex-direction: row; align-items: center; padding: 11px 12px; border-right: 0; border-bottom: 1px solid var(--line); }.sidebar-brand { margin: 0 auto 0 0; }.sidebar nav { display: flex; }.sidebar-foot { display: flex; align-items: center; gap: 3px; margin: 0 0 0 3px; padding: 0; border: 0; }.sidebar-account > span { width: 34px; height: 34px; }.sidebar-actions { display: flex; gap: 2px; }.sidebar-actions a, .sidebar-actions button { width: 34px; min-height: 38px; padding: 0; }.workspace { padding: 0 16px 40px; }.topbar { min-height: 88px; }.metric-grid.five, .model-usage-metrics { grid-template-columns: 1fr 1fr; }.metric-card { min-height: 132px; }.form-grid.two, .model-switches { grid-template-columns: 1fr; }.model-list { grid-template-columns: 1fr; }.section-heading { align-items: flex-start; }.section-heading p { max-width: 235px; line-height: 1.6; }.plan-dialog-card { padding: 22px 18px; }.permission-status { display: none; } }
@media (prefers-reduced-motion: reduce) { *, *::before, *::after { scroll-behavior: auto !important; transition-duration: .01ms !important; animation-duration: .01ms !important; } .cursor-glow { display: none; } }
