* {
    -webkit-user-select: none; /* Chrome, Safari, Opera */
    -moz-user-select: none;    /* Firefox */
    -ms-user-select: none;     /* Internet Explorer/Edge */
    user-select: none;         /* Non-prefixed version, currently supported by Chrome, Edge, Opera, and Firefox */
}

body, html {
    margin: 0;
    padding: 0;
    height: 100%;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    overflow: hidden;
    background: linear-gradient(to bottom, #000046, #1CB5E0);
    color: white;
    perspective: 1000px; 
}

.background-animation {
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: linear-gradient(270deg, #000046, #1CB5E0);
    background-size: 400% 400%;
    z-index: -1;
    animation: backgroundShift 30s ease infinite;
}

@keyframes backgroundShift {
    0%, 100% { background-position: 0% 50%; }
    50% { background-position: 100% 50%; }
}

.content-container {
    width: 350px;
    height: 450px;
    position: relative;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    box-shadow: 0px 10px 30px rgba(0,0,0,0.5), inset 0 0 30px rgba(0, 0, 0, 0.2);
    border-radius: 20px;
    display: flex;
    flex-direction: column;
    justify-content: center; /* Center the content vertically */
    align-items: center; /* Center the content horizontally */
    padding: 20px;
    background: rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(10px);
    transform-origin: center center;
}

.inner-container {
    width: calc(100% - 40px);
    padding: 20px;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    align-items: center;
    padding: 20px;
    transition: transform 0.5s, background-color 0.5s;
    transform-style: preserve-3d;
    background-color: rgba(255, 255, 255, 0.1); 
    transform-origin: center center;
}

/* Welcome to TrollHub typing animation */
@keyframes typing {
    from { width: 0; }
    to { width: 100%; }
}

@keyframes typing_blink {
    from, to { border-color: transparent; }
    50% { border-color: black; }
}

@font-face {
    font-family: Bubble;
    src: url(/fonts/Bubble.otf);
}

h1 {
    font-size: 1.2em;
    white-space: nowrap;
    overflow: hidden;
    /* border-right: .15em solid black; The typewriter cursor */
    width: 0;
    animation: typing 5s steps(40, end) forwards, typing_blink .75s step-end infinite;
    color: blue; /* Start with blue, it will be overridden by JavaScript */
    /* font-family: Bubble; */
}

/* Base navigation styles */
.button-row {
    display: flex;
    justify-content: space-around; 
    align-items: center; 
    flex-wrap: wrap; /* Allow buttons to wrap */
    width: 100%; /* Full width */
    margin: 10px 0; /* Adjusted margin for spacing between rows */
}

.button-row a, .button-row button {
    min-width: 150px;
    height: 50px; 
    margin: 0; 
    padding: 10px;
    color: white;
    background-color: #023e8a;
    border-radius: 5px;
    border: none;
    cursor: pointer;
    text-decoration: none;
    text-align: center;
    box-shadow: -5px 5px 10px #0006, inset -5px 5px 10px #005599;
    transition: transform 0.3s ease, box-shadow 0.3s ease;
    display: flex; 
    justify-content: center; 
    align-items: center; 
    flex-shrink: 0; 
    flex-grow: 1; /
}


.button-row a, .button-row button {
    flex-basis: calc(33.333% - 40px);
    padding: 10px 15px; 
    font-size: 16px; 
}

.button-row a:hover, .button-row button:hover {
    transform: perspective(200px) translateZ(15px);
    box-shadow: -10px 10px 20px #0006, inset -5px 5px 10px #005599;
}

.button-row a:active, .button-row button:active {
    transform: perspective(200px) translateZ(5px);
    box-shadow: -2px 2px 5px #0006, inset -2px 2px 5px #005599;
}

#installButton {
    background-color: #4CAF50; /* Green background */
    color: white; /* White text */
    padding: 15px 32px; /* Padding inside the button */
    text-align: center; /* Centered text */
    text-decoration: none; /* No underline */
    display: inline-block; /* Allows setting width and height */
    font-size: 16px; /* Font size */
    margin: 4px 2px; /* Margin around the button */
    cursor: pointer; /* Cursor changes to pointer when hovering over the button */
    border: none; /* No border */
    border-radius: 5px; /* Rounded corners */
    box-shadow: 0 4px 8px 0 rgba(0,0,0,0.2); /* Box shadow for 3D effect */
    transition: 0.3s; /* Smooth transition for hover effects */
}

#installButton:hover {
    background-color: #45a049; /* Darker shade of green on hover */
    box-shadow: 0 8px 16px 0 rgba(0,0,0,0.2); /* Larger shadow on hover */
}

/* Styles for tablets and small desktops */
@media (max-width: 768px) {
    .button-row a, .button-row button {
        padding: 8px 12px; /* Smaller padding */
        font-size: 14px; /* Smaller font size */
        margin: 4px; /* Adjust margin */
    }
}

