:root {
  --fm-font-display: "Trebuchet MS", "Segoe UI", sans-serif;
  --fm-font-body: "Segoe UI", "Trebuchet MS", sans-serif;
}

* {
  box-sizing: border-box;
}

html {
  min-height: 100%;
  scroll-behavior: smooth;
}

body.app-shell {
  min-height: 100vh;
  margin: 0;
  color: var(--fm-text);
  font-family: var(--fm-font-body);
  background: var(--fm-bg-base);
  overflow-x: hidden;
}

body.app-shell::before {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -3;
  background-image: var(--fm-bg-image);
  background-size: cover;
  background-position: center top;
  background-repeat: no-repeat;
  transform: scale(1.02);
}

body.app-shell::after {
  content: "";
  position: fixed;
  inset: 0;
  z-index: -2;
  background: var(--fm-bg-overlay);
  pointer-events: none;
}

.app-bg,
.app-ornaments {
  position: fixed;
  inset: 0;
  z-index: -1;
  pointer-events: none;
}

.app-bg::before {
  content: "";
  position: absolute;
  inset: 0;
  opacity: 0.34;
  background-image:
    linear-gradient(90deg, var(--fm-field-lines) 1px, transparent 1px),
    linear-gradient(0deg, var(--fm-field-lines) 1px, transparent 1px);
  background-size: 84px 84px;
  mask-image: linear-gradient(180deg, rgba(0,0,0,0.72), transparent 80%);
}

.app-bg::after {
  content: "";
  position: absolute;
  width: min(72vw, 840px);
  height: min(72vw, 840px);
  right: -22vw;
  top: 4rem;
  border-radius: 50%;
  border: 1px solid var(--fm-field-lines);
  box-shadow: inset 0 0 0 3rem rgba(255,255,255,0.02);
  opacity: 0.7;
}

.app-ornament {
  position: absolute;
  filter: blur(0.1px);
  opacity: 0.7;
}

.app-ornament--ball {
  width: 86px;
  height: 86px;
  left: max(2rem, 7vw);
  bottom: 7rem;
  border-radius: 50%;
  background:
    radial-gradient(circle at 50% 50%, transparent 0 22%, rgba(0,0,0,0.18) 23% 25%, transparent 26%),
    conic-gradient(from 22deg, rgba(255,255,255,0.9), rgba(255,255,255,0.22), rgba(255,255,255,0.85));
  box-shadow: 0 18px 38px rgba(0,0,0,0.22);
}

.app-ornament--pitch {
  width: 210px;
  height: 120px;
  right: 9vw;
  bottom: 10rem;
  border: 2px solid var(--fm-field-lines);
  border-radius: 18px;
}

.app-ornament--pitch::before,
.app-ornament--pitch::after {
  content: "";
  position: absolute;
  border: 2px solid var(--fm-field-lines);
}

.app-ornament--pitch::before {
  inset: 18px 82px;
  border-radius: 999px;
}

.app-ornament--pitch::after {
  top: 0;
  bottom: 0;
  left: 50%;
  width: 0;
  border-width: 0 0 0 2px;
}

.app-ornament--lights {
  width: 360px;
  height: 360px;
  top: -90px;
  left: 50%;
  transform: translateX(-50%);
  background: radial-gradient(circle, rgba(255,255,255,0.25), transparent 58%);
}

.app-container {
  width: min(1280px, calc(100% - 2rem));
  padding-top: 2rem;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 1030;
  padding: 1rem 0 0.25rem;
}

.site-navbar {
  width: min(1320px, calc(100% - 1.25rem));
  margin: 0 auto;
  padding: 0.82rem 1rem;
  border: 1px solid var(--fm-header-border);
  border-radius: 1.6rem;
  background: var(--fm-header-bg);
  box-shadow: var(--fm-shadow-soft);
  backdrop-filter: blur(18px);
}

.site-navbar__inner {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.site-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.75rem;
  min-width: 210px;
  color: #fff !important;
  text-decoration: none;
}

.site-brand__crest {
  position: relative;
  display: inline-grid;
  place-items: center;
  width: 46px;
  height: 46px;
  border-radius: 16px;
  color: #06111f;
  background: var(--fm-button-bg);
  box-shadow: var(--fm-button-shadow);
  font-family: var(--fm-font-display);
  font-weight: 950;
  letter-spacing: -0.08em;
}

.site-brand__crest-ring {
  position: absolute;
  inset: 6px;
  border: 1px solid rgba(255,255,255,0.58);
  border-radius: 12px;
}

.site-brand__copy {
  display: grid;
  line-height: 1.05;
}

.site-brand__copy strong {
  font-family: var(--fm-font-display);
  font-size: 1.2rem;
  letter-spacing: -0.03em;
}

.site-brand__copy small {
  margin-top: 0.22rem;
  color: rgba(255,255,255,0.72);
  font-size: 0.75rem;
}

.worldcup-brand {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
  min-width: 0;
  max-width: 260px;
  padding: 0.38rem 0.72rem 0.38rem 0.42rem;
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 999px;
  color: #fff;
  background: linear-gradient(135deg, rgba(255,255,255,0.1), rgba(255,255,255,0.05));
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.08);
}

.worldcup-brand img {
  width: 60px;
  height: 34px;
  flex: 0 0 auto;
  border-radius: 0.68rem;
  object-fit: contain;
  display: block;
  background: rgba(5, 17, 31, 0.72);
}

.worldcup-brand span {
  display: grid;
  min-width: 0;
  line-height: 1;
}

