/* General Body Styling */
body {
    margin: 0;
    padding: 0;
    width: 100vw;
    height: 100vh;
    background: linear-gradient(to bottom, skyblue, whitesmoke);
    display: flex;
    justify-content: center;
    align-items: center;
    font-family: Arial, sans-serif;
    overflow: hidden;
}

/* Main Container */
#main {
    position: relative;
    width: 100%;
    height: 100%;
}

/* Fan Container */
#fan-container {
    position: absolute;
    top: 0;
    width: 100%;
    height: 100%; /* Occupy full screen */
    display: flex;
    flex-direction: column;
    justify-content: center; /* Center vertically */
    align-items: center; /* Center horizontally */
}

/* Stick Styling */
#stick {
    position: absolute;
    bottom: 0%; /* Position stick's top point at the center */
    width: 10px;
    height: 50vh;
    background-color: orange;
    z-index: 1;
}

/* Fan Styling */
#fan {
    width: 40%; /* Scale fan relative to the screen width */
    max-width: 300px; /* Limit fan size on larger screens */
    height: auto;
    animation: rotateFan linear infinite;
    z-index: 2;
}

/* Buttons Section */
#btns {
    position: absolute;
    bottom: 10px;
    display: flex;
    flex-direction: column;
    align-items: center; /* Center buttons horizontally */
    gap: 10px;
}

/* Button Styling */
button {
    border: none;
    border-radius: 10px;
    padding: 10px 20px;
    font-size: 16px;
    font-weight: bold;
    cursor: pointer;
    color: white;
    background-color: black;
    transition: background-color 0.3s ease, transform 0.2s ease;
    width: 300px;
    height: 100px;
    margin: 2px;
}

button:hover {
    background-color: gray;
    transform: scale(1.1);
}

/* Individual Button Colors */
#on {
    background-color: greenyellow;
}

#off {
    background-color: red;
}

#high {
    background-color: orange;
}

#med {
    background-color: yellow;
}

#low {
    background-color: lightblue;
}

/* Keyframes for Fan Rotation */
@keyframes rotateFan {
    100% {
        transform: rotate(360deg);
    }
}



@media (max-width: 860px) {
    #fan {
        width: 60%; 
    }

    #stick {
        width: 6px;
        height: 45%;
    }

    button {
        width: 250px;
        font-size: 12px;
        padding: 6px 12px;
    }

    #btns {
        bottom: 20px;
        gap: 6px;
    }
}

@media (max-width: 710px) {
    #fan {
        width: 50%;
    }

    #stick {
        width: 8px;
        height: 50%;
    }

    button {
        width: 150px;
        font-size: 14px;
        padding: 8px 16px;
    }

    #btns {
        bottom: 15px;
        gap: 8px;
    }
}

@media (max-width: 465px) {
    #fan {
        width: 50%;
    }

    #stick {
        width: 8px;
        height: 50%;
    }

    button {
        width: 100px;
        font-size: 14px;
        padding: 8px 16px;
    }

    #btns {
        bottom: 15px;
        gap: 8px;
    }
}