@import url('https://fonts.googleapis.com/css2?family=Baloo+2:wght@600;700&family=Nunito:wght@400;600;700&display=swap');

:root {
  --ink: #0D0D0D;
  --ink-soft: #3C4C59;
  --steel: #8094A6;
  --mist: #BACBD9;
  --fog: #EBEFF2;
  --sky: var(--fog);
  --sky-deep: var(--mist);
  --sand: var(--fog);
  --panel: var(--fog);
  --panel-2: var(--mist);
  --line: var(--mist);
  --accent: var(--ink-soft);
  --accent-2: var(--steel);
  --accent-3: var(--mist);
  --text: var(--ink);
  --muted: var(--steel);
  --shadow: 0 16px 28px rgba(60, 76, 89, 0.18);
  --radius-lg: 18px;
  --radius-md: 14px;
  --radius-sm: 10px;
  --content-max: 1400px;
}

* {
  box-sizing: border-box;
}

html, body {
  height: 100%;
}

body {
  margin: 0;
  font-family: "Nunito", system-ui, -apple-system, "Segoe UI", sans-serif;
  color: var(--text);
  background:
    radial-gradient(900px 600px at 10% 0%, rgba(186, 203, 217, 0.6), transparent 60%),
    radial-gradient(900px 600px at 90% 15%, rgba(128, 148, 166, 0.35), transparent 65%),
    linear-gradient(180deg, var(--sky) 0%, var(--sky-deep) 60%, var(--sand) 100%);
  background-attachment: fixed;
  overflow-x: hidden;
}

body::before {
  content: "";
  position: fixed;
  inset: 0;
  background:
    radial-gradient(circle at 20% 20%, rgba(186, 203, 217, 0.45) 1px, transparent 1px),
    radial-gradient(circle at 70% 40%, rgba(128, 148, 166, 0.35) 1px, transparent 1px);
  background-size: 30px 30px, 34px 34px;
  opacity: 0.3;
  pointer-events: none;
  z-index: 0;
}

h1, h2, h3 {
  font-family: "Baloo 2", "Nunito", sans-serif;
  margin: 0;
  letter-spacing: 0.01em;
}

p {
  margin: 0;
}

button, input {
  font: inherit;
}

img {
  max-width: 100%;
  display: block;
}

.app {
  min-height: 100vh;
}

.bg-orb {
  display: block;
  position: fixed;
  border-radius: 999px;
  filter: blur(24px);
  opacity: 0.45;
  pointer-events: none;
  z-index: 0;
  mix-blend-mode: multiply;
}

.bg-orb--one {
  width: 320px;
  height: 320px;
  top: -80px;
  left: -40px;
  background: radial-gradient(circle at 30% 30%, rgba(128, 148, 166, 0.55), rgba(128, 148, 166, 0) 70%);
}

.bg-orb--two {
  width: 420px;
  height: 420px;
  top: 120px;
  right: -120px;
  background: radial-gradient(circle at 40% 40%, rgba(186, 203, 217, 0.55), rgba(186, 203, 217, 0) 70%);
}

.bg-orb--three {
  width: 360px;
  height: 360px;
  bottom: -120px;
  left: 10%;
  background: radial-gradient(circle at 50% 50%, rgba(60, 76, 89, 0.4), rgba(60, 76, 89, 0) 70%);
}

.page {
  max-width: none;
  width: 100%;
  margin: 0;
  padding: 20px 22px 90px;
  position: relative;
  z-index: 1;
}

.topbar {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 16px;
  padding: 14px 18px;
  border-radius: var(--radius-lg);
  border: 2px solid var(--accent-2);
  background: linear-gradient(180deg, rgba(235, 239, 242, 0.95), rgba(186, 203, 217, 0.65));
  box-shadow: var(--shadow);
  backdrop-filter: blur(8px);
  position: sticky;
  top: 16px;
  z-index: 5;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  font-weight: 700;
  color: var(--text);
}

.brand__mark {
  width: 36px;
  height: 36px;
  display: grid;
  place-items: center;
  border-radius: 10px;
  background: var(--accent);
  border: 2px solid var(--accent-2);
  color: var(--panel);
  font-weight: 800;
}

.brand__text {
  font-size: 1rem;
  text-transform: uppercase;
}

