    * {
      box-sizing: border-box;
    }

    :root {
      --background: #070b10;
      --surface: #101720;
      --surface-light: #172330;
      --text: #eafaff;
      --muted: #8da9b8;
      --yellow: #fcee09;
      --green: #39ff88;
      --blue: #00d9ff;
      --red: #ff2638;
      --border: rgba(0, 217, 255, 0.22);
    }

    body {
      min-height: 100vh;
      margin: 0;
      color: var(--text);
      background:
        radial-gradient(
          circle at 85% 10%,
          rgba(0, 217, 255, 0.12),
          transparent 32%
        ),
        radial-gradient(
          circle at 10% 80%,
          rgba(57, 255, 136, 0.07),
          transparent 30%
        ),
        var(--background);
      font-family:
        system-ui,
        -apple-system,
        BlinkMacSystemFont,
        "Segoe UI",
        "Microsoft YaHei",
        sans-serif;
      line-height: 1.7;
    }

    a {
      color: inherit;
      text-decoration: none;
    }

    .container {
      width: min(1180px, calc(100% - 32px));
      margin: 0 auto;
    }

    .site-header {
      position: sticky;
      top: 0;
      z-index: 10;
      border-bottom: 1px solid var(--border);
      background: rgba(7, 11, 16, 0.92);
      backdrop-filter: blur(12px);
    }

    .header-inner {
      min-height: 68px;
      display: flex;
      align-items: center;
      justify-content: space-between;
      gap: 24px;
    }

    .brand {
      font-weight: 900;
      letter-spacing: 0.12em;
      text-shadow:
        2px 0 rgba(0, 217, 255, 0.3),
        -2px 0 rgba(57, 255, 136, 0.16);
    }

    .brand span {
      color: var(--yellow);
    }

    nav {
      display: flex;
      flex-wrap: wrap;
      gap: 18px;
      color: var(--muted);
      font-size: 14px;
    }

    nav a {
      transition:
        color 0.2s ease,
        text-shadow 0.2s ease;
    }

    nav a:hover,
    nav a.active {
      color: var(--blue);
      text-shadow: 0 0 12px rgba(0, 217, 255, 0.65);
    }

    main {
      padding: 70px 0;
    }

    .breadcrumb {
      margin-bottom: 18px;
      color: var(--muted);
      font-family: monospace;
      font-size: 13px;
    }

    .breadcrumb a {
      color: var(--green);
    }

    .page-label {
      display: inline-block;
      margin: 0 0 18px;
      padding: 5px 10px;
      color: #071015;
      background: var(--yellow);
      font-size: 13px;
      font-weight: 900;
      letter-spacing: 0.14em;
      box-shadow: 4px 4px 0 rgba(0, 217, 255, 0.35);
    }

    h1 {
      margin: 0;
      font-size: clamp(42px, 8vw, 78px);
      line-height: 1.05;
      letter-spacing: -0.04em;
      text-shadow:
        3px 0 rgba(0, 217, 255, 0.22),
        -2px 0 rgba(57, 255, 136, 0.12);
    }

    .page-description {
      max-width: 720px;
      margin: 22px 0 0;
      color: var(--muted);
      font-size: 18px;
    }

    .placeholder {
      min-height: 460px;
      margin-top: 48px;
      display: grid;
      place-items: center;
      padding: 32px;
      border: 1px solid var(--border);
      border-left: 4px solid var(--blue);
      background:
        linear-gradient(
          145deg,
          rgba(23, 35, 48, 0.84),
          rgba(10, 17, 24, 0.95)
        );
      text-align: center;
    }

    .placeholder-symbol {
      margin-bottom: 12px;
      color: var(--blue);
      font-family: monospace;
      font-size: 54px;
      font-weight: 900;
      text-shadow: 0 0 22px rgba(0, 217, 255, 0.48);
    }

    .placeholder h2 {
      margin: 0 0 10px;
      font-size: 26px;
    }

    .placeholder p {
      max-width: 520px;
      margin: 0;
      color: var(--muted);
    }

    .back-button {
      display: inline-block;
      margin-top: 28px;
      padding: 10px 16px;
      border: 1px solid rgba(57, 255, 136, 0.45);
      color: var(--green);
      font-family: monospace;
      font-weight: 700;
      transition:
        background 0.2s ease,
        color 0.2s ease;
    }

    .back-button:hover {
      color: #071015;
      background: var(--green);
    }

    footer {
      margin-top: 70px;
      padding: 32px 0;
      border-top: 1px solid var(--border);
      color: var(--muted);
      text-align: center;
      font-size: 13px;
    }

    @media (max-width: 720px) {
      .header-inner {
        padding: 14px 0;
        align-items: flex-start;
        flex-direction: column;
        gap: 8px;
      }

      nav {
        gap: 12px;
      }

      main {
        padding-top: 48px;
      }

      .placeholder {
        min-height: 360px;
      }
    }
    /* =========================
   角色列表
   ========================= */

