:root {
  --page-bg: #6f57c7;
  --panel-bg: #efefef;
  --panel-border: #cfe6f7;
  --text: #2b2f38;
  --muted: #6f7b8a;
  --blue: #1f9eff;
  --green: #56b955;
  --orange: #f7ab2f;
  --purple: #d7b6e6;
  --pink: #f3b7cf;
}

* { box-sizing: border-box; }
html, body { margin: 0; padding: 0; }
body {
  min-height: 100vh;
  font-family: "Segoe UI", "Microsoft YaHei UI", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at top right, rgba(252, 207, 123, 0.18), transparent 28%),
    radial-gradient(circle at 15% 12%, rgba(110, 184, 255, 0.16), transparent 26%),
    linear-gradient(180deg, #142944, #1a365a 46%, #244774);
}

.hub-home-body {
  background:
    radial-gradient(circle at top right, rgba(228, 182, 108, 0.2), transparent 26%),
    radial-gradient(circle at 10% 10%, rgba(121, 52, 38, 0.22), transparent 22%),
    linear-gradient(180deg, #241816, #3c221d 45%, #5a3224);
}

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

.page-shell {
  padding: 16px;
}

.top-nav {
  width: min(1900px, calc(100vw - 24px));
  margin: 0 auto 16px;
  padding: 10px 14px;
  border-radius: 12px;
  background: rgba(255, 255, 255, 0.14);
  border: 1px solid rgba(255, 255, 255, 0.2);
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  color: #fff;
  box-shadow: 0 10px 24px rgba(40, 29, 85, 0.12);
}

.top-nav-link {
  display: inline-flex;
  align-items: center;
  min-height: 34px;
  padding: 0 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.18);
  font-size: 13px;
  font-weight: 700;
}

.top-nav-title {
  font-size: 14px;
  font-weight: 700;
  letter-spacing: 0.04em;
}

.hub-shell {
  min-height: 100vh;
  max-width: 1500px;
  margin: 0 auto;
  padding: 24px 22px 32px;
  display: grid;
  gap: 18px;
  position: relative;
}

.hub-home-body .hub-shell::before,
.hub-home-body .hub-shell::after {
  content: "";
  position: absolute;
  pointer-events: none;
  border-radius: 999px;
  z-index: 0;
}

.hub-home-body .hub-shell::before {
  width: 280px;
  height: 280px;
  top: 12px;
  right: 16px;
  background: radial-gradient(circle, rgba(238, 198, 128, 0.14), transparent 68%);
}

.hub-home-body .hub-shell::after {
  width: 360px;
  height: 360px;
  left: -120px;
  top: 140px;
  background: radial-gradient(circle, rgba(154, 78, 55, 0.14), transparent 70%);
}

.hub-hero {
  padding: 28px 30px;
  border-radius: 24px;
  background:
    linear-gradient(135deg, rgba(255,255,255,0.22), rgba(255,255,255,0.08)),
    linear-gradient(135deg, rgba(59, 120, 201, 0.42), rgba(23, 53, 95, 0.24));
  border: 1px solid rgba(255,255,255,0.24);
  color: #fff;
  box-shadow: 0 24px 54px rgba(10, 24, 48, 0.26);
  position: relative;
  overflow: hidden;
}

.hub-home-body .hub-hero {
  background:
    linear-gradient(135deg, rgba(83, 34, 27, 0.92), rgba(46, 24, 22, 0.9)),
    linear-gradient(180deg, rgba(126, 67, 45, 0.4), rgba(53, 29, 24, 0.24));
  border-color: rgba(238, 200, 142, 0.22);
  box-shadow: 0 26px 58px rgba(19, 8, 8, 0.3);
}

.hub-hero::before,
.hub-hero::after {
  content: "";
  position: absolute;
  border-radius: 999px;
  pointer-events: none;
}

.hub-hero::before {
  width: 220px;
  height: 220px;
  right: -70px;
  top: -90px;
  background: radial-gradient(circle, rgba(255,255,255,0.18), transparent 68%);
}

.hub-hero::after {
  width: 280px;
  height: 280px;
  right: 18%;
  bottom: -180px;
  background: radial-gradient(circle, rgba(129, 202, 255, 0.18), transparent 70%);
}

.hub-hero-grid {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1.7fr) minmax(240px, 0.75fr);
  gap: 22px;
  align-items: end;
}

.hub-hero-main {
  min-width: 0;
}

.hub-home-body .hub-hero-main,
.hub-home-body .hub-hero-side {
  position: relative;
  z-index: 1;
}

.hub-hero-side {
  display: grid;
  gap: 12px;
}

.hub-hero-stat {
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(10, 28, 52, 0.26);
  border: 1px solid rgba(255, 255, 255, 0.12);
  backdrop-filter: blur(6px);
}

.hub-home-body .hub-hero-stat {
  background: rgba(120, 69, 44, 0.22);
  border-color: rgba(235, 198, 143, 0.14);
}

.hub-hero-stat strong {
  display: block;
  font-size: clamp(26px, 4vw, 34px);
  line-height: 1;
}

.hub-hero-stat span {
  display: block;
  margin-top: 6px;
  font-size: 12px;
  line-height: 1.4;
  color: rgba(255, 255, 255, 0.84);
}

.hub-home-body .hub-kicker {
  color: rgba(245, 215, 170, 0.88);
}

.hub-home-body .hub-sub {
  color: rgba(255, 241, 221, 0.88);
}

.hub-home-body .hub-hero-stat span {
  color: rgba(255, 232, 202, 0.82);
}

.hub-kicker {
  margin: 0 0 8px;
  font-size: 11px;
  letter-spacing: 0.22em;
  font-weight: 700;
  opacity: 0.82;
}

.hub-hero h1 {
  margin: 0;
  font-size: clamp(30px, 4.8vw, 52px);
  line-height: 1.04;
}

.hub-sub {
  margin: 12px 0 0;
  max-width: 860px;
  font-size: 14px;
  line-height: 1.8;
  color: rgba(255, 255, 255, 0.9);
}

.hub-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 18px;
  position: relative;
  z-index: 1;
}

.hub-forum {
  padding: 22px;
  display: grid;
  gap: 18px;
}

.forum-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 18px;
  flex-wrap: wrap;
}

.forum-head-main {
  min-width: min(100%, 680px);
}

.forum-head-copy {
  margin: 8px 0 0;
  font-size: 13px;
  line-height: 1.7;
  color: #5e6f82;
}

.forum-identity-card {
  min-width: 240px;
  padding: 14px 16px;
  border-radius: 16px;
  background: linear-gradient(135deg, #eef6ff, #f8fbff);
  border: 1px solid #d7e5f5;
  display: grid;
  gap: 6px;
}

.forum-identity-label {
  font-size: 12px;
  font-weight: 700;
  color: #6981a0;
}

.forum-identity-name {
  font-size: 22px;
  line-height: 1.2;
  color: #19385f;
}

.forum-identity-hint {
  font-size: 12px;
  color: #6b7f97;
}

.forum-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.75fr) minmax(300px, 0.85fr);
  gap: 18px;
  align-items: start;
}

.forum-main-column,
.forum-side-column {
  display: grid;
  gap: 16px;
}

.forum-compose-card,
.forum-section {
  padding: 18px;
  border-radius: 18px;
  background: #ffffff;
  border: 1px solid #dbe4ef;
  box-shadow: 0 14px 28px rgba(50, 75, 120, 0.06);
}

