﻿*, *::before, *::after {
    font-family: Arial, Helvetica, sans-serif !important;
    font-size: 1rem;
}

:root {
    --designWidth: 520px;
    --designHeight: 1200px;
}

body {
    display: flex;
    gap: 15px;
    justify-content: center;
    align-items: center;
    height: 100vh;
    width: 100vw;
    margin: 0 auto;
    background-color: #f4f4f9;
}

.flexContainer {
    position: absolute;
    transform-origin: center;
    max-width: var(--designWidth);
    max-height: var(--designHeight);
    width: var(--designWidth);
    height: var(--designHeight);
    display: flex;
    flex-direction: column;
    background: white;
    padding: 20px;
}

input, button, select, textarea {
    font-family: Arial, Helvetica, sans-serif !important;
    font-size: 1rem;
}



progress {
    max-width: 480px;
}

    /* Styles the track (background) */
    progress::-webkit-progress-bar {
        background-color: #e0e0e0;
        border-radius: 10px;
    }

    /* Styles the fill bar for WebKit browsers (Chrome, Safari, Edge) */
    progress::-webkit-progress-value {
        background-color: #3498db;
        border-radius: 10px;
        transition: width 0.3s ease; /* Smooth transition when value changes */
    }

    /* Styles the fill bar for Firefox */
    progress::-moz-progress-bar {
        background-color: #3498db;
        border-radius: 10px;
    }

.widget-container {
    width: 100%;
    max-width: 480px;
}

.inputContainer {
    display: flex;
    max-width: 480px;
    gap: 10px;
    padding: 20px 0px;
    border-radius: 8px;
    /*      box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1);*/
}

.inputIcon {
    align-content: center;
    align-items: stretch;
    display: flex;
}

#wordInput {
    padding: 12px 0 12px 12px;
    font-size: 16px;
    border: 1px solid #ccc;
    border-radius: 4px;
    width: 200px;
    outline: none;
    display: inline-block;
    align-items: center;
    flex: 1;
    min-width: 0;
}

/* Anchor the mic button inside the right edge of the input */
#micBtn {
    right: 12px;
    background: none;
    border: none;
    cursor: pointer; /* Provides clear interactive cue */
    color: #666;
    font-size: 16px;
    padding: 4px;
}

    /* Subtle focus state change */
    #micBtn:hover {
        color: #1a73e8;
    }

.vocabGroup {
    width: 100%;
    padding: 20px 0px;
}

button {
    padding: 12px 20px;
    font-size: 1em;
    border: none;
    border-radius: 4px;
    cursor: pointer;
    font-weight: bold;
    transition: background-color 0.3s ease;
    box-shadow: 0 4px 10px 0 rgba(0, 0, 0, 0.2);
}

#answer {
    box-shadow: 0 4px 10px 0 rgba(0, 0, 0, 0.2);
    margin-left: auto;
}

/* State-specific button classes */
.ready {
    background-color: #007bff;
    color: white;
}

.listening {
    background-color: #dc3545;
    color: white;
    animation: pulse 1.5s infinite;
}

@keyframes pulse {
    0% {
        opacity: 1;
    }

    50% {
        opacity: 0.6;
    }

    100% {
        opacity: 1;
    }
}

dialog {
    border: none;
    border-radius: 8px;
    padding: 24px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.15);
    max-width: 400px;
    width: 50%;
}

    /* Background Dimming & Blur */
    dialog::backdrop {
        background-color: rgba(0, 0, 0, 0.5);
        backdrop-filter: blur(4px);
    }

.errorContent {
    display: flex;
    flex-direction: column;
    gap: 16px;
}
