.soul-shop-shell {
  min-height: max(560px, calc(100vh - 390px));
  padding: 30px;
  border: 2px solid rgba(0, 204, 204, 0.55);
  border-radius: 15px;
  background: rgba(7, 10, 11, 0.86);
  box-shadow: 0 0 18px rgba(0, 255, 255, 0.14);
  overflow: hidden;
  text-align: left;
}

.soul-shop-shell [hidden] { display: none !important; }

.soul-shop-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 32px;
  margin-bottom: 14px;
  position: relative;
}

.soul-shop-nav .back-link { margin: 0; }

.soul-guide-link {
  position: absolute;
  right: 0;
  padding: 6px 10px;
  border: 1px solid rgba(0, 204, 204, 0.48);
  border-radius: 5px;
  background: rgba(0, 204, 204, 0.08);
  color: #aeeaea;
  font-size: 0.7rem;
  font-weight: 700;
  text-decoration: none;
}

.soul-guide-link:hover,
.soul-guide-link:focus-visible {
  border-color: #00ffff;
  background: rgba(0, 204, 204, 0.18);
  color: #fff;
  outline: none;
}

.soul-shop-shell .top-button {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 6px 10px;
  border: 1px solid rgba(0, 204, 204, 0.62);
  border-radius: 5px;
  background: rgba(0, 204, 204, 0.12);
  color: #bff7f7;
  font: inherit;
  font-size: 0.74rem;
  text-decoration: none;
}

.soul-shop-shell .top-button:hover,
.soul-shop-shell .top-button:focus-visible {
  border-color: #00ffff;
  background: rgba(0, 204, 204, 0.22);
  color: #fff;
}

.soul-shop-shell .top-button:disabled {
  opacity: 0.48;
}

.soul-account-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 28px;
  padding: 18px 20px;
  border-bottom: 1px solid rgba(0, 204, 204, 0.42);
  background: rgba(4, 13, 14, 0.62);
}

.soul-intro h2,
.soul-section-head h2 {
  margin: 2px 0 0;
  color: #f0f0f0;
  font-size: 1.35rem;
}

.soul-intro p:last-child,
.soul-login-area p,
.soul-section-head > p,
.soul-email-notice p {
  margin: 4px 0 0;
  color: #aebfc2;
  font-size: 0.88rem;
}

.soul-kicker,
.soul-stat span {
  margin: 0;
  color: #00cccc;
  font-size: 0.68rem;
  letter-spacing: 0.13em;
  text-transform: uppercase;
}

.soul-login-area {
  min-width: 245px;
  text-align: right;
}

.soul-login-area strong {
  display: block;
  color: #00dddd;
  font-size: 0.95rem;
}

.soul-steam-id {
  display: block;
  margin-top: 3px;
  color: #789294;
  font-size: 0.66rem;
  letter-spacing: 0.04em;
}

.soul-login-button,
.soul-logout-button { margin-top: 8px; }

.soul-login-button {
  display: inline-flex;
  border-radius: 4px;
  line-height: 0;
  transition: filter 0.18s ease, transform 0.18s ease;
}

.soul-login-button:hover,
.soul-login-button:focus-visible {
  filter: brightness(1.15);
  transform: translateY(-1px);
}

.soul-login-button:focus-visible {
  outline: 2px solid #00ffff;
  outline-offset: 4px;
}

.soul-login-button img { display: block; }

.soul-status {
  margin: 12px 0;
  padding: 8px 12px;
  border-left: 3px solid #00cccc;
  background: rgba(0, 204, 204, 0.08);
  color: #b8d8d8;
  font-size: 0.78rem;
}

.soul-summary {
  display: grid;
  grid-template-columns: 1.05fr 1fr 1.35fr;
  margin-bottom: 14px;
  border: 1px solid rgba(0, 204, 204, 0.32);
  background: rgba(4, 8, 9, 0.72);
}

.soul-stat {
  min-width: 0;
  padding: 11px 15px;
  border-right: 1px solid rgba(0, 204, 204, 0.22);
}

.soul-stat:last-child { border-right: 0; }

