/* ═══════════════════════════════════════════════════════════
   GOU COSTS — SPLASH SCREEN  (pure CSS 3-D, no library)
   Palette: #262626 · #F2CB9B · #8C8274 · #BFBFBF · #F2F2F2
   ═══════════════════════════════════════════════════════════ */

#gou-splash {
    position: fixed;
    inset: 0;
    z-index: 9999;
    background: #F2F2F2;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 2.25rem;
    font-family: 'Outfit', sans-serif;
    overflow: hidden;
    transition: opacity 0.55s ease, visibility 0.55s ease;
}
#gou-splash.hidden {
    opacity: 0;
    visibility: hidden;
    pointer-events: none;
}

/* ── subtle radial backdrop so scene pops ── */
#gou-splash::before {
    content: '';
    position: absolute;
    inset: 0;
    background: radial-gradient(ellipse 70% 60% at 50% 50%,
        rgba(242,203,155,0.10) 0%,
        transparent 72%);
    pointer-events: none;
}

/* ════════════════════════════════════════
   BRAND LOCKUP
════════════════════════════════════════ */
.splash-brand {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    animation: splashSlideDown 0.6s cubic-bezier(0.16,1,0.3,1) both;
}
.splash-logo {
    width: 44px; height: 44px;
    background: #262626;
    border-radius: 12px;
    display: flex; align-items: center; justify-content: center;
    color: #F2CB9B;
    font-size: 1.4rem; font-weight: 800;
    box-shadow: 0 8px 20px rgba(38,38,38,0.18);
}
.splash-title {
    font-size: 1.55rem; font-weight: 800;
    color: #262626; letter-spacing: -0.5px;
}
.splash-title span { color: #8C8274; }

@keyframes splashSlideDown {
    from { opacity: 0; transform: translateY(-16px); }
    to   { opacity: 1; transform: translateY(0); }
}

/* ════════════════════════════════════════
   3-D SCENE CONTAINER
   perspective + preserve-3d = real depth
════════════════════════════════════════ */
.splash-scene-wrap {
    perspective: 520px;
    perspective-origin: 50% 44%;
    width: 200px; height: 200px;
    position: relative;
}

.splash-scene {
    width: 100%; height: 100%;
    position: relative;
    transform-style: preserve-3d;
    /* Slow continuous Y-rotation drives the whole scene */
    animation: sceneRotate 10s linear infinite;
}

@keyframes sceneRotate {
    from { transform: rotateX(22deg) rotateY(0deg); }
    to   { transform: rotateX(22deg) rotateY(360deg); }
}

/* ── SERVER CUBE ── */
.server-cube {
    position: absolute;
    top: 50%; left: 50%;
    width: 58px; height: 58px;
    transform: translate(-50%, -50%);
    transform-style: preserve-3d;
}

/* Six faces */
.cube-face {
    position: absolute;
    width: 58px; height: 58px;
    border-radius: 6px;
    backface-visibility: visible;
}
.cube-face.front  { background: #262626; transform: translateZ(29px); }
.cube-face.back   { background: #1a1a1a; transform: rotateY(180deg) translateZ(29px); }
.cube-face.right  { background: #2e2e2e; transform: rotateY(90deg)  translateZ(29px); }
.cube-face.left   { background: #1e1e1e; transform: rotateY(-90deg) translateZ(29px); }
.cube-face.top    { background: #343434; transform: rotateX(90deg)  translateZ(29px); }
.cube-face.bottom { background: #141414; transform: rotateX(-90deg) translateZ(29px); }

/* LED strips on visible faces */
.cube-face.front::before,
.cube-face.right::before,
.cube-face.top::before {
    content: '';
    position: absolute;
    inset: 0;
    border-radius: 6px;
}
.cube-face.front::before {
    background:
        /* Amber LED row */
        linear-gradient(transparent 22%, #F2CB9B 22%, #F2CB9B 28%, transparent 28%),
        /* Stone stripe */
        linear-gradient(transparent 42%, #8C8274 42%, #8C8274 46%, transparent 46%);
    opacity: 0.9;
    animation: ledFlicker 1.8s ease-in-out infinite alternate;
}
.cube-face.right::before {
    background: linear-gradient(transparent 35%, rgba(242,203,155,0.4) 35%, rgba(242,203,155,0.4) 40%, transparent 40%);
    opacity: 0.6;
}
.cube-face.top::before {
    background: radial-gradient(ellipse 60% 60% at 50% 50%, rgba(242,203,155,0.25) 0%, transparent 70%);
}

@keyframes ledFlicker {
    0%, 90% { opacity: 0.9; }
    95%      { opacity: 0.4; }
    100%     { opacity: 1.0; }
}

/* Pulse halo around the cube */
.cube-halo {
    position: absolute;
    top: 50%; left: 50%;
    width: 58px; height: 58px;
    transform: translate(-50%, -50%) translateZ(0px);
    border-radius: 8px;
    box-shadow: 0 0 0 0 rgba(242,203,155,0.5);
    animation: cubeHalo 2.4s ease-in-out infinite;
    pointer-events: none;
}
@keyframes cubeHalo {
    0%   { box-shadow: 0 0  0   0px rgba(242,203,155,0.55); }
    60%  { box-shadow: 0 0 28px 12px rgba(242,203,155,0.0); }
    100% { box-shadow: 0 0  0   0px rgba(242,203,155,0.0); }
}

/* ── ORBITAL RINGS ── */
/* Ring 1: outer amber — tilted 0° (equatorial) */
.orbit-1 {
    position: absolute;
    top: 50%; left: 50%;
    width: 160px; height: 160px;
    margin: -80px 0 0 -80px;
    transform-style: preserve-3d;
    transform: rotateX(90deg) rotateZ(0deg);
    animation: orb1Spin 3.2s linear infinite;
}
/* Ring 2: mid stone — tilted 58° */
.orbit-2 {
    position: absolute;
    top: 50%; left: 50%;
    width: 120px; height: 120px;
    margin: -60px 0 0 -60px;
    transform-style: preserve-3d;
    transform: rotateX(90deg) rotateZ(58deg);
    animation: orb2Spin 5s linear infinite reverse;
}
/* Ring 3: inner fog — tilted 120° */
.orbit-3 {
    position: absolute;
    top: 50%; left: 50%;
    width: 88px; height: 88px;
    margin: -44px 0 0 -44px;
    transform-style: preserve-3d;
    transform: rotateX(90deg) rotateZ(120deg);
    animation: orb3Spin 7s linear infinite;
}

@keyframes orb1Spin { from { transform: rotateX(90deg) rotateZ(0deg);   } to { transform: rotateX(90deg) rotateZ(360deg);   } }
@keyframes orb2Spin { from { transform: rotateX(90deg) rotateZ(58deg);  } to { transform: rotateX(90deg) rotateZ(-302deg);  } }
@keyframes orb3Spin { from { transform: rotateX(90deg) rotateZ(120deg); } to { transform: rotateX(90deg) rotateZ(480deg);  } }

/* Ring SVG-like border via border trick */
.orbit-1, .orbit-2, .orbit-3 {
    border-radius: 50%;
    border: 2px solid transparent;
}
.orbit-1 { border-color: rgba(242,203,155,0.55) rgba(242,203,155,0.08) rgba(242,203,155,0.08) rgba(242,203,155,0.08); }
.orbit-2 { border-color: rgba(140,130,116,0.50) rgba(140,130,116,0.08) rgba(140,130,116,0.08) rgba(140,130,116,0.08); }
.orbit-3 { border-color: rgba(191,191,191,0.45) rgba(191,191,191,0.08) rgba(191,191,191,0.08) rgba(191,191,191,0.08); }

/* Orbital dots (glowing spheres riding each ring) */
.orb-dot {
    position: absolute;
    border-radius: 50%;
    transform-style: preserve-3d;
}
/* Amber dot on ring 1 */
.orb-dot-1 {
    width: 12px; height: 12px;
    top: -6px; left: 50%;
    margin-left: -6px;
    background: #F2CB9B;
    box-shadow: 0 0 10px 3px rgba(242,203,155,0.7),
                0 0 22px 6px rgba(242,203,155,0.3);
}
/* Stone dot on ring 2 */
.orb-dot-2 {
    width: 9px; height: 9px;
    top: -4.5px; left: 50%;
    margin-left: -4.5px;
    background: #8C8274;
    box-shadow: 0 0 8px 2px rgba(140,130,116,0.6);
}
/* Fog dot on ring 3 */
.orb-dot-3 {
    width: 7px; height: 7px;
    top: -3.5px; left: 50%;
    margin-left: -3.5px;
    background: #BFBFBF;
    box-shadow: 0 0 6px 2px rgba(191,191,191,0.5);
}

/* ── FLOATING PARTICLES (Z-depth via translateZ) ── */
.splash-particles {
    position: absolute;
    inset: 0;
    transform-style: preserve-3d;
}

.particle {
    position: absolute;
    border-radius: 50%;
    animation: particleFloat linear infinite;
    opacity: 0;
}

.particle:nth-child(1)  { width:5px; height:5px; background:#F2CB9B; top:15%; left:25%; animation-duration:4.2s; animation-delay:0s;    transform: translateZ(40px); }
.particle:nth-child(2)  { width:4px; height:4px; background:#8C8274; top:70%; left:70%; animation-duration:5.5s; animation-delay:0.7s;  transform: translateZ(60px); }
.particle:nth-child(3)  { width:6px; height:6px; background:#BFBFBF; top:30%; left:75%; animation-duration:3.8s; animation-delay:1.2s;  transform: translateZ(20px); }
.particle:nth-child(4)  { width:3px; height:3px; background:#F2CB9B; top:80%; left:20%; animation-duration:6.1s; animation-delay:0.3s;  transform: translateZ(50px); }
.particle:nth-child(5)  { width:5px; height:5px; background:#8C8274; top:50%; left:10%; animation-duration:4.8s; animation-delay:1.8s;  transform: translateZ(30px); }
.particle:nth-child(6)  { width:4px; height:4px; background:#F2CB9B; top:20%; left:85%; animation-duration:5.2s; animation-delay:0.9s;  transform: translateZ(70px); }

@keyframes particleFloat {
    0%   { opacity: 0;   transform: translateY(0)   translateZ(var(--pz, 40px)); }
    15%  { opacity: 0.8; }
    80%  { opacity: 0.6; }
    100% { opacity: 0;   transform: translateY(-30px) translateZ(var(--pz, 40px)); }
}

/* ── DROP SHADOW under the scene for ground-plane illusion ── */
.splash-shadow {
    width: 110px; height: 16px;
    background: radial-gradient(ellipse 100% 100% at 50% 50%, rgba(38,38,38,0.12) 0%, transparent 80%);
    border-radius: 50%;
    animation: shadowPulse 2.4s ease-in-out infinite;
    margin-top: -1.5rem;
}
@keyframes shadowPulse {
    0%, 100% { transform: scaleX(1);    opacity: 0.7; }
    50%       { transform: scaleX(0.82); opacity: 0.4; }
}

/* ════════════════════════════════════════
   STATUS + PROGRESS
════════════════════════════════════════ */
.splash-status {
    font-size: 0.88rem;
    font-weight: 600;
    color: #8C8274;
    letter-spacing: 0.4px;
    animation: splashFade 1.8s ease-in-out infinite;
}
@keyframes splashFade {
    0%, 100% { opacity: 0.4; }
    50%       { opacity: 1;   }
}

.splash-progress {
    width: 180px; height: 3px;
    background: #BFBFBF;
    border-radius: 99px;
    overflow: hidden;
}
.splash-progress-fill {
    height: 100%;
    background: #F2CB9B;
    border-radius: 99px;
    animation: splashProgress 2.4s ease-in-out infinite;
    transform-origin: left;
}
@keyframes splashProgress {
    0%   { width: 0%;   opacity: 1; }
    70%  { width: 88%;  opacity: 1; }
    100% { width: 100%; opacity: 0; }
}
