/* static/css/styles.css */

/* Importing Google Fonts */
@import url('https://fonts.googleapis.com/css2?family=Roboto:wght@400;500;700&display=swap');

body {
    font-family: 'Roboto', sans-serif;
    background-color: #121212;
    color: #FFFFFF;
    margin: 0;
    padding: 0;
    display: flex;
    height: 100vh;
    justify-content: center;
    align-items: center;
}

.container {
    background: #1E1E1E;
    padding: 1rem 1.2rem 2rem 1.2rem;
    border-radius: 12px;
    box-shadow: 0 0 20px rgba(0, 0, 0, 0.2);
    text-align: center;
    width: 90%;
    max-width: 500px;
}

h1 {
    margin-bottom: 0.5rem;
    font-weight: 700;
}

.subtitle {
    margin-bottom: 2rem;
    color: #B3B3B3;
    font-weight: 400;
}

form {
    width: 100%;
}

.input-group {
    display: flex;
    width: 100%;
}

.input-group input[type="text"] {
    flex: 1;
    padding: 0.75rem 1rem;
    margin-right: 0.5rem;
    border: 1px solid #333333;
    border-radius: 8px;
    background-color: #2A2A2A;
    color: #FFFFFF;
    font-size: 1rem;
}

.input-group input[type="text"]::placeholder {
    color: #777777;
}

.input-group input[type="text"]:focus {
    outline: none;
    border-color: #BB86FC;
}

.input-group button {
    padding: 0.75rem 1.5rem;
    border: none;
    background: #BB86FC;
    color: #FFFFFF;
    border-radius: 8px;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.3s;
}

.input-group button:hover {
    background: #9B63D9;
}

.message {
    margin-top: 1.5rem;
    padding: 1rem;
    border-radius: 8px;
    font-size: 1rem;
}

.message.success {
    background-color: #2A2A2A;
    color: #FFFFFF;
}

.message.success p {
    margin-top: .1rem;
}

.message.error {
    background-color: #CF6679;
    color: #FFFFFF;
}

.result {
    margin-top: 1rem;
    display: flex;
    justify-content: center;
    align-items: center;
}

.result input {
    flex: 1;
    padding: 0.75rem 1rem;
    border: 1px solid #333333;
    border-radius: 8px;
    background-color: #2A2A2A;
    color: #FFFFFF;
    margin-right: 0.5rem;
    font-size: 1rem;
}

.result button {
    padding: 0.75rem 1rem;
    border: none;
    background: #03DAC6;
    color: #000000;
    border-radius: 8px;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.3s;
}

.result button:hover {
    background: #01B3A5;
}

/* Modal Styles */
.modal {
    display: none; /* Hidden by default */
    position: fixed; /* Stay in place */
    z-index: 1001; /* Sit on top */
    left: 0;
    top: 0;
    width: 100%; /* Full width */
    height: 100%; /* Full height */
    overflow: auto; /* Enable scroll if needed */
    background-color: rgba(0, 0, 0, 0.6); /* Black with opacity */
}

.modal-content {
    background-color: #1E1E1E;
    margin: 25% auto; /* 10% from the top and centered */
    padding: 20px;
    border: 1px solid #888;
    width: 90%;
    max-width: 500px;
    border-radius: 12px;
    position: relative;
    box-shadow: 0 5px 15px rgba(0,0,0,0.3);
}

.close-button {
    color: #aaaaaa;
    float: right;
    font-size: 28px;
    font-weight: bold;
    position: absolute;
    top: 10px;
    right: 20px;
    cursor: pointer;
}

.close-button:hover,
.close-button:focus {
    color: #ffffff;
    text-decoration: none;
}

.modal-content h2 {
    margin-top: 0;
}

.modal-content .result {
    display: flex;
    margin-top: 1rem;
}

.modal-content .result input {
    flex: 1;
    padding: 0.75rem 1rem;
    margin-right: 0.5rem;
    border: 1px solid #333333;
    border-radius: 8px;
    background-color: #2A2A2A;
    color: #FFFFFF;
    font-size: 1rem;
}

.modal-content .result button {
    padding: 0.75rem 1rem;
    border: none;
    background: #03DAC6;
    color: #000000;
    border-radius: 8px;
    font-size: 1rem;
    cursor: pointer;
    transition: background 0.3s;
}

.modal-content .result button:hover {
    background: #01B3A5;
}

/* Adjust z-index for notifications to appear above modal */
.notification {
    z-index: 1002;
}

/* Notification Styles */
.notification {
    position: absolute;
    top: 20px;
    left: 50%;
    transform: translateX(-50%);
    background-color: #323232;
    color: #FFFFFF;
    padding: 1rem 1.5rem;
    border-radius: 8px;
    z-index: 1002;
    font-size: 1rem;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.3);
    animation: fadeInOut 3s ease forwards;
}

.notification.success {
    background-color: #2A2A2A;
}

.notification.error {
    background-color: #CF6679;
}

@keyframes fadeInOut {
    0% {
        opacity: 0;
        transform: translate(-50%, -20px);
    }
    10%, 90% {
        opacity: 1;
        transform: translate(-50%, 0);
    }
    100% {
        opacity: 0;
        transform: translate(-50%, -20px);
    }
}

@media (max-width: 600px) {
    .input-group {
        flex-direction: column;
    }

    .input-group input[type="text"] {
        margin-right: 0;
        margin-bottom: 1rem;
    }

    .result {
        flex-direction: column;
    }

    .result input {
        margin-right: 0;
        margin-bottom: 1rem;
        width: calc(100% - 1rem);
    }

    .modal-content .result {
        flex-direction: column;
    }

    .modal-content .result input,
    .modal-content .result button {
        width: 100%;
        margin-right: 0;
        margin-bottom: 1rem;
    }
}
