:root {
  color-scheme: light;
  --ink: #172026;
  --muted: #64717d;
  --line: #dce4ea;
  --surface: #ffffff;
  --soft: #f4f7f9;
  --green: #12805c;
  --blue: #245f9f;
  --sky: #dcecff;
  --gold: #b9821c;
  --gold-soft: #fff3d5;
  --red: #c94b4b;
  --owned: #4d6476;
  --shadow: 0 22px 60px rgba(23, 32, 38, 0.12);
  --ease: cubic-bezier(0.22, 1, 0.36, 1);
}

:root[data-theme="dark"] {
  color-scheme: dark;
  --ink: #edf4fb;
  --muted: #a8b7c6;
  --line: #263646;
  --surface: #111a23;
  --soft: #172331;
  --green: #4dd3a4;
  --blue: #6da8f0;
  --sky: #17324f;
  --gold: #e9bc62;
  --gold-soft: #302814;
  --red: #ff8585;
  --owned: #b3c4d4;
  --shadow: 0 22px 60px rgba(0, 0, 0, 0.34);
}

* {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
}

[hidden] {
  display: none !important;
}

.icon-sprite {
  position: absolute;
  width: 0;
  height: 0;
  overflow: hidden;
}

.icon {
  width: 1em;
  height: 1em;
  flex: 0 0 auto;
  color: currentColor;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  fill: none;
}

body {
  margin: 0;
  min-height: 100vh;
  overflow-x: hidden;
  background:
    linear-gradient(120deg, rgba(18, 128, 92, 0.22), transparent 26rem),
    linear-gradient(240deg, rgba(36, 95, 159, 0.22), transparent 24rem),
    #f7f9fb;
  color: var(--ink);
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
}

:root[data-theme="dark"] body {
  background:
    linear-gradient(120deg, rgba(77, 211, 164, 0.12), transparent 26rem),
    linear-gradient(240deg, rgba(109, 168, 240, 0.13), transparent 24rem),
    #0b1118;
}

button,
input,
label {
  font: inherit;
}

input,
select,
textarea {
  font-size: 16px;
}

:root[data-theme="dark"] input,
:root[data-theme="dark"] select,
:root[data-theme="dark"] textarea {
  background: #0f1821;
  color: var(--ink);
  border-color: var(--line);
}

button,
label {
  -webkit-tap-highlight-color: transparent;
}

button {
  cursor: pointer;
}

.site-shell {
  width: min(1180px, calc(100% - 2rem));
  margin: 0 auto;
  overflow-x: hidden;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  display: grid;
  grid-template-columns: auto 1fr auto;
  gap: 1rem;
  align-items: center;
  background: rgba(247, 249, 251, 0.88);
  backdrop-filter: blur(14px);
  padding: clamp(1rem, 2.5vw, 1.5rem);
}

:root[data-theme="dark"] .site-header {
  background: rgba(11, 17, 24, 0.9);
}

.site-header > * {
  min-width: 0;
}

.brand {
  display: flex;
  align-items: center;
  gap: 0.65rem;
  min-width: 16rem;
  color: inherit;
  text-decoration: none;
}

.brand-logo {
  display: block;
  width: clamp(8.5rem, 22vw, 9.25rem);
  height: auto;
}

.brand-logo-dark {
  display: none;
}

:root[data-theme="dark"] .brand-logo-light {
  display: none;
}

:root[data-theme="dark"] .brand-logo-dark {
  display: block;
}

.menu-toggle {
  display: none;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-size: 1.35rem;
  font-weight: 700;
}

.icon-action {
  width: 2.55rem;
  padding: 0;
}

.header-menu {
  display: contents;
}

.main-nav {
  display: flex;
  justify-content: center;
  gap: 0.35rem;
  min-width: 0;
  padding: 0.25rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.76);
}

.main-nav button,
.secondary-action,
.primary-action,
.danger-action {
  align-items: center;
  justify-content: center;
  gap: 0.45rem;
  min-height: 2.55rem;
  border-radius: 8px;
  border: 1px solid transparent;
  padding: 0 0.9rem;
  font-weight: 700;
}

.main-nav button {
  display: inline-flex;
  background: transparent;
  color: var(--muted);
  transition: background 0.18s var(--ease), color 0.18s var(--ease), transform 0.18s var(--ease);
}

.main-nav button.active {
  background: var(--ink);
  color: #fff;
}

:root[data-theme="dark"] .main-nav button.active {
  background: var(--blue);
  color: #08111a;
}

.main-nav button:hover,
.main-nav button:focus-visible {
  transform: translateY(-1px);
}

.header-actions,
.button-row {
  display: flex;
  gap: 0.6rem;
  align-items: center;
  flex-wrap: wrap;
  min-width: 0;
}

.secondary-action {
  display: inline-flex;
  background: #fff;
  color: var(--ink);
  border-color: var(--line);
  text-decoration: none;
  transition: border-color 0.18s var(--ease), box-shadow 0.18s var(--ease), transform 0.18s var(--ease), background 0.18s var(--ease);
}

:root[data-theme="dark"] .secondary-action,
:root[data-theme="dark"] .menu-toggle,
:root[data-theme="dark"] .main-nav,
:root[data-theme="dark"] .album-search-card,
:root[data-theme="dark"] .section-quick-nav,
:root[data-theme="dark"] .site-footer,
:root[data-theme="dark"] .qr-code,
:root[data-theme="dark"] .sync-choice-modal,
:root[data-theme="dark"] .account-modal {
  background: rgba(17, 26, 35, 0.96);
}

:root[data-theme="dark"] .secondary-action:hover,
:root[data-theme="dark"] .secondary-action:focus-visible {
  background: #1c2a38;
}

.secondary-action.full {
  width: 100%;
}

.primary-action {
  display: inline-flex;
  background: var(--blue);
  color: #fff;
  border-color: var(--blue);
  transition: border-color 0.18s var(--ease), box-shadow 0.18s var(--ease), transform 0.18s var(--ease), background 0.18s var(--ease);
}

:root[data-theme="dark"] .primary-action {
  color: #07111b;
}

.secondary-action:hover,
.secondary-action:focus-visible,
.primary-action:hover,
.primary-action:focus-visible {
  box-shadow: 0 10px 24px rgba(23, 32, 38, 0.12);
  transform: translateY(-1px);
}

.primary-action.small {
  min-height: 2.55rem;
}

.danger-action {
  background: #fff;
  color: var(--red);
  border-color: rgba(201, 75, 75, 0.35);
}

.back-to-top {
  position: fixed;
  right: clamp(1rem, 3vw, 2rem);
  bottom: clamp(1rem, 3vw, 2rem);
  z-index: 30;
  display: grid;
  place-items: center;
  width: 3rem;
  height: 3rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: rgba(255, 255, 255, 0.94);
  color: var(--blue);
  box-shadow: 0 14px 36px rgba(23, 32, 38, 0.16);
  font-size: 1.35rem;
  font-weight: 700;
  opacity: 0;
  pointer-events: none;
  transform: translateY(0.4rem);
  transition: opacity 160ms ease, transform 160ms ease;
}

.back-to-top.visible {
  opacity: 1;
  pointer-events: auto;
  transform: translateY(0);
}

.file-action {
  position: relative;
  overflow: hidden;
}

.file-action.has-tooltip {
  overflow: visible;
}

.file-action input {
  position: absolute;
  inset: auto 0 0 auto;
  width: 100%;
  height: 100%;
  opacity: 0;
  cursor: pointer;
  font-size: 0;
}

.file-action.has-tooltip::after {
  position: absolute;
  z-index: 8;
  bottom: calc(100% + 0.55rem);
  right: 0;
  width: min(14rem, 78vw);
  padding: 0.55rem 0.65rem;
  border-radius: 8px;
  background: var(--ink);
  color: #fff;
  content: attr(data-tooltip);
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.35;
  opacity: 0;
  pointer-events: none;
  text-align: left;
  transform: translateY(0.25rem);
  transition: opacity 0.16s ease, transform 0.16s ease;
}

