/* =========================================
    GLOBAL STYLES
   ========================================= */
html {
    scroll-behavior: smooth;
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body,
html {
    width: 100%;
    height: 100%;
}

/* SCROLLBAR */
::-webkit-scrollbar {
    width: 10px;
}

::-webkit-scrollbar-track {
    background: #0a0a0a;
    border-left: 1px solid #1a1a1a;
}

::-webkit-scrollbar-thumb {
    background: linear-gradient(to bottom, #4a3b24, #8b6b3f, #4a3b24);
    border-radius: 5px;
    border: 2px solid #0a0a0a;
}

::-webkit-scrollbar-thumb:hover {
    background: #e1c578;
    box-shadow: 0 0 10px rgba(212, 175, 55, 0.4);
}

html {
    scrollbar-width: thin;
    scrollbar-color: #8b6b3f #0a0a0a;
}

/* HEADER */
.codex-frame {
    width: 100%;
    display: flow-root;
    background: transparent !important;
}

.header {
    position: sticky;
    top: 0;
    z-index: 1000;
    height: 172px;
    display: flex;
    justify-content: center;
    align-items: center;

    backdrop-filter: blur(10px);
    -webkit-backdrop-filter: blur(10px);

    background-color: rgba(23, 23, 23, 0.7);

    background-image: url('images/Header_Gradient_Gold.png');
    background-size: 100% 100%;
    background-repeat: no-repeat;
    overflow: visible;
}

.gold-line-overlay {
    position: absolute;
    top: 100%;
    left: 0;
    width: 100%;
    height: 6px;
    transform: translateY(-100%);
    background-image: url('images/gold-line.png');
    background-repeat: repeat-x;
    background-size: contain;
    z-index: 10;
    -webkit-mask-image: linear-gradient(to right, black 0%, black 20%, transparent 40%, transparent 60%, black 80%, black 100%);
    mask-image: linear-gradient(to right, black 0%, black 20%, transparent 40%, transparent 60%, black 80%, black 100%);
    animation: edgeGlow 5s ease-in-out infinite;
}

/* Navigation */
.title-area {
    display: flex;
    justify-content: center;
    align-items: center;
    padding: 20px 0;
}

.site-logo {
    width: 180px; /* Adjust based on your preference */
    height: auto;
    filter: drop-shadow(0 0 15px rgba(225, 197, 120, 0.4));
    transition: transform 0.3s ease;
    animation: logo-float 4s ease-in-out infinite;
}

/* Subtle hovering animation to match the night sky vibe */
@keyframes logo-float {
    0%, 100% { transform: translateY(0); }
    50% { transform: translateY(-10px); }
}

/* Ensure it shrinks on mobile so it doesn't break the layout */
@media (max-width: 768px) {
    .site-logo {
        width: 120px;
    }
}
.nav-btn {
    position: absolute;
    top: 0;
    width: clamp(220px, 25vw, 315px);
    aspect-ratio: 315 / 136;
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 11;
    text-decoration: none;
}

.nav-btn span {
    position: relative;
    top: -2px;
    z-index: 12;
    font-size: clamp(1.4rem, 2vw, 2.2rem);
    letter-spacing: 4px;
    font-family: 'Cinzel', serif;
    color: #8b6b3f;
    text-shadow: 0 0 10px rgba(0, 0, 0, 0.8), 0 0 5px rgba(139, 107, 63, 0.3);
    text-transform: uppercase;
}

.btn-left {
    left: 0;
}

.btn-right {
    right: 0;
}

.btn-right img {
    transform: scaleX(-1);
}

.nav-btn:hover span {
    color: #e1c578;
    text-shadow: 0 0 15px rgba(212, 175, 55, 0.6);
}

.nav-btn:hover {
    filter: brightness(1.3);
}

.nav-btn img {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: fill;
}

.btn-bg {
    z-index: -2;
    mix-blend-mode: multiply;
    filter: brightness(0.5) contrast(1.2);
    opacity: 0.9;
}

.btn-frame {
    z-index: -1;
    animation: edgeGlow 5s ease-in-out infinite;
}
/*  MOBILE HEADER */
.mobile-header {
    display: none;
}

.mobile-nav-btn {
    border: 1px solid rgba(201, 168, 106, 0.4);
    padding: 5px 12px;
    background: rgba(0,0,0,0.3);
}
@media (max-width: 768px) {
    .header {
        display: none !important;
    }

    .mobile-header {
        display: flex;
        position: sticky;
        top: 0;
        width: 100%;
        height: 60px; 
        background: rgba(23, 23, 23, 0.9);
        backdrop-filter: blur(10px);
        -webkit-backdrop-filter: blur(10px);
        border-bottom: 1px solid rgba(201, 168, 106, 0.3);
        z-index: 2000;
        justify-content: space-between;
        align-items: center;
        padding: 0 15px;
    }

    .mobile-title {
        display: flex;
        align-items: center;
        justify-content: center;
        height: 100%;
    }

    .mobile-logo {
        height: 40px; /* Leaves 10px padding top/bottom in a 60px header */
        width: auto;
        filter: drop-shadow(0 0 8px rgba(201, 168, 106, 0.4));
    }

    .mobile-nav-btn {
        background: none;
        border: none;
        text-decoration: none;
        font-family: 'Cinzel', serif;
        color: #c9a86a;
        font-size: 0.9rem;
        text-transform: uppercase;
        letter-spacing: 1px;
        padding: 10px;
    }

    .mobile-header .gold-line-overlay {
        height: 3px;
        opacity: 0.7;
    }
}

/* MENU WINDOW */
.menu-header {
    position: relative;
    margin-bottom: 5vh;
}

.menu-title {
    font-family: 'Cinzel', serif;
    color: #8b6b3f;
    font-size: clamp(1.2rem, 3vh, 2.2rem);
    margin-bottom: 0.5vh;
    border-bottom: none;
    font-style: italic;
    letter-spacing: 0.20em;
    text-transform: uppercase;
}

.menu-line-wrapper {
    position: absolute;
    top: 100%;
    width: 180%;
    left: -20.3%;
    pointer-events: none;
    z-index: 15;
    animation: edgeGlow 5s ease-in-out infinite;
}

.menu-separator-img {
    width: 100%;
    height: auto;
    display: block;
    overflow: visible;
}

.menu-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    z-index: 2000;
    visibility: hidden;
    transition: visibility 0.5s;
}

.menu-overlay.active .menu-dimmer {
    opacity: 1;
    pointer-events: auto;
}

.menu-overlay.active .menu-content {
    opacity: 1;
    transform: translateX(0);
}

.menu-overlay.active {
    visibility: visible;
    transition-delay: 0s;
}

.menu-dimmer {
    position: absolute;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.7);
    z-index: 1;
    opacity: 0;
    transition: opacity 0.5s ease;
    pointer-events: none;
}