.character-grid {
  margin-top: 48px;
  display: grid;
  grid-template-columns:
    repeat(auto-fill, minmax(260px, 340px));
  justify-content: start;
  align-items: start;
  gap: 22px;
}

.character-card {
  position: relative;
  display: block;
  overflow: hidden;
  border: 1px solid var(--border);
  background:
    linear-gradient(
      145deg,
      rgba(23, 35, 48, 0.96),
      rgba(10, 17, 24, 0.98)
    );
  box-shadow:
    0 16px 42px rgba(0, 0, 0, 0.25);
  transition:
    transform 0.2s ease,
    border-color 0.2s ease,
    box-shadow 0.2s ease;
}

.character-card::before {
  content: "";
  position: absolute;
  z-index: 2;
  top: 0;
  left: 0;
  width: 86px;
  height: 5px;
  background:
    linear-gradient(
      90deg,
      var(--yellow),
      var(--green),
      var(--blue)
    );
}

.character-card:hover {
  transform: translateY(-6px);
  border-color: rgba(0, 217, 255, 0.65);
  box-shadow:
    0 22px 50px rgba(0, 0, 0, 0.34),
    0 0 28px rgba(0, 217, 255, 0.1);
}

.character-portrait {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: top center;
  border-bottom: 1px solid var(--border);
  background: var(--surface);
}

.character-card-body {
  padding: 22px;
}

.character-code {
  margin: 0 0 12px;
  color: var(--yellow);
  font-family: monospace;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.12em;
}

.character-name {
  margin: 0;
  font-size: 28px;
  line-height: 1.2;
}

.character-role {
  margin: 8px 0 0;
  color: var(--blue);
  font-family: monospace;
  font-size: 13px;
  font-weight: 700;
}

.character-summary {
  margin: 18px 0 0;
  color: var(--muted);
}

