/* Reset some basic styles */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

/* Top bar styling */
.top-bar {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    max-width: 1200px;
    padding: 10px 20px;
    margin: 0 auto;
    position: fixed;
    top: 0;
    left: 0;
    right: 0;
    z-index: 1000;
    background-color: transparent;
    height: 60px;
}

.logo {
    height: 40px;
    cursor: pointer;
}

.top-right-button {
    padding: 10px 15px;
    font-size: 16px;
    background-color: transparent;
    color: rgba(64, 64, 64, 0.8);
    border: 1px solid rgba(128, 128, 128, 0.2);
    border-radius: 5px;
    cursor: pointer;
    text-align: center;
    height: 40px;
    display: flex;
    align-items: center;
    transition: background-color 0.3s ease, color 0.3s ease;
}

.top-right-button:hover {
    background-color: rgba(128, 128, 128, 0.2);
    color: white;
}

/* Background section styling */
.background-section {
    background-image: url('./design/background_whitedigi.jpg');
    background-size: cover;
    background-position: center;
    height: 100vh;
    width: 100%;
    display: flex;
    flex-direction: column;
    justify-content: center; /* Centers items vertically */
    align-items: center;     /* Centers items horizontally */
    position: relative;      /* Establishes positioning context for absolute children */
    padding-top: 60px;       /* Prevents overlap with the fixed top bar */
}

/* Heading styling */
.background-section h1 {
    color: white; /* Ensure the headline is visible against the background */
    font-size: 48px;
    margin-bottom: 40px;
    text-align: center;
}

:root {
    /* You can adjust these variables to shift the image around */
    --head-page-image-offset-x: 50%;  /* Horizontal offset (negative moves it left, positive moves it right) */
    --head-page-image-offset-y: -5%; /* Vertical offset (negative moves it up, positive moves it down) */
}

/* Head Page Image Styling */
.head-page-image {
    max-width: 50%;         /* Scales the image down to 50% of its original size */
    height: auto;
    margin-bottom: 50px;     /* Adjust margin below the image */
    transform: translate(var(--head-page-image-offset-x), var(--head-page-image-offset-y));
}

/* Buttons Container */
.buttons-container {
    position: absolute;    /* Position relative to .background-section */
    bottom: 20%;           /* 20% from the bottom */
    left: 50%;             /* Center horizontally */
    transform: translateX(-50%); /* Perfectly center horizontally */
    display: flex;
    gap: 20px;             /* Space between buttons */
    justify-content: center;
    align-items: center;
    z-index: 20;           /* Ensure buttons are above other elements */
}

/* Styling for action buttons */
.action-button {
    padding: 15px 30px;
    font-size: 18px;
    color: #40E0D0; /* Turquoise text */
    background-color: rgba(255, 255, 255, 0.2); /* Semi-transparent background */
    border: 2px solid #40E0D0; /* Turquoise border */
    border-radius: 50px; /* Makes the button oval */
    cursor: pointer;
    transition: background-color 0.3s ease, transform 0.3s ease, color 0.3s ease, border-color 0.3s ease;
    backdrop-filter: blur(5px); /* Frosted glass effect */
    text-transform: uppercase;  /* Uppercase text */
}

.action-button:hover {
    background-color: rgba(64, 224, 208, 0.4); /* Turquoise with increased opacity on hover */
    color: #ffffff; /* White text on hover */
    border-color: #40E0D0; /* Maintain turquoise border */
    transform: scale(1.05); /* Slightly enlarge the button */
}

/* Reverting style for the Join Now button */
#join-now.action-button {
    background-color: #40E0D0; /* Turquoise background */
    color: #ffffff;           /* White text */
}

#join-now.action-button:hover {
    background-color: transparent; /* Turns transparent on hover */
    color: #40E0D0;                /* Turquoise text on hover */
}

/* Container for positioning the unused license image */
.unused-license-container {
    position: absolute; /* Position absolutely within .background-section */
    top: 35%;           /* 35% from the top */
    left: 10%;          /* 10% from the left */
    display: flex;
    justify-content: flex-start;
    align-items: center; /* Vertically center the image within the container */
    z-index: 15;         /* Ensure it's above the mailchimp card but below buttons */
}

/* Styling for the unused license image */
.unused-license-image {
    max-width: 300px;    /* Adjusted max-width for better visibility */
    height: auto;
    transform: scale(1); /* Remove scaling to maintain original size */
    transition: opacity 0.3s ease; /* Smooth transition for hover effect */
    position: relative;  /* Stack context for the overlay */
    animation: float 5s ease-in-out infinite; /* Floating animation */
}

/* Optional: Hover effect for the unused license image */
.unused-license-container:hover .unused-license-image {
    opacity: 0.8; /* Slightly reduce opacity on hover */
    animation-play-state: paused; /* Pause the animation */
}

/* Container for the mailchimp card */
.mailchimp-card-container {
    position: absolute;   /* Position relative to the background section */
    top: 38%;             /* Vertically center */
    right: 200px;         /* Space from the right edge */
    transform: translateY(-50%); /* Adjust for perfect centering */
    z-index: 10;          /* Ensure it’s below the buttons */
}

/* Styling for the mailchimp card image */
.mailchimp-card {
    width: 230px;  /* Adjust the size as needed */
    height: auto;  /* Maintain aspect ratio */
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1); /* Optional shadow for depth */
    animation: float 4s ease-in-out infinite; /* Floating animation */
}

/* Optional: Hover effect for the mailchimp card image */
.mailchimp-card:hover {
    animation-play-state: paused; /* Pause the animation */
}

/* Define the floating animation */
@keyframes float {
    0% {
        transform: translateY(0px);
    }
    50% {
        transform: translateY(-10px);
    }
    100% {
        transform: translateY(0px);
    }
}

@media (max-width: 768px) {
    .unused-license-container,
    .mailchimp-card-container {
        display: none; /* Hide floating cards on mobile */
    }

    .buttons-container {
        flex-direction: column;
        gap: 15px;
        bottom: 20%; /* Maintain 20% from the bottom */
    }

    /* Move the entire container further up */
    .head-page-container {
        margin-top: -100px; /* Adjust this negative value as needed */
    }

    .head-page-image {
        max-width: 60%;           /* Adjust head_page image size for smaller screens */
        margin: 0 auto 30px;        /* Center image and adjust bottom margin */
        display: block;
        transform: none;           /* Remove any transform overrides */
    }

    .background-section h1 {
        font-size: 36px; /* Reduce font size on smaller screens */
        margin-bottom: 250px; /* Adjust margin as needed */
    }
}


/* Feedback Messages */
#unsupported-os-message, #download-status {
    font-family: Arial, sans-serif;
    font-size: 1em;
}

#unsupported-os-message p, #download-status p {
    margin: 0;
    padding: 10px;
}

#unsupported-os-message {
    color: #ff0000; /* Red color for errors */
}

#download-status {
    color: #008000; /* Green color for success */
}