.worldcup-brand strong,
.worldcup-brand small {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.worldcup-brand strong {
  font-size: 0.82rem;
  font-weight: 950;
}

.worldcup-brand small {
  margin-top: 0.16rem;
  color: rgba(255,255,255,0.64);
  font-size: 0.62rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.site-help-btn {
  border: 1px solid rgba(255,255,255,0.2);
  border-radius: 999px;
  color: #fff;
  background: rgba(255,255,255,0.08);
  font-size: 0.82rem;
  font-weight: 800;
}

.site-help-btn:hover,
.site-help-btn:focus {
  color: #fff;
  background: rgba(255,255,255,0.16);
}

.fm-tour {
  position: fixed;
  inset: 0;
  z-index: 1080;
}

.fm-tour__backdrop {
  position: absolute;
  inset: 0;
  background: rgba(4, 11, 22, 0.68);
}

.fm-tour__dialog {
  position: fixed;
  width: min(380px, calc(100vw - 2rem));
  max-height: calc(100vh - 2rem);
  padding: 1rem 1rem 0.95rem;
  border: 1px solid rgba(255,255,255,0.16);
  border-radius: 1.15rem;
  color: #fff;
  background: linear-gradient(180deg, rgba(9, 22, 39, 0.97), rgba(15, 34, 58, 0.95));
  box-shadow: 0 24px 60px rgba(0,0,0,0.38);
  overflow-y: auto;
  overscroll-behavior: contain;
}

.fm-tour__dialog::after {
  content: "";
  position: absolute;
  width: 18px;
  height: 18px;
  background: #0f223a;
  transform: rotate(45deg);
}

.fm-tour__dialog--top::after {
  top: -9px;
  left: 38px;
}

.fm-tour__dialog--bottom::after {
  bottom: -9px;
  left: 38px;
}

.fm-tour__dialog--center {
  top: 50% !important;
  left: 50% !important;
  transform: translate(-50%, -50%);
}

.fm-tour__dialog--center::after {
  display: none;
}

.fm-tour__eyebrow {
  margin-bottom: 0.4rem;
  color: rgba(255,255,255,0.72);
  font-size: 0.74rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.fm-tour__title {
  margin: 0 0 0.55rem;
  font-family: var(--fm-font-display);
  font-size: 1.35rem;
  font-weight: 900;
  letter-spacing: -0.03em;
}

.fm-tour__body {
  margin: 0;
  color: rgba(255,255,255,0.84);
  line-height: 1.5;
}

.fm-tour__actions {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  margin-top: 1rem;
}

.fm-tour__actions-main {
  display: flex;
  gap: 0.55rem;
}

.fm-tour-target-active {
  position: relative;
  z-index: 1082 !important;
  border-radius: 1rem;
  box-shadow: 0 0 0 4px rgba(255, 210, 63, 0.95), 0 0 0 9999px rgba(4, 11, 22, 0.72);
}

@media (max-width: 767.98px) {
  .fm-tour__dialog {
    width: calc(100vw - 1.25rem);
    max-height: calc(100vh - 1rem);
    padding: 0.95rem 0.95rem 0.9rem;
  }

  .fm-tour__actions {
    flex-direction: column;
  }

  .fm-tour__actions-main {
    justify-content: space-between;
  }

  .site-help-btn {
    width: 100%;
  }
}

.admin-table {
  margin-bottom: 0;
  color: var(--fm-text);
  --bs-table-bg: transparent;
  --bs-table-color: var(--fm-text);
  --bs-table-border-color: var(--fm-card-border);
  --bs-table-hover-bg: color-mix(in srgb, var(--fm-primary) 10%, transparent);
  --bs-table-hover-color: var(--fm-text);
}

.admin-table thead th {
  color: var(--fm-muted);
  font-size: 0.78rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.06em;
  border-bottom-width: 1px;
}

.admin-activity-list {
  display: grid;
  gap: 0.8rem;
}

.admin-activity-item {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 1rem;
  padding: 0.95rem 1rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 1rem;
  background: color-mix(in srgb, var(--fm-card-strong) 86%, transparent);
}

.admin-activity-item strong {
  display: block;
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: 1rem;
}

.admin-activity-item p,
.admin-activity-item small {
  color: var(--fm-muted);
}

.site-navbar__collapse {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex: 1 1 auto;
  gap: 1rem;
}

.site-navbar__links {
  display: flex;
  flex-wrap: wrap;
  gap: 0.18rem;
}

.site-navbar .nav-link {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 42px;
  padding: 0.58rem 0.72rem !important;
  border-radius: 999px;
  color: rgba(255,255,255,0.82) !important;
  font-weight: 800;
  font-size: 0.9rem;
  transition: 180ms ease;
}

.site-navbar .nav-link:hover,
.site-navbar .nav-link:focus {
  color: #fff !important;
  background: rgba(255,255,255,0.12);
  transform: translateY(-1px);
}

.site-mobile-primary-nav {
  display: none;
  gap: 0.45rem;
  flex: 1 1 100%;
  order: 4;
}

.site-mobile-primary-nav .nav-link {
  flex: 1 1 0;
  min-width: 0;
  padding-inline: 0.45rem !important;
  font-size: 0.78rem;
  text-align: center;
}

.site-navbar__actions {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  flex-wrap: wrap;
  gap: 0.65rem;
  margin-left: auto;
}

.theme-switcher {
  position: relative;
  flex: 0 0 auto;
}

.theme-switcher__toggle {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  min-width: 220px;
  padding: 0.55rem 0.8rem;
  border: 1px solid rgba(255,255,255,0.22);
  border-radius: 1rem;
  color: #fff;
  background: rgba(255,255,255,0.1);
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.08);
}

.theme-switcher__toggle:hover,
.theme-switcher__toggle:focus {
  color: #fff;
  border-color: rgba(255,255,255,0.4);
  background: rgba(255,255,255,0.16);
}

.theme-switcher__icon {
  display: grid;
  place-items: center;
  width: 44px;
  height: 36px;
  border-radius: 12px;
  color: var(--fm-button-text);
  background: var(--fm-button-bg);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.theme-switcher__text {
  display: grid;
  text-align: left;
  line-height: 1.08;
}

.theme-switcher__eyebrow {
  color: rgba(255,255,255,0.62);
  font-size: 0.68rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.theme-switcher__toggle strong {
  color: #fff;
  font-size: 0.88rem;
}

.theme-switcher__menu {
  width: min(390px, calc(100vw - 1.5rem));
  padding: 0.65rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 1.15rem;
  background: var(--fm-card-strong);
  box-shadow: var(--fm-shadow-card);
  overflow: hidden;
}

.theme-switcher__option {
  display: grid;
  grid-template-columns: 52px 1fr;
  gap: 0.8rem;
  width: 100%;
  padding: 0.72rem;
  border: 0;
  border-radius: 0.9rem;
  color: var(--fm-text);
  background: transparent;
  text-align: left;
}

.theme-switcher__option:hover,
.theme-switcher__option:focus,
.theme-switcher__option--active {
  background: color-mix(in srgb, var(--fm-primary) 13%, transparent);
}

.theme-switcher__swatch {
  width: 52px;
  height: 42px;
  border-radius: 14px;
  border: 1px solid rgba(255,255,255,0.38);
  background-size: cover;
  background-position: center;
  box-shadow: 0 10px 20px rgba(0,0,0,0.16);
}

.theme-switcher__swatch--stadium-elite { background-image: url("/images/themes/stadium-elite.svg"); }
.theme-switcher__swatch--world-pitch { background-image: url("/images/themes/world-pitch.svg"); }
.theme-switcher__swatch--sticker-album { background-image: url("/images/themes/sticker-album.svg"); }
.theme-switcher__swatch--world-festival { background-image: url("/images/themes/world-festival.svg"); }
.theme-switcher__swatch--legendary-cup { background-image: url("/images/themes/legendary-cup.svg"); }

.theme-switcher__copy {
  display: grid;
  gap: 0.15rem;
}

.theme-switcher__copy strong {
  color: var(--fm-heading);
  font-size: 0.96rem;
}

.theme-switcher__copy small {
  color: var(--fm-muted);
  font-size: 0.78rem;
  line-height: 1.25;
}

.site-user-pill {
  display: grid;
  min-width: 0;
  max-width: 240px;
  padding: 0.48rem 0.8rem;
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 999px;
  color: #fff;
  background: rgba(255,255,255,0.1);
  line-height: 1.06;
}

.site-user-pill__eyebrow {
  color: rgba(255,255,255,0.62);
  font-size: 0.65rem;
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.site-user-pill strong {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
  font-size: 0.82rem;
  max-width: 100%;
}

.site-navbar__account {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  min-width: 0;
}

.site-logout-form {
  margin: 0;
}

.site-footer {
  padding: 2rem 0 1.5rem;
}

.site-footer__content {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  width: min(1280px, calc(100% - 2rem));
  margin: 0 auto;
  padding: 1rem 1.2rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 1.2rem;
  color: var(--fm-muted);
  background: var(--fm-card-bg);
  backdrop-filter: blur(14px);
}

.site-footer__brand,
.site-footer__tagline {
  align-self: center;
}

.site-footer__author {
  display: grid;
  gap: 0.55rem;
  justify-items: center;
  text-align: center;
}

.site-footer__author-name {
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-weight: 900;
}

.site-footer__contact {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 0.6rem;
}

.site-footer__contact-label {
  align-self: center;
  color: var(--fm-muted);
  font-size: 0.88rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.site-footer__chip {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  min-height: 44px;
  padding: 0.62rem 0.95rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 999px;
  text-decoration: none;
  font-weight: 800;
  color: var(--fm-heading);
  background: var(--fm-card-strong);
  box-shadow: 0 10px 24px rgba(6, 12, 22, 0.18);
  transition: transform 170ms ease, box-shadow 170ms ease, border-color 170ms ease, background 170ms ease;
}

.site-footer__chip:hover,
.site-footer__chip:focus-visible {
  transform: translateY(-1px);
  box-shadow: 0 14px 28px rgba(6, 12, 22, 0.24);
  text-decoration: none;
}

.site-footer__chip-icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 1.2rem;
  height: 1.2rem;
}

.site-footer__chip-icon svg {
  width: 100%;
  height: 100%;
  fill: currentColor;
}

.site-footer__chip--mail {
  border-color: color-mix(in srgb, var(--fm-accent) 38%, var(--fm-card-border));
  background: color-mix(in srgb, var(--fm-accent) 12%, var(--fm-card-strong));
}

.site-footer__chip--mail:hover,
.site-footer__chip--mail:focus-visible {
  color: var(--fm-accent);
}

.site-footer__chip--whatsapp {
  border-color: rgba(37, 211, 102, 0.45);
  background: linear-gradient(135deg, rgba(37, 211, 102, 0.18), rgba(18, 140, 77, 0.14));
  color: #25d366;
}

.site-footer__chip--whatsapp:hover,
.site-footer__chip--whatsapp:focus-visible {
  color: #1ebe5d;
  border-color: rgba(37, 211, 102, 0.68);
}

.site-footer__chip--linkedin {
  border-color: rgba(10, 102, 194, 0.45);
  background: linear-gradient(135deg, rgba(10, 102, 194, 0.18), rgba(9, 76, 145, 0.12));
  color: #59a7ff;
}

.site-footer__chip--linkedin:hover,
.site-footer__chip--linkedin:focus-visible {
  color: #7ebcff;
  border-color: rgba(10, 102, 194, 0.68);
}

.btn {
  border-radius: 999px;
  border-width: 1px;
  font-family: var(--fm-font-display);
  font-weight: 900;
  letter-spacing: -0.01em;
  transition: transform 170ms ease, box-shadow 170ms ease, background 170ms ease, border-color 170ms ease;
}

.site-navbar .nav-link--primary {
  color: var(--fm-button-text) !important;
  background: var(--fm-button-bg);
  box-shadow: var(--fm-button-shadow);
}

.site-navbar .nav-link--primary:hover,
.site-navbar .nav-link--primary:focus {
  color: var(--fm-button-text) !important;
  background: var(--fm-button-bg);
}

.site-navbar .nav-link--active,
.site-navbar .nav-link--active:hover,
.site-navbar .nav-link--active:focus {
  color: var(--fm-button-text) !important;
  background: var(--fm-button-bg);
  box-shadow: var(--fm-button-shadow);
}

.site-navbar .nav-link--active.dropdown-toggle::after {
  filter: none;
}

.nav-link--dropdown {
  border: 0;
  background: transparent;
}

.site-menu-dropdown {
  min-width: 250px;
  padding: 0.45rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 1rem;
  background: var(--fm-card-strong);
  box-shadow: var(--fm-shadow-card);
}

.site-menu-dropdown .dropdown-item {
  border-radius: 0.75rem;
  color: var(--fm-text);
  font-weight: 700;
}

.site-menu-dropdown .dropdown-item:hover,
.site-menu-dropdown .dropdown-item:focus {
  color: var(--fm-heading);
  background: color-mix(in srgb, var(--fm-primary) 12%, transparent);
}

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

.btn:focus-visible,
.form-control:focus,
.form-select:focus,
.form-check-input:focus {
  outline: none;
  box-shadow: 0 0 0 0.22rem color-mix(in srgb, var(--fm-primary) 28%, transparent);
  border-color: var(--fm-primary);
}

.btn-primary,
.btn-dark,
.site-register-btn,
.site-login-link,
.site-logout-btn,
.btn-danger,
.btn-success {
  border: 0;
  color: var(--fm-button-text) !important;
  background: var(--fm-button-bg);
  box-shadow: var(--fm-button-shadow);
}

.btn-dark {
  background: linear-gradient(135deg, color-mix(in srgb, var(--fm-heading) 88%, #050816), color-mix(in srgb, var(--fm-primary) 28%, #07111f));
}

.btn-danger {
  background: linear-gradient(135deg, var(--fm-danger), color-mix(in srgb, var(--fm-danger) 72%, #111827));
}

.btn-success {
  background: linear-gradient(135deg, var(--fm-success), color-mix(in srgb, var(--fm-success) 68%, #111827));
}

.btn-primary:hover,
.btn-dark:hover,
.site-register-btn:hover,
.site-login-link:hover,
.site-logout-btn:hover,
.btn-danger:hover,
.btn-success:hover {
  filter: saturate(1.12) brightness(1.04);
  box-shadow: 0 18px 38px color-mix(in srgb, var(--fm-primary) 25%, transparent);
}

.btn-light,
.btn-outline-primary,
.btn-outline-dark,
.btn-outline-light,
.btn-outline-secondary,
.btn-secondary {
  border: 1px solid var(--fm-card-border);
  color: var(--fm-secondary-button-text) !important;
  background: var(--fm-secondary-button-bg);
  box-shadow: 0 12px 24px rgba(0,0,0,0.08);
}

.btn-light:hover,
.btn-outline-primary:hover,
.btn-outline-dark:hover,
.btn-outline-light:hover,
.btn-outline-secondary:hover,
.btn-secondary:hover {
  border-color: var(--fm-primary);
  color: var(--fm-secondary-button-text) !important;
  background: color-mix(in srgb, var(--fm-secondary-button-bg) 80%, var(--fm-primary) 20%);
}

.btn-outline-primary {
  border-color: color-mix(in srgb, var(--fm-primary) 42%, var(--fm-card-border));
  color: var(--fm-primary) !important;
  background: color-mix(in srgb, var(--fm-primary) 10%, var(--fm-secondary-button-bg));
}

.btn-outline-primary:hover,
.btn-outline-primary:focus {
  color: var(--fm-button-text) !important;
  border-color: transparent;
  background: var(--fm-button-bg);
  box-shadow: var(--fm-button-shadow);
}

.btn-outline-success {
  border-color: color-mix(in srgb, var(--fm-success) 56%, var(--fm-card-border));
  color: var(--fm-success) !important;
  background: color-mix(in srgb, var(--fm-success) 10%, var(--fm-secondary-button-bg));
  box-shadow: 0 12px 24px rgba(0,0,0,0.08);
}

.btn-outline-success:hover,
.btn-outline-success:focus {
  color: #ffffff !important;
  border-color: transparent;
  background: linear-gradient(135deg, var(--fm-success), color-mix(in srgb, var(--fm-success) 68%, #111827));
  box-shadow: 0 18px 38px color-mix(in srgb, var(--fm-success) 24%, transparent);
}

.btn-outline-danger {
  border-color: color-mix(in srgb, var(--fm-danger) 56%, var(--fm-card-border));
  color: var(--fm-danger) !important;
  background: color-mix(in srgb, var(--fm-danger) 10%, var(--fm-secondary-button-bg));
  box-shadow: 0 12px 24px rgba(0,0,0,0.08);
}

.btn-outline-danger:hover,
.btn-outline-danger:focus {
  color: #ffffff !important;
  border-color: transparent;
  background: linear-gradient(135deg, var(--fm-danger), color-mix(in srgb, var(--fm-danger) 72%, #111827));
  box-shadow: 0 18px 38px color-mix(in srgb, var(--fm-danger) 24%, transparent);
}

.btn:disabled,
.btn.disabled {
  opacity: 0.56;
  transform: none !important;
  box-shadow: none !important;
  cursor: not-allowed;
}

.btn-sm {
  padding: 0.45rem 0.78rem;
  font-size: 0.82rem;
}

.btn-lg {
  padding: 0.85rem 1.25rem;
  font-size: 1rem;
}

.page-kicker,
.album-kicker {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
  margin-bottom: 0.7rem;
  color: var(--fm-primary);
  font-size: 0.78rem;
  font-weight: 950;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.page-kicker::before,
.album-kicker::before {
  content: "";
  width: 0.7rem;
  height: 0.7rem;
  border-radius: 50%;
  background: var(--fm-theme-chip);
  box-shadow: 0 0 0 0.28rem color-mix(in srgb, var(--fm-theme-chip) 18%, transparent);
}

.page-title {
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: 3.15rem;
  font-weight: 950;
  line-height: 1.02;
  letter-spacing: 0;
  text-wrap: balance;
}

.country-identity {
  display: inline-flex;
  align-items: center;
  gap: 0.6rem;
  min-width: 0;
}

.country-identity--hero {
  margin-bottom: 0.35rem;
}

.country-identity--hero .display-6,
.country-identity--hero .page-title,
.country-identity--hero h1 {
  margin-bottom: 0;
}

.country-identity--inline {
  gap: 0.42rem;
}

.country-flag {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  inline-size: 1.55rem;
  block-size: 1.55rem;
  border-radius: 999px;
  background: color-mix(in srgb, var(--fm-surface) 82%, transparent);
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 72%, transparent);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.35);
  flex-shrink: 0;
  overflow: hidden;
}

.country-flag img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.country-identity--hero .country-flag {
  inline-size: 2.15rem;
  block-size: 2.15rem;
}

.page-subtitle,
.text-muted {
  color: var(--fm-muted) !important;
}

.hero-card,
.fm-surface,
.card,
.album-section-card,
.album-page-card,
.album-slot-card,
.album-book-page,
.album-sticker-status-card,
.fm-list-filter,
.fm-empty-filter {
  position: relative;
  border: 1px solid var(--fm-card-border);
  color: var(--fm-text);
  background: var(--fm-card-bg);
  box-shadow: var(--fm-shadow-card);
  backdrop-filter: blur(16px);
}

.hero-card,
.fm-surface,
.card {
  border-radius: var(--fm-radius-xl);
}

.hero-card {
  padding: clamp(1.3rem, 3vw, 2.6rem);
  overflow: hidden;
}

.home-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.22fr) minmax(320px, 0.78fr);
  gap: clamp(1.5rem, 3vw, 3rem);
  align-items: center;
  padding: clamp(1.85rem, 4vw, 3.1rem);
}

.home-hero__lead,
.home-hero__aside {
  min-width: 0;
}

.home-hero__lead .fm-badge-soft {
  margin-bottom: 1rem;
}

.home-hero__lead .page-title {
  max-width: 10.5ch;
  margin-bottom: 1rem;
  font-size: clamp(3.2rem, 5vw, 4.55rem);
  line-height: 0.92;
  letter-spacing: -0.045em;
  overflow-wrap: anywhere;
}

.home-hero__lead .page-subtitle {
  max-width: 58ch;
  margin-bottom: 0;
  font-size: 1.08rem;
  line-height: 1.6;
  overflow-wrap: anywhere;
}

.home-hero__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.85rem;
  margin-top: 1.5rem;
}

.home-auth-panel {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
  max-width: 560px;
  margin-top: 1.35rem;
  padding: 0.8rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 1rem;
  background: color-mix(in srgb, var(--fm-card-strong) 82%, transparent);
}

.home-auth-panel__google {
  grid-column: 1 / -1;
  margin: 0;
}

.home-auth-panel span {
  grid-column: 1 / -1;
  color: var(--fm-muted);
  font-size: 0.9rem;
  line-height: 1.35;
}

.home-auth-panel .btn {
  min-height: 48px;
}

.home-hero__aside {
  display: grid;
  gap: 0.95rem;
  align-self: stretch;
  align-content: center;
  padding: 1.45rem 1.55rem;
  border-radius: 1.6rem;
}

.home-hero__eyebrow {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  width: fit-content;
  padding: 0.28rem 0.68rem;
  border-radius: 999px;
  color: var(--fm-primary);
  background: color-mix(in srgb, var(--fm-primary) 14%, transparent);
  border: 1px solid color-mix(in srgb, var(--fm-primary) 26%, transparent);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.home-hero__aside h2 {
  margin: 0;
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: clamp(1.45rem, 2vw, 1.9rem);
  font-weight: 950;
  letter-spacing: -0.03em;
  overflow-wrap: anywhere;
}

.home-hero__steps {
  display: grid;
  gap: 0.8rem;
  margin: 0;
  padding: 0;
}

.home-hero__steps li {
  position: relative;
  padding-left: 1.6rem;
  color: var(--fm-text);
  font-size: 1rem;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.home-hero__steps li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.5rem;
  width: 0.62rem;
  height: 0.62rem;
  border-radius: 999px;
  background: linear-gradient(135deg, var(--fm-primary), var(--fm-accent));
  box-shadow: 0 0 0 0.22rem color-mix(in srgb, var(--fm-primary) 18%, transparent);
}

.home-hero__help {
  justify-self: start;
}

.auth-page {
  display: grid;
  justify-content: center;
  padding: clamp(0.25rem, 2vw, 1.5rem) 0;
}

.auth-card {
  width: min(100%, 520px);
  padding: clamp(1rem, 3vw, 1.6rem);
  border: 1px solid var(--fm-card-border);
  border-radius: var(--fm-radius-xl);
  color: var(--fm-text);
  background: var(--fm-card-bg);
  box-shadow: var(--fm-shadow-card);
  backdrop-filter: blur(16px);
}

.auth-card--wide {
  width: min(100%, 760px);
}

.auth-card__header {
  display: grid;
  gap: 0.45rem;
  margin-bottom: 0.9rem;
}

.auth-card__header h1 {
  margin: 0;
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: clamp(2rem, 4vw, 2.65rem);
  font-weight: 950;
  line-height: 1;
  letter-spacing: 0;
}

.auth-card__header p,
.auth-hint {
  margin: 0;
  color: var(--fm-muted);
  line-height: 1.4;
}

.auth-google-form {
  margin: 0;
}

.auth-google-button {
  display: inline-flex;
  gap: 0.5rem;
  align-items: center;
  justify-content: center;
  width: 100%;
  min-height: 48px;
  padding: 0.68rem 1.1rem;
  border: 1px solid rgba(95, 156, 236, 0.72);
  border-radius: 999px;
  color: #ffffff;
  background: linear-gradient(180deg, #6ea4eb 0%, #5b92df 100%);
  box-shadow: 0 12px 24px rgba(37, 92, 168, 0.22);
  font-weight: 900;
  text-align: center;
  transition: transform 170ms ease, box-shadow 170ms ease, filter 170ms ease;
}

.auth-google-button__icon {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 2rem;
  height: 2rem;
  flex: 0 0 2rem;
  border: 1px solid rgba(218, 220, 224, 0.9);
  border-radius: 999px;
  background: #ffffff;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.82);
}

.auth-google-button__icon svg {
  display: block;
  width: 1.2rem;
  height: 1.2rem;
}

.auth-google-button:hover,
.auth-google-button:focus-visible {
  color: #ffffff;
  border-color: rgba(95, 156, 236, 0.9);
  background: linear-gradient(180deg, #78acf0 0%, #659ae3 100%);
  box-shadow: 0 15px 28px rgba(37, 92, 168, 0.28);
  filter: saturate(1.02);
}

.auth-google-button strong {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
  color: inherit;
  font-size: 1rem;
  line-height: 1.1;
}

.auth-divider {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin: 1rem 0;
  color: var(--fm-muted);
  font-size: 0.88rem;
}

.auth-divider::before,
.auth-divider::after {
  content: "";
  flex: 1;
  height: 1px;
  background: var(--fm-card-border);
}

.auth-form__row {
  display: flex;
  gap: 0.75rem;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1rem;
}

.auth-form__row--submit {
  margin-top: 1.1rem;
  margin-bottom: 0;
}

.auth-submit {
  min-height: 46px;
  min-width: 140px;
}

.hero-card::after,
.fm-surface::after {
  content: "";
  position: absolute;
  inset: 1px;
  z-index: -1;
  border-radius: inherit;
  background:
    radial-gradient(circle at 92% 2%, color-mix(in srgb, var(--fm-primary) 22%, transparent), transparent 14rem),
    radial-gradient(circle at 4% 95%, color-mix(in srgb, var(--fm-accent) 16%, transparent), transparent 14rem);
  pointer-events: none;
}

.fm-badge-soft,
.fm-chip,
.album-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  width: fit-content;
  padding: 0.35rem 0.72rem;
  border: 1px solid color-mix(in srgb, var(--fm-primary) 30%, transparent);
  border-radius: 999px;
  color: var(--fm-primary);
  background: color-mix(in srgb, var(--fm-primary) 12%, transparent);
  font-size: 0.78rem;
  font-weight: 950;
}

.fm-chip--danger {
  color: var(--fm-danger);
  border-color: color-mix(in srgb, var(--fm-danger) 34%, transparent);
  background: color-mix(in srgb, var(--fm-danger) 13%, transparent);
}

.fm-chip--success {
  color: var(--fm-success);
  border-color: color-mix(in srgb, var(--fm-success) 34%, transparent);
  background: color-mix(in srgb, var(--fm-success) 13%, transparent);
}

.fm-chip--accent {
  color: var(--fm-accent);
  border-color: color-mix(in srgb, var(--fm-accent) 34%, transparent);
  background: color-mix(in srgb, var(--fm-accent) 13%, transparent);
}

.fm-chip--dark {
  color: var(--fm-heading);
  border-color: var(--fm-card-border);
  background: var(--fm-card-strong);
}

.fm-chip--country {
  gap: 0.42rem;
}

.fm-chip--country .country-flag {
  inline-size: 1.15rem;
  block-size: 1.15rem;
  background: transparent;
  border-color: color-mix(in srgb, var(--fm-card-border) 46%, transparent);
}

.fm-section-title {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
  margin-bottom: 1rem;
}

.fm-section-title > div:first-child {
  min-width: 0;
  flex: 1 1 320px;
}

.fm-section-title h2 {
  margin: 0;
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-weight: 950;
  letter-spacing: -0.035em;
  overflow-wrap: anywhere;
}

.fm-section-title p {
  margin: 0.2rem 0 0;
  color: var(--fm-muted);
  overflow-wrap: anywhere;
}

.fm-section-title--compact {
  margin-bottom: 0.75rem;
}

.fm-section-title--compact h2 {
  font-size: 1.25rem;
  letter-spacing: 0;
}

.fm-section-title--compact p {
  margin-top: 0.12rem;
  font-size: 0.9rem;
}

.fm-info-panel {
  display: grid;
  grid-template-columns: 64px minmax(0, 1fr) auto;
  gap: 1rem;
  align-items: center;
  padding: 1.1rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 1.35rem;
  background: var(--fm-card-bg);
  box-shadow: var(--fm-shadow-soft);
  backdrop-filter: blur(16px);
}

.fm-info-panel--compact {
  gap: 0.85rem;
  padding: 0.9rem 1rem;
}

.fm-info-panel__icon,
.fm-empty-state__icon,
.fm-card-token {
  display: grid;
  place-items: center;
  border-radius: 1rem;
  color: var(--fm-button-text);
  background: var(--fm-button-bg);
  box-shadow: var(--fm-button-shadow);
  font-family: var(--fm-font-display);
  font-weight: 950;
}

.fm-info-panel__icon {
  width: 64px;
  height: 64px;
  padding: 0.45rem;
  font-size: 0.8rem;
  line-height: 1;
  text-align: center;
}

.fm-info-panel--compact .fm-info-panel__icon {
  width: 56px;
  height: 56px;
  font-size: 0.9rem;
}

.fm-info-panel__icon--stacked {
  gap: 0.1rem;
}

.fm-info-panel__icon--stacked span {
  font-size: 0.68rem;
  line-height: 1;
  text-transform: uppercase;
}

.fm-info-panel__icon--stacked strong {
  font-size: 1.45rem;
  line-height: 1;
}

.fm-info-panel h2,
.fm-info-panel h3 {
  margin: 0 0 0.25rem;
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-weight: 950;
}

.fm-info-panel--compact h2 {
  margin-bottom: 0.12rem;
  font-size: 1.05rem;
}

.fm-info-panel--compact p {
  font-size: 0.92rem;
  line-height: 1.28;
}

.fm-summary-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 0.9rem;
  margin-bottom: 1rem;
}

.fm-summary-grid--compact {
  gap: 0.7rem;
  margin-bottom: 0.8rem;
}

.fm-summary-card {
  position: relative;
  padding: 1rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 1.25rem;
  background: var(--fm-card-bg);
  box-shadow: var(--fm-shadow-soft);
  overflow: hidden;
}

.fm-summary-grid--compact .fm-summary-card {
  padding: 0.82rem 0.9rem;
  border-radius: 1.05rem;
}

.fm-summary-card::after {
  content: "";
  position: absolute;
  right: -1.5rem;
  bottom: -1.8rem;
  width: 6rem;
  height: 6rem;
  border-radius: 50%;
  background: color-mix(in srgb, var(--fm-primary) 12%, transparent);
}

.fm-summary-grid--compact .fm-summary-card::after {
  right: -1.2rem;
  bottom: -1.35rem;
  width: 4.7rem;
  height: 4.7rem;
}

.fm-summary-card span {
  display: block;
  color: var(--fm-muted);
  font-size: 0.75rem;
  font-weight: 950;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.fm-summary-grid--compact .fm-summary-card span {
  font-size: 0.7rem;
}

.fm-summary-card strong {
  display: block;
  margin-top: 0.35rem;
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: 2.3rem;
  line-height: 1;
}

.fm-summary-grid--compact .fm-summary-card strong {
  margin-top: 0.24rem;
  font-size: 1.8rem;
}

.fm-action-panel {
  padding: 1.2rem;
  border: 1px solid var(--fm-card-border);
  border-radius: var(--fm-radius-xl);
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--fm-primary) 10%, transparent), transparent 55%),
    var(--fm-card-bg);
  box-shadow: var(--fm-shadow-card);
  backdrop-filter: blur(16px);
}

.fm-action-panel--compact {
  padding: 0.95rem 1rem;
  border-radius: 1.3rem;
}

.fm-action-panel .form-label {
  color: var(--fm-heading);
  font-weight: 900;
}

.fm-action-panel--compact .form-label {
  margin-bottom: 0.3rem;
}

.help-page,
.help-page .row,
.help-page [class*="col-"],
.help-page .page-header,
.help-page .fm-surface,
.help-page .fm-section-title {
  min-width: 0;
}

.help-page .page-header > div {
  min-width: 0;
}

.help-page .page-title,
.help-page .page-subtitle,
.help-page h2,
.help-page p,
.help-page li {
  overflow-wrap: anywhere;
}

.help-page .fm-surface p:last-child,
.help-page .fm-surface ul:last-child,
.help-page .fm-surface ol:last-child {
  margin-bottom: 0;
}

.help-page .page-header .btn {
  max-width: 100%;
}

.help-page .page-header {
  align-items: center;
}

.help-page .page-header > .d-flex {
  justify-content: flex-end;
}

.help-steps-panel {
  display: grid;
  gap: 0.9rem;
  padding: 1rem;
}

.help-steps-panel__header {
  min-width: 0;
}

.help-steps-panel__header h2 {
  margin: 0.18rem 0 0;
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: 1.35rem;
  font-weight: 950;
  letter-spacing: 0;
  line-height: 1.05;
}

.help-step-grid,
.help-info-grid {
  display: grid;
  gap: 0.7rem;
  min-width: 0;
}

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

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

.help-step-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 0.65rem;
  align-items: start;
  min-width: 0;
  padding: 0.75rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 0.8rem;
  background: color-mix(in srgb, var(--fm-card-strong) 88%, transparent);
}

.help-step-card > span {
  display: grid;
  place-items: center;
  width: 1.8rem;
  height: 1.8rem;
  border-radius: 999px;
  color: var(--fm-button-text);
  background: var(--fm-button-bg);
  font-family: var(--fm-font-display);
  font-size: 0.85rem;
  font-weight: 950;
  line-height: 1;
}

.help-step-card h3 {
  margin: 0 0 0.18rem;
  color: var(--fm-heading);
  font-size: 1rem;
  font-weight: 900;
  letter-spacing: 0;
  line-height: 1.12;
}

.help-step-card p {
  margin: 0;
  color: var(--fm-muted);
  font-size: 0.88rem;
  line-height: 1.35;
}

.help-first-steps {
  width: min(100%, 980px);
  margin-inline: auto;
  padding: clamp(0.9rem, 2vw, 1.15rem);
  border: 1px solid color-mix(in srgb, var(--fm-primary) 34%, var(--fm-card-border));
  border-radius: 1.1rem;
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--fm-card-strong) 92%, transparent), color-mix(in srgb, var(--fm-card-bg) 92%, transparent));
  box-shadow: 0 1rem 2rem color-mix(in srgb, var(--fm-shadow-color) 14%, transparent);
  overflow: hidden;
}

.help-first-steps,
.help-first-steps * {
  box-sizing: border-box;
  max-width: 100%;
}

.help-first-steps__header {
  min-width: 0;
  margin-bottom: 0.7rem;
}

.help-first-steps__header h2 {
  margin: 0 0 0.2rem;
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: clamp(1.2rem, 2vw, 1.55rem);
  font-weight: 950;
  line-height: 1.05;
  overflow-wrap: break-word;
}

.help-first-steps__header p {
  margin: 0;
  color: var(--fm-muted);
  font-size: 0.92rem;
  line-height: 1.35;
  overflow-wrap: break-word;
}

.help-checklist {
  display: grid;
  grid-template-columns: repeat(3, minmax(12rem, 1fr));
  gap: 0.45rem;
  padding: 0;
  margin: 0;
  list-style: none;
  counter-reset: help-step;
}

.help-checklist li {
  position: relative;
  min-width: 0;
  min-height: 2.15rem;
  padding: 0.5rem 0.65rem 0.5rem 2.2rem;
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 82%, var(--fm-primary));
  border-radius: 0.72rem;
  color: var(--fm-text);
  background: color-mix(in srgb, var(--fm-card-strong) 76%, transparent);
  box-shadow: none;
  font-size: 0.84rem;
  font-weight: 750;
  line-height: 1.22;
  overflow: hidden;
  overflow-wrap: break-word;
  word-break: normal;
}

.help-checklist li::before {
  counter-increment: help-step;
  content: counter(help-step);
  position: absolute;
  left: 0.55rem;
  top: 0.5rem;
  display: grid;
  place-items: center;
  width: 1.22rem;
  height: 1.22rem;
  border-radius: 999px;
  color: var(--fm-button-text);
  background: var(--fm-button-bg);
  font-family: var(--fm-font-display);
  font-size: 0.66rem;
  font-weight: 950;
  line-height: 1;
}

.help-info-grid .fm-surface {
  padding: 1rem;
}

.fm-empty-state {
  display: grid;
  justify-items: center;
  gap: 0.8rem;
  padding: clamp(1.4rem, 4vw, 3rem);
  border: 1px dashed color-mix(in srgb, var(--fm-primary) 38%, var(--fm-card-border));
  border-radius: var(--fm-radius-xl);
  color: var(--fm-text);
  text-align: center;
  background:
    radial-gradient(circle at top, color-mix(in srgb, var(--fm-primary) 12%, transparent), transparent 16rem),
    var(--fm-card-bg);
}

.fm-empty-state__icon {
  width: 76px;
  height: 76px;
  padding: 0.5rem;
  font-size: 0.82rem;
  line-height: 1;
  text-align: center;
}

.fm-empty-state h1,
.fm-empty-state h3 {
  margin: 0;
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-weight: 950;
  line-height: 1.05;
  text-wrap: balance;
}

.fm-empty-state p {
  max-width: 560px;
  margin: 0;
  color: var(--fm-muted);
}

.fm-error-page {
  max-width: 820px;
  margin-inline: auto;
  padding: clamp(1rem, 3vw, 1.6rem);
}

.fm-error-page__trace,
.fm-error-page__dev {
  margin-top: 1rem;
  padding: 0.85rem 1rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 1rem;
  color: var(--fm-muted);
  background: var(--fm-card-strong);
}

.fm-error-page__trace code {
  color: var(--fm-heading);
  overflow-wrap: anywhere;
}

.fm-list-reset {
  display: grid;
  gap: 0.7rem;
  padding: 0;
  margin: 0;
  list-style: none;
}

.fm-list-reset li {
  position: relative;
  padding-left: 1.6rem;
}

.fm-list-reset li::before {
  content: "";
  position: absolute;
  left: 0;
  top: 0.45rem;
  width: 0.76rem;
  height: 0.76rem;
  border-radius: 50%;
  background: var(--fm-button-bg);
}

.page-header {
  display: flex;
  justify-content: space-between;
  gap: 1.25rem;
  align-items: end;
  padding: clamp(1.1rem, 2vw, 1.6rem);
  border: 1px solid var(--fm-card-border);
  border-radius: var(--fm-radius-xl);
  background: var(--fm-card-bg);
  box-shadow: var(--fm-shadow-card);
  backdrop-filter: blur(16px);
}

.page-header--compact {
  align-items: center;
  padding: 0.95rem 1.1rem;
  border-radius: 1.45rem;
}

.page-header--compact .page-kicker {
  margin-bottom: 0.34rem;
  font-size: 0.82rem;
}

.page-header--compact .page-kicker::before {
  width: 0.58rem;
  height: 0.58rem;
}

.page-header--compact .page-title {
  margin-bottom: 0.08rem;
  font-size: clamp(2rem, 3vw, 2.65rem);
  line-height: 0.98;
}

.page-header--compact .page-subtitle {
  margin-bottom: 0;
  font-size: 0.96rem;
  line-height: 1.22;
}

.page-header--missing .btn {
  min-height: 40px;
  padding-block: 0.55rem;
}

.missing-page {
  display: grid;
  gap: 0.85rem;
}

.missing-page__header {
  margin-bottom: 0;
  padding: 1.2rem 1.35rem;
}

.missing-page__header .page-kicker {
  margin-bottom: 0.3rem;
}

.missing-page__header .page-title {
  margin-bottom: 0.18rem;
}

.missing-page__header .page-subtitle {
  margin-bottom: 0;
  max-width: 62ch;
  line-height: 1.3;
}

.missing-page__summary {
  margin-bottom: 0;
}

.missing-page__summary .fm-summary-card {
  padding: 0.72rem 0.82rem;
}

.missing-page__summary .fm-summary-card strong {
  font-size: 1.62rem;
}

.missing-page__action-panel {
  margin-bottom: 0;
  padding: 1rem 1.15rem;
}

.missing-page__action-panel .fm-section-title {
  margin-bottom: 0.65rem;
}

.missing-page__action-panel .fm-section-title h2 {
  font-size: 1rem;
}

.missing-page__action-panel .fm-section-title p {
  font-size: 0.88rem;
}

.missing-page__action-panel .form-label {
  margin-bottom: 0.35rem;
}

.missing-page__action-panel .btn,
.missing-page__header .btn {
  min-height: 38px;
  padding-block: 0.5rem;
}

.page-header--duplicates .btn {
  min-height: 40px;
  padding-block: 0.55rem;
}

.duplicates-page {
  display: grid;
  gap: 0.85rem;
}

.duplicates-page__header {
  margin-bottom: 0;
  padding: 1.2rem 1.35rem;
}

.duplicates-page__header .page-kicker {
  margin-bottom: 0.3rem;
}

.duplicates-page__header .page-title {
  margin-bottom: 0.18rem;
}

.duplicates-page__header .page-subtitle {
  margin-bottom: 0;
  max-width: 62ch;
  line-height: 1.3;
}

.duplicates-page__summary {
  margin-bottom: 0;
}

.duplicates-page__summary .fm-summary-card {
  padding: 0.72rem 0.82rem;
}

.duplicates-page__summary .fm-summary-card strong {
  font-size: 1.62rem;
}

.duplicates-page__action-panel {
  margin-bottom: 0;
  padding: 1rem 1.15rem;
}

.duplicates-page__action-panel .fm-section-title {
  margin-bottom: 0.65rem;
}

.duplicates-page__action-panel .fm-section-title h2 {
  font-size: 1rem;
}

.duplicates-page__action-panel .fm-section-title p {
  font-size: 0.88rem;
}

.duplicates-page__action-panel .form-label {
  margin-bottom: 0.35rem;
}

.duplicates-page__action-panel .btn,
.duplicates-page__header .btn {
  min-height: 38px;
  padding-block: 0.5rem;
}

.dashboard-hero {
  min-height: 320px;
}

.dashboard-hero::before {
  content: "";
  position: absolute;
  right: clamp(1rem, 4vw, 4rem);
  bottom: -4rem;
  width: min(32vw, 360px);
  height: min(32vw, 360px);
  border-radius: 50%;
  border: 2px solid var(--fm-field-lines);
  background:
    radial-gradient(circle, transparent 0 34%, var(--fm-field-lines) 35% 36%, transparent 37%),
    linear-gradient(45deg, transparent 47%, var(--fm-field-lines) 48% 52%, transparent 53%);
  opacity: 0.9;
}

.dashboard-hero__copy {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 1.5rem;
  align-items: end;
}

.dashboard-hero__actions {
  display: flex;
  gap: 0.7rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.dashboard-quickstrip {
  display: flex;
  flex-wrap: wrap;
  gap: 0.7rem;
  margin-top: 1.35rem;
}

.dashboard-quickstrip span {
  display: inline-flex;
  align-items: baseline;
  gap: 0.38rem;
  padding: 0.46rem 0.78rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 999px;
  color: var(--fm-muted);
  background: color-mix(in srgb, var(--fm-card-strong) 76%, transparent);
  font-weight: 800;
}

.dashboard-quickstrip strong {
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: 1.1rem;
}

.dashboard-hero__badge {
  position: relative;
  z-index: 1;
  display: grid;
  gap: 0.65rem;
  width: min(100%, 360px);
  margin-top: 2rem;
  padding: 1.1rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 1.25rem;
  background: var(--fm-card-strong);
}

.dashboard-hero__badge div {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
}

.dashboard-hero__badge span {
  color: var(--fm-muted);
  font-weight: 900;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.dashboard-hero__badge strong {
  color: var(--fm-primary);
  font-family: var(--fm-font-display);
  font-size: 3rem;
  line-height: 1;
}

.dashboard-hero__progress {
  height: 0.7rem;
  border-radius: 999px;
  background: color-mix(in srgb, var(--fm-muted) 20%, transparent);
  overflow: hidden;
}

.dashboard-hero__progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--fm-button-bg);
  box-shadow: var(--fm-button-shadow);
}

.dashboard-stat-grid {
  display: grid;
  grid-template-columns: repeat(5, minmax(0, 1fr));
  gap: 1rem;
}

.stat-card {
  position: relative;
  display: grid;
  grid-template-columns: 56px 1fr;
  gap: 1rem;
  min-height: 170px;
  padding: 1.1rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 1.35rem;
  color: var(--fm-text);
  background: var(--fm-card-bg);
  box-shadow: var(--fm-shadow-soft);
  overflow: hidden;
  backdrop-filter: blur(16px);
  transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

.stat-card:hover {
  transform: translateY(-4px);
  border-color: color-mix(in srgb, var(--fm-primary) 48%, var(--fm-card-border));
  box-shadow: var(--fm-shadow-card);
}

.stat-card::after {
  content: "";
  position: absolute;
  right: -2rem;
  bottom: -2.5rem;
  width: 8rem;
  height: 8rem;
  border-radius: 50%;
  background: color-mix(in srgb, var(--fm-primary) 13%, transparent);
}

.stat-card__icon {
  display: grid;
  place-items: center;
  width: 56px;
  height: 56px;
  border-radius: 19px;
  color: var(--fm-button-text);
  background: var(--fm-button-bg);
  box-shadow: var(--fm-button-shadow);
}

.stat-card__icon::before {
  content: "";
  display: block;
  width: 28px;
  height: 28px;
  background: currentColor;
  mask-size: contain;
  mask-repeat: no-repeat;
  mask-position: center;
}

.stat-card__icon--owned::before { mask-image: url("/images/themes/icon-album.svg"); }
.stat-card__icon--missing::before { mask-image: url("/images/themes/icon-target.svg"); }
.stat-card__icon--duplicate::before { mask-image: url("/images/themes/icon-stack.svg"); }
.stat-card__icon--perfect::before { mask-image: url("/images/themes/icon-trophy.svg"); }
.stat-card__icon--partial::before { mask-image: url("/images/themes/icon-swap.svg"); }

.stat-card__label {
  color: var(--fm-muted);
  font-size: 0.72rem;
  font-weight: 950;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.stat-card__value {
  margin-top: 0.28rem;
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: clamp(2rem, 3vw, 3.4rem);
  font-weight: 950;
  line-height: 0.95;
}

.stat-card__support {
  margin-top: 0.48rem;
  color: var(--fm-muted);
  font-size: 0.9rem;
  line-height: 1.28;
}

.match-board {
  padding: clamp(1rem, 2vw, 1.5rem);
  border-radius: var(--fm-radius-xl);
}

.match-board__header {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  margin-bottom: 1.1rem;
}

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

.match-card {
  display: grid;
  gap: 1rem;
  padding: 1.25rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 1.25rem;
  background: var(--fm-card-strong);
  box-shadow: var(--fm-shadow-soft);
  overflow: hidden;
}

.match-card__top,
.match-card__footer,
.match-card__stats {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
}

.match-card__title {
  margin: 0;
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: 1.35rem;
  font-weight: 950;
  overflow-wrap: anywhere;
}

.match-card__meta,
.match-card__score {
  color: var(--fm-muted);
  overflow-wrap: anywhere;
}

.match-card__top > div:first-child,
.match-card__top > div:last-child {
  min-width: 0;
  max-width: 100%;
}

.match-card__status {
  display: inline-flex;
  padding: 0.28rem 0.65rem;
  border-radius: 999px;
  color: var(--fm-button-text);
  background: var(--fm-button-bg);
  font-size: 0.78rem;
  font-weight: 950;
}

.match-card__status--perfect {
  color: #ffffff;
  background: linear-gradient(135deg, var(--fm-success), color-mix(in srgb, var(--fm-success) 68%, #111827));
}

.match-card__status--partial {
  color: var(--fm-secondary-button-text);
  background: var(--fm-secondary-button-bg);
  border: 1px solid var(--fm-card-border);
}

.match-card__stat {
  display: inline-flex;
  padding: 0.42rem 0.75rem;
  border-radius: 999px;
  color: var(--fm-heading);
  background: color-mix(in srgb, var(--fm-primary) 13%, transparent);
  font-weight: 800;
}

.album-hero {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 1.5rem;
  align-items: center;
  padding: clamp(1.2rem, 3vw, 2rem);
  border-radius: var(--fm-radius-xl);
  overflow: hidden;
}

.album-hero--compact {
  position: relative;
  border: 1px solid var(--fm-card-border);
  color: var(--fm-text);
  background:
    radial-gradient(circle at 0 0, color-mix(in srgb, var(--fm-primary) 12%, transparent), transparent 14rem),
    linear-gradient(135deg, color-mix(in srgb, var(--fm-card-bg) 92%, transparent), color-mix(in srgb, var(--fm-card-strong) 88%, transparent));
  box-shadow: var(--fm-shadow-card);
  backdrop-filter: blur(18px);
}

.album-hero--compact::after {
  content: "";
  position: absolute;
  inset: 1px;
  border-radius: inherit;
  background:
    radial-gradient(circle at 94% 8%, color-mix(in srgb, var(--fm-accent) 10%, transparent), transparent 12rem),
    radial-gradient(circle at 8% 100%, color-mix(in srgb, var(--fm-success) 10%, transparent), transparent 14rem);
  pointer-events: none;
}

.album-hero--compact > * {
  position: relative;
  z-index: 1;
}

html.theme-stadium-elite .album-hero--compact,
body.theme-stadium-elite .album-hero--compact,
html.theme-legendary-cup .album-hero--compact,
body.theme-legendary-cup .album-hero--compact {
  background:
    radial-gradient(circle at 10% 0, color-mix(in srgb, var(--fm-primary) 18%, transparent), transparent 15rem),
    linear-gradient(135deg, rgba(7, 15, 31, 0.94), rgba(8, 35, 53, 0.9));
}

html.theme-world-pitch .album-hero--compact,
body.theme-world-pitch .album-hero--compact {
  background:
    radial-gradient(circle at 0 0, color-mix(in srgb, var(--fm-accent) 12%, transparent), transparent 12rem),
    linear-gradient(135deg, color-mix(in srgb, var(--fm-card-bg) 88%, #f7fff6), color-mix(in srgb, var(--fm-primary) 9%, #f1fff2));
}

html.theme-sticker-album .album-hero--compact,
body.theme-sticker-album .album-hero--compact,
html.theme-world-festival .album-hero--compact,
body.theme-world-festival .album-hero--compact {
  background:
    radial-gradient(circle at 100% 0, color-mix(in srgb, var(--fm-accent) 12%, transparent), transparent 12rem),
    linear-gradient(135deg, color-mix(in srgb, var(--fm-card-bg) 92%, #fffdf7), color-mix(in srgb, var(--fm-primary) 8%, #fff7f2));
}

.album-hero--index {
  border: 1px solid var(--fm-header-border);
  color: var(--fm-text);
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--fm-card-bg) 86%, transparent), color-mix(in srgb, var(--fm-header-bg) 48%, transparent)),
    var(--fm-card-bg);
  box-shadow: var(--fm-shadow-card);
  backdrop-filter: blur(18px);
}

html.theme-stadium-elite .album-hero--index,
body.theme-stadium-elite .album-hero--index,
html.theme-legendary-cup .album-hero--index,
body.theme-legendary-cup .album-hero--index {
  background:
    radial-gradient(circle at 8% 0, color-mix(in srgb, var(--fm-primary) 18%, transparent), transparent 16rem),
    linear-gradient(135deg, rgba(5, 13, 28, 0.94), rgba(8, 42, 42, 0.88));
}

html.theme-world-pitch .album-hero--index,
body.theme-world-pitch .album-hero--index {
  color: #0b2415;
  border-color: rgba(15, 118, 54, 0.28);
  background:
    radial-gradient(circle at 0 0, rgba(250, 204, 21, 0.18), transparent 14rem),
    linear-gradient(135deg, rgba(246, 255, 241, 0.96), rgba(211, 246, 211, 0.92));
}

html.theme-world-pitch .album-hero--index .album-kicker,
body.theme-world-pitch .album-hero--index .album-kicker {
  color: #0f7a39 !important;
}

html.theme-world-pitch .album-hero--index h1,
html.theme-world-pitch .album-hero--index .display-6,
body.theme-world-pitch .album-hero--index h1,
body.theme-world-pitch .album-hero--index .display-6 {
  color: #06170d;
}

html.theme-world-pitch .album-hero--index .text-muted,
html.theme-world-pitch .album-hero--index .album-hero-actions__hint,
body.theme-world-pitch .album-hero--index .text-muted,
body.theme-world-pitch .album-hero--index .album-hero-actions__hint {
  color: #264936 !important;
}

.album-hero--index h1,
.album-hero--index .display-6 {
  color: var(--fm-heading);
}

.album-hero--index .text-muted,
.album-hero--index .album-hero-actions__hint {
  color: var(--fm-muted) !important;
}

.album-hero--index .btn-light {
  color: var(--fm-heading) !important;
  border-color: color-mix(in srgb, var(--fm-primary) 34%, var(--fm-card-border));
  background: color-mix(in srgb, var(--fm-card-strong) 88%, transparent);
}

.album-hero--index .btn-light:hover,
.album-hero--index .btn-light:focus {
  color: var(--fm-button-text) !important;
  background: var(--fm-button-bg);
}

.album-hero--physical .album-stats {
  grid-template-columns: repeat(4, minmax(96px, 1fr));
}

.album-quick-start {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto auto;
  gap: 0.8rem;
  align-items: center;
  padding: 0.9rem 1rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 1rem;
  color: var(--fm-text);
  background: var(--fm-card-bg);
  box-shadow: var(--fm-shadow-soft);
}

.album-quick-start__main {
  min-width: 0;
}

.album-quick-start__main h1 {
  margin: 0;
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: clamp(1.45rem, 2.8vw, 2.1rem);
  font-weight: 950;
  line-height: 1.03;
  letter-spacing: 0;
  overflow-wrap: anywhere;
}

.album-quick-start__stats {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  justify-content: flex-end;
  min-width: 0;
}

.album-quick-start__stats span {
  display: inline-flex;
  align-items: baseline;
  gap: 0.28rem;
  padding: 0.4rem 0.58rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 999px;
  color: var(--fm-muted);
  background: var(--fm-card-strong);
  font-size: 0.82rem;
  white-space: nowrap;
}

.album-quick-start__stats strong {
  color: var(--fm-heading);
  font-size: 0.96rem;
}

.album-quick-start__action {
  white-space: nowrap;
}

.album-quick-start__bulk-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.48rem;
  grid-column: 1 / -1;
  align-items: center;
}

.album-quick-start__bulk-actions form {
  margin: 0;
}

.album-quick-start__bulk-actions .btn {
  min-height: 2.25rem;
  padding: 0.42rem 0.8rem;
  font-size: 0.8rem;
}

.album-section-browser__heading {
  display: flex;
  gap: 0.65rem;
  align-items: baseline;
  justify-content: space-between;
  min-width: 0;
}

.album-section-browser__heading strong {
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: 1.1rem;
  font-weight: 950;
}

.album-section-browser__heading span {
  color: var(--fm-muted);
  font-size: 0.88rem;
  overflow-wrap: anywhere;
}

.album-section-browser__heading {
  margin-bottom: 0.58rem;
}

.album-hero-actions {
  display: flex;
  align-items: center;
  gap: 0.7rem;
  flex-wrap: wrap;
}

.album-hero-actions__hint {
  color: var(--fm-muted);
  font-size: 0.9rem;
  flex: 1 1 260px;
  min-width: 0;
  overflow-wrap: anywhere;
}

.physical-album-toolbar {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 1rem;
  flex-wrap: wrap;
}

.physical-album-toolbar__hint {
  color: var(--fm-muted);
  font-size: 0.92rem;
}

.album-stats {
  display: grid;
  grid-template-columns: repeat(3, minmax(96px, 1fr));
  gap: 0.75rem;
}

.album-stat-card {
  min-width: 105px;
  padding: 0.95rem;
  border-radius: 1.1rem;
  text-align: center;
  background: var(--fm-card-strong);
}

.album-hero--index .album-stat-card {
  border: 1px solid var(--fm-card-border);
  background: color-mix(in srgb, var(--fm-card-strong) 92%, transparent);
}

.album-hero--compact .album-stat-card,
.album-hero--compact .dashboard-quickstrip span {
  border: 1px solid var(--fm-card-border);
  background: color-mix(in srgb, var(--fm-card-strong) 88%, transparent);
}

.album-hero--compact .display-6,
.album-hero--compact h1 {
  color: var(--fm-heading);
}

.album-hero--compact .text-muted,
.album-hero--compact .album-kicker {
  color: var(--fm-muted) !important;
}

.album-hero--compact .album-kicker {
  color: var(--fm-primary) !important;
}

.album-page-hero--dense {
  grid-template-columns: minmax(0, 1fr);
  gap: 0.6rem;
  padding: clamp(0.72rem, 1.6vw, 1rem);
}

.album-page-hero--dense .country-identity--hero {
  margin-bottom: 0.22rem;
}

.album-page-hero--dense .country-identity--hero .country-flag {
  inline-size: 1.7rem;
  block-size: 1.7rem;
}

.album-page-hero--dense .display-6,
.album-page-hero--dense h1 {
  font-size: clamp(1.45rem, 3vw, 2.15rem);
  line-height: 1;
}

.album-page-hero__hint {
  max-width: 780px;
  font-size: 0.9rem;
  line-height: 1.3;
}

.album-page-summary {
  margin-top: 0.7rem;
}

.album-page-summary span {
  min-height: 0;
  padding: 0.32rem 0.68rem;
  font-size: 0.86rem;
}

.album-page-summary strong {
  font-size: 0.92rem;
}

.album-stat-card strong {
  display: block;
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: 1.8rem;
  font-weight: 950;
}

.album-stat-card span {
  color: var(--fm-muted);
}

.album-stat-card--owned strong,
.album-count-success {
  color: var(--fm-success);
}

.album-stat-card--missing strong,
.album-count-danger {
  color: var(--fm-danger);
}

.album-legend {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  color: var(--fm-muted);
}

.album-legend span {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}

.album-legend__swatch {
  width: 15px;
  height: 15px;
  border-radius: 5px;
  border: 1px solid var(--fm-card-border);
  background: var(--fm-card-strong);
}

.album-legend__swatch--complete,
.album-legend__swatch--duplicate {
  border-color: var(--fm-success);
  background: color-mix(in srgb, var(--fm-success) 22%, transparent);
}

.album-legend__swatch--missing {
  border-color: var(--fm-danger);
  background: color-mix(in srgb, var(--fm-danger) 20%, transparent);
}

.album-legend__swatch--neutral {
  border-color: color-mix(in srgb, var(--fm-muted) 48%, var(--fm-card-border));
  background: color-mix(in srgb, var(--fm-muted) 18%, transparent);
}

.album-section-grid,
.album-page-grid,
.album-slot-grid {
  display: grid;
  gap: 1rem;
}

.album-section-grid {
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
}

.album-page-grid {
  grid-template-columns: repeat(auto-fit, minmax(260px, 1fr));
}

.album-page-grid--compact {
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 0.75rem;
}

.album-slot-grid {
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
}

.album-section-card,
.album-page-card,
.album-slot-card {
  display: block;
  height: 100%;
  padding: 1.05rem;
  border-radius: 1.25rem;
  text-decoration: none;
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.album-section-card:hover,
.album-page-card:hover,
.album-slot-card:hover {
  transform: translateY(-3px);
  border-color: color-mix(in srgb, var(--fm-primary) 52%, var(--fm-card-border));
}

.album-section-card--missing,
.album-slot-card--missing {
  border-color: color-mix(in srgb, var(--fm-danger) 68%, var(--fm-card-border));
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--fm-danger) 20%, transparent), transparent 62%),
    var(--fm-card-bg);
}

.album-section-card--complete,
.album-slot-card--duplicate {
  border-color: color-mix(in srgb, var(--fm-success) 36%, var(--fm-card-border));
}

.album-section-card--neutral,
.album-page-card--neutral,
.album-slot-card--neutral {
  border-color: color-mix(in srgb, var(--fm-muted) 34%, var(--fm-card-border));
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--fm-muted) 10%, transparent), transparent 70%),
    var(--fm-card-bg);
}

.album-section-card__top,
.album-page-card__header,
.album-slot-card__header,
.album-section-card__meta,
.album-section-card__cta,
.album-status-line {
  display: flex;
  justify-content: space-between;
  gap: 0.75rem;
  align-items: center;
}

.album-section-card {
  position: relative;
  min-width: 0;
  overflow: hidden;
  cursor: pointer;
}

.album-section-card__link {
  position: absolute;
  inset: 0;
  z-index: 1;
  border-radius: inherit;
}

.album-section-card__link:focus-visible {
  outline: 3px solid color-mix(in srgb, var(--fm-primary) 68%, #ffffff);
  outline-offset: -4px;
}

.album-section-card > :not(.album-section-card__link) {
  position: relative;
  z-index: 2;
  pointer-events: none;
}

.album-section-card__fake-btn {
  pointer-events: none;
}

.album-section-card__identity {
  display: inline-flex;
  min-width: 0;
  align-items: center;
  gap: 0.5rem;
}

.album-section-card__identity .country-flag {
  inline-size: 2.2rem;
  block-size: 2.2rem;
  flex: 0 0 auto;
  border-radius: 0.75rem;
  box-shadow: 0 10px 22px color-mix(in srgb, var(--fm-primary) 18%, transparent);
}

.album-section-card__top > .text-muted {
  flex: 0 0 auto;
  white-space: nowrap;
}

.album-section-card h2,
.album-section-card p,
.album-section-card__meta,
.album-section-card__cta {
  min-width: 0;
  overflow-wrap: anywhere;
}

.album-bulk-panel {
  display: grid;
  grid-template-columns: 1fr;
  gap: 1rem;
  align-items: stretch;
}

.album-bulk-panel > div {
  min-width: 0;
}

.album-bulk-panel h2 {
  margin: 0.25rem 0 0.35rem;
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-weight: 950;
  overflow-wrap: anywhere;
}

.album-bulk-panel p {
  overflow-wrap: anywhere;
}

.album-bulk-panel__actions {
  display: grid;
  gap: 0.75rem;
  min-width: 0;
}

.album-bulk-panel__actions .btn,
.album-bulk-panel__actions .form-control {
  width: 100%;
}

.album-bulk-form,
.album-bulk-form__row {
  display: grid;
  gap: 0.55rem;
  min-width: 0;
}

.album-bulk-form--danger {
  padding: 0.75rem;
  border: 1px solid color-mix(in srgb, var(--fm-danger) 42%, var(--fm-card-border));
  border-radius: 1rem;
  background: color-mix(in srgb, var(--fm-danger) 8%, transparent);
}

.album-bulk-form label {
  color: var(--fm-muted);
  font-size: 0.84rem;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.album-bulk-form__row {
  grid-template-columns: minmax(0, 1fr) auto;
  align-items: center;
}

.album-bulk-form__row .form-control,
.album-bulk-form__row .btn {
  max-width: 100%;
}

.album-next-step-panel__title {
  flex-direction: column;
  align-items: stretch;
}

.album-next-step-panel__title > div:first-child,
.album-next-step-panel__title > a,
.album-next-step-panel__title .btn {
  min-width: 0;
  max-width: 100%;
}

.album-next-step-panel__title > a,
.album-next-step-panel__title .btn {
  align-self: flex-start;
}

.album-control-panel {
  display: grid;
  grid-template-columns: minmax(250px, 0.95fr) minmax(0, 1.45fr);
  gap: 0.85rem 1rem;
  align-items: center;
  padding: 0.95rem 1rem;
}

.album-control-panel__summary,
.album-control-panel__copy,
.album-control-panel__toolbar {
  min-width: 0;
}

.album-control-panel__summary {
  display: grid;
  gap: 0.3rem;
  align-content: center;
}

.album-control-panel__copy {
  display: grid;
  gap: 0.18rem;
}

.album-control-panel__toolbar {
  display: flex;
  flex-wrap: wrap;
  justify-content: flex-end;
  align-items: center;
  gap: 0.5rem 0.65rem;
}

.album-control-panel__copy h2 {
  margin: 0;
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: clamp(1.12rem, 1.55vw, 1.4rem);
  font-weight: 950;
  letter-spacing: 0;
  line-height: 1.05;
}

.album-control-panel__copy p,
.album-control-panel__danger label {
  margin: 0;
  color: var(--fm-muted);
  font-size: 0.84rem;
  line-height: 1.18;
  overflow-wrap: anywhere;
}

.album-control-panel__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  align-items: center;
  min-width: 0;
}

.album-control-panel__actions form,
.album-control-panel__danger {
  margin: 0;
  min-width: 0;
}

.album-control-panel .btn {
  width: auto;
  max-width: 100%;
  white-space: nowrap;
}

.album-control-panel__danger {
  display: flex;
  align-items: center;
  gap: 0.45rem;
  max-width: 420px;
  padding: 0.44rem 0.55rem;
  border: 1px solid color-mix(in srgb, var(--fm-danger) 40%, var(--fm-card-border));
  border-radius: 999px;
  background: color-mix(in srgb, var(--fm-danger) 8%, transparent);
}

.album-control-panel__danger-row {
  display: flex;
  flex: 1 1 auto;
  gap: 0.4rem;
  align-items: center;
  min-width: 0;
}

.album-control-panel__danger-row .form-control {
  min-width: 0;
  flex: 1 1 120px;
}

.album-control-panel__danger-row .form-control {
  min-width: 0;
  max-width: 100%;
}

.album-page-card {
  overflow: hidden;
}

.album-page-card--missing {
  border-color: color-mix(in srgb, var(--fm-danger) 70%, var(--fm-card-border));
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--fm-danger) 16%, transparent), transparent 68%),
    var(--fm-card-strong);
}

.album-page-card--complete {
  border-color: color-mix(in srgb, var(--fm-success) 34%, var(--fm-card-border));
}

.album-page-card--neutral .album-page-card__cta {
  color: var(--fm-muted);
}

.album-page-card__cta {
  margin-top: 1rem;
  color: var(--fm-primary);
  font-weight: 950;
}

.album-page-card--missing .album-page-card__cta {
  color: var(--fm-danger);
}

.album-page-card--compact {
  padding: 0.78rem;
  border-radius: 0.95rem;
}

.album-page-card--compact h2 {
  margin: 0.45rem 0 0.2rem;
  font-size: 0.96rem;
  line-height: 1.15;
}

.album-page-card--compact .album-page-card__header,
.album-page-card--compact .album-page-card__status,
.album-page-card--compact .album-page-card__cta {
  font-size: 0.82rem;
}

.album-page-card--compact .album-page-card__cta {
  margin-top: 0.45rem;
}

.album-code-preview {
  display: flex;
  flex-wrap: wrap;
  gap: 0.38rem;
  margin-top: 1rem;
}

.album-code-preview span {
  padding: 0.28rem 0.55rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 999px;
  color: var(--fm-muted);
  background: var(--fm-card-strong);
  font-size: 0.78rem;
  font-weight: 850;
}

.album-missing-strip {
  display: flex;
  justify-content: space-between;
  gap: 1rem;
  align-items: center;
  padding: 1.1rem;
  border: 1px solid color-mix(in srgb, var(--fm-danger) 34%, var(--fm-card-border));
  border-radius: 1.35rem;
  background:
    radial-gradient(circle at 8% 0, color-mix(in srgb, var(--fm-danger) 18%, transparent), transparent 13rem),
    var(--fm-card-bg);
  box-shadow: var(--fm-shadow-soft);
}

.album-missing-strip--compact {
  padding: 0.8rem 0.95rem;
  border-color: color-mix(in srgb, var(--fm-danger) 62%, var(--fm-card-border));
  background:
    linear-gradient(90deg, color-mix(in srgb, var(--fm-danger) 18%, transparent), transparent 72%),
    var(--fm-card-bg);
}

.album-missing-strip h2 {
  margin: 0;
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-weight: 950;
}

.album-missing-strip--compact h2 {
  font-size: 1.15rem;
  letter-spacing: 0;
}

.album-sticker-status {
  padding: 0.9rem;
  border: 1px solid var(--fm-card-border);
  border-radius: var(--fm-radius-xl);
  background: color-mix(in srgb, var(--fm-card-bg) 82%, transparent);
  box-shadow: var(--fm-shadow-card);
}

.album-sticker-status--priority {
  border-color: color-mix(in srgb, var(--fm-primary) 24%, var(--fm-card-border));
}

.album-sticker-status-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
  gap: 0.9rem;
}

.album-sticker-status-card {
  position: relative;
  display: grid;
  gap: 0.65rem;
  min-height: 166px;
  padding: 0.92rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 1.2rem;
  color: var(--fm-text);
  text-decoration: none;
  background: var(--fm-card-strong);
  box-shadow: var(--fm-shadow-soft);
  overflow: hidden;
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.album-sticker-status-card:hover {
  transform: translateY(-3px) rotate(-0.4deg);
  color: var(--fm-text);
  border-color: color-mix(in srgb, var(--fm-primary) 45%, var(--fm-card-border));
  box-shadow: var(--fm-shadow-card);
}

.album-sticker-status-card::after {
  content: "";
  position: absolute;
  right: -2rem;
  bottom: -2rem;
  width: 6.5rem;
  height: 6.5rem;
  border-radius: 50%;
  background: color-mix(in srgb, var(--fm-primary) 11%, transparent);
}

.album-sticker-status-card--missing::after {
  background: color-mix(in srgb, var(--fm-danger) 20%, transparent);
}

.album-sticker-status-card--owned::after {
  background: color-mix(in srgb, var(--fm-success) 13%, transparent);
}

.album-sticker-status-card--neutral::after {
  background: color-mix(in srgb, var(--fm-muted) 10%, transparent);
}

.album-sticker-status-card--missing {
  border-color: color-mix(in srgb, var(--fm-danger) 82%, var(--fm-card-border));
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--fm-danger) 26%, transparent), transparent 76%),
    var(--fm-card-strong);
  box-shadow:
    0 0 0 1px color-mix(in srgb, var(--fm-danger) 24%, transparent),
    0 14px 32px color-mix(in srgb, var(--fm-danger) 17%, transparent);
}