.nav {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  padding: 6px;
  border-radius: 999px;
  border: 2px solid var(--line);
  background: rgba(235, 239, 242, 0.8);
}

.nav__link {
  border: 2px solid transparent;
  background: transparent;
  color: var(--text);
  padding: 8px 14px;
  border-radius: 999px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s ease, border-color 0.2s ease, transform 0.2s ease;
}

.nav__link.is-active {
  background: var(--accent);
  color: var(--panel);
  border-color: var(--accent-2);
}

.nav-toggle {
  display: none;
  flex-direction: column;
  gap: 4px;
  border: 2px solid var(--accent-2);
  background: transparent;
  border-radius: 8px;
  padding: 6px;
  cursor: pointer;
}

.nav-toggle span {
  width: 18px;
  height: 2px;
  background: var(--accent);
}

.auth {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
  flex-wrap: wrap;
}

.lang-switch {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 6px 8px;
  border-radius: 999px;
  border: 2px solid var(--line);
  background: rgba(235, 239, 242, 0.92);
}

.lang-btn {
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 2px solid transparent;
  background: var(--panel);
  display: grid;
  place-items: center;
  font-size: 1.15rem;
  line-height: 1;
  cursor: pointer;
  transition: transform 0.15s ease, border-color 0.2s ease, box-shadow 0.2s ease;
}

.lang-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 12px rgba(60, 76, 89, 0.18);
}

.lang-btn.is-active {
  border-color: var(--accent-2);
  background: var(--accent-3);
  box-shadow: 0 6px 12px rgba(60, 76, 89, 0.18);
}

.lang-btn:focus-visible {
  outline: 3px solid rgba(128, 148, 166, 0.35);
  outline-offset: 2px;
}

.user {
  display: flex;
  align-items: center;
  gap: 10px;
}

.user__name {
  font-weight: 700;
  color: var(--accent);
}

.btn {
  border-radius: 999px;
  padding: 10px 16px;
  border: 2px solid transparent;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.btn--small {
  padding: 8px 12px;
  font-size: 0.9rem;
}

.btn--primary {
  background: var(--accent);
  color: var(--panel);
  border-color: var(--accent-2);
  box-shadow: 0 8px 14px rgba(60, 76, 89, 0.22);
}

.btn--ghost {
  background: var(--panel);
  color: var(--accent);
  border-color: var(--line);
}

.btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(60, 76, 89, 0.18);
}

.btn:focus-visible {
  outline: 3px solid rgba(128, 148, 166, 0.35);
  outline-offset: 2px;
}

.shell {
  display: grid;
  grid-template-columns: 240px minmax(0, 1fr) 240px;
  gap: 22px;
  margin-top: 22px;
  align-items: start;
}

.sidebar {
  display: grid;
  gap: 16px;
  align-self: start;
}

.main {
  min-width: 0;
  display: grid;
  gap: 18px;
  align-content: start;
}

.panel {
  background: var(--panel);
  border: 2px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 16px;
  box-shadow: var(--shadow);
}

.panel--block {
  display: grid;
  gap: 12px;
}

.panel__title {
  font-size: 1.1rem;
}

.panel__title-row {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.menu-list {
  display: grid;
  gap: 8px;
}

.menu-btn {
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 2px solid var(--line);
  background: var(--panel);
  color: var(--accent);
  font-weight: 700;
  cursor: pointer;
  text-align: left;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.menu-btn.is-active {
  background: var(--accent-3);
  border-color: var(--accent-2);
  box-shadow: 0 6px 14px rgba(60, 76, 89, 0.18);
}

.menu-btn:hover {
  transform: translateY(-1px);
}

.link {
  border: none;
  background: none;
  color: var(--accent);
  font-weight: 700;
  cursor: pointer;
  padding: 0;
}

.muted {
  color: var(--muted);
  font-size: 0.95rem;
}

.view {
  margin-top: 0;
  display: none;
}

.view--active {
  display: grid;
  gap: 18px;
}

.eyebrow {
  font-size: 0.75rem;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--muted);
  margin-bottom: 6px;
}

.play-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 16px 18px;
  border-radius: var(--radius-lg);
  border: 2px solid var(--line);
  background: var(--panel);
  box-shadow: var(--shadow);
}

.play-title {
  font-size: clamp(2rem, 3vw, 2.8rem);
  line-height: 1.1;
}