.soul-stat strong {
  display: block;
  margin-top: 2px;
  color: #e4e8e8;
  font-size: 1rem;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.soul-stat-primary strong {
  color: #00ffff;
  font-size: 1.25rem;
}

.soul-email-notice {
  display: grid;
  grid-template-columns: minmax(180px, 0.7fr) minmax(360px, 1.3fr);
  align-items: center;
  gap: 20px;
  margin-bottom: 18px;
  padding: 12px 15px;
  border: 1px solid rgba(223, 177, 70, 0.46);
  border-radius: 7px;
  background: rgba(61, 42, 7, 0.34);
}

.soul-email-notice.is-verified {
  border-color: rgba(94, 214, 164, 0.42);
  background: rgba(8, 53, 38, 0.32);
}

.soul-email-notice strong { color: #f0f0f0; }
.soul-email-form label,
.soul-email-form small { display: block; }

.soul-email-form label {
  margin-bottom: 5px;
  color: #d5e3e3;
  font-size: 0.78rem;
}

.soul-email-form small {
  margin-top: 5px;
  color: #aebfc2;
  font-size: 0.72rem;
}

.soul-inline-form { display: flex; gap: 8px; }

.soul-inline-form input {
  flex: 1;
  min-width: 0;
  padding: 7px 9px;
  border: 1px solid rgba(0, 204, 204, 0.65);
  border-radius: 5px;
  background: #080808;
  color: #e0e0e0;
}

.soul-catalog-section { padding-top: 5px; }

.soul-section-head {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 20px;
  padding: 0 2px 10px;
  border-bottom: 1px solid rgba(0, 204, 204, 0.35);
}

.soul-section-head > p { max-width: 480px; text-align: right; }

.soul-catalog-tools {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 16px;
  margin-top: 12px;
}

.soul-catalog-tools label,
.soul-catalog-sort > span {
  display: block;
  margin-bottom: 5px;
  color: #8fb9bc;
  font-size: 0.7rem;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.soul-catalog-search {
  flex: 1;
  max-width: 420px;
}

.soul-catalog-search input {
  box-sizing: border-box;
  width: min(360px, 100%);
  padding: 7px 9px;
  border: 1px solid rgba(0, 204, 204, 0.42);
  border-radius: 5px;
  background: rgba(3, 8, 9, 0.82);
  color: #e2eeee;
  font: inherit;
  font-size: 0.76rem;
}

.soul-catalog-sort {
  width: min(250px, 100%);
}

.soul-shop-select {
  position: relative;
}

.soul-shop-select__button {
  display: inline-flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  width: 100%;
  padding: 7px 9px;
  border: 1px solid rgba(0, 204, 204, 0.42);
  border-radius: 5px;
  background: rgba(3, 8, 9, 0.82);
  color: #e2eeee;
  font: inherit;
  font-size: 0.76rem;
  line-height: 1.25;
  text-align: left;
}

.soul-shop-select__button:focus-visible {
  border-color: #00ffff;
  outline: none;
  box-shadow: 0 0 10px rgba(0, 255, 255, 0.2);
}

.soul-shop-select__caret {
  flex: 0 0 auto;
  color: rgba(0, 204, 204, 0.82);
  font-size: 0.76em;
}

.soul-shop-select__menu {
  position: absolute;
  z-index: 30;
  top: calc(100% + 6px);
  right: 0;
  min-width: 100%;
  max-height: min(52vh, 300px);
  overflow-y: auto;
  padding: 6px;
  border: 1px solid rgba(0, 204, 204, 0.55);
  border-radius: 8px;
  background: rgba(8, 8, 8, 0.98);
  box-shadow: 0 14px 30px rgba(0, 0, 0, 0.46);
}

.soul-shop-select__menu[hidden] { display: none; }

.soul-shop-select__option {
  display: block;
  width: 100%;
  padding: 10px 12px;
  border: 0;
  border-radius: 6px;
  background: transparent;
  color: #e0e0e0;
  font: inherit;
  font-size: 0.76rem;
  line-height: 1.25;
  text-align: left;
  white-space: nowrap;
}

.soul-shop-select__option:hover,
.soul-shop-select__option:focus-visible,
.soul-shop-select__option[aria-selected="true"] {
  background: rgba(0, 204, 204, 0.16);
  color: #fff;
}

.soul-shop-select__option:focus-visible {
  outline: 1px solid rgba(0, 255, 255, 0.7);
  outline-offset: 1px;
}

.soul-catalog {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(290px, 1fr));
  gap: 16px;
  margin-top: 16px;
}

.soul-game-card {
  display: flex;
  min-width: 0;
  overflow: hidden;
  border: 1px solid rgba(0, 204, 204, 0.28);
  border-radius: 9px;
  background: linear-gradient(180deg, rgba(9, 18, 20, 0.96), rgba(4, 8, 9, 0.96));
  box-shadow: 0 8px 20px rgba(0, 0, 0, 0.18);
  flex-direction: column;
  transition: transform 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.soul-game-card:hover {
  transform: translateY(-2px);
  border-color: rgba(0, 255, 255, 0.52);
  box-shadow: 0 12px 28px rgba(0, 0, 0, 0.28), 0 0 14px rgba(0, 204, 204, 0.1);
}

.soul-game-art {
  display: flex;
  aspect-ratio: 460 / 215;
  overflow: hidden;
  background: radial-gradient(circle at center, rgba(0, 204, 204, 0.14), rgba(2, 7, 8, 0.96));
  color: #769597;
  align-items: center;
  justify-content: center;
  font-size: 0.68rem;
  text-decoration: none;
}

.soul-game-art img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.25s ease, filter 0.25s ease;
}

.soul-game-card:hover .soul-game-art img {
  transform: scale(1.025);
  filter: brightness(1.06);
}

.soul-game-art.is-missing::after {
  content: "Steam artwork unavailable";
}

.soul-game-body {
  display: flex;
  flex: 1;
  flex-direction: column;
  padding: 13px;
}

.soul-game-card h3 {
  margin: 0;
  color: #00cccc;
  font-size: 1rem;
  line-height: 1.3;
}

.soul-game-card h3 a { color: inherit; }

.soul-game-description {
  display: -webkit-box;
  min-height: 4.35em;
  margin: 9px 0 10px;
  overflow: hidden;
  color: #a9bdc1;
  font-size: 0.74rem;
  line-height: 1.45;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
}

.soul-game-description.is-muted { color: #71878b; }

.soul-game-note {
  margin: 0 0 10px;
  padding: 6px 8px;
  border-left: 2px solid rgba(223, 177, 70, 0.58);
  background: rgba(61, 42, 7, 0.25);
  color: #c9b98f;
  font-size: 0.7rem;
}

.soul-game-footer {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 10px;
  margin-top: auto;
  padding-top: 10px;
  border-top: 1px solid rgba(0, 204, 204, 0.15);
}

.soul-game-price strong,
.soul-game-price span { display: block; }
.soul-game-price strong { color: #e5eeee; font-size: 0.88rem; }
.soul-game-price span { margin-top: 2px; color: #8da4a8; font-size: 0.67rem; }

.soul-steam-link {
  color: #7edede;
  font-size: 0.68rem;
  white-space: nowrap;
}

.soul-game-card button { width: 100%; margin-top: 10px; }

.soul-history-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 10px;
  margin-top: 20px;
}

.soul-history-panel {
  border-top: 1px solid rgba(0, 204, 204, 0.38);
  background: rgba(5, 9, 10, 0.5);
}

.soul-history-panel summary {
  padding: 11px 4px;
  color: #bfeeee;
  font-size: 0.82rem;
  font-weight: bold;
}

.soul-transactions { display: grid; gap: 5px; padding: 0 4px 8px; }

.soul-pager {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  padding: 4px 4px 10px;
}

.soul-pager button {
  padding: 4px 8px;
  border: 1px solid rgba(0, 204, 204, 0.48);
  border-radius: 4px;
  background: rgba(0, 204, 204, 0.1);
  color: #bfeeee;
  font: inherit;
  font-size: 0.68rem;
}

.soul-pager button:disabled { opacity: 0.35; }

.soul-pager span {
  min-width: 78px;
  color: #9baeb5;
  font-size: 0.68rem;
  text-align: center;
}

.soul-catalog-pager { margin-top: 13px; }

.soul-transaction {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 8px 9px;
  border-left: 2px solid rgba(0, 204, 204, 0.35);
  background: rgba(0, 0, 0, 0.28);
}

.soul-transaction strong,
.soul-transaction span { display: block; }
.soul-transaction strong,
.soul-transaction b { font-size: 0.78rem; }
.soul-transaction span,
.soul-empty { color: #9baeb5; font-size: 0.7rem; }
.soul-transaction .is-credit { color: #8ff5c5; }
.soul-transaction .is-debit { color: #ffb7a8; }

.soul-empty {
  grid-column: 1 / -1;
  padding: 18px 10px;
  border: 1px dashed rgba(0, 204, 204, 0.24);
  border-radius: 5px;
  text-align: center;
}

@media (max-width: 800px) {
  .soul-shop-shell {
    min-height: 0;
    padding: 16px;
  }
  .soul-account-bar,
  .soul-section-head { align-items: flex-start; flex-direction: column; }
  .soul-login-area,
  .soul-section-head > p { min-width: 0; text-align: left; }
  .soul-summary,
  .soul-email-notice,
  .soul-history-grid { grid-template-columns: 1fr; }
  .soul-stat { border-right: 0; border-bottom: 1px solid rgba(0, 204, 204, 0.22); }
  .soul-stat:last-child { border-bottom: 0; }
  .soul-shop-nav { justify-content: center; }
  .soul-inline-form { flex-direction: column; }
  .soul-catalog-tools { align-items: stretch; flex-direction: column; }
  .soul-catalog-search,
  .soul-catalog-sort { max-width: none; width: 100%; }
}

@media (max-width: 520px) {
  .soul-shop-nav { align-items: stretch; flex-direction: column; gap: 8px; text-align: center; }
  .soul-guide-link { position: static; }
  .soul-catalog { grid-template-columns: 1fr; }
}
