@font-face {
    font-family: 'Xmas';
    src: url(../fonts/xmas.otf);
    font-weight: normal;
    font-style: normal;
}

:root {
    --font-xmas: 'Xmas';
    --font-inter: 'Inter', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --font-roboto: 'Roboto', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
}

body {
    font-family: var(--font-inter);
    font-optical-sizing: auto;
    font-weight: 400;
    font-style: normal;
}

h1, h2, h3, h4, h5, h6,
.navbar-brand {
    font-family: var(--font-roboto);
    font-weight: 500;
}

.navbar-brand {
    font-weight: 700;
}

.modern-navbar {
    width: 60%;
    background: linear-gradient(135deg, #f8fafc70 0%, #e2e8f070 100%);
    padding: 0.75rem 0;
    border-radius: 16px;
    margin: 12px;
    box-shadow:
        0 4px 20px rgba(148, 163, 184, 0.15),
        0 2px 8px rgba(0, 0, 0, 0.05);
        /* border: 1px solid rgba(148, 163, 184, 0.2); */
}
    
.modern-nav {
    position: absolute;
    align-items: center;
    gap: 0.5rem;
    z-index: 100;
}

.modern-nav .nav-link {
    font-family: xmas;
    font-size: 50px;
    color: white !important;
    background: rgba(148, 163, 184, 0.1);
    backdrop-filter: blur(10px);
    border-color: rgba(148, 163, 184, 0.2);
}

.dropdown {
    position: relative;
}

.modern-nav-link {
    color: #475569 !important;
    font-weight: 500;
    padding: 0.5rem 1rem !important;
    border-radius: 12px;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    display: flex;
    align-items: center;
    margin: 0 0.25rem;
    text-decoration: none;
    border: 1px solid transparent;
    width: max-content;
}

.modern-nav-link:hover {
    color: #1e293b !important;
    background: rgba(148, 163, 184, 0.1);
    backdrop-filter: blur(10px);
    border-color: rgba(148, 163, 184, 0.2);
    transform: translateY(-1px);
}

.modern-nav-link.active {
    color: #1e293b !important;
    background: rgba(148, 163, 184, 0.2);
    backdrop-filter: blur(15px);
    border-color: rgba(148, 163, 184, 0.3);
    box-shadow:
        0 4px 15px rgba(148, 163, 184, 0.2),
        inset 0 1px 0 rgba(255, 255, 255, 0.3);
    font-weight: 600;
}

.modern-dropdown {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.12),
        0 2px 8px rgba(0, 0, 0, 0.08);
    padding: 0.5rem;
    margin-top: 0.5rem;
    opacity: 0;
    visibility: hidden;
    transform: translateY(-10px);
    transition: all 0.3s ease;
    display: block !important;
    position: absolute !important;
    top: 100% !important;
    left: 0 !important;
    z-index: 1000;
}

.dropdown:hover .modern-dropdown {
    opacity: 1 !important;
    visibility: visible !important;
    transform: translateY(0) !important;
}

.modern-dropdown:hover {
    opacity: 1 !important;
    visibility: visible !important;
    transform: translateY(0) !important;
}

.modern-dropdown .dropdown-item {
    color: #374151;
    padding: 0.5rem 0.75rem;
    border-radius: 8px;
    transition: all 0.2s ease;
    display: flex;
    align-items: center;
    font-weight: 500;
}