.panel__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 10px;
  color: var(--muted);
}

.pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  border-radius: 999px;
  border: 2px solid var(--line);
  background: var(--panel);
  color: var(--accent);
  font-size: 0.85rem;
}

.mono {
  font-family: "Nunito", sans-serif;
  font-size: 0.85rem;
  font-weight: 700;
}

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

.play-actions.is-disabled {
  opacity: 0.5;
  pointer-events: none;
}

.board-wrap {
  position: relative;
}

.fav-toggle {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 2px solid var(--line);
  background: rgba(235, 239, 242, 0.95);
  display: grid;
  place-items: center;
  font-size: 1.35rem;
  cursor: pointer;
  z-index: 3;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.fav-toggle:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 16px rgba(60, 76, 89, 0.18);
}

.fav-toggle.is-active {
  border-color: var(--accent-2);
  background: rgba(128, 148, 166, 0.18);
  color: var(--accent);
}

.calendar-fav {
  position: absolute;
  top: 6px;
  right: 6px;
  width: 34px;
  height: 34px;
  border-radius: 50%;
  border: 1px solid var(--line);
  background: rgba(235, 239, 242, 0.9);
  display: grid;
  place-items: center;
  font-size: 1rem;
  cursor: pointer;
}

.calendar-fav.is-active {
  border-color: var(--accent-2);
  background: rgba(128, 148, 166, 0.2);
  color: var(--accent);
}

.favorites-section {
  margin-top: 18px;
  display: grid;
  gap: 12px;
}

.category-shell {
  border-radius: var(--radius-lg);
  border: 2px solid var(--line);
  background: var(--panel);
  padding: 14px 16px;
  box-shadow: var(--shadow);
}

.starter-board {
  position: relative;
  overflow: hidden;
}

.starter-board--active {
  background: linear-gradient(180deg, rgba(235, 239, 242, 0.95), rgba(186, 203, 217, 0.55));
}

.starter-board--active::after {
  content: "";
  position: absolute;
  inset: 12px;
  border-radius: var(--radius-md);
  border: 1px dashed rgba(128, 148, 166, 0.5);
  pointer-events: none;
}

.starter-actions {
  margin-top: 14px;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  border: 2px solid rgba(128, 148, 166, 0.35);
  background: rgba(235, 239, 242, 0.7);
  display: grid;
  gap: 10px;
}

.starter-lead {
  margin: 0;
  color: var(--accent);
  font-weight: 600;
}

.starter-buttons {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
}

.category-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  margin-bottom: 12px;
}

.category-header__text {
  display: grid;
  gap: 4px;
}

.category-title {
  margin: 0;
  font-size: 1.1rem;
  font-family: "Baloo 2", "Nunito", sans-serif;
}

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

.category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 12px;
}

.category-footer {
  margin-top: 12px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
}

.category-card {
  border-radius: var(--radius-md);
  border: 2px solid var(--line);
  background: var(--panel);
  padding: 12px 14px;
  text-align: left;
  display: grid;
  gap: 6px;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
}

.category-card:hover {
  transform: translateY(-1px);
  box-shadow: 0 8px 16px rgba(60, 76, 89, 0.18);
}

.category-card:focus-visible {
  outline: 3px solid rgba(128, 148, 166, 0.35);
  outline-offset: 2px;
}

.category-card.is-active {
  border-color: var(--accent-2);
  background: rgba(186, 203, 217, 0.5);
}

.category-card__title {
  font-weight: 700;
}

.category-card__meta {
  color: var(--muted);
  font-size: 0.85rem;
}

.profile-hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 18px 20px;
  border-radius: var(--radius-lg);
  border: 2px solid var(--line);
  background: linear-gradient(180deg, rgba(235, 239, 242, 0.98), rgba(186, 203, 217, 0.65));
  box-shadow: var(--shadow);
}

.profile-subtitle {
  color: var(--muted);
  margin-top: 4px;
  font-size: 1rem;
}

.profile-grid {
  display: grid;
  grid-template-columns: minmax(0, 1fr) minmax(0, 1fr);
  gap: 18px;
}

.profile-panel {
  display: grid;
  gap: 14px;
  padding: 18px 20px;
  border-radius: var(--radius-lg);
  border: 2px solid var(--line);
  background: var(--panel);
  box-shadow: var(--shadow);
}

