:root {
  color-scheme: light;
  --bg: #f5f7f8;
  --surface: #ffffff;
  --surface-muted: #eef2f3;
  --text: #20262d;
  --muted: #66727c;
  --border: #dbe2e5;
  --accent: #0b9fba;
  --accent-strong: #087f96;
  --success: #18885a;
  --warning: #9b6610;
  --danger: #a33a3a;
  --radius: 6px;
  --shadow: 0 12px 34px rgba(32, 38, 45, 0.08);
}

* {
  box-sizing: border-box;
}

html {
  min-width: 320px;
  background: var(--bg);
  scroll-behavior: smooth;
}

body {
  margin: 0;
  color: var(--text);
  background: var(--bg);
  font-family:
    "Segoe UI", "PingFang SC", "Microsoft YaHei", Arial, sans-serif;
  font-size: 15px;
  line-height: 1.6;
}

a {
  color: inherit;
  text-decoration: none;
}

button,
input,
select {
  font: inherit;
}

button,
.button {
  min-height: 42px;
  border: 1px solid transparent;
  border-radius: var(--radius);
  padding: 9px 16px;
  color: #ffffff;
  background: var(--accent);
  cursor: pointer;
  font-weight: 650;
  text-align: center;
  transition:
    background 160ms ease,
    transform 160ms ease,
    border-color 160ms ease;
}

button:hover,
.button:hover {
  background: var(--accent-strong);
}

button:active,
.button:active {
  transform: translateY(1px);
}

button:focus-visible,
.button:focus-visible,
a:focus-visible,
input:focus-visible,
select:focus-visible {
  outline: 3px solid rgba(11, 159, 186, 0.22);
  outline-offset: 2px;
}

button:disabled {
  color: #7f8a92;
  background: #e1e6e8;
  border-color: #d5dcdf;
  cursor: not-allowed;
}

.button.secondary {
  color: var(--text);
  background: var(--surface);
  border-color: var(--border);
}

.button.secondary:hover {
  background: var(--surface-muted);
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  border-bottom: 1px solid var(--border);
  background: rgba(255, 255, 255, 0.96);
  backdrop-filter: blur(12px);
}

.header-inner {
  width: min(1180px, calc(100% - 32px));
  min-height: 66px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 24px;
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 11px;
  font-size: 17px;
  font-weight: 750;
  white-space: nowrap;
}

.brand img {
  width: 36px;
  height: 36px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
}

.site-nav {
  display: flex;
  align-items: center;
  gap: 8px;
}

.site-nav a {
  padding: 8px 11px;
  border-radius: var(--radius);
  color: var(--muted);
  font-weight: 600;
}

.site-nav a:hover,
.site-nav a[aria-current="page"] {
  color: var(--text);
  background: var(--surface-muted);
}

.account-label {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--muted);
  font-size: 13px;
  white-space: nowrap;
}

.status-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--success);
}

.main-shell {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 34px 0 56px;
}

.page-heading {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 24px;
  margin-bottom: 24px;
}

.page-heading h1 {
  max-width: 760px;
  margin: 0;
  font-size: clamp(28px, 4vw, 46px);
  line-height: 1.08;
  letter-spacing: 0;
}

.page-heading p {
  max-width: 640px;
  margin: 10px 0 0;
  color: var(--muted);
}

.eyebrow {
  margin: 0 0 8px;
  color: var(--accent-strong);
  font-size: 13px;
  font-weight: 750;
}

.notice {
  display: flex;
  align-items: flex-start;
  gap: 12px;
  margin-bottom: 22px;
  padding: 13px 15px;
  border: 1px solid #bddde3;
  border-radius: var(--radius);
  color: #285c66;
  background: #eaf7f9;
}

.notice strong {
  display: block;
  margin-bottom: 2px;
  color: #164c56;
}

.dashboard-grid {
  display: grid;
  grid-template-columns: minmax(0, 1.65fr) minmax(260px, 0.75fr);
  gap: 20px;
}

.panel {
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow);
}

.panel-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  min-height: 58px;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
}

.panel-header h2,
.panel-header h3 {
  margin: 0;
  font-size: 17px;
  letter-spacing: 0;
}

.panel-body {
  padding: 18px;
}

.metric-row {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1px;
  overflow: hidden;
  border-bottom: 1px solid var(--border);
  background: var(--border);
}

.metric {
  min-height: 118px;
  padding: 20px;
  background: var(--surface);
}

.metric-label {
  color: var(--muted);
  font-size: 13px;
}

.metric-value {
  margin-top: 10px;
  font-size: 27px;
  font-weight: 760;
  line-height: 1.1;
}

.metric-note {
  margin-top: 8px;
  color: var(--muted);
  font-size: 12px;
}

.table-wrap {
  overflow-x: auto;
}

table {
  width: 100%;
  border-collapse: collapse;
  min-width: 660px;
}