.modern-dropdown .dropdown-item:hover {
    background: linear-gradient(135deg, #e2e8f0 0%, #cbd5e1 100%);
    color: #1e293b;
    transform: translateX(2px);
}

.modern-dropdown .dropdown-item.red {
    background: linear-gradient(135deg, #d91616 0%, #d9161650 100%);
    color: white;
    font-weight: 600;
    text-align: center;
    display: block;
}

.modern-navbar .navbar-brand {
    color: #1e293b !important;
    font-weight: 700;
}

.modern-nav .dropdown-toggle::after {
    display: none;
}

.navbar-nav .dropdown-toggle {
    color: #475569 !important;
}

.navbar-nav .dropdown-menu {
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(20px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    box-shadow:
        0 8px 32px rgba(0, 0, 0, 0.12),
        0 2px 8px rgba(0, 0, 0, 0.08);
}

.card-header {
    font-family: var(--font-roboto);
    font-weight: 500;
}

.dashboard-header {
    background: linear-gradient(135deg, #f8fafc 0%, #e2e8f0 100%);
    border-radius: 15px;
    padding: 2rem;
    margin-bottom: 2rem;
    border: 1px solid rgba(148, 163, 184, 0.2);
}

.text-gray-800 {
    color: #2d3748 !important;
}

.btn {
    font-family: var(--font-inter);
    font-weight: 500;
}

.navbar-logo {
    height: 45px;
    width: auto;
    object-fit: contain;
}

.auth-logo {
    height: 60px;
    width: auto;
    object-fit: contain;
    max-width: 200px;
}

.login-background {
    position: fixed;
    top: 0;
    left: 0;
    width: 100vw;
    height: 100vh;
    background-image: url('/images/xmas-bg.gif');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    /* filter: blur(3px); */
    z-index: -2;
}

.login-background::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.35);
    /* backdrop-filter: blur(2px); */
    z-index: -1;
}

.glass-card {
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(8px);
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 20px;
    box-shadow:
        0 25px 50px rgba(0, 0, 0, 0.15),
        0 10px 25px rgba(0, 0, 0, 0.1),
        inset 0 1px 0 rgba(255, 255, 255, 0.5);
    position: relative;
    overflow: hidden;
}

.glass-card::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(255, 255, 255, 0.1);
    pointer-events: none;
    z-index: 1;
}

/* Contenuto del form sopra l'overlay */
.glass-card > * {
    position: relative;
    z-index: 2;
}

.glass-card::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 1px;
    background: linear-gradient(90deg,
        transparent,
        rgba(255, 255, 255, 0.6),
        transparent);
}

/* Auth Body Styling */
.auth-body {
    background: transparent !important;
    min-height: 100vh;
    position: relative;
}

/* Logo Enhancement for Glass Theme */
.auth-logo {
    height: 80px;
    width: auto;
    object-fit: contain;
    max-width: 250px;
    filter: drop-shadow(0 4px 8px rgba(0, 0, 0, 0.2));
}

/* Form Controls Glass Style */
.glass-input {
    border: 1px solid rgba(255, 255, 255, 0.3);
    border-radius: 12px;
    backdrop-filter: blur(10px);
    color: #333;
    transition: all 0.3s ease;
}

.glass-input:focus {
    border-color: rgba(255, 255, 255, 0.5);
    box-shadow: 0 0 20px rgba(255, 255, 255, 0.3);
    outline: none;
}

.glass-input:not(select) {
    background: rgba(255, 255, 255, 0.2);
}

.glass-input:not(select):focus {
    background: rgba(255, 255, 255, 0.3);
}

.glass-input::placeholder {
    color: rgba(60, 60, 60, 0.8);
}

.glass-btn {
    background: linear-gradient(135deg,
        rgba(255, 255, 255, 0.3),
        rgba(255, 255, 255, 0.1));
    border: 1px solid rgba(255, 255, 255, 0.4);
    border-radius: 12px;
    backdrop-filter: blur(10px);
    color: #333;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 8px 16px rgba(0, 0, 0, 0.1);
}

.glass-btn:hover {
    background: linear-gradient(135deg,
        rgba(255, 255, 255, 0.4),
        rgba(255, 255, 255, 0.2));
    transform: translateY(-2px);
    box-shadow: 0 12px 24px rgba(0, 0, 0, 0.15);
    color: #333;
}

.glass-label {
    color: #333;
    font-weight: 500;
    font-size: 0.9rem;
    margin-bottom: 0.5rem;
}

.form-check-input {
    background: rgba(255, 255, 255, 0.2);
    border: 1px solid rgba(255, 255, 255, 0.3);
    backdrop-filter: blur(10px);
}

.form-check-label,
.btn-link {
    color: #333 !important;
}

.btn-link:hover {
    color: #555 !important;
}

.invalid-feedback {
    color: #dc3545;
    font-weight: 500;
}

.auth-body h3 {
    font-family: 'xmas';
    font-size: 4em;
    color: goldenrod !important;
    text-shadow: 1px 1px 4px black;
}

@media (max-width: 768px) {
    .auth-logo {
        height: 60px;
    }

    .glass-card {
        border-radius: 16px;
        margin: 1rem;
    }
}

