:root {
  --blue: #246bfe;
  --blue-soft: #eaf1ff;
  --ink: #1d2939;
  --muted: #667085;
  --line: #e6eaf0;
  --surface: #ffffff;
  --page: #f5f7fa;
  --teal: #0c8f85;
  --orange: #e87722;
  --red: #df4b4b;
  --shadow: 0 10px 30px rgba(28, 45, 78, .08);
}

* { box-sizing: border-box; }
html, body { margin: 0; min-height: 100%; font-family: "Microsoft YaHei", "PingFang SC", Arial, sans-serif; color: var(--ink); background: var(--page); font-size: 14px; }
button, input, select, textarea { font: inherit; }
button { cursor: pointer; }
.hidden { display: none !important; }
button:focus { outline: none; }
button:focus-visible { outline: 2px solid #8cb1ff; outline-offset: 2px; }

/* Login */
.login-view { position: relative; isolation: isolate; overflow: hidden; min-height: 100vh; display: grid; place-items: center; padding: 24px; background: linear-gradient(rgba(11, 70, 137, .14), rgba(7, 39, 88, .28)), url("assets/login-bg-tech.png") center / cover; }
.login-card { position: relative; z-index: 2; width: min(390px, 100%); padding: 28px 34px 30px; background: rgba(3, 38, 84, .68); box-shadow: 0px 1px 10px 5px rgb(103, 151, 255, 0.42), 0 0 26px rgba(44, 190, 255, .16) inset; backdrop-filter: blur(7px); border-radius: 5px; }
.login-brand-mark { margin: 0 auto 15px; width: 60px; height: 40px; display: grid; place-items: center; color: #d8f8ff; background: rgba(35, 165, 238, .3); border-radius: 5px; font-weight: 800; letter-spacing: 1px; }
.login-card h1 { margin: 0 0 24px; color: #f0fbff; text-align: center; font-size: 23px; font-weight: 600; letter-spacing: 1px; text-shadow: 0 0 12px rgba(143, 235, 255, .25); }
.login-form label { display: block; margin-bottom: 16px; color: #b8d9eb; }
.login-form label > span:first-child { display: block; margin-bottom: 7px; color: #c3e4f3; font-size: 13px; }
.login-form input[type="text"], .login-form input[type="password"] { width: 100%; height: 38px; padding: 0 12px; border: 1px solid rgb(56 58 58 / 64%); border-radius: 2px; outline: none; background: rgba(1, 27, 65, .4); color: #f1fcff; transition: border-color .2s, box-shadow .2s; }
.login-form input:focus { border-color: #9af1ff; box-shadow: 0 0 10px rgba(78, 218, 255, .25); }
.remember-line { display: flex !important; align-items: center; justify-content: space-between; gap: 12px; margin: -1px 0 19px !important; color: #a9d4e7 !important; font-size: 12px; }
.remember-line label { display: flex; align-items: center; gap: 7px; margin: 0; color: inherit; }
.remember-line input { accent-color: #42cfff; }
.primary-button { border: 1px solid rgb(58 58 58 / 72%); color: #f2fcff; background: rgba(10, 143, 209, .88); border-radius: 3px; box-shadow: 0 0 16px rgba(37, 199, 255, .24); transition: background .2s, transform .2s; }
.primary-button:hover { background: rgba(25, 170, 231, .96); }
.primary-button:active { transform: translateY(1px); }
.login-button { width: 100%; height: 42px; font-weight: 600; }
.button-icon { margin-right: 7px; font-size: 17px; vertical-align: -1px; }

/* App shell */
.app-view { min-height: 100vh; display: flex; }
.sidebar { position: fixed; z-index: 10; top: 0; bottom: 0; left: 0; width: 200px; display: flex; flex-direction: column; padding: 24px 14px 16px; background: #172437; color: #bdc8d8; }
.brand { display: flex; gap: 11px; align-items: center; padding: 0 12px 28px; color: #fff; }
.brand-icon { width: 36px; height: 36px; display: grid; place-items: center; background: var(--blue); border-radius: 5px; color: #fff; font-weight: 800; font-size: 19px; }
.brand strong { display: block; font-size: 16px; font-weight: 600; }
.brand small { display: block; margin-top: 4px; color: #8090a6; font-size: 9px; letter-spacing: 1.3px; }
.sidebar-section-label { padding: 0 13px 11px; color: #718198; font-size: 11px; letter-spacing: 1px; }
.main-nav { display: grid; gap: 5px; }
.nav-item { position: relative; min-height: 43px; display: flex; align-items: center; gap: 13px; padding: 0 13px; border: 0; border-radius: 5px; color: #afbbca; background: transparent; font-size: 14px; text-align: left; transition: color .2s, background .2s; }
.nav-item:hover { color: #fff; background: #21334b; }
.nav-item.active { color: #fff; background: var(--blue); box-shadow: 0 7px 16px rgba(36, 107, 254, .2); }
.nav-item.permission-hidden { display: none; }
.nav-icon { width: 22px; height: 22px; flex: 0 0 22px; display: grid; place-items: center; color: currentColor; line-height: 1; text-align: center; }
.nav-icon svg, .ui-icon { width: 21px; height: 21px; display: block; overflow: visible; fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.7; shape-rendering: geometricPrecision; }
.nav-icon svg * { vector-effect: non-scaling-stroke; }
.sidebar-bottom { margin-top: auto; }
.system-tip { display: flex; align-items: center; gap: 9px; margin: 0 5px 17px; padding: 12px; border: 1px solid #2a3b54; border-radius: 7px; background: #1c2d44; }
.tip-icon { width: 18px; height: 18px; display: grid; place-items: center; border: 1px solid #6bb9b0; border-radius: 50%; color: #6bb9b0; font-size: 11px; }
.system-tip strong, .system-tip span { display: block; font-size: 11px; }
.system-tip strong { margin-bottom: 4px; color: #e3eaf3; }
.system-tip span { color: #7f90a5; }
.sidebar-setting { width: 100%; }
.main-area { width: calc(100% - 200px); margin-left: 200px; min-width: 0; }
.topbar { height: 67px; display: flex; align-items: center; justify-content: space-between; padding: 0 31px; border-bottom: 1px solid var(--line); background: var(--surface); }
.topbar-left, .topbar-actions { display: flex; align-items: center; gap: 18px; }
.topbar-left { color: #000; font-weight: 600; }
.page-top-title { display: flex; align-items: center; min-height: 28px; color: #000; font-size: 18px; font-weight: 600; }
.icon-button { position: relative; width: 34px; height: 34px; display: inline-grid; place-items: center; padding: 0; border: 0; color: #6b778b; background: transparent; font-size: 19px; }
.icon-button:hover { color: var(--blue); }
.notice-dot { position: absolute; top: 5px; right: 5px; width: 6px; height: 6px; border: 1px solid #fff; border-radius: 50%; background: var(--red); }
.mobile-menu { display: none; }
.user-menu { position: relative; }
.user-button { display: flex; align-items: center; gap: 8px; border: 0; background: transparent; color: var(--ink); }
.avatar { width: 31px; height: 31px; display: grid; place-items: center; border-radius: 50%; color: #21617b; background: #d8f0ed; font-weight: 600; }
.user-name { font-size: 13px; }
.chevron { color: #98a2b3; font-size: 17px; }
.user-dropdown { position: absolute; z-index: 20; top: 40px; right: 0; width: 90px; padding: 5px; border: 1px solid var(--line); border-radius: 7px; background: #fff; box-shadow: var(--shadow); }
.user-dropdown button { width: 100%; padding: 5px 10px; border: 0; border-radius: 4px; background: transparent; color: #000; text-align: left; }
.user-dropdown button:hover { color: var(--blue); background: var(--blue-soft); }
.content { padding: 29px 31px 42px; }
.page-heading { display: flex; align-items: flex-end; justify-content: space-between; margin-bottom: 24px; }
.page-heading h1 { margin: 0; color: #000; font-size: 22px; font-weight: 600; }
.page-heading p { margin: 8px 0 0; color: #000; font-size: 12px; }
.heading-actions { display: flex; align-items: center; gap: 9px; }
.filter-spacer { flex: 1; min-width: 18px; }
.filter-actions { display: flex; align-items: center; gap: 9px; }
.summary-line { display: flex; align-items: center; gap: 22px; color: #000; font-size: 14px; white-space: nowrap; }
.summary-line strong { color: #26364a; font-size: 16px; font-weight: 600; }
.log-filter-bar .summary-line strong { color: var(--blue); }
.expense-summary { margin-left: 20px; gap: 30px; }
.expense-summary strong.income { color: #e24c4c; }
.expense-summary strong.expense { color: var(--teal); }
.expense-summary strong.net { color: #26364a; }
.log-filter-bar .filter-actions { margin-left: 12px; }
.business-heading { display: block; }
.business-heading .heading-actions { justify-content: flex-end; margin-top: 16px; }
.outline-button, .toolbar-button { height: 36px; padding: 0 13px; border: 1px solid #d8dee8; border-radius: 4px; color: #000; background: #fff; white-space: nowrap; transition: border-color .2s, color .2s, background .2s; }
.outline-button:hover, .toolbar-button:hover { border-color: var(--blue); color: var(--blue); background: #f7faff; }
.solid-button { height: 36px; padding: 0 15px; border: 0; border-radius: 4px; color: #fff; background: var(--blue); white-space: nowrap; }
.solid-button:hover { background: #1356dc; }
.button-symbol { width: 18px; height: 18px; display: inline-flex; align-items: center; justify-content: center; margin-right: 6px; font-size: 17px; line-height: 1; vertical-align: middle; }
.button-symbol svg { width: 17px; height: 17px; display: block; fill: none; stroke: currentColor; stroke-width: 1.7; stroke-linecap: round; stroke-linejoin: round; shape-rendering: geometricPrecision; }

/* Dashboard */
.welcome-strip { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; padding: 20px 23px; border: 1px solid #dfe9f5; border-radius: 8px; background: #edf5ff; }
.welcome-strip h2 { margin: 0; color: #243b5a; font-size: 17px; font-weight: 600; }
.welcome-strip p { margin: 7px 0 0; color: #7086a2; font-size: 12px; }
.date-badge { color: #5d7695; font-size: 12px; }
.metrics { display: grid; grid-template-columns: repeat(4, 1fr); gap: 14px; margin-bottom: 20px; }
.metric-card { display: flex; align-items: center; gap: 14px; padding: 18px 20px; border: 1px solid var(--line); border-radius: 7px; background: #fff; }
.metric-icon { width: 38px; height: 38px; display: grid; place-items: center; border-radius: 8px; color: var(--blue); background: #eaf1ff; font-size: 19px; }
.metric-card:nth-child(2) .metric-icon { color: var(--teal); background: #e5f6f3; }
.metric-card:nth-child(3) .metric-icon { color: var(--orange); background: #fff0e5; }
.metric-card:nth-child(4) .metric-icon { color: #8064c8; background: #f0ebff; }
.metric-label { color: #8b98a9; font-size: 12px; }
.metric-value { margin-top: 5px; color: #1d2939; font-size: 21px; font-weight: 650; }
.dashboard-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 20px; }
.panel { min-width: 0; border: 1px solid var(--line); border-radius: 8px; background: #fff; }
.settings-panel { overflow: hidden; }
.logs-table { min-width: 780px; }
.settings-table { min-width: 900px; }
.account-type { display: inline-flex; align-items: center; padding: 4px 8px; border-radius: 4px; font-size: 12px; }.account-type.admin { color: #176b56; background: #e8f7f2; }.account-type.operator { color: #536174; background: #f0f3f7; }.permission-all { color: #176b56; font-size: 12px; font-weight: 600; }.permission-muted { color: #98a2b3; font-size: 12px; }
.settings-table th:first-child, .settings-table td:first-child { padding-left: 20px; }
.panel-header { display: flex; align-items: center; justify-content: space-between; min-height: 58px; padding: 0 20px; border-bottom: 1px solid var(--line); }
.panel-title { margin: 0; color: #000; font-size: 15px; font-weight: 600; }
.panel-header .muted-link { color: var(--blue); border: 0; background: transparent; font-size: 12px; }
.panel-body { padding: 0 20px; }
.data-row { display: grid; grid-template-columns: 1.25fr .8fr .8fr .7fr; align-items: center; min-height: 56px; padding: 16px 0; border-bottom: 1px solid #eff2f5; }
.data-row:last-child { border-bottom: 0; }
.dashboard-grid .panel.has-bottom-space:first-child .data-row:last-child { border-bottom: 1px solid #eff2f5; }
.data-row .main { color: #667085; font-size: 13px; font-weight: 600; }
.data-row small { display: block; margin-top: 4px; color: #98a2b3; font-size: 11px; font-weight: 400; }
.data-row span { color: #667085; font-size: 12px; }
.data-row > span { font-size: 13px; }
.data-row .deal-date { color: #667085; text-align: right; }
.amount { color: var(--blue) !important; font-weight: 600; }
.due-row { display: grid; grid-template-columns: 1.25fr 1.0fr .8fr; align-items: center; min-height: 56px; padding: 16px 0; border-bottom: 1px solid #eff2f5; }
.due-row:last-child { border-bottom: 0; }
.dashboard-grid .panel.has-bottom-space:last-child .due-row:last-child { border-bottom: 1px solid #eff2f5; }
.due-title { color: #667085; font-weight: 600; font-size: 13px; }
.due-meta { margin-top: 5px; color: #98a2b3; font-size: 11px; }
.due-status { display: flex; width: 68px; margin: 0 auto; align-items: center; justify-content: flex-start; color: var(--red); font-size: 13px; text-align: left; white-space: nowrap; }
.due-date { display: flex; min-width: 0; align-items: center; justify-content: flex-end; color: var(--red); font-size: 13px; text-align: right; white-space: nowrap; }
.due-status.urgent, .due-date.urgent { color: var(--red); }
.empty-state { padding: 54px 20px; color: #98a2b3; text-align: center; }

/* Business pages */
.filter-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 9px; margin-bottom: 13px; padding: 12px; border: 1px solid var(--line); border-radius: 7px; background: #fff; }
.business-filter-bar .filter-actions, .expense-filter-bar .filter-actions { margin-left: 0; }
.search-box { position: relative; min-width: 220px; flex: 1; max-width: 300px; }
.search-box input, .filter-select { width: 100%; height: 34px; padding: 0 11px; border: 1px solid #dfe4eb; border-radius: 4px; outline: none; color: var(--ink); background: #fff; }
.search-box input { padding-left: 32px; }
.search-box:before { display: none; }
.filter-select { width: 125px; color: #000; }
.period-input { width: 145px; height: 34px; padding: 0 10px; border: 1px solid #dfe4eb; border-radius: 4px; outline: none; color: #000; background: #fff; }.period-input:focus { border-color: var(--blue); }.period-year { width: 88px; }.period-separator { color: #000; font-size: 12px; }
.filter-divider { width: 1px; height: 20px; margin: 0 2px; background: var(--line); }
.table-panel { overflow: hidden; border: 1px solid var(--line); border-radius: 7px; background: #fff; }
.table-scroll { overflow-x: auto; }
.data-table { width: 100%; min-width: 920px; border-collapse: collapse; }
.data-table th { height: 44px; padding: 0 15px; border-bottom: 1px solid var(--line); color: #000; background: #fbfcfd; font-size: 12px; font-weight: 600; text-align: left; white-space: nowrap; }
.data-table td { height: 58px; padding: 0 15px; border-bottom: 1px solid #eef1f4; color: #59677a; font-size: 13px; white-space: nowrap; }
.data-table tbody tr:hover { background: #fbfdff; }
.data-table tbody tr:last-child td { border-bottom: 0; }
.checkbox { width: 15px; height: 15px; accent-color: var(--blue); }
.data-table a { color: var(--blue); text-decoration: none; font-weight: 600; }
.data-table a:hover { text-decoration: underline; }
.order-expiry { display: inline-flex; flex-direction: column; gap: 4px; line-height: 1.2; }
.order-expiry-meta { display: flex; align-items: center; gap: 4px; color: #667085; font-size: 12px; }
.expiry-days { color: var(--red); }
.expiry-days.expired { font-weight: 600; }
.expiry-label { color: #667085; }
.renew-link { margin-left: 2px; color: var(--blue) !important; font-weight: 600; }
.order-renewed { color: var(--teal); font-size: 12px; font-weight: 600; }
.password-mask { color: #98a2b3; letter-spacing: 2px; }
.status { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; }
.status:before { content: ""; width: 6px; height: 6px; border-radius: 50%; background: #c5ccd6; }
.status.success { color: var(--teal); }.status.success:before { background: var(--teal); }
.status.warning { color: #c9822b; }.status.warning:before { background: #e4a34d; }
.status.danger { color: var(--red); }.status.danger:before { background: var(--red); }
.status.neutral { color: #758195; }
.money-in { color: #e24c4c !important; font-weight: 600; }.money-out { color: var(--teal) !important; font-weight: 600; }
.row-actions { display: flex; gap: 12px; }
.text-button { padding: 0; border: 0; color: var(--blue); background: transparent; font-size: 12px; }.text-button.danger { color: var(--red); }
.table-footer { display: flex; justify-content: space-between; align-items: center; padding: 14px 16px; border-top: 1px solid var(--line); color: #000; font-size: 12px; }
.pagination { display: flex; gap: 5px; }
.page-button { width: 28px; height: 28px; border: 1px solid #dce2eb; border-radius: 4px; color: #000; background: #fff; font-size: 12px; }.page-button.active { color: #fff; border-color: var(--blue); background: var(--blue); }.page-button:disabled { cursor: default; opacity: .45; }
.tab-bar { display: flex; gap: 25px; align-items: center; margin-bottom: 13px; padding: 0 4px; border-bottom: 1px solid var(--line); }
.tab-button { position: relative; padding: 12px 4px; border: 0; color: #000; background: transparent; }.tab-button.active { color: var(--blue); }.tab-button.active:after { content: ""; position: absolute; right: 0; bottom: -1px; left: 0; height: 2px; background: var(--blue); }
.product-name { display: flex; align-items: center; gap: 9px; }.product-dot { width: 26px; height: 26px; display: grid; place-items: center; border-radius: 5px; color: var(--blue); background: #eaf1ff; font-size: 13px; }
.product-dot.green { color: var(--teal); background: #e5f6f3; }.product-dot.orange { color: var(--orange); background: #fff0e5; }
.expense-filter-bar .search-box { min-width: 215px; max-width: 220px; }
.expense-filter-bar .filter-select { width: 110px; }
@media (min-width: 1300px) { .expense-filter-bar { flex-wrap: nowrap; } }
.search-box input { padding-left: 11px; }.search-box input::placeholder, .form-field input::placeholder { color: #b8c1cd; opacity: 1; }.metric-icon svg { width: 20px; height: 20px; fill: none; stroke: currentColor; stroke-linecap: round; stroke-linejoin: round; stroke-width: 1.8; }

/* Modal and misc */
.modal-backdrop { position: fixed; z-index: 50; inset: 0; display: grid; place-items: center; padding: 20px; background: rgba(18, 32, 51, .48); }
.modal { width: min(560px, 100%); max-height: calc(100vh - 40px); overflow: auto; border-radius: 9px; background: #fff; box-shadow: 0 20px 60px rgba(15, 32, 55, .24); }
.modal-wide { width: min(860px, 100%); }
.modal-permissions { width: min(860px, 100%); }
.detail-modal { width: min(760px, calc(100vw - 40px)); max-height: none; overflow: hidden; }
.modal-header { display: flex; justify-content: space-between; align-items: center; padding: 18px 30px; border-bottom: 1px solid var(--line); }.modal-header h3 { margin: 0; font-size: 17px; font-weight: 600; }.close-button { border: 0; color: #000; background: transparent; font-size: 23px; }.close-button:hover { color: var(--red); }
.modal-body { padding: 30px; }.form-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 16px; }.form-field.full { grid-column: 1 / -1; }.form-field label { display: block; margin-bottom: 7px; color: #000; font-size: 13px; }.form-field input, .form-field select, .form-field textarea { width: 100%; height: 36px; padding: 0 10px; border: 1px solid #dfe4eb; border-radius: 4px; outline: none; color: #59677a; font-size: 13px; }.form-field textarea { height: 120px; padding-top: 9px; resize: vertical; }.form-field input:focus, .form-field select:focus, .form-field textarea:focus { border-color: var(--blue); }.modal-footer { display: flex; justify-content: center; gap: 10px; padding: 15px 22px; border-top: 1px solid var(--line); }.cancel-button { height: 36px; padding: 0 15px; border: 1px solid #d8dee8; border-radius: 4px; color: #000; background: #fff; }
.order-form .form-grid { grid-template-columns: repeat(3, minmax(0, 1fr)); }
.order-remark { grid-column: span 2; }
.order-contract { grid-column: span 1; }
.contract-control { display: block; }
#orderContractFile { display: none; }
.contract-actions { display: flex; width: 100%; gap: 8px; }
.contract-button { flex: 1 1 0; min-width: 0; height: 36px; color: #fff !important; border-color: transparent; }
.contract-view, .contract-view:hover { color: #fff; background: #246bfe; }
.contract-upload, .contract-upload:hover { color: #fff; background: #246bfe; }
.contract-delete, .contract-delete:hover { color: #fff; background: #fe2424; }
.contract-download, .contract-download:hover { color: #fff; background: #246bfe; }
.contract-button:disabled { cursor: default; opacity: .45; }
.contract-attachment-label { display: block; margin-top: 24px; color: #000; font-size: 13px; }
.contract-file-name { width: 100%; height: 36px; padding: 0 10px; overflow: hidden; border: 1px solid #dfe4eb; border-radius: 4px; color: #59677a; background: #fff; font-size: 13px; line-height: 34px; text-overflow: ellipsis; white-space: nowrap; }
.readonly-field { display: flex; align-items: center; height: 36px; padding: 0 10px; border: 1px solid #e2e7ee; border-radius: 4px; color: #59677a; font-size: 13px; background: #f7f9fb; }
.permission-modal-header { position: relative; }.permission-title-row { flex: 1; display: flex; align-items: end; }.permission-title-row h3 { font-size: 17px; }.permission-account { position: absolute; left: 50%; color: #246bfe; font-weight: bold; white-space: nowrap; transform: translateX(-50%); }.permission-log-row > label:nth-child(3) { grid-column: 3; }
.modal-caption { margin: 5px 0 0; color: #000; font-size: 12px; }.permission-select-all { display: flex; align-items: center; justify-content: space-between; min-height: 42px; padding: 0 14px; border-bottom: 1px solid var(--line); color: #000; font-size: 12px; }.permission-select-all label { color: #000; font-weight: 600; }.permission-select-all input, .permission-row input { width: 15px; height: 15px; margin: 0 6px 0 0; vertical-align: -3px; accent-color: var(--blue); }.permission-matrix { overflow-x: auto; border: 1px solid var(--line); border-radius: 5px; }.permission-row { display: grid; grid-template-columns: minmax(220px, 1.7fr) repeat(5, minmax(78px, 1fr)); align-items: center; min-height: 45px; border-top: 1px solid #eef1f4; color: #000; font-size: 12px; }.permission-row:first-child { border-top: 0; }.permission-row > * { padding: 0 12px; }.permission-row.permission-header { min-height: 38px; color: #000; background: #eff5fb; font-weight: 600; }.permission-row label { display: flex; align-items: center; }.permission-row .permission-module { color: #000; font-weight: 600; }
.combo-field { position: relative; }.suggestion-list { position: absolute; z-index: 70; top: calc(100% + 4px); right: 0; left: 0; display: none; max-height: 190px; overflow-y: auto; border: 1px solid #dfe4eb; border-radius: 4px; background: #fff; box-shadow: 0 8px 20px rgba(20, 35, 60, .12); }.suggestion-list.open { display: block; }.suggestion-item { width: 100%; padding: 10px 12px; border: 0; border-bottom: 1px solid #eef1f4; color: #000; background: #fff; text-align: left; }.suggestion-item:hover { color: var(--blue); background: var(--blue-soft); }.suggestion-empty { padding: 11px 12px; color: #000; font-size: 12px; }
.detail-body { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 0 30px; padding: 14px 30px 30px; }.detail-row { display: grid; grid-template-columns: 88px minmax(0, 1fr); align-items: center; min-height: 42px; padding: 7px 0; border-bottom: 1px solid #eff2f5; color: #59677a; font-size: 12px; }.detail-row:last-child { border-bottom: 1px solid #eff2f5; }.detail-row > span { color: #000; font-size: 13px; }.detail-row strong { color: #59677a; font-size: 13px; font-weight: 500; overflow-wrap: anywhere; word-break: break-word; }.detail-row.detail-wide { grid-column: 1 / -1; }
.toast-root { position: fixed; z-index: 100; top: 10px; left: 50%; display: grid; gap: 10px; max-width: calc(100vw - 32px); transform: translateX(-50%); }.toast { min-width: 240px; max-width: min(520px, calc(100vw - 32px)); padding: 12px 15px; border: 1px solid #d6e9e7; border-left: 3px solid var(--teal); border-radius: 6px; color: #315a57; background: #f1fbf9; box-shadow: var(--shadow); text-align: center; }.toast.error { border-color: #f0d6d6; border-left-color: var(--red); color: #8d3838; background: #fff5f5; }
.notice-panel { padding: 16px 20px; border: 1px solid #f0d6d6; border-radius: 7px; color: #8d3838; background: #fff7f7; }
@media (max-width: 760px) { .permission-modal-header { display: grid; grid-template-columns: minmax(0, 1fr) auto; align-items: start; gap: 8px; padding: 18px 20px; }.permission-title-row { min-width: 0; display: flex; flex-direction: column; align-items: flex-start; gap: 8px; }.permission-account { position: static; align-self: flex-start; transform: none; font-size: 13px; line-height: 1.4; } }

@media (max-width: 760px) { .detail-modal { width: min(560px, calc(100vw - 32px)); max-height: calc(100vh - 40px); overflow: auto; }.detail-body { grid-template-columns: 1fr; gap: 0; }.detail-row.detail-wide { grid-column: auto; }.order-remark, .order-contract { grid-column: auto; } }

@media (max-width: 1100px) { .metrics { grid-template-columns: repeat(2, 1fr); } .dashboard-grid { grid-template-columns: 1fr; } }
@media (max-width: 760px) { .sidebar { transform: translateX(-100%); transition: transform .25s; box-shadow: 8px 0 24px rgba(0,0,0,.14); }.sidebar.open { transform: translateX(0); }.main-area { width: 100%; margin-left: 0; }.topbar { padding: 0 16px; }.mobile-menu { display: inline-grid; }.content { padding: 22px 16px 32px; }.page-heading { align-items: flex-start; flex-direction: column; gap: 14px; }.business-heading .heading-actions { width: 100%; }.expense-heading .heading-actions { align-items: center; }.expense-heading-actions .summary-line { position: static; transform: none; }.metrics { gap: 10px; }.metric-card { padding: 14px; }.metric-value { font-size: 18px; }.welcome-strip { align-items: flex-start; flex-direction: column; gap: 10px; }.data-row { grid-template-columns: 1.2fr .6fr .6fr; }.data-row > span:nth-last-child(1) { display: none; }.form-grid { grid-template-columns: 1fr; }.form-field.full { grid-column: auto; }.user-name { display: none; }.permission-title-row { align-items: flex-start; flex-direction: column; gap: 4px; } }
@media (max-width: 760px) { .expense-filter-bar { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); align-items: stretch; gap: 5px; padding: 10px; }.expense-filter-bar .search-box { grid-column: 1 / -1; min-width: 0; width: auto; max-width: none; }.expense-filter-bar > .filter-select, .expense-filter-bar > .period-select { width: 100%; min-width: 0; }.expense-filter-bar > .period-input { grid-column: 1 / -1; width: 100%; min-width: 0; }.expense-filter-bar > .period-separator { grid-column: 1 / -1; justify-self: center; align-self: center; text-align: center; }.expense-filter-bar > .filter-divider { display: none; }.expense-filter-bar > .toolbar-button { grid-column: 1 / -1; width: 100%; }.expense-filter-bar > .expense-summary { grid-column: 1 / -1; display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); align-items: center; width: 100%; margin-left: 0; padding: 10px 0; border-top: 0; gap: 4px; }.expense-summary span { display: flex; min-width: 0; flex-direction: column; align-items: center; gap: 3px; font-size: 12px; white-space: nowrap; }.expense-summary strong { font-size: 14px !important; }.expense-filter-bar > .filter-spacer { display: none; }.expense-filter-bar > .filter-actions { grid-column: 1 / -1; width: 100%; }.expense-filter-bar > .filter-actions button { flex: 1; min-width: 0; } }
@media (max-width: 760px) { .log-filter-bar > .summary-line { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); align-items: center; width: 100%; margin: 0; padding: 5px; box-sizing: border-box; gap: 4px; }.log-filter-bar > .summary-line span { display: flex; min-width: 0; flex-direction: column; align-items: center; gap: 3px; font-size: 12px; white-space: nowrap; }.log-filter-bar > .summary-line strong { font-size: 14px !important; } }
@media (max-width: 440px) { .metrics { grid-template-columns: 1fr; }.filter-bar { align-items: stretch; flex-direction: column; }.search-box, .filter-select { max-width: none; width: 100%; }.filter-divider, .filter-spacer { display: none; }.filter-actions { width: 100%; }.log-filter-bar .filter-actions { margin-left: 0; }.filter-actions button { flex: 1; }.expense-filter-bar .summary-line, .log-filter-bar .summary-line { width: 100%; justify-content: space-between; gap: 8px; white-space: normal; }.expense-filter-bar .summary-line strong, .log-filter-bar .summary-line strong { font-size: 14px; }.page-top-title { font-size: 18px; }.heading-actions { width: 100%; }.heading-actions button { flex: 1; }.order-form .form-grid { grid-template-columns: 1fr; }.login-card { padding: 28px 24px; } }
@media (max-width: 760px) { .permission-title-row { gap: 10px; } }
@media (max-width: 760px) { .due-row { grid-template-columns: 1.25fr 0.5fr .8fr; gap: 6px; padding: 14px 0; }.due-status { width: 64px; }.due-status, .due-date { font-size: 12px; } }