.album-sticker-status-card--owned {
  border-color: color-mix(in srgb, var(--fm-success) 34%, var(--fm-card-border));
}

.album-sticker-status-card--neutral {
  border-color: color-mix(in srgb, var(--fm-muted) 34%, var(--fm-card-border));
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--fm-muted) 10%, transparent), transparent 76%),
    var(--fm-card-strong);
}

.album-sticker-status-card__top {
  display: flex;
  justify-content: space-between;
  gap: 0.6rem;
  color: var(--fm-muted);
  font-size: 0.82rem;
  font-weight: 950;
}

.album-sticker-status-card strong {
  position: relative;
  z-index: 1;
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: 1rem;
  line-height: 1.12;
}

.album-sticker-status-card small {
  position: relative;
  z-index: 1;
  color: var(--fm-muted);
}

.album-sticker-status-card__state {
  position: relative;
  z-index: 1;
  width: fit-content;
  margin-top: auto;
  padding: 0.34rem 0.72rem;
  border-radius: 999px;
  color: var(--fm-button-text);
  background: var(--fm-button-bg);
  font-size: 0.8rem;
  font-weight: 950;
}

.album-sticker-status-card__state--missing {
  color: #ffffff;
  background: var(--fm-danger);
  box-shadow: 0 8px 18px color-mix(in srgb, var(--fm-danger) 34%, transparent);
}

