:root {
  --ink: #17211b;
  --muted: #728078;
  --line: #e4e9e5;
  --paper: #ffffff;
  --canvas: #f4f6f2;
  --green: #176b3a;
  --green-dark: #0e4e29;
  --green-soft: #eaf6ed;
  --coral: #e76f51;
  --blue: #3878bf;
  --violet: #7357b8;
  --amber: #c8892f;
  --shadow: 0 8px 30px rgba(28, 53, 37, .055);
}

* { box-sizing: border-box; }
html { font-size: 15px; }
body {
  margin: 0;
  color: var(--ink);
  background: var(--canvas);
  font-family: Inter, "SF Pro Display", "PingFang SC", "Microsoft YaHei", sans-serif;
  -webkit-font-smoothing: antialiased;
}
a { color: inherit; text-decoration: none; }
button, input, textarea, select { font: inherit; }
button { cursor: pointer; }

.app-shell { min-height: 100vh; }
.sidebar {
  position: fixed;
  inset: 0 auto 0 0;
  z-index: 30;
  display: flex;
  width: 248px;
  flex-direction: column;
  color: #eff8f1;
  background:
    radial-gradient(circle at 5% 82%, rgba(93, 172, 116, .24), transparent 28%),
    linear-gradient(160deg, #183626 0%, #10291c 60%, #0c2116 100%);
}
.brand {
  display: flex;
  align-items: center;
  gap: 12px;
  height: 92px;
  padding: 0 28px;
  border-bottom: 1px solid rgba(255,255,255,.09);
}
.brand-mark {
  display: grid;
  flex: 0 0 auto;
  width: 40px;
  height: 40px;
  place-items: center;
  border-radius: 12px 12px 12px 4px;
  color: #14351f;
  background: #a9e2b8;
  font-size: 18px;
  font-weight: 900;
  box-shadow: inset 0 0 0 1px rgba(255,255,255,.5);
}
.brand strong { display: block; font-size: 13px; letter-spacing: .015em; white-space: nowrap; }
.brand small { display: block; margin-top: 3px; color: #95ab9d; font-size: 11px; letter-spacing: .08em; }
.nav { display: flex; flex: 1; flex-direction: column; gap: 6px; padding: 26px 16px; }
.nav a {
  display: flex;
  align-items: center;
  gap: 13px;
  padding: 12px 14px;
  border-radius: 10px;
  color: #afc1b5;
  font-size: 14px;
  transition: .18s ease;
}
.nav a:hover { color: #fff; background: rgba(255,255,255,.06); }
.nav a.active { color: #f6fff8; background: rgba(149, 219, 167, .16); box-shadow: inset 3px 0 #9edbae; }
.nav-icon { width: 22px; color: #8dba9a; font-size: 19px; text-align: center; }
.nav-label { margin: 22px 14px 5px; color: #667e6e; font-size: 10px; font-weight: 800; letter-spacing: .16em; text-transform: uppercase; }
.sidebar-footer { padding: 18px; border-top: 1px solid rgba(255,255,255,.08); }
.server-status { margin: 0 7px 15px; color: #7f9888; font-size: 11px; }
.server-status i, .badge i, .legend i {
  display: inline-block;
  width: 7px;
  height: 7px;
  margin-right: 7px;
  border-radius: 50%;
  background: #58c579;
  box-shadow: 0 0 0 4px rgba(88,197,121,.1);
}
.profile { display: flex; align-items: center; gap: 10px; }
.avatar, .user-chip {
  display: inline-grid;
  width: 34px;
  height: 34px;
  margin-right: 6px;
  place-items: center;
  border-radius: 10px;
  color: #1e5c35;
  background: #dff1e4;
  font-weight: 800;
}
.profile > a { min-width: 0; flex: 1; }
.profile strong { display: block; overflow: hidden; color: #eef7f0; font-size: 13px; text-overflow: ellipsis; }
.profile small { display: block; margin-top: 2px; color: #7f9888; font-size: 10px; }
.icon-button { padding: 6px; border: 0; color: #82998a; background: transparent; font-size: 18px; }
.sidebar-logout-button { display: inline-flex; align-items: center; gap: 5px; padding: 7px 8px; border: 1px solid rgba(255,255,255,.09); border-radius: 8px; color: #9fb2a5; background: rgba(255,255,255,.04); font-size: 9px; }
.sidebar-logout-button b { font-size: 14px; font-weight: 400; }

.main { min-height: 100vh; margin-left: 248px; }
.simple-user .main { margin-left: 0; }
.simple-user .content { max-width: 1160px; }
.topbar {
  display: flex;
  align-items: center;
  min-height: 92px;
  padding: 20px 42px;
  border-bottom: 1px solid var(--line);
  background: rgba(255,255,255,.82);
  backdrop-filter: blur(14px);
}
.topbar h1 { margin: 0 0 5px; font-size: 23px; letter-spacing: -.02em; }
.topbar p { margin: 0; color: var(--muted); font-size: 12px; }
.topbar-title { min-width: 0; }
.top-domain { margin-left: auto; padding: 8px 12px; border: 1px solid var(--line); border-radius: 8px; color: #66736c; background: #fafcf9; font: 11px ui-monospace, SFMono-Regular, Consolas, monospace; }
.user-contact-top { display: flex; min-height: 42px; align-items: center; gap: 7px; margin-left: auto; padding: 5px 6px 5px 12px; border: 1px solid #d8e8dc; border-radius: 11px; color: #7f8c84; background: #f5faf6; font-size: 10px; }
.user-contact-top > span { margin-right: 2px; white-space: nowrap; }
.user-contact-top a { display: flex; min-height: 30px; align-items: center; gap: 6px; padding: 0 10px; border: 1px solid #dbe8de; border-radius: 8px; color: #176b3a; background: #fff; transition: .16s; }
.user-contact-top a:hover { border-color: #9fc8aa; background: #edf8f0; }
.user-contact-top b { font-size: 9px; letter-spacing: .08em; }
.user-contact-top strong { font-size: 12px; font-weight: 800; letter-spacing: .015em; }
.topbar-logout { margin-left: 10px; }
.topbar-logout button { display: inline-flex; height: 34px; align-items: center; gap: 8px; padding: 0 12px; border: 1px solid #dfe5e0; border-radius: 8px; color: #58665e; background: #fff; font-size: 10px; font-weight: 700; transition: .16s; }
.topbar-logout button:hover { border-color: #e4b5aa; color: #b54d36; background: #fff7f5; }
.topbar-logout b { font-size: 14px; font-weight: 500; }
.menu-button { display: none; margin-right: 13px; padding: 7px; border: 0; background: transparent; font-size: 20px; }
.sidebar-backdrop { display: none; }
.content { width: 100%; max-width: 1480px; margin: 0 auto; padding: 34px 42px 60px; }
.flash-stack { display: grid; gap: 8px; margin-bottom: 20px; }
.flash { padding: 12px 15px; border: 1px solid #cfe4d4; border-radius: 9px; color: #256039; background: #eff8f1; font-size: 13px; }
.flash.error { border-color: #f0cbc2; color: #a54029; background: #fff3ef; }

.stats-grid { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 18px; margin-bottom: 18px; }
.stat-card { position: relative; min-height: 154px; overflow: hidden; padding: 24px; border: 1px solid var(--line); border-radius: 15px; background: var(--paper); box-shadow: var(--shadow); }
.stat-card.accent { color: #f5fff7; border-color: transparent; background: linear-gradient(135deg, #1d713f, #11552d); }
.stat-label { display: block; color: var(--muted); font-size: 12px; font-weight: 700; }
.accent .stat-label { color: #bde2c8; }
.stat-card > strong { display: block; margin: 16px 0 8px; font-size: 32px; line-height: 1; letter-spacing: -.04em; }
.stat-card small { color: #95a099; font-size: 10px; }
.accent small { color: #a7cdb2; }
.stat-symbol { position: absolute; top: 22px; right: 22px; color: #8cd0a0; font-size: 25px; }
.stat-symbol.coral { color: var(--coral); }.stat-symbol.blue { color: var(--blue); }.stat-symbol.violet { color: var(--violet); }
.panel { border: 1px solid var(--line); border-radius: 15px; background: var(--paper); box-shadow: var(--shadow); }
.dashboard-grid { display: grid; grid-template-columns: minmax(0, 2fr) minmax(290px, .8fr); gap: 18px; margin-bottom: 18px; }
.chart-panel, .quick-panel { min-height: 325px; padding: 24px; }
.panel-head { display: flex; align-items: flex-start; justify-content: space-between; margin-bottom: 23px; }
.panel-head h2 { margin: 0 0 5px; font-size: 15px; }
.panel-head p { margin: 0; color: var(--muted); font-size: 11px; }
.legend { color: var(--muted); font-size: 10px; }
.legend i { width: 8px; height: 8px; background: var(--green); box-shadow: none; }
.chart { display: grid; height: 210px; grid-template-columns: repeat(14, 1fr); align-items: end; gap: 9px; padding-top: 25px; border-bottom: 1px solid var(--line); background: repeating-linear-gradient(to bottom, transparent 0, transparent 49px, #edf1ed 50px); }
.bar-column { position: relative; display: flex; height: 185px; flex-direction: column; justify-content: flex-end; align-items: center; }
.bar-column i { display: block; width: min(75%, 26px); min-height: 7px; border-radius: 6px 6px 2px 2px; background: linear-gradient(180deg, #3f9460, #1c6d3d); transition: .2s; }
.bar-column:hover i { filter: brightness(1.13); transform: translateY(-2px); }
.bar-column small { position: absolute; top: calc(100% + 9px); color: #98a19b; font-size: 9px; white-space: nowrap; }
.bar-value { margin-bottom: 5px; color: #607067; font-size: 9px; }
.quick-link { display: flex; align-items: center; gap: 12px; padding: 13px 0; border-bottom: 1px solid #edf0ed; }
.quick-link:last-child { border-bottom: 0; }
.quick-link > span:nth-child(2) { flex: 1; }
.quick-link strong { display: block; margin-bottom: 3px; font-size: 12px; }
.quick-link small { color: var(--muted); font-size: 9px; }
.quick-link b { color: #a6afa9; font-size: 20px; font-weight: 400; }
.quick-icon { display: grid; width: 38px; height: 38px; place-items: center; border-radius: 11px; font-size: 18px; }
.quick-icon.green { color: var(--green); background: var(--green-soft); }
.quick-icon.blue { color: var(--blue); background: #e9f1fa; }
.quick-icon.amber { color: var(--amber); background: #fbf2e5; }
.table-panel { overflow: hidden; }
.table-panel > .panel-head { margin: 0; padding: 22px 24px; border-bottom: 1px solid var(--line); }
.text-link, .table-action, .link-button { color: var(--green); font-size: 11px; font-weight: 700; }
.table-wrap { overflow-x: auto; }
table { width: 100%; border-collapse: collapse; }
th { padding: 13px 20px; color: #87928b; background: #f8faf7; font-size: 10px; font-weight: 700; text-align: left; white-space: nowrap; }
td { padding: 17px 20px; border-top: 1px solid #edf0ed; color: #59675f; font-size: 12px; vertical-align: middle; }
tbody tr:first-child td { border-top: 0; }
tbody tr:hover { background: #fbfcfa; }
.domain-name { color: #26342b; font: 600 12px ui-monospace, SFMono-Regular, Consolas, monospace; }
.url-text { display: block; max-width: 420px; overflow: hidden; color: #708078; font: 11px ui-monospace, SFMono-Regular, Consolas, monospace; text-overflow: ellipsis; white-space: nowrap; }
.cell-note { display: block; margin-top: 5px; color: #9aa49e; font-size: 9px; }
.user-remark { max-width: 260px; margin-left: 52px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.badge { display: inline-flex; align-items: center; padding: 5px 9px; border-radius: 999px; font-size: 9px; font-weight: 700; white-space: nowrap; }
.badge.success { color: #267345; background: #eaf6ed; }
.badge.success i { width: 5px; height: 5px; margin-right: 5px; box-shadow: none; }
.badge.warning { color: #91601b; background: #fbf1e1; }.badge.warning i { width: 5px; height: 5px; margin-right: 5px; background: #d79b42; box-shadow: none; }
.badge.muted-badge { color: #767f79; background: #eef0ee; }.badge.muted-badge i { width: 5px; height: 5px; margin-right: 5px; background: #9ba29e; box-shadow: none; }
.badge.neutral { color: #59675f; background: #eef2ef; }
.action-row { display: flex; align-items: center; gap: 11px; }
.link-button { padding: 0; border: 0; background: transparent; }
.danger-text { color: #c6563e; }
.empty { padding: 68px 20px; text-align: center; }
.empty > span { display: grid; width: 52px; height: 52px; margin: 0 auto 15px; place-items: center; border-radius: 15px; color: var(--green); background: var(--green-soft); font-size: 24px; }
.empty h3 { margin: 0 0 7px; font-size: 15px; }.empty p { margin: 0; color: var(--muted); font-size: 11px; }.empty.compact { padding: 40px; }

.page-actions { display: flex; align-items: center; justify-content: space-between; gap: 15px; margin-bottom: 18px; }
.page-actions.right { justify-content: flex-end; }
.info-strip { flex: 1; padding: 13px 15px; border: 1px solid #d8e7da; border-radius: 10px; color: #496151; background: #edf6ef; font-size: 11px; }
.info-strip span { display: inline-grid; width: 18px; height: 18px; margin-right: 8px; place-items: center; border-radius: 50%; color: white; background: var(--green); font-size: 10px; font-weight: 800; }
.button { display: inline-flex; min-height: 40px; align-items: center; justify-content: center; gap: 9px; padding: 0 17px; border: 1px solid transparent; border-radius: 9px; font-size: 12px; font-weight: 700; transition: .16s; }
.button.primary { color: #fff; background: var(--green); box-shadow: 0 6px 14px rgba(23,107,58,.16); }
.button.primary:hover { background: var(--green-dark); transform: translateY(-1px); }
.button.secondary { border-color: var(--line); color: #55635a; background: #fff; }
.button.full { width: 100%; min-height: 48px; justify-content: space-between; padding: 0 19px; }

.form-layout { display: grid; grid-template-columns: minmax(0, 720px) 270px; align-items: start; justify-content: center; gap: 20px; }
.form-card { padding: 30px; }
.form-card.narrow { max-width: 680px; margin: 0 auto; }
.form-section { display: flex; align-items: center; gap: 13px; margin-bottom: 25px; }
.form-section.second { margin-top: 35px; padding-top: 28px; border-top: 1px solid var(--line); }
.section-index { display: grid; width: 38px; height: 38px; place-items: center; border-radius: 11px; color: var(--green); background: var(--green-soft); font-size: 10px; font-weight: 900; }
.form-section h2 { margin: 0 0 3px; font-size: 15px; }.form-section p { margin: 0; color: var(--muted); font-size: 10px; }
.field { display: block; margin-bottom: 20px; }
.field > span { display: block; margin-bottom: 8px; color: #435048; font-size: 11px; font-weight: 700; }
.field input, .field textarea, .field select {
  width: 100%;
  padding: 12px 13px;
  border: 1px solid #dce2dd;
  border-radius: 9px;
  outline: 0;
  color: #26332b;
  background: #fbfcfb;
  font-size: 12px;
  transition: .15s;
}
.field textarea { line-height: 1.6; resize: vertical; }
.field input:focus, .field textarea:focus, .field select:focus { border-color: #74aa84; background: #fff; box-shadow: 0 0 0 3px rgba(45,123,69,.09); }
.field input:disabled { color: #7d8781; background: #f0f2f0; }
.field small { display: block; margin-top: 7px; color: #929d96; font-size: 9px; }
.switch-row { display: flex; align-items: center; justify-content: space-between; gap: 20px; margin: 20px 0; padding: 16px; border: 1px solid var(--line); border-radius: 10px; background: #fafbfa; }
.switch-row strong, .switch-row small { display: block; }.switch-row strong { margin-bottom: 4px; font-size: 11px; }.switch-row small { color: var(--muted); font-size: 9px; }
.switch-row input { width: 38px; height: 20px; accent-color: var(--green); }
.form-actions { display: flex; justify-content: flex-end; gap: 10px; margin-top: 30px; padding-top: 22px; border-top: 1px solid var(--line); }
.helper-card { padding: 24px; border: 1px solid #d9e7dc; border-radius: 15px; color: #365143; background: #edf6ef; }
.helper-icon { display: grid; width: 42px; height: 42px; place-items: center; border-radius: 12px; color: white; background: var(--green); font-size: 21px; }
.helper-card h3 { margin: 18px 0 8px; font-size: 14px; }.helper-card p { margin: 0; color: #668070; font-size: 10px; line-height: 1.7; }
.dns-example { display: grid; gap: 8px; margin: 17px 0; padding: 13px; border: 1px solid #d4e4d8; border-radius: 9px; background: rgba(255,255,255,.58); }
.dns-example span { display: flex; justify-content: space-between; color: #718077; font-size: 9px; }.dns-example strong { color: #244f33; font: 600 10px ui-monospace, monospace; }
.helper-note { padding-top: 14px; border-top: 1px solid #d8e6da; }
.user-chip.large { width: 36px; height: 36px; margin-right: 10px; }
.user-cell-main { display: flex; align-items: center; }
.user-cell-main > span:last-child { min-width: 0; }
.change-cell span { display: block; max-width: 420px; overflow: hidden; color: #7b8780; font: 10px ui-monospace, monospace; text-overflow: ellipsis; white-space: nowrap; }
.change-cell span + span { margin-top: 5px; color: #356047; }
.stats-summary { display: grid; grid-template-columns: 180px minmax(0, 1fr) auto; align-items: center; gap: 18px; margin-bottom: 18px; padding: 19px 22px; border: 1px solid var(--line); border-radius: 14px; background: #fff; box-shadow: var(--shadow); }
.stats-summary span { display: block; margin-bottom: 5px; color: var(--muted); font-size: 10px; }.stats-summary strong { font-size: 22px; }
.stats-summary .target-strong { display: block; overflow: hidden; font: 600 11px ui-monospace, monospace; text-overflow: ellipsis; white-space: nowrap; }
.full-chart { min-height: 320px; margin-bottom: 18px; }.chart.thirty { grid-template-columns: repeat(30, 1fr); gap: 5px; }
code { padding: 4px 6px; border-radius: 5px; color: #3d5748; background: #f0f4f1; font-size: 10px; }
.error-card { padding: 90px 20px; text-align: center; }.error-card > strong { display: block; color: #bad2c0; font-size: 86px; line-height: 1; }.error-card h2 { margin: 20px 0 28px; font-size: 18px; }

.domain-groups { display: grid; gap: 18px; }
.user-domain-group { overflow: hidden; }
.domain-group-head { display: flex; min-height: 88px; align-items: center; justify-content: space-between; gap: 20px; padding: 18px 22px; border-bottom: 1px solid var(--line); background: linear-gradient(90deg, #fbfdfb, #f7faf7); }
.group-user { display: flex; min-width: 0; align-items: center; gap: 12px; }
.group-avatar { width: 42px; height: 42px; margin: 0; border-radius: 13px; font-size: 14px; }
.group-user-line { display: flex; align-items: center; gap: 9px; }
.group-user-line > strong { font-size: 15px; }
.group-user p { max-width: 520px; margin: 6px 0 0; overflow: hidden; color: var(--muted); font-size: 10px; text-overflow: ellipsis; white-space: nowrap; }
.domain-count { padding: 4px 8px; border-radius: 999px; color: #597064; background: #edf2ee; font-size: 9px; font-weight: 700; }
.group-actions { display: flex; flex: 0 0 auto; align-items: center; gap: 16px; }
.compact-button { min-height: 34px; padding: 0 13px; font-size: 10px; }
.domain-list-head, .group-domain-row { display: grid; grid-template-columns: minmax(170px, 1.1fr) minmax(210px, 1.7fr) 105px 120px minmax(185px, .9fr); align-items: center; gap: 16px; }
.domain-list-head { padding: 10px 22px; color: #8a958e; background: #f8faf7; font-size: 9px; font-weight: 700; }
.group-domain-row { min-height: 79px; padding: 15px 22px; border-top: 1px solid #edf0ed; }
.group-domain-row:first-child { border-top: 0; }
.group-domain-row:hover { background: #fbfcfa; }
.domain-primary small { display: block; margin-top: 6px; color: #99a39d; font-size: 9px; }
.unset-target { color: #aa7a33; font-size: 10px; font-weight: 700; }
.own-domain-grid { display: grid; grid-template-columns: repeat(2, minmax(0, 1fr)); gap: 18px; }
.own-domain-card { padding: 22px; }
.own-domain-top { display: flex; align-items: center; gap: 11px; }
.domain-orb { display: grid; width: 38px; height: 38px; flex: 0 0 auto; place-items: center; border-radius: 11px; color: var(--green); background: var(--green-soft); font-size: 19px; }
.own-domain-top > div { min-width: 0; flex: 1; }
.own-domain-top small { display: block; margin-top: 5px; color: #99a39d; font-size: 9px; }
.inline-target-form { margin: 20px 0; }
.inline-target-form label { display: block; margin-bottom: 8px; color: #435048; font-size: 10px; font-weight: 800; }
.inline-target-row { display: grid; grid-template-columns: minmax(0, 1fr) auto; gap: 9px; }
.inline-target-row input { min-width: 0; min-height: 43px; padding: 0 12px; border: 1px solid var(--line); border-radius: 9px; outline: 0; color: var(--text); background: #f8faf7; font: 500 11px ui-monospace, monospace; }
.inline-target-row input:focus { border-color: #74aa84; background: #fff; box-shadow: 0 0 0 3px rgba(45,123,69,.09); }
.inline-target-row .button { min-height: 43px; padding: 0 15px; white-space: nowrap; }

.login-body { min-height: 100vh; background: #eef2ed; }
.login-shell { display: grid; min-height: 100vh; grid-template-columns: minmax(440px, .9fr) minmax(480px, 1.1fr); }
.login-intro {
  display: flex;
  padding: 54px clamp(40px, 6vw, 100px);
  flex-direction: column;
  justify-content: space-between;
  color: #f4fbf5;
  background:
    radial-gradient(circle at 80% 18%, rgba(131,207,152,.2), transparent 25%),
    radial-gradient(circle at 12% 88%, rgba(100,183,123,.15), transparent 30%),
    linear-gradient(145deg, #173a26, #0c2718 70%);
}
.login-brand { display: flex; align-items: center; gap: 12px; font-size: 18px; letter-spacing: .025em; }
.eyebrow { display: block; margin-bottom: 20px; color: #8fc49e; font-size: 10px; font-weight: 800; letter-spacing: .2em; }
.eyebrow.dark { margin-bottom: 10px; color: var(--green); }
.login-intro h1 { margin: 0 0 23px; font-size: clamp(36px, 4vw, 56px); line-height: 1.22; letter-spacing: -.045em; }
.login-intro p { max-width: 460px; margin: 0; color: #9fb4a6; font-size: 13px; line-height: 1.8; }
.login-feature { display: flex; align-items: center; gap: 14px; }
.login-feature > span { display: grid; width: 48px; height: 48px; place-items: center; border: 1px solid rgba(255,255,255,.14); border-radius: 13px; color: #a9d8b6; font-size: 13px; font-weight: 900; }
.login-feature strong, .login-feature small { display: block; }.login-feature strong { margin-bottom: 4px; font-size: 12px; }.login-feature small { color: #779080; font-size: 9px; }
.login-panel { display: grid; padding: 40px; place-items: center; background: #f5f7f3; }
.login-card { width: min(100%, 390px); padding: 40px; border: 1px solid #e1e7e1; border-radius: 20px; background: #fff; box-shadow: 0 22px 60px rgba(19,52,31,.08); }
.login-card h2 { margin: 0 0 8px; font-size: 25px; letter-spacing: -.025em; }.muted { margin: 0 0 30px; color: var(--muted); font-size: 11px; }
.login-card .field { margin-bottom: 17px; }.login-card .field input { min-height: 46px; background: #f8faf7; }
.secure-note { margin-top: 20px; color: #98a19b; font-size: 9px; text-align: center; }.secure-note i { display: inline-block; width: 6px; height: 6px; margin-right: 6px; border-radius: 50%; background: #61b77a; }
.mobile-brand { display: none; }

@media (max-width: 1180px) {
  .stats-grid { grid-template-columns: repeat(2, 1fr); }
  .dashboard-grid { grid-template-columns: 1fr; }
  .quick-panel { min-height: auto; }
  .domain-list-head, .group-domain-row { grid-template-columns: minmax(150px, 1fr) minmax(180px, 1.4fr) 90px 105px minmax(160px, .8fr); gap: 10px; }
}
@media (max-width: 860px) {
  .sidebar { width: min(82vw, 300px); transform: translateX(-100%); transition: transform .22s ease; box-shadow: 20px 0 60px rgba(0,0,0,.18); }
  .sidebar.open { transform: translateX(0); }
  .sidebar-backdrop { position: fixed; inset: 0; z-index: 25; display: block; border: 0; visibility: hidden; opacity: 0; background: rgba(8, 23, 14, .42); transition: opacity .2s, visibility .2s; }
  .sidebar-backdrop.open { visibility: visible; opacity: 1; }
  body.menu-open { overflow: hidden; }
  .main { margin-left: 0; }
  .menu-button { display: block; }
  .topbar { position: sticky; top: 0; z-index: 20; }
  .topbar, .content { padding-left: 22px; padding-right: 22px; }
  .form-layout { grid-template-columns: 1fr; }
  .login-shell { grid-template-columns: 1fr; }.login-intro { display: none; }.mobile-brand { display: flex; align-items: center; gap: 10px; margin-bottom: 34px; font-size: 18px; }
  .domain-list-head { display: none; }
  .group-domain-row { grid-template-columns: 1fr auto; gap: 13px 18px; padding: 18px 20px; }
  .domain-target { grid-column: 1 / -1; grid-row: 2; }
  .group-domain-row > div:nth-child(3) { grid-column: 1; grid-row: 3; }
  .group-domain-row > div:nth-child(4) { grid-column: 2; grid-row: 3; }
  .group-domain-row .action-row { grid-column: 1 / -1; grid-row: 4; padding-top: 10px; border-top: 1px dashed var(--line); }
  .own-domain-grid { grid-template-columns: 1fr; }
}
@media (max-width: 560px) {
  html { font-size: 14px; }
  .topbar { min-height: 72px; padding: 12px 14px; }.topbar h1 { font-size: 18px; }.topbar p { max-width: 205px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }.top-domain { display: none; }
  .simple-user .topbar { align-items: center; gap: 12px 8px; flex-wrap: wrap; }
  .simple-user .topbar-title { order: 1; flex: 1; }
  .simple-user .topbar-logout { order: 2; }
  .simple-user .user-contact-top { order: 3; width: 100%; margin: 0; padding: 6px; justify-content: stretch; }
  .simple-user .user-contact-top > span { padding-left: 5px; }
  .simple-user .user-contact-top a { min-height: 36px; flex: 1; justify-content: center; }
  .simple-user .user-contact-top strong { font-size: 13px; }
  .menu-button { width: 40px; height: 40px; margin-right: 8px; padding: 0; border: 1px solid var(--line); border-radius: 10px; background: #fff; }
  .topbar-logout { margin-left: auto; }.topbar-logout button { min-width: 64px; height: 40px; justify-content: center; }.topbar-logout button span { display: inline; }.topbar-logout b { display: none; }
  .content { padding: 18px 12px 34px; }
  .stats-grid { grid-template-columns: 1fr 1fr; gap: 10px; }.stat-card { min-height: 135px; padding: 18px; }.stat-card > strong { font-size: 27px; }.stat-card small { display: none; }
  .dashboard-grid { gap: 12px; }.chart-panel, .quick-panel { padding: 18px; }
  .chart-panel { min-height: 275px; }.chart { height: 165px; gap: 4px; overflow: hidden; }.bar-column { height: 145px; }.bar-column small { font-size: 7px; transform: rotate(-45deg); transform-origin: center; }
  .page-actions { align-items: stretch; flex-direction: column; }.page-actions .button { align-self: flex-end; }
  .form-card { padding: 20px 16px; }.form-actions { position: sticky; bottom: 0; z-index: 5; margin: 24px -4px -4px; padding: 14px 4px 4px; background: linear-gradient(to bottom, rgba(255,255,255,0), #fff 25%); }.form-actions .button { min-height: 44px; flex: 1; }
  .field input, .field textarea, .field select { min-height: 46px; font-size: 16px; }
  .field textarea { min-height: 96px; }
  .switch-row { min-height: 64px; }
  .stats-summary { grid-template-columns: 1fr auto; }.stats-summary > div:nth-child(2) { grid-column: 1 / -1; grid-row: 2; }
  .full-chart { overflow-x: auto; overscroll-behavior-x: contain; }.chart.thirty { min-width: 680px; }
  .login-panel { padding: 16px; }.login-card { padding: 28px 22px; }
  .domain-group-head { align-items: flex-start; flex-direction: column; }
  .group-actions { width: 100%; justify-content: space-between; }
  .group-user-line { flex-wrap: wrap; }
  .group-user p { white-space: normal; }
  .inline-target-row { grid-template-columns: 1fr; }
  .inline-target-row input { min-height: 48px; font-size: 16px; }
  .inline-target-row .button { min-height: 46px; }
  .button, .quick-link, .table-action, .link-button { min-height: 42px; }
  .table-action, .link-button { display: inline-flex; align-items: center; }
  .table-panel { overflow: visible; border: 0; background: transparent; box-shadow: none; }
  .table-panel > .panel-head { margin-bottom: 10px; border: 1px solid var(--line); border-radius: 13px; background: #fff; }
  .table-wrap { overflow: visible; }
  .table-wrap table, .table-wrap tbody { display: block; width: 100%; }
  .table-wrap thead { display: none; }
  .table-wrap tbody { display: grid; gap: 10px; }
  .table-wrap tr { display: grid; padding: 14px 16px; border: 1px solid var(--line); border-radius: 13px; background: #fff; box-shadow: var(--shadow); }
  .table-wrap td { display: grid; min-height: 38px; padding: 8px 0; grid-template-columns: 92px minmax(0, 1fr); align-items: center; gap: 10px; border: 0; border-top: 1px dashed #edf0ed; }
  .table-wrap td:first-child { border-top: 0; }
  .table-wrap td::before { content: attr(data-label); color: #8a958e; font-size: 9px; font-weight: 700; }
  .table-wrap td > * { min-width: 0; }
  .table-wrap .url-text, .table-wrap .change-cell span { max-width: 100%; white-space: normal; overflow-wrap: anywhere; }
  .table-wrap .user-remark { margin-left: 0; }
  .table-wrap .user-cell-main { grid-column: 2; }
  .table-wrap .user-cell-main .user-chip { margin-right: 10px; }
}