th,
td {
  padding: 13px 14px;
  border-bottom: 1px solid var(--border);
  text-align: left;
  vertical-align: middle;
}

th {
  color: var(--muted);
  background: #fafbfb;
  font-size: 12px;
  font-weight: 700;
}

tbody tr:last-child td {
  border-bottom: 0;
}

.model-name {
  font-weight: 700;
}

.model-id {
  color: var(--muted);
  font-family: Consolas, "SFMono-Regular", monospace;
  font-size: 12px;
}

.tag {
  display: inline-flex;
  align-items: center;
  min-height: 26px;
  padding: 3px 8px;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--muted);
  background: #fafbfb;
  font-size: 12px;
  font-weight: 650;
}

.tag.success {
  color: var(--success);
  border-color: #b9dfcf;
  background: #edf8f3;
}

.stack {
  display: grid;
  gap: 14px;
}

.quick-action {
  display: block;
  padding: 14px 15px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
}

.quick-action:hover {
  border-color: #9acbd3;
  background: #f5fbfc;
}

.quick-action strong {
  display: block;
}

.quick-action span {
  display: block;
  margin-top: 3px;
  color: var(--muted);
  font-size: 13px;
}

.product-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.55fr) minmax(300px, 0.7fr);
  gap: 22px;
}

.price-list {
  display: grid;
  gap: 12px;
}

.price-option {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 14px;
  padding: 15px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  cursor: pointer;
}

.price-option:hover,
.price-option.selected {
  border-color: var(--accent);
  background: #f2fbfc;
}

.price-option input {
  width: 18px;
  height: 18px;
  accent-color: var(--accent);
}

.price-option strong,
.price-option span {
  display: block;
}

.price-option span {
  color: var(--muted);
  font-size: 13px;
}

.price-option .amount {
  color: var(--text);
  font-size: 18px;
  font-weight: 760;
}

.summary-list {
  display: grid;
  gap: 11px;
}

.summary-row {
  display: flex;
  justify-content: space-between;
  gap: 20px;
  color: var(--muted);
}

.summary-row strong {
  color: var(--text);
}

.summary-row.total {
  margin-top: 5px;
  padding-top: 14px;
  border-top: 1px solid var(--border);
  font-size: 18px;
}

.payment-method {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 15px;
  border: 1px solid var(--accent);
  border-radius: var(--radius);
  background: #f2fbfc;
}

.payment-method strong,
.payment-method span {
  display: block;
}

.payment-method span {
  color: var(--muted);
  font-size: 12px;
}

.checkout-actions {
  display: grid;
  gap: 10px;
  margin-top: 18px;
}

.field {
  display: grid;
  gap: 7px;
}

.field label {
  font-size: 13px;
  font-weight: 700;
}

.field input,
.field select {
  width: 100%;
  min-height: 42px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 9px 11px;
  color: var(--text);
  background: #ffffff;
}

.field small {
  color: var(--muted);
}

.legal {
  max-width: 820px;
}

.legal h2 {
  margin: 30px 0 10px;
  font-size: 21px;
}

.legal p,
.legal li {
  color: #4f5c65;
}

.legal ul {
  padding-left: 20px;
}

.site-footer {
  border-top: 1px solid var(--border);
  background: var(--surface);
}

.footer-inner {
  width: min(1180px, calc(100% - 32px));
  margin: 0 auto;
  padding: 26px 0;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  color: var(--muted);
  font-size: 13px;
}

.footer-links {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
}

.mobile-nav {
  display: none;
}

@media (max-width: 820px) {
  .header-inner {
    grid-template-columns: 1fr auto;
    min-height: 60px;
  }

  .site-nav,
  .account-label {
    display: none;
  }

  .mobile-nav {
    display: block;
  }

  .mobile-nav select {
    min-height: 38px;
    max-width: 150px;
    border: 1px solid var(--border);
    border-radius: var(--radius);
    padding: 7px 30px 7px 9px;
    background: var(--surface);
  }

  .main-shell {
    padding-top: 24px;
  }

  .page-heading,
  .footer-inner {
    align-items: flex-start;
    flex-direction: column;
  }

  .dashboard-grid,
  .product-layout {
    grid-template-columns: 1fr;
  }

  .metric-row {
    grid-template-columns: 1fr;
  }

  .metric {
    min-height: auto;
  }
}

@media (max-width: 520px) {
  .header-inner,
  .main-shell,
  .footer-inner {
    width: min(100% - 22px, 1180px);
  }

  .brand span {
    font-size: 15px;
  }

  .brand img {
    width: 32px;
    height: 32px;
  }

  .page-heading h1 {
    font-size: 30px;
  }

  .panel-header,
  .panel-body,
  .metric {
    padding-left: 14px;
    padding-right: 14px;
  }

  .price-option {
    grid-template-columns: auto 1fr;
  }

  .price-option .amount {
    grid-column: 2;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  * {
    transition: none !important;
  }
}