.album-sticker-status-card__state--owned {
  color: #ffffff;
  background: var(--fm-success);
  box-shadow: 0 8px 18px color-mix(in srgb, var(--fm-success) 24%, transparent);
}

.album-sticker-status-card__state--neutral {
  color: var(--fm-heading);
  background: color-mix(in srgb, var(--fm-card-strong) 92%, transparent);
  border: 1px solid color-mix(in srgb, var(--fm-muted) 32%, var(--fm-card-border));
  box-shadow: none;
}

.album-section-card h2,
.album-page-card h2,
.album-slot-card h2,
.album-slot-card__title {
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: 1.12rem;
  font-weight: 950;
}

.album-progress {
  height: 0.5rem;
  margin: 1rem 0 0.85rem;
  border-radius: 999px;
  background: color-mix(in srgb, var(--fm-muted) 16%, transparent);
  overflow: hidden;
}

.album-progress span {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--fm-button-bg);
}

.album-slot-card__country {
  color: var(--fm-heading);
  font-weight: 800;
}

.album-slot-card__country .country-flag {
  inline-size: 1.2rem;
  block-size: 1.2rem;
}

.album-slot-card__type,
.album-section-card__meta,
.album-page-card p {
  color: var(--fm-muted);
}

.album-duplicate-controls {
  display: inline-flex;
  align-items: center;
  gap: 0.45rem;
}

.album-duplicate-qty {
  min-width: 28px;
  text-align: center;
  color: var(--fm-heading);
  font-weight: 950;
}

.fm-list-filter {
  display: grid;
  grid-template-columns: minmax(240px, 1fr) minmax(170px, 0.45fr) minmax(170px, 0.45fr) auto;
  gap: 0.85rem;
  align-items: end;
  padding: 1rem;
  border-radius: 1.35rem;
  margin-bottom: 1rem;
}

.fm-list-filter--matches {
  grid-template-columns: minmax(280px, 1fr) minmax(180px, 0.42fr) minmax(220px, auto);
  gap: 0.7rem;
  align-items: center;
  padding: 0.8rem 1rem;
  border-radius: 1.2rem;
}

.fm-list-filter--matches .form-label {
  margin-bottom: 0.25rem;
  font-size: 0.82rem;
  font-weight: 850;
}

.fm-list-filter--matches .form-control,
.fm-list-filter--matches .form-select {
  min-height: 40px;
  padding-block: 0.55rem;
}

.fm-country-autocomplete {
  position: relative;
}

.fm-country-autocomplete__list {
  position: absolute;
  z-index: 25;
  width: 100%;
  margin-top: 0.35rem;
  padding: 0.3rem;
  border: 1px solid var(--fm-border);
  border-radius: 0.85rem;
  background: var(--fm-surface);
  box-shadow: var(--fm-shadow-soft);
  max-height: 220px;
  overflow-y: auto;
}

.fm-country-autocomplete__option {
  width: 100%;
  border: 0;
  border-radius: 0.7rem;
  padding: 0.5rem 0.65rem;
  text-align: left;
  color: var(--fm-heading);
  background: transparent;
}

.fm-country-autocomplete__option:hover,
.fm-country-autocomplete__option:focus-visible,
.fm-country-autocomplete__option--active {
  background: rgba(255,255,255,0.12);
  outline: none;
}

.fm-country-autocomplete__empty {
  color: var(--fm-muted);
  font-size: 0.82rem;
  padding: 0.5rem 0.65rem;
}

.fm-list-filter__count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 44px;
  padding: 0.6rem 0.85rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 999px;
  color: var(--fm-muted);
  background: var(--fm-card-strong);
  white-space: nowrap;
}

.fm-list-filter--matches .fm-list-filter__count {
  min-height: 40px;
  padding: 0.45rem 0.8rem;
  font-size: 0.92rem;
}

.fm-list-filter--album {
  grid-template-columns: minmax(280px, 1fr) auto;
  gap: 0.7rem;
  align-items: center;
  padding: 0.85rem 1rem;
  border-radius: 1.2rem;
}

.fm-list-filter--album .form-label {
  margin-bottom: 0.25rem;
  font-size: 0.82rem;
  font-weight: 850;
}

.fm-list-filter--album .form-control {
  min-height: 40px;
  padding-block: 0.55rem;
}

.fm-list-filter--album .fm-list-filter__count {
  min-height: 40px;
  padding: 0.45rem 0.8rem;
  font-size: 0.92rem;
}

.fm-list-filter__count strong {
  margin: 0 0.25rem;
  color: var(--fm-heading);
}

.fm-empty-filter {
  padding: 1rem;
  border-radius: 1rem;
  color: var(--fm-muted);
  text-align: center;
}

.fm-collection-list {
  display: grid;
  gap: 0.85rem;
}

.fm-collection-item {
  position: relative;
  display: grid;
  grid-template-columns: 72px minmax(0, 1fr) auto;
  gap: 1rem;
  align-items: center;
  padding: 1rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 1.25rem;
  background: var(--fm-card-strong);
  box-shadow: var(--fm-shadow-soft);
  overflow: hidden;
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.fm-collection-item:hover {
  transform: translateY(-3px);
  border-color: color-mix(in srgb, var(--fm-primary) 48%, var(--fm-card-border));
  box-shadow: var(--fm-shadow-card);
}

.fm-collection-item::after {
  content: "";
  position: absolute;
  right: -2.2rem;
  bottom: -2.4rem;
  width: 8rem;
  height: 8rem;
  border-radius: 50%;
  background: color-mix(in srgb, var(--fm-primary) 11%, transparent);
}

.fm-collection-item--missing {
  border-left: 5px solid var(--fm-danger);
}

.fm-collection-item--duplicate {
  border-left: 5px solid var(--fm-success);
}

.fm-card-token {
  width: 72px;
  height: 86px;
  border-radius: 1rem;
  font-size: 0.95rem;
  text-align: center;
}

.fm-card-token--missing {
  background: linear-gradient(135deg, var(--fm-danger), color-mix(in srgb, var(--fm-danger) 62%, #111827));
}

.fm-card-token--duplicate {
  background: linear-gradient(135deg, var(--fm-success), color-mix(in srgb, var(--fm-success) 58%, var(--fm-primary)));
}

.fm-collection-item__main,
.fm-collection-item__actions {
  position: relative;
  z-index: 1;
}

.fm-collection-item__title {
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: 1.15rem;
  font-weight: 950;
  line-height: 1.15;
}

.fm-collection-item__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  align-items: center;
  margin-top: 0.55rem;
}

.fm-collection-item__actions {
  display: flex;
  gap: 0.45rem;
  flex-wrap: wrap;
  justify-content: flex-end;
}

.fm-collection-item__actions form {
  margin: 0;
}

.fm-quantity-badge {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 2.5rem;
  padding: 0.34rem 0.72rem;
  border-radius: 999px;
  color: var(--fm-button-text);
  background: var(--fm-button-bg);
  box-shadow: var(--fm-button-shadow);
  font-weight: 950;
}

.fm-inline-note {
  display: inline-flex;
  padding: 0.45rem 0.75rem;
  border-radius: 999px;
  color: var(--fm-muted);
  background: var(--fm-card-strong);
  white-space: normal;
  overflow-wrap: anywhere;
  max-width: 100%;
}

.fm-minw-0 {
  min-width: 0 !important;
}

.fm-maxw-100 {
  max-width: 100% !important;
}

.fm-text-safe {
  min-width: 0;
  max-width: 100%;
  overflow-wrap: anywhere;
  word-break: break-word;
}

.fm-text-safe > * {
  max-width: 100%;
}

.fm-chip-safe,
.fm-button-safe {
  max-width: 100%;
  white-space: normal;
  overflow-wrap: anywhere;
}

.fm-panel-safe {
  min-width: 0;
  overflow: hidden;
}

.match-card .row,
.match-card .col-md-6,
.match-card .fm-surface,
.match-card .d-flex,
.match-card .text-end {
  min-width: 0;
}

.match-card .fm-surface {
  padding: 1rem;
  overflow: hidden;
}

.match-card ul,
.match-card li,
.match-card p,
.match-card .badge,
.match-card .btn,
.match-card .fm-chip,
.match-card .small,
.match-card .text-muted,
.match-card h2,
.match-card h3,
.match-card h4,
.match-card h5 {
  overflow-wrap: anywhere;
}

.match-card ul {
  padding-left: 1.1rem;
}

.match-card li + li {
  margin-top: 0.28rem;
}

.match-card .btn {
  max-width: 100%;
}

.whatsapp-primary-action,
.album-status-line--match-link {
  text-decoration: none;
}

.whatsapp-primary-action {
  display: inline-grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 0.65rem;
  align-items: center;
  min-height: 48px;
  max-width: 100%;
  padding: 0.58rem 0.78rem;
  border: 1px solid color-mix(in srgb, var(--fm-success) 64%, #ffffff);
  border-radius: 8px;
  color: #ffffff;
  background: var(--fm-success);
  box-shadow: 0 12px 26px color-mix(in srgb, var(--fm-success) 28%, transparent);
}

.whatsapp-primary-action strong,
.whatsapp-primary-action span span {
  display: block;
  min-width: 0;
  overflow-wrap: anywhere;
}

.whatsapp-primary-action strong {
  color: #ffffff;
  font-size: 0.88rem;
  line-height: 1.1;
}

.whatsapp-primary-action span span {
  color: rgba(255, 255, 255, 0.88);
  font-size: 0.76rem;
  line-height: 1.2;
}

.whatsapp-action-icon {
  display: inline-grid;
  place-items: center;
  flex: 0 0 auto;
  width: 2rem;
  height: 2rem;
  border-radius: 999px;
  color: #ffffff;
  background: color-mix(in srgb, #ffffff 16%, transparent);
}

.whatsapp-action-icon svg {
  display: block;
  width: 1.28rem;
  height: 1.28rem;
  fill: currentColor;
}

.form-control,
.form-select {
  border: 1px solid var(--fm-card-border);
  border-radius: 0.9rem;
  color: var(--fm-text);
  background-color: var(--fm-card-strong);
}

.form-control::placeholder {
  color: color-mix(in srgb, var(--fm-muted) 76%, transparent);
}

.card {
  overflow: hidden;
}

.card-body {
  color: var(--fm-text);
}

.alert {
  border-radius: 1rem;
}

.fm-alert-success {
  color: var(--fm-heading);
  border: 1px solid color-mix(in srgb, var(--fm-success) 30%, transparent);
  background: color-mix(in srgb, var(--fm-success) 14%, var(--fm-card-strong));
}

.theme-picker-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 1rem;
}

.theme-choice-card {
  overflow: hidden;
  border-radius: 1.25rem;
  transition: transform 180ms ease, border-color 180ms ease, box-shadow 180ms ease;
}

.theme-choice-card--active {
  border-color: var(--fm-primary);
  box-shadow: 0 0 0 4px color-mix(in srgb, var(--fm-primary) 18%, transparent), var(--fm-shadow-card);
}

.theme-choice-card:hover {
  transform: translateY(-3px);
}

.theme-choice-card__preview {
  min-height: 150px;
  padding: 1rem;
  background-size: cover;
  background-position: center;
  color: #ffffff;
  text-shadow: 0 2px 14px rgba(0,0,0,0.42);
}

.theme-preview-chip {
  display: inline-flex;
  padding: 0.28rem 0.65rem;
  border-radius: 999px;
  color: #07111f;
  background: rgba(255,255,255,0.82);
  font-size: 0.75rem;
  font-weight: 950;
}

.theme-preview-title {
  margin-top: 2rem;
  font-family: var(--fm-font-display);
  font-size: 1.35rem;
  font-weight: 950;
}

.theme-preview-lines {
  display: grid;
  gap: 0.45rem;
  width: 72%;
  margin-top: 0.9rem;
}

.theme-preview-lines span {
  display: block;
  height: 0.5rem;
  border-radius: 999px;
  background: rgba(255,255,255,0.62);
}

.theme-preview-stadium-elite { background-image: url("/images/themes/stadium-elite.svg"); }
.theme-preview-world-pitch { background-image: url("/images/themes/world-pitch.svg"); }
.theme-preview-sticker-album { background-image: url("/images/themes/sticker-album.svg"); }
.theme-preview-world-festival { background-image: url("/images/themes/world-festival.svg"); }
.theme-preview-legendary-cup { background-image: url("/images/themes/legendary-cup.svg"); }

.theme-choice-card__body {
  padding: 1rem;
}

.theme-choice-card__body h2 {
  color: var(--fm-heading);
}

/* Album page detail: stronger physical-album treatment for /Album/Page */
.album-page-nav {
  display: grid;
  grid-template-columns: minmax(160px, 1fr) minmax(220px, 0.8fr) minmax(160px, 1fr);
  gap: 1rem;
  align-items: center;
  padding: 0.95rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 1.35rem;
  background: var(--fm-card-bg);
  box-shadow: var(--fm-shadow-soft);
  backdrop-filter: blur(16px);
}

.album-page-nav--compact {
  grid-template-columns: minmax(130px, 0.8fr) minmax(190px, 0.7fr) minmax(130px, 0.8fr);
  gap: 0.65rem;
  padding: 0.55rem;
  border-radius: 1rem;
}

.album-page-nav--compact .btn,
.album-page-nav--compact > .disabled {
  min-height: 2.05rem;
  padding: 0.36rem 0.72rem;
  font-size: 0.82rem;
}

.album-page-nav--swipe {
  grid-template-columns: minmax(132px, 0.82fr) minmax(220px, 1fr) minmax(132px, 0.82fr);
}

.album-page-nav__swipe-hint {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  min-width: 0;
  padding: 0.45rem 0.7rem;
  border: 1px dashed color-mix(in srgb, var(--fm-primary) 34%, var(--fm-card-border));
  border-radius: 0.9rem;
  background: color-mix(in srgb, var(--fm-primary) 9%, transparent);
  text-align: left;
}

.album-page-nav__swipe-icon {
  display: inline-grid;
  grid-template-columns: repeat(3, 9px);
  gap: 0.18rem;
  flex: 0 0 auto;
}

.album-page-nav__swipe-icon i {
  display: block;
  width: 9px;
  height: 9px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--fm-primary) 78%, #ffffff);
  opacity: 0.45;
  animation: album-page-swipe-pulse 1.3s ease-in-out infinite;
}

.album-page-nav__swipe-icon i:nth-child(2) {
  animation-delay: 0.15s;
}

.album-page-nav__swipe-icon i:nth-child(3) {
  animation-delay: 0.3s;
}

.album-page-nav__swipe-copy {
  display: grid;
  gap: 0.12rem;
  min-width: 0;
}

.album-page-nav__swipe-copy strong {
  color: var(--fm-heading);
  font-size: 0.8rem;
  font-weight: 950;
  letter-spacing: 0.06em;
  text-transform: uppercase;
}

.album-page-nav__swipe-copy span {
  color: var(--fm-muted);
  font-size: 0.74rem;
  line-height: 1.2;
}

.album-page-nav > :last-child {
  justify-self: end;
}

.album-page-nav--footer {
  grid-template-columns: minmax(160px, 1fr) minmax(24px, auto) minmax(160px, 1fr);
}

.album-page-nav__footer-spacer {
  min-height: 1px;
}

.album-page-nav__progress {
  display: grid;
  justify-items: center;
  gap: 0.25rem;
  padding: 0.75rem 1rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 1.15rem;
  background: var(--fm-card-strong);
  text-align: center;
}

.album-page-nav--compact .album-page-nav__progress {
  gap: 0.15rem;
  padding: 0.42rem 0.65rem;
  border-radius: 0.8rem;
}

.album-page-nav__progress strong {
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: 2rem;
  line-height: 1;
}

.album-page-nav--compact .album-page-nav__progress strong {
  display: none;
}

.album-page-nav__progress span {
  color: var(--fm-muted);
  font-size: 0.82rem;
  font-weight: 900;
}

.album-page-nav--compact .album-page-nav__progress span {
  color: var(--fm-heading);
  font-size: 0.78rem;
}

.album-page-nav__bar {
  width: 100%;
  height: 0.48rem;
  margin-top: 0.25rem;
  border-radius: 999px;
  background: color-mix(in srgb, var(--fm-muted) 18%, transparent);
  overflow: hidden;
}

.album-page-nav--compact .album-page-nav__bar {
  height: 0.32rem;
  margin-top: 0.12rem;
}

.album-page-nav__bar i {
  display: block;
  height: 100%;
  border-radius: inherit;
  background: var(--fm-button-bg);
}

.album-page-swipe {
  position: relative;
  overflow: hidden;
  overflow: clip;
  contain: layout paint;
  isolation: isolate;
  touch-action: pan-y;
}

.album-page-swipe__content,
.album-page-swipe-track {
  transition: transform 0.22s ease, opacity 0.2s ease;
  will-change: transform, opacity;
}

.album-page-swipe__content {
  position: relative;
  z-index: 2;
  background: transparent;
}

.album-page-swipe__content--hidden {
  opacity: 0;
  pointer-events: none;
}

.album-page-swipe--hydrating {
  opacity: 0;
}

.album-page-swipe-track {
  --album-page-swipe-gap: 24px;
  position: absolute;
  inset: 0;
  z-index: 1;
  display: flex;
  gap: var(--album-page-swipe-gap);
  align-items: start;
  width: 200%;
  height: 100%;
  pointer-events: none;
}

.album-page-swipe-track__page {
  width: calc((100% - var(--album-page-swipe-gap)) / 2);
  flex: 0 0 calc((100% - var(--album-page-swipe-gap)) / 2);
  display: block;
  min-width: 0;
  overflow: hidden;
  contain: layout paint;
}

.album-page-swipe-track__page > .album-page-swipe__content {
  width: 100%;
  min-width: 0;
}

.album-page-swipe-track--overlay {
  position: fixed;
  inset: auto auto auto auto;
  z-index: 1200;
  margin: 0;
}

.album-page-swipe-track--overlay-fade {
  opacity: 0;
  transition: opacity 0.18s ease;
}

.album-page-swipe::before {
  content: "";
  position: fixed;
  right: 1rem;
  bottom: 1.1rem;
  z-index: 30;
  width: 58px;
  height: 58px;
  border-radius: 50%;
  border: 1px solid color-mix(in srgb, var(--fm-primary) 34%, var(--fm-card-border));
  background:
    radial-gradient(circle at 50% 34%, color-mix(in srgb, #ffffff 92%, transparent) 0 7px, transparent 8px),
    radial-gradient(circle at 50% 68%, color-mix(in srgb, var(--fm-primary) 18%, transparent) 0 18px, transparent 19px),
    linear-gradient(135deg, color-mix(in srgb, var(--fm-primary) 24%, transparent), color-mix(in srgb, var(--fm-accent) 20%, transparent)),
    var(--fm-card-bg);
  box-shadow: 0 18px 34px rgba(4, 11, 22, 0.28);
  opacity: 0.9;
  pointer-events: none;
}

.album-page-swipe::after {
  content: "ARRASTRA";
  position: fixed;
  right: 4.95rem;
  bottom: 2.08rem;
  z-index: 30;
  display: inline-flex;
  align-items: center;
  min-height: 2rem;
  padding: 0.42rem 0.72rem;
  border-radius: 999px;
  border: 1px solid color-mix(in srgb, var(--fm-primary) 34%, var(--fm-card-border));
  color: var(--fm-heading);
  background: color-mix(in srgb, var(--fm-card-bg) 92%, transparent);
  box-shadow: 0 14px 26px rgba(4, 11, 22, 0.18);
  font-size: 0.7rem;
  font-weight: 950;
  letter-spacing: 0.14em;
  pointer-events: none;
}

.album-page-swipe--dragging {
  user-select: none;
}

.album-page-swipe--loading {
  pointer-events: none;
}

.album-page-swipe--swipe-ready-next::after,
.album-page-swipe--swipe-ready-prev::after {
  color: var(--fm-button-text);
  background: var(--fm-button-bg);
  box-shadow: var(--fm-button-shadow);
}

.album-page-swipe--swipe-ready-next::before,
.album-page-swipe--swipe-ready-prev::before {
  border-color: color-mix(in srgb, var(--fm-primary) 62%, var(--fm-card-border));
  transform: scale(1.04);
}

.album-page-swipe--swipe-next {
  opacity: 0;
  filter: blur(2px);
  transform: translate3d(-88px, 0, 0) scale(0.985);
}

.album-page-swipe--swipe-prev {
  opacity: 0;
  filter: blur(2px);
  transform: translate3d(88px, 0, 0) scale(0.985);
}

.album-page-swipe--entering {
  animation: album-page-swipe-enter 0.3s ease;
}

.album-page-swipe-hint {
  display: flex;
  justify-content: space-between;
  gap: 0.85rem;
  align-items: center;
  padding: 0.52rem 0.78rem;
  border: 1px dashed color-mix(in srgb, var(--fm-primary) 34%, var(--fm-card-border));
  border-radius: 0.95rem;
  color: var(--fm-muted);
  background: color-mix(in srgb, var(--fm-primary) 9%, transparent);
  font-size: 0.82rem;
  font-weight: 800;
}

.album-page-swipe-hint__gesture,
.album-page-swipe-hint__directions {
  display: inline-flex;
  align-items: center;
  gap: 0.7rem;
  min-width: 0;
  flex-wrap: wrap;
}

.album-page-swipe-hint__gesture {
  color: var(--fm-heading);
}

.album-page-swipe-hint__icon {
  display: inline-grid;
  grid-template-columns: repeat(3, 8px);
  gap: 0.18rem;
  align-items: center;
  justify-items: center;
}

.album-page-swipe-hint__icon i {
  display: block;
  width: 8px;
  height: 8px;
  border-radius: 999px;
  background: color-mix(in srgb, var(--fm-primary) 78%, #ffffff);
  opacity: 0.45;
  animation: album-page-swipe-pulse 1.3s ease-in-out infinite;
}

.album-page-swipe-hint__icon i:nth-child(2) {
  animation-delay: 0.15s;
}

.album-page-swipe-hint__icon i:nth-child(3) {
  animation-delay: 0.3s;
}

@keyframes album-page-swipe-enter {
  from {
    opacity: 0;
    transform: translate3d(28px, 0, 0);
  }

  to {
    opacity: 1;
    transform: translate3d(0, 0, 0);
  }
}

@keyframes album-page-swipe-pulse {
  0%,
  100% {
    transform: translateX(0);
    opacity: 0.38;
  }

  50% {
    transform: translateX(4px);
    opacity: 1;
  }
}

.album-page-guide--compact {
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.75rem;
  padding: 0.62rem 0.78rem;
  border-radius: 1rem;
}

.album-page-guide--compact h2 {
  margin-bottom: 0.08rem;
  font-size: 1.18rem;
  line-height: 1.05;
}

.album-page-guide--compact p {
  font-size: 0.84rem;
  line-height: 1.28;
}

.album-page-guide--compact .album-legend {
  gap: 0.55rem;
  justify-content: flex-end;
  font-size: 0.78rem;
}

.album-page-guide--compact .album-legend__swatch {
  width: 0.7rem;
  height: 0.7rem;
  border-radius: 0.25rem;
}

.album-page-slots-title {
  margin-top: 0.4rem;
  margin-bottom: 0.55rem;
}

.album-slot-grid--page {
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  align-items: stretch;
}

.album-slot-grid--page .album-slot-card {
  position: relative;
  display: grid;
  grid-template-rows: auto 1fr auto;
  min-width: 0;
  min-height: 194px;
  padding: 0.78rem;
  border-width: 2px;
  isolation: isolate;
  overflow: hidden;
}

.album-slot-grid--page .album-slot-card--owned {
  border-color: color-mix(in srgb, var(--fm-success) 64%, var(--fm-card-border));
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--fm-success) 18%, transparent), transparent 74%),
    var(--fm-card-bg);
}

.album-slot-grid--page .album-slot-card--neutral {
  border-color: color-mix(in srgb, var(--fm-muted) 36%, var(--fm-card-border));
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--fm-muted) 10%, transparent), transparent 76%),
    var(--fm-card-bg);
}