.file-action.has-tooltip::before {
  position: absolute;
  z-index: 9;
  bottom: calc(100% + 0.2rem);
  right: 1.1rem;
  width: 0.55rem;
  height: 0.55rem;
  background: var(--ink);
  content: "";
  opacity: 0;
  pointer-events: none;
  transform: translateY(0.25rem) rotate(45deg);
  transition: opacity 0.16s ease, transform 0.16s ease;
}

.file-action.has-tooltip:hover::after,
.file-action.has-tooltip:focus-within::after {
  opacity: 1;
  transform: translateY(0);
}

.file-action.has-tooltip:hover::before,
.file-action.has-tooltip:focus-within::before {
  opacity: 1;
  transform: translateY(0) rotate(45deg);
}

.modal-overlay {
  position: fixed;
  inset: 0;
  z-index: 60;
  display: grid;
  place-items: center;
  padding: 1rem;
  background: rgba(23, 32, 38, 0.42);
}

.modal-overlay[hidden] {
  display: none;
}

.account-modal {
  width: min(100%, 28rem);
  max-height: calc(100vh - 2rem);
  overflow: auto;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  box-shadow: var(--shadow);
  padding: 1rem;
}

.modal-header {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 1rem;
}

.modal-close {
  display: grid;
  place-items: center;
  width: 2.3rem;
  height: 2.3rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-size: 1.4rem;
  line-height: 1;
}

.account-tabs {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.4rem;
  margin-top: 1rem;
  padding: 0.25rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
}

.account-tabs button {
  min-height: 2.4rem;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--muted);
  font-weight: 700;
}

.account-tabs button.active {
  background: #fff;
  color: var(--ink);
}

.account-form {
  display: grid;
  gap: 0.85rem;
  margin-top: 1rem;
}

.account-panel {
  border-top: 1px solid var(--line);
  padding-top: 1rem;
}

.account-form label {
  display: grid;
  gap: 0.35rem;
  color: var(--muted);
  font-size: 0.84rem;
  font-weight: 700;
}

.account-form input,
.account-form select,
.account-form textarea {
  min-height: 2.65rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 0 0.75rem;
  color: var(--ink);
}

.account-form textarea {
  min-height: 5.5rem;
  padding: 0.75rem;
  resize: vertical;
}

.account-form .checkbox-field {
  display: flex;
  gap: 0.55rem;
  align-items: center;
  color: var(--ink);
}

.account-form .checkbox-field input {
  width: 1.05rem;
  height: 1.05rem;
  min-height: 0;
  accent-color: var(--green);
}

.account-form select:disabled {
  color: var(--muted);
  background: var(--soft);
}

.account-form input:disabled,
.account-form textarea:disabled {
  color: var(--muted);
  background: var(--soft);
}

.account-message {
  min-height: 1.2rem;
  color: var(--red);
  font-size: 0.9rem;
  overflow-wrap: anywhere;
}

.account-message.success {
  color: var(--green);
}

.account-message.info {
  color: var(--blue);
}

.text-action {
  min-height: 2rem;
  border: 0;
  background: transparent;
  color: var(--blue);
  font-weight: 700;
  text-align: center;
}

.account-signed-in {
  display: grid;
  gap: 0.65rem;
  margin-top: 1rem;
}

.account-signed-in strong {
  font-size: 1.1rem;
}

.account-location {
  color: var(--muted);
  font-size: 0.92rem;
}

.account-collapse {
  border-top: 1px solid var(--line);
  padding-top: 0.55rem;
}

.account-collapse summary {
  display: flex;
  align-items: center;
  justify-content: space-between;
  min-height: 2.65rem;
  cursor: pointer;
  color: var(--ink);
  font-weight: 700;
  list-style: none;
}

.summary-label {
  display: inline-flex;
  gap: 0.45rem;
  align-items: center;
}

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

.account-collapse summary::after {
  content: "+";
  display: grid;
  place-items: center;
  width: 1.8rem;
  height: 1.8rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  color: var(--blue);
  font-weight: 800;
}

.account-collapse[open] summary::after {
  content: "-";
}

.account-note {
  color: var(--muted);
  line-height: 1.45;
}

.trade-privacy-card {
  display: grid;
  gap: 0.55rem;
  border: 1px solid rgba(48, 101, 166, 0.18);
  border-radius: 8px;
  background: rgba(48, 101, 166, 0.07);
  padding: 0.85rem;
}

.trade-privacy-card.is-active {
  border-color: rgba(18, 128, 92, 0.24);
  background: rgba(18, 128, 92, 0.08);
}

.trade-privacy-card strong {
  color: var(--ink);
  font-size: 0.98rem;
}

.trade-privacy-card p,
.trade-privacy-card ul {
  margin: 0;
}

.trade-privacy-card p,
.trade-privacy-card li {
  color: var(--muted);
  line-height: 1.45;
}

.trade-privacy-card ul {
  display: grid;
  gap: 0.35rem;
  padding: 0;
  list-style: none;
}

.trade-privacy-card li {
  display: flex;
  gap: 0.4rem;
  align-items: flex-start;
  font-size: 0.9rem;
}

.trade-privacy-card li .icon {
  flex: 0 0 auto;
  margin-top: 0.15rem;
  color: var(--blue);
}

.trade-privacy-card.is-active li .icon {
  color: var(--green);
}

#tradeWhatsappNotice .icon {
  color: var(--gold);
}

:root[data-theme="dark"] .trade-privacy-card {
  border-color: rgba(111, 169, 232, 0.22);
  background: rgba(35, 80, 128, 0.2);
}

:root[data-theme="dark"] .trade-privacy-card.is-active {
  border-color: rgba(80, 210, 163, 0.28);
  background: rgba(18, 128, 92, 0.16);
}

.sync-choice-body {
  display: grid;
  gap: 1rem;
  margin-top: 1rem;
}

.sync-choice-body p {
  color: var(--muted);
  line-height: 1.45;
}

.sync-choice-actions {
  display: grid;
  gap: 0.6rem;
}

main {
  padding: 0.5rem 0 3rem;
}

.complete-banner {
  display: flex;
  gap: 0.85rem;
  align-items: center;
  margin: 1.5rem 0 1rem;
  padding: 0.85rem 1rem;
  color: #2f2300;
  background: linear-gradient(135deg, rgba(255, 248, 219, 0.98), rgba(255, 236, 163, 0.92));
  border: 1px solid rgba(207, 150, 18, 0.42);
  border-radius: 8px;
  box-shadow: 0 14px 34px rgba(180, 128, 18, 0.12);
}

.complete-banner[hidden] {
  display: none;
}

.complete-banner-check {
  display: grid;
  flex: 0 0 auto;
  place-items: center;
  width: 2.45rem;
  height: 2.45rem;
  color: #fff;
  background: linear-gradient(135deg, #d8a21f, #f2c94c);
  border: 1px solid rgba(145, 98, 0, 0.28);
  border-radius: 999px;
  box-shadow: 0 8px 20px rgba(190, 135, 12, 0.22);
}

.complete-banner-check .icon {
  width: 1.2rem;
  height: 1.2rem;
  stroke-width: 3;
}

.complete-banner strong {
  display: block;
  font-size: 1rem;
  line-height: 1.1;
}

.complete-banner p {
  margin-top: 0.18rem;
  color: rgba(47, 35, 0, 0.72);
  font-size: 0.92rem;
  line-height: 1.35;
}

:root[data-theme="dark"] .complete-banner {
  color: #fff8dc;
  background: linear-gradient(135deg, rgba(67, 50, 8, 0.98), rgba(112, 78, 8, 0.9));
  border-color: rgba(247, 203, 85, 0.46);
  box-shadow: 0 16px 36px rgba(0, 0, 0, 0.22);
}

:root[data-theme="dark"] .complete-banner p {
  color: rgba(255, 248, 220, 0.78);
}

.hero-panel,
.side-panel,
.album-section,
.summary-item,
.chart-card,
.skills-panel,
.trade-card,
.community-card,
.compare-card,
.public-card,
.public-list-card,
.legal-card,
.help-card {
  background: rgba(255, 255, 255, 0.92);
  border: 1px solid var(--line);
  border-radius: 8px;
  box-shadow: 0 12px 34px rgba(23, 32, 38, 0.07);
}

:root[data-theme="dark"] .hero-panel,
:root[data-theme="dark"] .side-panel,
:root[data-theme="dark"] .album-section,
:root[data-theme="dark"] .summary-item,
:root[data-theme="dark"] .chart-card,
:root[data-theme="dark"] .skills-panel,
:root[data-theme="dark"] .trade-card,
:root[data-theme="dark"] .community-card,
:root[data-theme="dark"] .compare-card,
:root[data-theme="dark"] .public-card,
:root[data-theme="dark"] .public-list-card,
:root[data-theme="dark"] .legal-card,
:root[data-theme="dark"] .help-card {
  background: rgba(17, 26, 35, 0.94);
  box-shadow: 0 14px 38px rgba(0, 0, 0, 0.26);
}

.hero-panel {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  align-items: start;
  padding: clamp(1rem, 2.5vw, 1.5rem);
  margin-bottom: 1rem;
}

.hero-copy {
  display: grid;
  gap: 0.45rem;
}

.guest-note {
  max-width: 52rem;
  color: var(--muted);
  font-size: 0.98rem;
  line-height: 1.5;
}

.hero-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  margin-top: 0.25rem;
}

