@import "https://fonts.googleapis.com/css2?family=Baskervville:ital@0;1&family=Prata&family=Manrope:wght@400;500;600;700&display=swap";*{box-sizing:border-box;margin:0;padding:0}html,body,#root{width:100%;min-height:100%}body{color:#d4cbb8;touch-action:manipulation;overscroll-behavior-y:none;-webkit-user-select:none;user-select:none;-webkit-tap-highlight-color:transparent;background:#050509;min-height:100dvh;font-family:Manrope,sans-serif;overflow:hidden}button{font:inherit;appearance:none}.app-shell{--bg:#050505;--panel:#0a0a0ae0;--panel-soft:#ffffff0a;--line:#ffffff1a;--line-strong:#ffffff2e;--text-main:#f5f5f5;--text-soft:#ffffff9e;--accent:#fff;--accent-soft:#ffffff1f;--font-display:"Prata", serif;--font-editor:"Baskervville", serif;--font-ui:"Manrope", sans-serif;--safe-top:env(safe-area-inset-top,0px);--safe-right:env(safe-area-inset-right,0px);--safe-bottom:env(safe-area-inset-bottom,0px);--safe-left:env(safe-area-inset-left,0px);width:100%;min-height:100dvh;position:relative;overflow:hidden}.auth-btn{font-family:var(--font-ui);border:1px solid var(--line-strong);background:var(--panel-soft);color:var(--text-main);cursor:pointer;letter-spacing:.12em;text-transform:uppercase;border-radius:999px;min-height:48px;padding:12px 18px;font-size:.78rem;transition:all .2s}.auth-btn.primary{background:linear-gradient(135deg,#ffffff2e,#ffffff0f);border-color:#ffffff3d}.auth-btn:hover:not(:disabled){background:#ffffff24;transform:translateY(-1px)}.auth-btn:disabled,#start-btn:disabled{opacity:.5;cursor:not-allowed}.landing-hero{z-index:10;grid-template-columns:minmax(0,1fr) minmax(260px,.8fr);align-items:center;gap:clamp(20px,4vw,56px);min-height:100%;padding:32px clamp(18px,4vw,56px);display:grid;position:relative}.landing-hero:before{content:"";pointer-events:none;background:radial-gradient(circle at 18% 24%,#ffffff12,#0000 32%),radial-gradient(circle at 78% 40%,#ffffff0a,#0000 26%),linear-gradient(#ffffff08,#0000 45%);position:absolute;inset:0}.landing-copy,.hero-cube-wrap{z-index:1;position:relative}.landing-copy{max-width:640px}.landing-copy h1{font-family:var(--font-display);letter-spacing:-.05em;color:#fff;flex-direction:column;gap:.04em;max-width:8ch;font-size:clamp(3rem,7vw,5.8rem);font-style:normal;font-weight:300;line-height:.88;display:flex}.landing-copy h1 span:last-child{color:#ffffffc7}.auth-switch{background:#ffffff08;border:1px solid #ffffff14;border-radius:999px;gap:8px;margin-top:20px;margin-bottom:10px;padding:6px;display:inline-flex}.auth-switch-btn{color:#ffffff8f;min-height:40px;font-family:var(--font-ui);letter-spacing:.12em;text-transform:uppercase;cursor:pointer;background:0 0;border:0;border-radius:999px;padding:0 16px;font-size:.78rem}.auth-switch-btn.active{color:#fff;background:#ffffff14}.landing-actions{flex-flow:wrap;align-items:flex-start;gap:12px;margin-top:20px;display:flex}.hero-code-input{color:#fff;width:min(320px,100%);min-height:56px;font-family:var(--font-ui);letter-spacing:.08em;appearance:none;background:#ffffff0a;border:1px solid #ffffff24;border-radius:999px;outline:none;padding:0 18px;font-size:.92rem;transition:border-color .2s,background .2s,box-shadow .2s}.hero-code-input::placeholder{color:#ffffff57}.hero-code-input:focus{background:#ffffff0f;border-color:#ffffff4d;box-shadow:0 0 0 4px #ffffff0a}.hero-password-wrap{width:min(320px,100%);position:relative}.hero-password-input{width:100%;padding-right:82px}.hero-password-toggle{color:#ffffffd1;min-height:40px;font-family:var(--font-ui);letter-spacing:.14em;text-transform:uppercase;cursor:pointer;background:#ffffff14;border:0;border-radius:999px;padding:0 14px;font-size:.7rem;position:absolute;top:50%;right:8px;transform:translateY(-50%)}.hero-password-toggle:hover{background:#ffffff24}.hero-login-btn{font-family:var(--font-ui);color:#fff;letter-spacing:.2em;text-transform:uppercase;background:linear-gradient(135deg,#ffffff29,#ffffff0f),#ffffff0a;border:1px solid #ffffff38;border-radius:999px;min-width:220px;min-height:56px;padding:16px 28px;font-size:.9rem;transition:transform .25s,box-shadow .25s,background .25s;box-shadow:0 20px 80px #00000047}.hero-login-btn:hover:not(:disabled){transform:translateY(-2px);box-shadow:0 24px 90px #00000059}.hero-login-btn:disabled{opacity:.6;cursor:not-allowed}.landing-error{color:#ffe2e2;background:#780c0cb8;border:1px solid #ffffff14;border-radius:14px;max-width:420px;margin-top:16px;padding:12px 14px}.landing-notice{color:#ffffffd1;background:#ffffff0f;border:1px solid #ffffff14;border-radius:14px;max-width:420px;margin-top:16px;padding:12px 14px}.hero-cube-wrap{justify-content:center;align-items:center;display:flex}.hero-cube-scene{perspective:500px;filter:drop-shadow(0 0 35px #ffffff0f);width:120px;height:120px;position:relative}.hero-cube{width:120px;height:120px;transform-style:preserve-3d;will-change:transform;animation:20s linear infinite heroSpin;position:absolute;top:0;left:0}.hero-cube .face{-webkit-backdrop-filter:blur(16px)saturate(120%);background:#ffffff0f;border:1px solid #ffffff1f;border-radius:10px;grid-template-rows:repeat(3,1fr);grid-template-columns:repeat(3,1fr);gap:3px;width:120px;height:120px;padding:4px;display:grid;position:absolute}.cubelet{background:#ffffff0a;border:1px solid #ffffff1a;border-radius:4px}.face-front{transform:translateZ(60px)}.face-back{transform:rotateY(180deg)translateZ(60px)}.face-right{transform:rotateY(90deg)translateZ(60px)}.face-left{transform:rotateY(-90deg)translateZ(60px)}.face-top{transform:rotateX(90deg)translateZ(60px)}.face-bottom{transform:rotateX(-90deg)translateZ(60px)}.game-mount{z-index:0;pointer-events:none;position:fixed;inset:0}.game-mount.active,.game-mount.active canvas{pointer-events:auto;touch-action:none}.game-loading{z-index:25;color:#ffffffb8;letter-spacing:.08em;text-transform:uppercase;text-align:center;background:#08080fe0;border:1px solid #ffffff14;border-radius:10px;padding:10px 14px;font-size:.62rem;position:fixed;inset:auto 16px 16px}.game-canvas{cursor:grab;width:100%;height:100%;display:block}.game-canvas:active{cursor:grabbing}#vignette{pointer-events:none;z-index:1;background:radial-gradient(#0000 60%,#00000026 100%);position:fixed;inset:0}#setup{z-index:10;overscroll-behavior:contain;-webkit-overflow-scrolling:touch;padding:max(14px, var(--safe-top)) max(16px, var(--safe-right)) max(20px, var(--safe-bottom)) max(16px, var(--safe-left));background:radial-gradient(circle at top,#ffffff0d,#0000 30%),#08080f;flex-direction:column;justify-content:space-between;align-items:center;display:flex;position:fixed;inset:0;overflow:hidden auto}.setup-header{flex-shrink:0;justify-content:flex-end;align-items:center;gap:18px;width:min(980px,100%);display:flex}.setup-topbar{flex-direction:row;align-items:center;gap:16px;min-width:0;display:flex}.credits-add-btn{color:#ffffff80;cursor:pointer;background:0 0;border:1.5px solid #ffffff2e;border-radius:50%;justify-content:center;align-items:center;width:26px;height:26px;font-size:1rem;line-height:1;transition:border-color .2s,color .2s;display:flex}.credits-add-btn:hover{color:#ffffffe6;border-color:#fff6}.profile-wrap{margin-left:auto;position:relative}.profile-btn{cursor:pointer;background:#ffffffd9;border:1.5px solid #ffffff40;border-radius:50%;width:30px;height:30px;transition:border-color .2s}.profile-btn:hover{border-color:#ffffff80}.profile-menu{-webkit-backdrop-filter:blur(16px);z-index:20;background:#121218f2;border:1px solid #ffffff1a;border-radius:10px;flex-direction:column;min-width:180px;padding:10px 0;display:flex;position:absolute;top:calc(100% + 8px);right:0}.profile-email{font-family:var(--font-ui);color:#fff6;letter-spacing:.02em;text-overflow:ellipsis;white-space:nowrap;border-bottom:1px solid #ffffff14;padding:6px 14px 10px;font-size:.68rem;overflow:hidden}.profile-menu-item{color:#ffffffb3;font-family:var(--font-ui);letter-spacing:.06em;text-align:left;cursor:pointer;background:0 0;border:0;padding:8px 14px;font-size:.74rem;transition:background .15s}.profile-menu-item:hover:not(:disabled){background:#ffffff0f}.profile-menu-item:disabled{color:#ffffff40;cursor:default}.profile-danger{color:#c83c3cb3}.profile-danger:disabled{color:#c83c3c4d}.toast{font-family:var(--font-ui);letter-spacing:.04em;z-index:50;pointer-events:none;border-radius:8px;padding:8px 18px;font-size:.76rem;animation:.3s toastIn,.4s 2.1s forwards toastOut;position:fixed;top:28px;left:50%;transform:translate(-50%)}.toast.success{color:#fff;background:#009b48e6}.toast.error{color:#fff;background:#c83232e6}@keyframes toastIn{0%{opacity:0;transform:translate(-50%)translateY(-10px)}to{opacity:1;transform:translate(-50%)translateY(0)}}@keyframes toastOut{0%{opacity:1}to{opacity:0}}.redeem-inline{align-items:center;gap:6px;display:flex}.redeem-inline-input{color:#fff;width:100px;height:30px;font-family:var(--font-ui);letter-spacing:.08em;text-transform:uppercase;background:#ffffff0f;border:1px solid #ffffff26;border-radius:6px;outline:none;padding:0 8px;font-size:.72rem}.redeem-inline-input:focus{border-color:#ffffff4d}.redeem-inline-btn,.redeem-inline-close{color:#ffffff80;font-family:var(--font-ui);letter-spacing:.08em;text-transform:uppercase;cursor:pointer;background:0 0;border:0;padding:0;font-size:.7rem}.redeem-inline-btn:hover,.redeem-inline-close:hover{color:#ffffffe6}.redeem-inline-close{font-size:.9rem;line-height:1}.credits-inline{background:#ffffff0f;border:1px solid #ffffff14;border-radius:999px;align-items:center;gap:10px;min-height:38px;padding:0 14px;display:inline-flex}.credits-icon{color:#ffffffeb;justify-content:center;align-items:center;width:16px;height:16px;font-size:.68rem;line-height:1;display:inline-flex}.credits-value{color:#fff;font-family:var(--font-ui);letter-spacing:.08em;font-size:.92rem;font-weight:600;line-height:1}.setup-link{color:#ffffff8f;font-family:var(--font-ui);letter-spacing:.12em;text-transform:uppercase;cursor:pointer;white-space:nowrap;background:0 0;border:0;padding:0;font-size:.74rem}.setup-link:hover{color:#ffffffe6}.status-label{font-family:var(--font-ui);letter-spacing:.18em;text-transform:uppercase;opacity:.45;font-size:.62rem}.status-value{font-family:var(--font-ui);opacity:.82;font-size:1rem}.cube-preview-scene{perspective:400px;cursor:grab;touch-action:none;-webkit-user-select:none;user-select:none;justify-content:center;align-items:center;height:140px;margin-bottom:8px;display:flex}.cube-preview-scene:active{cursor:grabbing}.cube-preview{width:90px;height:90px;transform-style:preserve-3d;position:relative}.cube-preview-face{backface-visibility:hidden;background:#16161e;border-radius:6px;grid-template-rows:repeat(3,1fr);grid-template-columns:repeat(3,1fr);gap:2px;width:90px;height:90px;padding:3px;display:grid;position:absolute}.cube-preview-cell{border-radius:3px;box-shadow:inset 0 1px 1px #ffffff26}.setup-surface{flex-direction:column;flex:1 1 0;justify-content:center;align-items:center;width:min(980px,100%);min-height:0;padding:10px 0;display:flex}.setup-actions{flex-direction:column;flex-shrink:0;align-items:stretch;width:min(980px,100%);display:flex}.redeem-panel{width:min(980px,100%);margin-top:8px}.redeem-row{gap:12px;width:min(980px,100%);display:flex}.redeem-input{color:#fff;min-height:52px;font-family:var(--font-ui);letter-spacing:.08em;background:#ffffff0a;border:1px solid #ffffff1f;border-radius:999px;outline:none;flex:1;padding:0 16px;font-size:.9rem}.redeem-input::placeholder{color:#ffffff57}.redeem-btn{color:#fff;min-width:140px;min-height:52px;font-family:var(--font-ui);letter-spacing:.14em;text-transform:uppercase;cursor:pointer;background:#ffffff0d;border:1px solid #ffffff24;border-radius:999px;font-size:.78rem}.redeem-btn:disabled{opacity:.5;cursor:not-allowed}.credits-feedback{color:#ffd3d3;width:min(980px,100%);font-family:var(--font-ui);margin-top:12px;font-size:.9rem}.credits-feedback.success{color:#ffffffc7}.preset-bar{flex-shrink:0;justify-content:center;align-items:stretch;gap:8px;width:min(980px,100%);padding:12px 0;display:flex}.color-strip{flex-shrink:0;justify-content:center;align-items:center;gap:12px;padding-bottom:10px;display:flex}.color-btn{cursor:pointer;border:2px solid #ffffff1f;border-radius:999px;flex-shrink:0;width:36px;height:36px;transition:all .2s;position:relative}.color-btn,.preset-btn,.setup-link,.code-reveal-btn,.hero-password-toggle,.auth-switch-btn{touch-action:manipulation}.color-btn:hover{transform:scale(1.05)}.color-btn.active{border-color:#fff;transform:scale(1.04);box-shadow:0 0 0 4px #ffffff14}.preset-btn{color:#ffffff8c;min-height:44px;font-family:var(--font-ui);letter-spacing:.12em;text-transform:uppercase;cursor:pointer;text-align:center;background:#ffffff0a;border:1px solid #ffffff1a;border-radius:12px;flex:1;padding:10px 14px;font-size:.78rem;transition:all .2s}.preset-btn:hover{color:#ffffffe6;background:#ffffff14}.preset-btn.active{color:#fff;background:#ffffff1f;border-color:#ffffff4d}.preset-secondary{color:#ffffff8c}.save-preset-row{flex-shrink:0;justify-content:flex-end;width:min(980px,100%);padding:4px 0;display:flex}.save-preset-trigger{color:#ffffff80;font-family:var(--font-ui);letter-spacing:.12em;text-transform:uppercase;cursor:pointer;background:0 0;border:0;padding:0;font-size:.72rem;transition:color .2s}.save-preset-trigger:hover{color:#ffffffe6}.save-preset-actions{align-items:center;gap:16px;display:flex}.save-preset-reset{color:#ffffff59}.save-preset-reset:hover{color:#ff6b6b}.save-preset-form{align-items:center;gap:6px;display:flex}.save-preset-input{color:#fff;width:140px;min-height:34px;font-family:var(--font-ui);letter-spacing:.04em;background:#ffffff0a;border:1px solid #ffffff24;border-radius:999px;outline:none;padding:0 12px;font-size:.78rem}.save-preset-input::placeholder{color:#ffffff4d}.save-preset-input:focus{border-color:#ffffff4d}.save-preset-confirm{color:#fff;min-height:34px;font-family:var(--font-ui);letter-spacing:.1em;text-transform:uppercase;cursor:pointer;background:#ffffff14;border:1px solid #ffffff2e;border-radius:999px;padding:0 14px;font-size:.7rem}.save-preset-confirm:disabled{opacity:.5;cursor:not-allowed}.save-preset-cancel{color:#ffffff80;cursor:pointer;background:0 0;border:0;border-radius:999px;width:34px;min-height:34px;font-size:1rem}.save-preset-cancel:hover{color:#fff}#cross-layout{grid-template-columns:repeat(3,1fr);justify-content:center;gap:6px 10px;width:100%;max-width:420px;display:grid}.face-editor{border-radius:8px;flex-direction:column;align-items:center;gap:4px;width:100%;min-width:0;padding:4px;transition:box-shadow .2s,background .2s;display:flex}.face-editor.highlighted{background:#009b481f;box-shadow:0 0 0 1.5px #009b4899}.face-label{color:#ffffffe6;font-family:var(--font-editor);letter-spacing:-.01em;text-transform:uppercase;font-size:.78rem}.face-grid{aspect-ratio:1;background:#ffffff05;border-radius:10px;grid-template-columns:repeat(3,1fr);gap:3px;width:100%;padding:4px;display:grid}.face-cell{aspect-ratio:1;cursor:pointer;border:1px solid #ffffff0f;border-radius:6px;width:100%;min-width:0;min-height:0;transition:all .12s}.face-cell:hover{border-color:#ffffff40}.code-reveal-btn{color:#ffffff75;font-family:var(--font-ui);letter-spacing:.14em;text-transform:uppercase;cursor:pointer;background:0 0;border:0;align-self:flex-start;margin-top:6px;padding:0;font-size:.76rem}.code-reveal-btn.active,.code-reveal-btn:hover{color:#ffffffe6}#start-btn{font-family:var(--font-ui);color:#fff;letter-spacing:.28em;text-transform:uppercase;cursor:pointer;background:linear-gradient(135deg,#ffffff24,#ffffff0f);border:1px solid #ffffff2e;border-radius:999px;width:100%;min-height:48px;margin-top:10px;padding:14px 24px;font-size:clamp(.9rem,2vw,1rem);font-weight:500;transition:all .25s;box-shadow:0 18px 50px #00000038}#start-btn:hover{background:linear-gradient(135deg,#fff3,#ffffff1a);border-color:#ffffff42;transform:translateY(-1px)}.start-cost{text-align:center;font-family:var(--font-ui);letter-spacing:.08em;color:#ffffff59;margin-top:6px;font-size:.68rem;display:block}@media (width<=640px){body{overscroll-behavior-y:contain;overflow:auto}.app-shell{overflow:visible}.landing-hero{text-align:center;flex-direction:column;justify-content:center;align-items:center;gap:0;min-height:100dvh;padding:24px 20px;display:flex}.landing-copy{width:min(100%,340px)}.landing-copy h1{max-width:none;margin-inline:auto;font-size:clamp(2.4rem,10vw,3.6rem)}.hero-cube-wrap{order:-1;margin-bottom:35px}.auth-switch{margin-top:16px;margin-bottom:6px}.landing-actions{flex-direction:column;justify-content:center;align-items:stretch;gap:10px;width:100%;margin-top:16px}.hero-code-input{width:100%;min-height:50px}.hero-login-btn{min-height:50px}.hero-password-wrap{width:100%}.hero-login-btn,.landing-error,.landing-notice{width:100%;max-width:none}.auth-switch{justify-content:space-between;width:100%}.auth-switch-btn{flex:1}.setup-header{width:100%;margin-bottom:8px}.setup-topbar{z-index:12;background:0 0;flex-direction:row;justify-content:space-between;align-items:center;gap:12px;width:100%;padding:2px 0 8px;position:sticky;top:0}.credits-inline{flex-shrink:0;min-width:0}.preset-bar{gap:14px;padding:10px 0}.preset-btn{letter-spacing:.1em;font-size:.72rem}.cube-preview-scene{perspective:350px;align-items:flex-end;height:140px;margin-top:24px;margin-bottom:12px;padding-bottom:10px}.color-strip{gap:8px;padding-bottom:8px}.color-btn{width:28px;height:28px}.setup-surface{width:100%;padding:6px 0}.redeem-row{flex-direction:column}.redeem-btn{width:100%}#cross-layout{grid-template-columns:repeat(3,1fr);gap:8px;width:100%;max-width:100%}.face-label{font-size:.72rem}.setup-actions{-webkit-backdrop-filter:none;background:0 0;padding-top:0;padding-bottom:0;position:static}.credits-feedback{margin-top:10px}#start-btn{margin-top:16px}}@media (width<=420px){#setup{padding:max(12px, var(--safe-top)) max(12px, var(--safe-right)) max(16px, var(--safe-bottom)) max(12px, var(--safe-left))}.setup-link{font-size:.66rem}.setup-topbar{gap:10px}.credits-inline{min-height:34px;padding:0 12px}.credits-value{font-size:.84rem}.hero-login-btn{width:100%;min-height:48px;padding-inline:18px;font-size:.82rem}.hero-code-input{min-height:46px}.face-grid{gap:3px;padding:4px}#cross-layout{gap:4px}.color-btn{width:26px;height:26px}.color-strip{gap:6px}.face-label{font-size:.66rem}#start-btn{letter-spacing:.18em;width:100%;min-width:100%;font-size:.82rem}.preset-btn{width:auto}}@supports (-webkit-touch-callout:none){body,.app-shell,#setup,.landing-hero{min-height:100svh}}@keyframes heroSpin{0%{transform:rotateX(-22deg)rotateY(0)}50%{transform:rotateX(-30deg)rotateY(180deg)}to{transform:rotateX(-22deg)rotateY(360deg)}}