.album-slot-grid--page .album-slot-card--missing {
  border-color: color-mix(in srgb, var(--fm-danger) 82%, var(--fm-card-border));
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--fm-danger) 28%, transparent), transparent 78%),
    var(--fm-card-bg);
  box-shadow:
    0 0 0 1px color-mix(in srgb, var(--fm-danger) 28%, transparent),
    0 14px 32px color-mix(in srgb, var(--fm-danger) 18%, transparent);
}

.album-slot-grid--page .album-slot-card--duplicate {
  box-shadow:
    0 0 0 1px color-mix(in srgb, var(--fm-accent) 24%, transparent),
    var(--fm-shadow-soft);
}

.album-slot-grid--page .album-slot-card--match-ready {
  border-color: color-mix(in srgb, var(--fm-success) 78%, #ffffff);
  box-shadow:
    0 0 0 2px color-mix(in srgb, var(--fm-success) 18%, transparent),
    0 18px 42px color-mix(in srgb, var(--fm-success) 28%, transparent);
  animation: album-card-match-ready 1.25s ease-in-out 3;
}

.album-slot-grid--page .album-slot-card::before {
  content: "";
  position: absolute;
  inset: 0.55rem;
  z-index: -1;
  border: 1px dashed color-mix(in srgb, var(--fm-muted) 24%, transparent);
  border-radius: 0.95rem;
  pointer-events: none;
}

.album-slot-grid--page .album-slot-card__header {
  position: relative;
  z-index: 1;
  margin-bottom: 0.45rem;
  min-width: 0;
}

.album-slot-grid--page .album-slot-card__body {
  display: grid;
  align-content: start;
  gap: 0.32rem;
  min-width: 0;
  min-height: 72px;
}

.album-slot-card__media {
  position: relative;
  overflow: hidden;
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 86%, transparent);
  border-radius: 1rem;
  background:
    linear-gradient(135deg, rgba(255,255,255,0.7), rgba(255,255,255,0.2)),
    repeating-conic-gradient(from 45deg, rgba(0,0,0,0.03) 0% 25%, rgba(255,255,255,0.16) 0% 50%) 50% / 22px 22px;
  aspect-ratio: 231 / 307;
  box-shadow: inset 0 1px 0 rgba(255,255,255,0.3);
}

.album-slot-card__media img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: contain;
  user-select: none;
  -webkit-user-drag: none;
  touch-action: pan-y;
}

