/* style.css */
@import url('https://fonts.googleapis.com/css2?family=Changa:wght@200..800&display=swap');

html, body {
    height: 100%;
    margin: 0;
}

body {
    direction: rtl;
    font-family: "Changa", serif;
    background-color: #101925;
    overflow: hidden;
}

#container {
    position: relative;
    width: 100%;
    height: 100%; /* Changed from 100vh to 100% */
    overflow: hidden;
}

#videoElement, #canvas {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    object-fit: cover;
}

#videoElement {
    position: absolute;
    top: 0;
    left: 0;
    width: 1px; /* Minimal size */
    height: 1px;
    opacity: 0; /* Invisible */
    z-index: -1; /* Send it behind other elements */
}

#logo {
    position: absolute;
    top: 10px;
    left: 10px;
    width: 180px;
    height: auto;
    z-index: 10;
}

#textOverlay {
    position: absolute;
    bottom: 100px; /* Increased bottom value */
    width: 100%;
    text-align: center;
    font-size: 1.2em;
    color: #44C0C0;
    z-index: 10;
}

#captureButton {
    color: white;
    font-family: "Changa", serif;
    background-color: #F26F63;
    border: 0.5px solid #F26F63;
    border-radius: 12px;
    position: absolute;
    bottom: 30px; /* Increased bottom value */
    left: 50%;
    transform: translateX(-50%);
    padding: 10px 20px;
    font-size: 1em;
    z-index: 10;
    cursor: pointer;
}

.modal {
    display: none;
    position: fixed;
    z-index: 20;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: auto;
    background-color: rgba(0,0,0,0.8);
}

.modal-content {
    position: relative;
    margin: auto;
    top: 10%;
    width: 80%;
    max-width: 500px;
    text-align: center;
}

#capturedImage {
    width: 100%;
    height: auto;
}

#closeModal {
    position: absolute;
    top: 10px;
    right: 20px;
    font-size: 2em;
    color: white;
    cursor: pointer;
}

#downloadButton {
    display: inline-block;
    margin: 20px auto;
    padding: 10px 20px;
    font-family: "Changa", serif;
    background-color: #F26F63;
    border: 0.5px solid #F26F63;
    color: white;
    text-decoration: none;
    font-size: 1em;
    border-radius: 12px;
}

@media (max-width: 600px) {
    #textOverlay {
        font-size: 1em;
        bottom: 90px; /* Adjusted for mobile */
    }
    #captureButton {
        bottom: 40px; /* Adjusted for mobile */
    }
    #logo {
        width: 190px;
    }
}