.collection-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 16px;
  padding: 16px 18px;
  border-radius: var(--radius-lg);
  border: 2px solid var(--line);
  background: var(--panel);
  box-shadow: var(--shadow);
}

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

.mini-card {
  display: grid;
  grid-template-columns: 44px 1fr auto;
  align-items: center;
  gap: 10px;
  padding: 10px;
  border-radius: var(--radius-md);
  border: 2px solid var(--line);
  background: var(--panel);
}

.mini-card__meta {
  display: grid;
  gap: 2px;
}

.mini-card__thumb {
  width: 44px;
  height: 44px;
  border-radius: 10px;
  background-size: cover;
  background-position: center;
  border: 2px solid var(--line);
}

.mini-card__title {
  font-weight: 700;
}

.mini-card__date {
  font-size: 0.82rem;
  color: var(--muted);
}

.mini-card__pieces {
  font-size: 0.8rem;
  color: var(--muted);
}

.collection-header h2 {
  font-size: 1.3rem;
}

.collection-tabs {
  display: inline-flex;
  gap: 6px;
  margin-top: 14px;
  padding: 6px;
  border-radius: 999px;
  border: 2px solid var(--line);
  background: rgba(235, 239, 242, 0.8);
}

.tab-btn {
  border: 2px solid transparent;
  background: transparent;
  color: var(--muted);
  padding: 8px 16px;
  border-radius: 999px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.tab-btn.is-active {
  background: var(--accent);
  color: var(--panel);
  border-color: var(--accent-2);
}

.collection-pane {
  display: none;
  margin-top: 16px;
}

.collection-pane--active {
  display: block;
}

.collection-subtitle {
  font-weight: 700;
  color: var(--muted);
  margin-bottom: 12px;
}

.calendar-header {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-radius: var(--radius-md);
  border: 2px solid var(--line);
  background: var(--panel);
  box-shadow: var(--shadow);
}

.calendar-title {
  text-align: center;
  font-weight: 700;
}

.calendar-weekdays {
  margin-top: 10px;
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  text-transform: uppercase;
  font-size: 0.75rem;
  color: var(--muted);
  gap: 6px;
}

.calendar-weekdays span {
  text-align: center;
  padding: 6px 0;
}

.calendar-multi {
  margin-top: 12px;
}

.calendar-pack {
  display: none;
  border-radius: var(--radius-lg);
  border: 2px solid var(--line);
  background: var(--panel);
  padding: 12px;
  box-shadow: var(--shadow);
  gap: 10px;
}

.calendar-pack--active {
  display: grid;
}

.calendar-pack__title {
  margin: 0;
  font-size: 1rem;
}

.calendar-tabs {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 12px;
  padding: 6px;
  border-radius: 999px;
  border: 2px solid var(--line);
  background: rgba(235, 239, 242, 0.8);
}

.calendar-tab {
  border: 2px solid transparent;
  background: transparent;
  color: var(--muted);
  padding: 6px 12px;
  border-radius: 999px;
  font-weight: 700;
  cursor: pointer;
  transition: background 0.2s ease, color 0.2s ease, border-color 0.2s ease;
}

.calendar-tab.is-active {
  background: var(--accent);
  color: var(--panel);
  border-color: var(--accent-2);
}

.calendar-grid {
  margin-top: 8px;
  display: grid;
  grid-template-columns: repeat(7, minmax(0, 1fr));
  gap: 10px;
}

.calendar-day {
  position: relative;
  border-radius: 14px;
  border: 2px solid var(--line);
  background: var(--panel);
  min-height: 92px;
  padding: 10px;
  display: grid;
  gap: 8px;
  box-shadow: var(--shadow);
}

.calendar-day--inactive {
  opacity: 0.45;
  pointer-events: none;
}

.calendar-day--locked {
  background: rgba(186, 203, 217, 0.45);
  color: var(--muted);
}

.calendar-day--owned {
  border-color: var(--accent-2);
  box-shadow: 0 10px 20px rgba(60, 76, 89, 0.18);
}

.calendar-day--today {
  border-color: var(--accent);
  box-shadow: 0 12px 22px rgba(60, 76, 89, 0.2);
}

.calendar-day__num {
  font-weight: 800;
  font-size: 1rem;
}

.calendar-day__thumb {
  width: 100%;
  aspect-ratio: 16 / 9;
  border-radius: 10px;
  background-size: cover;
  background-position: center;
  border: 2px solid var(--line);
}

.calendar-day--locked .calendar-day__thumb {
  filter: grayscale(60%) blur(0.4px);
  opacity: 0.6;
}

.calendar-day__meta {
  font-size: 0.78rem;
  color: var(--muted);
}

.calendar-day__cta {
  margin-top: auto;
}

.calendar-btn {
  width: 100%;
  border-radius: 999px;
  border: 2px solid var(--line);
  background: var(--panel);
  padding: 6px 10px;
  font-weight: 700;
  cursor: pointer;
}

.calendar-btn--play {
  border-color: var(--accent-2);
  color: var(--accent);
  background: rgba(186, 203, 217, 0.45);
}

.calendar-btn--buy {
  border-color: var(--accent-2);
  color: var(--accent);
  background: rgba(186, 203, 217, 0.3);
}

.calendar-btn--lock {
  border-color: var(--line);
  color: var(--muted);
  background: rgba(186, 203, 217, 0.35);
  cursor: default;
}

.purchased-grid {
  display: grid;
  gap: 16px;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
}

.pack-card {
  border-radius: var(--radius-lg);
  border: 2px solid var(--line);
  background: var(--panel);
  padding: 14px;
  display: grid;
  gap: 10px;
  box-shadow: var(--shadow);
}

.pack-card--locked {
  background: rgba(186, 203, 217, 0.35);
  opacity: 0.7;
}

.pack-card__title {
  font-weight: 700;
  font-size: 1rem;
}

.pack-card__meta {
  color: var(--muted);
  font-size: 0.9rem;
}

.pack-card__actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.pack-puzzle {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  border-radius: 999px;
  border: 2px solid var(--line);
  background: var(--panel);
  padding: 6px 10px 6px 6px;
  font-weight: 700;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.pack-puzzle:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 12px rgba(60, 76, 89, 0.18);
}

.pack-puzzle__thumb {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background-size: cover;
  background-position: center;
  border: 2px solid var(--line);
}

.pack-puzzle__title {
  font-size: 0.85rem;
  color: var(--accent);
}

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

.solved-card {
  display: grid;
  grid-template-rows: auto 1fr;
  border-radius: var(--radius-lg);
  border: 2px solid var(--line);
  background: var(--panel);
  overflow: hidden;
  box-shadow: var(--shadow);
}

.solved-thumb {
  aspect-ratio: 4 / 3;
  background-size: cover;
  background-position: center;
}

.solved-body {
  padding: 12px;
  display: grid;
  gap: 8px;
}

.solved-title {
  font-weight: 700;
}

.solved-meta {
  color: var(--muted);
  font-size: 0.9rem;
}

.solved-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.empty {
  margin-top: 16px;
  padding: 18px;
  border-radius: var(--radius-md);
  border: 2px dashed var(--line);
  color: var(--muted);
  text-align: center;
  background: var(--panel);
}

#board {
  position: relative;
  width: 100%;
  border-radius: 16px;
  border: 2px solid var(--line);
  background: linear-gradient(180deg, rgba(235, 239, 242, 0.95), rgba(186, 203, 217, 0.7));
  box-shadow: inset 0 0 0 2px rgba(235, 239, 242, 0.6), 0 18px 30px rgba(60, 76, 89, 0.18);
  overflow: visible;
  min-height: 360px;
  margin: 0 auto;
}

