/* Domain workspace — selected design direction, 2026-10-03. */
:root {
    font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC", "Microsoft YaHei", sans-serif;
    font-size: 14px; line-height: 1.6; color: #17243c; background: #fff;
    --blue: #235bd6; --blue-hover: #1948b0; --text: #17243c; --muted: #697991;
    --border: #e4e9f1; --soft: #f7f9fc; --selected: #eaf1ff; --danger: #b42332;
    --text-small: 12px; --text-body: 14px; --text-section: 16px; --text-dialog: 20px; --text-page: 30px;
    --sidebar-width: 224px; --projects-width: 272px;
}
* { box-sizing: border-box; }
body { margin: 0; min-height: 100vh; display: flex; }
[hidden] { display: none!important; }
a { color: var(--blue); text-decoration: none; }
a:hover { text-decoration: underline; }
button, input, select, textarea { font: inherit; }
button, a, input, select, textarea, summary { outline-offset: 3px; }
:focus-visible { outline: 3px solid #8fb4ff; }
button { cursor: pointer; }
button:disabled { opacity: .45; cursor: not-allowed; }
h1, h2, h3, p { margin-top: 0; }
h1 { margin-bottom: 10px; font-size: 30px; line-height: 1.3; letter-spacing: -.025em; font-weight: 700; overflow-wrap: anywhere; }
h2 { font-size: 16px; line-height: 1.5; font-weight: 600; margin-bottom: 16px; }
h3 { font-size: 14px; font-weight: 600; }
strong, b { font-weight: 600; }
small, .hint, .muted { font-size: 12px; line-height: 1.6; color: var(--muted); font-weight: 400; }
small { display: block; margin-top: 4px; overflow-wrap: anywhere; }
code { font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace; font-size: 13px; overflow-wrap: anywhere; }
.ui-icon { width: 20px; height: 20px; flex: none; vertical-align: middle; opacity: .8; }
.sr-only, .skip-link:not(:focus) { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip-path: inset(50%); white-space: nowrap; border: 0; }
.skip-link:focus { position: fixed; left: 16px; top: 12px; background: #fff; padding: 10px 16px; z-index: 100; }
/* Main application navigation. */
.app-sidebar { width: var(--sidebar-width); flex: none; background: #202b3b; color: #edf2fa; height: 100dvh; position: sticky; top: 0; display: flex; flex-direction: column; padding: 30px 12px 20px; }
.brand { display: flex; align-items: center; gap: 12px; padding: 0 12px; font-size: 20px; font-weight: 600; white-space: nowrap; }
.brand-icon { display: grid; place-items: center; width: 42px; height: 42px; border-radius: 10px; background: #245cd6; color: #fff; font-size: 22px; font-weight: 600; flex: none; }
.sidebar-caption { margin: 6px 0 50px 67px; color: #a6b1c3; font-size: 12px; }
.app-sidebar nav { display: grid; gap: 8px; }
.app-sidebar nav a { display: flex; align-items: center; gap: 16px; color: #c9d3e2; padding: 14px 16px; border-radius: 6px; font-size: 15px; font-weight: 500; }
.app-sidebar .ui-icon { filter: brightness(0) invert(1); opacity: .85; width: 22px; height: 22px; }
.app-sidebar nav a:hover { background: #2a374b; text-decoration: none; color: #fff; }
.app-sidebar nav a.active { background: #2b477e; color: #fff; font-weight: 600; }
.app-sidebar form { margin-top: auto; }
.app-sidebar .link { display: flex; align-items: center; gap: 16px; background: none; border: 0; color: #b8c4d6; padding: 12px 16px; font-size: 13px; }
.app-main { min-width: 0; flex: 1; padding: 38px 40px 56px; }
.eyebrow { font-size: 13px; font-weight: 400; color: var(--muted); margin: 0 0 25px; overflow-wrap: anywhere; }
.eyebrow span { color: #a9b3c2; margin: 0 8px; }
.page-heading h1 { margin-bottom: 12px; }
.page-intro { display: flex; align-items: center; justify-content: space-between; gap: 24px; margin-bottom: 32px; }
.page-intro p { color: var(--muted); margin: 0; max-width: 720px; }
.actions { display: flex; align-items: center; gap: 10px; flex-wrap: wrap; }
/* Shared controls. */
button:not(.text-button):not(.icon-button):not(.copy-button):not(.link):not(.project-picker), .button {
    display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 42px; padding: 9px 17px;
    border: 1px solid var(--blue); border-radius: 6px; background: var(--blue); color: #fff; font-size: 14px; font-weight: 600; line-height: 1.5; text-decoration: none;
}
button:not(.text-button):not(.icon-button):not(.copy-button):not(.link):not(.project-picker):hover, .button:hover { background: var(--blue-hover); border-color: var(--blue-hover); }
button:not(.secondary):not(.text-button):not(.icon-button):not(.copy-button):not(.link):not(.project-picker)>.ui-icon { filter: brightness(0) invert(1); opacity: 1; }
button.secondary, .button.secondary { background: #fff!important; border-color: #d5deec!important; color: #263b5c!important; font-weight: 500!important; }
button.secondary:hover, .button.secondary:hover { background: var(--soft)!important; border-color: #b3c4de!important; }
.text-button, .reset-link { background: none; border: 0; color: var(--blue); padding: 7px 9px; border-radius: 5px; font-size: 14px; font-weight: 500; line-height: 1.5; white-space: nowrap; }
.text-button { display: inline-flex; align-items: center; justify-content: center; gap: 8px; min-height: 36px; }
.text-button:hover { background: #edf3ff; text-decoration: none; }
.danger, .text-button.danger { color: var(--danger); }
.text-button.danger:hover { background: #fff0ee; }
button.danger-button { background: var(--danger)!important; border-color: var(--danger)!important; }
.icon-button, .copy-button { display: inline-flex; align-items: center; justify-content: center; background: transparent; color: #586a85; border: 1px solid transparent; border-radius: 6px; padding: 7px; min-width: 34px; min-height: 34px; line-height: 1; }
.icon-button { font-size: 22px; }
.icon-button:hover, .copy-button:hover { background: #eef3fb; color: var(--blue); }
.copy-button { font-size: 12px; flex: none; white-space: nowrap; }
.copy-button .ui-icon { width: 16px; height: 16px; opacity: .55; }
label { display: block; font-size: 12px; font-weight: 500; color: #52647f; margin-bottom: 18px; }
input, select, textarea { width: 100%; min-width: 0; margin-top: 7px; background: #fff; color: var(--text); border: 1px solid #ced8e7; border-radius: 6px; padding: 10px 12px; min-height: 42px; font-size: 14px; font-weight: 400; line-height: 1.5; }
input:focus, select:focus, textarea:focus { border-color: #6892e5; }
input::placeholder, textarea::placeholder { color: #8895a9; opacity: 1; }
input[type=checkbox] { width: 17px; height: 17px; min-height: 0; margin: 0; padding: 0; accent-color: var(--blue); cursor: pointer; flex: none; }
input[type=date] { font-variant-numeric: tabular-nums; }
textarea { resize: vertical; }
input:disabled, select:disabled { background: #f3f5f8; color: #8793a4; }
.check-label { display: flex; align-items: center; gap: 9px; font-size: 14px; font-weight: 400; color: var(--text); }
.required { color: var(--danger); }
.form-grid { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 18px; }
.search-control { display: flex; align-items: center; min-width: 0; border: 1px solid #ced8e7; border-radius: 6px; background: #fff; padding-left: 12px; }
.search-control>.ui-icon { width: 18px; height: 18px; opacity: .45; }
.search-control input { border: 0; margin: 0; background: none; padding: 9px 10px; min-height: 42px; }
.search-control:focus-within { outline: 2px solid #9cbcff; outline-offset: 2px; }
.search-control input:focus { outline: 0; }
.search-control>.icon-button { margin-right: 3px; padding: 5px; min-width: 28px; }
/* Persistent project navigator and focused domain workspace. */
.page-projects .app-main { display: grid; grid-template-columns: var(--projects-width) minmax(0,1fr); padding: 0; align-items: start; }
.project-navigator { position: sticky; top: 0; height: 100dvh; padding: 34px 20px 24px; background: #f5f7fb; border-right: 1px solid var(--border); display: flex; flex-direction: column; overflow-y: auto; }
.project-navigator, .project-nav-list { scrollbar-width: thin; scrollbar-color: #c4cddd transparent; }
.project-navigator:hover, .project-nav-list:hover { scrollbar-color: #a6b4c9 transparent; }
.project-navigator::-webkit-scrollbar, .project-nav-list::-webkit-scrollbar { width: 6px; height: 6px; }
.project-navigator::-webkit-scrollbar-track, .project-nav-list::-webkit-scrollbar-track { background: transparent; }
.project-navigator::-webkit-scrollbar-thumb, .project-nav-list::-webkit-scrollbar-thumb { background: #c4cddd; border-radius: 999px; }
.project-navigator::-webkit-scrollbar-thumb:hover, .project-nav-list::-webkit-scrollbar-thumb:hover { background: #a6b4c9; }
.project-navigator::-webkit-scrollbar-button, .project-nav-list::-webkit-scrollbar-button { display: none; width: 0; height: 0; }
.project-nav-heading { display: flex; align-items: center; justify-content: space-between; margin-bottom: 20px; }
.project-nav-heading h2 { font-size: 20px; margin: 0; }
.project-nav-heading .icon-button { border-color: #d3ddea; background: transparent; }
.project-nav-meta { display: flex; justify-content: space-between; color: #7c889c; font-size: 11px; margin: 18px 8px 10px; }
.project-nav-list { display: grid; gap: 6px; }
.project-nav-item { display: flex; align-items: center; justify-content: space-between; gap: 14px; padding: 14px 12px; border-radius: 6px; color: #1c2e4c; border-left: 3px solid transparent; min-height: 52px; }
.project-nav-item>span:first-child { font-size: 15px; font-weight: 600; min-width: 0; overflow-wrap: anywhere; }
.project-nav-item:hover { background: #eaf0f9; text-decoration: none; }
.project-nav-item.is-selected { color: #2057cc; background: #e5edfc; border-left-color: #93b5fd; }
.project-count { font-size: 15px; font-weight: 600; color: #16804a; font-variant-numeric: tabular-nums; flex: none; }
.project-count.is-empty { color: #d32f3d; }
.project-count.is-low { color: #a67c00; }
.project-nav-footer { margin: auto 8px 0; padding-top: 32px; color: #7c889c; font-size: 11px; }
.project-picker { display: none; }
.project-workspace { min-width: 0; padding: 36px 32px 48px; }
.workspace-heading { display: flex; justify-content: space-between; align-items: center; gap: 20px; margin-bottom: 20px; }
.workspace-heading>div:first-child { min-width: 0; }
.workspace-heading h1 { font-size: 40px; letter-spacing: -.03em; margin: 0 0 10px; }
.workspace-heading p { color: var(--muted); margin: 0; }
.workspace-heading .actions { flex: none; }
.workspace-context { display: flex; flex-wrap: wrap; align-items: center; gap: 10px 16px; color: var(--muted); font-size: 13px; margin-bottom: 40px; min-height: 32px; }
.workspace-context>span:first-child { display: flex; align-items: center; gap: 8px; }
.project-server-ip { display: inline-flex; align-items: center; gap: 5px; min-width: 0; }
.project-server-ip code { padding: 3px 8px; border: 1px solid var(--border); border-radius: 4px; background: #fafbfe; color: #253957; min-width: 0; }
.context-link { color: var(--muted); font-size: 12px; }
.domain-state-tabs { display: flex; gap: 26px; border-bottom: 1px solid var(--border); margin-bottom: 22px; }
.domain-state-tabs a { display: inline-flex; gap: 8px; padding: 10px 0 13px; color: #6b7b93; border-bottom: 3px solid transparent; margin-bottom: -1px; white-space: nowrap; font-weight: 500; }
.domain-state-tabs a.active { border-color: var(--blue); color: var(--blue); font-weight: 600; }
.domain-state-tabs a:hover { text-decoration: none; color: var(--blue); }
.domain-state-tabs strong { font-size: 13px; font-weight: 500; }
.domain-list-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 24px; flex-wrap: wrap; border-bottom: 1px solid var(--border); margin-bottom: 22px; }
.domain-list-toolbar .domain-state-tabs { border-bottom: 0; margin-bottom: 0; }
.domain-list-toolbar .selection-bar { margin-left: auto; padding: 0; background: transparent; border: 0; gap: 10px; }
.domain-list-toolbar .selection-hint { display: none; }
.domain-list-toolbar .selection-bar .actions { margin-left: 0; }
.domain-create-actions { margin-left: auto; flex: none; padding-bottom: 10px; }
.domain-create-actions button { white-space: nowrap; }
.project-workspace > .selection-bar { margin-bottom: 16px; border: 1px solid var(--border); border-radius: 8px; }
.workspace-toolbar { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; margin-bottom: 20px; }
.workspace-toolbar .search-control { width: min(420px,60%); }
.result-count { margin-left: auto; font-size: 12px; color: var(--muted); white-space: nowrap; }
.date-filters { position: relative; font-size: 12px; color: var(--muted); }
.date-filters summary { cursor: pointer; padding: 8px 0; }
.date-filter-fields { display: flex; align-items: flex-end; gap: 12px; position: absolute; z-index: 5; padding: 18px; background: #fff; box-shadow: 0 8px 30px #22365415; border: 1px solid var(--border); right: 0; width: 440px; border-radius: 8px; }
.date-filter-fields label { margin: 0; min-width: 0; }
.workspace-empty { padding: 18vh 24px; text-align: center; }
.empty-icon { display: inline-flex; padding: 16px; margin-bottom: 18px; border-radius: 12px; background: var(--selected); }
.empty-icon img { width: 32px; height: 32px; }
.workspace-empty p { color: var(--muted); margin-bottom: 24px; }
/* Data surfaces and row actions. */
.card { background: #fff; padding: 24px; border: 1px solid var(--border); border-radius: 8px; margin-bottom: 24px; }
.card p { line-height: 1.7; color: var(--muted); }
.list-card { padding: 0; }
.list-meta { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; padding: 18px 20px; border-bottom: 1px solid var(--border); }
.list-meta strong { font-size: 16px; }
.list-meta span { color: var(--muted); font-size: 12px; }
.table-wrap { width: 100%; overflow-x: auto; }
table { width: 100%; border-collapse: collapse; text-align: left; }
th { background: #f7f9fd; color: #75839a; font-size: 12px; font-weight: 500; padding: 14px 16px; border-bottom: 1px solid var(--border); white-space: nowrap; }
td { vertical-align: middle; font-size: 14px; padding: 17px 16px; border-bottom: 1px solid #edf0f5; }
tbody tr:last-child>td { border-bottom: 0; }
tbody tr:hover { background: #fbfcfe; }
.domain-table { table-layout: fixed; }
.domain-table .selection-cell { width: 42px; padding-right: 0; }
.domain-table th.operations { width: 158px; text-align: right; }
.domain-table th.status-column { width: 106px; }
.domain-table th.added-date-column { width: 120px; }
.domain-table.has-usage-time { min-width: 720px; }
.domain-table th.usage-time-column { width: 156px; }
.usage-time-cell { color: var(--muted); font-size: 14px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.domain-name { display: flex; align-items: center; gap: 6px; min-width: 0; }
.domain-name strong { font-size: 15px; font-weight: 600; overflow-wrap: anywhere; min-width: 0; }
.domain-name .copy-button { padding: 5px; min-width: 26px; min-height: 28px; opacity: .35; }
.domain-name:hover .copy-button, .domain-name:focus-within .copy-button { opacity: 1; }
.date-cell { font-size: 14px; font-variant-numeric: tabular-nums; color: var(--muted); }
.badge { display: inline-flex; align-items: center; gap: 6px; padding: 4px 8px; border-radius: 5px; font-size: 12px; font-weight: 500; line-height: 1.5; color: #26724e; background: #edf8f1; max-width: 100%; overflow-wrap: anywhere; }
.badge::before { content: ""; width: 5px; height: 5px; border-radius: 50%; background: currentColor; flex: none; }
.badge.available, .badge.info { background: #edf3ff; color: #245ac0; }
.badge.red { color: #aa3540; background: #fff1ef; }
.badge.ended, .badge.neutral { background: #f0f3f7; color: #64738a; }
.row-actions { display: flex; align-items: center; justify-content: flex-end; gap: 8px; }
.row-actions form { margin: 0; }
.usage-action { background: #f6f9ff; border: 1px solid #e1e9f8; font-size: 12px; font-weight: 600; padding: 7px 10px; white-space: nowrap; }
.more-button { width: 30px; min-width: 30px; }
.action-menu { position: fixed; inset: auto; margin: 0; padding: 6px; width: 188px; max-width: calc(100vw - 16px); background: #fff; border: 1px solid #dce3ee; border-radius: 8px; box-shadow: 0 8px 26px #17243c1c; color: var(--text); }
.action-menu:popover-open { display: grid; gap: 2px; }
.action-menu .text-button { display: flex; justify-content: flex-start; width: 100%; padding: 9px 12px; font-size: 13px; color: #304766; }
.action-menu .danger { color: var(--danger); }
.action-menu .ui-icon { width: 17px; height: 17px; }
.selection-bar { display: flex; align-items: center; gap: 14px; flex-wrap: wrap; padding: 12px 16px; border-bottom: 1px solid var(--border); background: #edf4ff; font-size: 12px; }
.selection-bar:has([data-selection-submit]:disabled) { display: none; }
.selection-bar .actions { margin-left: auto; }
.selection-hint { color: var(--muted); }
.selection-bar button { font-size: 12px!important; min-height: 32px!important; padding: 5px 10px!important; }
.pagination { display: flex; align-items: center; justify-content: space-between; gap: 16px; flex-wrap: wrap; color: var(--muted); font-size: 12px; padding: 22px 16px; border-top: 1px solid var(--border); }
.pagination>div { display: flex; gap: 10px; margin-left: auto; }
.pagination .button { font-size: 12px; min-height: 34px; padding: 6px 12px; }
.project-domain-empty, .empty { text-align: center; padding: 56px 20px; color: var(--muted); }
.project-domain-empty { border: 1px dashed #dce4ef; border-radius: 8px; display: flex; align-items: center; justify-content: center; flex-wrap: wrap; gap: 16px; }
.empty strong { font-size: 16px; color: var(--text); }
.empty p { margin: 10px 0 18px; }
.recovery-note { padding: 14px 18px; background: #f5f8fd; font-size: 13px; color: var(--muted); border-bottom: 1px solid var(--border); }
/* Dialogs and confirmation workflows. */
dialog { border: 1px solid #dfe5ef; border-radius: 12px; background: #fff; color: var(--text); padding: 28px; width: min(540px,calc(100vw - 32px)); max-height: calc(100dvh - 48px); overflow: auto; box-shadow: 0 24px 80px #12213838; }
dialog::backdrop { background: #12213866; backdrop-filter: blur(2px); }
.dialog-head { display: flex; align-items: flex-start; justify-content: space-between; gap: 16px; margin-bottom: 24px; }
.dialog-head h2 { margin: 0; font-size: 20px; line-height: 1.4; font-weight: 600; }
.dialog-head p { color: var(--muted); font-size: 12px; margin: 6px 0 0; overflow-wrap: anywhere; }
.dialog-head .icon-button { flex: none; margin: -4px -4px 0 0; }
.dialog-actions { display: flex; align-items: center; justify-content: flex-end; gap: 10px; margin-top: 26px; padding-top: 18px; border-top: 1px solid var(--border); flex-wrap: wrap; }
dialog .dialog-actions { position: sticky; bottom: -28px; background: #fff; padding-bottom: 12px; z-index: 2; }
.usage-mode { background: #f5f8fd; border: 1px solid var(--border); border-radius: 8px; padding: 18px; margin: 20px 0; }
.usage-mode p { margin: 8px 0 14px; color: var(--muted); }
.usage-future { padding: 18px; border: 1px dashed #d9e0eb; border-radius: 8px; }
.usage-future-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; }
.usage-future-head span { font-size: 12px; color: var(--muted); }
.usage-future p { color: var(--muted); font-size: 12px; margin-top: 8px; }
.usage-future label { margin: 14px 0 0; }
.notice, .error { padding: 14px 18px; border-radius: 7px; margin-bottom: 22px; line-height: 1.7; overflow-wrap: anywhere; font-size: 13px; }
.notice { background: #edf7f1; border: 1px solid #d6ebdf; color: #276b4b; }
.error { color: #ab2f3b; background: #fff3f1; border: 1px solid #f3d9d4; }
.page-projects .app-main>.notice, .page-projects .app-main>.error { grid-column: 1/-1; margin: 0; border-radius: 0; }
.toast { position: fixed; bottom: 28px; left: 50%; transform: translateX(-50%); padding: 12px 20px; background: #22334e; color: #fff; border-radius: 8px; box-shadow: 0 4px 20px #14213625; max-width: calc(100vw - 32px); overflow-wrap: anywhere; z-index: 100; }
/* Server and audit pages use the same quiet surfaces. */
.server-filters, .filters { display: flex; align-items: flex-end; gap: 16px; padding: 20px; border-bottom: 1px solid var(--border); }
.server-filters label { flex: 1; max-width: 560px; margin: 0; }
.server-intro { margin-bottom: 20px; color: var(--muted); }
.server-toolbar { display: flex; align-items: center; justify-content: space-between; gap: 20px; flex-wrap: wrap; margin-bottom: 24px; }
.server-toolbar .server-filters { padding: 0; border: 0; align-items: center; gap: 10px; flex-wrap: wrap; min-width: 0; }
.server-toolbar .server-filters input { width: 320px; max-width: 100%; margin: 0; }
.server-toolbar>button { flex: none; }
.server-table { table-layout: fixed; }
.server-renewal { display: flex; align-items: center; flex-wrap: wrap; gap: 6px; }
.badge.renewal-soon { color: #8a6400; background: #fff5cc; }
.renewal-notice { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 14px; padding: 10px 14px; margin-bottom: 16px; border: 1px solid #eedb9b; border-radius: 8px; background: #fffbeb; color: #795d15; }
.renewal-heading { display: flex; align-items: center; flex-wrap: wrap; gap: 8px; }
.renewal-heading strong { white-space: nowrap; }
.renewal-server { display: inline-flex; align-items: center; gap: 6px; font-size: 12px; }
.renewal-server>span { white-space: nowrap; }
.renewal-today { color: var(--danger); }
.server-table th:first-child { width: 24%; }
.server-table th:nth-child(2) { width: 25%; }
.server-table th:last-child { width: 140px; }
.server-table td[data-label="操作"] { white-space: nowrap; }
.delete-resource-button { color: var(--danger); }
.server-ip { display: flex; align-items: center; gap: 8px; min-width: 0; }
.server-ip code { font-weight: 600; min-width: 0; }
.server-linked-projects { display: flex; flex-wrap: wrap; gap: 6px; }
.server-linked-projects a, .project-tag { font-size: 12px; background: #f0f4fc; border-radius: 4px; padding: 4px 8px; overflow-wrap: anywhere; }
.server-project-fieldset { border: 1px solid var(--border); border-radius: 7px; padding: 14px; margin-top: 20px; }
.server-project-fieldset legend { color: var(--muted); font-size: 12px; padding: 0 6px; }
.server-project-options { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); max-height: 200px; overflow: auto; gap: 12px; }
.server-project-options .check-label { margin: 0; }
.filters-dated { display: grid; grid-template-columns: minmax(180px,1.6fr) repeat(2,minmax(120px,1fr)) repeat(2,140px) auto auto; align-items: end; gap: 14px; }
.filters-dated label { margin: 0; }
.filters-dated .reset-link { justify-self: start; align-self: center; }
.activity-table { table-layout: fixed; }
.activity-table th:nth-child(1) { width: 158px; }
.activity-table th:nth-child(2) { width: 22%; }
.activity-table th:nth-child(3) { width: 184px; }
.activity-table td { padding: 20px 16px; }
.activity-object, .activity-detail { overflow-wrap: anywhere; }
.activity-object>a { font-weight: 600; }
.activity-detail strong { font-size: 12px; }
.change-values { display: flex; align-items: baseline; flex-wrap: wrap; gap: 5px; margin-top: 5px; }
.old-value { color: var(--muted); background: #f1f3f7; border-radius: 4px; padding: 2px 6px; }
.new-value { color: #276e4f; background: #edf8f1; border-radius: 4px; padding: 2px 6px; }
/* Cloudflare settings and the domain-scoped configuration dialog. */
.settings-layout { display: grid; grid-template-columns: minmax(0,1.25fr) minmax(0,1fr); align-items: start; gap: 28px; max-width: 1120px; }
.narrow { max-width: 720px; }
.cf-permissions { background: var(--soft); border: 0; }
.cf-permissions ul { padding-left: 20px; color: var(--muted); }
.cf-permissions li { margin-bottom: 8px; }
.cf-connection .dialog-actions { justify-content: flex-start; }
.cf-connection>form+form { margin-top: 16px; }
.cf-domain-dialog { width: min(1020px,calc(100vw - 40px)); }
.cf-domain-dialog .dialog-head { position: sticky; top: -28px; background: #fff; z-index: 5; padding: 12px 0 18px; margin-bottom: 10px; border-bottom: 1px solid var(--border); }
.cf-domain-heading { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin: 20px 0; }
.cf-domain-heading h2 { margin: 0; }
.cf-domain-heading>a { margin-left: auto; }
.cf-tabs { display: flex; gap: 20px; margin-bottom: 24px; border-bottom: 1px solid var(--border); }
.cf-tabs .text-button { border-radius: 0; padding: 12px 0; color: var(--muted); border-bottom: 2px solid transparent; }
.cf-tabs [aria-selected=true] { color: var(--blue); border-bottom-color: var(--blue); }
.cf-tabs [data-cf-tab=remove] { color: var(--danger); margin-left: auto; }
.cf-tabs [data-cf-tab=remove][aria-selected=true] { border-color: var(--danger); }
.cf-dns-table { table-layout: fixed; }
.cf-dns-table th:first-child { width: 65px; }
.cf-dns-table th:nth-last-child(1) { width: 100px; }
.cf-dns-table th:nth-last-child(2) { width: 70px; }
.cf-dns-table th:nth-last-child(3) { width: 88px; }
.cf-dns-table strong, .cf-dns-table code { overflow-wrap: anywhere; }
.cf-domain-dialog .card { margin-bottom: 20px; }
.cf-dns-row { display: grid; grid-template-columns: minmax(0,1.4fr) minmax(0,1.1fr) minmax(130px,.9fr) auto; gap: 12px; align-items: end; padding: 16px 0; border-bottom: 1px solid var(--border); }
.cf-dns-row label { margin: 0; }
.cf-dns-row>button { margin-bottom: 3px; }
.cf-form-footer { display: flex; align-items: center; flex-wrap: wrap; gap: 12px; margin-top: 22px; }
.cf-form-footer>button:last-child { margin-left: auto; }
.cf-inline-form { display: flex; align-items: end; gap: 12px; margin: 20px 0; }
.cf-inline-form label { flex: 1; margin: 0; }
.cf-rules { margin: 28px 0; padding-top: 20px; border-top: 1px solid var(--border); }
.cf-rule { display: flex; align-items: center; justify-content: space-between; gap: 18px; padding: 16px 0; border-bottom: 1px solid var(--border); }
.cf-rule>div { min-width: 0; overflow-wrap: anywhere; }
.cf-rule form { flex: none; }
.cf-danger { border-color: #f0d5d7; background: #fffdfd; }
.cf-danger h2 { color: var(--danger); }
.cf-danger form { max-width: 520px; }
.cf-results table { table-layout: fixed; }
.cf-results td { overflow-wrap: anywhere; }
.cf-results td small { color: var(--danger); }
.cf-domain-dialog[aria-busy=true] [data-cf-dialog-content] { opacity: .65; }
/* Bulk preview and access screens. */
.bulk-modal-table { max-height: 45vh; overflow: auto; border: 1px solid var(--border); border-radius: 6px; }
.bulk-modal-table table { table-layout: fixed; }
.bulk-modal-table th:first-child { width: 65%; }
.bulk-modal-table td, .preview-table td { overflow-wrap: anywhere; }
.bulk-modal-table th { position: sticky; top: 0; }
.preview-toolbar, .preview-switch { display: flex; align-items: center; gap: 12px; flex-wrap: wrap; margin-bottom: 16px; }
.preview-switch [aria-pressed=true] { background: #eaf1ff!important; color: var(--blue)!important; border-color: #a9c3f9!important; }
.workflow-steps { list-style: none; display: flex; flex-wrap: wrap; gap: 24px; padding: 0; color: var(--muted); font-size: 12px; margin: 26px 0; }
.workflow-steps [aria-current=step] { color: var(--blue); font-weight: 600; }
.auth { width: min(440px,calc(100% - 40px)); margin: auto; padding: 60px 0; }
body:has(.auth) { background: #f3f6fb; }
.auth header { margin-bottom: 26px; }
.auth h1 { font-size: 26px; }
.auth .card { padding: 28px; box-shadow: 0 8px 32px #263b5b08; }
.auth .card p { margin-bottom: 24px; }
.auth form>button { width: 100%; }
/* Responsive layout: preserve the project context and every operation. */
@media(min-width:901px) and (max-width:1200px) {
    :root { --sidebar-width: 184px; --projects-width: 218px; }
    .brand { font-size: 15px; padding: 0 6px; gap: 9px; }
    .brand-icon { width: 34px; height: 36px; font-size: 18px; }
    .sidebar-caption { margin-left: 50px; }
    .app-sidebar nav a { gap: 12px; padding: 12px; }
    .project-navigator { padding-left: 14px; padding-right: 14px; }
    .project-workspace { padding-left: 24px; padding-right: 24px; }
    .workspace-heading { align-items: flex-start; flex-direction: column; }
    .workspace-heading h1 { font-size: 30px; }
    .domain-table th.operations { width: 140px; }
    .domain-table th.status-column { width: 88px; }
    .domain-table th.added-date-column { width: 100px; }
    .domain-table th, .domain-table td { padding-left: 10px; padding-right: 10px; }
    .filters-dated { grid-template-columns: repeat(3,minmax(0,1fr)); }
}
@media(max-width:900px) {
    body { display: block; }
    .app-sidebar { position: relative; width: 100%; height: auto; padding: 16px; display: grid; grid-template-columns: 1fr auto; gap: 16px; }
    .brand { font-size: 16px; padding: 0; gap: 10px; }
    .brand-icon { width: 32px; height: 32px; font-size: 18px; border-radius: 7px; }
    .sidebar-caption { display: none; }
    .app-sidebar nav { grid-column: 1/-1; grid-row: 2; display: flex; gap: 6px; }
    .app-sidebar nav a { justify-content: center; gap: 8px; padding: 9px 12px; flex: 1; font-size: 13px; }
    .app-sidebar nav .ui-icon { width: 18px; height: 18px; }
    .app-sidebar form { grid-column: 2; grid-row: 1; margin: 0; }
    .app-sidebar .link { font-size: 12px; gap: 6px; padding: 6px; }
    .app-sidebar .link .ui-icon { width: 17px; height: 17px; }
    .app-main { padding: 28px 22px 40px; }
    .page-projects .app-main { display: block; }
    .project-navigator { position: relative; height: auto; padding: 16px 22px; overflow: visible; }
    .project-nav-heading, .project-nav-meta, .project-nav-footer { display: none; }
    .project-search { display: none; }
    .project-picker { display: flex; width: 100%; justify-content: space-between; align-items: center; border: 0; background: none; color: var(--text); font-size: 14px; font-weight: 600; text-align: left; padding: 0; gap: 16px; }
    .project-picker span { font-size: 12px; font-weight: 400; color: var(--blue); flex: none; }
    .project-nav-list { display: none; }
    .project-navigator.is-open .project-nav-list { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); margin-top: 16px; max-height: 320px; overflow: auto; }
    .project-navigator.is-open .project-search { display: block; margin: 16px 0; }
    .project-navigator.is-open .project-nav-heading { display: flex; margin-bottom: 14px; }
    .project-workspace { padding: 26px 22px 40px; }
    .workspace-heading h1 { font-size: 28px; }
    .workspace-heading { flex-wrap: wrap; }
    .workspace-context { margin-bottom: 28px; }
    .eyebrow { margin-bottom: 18px; }
    .workspace-toolbar .search-control { width: min(420px,65%); }
    .settings-layout { grid-template-columns: minmax(0,1fr); gap: 0; }
    .server-table, .activity-table, .cf-dns-table { display: block; }
    .server-table thead, .activity-table thead, .cf-dns-table thead { display: none; }
    .server-table tbody, .activity-table tbody, .cf-dns-table tbody { display: block; padding: 0 16px; }
    .server-table tr, .cf-dns-table tr { display: grid; grid-template-columns: minmax(0,1fr); gap: 12px; padding: 20px 0; border-bottom: 1px solid var(--border); }
    .server-table td, .cf-dns-table td { display: flex; align-items: baseline; gap: 12px; min-width: 0; padding: 0; border: 0; }
    .server-table td[data-label]::before, .cf-dns-table td[data-label]::before { content: attr(data-label); font-size: 12px; color: var(--muted); min-width: 80px; flex: none; }
    .server-table td[data-label="服务器 IP"]::before, .server-table td[data-label="操作"]::before, .cf-dns-table td[data-label="操作"]::before { display: none; }
    .server-table td:last-child, .cf-dns-table td:last-child { justify-content: flex-end; }
    .server-table td.empty, .cf-dns-table td.empty { display: block; padding: 20px; text-align: center; }
    .server-table .server-ip { width: 100%; justify-content: space-between; }
    .server-table tbody tr:last-child, .cf-dns-table tbody tr:last-child { border-bottom: 0; }
    .activity-table tr { display: grid; grid-template-columns: minmax(0,1fr) auto; gap: 8px 12px; padding: 20px 0; border-bottom: 1px solid var(--border); }
    .activity-table td { display: block; padding: 0; border: 0; min-width: 0; }
    .activity-table .activity-object { grid-column: 1; grid-row: 1; }
    .activity-table .date-cell { grid-column: 1; grid-row: 2; font-size: 12px; }
    .activity-table .date-cell small { display: inline; margin-left: 8px; }
    .activity-table .activity-action { grid-column: 2; grid-row: 1/3; max-width: 150px; }
    .activity-table .activity-detail { grid-column: 1/-1; grid-row: 3; margin-top: 6px; }
    .activity-table td.empty { grid-column: 1/-1; padding: 20px; }
    .filters-dated { grid-template-columns: repeat(2,minmax(0,1fr)); }
    .filters-dated .search-field { grid-column: 1/-1; }
    .cf-dns-row { grid-template-columns: repeat(2,minmax(0,1fr)); }
    .cf-dns-row>button { justify-self: end; }
    .cf-rule { align-items: flex-start; flex-direction: column; gap: 8px; }
}
@media(max-width:760px) {
    .app-sidebar { padding: 14px 12px 10px; gap: 12px; }
    .app-sidebar nav { gap: 3px; }
    .app-sidebar nav a { font-size: 12px; padding: 9px 6px; gap: 5px; }
    .app-sidebar nav .ui-icon { display: none; }
    .app-main, .project-workspace { padding: 24px 16px 36px; }
    .project-navigator { padding: 16px; }
    .workspace-heading { align-items: flex-start; gap: 18px; }
    .workspace-heading .actions { width: 100%; }
    .workspace-heading .actions>* { flex: 1; }
    .project-workspace>.eyebrow { display: none; }
    .workspace-heading { margin-bottom: 16px; gap: 14px; }
    .workspace-heading h1 { font-size: 26px; margin-bottom: 0; }
    .workspace-heading p { display: none; }
    .workspace-context { margin-bottom: 20px; }
    .workspace-context { font-size: 12px; gap: 8px; }
    .domain-state-tabs { gap: 20px; overflow-x: auto; margin-bottom: 18px; }
    .domain-state-tabs a { font-size: 13px; gap: 5px; }
    .workspace-toolbar { gap: 10px; }
    .workspace-toolbar .search-control { width: 100%; }
    .result-count { margin-left: auto; }
    .date-filter-fields { position: static; width: 100%; flex-direction: column; align-items: stretch; box-shadow: none; margin-top: 8px; }
    .date-filters[open] { flex-basis: 100%; }
    .domain-table, .domain-table tbody { display: block; }
    .domain-table thead { display: block; }
    .domain-table thead tr { display: flex; padding: 10px 14px; background: var(--soft); border-bottom: 1px solid var(--border); }
    .domain-table th { display: none; }
    .domain-table th.selection-cell { display: flex; width: auto; align-items: center; gap: 8px; padding: 0; border: 0; }
    .domain-table th.selection-cell::after { content: "全选当前页"; font-weight: 400; font-size: 12px; }
    .domain-table tbody>tr { display: grid; grid-template-columns: 24px minmax(0,1fr) auto; gap: 8px; padding: 18px 14px; border-bottom: 1px solid var(--border); }
    .domain-table tbody>tr:last-child { border-bottom: 0; }
    .domain-table td { display: block; padding: 0; border: 0; width: auto; min-width: 0; }
    .domain-table .selection-cell { grid-column: 1; grid-row: 1; padding: 3px 0; width: auto; }
    .domain-table .domain-cell { grid-column: 2/-1; grid-row: 1; }
    .domain-table .domain-name { justify-content: space-between; }
    .domain-table .domain-name .copy-button { opacity: .8; }
    .domain-table .date-cell { grid-column: 2; grid-row: 2; font-size: 12px; }
    .domain-table td[data-label=状态] { grid-column: 3; grid-row: 2; }
    .domain-table .row-actions-cell { grid-column: 2/-1; grid-row: 3; }
    .domain-table.has-usage-time { min-width: 0; }
    .domain-table .usage-time-cell { grid-column: 2/-1; grid-row: 3; font-size: 12px; }
    .domain-table .usage-time-cell::before { content: "投入时间："; }
    .domain-table.has-usage-time .row-actions-cell { grid-row: 4; }
    .domain-table .date-cell::before { content: "添加于 "; font-size: 12px; }
    .domain-table .row-actions { margin-top: 4px; }
    .domain-table .row-actions .text-button { min-height: 40px; font-size: 13px; }
    .domain-table .more-button { min-width: 40px; min-height: 40px; }
    .domain-table td.empty { grid-column: 1/-1; }
    .domain-table tbody>tr:not(:has(.selection-cell)) { grid-template-columns: minmax(0,1fr); }
    .domain-table tbody>tr:not(:has(.selection-cell))>td { grid-column: 1; grid-row: auto; }
    .page-intro { align-items: flex-start; flex-direction: column; gap: 18px; margin-bottom: 24px; }
    h1 { font-size: 26px; }
    .card { padding: 20px; }
    .list-card { padding: 0; }
    .server-filters { flex-wrap: wrap; padding: 16px; gap: 10px; }
    .server-filters label { flex-basis: 100%; }
    .filters { padding: 16px; gap: 12px; }
    .filters button { align-self: stretch; }
    .activity-table .activity-action { max-width: 120px; }
    .activity-table .date-cell small { display: block; margin-left: 0; }
    .pagination { padding: 16px; gap: 10px; }
    dialog { padding: 22px; max-height: calc(100dvh - 24px); width: calc(100vw - 24px); }
    dialog .dialog-actions { bottom: -22px; }
    .cf-domain-dialog { padding: 18px; width: calc(100vw - 20px); }
    .cf-domain-dialog .dialog-head { top: -18px; }
    .cf-domain-dialog .card { padding: 16px; }
    .cf-domain-dialog .list-card { padding: 0; }
    .cf-tabs { gap: 16px; }
    .cf-tabs .text-button { font-size: 13px; }
    .cf-domain-heading>a { margin-left: 0; }
    .cf-dns-row { grid-template-columns: minmax(0,1fr); }
    .cf-dns-row>button { justify-self: start; }
    .cf-form-footer { align-items: stretch; }
    .cf-form-footer>button:last-child { width: 100%; margin-left: 0; }
    .cf-inline-form { align-items: stretch; flex-direction: column; }
    .cf-results th, .cf-results td { font-size: 12px; padding: 10px 8px; }
    .form-grid, .server-project-options { grid-template-columns: minmax(0,1fr); gap: 0; }
    .server-project-options { gap: 12px; }
    .bulk-modal-table table, .bulk-modal-table tbody { display: block; }
    .bulk-modal-table thead { display: none; }
    .bulk-modal-table tr { display: grid; gap: 8px; padding: 14px; border-bottom: 1px solid var(--border); }
    .bulk-modal-table td { display: block; padding: 0; border: 0; }
    .selection-bar { padding: 12px; gap: 8px; }
    .selection-bar .actions { margin-left: 0; }
    .selection-hint { flex-basis: 100%; }
    .auth { margin: 8vh auto; padding: 30px 0; }
}
@media(prefers-reduced-motion:reduce) { *, *::before, *::after { scroll-behavior: auto!important; transition: none!important; animation: none!important; } }
.project-workspace[aria-busy="true"] { opacity: .65; cursor: progress; }
.project-profile { display: flex; align-items: center; flex-wrap: wrap; gap: 8px 16px; background: var(--soft); border: 1px solid var(--border); padding: 10px 14px; border-radius: 8px; margin-bottom: 16px; }
.project-facts { display: flex; flex-wrap: wrap; gap: 8px 20px; margin: 0; min-width: 0; }
.project-facts>div { display: flex; align-items: baseline; gap: 8px; min-width: 0; }
.project-facts dt { font-size: 12px; color: var(--muted); flex: none; }
.project-facts dd { margin: 0; overflow-wrap: anywhere; }
.project-profile .actions { margin-left: auto; }
.project-notes { overflow-wrap: anywhere; }
.service-toolbar, .service-section-heading { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 12px; margin-bottom: 16px; }
.service-toolbar form { display: flex; align-items: center; flex-wrap: wrap; gap: 10px; }
.service-toolbar label { margin: 0; }
.service-toolbar select { margin: 0; width: 220px; }
.service-toolbar > .service-actions { flex-wrap: wrap; max-width: 100%; }
.service-section-heading h2 { margin: 0; font-size: 18px; }
.service-view-nav { display: flex; gap: 24px; border-bottom: 1px solid var(--border); margin-bottom: 20px; }
.service-view-nav a { display: inline-flex; align-items: center; gap: 8px; min-height: 48px; padding: 8px 0; border-bottom: 2px solid transparent; color: var(--muted); font-weight: 500; }
.service-view-nav a[aria-current="page"] { color: #235bd6; border-bottom-color: #235bd6; }
.service-view-nav span { padding: 1px 7px; background: #f0f3f8; border-radius: 6px; font-size: 12px; color: var(--muted); }
.service-section-heading { padding: 20px 24px; margin: 0; gap: 16px; }
.service-section-heading p { margin: 4px 0 0; font-size: 12px; color: var(--muted); }
.service-section-heading button { flex-shrink: 0; }
.service-source-link { min-height: 44px; display: inline-flex; align-items: center; }
.service-name { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.service-name strong { flex-basis: 100%; }
.service-table td { vertical-align: middle; }
.service-table th:first-child { width: 18%; }
.service-billing-table th:nth-child(4), .service-billing-table th:nth-child(5) { width: 9%; }
.service-table .service-notes { color: var(--muted); font-size: 12px; white-space: pre-line; }
.service-source-date { flex-basis: 100%; color: var(--muted); font-size: 12px; }
.service-table { table-layout: fixed; }
.service-table th:last-child { width: 132px; }
.service-name, .service-notes { overflow-wrap: anywhere; }
.service-projects { display: flex; flex-wrap: wrap; gap: 6px; }
.service-projects a { padding: 4px 8px; background: #edf3ff; border-radius: 5px; font-size: 12px; }
.service-actions { display: flex; align-items: center; justify-content: flex-end; gap: 4px; white-space: nowrap; }
.service-schedule-date { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; }
.service-renewal-notice .renewal-server { max-width: 100%; flex-wrap: wrap; }
.service-renewal-notice .renewal-server>span { white-space: normal; overflow-wrap: anywhere; }
.excel-source-wrap { max-height: 70dvh; }
.excel-source-table { width: max-content; min-width: 100%; font-size: 12px; }
.excel-source-table thead th { position: sticky; top: 0; z-index: 1; }
.excel-source-table td, .excel-source-table th { padding: 6px 10px; border: 1px solid var(--border); min-width: 30px; white-space: nowrap; }
@media(max-width:900px) {
    .service-section-heading { padding: 16px; }
    .service-section-heading > div { flex: 1 1 200px; }
    .service-table .service-notes { grid-column: 1/-1; }
    .service-table, .service-table tbody { display: block; }
    .service-table thead { display: none; }
    .service-table tbody { padding: 0 16px; }
    .service-table tr { display: grid; grid-template-columns: repeat(2,minmax(0,1fr)); gap: 10px; padding: 16px 0; border-bottom: 1px solid var(--border); }
    .service-table td { display: block; padding: 0; border: 0; min-width: 0; }
    .service-table td:first-child, .service-table td:nth-child(2), .service-table td:last-child, .service-table td.empty { grid-column: 1/-1; }
    .service-table td[data-label]::before { content: attr(data-label); display: block; font-size: 12px; color: var(--muted); margin-bottom: 4px; }
    .service-table td:first-child::before, .service-table td:last-child::before { display: none; }
}

/* Phone navigation, touch targets and safe areas. */
@media(max-width:760px) {
    body:has(.app-sidebar) { padding-bottom: calc(76px + env(safe-area-inset-bottom)); }
    html { scroll-padding-bottom: calc(84px + env(safe-area-inset-bottom)); }
    .app-sidebar { padding: calc(12px + env(safe-area-inset-top)) 16px 12px; gap: 0; }
    .app-sidebar nav { position: fixed; inset: auto 0 0; z-index: 20; display: grid; grid-template-columns: repeat(5,minmax(0,1fr)); gap: 4px; padding: 8px 8px calc(8px + env(safe-area-inset-bottom)); background: #fff; border-top: 1px solid var(--border); box-shadow: 0 -3px 16px #17243c08; }
    .app-sidebar nav a { flex-direction: column; gap: 3px; min-height: 52px; padding: 5px 2px; font-size: 11px; color: #586a85; border-radius: 8px; white-space: nowrap; }
    .app-sidebar nav a.active, .app-sidebar nav a:hover { background: #edf3ff; color: var(--blue); }
    .app-sidebar nav .ui-icon { display: block; width: 21px; height: 21px; filter: none; }
    .app-sidebar .link { min-height: 44px; padding: 8px; }
    .project-navigator { position: sticky; top: 0; z-index: 10; padding: calc(8px + env(safe-area-inset-top)) 16px 8px; box-shadow: 0 2px 8px #17243c08; }
    .project-picker { min-height: 44px; }
    .project-navigator.is-open { max-height: calc(100dvh - 156px - env(safe-area-inset-bottom) - env(safe-area-inset-top)); overflow-y: auto; overscroll-behavior: contain; }
    .project-navigator.is-open .project-nav-list { max-height: none; overflow: visible; }
    .project-nav-item { padding: 10px 8px; min-height: 48px; gap: 8px; }
    .project-nav-item>span:first-child { font-size: 14px; }
    .app-main, .project-workspace { padding: 20px 16px 28px; }
    button, .button, .text-button, .icon-button, .copy-button, .reset-link { touch-action: manipulation; }
    button:not(.text-button):not(.icon-button):not(.copy-button):not(.link):not(.project-picker), .button, .text-button, .icon-button, .copy-button, .pagination .button { min-height: 44px; }
    .icon-button, .copy-button, .domain-name .copy-button, .domain-table .more-button { min-width: 44px; min-height: 44px; }
    input:not([type=checkbox]):not([type=hidden]), select, textarea { font-size: 16px; min-height: 44px; }
    input[type=checkbox] { width: 22px; height: 22px; }
    .check-label { min-height: 44px; }
    .workspace-heading { position: relative; gap: 16px; }
    .workspace-heading>div:first-child { width: 100%; }
    .workspace-heading h1 { padding-right: 88px; min-height: 44px; display: flex; align-items: center; }
    .workspace-heading .actions { gap: 10px; }
    .workspace-heading .actions>button { white-space: nowrap; padding: 10px 12px; }
    .workspace-heading .actions>.delete-resource-button { position: absolute; top: 0; right: -8px; flex: none; padding: 8px; font-size: 13px; color: var(--danger)!important; background: transparent!important; border-color: transparent!important; }
    .workspace-context { flex-wrap: wrap; gap: 6px; margin-bottom: 16px; }
    .project-server-ip { max-width: 100%; }
    .project-server-ip code { overflow-wrap: anywhere; }
    .domain-list-toolbar { gap: 0; margin-bottom: 16px; }
    .domain-list-toolbar .domain-state-tabs { gap: 24px; }
    .domain-create-actions { gap: 8px; }
    .project-workspace > .selection-bar { gap: 8px; }
    .domain-state-tabs a { min-height: 48px; display: inline-flex; align-items: center; }
    .domain-list-toolbar .selection-bar { width: 100%; margin: 0; padding: 8px 0; justify-content: space-between; gap: 6px; }
    .selection-bar button { min-height: 44px!important; padding: 8px 10px!important; }
    .selection-bar .actions { gap: 4px; flex-wrap: wrap; }
    .domain-table .selection-cell { padding-top: 10px; }
    .domain-table th.selection-cell { min-height: 44px; padding: 0; }
    .domain-table .domain-name { align-items: center; }
    .domain-table .row-actions .text-button, .action-menu .text-button { min-height: 44px; }
    .usage-time-cell { white-space: normal; }
    .server-intro { margin-bottom: 16px; }
    .server-toolbar { gap: 12px; margin-bottom: 16px; }
    .server-toolbar .server-filters { flex: 1 1 100%; gap: 8px; }
    .server-toolbar .server-filters input { flex: 1; width: 0; }
    .server-toolbar .reset-link { flex-basis: 100%; padding: 6px 0; }
    .server-toolbar>button { margin-left: auto; }
    .server-table tr { grid-template-columns: minmax(0,1fr) auto; gap: 10px 12px; padding: 16px 0; }
    .server-table td:first-child, .server-table td:nth-child(2), .server-table td.empty { grid-column: 1/-1; }
    .server-table td:nth-child(3), .server-table td:nth-child(4) { display: block; }
    .server-table td:nth-child(3)::before, .server-table td:nth-child(4)::before { display: block; margin-bottom: 4px; }
    .server-table td:nth-child(5) { align-self: center; gap: 8px; }
    .server-table td:nth-child(5)::before { min-width: 0; }
    .server-table td:last-child { gap: 4px; }
    .server-table td.empty:last-child { display: block; }
    .server-ip code { font-size: 14px; }
    .server-linked-projects a { min-height: 36px; display: inline-flex; align-items: center; padding: 6px 10px; }
    .filters-dated { gap: 12px; padding: 16px; }
    .activity-object, .activity-detail, .change-values { overflow-wrap: anywhere; }
    .pagination { padding: 14px; }
    dialog { width: 100%; max-width: 100%; max-height: calc(100dvh - 12px); margin: auto 0 0; padding: 20px 20px calc(20px + env(safe-area-inset-bottom)); border-radius: 16px 16px 0 0; border-bottom: 0; overscroll-behavior: contain; scroll-padding-block: 20px 100px; }
    .dialog-head { align-items: center; margin-bottom: 20px; }
    dialog .dialog-actions { bottom: calc(-20px - env(safe-area-inset-bottom)); padding-bottom: calc(12px + env(safe-area-inset-bottom)); gap: 10px; }
    .dialog-actions>button, .dialog-actions>.button { flex: 1; }
    .cf-domain-dialog { width: 100%; padding: 20px; }
    .cf-domain-dialog .dialog-head { top: -20px; }
    .cf-tabs { overflow-x: auto; white-space: nowrap; }
    .cf-tabs .text-button { flex: none; }
    .project-profile { padding: 10px 12px; }
    .project-facts { width: 100%; gap: 8px 14px; }
    .service-toolbar { align-items: stretch; }
    .service-toolbar form { width: 100%; }
    .service-toolbar select { flex: 1; width: 0; }
    .service-actions .text-button { min-height: 44px; }
    .service-projects a { min-height: 44px; display: inline-flex; align-items: center; }
}
