.product-dose__heading {
    margin-bottom: 15px;
    position: relative;
}

.article-card__media {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
}

.viewer-container {
    position: relative;
    width: 100%;
    height: 0;
    padding-bottom: 100%; /* Maintain aspect ratio (16:9) */
    overflow: hidden;
}

.viewer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
}

.gui-wrap {
    box-sizing: border-box;
    position: absolute;
    top: 0;
    margin-top: 10px; /* Ensure space between heading and controls */
    pointer-events: none;
    z-index: 2;
    padding: 15px;
}

.gui-wrap > .main {
    pointer-events: all;
    max-height: 100%;
    overflow: auto;
}

.gui-wrap::-webkit-scrollbar-thumb:hover {
    background: #999;
}
.dg li.gui-stats:not(.folder) {
    height: auto;
}
.axes {
    width: 50px;
    height: 50px;
    margin: 10px;
    position: absolute;
    left: 0;
    bottom: 0;
    z-index: 10;
    pointer-events: none;
}

/* Enhanced spinner with modern style */
.spinner {
    width: 50px;
    height: 50px;
    position: absolute;
    left: 50%;
    top: 40%;
    transform: translate(-50%, -50%);
    border: 5px solid rgba(255, 255, 255, 0.2);
    border-top: 5px solid #000000;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    z-index: 10;
}

/* Loading bar container */
.progress-container {
    position: absolute;
    bottom: 10%;
    left: 50%;
    transform: translateX(-50%);
    width: 80%;
    height: 10px;
    background-color: rgba(0, 0, 0, 0.1);
    border-radius: 5px;
    overflow: hidden;
    box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

/* Loading bar itself */
.progress-bar {
    height: 100%;
    width: 0%;
    background: linear-gradient(90deg, #000205, #161616);
    border-radius: 5px;
    transition: width 0.2s ease;
}

/* Loading message */
.loading-message {
    position: absolute;
    top: 52%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 14px;
    font-weight: bold;
    color: #333;
    z-index: 10;
}

/* Keyframes for spinner animation */
@keyframes spin {
    0% {
        transform: translate(-50%, -50%) rotate(0deg);
    }
    100% {
        transform: translate(-50%, -50%) rotate(360deg);
    }
}


/* Background overlay for loading */
.viewer-container.loading::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(
        to bottom,
        rgba(0, 13, 27, 0.2),
        rgba(0, 123, 255, 0)
    );
    z-index: 9;
    animation: pulse 2s infinite;
}

/* Subtle pulsing effect for overlay */
@keyframes pulse {
    0% {
        opacity: 0.8;
    }
    50% {
        opacity: 1;
    }
    100% {
        opacity: 0.8;
    }
}
@-webkit-keyframes sk-scaleout {
    0% {
        -webkit-transform: scale(0);
    }
    100% {
        -webkit-transform: scale(1);
        opacity: 0;
    }
}

@keyframes sk-scaleout {
    0% {
        -webkit-transform: scale(0);
        transform: scale(0);
    }
    100% {
        -webkit-transform: scale(1);
        transform: scale(1);
        opacity: 0;
    }
}

/* Adjust viewer container height for mobile screens */
@media (max-width: 768px) {
    .viewer-container {
        padding-bottom: 100%; /* Increase height for mobile (4:3 aspect ratio) */
    }
}

@media (max-width: 480px) {
    .viewer-container {
        padding-bottom: 80%; /* Increase further for small mobile screens (1:1 aspect ratio) */
    }

    .gui-wrap {
        display: none;
    }
}

.gui-wrap {
    display: none;
}