.menu-content {
    position: absolute;
    top: 15vh;
    left: -1px;
    height: 75vh;
    aspect-ratio: 450 / 882;
    z-index: 2;
    background: transparent;
    display: flex;
    flex-direction: column;
    opacity: 0;
    transform: translateX(-110%);
    transition: transform 0.5s cubic-bezier(0.16, 1, 0.3, 1),
        opacity 0.4s ease-in-out;
    overflow: visible;
}

.menu-overlay.active .menu-content {
    opacity: 1;
    transform: translateX(0);
    opacity: 1;
}

.menu-bg-layer {
    position: absolute;
    top: 1.8%;
    left: 0.1%;
    width: 94.5%;
    height: 96.4%;
    z-index: -1;
    mix-blend-mode: multiply;
    object-fit: fill;
}

.menu-frame-layer {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 10;
    object-fit: contain;
    animation: edgeGlow 5s ease-in-out infinite;
}

.menu-text-container {
    position: relative;
    z-index: 11;
    padding: 10% 12%;
    height: 100%;
    display: flex;
    flex-direction: column;
    overflow: visible !important;
}

.menu-item {
    position: relative;
    width: 100%;
    padding: 0.1vh 0;
    margin-bottom: 5.5vh;
    overflow: visible;
}

.menu-item::before {
    content: '';
    position: absolute;
    top: 0;
    left: -60%;
    width: 250%;
    height: 100%;
    background: linear-gradient(90deg,
            rgba(0, 0, 0, 0) 0%,
            rgba(20, 15, 10, 0.85) 15%,
            rgba(20, 15, 10, 0) 100%);
    z-index: 1;
    opacity: 0;
    transition: opacity 0.4s ease;
    pointer-events: none;
}

