/* =========================================
   ZÁKLADNÍ STYLING A POZADÍ
   ========================================= */

body, html {
    margin: 0;
    padding: 0;
    font-family: 'Roboto';
    background-color: #000;
    color: white;
    overflow-x: hidden;
}

#starsCanvas {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    z-index: 0; 
    background: radial-gradient(circle at center, #1a1a1a 0%, #000 100%);
    pointer-events: none;
}

/* =========================================
   3D MODEL A HLAVNÍ PRVKY (LOGO, TITULEK)
   ========================================= */

model-viewer {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100vh;
    z-index: 1;
    --progress-mask: transparent;
    background: transparent;
}

.fixed-corner-logo {
    position: fixed;
    top: 30px;
    left: 40px;
    width: 60px;
    height: auto;
    z-index: 1001;
    pointer-events: auto;
    opacity: 0.8;
    transition: all 0.4s ease;
}

.fixed-corner-logo:hover {
    opacity: 1;
    transform: scale(1.1);
}

.main-title {
    position: fixed;
    top: 14%;
    left: 9%;
    width: auto;
    text-align: left;
    font-family: 'MedievalSharp', cursive;
    font-size: 3rem;
    color: #ffffff;
    text-shadow: 0 0 10px rgba(0,0,0,0.8), 2px 2px 5px rgba(0,0,0,1);
    z-index: 1001;
    pointer-events: none;
    letter-spacing: 2px;
    margin: 0;
}

/* =========================================
   NAVIGACE
   ========================================= */

.main-nav {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 80px;
    display: flex;
    align-items: center;
    justify-content: flex-end;
    padding: 0 60px;
    z-index: 2000;
    background: linear-gradient(to bottom, rgba(0,0,0,0.8) 0%, transparent 100%);
    box-sizing: border-box;
    transition: background 0.3s ease;
}

.main-nav:hover {
    background: rgba(0, 0, 0, 0.9);
}

.main-nav ul {
    list-style: none;
    margin: 0;
    padding: 0;
    display: flex;
    gap: 45px;
}

.main-nav ul li a {
    font-family: 'MedievalSharp', cursive;
    text-decoration: none;
    color: #ffffff;
    font-size: 1.3rem;
    letter-spacing: 2px;
    position: relative;
    display: inline-block;
    transition: all 0.3s ease;
    text-shadow: 2px 2px 10px rgba(0, 0, 0, 0.7);
}

.main-nav ul li a:hover {
    transform: scale(1.1);
}

.main-nav ul li a::after {
    content: '';
    position: absolute;
    left: 0;
    bottom: -15px;
    width: 0;
    height: 20px;
    background-image: url('menu/sword3.png');
    background-size: contain;
    background-repeat: no-repeat;
    background-position: left center;
    transition: width 0.4s ease-out;
}

.main-nav ul li a:hover::after {
    width: 100%;
}

/* =========================================
   SCROLL EFEKTY ATD
   ========================================= */

.scroll-container {
    position: relative;
    z-index: 2;
}

.step {
    height: 100vh;
    display: flex;
    align-items: center;
    padding: 0 10%;
    pointer-events: none;
}

.label {
    max-width: 350px;
    background: rgba(0, 0, 0, 0.7);
    padding: 20px;
    border-radius: 20px;
    opacity: 0;
    transform: translateY(20px);
    transition: all 0.6s ease-out;
    pointer-events: all;
    backdrop-filter: blur(5px);
    z-index: 100;
    border: 1px solid rgba(255,255,255,0.2);
}

.label p {
    font-weight: 100;
    line-height: 1.6;
    letter-spacing: 1.5px;
}

.label.visible {
    opacity: 1;
    transform: translateY(0);
}

.left { align-self: center; justify-self: flex-start; }
.right { margin-left: auto; }

.central {
    margin: 0 auto;
    text-align: center;
}

.back-button {
    display: inline-block;
    margin-top: 20px;
    padding: 12px 25px;
    background-color: transparent;
    color: #ffffff;
    border: 2px solid #ffffff;
    font-family: 'MedievalSharp', cursive;
    text-decoration: none;
    font-size: 1.1rem;
    border-radius: 5px;
    transition: all 0.3s ease;
    cursor: pointer;
    pointer-events: auto;
}

.back-button:hover {
    background-color: #ffffff;
    color: #000000;
    transform: scale(1.05);
    box-shadow: 0 0 15px rgba(255, 255, 255, 0.5);
}

/* =========================================
   RESPONZIVITA (MOBILNÍ ZAŘÍZENÍ)
   ========================================= */

@media (max-width: 900px) {
    .main-nav {
        padding: 0 30px;
        height: 70px;
    }
    .main-nav ul {
        gap: 25px;
    }
    .main-nav ul li a {
        font-size: 1.1rem;
    }
}

@media (max-width: 768px) {
    .main-title {
        position: absolute;
        font-size: 1.6rem;
        top: 80px;
        left: 5%;
        width: 90%;
        text-align: center;
    }

    .fixed-corner-logo {
        top: 15px;
        left: 15px;
        width: 40px;
    }

    model-viewer {
        height: 100vh;
        top: 10%;
    }

    .step {
        height: 100vh;
        align-items: flex-end;
        padding: 0 5% 120px 5%;
    }

    .label {
        max-width: 100%;
        width: 100%;
        margin: 0 auto !important;
        text-align: center;
        box-sizing: border-box;
        padding: 15px;
        background: rgba(0, 0, 0, 0.8);
        display: flex;
        flex-direction: column;
        align-items: center;
    }

    .label h2 {
        font-size: 1.2rem;
        margin-bottom: 5px;
    }

    .label p {
        font-size: 0.85rem;
    }

    #step1 {
        margin-top: 60vh;
    }

    .back-button {
        width: 100%;
        min-width: 200px;
        font-size: 0.9rem;
        padding: 10px;
        margin: 20px auto 0 auto;
        box-sizing: border-box;
    }
}

@media (max-width: 600px) {
    .main-nav {
        height: auto;
        padding: 15px 0;
        background: rgba(0, 0, 0, 0.95);
        justify-content: center;
        flex-direction: column;
    }

    .main-nav ul {
        flex-direction: row;
        gap: 15px;
        flex-wrap: wrap;
        justify-content: center;
    }

    .main-nav ul li a {
        font-size: 0.9rem;
        letter-spacing: 1px;
    }

    .main-nav ul li a::after {
        height: 12px;
        bottom: -8px;
    }
}