/* Styles for large phones and small tablets */
@media (max-width: 600px) {
    .button-row a, .button-row button {
        padding: 6px 10px; /* Even smaller padding */
        font-size: 12px; /* Even smaller font size */
        margin: 3px; /* Adjust margin */
    }
}

/* Styles for small phones */
@media (max-width: 480px) {
    .button-row a, .button-row button {
        padding: 4px 8px; /* Even smaller padding */
        font-size: 10px; /* Even smaller font size */
        margin: 2px; /* Adjust margin */
    }
}

@media (max-width: 480px) {
    .button-row a, .button-row button {
        flex-basis: calc(100% - 10px); /* Take full width minus some margin */
    }
}

.beta-label {
    background-color: #f44336; /* Red background for beta label */
    color: white; /* White text for beta label */
    font-size: 12px; /* Smaller font size for beta label */
    padding: 2px 4px; /* Padding for beta label */
    margin-left: 10px; /* Space between label and button text */
    border-radius: 2px; /* Rounded corners for beta label */
}


#volumeControl, #musicSelection {
    width: 100%;
    text-align: center;
    margin: 20px 0;
}

#volumeControl label,
#musicSelection label {
    display: block;
    margin-bottom: 10px;
    font-size: 1.2em;
}

#volumeSlider {
    width: 100%;
    margin-bottom: 20px;
    background: #ddd;
    outline: none;
    opacity: 0.7;
    transition: opacity .2s;
    -webkit-appearance: none; 
    border-radius: 30px;
}

#volumeSlider:hover, #musicSelection select:hover {
    opacity: 1
}

#volumeSlider::-webkit-slider-thumb, #volumeSlider::-moz-range-thumb {
    width: 25px;
    height: 25px;
    background: #4CAF50;
    cursor: pointer;
    border-radius: 50%;
    -webkit-appearance: none; /* Removes default thumb style for WebKit browsers */
}

#musicSelection select {
    font-size: 14px;
    padding: 10px;
    border-radius: 5px;
    border: 1px solid #fff;
    background-color: rgba(255, 255, 255, 0.8);
    color: #333;
    cursor: pointer;
}

#musicSelection select:focus {
    outline: none;
    box-shadow: 0 0 0 2px rgba(255, 255, 255, 0.5);
}

.footer {
    text-align: center;
    padding: 10px;
    background: rgba(255,255,255,0.1);
    color: white;
}

.draggable {
    cursor: move;
    position: relative; /* Start as relative for initial layout */
}

#resetLayout {
    background-color: #ff0000;
    color: white;
    border: none;
    cursor: pointer;
    padding: 10px 20px;
    margin-top: 20px;
    border-radius: 5px;
    display: none; /* Initially hidden */
}

p {
    margin-bottom: 1rem;
    padding: 0 1rem;
}

p, h1, h2 {
    margin: 1rem;
    text-align: center;
}

/* what this code below will do is when the user taps onto another page it will fade in and out" */
.fade-effect {
    animation: fadeInEffect 2s ease-in-out forwards;
}

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

.fade-out {
    animation: fadeOutEffect 1s ease-in-out forwards;
}

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


@media screen and (min-width: 601px) {
    #volumeControl {
        width: 100%; 
        max-width: 600px; 
        margin: 0 auto; 
        padding: 10px; 
    }


    #volumeSlider {
        width: 80%; 
        margin: 10px auto;
    }

    .footer {
        padding: 10px 0;
        position: static;
        bottom: 0;
        left: 0;
        width: 100%;
        text-align: center;
        margin-top: 20px;
    }

    .content-container {
        height: auto; 
        padding: 40px;
    }

    .inner-container {
        justify-content: flex-start; 
        padding: 20px 40px; 
    }
}

/* Media Queries for Responsive Design */
@media screen and (max-width: 600px) {
    #toggleChristmas {
        font-size: 14px; 
        padding: 10px;
        margin-bottom: 10px; 
    }

    #volumeControl {
        display: block;
        width: 90%; 
        margin: 0 auto; 
        padding: 10px;
    }

    #volumeSlider {
        width: 100%; 
    }
    
    .footer {
        padding: 10px 0;
        position: static;
        bottom: 0;
        left: 0;
        width: 100%;
        text-align: center;
        margin-top: 20px;
    }

    .content-container {
        height: auto; 
        padding: 40px;
    }

    .inner-container {
        justify-content: flex-start; 
        padding: 20px 40px; 
    }
}


/* Responsive design: Adjust font size on smaller screens */
@media (max-width: 768px) {
    h1 {
        font-size: 1.5em; /* Smaller font size on smaller devices */
    }
}

/* Further responsive adjustments for very small screens */
@media (max-width: 480px) {
    h1 {
        font-size: 1.2em; /* Even smaller font size for very small devices */
    }
}