:root {
  color-scheme: light;
  --ink: #17202a;
  --muted: #667085;
  --line: #dde3ea;
  --panel: #ffffff;
  --soft: #f6f8fb;
  --accent: #4f6bff;
  --accent-deep: #2836c7;
  --cyan: #26d6f4;
  --gold: #b7791f;
  --gold-soft: #fff7e6;
  --blue-soft: #eef4ff;
  --night: #070c22;
  --shadow: 0 22px 60px rgba(13, 21, 48, 0.18);
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", "PingFang SC",
    "Microsoft YaHei", sans-serif;
  color: var(--ink);
  background:
    linear-gradient(135deg, rgba(79, 107, 255, 0.12), transparent 34%),
    linear-gradient(315deg, rgba(38, 214, 244, 0.1), transparent 32%),
    #eef2f8;
  padding: 44px 20px;
  letter-spacing: 0;
}

.sheet {
  width: min(1100px, 100%);
  margin: 0 auto;
  background: var(--panel);
  border: 1px solid rgba(23, 32, 42, 0.08);
  border-radius: 8px;
  box-shadow: var(--shadow);
  overflow: hidden;
}

.masthead {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 28px;
  align-items: start;
  padding: 36px 46px 38px;
  background:
    radial-gradient(circle at 22% 4%, rgba(141, 92, 255, 0.46), transparent 28%),
    radial-gradient(circle at 78% 2%, rgba(38, 214, 244, 0.22), transparent 26%),
    linear-gradient(135deg, #070c22 0%, #0b1234 62%, #11184a 100%);
  border-bottom: 1px solid rgba(255, 255, 255, 0.08);
  color: #fff;
  position: relative;
  overflow: hidden;
}

.masthead::after {
  content: "";
  position: absolute;
  left: 46px;
  right: 46px;
  bottom: 0;
  height: 1px;
  background: linear-gradient(90deg, transparent, rgba(38, 214, 244, 0.7), transparent);
}

.brand {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 30px;
}

.brand-mark {
  width: 82px;
  height: 52px;
  flex: 0 0 auto;
  filter: drop-shadow(0 10px 22px rgba(80, 110, 255, 0.35));
}

.brand-name {
  display: block;
  color: #fff;
  font-size: 31px;
  font-weight: 300;
  line-height: 1;
}

.brand-name strong {
  font-weight: 800;
}

.brand-tagline {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-top: 9px;
  color: rgba(255, 255, 255, 0.68);
  font-size: 13px;
  font-weight: 500;
}

.eyebrow {
  margin: 0 0 12px;
  color: var(--cyan);
  font-size: 14px;
  font-weight: 700;
}

h1 {
  margin: 0;
  font-size: clamp(30px, 4vw, 48px);
  line-height: 1.12;
  letter-spacing: 0;
  color: #fff;
}

.subtitle {
  margin: 16px 0 0;
  max-width: 740px;
  color: rgba(255, 255, 255, 0.74);
  font-size: 16px;
  line-height: 1.75;
}

.meta {
  min-width: 210px;
  padding: 18px 20px;
  border: 1px solid rgba(255, 255, 255, 0.18);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.08);
  backdrop-filter: blur(12px);
}

.meta span {
  display: block;
  color: rgba(255, 255, 255, 0.62);
  font-size: 12px;
  margin-bottom: 6px;
}

.meta strong {
  display: block;
  color: #fff;
  font-size: 18px;
}

.content {
  padding: 38px 46px 44px;
}

