/* MYTHIX V4 cinematic motion and responsive system */
html {
  scroll-behavior: smooth;
  scroll-padding-top: 92px;
}

body {
  min-width: 0;
  background:
    radial-gradient(circle at 78% 4%, rgba(102, 223, 242, .07), transparent 28rem),
    radial-gradient(circle at 12% 32%, rgba(183, 255, 49, .045), transparent 34rem),
    #06080c;
}

main {
  position: relative;
  isolation: isolate;
  min-width: 0;
}

main::before {
  content: "";
  position: absolute;
  inset: 0;
  z-index: -1;
  pointer-events: none;
  background-image:
    linear-gradient(rgba(255, 255, 255, .018) 1px, transparent 1px),
    linear-gradient(90deg, rgba(255, 255, 255, .018) 1px, transparent 1px);
  background-size: 72px 72px;
  mask-image: linear-gradient(to bottom, transparent, black 12%, black 80%, transparent);
}

img,
video,
svg {
  max-width: 100%;
}

.site-header {
  will-change: transform, background-color;
  transition: background-color .28s ease, border-color .28s ease, box-shadow .28s ease;
  animation: myx-header-in .62s cubic-bezier(.2, .78, .2, 1) both;
}

.site-header.is-scrolled {
  background: rgba(5, 7, 10, .95);
  border-color: rgba(183, 255, 49, .14);
  box-shadow: 0 16px 45px rgba(0, 0, 0, .34);
}

.main-nav a::before,
.nav-join::before {
  content: "";
  position: absolute;
  left: 10px;
  right: 10px;
  bottom: -13px;
  height: 2px;
  border-radius: 999px;
  background: linear-gradient(90deg, transparent, var(--accent), transparent);
  transform: scaleX(0);
  opacity: 0;
  transition: transform .24s ease, opacity .24s ease;
}

.main-nav a:hover::before,
.nav-join:hover::before {
  transform: scaleX(1);
  opacity: .8;
}

.button {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  transition: transform .2s ease, box-shadow .2s ease, border-color .2s ease, background-color .2s ease;
}

.button::after {
  content: "";
  position: absolute;
  inset: -2px auto -2px -45%;
  z-index: -1;
  width: 38%;
  background: linear-gradient(105deg, transparent, rgba(255, 255, 255, .32), transparent);
  transform: skewX(-18deg);
  transition: left .48s cubic-bezier(.2, .72, .2, 1);
}

.button:hover::after {
  left: 112%;
}

.button:hover {
  transform: translateY(-2px);
  box-shadow: 0 15px 34px rgba(0, 0, 0, .3), 0 0 24px rgba(183, 255, 49, .1);
}

.hero.home-visual {
  background-size: cover;
  animation: myx-hero-breathe 14s ease-in-out infinite alternate;
}

.hero.home-visual .hero-grid {
  animation: myx-grid-drift 12s ease-in-out infinite alternate;
  will-change: transform, opacity;
}

.hero.home-visual .hero-glow {
  animation: myx-glow-drift 9s ease-in-out infinite alternate;
  will-change: transform, opacity;
}

.hero.home-visual h1 span {
  position: relative;
  display: inline-block;
}

.hero.home-visual h1 span::after {
  content: "";
  position: absolute;
  left: 0;
  right: 0;
  bottom: -8px;
  height: 3px;
  border-radius: 999px;
  background: linear-gradient(90deg, var(--accent), rgba(102, 223, 242, .8), transparent);
  transform-origin: left;
  animation: myx-line-in 1s .55s cubic-bezier(.2, .8, .2, 1) both;
}

.page-hero {
  position: relative;
  overflow: hidden;
  isolation: isolate;
}

.page-hero::after {
  content: "";
  position: absolute;
  right: -14vw;
  top: -26vw;
  z-index: -1;
  width: 48vw;
  aspect-ratio: 1;
  border: 1px solid rgba(102, 223, 242, .08);
  border-radius: 50%;
  box-shadow: 0 0 0 8vw rgba(102, 223, 242, .018), 0 0 0 16vw rgba(183, 255, 49, .012);
  animation: myx-orbit 28s linear infinite;
}

.motion-card {
  position: relative;
  isolation: isolate;
  overflow: hidden;
  transition: transform .28s cubic-bezier(.2, .75, .25, 1), border-color .28s ease, box-shadow .28s ease;
}

.motion-card::after {
  content: "";
  position: absolute;
  inset: 0;
  z-index: 4;
  pointer-events: none;
  background: linear-gradient(112deg, transparent 22%, rgba(255, 255, 255, .075) 48%, transparent 72%);
  transform: translateX(-135%);
  transition: transform .7s cubic-bezier(.2, .75, .25, 1);
}

.motion-card img {
  transition: transform .7s cubic-bezier(.2, .75, .25, 1), filter .35s ease;
}

.partner-logo-link,
.header-partner-logo {
  transition: border-color .25s ease, filter .25s ease, transform .25s ease;
}

.partner-logo-link:hover {
  border-color: rgba(183, 255, 49, .35);
  filter: brightness(1.08);
  transform: translateY(-3px);
}

