/**
 * استایل‌های فرم پیش مصاحبه
 * Pre Interview Form Styles
 */

.pre-interview-trigger-container {
    text-align: center;
}

.pre-interview-form .form-label {
    font-weight: 600;
    color: #495057;
    margin-bottom: 0.5rem;
    display: flex;
    align-items: center;
    gap: 8px;
}

.pre-interview-form .form-control,
.pre-interview-form .form-select {
    border-radius: 8px;
    border: 2px solid #e9ecef;
    padding: 12px 16px;
    font-size: 14px;
    transition: all 0.3s ease;
}

.pre-interview-form .form-control:focus,
.pre-interview-form .form-select:focus {
    box-shadow: 0 0 0 0.2rem rgba(0, 123, 255, 0.25);
    transform: translateY(-1px);
}

.pre-interview-form .invalid-feedback {
    display: block;
    font-size: 12px;
    color: #dc3545;
    margin-top: 5px;
}

.pre-interview-form .form-text {
    font-size: 12px;
    color: #6c757d;
    margin-top: 5px;
}

#pre-interview-audio-recorder-container {
    background: #ffffff;
    border-radius: 12px;
    padding: 1.5rem;
    border: 2px dashed #dee2e6;
    transition: all 0.3s ease;
}

#pre-interview-recording-controls button {
    padding: 10px 20px;
    border-radius: 25px;
    font-weight: 600;
    transition: all 0.3s ease;
    border: none;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

#stop-recording-pre-interview {
    background: linear-gradient(135deg, #ffc107 0%, #e0a800 100%);
    color: #212529;
}

#stop-recording-pre-interview:hover {
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(255, 193, 7, 0.3);
}

.recording-indicator {
    position: relative;
    display: inline-block;
    width: 12px;
    height: 12px;
}

.recording-dot {
    width: 12px;
    height: 12px;
    background-color: #dc3545;
    border-radius: 50%;
    animation: recording-pulse 1s infinite;
}

@keyframes recording-pulse {
    0% { 
        opacity: 1; 
        transform: scale(1); 
    }
    50% { 
        opacity: 0.5; 
        transform: scale(1.2); 
    }
    100% { 
        opacity: 1; 
        transform: scale(1); 
    }
}

#pre-interview-recording-time {
    font-family: 'Courier New', monospace;
    font-size: 18px;
    color: #dc3545;
    font-weight: bold;
}

#pre-interview-audio-preview {
    background: #d4edda;
    border: 1px solid #c3e6cb;
    border-radius: 8px;
    padding: 15px;
    margin-top: 10px;
}

#pre-interview-audio-player {
    border-radius: 6px;
    border: 1px solid #28a745;
    background-color: #f8fff9;
}

#pre-interview-audio-preview .btn {
    border-radius: 20px;
    padding: 6px 12px;
    font-size: 12px;
}

.pre-interview-table thead th {
    background-color: #e9ecef;
    color: #495057;
    font-weight: 600;
    font-size: 12px;
    padding: 0.5rem;
    vertical-align: middle;
    border-bottom: 2px solid #333;
}

.pre-interview-table tbody td {
    padding: 0.5rem;
    vertical-align: middle;
}

@media (max-width: 768px) {    
    #preInterviewModal .modal-body {
        padding: 1rem;
    }
    
    #preInterviewModal .modal-footer {
        padding: 1rem;
        flex-direction: column;
        gap: 10px;
    }
    
    #preInterviewModal .modal-footer .btn {
        width: 100%;
        justify-content: center;
    }
    
    #pre-interview-audio-recorder-container {
        padding: 1rem;
    }

    #pre-interview-trigger-btn {
        font-size: 12px;
    }
    
    #calls-accordion .call-item .accordion-button {
        font-size: 10px !important;
    }

    #calls-accordion .call-item span.text-muted {
        font-size: 8px !important;
    }

    .pre-interview-list-containe .table td, .table th {
        padding: 0.5rem 0.25rem;
        font-size: 0.85rem;
    }
    
    .pre-interview-list-containe .btn.fs-8 {
        padding: 0.25rem 0.5rem;
        font-size: 0.75rem;
    }
    
    .pre-interview-list-containe .badge.fs-7 {
        font-size: 0.7rem;
    }
    
    #mobile-filter-icon {
        transition: transform 0.3s ease;
    }
}

