/* UI Guide baseline: presentation only. Loaded last to normalize shared UI without changing behavior. */
:root {
  --bg: #f4f6fa;
  --panel: #ffffff;
  --ink: #172033;
  --muted: #5c687a;
  --line: #e4e8f0;
  --nav: #142035;
  --nav2: #1d2d47;
  --primary: #3568e8;
  --primary-soft: #eef3ff;
  --success: #18865d;
  --warning: #b66a06;
  --danger: #c8384a;
  --info: #2774c9;
  --shadow: 0 8px 28px rgba(25, 42, 70, 0.07);
}

html, body { color: var(--ink); background: var(--bg); font-family: Inter, "PingFang SC", "Microsoft YaHei", system-ui, sans-serif; }
.sidebar { background: linear-gradient(180deg, var(--nav), #101a2d 100%); }
.nav-parent:hover, .nav-parent.active, .nav-child:hover, .nav-child.active { background-color: var(--nav2); }
.content-wrap, .content-wrap.overview-page { width: 100%; max-width: none; margin: 0; padding: 22px clamp(16px, 1.4vw, 28px) 44px; }
.page-header { margin-bottom: 20px; }
.page-header h1 { margin: 0 0 6px; color: var(--ink); font-size: 25px; line-height: 1.28; letter-spacing: -0.02em; }
.page-header p, .panel-head p, .ov-section-head p { color: var(--muted); }
.filter-panel, .panel, .ov-card { border: 1px solid var(--line); border-radius: 11px; background: var(--panel); box-shadow: var(--shadow); }
.filter-panel { margin-bottom: 16px; padding: 17px 18px; }
.filter-grid, .filter-actions, .page-actions, .ov-tools { gap: 12px; }
button, input, select, textarea { font: inherit; }
input:not([type="checkbox"]):not([type="radio"]), select, textarea { border: 1px solid #d9dee8; border-radius: 7px; background-color: #fff; color: #263247; outline: none; }
input:not([type="checkbox"]):not([type="radio"]), select:not([multiple]) { min-height: 36px; }
select:not([multiple]) { appearance: none; padding-right: 34px; background-image: linear-gradient(45deg, transparent 50%, #718096 50%), linear-gradient(135deg, #718096 50%, transparent 50%); background-position: calc(100% - 15px) 50%, calc(100% - 10px) 50%; background-size: 5px 5px, 5px 5px; background-repeat: no-repeat; cursor: pointer; }
textarea { min-height: 72px; padding: 10px 12px; resize: vertical; }
input:not([type="checkbox"]):not([type="radio"]):focus, select:focus, textarea:focus { border-color: #6c94ed; box-shadow: 0 0 0 3px rgba(53, 104, 232, 0.1); }
button:focus-visible, a:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible, [tabindex]:focus-visible { outline: 2px solid #6c94ed; outline-offset: 2px; }
.button { min-height: 36px; border-radius: 7px; padding-inline: 14px; }
.button.primary { background: var(--primary); box-shadow: 0 4px 12px rgba(53, 104, 232, 0.16); }
.button:disabled, button:disabled { cursor: not-allowed; opacity: 0.52; }
.panel-head, .ov-section-head { min-height: 68px; padding: 16px 18px; }
.panel-head h2, .ov-section-head h2 { color: var(--ink); font-size: 15px; line-height: 1.35; }
.table-scroll, .ov-table-scroll { width: 100%; overflow-x: auto; scrollbar-gutter: stable; }
th, .ov-table th { height: 42px; background: #fafbfc; color: #6f7a8c; font-size: 11px; font-weight: 650; }
td, .ov-table td { height: 52px; color: #4d596c; }
tbody tr:hover, .ov-table tbody tr:hover { background: #fafcff; }
.metrics article, .runtime-grid article { position: relative; overflow: hidden; border-radius: 11px; }
.metrics article::before, .runtime-grid article::before { position: absolute; inset: 0 0 auto; height: 2px; background: linear-gradient(90deg, rgba(53, 104, 232, 0.72), rgba(53, 104, 232, 0)); content: ""; }
.core-first .core-counts { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.core-first .core-count strong, .core-first .review-money-row strong { overflow-wrap: normal; word-break: keep-all; }
.traffic-chart-axis span { min-width: 0; flex: 1 1 0; overflow: hidden; text-align: center; text-overflow: ellipsis; white-space: nowrap; }
.traffic-bottom > *, .admin-accounts > * { min-width: 0; max-width: 100%; }
.customer-service { grid-template-columns: minmax(0, 1fr); }
.customer-service > * { min-width: 0; }

@media (max-width: 1180px) {
  .core-first .core-counts { grid-template-columns: repeat(2, minmax(0, 1fr)); }
}

@media (max-width: 620px) {
  .content-wrap, .content-wrap.overview-page { padding: 16px 12px 28px; }
  .core-first .core-counts { grid-template-columns: 1fr; }
}

.ui-select { position: relative; display: inline-block; width: 100%; min-width: 0; color: #263247; vertical-align: middle; }
.ui-select-native { position: absolute !important; width: 1px !important; min-width: 1px !important; max-width: 1px !important; height: 1px !important; min-height: 0 !important; margin: -1px !important; padding: 0 !important; overflow: hidden !important; clip: rect(0 0 0 0) !important; border: 0 !important; opacity: 0; pointer-events: none; }
.ui-select-trigger { position: relative; width: 100%; min-height: 36px; padding: 0 34px 0 11px; overflow: hidden; border: 1px solid #d9dee8; border-radius: 7px; background: #fff; color: #263247; font-size: 12px; text-align: left; text-overflow: ellipsis; white-space: nowrap; cursor: pointer; }
.ui-select-trigger::after { position: absolute; top: 50%; right: 13px; width: 7px; height: 7px; border-right: 1.5px solid #718096; border-bottom: 1.5px solid #718096; content: ""; transform: translateY(-65%) rotate(45deg); transition: transform .16s ease; }
.ui-select.is-open .ui-select-trigger { border-color: #6c94ed; box-shadow: 0 0 0 3px rgba(53, 104, 232, .1); }
.ui-select.is-open .ui-select-trigger::after { transform: translateY(-25%) rotate(225deg); }
.ui-select-menu { position: absolute; z-index: 120; top: calc(100% + 6px); left: 0; width: max(100%, max-content); min-width: 100%; max-width: min(360px, 80vw); max-height: 280px; padding: 6px; overflow: auto; border: 1px solid #dfe4ed; border-radius: 10px; background: #fff; box-shadow: 0 16px 36px rgba(25, 42, 70, .16); }
.ui-select-menu[hidden] { display: none; }
.ui-select-option { position: relative; display: block; width: 100%; min-height: 34px; padding: 7px 34px 7px 10px; overflow: hidden; border: 0; border-radius: 7px; background: transparent; color: #3f4c60; font-size: 12px; line-height: 1.45; text-align: left; text-overflow: ellipsis; white-space: nowrap; cursor: pointer; }
.ui-select-option:hover, .ui-select-option:focus-visible { background: #f3f6ff; color: #2858cc; outline: none; }
.ui-select-option.is-selected { background: var(--primary-soft); color: #2858cc; font-weight: 650; }
.ui-select-option.is-selected::after { position: absolute; right: 11px; color: var(--primary); content: "✓"; font-weight: 800; }
.ui-select-option:disabled { color: #a4adba; cursor: not-allowed; }
.ov-tools .ui-select, .admin-page-actions .ui-select, .event-count-period .ui-select { width: auto; min-width: 120px; }

.ui-date { position: relative; display: inline-block; width: 100%; min-width: 0; vertical-align: middle; }
.ui-date-native { position: absolute !important; width: 1px !important; min-width: 1px !important; max-width: 1px !important; height: 1px !important; min-height: 0 !important; margin: -1px !important; padding: 0 !important; overflow: hidden !important; clip: rect(0 0 0 0) !important; border: 0 !important; opacity: 0; pointer-events: none; }
.ui-date-trigger { position: relative; display: flex; align-items: center; justify-content: space-between; width: 100%; min-height: 36px; padding: 0 11px; border: 1px solid #d9dee8; border-radius: 7px; background: #fff; color: #263247; font-size: 12px; text-align: left; cursor: pointer; }
.ui-date-trigger.is-placeholder { color: #8a94a3; }
.ui-date-trigger i { width: 16px; height: 16px; border: 1.5px solid #718096; border-radius: 3px; background: linear-gradient(#718096,#718096) 2px 4px/10px 1px no-repeat; }
.ui-date-trigger i::before { display: block; width: 8px; height: 2px; margin: -3px auto 0; border-inline: 1.5px solid #718096; content: ""; }
.ui-date.is-open .ui-date-trigger { border-color: #6c94ed; box-shadow: 0 0 0 3px rgba(53,104,232,.1); }
.ui-date-panel { position: absolute; z-index: 140; top: calc(100% + 7px); right: 0; width: min(292px, calc(100vw - 24px)); padding: 12px; border: 1px solid #dfe4ed; border-radius: 11px; background: #fff; box-shadow: 0 18px 44px rgba(25,42,70,.2); color: #263247; }
.ui-date-panel[hidden] { display: none; }
.ui-date-head { display: grid; grid-template-columns: 32px 1fr 32px; align-items: center; margin-bottom: 8px; }
.ui-date-head strong { text-align: center; font-size: 13px; }
.ui-date-head button { width: 30px; height: 30px; border: 0; border-radius: 7px; background: transparent; color: #5c687a; cursor: pointer; }
.ui-date-head button:hover { background: #f3f6ff; color: #2858cc; }
.ui-date-week, .ui-date-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 3px; }
.ui-date-week b { padding: 5px 0; color: #8a94a3; font-size: 10px; font-weight: 600; text-align: center; }
.ui-date-day { display: grid; place-items: center; min-width: 0; height: 32px; padding: 0; border: 0; border-radius: 7px; background: transparent; color: #3f4c60; font-size: 11px; cursor: pointer; }
.ui-date-day:hover, .ui-date-day:focus-visible { background: #f3f6ff; color: #2858cc; outline: none; }
.ui-date-day.is-outside { color: #b3bac5; }
.ui-date-day.is-today { box-shadow: inset 0 0 0 1px #9eb8f3; color: #2858cc; }
.ui-date-day.is-selected { background: var(--primary); color: #fff; font-weight: 700; box-shadow: none; }
.ui-date-day:disabled { color: #d1d6de; cursor: not-allowed; }
.ui-date-foot { display: flex; justify-content: space-between; margin-top: 9px; padding-top: 9px; border-top: 1px solid #edf0f5; }
.ui-date-foot button { min-height: 30px; padding: 0 9px; border: 0; border-radius: 7px; background: transparent; color: #3568e8; font-size: 11px; cursor: pointer; }
.ui-date-foot button:hover { background: #eef3ff; }