.store-card .store-image img,
.tournament-card .card-art img,
.member-card .member-photo img,
.creator-card .creator-media img {
  will-change: transform;
}

.leaderboard {
  overflow-x: auto;
  overscroll-behavior-inline: contain;
}

.table-card {
  overscroll-behavior-inline: contain;
}

.filter-tabs {
  scrollbar-width: thin;
}

.store-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 360px));
  gap: 20px;
  justify-content: start;
}

.rich-text,
.form-card,
.info-card {
  min-width: 0;
}

.pro-player-name {
  hyphens: none;
  word-break: normal;
  overflow-wrap: anywhere;
}

.nav-mobile-store {
  display: none !important;
}

.motion-ready [data-reveal] {
  opacity: 0;
  transform: translate3d(0, 28px, 0);
  filter: blur(4px);
  transition:
    opacity .72s cubic-bezier(.2, .72, .2, 1),
    transform .72s cubic-bezier(.2, .72, .2, 1),
    filter .72s ease;
  transition-delay: var(--reveal-delay, 0ms);
}

.motion-ready [data-reveal].is-visible {
  opacity: 1;
  transform: none;
  filter: none;
}

@media (hover: hover) and (pointer: fine) {
  .motion-card:hover {
    transform: translateY(-7px);
    border-color: rgba(183, 255, 49, .3);
    box-shadow: 0 28px 75px rgba(0, 0, 0, .34), 0 0 0 1px rgba(183, 255, 49, .04);
  }

  .motion-card:hover::after {
    transform: translateX(135%);
  }

  .motion-card:hover img {
    transform: scale(1.035);
    filter: saturate(1.06) contrast(1.02);
  }
}

@media (min-width: 1800px) {
  .container,
  .hero.home-visual .hero-inner {
    width: min(1480px, calc(100% - 128px));
  }

  .site-header {
    padding-inline: clamp(42px, 4vw, 92px);
  }

  .section {
    padding: 108px 0;
  }

  .section-tight {
    padding: 78px 0;
  }

  .page-hero {
    padding: 132px 0 86px;
  }

  .hero.home-visual {
    min-height: min(920px, calc(100svh - 76px));
  }

  .hero.home-visual h1 {
    max-width: 920px;
    font-size: clamp(6rem, 6vw, 9rem);
  }

  .hero.home-visual .hero-inner > p {
    max-width: 760px;
    font-size: 1.26rem;
  }

  .hero-metrics {
    grid-template-columns: repeat(3, minmax(0, 205px));
    gap: 16px;
  }

  .card-grid,
  .news-grid,
  .media-grid,
  .feature-grid {
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 26px;
  }

  .site-footer {
    padding-inline: max(64px, calc((100% - 1480px) / 2));
  }

  .partner-showcase-inner {
    grid-template-columns: minmax(0, 1fr) 360px;
  }
}

@media (max-width: 1050px) {
  .nav-mobile-store {
    display: block !important;
    color: var(--accent) !important;
  }

  .store-access-bar {
    top: auto;
    right: 12px;
    bottom: max(14px, env(safe-area-inset-bottom));
  }

  .store-access-bar a {
    padding: 9px 12px;
    font-size: .76rem;
    box-shadow: 0 14px 38px rgba(0, 0, 0, .45);
  }

  .main-nav {
    left: 0 !important;
    right: 0 !important;
    width: auto !important;
    justify-self: stretch !important;
    align-items: stretch;
    gap: 0 !important;
    box-sizing: border-box;
    max-height: calc(100dvh - 76px);
    overflow-y: auto;
    box-shadow: 0 22px 48px rgba(0, 0, 0, .4);
  }

  .main-nav a {
    width: 100%;
    padding: 12px 4px;
    border-bottom: 1px solid rgba(255, 255, 255, .06);
  }

  .main-nav a::before {
    display: none;
  }

  .page-hero::after {
    right: -28vw;
    top: -20vw;
    width: 76vw;
  }

  .dashboard-main,
  .admin-main {
    min-width: 0;
  }

  .table-card {
    max-width: 100%;
  }
}