.board__veil {
  position: absolute;
  inset: 0;
  border-radius: inherit;
  background: linear-gradient(180deg, rgba(235, 239, 242, 0.25), rgba(186, 203, 217, 0.55));
  pointer-events: none;
  transition: opacity 0.6s ease;
}

.board--solved .board__veil {
  opacity: 0;
}

.piece--solved {
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.6s ease;
}

.win {
  padding: 12px;
  border-radius: var(--radius-md);
  background: var(--panel);
  border: 2px solid var(--accent-2);
}

.coins {
  margin-top: 10px;
  padding: 10px 12px;
  border-radius: var(--radius-md);
  border: 2px solid var(--line);
  background: var(--panel);
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-weight: 700;
}

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

.coins__value {
  background: rgba(128, 148, 166, 0.25);
  color: var(--accent);
  padding: 4px 10px;
  border-radius: 999px;
  border: 2px solid rgba(128, 148, 166, 0.45);
}

.profile-card {
  display: grid;
  gap: 12px;
}

.profile__header {
  display: flex;
  align-items: center;
  gap: 12px;
}

.profile__avatar {
  width: 56px;
  height: 56px;
  border-radius: 50%;
  background: linear-gradient(140deg, var(--accent-2), var(--accent));
  border: 2px solid var(--panel);
  box-shadow: 0 6px 12px rgba(60, 76, 89, 0.18);
  display: grid;
  place-items: center;
  font-weight: 700;
  color: var(--panel);
  font-size: 1.1rem;
}

