:root{color-scheme:dark;--shell-bg:#101f26;--shell-panel:#192d33;--shell-pine:#27483f;--shell-ivory:#fff2d5;--shell-muted:#c2c9c1;--shell-brass:#d8b676;--shell-red:#842d32;--shell-line:#53615c;--shell-serif:Georgia,"Times New Roman",serif;--shell-sans:"Segoe UI",system-ui,sans-serif}*,*::before,*::after{box-sizing:border-box}html{min-width:300px;scroll-padding-top:12px}body{margin:0;min-height:100vh;background:radial-gradient(ellipse at 45% 0,#243b40 0,transparent 60rem),var(--shell-bg);color:var(--shell-ivory);font:16px/1.5 var(--shell-sans)}a{color:#f4dbad;text-underline-offset:.2em}button,input,select,textarea{font:inherit}button,a,input,textarea,select{-webkit-tap-highlight-color:transparent}button{cursor:pointer}button:disabled{cursor:default}img,canvas{max-width:100%}:focus-visible{outline:3px solid #f5cf7b;outline-offset:3px}[hidden]{display:none!important}.shell-skip{position:absolute;left:-9999px}.shell-skip:focus{left:8px;top:6px;background:black;z-index:50}.shell-loading{margin:24px}.shell-view{width:100%}#main-content{min-height:69vh;outline:none}.shell-toast{position:fixed;z-index:100;bottom:22px;left:50%;transform:translateX(-50%);background:#f9eccd;color:#272e27;padding:10px 18px;border-radius:12px;font-size:15px;box-shadow:0 6px 26px #0007;width:max-content;max-width:min(560px,calc(100% - 30px));pointer-events:none}.shell-dialog{width:min(570px,calc(100% - 26px));max-height:84dvh;overflow:auto;border-radius:16px;border:1px solid #b99b69;background:#17302e;color:#fff3d9;padding:22px}.shell-dialog::backdrop{background:#061319bd}.shell-dialog-top{display:flex;justify-content:space-between;align-items:center;gap:10px}.shell-dialog h2{font:normal 32px var(--shell-serif);margin:0 0 8px}.shell-dialog-top button{border:1px solid #78765d;color:inherit;background:none;border-radius:50%;width:36px;height:36px;font-size:23px;line-height:1}.shell-dialog-content p{margin:.6em 0}.shell-order-row{padding:10px 0;border-bottom:1px solid #52615a;display:flex;justify-content:space-between;align-items:center;gap:10px}.shell-action{border:1px solid #bea070;border-radius:8px;padding:8px 13px;text-decoration:none;background:#f5d8a3;color:#382f21;font-weight:700}.shell-action:disabled{opacity:.7}.shell-soft{background:transparent;color:var(--shell-ivory)}

.shell-head { position: sticky; top: 0; z-index: 25; background: #112222; border-bottom: 1px solid #69654e; }
.shell-bar {
  display: flex;
  align-items: center;
  gap: clamp(.55rem, 2vw, 1.4rem);
  width: min(1440px, 100%);
  min-height: 3.75rem;
  margin: auto;
  padding: max(.45rem, env(safe-area-inset-top)) clamp(.65rem, 3vw, 3rem) .45rem;
}
.shell-back, .shell-logo {
  display: inline-flex;
  flex: none;
  align-items: center;
  gap: .45rem;
  color: #ffe4b1;
  text-decoration: none;
}
.shell-back {
  min-height: 2.75rem;
  padding-inline: .65rem;
  border: 1px solid #a68b66;
  border-radius: 8px;
  background: #294441;
  font-weight: 700;
}
.shell-back:hover { background: #3a554a; }
.shell-logo { font: 600 clamp(1.25rem, 2vw, 1.8rem)/1.1 var(--shell-serif); letter-spacing: -.02em; }
.shell-main-nav { display: flex; align-items: center; gap: .38rem; justify-content: center; flex: 1 1 auto; }
.shell-main-nav a {
  --reward-count-top: -.45rem;
  --reward-count-right: -.2rem;
  display: inline-flex;
  align-items: center;
  min-height: 2.15rem;
  padding: .23rem .52rem;
  border: 1px solid #718376;
  border-radius: .45rem;
  background: #203632;
  color: #ffebc5;
  font: 680 .81rem/1.18 var(--shell-sans);
  text-decoration: none;
}
.shell-main-nav a:hover, .shell-main-nav a[aria-current='page'] { background: #3a554a; border-color: #e4c786; }
.shell-main-nav a[href='#shop'], .ec-yard-links a.ec-button[href='#shop'] {
  gap: .34rem;
  border-color: #efc475;
  background: #f0d39a;
  color: #38281b;
}
.shell-main-nav a[href='#shop']:is(:hover, [aria-current='page']),
.ec-yard-links a.ec-button[href='#shop']:hover {
  border-color: #ffdda0;
  background: #ffe6b7;
  color: #38281b;
}
:is(.shell-main-nav a[href='#shop'], .ec-yard-links a.ec-button[href='#shop']) > .mobile-icon {
  display: block;
  flex: none;
  width: 1rem;
  height: 1rem;
  color: inherit;
  fill: none;
  stroke: currentColor;
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}
.shell-insignia {
  display: grid;
  flex: none;
  place-items: center;
  width: 35px;
  height: 35px;
  border: 1px solid #bc9251;
  border-radius: 50%;
  background: radial-gradient(at 36% 25%, #bd5551, #852a31 49%, #462a2a);
  box-shadow: inset 0 0 0 3px #842e36, inset 0 0 0 4px #bea575;
  color: #ffdb8d;
  font: normal 24px/1 var(--shell-serif);
}
.shell-game-nav { width: min(1250px, 100%); margin: 0 auto; padding: 10px clamp(14px, 3vw, 38px) 0; }
.shell-game-nav a { display: inline-block; padding: 5px 0; color: #efd9af; font-weight: 600; font-size: 14px; }

@media (max-width: 555px) {
  .shell-logo-name { display: none; }
  .shell-insignia { width: 31px; height: 31px; font-size: 21px; }
}
@media (max-width: 880px) {
  .shell-bar { flex-wrap: wrap; row-gap: .35rem; }
  .shell-main-nav { flex: 0 0 100%; order: 2; justify-content: start; }
}
@media (max-width: 370px) {
  .shell-back { width: 2rem; min-height: 2.1rem; padding: 0; justify-content: center; font-size: 0; }
  .shell-back span { font-size: 1.1rem; }
}
@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; }
}

.snow-coin {
  position: relative;
  display: inline-grid;
  flex: none;
  place-items: center;
  width: 1.65rem;
  aspect-ratio: 1;
  border: 1px solid #fff4cb;
  border-radius: 50%;
  background: radial-gradient(circle at 30% 23%, #fcf7e6, #a9d8e6 44%, #5f8da7 77%, #345369);
  box-shadow: inset 0 0 0 2px #dce7ea, inset 0 0 0 3px #567586, 0 2px 4px #071218c9;
}
.snow-coin > i { position: absolute; inset: 20%; filter: drop-shadow(0 1px 0 #315979); }
.snow-coin b { position: absolute; inset: 4% auto; left: calc(50% - .5px); width: 1px; background: #fff8df; }
.snow-coin b:nth-child(2) { rotate: 60deg; }
.snow-coin b:nth-child(3) { rotate: -60deg; }
.snow-coin b::before, .snow-coin b::after {
  position: absolute;
  left: -1px;
  width: 3px;
  height: 3px;
  content: '';
  border: solid #fff8df;
  border-width: 0 1px 1px 0;
  transform: rotate(45deg);
}
.snow-coin b::before { top: 0; }
.snow-coin b::after { bottom: 0; rotate: 180deg; }
.shell-coin-total {
  display: flex;
  align-items: center;
  gap: .65rem;
  margin: .65rem 0 1.15rem;
  color: #f9e3b8;
  font: normal 2rem/1 Georgia, serif;
  font-variant-numeric: tabular-nums;
}
.shell-coin-total .snow-coin { width: 2.25rem; }
.shell-coin-packs { display: grid; gap: .45rem; }
.shell-coin-pack { display: grid; grid-template-columns: auto 1fr auto; align-items: center; gap: .6rem; padding: .55rem; background: #24413a; border-radius: 8px; }
.shell-coin-pack button { display: inline-flex; align-items: center; gap: .32rem; }
.shell-coin-pack button img { width: 1rem; height: 1rem; object-fit: contain; }
.shell-coin-actions { display: flex; flex-wrap: wrap; gap: .45rem; margin-top: .9rem; }
.shell-coin-status:empty { display: none; }
@media (max-width: 720px) {
  body { padding-bottom: env(safe-area-inset-bottom); }
  .shell-toast { bottom: max(1rem, env(safe-area-inset-bottom)); }
}

@media (max-width: 760px), (pointer: coarse) {
  body:not([data-route='tree'], :has(.elka-claw.is-at-cabinet)) > #main-content {
    padding-inline: env(safe-area-inset-left) env(safe-area-inset-right);
  }
  .shell-bar {
    padding-left: max(.65rem, env(safe-area-inset-left));
    padding-right: max(.65rem, env(safe-area-inset-right));
  }
  .shell-main-nav { flex-wrap: wrap; }
  .shell-main-nav a, .shell-action, .shell-game-nav a { min-height: 44px; }
  .shell-game-nav a { display: inline-flex; align-items: center; }
  .shell-back, .shell-logo, .shell-dialog-top button { min-width: 44px; min-height: 44px; }
  .shell-logo { justify-content: center; }
}

@media (max-width: 600px), (max-height: 500px) {
  .shell-head { position: relative; }
}

.shell-wallet {
  --wallet-height: 2.45rem;
  display: inline-flex;
  align-items: stretch;
  flex: none;
  font-variant-numeric: tabular-nums;
}
.shell-wallet__balance, .shell-wallet__add {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: .3rem;
  min-height: var(--wallet-height);
  border: 1px solid #aa8b56;
  background: #1b332f;
  color: #fff0cf;
  font: 750 .92rem/1 var(--shell-sans);
  text-decoration: none;
  touch-action: manipulation;
}
.shell-wallet__balance { min-width: 44px; padding: .22rem .45rem; }
.shell-wallet__balance:focus-visible, .shell-wallet__add:focus-visible { z-index: 1; }
.shell-wallet__balance[data-wallet-balance='coins'] { border-radius: 8px 0 0 8px; }
.shell-wallet__balance[data-wallet-balance='tickets'] {
  display: grid;
  grid-template-columns: auto auto;
  align-content: center;
  gap: .14rem .3rem;
  min-width: 4.12rem;
  margin-inline-end: .28rem;
  border-radius: 8px;
}
.shell-wallet__balance:hover { background: #304941; border-color: #f0d195; }
.shell-wallet__count { min-width: 2ch; text-align: center; }
.shell-wallet .snow-coin { width: 1.15rem; }
.shell-wallet .wheel-ticket { width: 1.18rem; }
.shell-wallet__add {
  min-width: 2rem;
  padding: 0 .36rem;
  border-inline-start: 0;
  border-radius: 0 8px 8px 0;
  background: linear-gradient(#ffe8b5, #e6b86d);
  color: #392616;
  font-size: 1.24rem;
}
.shell-wallet__add:hover { background: #ffebbf; }
.shell-wallet .ticket-recovery {
  --ticket-recovery-rail: #476058;
  grid-column: 1 / -1;
  gap: .22rem;
  padding: 0 0 .19rem;
  border: 0;
  background: transparent;
  font-size: .66rem;
}
.shell-wallet .ticket-recovery .wheel-ticket,
.shell-wallet .ticket-recovery__word,
.shell-wallet .ticket-recovery__lead { display: none; }
.shell-wallet .ticket-recovery__time { min-width: 0; font-size: inherit; }
.shell-wallet .ticket-recovery::after { inset: auto 0 0; }
.shell-wallet-status {
  position: absolute;
  width: 1px;
  height: 1px;
  overflow: hidden;
  clip-path: inset(50%);
}
.shell-wallet-flight {
  position: fixed;
  z-index: 120;
  inset: 0;
  width: 100%;
  height: 100%;
  margin: 0;
  padding: 0;
  overflow: clip;
  border: 0;
  background: transparent;
  pointer-events: none;
}
.shell-wallet-flight > .shell-wallet-particle {
  position: absolute;
  inset: 0 auto auto 0;
  width: 1.65rem;
  offset-rotate: 0deg;
  offset-anchor: center;
  filter: drop-shadow(0 0 6px #f4d397b3);
}
.shell-wallet-gain {
  position: absolute;
  display: inline-flex;
  align-items: center;
  gap: .32rem;
  padding: .32rem .5rem;
  transform: translateX(-100%);
  border: 1px solid #ba9a5d;
  border-radius: 8px;
  background: #172f30;
  color: #fff0cf;
  box-shadow: 0 3px 12px #080f15aa;
  font: 750 .9rem/1 var(--shell-sans);
  font-variant-numeric: tabular-nums;
}
.shell-wallet-gain :is(.snow-coin, .wheel-ticket) { width: 1rem; }
.shell-wallet-gain > span:last-child { color: #ffd889; }
.shell-wallet-gain[data-kind='coins'] > span:last-child { color: #c1e6f4; }
.shell-wallet:is(.claw-wallet, .words-wallet) { display: none; }
.words-cabinet:is(:fullscreen, [data-expanded]) > .words-wallet {
  position: sticky;
  top: 0;
  z-index: 3;
  display: inline-flex;
  grid-column: 1 / -1;
  justify-self: end;
  margin: 5px 8px;
}
@media (max-width: 760px), (max-height: 500px) {
  .is-at-cabinet .claw-badges > .claw-wallet { display: inline-flex; grid-area: 2 / 1 / auto / -1; justify-self: end; }
  .is-at-cabinet .claw-badges:has(> .claw-wallet) > .claw-stage-tools { grid-row: 3; }
}
