@import url('../styles/globals.css');

.audio-lab-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 1.5rem;
    margin-bottom: 4rem;
}

.lab-card {
    background: var(--bg-color);
    border: none;
    border-radius: 20px;
    padding: 1.5rem;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02), 0 1px 2px rgba(0, 0, 0, 0.04);
    transition: all 0.3s ease;
    display: flex;
    flex-direction: column;
}

.lab-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--hover-shadow);
}

.lab-title {
    font-size: 0.85rem;
    font-weight: 700;
    color: var(--text-primary);
    margin-bottom: 1rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.lab-metric {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 0.8rem;
    font-size: 0.8rem;
    color: var(--text-secondary);
}

.lab-metric span:last-child {
    color: var(--text-primary);
    font-weight: 600;
    font-family: 'SF Mono', 'Monaco', 'Inconsolata', monospace;
}

.action-button {
    background: var(--surface-color);
    color: var(--text-primary);
    border: none;
    padding: 0.8rem 1.2rem;
    border-radius: 12px;
    font-size: 0.85rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    width: 100%;
    margin-top: auto;
    text-align: center;
    text-decoration: none;
}

.action-button:hover {
    background: #e5e5ea;
}

.action-button:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

canvas#mic-visualizer {
    width: 100%;
    height: 100px;
    background: #f5f5f7;
    border-radius: 12px;
    margin-bottom: 1rem;
}

.freq-slider-container {
    display: flex;
    align-items: center;
    gap: 8px;
    margin-bottom: 1rem;
}

input[type=range] {
    width: 100%;
    accent-color: var(--accent-blue);
}

.device-select {
    width: 100%;
    padding: 0.8rem 1rem;
    padding-right: 2.5rem;
    /* Space for arrow */
    border-radius: 10px;
    border: 1px solid var(--border-color);
    background-color: var(--surface-color);
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='16' height='16' viewBox='0 0 24 24' fill='none' stroke='%2386868b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpolyline points='6 9 12 15 18 9'%3E%3C/polyline%3E%3C/svg%3E");
    background-repeat: no-repeat;
    background-position: right 1rem center;
    background-size: 1rem;
    color: var(--text-primary);
    font-family: 'Plus Jakarta Sans', sans-serif;
    font-size: 0.85rem;
    font-weight: 500;
    line-height: 1.3;
    outline: none;
    appearance: none;
    -webkit-appearance: none;
    cursor: pointer;
    transition: all 0.2s cubic-bezier(0.4, 0, 0.2, 1);
    box-shadow: 0 1px 2px rgba(0, 0, 0, 0.03);
    margin-bottom: 0.8rem;
}

@keyframes blink {
    0% {
        opacity: 1;
    }

    50% {
        opacity: 0.4;
    }

    100% {
        opacity: 1;
    }
}