/* Messaging Styles - Extracted from messaging templates */

/* Character Counter */
.char-counter {
    font-size: 0.875rem;
    color: #6c757d;
}

.char-counter.warning {
    color: #ffc107;
}

.char-counter.danger {
    color: #dc3545;
}

/* File Upload Area */
.file-upload-area {
    border: 2px dashed #dee2e6;
    border-radius: 0.5rem;
    padding: 2rem;
    text-align: center;
    transition: all 0.3s;
    cursor: pointer;
}

.file-upload-area:hover {
    border-color: #667eea;
    background-color: #f8f9fa;
}

.file-upload-area.dragover {
    border-color: #667eea;
    background-color: #e7f1ff;
}

/* Status Badge */
.status-badge {
    min-width: 80px;
    display: inline-block;
}

/* Filter Card */
.filter-card {
    background-color: #f8f9fa;
}

/* Table Hover */
.table-hover tbody tr:hover {
    cursor: pointer;
    background-color: #f8f9fa;
}

/* Empty State */
.empty-state {
    padding: 3rem;
    text-align: center;
    color: #6c757d;
}

.empty-state i {
    font-size: 4rem;
    margin-bottom: 1rem;
}

/* Message Header */
.message-header {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    padding: 2rem;
    border-radius: 0.5rem 0.5rem 0 0;
}

/* Message Body */
.message-body {
    background-color: white;
    padding: 2rem;
    border: 1px solid #dee2e6;
    border-top: none;
    border-radius: 0 0 0.5rem 0.5rem;
}

/* Info Row */
.info-row {
    padding: 0.75rem 0;
    border-bottom: 1px solid #f0f0f0;
}

.info-row:last-child {
    border-bottom: none;
}

.info-label {
    font-weight: 600;
    color: #6c757d;
    min-width: 120px;
    display: inline-block;
}

/* Content Box */
.content-box {
    background-color: #f8f9fa;
    padding: 1.5rem;
    border-radius: 0.5rem;
    white-space: pre-wrap;
    word-wrap: break-word;
    line-height: 1.8;
}

/* Attachment Item (legacy) */
.attachment-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.75rem;
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 0.25rem;
    margin-bottom: 0.5rem;
    transition: all 0.3s;
}

.attachment-item:hover {
    background-color: #e9ecef;
    border-color: #667eea;
}

/* Attachment Item Wrapper - with Thumbnail Support */
.attachment-item-wrapper {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.75rem;
    background-color: #f8f9fa;
    border: 1px solid #dee2e6;
    border-radius: 0.5rem;
    margin-bottom: 0.75rem;
    transition: all 0.3s;
}

.attachment-item-wrapper:hover {
    background-color: #e9ecef;
    border-color: #667eea;
}

/* Thumbnail Container */
.attachment-thumbnail {
    flex-shrink: 0;
    width: 80px;
    height: 80px;
    min-width: 80px;
    max-width: 80px;
    min-height: 80px;
    max-height: 80px;
    border-radius: 0.375rem;
    overflow: hidden !important;
    background-color: #dee2e6;
    display: block;
    position: relative;
    clip-path: inset(0);
}

/* Center file icons only */
.attachment-thumbnail .file-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
}

/* Thumbnail Link */
.thumbnail-link {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    width: 80px;
    height: 80px;
    display: block;
    overflow: hidden;
}

.thumbnail-link img,
.thumbnail-link video {
    position: absolute;
    top: 0;
    left: 0;
    width: 80px !important;
    height: 80px !important;
    max-width: 80px !important;
    max-height: 80px !important;
    object-fit: cover;
}

/* Image Thumbnail */
.thumbnail-image {
    position: absolute !important;
    top: 0 !important;
    left: 0 !important;
    width: 80px !important;
    height: 80px !important;
    max-width: 80px !important;
    max-height: 80px !important;
    object-fit: cover !important;
    cursor: pointer;
}

.thumbnail-image:hover {
    opacity: 0.9;
}

/* Video Thumbnail */
.video-thumbnail {
    position: relative;
    width: 100%;
    height: 100%;
    display: block;
}

.thumbnail-video {
    position: absolute;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    max-width: 100%;
    max-height: 100%;
    object-fit: cover;
}

.video-play-icon {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-size: 2rem;
    text-shadow: 0 2px 4px rgba(0,0,0,0.5);
    pointer-events: none;
}

/* File Icon Fallback */
.file-icon {
    font-size: 2rem;
    color: #6c757d;
}

/* Attachment Info */
.attachment-info {
    flex-grow: 1;
    min-width: 0;
}

.attachment-info strong {
    display: block;
    word-break: break-all;
    margin-bottom: 0.25rem;
}

/* Rejection Box */
.rejection-box {
    background-color: #fff5f5;
    border: 1px solid #f5c6cb;
    border-radius: 0.5rem;
    padding: 1.5rem;
}

/* Timeline */
.timeline {
    position: relative;
    padding-left: 2rem;
}

.timeline-item {
    position: relative;
    padding-bottom: 1.5rem;
}

.timeline-item:before {
    content: '';
    position: absolute;
    left: -1.5rem;
    top: 0;
    width: 2px;
    height: 100%;
    background-color: #dee2e6;
}

.timeline-item:last-child:before {
    display: none;
}

.timeline-dot {
    position: absolute;
    left: -2rem;
    top: 0;
    width: 1rem;
    height: 1rem;
    border-radius: 50%;
    background-color: white;
    border: 3px solid #667eea;
}