.character-tags {
  margin-top: 18px;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.character-tag {
  padding: 4px 9px;
  border: 1px solid rgba(57, 255, 136, 0.32);
  color: var(--green);
  background: rgba(57, 255, 136, 0.04);
  font-family: monospace;
  font-size: 11px;
}

.character-open {
  display: inline-block;
  margin-top: 22px;
  color: var(--blue);
  font-family: monospace;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.1em;
  transition:
    color 0.2s ease,
    transform 0.2s ease;
}

.character-card:hover .character-open {
  color: var(--green);
  transform: translateX(5px);
}


/* =========================
   角色详情页
   ========================= */

.profile-layout {
  margin-top: 48px;
  display: grid;
  grid-template-columns:
    minmax(260px, 0.78fr)
    minmax(0, 1.22fr);
  gap: 30px;
  align-items: start;
}

.profile-portrait-panel {
  position: sticky;
  top: 96px;
  border: 1px solid var(--border);
  background: var(--surface);
}

.profile-portrait {
  display: block;
  width: 100%;
  aspect-ratio: 4 / 5;
  object-fit: cover;
  object-position: top center;
}

.profile-status {
  padding: 16px 18px;
  border-top: 1px solid var(--border);
  color: var(--green);
  font-family: monospace;
  font-size: 12px;
  font-weight: 800;
}

.profile-status::before {
  content: "● ";
  color: var(--green);
}

.profile-data {
  border: 1px solid var(--border);
  background:
    linear-gradient(
      145deg,
      rgba(23, 35, 48, 0.82),
      rgba(10, 17, 24, 0.94)
    );
}

.profile-data-header {
  padding: 18px 22px;
  border-bottom: 1px solid var(--border);
  color: var(--yellow);
  font-family: monospace;
  font-size: 13px;
  font-weight: 900;
  letter-spacing: 0.12em;
}

.profile-info {
  margin: 0;
  display: grid;
  grid-template-columns: 1fr 1fr;
}

.profile-info div {
  padding: 18px 22px;
  border-bottom: 1px solid var(--border);
}

.profile-info div:nth-child(odd) {
  border-right: 1px solid var(--border);
}

.profile-info dt {
  margin-bottom: 5px;
  color: var(--muted);
  font-size: 12px;
}

.profile-info dd {
  margin: 0;
  color: var(--text);
  font-weight: 700;
}

.profile-introduction {
  padding: 24px;
}

.profile-introduction h2 {
  margin: 0 0 14px;
  color: var(--blue);
  font-size: 24px;
}

.profile-introduction p {
  margin: 0;
  color: var(--muted);
}

.profile-introduction p + p {
  margin-top: 16px;
}

.story-container {
  margin-top: 42px;
}

.story-section {
  margin-top: 22px;
  padding: 28px;
  border: 1px solid var(--border);
  border-left: 4px solid var(--yellow);
  background:
    linear-gradient(
      90deg,
      rgba(252, 238, 9, 0.035),
      rgba(16, 23, 32, 0.92) 28%
    );
}

.story-number {
  margin: 0 0 8px;
  color: var(--yellow);
  font-family: monospace;
  font-size: 12px;
  font-weight: 900;
  letter-spacing: 0.12em;
}

.story-section h2 {
  margin: 0 0 18px;
  font-size: 28px;
}

.story-section p {
  margin: 0;
  color: var(--muted);
}

.story-section p + p {
  margin-top: 16px;
}

.story-image {
  display: block;
  width: 100%;
  max-height: 560px;
  margin-top: 24px;
  object-fit: cover;
  border: 1px solid var(--border);
}

@media (max-width: 820px) {
  .profile-layout {
    grid-template-columns: 1fr;
  }

  .profile-portrait-panel {
    position: static;
    max-width: 520px;
  }
}

@media (max-width: 560px) {
  .profile-info {
    grid-template-columns: 1fr;
  }

  .profile-info div:nth-child(odd) {
    border-right: 0;
  }

  .story-section {
    padding: 22px;
  }
}
@media (max-width: 600px) {
  .character-grid {
    grid-template-columns: 1fr;
  }

  .character-card {
    width: 100%;
  }
}
/* =========================
   角色属性面板入口
   ========================= */

.profile-actions {
  margin-top: 28px;
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 14px;
}

.sheet-open-button {
  display: inline-flex;
  align-items: center;
  gap: 16px;
  padding: 12px 18px;
  border: 1px solid rgba(255, 38, 56, 0.72);
  color: var(--text);
  background:
    linear-gradient(
      90deg,
      rgba(255, 38, 56, 0.18),
      rgba(10, 17, 24, 0.95)
    );
  font: inherit;
  font-weight: 800;
  cursor: pointer;
  box-shadow:
    inset 4px 0 0 #ff2638,
    0 0 24px rgba(255, 38, 56, 0.08);
  transition:
    color 0.2s ease,
    border-color 0.2s ease,
    transform 0.2s ease,
    box-shadow 0.2s ease;
}

.sheet-open-button:hover {
  color: #fff;
  border-color: #ff2638;
  transform: translateY(-2px);
  box-shadow:
    inset 4px 0 0 #ff2638,
    0 0 30px rgba(255, 38, 56, 0.2);
}

.sheet-open-code {
  color: #ff5260;
  font-family: monospace;
  font-size: 11px;
  letter-spacing: 0.12em;
}

.profile-access-label {
  color: var(--green);
  font-family: monospace;
  font-size: 11px;
  letter-spacing: 0.1em;
}


/* =========================
   属性面板窗口
   ========================= */

body.character-sheet-open {
  overflow: hidden;
}

.character-sheet-modal {
  position: fixed;
  inset: 0;
  z-index: 10000;
  display: grid;
  place-items: center;
  padding: 24px;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition:
    opacity 0.25s ease,
    visibility 0.25s ease;
}

.character-sheet-modal.is-open {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
}

.sheet-backdrop {
  position: absolute;
  inset: 0;
  width: 100%;
  border: 0;
  background:
    radial-gradient(
      circle at center,
      rgba(255, 38, 56, 0.08),
      transparent 50%
    ),
    rgba(2, 5, 8, 0.88);
  backdrop-filter: blur(8px);
  cursor: default;
}

.character-sheet-window {
  position: relative;
  z-index: 1;
  width: min(1320px, 100%);
  max-height: calc(100vh - 48px);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  border: 1px solid rgba(0, 217, 255, 0.45);
  background:
    linear-gradient(
      145deg,
      rgba(11, 18, 25, 0.99),
      rgba(5, 8, 12, 0.99)
    );
  box-shadow:
    0 30px 90px rgba(0, 0, 0, 0.7),
    0 0 44px rgba(0, 217, 255, 0.1);
  transform: translateY(18px) scale(0.985);
  transition: transform 0.25s ease;
}

.character-sheet-modal.is-open
.character-sheet-window {
  transform: translateY(0) scale(1);
}

.sheet-window-header {
  flex: 0 0 auto;
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 20px;
  padding: 22px 26px;
  border-bottom: 1px solid rgba(0, 217, 255, 0.28);
  background:
    linear-gradient(
      90deg,
      rgba(255, 38, 56, 0.14),
      rgba(0, 217, 255, 0.04)
    );
}

.sheet-window-code {
  margin: 0 0 5px;
  color: #ff5260;
  font-family: monospace;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.14em;
}

.sheet-window-header h2 {
  margin: 0;
  font-size: clamp(24px, 4vw, 38px);
  line-height: 1.15;
}

.sheet-close-button {
  width: 44px;
  height: 44px;
  flex: 0 0 auto;
  border: 1px solid rgba(255, 38, 56, 0.55);
  color: #ff5260;
  background: rgba(255, 38, 56, 0.05);
  font-size: 30px;
  line-height: 1;
  cursor: pointer;
}

.sheet-close-button:hover {
  color: #071015;
  background: #ff2638;
}

.sheet-window-toolbar {
  flex: 0 0 auto;
  min-height: 52px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 9px 26px;
  border-bottom: 1px solid var(--border);
  color: var(--green);
  background: rgba(57, 255, 136, 0.025);
  font-family: monospace;
  font-size: 12px;
}

.sheet-status-dot {
  display: inline-block;
  width: 8px;
  height: 8px;
  margin-right: 7px;
  border-radius: 50%;
  background: var(--green);
  box-shadow: 0 0 12px var(--green);
}

.sheet-auth-button {
  padding: 7px 11px;
  border: 1px solid rgba(141, 169, 184, 0.25);
  color: var(--muted);
  background: transparent;
  font-family: monospace;
  font-size: 11px;
}

.sheet-auth-button.is-authenticated {
  border-color: rgba(57, 255, 136, 0.45);
  color: var(--green);
}

.sheet-window-content {
  flex: 1 1 auto;
  overflow-y: auto;
  overscroll-behavior: contain;
  padding: 26px;
}

.sheet-section-heading {
  margin-bottom: 18px;
  display: flex;
  align-items: flex-end;
  justify-content: space-between;
  gap: 18px;
}

.sheet-section-heading p {
  margin: 0 0 3px;
  color: var(--yellow);
  font-family: monospace;
  font-size: 11px;
  font-weight: 900;
  letter-spacing: 0.12em;
}

.sheet-section-heading h3 {
  margin: 0;
  font-size: 27px;
}

.sheet-section-heading > span {
  color: var(--muted);
  font-family: monospace;
  font-size: 11px;
}


/* =========================
   基础属性
   ========================= */

.attribute-grid {
  display: grid;
  grid-template-columns:
    repeat(5, minmax(120px, 1fr));
  gap: 12px;
}

.attribute-card {
  position: relative;
  min-height: 128px;
  display: grid;
  grid-template-columns: 1fr auto;
  align-content: space-between;
  gap: 12px;
  padding: 16px;
  overflow: hidden;
  border: 1px solid rgba(0, 217, 255, 0.28);
  background:
    linear-gradient(
      145deg,
      rgba(23, 35, 48, 0.88),
      rgba(8, 13, 18, 0.96)
    );
}

.attribute-card::before {
  content: "";
  position: absolute;
  top: 0;
  left: 0;
  width: 54px;
  height: 4px;
  background:
    linear-gradient(
      90deg,
      var(--yellow),
      var(--blue)
    );
}

.attribute-name {
  color: var(--text);
  font-weight: 800;
}

.attribute-code {
  color: var(--blue);
  font-family: monospace;
  font-size: 12px;
  font-weight: 900;
}

.attribute-value {
  grid-column: 1 / -1;
  width: 100%;
  border: 0;
  border-top: 1px solid rgba(0, 217, 255, 0.18);
  color: var(--yellow);
  background: transparent;
  font-family: monospace;
  font-size: 34px;
  font-weight: 900;
  text-align: right;
  outline: none;
}

.attribute-value:not([readonly]) {
  border-bottom: 1px solid var(--green);
  color: var(--green);
}


/* =========================
   技能面板
   ========================= */

.skills-section {
  margin-top: 44px;
}

.skill-group {
  margin-top: 14px;
  border: 1px solid rgba(0, 217, 255, 0.22);
  background: rgba(16, 23, 32, 0.72);
}

.skill-group-heading {
  width: 100%;
  min-height: 62px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  padding: 13px 18px;
  border: 0;
  border-left: 4px solid var(--blue);
  color: var(--text);
  background:
    linear-gradient(
      90deg,
      rgba(0, 217, 255, 0.07),
      transparent 65%
    );
  text-align: left;
  cursor: pointer;
}

.skill-group-heading:hover {
  background:
    linear-gradient(
      90deg,
      rgba(0, 217, 255, 0.14),
      transparent 65%
    );
}

.skill-group-heading strong {
  display: block;
  font-size: 18px;
}

.skill-group-heading small {
  display: block;
  margin-top: 2px;
  color: var(--blue);
  font-family: monospace;
  font-size: 10px;
  letter-spacing: 0.12em;
}

.skill-group-toggle-symbol {
  color: var(--yellow);
  font-family: monospace;
  font-size: 25px;
  font-weight: 900;
}

.skill-table-wrapper {
  overflow-x: auto;
}

.skill-table {
  width: 100%;
  min-width: 680px;
  border-collapse: collapse;
}

.skill-table th,
.skill-table td {
  padding: 11px 14px;
  border-top: 1px solid rgba(0, 217, 255, 0.13);
  text-align: center;
}

.skill-table th {
  color: var(--muted);
  background: rgba(0, 217, 255, 0.025);
  font-family: monospace;
  font-size: 10px;
  font-weight: 800;
  letter-spacing: 0.08em;
}

.skill-table th:first-child,
.skill-table td:first-child {
  text-align: left;
}

.skill-table tbody tr:hover {
  background: rgba(57, 255, 136, 0.025);
}

.skill-name-cell {
  min-width: 230px;
}

.skill-name {
  color: var(--text);
  font-weight: 700;
}

.skill-attribute-code {
  display: inline-block;
  margin-left: 8px;
  color: var(--blue);
  font-family: monospace;
  font-size: 10px;
}

.skill-number-input {
  width: 76px;
  padding: 6px 7px;
  border: 1px solid rgba(0, 217, 255, 0.2);
  color: var(--text);
  background: rgba(5, 8, 12, 0.72);
  font-family: monospace;
  font-weight: 800;
  text-align: center;
  outline: none;
}

.skill-number-input:not([readonly]) {
  border-color: var(--green);
  color: var(--green);
}

.skill-total {
  display: inline-grid;
  min-width: 48px;
  min-height: 36px;
  place-items: center;
  padding: 5px 9px;
  border: 1px solid rgba(252, 238, 9, 0.38);
  color: var(--yellow);
  background: rgba(252, 238, 9, 0.04);
  font-family: monospace;
  font-size: 17px;
  font-weight: 900;
}


/* =========================
   面板底部
   ========================= */

.sheet-window-footer {
  flex: 0 0 auto;
  min-height: 58px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 20px;
  padding: 10px 26px;
  border-top: 1px solid rgba(0, 217, 255, 0.22);
  color: var(--muted);
  background: rgba(5, 8, 12, 0.95);
  font-family: monospace;
  font-size: 10px;
  letter-spacing: 0.08em;
}

.sheet-footer-close {
  padding: 8px 13px;
  border: 1px solid rgba(57, 255, 136, 0.4);
  color: var(--green);
  background: transparent;
  font-family: monospace;
  cursor: pointer;
}

.sheet-footer-close:hover {
  color: #071015;
  background: var(--green);
}


/* =========================
   属性面板响应式布局
   ========================= */

@media (max-width: 980px) {
  .attribute-grid {
    grid-template-columns:
      repeat(3, minmax(120px, 1fr));
  }
}

@media (max-width: 680px) {
  .character-sheet-modal {
    padding: 0;
  }

  .character-sheet-window {
    width: 100%;
    height: 100%;
    max-height: none;
    border: 0;
  }

  .sheet-window-header,
  .sheet-window-content {
    padding-left: 16px;
    padding-right: 16px;
  }

  .sheet-window-toolbar,
  .sheet-window-footer {
    padding-left: 16px;
    padding-right: 16px;
  }

  .attribute-grid {
    grid-template-columns:
      repeat(2, minmax(110px, 1fr));
  }

  .sheet-section-heading {
    align-items: flex-start;
    flex-direction: column;
  }

  .sheet-window-footer > span {
    display: none;
  }

  .sheet-window-footer {
    justify-content: flex-end;
  }
}

@media (max-width: 390px) {
  .attribute-grid {
    grid-template-columns: 1fr;
  }
}