/* Voice Search (ხმოვანი ძიება) Styles */

/* Floating Mobile Voice Search Button */
.voice-search-float-btn {
    position: fixed;
    bottom: 24px;
    right: 20px;
    z-index: 9999;
    display: flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #7B3FBE 0%, #C06BB0 100%);
    color: #ffffff;
    padding: 12px 18px;
    border-radius: 50px;
    box-shadow: 0 8px 25px rgba(123, 63, 190, 0.45);
    border: 2px solid rgba(255, 255, 255, 0.25);
    cursor: pointer;
    transition: all 0.3s cubic-bezier(0.4, 0, 0.2, 1);
    font-family: 'Plus Jakarta Sans', system-ui, -apple-system, sans-serif;
    font-weight: 600;
    font-size: 14px;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
}

.voice-search-float-btn:hover {
    transform: translateY(-3px) scale(1.03);
    box-shadow: 0 12px 30px rgba(123, 63, 190, 0.6);
}

.voice-search-float-btn:active {
    transform: translateY(0) scale(0.97);
}

.voice-search-icon-wrap {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.2);
}

.voice-search-float-btn.recording {
    background: linear-gradient(135deg, #e11d48 0%, #f43f5e 100%);
    box-shadow: 0 8px 25px rgba(225, 29, 72, 0.55);
    animation: voicePulse 1.5s infinite;
}

@keyframes voicePulse {
    0% {
        box-shadow: 0 0 0 0 rgba(225, 29, 72, 0.7);
    }
    70% {
        box-shadow: 0 0 0 16px rgba(225, 29, 72, 0);
    }
    100% {
        box-shadow: 0 0 0 0 rgba(225, 29, 72, 0);
    }
}

/* Modal Overlay for Voice Search Feedback */
.voice-search-modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.75);
    backdrop-filter: blur(8px);
    -webkit-backdrop-filter: blur(8px);
    z-index: 10000;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

.voice-search-modal-overlay.active {
    opacity: 1;
    visibility: visible;
}

.voice-search-modal-card {
    background: #ffffff;
    border-radius: 24px;
    width: 100%;
    max-width: 440px;
    padding: 28px 24px;
    box-shadow: 0 20px 40px rgba(0, 0, 0, 0.25);
    text-align: center;
    position: relative;
    transform: translateY(20px) scale(0.95);
    transition: transform 0.3s ease;
}

.voice-search-modal-overlay.active .voice-search-modal-card {
    transform: translateY(0) scale(1);
}

.voice-mic-wave-container {
    width: 80px;
    height: 80px;
    margin: 0 auto 20px auto;
    border-radius: 50%;
    background: linear-gradient(135deg, #7B3FBE, #C06BB0);
    display: flex;
    align-items: center;
    justify-content: center;
    color: #ffffff;
    font-size: 32px;
    position: relative;
    box-shadow: 0 10px 25px rgba(123, 63, 190, 0.35);
    cursor: pointer;
    transition: transform 0.2s, background 0.3s;
    user-select: none;
}

.voice-mic-wave-container:hover {
    transform: scale(1.06);
}

.voice-mic-wave-container:active {
    transform: scale(0.95);
}

.voice-mic-wave-container.error {
    background: linear-gradient(135deg, #ef4444, #f87171);
    box-shadow: 0 10px 25px rgba(239, 68, 68, 0.35);
}

.voice-mic-wave-container.listening::before,
.voice-mic-wave-container.listening::after {
    content: '';
    position: absolute;
    inset: -10px;
    border-radius: 50%;
    border: 2px solid #7B3FBE;
    animation: waveExpand 2s cubic-bezier(0, 0.2, 0.8, 1) infinite;
    opacity: 0;
}

.voice-mic-wave-container.listening::after {
    animation-delay: 1s;
}

@keyframes waveExpand {
    0% {
        transform: scale(0.8);
        opacity: 1;
    }
    100% {
        transform: scale(1.5);
        opacity: 0;
    }
}

.voice-manual-input-wrap {
    display: flex;
    gap: 8px;
    margin-top: 16px;
}

.voice-manual-input {
    flex: 1;
    padding: 10px 14px;
    border: 1px solid #cbd5e1;
    border-radius: 12px;
    font-size: 14px;
    outline: none;
    font-family: inherit;
    transition: border-color 0.2s;
}

.voice-manual-input:focus {
    border-color: #7B3FBE;
}

.voice-manual-btn {
    background: linear-gradient(135deg, #7B3FBE, #C06BB0);
    color: #ffffff;
    border: none;
    padding: 10px 18px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    transition: opacity 0.2s;
}

.voice-manual-btn:hover {
    opacity: 0.9;
}

.voice-status-title {
    font-size: 20px;
    font-weight: 700;
    color: #1e293b;
    margin-bottom: 8px;
}

.voice-transcript-text {
    font-size: 15px;
    color: #475569;
    background: #f8fafc;
    border: 1px dashed #cbd5e1;
    padding: 14px 16px;
    border-radius: 14px;
    margin: 16px 0;
    min-height: 54px;
    display: flex;
    align-items: center;
    justify-content: center;
    font-style: italic;
    word-break: break-word;
}

.voice-parsed-tags {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    justify-content: center;
    margin-top: 12px;
}

.voice-tag {
    font-size: 12px;
    font-weight: 600;
    background: #f1f5f9;
    color: #4A1D7C;
    border: 1px solid #e2e8f0;
    padding: 4px 12px;
    border-radius: 20px;
    display: inline-flex;
    align-items: center;
    gap: 4px;
}

.voice-close-modal-btn {
    position: absolute;
    top: 16px;
    right: 16px;
    background: none;
    border: none;
    font-size: 22px;
    color: #94a3b8;
    cursor: pointer;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: background 0.2s, color 0.2s;
}

.voice-permission-guide {
    background: #f8fafc;
    border: 1px solid #e2e8f0;
    border-radius: 16px;
    padding: 14px;
    margin: 12px 0;
    text-align: left;
    font-size: 13px;
    color: #334155;
}

.voice-permission-guide ol {
    margin: 8px 0 0 18px;
    padding: 0;
    line-height: 1.6;
}

.voice-permission-guide li {
    margin-bottom: 4px;
}

.voice-reload-btn {
    width: 100%;
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
    border: none;
    padding: 10px 16px;
    border-radius: 12px;
    font-weight: 600;
    font-size: 14px;
    cursor: pointer;
    margin-top: 10px;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.voice-reload-btn:hover {
    opacity: 0.92;
}
