body.hop-profile-page {
  margin: 0;
  min-height: 100vh;
  color: var(--text, #d8dce8);
  font-family: Inter, system-ui, sans-serif;
}

.hp-wrap {
  position: relative;
  z-index: 1;
  max-width: 1440px;
  margin: 0 auto;
  padding: 20px 16px 48px;
}

.hp-hero {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 20px;
  padding: 16px 18px;
  background: var(--panel, #161b24);
  border: 1px solid var(--border, #2b3443);
  border-radius: 12px;
}

.hp-invite-btn {
  flex-shrink: 0;
  margin-left: auto;
  width: 44px;
  height: 44px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border-radius: 12px;
  border: 1px solid rgba(48, 232, 160, 0.35);
  background: rgba(48, 232, 160, 0.1);
  color: #30e8a0;
  cursor: pointer;
  padding: 0;
  transition: background 0.2s, border-color 0.2s, transform 0.15s;
}

.hp-invite-btn:hover {
  background: rgba(48, 232, 160, 0.18);
  border-color: rgba(48, 232, 160, 0.55);
}

.hp-invite-btn:active {
  transform: scale(0.96);
}

.hp-invite-btn__icon {
  width: 22px;
  height: 22px;
}

.hp-toast {
  position: fixed;
  left: 50%;
  bottom: 24px;
  transform: translateX(-50%);
  z-index: 200;
  padding: 10px 16px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
  color: #d8fce8;
  background: rgba(22, 40, 32, 0.95);
  border: 1px solid rgba(48, 232, 160, 0.35);
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.35);
  pointer-events: none;
}

.hp-toast.show {
  display: block;
}

.hp-toast[hidden] {
  display: none;
}

.hp-hero__avatar {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  background: var(--surface, #12141c);
  border: 2px solid rgba(240, 160, 48, 0.35);
  flex-shrink: 0;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 28px;
  font-weight: 800;
  color: var(--muted, #7b8597);
}

.hp-hero__avatar img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.hp-hero__text h1 {
  margin: 0 0 4px;
  font-size: 22px;
  font-weight: 800;
  line-height: 1.2;
}

.hp-hero__sub {
  margin: 0;
  font-size: 13px;
  color: var(--muted, #7b8597);
  line-height: 1.5;
}

.hp-hop-row {
  display: flex;
  align-items: baseline;
  gap: 8px;
  flex-wrap: wrap;
}

.hp-hop-delta {
  font-size: 12px;
  font-weight: 600;
  font-variant-numeric: tabular-nums;
  color: var(--muted, #7b8597);
}

.hp-hop-delta.mint { color: #30e8a0; }
.hp-hop-delta.red { color: #f04848; }

.hp-banner {
  display: none;
  padding: 10px 14px;
  border-radius: 8px;
  font-size: 13px;
  margin-bottom: 14px;
  background: rgba(240, 160, 48, 0.12);
  border: 1px solid rgba(240, 160, 48, 0.35);
  color: #f0c878;
}

.hp-banner.show { display: block; }

.hp-layout {
  display: grid;
  grid-template-columns: 200px minmax(0, 1fr) 272px;
  gap: 16px;
  align-items: start;
}

.hp-sidebar-left,
.hp-sidebar-right {
  position: sticky;
  top: calc(var(--home-header-h, 64px) + 16px);
}

.hp-sidebar-left .hp-card {
  margin-bottom: 10px;
}

.hp-sidebar-left .hp-card:last-child {
  margin-bottom: 0;
}

.hp-sidebar-left .hp-card .val {
  font-size: 28px;
}

.hp-sidebar-left .hp-card--hop .val {
  font-size: 32px;
}

.hp-sidebar-right .hp-section-title {
  margin-top: 0;
}

.hp-sidebar-right .hp-table {
  font-size: 12px;
  display: block;
  overflow-x: auto;
}

.hp-sidebar-right .hp-table thead {
  display: block;
}

.hp-sidebar-right .hp-table tbody {
  display: block;
  max-height: 440px;
  overflow-y: auto;
  overscroll-behavior: contain;
  scrollbar-width: thin;
  scrollbar-color: rgba(255, 255, 255, 0.2) transparent;
}

.hp-sidebar-right .hp-table tbody::-webkit-scrollbar {
  width: 6px;
}

.hp-sidebar-right .hp-table tbody::-webkit-scrollbar-thumb {
  background: rgba(255, 255, 255, 0.18);
  border-radius: 3px;
}

.hp-sidebar-right .hp-table tr {
  display: grid;
  grid-template-columns: 1fr auto auto;
  gap: 4px 8px;
  align-items: center;
  border-bottom: 1px solid var(--border, #2b3443);
  padding: 8px 10px;
}

.hp-sidebar-right .hp-table thead tr {
  padding: 6px 10px;
  background: var(--surface, #12141c);
}

.hp-sidebar-right .hp-table tbody tr:last-child {
  border-bottom: none;
}

.hp-sidebar-right .hp-table th,
.hp-sidebar-right .hp-table td {
  padding: 0;
  border: none;
  display: block;
}

.hp-sidebar-right .hp-table th.num,
.hp-sidebar-right .hp-table td.num {
  text-align: right;
}

.hp-sidebar-right .hp-history-map {
  font-weight: 600;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.hp-sidebar-right .hp-history-date {
  font-size: 10px;
  color: var(--muted, #7b8597);
  margin-top: 2px;
}

.hp-sidebar-right .hp-history-score {
  font-size: 11px;
  color: var(--muted, #7b8597);
  text-align: right;
}

.hp-sidebar-right .hp-table tr.hp-history-empty {
  display: block;
  padding: 12px 10px;
}

.hp-sidebar-right .hp-table tr.hp-history-empty td {
  display: block;
  text-align: center;
}

.hp-match-breakdown-box {
  overflow-x: auto;
}

.hp-main {
  min-width: 0;
}

.hp-card {
  background: var(--panel, #161b24);
  border: 1px solid var(--border, #2b3443);
  border-radius: 10px;
  padding: 14px 16px;
}

.hp-card--hop {
  border-color: rgba(240, 160, 48, 0.45);
}

.hp-card .val {
  font-size: 24px;
  font-weight: 800;
  line-height: 1.1;
  font-variant-numeric: tabular-nums;
}

.hp-card .val.mint { color: #30e8a0; }
.hp-card .val.orange { color: #f0a030; }
.hp-card .val.red { color: #f04848; }

.hp-card .lbl {
  font-size: 11px;
  color: var(--muted, #7b8597);
  margin-top: 4px;
}

.hp-section-title {
  font-size: 14px;
  font-weight: 700;
  margin: 22px 0 10px;
}

.hp-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 13px;
  background: var(--panel, #161b24);
  border: 1px solid var(--border, #2b3443);
  border-radius: 10px;
  overflow: hidden;
}

.hp-table th,
.hp-table td {
  padding: 8px 12px;
  border-bottom: 1px solid var(--border, #2b3443);
  vertical-align: middle;
}

.hp-table th {
  font-size: 11px;
  color: var(--muted, #7b8597);
  font-weight: 700;
  background: var(--surface, #12141c);
  text-align: left;
}

.hp-table th.num { text-align: right; }
.hp-table td { text-align: left; }
.hp-table tr:last-child td { border-bottom: none; }
.hp-table td.num { text-align: right; font-variant-numeric: tabular-nums; }

.hp-empty {
  font-size: 13px;
  color: var(--muted, #7b8597);
  padding: 12px 0;
}

.hp-tag {
  display: inline-block;
  font-size: 10px;
  font-weight: 700;
  padding: 2px 6px;
  border-radius: 4px;
  text-transform: uppercase;
}

.hp-tag.completed { background: rgba(48, 232, 160, 0.15); color: #30e8a0; }
.hp-tag.abandoned { background: rgba(240, 72, 72, 0.15); color: #f04848; }

.hp-match-breakdown-box {
  display: none;
  background: var(--panel, #161b24);
  border: 1px solid var(--border, #2b3443);
  border-radius: 10px;
  padding: 14px 16px;
  margin-bottom: 18px;
  font-size: 13px;
  line-height: 1.55;
}

.hp-match-breakdown-box.show { display: block; }

.hp-match-breakdown-box h3 {
  margin: 0 0 8px;
  font-size: 14px;
  font-weight: 700;
}

.hp-match-breakdown-box .hint {
  color: var(--muted, #7b8597);
  font-size: 12px;
  margin-top: 8px;
}

.hp-match-breakdown-meta {
  font-size: 12px;
  color: var(--muted, #7b8597);
  margin-bottom: 10px;
}

.hp-breakdown-table td.num,
.hp-breakdown-table th.num {
  text-align: right;
  font-variant-numeric: tabular-nums;
}

.hp-breakdown-table th { white-space: nowrap; }
.hp-breakdown-table .mint { color: #30e8a0; }
.hp-breakdown-table .red { color: #f04848; }

.hp-table tbody tr.hp-history-row { cursor: pointer; }
.hp-table tbody tr.hp-history-row:hover { background: rgba(255, 255, 255, 0.03); }
.hp-table tbody tr.hp-history-row.selected { background: rgba(240, 160, 48, 0.08); }

.hp-placeholder {
  background: var(--panel, #161b24);
  border: 1px solid var(--border, #2b3443);
  border-radius: 10px;
  padding: 24px 16px;
  text-align: center;
  color: var(--muted, #7b8597);
  font-size: 13px;
}

@media (max-width: 1100px) {
  .hp-layout {
    grid-template-columns: 1fr;
  }

  .hp-sidebar-left,
  .hp-sidebar-right {
    position: static;
  }

  .hp-sidebar-left {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 10px;
  }

  .hp-sidebar-left .hp-card {
    margin-bottom: 0;
  }

  .hp-sidebar-left .hp-card .val {
    font-size: 22px;
  }

  .hp-sidebar-left .hp-card--hop .val {
    font-size: 26px;
  }
}

@media (max-width: 600px) {
  .hp-sidebar-left {
    grid-template-columns: repeat(2, 1fr);
  }

  .hp-hero {
    flex-direction: column;
    text-align: center;
  }

  .hp-invite-btn {
    margin-left: 0;
  }
}
