/* 3D Model Showcase Styles */

#model-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 1;
    overflow: hidden;
}

#model-container canvas {
    display: block;
    outline: none;
}

/* UI Overlay */
.model-ui-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 10;
    font-family: 'Montserrat', sans-serif;
}

/* Model Information Panel */
#model-info {
    position: absolute;
    bottom: 80px;
    left: 50px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 30px;
    border-radius: 15px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.1);
    pointer-events: auto;
    max-width: 300px;
    transition: all 0.3s ease;
}

#model-info h3 {
    font-family: 'Playfair Display', serif;
    font-size: 24px;
    font-weight: 600;
    color: #333;
    margin-bottom: 10px;
}

#model-info p {
    font-size: 14px;
    color: #666;
    line-height: 1.6;
}

/* Navigation Controls */
.model-navigation {
    position: absolute;
    top: 50%;
    transform: translateY(-50%);
    pointer-events: auto;
}

.nav-button {
    background: rgba(255, 255, 255, 0.9);
    border: none;
    width: 60px;
    height: 60px;
    border-radius: 50%;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 20px;
    color: #333;
    transition: all 0.3s ease;
    backdrop-filter: blur(10px);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
}

.nav-button:hover {
    background: rgba(255, 255, 255, 1);
    transform: scale(1.1);
    box-shadow: 0 15px 40px rgba(0, 0, 0, 0.15);
}

.nav-button:active {
    transform: scale(0.95);
}

.nav-left {
    left: 30px;
}

.nav-right {
    right: 30px;
}

/* Progress and Navigation Elements - COMPLETELY REMOVED */
/* All progress bars and dot navigation removed from project */

/* Control Panel */
.control-panel {
    position: absolute;
    top: 30px;
    right: 30px;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(10px);
    padding: 20px;
    border-radius: 12px;
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1);
    pointer-events: auto;
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.control-button {
    background: darkgray;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 8px;
    cursor: pointer;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 1px;
    transition: all 0.3s ease;
}

.control-button:hover {
    background: gray;
    transform: translateY(-2px);
    box-shadow: 0 8px 20px rgba(128, 128, 128, 0.3);
}

.control-button:active {
    transform: translateY(0);
}

/* Instructions */
.instructions {
    position: absolute;
    top: 30px;
    left: 30px;
    background: rgba(0, 0, 0, 0.8);
    color: white;
    padding: 20px;
    border-radius: 12px;
    max-width: 250px;
    font-size: 12px;
    line-height: 1.6;
    pointer-events: auto;
    opacity: 0.8;
    transition: opacity 0.3s ease;
}

.instructions:hover {
    opacity: 1;
}

.instructions h4 {
    margin-bottom: 10px;
    font-weight: 600;
    color: #333;
}

.instructions ul {
    list-style: none;
    padding: 0;
}

.instructions li {
    margin-bottom: 5px;
    padding-left: 15px;
    position: relative;
}

.instructions li:before {
    content: "•";
    color: #333;
    position: absolute;
    left: 0;
}

/* Loading Screen */
.loading-screen {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: lightgray;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    transition: opacity 0.5s ease;
}

.loading-screen.hidden {
    opacity: 0;
    pointer-events: none;
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(211, 211, 211, 0.2);
    border-top: 4px solid darkgray;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin-bottom: 20px;
}

.loading-text {
    font-size: 16px;
    color: #333;
    font-weight: 500;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

/* Mobile Responsive */
@media (max-width: 768px) {
    #model-info {
        bottom: 120px;
        left: 20px;
        right: 20px;
        max-width: none;
        padding: 20px;
    }

    .model-navigation {
        display: none;
    }

    .control-panel {
        top: 20px;
        right: 20px;
        padding: 15px;
    }

    .instructions {
        top: 20px;
        left: 20px;
        max-width: 200px;
        padding: 15px;
        font-size: 11px;
    }

    .progress-container {
        width: 250px;
        bottom: 20px;
    }

    .model-dots {
        bottom: 50px;
        gap: 12px;
    }

    .dot {
        width: 10px;
        height: 10px;
    }
}

@media (max-width: 480px) {
    #model-info {
        bottom: 100px;
        left: 15px;
        right: 15px;
        padding: 15px;
    }

    #model-info h3 {
        font-size: 20px;
    }

    .control-panel {
        right: 15px;
        padding: 12px;
    }

    .instructions {
        left: 15px;
        max-width: 180px;
        padding: 12px;
    }

    .progress-container {
        width: 200px;
        bottom: 15px;
    }
}

/* Smooth scrolling for the page */
html {
    scroll-behavior: smooth;
}

/* Hide default scrollbar when 3D view is active */
body.model-view-active {
    overflow: hidden;
}

/* Animation for UI elements */
.fade-in {
    animation: fadeIn 0.8s ease-out;
}

.slide-up {
    animation: slideUp 0.8s ease-out;
}

@keyframes fadeIn {
    from {
        opacity: 0;
    }
    to {
        opacity: 1;
    }
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(30px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* A media gallery with the original composition, sized to Safari's visible viewport. */
.main-content { min-height: 100vh !important; min-height: 100dvh !important; }
#model-container { position: fixed !important; inset: 0; width: 100% !important; height: 100vh !important; height: 100dvh !important; background: lightgray !important; touch-action: none; overscroll-behavior: contain; }
.showcase-poster { position: absolute; top: 50%; left: 50%; width: min(65vw, 448px); max-height: 70%; object-fit: contain; transform: translate(-50%, -50%); }
.showcase-model { position: absolute; top: 0; left: 0; transform-origin: center; pointer-events: none; will-change: transform; }
.showcase-model img, .showcase-model video { display: block; width: 100%; height: 100%; object-fit: contain; }
.showcase-model video[hidden], .showcase-model img[hidden] { display: none; }
@media (pointer: coarse), (max-width: 768px) { .mobile-header { padding-top: max(15px, env(safe-area-inset-top)); } }

/* Original Ionicons artwork, served inline to avoid another runtime dependency. */
.interface-icon { display: inline-block; width: 1em; height: 1em; fill: currentColor; vertical-align: middle; }
.interface-icon svg { display: block; width: 100%; height: 100%; }
