:root {
  --bg: #f5fbff;
  --panel: #ffffff;
  --blue-50: #eaf6ff;
  --blue-100: #d8efff;
  --blue-200: #bfe4fb;
  --blue-500: #2f8fce;
  --blue-600: #1677b7;
  --navy: #123a59;
  --ink: #16334a;
  --muted: #6d8799;
  --line: #dceaf2;
  --success: #1e8a6a;
  --warning: #a16a1e;
  --shadow: 0 16px 40px rgba(40, 109, 151, 0.08);
  font-family: "Segoe UI", "Microsoft YaHei", sans-serif;
  color: var(--ink);
  background: var(--bg);
}

* { box-sizing: border-box; }
body { margin: 0; min-width: 320px; background: var(--bg); }
button, input, select { font: inherit; }
button { cursor: pointer; }
.app-shell { display: flex; min-height: 100vh; }
.sidebar { width: 246px; flex: 0 0 246px; background: #fff; border-right: 1px solid var(--line); padding: 26px 18px; display: flex; flex-direction: column; }
.brand-lockup { display: flex; align-items: center; gap: 11px; padding: 3px 8px 34px; }
.brand-mark { width: 40px; height: 40px; display: grid; place-items: center; border-radius: 12px; color: #fff; background: linear-gradient(145deg, #5ebcf0, #197ab9); font-weight: 800; letter-spacing: -1px; box-shadow: 0 7px 16px rgba(31, 132, 190, .2); }
.brand-lockup strong { display: block; color: var(--navy); font-size: 15px; }
.brand-lockup span { display: block; color: var(--muted); font-size: 11px; margin-top: 3px; }
.primary-nav { display: grid; gap: 7px; }
.nav-item { border: 0; background: transparent; border-radius: 10px; color: #6b8496; display: flex; align-items: center; gap: 11px; padding: 12px 13px; text-align: left; font-size: 13px; transition: .2s ease; }
.nav-item:hover { background: var(--blue-50); color: var(--blue-600); }
.nav-item.active { background: var(--blue-50); color: var(--blue-600); font-weight: 700; }
.nav-icon { width: 20px; font-size: 19px; line-height: 1; text-align: center; }
.sidebar-note { margin-top: auto; padding: 13px 12px; background: #f5fbff; border: 1px solid #e1f0f8; border-radius: 10px; display: flex; gap: 9px; align-items: flex-start; }
.sidebar-note strong { display: block; font-size: 11px; color: var(--navy); }
.sidebar-note small { display: block; color: var(--muted); font-size: 10px; margin-top: 4px; }
.status-dot { display: inline-block; width: 7px; height: 7px; border-radius: 50%; background: #32b786; margin-top: 4px; box-shadow: 0 0 0 3px #d7f5e9; }
.main-content { flex: 1; min-width: 0; padding: calc(26px + env(safe-area-inset-top)) clamp(20px, 4vw, 62px) calc(22px + env(safe-area-inset-bottom)); }
.topbar { display: flex; align-items: flex-start; justify-content: space-between; max-width: 1140px; margin: 0 auto 28px; }
.eyebrow, .section-kicker { color: var(--blue-600); text-transform: uppercase; letter-spacing: .12em; font-size: 10px; font-weight: 800; margin: 0 0 7px; }
h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: 0; color: var(--navy); font-size: 27px; letter-spacing: -.03em; }
h2 { margin-bottom: 7px; color: var(--navy); font-size: 20px; letter-spacing: -.02em; }
h3 { margin: 0; color: var(--navy); font-size: 16px; }
.topbar-actions { display: flex; align-items: center; gap: 10px; }
.data-chip, .step-badge, .result-label, .match-code, .table-meta { font-size: 11px; color: #4c7188; background: var(--blue-50); border: 1px solid var(--blue-100); border-radius: 99px; padding: 7px 10px; white-space: nowrap; }
.data-chip .status-dot { margin: 0 7px 1px 0; }
.icon-button { width: 34px; height: 34px; border: 1px solid var(--line); border-radius: 9px; background: #fff; color: var(--blue-600); font-size: 19px; }
.icon-button:hover { background: var(--blue-50); }
.view-panel { max-width: 1140px; margin: 0 auto; }
.hidden { display: none !important; }
.intro-row { display: flex; align-items: flex-end; justify-content: space-between; gap: 20px; margin-bottom: 18px; }
.intro-row p { color: var(--muted); font-size: 13px; margin-bottom: 0; }
.formula-note { border: 1px solid var(--blue-100); background: var(--blue-50); color: var(--blue-600); border-radius: 8px; padding: 9px 12px; font-size: 11px; white-space: nowrap; }
.dashboard-grid { display: grid; grid-template-columns: minmax(0, 1.15fr) minmax(320px, .85fr); gap: 16px; }
.card { border: 1px solid var(--line); background: var(--panel); border-radius: 12px; box-shadow: var(--shadow); }
.input-card, .result-card, .parameter-card, .table-card { padding: 23px; }
.card-heading, .table-toolbar { display: flex; align-items: flex-start; justify-content: space-between; gap: 15px; margin-bottom: 21px; }
.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 15px 13px; }
.field { display: grid; gap: 7px; }
.field-wide { grid-column: span 2; }
.field > span { color: #547388; font-size: 11px; font-weight: 700; }
select, input { width: 100%; color: var(--ink); border: 1px solid #cfe1ec; border-radius: 8px; background: #fbfdff; padding: 10px 11px; outline: none; transition: .2s ease; }
select:focus, input:focus { border-color: var(--blue-500); box-shadow: 0 0 0 3px rgba(47, 143, 206, .12); }
.input-with-suffix { position: relative; }
.input-with-suffix input { padding-right: 30px; }
.input-with-suffix span { position: absolute; right: 11px; top: 10px; color: var(--muted); font-size: 12px; }
.field-hint { color: var(--muted); font-size: 10px; margin-top: -2px; }
.selection-summary { border-top: 1px solid var(--line); margin-top: 21px; padding-top: 15px; color: var(--muted); font-size: 11px; line-height: 1.7; }
.selection-summary strong { color: var(--navy); font-weight: 700; }
.result-card { background: linear-gradient(150deg, #fff 0%, #f2faff 100%); border-color: var(--blue-200); }
.result-value { display: flex; align-items: baseline; color: var(--blue-600); padding: 15px 0 2px; }
.result-value span { font-size: 22px; margin-right: 4px; font-weight: 700; }
.result-value strong { font-size: clamp(37px, 5vw, 55px); letter-spacing: -.05em; line-height: 1; }
.result-caption { color: var(--muted); font-size: 12px; margin-bottom: 22px; }
.result-breakdown { display: grid; grid-template-columns: repeat(3, 1fr); border-top: 1px solid var(--blue-100); border-bottom: 1px solid var(--blue-100); padding: 14px 0; gap: 10px; }
.result-breakdown div { min-width: 0; }
.result-breakdown span, .parameter-item span { display: block; color: var(--muted); font-size: 10px; margin-bottom: 6px; }
.result-breakdown strong { display: block; color: var(--navy); font-size: 13px; }
.secondary-result, .brand-reference-row { display: flex; align-items: center; justify-content: space-between; gap: 12px; border-bottom: 1px solid var(--blue-100); padding: 13px 0; color: var(--muted); font-size: 11px; }
.secondary-result strong, .brand-reference-row strong { color: var(--blue-600); font-size: 18px; }
.brand-reference-row { border-bottom: 0; padding-bottom: 0; }
.brand-reference-row strong { color: var(--navy); font-size: 15px; }
.result-actions { display: flex; gap: 8px; margin-top: 20px; }
.button { border: 0; border-radius: 8px; padding: 10px 12px; font-size: 12px; font-weight: 700; display: inline-flex; align-items: center; justify-content: center; gap: 6px; }
.button.primary { background: var(--blue-600); color: #fff; box-shadow: 0 7px 16px rgba(22, 119, 183, .2); }
.button.primary:hover { background: #0f669e; }
.button.secondary { background: #fff; color: var(--blue-600); border: 1px solid var(--blue-200); }
.button.secondary:hover { background: var(--blue-50); }
.assumption-banner { margin-top: 18px; background: rgba(255, 255, 255, .75); border: 1px solid #dbeef8; border-radius: 8px; padding: 10px; color: var(--muted); font-size: 10px; line-height: 1.6; }
.assumption-banner strong { color: var(--warning); margin-right: 5px; }
.parameter-card { margin-top: 16px; }
.parameter-grid { display: grid; grid-template-columns: repeat(4, 1fr); gap: 10px; }
.parameter-item { background: #f8fcff; border: 1px solid #e4f1f7; padding: 13px; border-radius: 9px; }
.parameter-item strong { display: block; color: var(--navy); font-size: 17px; margin-bottom: 7px; }
.parameter-item small { color: var(--muted); font-size: 10px; }
.muted-note { color: var(--muted); font-size: 10px; margin: 15px 0 0; }
.table-card { overflow: hidden; }
.table-toolbar { margin-bottom: 17px; align-items: center; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; min-width: 630px; }
th, td { text-align: left; padding: 13px 12px; border-bottom: 1px solid #eaf1f5; font-size: 12px; }
th { color: var(--muted); background: #f6fbfe; font-size: 10px; font-weight: 800; letter-spacing: .05em; }
td { color: var(--ink); }
td strong { color: var(--navy); }
.price-cell { color: var(--blue-600); font-weight: 800; }
.best-badge { display: inline-block; color: var(--success); background: #e6f7f0; border-radius: 99px; padding: 4px 7px; font-size: 10px; }
.history-list { display: grid; gap: 10px; }
.history-item { display: flex; align-items: center; justify-content: space-between; gap: 16px; border: 1px solid #e5f0f5; border-radius: 9px; background: #fbfdff; padding: 14px; }
.history-item h4 { margin: 0 0 6px; color: var(--navy); font-size: 13px; }
.history-item p { margin: 0; color: var(--muted); font-size: 11px; }
.history-price { color: var(--blue-600); font-size: 18px; font-weight: 800; white-space: nowrap; }
.empty-state { padding: 42px 20px; text-align: center; color: var(--muted); font-size: 12px; }
.app-footer { max-width: 1140px; margin: 25px auto 0; color: #91a7b5; font-size: 10px; }
.toast { position: fixed; z-index: 120; left: 50%; bottom: calc(25px + env(safe-area-inset-bottom)); transform: translate(-50%, 20px); padding: 10px 14px; background: var(--navy); color: #fff; border-radius: 8px; font-size: 12px; opacity: 0; pointer-events: none; transition: .2s ease; box-shadow: var(--shadow); max-width: min(90vw, 430px); text-align: center; }
.toast.show { opacity: 1; transform: translate(-50%, 0); }

@media (max-width: 860px) {
  .sidebar { width: 76px; flex-basis: 76px; padding: 18px 10px; align-items: center; }
  .brand-lockup { padding: 3px 0 28px; }
  .brand-lockup > div:last-child, .nav-item span:last-child, .sidebar-note div { display: none; }
  .brand-mark { width: 38px; height: 38px; }
  .nav-item { width: 48px; height: 44px; padding: 0; justify-content: center; }
  .sidebar-note { padding: 13px; }
  .main-content { padding-left: 26px; padding-right: 26px; }
  .dashboard-grid { grid-template-columns: 1fr; }
}

@media (max-width: 560px) {
  .app-shell { display: block; }
  .sidebar { width: 100%; height: 62px; flex-direction: row; justify-content: space-between; padding: 10px 15px; border-right: 0; border-bottom: 1px solid var(--line); }
  .brand-lockup { padding: 0; }
  .brand-mark { width: 34px; height: 34px; border-radius: 9px; font-size: 13px; }
  .brand-lockup > div:last-child { display: block; }
  .primary-nav { display: flex; gap: 4px; }
  .nav-item { width: 39px; height: 39px; }
  .sidebar-note { display: none; }
  .main-content { padding: 22px 15px; }
  .topbar { margin-bottom: 21px; }
  h1 { font-size: 23px; }
  .data-chip { display: none; }
  .intro-row { display: block; }
  .formula-note { display: inline-block; margin-top: 13px; white-space: normal; }
  .input-card, .result-card, .parameter-card, .table-card { padding: 17px; }
  .parameter-grid { grid-template-columns: 1fr 1fr; }
  .result-actions { flex-direction: column; }
  .history-item { align-items: flex-start; flex-direction: column; gap: 10px; }
}

/* Formal mobile app surface and account area. */
.app-shell { min-height: 100vh; background: #f7fbfe; }
.sidebar { background: rgba(255,255,255,.95); }
.brand-wordmark { color: #12345f; font-size: 21px; font-weight: 850; letter-spacing: -.08em; white-space: nowrap; }
.brand-wordmark span, .launch-logo span { color: #e60012; }
.mobile-brand { display: none; }
.topbar-heading { min-width: 0; }
.page-subtitle { margin: 4px 0 0; color: var(--muted); font-size: 12px; }
.estimate-layout { display: grid; grid-template-columns: minmax(0, 1.1fr) minmax(330px, .9fr); gap: 16px; align-items: stretch; }
.price-card { background: #fff; border: 1px solid #dcebf2; border-radius: 16px; box-shadow: 0 14px 35px rgba(38,84,105,.07); padding: 22px; }
.price-card-top { display: flex; justify-content: space-between; gap: 18px; }
.price-value { display: flex; align-items: baseline; color: #157ddd; margin-top: 3px; }
.price-value span { font-size: 24px; font-weight: 700; margin-right: 4px; }
.price-value strong { font-size: clamp(48px, 6vw, 74px); line-height: .95; letter-spacing: -.08em; font-weight: 780; }
.price-side { min-width: 155px; padding-left: 17px; border-left: 1px solid #e5eef3; display: grid; align-content: center; gap: 11px; }
.price-side div { display: flex; justify-content: space-between; gap: 16px; align-items: center; }
.price-side span { color: var(--muted); font-size: 11px; }
.price-side strong { color: var(--navy); font-size: 14px; }
.price-bar { height: 13px; background: #dbeaf2; border-radius: 99px; overflow: hidden; margin-top: 19px; }
.price-bar-fill { display: block; width: 61%; height: 100%; border-radius: inherit; background: linear-gradient(90deg,#71c5f3,#3c95da); }
.price-legend { display: flex; gap: 25px; color: var(--muted); font-size: 10px; margin-top: 9px; }
.price-legend i { display: inline-block; width: 14px; height: 8px; border-radius: 99px; margin-right: 5px; background: #70c2f1; vertical-align: middle; }
.price-legend .legend-frame { background: #72c7f4; }
.price-legend .legend-plate { background: #4d93d8; }
.price-legend b { color: var(--blue-600); margin-left: 4px; }
.secondary-price { display: flex; align-items: center; gap: 10px; border-top: 1px solid #e8f0f4; padding-top: 14px; margin-top: 16px; color: var(--muted); font-size: 11px; }
.secondary-price strong { color: #157ddd; font-size: 20px; margin-left: auto; }
.secondary-price em { color: var(--blue-600); background: var(--blue-50); border-radius: 99px; padding: 5px 7px; font-style: normal; font-size: 10px; }
.price-actions { display: flex; gap: 9px; margin-top: 16px; }
.price-actions .button { flex: 1; }
.card-heading { margin-bottom: 15px; }
.reset-link { border: 0; background: transparent; color: var(--muted); font-size: 11px; }
.parameter-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 0 15px; }
.parameter-field { display: flex; align-items: center; gap: 8px; min-width: 0; padding: 11px 0; border-bottom: 1px solid #eaf1f4; }
.field-icon { width: 26px; height: 26px; border: 1px solid #c8dfeb; border-radius: 8px; display: grid; place-items: center; color: #4b82a8; font-size: 14px; flex: 0 0 auto; }
.field-copy { display: grid; gap: 2px; min-width: 0; flex: 1; }
.field-copy small { color: var(--muted); font-size: 10px; }
.field-copy select, .field-copy input { border: 0; background: transparent; padding: 0; color: var(--navy); font-size: 13px; font-weight: 700; min-width: 0; outline: 0; }
.parameter-field > b { color: #8098a5; font-size: 22px; font-weight: 400; }
.selection-summary { font-size: 10px; line-height: 1.6; color: var(--muted); margin-top: 13px; }
.matched-card { margin-top: 16px; padding: 18px 21px; }
.matched-grid { display: grid; grid-template-columns: repeat(4,1fr); gap: 10px; }
.matched-grid > div { padding: 11px; border: 1px solid #e3eef2; border-radius: 10px; background: #fbfdfe; }
.matched-grid span { display: block; color: var(--muted); font-size: 9px; margin-bottom: 6px; }
.matched-grid strong { color: var(--navy); font-size: 15px; }
.view-heading { display: flex; justify-content: space-between; gap: 20px; align-items: flex-end; margin-bottom: 17px; }
.view-heading h2 { margin: 0 0 5px; color: var(--navy); }
.view-heading p:not(.section-kicker) { margin: 0; color: var(--muted); font-size: 12px; }
.view-select { border: 1px solid #c5e0ed; border-radius: 9px; background: #fff; padding: 10px 12px; color: var(--blue-600); font-weight: 700; }
.compare-summary, .history-summary { display: grid; grid-template-columns: repeat(3,1fr); gap: 1px; background: #e2edf2; border: 1px solid #e2edf2; border-radius: 14px; overflow: hidden; margin-bottom: 15px; }
.compare-summary > div, .history-summary > div { background: #fff; padding: 16px 14px; text-align: center; }
.compare-summary strong, .history-summary strong { display: block; color: #157ddd; font-size: 24px; letter-spacing: -.04em; }
.compare-summary span, .history-summary span { display: block; color: var(--muted); font-size: 10px; margin-top: 4px; }
.table-card { padding: 20px; }
.table-toolbar { align-items: center; }
.table-toolbar h3 { margin: 0; }
.table-toolbar .section-kicker { margin-bottom: 5px; }
.table-wrap table { min-width: 520px; }
.history-item { border-color: #e0edf2; box-shadow: none; }
.account-status { color: #258d71; background: #e6f7f0; border-radius: 99px; padding: 7px 10px; font-size: 10px; font-weight: 700; }
.account-status i { display: inline-block; width: 6px; height: 6px; background: #2bb889; border-radius: 50%; margin-right: 5px; }
.account-card { display: flex; align-items: center; gap: 14px; padding: 22px; border: 1px solid #e0edf3; border-radius: 16px; background: #fff; box-shadow: var(--shadow); margin-bottom: 16px; }
.account-avatar { width: 70px; height: 70px; display: grid; place-items: center; border-radius: 50%; color: #718eb8; background: #e7eef8; font-size: 31px; font-weight: 700; }
.account-card strong { display: block; color: var(--navy); font-size: 19px; }
.account-card span:not(.account-role) { display: block; color: var(--muted); font-size: 11px; margin-top: 5px; }
.account-role { margin-left: auto; color: var(--blue-600); background: var(--blue-50); border-radius: 99px; padding: 7px 9px; font-size: 10px; }
.settings-card { padding: 0 20px; }
.setting-row { width: 100%; display: flex; align-items: center; gap: 13px; border: 0; border-bottom: 1px solid #e8eff3; background: #fff; padding: 18px 0; text-align: left; }
.setting-row:last-child { border-bottom: 0; }
.setting-icon { width: 32px; height: 32px; display: grid; place-items: center; border: 1px solid #bed8e5; border-radius: 10px; color: var(--blue-600); font-size: 18px; }
.setting-row > span:nth-child(2) { display: grid; gap: 4px; flex: 1; }
.setting-row strong { color: var(--navy); font-size: 15px; }
.setting-row small { color: var(--muted); font-size: 10px; }
.setting-row > b { color: #8498a4; font-size: 23px; font-weight: 400; }
.setting-row.danger strong { color: #de2c36; }
.setting-row.danger .setting-icon { color: #de2c36; border-color: #f0bec2; }
.mobile-bottom-nav { display: none; }
.auth-screen { position: fixed; inset: 0; z-index: 90; display: grid; place-items: center; padding: calc(20px + env(safe-area-inset-top)) calc(20px + env(safe-area-inset-right)) calc(20px + env(safe-area-inset-bottom)) calc(20px + env(safe-area-inset-left)); background: #f7fbfe; overflow: auto; }
.auth-screen.hidden { display: none; }
.app-shell.is-locked, .mobile-bottom-nav.is-locked { pointer-events: none; filter: blur(1px); }
.auth-card { width: min(410px,100%); padding: 34px 28px 25px; border: 1px solid #dcebf2; border-radius: 22px; background: #fff; box-shadow: 0 20px 60px rgba(38,84,105,.12); }
.auth-logo { color: #12345f; text-align: center; font-size: 27px; font-weight: 850; letter-spacing: -.08em; }
.auth-logo span { color: #e60012; }
.auth-card h1 { color: var(--navy); font-size: 24px; text-align: center; margin: 22px 0 5px; }
.auth-card > p { color: var(--muted); font-size: 12px; text-align: center; margin: 0 0 24px; }
.auth-card label { display: grid; gap: 7px; margin-top: 13px; }
.auth-card label span { color: #688493; font-size: 11px; font-weight: 700; }
.auth-card input { width: 100%; border: 1px solid #cfe1ea; border-radius: 10px; padding: 12px; }
.auth-card .button { width: 100%; margin-top: 20px; height: 43px; }
.auth-foot { display: flex; justify-content: space-between; margin-top: 15px; color: var(--muted); font-size: 10px; }
.auth-foot button { border: 0; background: transparent; color: var(--blue-600); font: inherit; }
.settings-modal { position: fixed; inset: 0; z-index: 80; display: grid; place-items: center; padding: calc(20px + env(safe-area-inset-top)) calc(20px + env(safe-area-inset-right)) calc(20px + env(safe-area-inset-bottom)) calc(20px + env(safe-area-inset-left)); background: rgba(19,58,80,.22); backdrop-filter: blur(4px); }
.settings-modal.hidden { display: none; }
.settings-modal-card { position: relative; width: min(430px,100%); max-height: min(680px,90vh); overflow: auto; padding: 24px; border: 1px solid #dcebf2; border-radius: 18px; background: #fff; box-shadow: 0 20px 60px rgba(26,74,96,.18); }
.settings-modal-card h2 { margin: 4px 0 17px; color: var(--navy); }
.settings-close { position: absolute; top: 11px; right: 14px; width: 31px; height: 31px; border: 0; border-radius: 50%; background: #f1f7f9; color: var(--muted); font-size: 23px; line-height: 1; }
.pwa-banner { position: fixed; z-index: 130; left: max(12px, env(safe-area-inset-left)); right: max(12px, env(safe-area-inset-right)); top: calc(12px + env(safe-area-inset-top)); display: flex; align-items: center; gap: 10px; padding: 11px 12px; border: 1px solid var(--blue-100); border-radius: 12px; background: rgba(255,255,255,.98); color: var(--navy); box-shadow: var(--shadow); font-size: 12px; }
.pwa-banner span { flex: 1; line-height: 1.45; }
.pwa-banner button { border: 0; border-radius: 8px; padding: 7px 10px; background: var(--blue-600); color: #fff; font: inherit; font-weight: 700; white-space: nowrap; }
.pwa-banner .pwa-banner-close { padding: 2px 6px; background: transparent; color: var(--muted); font-size: 20px; font-weight: 400; }
.settings-copy { color: var(--muted); font-size: 12px; line-height: 1.7; margin: 0; }
.settings-list { display: grid; gap: 10px; }
.settings-list-row { display: flex; align-items: center; justify-content: space-between; gap: 15px; padding: 13px; border: 1px solid #e0edf2; border-radius: 11px; background: #fbfdfe; color: var(--navy); font-size: 12px; }
.settings-list-row small { color: var(--muted); font-size: 10px; }
.switch-control { width: 39px; height: 22px; border: 0; border-radius: 99px; background: #cddde5; padding: 3px; }
.switch-control i { display: block; width: 16px; height: 16px; border-radius: 50%; background: #fff; transition: transform .2s ease; }
.switch-control.is-on { background: var(--blue-600); }
.switch-control.is-on i { transform: translateX(17px); }
.modal-form { display: grid; gap: 12px; }
.modal-form label { display: grid; gap: 6px; color: #698391; font-size: 11px; font-weight: 700; }
.modal-form input { width: 100%; }
.modal-form .button { height: 40px; margin-top: 4px; }
.launch-logo { color: #12345f; font-size: 42px; font-weight: 850; letter-spacing: -.1em; }
.launch-brand > strong { color: #12345f; font-size: 14px; letter-spacing: .08em; }
.account-company { min-width: 170px; }
.account-company-logo { color: #17375f; font-size: 25px; font-weight: 850; letter-spacing: -.09em; }
.account-company-logo span { color: #e60012; }
.account-company small { display: block; color: var(--muted); font-size: 10px; margin-top: 5px; }
.account-divider { width: 1px; height: 58px; background: #e3edf2; }
.logout-button { width: 100%; border: 1.5px solid #e60012; border-radius: 12px; background: #fff; color: #e60012; font: inherit; font-size: 15px; font-weight: 700; padding: 13px; margin-top: 17px; }
.account-version { text-align: center; color: #97a7b1; font-size: 11px; margin: 25px 0 0; }

@media (max-width: 860px) {
  .estimate-layout { grid-template-columns: 1fr; }
  .matched-grid { grid-template-columns: repeat(2,1fr); }
}
@media (max-width: 560px) {
  body { background: #f7fbfe; }
  .app-shell { display: block; min-height: 100vh; padding-bottom: 70px; }
  .sidebar { display: none; }
  .main-content { padding: calc(12px + env(safe-area-inset-top)) max(15px, env(safe-area-inset-right)) calc(24px + 70px + env(safe-area-inset-bottom)) max(15px, env(safe-area-inset-left)); }
  .topbar { align-items: center; margin-bottom: 20px; }
  .mobile-brand { display: flex; align-items: center; gap: 8px; }
  .mobile-brand .brand-wordmark { font-size: 19px; }
  .mobile-brand strong { color: var(--navy); font-size: 14px; }
  .topbar-heading { display: none; }
  .topbar-actions { margin-left: auto; }
  .topbar-actions .icon-button { display: none; }
  .data-chip { display: inline-flex; font-size: 10px; }
  .estimate-layout { display: block; }
  .price-card { padding: 17px; border-radius: 16px; }
  .price-value strong { font-size: 54px; }
  .price-side { min-width: 128px; padding-left: 12px; gap: 9px; }
  .price-side span { font-size: 9px; }
  .price-side strong { font-size: 12px; }
  .price-actions .button { font-size: 11px; }
  .parameter-card { margin-top: 12px; padding: 15px; }
  .parameter-grid { gap: 0 10px; }
  .parameter-field { padding: 10px 0; }
  .field-copy select, .field-copy input { font-size: 12px; max-width: 94px; }
  .matched-card { display: none; }
  .view-heading { align-items: flex-start; }
  .view-heading h2 { font-size: 23px; }
  .view-heading p:not(.section-kicker) { font-size: 11px; }
  .view-select { max-width: 100px; }
  .compare-summary strong, .history-summary strong { font-size: 21px; }
  .table-card { padding: 15px; }
  .account-card { padding: 18px; }
  .account-company { min-width: 0; flex: 1; }
  .account-company-logo { font-size: 19px; }
  .account-company small { font-size: 8px; }
  .account-divider { height: 48px; }
  .account-avatar { width: 58px; height: 58px; font-size: 26px; }
  .account-card strong { font-size: 17px; }
  .account-card > div:nth-of-type(4) { min-width: 70px; }
  .account-role { display: none; }
  .settings-card { padding: 0 15px; }
  .mobile-bottom-nav { position: fixed; z-index: 40; display: grid; grid-template-columns: repeat(4,1fr); left: 0; right: 0; bottom: 0; height: calc(68px + env(safe-area-inset-bottom)); padding: 7px max(7px, env(safe-area-inset-right)) calc(7px + env(safe-area-inset-bottom)) max(7px, env(safe-area-inset-left)); border-top: 1px solid #e2edf2; background: rgba(255,255,255,.97); box-shadow: 0 -8px 25px rgba(36,89,111,.06); }
  .mobile-bottom-nav .nav-item { width: auto; height: 53px; padding: 4px 0; display: grid; gap: 1px; place-content: center; justify-items: center; color: #7d92a0; font-size: 10px; border-radius: 12px; }
  .mobile-bottom-nav .nav-item.active { color: #167ddd; background: #e9f5ff; }
  .mobile-bottom-nav .nav-icon { width: auto; font-size: 19px; }
  .auth-card { padding: 28px 21px 22px; }
}

/* Refined Yingte visual system: PuHuiTi-first typography, lighter hierarchy, and a calm launch page. */
@font-face {
  font-family: "Alibaba PuHuiTi 3.0";
  src: url("./fonts/Alibaba-PuHuiTi-Regular.ttf") format("truetype");
  font-style: normal;
  font-weight: 400 900;
  font-display: swap;
}
:root {
  --bg: #f7f8fa;
  --panel: #ffffff;
  --blue-50: #f0f7fb;
  --blue-100: #dcecf4;
  --blue-200: #c4dfeb;
  --blue-500: #438eaf;
  --blue-600: #19779d;
  --navy: #173b50;
  --ink: #294a5d;
  --muted: #78909d;
  --line: #e3ebef;
  --shadow: 0 14px 35px rgba(38, 84, 105, .07);
  font-family: "Alibaba PuHuiTi 3.0", "Alibaba PuHuiTi", "阿里巴巴普惠体", "PingFang SC", "Microsoft YaHei", sans-serif;
}

body, button, input, select { font-family: inherit; }
body { background: #f7f8fa; }
.launch-screen { position: fixed; inset: 0; z-index: 100; display: flex; flex-direction: column; justify-content: space-between; padding: 22px 24px 30px; background: #f5f6f8; color: #14191d; transition: opacity .35s ease, visibility .35s ease; }
.launch-screen.is-hidden { opacity: 0; visibility: hidden; pointer-events: none; }
.launch-status { display: flex; justify-content: space-between; font-size: 14px; line-height: 1; font-weight: 600; letter-spacing: .01em; }
.launch-brand { align-self: center; display: flex; flex-direction: column; align-items: center; gap: 8px; transform: translateY(8vh); }
.launch-brand-cn { min-width: 138px; padding: 13px 18px 12px; color: #fff; background: #e60012; border-radius: 2px; text-align: center; font-size: 38px; font-weight: 800; line-height: 1; letter-spacing: .16em; text-indent: .16em; box-shadow: 0 12px 22px rgba(230, 0, 18, .14); }
.launch-brand-en { color: #a3adb3; font-size: 10px; font-weight: 700; letter-spacing: .32em; text-indent: .32em; }
.launch-bottom { display: flex; justify-content: space-between; color: #a0a9ae; font-size: 10px; letter-spacing: .04em; }
.brand-mark { background: #e60012; border-radius: 9px; font-size: 15px; letter-spacing: .06em; box-shadow: 0 7px 16px rgba(230, 0, 18, .16); }
.sidebar { background: rgba(255,255,255,.82); border-right-color: var(--line); }
.brand-lockup strong, h1, h2, h3 { letter-spacing: -.025em; }
h1 { font-size: 25px; font-weight: 750; }
h2 { font-size: 19px; font-weight: 720; }
h3 { font-size: 15px; font-weight: 720; }
.eyebrow, .section-kicker { letter-spacing: .08em; font-size: 10px; }
.main-content { padding-top: 24px; }
.topbar { margin-bottom: 24px; }
.data-chip, .step-badge, .result-label, .match-code, .table-meta { padding: 6px 9px; background: var(--blue-50); border-color: var(--blue-100); }
.card { border-radius: 16px; box-shadow: var(--shadow); }
.input-card, .result-card, .parameter-card, .table-card { padding: 21px; }
.result-card { background: linear-gradient(145deg, #fff 0%, #f1f8fb 100%); }
.result-value strong { font-size: clamp(35px, 4.2vw, 48px); font-weight: 760; }
.result-value { padding-top: 10px; }
.form-grid { gap: 13px 12px; }
.field > span { font-size: 11px; font-weight: 650; }
select, input { border-radius: 10px; background: #fcfdfe; padding: 10px 11px; }
.button { border-radius: 10px; font-weight: 680; }
.button.primary { background: var(--blue-600); box-shadow: 0 7px 16px rgba(25,119,157,.15); }
.parameter-item { border-radius: 11px; background: #fbfdfe; }
.table-card table { border-radius: 10px; }
.history-item { border-radius: 12px; background: #fff; }
.history-actions { display: flex; align-items: center; gap: 10px; }
.history-edit { border: 1px solid #cfe1ec; border-radius: 8px; background: #fff; color: var(--blue-600); padding: 6px 10px; font-size: 11px; cursor: pointer; }
.history-edit:hover { background: #eef8fd; }
.app-footer { margin-top: 22px; }
.admin-body { min-height: 100vh; background: #f5f8fa; }
.admin-shell { width: min(1180px, calc(100% - 32px)); margin: 0 auto; padding: 42px 0 60px; }
.admin-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 18px; margin-bottom: 26px; }
.admin-header h1 { margin: 6px 0; }
.admin-header p:not(.section-kicker) { color: var(--muted); font-size: 13px; }
.admin-login { max-width: 420px; margin: 70px auto; padding: 28px; }
.admin-login h2 { margin: 16px 0 5px; }
.admin-login > p { color: var(--muted); font-size: 12px; margin-bottom: 22px; }
.admin-login label { display: grid; gap: 7px; margin-bottom: 14px; color: var(--ink); font-size: 12px; font-weight: 650; }
.admin-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 18px; margin-bottom: 18px; }
.admin-panel { padding: 21px; }
.admin-panel h2 { margin: 4px 0 0; }
.admin-list { display: grid; gap: 9px; margin-top: 17px; }
.admin-row, .admin-factor { display: flex; align-items: center; justify-content: space-between; gap: 15px; border: 1px solid var(--line); border-radius: 11px; padding: 12px; background: #fbfdfe; color: var(--ink); font-size: 12px; }
.admin-row span { display: grid; gap: 4px; }
.admin-row small { color: var(--muted); font-size: 10px; }
.admin-row b { color: var(--blue-600); font-size: 11px; }
.admin-row-actions { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; justify-content: flex-end; }
.admin-factor input { width: 90px; padding: 7px 9px; }
.admin-panel .table-wrap { overflow: auto; }
.admin-panel table { min-width: 760px; }
.admin-panel th, .admin-panel td { white-space: nowrap; }
@media (max-width: 720px) { .admin-shell { width: min(100% - 24px, 600px); padding-top: 24px; } .admin-header { flex-direction: column; } .admin-grid { grid-template-columns: 1fr; } .admin-panel { padding: 16px; } }

@media (max-width: 560px) {
  .launch-screen { padding: 21px 20px 27px; }
  .launch-brand-cn { min-width: 124px; font-size: 32px; }
  .launch-brand { transform: translateY(7vh); }
  .sidebar { height: 64px; background: rgba(255,255,255,.96); }
  .main-content { padding: 20px 14px 26px; }
  .topbar { margin-bottom: 18px; }
  h1 { font-size: 22px; }
  h2 { font-size: 18px; }
  .intro-row p { font-size: 12px; }
  .input-card, .result-card, .parameter-card, .table-card { padding: 16px; }
  .result-value strong { font-size: 40px; }
  .result-actions { gap: 8px; }
  .history-actions { width: 100%; justify-content: space-between; }
}