.hero-actions .primary-action,
.hero-actions .secondary-action {
  min-width: 9.5rem;
  text-decoration: none;
}

.eyebrow {
  display: inline-flex;
  gap: 0.35rem;
  align-items: center;
  margin: 0 0 0.35rem;
  color: var(--green);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

h1,
h2,
p {
  margin: 0;
}

h1 {
  max-width: none;
  font-size: clamp(1.5rem, 5vw, 2rem);
  line-height: 1.1;
  letter-spacing: 0;
}

h2 {
  font-size: clamp(1.25rem, 2vw, 1.7rem);
  line-height: 1.12;
}

.quick-stats,
.summary-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
}

.quick-stats {
  align-items: stretch;
}

.quick-stats article,
.summary-item {
  padding: 1rem;
}

.quick-stats article {
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.quick-stats span,
.summary-item span,
.progress-card span,
.filter-group label,
.filter-group > span {
  display: flex;
  gap: 0.35rem;
  align-items: center;
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.quick-stats strong,
.summary-item strong {
  display: block;
  margin-top: 0.25rem;
  font-size: clamp(1.65rem, 3vw, 2.35rem);
  line-height: 1;
}

.view {
  display: none;
}

.view.active {
  animation: viewFade 0.22s var(--ease);
  display: block;
}

@keyframes viewFade {
  from {
    opacity: 0;
    transform: translateY(0.35rem);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.workspace {
  display: grid;
  grid-template-columns: minmax(16rem, 19rem) 1fr;
  gap: 1rem;
  align-items: start;
}

.album-preview-locked .workspace {
  position: relative;
}

.album-preview-locked .side-panel,
.album-preview-locked .album-workarea {
  filter: blur(5px);
  opacity: 0.44;
  pointer-events: none;
  user-select: none;
  transition: filter 0.22s var(--ease), opacity 0.22s var(--ease);
}

.album-preview-card {
  display: none;
}

.album-preview-locked .album-preview-card {
  position: absolute;
  z-index: 4;
  top: min(8rem, 22vh);
  left: 50%;
  display: grid;
  gap: 0.65rem;
  width: min(36rem, calc(100% - 2rem));
  transform: translateX(-50%);
  border: 1px solid rgba(48, 101, 166, 0.24);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 20px 50px rgba(23, 32, 38, 0.16);
  color: var(--ink);
  padding: 1.1rem;
  line-height: 1.4;
}

.album-preview-card h2,
.album-preview-card p {
  margin: 0;
}

.album-preview-card h2 {
  font-size: 1.35rem;
}

.album-preview-card > p:not(.eyebrow) {
  color: var(--muted);
}

.album-preview-actions {
  display: grid;
  grid-template-columns: 1.2fr 1fr 0.85fr 0.9fr;
  gap: 0.55rem;
  margin-top: 0.25rem;
}

.album-preview-actions .primary-action,
.album-preview-actions .secondary-action {
  width: 100%;
  min-width: 0;
  white-space: nowrap;
}

:root[data-theme="dark"] .album-preview-locked .album-preview-card {
  border-color: rgba(111, 169, 232, 0.28);
  background: rgba(17, 26, 35, 0.96);
  box-shadow: 0 22px 55px rgba(0, 0, 0, 0.36);
}

.album-workarea {
  display: grid;
  gap: 1rem;
  min-width: 0;
}

.album-search-card {
  position: sticky;
  top: 5.5rem;
  z-index: 9;
  display: grid;
  gap: 0.45rem;
  padding: 0.8rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background:#E4FCF4;
  box-shadow: 0 10px 30px rgba(23, 32, 38, 0.08);
}

.album-search-card label {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.album-search-row {
  display: grid;
  grid-template-columns: minmax(12rem, 1fr) auto;
  gap: 0.55rem;
  align-items: center;
}

.album-search-card input {
  width: 100%;
  min-height: 2.75rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 0 2.55rem 0 0.85rem;
}

.album-search-card input::-webkit-search-cancel-button,
.album-search-card input::-webkit-search-decoration {
  display: none;
}

.search-input-wrap {
  position: relative;
  min-width: 0;
}

.search-clear-btn {
  position: absolute;
  top: 50%;
  right: 0.45rem;
  display: block;
  width: 1.85rem;
  height: 1.85rem;
  transform: translateY(-50%);
  border: 0;
  border-radius: 999px;
  background: var(--soft);
  color: var(--muted);
  font-size: 0;
  line-height: 0;
}

.search-clear-btn::before,
.search-clear-btn::after {
  position: absolute;
  top: 50%;
  left: 50%;
  width: 0.78rem;
  height: 0.16rem;
  border-radius: 999px;
  background: currentColor;
  content: "";
  transform-origin: center;
}

.search-clear-btn::before {
  transform: translate(-50%, -50%) rotate(45deg);
}

.search-clear-btn::after {
  transform: translate(-50%, -50%) rotate(-45deg);
}

.search-clear-btn:hover,
.search-clear-btn:focus-visible {
  background: rgba(201, 75, 75, 0.12);
  color: var(--red);
}

.album-toolbar {
  display: flex;
  gap: 0.35rem;
  align-items: center;
}

.album-toolbar .icon-action {
  flex: 0 0 auto;
  display: inline-grid;
  place-items: center;
  width: 2.75rem;
  height: 2.75rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--muted);
  transition: background 0.18s var(--ease), border-color 0.18s var(--ease), color 0.18s var(--ease), transform 0.18s var(--ease);
}

.album-toolbar .icon-action .icon {
  transform-origin: center;
  transition: transform 0.2s var(--ease);
}

.album-toolbar .icon-action:hover,
.album-toolbar .icon-action:focus-visible {
  border-color: rgba(36, 95, 159, 0.34);
  color: var(--blue);
  transform: translateY(-1px);
}

.album-toolbar .icon-action.is-active {
  border-color: var(--blue);
  background: var(--blue);
  color: #fff;
  box-shadow: 0 0 0 2px rgba(43, 111, 186, 0.14), 0 8px 18px rgba(43, 111, 186, 0.16);
}

.album-toolbar .icon-action.is-rotated .icon,
.album-toolbar .icon-action.is-inverted .icon {
  transform: rotate(180deg);
}

.album-toolbar .icon-action:active .icon {
  transform: scale(0.94);
}

.album-toolbar .icon-action.is-rotated:active .icon,
.album-toolbar .icon-action.is-inverted:active .icon {
  transform: rotate(180deg) scale(0.94);
}

.section-quick-nav {
  display: flex;
  gap: 0.45rem;
  flex-wrap: nowrap;
  overflow-x: auto;
  padding: 0.75rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.9);
  box-shadow: 0 10px 30px rgba(23, 32, 38, 0.06);
  scrollbar-width: thin;
}

.section-jump {
  --section-progress: 0%;
  flex: 0 0 auto;
  display: grid;
  place-items: center;
  width: 2.55rem;
  height: 2.55rem;
  border: 0;
  border-radius: 999px;
  background:
    conic-gradient(var(--blue) var(--section-progress), #dbe5ef 0);
  color: var(--ink);
  padding: 0;
  transition: box-shadow 0.16s ease, transform 0.16s ease, filter 0.16s ease;
}

.section-jump:hover,
.section-jump:focus-visible {
  box-shadow: 0 10px 24px rgba(36, 95, 159, 0.12);
  filter: saturate(1.08);
  transform: translateY(-1px);
}

.section-jump.is-complete {
  background: conic-gradient(var(--green) 100%, var(--green) 0);
  box-shadow: 0 0 0 2px rgba(18, 128, 92, 0.08);
}

.section-jump-icon {
  display: grid;
  place-items: center;
  width: calc(100% - 0.4rem);
  height: calc(100% - 0.4rem);
  border-radius: 999px;
  background: #fff;
  box-shadow: inset 0 0 0 1px rgba(18, 32, 44, 0.06);
}

:root[data-theme="dark"] .section-jump {
  background: conic-gradient(var(--blue) var(--section-progress), #2a3948 0);
}

:root[data-theme="dark"] .section-jump-icon {
  background: #0f1821;
  box-shadow: inset 0 0 0 1px rgba(237, 244, 251, 0.08);
}

.section-jump .country-flag {
  width: 1.85rem;
  height: 1.85rem;
  font-size: 1.12rem;
}

.side-panel {
  position: sticky;
  top: 5.5rem;
  padding: 1rem;
  background:
    linear-gradient(180deg, rgba(220, 236, 255, 0.78), rgba(247, 250, 248, 0.96)),
    #eef6fb;
  border-color: #cbdce8;
}

.progress-card {
  display: grid;
  grid-template-columns: 3.6rem 1fr;
  gap: 0.8rem;
  align-items: center;
}

.progress-card strong {
  display: block;
  margin-top: 0.15rem;
  font-size: 1.8rem;
  line-height: 1;
}

.ring {
  display: grid;
  place-items: center;
  width: 3.25rem;
  height: 3.25rem;
  border-radius: 50%;
  background: conic-gradient(var(--blue) 0deg, #dfe8f5 0deg 360deg);
}

.ring span {
  width: 2.25rem;
  height: 2.25rem;
  border-radius: 50%;
  background: #fff;
}

.save-status {
  margin-top: 1rem;
  padding: 0.75rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #f7faf8;
}

.save-status span,
.save-status small,
.backup-card span,
.backup-card small {
  display: block;
}

.save-status span {
  color: var(--green);
  font-size: 0.82rem;
  font-weight: 700;
}

.save-status small {
  margin-top: 0.2rem;
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.35;
}

.backup-card {
  margin-top: 0.75rem;
  padding: 0.75rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
}

.backup-card span {
  color: var(--ink);
  font-size: 0.82rem;
  font-weight: 700;
}

.backup-card small {
  margin-top: 0.2rem;
  color: var(--muted);
  font-size: 0.78rem;
  line-height: 1.35;
}

.backup-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.45rem;
  margin-top: 0.65rem;
}

.backup-actions .primary-action,
.backup-actions .secondary-action {
  width: 100%;
  min-height: 2.35rem;
  padding: 0 0.55rem;
  font-size: 0.88rem;
}

.filter-group {
  margin-top: 1rem;
}

.filter-group input {
  width: 100%;
  min-height: 2.75rem;
  margin-top: 0.4rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  padding: 0 0.8rem;
}

.status-tabs {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(7rem, 1fr));
  gap: 0.45rem;
  margin-top: 0.5rem;
}

.status-tabs button {
  display: inline-flex;
  gap: 0.4rem;
  align-items: center;
  justify-content: center;
  min-height: 2.45rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--muted);
  font-weight: 700;
  transition: background 0.18s var(--ease), border-color 0.18s var(--ease), color 0.18s var(--ease), transform 0.18s var(--ease);
}

.status-tabs button.active {
  background: var(--sky);
  color: var(--blue);
  border-color: rgba(36, 95, 159, 0.28);
  box-shadow: 0 0 0 2px rgba(36, 95, 159, 0.08);
}

.status-tabs button:hover,
.status-tabs button:focus-visible {
  background: rgba(36, 95, 159, 0.1);
  border-color: rgba(36, 95, 159, 0.28);
  color: var(--blue);
  box-shadow: 0 8px 18px rgba(36, 95, 159, 0.1);
  transform: translateY(-1px);
}

.panel-actions {
  display: grid;
  grid-template-columns: 1fr;
  gap: 0.5rem;
  margin-top: 1rem;
}

.panel-actions .secondary-action {
  min-height: 2.45rem;
  padding: 0 0.55rem;
  font-size: 0.9rem;
}

.panel-actions .secondary-action:hover,
.panel-actions .secondary-action:focus-visible,
.panel-actions .secondary-action.is-active {
  background: rgba(36, 95, 159, 0.1);
  border-color: rgba(36, 95, 159, 0.28);
  color: var(--blue);
  box-shadow: 0 8px 18px rgba(36, 95, 159, 0.1);
}

.panel-actions .secondary-action.is-active {
  box-shadow: 0 0 0 2px rgba(36, 95, 159, 0.08);
}

.hint {
  margin-top: 1rem;
  color: var(--muted);
  font-size: 0.92rem;
  line-height: 1.45;
}

.album-sections {
  display: grid;
  gap: 0.85rem;
}

.album-section {
  padding: 1rem;
  scroll-margin-top: 8rem;
  transition: border-color 0.2s var(--ease), box-shadow 0.2s var(--ease), transform 0.2s var(--ease);
}

.album-section:hover {
  border-color: #c8d5de;
  box-shadow: 0 16px 38px rgba(23, 32, 38, 0.08);
}

.section-header {
  display: grid;
  gap: 0.15rem;
  width: 100%;
  padding: 0 0 0.85rem;
}

.section-title-toggle {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  width: 100%;
  border: 0;
  background: transparent;
  color: var(--ink);
  padding: 0;
  text-align: left;
}

.section-title-toggle .chevron {
  display: inline-grid;
  place-items: center;
  width: 1.75rem;
  height: 1.75rem;
  border-radius: 999px;
  color: var(--blue);
  transition: background 0.18s var(--ease), transform 0.18s var(--ease);
}

.section-title-toggle:hover .chevron,
.section-title-toggle:focus-visible .chevron {
  background: rgba(36, 95, 159, 0.08);
  transform: translateY(-1px);
}

.section-title-toggle h2 {
  display: flex;
  gap: 0.45rem;
  align-items: center;
  min-width: 0;
  font-size: 1.15rem;
}

.section-title-text {
  min-width: 0;
}

.section-complete-badge {
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  width: 1.35rem;
  height: 1.35rem;
  border-radius: 999px;
  background: #12805c;
  color: #fff;
  box-shadow: 0 3px 9px rgba(18, 128, 92, 0.24);
}

.section-complete-badge .icon {
  width: 0.82rem;
  height: 0.82rem;
  stroke-width: 2.6;
}

.section-icon {
  width: 1.05rem;
  height: 1.05rem;
  color: var(--gold);
}

.country-flag {
  display: inline-grid;
  place-items: center;
  width: 1.35rem;
  height: 1.35rem;
  border-radius: 999px;
  background: #fff;
  color: var(--ink);
  box-shadow: inset 0 0 0 1px rgba(23, 32, 38, 0.08);
  font-size: 1rem;
  font-weight: 800;
  line-height: 1;
}

:root[data-theme="dark"] .country-flag {
  background: rgba(237, 244, 251, 0.08);
  color: var(--ink);
  box-shadow: inset 0 0 0 1px rgba(237, 244, 251, 0.12);
}

.section-meta {
  display: flex;
  gap: 0.5rem;
  align-items: center;
  flex-wrap: wrap;
  margin-top: 0.15rem;
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 700;
}

.section-count-pill,
.section-top-link,
.section-complete-link,
.section-more-menu summary,
.section-more-menu button {
  display: inline-flex;
  gap: 0.25rem;
  align-items: center;
  min-height: 1.55rem;
  border-radius: 999px;
  padding: 0 0.55rem;
  font-size: 0.76rem;
  font-weight: 800;
  transition: background 0.18s var(--ease), border-color 0.18s var(--ease), box-shadow 0.18s var(--ease), transform 0.18s var(--ease), opacity 0.18s var(--ease);
}

.section-filter-group {
  display: inline-flex;
  gap: 0.15rem;
  align-items: center;
  padding: 0.15rem;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--soft);
}

.section-filter-button {
  display: inline-grid;
  place-items: center;
  width: 1.7rem;
  height: 1.7rem;
  border: 1px solid transparent;
  border-radius: 999px;
  padding: 0;
  background: transparent;
  color: var(--muted);
  transition: background 0.16s var(--ease), border-color 0.16s var(--ease), color 0.16s var(--ease), transform 0.16s var(--ease);
}

.section-filter-button .icon {
  width: 0.85rem;
  height: 0.85rem;
}

.section-filter-button:hover,
.section-filter-button:focus-visible {
  color: var(--blue);
  transform: translateY(-1px);
}

.section-filter-button.active {
  border-color: rgba(36, 95, 159, 0.34);
  background: var(--blue);
  color: #fff;
  box-shadow: 0 4px 10px rgba(36, 95, 159, 0.18);
}

:root[data-theme="dark"] .section-filter-group {
  background: #0f1821;
}

:root[data-theme="dark"] .section-filter-button.active {
  border-color: var(--blue);
  color: #07111b;
}

.section-filter-empty {
  margin: 0;
  padding: 1rem;
  border: 1px dashed var(--line);
  border-radius: 8px;
  background: var(--soft);
  color: var(--muted);
  font-size: 0.88rem;
  font-weight: 700;
  text-align: center;
}

.section-more-menu {
  position: relative;
}

.section-more-menu summary {
  justify-content: center;
  min-width: 2rem;
  border: 1px solid rgba(36, 95, 159, 0.18);
  background: rgba(36, 95, 159, 0.07);
  color: var(--blue);
  cursor: pointer;
  list-style: none;
}

.section-more-menu summary::-webkit-details-marker {
  display: none;
}

.section-more-menu[open] summary,
.section-more-menu summary:hover,
.section-more-menu summary:focus-visible {
  border-color: rgba(36, 95, 159, 0.36);
  background: rgba(36, 95, 159, 0.12);
}

.section-more-menu button {
  position: absolute;
  right: 0;
  top: calc(100% + 0.35rem);
  z-index: 8;
  width: max-content;
  border: 1px solid rgba(36, 95, 159, 0.22);
  background: #fff;
  color: var(--blue);
  box-shadow: 0 12px 30px rgba(23, 32, 38, 0.14);
}

.section-count-pill {
  border: 1px solid rgba(36, 95, 159, 0.18);
  background: rgba(36, 95, 159, 0.07);
  color: var(--blue);
}

.section-duplicate-count {
  display: inline-flex;
  gap: 0.2rem;
  align-items: center;
  margin-left: 0.15rem;
  padding-left: 0.45rem;
  border-left: 1px solid rgba(36, 95, 159, 0.2);
  color: var(--muted);
}

.section-duplicate-count.has-duplicates {
  color: var(--blue);
}

:root[data-theme="dark"] .section-count-pill {
  border-color: rgba(109, 168, 240, 0.26);
  background: rgba(109, 168, 240, 0.12);
}

:root[data-theme="dark"] .section-duplicate-count {
  border-left-color: rgba(109, 168, 240, 0.24);
}

:root[data-theme="dark"] .section-more-menu summary {
  border-color: rgba(109, 168, 240, 0.26);
  background: rgba(109, 168, 240, 0.12);
}

:root[data-theme="dark"] .section-more-menu button {
  border-color: rgba(109, 168, 240, 0.28);
  background: #0f1821;
}

.section-top-link {
  border: 1px solid rgba(18, 128, 92, 0.24);
  background: rgba(18, 128, 92, 0.08);
  color: var(--green);
}

.section-top-link:hover,
.section-top-link:focus-visible {
  border-color: rgba(18, 128, 92, 0.44);
  background: rgba(18, 128, 92, 0.12);
  box-shadow: 0 8px 18px rgba(18, 128, 92, 0.13);
}

.section-complete-link {
  border: 1px solid rgba(36, 95, 159, 0.24);
  background: rgba(36, 95, 159, 0.08);
  color: var(--blue);
}

.section-complete-link:hover,
.section-complete-link:focus-visible {
  border-color: rgba(36, 95, 159, 0.44);
  background: rgba(36, 95, 159, 0.12);
  box-shadow: 0 8px 18px rgba(36, 95, 159, 0.13);
}

.section-complete-link:disabled {
  cursor: default;
  opacity: 0.48;
  pointer-events: none;
}

.section-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(min(8rem, calc((100% - 1.5rem) / 3)), 1fr));
  gap: 0.75rem;
}