.album-slot-card__media-placeholder {
  display: grid;
  place-items: center;
  gap: 0.45rem;
  width: 100%;
  height: 100%;
  padding: 1rem;
  color: var(--fm-muted);
  text-align: center;
  font-size: 0.78rem;
  font-weight: 900;
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.album-slot-card__media-placeholder .country-flag {
  inline-size: 2.1rem;
  block-size: 2.1rem;
}

.album-slot-grid--page .album-slot-card__title {
  display: -webkit-box;
  overflow: hidden;
  overflow-wrap: anywhere;
  -webkit-box-orient: vertical;
  -webkit-line-clamp: 3;
  font-size: 0.94rem;
  line-height: 1.08;
}

.album-slot-grid--page .album-slot-card__meta {
  color: var(--fm-muted);
  min-width: 0;
  overflow: hidden;
  font-size: 0.78rem;
  font-weight: 800;
}

.album-slot-card__state,
.album-slot-card__duplicate-badge {
  display: inline-flex;
  width: fit-content;
  align-items: center;
  gap: 0.35rem;
  margin-top: 0.3rem;
  padding: 0.28rem 0.58rem;
  border-radius: 999px;
  font-size: 0.72rem;
  font-weight: 950;
}

.album-slot-card__state--missing {
  color: #ffffff;
  border: 1px solid color-mix(in srgb, var(--fm-danger) 72%, #ffffff);
  background: var(--fm-danger);
  box-shadow: 0 8px 20px color-mix(in srgb, var(--fm-danger) 30%, transparent);
}

.album-slot-card__state--owned {
  color: #ffffff;
  border: 1px solid color-mix(in srgb, var(--fm-success) 72%, #ffffff);
  background: var(--fm-success);
  box-shadow: 0 8px 20px color-mix(in srgb, var(--fm-success) 24%, transparent);
}

.album-slot-card__state--neutral {
  color: var(--fm-heading);
  border: 1px solid color-mix(in srgb, var(--fm-muted) 32%, var(--fm-card-border));
  background: color-mix(in srgb, var(--fm-card-strong) 92%, transparent);
  box-shadow: none;
}

.album-slot-card__duplicate-badge {
  color: var(--fm-accent);
  border: 1px solid color-mix(in srgb, var(--fm-accent) 56%, transparent);
  background: color-mix(in srgb, var(--fm-accent) 18%, transparent);
  font-size: 0.72rem;
}

.album-slot-match-badge {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr);
  gap: 0.42rem;
  align-items: center;
  width: 100%;
  padding: 0.48rem 0.56rem;
  border: 1px solid color-mix(in srgb, var(--fm-success) 66%, #ffffff);
  border-radius: 8px;
  background:
    linear-gradient(135deg, color-mix(in srgb, var(--fm-success) 22%, var(--fm-card-strong)), var(--fm-card-strong)),
    var(--fm-card-strong);
  color: var(--fm-heading);
  box-shadow: inset 0 0 0 1px color-mix(in srgb, #ffffff 18%, transparent);
}

.album-slot-match-badge__pulse {
  display: grid;
  place-items: center;
  width: 1.55rem;
  height: 1.55rem;
  border-radius: 999px;
  background: var(--fm-success);
  color: #ffffff;
  font-weight: 950;
  line-height: 1;
  animation: album-match-pulse 1s ease-in-out infinite;
}

.album-slot-match-badge__text {
  min-width: 0;
  color: var(--fm-heading);
  font-size: 0.78rem;
  font-weight: 900;
}

.album-slot-grid--page .album-slot-card__status {
  display: grid;
  gap: 0.34rem;
  margin-top: 0.58rem;
  padding-top: 0.58rem;
  border-top: 1px solid var(--fm-card-border);
}

@keyframes album-card-match-ready {
  0%,
  100% {
    transform: translateY(0);
    box-shadow:
      0 0 0 2px color-mix(in srgb, var(--fm-success) 18%, transparent),
      0 18px 42px color-mix(in srgb, var(--fm-success) 28%, transparent);
  }
  50% {
    transform: translateY(-3px);
    box-shadow:
      0 0 0 4px color-mix(in srgb, var(--fm-success) 28%, transparent),
      0 24px 50px color-mix(in srgb, var(--fm-success) 36%, transparent);
  }
}

@keyframes album-match-pulse {
  0%,
  100% {
    transform: scale(1);
    box-shadow: 0 0 0 0 color-mix(in srgb, var(--fm-success) 34%, transparent);
  }
  50% {
    transform: scale(1.08);
    box-shadow: 0 0 0 7px color-mix(in srgb, var(--fm-success) 0%, transparent);
  }
}

.album-slot-grid--page .album-status-line {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.42rem;
  align-items: center;
  padding: 0.42rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 0.72rem;
  background: color-mix(in srgb, var(--fm-card-strong) 70%, transparent);
  overflow: hidden;
}

.album-slot-grid--page .album-status-line--state {
  display: block;
  padding: 0;
  border: 0;
  background: transparent;
}

.album-slot-grid--page .album-status-line--match {
  grid-template-columns: minmax(0, 1fr) auto;
  gap: 0.52rem;
  border-color: color-mix(in srgb, var(--fm-success) 58%, var(--fm-card-border));
  background: color-mix(in srgb, var(--fm-success) 14%, var(--fm-card-strong));
}

.album-slot-grid--page .album-status-line--match-link {
  grid-template-columns: auto minmax(0, 1fr) auto;
  min-height: 54px;
  padding: 0.58rem;
  color: var(--fm-heading);
  cursor: pointer;
}

.album-slot-grid--page .album-status-line--match-link:hover,
.album-slot-grid--page .album-status-line--match-link:focus-visible {
  border-color: color-mix(in srgb, var(--fm-success) 82%, #ffffff);
  background: color-mix(in srgb, var(--fm-success) 20%, var(--fm-card-strong));
}

.album-status-line__copy {
  display: grid;
  gap: 0.12rem;
  min-width: 0;
}

.album-status-line__chevron {
  display: inline-grid;
  place-items: center;
  width: 1.25rem;
  color: var(--fm-success);
  font-size: 1.35rem;
  font-weight: 900;
}

.album-slot-grid--page .album-status-line--match strong {
  display: block;
  color: var(--fm-heading);
  font-size: 0.82rem;
  line-height: 1.12;
  overflow-wrap: anywhere;
}

.album-slot-grid--page .album-status-line--match span {
  display: block;
  color: var(--fm-muted);
  font-size: 0.76rem;
  line-height: 1.25;
  overflow-wrap: anywhere;
}

.album-slot-grid--page .album-status-line--match .whatsapp-action-icon {
  color: #ffffff;
  background: var(--fm-success);
  box-shadow: 0 0 0 5px color-mix(in srgb, var(--fm-success) 14%, transparent);
}

.album-slot-grid--page .album-status-line--state .album-inline-form,
.album-slot-grid--page .album-status-line--state .btn {
  width: 100%;
}

.album-slot-grid--page .album-status-line > * {
  min-width: 0;
}

.album-status-line__label {
  color: var(--fm-muted);
  font-size: 0.76rem;
  font-weight: 950;
  letter-spacing: 0;
  text-transform: uppercase;
}

.album-slot-grid--page .album-status-line--duplicates {
  grid-template-columns: minmax(0, 1fr) minmax(104px, auto);
}

.album-slot-grid--page .album-status-line--duplicates .album-status-line__label {
  font-size: 0.72rem;
  letter-spacing: 0.03em;
  white-space: nowrap;
}

.album-slot-grid--page .album-duplicate-controls {
  display: grid;
  grid-template-columns: 28px minmax(18px, auto) 28px;
  gap: 0.18rem;
  align-items: center;
  justify-content: end;
  width: min(100%, 104px);
  max-width: 100%;
  padding: 0.16rem 0.2rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 999px;
  background: var(--fm-card-strong);
}

.album-inline-form {
  margin: 0;
  min-width: 0;
}

.album-slot-grid--page .album-status-line .btn {
  min-width: 0;
  width: 100%;
  min-height: 28px;
  padding-inline: 0.38rem;
  font-size: 0.76rem;
  font-weight: 950;
}

.album-slot-grid--page .album-status-line--state .btn {
  min-height: 34px;
}

.album-slot-grid--page .album-inline-form,
.album-slot-grid--page .album-duplicate-controls {
  max-width: 100%;
}

.album-slot-grid--page .album-duplicate-qty {
  min-width: 0;
  line-height: 1;
  font-size: 0.95rem;
}

.album-book {
  display: grid;
  gap: 1.25rem;
}

.album-book-spread {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  align-items: start;
}

.album-book-page {
  display: grid;
  gap: 1rem;
  min-height: 100%;
  padding: 1.1rem;
  border-radius: 1.4rem;
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--fm-card-strong) 92%, transparent), color-mix(in srgb, var(--fm-card-bg) 96%, transparent));
}

.album-book-page--blank {
  min-height: 280px;
  border-style: dashed;
  opacity: 0.45;
}

.album-book-page__header {
  display: flex;
  justify-content: space-between;
  align-items: start;
  gap: 1rem;
}

.album-book-page__eyebrow {
  display: inline-flex;
  margin-bottom: 0.35rem;
  color: var(--fm-primary);
  font-size: 0.76rem;
  font-weight: 950;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.album-book-page__header h2 {
  margin: 0;
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: 1.7rem;
  font-weight: 950;
  line-height: 1.06;
}

.album-book-page__header small {
  display: inline-block;
  margin-top: 0.2rem;
  color: var(--fm-muted);
  font-size: 0.92rem;
}

.album-book-page__summary {
  display: flex;
  gap: 0.6rem;
  flex-wrap: wrap;
}

.album-book-page__summary-item {
  display: inline-flex;
  align-items: center;
  padding: 0.4rem 0.72rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 999px;
  color: var(--fm-muted);
  background: var(--fm-card-strong);
  font-size: 0.82rem;
  font-weight: 800;
}

.album-book-page__summary-item--owned {
  color: var(--fm-success);
  border-color: color-mix(in srgb, var(--fm-success) 42%, var(--fm-card-border));
}

.album-book-page__summary-item--missing {
  color: var(--fm-danger);
  border-color: color-mix(in srgb, var(--fm-danger) 42%, var(--fm-card-border));
}

.album-book-slots {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
  gap: 0.7rem;
}

.album-book-slot {
  display: grid;
  grid-template-rows: auto 1fr auto;
  gap: 0.28rem;
  min-height: 112px;
  padding: 0.72rem;
  border: 1px solid var(--fm-card-border);
  border-radius: 1rem;
  color: var(--fm-text);
  background: color-mix(in srgb, var(--fm-card-strong) 92%, transparent);
  text-decoration: none;
  transition: transform 160ms ease, border-color 160ms ease, box-shadow 160ms ease;
  overflow: hidden;
}

.album-book-slot:hover {
  transform: translateY(-2px);
  border-color: color-mix(in srgb, var(--fm-primary) 46%, var(--fm-card-border));
  box-shadow: var(--fm-shadow-soft);
}

.album-book-slot--owned {
  border-color: color-mix(in srgb, var(--fm-success) 46%, var(--fm-card-border));
  background: linear-gradient(180deg, color-mix(in srgb, var(--fm-success) 12%, transparent), transparent 65%), var(--fm-card-strong);
}

.album-book-slot--missing {
  border-color: color-mix(in srgb, var(--fm-danger) 56%, var(--fm-card-border));
  background: linear-gradient(180deg, color-mix(in srgb, var(--fm-danger) 14%, transparent), transparent 65%), var(--fm-card-strong);
}

.album-book-slot--neutral {
  border-color: color-mix(in srgb, var(--fm-muted) 32%, var(--fm-card-border));
}

.album-book-slot--duplicate {
  box-shadow: inset 0 0 0 1px color-mix(in srgb, var(--fm-accent) 28%, transparent);
}

.album-book-slot__top {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 0.5rem;
}

.album-book-slot__code {
  display: inline-flex;
  align-items: center;
  min-height: 1.55rem;
  padding: 0.12rem 0.5rem;
  border-radius: 999px;
  color: var(--fm-heading);
  background: color-mix(in srgb, var(--fm-card-bg) 90%, transparent);
  font-size: 0.74rem;
  font-weight: 900;
}

.album-book-slot__state {
  width: 0.7rem;
  height: 0.7rem;
  border-radius: 999px;
  background: color-mix(in srgb, var(--fm-muted) 46%, transparent);
}

.album-book-slot--owned .album-book-slot__state,
.album-book-slot--duplicate .album-book-slot__state {
  background: var(--fm-success);
}

.album-book-slot--missing .album-book-slot__state {
  background: var(--fm-danger);
}

.album-book-slot strong {
  display: -webkit-box;
  overflow: hidden;
  color: var(--fm-heading);
  font-size: 0.95rem;
  line-height: 1.15;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
}

.album-book-slot small {
  color: var(--fm-muted);
  font-size: 0.76rem;
  font-weight: 700;
}

.album-book-slot__footer {
  display: flex;
  justify-content: space-between;
  align-items: end;
  gap: 0.5rem;
  margin-top: 0.25rem;
}

.album-book-slot__footer small {
  min-width: 0;
}

.album-book-slot__duplicate {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 0;
  min-height: 1.5rem;
  padding: 0.16rem 0.48rem;
  border-radius: 999px;
  color: var(--fm-accent);
  background: color-mix(in srgb, var(--fm-accent) 16%, transparent);
  font-size: 0.74rem;
  font-weight: 950;
  line-height: 1.1;
  white-space: nowrap;
  flex-shrink: 0;
}

@media (max-width: 1199.98px) {
  .worldcup-brand {
    margin-left: auto;
  }

  .site-navbar__collapse {
    margin-top: 1rem;
    padding-top: 1rem;
    border-top: 1px solid rgba(255,255,255,0.14);
    align-items: stretch;
  }

  .site-navbar__actions {
    justify-content: stretch;
    align-items: stretch;
    flex-wrap: wrap;
  }

  .site-navbar__actions > * {
    flex: 1 1 210px;
  }

  .site-navbar__account {
    display: grid;
    gap: 0.6rem;
    flex: 1 1 100%;
  }

  .theme-switcher__toggle,
  .site-login-link,
  .site-register-btn,
  .site-logout-btn {
    width: 100%;
    justify-content: center;
  }

  .site-user-pill {
    max-width: none;
  }

  .site-user-pill strong {
    white-space: normal;
    overflow-wrap: anywhere;
  }

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

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

  .help-info-grid {
    grid-template-columns: 1fr;
  }

  .fm-list-filter {
    grid-template-columns: 1fr 1fr;
  }

  .fm-list-filter--matches {
    grid-template-columns: minmax(0, 1fr) minmax(180px, 0.5fr);
  }

  .fm-list-filter--album {
    grid-template-columns: minmax(0, 1fr) auto;
  }

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

  .album-page-nav > :last-child {
    justify-self: stretch;
  }

  .album-page-nav .btn {
    width: 100%;
  }

  .fm-list-filter__search,
  .fm-list-filter__count {
    grid-column: 1 / -1;
  }

  .fm-list-filter--matches .fm-list-filter__count {
    grid-column: auto;
  }

  .fm-list-filter--album .fm-list-filter__count {
    grid-column: auto;
  }

  .album-hero--physical .album-stats {
    grid-template-columns: repeat(2, minmax(96px, 1fr));
  }
}

@media (max-width: 767.98px) {
  .app-container {
    width: min(100% - 1rem, 1280px);
    padding-top: 1rem;
  }

  .site-navbar__inner {
    gap: 0.65rem;
  }

  .site-brand {
    min-width: 0;
  }

  .worldcup-brand {
    display: none;
  }

  .site-mobile-primary-nav {
    display: flex;
  }

  .site-navbar__links {
    display: grid;
    gap: 0.35rem;
  }

  .album-bulk-panel {
    grid-template-columns: 1fr;
  }

  .album-bulk-form__row {
    grid-template-columns: 1fr;
  }

  .album-bulk-form__row .btn {
    width: 100%;
  }

  .album-control-panel {
    grid-template-columns: 1fr;
    padding: 0.85rem;
  }

  .album-control-panel__toolbar,
  .album-control-panel__actions {
    align-items: stretch;
    justify-content: stretch;
    flex-direction: column;
  }

  .album-control-panel__toolbar > .btn,
  .album-control-panel__actions form,
  .album-control-panel__actions .btn {
    width: 100%;
  }

  .album-control-panel__danger {
    display: grid;
    gap: 0.4rem;
    max-width: 100%;
    border-radius: 0.9rem;
  }

  .album-control-panel__danger-row {
    display: grid;
    grid-template-columns: 1fr;
  }

  .album-control-panel__danger-row .btn {
    width: 100%;
  }

  .album-quick-start {
    grid-template-columns: 1fr;
    gap: 0.5rem;
    padding: 0.72rem;
  }

  .album-quick-start__main h1 {
    font-size: 1.22rem;
    line-height: 1.02;
  }

  .album-quick-start__stats {
    justify-content: start;
    gap: 0.32rem;
  }

  .album-quick-start__stats span {
    padding: 0.28rem 0.44rem;
    font-size: 0.73rem;
  }

  .album-quick-start__action {
    width: 100%;
  }

  .album-quick-start__bulk-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 0.42rem;
  }

  .album-quick-start__bulk-actions form,
  .album-quick-start__bulk-actions .btn {
    width: 100%;
  }

  .album-quick-start__bulk-actions .btn {
    min-height: 2.1rem;
    padding-inline: 0.4rem;
    font-size: 0.7rem;
  }

  .album-section-browser__heading {
    align-items: start;
    flex-direction: column;
    gap: 0.1rem;
  }

  .album-slot-grid--page .album-status-line--match {
    grid-template-columns: 1fr;
    align-items: stretch;
    padding: 0.58rem;
  }

  .album-slot-grid--page .album-status-line--match-link {
    grid-template-columns: auto minmax(0, 1fr);
    min-height: 58px;
    padding: 0.68rem;
  }

  .album-slot-grid--page .album-status-line--match-link .album-status-line__chevron {
    display: none;
  }

  .album-slot-grid--page .album-status-line--match .btn {
    width: 100%;
    min-height: 44px;
  }

  .whatsapp-primary-action {
    width: 100%;
    min-height: 56px;
  }

  .page-title {
    font-size: 2.05rem;
    line-height: 1.08;
  }

  .page-subtitle {
    font-size: 0.95rem;
  }

  .site-header {
    padding-top: 0.5rem;
  }

  .site-navbar {
    width: calc(100% - 0.75rem);
    border-radius: 1.1rem;
  }

  .site-brand {
    min-width: 0;
    gap: 0.55rem;
  }

  .site-brand__copy small {
    display: none;
  }

  .site-brand__copy {
    display: flex;
    align-items: center;
    min-width: 0;
  }

  .site-brand__copy strong {
    font-size: 1.05rem;
    line-height: 1;
    white-space: nowrap;
  }

  .site-brand__crest {
    width: 40px;
    height: 40px;
    border-radius: 14px;
  }

  .site-brand__crest-ring {
    inset: 5px;
    border-radius: 10px;
  }

  .site-navbar .nav-link {
    justify-content: center;
  }

  .theme-switcher__toggle {
    min-width: 0;
  }

  .dashboard-hero__copy,
  .page-header,
  .album-hero {
    grid-template-columns: 1fr;
  }

  .page-header {
    align-items: stretch;
    flex-direction: column;
    padding: 1rem;
    border-radius: 1.1rem;
  }

  .page-header--compact {
    gap: 0.7rem;
    padding: 0.85rem 0.95rem;
  }

  .page-header--compact .page-kicker {
    margin-bottom: 0.2rem;
  }

  .page-header--compact .page-title {
    font-size: 1.9rem;
  }

  .page-header--compact .page-subtitle {
    font-size: 0.9rem;
  }

  .home-hero {
    grid-template-columns: 1fr;
    gap: 1rem;
    padding: 1.2rem;
  }

  .home-hero__lead .page-title {
    max-width: none;
    font-size: clamp(2.35rem, 8vw, 3.15rem);
    line-height: 0.96;
  }

  .home-hero__lead .page-subtitle {
    max-width: none;
    font-size: 0.97rem;
    line-height: 1.5;
  }

  .home-hero__actions {
    gap: 0.65rem;
    margin-top: 1.15rem;
  }

  .home-auth-panel {
    grid-template-columns: 1fr;
    gap: 0.6rem;
    margin-top: 0.95rem;
    padding: 0.65rem;
  }

  .home-auth-panel .btn {
    width: 100%;
  }

  .home-hero__aside {
    padding: 1.05rem 1rem;
    gap: 0.75rem;
  }

  .home-hero__steps {
    gap: 0.65rem;
  }

  .home-hero__steps li {
    font-size: 0.95rem;
  }

  .auth-page {
    padding-top: 0;
  }

  .auth-card {
    padding: 0.95rem;
    border-radius: 1rem;
  }

  .auth-card__header {
    gap: 0.32rem;
    margin-bottom: 0.72rem;
  }

  .auth-card__header h1 {
    font-size: 2rem;
  }

  .auth-card__header p {
    font-size: 0.94rem;
  }

  .auth-google-button {
    min-height: 48px;
    padding: 0.68rem 1rem;
  }

  .auth-divider {
    margin: 0.82rem 0;
  }

  .auth-form__row,
  .auth-form__row--submit {
    display: grid;
    grid-template-columns: 1fr;
    gap: 0.65rem;
    align-items: stretch;
  }

  .auth-submit {
    width: 100%;
  }

  .missing-page {
    gap: 0.7rem;
  }

  .missing-page__header,
  .missing-page__action-panel {
    padding: 0.95rem;
  }

  .missing-page__summary .fm-summary-card {
    padding: 0.68rem 0.78rem;
  }

  .missing-page__summary .fm-summary-card strong {
    font-size: 1.45rem;
  }

  .duplicates-page {
    gap: 0.7rem;
  }

  .duplicates-page__header,
  .duplicates-page__action-panel {
    padding: 0.95rem;
  }

  .duplicates-page__summary .fm-summary-card {
    padding: 0.68rem 0.78rem;
  }

  .duplicates-page__summary .fm-summary-card strong {
    font-size: 1.45rem;
  }

  .hero-card,
  .fm-surface,
  .album-hero,
  .fm-action-panel {
    padding: 1rem;
    border-radius: 1.1rem;
  }

  .dashboard-hero__actions,
  .match-board__header,
  .match-card__top,
  .match-card__footer,
  .match-card__stats {
    justify-content: stretch;
    align-items: stretch;
    flex-direction: column;
  }

  .dashboard-stat-grid {
    grid-template-columns: 1fr;
  }

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

  .album-stat-card {
    min-width: 0;
    padding: 0.7rem;
  }

  .album-stat-card strong {
    font-size: 1.45rem;
  }

  .site-footer__content {
    flex-direction: column;
  }

  .fm-section-title,
  .fm-info-panel,
  .album-missing-strip {
    align-items: stretch;
    flex-direction: column;
  }

  .fm-info-panel {
    grid-template-columns: 1fr;
    gap: 0.7rem;
    padding: 0.85rem;
  }

  .fm-info-panel__icon {
    width: 52px;
    height: 52px;
    justify-self: start;
  }

  .fm-collection-item {
    grid-template-columns: 1fr;
  }

  .fm-card-token {
    width: 100%;
    height: 54px;
  }

  .fm-collection-item__actions {
    justify-content: stretch;
  }

  .fm-collection-item__actions form,
  .fm-collection-item__actions .btn {
    width: 100%;
  }

  .fm-list-filter {
    grid-template-columns: 1fr;
  }

  .fm-list-filter--matches {
    grid-template-columns: 1fr;
    gap: 0.6rem;
    padding: 0.78rem;
  }

  .fm-list-filter--album {
    grid-template-columns: 1fr;
    gap: 0.6rem;
    padding: 0.78rem;
  }

  .fm-list-filter--matches .fm-list-filter__count {
    width: 100%;
  }

  .fm-list-filter--album .fm-list-filter__count {
    width: 100%;
  }

  .fm-section-title {
    gap: 0.6rem;
    margin-bottom: 0.65rem;
  }

  .fm-section-title h2 {
    font-size: 1.25rem;
  }

  .fm-section-title > div:first-child {
    flex: 0 0 auto;
  }

  .fm-section-title > * {
    width: 100%;
  }

  .fm-section-title .btn,
  .fm-section-title .fm-chip {
    width: fit-content;
    max-width: 100%;
  }

  .help-page .page-header .btn {
    width: 100%;
  }

  .help-page .page-header > .d-flex {
    justify-content: stretch;
  }

  .help-step-grid,
  .help-info-grid {
    grid-template-columns: 1fr;
  }

  .help-checklist {
    grid-template-columns: 1fr;
    gap: 0.4rem;
  }

  .help-checklist li {
    min-height: 0;
    padding: 0.52rem 0.65rem 0.52rem 2.15rem;
    font-size: 0.84rem;
  }

  .dashboard-quickstrip {
    gap: 0.5rem;
  }

  .dashboard-quickstrip span {
    flex: 1 1 calc(50% - 0.5rem);
    justify-content: space-between;
  }

  .album-page-nav {
    gap: 0.65rem;
    padding: 0.58rem;
  }

  .album-page-hero--dense {
    gap: 0.4rem;
    padding: 0.58rem 0.62rem;
  }

  .album-page-hero--dense .display-6,
  .album-page-hero--dense h1 {
    font-size: 1.16rem;
    line-height: 0.98;
  }

  .album-page-hero__hint {
    display: none;
  }

  .album-page-hero--dense .album-kicker {
    font-size: 0.7rem;
    letter-spacing: 0.1em;
  }

  .album-page-hero--dense .country-identity--hero {
    gap: 0.42rem;
    margin-bottom: 0;
  }

  .album-page-hero--dense .country-identity--hero .country-flag {
    inline-size: 1.35rem;
    block-size: 1.35rem;
  }

  .album-page-summary {
    gap: 0.28rem;
    margin-top: 0.2rem;
  }

  .album-page-summary span {
    flex: 1 1 calc(50% - 0.32rem);
    padding: 0.18rem 0.42rem;
    font-size: 0.64rem;
  }

  .album-page-summary strong {
    font-size: 0.7rem;
  }

  .album-page-nav--compact {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.42rem;
    padding: 0.42rem;
  }

  .album-page-nav--swipe {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .album-page-nav--swipe > :first-child {
    grid-column: 1;
    grid-row: 1;
  }

  .album-page-nav--swipe > :last-child {
    grid-column: 2;
    grid-row: 1;
  }

  .album-page-nav--footer {
    grid-template-columns: 1fr 1fr;
  }

  .album-page-nav--footer > :last-child {
    justify-self: stretch;
  }

  .album-page-nav__footer-spacer {
    display: none;
  }

  .album-page-nav__progress {
    padding: 0.65rem;
  }

  .album-page-nav__swipe-hint {
    grid-column: 1 / -1;
    grid-row: 2;
    gap: 0.42rem;
    justify-content: center;
    padding: 0.38rem 0.58rem;
    border-radius: 0.78rem;
  }

  .album-page-nav__swipe-copy {
    gap: 0.04rem;
    text-align: center;
  }

  .album-page-nav__swipe-copy strong {
    font-size: 0.68rem;
  }

  .album-page-nav__swipe-copy span {
    font-size: 0.62rem;
    line-height: 1.1;
  }

  .album-page-nav--compact .btn,
  .album-page-nav--compact > .disabled {
    min-height: 2rem;
    padding: 0.34rem 0.4rem;
    font-size: 0.74rem;
  }

  .album-page-nav__progress strong {
    font-size: 1.5rem;
  }

  .album-page-guide--compact {
    grid-template-columns: 1fr;
    gap: 0.45rem;
    padding: 0.58rem;
  }

  .album-page-swipe-hint {
    flex-direction: column;
    align-items: flex-start;
    gap: 0.35rem;
  }

  .album-page-swipe::before {
    right: 0.65rem;
    bottom: 0.85rem;
    width: 48px;
    height: 48px;
  }

  .album-page-swipe::after {
    right: 4.2rem;
    bottom: 1.58rem;
    padding: 0.34rem 0.58rem;
    font-size: 0.62rem;
    letter-spacing: 0.1em;
  }

  .album-page-guide--compact h2 {
    font-size: 1rem;
  }

  .album-page-guide--compact p {
    font-size: 0.74rem;
  }

  .album-page-guide--compact .album-legend {
    justify-content: flex-start;
    gap: 0.4rem;
    font-size: 0.7rem;
  }

  .breadcrumb {
    font-size: 0.86rem;
    overflow-wrap: anywhere;
  }

  .btn {
    white-space: normal;
  }

  .album-slot-grid--page {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.48rem;
  }

  .album-section-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.58rem;
  }

  .album-section-card {
    padding: 0.62rem;
    border-radius: 0.95rem;
  }

  .album-section-card__top,
  .album-section-card__meta,
  .album-section-card__cta {
    gap: 0.35rem;
  }

  .album-section-card__identity {
    gap: 0.28rem;
  }

  .album-section-card__identity .country-flag {
    inline-size: 1.35rem;
    block-size: 1.35rem;
    border-radius: 0.45rem;
  }

  .album-section-card .album-chip,
  .album-section-card__top > .text-muted,
  .album-section-card__meta,
  .album-section-card__cta {
    font-size: 0.64rem;
    line-height: 1.15;
  }

  .album-section-card h2 {
    margin-bottom: 0.15rem;
    font-size: 0.84rem;
    line-height: 1.08;
  }

  .album-section-card p {
    margin-bottom: 0.45rem !important;
    font-size: 0.68rem;
    line-height: 1.15;
  }

  .album-section-card__meta,
  .album-section-card__cta {
    align-items: flex-start;
    flex-direction: column;
  }

  .album-section-card__cta .btn {
    width: 100%;
    padding: 0.32rem 0.4rem;
    font-size: 0.62rem;
    line-height: 1.1;
  }

  .album-section-card .album-progress {
    height: 0.34rem;
    margin: 0.5rem 0;
  }

  .album-slot-grid--page .album-slot-card {
    min-height: 0;
    padding: 0.5rem;
    border-radius: 0.9rem;
  }

  .album-slot-grid--page .album-slot-card::before {
    inset: 0.32rem;
    border-radius: 0.62rem;
  }

  .album-slot-grid--page .album-slot-card__header {
    gap: 0.25rem;
    margin-bottom: 0.28rem;
  }

  .album-slot-grid--page .album-chip,
  .album-slot-grid--page .text-muted {
    font-size: 0.62rem;
    min-width: 0;
    overflow-wrap: anywhere;
  }

  .album-slot-grid--page .album-slot-card__title {
    -webkit-line-clamp: 2;
    font-size: 0.75rem;
    line-height: 1.02;
  }

  .album-slot-grid--page .album-slot-card__body {
    min-height: 0;
    gap: 0.22rem;
  }

  .album-slot-grid--page .album-slot-card__meta {
    font-size: 0.68rem;
  }

  .album-slot-grid--page .album-slot-card__meta .country-flag {
    inline-size: 0.9rem;
    block-size: 0.9rem;
  }

  .album-slot-card__state,
  .album-slot-card__duplicate-badge {
    padding: 0.18rem 0.34rem;
    margin-top: 0.14rem;
    font-size: 0.58rem;
  }

  .album-slot-grid--page .album-status-line {
    align-items: stretch;
    flex-direction: column;
    gap: 0.22rem;
    padding: 0.24rem;
  }

  .album-slot-grid--page .album-status-line .btn,
  .album-slot-grid--page .album-inline-form {
    width: 100%;
    min-height: 24px;
    font-size: 0.6rem;
    padding-inline: 0.22rem;
  }

  .album-status-line__label {
    font-size: 0.62rem;
  }

  .album-slot-grid--page .album-duplicate-controls {
    grid-template-columns: 22px minmax(14px, auto) 22px;
    justify-content: center;
    width: 100%;
    padding: 0.08rem 0.12rem;
  }

  .album-slot-grid--page .album-duplicate-qty {
    font-size: 0.76rem;
  }

  .admin-activity-item {
    flex-direction: column;
    align-items: stretch;
  }

  .admin-activity-item .fm-chip {
    width: fit-content;
    max-width: 100%;
  }

  .physical-album-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .album-book-spread {
    grid-template-columns: 1fr;
  }

  .album-book-page {
    padding: 0.9rem;
  }

  .album-book-page__header {
    flex-direction: column;
    align-items: stretch;
  }

  .album-book-page__header .btn {
    width: 100%;
  }

  .album-book-slots {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .album-book-slot__footer {
    align-items: stretch;
    flex-direction: column;
  }

  .album-book-slot__duplicate {
    align-self: start;
  }
}

@media (max-width: 480px) {
  .page-title {
    font-size: 1.75rem;
  }

  .display-6 {
    font-size: 1.55rem;
  }

  .country-identity--hero {
    align-items: flex-start;
  }

  .country-identity--hero .country-flag {
    inline-size: 1.65rem;
    block-size: 1.65rem;
  }

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

  .fm-summary-card {
    padding: 0.75rem;
  }

  .stat-card {
    grid-template-columns: 1fr;
  }

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

  .dashboard-quickstrip:not(.album-page-summary) span {
    flex-basis: 100%;
  }

  .album-page-summary span {
    flex: 1 1 calc(50% - 0.32rem);
  }
}

.contest-nav {
  display: flex;
  gap: 0.6rem;
  row-gap: 0.55rem;
  flex-wrap: wrap;
  align-items: center;
  max-width: 100%;
  overflow: visible;
  overflow-y: visible;
  position: relative;
  z-index: 25;
}

.contest-nav > .fm-chip {
  flex: 0 0 auto;
  max-width: 100%;
  white-space: nowrap;
}

.contest-dashboard {
  display: grid;
  gap: 1rem;
}

.contest-dashboard__hero {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  min-width: 0;
}

.contest-dashboard__hero h2 {
  margin: 0.25rem 0 0;
  color: var(--fm-heading);
  font-size: 1.7rem;
  line-height: 1;
}

.contest-dashboard__main-action {
  min-width: 11rem;
}

.contest-dashboard__stats,
.contest-dashboard__actions {
  display: grid;
  gap: 0.7rem;
  min-width: 0;
}

.contest-dashboard__stats {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.contest-dashboard__stats article,
.contest-dashboard-link {
  min-width: 0;
  padding: 0.78rem;
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 78%, transparent);
  border-radius: 0.85rem;
  background: color-mix(in srgb, var(--fm-card-strong) 76%, #08111d);
}

.contest-dashboard__stats span,
.contest-dashboard-link span {
  color: var(--fm-muted);
  font-size: 0.78rem;
  font-weight: 800;
}

.contest-dashboard__stats strong {
  display: block;
  margin-top: 0.15rem;
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: 1.35rem;
  line-height: 1;
}

.contest-dashboard__stat--live {
  border-color: color-mix(in srgb, var(--fm-success) 48%, var(--fm-card-border));
}

.contest-dashboard__actions {
  grid-template-columns: repeat(4, minmax(0, 1fr));
}

.contest-dashboard-link {
  display: grid;
  gap: 0.2rem;
  color: var(--fm-heading);
  text-decoration: none;
}

.contest-dashboard-link:hover,
.contest-dashboard-link:focus-visible {
  color: var(--fm-heading);
  border-color: var(--fm-primary);
  text-decoration: none;
}

.contest-rules-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 1rem;
  align-items: start;
  overflow: visible;
}

.contest-home-hero {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(320px, 0.85fr);
  gap: 1.1rem;
  align-items: stretch;
  padding: 1.15rem;
}

.contest-home-hero__lead {
  display: grid;
  gap: 0.8rem;
  min-width: 0;
}

.contest-home-hero__eyebrow {
  display: inline-flex;
  width: fit-content;
  max-width: 100%;
  padding: 0.32rem 0.72rem;
  border-radius: 999px;
  color: var(--fm-accent);
  background: color-mix(in srgb, var(--fm-accent) 14%, transparent);
  border: 1px solid color-mix(in srgb, var(--fm-accent) 26%, transparent);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
  overflow-wrap: anywhere;
}

.contest-home-hero__title {
  margin: 0;
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: clamp(2rem, 3.3vw, 3rem);
  line-height: 0.98;
  letter-spacing: -0.04em;
  overflow-wrap: anywhere;
}

.contest-home-hero__copy {
  margin: 0;
  color: var(--fm-muted);
  font-size: 1rem;
  line-height: 1.5;
  overflow-wrap: anywhere;
}

.contest-home-hero__chips {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

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

.contest-section-stack {
  display: grid;
  gap: 1rem;
}

.contest-home-shell {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(320px, 0.8fr);
  gap: 1rem;
  align-items: stretch;
}

.contest-home-shell--bottom {
  grid-template-columns: minmax(0, 1fr) minmax(280px, 0.8fr);
}

.contest-home-status {
  display: grid;
  gap: 0.9rem;
  min-width: 0;
  padding: 1rem;
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 84%, transparent);
  border-radius: 1.35rem;
  background:
    radial-gradient(circle at top right, color-mix(in srgb, var(--fm-primary) 16%, transparent), transparent 38%),
    linear-gradient(180deg, color-mix(in srgb, var(--fm-card-strong) 88%, transparent), color-mix(in srgb, var(--fm-surface) 96%, transparent));
}

.contest-home-status__head,
.contest-home-status__grid,
.contest-home-groups__identity {
  display: grid;
  gap: 0.2rem;
  min-width: 0;
}

.contest-home-status__eyebrow,
.contest-prediction-card__step,
.contest-predictions-scorecard__eyebrow {
  color: var(--fm-accent);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.contest-home-status__head strong {
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: 1.45rem;
  line-height: 1;
  overflow-wrap: anywhere;
}

.contest-home-status__grid {
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.75rem;
}

.contest-home-status__card {
  display: grid;
  gap: 0.3rem;
  min-width: 0;
  padding: 0.9rem;
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 72%, transparent);
  border-radius: 1rem;
  background: color-mix(in srgb, var(--fm-surface) 74%, transparent);
}

.contest-home-status__card--accent {
  border-color: color-mix(in srgb, var(--fm-success) 36%, var(--fm-card-border));
  background:
    radial-gradient(circle at top right, color-mix(in srgb, var(--fm-success) 12%, transparent), transparent 42%),
    color-mix(in srgb, var(--fm-surface) 74%, transparent);
}

.contest-home-status__card > span,
.contest-home-groups__identity span,
.contest-checklist__item span {
  color: var(--fm-muted);
  font-size: 0.84rem;
  line-height: 1.38;
  overflow-wrap: anywhere;
}

.contest-home-status__card strong {
  color: var(--fm-heading);
  font-size: 1.25rem;
  line-height: 1.05;
  overflow-wrap: anywhere;
}

.contest-list-toolbar {
  display: flex;
  align-items: end;
  justify-content: space-between;
  gap: 0.9rem;
  flex-wrap: wrap;
  margin-bottom: 0.9rem;
}

.contest-searchbar {
  display: grid;
  gap: 0.35rem;
  flex: 1 1 18rem;
  min-width: min(100%, 18rem);
}

.contest-searchbar > span {
  color: var(--fm-muted);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.contest-empty-state,
.contest-checklist__item,
.contest-predictions-scorecard,
.contest-prediction-card {
  min-width: 0;
  padding: 0.9rem;
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 74%, transparent);
  border-radius: 1rem;
  background: color-mix(in srgb, var(--fm-card-strong) 68%, transparent);
}

.contest-empty-state strong,
.contest-home-groups__identity strong,
.contest-checklist__item strong,
.contest-prediction-card__head strong {
  color: var(--fm-heading);
  overflow-wrap: anywhere;
}

.contest-empty-state p {
  color: var(--fm-muted);
}

.contest-checklist {
  display: grid;
  gap: 0.75rem;
}

.contest-predictions-shell {
  display: grid;
  gap: 1rem;
  overflow: visible;
}

.contest-predictions-layout {
  display: grid;
  grid-template-columns: minmax(0, 1.2fr) minmax(260px, 0.8fr);
  gap: 1rem;
  align-items: start;
}

.contest-predictions-fields,
.contest-predictions-side {
  display: grid;
  gap: 0.9rem;
  min-width: 0;
  overflow: visible;
}

.contest-predictions-shell--compact {
  max-width: 920px;
}

.contest-predictions-fields--compact {
  grid-template-columns: repeat(3, minmax(0, 1fr));
}

.contest-prediction-points {
  display: flex;
  flex-wrap: wrap;
  gap: 0.4rem;
  margin-top: 0.45rem;
}

.contest-prediction-card {
  display: grid;
  gap: 0.7rem;
  overflow: visible;
}

.contest-prediction-card--picker {
  gap: 0.9rem;
}

.contest-prediction-card__head {
  display: grid;
  gap: 0.18rem;
}

.contest-picker,
.contest-picker__field,
.contest-picker__selected {
  display: grid;
  gap: 0.45rem;
  min-width: 0;
}

.contest-picker {
  position: relative;
  z-index: 1;
  isolation: isolate;
  overflow: visible;
}

.contest-picker:focus-within,
.contest-picker--open {
  z-index: 60;
}

.contest-picker__label {
  color: var(--fm-muted);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.contest-picker__input {
  min-height: 50px;
}

.contest-picker__panel {
  position: absolute;
  top: calc(100% + 0.45rem);
  left: 0;
  right: 0;
  z-index: 80;
  padding: 0.45rem;
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 88%, transparent);
  border-radius: 1rem;
  background: color-mix(in srgb, var(--fm-card-strong) 96%, #08111d);
  box-shadow: 0 22px 44px rgba(0, 0, 0, 0.24);
  backdrop-filter: none;
  overflow: hidden;
}

.contest-picker--dropup .contest-picker__panel {
  top: auto;
  bottom: calc(100% + 0.45rem);
}

.contest-picker__results {
  display: grid;
  gap: 0.35rem;
  max-height: min(16rem, var(--contest-picker-max-height, 16rem));
  overflow-y: auto;
}

.contest-picker__option {
  width: 100%;
  min-height: 42px;
  padding: 0.62rem 0.78rem;
  border: 0;
  border-radius: 0.85rem;
  color: var(--fm-heading);
  background: color-mix(in srgb, var(--fm-surface) 94%, #08111d);
  font-weight: 700;
  text-align: left;
  overflow-wrap: anywhere;
}

.contest-picker__option:hover,
.contest-picker__option:focus-visible,
.contest-picker__option--active {
  background: color-mix(in srgb, var(--fm-primary) 22%, var(--fm-surface));
  outline: none;
}

.contest-picker__empty {
  color: var(--fm-muted);
  font-size: 0.86rem;
  padding: 0.4rem 0.5rem;
}

.contest-picker__selected {
  padding: 0.72rem 0.8rem;
  border: 1px solid color-mix(in srgb, var(--fm-success) 32%, var(--fm-card-border));
  border-radius: 0.95rem;
  background: color-mix(in srgb, var(--fm-success) 10%, transparent);
}

.contest-picker__selected span {
  color: var(--fm-success);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.1em;
  text-transform: uppercase;
}

.contest-picker__selected strong {
  color: var(--fm-heading);
  overflow-wrap: anywhere;
}

.contest-prediction-card p,
.contest-predictions-scorecard p {
  margin: 0;
  color: var(--fm-muted);
  overflow-wrap: anywhere;
}

.contest-suggestion-cloud {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.5rem;
  max-height: 16rem;
  overflow: auto;
  padding-right: 0.2rem;
}

.contest-suggestion-cloud-wrap {
  display: grid;
  gap: 0.55rem;
}

.contest-suggestion-cloud__item {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  max-width: 100%;
  min-height: 38px;
  padding: 0.52rem 0.82rem;
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 74%, transparent);
  border-radius: 999px;
  color: var(--fm-heading);
  background: color-mix(in srgb, var(--fm-surface) 80%, transparent);
  font-size: 0.82rem;
  font-weight: 800;
  overflow-wrap: anywhere;
}

.contest-suggestion-cloud__item:hover,
.contest-suggestion-cloud__item:focus {
  border-color: var(--fm-primary);
  background: color-mix(in srgb, var(--fm-primary) 14%, var(--fm-surface));
}

.contest-suggestion-cloud__item:disabled {
  opacity: 0.58;
}

.contest-grid--hero {
  align-content: start;
}

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

.contest-stat {
  display: flex;
  flex-direction: column;
  gap: 0.32rem;
  min-height: 110px;
  justify-content: center;
  min-width: 0;
  padding: 1rem;
  border-radius: 1.2rem;
  overflow: hidden;
}

.contest-stat strong {
  font-size: clamp(1.4rem, 2vw, 2rem);
  line-height: 1.02;
  overflow-wrap: anywhere;
}

.contest-stat__label {
  color: var(--fm-text-muted);
  text-transform: uppercase;
  letter-spacing: 0.08em;
  font-size: 0.75rem;
  overflow-wrap: anywhere;
}

.contest-stat small {
  color: var(--fm-muted);
  font-size: 0.82rem;
  line-height: 1.3;
  overflow-wrap: anywhere;
}

.contest-stat--highlight {
  background:
    radial-gradient(circle at top right, color-mix(in srgb, var(--fm-accent) 18%, transparent), transparent 38%),
    linear-gradient(180deg, color-mix(in srgb, var(--fm-card-strong) 88%, transparent), color-mix(in srgb, var(--fm-surface) 96%, transparent));
  border-color: color-mix(in srgb, var(--fm-accent) 28%, var(--fm-card-border));
}

.contest-panel {
  min-width: 0;
  padding: 1rem;
  overflow: visible;
}

.contest-rules-grid > .contest-panel,
.contest-predictions-shell,
.contest-predictions-form,
.contest-predictions-fields,
.contest-prediction-card--picker,
.contest-prediction-card--picker .contest-picker,
.contest-prediction-card--picker .contest-picker__field,
.contest-nav,
.contest-list-toolbar,
.contest-ranking-list,
.contest-empty-state {
  overflow: visible;
}

.contest-panel .fm-section-title {
  align-items: flex-start;
}

.contest-panel .fm-section-title > div {
  min-width: 0;
}

.contest-panel .fm-section-title .fm-chip,
.contest-panel .fm-section-title .btn {
  flex: 0 0 auto;
  max-width: 100%;
}

.contest-panel .fm-section-title h2,
.contest-panel .fm-section-title p {
  overflow-wrap: anywhere;
}

.contest-rule-list,
.contest-prize-list {
  display: grid;
  gap: 0.75rem;
}

.contest-rule-list > div,
.contest-rule-list--compact {
  min-width: 0;
}

.contest-rule-list > div {
  display: flex;
  justify-content: space-between;
  gap: 0.85rem;
  padding: 0.72rem 0.8rem;
  border-radius: 1rem;
  background: color-mix(in srgb, var(--fm-card-strong) 72%, transparent);
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 74%, transparent);
}

.contest-rule-list > div strong,
.contest-rule-list > div span {
  min-width: 0;
  overflow-wrap: anywhere;
}

.contest-rule-list > div strong {
  color: var(--fm-heading);
}

.contest-rule-list > div span {
  color: var(--fm-muted);
  text-align: right;
}

.contest-rule-list--compact {
  gap: 0.35rem;
}

.contest-prize-list div,
.contest-summary-inline {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
}

.contest-prize-list div {
  min-width: 0;
  padding: 0.78rem 0.82rem;
  border-radius: 1rem;
  background: color-mix(in srgb, var(--fm-card-strong) 72%, transparent);
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 74%, transparent);
}

.contest-prize-list span,
.contest-prize-list strong {
  min-width: 0;
  overflow-wrap: anywhere;
}

.contest-prize-list strong {
  text-align: right;
}

.contest-panel__note {
  overflow-wrap: anywhere;
}

.contest-home-groups,
.contest-home-groups__list {
  display: grid;
  gap: 0.65rem;
  min-width: 0;
}

.contest-home-groups__list--grid {
  grid-template-columns: repeat(auto-fit, minmax(230px, 1fr));
}

.contest-home-groups__item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  min-width: 0;
  padding: 0.72rem 0.78rem;
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 72%, transparent);
  border-radius: 0.95rem;
  background: color-mix(in srgb, var(--fm-surface) 70%, transparent);
}