.forum-hot-panel {
  position: sticky;
  top: 16px;
}

.forum-compose-head,
.forum-section-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.forum-section-title {
  margin: 0;
  font-size: 18px;
  line-height: 1.25;
  color: #233548;
}

.forum-section-hint,
.forum-compose-note {
  margin: 4px 0 0;
  font-size: 12px;
  line-height: 1.6;
  color: #738299;
}

.forum-field {
  display: grid;
  gap: 8px;
  margin-top: 14px;
  font-size: 12px;
  font-weight: 700;
  color: #5a6c81;
}

.forum-textarea {
  min-height: 140px;
  resize: vertical;
}

.forum-compose-meta,
.forum-compose-actions,
.forum-thread-meta,
.forum-thread-author-row {
  display: flex;
  align-items: center;
  gap: 10px;
  flex-wrap: wrap;
}

.forum-compose-actions {
  margin-top: 14px;
  justify-content: flex-end;
}

.forum-reply-target {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 12px;
  border-radius: 999px;
  background: #edf4ff;
  color: #47688d;
  font-size: 12px;
  font-weight: 700;
}

.forum-char-count {
  font-size: 12px;
  font-weight: 700;
  color: #6b7890;
}

.forum-status {
  padding: 12px 14px;
  border-radius: 12px;
  font-size: 13px;
  line-height: 1.6;
  background: #edf7ff;
  border: 1px solid #cce0f6;
  color: #315a8f;
}

.forum-status.is-error {
  background: #fff1ef;
  border-color: #efc0bc;
  color: #9b453f;
}

.forum-thread-list,
.forum-hot-list {
  display: grid;
  gap: 14px;
}

.forum-empty {
  padding: 18px 16px;
  border-radius: 14px;
  border: 1px dashed #dbe4ef;
  background: #fbfdff;
  text-align: center;
  font-size: 13px;
  color: #6c7a8d;
}

.forum-thread-card {
  border: 1px solid #dbe4ef;
  border-radius: 16px;
  background: linear-gradient(180deg, #ffffff, #fbfdff);
  overflow: hidden;
  transition: border-color 0.18s ease, box-shadow 0.18s ease;
}

.forum-thread-card:hover {
  border-color: #c9daee;
  box-shadow: 0 16px 30px rgba(50, 75, 120, 0.08);
}

.forum-thread-card.is-flash {
  border-color: #68a8ff;
  box-shadow: 0 0 0 3px rgba(104, 168, 255, 0.16);
}

.forum-thread-head,
.forum-thread-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  padding: 16px 18px 0;
}

.forum-thread-footer {
  padding: 14px 18px 16px;
  border-top: 1px solid #edf2f7;
  margin-top: 14px;
}

.forum-thread-badge {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 10px;
  border-radius: 999px;
  background: #eef4ff;
  color: #5376a3;
  font-size: 11px;
  font-weight: 800;
  letter-spacing: 0.02em;
}

.forum-author {
  font-size: 14px;
  font-weight: 800;
  color: #243447;
}

.forum-time {
  font-size: 12px;
  color: #7b8899;
}

.forum-message-content,
.forum-reply-content,
.forum-hot-preview {
  white-space: pre-wrap;
  word-break: break-word;
  line-height: 1.8;
  color: #405064;
  font-size: 14px;
}

.forum-message-content {
  padding: 14px 18px 0;
}

.forum-reply-content {
  text-indent: 2em;
  font-size: 13px;
}