.album-section.animate-open .section-grid {
  animation: sectionReveal 0.22s var(--ease);
}

@keyframes sectionReveal {
  from {
    opacity: 0;
    transform: translateY(-0.35rem);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.sticker-tile {
  position: relative;
  min-width: 0;
  overflow: hidden;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
  color: var(--ink);
  padding: 0.8rem 0.8rem 0.8rem 0.95rem;
  transition: background 0.18s var(--ease), border-color 0.18s var(--ease), box-shadow 0.18s var(--ease);
}

.sticker-tile::before {
  content: "";
  position: absolute;
  inset: 0 auto 0 0;
  width: 0.25rem;
  background: #98a8b5;
}

:root[data-theme="dark"] .sticker-tile {
  background: #13202b;
}

.sticker-tile:hover {
  box-shadow: 0 12px 26px rgba(23, 32, 38, 0.09);
}

.sticker-tile.missing {
  background: #f7f9fb;
  border-color: #cbd6df;
}

.sticker-tile.missing .quantity-label {
  color: #596b79;
}

.sticker-tile.missing .status-icon {
  color: #6d8191;
}

.sticker-tile.owned,
.sticker-tile.duplicate {
  background: #e6f5ef;
  border-color: rgba(18, 128, 92, 0.46);
}

.sticker-tile.owned::before {
  background: var(--green);
}

.sticker-tile.owned .quantity-label,
.sticker-tile.owned .status-icon {
  color: #0f7555;
}

:root[data-theme="dark"] .sticker-tile.owned,
:root[data-theme="dark"] .sticker-tile.duplicate {
  background: rgba(77, 211, 164, 0.1);
  border-color: rgba(77, 211, 164, 0.24);
}

.sticker-tile.shiny {
  background: var(--gold-soft);
  border-color: rgba(185, 130, 28, 0.24);
}

.sticker-tile.duplicate {
  background: #edf4ff;
  border-color: rgba(36, 95, 159, 0.28);
}

.sticker-tile.duplicate::before {
  background: var(--blue);
}

.sticker-tile.duplicate .quantity-label,
.sticker-tile.duplicate .status-icon {
  color: var(--blue);
}

:root[data-theme="dark"] .sticker-tile.duplicate {
  background: rgba(109, 168, 240, 0.12);
  border-color: rgba(109, 168, 240, 0.28);
}

:root[data-theme="dark"] .sticker-tile.missing {
  background: #101923;
  border-color: #35495b;
}

:root[data-theme="dark"] .sticker-tile.missing::before {
  background: #71879a;
}

:root[data-theme="dark"] .sticker-tile.missing .quantity-label,
:root[data-theme="dark"] .sticker-tile.missing .status-icon {
  color: #a9bac9;
}

:root[data-theme="dark"] .sticker-tile.owned {
  background: rgba(77, 211, 164, 0.14);
  border-color: rgba(77, 211, 164, 0.42);
}

:root[data-theme="dark"] .sticker-tile.owned .quantity-label,
:root[data-theme="dark"] .sticker-tile.owned .status-icon {
  color: var(--green);
}

.sticker-main {
  display: flex;
  justify-content: space-between;
  gap: 0.5rem;
  align-items: center;
}

.sticker-number {
  display: inline-flex;
  gap: 0.35rem;
  align-items: center;
  font-size: 1.08rem;
  font-weight: 700;
  white-space: nowrap;
}

.duplicate-badge {
  display: inline-grid;
  place-items: center;
  min-width: 1.75rem;
  height: 1.75rem;
  padding: 0 0.35rem;
  border-radius: 999px;
  background: var(--blue);
  color: #fff;
  font-size: 0.86rem;
  font-weight: 700;
}

.quantity-label {
  display: flex;
  gap: 0.25rem;
  align-items: center;
  flex-wrap: wrap;
  margin-top: 0.35rem;
  color: var(--muted);
  font-size: 0.76rem;
  font-weight: 700;
}

.status-icon {
  width: 0.86rem;
  height: 0.86rem;
  color: var(--blue);
}

.tile-actions {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0.5rem;
  margin-top: 0.65rem;
}

.tile-actions button {
  min-height: 2.45rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  font-size: 1.1rem;
  font-weight: 700;
  transition: background 0.16s var(--ease), border-color 0.16s var(--ease), box-shadow 0.16s var(--ease);
}

.tile-actions button:hover,
.tile-actions button:focus-visible {
  box-shadow: 0 8px 18px rgba(23, 32, 38, 0.11);
}

.tile-actions button:active,
.section-jump:active,
.primary-action:active,
.secondary-action:active {
  transform: translateY(0);
}

.tile-actions button[data-action="increase"] {
  background: #eaf2fb;
  color: #1d4f82;
  border-color: #cfe0ef;
}

:root[data-theme="dark"] .tile-actions button,
:root[data-theme="dark"] .tile-actions button[data-action="decrease"] {
  background: #0f1821;
  color: var(--ink);
  border-color: var(--line);
}

:root[data-theme="dark"] .tile-actions button[data-action="increase"] {
  background: rgba(109, 168, 240, 0.16);
  color: var(--ink);
  border-color: rgba(109, 168, 240, 0.28);
}

.tile-actions button[data-action="decrease"] {
  background: #fff;
  color: #14202a;
  border-color: #d6e0e7;
}

.empty-state {
  padding: 2rem;
  text-align: center;
  color: var(--muted);
  border: 1px dashed var(--line);
  border-radius: 8px;
}

.stats-layout,
.trade-layout,
.public-layout,
.help-layout {
  display: grid;
  gap: 1rem;
}

.trade-preview-locked .trade-layout {
  position: relative;
}

.chart-card,
.skills-panel,
.trade-card,
.community-card,
.compare-card,
.public-card,
.public-list-card,
.legal-card,
.help-card {
  padding: 1.2rem;
}

.chart {
  display: grid;
  gap: 0.85rem;
  margin-top: 1rem;
  border-radius: 8px;
  background: #f2f6f9;
  padding: 1rem;
}

.chart-row {
  display: grid;
  grid-template-columns: 6.4rem minmax(0, 1fr) 4.2rem;
  gap: 0.75rem;
  align-items: center;
}

.chart-row span {
  color: var(--muted);
  font-size: 0.9rem;
  font-weight: 800;
}

.chart-row strong {
  color: var(--ink);
  text-align: right;
}

.chart-track {
  height: 0.8rem;
  overflow: hidden;
  border-radius: 999px;
  background: #dfe8f0;
}

.chart-track i {
  display: block;
  width: 0;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--blue), var(--green));
  transition: width 0.25s ease;
}

