body {
    margin: 0;
    height: 100vh;
    display: flex;
    justify-content: center;
    align-items: center;
    background: linear-gradient(to bottom, #CBC2C3, #95B7FE, #0176E0, #2A3D7E);
    overflow: hidden;
    color: black;
    font-family: ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, Segoe UI, Roboto, Helvetica Neue, Arial, Noto Sans, sans-serif;
    -webkit-font-smoothing: antialiased;
    box-sizing: border-box; /* Include borders in dimensions */
}

html, body {
    margin: 0;
    padding: 0;
    height: 100%; /* Ensure full height */
    width: 100%;
}

#cloud-container {
    position: absolute;
    top: 0; /* Ensure it starts at the very top of the page */
    left: 0;
    width: 100%;
    height: 100%; /* Ensure full height */
    overflow: hidden;
    pointer-events: none;
    z-index: -1;
    background-image: url('images/screenglare.png');
    background-size: 100% 100%; /* Ensure full width and height */
    background-position: top; /* Align the image at the top */
    background-repeat: no-repeat; /* Prevent tiling */
    margin: 0; /* Remove any unexpected margin */
    padding: 0; /* Remove any unexpected padding */
    box-sizing: border-box; /* Include padding in size calculations */
}

.cloud {
    position: absolute;
    opacity: 0.8;
    z-index: -1;
    transform: translateX(-100%);
    will-change: transform, opacity;
    filter: blur(1px);
    -webkit-filter: blur(1px); /* For Safari and older mobile browsers */
}

/* Window Pane Styling */
.window-panes {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    pointer-events: none;
    z-index: 1; /* Ensure it's above the background but below the poster */
    display: block; /* Ensure visibility */
}

.window-panes::before,
.window-panes::after {
    content: '';
    position: absolute;
    background: rgba(220, 220, 255, 1); /* Light translucent white for the window frame */
}

.window-panes::before {
    width: 100%; /* Full width of the window */
    height: 20px; /* Thickness of the horizontal line */
    top: 50%; /* Centered horizontally */
    left: 0;
    transform: translateY(-50%); /* Align with the center of the window */
}

.window-panes::after {
    width: 20px; /* Thickness of the vertical line */
    height: 100%; /* Full height of the window */
    top: 0;
    left: 50%; /* Centered vertically */
    transform: translateX(-50%); /* Align with the center of the window */
}

.poster {
    display: none;
    position: absolute;
    width: 90%;
    max-width: 400px;
    height: 70vh;
    padding: 20px;
    background: #E6E6E6;
    border-radius: 15px;
    text-align: left;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    color: #1a1a1a;
    overflow-wrap: break-word; /* Ensure text wraps properly */
    overflow: hidden; /* Avoid content overflow */
}

.poster h1 {
    margin: 0;
    font-size: 3rem;
    line-height: 1.1; /* Slightly increased for better readability */
    letter-spacing: -0.02em;
}

.poster p {
    font-size: 1.1rem; /* Reduced size for better fit */
    margin: 0;
    line-height: 1.2;
}

/* Mobile-Specific Adjustments */
@media (max-width: 768px) {
    #cloud-container {
        background-size: auto 100%; /* Ensure full coverage on mobile */
    }

    .cloud {
        filter: blur(1px); /* Reduce blur for smaller clouds */
        opacity: 0.9; /* Slightly more opaque on smaller screens */
    }

    .poster {
        width: 80%;
        height: 70vh;
        max-height: 80vh; /* Limit the height to prevent overflow */
        border-radius: 12px;
        padding: 15px;
    }

    .poster h1 {
        font-size: 2.5rem; /* Reduce title size for smaller screens */
    }

    .poster p {
        font-size: 1rem; /* Adjust text size for better readability */
    }
}