.contest-home-groups__identity strong {
  display: block;
}

.contest-home-groups__item--card {
  min-height: 100%;
  align-items: flex-start;
  flex-direction: column;
}

.contest-home-groups__item--card .fm-chip {
  align-self: flex-start;
}

.contest-home-groups__item > span:first-child {
  min-width: 0;
  overflow-wrap: anywhere;
}

.contest-ranking-list {
  display: grid;
  gap: 0.75rem;
}

.contest-ranking-row {
  display: grid;
  grid-template-columns: minmax(4.25rem, 0.3fr) minmax(0, 1.2fr) minmax(0, 1fr) minmax(8rem, 0.7fr);
  gap: 0.85rem;
  align-items: center;
  min-width: 0;
  padding: 0.85rem 0.95rem;
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 74%, transparent);
  border-radius: 1rem;
  background: color-mix(in srgb, var(--fm-card-strong) 72%, transparent);
}

.contest-ranking-row--me {
  border-color: color-mix(in srgb, var(--fm-success) 48%, var(--fm-card-border));
  background:
    radial-gradient(circle at top right, color-mix(in srgb, var(--fm-success) 12%, transparent), transparent 38%),
    color-mix(in srgb, var(--fm-card-strong) 78%, transparent);
}

.contest-ranking-row__position,
.contest-ranking-row__identity,
.contest-ranking-row__metrics,
.contest-ranking-row__prize {
  display: grid;
  gap: 0.18rem;
  min-width: 0;
}

.contest-ranking-row__position {
  justify-items: center;
}

.contest-ranking-row__position strong,
.contest-ranking-row__prize strong {
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: 1.35rem;
  line-height: 1;
}

.contest-ranking-row__identity strong {
  color: var(--fm-heading);
  font-size: 1rem;
}

.contest-ranking-row__position span,
.contest-ranking-row__identity span,
.contest-ranking-row__metrics span,
.contest-ranking-row__prize span {
  color: var(--fm-muted);
  font-size: 0.8rem;
  overflow-wrap: anywhere;
}

.contest-ranking-row__prize {
  justify-items: end;
  text-align: right;
}

.contest-ranking-row--bets {
  grid-template-columns: minmax(3.8rem, 0.22fr) minmax(0, 1.35fr) minmax(0, 0.9fr) minmax(6.5rem, 0.45fr);
  gap: 0.65rem;
  padding: 0.68rem 0.8rem;
}

.contest-bet-row__teams {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.42rem;
  min-width: 0;
}

.contest-bet-row__team {
  min-width: 0;
  gap: 0.4rem;
}

.contest-bet-row__team .country-flag {
  inline-size: 1.05rem;
  block-size: 1.05rem;
  flex: 0 0 auto;
}

.contest-bet-row__team > span:last-child {
  overflow-wrap: anywhere;
}

.contest-bet-row__versus {
  color: var(--fm-muted);
  font-size: 0.76rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.contest-match-list {
  display: grid;
  gap: 1rem;
}

.contest-matches-board {
  display: grid;
  gap: 1rem;
}

.contest-match-filter {
  display: grid;
  gap: 0.8rem;
  min-width: 0;
}

.contest-match-filter__quick,
.contest-match-filter__fields {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  min-width: 0;
}

.contest-match-filter__fields {
  align-items: end;
}

.contest-match-filter__fields .contest-searchbar {
  flex: 1 1 11rem;
  min-width: min(100%, 11rem);
}

.contest-match-filter__count {
  align-self: end;
}

.contest-filter-pill {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  min-height: 38px;
  padding: 0.48rem 0.78rem;
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 78%, transparent);
  border-radius: 999px;
  color: var(--fm-heading);
  background: color-mix(in srgb, var(--fm-card-strong) 88%, #08111d);
  font-size: 0.84rem;
  font-weight: 900;
}

.contest-filter-pill span {
  color: var(--fm-muted);
  font-size: 0.76rem;
}

.contest-filter-pill--active,
.contest-filter-pill:hover,
.contest-filter-pill:focus-visible {
  border-color: var(--fm-primary);
  color: var(--fm-button-text);
  background: var(--fm-button-bg);
}

.contest-filter-pill--active span,
.contest-filter-pill:hover span,
.contest-filter-pill:focus-visible span {
  color: currentColor;
}

.contest-filter-pill--live {
  border-color: color-mix(in srgb, var(--fm-success) 46%, var(--fm-card-border));
}

.contest-compact-match-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(260px, 1fr));
  gap: 0.85rem;
}

.contest-compact-match-card {
  display: grid;
  gap: 0.65rem;
  min-width: 0;
  padding: 0.78rem;
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 82%, transparent);
  border-radius: 0.85rem;
  background: color-mix(in srgb, var(--fm-card-strong) 76%, #08111d);
}

.contest-compact-match-card--saving {
  box-shadow: 0 0 0 1px color-mix(in srgb, var(--fm-primary) 26%, transparent);
}

.contest-compact-match-card__top,
.contest-compact-match-card__details,
.contest-compact-bet-form__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.5rem;
  min-width: 0;
}

.contest-compact-match-card__top {
  color: var(--fm-muted);
  font-size: 0.78rem;
  font-weight: 800;
}

.contest-match-status {
  display: inline-flex;
  align-items: center;
  gap: 0.34rem;
  flex: 0 0 auto;
  min-height: 26px;
  padding: 0.22rem 0.52rem;
  border-radius: 999px;
  color: var(--fm-muted);
  background: color-mix(in srgb, var(--fm-surface) 86%, #08111d);
  font-size: 0.72rem;
  font-weight: 900;
}

.contest-match-status--live {
  color: #0d3b22;
  background: color-mix(in srgb, var(--fm-success) 84%, white);
}

.contest-match-status--finished {
  color: var(--fm-heading);
}

.contest-match-status__dot {
  width: 0.48rem;
  height: 0.48rem;
  border-radius: 999px;
  background: currentColor;
  box-shadow: 0 0 0 0.22rem color-mix(in srgb, var(--fm-success) 22%, transparent);
}

.contest-compact-scoreboard {
  display: grid;
  grid-template-columns: minmax(0, 1fr) auto minmax(0, 1fr);
  gap: 0.55rem;
  align-items: center;
}

.contest-compact-team {
  display: grid;
  gap: 0.25rem;
  min-width: 0;
  justify-items: start;
}

.contest-compact-team--right {
  justify-items: end;
  text-align: right;
}

.contest-compact-team .country-flag {
  inline-size: 1.45rem;
  block-size: 1.45rem;
}

.contest-compact-team strong {
  color: var(--fm-heading);
  font-size: 0.9rem;
  line-height: 1.1;
  overflow-wrap: anywhere;
}

.contest-compact-score {
  min-width: 3.4rem;
  padding: 0.42rem 0.52rem;
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 80%, transparent);
  border-radius: 0.75rem;
  color: var(--fm-heading);
  background: color-mix(in srgb, var(--fm-surface) 88%, #08111d);
  font-family: var(--fm-font-display);
  font-size: 1.05rem;
  font-weight: 950;
  text-align: center;
}

.contest-compact-match-card__details {
  align-items: flex-start;
  flex-wrap: wrap;
  justify-content: flex-start;
  color: var(--fm-muted);
  font-size: 0.76rem;
  line-height: 1.3;
}

.contest-compact-points {
  color: var(--fm-success);
  font-weight: 900;
}

.contest-compact-bet-form {
  display: grid;
  gap: 0.55rem;
  min-width: 0;
}

.contest-compact-bet-form--saving .form-control[readonly] {
  opacity: 1;
  cursor: progress;
}

.contest-compact-bet-form--saving .btn {
  cursor: progress;
}

.contest-compact-bet-form__scores {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.5rem;
}

.contest-compact-bet-form__scores label {
  display: grid;
  gap: 0.22rem;
  min-width: 0;
  margin: 0;
}

.contest-compact-bet-form__scores span {
  color: var(--fm-muted);
  font-size: 0.7rem;
  font-weight: 900;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.contest-compact-bet-form__scores .form-control {
  min-height: 38px;
  padding-block: 0.35rem;
}

.contest-compact-bet-note {
  color: var(--fm-muted);
  font-size: 0.76rem;
  font-weight: 900;
}

.contest-compact-bet-note--saved {
  color: var(--fm-success);
}

.contest-compact-bet-note--pending {
  color: var(--fm-warning);
}

.contest-compact-bet-note--locked {
  color: var(--fm-muted);
}

.contest-compact-bet-state {
  display: grid;
  gap: 0.18rem;
  min-width: 0;
}

.contest-compact-bet-feedback {
  font-size: 0.72rem;
  font-weight: 800;
  line-height: 1.25;
}

.contest-compact-bet-feedback--success {
  color: var(--fm-success);
}

.contest-compact-bet-feedback--error {
  color: var(--fm-danger);
}

.contest-day-group {
  display: grid;
  gap: 1rem;
}

.contest-match-card__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.75rem 1rem;
  color: var(--fm-text-muted);
}

.contest-match-card__time {
  color: var(--fm-accent);
  font-weight: 700;
  margin-bottom: 0.35rem;
}

.contest-match-card__teams {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  flex-wrap: wrap;
}

.contest-team-inline {
  display: inline-flex;
  align-items: center;
  gap: 0.55rem;
}

.contest-team-inline .country-flag {
  inline-size: 1.7rem;
  block-size: 1.7rem;
  flex: 0 0 auto;
}

.contest-versus {
  color: var(--fm-text-muted);
  font-size: 0.9rem;
  text-transform: uppercase;
  letter-spacing: 0.08em;
}

.contest-bet-form {
  display: grid;
  gap: 0.85rem;
}

.contest-bet-form__scores {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 0.9rem;
}

.contest-bet-form__scores label {
  display: grid;
  gap: 0.45rem;
  font-weight: 600;
}

.contest-bet-form__footer,
.contest-predictions-form__footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  flex-wrap: wrap;
}

.contest-predictions-form {
  display: grid;
  gap: 1rem;
}

.contest-bet-form__status {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
  align-items: center;
}

.contest-bracket-shell {
  display: grid;
  gap: 1rem;
  padding: 1rem;
  min-width: 0;
  overflow: visible;
}