.skills-panel dl {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 0.75rem;
  margin: 1rem 0 0;
}

.skills-panel div {
  padding: 1rem;
  border-radius: 8px;
  background: var(--soft);
}

.skills-panel dt {
  display: flex;
  gap: 0.35rem;
  align-items: center;
  color: var(--muted);
  font-weight: 700;
}

.info-badge {
  position: relative;
  display: inline-grid;
  place-items: center;
  width: 1.05rem;
  height: 1.05rem;
  border: 1px solid #c9d6e2;
  border-radius: 50%;
  background: #fff;
  color: var(--blue);
  cursor: help;
  font-size: 0.72rem;
  font-weight: 800;
  line-height: 1;
}

.info-badge::after {
  position: absolute;
  z-index: 3;
  bottom: calc(100% + 0.55rem);
  left: 50%;
  width: min(13rem, 70vw);
  padding: 0.55rem 0.65rem;
  border-radius: 8px;
  background: var(--ink);
  color: #fff;
  content: attr(data-tooltip);
  font-size: 0.78rem;
  font-weight: 600;
  line-height: 1.35;
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 0.25rem);
  transition: opacity 0.16s ease, transform 0.16s ease;
}

.info-badge::before {
  position: absolute;
  z-index: 4;
  bottom: calc(100% + 0.2rem);
  left: 50%;
  width: 0.55rem;
  height: 0.55rem;
  background: var(--ink);
  content: "";
  opacity: 0;
  pointer-events: none;
  transform: translate(-50%, 0.25rem) rotate(45deg);
  transition: opacity 0.16s ease, transform 0.16s ease;
}