.menu-links a {
    display: block;
    font-family: 'Cinzel', serif;
    color: #8b6b3f;
    text-decoration: none;
    padding: 1.5vh 0;
    font-size: clamp(1.2rem, 3vh, 2.2rem);
    font-weight: 300;
    letter-spacing: 0.04em;
    transition: 0.3s;
    position: relative;
    z-index: 5;
    padding: 0;
}

.link-separator-img {
    position: absolute;
    bottom: -2px;
    width: 130%;
    left: -15%;
    height: auto;
    pointer-events: none;
    opacity: 0.3;
    transition: opacity 0.3s ease, filter 0.3s ease;
}

.menu-links a:hover {
    color: #e1c578;
    padding-left: 10px;
    text-shadow: 0 0 10px rgba(197, 160, 89, 0.5);
}

.menu-item:hover .link-separator-top,
.menu-item:hover .link-separator-img {
    opacity: 0.8;
    filter: brightness(1.2) drop-shadow(0 0 5px rgba(225, 197, 120, 0.5));
}

.link-separator-top,
.link-separator-img {
    position: absolute;
    width: 180%;
    left: -100%;
    height: auto;
    pointer-events: none;
    opacity: 0.4;
    transition: all 0.5s cubic-bezier(0.16, 1, 0.3, 1);
    transform-origin: left center;
}

.link-separator-top {
    top: -2px;
}

.menu-item:hover::before {
    opacity: 1;
}


.menu-item:hover .link-separator-img {
    opacity: 1;
    filter: brightness(1.3) drop-shadow(0 0 8px rgba(197, 160, 89, 0.5));
    transform: scaleX(1.5) translateX(5%);
}


.menu-item:hover .link-separator-top {
    opacity: 0.7;
    filter: brightness(1.2);
}

/* FOOTER */
.footer {
    width: 100%;
    height: 100px;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    clear: both;
    margin-top: 50px;
    z-index: 20;
}

.footer img {
    max-height: 130px;
    width: auto;
    object-fit: contain;
    margin-bottom: 20px;
    opacity: 0.8;
}

/* ANIMATIONS */
@keyframes edgeGlow {

    0%,
    100% {
        filter: brightness(1) drop-shadow(0 0 2px rgba(212, 175, 55, 0.3));
        opacity: 0.7;
    }

    50% {
        filter: brightness(1.5) drop-shadow(0 0 12px rgba(212, 175, 55, 0.9));
        opacity: 1;
    }
}

/* =========================================
   CONTENT
   ========================================= */

/* MAIN CONTENT */
.main-content {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: flex-start;
    padding-top: 15px;
    width: 100%;

}