.contest-bracket-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.85rem;
  flex-wrap: wrap;
}

.contest-bracket-toolbar__actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.55rem;
}

.contest-bracket-scroll {
  width: 100%;
  max-width: 100%;
  overflow-x: auto;
  overflow-y: visible;
  padding: 0.2rem 0.25rem 0.85rem;
  margin: 0;
  scrollbar-width: thin;
  scrollbar-color: color-mix(in srgb, var(--fm-primary) 44%, transparent) transparent;
  scrollbar-gutter: stable both-edges;
  -webkit-overflow-scrolling: touch;
  scroll-behavior: smooth;
  scroll-padding-inline: 0.8rem 2rem;
  cursor: grab;
}

.contest-bracket-scroll:active {
  cursor: grabbing;
}

.contest-bracket-scroll::-webkit-scrollbar {
  height: 10px;
}

.contest-bracket-scroll::-webkit-scrollbar-thumb {
  background: color-mix(in srgb, var(--fm-primary) 32%, var(--fm-card-strong));
  border-radius: 999px;
}

.contest-bracket {
  display: grid;
  grid-auto-flow: column;
  grid-auto-columns: minmax(18rem, 20rem);
  align-items: start;
  gap: 1rem;
  min-width: max-content;
  padding: 0.35rem 2rem 0.7rem 0.55rem;
}

.contest-bracket__round {
  position: relative;
  display: grid;
  gap: 0.95rem;
  align-content: start;
  min-height: 100%;
  min-width: 0;
  padding: 0.95rem;
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 86%, transparent);
  border-radius: 1.5rem;
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--fm-card-strong) 82%, transparent), color-mix(in srgb, var(--fm-surface) 92%, transparent));
  box-shadow: 0 22px 46px rgba(0, 0, 0, 0.16);
  scroll-margin-inline: 0.85rem 2rem;
}

.contest-bracket__round::after {
  content: "";
  position: absolute;
  inset-block: 4.7rem 0.9rem;
  inset-inline-end: -0.5rem;
  width: 1px;
  background:
    linear-gradient(180deg,
      transparent 0%,
      color-mix(in srgb, var(--fm-primary) 28%, transparent) 16%,
      color-mix(in srgb, var(--fm-primary) 28%, transparent) 84%,
      transparent 100%);
}

.contest-bracket__round:last-child::after {
  display: none;
}

.contest-bracket__round--final {
  background:
    radial-gradient(circle at top, color-mix(in srgb, var(--fm-accent) 16%, transparent), transparent 54%),
    linear-gradient(180deg, color-mix(in srgb, var(--fm-card-strong) 84%, transparent), color-mix(in srgb, var(--fm-surface) 92%, transparent));
  border-color: color-mix(in srgb, var(--fm-accent) 46%, var(--fm-card-border));
}

.contest-bracket__round--third-place {
  border-style: dashed;
  border-color: color-mix(in srgb, var(--fm-warning) 44%, var(--fm-card-border));
}

.contest-bracket__round-head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.85rem;
  padding-bottom: 0.8rem;
  border-bottom: 1px solid color-mix(in srgb, var(--fm-card-border) 78%, transparent);
}

.contest-bracket__round-head h2 {
  margin: 0.12rem 0 0;
  font-size: 1.15rem;
  line-height: 1.05;
}

.contest-bracket__round-kicker {
  display: inline-block;
  color: var(--fm-accent);
  font-size: 0.72rem;
  font-weight: 900;
  letter-spacing: 0.14em;
  text-transform: uppercase;
}

.contest-bracket__matches {
  display: grid;
  gap: 1rem;
  align-content: start;
}

.contest-bracket__round--final .contest-bracket__matches {
  padding-top: 0.7rem;
}

.contest-bracket__round--third-place .contest-bracket__matches {
  padding-top: 0.35rem;
}

.contest-bracket__match {
  position: relative;
  display: grid;
  gap: 0.8rem;
  min-width: 0;
  padding: 0.92rem;
  border-radius: 1.25rem;
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 92%, transparent);
  background:
    linear-gradient(180deg, color-mix(in srgb, var(--fm-card-strong) 88%, transparent), color-mix(in srgb, var(--fm-surface) 96%, transparent));
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.03);
}

.contest-bracket__match::before {
  content: "";
  position: absolute;
  inset-inline-start: 0.7rem;
  inset-block-start: 0.7rem;
  inline-size: 0.56rem;
  block-size: 0.56rem;
  border-radius: 999px;
  background: color-mix(in srgb, var(--fm-accent) 88%, white);
  box-shadow: 0 0 0 0.22rem color-mix(in srgb, var(--fm-accent) 16%, transparent);
}

.contest-bracket__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem 0.75rem;
  padding-inline-start: 0.95rem;
  color: var(--fm-text-muted);
  font-size: 0.78rem;
  font-weight: 700;
}

.contest-bracket__scoreboard {
  display: grid;
  gap: 0.45rem;
}

.contest-bracket__team {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.85rem;
  padding: 0.72rem 0.8rem;
  border-radius: 1rem;
  background: color-mix(in srgb, var(--fm-card) 72%, transparent);
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 82%, transparent);
}

.contest-bracket__team .contest-team-inline {
  min-width: 0;
  flex: 1 1 auto;
}

.contest-bracket__team .contest-team-inline > span:last-child {
  overflow-wrap: anywhere;
}

.contest-bracket__score {
  min-width: 1.6rem;
  text-align: center;
  font-size: 1.05rem;
  color: var(--fm-heading);
}

.contest-bracket__footer {
  display: grid;
  gap: 0.65rem;
}

.contest-bracket__winner {
  display: grid;
  gap: 0.18rem;
  padding: 0.65rem 0.72rem;
  border-radius: 1rem;
  background: color-mix(in srgb, var(--fm-success) 10%, transparent);
  border: 1px solid color-mix(in srgb, var(--fm-success) 26%, transparent);
}

.contest-bracket__winner small {
  color: var(--fm-success);
  font-size: 0.7rem;
  font-weight: 900;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.contest-bracket__winner strong {
  overflow-wrap: anywhere;
}

.contest-bracket__venue {
  color: var(--fm-text-muted);
  font-size: 0.82rem;
  line-height: 1.32;
  overflow-wrap: anywhere;
}

.contest-group-list,
.contest-admin-groups,
.contest-admin-member-list,
.contest-group-ranking {
  display: grid;
  gap: 1rem;
  min-width: 0;
}

.contest-group-panel,
.contest-admin-group {
  min-width: 0;
  overflow: hidden;
}

.contest-group-panel--compact {
  display: grid;
  gap: 0.75rem;
  padding: 0.85rem;
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 78%, transparent);
  border-radius: 0.85rem;
  background: color-mix(in srgb, var(--fm-card-strong) 72%, #08111d);
}

.contest-group-panel__head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.75rem;
  min-width: 0;
}

.contest-group-panel__head h2 {
  margin: 0;
  color: var(--fm-heading);
  font-size: 1.05rem;
}

.contest-group-panel__head span,
.contest-group-panel__me span {
  color: var(--fm-muted);
  font-size: 0.78rem;
}

.contest-group-panel__me {
  display: grid;
  gap: 0.1rem;
  justify-items: end;
  flex: 0 0 auto;
}

.contest-group-panel__me strong {
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: 1.2rem;
}

.contest-group-ranking--compact {
  gap: 0.5rem;
}

.contest-group-ranking--compact .contest-group-rank-row {
  grid-template-columns: minmax(3.4rem, 0.25fr) minmax(0, 1fr) minmax(4rem, 0.35fr);
  padding: 0.62rem;
  border-radius: 0.75rem;
}

.contest-group-panel__chips,
.contest-admin-group__chips,
.contest-group-rank-row__badges,
.contest-group-rank-row__breakdown {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  min-width: 0;
}

.contest-admin-group {
  display: grid;
  gap: 0.9rem;
  padding: 0.95rem;
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 82%, transparent);
  border-radius: 1rem;
  background: color-mix(in srgb, var(--fm-card-strong) 64%, transparent);
}

.contest-admin-group__head {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 0.85rem;
  min-width: 0;
}

.contest-admin-group__head > div:first-child,
.contest-admin-member-row__person,
.contest-group-rank-row__identity {
  min-width: 0;
}

.contest-admin-group__head strong,
.contest-admin-member-row__person strong,
.contest-group-rank-row__identity strong {
  display: block;
  color: var(--fm-heading);
  overflow-wrap: anywhere;
}

.contest-admin-group__head span,
.contest-admin-member-row__person span,
.contest-admin-member-row__person small,
.contest-group-rank-row__identity span {
  display: block;
  color: var(--fm-muted);
  overflow-wrap: anywhere;
}

.contest-admin-member-add,
.contest-admin-member-row {
  display: grid;
  align-items: end;
  gap: 0.65rem;
  min-width: 0;
}

.contest-admin-member-add {
  grid-template-columns: minmax(8rem, auto) minmax(0, 1fr) auto;
}

.contest-admin-member-row {
  grid-template-columns: minmax(12rem, 1.45fr) minmax(7rem, 0.7fr) minmax(7rem, 0.7fr) auto;
  padding: 0.72rem;
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 68%, transparent);
  border-radius: 0.9rem;
  background: color-mix(in srgb, var(--fm-surface) 72%, transparent);
}

.contest-admin-member-row .form-control,
.contest-admin-member-add .form-control,
.contest-admin-group-create .form-control {
  min-width: 0;
}

.contest-admin-member-row__status,
.contest-admin-member-row__paid {
  margin-bottom: 0;
  align-self: center;
  min-width: 0;
}

.contest-group-rank-row {
  display: grid;
  grid-template-columns: minmax(3.9rem, 0.25fr) minmax(0, 1.55fr) minmax(4.8rem, 0.35fr);
  gap: 0.85rem;
  align-items: center;
  padding: 0.9rem;
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 74%, transparent);
  border-radius: 1rem;
  background: color-mix(in srgb, var(--fm-card-strong) 70%, transparent);
}

.contest-group-rank-row--me {
  border-color: color-mix(in srgb, var(--fm-success) 52%, var(--fm-card-border));
  background:
    radial-gradient(circle at top right, color-mix(in srgb, var(--fm-success) 12%, transparent), transparent 38%),
    color-mix(in srgb, var(--fm-card-strong) 80%, transparent);
}

.contest-group-rank-row__position,
.contest-group-rank-row__score {
  display: grid;
  gap: 0.1rem;
  justify-items: center;
  min-width: 0;
}

.contest-group-rank-row__position strong,
.contest-group-rank-row__score strong {
  color: var(--fm-heading);
  font-family: var(--fm-font-display);
  font-size: 1.5rem;
  line-height: 1;
}

.contest-group-rank-row__position span,
.contest-group-rank-row__score span,
.contest-group-rank-row__breakdown span {
  color: var(--fm-muted);
  font-size: 0.78rem;
}

.contest-group-rank-row__breakdown {
  grid-column: 2 / -1;
}

.contest-group-rank-row__breakdown span {
  padding: 0.22rem 0.5rem;
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 72%, transparent);
  border-radius: 999px;
  background: color-mix(in srgb, var(--fm-surface) 72%, transparent);
}

.contest-challenge-create,
.contest-challenge-form,
.contest-challenge-list,
.contest-challenge-card,
.contest-challenge-response {
  display: grid;
  gap: 0.85rem;
  min-width: 0;
}

.contest-challenge-form {
  grid-template-columns: minmax(13rem, 1.3fr) minmax(12rem, 1fr) minmax(7rem, 0.45fr) minmax(13rem, 1fr) auto;
  align-items: end;
}

.contest-challenge-picks {
  display: flex;
  flex-wrap: wrap;
  gap: 0.45rem;
  min-width: 0;
  margin: 0;
  padding: 0;
  border: 0;
}

.contest-challenge-picks legend {
  width: 100%;
  margin: 0;
  color: var(--fm-muted);
  font-size: 0.76rem;
  font-weight: 900;
  letter-spacing: 0.08em;
  text-transform: uppercase;
}

.contest-challenge-picks label {
  position: relative;
  display: inline-flex;
  align-items: center;
  min-height: 38px;
  margin: 0;
}

.contest-challenge-picks input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.contest-challenge-picks span {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-height: 38px;
  padding: 0.45rem 0.72rem;
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 78%, transparent);
  border-radius: 999px;
  color: var(--fm-heading);
  background: color-mix(in srgb, var(--fm-card-strong) 82%, #08111d);
  font-size: 0.82rem;
  font-weight: 900;
  text-align: center;
}

.contest-challenge-picks input:checked + span,
.contest-challenge-picks input:focus-visible + span {
  border-color: var(--fm-primary);
  color: var(--fm-button-text);
  background: var(--fm-button-bg);
}

.contest-challenge-list {
  grid-template-columns: repeat(auto-fill, minmax(270px, 1fr));
}

.contest-challenge-card {
  padding: 0.85rem;
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 78%, transparent);
  border-radius: 0.85rem;
  background: color-mix(in srgb, var(--fm-card-strong) 74%, #08111d);
}

.contest-challenge-card__head,
.contest-challenge-card__meta,
.contest-challenge-card__picks,
.contest-challenge-response__actions {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 0.65rem;
  min-width: 0;
}

.contest-challenge-card__head {
  align-items: flex-start;
}

.contest-challenge-card__head > div,
.contest-challenge-card__picks > div {
  display: grid;
  gap: 0.15rem;
  min-width: 0;
}

.contest-challenge-card strong {
  color: var(--fm-heading);
  overflow-wrap: anywhere;
}

.contest-challenge-card span,
.contest-challenge-card__note {
  color: var(--fm-muted);
  font-size: 0.78rem;
  overflow-wrap: anywhere;
}

.contest-challenge-card__meta strong {
  flex: 0 0 auto;
}

.contest-challenge-card__picks {
  align-items: stretch;
}

.contest-challenge-card__picks > div {
  flex: 1 1 0;
  padding: 0.58rem 0.65rem;
  border: 1px solid color-mix(in srgb, var(--fm-card-border) 68%, transparent);
  border-radius: 0.75rem;
  background: color-mix(in srgb, var(--fm-surface) 72%, transparent);
}

.contest-challenge-card__note {
  margin: 0;
  color: var(--fm-success);
  font-weight: 800;
}

.contest-challenge-picks--inline {
  gap: 0.35rem;
}

.contest-challenge-reject {
  margin-top: -0.35rem;
}

@media (max-width: 767.98px) {
  .contest-home-hero {
    grid-template-columns: 1fr;
    padding: 0.95rem;
  }

  .contest-nav {
    gap: 0.45rem;
    row-gap: 0.45rem;
    align-items: stretch;
  }

  .contest-nav .fm-chip {
    display: inline-flex;
    justify-content: center;
    padding-inline: 0.7rem;
    font-size: 0.82rem;
    white-space: normal;
    text-align: center;
  }

  .contest-dashboard__hero {
    align-items: stretch;
    flex-direction: column;
  }

  .contest-dashboard__main-action {
    width: 100%;
  }

  .contest-dashboard__stats,
  .contest-dashboard__actions,
  .contest-rules-grid,
  .contest-predictions-fields--compact {
    grid-template-columns: 1fr;
  }

  .contest-home-shell,
  .contest-home-shell--bottom,
  .contest-predictions-layout {
    grid-template-columns: 1fr;
  }

  .contest-home-hero__title {
    font-size: 2rem;
  }

  .contest-home-actions .btn,
  .contest-predictions-form__footer .btn {
    width: 100%;
  }

  .contest-list-toolbar {
    align-items: stretch;
  }

  .contest-searchbar {
    flex-basis: 100%;
  }

  .contest-group-panel__head {
    align-items: flex-start;
    flex-direction: column;
  }

  .contest-group-panel__me {
    justify-items: start;
  }

  .contest-home-status__grid {
    grid-template-columns: 1fr;
  }

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

  .contest-stat {
    min-height: 92px;
    padding: 1rem;
  }

  .contest-panel {
    padding: 0.95rem;
  }

  .contest-panel .fm-section-title .fm-chip,
  .contest-panel .fm-section-title .btn {
    width: fit-content;
  }

  .contest-rule-list > div {
    align-items: flex-start;
    flex-direction: column;
  }

  .contest-rule-list > div span,
  .contest-prize-list strong {
    text-align: left;
  }

  .contest-home-groups__item {
    align-items: flex-start;
    flex-direction: column;
  }

  .contest-home-groups__list--grid {
    grid-template-columns: 1fr;
  }

  .contest-ranking-row {
    grid-template-columns: minmax(3.6rem, auto) minmax(0, 1fr);
  }

  .contest-ranking-row__metrics,
  .contest-ranking-row__prize {
    grid-column: 1 / -1;
  }

  .contest-ranking-row__prize {
    justify-items: start;
    text-align: left;
  }

  .contest-ranking-row--bets {
    gap: 0.55rem;
    padding: 0.6rem 0.72rem;
  }

  .contest-suggestion-cloud__item {
    width: 100%;
    justify-content: flex-start;
    text-align: left;
  }

  .contest-suggestion-cloud {
    grid-template-columns: 1fr;
  }

  .contest-bet-form__scores {
    grid-template-columns: 1fr;
  }

  .contest-match-filter__fields {
    align-items: stretch;
  }

  .contest-match-filter__fields .contest-searchbar,
  .contest-match-filter__count {
    flex-basis: 100%;
  }

  .contest-filter-pill {
    flex: 1 1 calc(50% - 0.4rem);
    padding-inline: 0.5rem;
  }

  .contest-compact-match-grid {
    grid-template-columns: 1fr;
    gap: 0.7rem;
  }

  .contest-compact-match-card {
    padding: 0.68rem;
  }

  .contest-compact-scoreboard {
    gap: 0.42rem;
  }

  .contest-compact-score {
    min-width: 2.8rem;
    font-size: 0.95rem;
  }

  .contest-compact-team strong {
    font-size: 0.82rem;
  }

  .contest-compact-bet-form__footer .btn {
    min-width: 6.2rem;
  }

  .contest-nav .fm-chip {
    flex: 0 1 auto;
    max-width: 100%;
    padding-inline: 0.8rem;
  }

  .contest-match-card__teams {
    align-items: flex-start;
    flex-direction: column;
    gap: 0.45rem;
  }

  .contest-versus {
    margin-left: 2.2rem;
  }

  .contest-bracket-shell {
    padding: 0.9rem;
  }

  .contest-bracket-toolbar {
    align-items: stretch;
    flex-direction: column;
  }

  .contest-bracket-toolbar__actions {
    width: 100%;
  }

  .contest-bracket-toolbar__actions .btn {
    flex: 1 1 10rem;
  }

  .contest-bracket {
    grid-auto-columns: minmax(16.4rem, 17.2rem);
    gap: 0.8rem;
    padding-inline: 0.25rem 1rem;
  }

  .contest-bracket__round {
    padding: 0.82rem;
    border-radius: 1.25rem;
  }

  .contest-bracket__round-head {
    align-items: flex-start;
  }

  .contest-bracket__round-head h2 {
    font-size: 1.02rem;
  }

  .contest-bracket__team {
    padding: 0.66rem 0.7rem;
  }

  .contest-bracket__meta {
    font-size: 0.74rem;
  }

  .contest-admin-group__head {
    flex-direction: column;
  }

  .contest-admin-member-add,
  .contest-admin-member-row {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .contest-challenge-form {
    grid-template-columns: 1fr;
    align-items: stretch;
  }

  .contest-challenge-form .btn,
  .contest-challenge-response__actions .btn,
  .contest-challenge-reject .btn {
    width: 100%;
  }

  .contest-challenge-list {
    grid-template-columns: 1fr;
  }

  .contest-challenge-card__head,
  .contest-challenge-card__meta {
    align-items: flex-start;
    flex-direction: column;
  }

  .contest-challenge-card__picks {
    flex-direction: column;
  }

.contest-admin-member-add .btn,
.contest-admin-member-row .btn {
  width: 100%;
}

.contest-group-rank-row {
  grid-template-columns: minmax(3.5rem, auto) minmax(0, 1fr);
}

  .contest-group-rank-row__score {
    grid-column: 1 / -1;
    display: flex;
    justify-content: flex-start;
    gap: 0.45rem;
  }

  .contest-group-rank-row__breakdown {
    grid-column: 1 / -1;
  }
}

.contest-admin-page {
  display: grid;
  gap: 0.9rem;
}

.contest-admin-hero {
  margin-bottom: 0;
}

.contest-admin-summary {
  gap: 0.65rem;
}

.contest-admin-summary .album-stat-card {
  min-width: 96px;
  padding: 0.8rem 0.75rem;
}

.contest-admin-summary .album-stat-card strong {
  font-size: 1.45rem;
}

.contest-admin-actions {
  display: flex;
  flex-wrap: wrap;
  gap: 0.6rem;
}

.contest-admin-actions--inline form {
  margin: 0;
}

.contest-admin-section {
  padding: 1rem;
}

.contest-admin-grid {
  --bs-gutter-y: 0.75rem;
}

.contest-admin-compact-form .form-label {
  margin-bottom: 0.22rem;
  font-size: 0.78rem;
}

.contest-admin-compact-form .form-control,
.contest-admin-compact-form .form-select {
  min-height: 2.5rem;
}

.contest-admin-sync-grid {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
}

.contest-admin-page .table-responsive {
  border-radius: 0.9rem;
}

.admin-table--matches th,
.admin-table--matches td {
  padding-top: 0.5rem;
  padding-bottom: 0.5rem;
  vertical-align: middle;
}

.contest-admin-match {
  display: grid;
  gap: 0.32rem;
  min-width: 0;
}

.contest-admin-match__main {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.45rem;
  min-width: 0;
}

.contest-admin-match__team {
  min-width: 0;
  gap: 0.42rem;
}

.contest-admin-match__team .country-flag,
.contest-admin-match__host .country-flag {
  inline-size: 1.1rem;
  block-size: 1.1rem;
  flex: 0 0 auto;
}

.contest-admin-match__team > span:last-child,
.contest-admin-match__host > span:last-child {
  overflow-wrap: anywhere;
}

.contest-admin-match__versus {
  color: var(--fm-muted);
  font-size: 0.78rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
}

.contest-admin-match__meta {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 0.35rem 0.5rem;
  color: var(--fm-muted);
  font-size: 0.77rem;
  line-height: 1.25;
}

.contest-admin-match__meta > span {
  display: inline-flex;
  align-items: center;
  gap: 0.32rem;
}

.contest-admin-match__host {
  gap: 0.35rem;
}

@media (max-width: 767.98px) {
  .contest-admin-page {
    gap: 0.75rem;
  }

  .contest-admin-section {
    padding: 0.85rem;
  }

  .contest-admin-actions .btn {
    width: 100%;
  }

  .contest-admin-summary {
    width: 100%;
  }

  .admin-table--matches th,
  .admin-table--matches td {
    padding-top: 0.42rem;
    padding-bottom: 0.42rem;
  }

  .contest-admin-match__main {
    gap: 0.35rem;
  }

  .contest-admin-match__meta {
    gap: 0.28rem 0.4rem;
    font-size: 0.74rem;
  }
}
