/* Ensure the background image covers the entire screen */
html, body {
    height: 100%;
    margin: 0;
    padding: 0;
}

body {
    background-image: url('/pictures/background.png');
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    background-attachment: fixed;
    font-family: Arial, Helvetica, sans-serif;
    background-color: black;
}

.language-switch {
    position: fixed;
    top: 20px;
    right: 20px;
    display: inline-flex;
    gap: 8px;
    padding: 8px;
    border-radius: 999px;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(6px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.25);
    z-index: 20;
}

.language-option {
    border: 0;
    border-radius: 999px;
    padding: 8px 14px;
    font-weight: 700;
    font-size: 14px;
    letter-spacing: 0.04em;
    color: white;
    background: transparent;
    cursor: pointer;
    transition: all 0.2s ease;
}

.language-option.is-active {
    color: black;
    background: linear-gradient(45deg, #ff4e00, #ff7300);
}

.language-option:hover {
    transform: translateY(-1px);
}

.home-button {
    position: fixed;
    top: 20px;
    left: 20px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 10px 16px;
    border-radius: 999px;
    text-decoration: none;
    font-weight: 700;
    font-size: 14px;
    letter-spacing: 0.04em;
    color: white;
    background: rgba(0, 0, 0, 0.55);
    backdrop-filter: blur(6px);
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.25);
    z-index: 20;
    transition: all 0.2s ease;
}

.home-button:hover {
    transform: translateY(-1px);
    background: rgba(0, 0, 0, 0.7);
}

.home-button:focus-visible {
    outline: 2px solid #ff7300;
    outline-offset: 3px;
}

/* Style for the logo */
#logo {
    display: block;
    margin: 20px auto;
    width: 700px;
}

/* Style for the form */
#formulaire {
    display: flex;
    justify-content: center;
    margin-top: 20px;
}

#formulaire div {
    display: flex;
    flex-direction: row;
    align-items: center;
}

/* Conteneur pour aligner correctement la zone de recherche */
#search-area {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    margin-top: 20px;
}

/* Champ de recherche */
#search-bar {
    padding: 15px;
    font-size: 20px;
    border: none;
    border-radius: 50px;
    width: 400px;
    box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.1);
    outline: none;
    transition: all 0.3s ease;
}
#search-bar:focus {
    box-shadow: 0px 4px 8px rgba(0, 0, 0, 0.3);
}

/* Bouton de recherche */
#search-button {
    background: linear-gradient(45deg, #ff4e00, #ff7300);
    border: none;
    border-radius: 50%;
    width: 50px;
    height: 50px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.2);
    transition: all 0.3s ease;
}
#search-button:hover {
    background: linear-gradient(45deg, #ff7300, #ff4e00);
}
#search-button::before {
    content: url("pictures/loupe.png");
    transform: scale(0.06);
    display: block;
}

#search-button:disabled {
    background: linear-gradient(45deg, #c0c0c0, #d3d3d3);
    cursor: not-allowed;
    box-shadow: none;
}

/* Style for the error message */
#error-message {
    display: flex;
    justify-content: center;
    margin-top: 7px;
    margin-bottom: 7px;
    color: red;
    font-size: 20px;
}

/* Bouton de téléchargement */
#download-area {
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
}
#download-button {
    margin-top: 7px;
    padding: 15px;
    width: 490px;
    font-size: 20px;
    font-weight: bold;
    color: black;
    background: linear-gradient(45deg, #ff4e00, #ff7300);
    border: none;
    border-radius: 50px;
    box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    transition: all 0.3s ease;
}
#download-button:disabled {
    background: linear-gradient(45deg, #c0c0c0, #d3d3d3);
    cursor: not-allowed;
    box-shadow: none;
}
#download-button:enabled:hover {
    background: linear-gradient(45deg, #ff7300, #ff4e00);
}

/* Bouton de copie du hash */
#copy-hash-button {
    margin-top: 10px;
    padding: 10px 20px;
    font-size: 16px;
    font-weight: bold;
    color: white;
    background: linear-gradient(45deg, #28a745, #20c997);
    border: none;
    border-radius: 25px;
    box-shadow: 0px 4px 6px rgba(0, 0, 0, 0.2);
    cursor: pointer;
    transition: all 0.3s ease;
}
#copy-hash-button:hover {
    background: linear-gradient(45deg, #20c997, #28a745);
}
#copy-hash-button.copied {
    background: linear-gradient(45deg, #6c757d, #868e96);
    cursor: default;
}
#copy-hash-button:disabled {
    background: linear-gradient(45deg, #6c757d, #868e96);
    cursor: not-allowed;
}

/* Media Queries pour rendre le site responsive */
@media (max-width: 768px) {
    .home-button {
        top: 12px;
        left: 12px;
        padding: 8px 12px;
        font-size: 13px;
    }

    .language-switch {
        top: 12px;
        right: 12px;
        padding: 6px;
    }

    .language-option {
        padding: 7px 12px;
        font-size: 13px;
    }

    #search-area {
        max-width: 90%;
    }

    #download-button {
        max-width: 90%;
    }

    #logo {
        display: block;
        margin: 10px auto;
        width: 400px;
    }
}

@media (max-width: 480px) {
    body {
        font-size: 16px;
    }

    .home-button {
        top: 10px;
        left: 10px;
        padding: 7px 11px;
    }

    #search-bar {
        padding: 10px;
    }

    #download-button {
        padding: 10px;
    }

    #logo {
        display: block;
        margin: 10px auto;
        width: 400px;
    }
}