/* BACKGROUND */
body {
    background: linear-gradient(to bottom, #0f1724 0%, #000000 100%) !important;
    background-attachment: fixed !important;
    background-repeat: no-repeat;
    background-size: cover;
    min-height: 100vh;
    margin: 0;
}
.dust-container {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1;
}

/* SPARKLES - Tiny golden particles */
.sparkle {
    position: absolute;
    pointer-events: none;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Golden sparkle variations - matching site palette */
.sparkle.gold-bright {
    background: radial-gradient(circle at 35% 35%, #e1c578, #c9a86a);
    box-shadow: 0 0 3px #e1c578, 0 0 6px rgba(225, 197, 120, 0.3);
}

.sparkle.gold-warm {
    background: radial-gradient(circle at 35% 35%, #d4b896, #c9a86a);
    box-shadow: 0 0 2px #d4b896, 0 0 4px rgba(212, 184, 150, 0.25);
}

.sparkle.gold-soft {
    background: radial-gradient(circle at 35% 35%, #c9a86a, #b8956a);
    box-shadow: 0 0 2px #c9a86a, 0 0 4px rgba(201, 168, 106, 0.2);
}

.sparkle.gold-pale {
    background: radial-gradient(circle at 35% 35%, #dcc9a3, #c9a86a);
    box-shadow: 0 0 1px #dcc9a3, 0 0 3px rgba(220, 201, 163, 0.15);
}

.sparkle.silver-bright {
    background: radial-gradient(circle at 35% 35%, #ffffff, #a8c1ff);
    box-shadow: 0 0 4px #ffffff, 0 0 8px rgba(168, 193, 255, 0.6);
}

.sparkle.silver-soft {
    background: radial-gradient(circle at 35% 35%, #e0e8ff, #8ba7e0);
    box-shadow: 0 0 2px #e0e8ff, 0 0 5px rgba(139, 167, 224, 0.4);
}

/* LARGE SILVER GLOW (For Hero Stars) */
.sparkle.silver-bright.large-glow {
    box-shadow: 0 0 10px #ffffff, 0 0 20px rgba(168, 193, 255, 0.8), 0 0 40px rgba(100, 149, 237, 0.4);
}


/* Sparkle size variations - mostly tiny */
.sparkle.size-1 {
    width: 0.5px;
    height: 0.5px;
}

.sparkle.size-2 {
    width: 1px;
    height: 1px;
}

.sparkle.size-3 {
    width: 1.5px;
    height: 1.5px;
}

.sparkle.size-4 {
    width: 2px;
    height: 2px;
}

.sparkle.size-5 {
    width: 2.5px;
    height: 2.5px;
}

.sparkle.size-6 {
    width: 3px;
    height: 3px;
}

/* Larger focal sparkles with more glow */
.sparkle.size-large-1 {
    width: 3px;
    height: 3px;
    filter: blur(4px);
}

.sparkle.size-large-2 {
    width: 4px;
    height: 4px;
    filter: blur(5px);
}

.sparkle.size-large-3 {
    width: 5px;
    height: 5px;
    filter: blur(6px);
}

.sparkle.gold-bright.large-glow {
    box-shadow: 0 0 8px #ffeb3b, 0 0 16px rgba(255, 235, 59, 0.9), 0 0 35px rgba(255, 235, 59, 0.6), 0 0 60px rgba(255, 193, 7, 0.4);
}

.sparkle.gold-warm.large-glow {
    box-shadow: 0 0 8px #ffd54f, 0 0 14px rgba(255, 213, 79, 0.8), 0 0 30px rgba(255, 193, 7, 0.5), 0 0 50px rgba(255, 152, 0, 0.3);
}

.sparkle.gold-soft.large-glow {
    box-shadow: 0 0 6px #ffca28, 0 0 12px rgba(255, 202, 40, 0.75), 0 0 28px rgba(255, 193, 7, 0.4), 0 0 48px rgba(255, 152, 0, 0.25);
}

/* Large sparkle star lines with gradient taper */
.sparkle.size-large-1::before,
.sparkle.size-large-1::after {
    content: '';
    position: absolute;
    display: block;
}

.sparkle.size-large-1::before {
    width: 150%;
    height: 0.6px;
    left: -75%;
    top: 50%;
    transform: translateY(-50%);
    background: linear-gradient(to right, transparent 0%, transparent 18%, rgba(255, 235, 59, 0.6) 38%, rgba(255, 235, 59, 0.8) 50%, rgba(255, 235, 59, 0.6) 62%, transparent 82%, transparent 100%);
    filter: blur(0.8px);
    box-shadow: 0 0 15px rgba(255, 213, 79, 0.5), inset 0 0 10px rgba(255, 245, 157, 0.3);
}

.sparkle.size-large-1::after {
    width: 0.6px;
    height: 150%;
    left: 50%;
    top: -75%;
    transform: translateX(-50%);
    background: linear-gradient(to bottom, transparent 0%, transparent 18%, rgba(255, 235, 59, 0.6) 38%, rgba(255, 235, 59, 0.8) 50%, rgba(255, 235, 59, 0.6) 62%, transparent 82%, transparent 100%);
    filter: blur(0.8px);
    box-shadow: 0 0 15px rgba(255, 213, 79, 0.5), inset 0 0 10px rgba(255, 245, 157, 0.3);
}

.sparkle.size-large-2::before,
.sparkle.size-large-2::after {
    content: '';
    position: absolute;
    display: block;
}

.sparkle.size-large-2::before {
    width: 200%;
    height: 0.87px;
    left: -100%;
    top: 50%;
    transform: translateY(-50%);
    background: linear-gradient(to right, transparent 0%, transparent 15%, rgba(255, 213, 79, 0.65) 36%, rgba(255, 193, 7, 0.85) 50%, rgba(255, 213, 79, 0.65) 64%, transparent 85%, transparent 100%);
    filter: blur(1px);
    box-shadow: 0 0 18px rgba(255, 193, 7, 0.55), inset 0 0 12px rgba(255, 235, 59, 0.3);
}

.sparkle.size-large-2::after {
    width: 0.87px;
    height: 200%;
    left: 50%;
    top: -100%;
    transform: translateX(-50%);
    background: linear-gradient(to bottom, transparent 0%, transparent 15%, rgba(255, 213, 79, 0.65) 36%, rgba(255, 193, 7, 0.85) 50%, rgba(255, 213, 79, 0.65) 64%, transparent 85%, transparent 100%);
    filter: blur(1px);
    box-shadow: 0 0 18px rgba(255, 193, 7, 0.55), inset 0 0 12px rgba(255, 235, 59, 0.3);
}

.sparkle.size-large-3::before,
.sparkle.size-large-3::after {
    content: '';
    position: absolute;
    display: block;
}

.sparkle.size-large-3::before {
    width: 250%;
    height: 1.1px;
    left: -125%;
    top: 50%;
    transform: translateY(-50%);
    background: linear-gradient(to right, transparent 0%, transparent 12%, rgba(255, 202, 40, 0.65) 34%, rgba(255, 193, 7, 0.85) 50%, rgba(255, 202, 40, 0.65) 66%, transparent 88%, transparent 100%);
    filter: blur(1.2px);
    box-shadow: 0 0 22px rgba(255, 193, 7, 0.6), inset 0 0 15px rgba(255, 235, 59, 0.35);
}

.sparkle.size-large-3::after {
    width: 1.1px;
    height: 250%;
    left: 50%;
    top: -125%;
    transform: translateX(-50%);
    background: linear-gradient(to bottom, transparent 0%, transparent 12%, rgba(255, 202, 40, 0.65) 34%, rgba(255, 193, 7, 0.85) 50%, rgba(255, 202, 40, 0.65) 66%, transparent 88%, transparent 100%);
    filter: blur(1.2px);
    box-shadow: 0 0 22px rgba(255, 193, 7, 0.6), inset 0 0 15px rgba(255, 235, 59, 0.35);
}

/* Animate the star lines */
@keyframes star-lines-pulse {

    0%,
    100% {
        opacity: 0;
    }

    25% {
        opacity: 0;
    }

    40% {
        opacity: 0.8;
    }

    60% {
        opacity: 0.8;
    }

    75% {
        opacity: 0;
    }
}

@keyframes circle-glow-pulse {

    0%,
    100% {
        filter: brightness(1) drop-shadow(0 0 8px rgba(255, 255, 0, 0.4));
    }

    25% {
        filter: brightness(1) drop-shadow(0 0 8px rgba(255, 255, 0, 0.4));
    }

    40% {
        filter: brightness(1.4) drop-shadow(0 0 20px rgba(255, 200, 100, 0.7));
    }

    60% {
        filter: brightness(1.4) drop-shadow(0 0 20px rgba(255, 200, 100, 0.7));
    }

    75% {
        filter: brightness(1) drop-shadow(0 0 8px rgba(255, 255, 0, 0.4));
    }
}

.sparkle.size-large-1::before,
.sparkle.size-large-1::after {
    animation: star-lines-pulse 2.5s ease-in-out infinite;
}

.sparkle.size-large-2::before,
.sparkle.size-large-2::after {
    animation: star-lines-pulse 3s ease-in-out infinite;
}

.sparkle.size-large-3::before,
.sparkle.size-large-3::after {
    animation: star-lines-pulse 3.5s ease-in-out infinite;
}

.sparkle.size-large-1.large-glow {
    animation: float-up 6s linear forwards, circle-glow-pulse 2.5s ease-in-out infinite;
}

.sparkle.size-large-2.large-glow {
    animation: float-up 6.5s linear forwards, circle-glow-pulse 3s ease-in-out infinite;
}

.sparkle.size-large-3.large-glow {
    animation: float-up 7s linear forwards, circle-glow-pulse 3.5s ease-in-out infinite;
}

/* Animations */
@keyframes float-up {
    0% {
        transform: translateY(0) translateX(0) scale(1);
        opacity: 0;
    }

    3% {
        opacity: 1;
    }

    97% {
        opacity: 1;
    }

    100% {
        transform: translateY(var(--distance)) translateX(var(--drift)) scale(0.3);
        opacity: 0;
    }
}

@keyframes glint-bright {

    0%,
    100% {
        filter: brightness(1);
    }

    30% {
        filter: brightness(2);
    }

    60% {
        filter: brightness(0.8);
    }
}

@keyframes glint-slow {

    0%,
    100% {
        filter: brightness(0.9);
    }

    50% {
        filter: brightness(1.6);
    }
}

@keyframes pulse-glow {

    0%,
    100% {
        filter: brightness(1) blur(0px);
    }

    50% {
        filter: brightness(1.4) blur(0.2px);
    }
}

@keyframes twinkle {

    0%,
    100% {
        opacity: 0;
    }

    10% {
        opacity: 0.2;
    }

    20% {
        opacity: 1;
    }

    30% {
        opacity: 0.4;
    }

    40% {
        opacity: 1;
    }

    50% {
        opacity: 0.1;
    }

    100% {
        opacity: 0;
    }
}

.sparkle[data-speed="slow"] {
    animation: float-up 8s linear forwards;
}

.sparkle[data-speed="medium"] {
    animation: float-up 5s linear forwards;
}

.sparkle[data-speed="fast"] {
    animation: float-up 3s linear forwards;
}

.sparkle[data-speed="very-fast"] {
    animation: float-up 1.5s linear forwards;
}

.sparkle.glinting { animation-name: float-up, glint-bright; }
.sparkle.pulsing { animation-name: float-up, pulse-glow; }
.sparkle.shimmering { animation-name: float-up, shimmer; }

/* Content area */
.content {
    position: relative;
    z-index: 10;
    text-align: center;
    color: white;
}

h1 {
    font-size: 3.5rem;
    font-weight: 300;
    letter-spacing: 3px;
    margin-bottom: 1rem;
    text-shadow: 0 0 30px rgba(255, 215, 0, 0.4);
}

p {
    font-size: 1.1rem;
    opacity: 0.8;
    letter-spacing: 1px;
}


/* MEDIA FOR NAVIGATION*/

@media (max-width: 1400px) {
    .nav-btn {
        width: 240px;
        height: 104px;
    }

    .title-area {
        font-size: 1.8rem;
        letter-spacing: 6px;
    }

}

/*  BACKGROUND */

@keyframes shimmer {
    0%, 100% { opacity: 0.5; transform: scale(1); }
    50% { opacity: 1; transform: scale(1.2); }
}