.table-wrap {
  overflow-x: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

table {
  width: 100%;
  min-width: 860px;
  border-collapse: collapse;
  table-layout: fixed;
}

th,
td {
  padding: 20px 18px;
  text-align: center;
  border-bottom: 1px solid var(--line);
  border-right: 1px solid var(--line);
  vertical-align: middle;
}

th:last-child,
td:last-child {
  border-right: 0;
}

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

thead th {
  color: #344054;
  background: #f4f7fa;
  font-size: 14px;
  font-weight: 700;
  line-height: 1.35;
}

tbody td {
  font-size: 16px;
  font-weight: 650;
}

.model {
  text-align: left;
  font-size: 18px;
  color: var(--accent-deep);
}

.channel {
  text-align: left;
  color: #253242;
  font-weight: 600;
  line-height: 1.45;
}

.default {
  color: #475467;
  background: var(--soft);
}

.discount {
  color: var(--accent-deep);
  background: var(--blue-soft);
}

.best {
  color: #7a4a08;
  background: var(--gold-soft);
  font-size: 18px;
}

.note {
  display: grid;
  grid-template-columns: 6px minmax(0, 1fr);
  gap: 18px;
  margin-top: 26px;
  padding: 22px 24px;
  border: 1px solid #f1d9a8;
  border-radius: 8px;
  background: linear-gradient(180deg, #fffaf0, #fffdf8);
}

.note::before {
  content: "";
  border-radius: 999px;
  background: var(--gold);
}

.note h2 {
  margin: 0 0 8px;
  font-size: 17px;
  line-height: 1.35;
}

.note p {
  margin: 0;
  color: #5f4b26;
  font-size: 15px;
  line-height: 1.8;
}

.footer {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  padding: 22px 46px;
  color: rgba(255, 255, 255, 0.68);
  font-size: 13px;
  background: var(--night);
  border-top: 1px solid rgba(255, 255, 255, 0.08);
}

.admin-body {
  background: #f5f7fb;
  padding: 28px 18px 50px;
}

.admin-shell {
  width: min(1120px, 100%);
  margin: 0 auto;
}

.admin-header {
  display: flex;
  justify-content: space-between;
  gap: 18px;
  align-items: center;
  margin-bottom: 22px;
  padding: 26px 28px;
  border-radius: 8px;
  color: #fff;
  background: linear-gradient(135deg, #070c22, #14206a);
}

.admin-header h1 {
  font-size: 32px;
}

.success {
  margin-bottom: 18px;
  padding: 14px 16px;
  border: 1px solid #9de2b3;
  border-radius: 8px;
  color: #166534;
  background: #effff4;
  font-weight: 700;
}

.admin-form {
  display: grid;
  gap: 18px;
}

.admin-panel {
  padding: 24px;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: 0 12px 34px rgba(18, 29, 55, 0.06);
}

.admin-panel h2 {
  margin: 0;
  color: #1f2937;
  font-size: 18px;
}

.admin-panel > h2 {
  margin-bottom: 18px;
}

.panel-title-row {
  display: flex;
  justify-content: space-between;
  gap: 16px;
  align-items: center;
  margin-bottom: 18px;
}

.form-grid {
  display: grid;
  gap: 16px;
}

.form-grid.two {
  grid-template-columns: repeat(2, minmax(0, 1fr));
}

.form-grid.five {
  grid-template-columns: repeat(5, minmax(0, 1fr));
}

label {
  display: grid;
  gap: 7px;
  margin-bottom: 16px;
}

label:last-child {
  margin-bottom: 0;
}

label span {
  color: #475467;
  font-size: 13px;
  font-weight: 700;
}

input,
textarea {
  width: 100%;
  border: 1px solid #ccd5e0;
  border-radius: 8px;
  padding: 11px 12px;
  color: var(--ink);
  background: #fff;
  font: inherit;
}

textarea {
  resize: vertical;
}

input:focus,
textarea:focus {
  border-color: var(--accent);
  box-shadow: 0 0 0 3px rgba(79, 107, 255, 0.14);
  outline: none;
}

.rate-card {
  display: grid;
  gap: 16px;
  padding: 18px;
  border: 1px solid #e3e8ef;
  border-radius: 8px;
  background: #fbfcfe;
}

.rate-card-header {
  display: flex;
  justify-content: space-between;
  gap: 14px;
  align-items: center;
}

.rate-card-header strong {
  color: #253242;
  font-size: 15px;
}

.rate-card + .rate-card {
  margin-top: 16px;
}

.admin-actions {
  position: sticky;
  bottom: 0;
  display: flex;
  justify-content: flex-end;
  gap: 12px;
  padding: 18px 0 0;
}

button,
.ghost-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  border-radius: 8px;
  padding: 0 18px;
  border: 0;
  color: #fff;
  background: var(--accent);
  font: inherit;
  font-weight: 800;
  text-decoration: none;
  cursor: pointer;
}

.secondary-button {
  color: var(--accent-deep);
  border: 1px solid #c7d2fe;
  background: #eef4ff;
}

.danger-button {
  min-height: 34px;
  padding: 0 12px;
  color: #b42318;
  border: 1px solid #fecdca;
  background: #fff5f4;
  font-size: 13px;
}

.ghost-button {
  border: 1px solid rgba(255, 255, 255, 0.24);
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
}

.admin-actions .ghost-button {
  color: var(--accent-deep);
  border-color: #c7d2fe;
  background: #eef4ff;
}

@media (max-width: 900px) {
  .form-grid.two,
  .form-grid.five {
    grid-template-columns: 1fr;
  }
}

@media (max-width: 760px) {
  body {
    padding: 18px 12px;
  }

  .masthead,
  .content,
  .footer {
    padding-left: 22px;
    padding-right: 22px;
  }

  .masthead {
    grid-template-columns: 1fr;
    gap: 22px;
    padding-top: 30px;
  }

  .masthead::after {
    left: 22px;
    right: 22px;
  }

  .brand {
    margin-bottom: 24px;
  }

  .brand-mark {
    width: 68px;
    height: 44px;
  }

  .brand-name {
    font-size: 27px;
  }

  .meta {
    width: 100%;
  }

  .footer,
  .admin-header,
  .admin-actions,
  .panel-title-row,
  .rate-card-header {
    flex-direction: column;
    align-items: stretch;
  }
}

@media print {
  body {
    padding: 0;
    background: #fff;
  }

  .sheet {
    width: 100%;
    border: 0;
    border-radius: 0;
    box-shadow: none;
  }

  .table-wrap {
    overflow: visible;
  }
}