@media (max-width: 760px) {
  html {
    scroll-padding-top: 76px;
  }

  .noise {
    opacity: .018;
  }

  .site-header {
    grid-template-columns: minmax(0, auto) 1fr auto;
    gap: 7px;
    padding-inline: 12px;
  }

  .brand-cluster {
    gap: 7px;
  }

  .brand {
    gap: 7px;
    font-size: .82rem;
  }

  .header-partner-logo {
    width: 30px;
    height: 30px;
  }

  .header-partner-logo img {
    right: -8px;
    width: 150px;
  }

  .nav-toggle {
    justify-self: end;
    padding: 7px 8px;
    font-size: .72rem;
  }

  .header-actions .button {
    min-height: 36px;
    padding-inline: 9px;
  }

  .main-nav {
    top: 68px;
    padding: 12px 14px;
  }

  .main-nav a {
    font-size: .95rem !important;
  }

  .hero.home-visual {
    min-height: min(720px, calc(100svh - 68px));
    background-position: 70% center;
    animation: none;
  }

  .hero.home-visual::before {
    background: linear-gradient(180deg, rgba(4, 7, 11, .38), rgba(4, 7, 11, .72) 42%, rgba(4, 7, 11, .985) 84%);
  }

  .hero.home-visual .hero-inner {
    padding-top: 120px;
    padding-bottom: 38px;
  }

  .hero.home-visual h1 {
    font-size: clamp(3rem, 15vw, 4.45rem);
    line-height: .92;
  }

  .hero.home-visual .hero-inner > p {
    font-size: .96rem;
    line-height: 1.62;
  }

  .hero-actions {
    gap: 10px;
  }

  .hero-metrics {
    margin-top: 30px;
  }

  .section {
    padding: 52px 0;
  }

  .section-tight {
    padding: 44px 0;
  }

  .page-hero {
    padding: 82px 0 46px;
  }

  .page-hero h1 {
    font-size: clamp(2.45rem, 12vw, 3.8rem);
    overflow-wrap: anywhere;
  }

  .page-hero p {
    font-size: .98rem;
  }

  .section-heading h2 {
    font-size: clamp(1.8rem, 9vw, 2.55rem);
  }

  .partner-showcase {
    padding: 18px 0;
  }

  .partner-logo-link {
    height: 74px;
  }

  .featured-event {
    gap: 20px;
  }

  .featured-event h3 {
    font-size: 1.35rem;
  }

  .countdown {
    font-size: 1.65rem;
  }

  .tournament-card .card-body,
  .store-card-body {
    padding: 17px;
  }

  .filter-tabs {
    flex-wrap: nowrap;
    overflow-x: auto;
    padding-bottom: 8px;
  }

  .filter-tabs a {
    flex: 0 0 auto;
  }

  .leaderboard-head,
  .leaderboard-row {
    min-width: 520px;
  }

  .leaderboard.compact .leaderboard-head,
  .leaderboard.compact .leaderboard-row {
    min-width: 0;
    grid-template-columns: 44px minmax(145px, 1fr) 68px;
  }

  .pro-player-profile-grid {
    gap: 26px;
  }

  .pro-player-name {
    font-size: clamp(2.55rem, 13vw, 4rem);
    line-height: .98;
  }

  .profile-hero-image,
  .pro-player-profile-image {
    max-height: none;
  }

  .store-grid {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .store-card {
    border-radius: 16px;
  }

  .form-card {
    padding: 20px;
  }

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

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

  .site-footer {
    padding: 42px 18px 26px;
  }

  .motion-ready [data-reveal] {
    transform: translate3d(0, 16px, 0);
    filter: none;
  }

  .hero.home-visual .hero-grid,
  .hero.home-visual .hero-glow {
    animation: none;
  }
}

@media (max-width: 430px) {
  .brand span {
    display: none;
  }

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

  .brand-logo {
    width: 32px;
    height: 32px;
    flex-basis: 32px;
  }

  .header-partner-logo {
    width: 30px;
  }

  .header-actions .button {
    font-size: .68rem;
  }

  .hero-metrics {
    grid-template-columns: 1fr;
  }

  .hero-metrics div {
    padding: 10px 12px;
  }

  .hero-metrics strong {
    font-size: 1.05rem;
  }

  .hero.home-visual {
    min-height: 780px;
  }

  .official-partner-mark {
    min-height: 130px;
  }

  .empty-state {
    padding: 42px 18px;
  }

  .dashboard-main,
  .admin-main {
    padding-inline: 14px !important;
  }
}

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

  .site-header,
  .hero.home-visual,
  .hero.home-visual .hero-grid,
  .hero.home-visual .hero-glow,
  .hero.home-visual h1 span::after,
  .page-hero::after {
    animation: none !important;
  }

  .motion-ready [data-reveal] {
    opacity: 1 !important;
    transform: none !important;
    filter: none !important;
    transition: none !important;
  }

  .motion-card,
  .motion-card img,
  .button,
  .button::after {
    transition: none !important;
  }
}

@keyframes myx-header-in {
  from { opacity: 0; transform: translateY(-18px); }
  to { opacity: 1; transform: none; }
}

@keyframes myx-line-in {
  from { transform: scaleX(0); }
  to { transform: scaleX(1); }
}

@keyframes myx-hero-breathe {
  from { background-size: 100% auto; }
  to { background-size: 104% auto; }
}

@keyframes myx-grid-drift {
  from { transform: perspective(800px) rotateX(62deg) scale(1.7) translateY(0); opacity: .1; }
  to { transform: perspective(800px) rotateX(62deg) scale(1.72) translateY(-18px); opacity: .2; }
}

@keyframes myx-glow-drift {
  from { transform: translate3d(-1%, 1%, 0) scale(1); opacity: .3; }
  to { transform: translate3d(2%, -2%, 0) scale(1.08); opacity: .48; }
}

@keyframes myx-orbit {
  to { transform: rotate(360deg); }
}
