/* Removed conflicting nav styles */


#intro {
    margin-bottom: 2rem
}

.float-right {
    float: right;
    max-width: 30vw
}

#interactive {
    display: block;
    width: 100%;
    clear: both
}

#control-overlay {
    position: absolute;
    top: 0;
    left: 0;
    width: min-content
}

#button-set {
    position: absolute;
    top: 0;
    bottom: 0;
    left: 0;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    padding: min(7vmin, 2rem);
    display: content;
    transition: opacity .5s
}

#control-overlay button {
    padding: .2rem;
    border: none;
    background: none;
    color: inherit;
    opacity: .2;
    cursor: pointer
}

@media (pointer: coarse) {

    #button-set,
    #control-overlay button {
        padding: min(3.5vmin, 1rem)
    }
}

#control-overlay button:hover {
    opacity: 1
}

section {
    box-sizing: border-box;
    padding: 0 10px
}

section img {
    display: block;
    margin: 0 auto;
    max-width: 100%
}

#interactive section {
    opacity: .8;
    padding: 10px 0;
    transform: scale(.97);
    transition: transform .1s
}

#step-box section:after {
    display: block;
    content: " ";
    text-align: center;
    background: #0004;
    position: relative;
    top: .5rem;
    height: 1px
}

#step-box section:last-of-type:after {
    display: none
}

#interactive section.active {
    opacity: 1;
    position: relative;
    transform: none
}

.note {
    padding: 10px;
    background-color: #f8f8f8;
    font-size: .9rem;
    line-height: 1.7
}

p hr {
    display: block;
    margin: 0;
    padding: 0;
    height: 1px;
    width: 100%;
    background: #000;
    border: none
}

sup {
    opacity: .7
}

#sphere {
    position: relative;
    width: 100%;
    height: 100%;
    box-sizing: border-box;
    background: #000;
    display: grid
}

.no-touch-action {
    touch-action: none
}

#sphere-wrapper {
    width: 100%;
    height: 75vh;
    position: relative;
    top: 0;
    display: grid;
    justify-content: center;
    align-items: center;
}

canvas {
    max-width: 100%;
    max-height: 100%;
}

.x {
    color: #b30000
}

.y {
    color: #006200
}

.z {
    color: #00b
}

@media (max-width: 00%) {
    #interactive {
        display: block
    }

    #sphere {
        position: sticky;
        top: 0;
        z-index: 1;
    }

    #control-overlay {
        position: absolute;
        top: 0;
        left: 0
    }

    canvas {
        max-width: 100%;
        position: relative;
        user-select: none
    }
}



/* Step Controls */
#step-controls {
    display: flex;
    justify-content: center;
    align-items: center;
    gap: 15px;
    padding: 10px 20px;
    margin: 15px auto;
}

#prev-step-btn, #next-step-btn, #step-indicator {
    display: none;
}

#step-controls button {
    padding: 10px 20px;
    font-size: 14px;
    font-weight: 500;
    cursor: pointer;
    border: 2px solid #555;
    border-radius: 8px;
    background: #333;
    color: #fff;
    transition: all 0.2s ease;
    touch-action: manipulation;
    /* Prevent double-tap zoom on mobile */
}

#step-controls button:hover {
    background: #444;
    border-color: #666;
}

#step-indicator {
    font-size: 16px;
    font-family: 'Noto Sans', sans-serif;
    font-weight: 500;
    color: #ccc;
}