.profile__identity {
  display: grid;
  gap: 2px;
}

.profile__name {
  font-weight: 700;
}

.profile__email {
  color: var(--muted);
  font-size: 0.85rem;
}

.profile__hint {
  color: var(--muted);
  font-size: 0.85rem;
}

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

.profile__stat {
  border-radius: var(--radius-md);
  border: 2px solid var(--line);
  background: var(--panel);
  padding: 12px 14px;
  display: grid;
  gap: 4px;
}

.profile__stat-label {
  color: var(--muted);
  font-size: 0.8rem;
  text-transform: uppercase;
  letter-spacing: 0.1em;
}

.profile__stat-value {
  font-weight: 700;
  font-size: 1.2rem;
}

.badge-grid {
  display: grid;
  gap: 10px;
}

.badge-grid--large {
  gap: 14px;
}

.badge {
  display: grid;
  grid-template-columns: 52px 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 12px 14px;
  border-radius: var(--radius-md);
  border: 2px solid var(--line);
  background: var(--panel);
  box-shadow: 0 10px 18px rgba(60, 76, 89, 0.16);
}

.badge__icon {
  width: 52px;
  height: 52px;
  border-radius: 50%;
  border: 2px solid var(--line);
  background-size: cover;
  background-position: center;
  background-color: var(--panel);
}

.badge__title {
  font-weight: 700;
  font-size: 0.95rem;
}

.badge__meta {
  color: var(--muted);
  font-size: 0.82rem;
}

.badge__progress {
  font-weight: 700;
  font-size: 0.85rem;
  color: var(--accent);
  background: rgba(128, 148, 166, 0.2);
  border: 1px solid rgba(128, 148, 166, 0.35);
  border-radius: 999px;
  padding: 4px 8px;
}

.badge--locked {
  opacity: 0.7;
  filter: grayscale(0.15);
  box-shadow: none;
}

.badge:not(.badge--locked) {
  border-color: rgba(128, 148, 166, 0.6);
  background: var(--panel);
}

.win__title {
  font-weight: 700;
  font-size: 1rem;
}

.win__stats {
  margin-top: 6px;
  color: var(--muted);
  font-size: 0.9rem;
}

.ad-card {
  padding: 14px;
  border-radius: var(--radius-md);
  border: 2px dashed var(--line);
  background: var(--panel);
  text-align: center;
  font-weight: 700;
  color: var(--accent);
}

.ad-slot {
  display: grid;
  gap: 10px;
  padding: 16px;
  border-radius: var(--radius-md);
  border: 2px solid rgba(128, 148, 166, 0.4);
  background: linear-gradient(180deg, rgba(235, 239, 242, 0.9), rgba(186, 203, 217, 0.55));
  box-shadow: var(--shadow);
}

.ad-slot--placeholder {
  background: rgba(235, 239, 242, 0.7);
  box-shadow: none;
}

.ad-slot__eyebrow {
  font-size: 0.7rem;
  letter-spacing: 0.18em;
  text-transform: uppercase;
  color: var(--muted);
}

.ad-slot__title {
  font-weight: 800;
  font-size: 1rem;
  color: var(--accent);
}

.ad-slot__meta {
  font-size: 0.85rem;
  color: var(--muted);
}

.store-list {
  display: grid;
  gap: 8px;
}

.modal {
  position: fixed;
  inset: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 20px;
  background: rgba(60, 76, 89, 0.3);
  backdrop-filter: blur(4px);
  z-index: 20;
}

.modal__backdrop {
  position: absolute;
  inset: 0;
}