.info-badge:hover::after,
.info-badge:focus-visible::after,
.info-badge:hover::before,
.info-badge:focus-visible::before {
  opacity: 1;
  transform: translate(-50%, 0);
}

.skills-panel dd {
  margin: 0.3rem 0 0;
  font-size: 1.65rem;
  font-weight: 700;
}

.trade-preview-card {
  display: none;
}

.trade-preview-locked .trade-preview-card {
  position: absolute;
  z-index: 4;
  top: min(5.5rem, 18vh);
  left: 50%;
  display: grid;
  gap: 0.65rem;
  width: min(40rem, calc(100% - 2rem));
  transform: translateX(-50%);
  border: 1px solid rgba(48, 101, 166, 0.24);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.94);
  box-shadow: 0 20px 50px rgba(23, 32, 38, 0.16);
  padding: 1.1rem;
}

.trade-preview-card h2,
.trade-preview-card p {
  margin: 0;
}

.trade-preview-card h2 {
  font-size: 1.35rem;
}

.trade-preview-card > p:not(.eyebrow) {
  color: var(--muted);
  line-height: 1.5;
}

.trade-preview-locked .trade-preview-content {
  filter: blur(5px);
  opacity: 0.44;
  pointer-events: none;
  user-select: none;
  transition: filter 0.22s var(--ease), opacity 0.22s var(--ease);
}

.trade-card {
  display: grid;
  grid-template-columns: minmax(12rem, 18rem) 1fr;
  gap: 1.5rem;
  align-items: center;
}

.community-card {
  display: grid;
  gap: 1rem;
}

.community-actions {
  display: flex;
  gap: 0.7rem;
  flex-wrap: wrap;
}

.discover-panel {
  display: grid;
  gap: 0.85rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(48, 101, 166, 0.05);
  padding: 0.9rem;
}

.discover-panel h3 {
  margin: 0 0 0.25rem;
  font-size: 1rem;
}

.discover-panel p {
  margin: 0;
}

.discover-panel > .secondary-action {
  width: fit-content;
  background: var(--green);
  color: var(--surface);
}

.discover-results {
  display: grid;
  gap: 0.65rem;
}

.discover-person {
  display: grid;
  gap: 0.65rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  padding: 0.85rem;
}

.discover-person header {
  display: flex;
  gap: 0.65rem;
  align-items: flex-start;
  justify-content: space-between;
}

.discover-person h4 {
  margin: 0;
  font-size: 1rem;
}

.discover-person small {
  color: var(--muted);
  font-weight: 700;
}

.discover-match-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.55rem;
}

.discover-match-grid span {
  display: grid;
  gap: 0.15rem;
  border-radius: 8px;
  background: var(--soft);
  padding: 0.65rem;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 700;
}

.discover-match-grid strong {
  color: var(--ink);
  font-size: 1.35rem;
  line-height: 1;
}

.discover-actions {
  display: flex;
  gap: 0.5rem;
  flex-wrap: wrap;
}

.discover-note {
  color: var(--muted);
  font-size: 0.9rem;
}

:root[data-theme="dark"] .discover-panel {
  background: rgba(35, 80, 128, 0.16);
}

:root[data-theme="dark"] .discover-panel > .secondary-action {
  color: #fff;
}

:root[data-theme="dark"] .discover-panel > .secondary-action:disabled {
  color: rgba(255, 255, 255, 0.72);
}

:root[data-theme="dark"] .trade-preview-locked .trade-preview-card {
  border-color: rgba(111, 169, 232, 0.28);
  background: rgba(17, 26, 35, 0.94);
  box-shadow: 0 14px 38px rgba(0, 0, 0, 0.26);
}

