/* Stable site-wide chrome. Kept separate from page bundles so SPA navigation
   cannot inherit a previous page's footer or animation overrides. */
html { min-height: 100%; background: #090a0b; }
body { min-height: 100vh; display: flex; flex-direction: column; }
body > main { flex: 1 0 auto; }

body > .footer {
  flex: 0 0 auto;
  width: 100%;
  margin: clamp(34px, 5vw, 68px) 0 0 !important;
  padding: clamp(42px, 5vw, 68px) clamp(14px, 2vw, 34px) 18px !important;
  overflow: hidden;
  background: transparent !important;
}
body > .footer::before {
  top: 0 !important;
  left: 50% !important;
  width: min(1320px, 88vw) !important;
  height: 190px !important;
  border-radius: 50% !important;
  background: radial-gradient(ellipse, rgba(255, 166, 56, .095), transparent 70%) !important;
  filter: blur(22px) !important;
  opacity: 1 !important;
  transform: translate(-50%, -55%) !important;
}
body > .footer::after { top: 44px !important; bottom: auto !important; }
body > .footer .footer-night {
  inset: 0 !important;
  width: auto !important;
  height: auto !important;
  background: radial-gradient(circle at 14% 40%, rgba(255, 174, 65, .045), transparent 23rem) !important;
  opacity: 1 !important;
  mask-image: none !important;
  -webkit-mask-image: none !important;
}
body > .footer .footer-shell {
  width: min(1320px, 100%) !important;
  margin-bottom: 0 !important;
  border-color: rgba(255, 173, 66, .11) !important;
  background: radial-gradient(circle at 8% 0, rgba(255, 173, 66, .07), transparent 25rem), linear-gradient(145deg, rgba(25, 21, 18, .97), rgba(10, 11, 12, .99)) !important;
  box-shadow: 0 24px 64px rgba(0, 0, 0, .24), inset 0 1px rgba(255, 255, 255, .025) !important;
}
body > .footer .footer-top { min-height: 104px !important; }
body > .footer .footer-links { grid-template-columns: repeat(4, minmax(0, 1fr)) !important; }
body > .footer .footer-bottom { min-height: 78px !important; }
.footer-legal-copy p { margin: 0; }
.footer-legal-copy p + p { display: flex; flex-wrap: wrap; gap: 7px 14px; margin-top: 7px; }
.footer-legal-copy strong { color: rgba(255, 248, 239, .86); }
.footer-legal-copy span { color: rgba(255, 248, 239, .52); }
.footer-legal-links { display: flex; flex-wrap: wrap; justify-content: flex-end; gap: 9px 18px; }

/* Four equal navigation groups replace the legacy third-column mobile layout. */
body > .footer .footer-top { flex-wrap: wrap; gap: 24px; }
body > .footer .footer-top::after,
body > .footer .footer-desc::after { content: none; display: none; }
body > .footer .footer-desc small { color: #b7aaa0; font: 600 13px/1.5 Manrope, sans-serif; letter-spacing: 0; }
body > .footer .footer-logo { animation: none; }
body > .footer .footer-socials { margin-left: auto; }
body > .footer .footer-socials a { width: 42px; height: 42px; border-radius: 12px; }
.footer-copy-ip { display: flex; align-items: center; gap: 12px; padding: 12px 16px; border: 1px solid #725022; border-radius: 12px; background: #342619; color: #ffc166; cursor: pointer; text-align: left; }
.footer-copy-ip span { display: grid; gap: 4px; }
.footer-copy-ip small { color: #c5ad8d; font: 600 11px/1.4 Manrope, sans-serif; }
.footer-copy-ip strong { font: 800 13px/1.4 Manrope, sans-serif; }
.footer-copy-ip .pivo-icon { width: 20px; height: 20px; flex: 0 0 20px; }
.footer-copy-ip:hover { background: #49331c; border-color: #ffb64b; }
body > .footer .footer-col { display: flex; grid-column: auto; min-width: 0; padding: 30px 16px !important; border: 0 !important; }
body > .footer .footer-col h4 { min-height: 44px; gap: 10px; color: #efdcc3 !important; font-size: 10px !important; letter-spacing: .08em !important; }
body > .footer .footer-col h4::before { content: none; }
body > .footer .footer-col h4 img { width: 36px; height: 36px; object-fit: contain; image-rendering: pixelated; filter: drop-shadow(0 4px 3px #0006); }
body > .footer .footer-col a { min-height: 40px !important; gap: 10px; width: 100%; padding: 5px 0 !important; font-size: 13px !important; line-height: 1.4; }
body > .footer .footer-col a .pivo-icon { width: 17px; height: 17px; flex: 0 0 17px; color: #bd925a; }
body > .footer .footer-col a::after { content: none; }
body > .footer .footer-col a:hover { color: #ffc166 !important; transform: translateX(3px); }
body > .footer :is(a, button):focus-visible { outline: 2px solid #ffc166; outline-offset: 4px; border-radius: 5px; }
body > .footer .footer-bottom { display: flex; flex-wrap: wrap; gap: 18px 24px; }
.footer-disclaimer { flex-basis: 100%; margin: 0; color: #958b81; font: 500 11px/1.5 Manrope, sans-serif; }
@media (max-width: 980px) {
  body > .footer .footer-links { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; padding: 0 16px !important; }
  body > .footer .footer-socials { margin-left: 0; width: auto; }
}
@media (max-width: 480px) {
  body > .footer .footer-top { gap: 18px; padding: 24px 18px !important; }
  body > .footer .footer-links { padding: 0 10px !important; }
  body > .footer .footer-col { padding: 20px 8px !important; }
  body > .footer .footer-col h4 { gap: 7px; font-size: 9px !important; letter-spacing: .02em !important; }
  body > .footer .footer-col h4 img { width: 28px; height: 28px; }
  body > .footer .footer-col a { min-height: 44px !important; font-size: 12px !important; gap: 7px; }
  .footer-copy-ip { width: 100%; justify-content: center; }
}

.site-important-event {
  position: fixed;
  z-index: 980;
  top: 88px;
  right: clamp(12px, 2vw, 28px);
  display: grid;
  grid-template-columns: 40px minmax(0, 1fr);
  width: min(330px, calc(100vw - 24px));
  gap: 11px;
  align-items: center;
  padding: 11px 13px;
  border: 1px solid rgba(255, 105, 76, .35);
  border-radius: 16px;
  background: linear-gradient(135deg, rgba(39, 23, 19, .97), rgba(17, 17, 18, .98));
  box-shadow: 0 18px 54px rgba(0, 0, 0, .38), inset 0 1px rgba(255,255,255,.04);
  animation: shellImportantIn .5s cubic-bezier(.16,1,.3,1) both;
}
.site-important-event-mark { display: grid; width: 40px; height: 40px; place-items: center; border-radius: 13px; color: #1a0d08; background: linear-gradient(135deg, #ffb150, #ff6c4d); box-shadow: 0 8px 22px rgba(255, 105, 76, .2); font: 900 19px/1 Unbounded, sans-serif; }
.site-important-event a { display: grid; min-width: 0; color: inherit; text-decoration: none; }
.site-important-event small { color: #ff8c70; font-size: 8px; font-weight: 900; letter-spacing: .12em; text-transform: uppercase; }
.site-important-event strong { margin-top: 3px; overflow: hidden; color: #fff7ef; font-size: 11px; text-overflow: ellipsis; white-space: nowrap; }
.site-important-event time { margin-top: 3px; color: rgba(255, 247, 239, .46); font-size: 9px; }
@keyframes shellImportantIn { from { opacity: 0; transform: translateY(-10px) scale(.97); } to { opacity: 1; transform: none; } }

.reveal {
  opacity: 0;
  transform: translate3d(0, 18px, 0);
  transition: opacity .58s cubic-bezier(.2,.8,.2,1), transform .58s cubic-bezier(.2,.8,.2,1);
  will-change: opacity, transform;
}
.reveal.is-visible { opacity: 1; transform: none; }
body.pivo-react-spa main.is-page-entering { animation: shellPageEnter .32s cubic-bezier(.16,1,.3,1) both; }
@keyframes shellPageEnter { from { opacity: .5; transform: translateY(7px); } to { opacity: 1; transform: none; } }

/* Keep the old route covered until the next route is visually ready. */
body.is-spa-navigating { overflow: hidden; }
body.is-spa-navigating > main,
body.is-spa-navigating > footer {
  opacity: .62;
  filter: blur(5px);
  transform: scale(.995);
  transition: opacity .3s ease, filter .38s ease, transform .46s cubic-bezier(.16,1,.3,1);
}
body.pivo-react-spa main.is-page-preparing {
  opacity: 0 !important;
  visibility: hidden;
  transform: translateY(13px) scale(.995) !important;
}
body.pivo-react-spa main.is-page-entering:not(.is-page-preparing) {
  visibility: visible;
  animation: shellSpaReady .56s cubic-bezier(.16,1,.3,1) both;
}
@keyframes shellSpaReady {
  from { opacity: 0; transform: translateY(12px) scale(.995); }
  to { opacity: 1; transform: none; }
}

.react-spa-transition {
  position: fixed;
  z-index: 10018;
  inset: 0;
  display: grid;
  place-items: center;
  opacity: 0;
  visibility: hidden;
  pointer-events: none;
  transition: opacity .32s ease, visibility 0s linear .32s;
}
.react-spa-transition.is-loading {
  opacity: 1;
  visibility: visible;
  pointer-events: auto;
  transition: opacity .22s ease, visibility 0s;
}
.react-spa-transition-backdrop {
  position: absolute;
  inset: 0;
  background: radial-gradient(circle at 50% 45%, rgba(255, 164, 56, .09), transparent 24rem), rgba(8, 9, 10, .82);
  -webkit-backdrop-filter: blur(12px) saturate(.8);
  backdrop-filter: blur(12px) saturate(.8);
}
.react-spa-loader-card {
  position: relative;
  display: flex;
  width: min(360px, calc(100vw - 36px));
  flex-direction: column;
  align-items: center;
  padding: 31px 28px 27px;
  border: 1px solid rgba(255, 178, 77, .14);
  border-radius: 24px;
  background: linear-gradient(145deg, rgba(28, 24, 20, .97), rgba(12, 13, 14, .98));
  box-shadow: 0 28px 80px rgba(0, 0, 0, .46), inset 0 1px rgba(255, 255, 255, .045);
  text-align: center;
  transform: translateY(7px) scale(.98);
  transition: transform .42s cubic-bezier(.16,1,.3,1);
}
.react-spa-transition.is-loading .react-spa-loader-card { transform: none; }
.react-spa-loader-mark {
  position: relative;
  display: grid;
  width: 78px;
  height: 106px;
  margin-bottom: 15px;
  place-items: center;
  border-radius: 24px;
  background: radial-gradient(circle at 50% 68%, rgba(255, 178, 77, .17), transparent 68%);
  filter: drop-shadow(0 14px 17px rgba(0, 0, 0, .35));
}
.react-spa-loader-mark img { width: 72px; height: 99px; object-fit: contain; image-rendering: pixelated; }
.react-spa-loader-mark::after {
  content: "";
  position: absolute;
  inset: -8px;
  border: 1px solid rgba(255, 184, 91, .34);
  border-top-color: transparent;
  border-radius: 24px;
  animation: shellSpaOrbit 1.4s linear infinite;
}
.react-spa-loader-card strong { color: #fff8ef; font-size: 17px; line-height: 1.25; }
.react-spa-loader-card > span { margin-top: 7px; color: rgba(255, 248, 239, .52); font-size: 13px; }
.react-spa-loader-dots { display: flex; gap: 6px; margin-top: 20px; }
.react-spa-loader-dots i {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: #ffad45;
  animation: shellSpaDot 1s ease-in-out infinite;
}
.react-spa-loader-dots i:nth-child(2) { animation-delay: .14s; }
.react-spa-loader-dots i:nth-child(3) { animation-delay: .28s; }
.react-spa-transition .react-spa-load-bar {
  position: absolute;
  z-index: 2;
  top: 0;
  left: 0;
  width: 0;
  height: 2px;
  opacity: 0;
  border: 0;
  border-radius: 0 2px 2px 0;
  background: linear-gradient(90deg, #f59a2d, #ffd28c);
  box-shadow: 0 0 18px rgba(255, 174, 69, .5);
}
.react-spa-transition.is-loading .react-spa-load-bar {
  width: 78%;
  opacity: 1;
  animation: shellSpaProgress 1.35s ease-in-out infinite alternate;
}
@keyframes shellSpaOrbit { to { transform: rotate(360deg); } }
@keyframes shellSpaDot { 0%, 70%, 100% { opacity: .28; transform: translateY(0); } 35% { opacity: 1; transform: translateY(-4px); } }
@keyframes shellSpaProgress { from { width: 18%; } to { width: 86%; } }

[data-chibi-host] { position: relative; }
.chibi-companion {
  position: absolute;
  z-index: 3;
  width: 30px;
  height: 37px;
  padding: 0;
  border: 0;
  background: transparent;
  opacity: .86;
  filter: drop-shadow(0 11px 13px rgba(0, 0, 0, .34));
  cursor: pointer;
  pointer-events: auto;
  animation: chibiCompanionFloat 4.6s ease-in-out infinite;
  transition: opacity .25s ease, filter .25s ease, transform .25s cubic-bezier(.16,1,.3,1);
}
.chibi-companion img { width: 100%; height: 100%; object-fit: contain; image-rendering: pixelated; user-select: none; }
.chibi-companion:hover { z-index: 2; opacity: 1; filter: drop-shadow(0 8px 10px rgba(255, 174, 69, .2)); transform: translateY(-3px) scale(1.12); }
.chibi-companion.is-leaving { opacity: 0; transform: translateY(-20px) scale(.72) rotate(8deg); pointer-events: none; }
.chibi-in-footer { right: -7px; bottom: -8px; animation-delay: -.8s; }
.chibi-in-shop { top: 8px; right: 11px; animation-delay: -2.1s; }
.chibi-in-players { right: 10px; bottom: 6px; animation-delay: -1.5s; }
.chibi-in-calendar { right: 18px; bottom: 9px; animation-delay: -2.8s; }
@keyframes chibiCompanionFloat { 50% { transform: translateY(-4px) rotate(1.5deg); } }
.cursor-sulleksik{position:fixed;z-index:10016;left:0;top:0;width:27px;height:34px;object-fit:contain;image-rendering:pixelated;pointer-events:none;filter:drop-shadow(0 7px 7px rgba(0,0,0,.34));transform-origin:center;will-change:transform}.cursor-sulleksik.is-running{animation:cursorSulleksikHop .22s ease-in-out infinite alternate}@keyframes cursorSulleksikHop{to{margin-top:-4px}}

@media (prefers-reduced-motion: reduce) {
  .reveal, .reveal.is-visible { opacity: 1 !important; transform: none !important; transition: none !important; }
  body.pivo-react-spa main.is-page-entering { animation: none !important; }
  body.is-spa-navigating > main, body.is-spa-navigating > footer { filter: none; transform: none; }
  .react-spa-loader-mark::after, .react-spa-loader-dots i, .react-spa-transition.is-loading .react-spa-load-bar { animation: none !important; }
  .react-spa-loader-mark img { content: url("/img/chibi/sulleexx-1.png"); }
  .chibi-companion { animation: none !important; }
  .cursor-sulleksik { animation: none !important; }
  .site-important-event { animation: none !important; }
}
@media (min-width: 761px) and (max-width: 1390px) {
  .site-header { grid-template-columns: minmax(155px, .8fr) minmax(0, auto) minmax(118px, .55fr) !important; padding-inline: 13px !important; }
  .site-header .site-nav { gap: 2px !important; padding: 4px !important; }
  .site-header .site-nav a { padding: 9px 8px !important; font-size: 11px !important; white-space: nowrap; }
  .site-header .brand strong { font-size: 16px !important; }
  .site-header .brand small { font-size: 9px !important; }
  .site-header .login-button, .site-header .account-trigger { padding-inline: 13px !important; font-size: 11px !important; }
}
@media (max-width: 760px) {
  body > .footer { margin-top: 34px !important; padding: 40px 10px 10px !important; }
  .footer-legal-links { justify-content: flex-start; }
  body > .footer .footer-links { grid-template-columns: repeat(2, minmax(0, 1fr)) !important; }
  .react-spa-loader-card { padding: 27px 22px 24px; border-radius: 21px; }
  .chibi-companion { width: 25px; height: 31px; opacity: .8; }
  .chibi-in-footer { right: -4px; bottom: -6px; }
  .chibi-in-shop { top: 5px; right: 8px; }
  .chibi-in-players { right: 6px; bottom: 4px; }
  .chibi-in-calendar { right: 8px; bottom: 5px; }
  .site-important-event { top: 76px; right: 10px; }
}

@media (max-width: 980px) {
  body .site-header:not(.is-hidden) { left: 8px !important; right: 8px !important; transform: none !important; }
}