.modal__card {
  position: relative;
  background: var(--panel);
  border: 2px solid var(--line);
  border-radius: var(--radius-lg);
  padding: 18px;
  width: min(420px, 100%);
  box-shadow: var(--shadow);
}

.modal__header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.modal__lead {
  margin: 6px 0 14px;
  color: var(--muted);
  font-size: 0.95rem;
}






.modal__close {
  border: none;
  background: transparent;
  font-size: 1.4rem;
  color: var(--accent);
  cursor: pointer;
}

.modal__tabs {
  display: flex;
  gap: 8px;
  margin-top: 12px;
}

.tab {
  border: 2px solid transparent;
  background: var(--panel);
  border-radius: 999px;
  padding: 6px 10px;
  font-weight: 700;
  cursor: pointer;
  font-size: 0.85rem;
  color: var(--accent);
}

.tab.is-active {
  border-color: var(--accent-2);
}

.form {
  display: grid;
  gap: 12px;
  margin-top: 16px;
}

.field {
  display: grid;
  gap: 6px;
  font-size: 0.9rem;
  color: var(--muted);
}

.field input {
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  border: 2px solid var(--line);
  background: var(--panel);
  color: var(--text);
}

.form__message {
  margin-top: 12px;
  font-size: 0.9rem;
  color: var(--accent);
  min-height: 1.2em;
}

.hidden {
  display: none;
}

.sr-only {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border: 0;
}

.absolute {
  position: absolute;
}

.relative {
  position: relative;
}

.left-1\/2 {
  left: 50%;
}

.top-4 {
  top: 1rem;
}

.inset-0 {
  top: 0;
  right: 0;
  bottom: 0;
  left: 0;
}

.-translate-x-1\/2 {
  transform: translateX(-50%);
}

.overflow-hidden {
  overflow: hidden;
}

.overflow-visible {
  overflow: visible;
}

.rounded-2xl {
  border-radius: 1rem;
}

.border {
  border-width: 1px;
  border-style: solid;
}

.border-slate-800 {
  border-color: var(--line);
}

.bg-slate-950 {
  background-color: var(--accent);
}

.mt-4 {
  margin-top: 1rem;
}

.touch-none {
  touch-action: none;
}

.select-none {
  user-select: none;
}

@media (min-width: 1200px) {
  .shell {
    grid-template-columns: 260px minmax(0, 1fr) 260px;
  }
}

@media (min-width: 1100px) {
  .sidebar {
    position: sticky;
    top: 104px;
  }
}

@media (max-width: 1024px) {
  .shell {
    grid-template-columns: 1fr;
  }

  .sidebar--left {
    order: 1;
  }

  .main {
    order: 0;
  }

  .sidebar--right {
    order: 2;
  }
}

@media (max-width: 900px) {
  .topbar {
    grid-template-columns: auto auto;
    grid-template-areas:
      "brand toggle"
      "nav nav"
      "auth auth";
  }

  .brand {
    grid-area: brand;
  }

  .nav-toggle {
    grid-area: toggle;
    display: inline-flex;
    justify-self: end;
  }

  .nav {
    grid-area: nav;
    display: none;
    flex-direction: column;
    align-items: stretch;
    padding: 10px;
    border: 2px solid var(--line);
    border-radius: var(--radius-md);
    background: var(--panel);
  }

  .auth {
    grid-area: auth;
    display: none;
    justify-content: flex-start;
    flex-wrap: wrap;
  }

  .topbar.is-open .nav,
  .topbar.is-open .auth {
    display: flex;
  }

  .play-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .collection-header {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media (max-width: 640px) {
  .page {
    padding: 18px 12px 56px;
  }

  .play-actions .btn {
    flex: 1 1 100%;
  }

  .calendar-grid {
    gap: 6px;
  }

  .calendar-day {
    min-height: 76px;
    padding: 8px;
  }

  .calendar-day__meta {
    display: none;
  }

  #board {
    min-height: 300px;
  }

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

  .profile-hero {
    flex-direction: column;
    align-items: flex-start;
  }

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

  .category-header {
    flex-direction: column;
    align-items: flex-start;
  }

  .category-footer {
    justify-content: flex-start;
  }
}

@media (prefers-reduced-motion: reduce) {
  body::before {
    display: none;
  }
}