:root[data-theme="dark"] .discover-person {
  background: rgba(17, 26, 35, 0.94);
}

:root[data-theme="dark"] .discover-match-grid span {
  background: rgba(255, 255, 255, 0.06);
}

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

.public-card {
  grid-column: 1 / -1;
}

.public-trade-box {
  display: grid;
  gap: 0.55rem;
  align-items: start;
  margin-top: 1rem;
  padding: 0.85rem;
  border: 1px solid rgba(18, 128, 92, 0.22);
  border-radius: 8px;
  background: rgba(18, 128, 92, 0.07);
}

.trade-badge {
  width: fit-content;
  border: 1px solid rgba(18, 128, 92, 0.3);
  border-radius: 999px;
  background: #fff;
  color: var(--green);
  padding: 0.28rem 0.65rem;
  font-size: 0.78rem;
  font-weight: 800;
}

.public-trade-box .primary-action {
  width: fit-content;
}

.public-card p,
.public-list-card p,
.compare-card p,
.trade-card p,
.community-card p,
.help-card p,
.help-card li,
.legal-card p {
  color: var(--muted);
  line-height: 1.55;
  margin: 5px 0 10px 0;
}

.legal-card {
  scroll-margin-top: 7rem;
}

.legal-card a {
  color: var(--blue);
  font-weight: 700;
}

.legal-card h2 { margin-bottom: 20px; }

.public-list-card h3 {
  display: flex;
  gap: 0.4rem;
  align-items: center;
  margin: 0 0 0.8rem;
  font-size: 1.1rem;
}

.public-list,
.compare-results {
  margin-top: 10px;
  display: grid;
  gap: 0.45rem;
}

.public-list p,
.compare-results p {
  margin: 0;
  padding: 0.55rem 0.65rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: var(--soft);
  color: var(--ink);
  font-size: 0.92rem;
  line-height: 1.45;
}

.compare-form {
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 0.6rem;
  margin-top: 1rem;
}

.compare-form input {
  min-width: 0;
  min-height: 2.65rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  padding: 0 0.8rem;
}

.public-link-field {
  display: grid;
  gap: 0.45rem;
  margin-top: 1rem;
  margin-bottom: 1rem;
  padding: 0.85rem;
  border: 1px solid rgba(36, 95, 159, 0.18);
  border-radius: 8px;
  background: rgba(36, 95, 159, 0.06);
}

.public-link-field label {
  color: var(--muted);
  font-size: 0.78rem;
  font-weight: 800;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.public-link-field div {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.5rem;
}

.public-link-field input {
  min-width: 0;
  min-height: 2.65rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: #fff;
  color: var(--ink);
  padding: 0 0.8rem;
}

:root[data-theme="dark"] .public-link-field input {
  background: #0f1821;
}

:root[data-theme="dark"] .public-link-field {
  border-color: rgba(109, 168, 240, 0.22);
  background: rgba(109, 168, 240, 0.09);
}

.inline-status {
  margin-top: 0.75rem;
  font-size: 0.9rem;
}

.help-card p {
  margin: 20px 0;
}

.qr-code {
  position: relative;
  width: 100%;
  aspect-ratio: 1;
  border-radius: 8px;
  background:
    repeating-linear-gradient(90deg, rgba(23, 32, 38, 0.95) 0 0.35rem, transparent 0.35rem 0.7rem),
    repeating-linear-gradient(0deg, transparent 0 0.45rem, rgba(23, 32, 38, 0.95) 0.45rem 0.68rem);
  overflow: hidden;
}

.qr-code.qr-empty {
  border: 1px dashed var(--line);
  background: #f2f6f9;
}

.qr-code:not(.qr-empty) {
  background: #fff;
}

.qr-code strong {
  position: absolute;
  inset: 50%;
  transform: translate(-50%, -50%);
  display: grid;
  place-items: center;
  width: 5rem;
  height: 5rem;
  border-radius: 8px;
  background: #fff;
  color: var(--blue);
  font-size: 1.6rem;
  font-weight: 700;
}

.qr-code img {
  position: absolute;
  inset: 0;
  width: 100%;
  height: 100%;
  object-fit: contain;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: #fff;
}

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

.help-card ol {
  margin: 1rem 0 0;
  padding-left: 1.2rem;
}

.site-footer {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
  margin: 1rem 0 2rem;
  padding: 1rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.72);
}

.site-footer div,
.site-footer nav {
  display: flex;
  gap: 0.7rem;
  align-items: center;
  flex-wrap: wrap;
}

.site-footer span,
.site-footer a,
.site-footer button {
  color: var(--muted);
  font-size: 0.9rem;
}

.site-footer a,
.site-footer button {
  border: 0;
  background: transparent;
  padding: 0;
  text-decoration: none;
  font-weight: 700;
}

.site-footer a:hover,
.site-footer button:hover {
  color: var(--blue);
}

.site-footer .footer-social-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  border: 0;
  border-radius: 999px;
  background: transparent;
  padding: 0;
}

.site-footer .footer-social-link:hover,
.site-footer .footer-social-link:focus-visible {
  background: rgba(34, 102, 173, 0.08);
}

.site-footer .footer-social-link .icon {
  width: 1.55rem;
  height: 1.55rem;
}

.manual-page {
  padding-bottom: 1.5rem;
}

.manual-header {
  grid-template-columns: 1fr auto;
}

.manual-hero {
  margin-top: 1rem;
}

.manual-layout {
  display: grid;
  grid-template-columns: minmax(13rem, 16rem) 1fr;
  gap: 1rem;
  align-items: start;
}

.manual-index {
  position: sticky;
  top: 6.2rem;
  display: grid;
  gap: 0.35rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.86);
  box-shadow: 0 10px 30px rgba(23, 32, 38, 0.08);
  padding: 0.85rem;
}

.manual-index strong {
  margin-bottom: 0.25rem;
  color: var(--ink);
}

.manual-index a {
  border-radius: 8px;
  color: var(--muted);
  padding: 0.45rem 0.55rem;
  text-decoration: none;
  font-weight: 700;
}

.manual-index a:hover,
.manual-index a:focus-visible {
  background: var(--soft);
  color: var(--blue);
}

.manual-content {
  display: grid;
  gap: 1rem;
  min-width: 0;
}

.manual-card {
  scroll-margin-top: 7rem;
  border: 1px solid var(--line);
  border-radius: 8px;
  background: rgba(255, 255, 255, 0.92);
  box-shadow: 0 10px 30px rgba(23, 32, 38, 0.08);
  padding: clamp(1rem, 2.5vw, 1.4rem);
}

.manual-card h2 {
  margin-bottom: 0.65rem;
}

.manual-card p,
.manual-card li,
.manual-card dd {
  color: var(--muted);
  line-height: 1.6;
}

.manual-card ul {
  display: grid;
  gap: 0.45rem;
  margin: 0.75rem 0 0;
  padding-left: 1.2rem;
}

.manual-card strong,
.manual-card dt {
  color: var(--ink);
}

.manual-faq {
  display: grid;
  gap: 0.75rem;
  margin: 0.75rem 0 0;
}

.manual-faq dt {
  font-weight: 800;
}

.manual-faq dd {
  margin: 0;
}

:root[data-theme="dark"] .manual-index,
:root[data-theme="dark"] .manual-card {
  background: rgba(17, 26, 35, 0.94);
  box-shadow: 0 14px 38px rgba(0, 0, 0, 0.26);
}

:root[data-theme="dark"] .album-search-card {
  background: #13281f;
}

:root[data-theme="dark"] .album-toolbar .icon-action {
  background: #0f1821;
  color: var(--muted);
}

:root[data-theme="dark"] .search-clear-btn {
  background: #172331;
  color: var(--muted);
}

:root[data-theme="dark"] .search-clear-btn:hover,
:root[data-theme="dark"] .search-clear-btn:focus-visible {
  background: rgba(255, 133, 133, 0.14);
  color: var(--red);
}

:root[data-theme="dark"] .album-toolbar .icon-action:hover,
:root[data-theme="dark"] .album-toolbar .icon-action:focus-visible {
  color: var(--blue);
}