.forum-hot-item {
  width: 100%;
  padding: 14px;
  border: 1px solid #dbe4ef;
  border-radius: 14px;
  background: #f8fbff;
  text-align: left;
  display: grid;
  gap: 8px;
  cursor: pointer;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.forum-hot-item:hover {
  transform: translateY(-1px);
  border-color: #b5ccea;
  box-shadow: 0 10px 18px rgba(60, 92, 140, 0.08);
}

.forum-hot-top {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.forum-hot-score {
  font-size: 12px;
  font-weight: 800;
  color: #5576a0;
}

.forum-hot-preview {
  font-size: 13px;
  line-height: 1.7;
}

.forum-reply-btn {
  min-height: 32px;
  padding: 0 14px;
}

.forum-reply-summary {
  font-size: 12px;
  font-weight: 700;
  color: #5b6f86;
  cursor: pointer;
  list-style: none;
}

.forum-reply-summary::-webkit-details-marker {
  display: none;
}

.forum-replies {
  border-top: 1px solid #edf2f7;
  background: #f7faff;
  padding: 14px 18px 18px;
}

.forum-replies[open] {
  background: #f3f8ff;
}

.forum-replies-list {
  margin-top: 12px;
  display: grid;
  gap: 10px;
}

.forum-reply-item {
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid #dbe6f3;
  background: #fff;
}

.forum-reply-meta {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 8px;
  flex-wrap: wrap;
}

.hub-card {
  min-height: 180px;
  padding: 18px 18px;
  border-radius: 22px;
  display: grid;
  align-content: start;
  gap: 10px;
  transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease;
  color: #fff;
  position: relative;
  overflow: hidden;
}

.hub-card h2 {
  margin: 0;
  font-size: 24px;
  line-height: 1.15;
}

.hub-card p {
  margin: 0;
  font-size: 14px;
  line-height: 1.7;
}

.hub-face {
  margin-top: auto;
  display: block;
  height: 72px;
  width: calc(100% + 36px);
  margin-left: -18px;
  margin-right: -18px;
  margin-bottom: -18px;
  background-repeat: repeat-x;
  background-position: center bottom;
  background-size: auto 100%;
  background-image: url("./stlulu-1.png");
  opacity: 0.2;
  pointer-events: none;
}

.hub-face-1 { filter: none; }
.hub-face-2 { filter: hue-rotate(22deg) saturate(0.95); }
.hub-face-3 { filter: hue-rotate(-18deg) saturate(1.08); }

.hub-card:hover {
  transform: translateY(-4px);
}

.hub-home-body .hub-card {
  box-shadow: 0 18px 36px rgba(25, 10, 10, 0.24);
}

.hub-card-equipped {
  background: linear-gradient(180deg, #2d87d8, #1d5fa4);
  border: 1px solid rgba(162, 217, 255, 0.34);
  box-shadow: 0 16px 34px rgba(18, 51, 97, 0.26);
}

.hub-card-equipped:hover {
  box-shadow: 0 20px 38px rgba(18, 51, 97, 0.34);
}

.hub-home-body .hub-card-equipped {
  background: linear-gradient(180deg, #4b5d8a, #2a3554);
  border-color: rgba(196, 205, 241, 0.2);
}

.hub-card-optimizer {
  background: linear-gradient(180deg, #3aa76a, #28794c);
  border: 1px solid rgba(164, 239, 191, 0.34);
  box-shadow: 0 16px 34px rgba(24, 79, 48, 0.24);
}

.hub-card-optimizer:hover {
  box-shadow: 0 20px 38px rgba(24, 79, 48, 0.32);
}

.hub-home-body .hub-card-optimizer {
  background: linear-gradient(180deg, #3f7d60, #214734);
  border-color: rgba(186, 226, 199, 0.18);
}

.hub-card-overview {
  background:
    radial-gradient(circle at right top, rgba(198, 255, 246, 0.2), transparent 28%),
    linear-gradient(180deg, #2ea8aa, #1b6f79);
  border: 1px solid rgba(175, 241, 235, 0.34);
  box-shadow: 0 16px 34px rgba(14, 89, 98, 0.28);
}

.hub-card-overview:hover {
  box-shadow: 0 22px 42px rgba(14, 89, 98, 0.36);
}

.hub-home-body .hub-card-overview {
  background:
    radial-gradient(circle at right top, rgba(224, 255, 222, 0.16), transparent 28%),
    linear-gradient(180deg, #2c8f73, #185240);
  border-color: rgba(200, 245, 221, 0.2);
}

.hub-card-overview .hub-badge {
  background: rgba(240, 255, 251, 0.2);
  border: 1px solid rgba(214, 255, 244, 0.28);
}

.hub-card-guild {
  background: linear-gradient(180deg, #cc7d26, #91531a);
  border: 1px solid rgba(255, 216, 158, 0.34);
  box-shadow: 0 16px 34px rgba(103, 58, 16, 0.26);
}

.hub-card-guild:hover {
  box-shadow: 0 20px 38px rgba(103, 58, 16, 0.34);
}

.hub-home-body .hub-card-guild {
  background: linear-gradient(180deg, #9a6432, #5c351a);
  border-color: rgba(242, 204, 151, 0.2);
}

.hub-card-forum {
  min-height: 164px;
  grid-column: 1 / -1;
  grid-template-columns: minmax(0, 1.6fr) auto;
  align-items: end;
  gap: 18px;
  background:
    radial-gradient(circle at right top, rgba(255, 226, 156, 0.28), transparent 28%),
    linear-gradient(135deg, #f9fcff, #deecfb 55%, #d2e2f5);
  color: #20364f;
  border: 1px solid rgba(190, 214, 238, 0.9);
  box-shadow: 0 18px 38px rgba(22, 54, 92, 0.18);
}

.hub-card-forum:hover {
  box-shadow: 0 24px 46px rgba(22, 54, 92, 0.24);
}

.hub-home-body .hub-card-forum {
  background:
    radial-gradient(circle at right top, rgba(249, 222, 168, 0.34), transparent 28%),
    linear-gradient(135deg, #fff7ea, #f4e4c7 54%, #e6d0ae);
  border-color: rgba(186, 149, 92, 0.45);
  box-shadow: 0 20px 42px rgba(41, 20, 15, 0.2);
}

.hub-card-forum-meta {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 8px;
  flex-wrap: wrap;
}

.hub-mini-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 12px;
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.7);
  border: 1px solid rgba(183, 204, 228, 0.9);
  font-size: 12px;
  font-weight: 700;
  color: #466587;
}

.hub-home-body .hub-mini-pill {
  background: rgba(255, 248, 234, 0.8);
  border-color: rgba(198, 162, 108, 0.6);
  color: #6d4c27;
}

.server-overview-body {
  background:
    radial-gradient(circle at top right, rgba(139, 224, 218, 0.22), transparent 26%),
    radial-gradient(circle at 12% 12%, rgba(139, 181, 255, 0.18), transparent 24%),
    linear-gradient(180deg, #112538, #16334a 42%, #1d4861);
}

.server-overview-shell {
  width: min(1820px, calc(100vw - 28px));
  margin: 0 auto 28px;
  display: grid;
  gap: 18px;
}

.server-overview-hero,
.server-overview-board {
  padding: 22px;
}

.server-overview-hero {
  display: grid;
  gap: 18px;
  background:
    radial-gradient(circle at right top, rgba(119, 225, 208, 0.24), transparent 28%),
    radial-gradient(circle at 12% 10%, rgba(125, 191, 255, 0.18), transparent 24%),
    linear-gradient(135deg, #f8fcff, #eef8ff 52%, #e6faf6);
  border-color: #d7e8f2;
}

.server-overview-hero-main {
  display: grid;
  gap: 8px;
}

.server-overview-hero h1 {
  margin: 0;
  font-size: clamp(28px, 4vw, 42px);
  line-height: 1.08;
  color: #20364f;
}

.server-overview-copy {
  margin: 0;
  max-width: 680px;
  font-size: 13px;
  line-height: 1.6;
  color: #6d7d91;
}

.server-overview-summary {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  gap: 12px;
}

.server-overview-summary-card {
  padding: 14px 16px;
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.9);
  border: 1px solid #d6e6f0;
  box-shadow: 0 12px 24px rgba(43, 83, 120, 0.08);
  display: grid;
  gap: 6px;
}

.server-overview-summary-card span,
.server-overview-summary-card small {
  font-size: 12px;
  color: #728399;
}

.server-overview-summary-card strong {
  font-size: clamp(22px, 3vw, 30px);
  line-height: 1.05;
  color: #20364f;
}

.server-overview-toolbar {
  display: grid;
  grid-template-columns: minmax(0, 260px) auto;
  gap: 14px;
  align-items: end;
  padding: 14px;
  border-radius: 18px;
  background:
    linear-gradient(135deg, rgba(255,255,255,0.92), rgba(245, 251, 255, 0.9)),
    linear-gradient(180deg, #f6fbff, #edf7ff);
  border: 1px solid #d8e7f1;
}

.server-overview-board {
  display: grid;
  gap: 16px;
  background:
    radial-gradient(circle at right top, rgba(198, 237, 232, 0.14), transparent 28%),
    linear-gradient(180deg, rgba(250, 253, 255, 0.98), rgba(242, 248, 252, 0.96));
}

.server-overview-cards {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 16px;
}

.server-overview-card {
  padding: 18px;
  border-radius: 20px;
  background:
    radial-gradient(circle at right top, rgba(255, 215, 146, 0.34), transparent 30%),
    radial-gradient(circle at 18% 14%, rgba(255, 245, 219, 0.42), transparent 24%),
    linear-gradient(180deg, #fffaf1, #fff2dd 56%, #f6e4c4);
  border: 1px solid #e7d3a7;
  box-shadow: 0 16px 30px rgba(92, 64, 24, 0.12);
  display: grid;
  gap: 14px;
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

.server-overview-card::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 6px;
  background: var(--card-accent, #2a8e7e);
}

.server-overview-card::after {
  content: "";
  position: absolute;
  width: 130px;
  height: 130px;
  right: -28px;
  top: -32px;
  border-radius: 999px;
  background: radial-gradient(circle, rgba(214, 147, 62, 0.18), transparent 72%);
  pointer-events: none;
  z-index: 0;
}

.server-overview-card > * {
  position: relative;
  z-index: 1;
}

.server-overview-card-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 12px;
}

.server-overview-card h2 {
  margin: 0;
  font-size: 26px;
  line-height: 1.1;
  color: #20364f;
}

.server-overview-card p {
  margin: 6px 0 0;
  font-size: 12px;
  line-height: 1.6;
  color: #70839a;
}

.server-overview-pill {
  display: inline-flex;
  align-items: center;
  min-height: 30px;
  padding: 0 12px;
  border-radius: 999px;
  background: rgba(235, 249, 247, 0.9);
  border: 1px solid #d0e9e4;
  font-size: 12px;
  font-weight: 700;
  color: #225f62;
  white-space: nowrap;
}

.server-overview-metrics {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
}

.server-overview-metric,
.server-overview-stat {
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.82);
  border: 1px solid #dfeaf2;
  display: grid;
  gap: 4px;
}

.server-overview-metric span,
.server-overview-stat span {
  font-size: 11px;
  font-weight: 700;
  color: #7a8b9f;
}

.server-overview-metric strong,
.server-overview-stat strong {
  font-size: 20px;
  line-height: 1.1;
  color: #1e3855;
}

.server-overview-card-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.server-overview-foot {
  padding-top: 12px;
  border-top: 1px solid #ead9b8;
  display: grid;
  gap: 10px;
  font-size: 12px;
  color: #627589;
}

.server-overview-foot b {
  color: #20364f;
}

.server-overview-foot-label {
  font-size: 12px;
  font-weight: 700;
  color: #597188;
}

.server-overview-region-list {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  max-height: 232px;
  overflow: auto;
  padding-right: 2px;
}

.server-overview-region-chip {
  padding: 12px 14px;
  border-radius: 16px;
  background:
    linear-gradient(135deg, rgba(255,255,255,0.96), rgba(246, 251, 255, 0.92)),
    linear-gradient(180deg, #f6fbff, #eef6fb);
  border: 1px solid #d9e8f2;
  display: grid;
  gap: 3px;
}

.server-overview-region-name {
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: #68829b;
}

.server-overview-region-chip strong {
  font-size: 16px;
  line-height: 1.15;
  color: #1f3954;
}

.server-overview-region-chip small,
.server-overview-region-empty {
  font-size: 11px;
  line-height: 1.45;
  color: #6d8095;
}

.server-overview-region-empty {
  padding: 12px 14px;
  border-radius: 14px;
  background: rgba(248, 252, 255, 0.84);
  border: 1px dashed #d6e4ee;
}

.server-overview-empty {
  grid-column: 1 / -1;
}

.forum-page-shell {
  width: min(1840px, calc(100vw - 28px));
  margin: 0 auto 28px;
  display: grid;
  gap: 18px;
}

.forum-page-hero {
  padding: 24px 28px;
  background:
    linear-gradient(135deg, rgba(255,255,255,0.94), rgba(246, 250, 255, 0.92)),
    linear-gradient(180deg, #f8fbff, #eef5ff);
}

.forum-page-hero-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 16px;
  flex-wrap: wrap;
}

.forum-page-title {
  margin: 0;
  font-size: clamp(28px, 3vw, 38px);
  line-height: 1.12;
  color: #21354a;
}

.forum-page-copy {
  margin: 8px 0 0;
  max-width: 820px;
  font-size: 14px;
  line-height: 1.7;
  color: #6b7a8d;
}

.forum-page-meta {
  display: flex;
  align-items: center;
  gap: 8px;
  flex-wrap: wrap;
}

.forum-page-pill {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 0 12px;
  border-radius: 999px;
  background: #eef4fb;
  border: 1px solid #d8e4f3;
  color: #5c7392;
  font-size: 12px;
  font-weight: 700;
}

.forum-board-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.95fr) minmax(320px, 420px);
  gap: 20px;
  align-items: start;
}

.forum-board-main,
.forum-board-side {
  display: grid;
  gap: 16px;
}

.forum-board-main {
  padding: 22px;
  align-content: start;
}

.forum-board-side {
  align-content: start;
  gap: 18px;
}

.forum-board-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
  margin-bottom: 12px;
  flex-wrap: wrap;
}

.forum-board-title {
  margin: 0;
  font-size: 18px;
  line-height: 1.25;
  color: #243548;
}

.forum-board-subtle {
  margin: 4px 0 0;
  font-size: 12px;
  line-height: 1.5;
  color: #7c8a9d;
}

.forum-status-inline {
  width: 100%;
  max-width: none;
  margin: 0 0 18px;
}

.forum-thread-list-wide .forum-thread-card {
  border-radius: 14px;
}

.forum-compose-card-main {
  margin-top: 18px;
  background: linear-gradient(180deg, #ffffff, #f7fbff);
}

.forum-page-textarea {
  min-height: 176px;
}

.forum-compose-actions-stacked {
  justify-content: flex-end;
}

.admin-guild-shell {
  width: min(1600px, calc(100vw - 24px));
  margin: 0 auto;
  display: grid;
  gap: 18px;
}

.admin-guild-panel {
  display: grid;
  gap: 16px;
}

.admin-guild-note {
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid #b8d8ff;
  background: #eef7ff;
  color: #315a8f;
  font-size: 14px;
  line-height: 1.5;
}

.admin-guild-stats {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 12px;
}

.admin-stat-card {
  padding: 14px 16px;
  border-radius: 16px;
  border: 1px solid #d8e5f5;
  background: linear-gradient(180deg, #fefefe, #f3f7fb);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
  display: grid;
  gap: 8px;
}

.admin-stat-card b {
  font-size: clamp(20px, 2.6vw, 28px);
  line-height: 1.1;
}

.admin-stat-label {
  font-size: 12px;
  font-weight: 700;
  letter-spacing: 0.06em;
  color: var(--muted);
}

.admin-guild-table td {
  white-space: nowrap;
}

.hub-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: fit-content;
  min-height: 24px;
  padding: 0 9px;
  border-radius: 999px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.08em;
  background: rgba(255, 255, 255, 0.18);
  color: #fff;
}

.app-grid {
  max-width: 1180px;
  margin: 0 auto;
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr) 255px;
  gap: 18px;
  align-items: start;
}

.optimizer-grid {
  width: min(1900px, calc(100vw - 24px));
  margin: 0 auto;
  display: grid;
  grid-template-columns: 1fr;
  gap: 18px;
  align-items: start;
}

.optimizer-grid-wide {
  grid-template-columns: 1fr;
}

.fold-panel {
  padding: 0;
  overflow: hidden;
}

.fold-summary {
  list-style: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 16px 18px;
  cursor: pointer;
  border-bottom: 1px solid rgba(122, 151, 190, .12);
}

.fold-summary::-webkit-details-marker {
  display: none;
}

.fold-summary span:first-child {
  font-size: 18px;
  font-weight: 700;
  color: var(--blue);
}

.fold-hint {
  font-size: 12px;
  font-weight: 700;
  color: #6b7890;
}

.fold-body {
  padding: 14px;
  display: grid;
  gap: 14px;
}

.panel {
  background: var(--panel-bg);
  border: 2px solid var(--panel-border);
  border-radius: 12px;
  box-shadow: 0 10px 28px rgba(40, 29, 85, 0.12);
}

.metric-panel {
  padding: 16px 14px 14px;
}

.optimizer-panel {
  padding: 16px 14px 14px;
  display: grid;
  gap: 14px;
}

.panel-head {
  padding-bottom: 10px;
  border-bottom: 2px solid #d9eaf6;
  margin-bottom: 12px;
}

.panel-head h2 {
  margin: 0;
  font-size: 18px;
  color: var(--blue);
}

.profession-card {
  margin-bottom: 12px;
  padding: 10px 12px;
  border: 1px solid #d8e7f4;
  border-radius: 8px;
  background: #ffffff;
}

.profession-label {
  display: grid;
  gap: 6px;
  font-size: 13px;
  font-weight: 700;
  color: #4a5565;
}

.profession-select {
  width: 100%;
  height: 32px;
  border: 1px solid #d4d4d4;
  border-radius: 6px;
  background: #fff;
  padding: 4px 8px;
  font-size: 13px;
  color: var(--text);
}

.metric-header,
.metric-row {
  display: grid;
  grid-template-columns: minmax(96px, 1.3fr) 72px 74px 74px;
  gap: 8px;
  align-items: center;
}

.metric-header {
  padding: 6px 0 10px;
  font-size: 12px;
  font-weight: 700;
  color: #4a5565;
}

.metric-rows {
  display: grid;
  gap: 8px;
}

.metric-name {
  font-size: 13px;
  font-weight: 600;
}

.metric-input {
  width: 100%;
  height: 28px;
  border: 1px solid #d4d4d4;
  border-radius: 4px;
  background: #fff;
  padding: 4px 8px;
  font-size: 12px;
}

.metric-score,
.metric-ratio {
  height: 28px;
  border-radius: 4px;
  display: grid;
  place-items: center;
  font-size: 12px;
  font-weight: 700;
  color: #fff;
}

.metric-score { background: var(--green); }
.metric-ratio { background: var(--orange); }

.yn-toggle {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 4px;
}

.yn-btn {
  height: 28px;
  border: 1px solid #d4d4d4;
  border-radius: 4px;
  background: #fff;
  color: #556070;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.yn-btn.active {
  color: #fff;
}

.yn-btn.is-no.active {
  border-color: #d9534f;
  background: #d9534f;
}

.yn-btn.is-yes.active {
  border-color: #58b758;
  background: #58b758;
}

.panel-footer {
  margin-top: 16px;
  border-radius: 6px;
  padding: 10px 12px;
  text-align: center;
  font-size: 14px;
  line-height: 1.5;
  color: #54657f;
}

.panel-footer b {
  margin-left: 4px;
  color: #4d63a8;
}

.footer-blue { background: #cfe3f7; }
.footer-purple { background: #dfc8e8; }

.side-panel {
  padding: 14px;
  display: grid;
  gap: 14px;
}

.side-block h3 {
  margin: 0 0 8px;
  font-size: 14px;
}

.optimizer-block {
  display: grid;
  gap: 8px;
}

.optimizer-block h3 {
  margin: 0;
  font-size: 14px;
}

.element-filter-grid {
  display: grid;
  gap: 8px;
}

.element-filter-row {
  display: grid;
  grid-template-columns: 32px 1fr;
  gap: 10px;
  align-items: center;
}

.element-filter-name {
  font-size: 13px;
  font-weight: 700;
  color: #4f6075;
}

.element-filter-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.element-filter-btn {
  width: 36px;
  height: 28px;
  border: 1px solid #cfdbe8;
  border-radius: 999px;
  background: #fff;
  color: #5a6a7d;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.element-filter-btn.is-active {
  border-color: #6bb36b;
  background: #56b955;
  color: #fff;
}

.check-grid,
.radio-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 6px 10px;
}

.skills-grid {
  max-height: 246px;
  overflow: auto;
  padding-right: 2px;
}

.single-check {
  display: grid;
  gap: 6px;
}

.candidate-list {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 8px 10px;
}

.candidate-item {
  min-height: 34px;
  padding: 6px 8px;
  border-radius: 8px;
  background: #fff;
  border: 1px solid #dbe4ef;
}

.import-box {
  width: 100%;
  min-height: 110px;
  border: 1px solid #d4d4d4;
  border-radius: 8px;
  background: #fff;
  padding: 10px 12px;
  font: inherit;
  font-size: 13px;
  resize: vertical;
}

.optimizer-actions {
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: 8px;
}

.optimizer-actions-2 {
  grid-template-columns: 1fr 1fr;
}

.optimizer-actions-3 {
  grid-template-columns: 1fr 1fr 1fr;
}

.optimizer-summary {
  text-align: left;
}

.optimizer-main-panel {
  min-width: 0;
}

.optimizer-results-panel {
  grid-column: auto;
}

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

.owned-scroll-card {
  border: 1px solid #dbe4ef;
  border-radius: 12px;
  background: #fff;
  overflow: hidden;
}

.owned-scroll-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  padding: 12px 14px;
  border-bottom: 1px solid #e9eef5;
  background: #f7faff;
  font-size: 12px;
  font-weight: 700;
  color: #617186;
}

.owned-list-scroll {
  max-height: 620px;
  overflow-y: auto;
  padding: 12px;
}

.owned-sheet {
  display: grid;
  gap: 0;
}

.owned-sheet-head,
.owned-sheet-row {
  display: grid;
  grid-template-columns:
    34px
    150px
    62px
    repeat(12, minmax(54px, 1fr))
    repeat(5, minmax(42px, .8fr))
    42px;
  gap: 6px;
  align-items: center;
}

.owned-sheet-head {
  position: sticky;
  top: 0;
  z-index: 2;
  padding: 10px 0;
  background: #f7faff;
  border-bottom: 1px solid #e9eef5;
  font-size: 12px;
  font-weight: 700;
  color: #617186;
}

.owned-sheet-head span:nth-child(n+16):nth-child(-n+20) {
  background: #eef7e9;
  border-radius: 6px;
  color: #4f7352;
}

.owned-sheet-row {
  padding: 8px 0;
  border-bottom: 1px solid #eef3f8;
}

.owned-sheet-row.is-invalid {
  background: #ffe6e3;
}

.owned-sheet-row:last-child {
  border-bottom: 0;
}

.mini-danger {
  border: 0;
  border-radius: 999px;
  min-height: 28px;
  padding: 0 10px;
  background: #fce4e3;
  color: #b24843;
  font-size: 12px;
  font-weight: 700;
  cursor: pointer;
}

.owned-index {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 999px;
  background: #edf4ff;
  font-weight: 700;
  color: #4e6b92;
}

.owned-item {
  border: 1px solid #dbe4ef;
  border-radius: 12px;
  background: #fff;
  overflow: hidden;
}

.owned-summary {
  list-style: none;
  display: grid;
  grid-template-columns: 44px minmax(0, 1fr) auto auto;
  gap: 10px;
  align-items: center;
  padding: 12px 14px;
  cursor: pointer;
  background: #f7faff;
}

.owned-summary::-webkit-details-marker {
  display: none;
}

.owned-summary-skill {
  min-width: 0;
  font-size: 14px;
  font-weight: 700;
  color: #1d3557;
}

.owned-summary-meta {
  font-size: 12px;
  font-weight: 700;
  color: #617186;
}

.owned-editor {
  padding: 14px;
  display: grid;
  gap: 12px;
  border-top: 1px solid #e9eef5;
}

.owned-topline {
  display: grid;
  grid-template-columns: minmax(180px, 240px) auto auto;
  gap: 12px;
  align-items: end;
}

.owned-input {
  width: 100%;
  height: 32px;
  border: 1px solid #d4dbe5;
  border-radius: 6px;
  background: #fff;
  padding: 4px 8px;
  font-size: 12px;
  color: #243447;
}

.owned-input-sm {
  height: 30px;
  padding: 4px 6px;
  font-size: 12px;
}

.owned-input-element {
  background: #f3faef;
  border-color: #cfe3c9;
}

.owned-input-element:disabled {
  background: #eef1f5;
  border-color: #d5dce5;
  color: #7a8798;
  cursor: not-allowed;
}

.owned-skill {
  min-width: 0;
}

.owned-bool {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 4px;
  min-height: 30px;
  border: 1px solid #dbe4ef;
  border-radius: 6px;
  background: #fafcff;
  font-size: 12px;
  font-weight: 700;
  color: #5d6a7e;
}

.owned-bool input {
  width: 14px;
  height: 14px;
  margin: 0;
}

.owned-bool.is-yes {
  border-color: #9bd19b;
  background: #e8f8e8;
  color: #2f7a2f;
}

.owned-bool.is-no {
  border-color: #efb2ad;
  background: #fff0ee;
  color: #b24a43;
}

.owned-check {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  min-height: 32px;
  padding: 0 10px;
  border: 1px solid #dbe4ef;
  border-radius: 8px;
  background: #fafcff;
  white-space: nowrap;
  font-weight: 700;
}

.owned-check input {
  width: 14px;
  height: 14px;
  margin: 0;
}

.owned-attrs {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.owned-elements {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 10px;
}

.owned-field {
  display: grid;
  gap: 6px;
  font-size: 12px;
  color: #5c6b80;
}

.owned-field span {
  font-weight: 700;
}

.result-list {
  display: grid;
  gap: 10px;
}

.result-empty {
  border-radius: 10px;
  background: #fff;
  border: 1px dashed #dbe4ef;
  padding: 18px;
  font-size: 14px;
  color: #68758a;
  text-align: center;
}

.result-card {
  border-radius: 12px;
  background: #fff;
  border: 1px solid #dbe4ef;
  overflow: hidden;
}

.result-summary {
  list-style: none;
  display: grid;
  grid-template-columns: 54px minmax(0, 1fr);
  gap: 12px;
  padding: 14px;
  cursor: pointer;
}

.result-summary::-webkit-details-marker {
  display: none;
}

.result-card[open] .result-summary {
  border-bottom: 1px solid #e8eef5;
  background: #fbfdff;
}

.result-detail {
  display: grid;
  gap: 8px;
  padding: 14px;
  background: #ffffff;
}

.result-detail-title {
  font-size: 12px;
  font-weight: 700;
  color: #66758a;
}

.result-detail-row {
  display: grid;
  gap: 12px;
  padding: 10px 12px;
  border-radius: 10px;
  background: #f7faff;
  border: 1px solid #e3ebf5;
  font-size: 12px;
  color: #516175;
}

.result-detail-main {
  display: flex;
  align-items: center;
  gap: 10px;
}

.result-detail-values {
  display: grid;
  gap: 10px;
}

.result-detail-group {
  display: grid;
  gap: 6px;
}

.result-detail-label {
  font-size: 11px;
  font-weight: 700;
  color: #66758a;
}

.result-chip-list {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
}

.result-chip {
  display: inline-flex;
  align-items: center;
  min-height: 24px;
  padding: 0 8px;
  border-radius: 999px;
  background: #edf4ff;
  color: #476485;
  font-size: 11px;
  font-weight: 700;
}

.result-chip.is-empty {
  background: #eef2f6;
  color: #7a8798;
}

.element-blocks {
  display: flex;
  align-items: center;
  gap: 6px;
}

.element-block {
  width: 16px;
  height: 16px;
  border-radius: 4px;
  border: 1px solid rgba(0, 0, 0, 0.08);
}

.element-block.is-metal {
  background: #f2c319;
  border-color: #d7a90d;
}

.element-block.is-fire {
  background: #e65b4f;
}

.element-block.is-wood {
  background: #56b86a;
}

.element-block.is-water {
  background: #4a8fe7;
}

.element-block.is-earth {
  background: #8a623d;
}

.element-block.is-empty {
  background: #edf1f5;
}

.result-detail-index {
  width: 24px;
  height: 24px;
  border-radius: 999px;
  display: grid;
  place-items: center;
  background: #edf4ff;
  color: #4a6990;
  font-weight: 700;
}

.result-detail-skill {
  font-weight: 700;
  color: #243447;
}

.result-rank {
  width: 54px;
  height: 54px;
  border-radius: 12px;
  display: grid;
  place-items: center;
  background: linear-gradient(135deg, #5aaef8, #8fdf8f);
  color: #fff;
  font-weight: 800;
}

.result-main {
  display: grid;
  gap: 8px;
  min-width: 0;
}

.result-skills {
  font-size: 14px;
  font-weight: 700;
  line-height: 1.6;
}

.result-metrics {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 14px;
  font-size: 12px;
  color: #617186;
}

.result-elements {
  display: grid;
  gap: 6px;
  padding-top: 2px;
}

.result-element-row {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr);
  gap: 8px;
  align-items: center;
}

.result-element-name {
  font-size: 11px;
  font-weight: 700;
  color: #617186;
}

.result-element-blocks {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 3px;
}

.element-block-gap {
  width: 8px;
  height: 1px;
  flex: 0 0 8px;
}

.check-item {
  display: flex;
  align-items: center;
  gap: 6px;
  font-size: 13px;
}

.check-item.is-disabled {
  opacity: 0.45;
}

.check-item input {
  width: 14px;
  height: 14px;
  margin: 0;
}

.coef-box {
  border-left: 4px solid #5cc45e;
  background: #dcebdd;
  border-radius: 4px;
  padding: 8px 10px;
  font-size: 14px;
  line-height: 1.8;
  color: #3d7a41;
}

.coef-box b {
  margin-left: 3px;
  font-weight: 700;
}

.summary-box {
  background: var(--pink);
  border-radius: 6px;
  padding: 10px 12px;
  text-align: center;
  font-size: 16px;
  color: #9a4a6f;
  line-height: 1.7;
}

.summary-box b {
  margin-left: 4px;
}

.score-cards {
  display: grid;
  gap: 8px;
}

.score-cards article {
  border-radius: 6px;
  background: #ffffff;
  border: 1px solid #dae4ef;
  padding: 8px 10px;
  display: flex;
  justify-content: space-between;
  gap: 10px;
  font-size: 12px;
}

.score-cards span {
  color: var(--muted);
}

.score-cards strong {
  color: #1d3557;
}

.recommend-box {
  border-left: 3px solid #f4a12d;
  background: #fff;
  border-radius: 6px;
  border-top-left-radius: 0;
  border-bottom-left-radius: 0;
  padding: 12px;
}

.recommend-list {
  min-height: 38px;
  display: flex;
  align-items: center;
  justify-content: center;
  border-radius: 8px;
  background: #57ba55;
  color: #fff;
  font-size: 16px;
  font-weight: 800;
  letter-spacing: 0.04em;
  box-shadow: 0 8px 20px rgba(87, 186, 85, 0.2);
}

.side-actions {
  display: grid;
  gap: 8px;
}

.btn {
  border: 0;
  border-radius: 6px;
  height: 34px;
  font-size: 13px;
  font-weight: 700;
  cursor: pointer;
}

.btn-primary {
  background: #57ba55;
  color: #fff;
}

.btn-ghost {
  background: #e9eef5;
  color: #456;
}

.btn-secondary {
  background: #57ba55;
  color: #fff;
}

.nav-btn {
  display: grid;
  place-items: center;
}

.hint {
  margin: 0;
  font-size: 11px;
  line-height: 1.5;
  color: #6b7280;
}

.guild-shell {
  width: min(1900px, calc(100vw - 24px));
  margin: 0 auto;
  display: grid;
  gap: 18px;
}

.guild-app-shell {
  grid-template-columns: 220px minmax(0, 1fr);
  align-items: start;
}

.guild-side,
.guild-main {
  padding: 16px 14px 14px;
  display: grid;
  gap: 14px;
}

.guild-side-actions {
  display: grid;
  gap: 10px;
}

.guild-side-note {
  padding: 10px 12px;
  border-radius: 10px;
  background: #f8fbff;
  border: 1px dashed #cfe0f2;
  color: #5c7087;
  font-size: 12px;
  line-height: 1.6;
}

.guild-side-group {
  display: grid;
  gap: 8px;
  padding-top: 4px;
}

.guild-side-submenu {
  display: grid;
  gap: 8px;
  padding-left: 12px;
}

.guild-group-toggle {
  position: relative;
  padding-right: 26px;
}

.guild-group-toggle::after {
  content: ">";
  position: absolute;
  right: 12px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 12px;
  transition: transform 0.18s ease;
}

.guild-group-toggle.is-open::after {
  transform: translateY(-50%) rotate(90deg);
}

#guildImportTeamBtn {
  background: #57ba55;
  color: #fff;
}

.guild-tab-btn {
  justify-content: center;
}

.guild-view {
  display: grid;
  gap: 14px;
}

.guild-battle-cards {
  display: grid;
  gap: 10px;
}

.guild-battle-chip {
  width: 100%;
  border: 1px solid #dbe4ef;
  border-radius: 10px;
  background: #fff;
  padding: 12px 14px;
  display: grid;
  gap: 6px;
  text-align: left;
  font: inherit;
  color: #415165;
  cursor: pointer;
}

.guild-battle-chip.is-win {
  background: #edf8ee;
  border-color: #bfe3c3;
  color: #2f6a37;
}

.guild-battle-chip.is-lose {
  background: #fff0ef;
  border-color: #efc0bc;
  color: #8d4a46;
}

.guild-battle-chip.is-active {
  border-color: #7fb4f3;
  box-shadow: inset 0 0 0 1px #b8d8ff;
}

.guild-battle-detail {
  margin-top: 6px;
  border-top: 1px solid rgba(255, 255, 255, 0.5);
  padding-top: 10px;
}

.guild-battle-actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.guild-battle-delete {
  border: 0;
  border-radius: 999px;
  padding: 4px 10px;
  font-size: 11px;
  font-weight: 700;
  cursor: pointer;
  background: rgba(255, 255, 255, 0.78);
  color: #5d6572;
}

.guild-auth,
.guild-dashboard {
  padding: 16px 14px 14px;
  display: grid;
  gap: 14px;
}

.guild-form-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 12px;
}

.guild-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.guild-note {
  padding: 10px 12px;
  border-radius: 8px;
  background: #fff6e9;
  border: 1px solid #f0d6a8;
  color: #8a6332;
  font-size: 12px;
  line-height: 1.6;
}

.guild-battle-card {
  padding: 14px;
  border-radius: 12px;
  border: 1px solid #dbe4ef;
  background: #fff;
  display: grid;
  gap: 12px;
}

.guild-battle-title {
  font-size: 18px;
  font-weight: 800;
  color: #1f5e95;
}

.guild-battle-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) 56px minmax(0, 1fr);
  gap: 12px;
  align-items: center;
}

.guild-battle-team {
  display: grid;
  gap: 10px;
  padding: 12px;
  border-radius: 10px;
  background: #f7faff;
  border: 1px solid #e5edf7;
}

.guild-battle-name {
  font-size: 16px;
  font-weight: 800;
  color: #33485f;
}

.guild-battle-versus {
  display: grid;
  place-items: center;
  height: 48px;
  border-radius: 999px;
  background: #edf4ff;
  color: #4b6990;
  font-size: 14px;
  font-weight: 800;
}

.guild-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 8px 16px;
  font-size: 13px;
  color: #556477;
}

.guild-csv-head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
}

.guild-table-wrap {
  border: 1px solid #dbe4ef;
  border-radius: 10px;
  background: #fff;
  overflow: auto;
  max-height: 520px;
}

.guild-table {
  width: 100%;
  border-collapse: collapse;
  min-width: 760px;
}

.guild-table th,
.guild-table td {
  padding: 10px 12px;
  border-bottom: 1px solid #e8eef5;
  text-align: left;
  font-size: 12px;
  color: #405064;
  white-space: nowrap;
}

.guild-row-missing-team td {
  background: #fff1f0;
}

.guild-team-inline-select {
  width: 100%;
  min-width: 88px;
  border: 1px solid #cfd9e5;
  border-radius: 6px;
  padding: 6px 8px;
  background: #fff;
  color: #33485f;
}

.guild-overview-toolbar {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 12px;
}

.guild-export-toolbar {
  grid-template-columns: repeat(5, minmax(0, 1fr));
  margin-bottom: 12px;
}

.guild-overview-layout {
  display: grid;
  grid-template-columns: 260px minmax(0, 1fr);
  gap: 14px;
}

.guild-overview-fields {
  border: 1px solid #dbe4ef;
  border-radius: 12px;
  background: #fff;
  padding: 14px;
  display: grid;
  gap: 10px;
  align-content: start;
  max-height: 520px;
  overflow: auto;
}

.guild-field-check {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: #405064;
}

.guild-overview-chart-panel {
  position: relative;
}

.guild-overview-chart-wrap {
  position: relative;
  border: 1px solid rgba(180, 202, 230, 0.52);
  border-radius: 18px;
  background:
    radial-gradient(circle at top right, rgba(141, 198, 255, 0.22), transparent 34%),
    radial-gradient(circle at 18% 18%, rgba(89, 159, 255, 0.12), transparent 28%),
    linear-gradient(145deg, #f7fbff 0%, #eef5ff 52%, #f9fcff 100%);
  padding: 12px;
  min-height: 440px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.8), 0 18px 40px rgba(93, 126, 170, 0.14);
  overflow: hidden;
}

.guild-overview-chart {
  width: 100%;
  height: 420px;
  display: block;
  filter: saturate(1.03);
}

.guild-chart-tooltip {
  position: fixed;
  z-index: 2;
  padding: 10px 12px;
  border-radius: 12px;
  background: rgba(18, 29, 46, 0.9);
  border: 1px solid rgba(141, 189, 255, 0.28);
  color: #f7fbff;
  font-size: 11.5px;
  font-weight: 700;
  pointer-events: none;
  white-space: nowrap;
  box-shadow: 0 14px 28px rgba(9, 18, 32, 0.26);
  backdrop-filter: blur(10px);
}

.guild-player-head {
  display: grid;
  gap: 12px;
}

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

.guild-ranking-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 14px;
}

.guild-ranking-card {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid #dbe4ef;
  border-radius: 14px;
  background: #ffffff;
}

.guild-rate-note {
  margin: 12px 0;
}

.guild-transform-note {
  margin-bottom: 12px;
}

.guild-transform-rate-up,
.guild-transform-rate-down,
.guild-transform-rate-flat,
.guild-transform-rate-na {
  font-weight: 700;
}

.guild-transform-rate-up {
  color: #1f8b4c;
}

.guild-transform-rate-down {
  color: #c75146;
}

.guild-transform-rate-flat {
  color: #4f6b8a;
}

.guild-transform-rate-na {
  color: #8a97a8;
}

.guild-player-card {
  border: 1px solid #dbe4ef;
  border-radius: 14px;
  background: #eef5fb;
  overflow: hidden;
  transition: border-color 0.18s ease, background-color 0.18s ease, box-shadow 0.18s ease;
}

.guild-player-summary {
  display: grid;
  grid-template-columns: minmax(160px, 1.2fr) minmax(160px, 1fr) 90px;
  gap: 12px;
  align-items: center;
  padding: 14px 16px;
  cursor: pointer;
  list-style: none;
  font-size: 13px;
  color: #31465f;
  background: #dfeaf7;
}

.guild-suwen-summary {
  grid-template-columns: minmax(160px, 1.2fr) minmax(180px, 1fr) minmax(180px, 1fr);
}

.guild-suwen-summary-stats {
  grid-column: 1 / -1;
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.guild-suwen-stat-chip {
  display: inline-flex;
  align-items: center;
  min-height: 28px;
  padding: 4px 10px;
  border-radius: 999px;
  border: 1px solid #c9dbef;
  background: #f7fbff;
  color: #3a5068;
  font-size: 12px;
  font-weight: 700;
}

.guild-suwen-score-chip {
  border-color: #a9c3e6;
  background: #eaf4ff;
  color: #244566;
}

.guild-player-summary::-webkit-details-marker {
  display: none;
}

.guild-player-card[open] .guild-player-summary {
  border-bottom: 1px solid #e8eef6;
  background: #c7dcf4;
}

.guild-player-card[open] {
  border-color: #92b7e0;
  background: #dfeefe;
  box-shadow: 0 10px 24px rgba(76, 116, 160, 0.12);
}

.guild-player-name {
  font-size: 15px;
  font-weight: 700;
  color: #223248;
}

.guild-player-meta {
  color: #627287;
}

.guild-player-body {
  padding: 14px 16px 16px;
  background: #ffffff;
}

.guild-player-filters {
  display: grid;
  gap: 12px;
  margin-bottom: 14px;
}

.guild-player-filter-row {
  display: grid;
  gap: 8px;
}

.guild-player-filter-label {
  font-size: 12px;
  font-weight: 700;
  color: #5b6b7d;
}

.guild-player-filter-chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.guild-player-chip {
  min-width: 72px;
}

.guild-player-field-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 8px 10px;
  padding: 12px;
  border: 1px solid #e5edf5;
  border-radius: 12px;
  background: #f8fbff;
}

.guild-player-chart-wrap {
  border: 1px solid rgba(180, 202, 230, 0.52);
  border-radius: 18px;
  background:
    radial-gradient(circle at top right, rgba(141, 198, 255, 0.2), transparent 34%),
    linear-gradient(145deg, #f7fbff 0%, #eef5ff 52%, #f9fcff 100%);
  padding: 12px;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.8), 0 16px 32px rgba(93, 126, 170, 0.12);
  overflow: hidden;
}

.guild-player-chart {
  width: 100%;
  height: 420px;
  display: block;
}

.guild-suwen-sections {
  display: grid;
  gap: 12px;
}

.guild-suwen-total-table {
  min-width: 320px;
}

.guild-table th {
  position: sticky;
  top: 0;
  background: #f7faff;
  font-weight: 700;
}

.guild-empty {
  padding: 20px 16px;
  border: 1px dashed #dbe4ef;
  border-radius: 10px;
  background: #fff;
  text-align: center;
  font-size: 13px;
  color: #6c7a8d;
}

@media (max-width: 1024px) {
  .admin-guild-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .app-grid {
    grid-template-columns: 1fr;
  }

  .optimizer-grid {
    grid-template-columns: 1fr;
  }

  .optimizer-grid-wide {
    grid-template-columns: 1fr;
  }

  .top-nav,
  .optimizer-grid {
    width: calc(100vw - 20px);
  }

  .hub-grid {
    grid-template-columns: 1fr;
  }

  .hub-hero-grid,
  .hub-card-forum {
    grid-template-columns: 1fr;
  }

  .server-overview-summary,
  .server-overview-cards,
  .server-overview-region-list {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .server-overview-toolbar {
    grid-template-columns: 1fr;
  }

  .hub-card-forum-meta {
    justify-content: flex-start;
  }

  .forum-layout,
  .forum-board-layout {
    grid-template-columns: 1fr;
  }

  .forum-hot-panel {
    position: static;
  }

  .forum-compose-head,
  .forum-section-head {
    align-items: flex-start;
  }

  .forum-compose-actions {
    width: 100%;
    justify-content: flex-start;
  }

  .hub-card-forum {
    grid-column: auto;
  }

  .guild-form-grid {
    grid-template-columns: 1fr;
  }

  .guild-app-shell {
    grid-template-columns: 1fr;
  }

  .guild-battle-grid {
    grid-template-columns: 1fr;
  }

  .guild-overview-toolbar,
  .guild-overview-layout,
  .guild-ranking-grid {
    grid-template-columns: 1fr;
  }

  .guild-player-summary {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .guild-player-field-grid {
    grid-template-columns: 1fr;
  }

  .check-grid,
  .radio-grid {
    grid-template-columns: 1fr 1fr 1fr;
  }

  .candidate-list,
  .optimizer-actions {
    grid-template-columns: 1fr 1fr;
  }

  .element-filter-row {
    grid-template-columns: 28px 1fr;
    gap: 8px;
  }

  .owned-sheet-head,
  .owned-sheet-row {
    grid-template-columns:
      30px
      130px
      56px
      repeat(12, minmax(48px, 1fr))
      repeat(5, minmax(40px, .7fr))
      40px;
    gap: 4px;
  }

  .owned-attrs {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .owned-elements {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .result-detail-row {
    gap: 8px;
  }

}

@media (max-width: 720px) {
  .admin-guild-stats {
    grid-template-columns: 1fr;
  }

  .page-shell {
    padding: 10px;
  }

  .top-nav {
    flex-direction: column;
    align-items: flex-start;
  }

  .hub-shell,
  .server-overview-shell,
  .forum-page-shell,
  .top-nav {
    width: calc(100vw - 16px);
  }

  .hub-hero {
    padding: 18px;
    border-radius: 18px;
  }

  .hub-hero-side {
    grid-template-columns: 1fr;
  }

  .hub-forum {
    padding: 16px;
  }

  .forum-page-hero,
  .forum-board-main {
    padding: 14px;
  }

  .forum-status-inline {
    margin-bottom: 14px;
  }

  .forum-compose-card-main {
    margin-top: 14px;
  }

  .forum-head,
  .forum-page-hero-head,
  .forum-board-head,
  .forum-thread-head,
  .forum-thread-footer {
    flex-direction: column;
    align-items: flex-start;
  }

  .forum-compose-card,
  .forum-section {
    padding: 14px;
  }

  .forum-compose-meta,
  .forum-thread-meta,
  .forum-thread-author-row,
  .hub-card-forum-meta {
    flex-direction: column;
    align-items: flex-start;
  }

  .metric-header,
  .metric-row {
    grid-template-columns: minmax(92px, 1.2fr) 68px 68px 68px;
    gap: 6px;
  }

  .check-grid,
  .radio-grid {
    grid-template-columns: 1fr 1fr;
  }

  .candidate-list,
  .optimizer-actions {
    grid-template-columns: 1fr;
  }

  .guild-shell,
  .top-nav {
    width: calc(100vw - 12px);
  }

  .top-nav,
  .optimizer-grid {
    width: calc(100vw - 12px);
  }

  .forum-compose-actions {
    flex-direction: column;
    align-items: stretch;
  }

  .forum-compose-actions .btn,
  .forum-reply-btn {
    width: 100%;
  }

  .server-overview-hero,
  .server-overview-board,
  .server-overview-card {
    padding: 14px;
  }

  .server-overview-summary,
  .server-overview-cards,
  .server-overview-metrics,
  .server-overview-region-list {
    grid-template-columns: 1fr;
  }

  .server-overview-card-head {
    flex-direction: column;
    align-items: flex-start;
  }

  .hub-card {
    min-height: 0;
  }

  .result-summary {
    grid-template-columns: 1fr;
  }

  .result-rank {
    width: 44px;
    height: 44px;
  }

  .result-detail-row {
    grid-template-columns: 1fr;
    gap: 6px;
  }

  .result-detail-main {
    align-items: flex-start;
  }

  .result-element-row {
    grid-template-columns: 1fr;
    gap: 4px;
  }

}