.accordion-close-btn {
    opacity: 0.8;
    transition: all 0.3s ease;
    font-size: 0.75rem;
}

.calls-audio-preview {
    margin-top: -10px;
}

.accordion-close-btn:hover {
    opacity: 1;
    background-color: rgba(108, 117, 125, 0.1) !important;
}

.accordion-close-btn-custom {
    opacity: 0.7;
    transition: all 0.3s ease;
    font-size: 0.9rem;
    background: transparent;
    border: none;
    color: #6c757d;
}

.accordion-close-btn-custom:hover {
    opacity: 1;
    color: #495057;
}

.accordion-no-arrow::after {
    display: none !important;
}

.no-after::after {
  background-image: none !important;
}

@media (max-width: 767.98px) {

    .pre-interview-list-containe .table td, .table th {
        padding: 0.5rem 0.25rem;
        font-size: 0.85rem;
    }
    
    .pre-interview-list-containe .btn.fs-8 {
        padding: 0.25rem 0.5rem;
        font-size: 0.75rem;
    }
}

/* استایل‌های bubble برای تاریخچه توضیحات (مثل پیام‌رسان) */
#descriptions-list .message-bubble-wrapper {
    max-width: 100%;
    margin-bottom: 1rem;
    align-items: flex-end;
    gap: 0.5rem;
}

/* آواتار کاربر */
#descriptions-list .user-avatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    object-fit: cover;
    flex-shrink: 0;
}

#descriptions-list .user-avatar-placeholder {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 1.2rem;
}

#descriptions-list .avatar-own {
    order: 2;
}

#descriptions-list .avatar-other {
    order: 1;
    background-color: #6c757d;
    color: #fff;
}

#descriptions-list .message-bubble {
    max-width: 75%;
    padding: 0.75rem 1rem;
    border-radius: 12px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.1);
    word-wrap: break-word;
}

/* bubble برای پیام‌های خود کاربر (سمت راست) */
#descriptions-list .bubble-own {
    background: linear-gradient(-135deg, rgb(140, 193, 222) 0%, rgb(217, 242, 255) 100%);
    color: var(--bs-dark);
    border-bottom-right-radius: 4px;
}

#descriptions-list .bubble-own .message-header .message-author {
    color: var(--bs-dark);
}

#descriptions-list .bubble-own .message-header .message-time {
    color: rgba(255, 255, 255, 0.7);
}

#descriptions-list .bubble-own .message-text {
    color: var(--bs-dark);
}

/* bubble برای پیام‌های دیگران (سمت چپ) */
#descriptions-list .bubble-other {
    background: linear-gradient(135deg, #eaeaea 0%, #fcfcfc 100%);;
    color: #212529;
    border-bottom-left-radius: 4px;
    border: 1px solid #999;
}

#descriptions-list .bubble-other .message-header .message-author {
    color: #495057;
}

#descriptions-list .bubble-other .message-header .message-time {
    color: #6c757d;
}

#descriptions-list .bubble-other .message-text {
    color: #212529;
}

#descriptions-list .message-header {
    display: flex;
    align-items: center;
    margin-bottom: 0.25rem;
}

#descriptions-list .message-author {
    font-size: 0.875rem;
}

#descriptions-list .message-time {
    font-size: 0.75rem;
}

#descriptions-list .message-text {
    font-size: 0.9rem;
    line-height: 1.4;
}

#descriptions-list .message-audio {
    margin-top: 0.5rem;
}

#initial-description-display .text-holder-description {
    padding: 0.5rem;
    border-radius: 8px;
    border: 1px solid #dee2e6;
    background: linear-gradient(135deg, #ececec 0%, #e7e7e7 100%);;
}

/* Responsive */
@media (max-width: 768px) {
    #descriptions-list .message-bubble {
        max-width: 85%;
        padding: 0.6rem 0.85rem;
    }
    
    #descriptions-list .user-avatar,
    #descriptions-list .user-avatar-placeholder {
        width: 35px;
        height: 35px;
        font-size: 1rem;
    }
    
    #descriptions-list .message-author {
        font-size: 0.8rem;
    }
    
    #descriptions-list .message-time {
        font-size: 0.7rem;
    }
    
    #descriptions-list .message-text {
        font-size: 0.85rem;
    }
}