:root[data-theme="dark"] .album-toolbar .icon-action.is-active {
  background: var(--blue);
  color: #07111b;
  box-shadow: 0 0 0 2px rgba(106, 174, 244, 0.18), 0 8px 18px rgba(0, 0, 0, 0.26);
}

:root[data-theme="dark"] .side-panel {
  background:
    linear-gradient(180deg, rgba(19, 48, 76, 0.78), rgba(14, 23, 31, 0.96)),
    #0f1821;
}

:root[data-theme="dark"] .quick-stats article,
:root[data-theme="dark"] .backup-card,
:root[data-theme="dark"] .manual-backup,
:root[data-theme="dark"] .save-status,
:root[data-theme="dark"] .chart,
:root[data-theme="dark"] .skills-panel header,
:root[data-theme="dark"] .skills-panel dl div,
:root[data-theme="dark"] .public-list p,
:root[data-theme="dark"] .account-form input:disabled,
:root[data-theme="dark"] .account-form textarea:disabled,
:root[data-theme="dark"] .public-trade-box {
  background: #0f1821;
}

:root[data-theme="dark"] .info-badge {
  border-color: rgba(109, 168, 240, 0.36);
  background: rgba(109, 168, 240, 0.16);
  color: var(--blue);
}

:root[data-theme="dark"] .info-badge::after,
:root[data-theme="dark"] .info-badge::before {
  background: #edf4fb;
  color: #07111b;
}

:root[data-theme="dark"] .file-action.has-tooltip::after,
:root[data-theme="dark"] .file-action.has-tooltip::before {
  background: #edf4fb;
  color: #07111b;
}

:root[data-theme="dark"] .save-status {
  background: rgba(77, 211, 164, 0.08);
  border-color: rgba(77, 211, 164, 0.2);
}

:root[data-theme="dark"] .ring span,
:root[data-theme="dark"] .modal-close,
:root[data-theme="dark"] .account-tabs button.active {
  background: #0f1821;
  color: var(--ink);
}

:root[data-theme="dark"] .modal-close:hover,
:root[data-theme="dark"] .modal-close:focus-visible {
  background: #1c2a38;
  border-color: rgba(109, 168, 240, 0.28);
}

:root[data-theme="dark"] .status-tabs button {
  background: #0f1821;
  color: var(--muted);
  border-color: var(--line);
}

:root[data-theme="dark"] .status-tabs button.active {
  background: rgba(109, 168, 240, 0.22);
  color: var(--blue);
  border-color: rgba(109, 168, 240, 0.42);
  box-shadow: 0 0 0 2px rgba(109, 168, 240, 0.12);
}

:root[data-theme="dark"] .status-tabs button:hover,
:root[data-theme="dark"] .status-tabs button:focus-visible,
:root[data-theme="dark"] .panel-actions .secondary-action:hover,
:root[data-theme="dark"] .panel-actions .secondary-action:focus-visible,
:root[data-theme="dark"] .panel-actions .secondary-action.is-active {
  background: rgba(109, 168, 240, 0.16);
  color: var(--blue);
  border-color: rgba(109, 168, 240, 0.46);
  box-shadow: 0 8px 18px rgba(0, 0, 0, 0.22), 0 0 0 2px rgba(109, 168, 240, 0.08);
}

:root[data-theme="dark"] .duplicate-badge {
  color: #07111b;
}

@media (max-width: 980px) {
  .site-header {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 2.75rem;
    align-items: center;
    gap: 0.75rem;
  }

  .brand {
    min-width: 0;
  }

  .brand-logo {
    width: clamp(9.5rem, 48vw, 12.25rem);
  }

  .menu-toggle {
    display: grid;
    justify-self: end;
  }

  .header-menu {
    display: none;
    grid-column: 1 / -1;
    gap: 0.75rem;
  }

  .site-header.menu-open .header-menu {
    display: grid;
  }

  .main-nav {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    justify-content: stretch;
    width: 100%;
  }

  .main-nav button {
    min-width: 0;
    padding: 0 0.55rem;
  }

  .header-actions {
    justify-content: flex-start;
  }

  .hero-panel,
  .workspace,
  .trade-card,
  .public-layout,
  .help-layout {
    grid-template-columns: 1fr;
  }

  .album-search-card {
    top: 5.15rem;
  }

  .site-footer {
    align-items: flex-start;
    flex-direction: column;
  }

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

  .side-panel {
    position: static;
  }

}

@media (max-width: 680px) {
  .site-shell {
    width: calc(100% - 0.9rem);
    max-width: 1180px;
  }

  .summary-grid,
  .skills-panel dl {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .hero-panel {
    gap: 0.75rem;
    padding: 0.85rem;
    width: 100%;
    max-width: 100%;
  }

  h1 {
    overflow-wrap: anywhere;
  }

  .quick-stats {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.45rem;
  }

  .quick-stats article {
    padding: 0.65rem;
  }

  .quick-stats span {
    font-size: 0.66rem;
    letter-spacing: 0.04em;
  }

  .quick-stats strong {
    font-size: 1.45rem;
  }

  .main-nav {
    grid-template-columns: 1fr;
  }

  .section-grid {
    grid-template-columns: repeat(3, minmax(min(6.5rem, calc((100% - 0.9rem) / 3)), 1fr));
    gap: 0.45rem;
  }

  .status-tabs {
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.35rem;
  }

  .status-tabs button {
    min-width: 0;
    padding: 0 0.25rem;
    font-size: 0.82rem;
    white-space: nowrap;
  }

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

  .discover-match-grid {
    grid-template-columns: 1fr;
  }

  .album-preview-actions {
    grid-template-columns: 1fr;
  }

  .manual-header {
    grid-template-columns: 1fr;
  }

  .manual-layout {
    grid-template-columns: 1fr;
  }

  .manual-index {
    position: static;
  }

  .side-panel,
  .album-workarea,
  .album-sections,
  .album-search-card,
  .album-section,
  .section-grid,
  .status-tabs,
  .panel-actions {
    width: 100%;
    max-width: 100%;
  }

  .workspace {
    justify-items: stretch;
  }

  .album-workarea {
    order: 1;
  }

  .side-panel {
    order: 2;
    overflow-x: hidden;
  }

  .album-search-card {
    position: sticky;
    top: 4.85rem;
    padding: 0.65rem;
  }

  .album-search-row {
    grid-template-columns: 1fr;
  }

  .album-toolbar {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
  }

  .album-toolbar .icon-action {
    width: 100%;
  }

  .section-quick-nav {
    display: flex;
    flex-wrap: nowrap;
    overflow-x: auto;
    padding: 0.6rem;
    scrollbar-width: thin;
  }

  .section-jump {
    flex: 0 0 auto;
    width: 2.45rem;
    height: 2.45rem;
  }

  .section-jump-icon {
    width: calc(100% - 0.38rem);
    height: calc(100% - 0.38rem);
  }

  .section-jump .country-flag {
    width: 1.7rem;
    height: 1.7rem;
  }

  .album-section {
    scroll-margin-top: 7.3rem;
  }

  .sticker-tile {
    padding: 0.58rem;
  }

  .sticker-main {
    gap: 0.35rem;
  }

  .sticker-number {
    font-size: 0.96rem;
  }

  .quantity-label {
    font-size: 0.7rem;
  }

  .tile-actions {
    gap: 0.35rem;
    margin-top: 0.55rem;
  }

  .tile-actions button {
    min-height: 2.25rem;
    padding: 0;
  }

  .duplicate-badge {
    min-width: 1.55rem;
    height: 1.55rem;
    font-size: 0.78rem;
  }
}

@media (max-width: 430px) {
  .summary-grid,
  .skills-panel dl {
    grid-template-columns: 1fr;
  }

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

  .header-actions,
  .button-row {
    align-items: stretch;
    flex-direction: column;
  }

  .public-link-field div {
    grid-template-columns: 1fr;
  }

  .secondary-action,
  .primary-action,
  .danger-action {
    width: 100%;
  }
}

@media (prefers-reduced-motion: reduce) {
  html {
    scroll-behavior: auto;
  }

  *,
  *::before,
  *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    scroll-behavior: auto !important;
    transition-duration: 0.01ms !important;
  }
}