@media (max-width: 768px) {
    .navbar-logo {
        height: 28px;
    }

    .auth-logo {
        height: 50px;
    }
}

@media (max-width: 991px) {
    .modern-navbar {
        margin: 8px;
        border-radius: 12px;
    }

    .modern-nav {
        padding-top: 1rem;
        flex-direction: column;
        align-items: stretch;
    }

    .modern-nav-link {
        margin: 0.25rem 0;
        justify-content: flex-start;
    }

    .modern-dropdown {
        position: static !important;
        transform: none !important;
        margin: 0.5rem 0;
        width: 100%;
    }
}

.door-container .icon {
    position: absolute;
    width: 125px;
    bottom: 0;
    z-index: 1;
    left: 50%;
    transform: translate(-50%);
}

.door-container .icon.ChristmasSocks {
    width: 80px;
    bottom: 30px;
}

.door-container .icon.decorazioni-complesse {
    width: 110px;
    top: 25px;
}

.door-container .icon.xmas-memory {
    width: 55px;
    bottom: 30%;
}

.door-container .icon.decora-albero {
    width: 100px;
    left: 56%;
}

.door-container .icon.GingerBreadSocks {
    width: 80px;
    bottom: 30px;
}

.door-container .icon.raccogli-regali {
    bottom: 2px;
}

.door-container .icon.aiutante-babbo {
    width: 80px;
    bottom: 8px;
}

.door-container .icon.MerryChristmas {
    width: 80px;
    bottom: 30px;
}

.door-container .icon.salta-camini {
    width: 100px;
    bottom: -7px;
    left: 51%;
}

.door-container .icon.trova-peluche {
    width: 70px;
}

.door-container .icon.corri-babbo {
    bottom: -25px;
}

.door-container .icon-bg {
    position: absolute;
    width: 80px;
    left: 70px;
    height: 0;
    top: 8px;
    border-top: 144px solid wheat;
    border-left: 9px solid transparent;
}

.door-container .icon-bg.dark {
    border-top: 144px solid darkred;
}

.door-container {
    position: relative;
}

.door-container .semi-opened,
.door-container:hover .closed {
    display: none;
}

.door-container:hover .semi-opened {
    display: block;
}

.door {
    width: 175px;
    cursor: pointer;
    filter: drop-shadow(1px 1px 5px #000);
    z-index: 2;
}

.door.ready {
    filter: drop-shadow(1px 1px 15px goldenrod);
}

.xmas-house {
    /* transform: scale(.6) translate(0, -30%); */
    position: relative;
    filter: drop-shadow(1px 1px 5px #000);
}

.walls {
    position: absolute;
    height: 100%;
    width: 100%;
    top: 0;
    left: 50%;
    transform: translate(-50%);
    background-image: url(/images/wall.jpg);
    background-size: 10%;
    filter: brightness(70%);
}

.home-bg {
    background-image: url('/images/home-bg.gif');
    background-repeat: no-repeat;
    background-size: 100%;
    width: 100vw;
    height: 100vh;
    position: fixed;
    left: 0;
    top: 0;
    filter: brightness(75%);
}

.roof {
    position: absolute;
    top: -8%;
    left: -3%;
    width: 100%;
    z-index: 90;
    filter: brightness(88%);
}

.roof img {
    width: 105%;
    aspect-ratio: 12/1;
}

.score {
    margin: 0;
    display: flex;
    width: 90%;
    margin: 0 15px 0 auto;
    gap: 10px;
}

.lvl-score {
    background: lightgray;
    width: calc(100% / 24);
    height: 6px;
    border-radius: 15em;
}

.lvl-score.done {
    background: #1ee11e;
}

.door-container::after {
    content: attr(data-number);
    position: absolute;
    z-index: 99;
    top: -5px;
    left: 97px;
    background: goldenrod;
    width: 25px;
    border-radius: 100%;
    aspect-ratio: 1;
    display: flex;
    justify-content: center;
    align-items: center;
    font-size: 23px;
    font-weight: 900;
    font-family: xmas;
    height: 25px;
    border: 2px solid darkred;
}

.santa-hat {
    position: absolute;
    width: 6%;
    z-index: 199;
    transform: rotateY(180deg);
    left: -10px;
    top: -35px;
    filter: brightness(70%) contrast(180%);
}