/* Estilos para el componente Text-to-Speech */
.tts-container {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    min-height: 100vh;
    padding: 0;
}

.header {
    text-align: center;
    padding: 40px 20px 30px;
    background: rgba(0, 0, 0, 0.1);
}

.title {
    font-size: 2.5rem;
    font-weight: 700;
    margin: 0 0 10px 0;
    text-shadow: 2px 2px 4px rgba(0, 0, 0, 0.3);
}

.title i {
    margin-right: 15px;
    color: #ffd700;
}

.subtitle {
    font-size: 1.1rem;
    opacity: 0.9;
    margin: 0;
}

.tts-content {
    max-width: 800px;
    margin: 0 auto;
    padding: 20px;
}

.input-section {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 30px;
    margin-bottom: 30px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.form-group {
    margin-bottom: 25px;
}

.form-label {
    display: block;
    font-weight: 600;
    margin-bottom: 8px;
    color: #fff;
    font-size: 1rem;
}

.form-label i {
    margin-right: 8px;
    color: #ffd700;
}

.form-select {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.9);
    color: #333;
    font-size: 1rem;
    transition: all 0.3s ease;
}

.form-select:focus {
    outline: none;
    border-color: #ffd700;
    box-shadow: 0 0 0 3px rgba(255, 215, 0, 0.3);
}

.form-select:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}

.form-textarea {
    width: 100%;
    padding: 16px;
    border: 2px solid rgba(255, 255, 255, 0.3);
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.9);
    color: #333;
    font-size: 1rem;
    resize: vertical;
    min-height: 120px;
    transition: all 0.3s ease;
    font-family: inherit;
}

.form-textarea:focus {
    outline: none;
    border-color: #ffd700;
    box-shadow: 0 0 0 3px rgba(255, 215, 0, 0.3);
}

.character-count {
    text-align: right;
    margin-top: 5px;
    opacity: 0.8;
}

.voice-preview {
    margin-top: 15px;
    padding: 15px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 8px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.preview-audio {
    width: 100%;
    margin-top: 10px;
    border-radius: 5px;
}

.generate-btn {
    width: 100%;
    padding: 16px 24px;
    background: linear-gradient(45deg, #ff6b6b, #ffd93d);
    border: none;
    border-radius: 10px;
    color: white;
    font-size: 1.1rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.3s ease;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 10px;
    text-transform: uppercase;
    letter-spacing: 1px;
}

.generate-btn:hover:not(:disabled) {
    transform: translateY(-2px);
    box-shadow: 0 8px 25px rgba(255, 107, 107, 0.4);
}

.generate-btn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
    transform: none;
}

.error-message {
    background: rgba(220, 53, 69, 0.9);
    color: white;
    padding: 15px 20px;
    border-radius: 8px;
    margin: 20px 0;
    display: flex;
    align-items: center;
    gap: 10px;
    font-weight: 500;
    border: 1px solid rgba(220, 53, 69, 0.3);
}

.results-section {
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(10px);
    border-radius: 15px;
    padding: 30px;
    border: 1px solid rgba(255, 255, 255, 0.2);
    margin-top: 30px;
}

.results-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 25px;
    flex-wrap: wrap;
    gap: 15px;
}

.results-header h3 {
    margin: 0;
    font-size: 1.5rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 10px;
}

.results-header h3 i {
    color: #ffd700;
}

.price-info {
    color: #ffd700;
    font-weight: 500;
}

.audio-player-container {
    display: flex;
    flex-direction: column;
    gap: 20px;
}

.audio-card {
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    padding: 20px;
    border: 1px solid rgba(255, 255, 255, 0.2);
}

.audio-info h4 {
    margin: 0 0 5px 0;
    font-size: 1.2rem;
    font-weight: 600;
    display: flex;
    align-items: center;
    gap: 8px;
}

.audio-info h4 i {
    color: #ffd700;
}

.audio-info p {
    margin: 0;
    opacity: 0.8;
    font-size: 0.95rem;
}

.audio-player {
    width: 100%;
    margin: 15px 0;
    border-radius: 5px;
}

.audio-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.action-btn {
    padding: 10px 16px;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    font-weight: 500;
    text-decoration: none;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    transition: all 0.3s ease;
}

.download-btn {
    background: #28a745;
    color: white;
}

.download-btn:hover {
    background: #218838;
    transform: translateY(-1px);
}

.copy-btn {
    background: #17a2b8;
    color: white;
}

.copy-btn:hover {
    background: #138496;
    transform: translateY(-1px);
}

.zip-download {
    text-align: center;
    margin-top: 15px;
}

.zip-btn {
    display: inline-flex;
    align-items: center;
    gap: 10px;
    padding: 12px 20px;
    background: #6f42c1;
    color: white;
    text-decoration: none;
    border-radius: 8px;
    font-weight: 500;
    transition: all 0.3s ease;
}

.zip-btn:hover {
    background: #5a339a;
    transform: translateY(-1px);
    color: white;
}

/* Responsividad */
@media (max-width: 768px) {
    .title {
        font-size: 2rem;
    }
    
    .tts-content {
        padding: 15px;
    }
    
    .input-section {
        padding: 20px;
    }
    
    .results-section {
        padding: 20px;
    }
    
    .results-header {
        flex-direction: column;
        align-items: flex-start;
    }
    
    .audio-actions {
        flex-direction: column;
    }
    
    .action-btn {
        justify-content: center;
    }
}

@media (max-width: 480px) {
    .title {
        font-size: 1.8rem;
    }
    
    .subtitle {
        font-size: 1rem;
    }
    
    .form-textarea {
        min-height: 100px;
    }
    
    .generate-btn {
        font-size: 1rem;
        padding: 14px 20px;
    }
}
