/* UI Modal Component Styles - Clean and consistent modal design */

/* Modal overlay - covers entire screen */
.modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.1), rgba(147, 51, 234, 0.1));
    backdrop-filter: blur(8px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 1000;
    opacity: 0;
    visibility: hidden;
    transition: opacity 0.3s ease, visibility 0.3s ease;
}

/* Show modal with animation */
.modal-overlay.modal-show {
    opacity: 1;
    visibility: visible;
}

/* Modal container */
.modal-container {
    background: #ffffff;
    border-radius: 20px;
    box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.25), 0 0 0 1px rgba(255, 255, 255, 0.05);
    max-width: 800px;
    width: 95%;
    max-height: 85vh;
    overflow: hidden;
    transform: scale(0.9) translateY(20px);
    transition: transform 0.3s ease;
    border: 1px solid rgba(229, 231, 235, 0.3);
    position: relative;
}

.modal-overlay.modal-show .modal-container {
    transform: scale(1) translateY(0);
}

/* Modal header */
.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 24px 24px 16px;
    border-bottom: 1px solid rgba(229, 231, 235, 0.2);
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.02), rgba(147, 51, 234, 0.02));
    position: relative;
}

.modal-header::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 2px;
    background: linear-gradient(135deg, var(--color-primary), var(--color-info));
}

.modal-title {
    margin: 0;
    font-size: 1.375rem;
    font-weight: 700;
    background: linear-gradient(135deg, var(--color-primary), var(--color-info));
    -webkit-background-clip: text;
    -webkit-text-fill-color: transparent;
    background-clip: text;
    line-height: 1.2;
}

.modal-close {
    background: none;
    border: none;
    font-size: 1.5rem;
    color: #9ca3af;
    cursor: pointer;
    padding: 8px;
    border-radius: 8px;
    transition: all 0.2s ease;
    line-height: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    width: 32px;
    height: 32px;
}

.modal-close:hover {
    color: #ef4444;
    background: rgba(239, 68, 68, 0.1);
    transform: scale(1.1);
}

/* Modal body */
.modal-body {
    padding: 20px;
    color: var(--text-secondary);
    line-height: 1.6;
    max-height: 70vh;
    overflow-y: auto;
    background: linear-gradient(135deg, rgba(248, 250, 252, 0.5), rgba(241, 245, 249, 0.5));
}

/* Modal body with form content */
.modal-body:has(.modal-form-content) {
    padding: 0;
    background: transparent;
}

/* Ensure proper spacing for form content */
.modal-body {
    padding: 0;
}

/* Scrollable modal content */
.modal-scrollable {
    max-height: 60vh;
    overflow-y: auto;
    padding-right: 8px;
}

/* Custom scrollbar for modal content */
.modal-scrollable::-webkit-scrollbar,
.modal-body::-webkit-scrollbar {
    width: 6px;
}

.modal-scrollable::-webkit-scrollbar-track,
.modal-body::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 3px;
}

.modal-scrollable::-webkit-scrollbar-thumb,
.modal-body::-webkit-scrollbar-thumb {
    background: #c1c1c1;
    border-radius: 3px;
}

.modal-scrollable::-webkit-scrollbar-thumb:hover,
.modal-body::-webkit-scrollbar-thumb:hover {
    background: #a8a8a8;
}

/* Modal footer */
.modal-footer {
    display: flex;
    align-items: center;
    justify-content: flex-end;
    gap: 12px;
    padding: 20px 24px 24px;
    border-top: 1px solid rgba(229, 231, 235, 0.2);
    background: linear-gradient(135deg, rgba(248, 250, 252, 0.8), rgba(241, 245, 249, 0.8));
}

/* Modal buttons */
.modal-btn {
    padding: 12px 20px;
    border-radius: 10px;
    font-size: 0.875rem;
    font-weight: 600;
    cursor: pointer;
    transition: all 0.2s ease;
    border: 1px solid transparent;
    min-width: 100px;
    position: relative;
    overflow: hidden;
}

.modal-btn-primary {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
    border: none;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
}

.modal-btn-primary:hover {
    background: linear-gradient(135deg, #dc2626, #b91c1c);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(239, 68, 68, 0.4);
}

.modal-btn-primary:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.2), 0 6px 16px rgba(239, 68, 68, 0.4);
}

.modal-btn-primary:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.3);
}

.modal-btn-secondary {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    color: white;
    border: none;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
}

.modal-btn-secondary:hover {
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(99, 102, 241, 0.4);
}

.modal-btn-secondary:focus {
    outline: none;
    box-shadow: 0 0 0 3px rgba(99, 102, 241, 0.2), 0 6px 16px rgba(99, 102, 241, 0.4);
}

.modal-btn-secondary:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(99, 102, 241, 0.3);
}

/* Responsive design */
@media (max-width: 640px) {
    .modal-container {
        width: 95%;
        margin: 20px;
    }
    
    .modal-header,
    .modal-body,
    .modal-footer {
        padding-left: 20px;
        padding-right: 20px;
    }
    
    .modal-title {
        font-size: 1.125rem;
    }
}

/* Enhanced Modal Content Styles */
.modal-success-content,
.modal-error-content,
.modal-info-content {
    text-align: center;
    padding: 16px 0;
}

.modal-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 72px;
    height: 72px;
    border-radius: 50%;
    margin: 0 auto 20px auto;
    position: relative;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.15);
}

.modal-icon::before {
    content: '';
    position: absolute;
    top: -4px;
    left: -4px;
    right: -4px;
    bottom: -4px;
    border-radius: 50%;
    background: linear-gradient(135deg, rgba(255, 255, 255, 0.2), rgba(255, 255, 255, 0.05));
    z-index: -1;
}

.modal-icon.success {
    background: linear-gradient(135deg, #10b981, #059669);
    color: white;
}

.modal-icon.error {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
}

.modal-icon.warning {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: white;
}

.modal-icon.info {
    background: linear-gradient(135deg, #3b82f6, #2563eb);
    color: white;
}

/* Modal content typography */
.modal-scrollable h3 {
    color: var(--text-primary);
    font-size: 1.125rem;
    font-weight: 700;
    margin: 24px 0 12px 0;
    line-height: 1.3;
}

.modal-scrollable h3:first-child {
    margin-top: 0;
}

.modal-scrollable p {
    margin: 0 0 16px 0;
    color: var(--text-secondary);
    line-height: 1.6;
    font-size: 0.95rem;
}

.modal-scrollable p:last-child {
    margin-bottom: 0;
}

.modal-scrollable strong {
    color: var(--text-primary);
    font-weight: 700;
}

/* Enhanced modal content boxes */
.modal-scrollable div[style*="background"] {
    border-radius: 12px !important;
    border-left: 4px solid transparent !important;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1) !important;
    margin: 16px 0 !important;
    padding: 16px !important;
}

/* Warning boxes */
.modal-scrollable div[style*="border-left: 4px solid var(--color-warning)"] {
    border-left-color: #f59e0b !important;
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.2), rgba(217, 119, 6, 0.15)) !important;
    border: 2px solid rgba(245, 158, 11, 0.3) !important;
    box-shadow: 0 6px 16px rgba(245, 158, 11, 0.2), inset 0 1px 0 rgba(255, 255, 255, 0.2) !important;
    position: relative !important;
}

/* Warning box glow effect */
.modal-scrollable div[style*="border-left: 4px solid var(--color-warning)"]::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.1), rgba(217, 119, 6, 0.05));
    border-radius: 12px;
    z-index: -1;
    filter: blur(4px);
}

/* Error boxes */
.modal-scrollable div[style*="border-left: 4px solid var(--color-error)"] {
    border-left-color: #ef4444 !important;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.15), rgba(220, 38, 38, 0.1)) !important;
    border: 2px solid rgba(239, 68, 68, 0.25) !important;
    box-shadow: 0 6px 16px rgba(239, 68, 68, 0.15), inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
    position: relative !important;
}

/* Error box glow effect */
.modal-scrollable div[style*="border-left: 4px solid var(--color-error)"]::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.08), rgba(220, 38, 38, 0.04));
    border-radius: 12px;
    z-index: -1;
    filter: blur(3px);
}

/* Info boxes */
.modal-scrollable div[style*="border-left: 4px solid var(--color-info)"] {
    border-left-color: #3b82f6 !important;
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.12), rgba(37, 99, 235, 0.08)) !important;
    border: 2px solid rgba(59, 130, 246, 0.2) !important;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
}

/* General info boxes without specific border colors */
.modal-scrollable div[style*="background: var(--color-bg)"] {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.15), rgba(37, 99, 235, 0.1)) !important;
    border-left: 4px solid #3b82f6 !important;
    border: 2px solid rgba(59, 130, 246, 0.2) !important;
    box-shadow: 0 4px 12px rgba(59, 130, 246, 0.1), inset 0 1px 0 rgba(255, 255, 255, 0.1) !important;
}

/* Enhanced text contrast in modal boxes */
.modal-scrollable div[style*="background"] p {
    color: #1f2937 !important;
    font-weight: 700 !important;
    margin: 0 !important;
    line-height: 1.5 !important;
    font-size: 0.95rem !important;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1) !important;
}

.modal-scrollable div[style*="background"] p[style*="color: var(--text-muted)"] {
    color: #374151 !important;
    font-size: 0.9rem !important;
    font-weight: 600 !important;
    line-height: 1.4 !important;
}

/* Specific styling for login error hint boxes */
.modal-scrollable div[style*="border-left: 4px solid var(--color-error)"] p {
    color: #dc2626 !important;
    font-weight: 700 !important;
    font-size: 0.95rem !important;
    line-height: 1.5 !important;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1) !important;
}

.modal-scrollable div[style*="border-left: 4px solid var(--color-error)"] p[style*="color: var(--text-muted)"] {
    color: #b91c1c !important;
    font-weight: 600 !important;
    font-size: 0.875rem !important;
    line-height: 1.4 !important;
}

/* Warning box specific styling */
.modal-scrollable div[style*="border-left: 4px solid var(--color-warning)"] p {
    color: #92400e !important;
    font-weight: 700 !important;
    font-size: 0.95rem !important;
    line-height: 1.5 !important;
    text-shadow: 0 1px 2px rgba(0, 0, 0, 0.1) !important;
}

.modal-scrollable div[style*="border-left: 4px solid var(--color-warning)"] p[style*="color: var(--text-muted)"] {
    color: #a16207 !important;
    font-weight: 600 !important;
    font-size: 0.875rem !important;
    line-height: 1.4 !important;
}

/* Custom warning icon */
.modal-scrollable div[style*="border-left: 4px solid var(--color-warning)"] p::before {
    content: "";
    display: inline-block;
    width: 16px;
    height: 16px;
    margin-right: 8px;
    vertical-align: middle;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23f59e0b'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M12 9v2m0 4h.01m-6.938 4h13.856c1.54 0 2.502-1.667 1.732-2.5L13.732 4c-.77-.833-1.964-.833-2.732 0L3.732 16.5c-.77.833.192 2.5 1.732 2.5z'/%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
}

/* Custom search/info icon for other boxes */
.modal-scrollable div[style*="background"]:not(div[style*="border-left: 4px solid var(--color-warning)"]) p::before {
    content: "";
    display: inline-block;
    width: 16px;
    height: 16px;
    margin-right: 6px;
    vertical-align: middle;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%233b82f6'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z'/%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
}

/* Custom search icon for login error */
.modal-scrollable div[style*="border-left: 4px solid var(--color-error)"] p::before {
    content: "";
    display: inline-block;
    width: 16px;
    height: 16px;
    margin-right: 6px;
    vertical-align: middle;
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23ef4444'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z'/%3E%3C/svg%3E");
    background-size: contain;
    background-repeat: no-repeat;
}

/* Custom icon classes for auth.js */
.custom-icon {
    display: inline-block;
    width: 16px;
    height: 16px;
    margin-right: 6px;
    vertical-align: middle;
    background-size: contain;
    background-repeat: no-repeat;
}

.custom-icon.info-icon {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%233b82f6'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M13 16h-1v-4h-1m1-4h.01M21 12a9 9 0 11-18 0 9 9 0 0118 0z'/%3E%3C/svg%3E");
}

.custom-icon.search-icon {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%23ef4444'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M21 21l-6-6m2-5a7 7 0 11-14 0 7 7 0 0114 0z'/%3E%3C/svg%3E");
}

.custom-icon.email-icon {
    background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' fill='none' viewBox='0 0 24 24' stroke='%233b82f6'%3E%3Cpath stroke-linecap='round' stroke-linejoin='round' stroke-width='2' d='M3 8l7.89 5.26a2 2 0 002.22 0L21 8M5 19h14a2 2 0 002-2V7a2 2 0 00-2-2H5a2 2 0 00-2 2v10a2 2 0 002 2z'/%3E%3C/svg%3E");
}

/* Modal Content Styling */
.modal-error-content,
.modal-success-content,
.modal-warning-content,
.modal-info-content,
.modal-form-content {
    text-align: center;
}

.modal-form-content {
    text-align: left;
    max-height: 60vh;
    overflow-y: auto;
    padding: 48px;
    margin: -48px;
    padding-bottom: 100px;
    box-sizing: border-box;
}

/* Custom scrollbar for modal form content */
.modal-form-content::-webkit-scrollbar {
    width: 6px;
}

.modal-form-content::-webkit-scrollbar-track {
    background: rgba(0, 0, 0, 0.1);
    border-radius: 3px;
}

.modal-form-content::-webkit-scrollbar-thumb {
    background: rgba(239, 68, 68, 0.3);
    border-radius: 3px;
}

.modal-form-content::-webkit-scrollbar-thumb:hover {
    background: rgba(239, 68, 68, 0.5);
}

.modal-form-content .form-group {
    margin-bottom: 28px;
    padding: 0 12px;
}

.modal-form-content .form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 28px;
    margin-bottom: 28px;
    padding: 0 12px;
}

@media (max-width: 768px) {
    .modal-container {
        max-width: 95%;
        width: 95%;
        margin: 20px;
    }
    
    .modal-form-content {
        padding: 32px;
        margin: -32px;
    }
    
    .modal-form-content .form-row {
        grid-template-columns: 1fr;
        gap: 20px;
    }
    
    .modal-form-content .form-group {
        padding: 0 8px;
    }
    
    .modal-form-content .form-row {
        padding: 0 8px;
    }
}

@media (max-width: 640px) {
    .modal-container {
        max-width: 98%;
        width: 98%;
        margin: 10px;
    }
    
    .modal-form-content {
        padding: 24px;
        margin: -24px;
    }
}

.modal-form-content .form-group label {
    display: block;
    margin-bottom: 10px;
    font-weight: 600;
    color: #374151;
    font-size: 0.9rem;
    letter-spacing: 0.025em;
}

.modal-form-content .form-group input,
.modal-form-content .form-group textarea,
.modal-form-content .form-group select {
    width: 100%;
    padding: 16px 20px;
    border: 2px solid rgba(229, 231, 235, 0.6);
    border-radius: 12px;
    background: #ffffff;
    color: var(--text-primary);
    font-size: 0.9rem;
    transition: all 0.3s ease;
    box-sizing: border-box;
    font-weight: 400;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.modal-form-content .form-group input:focus,
.modal-form-content .form-group textarea:focus,
.modal-form-content .form-group select:focus {
    outline: none;
    border-color: var(--primary-color);
    box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.15), 0 4px 8px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.modal-form-content .form-group textarea {
    resize: vertical;
    min-height: 100px;
}

.modal-form-content .form-group small {
    display: block;
    margin-top: 8px;
    color: #6b7280;
    font-size: 0.8rem;
    line-height: 1.5;
    font-weight: 400;
}

.modal-form-content .error-message {
    color: #dc2626;
    font-size: 0.8rem;
    font-weight: 500;
    margin-top: 10px;
    padding: 10px 14px;
    background: rgba(239, 68, 68, 0.1);
    border: 1px solid rgba(239, 68, 68, 0.3);
    border-radius: 8px;
    display: none;
}

/* Task Detail Modal Styles */
.modal-task-details {
    text-align: left;
    max-height: 70vh;
    overflow-y: auto;
    padding: 0;
}

.task-detail-header {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    padding: 24px;
    background: linear-gradient(135deg, rgba(248, 250, 252, 0.8), rgba(241, 245, 249, 0.6));
    border-bottom: 1px solid rgba(229, 231, 235, 0.3);
}

.task-detail-image {
    flex-shrink: 0;
    width: 100px;
    height: 100px;
    border-radius: 16px;
    overflow: hidden;
    background: #f8fafc;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 2px solid rgba(229, 231, 235, 0.3);
    box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
}

.task-detail-thumbnail {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.3s ease;
}

.task-detail-thumbnail:hover {
    transform: scale(1.05);
}

.task-detail-placeholder {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
    height: 100%;
    color: #9ca3af;
    background: #f8fafc;
}

.task-detail-info {
    flex: 1;
    min-width: 0;
}

.task-detail-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: #1f2937;
    margin: 0 0 12px 0;
    line-height: 1.3;
}

.task-detail-meta {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
    align-items: center;
}

.reward-badge {
    font-size: 1.125rem;
    font-weight: 700;
    color: #059669;
    background: linear-gradient(135deg, rgba(5, 150, 105, 0.1), rgba(16, 185, 129, 0.1));
    padding: 8px 16px;
    border-radius: 12px;
    border: 1px solid rgba(5, 150, 105, 0.2);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.task-detail-content {
    padding: 24px;
}

.task-detail-section {
    margin-bottom: 24px;
}

.task-detail-section:last-child {
    margin-bottom: 0;
}

.section-title {
    font-size: 1rem;
    font-weight: 600;
    color: #374151;
    margin: 0 0 12px 0;
    padding-bottom: 8px;
    border-bottom: 2px solid rgba(239, 68, 68, 0.1);
    display: flex;
    align-items: center;
    gap: 8px;
}

.section-title::before {
    content: '';
    width: 4px;
    height: 16px;
    background: linear-gradient(135deg, var(--primary-color), var(--color-info));
    border-radius: 2px;
}

.task-detail-description {
    color: #6b7280;
    font-size: 0.9rem;
    line-height: 1.6;
    margin: 0;
    padding: 16px;
    background: rgba(248, 250, 252, 0.5);
    border-radius: 8px;
    border: 1px solid rgba(229, 231, 235, 0.3);
}

.task-detail-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
}

.detail-group {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.detail-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: rgba(248, 250, 252, 0.3);
    border-radius: 8px;
    border: 1px solid rgba(229, 231, 235, 0.2);
    transition: all 0.2s ease;
}

.detail-item:hover {
    background: rgba(248, 250, 252, 0.5);
    transform: translateX(2px);
}

.detail-label {
    font-weight: 600;
    color: #374151;
    font-size: 0.875rem;
    text-transform: uppercase;
    letter-spacing: 0.025em;
}

.detail-value {
    color: #6b7280;
    font-size: 0.875rem;
    font-weight: 500;
    text-align: right;
}

.image-url-container {
    padding: 16px;
    background: rgba(248, 250, 252, 0.3);
    border-radius: 8px;
    border: 1px solid rgba(229, 231, 235, 0.2);
}

.image-link {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    color: #3b82f6;
    text-decoration: none;
    font-weight: 500;
    font-size: 0.875rem;
    padding: 8px 12px;
    border-radius: 6px;
    background: rgba(59, 130, 246, 0.1);
    border: 1px solid rgba(59, 130, 246, 0.2);
    transition: all 0.2s ease;
}

.image-link:hover {
    background: rgba(59, 130, 246, 0.15);
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.email-list {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 200px;
    overflow-y: auto;
    padding: 16px;
    background: rgba(248, 250, 252, 0.3);
    border-radius: 8px;
    border: 1px solid rgba(229, 231, 235, 0.2);
}

.email-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px;
    background: #ffffff;
    border-radius: 6px;
    border: 1px solid rgba(229, 231, 235, 0.3);
    transition: all 0.2s ease;
}

.email-item:hover {
    background: rgba(59, 130, 246, 0.05);
    border-color: rgba(59, 130, 246, 0.2);
    transform: translateX(2px);
}

.email-item svg {
    color: #6b7280;
    flex-shrink: 0;
}

.email-item span {
    color: #374151;
    font-size: 0.875rem;
    font-weight: 500;
}

/* Responsive Design for Task Details */
@media (max-width: 768px) {
    .task-detail-header {
        flex-direction: column;
        align-items: center;
        text-align: center;
        gap: 16px;
    }
    
    .task-detail-image {
        width: 80px;
        height: 80px;
    }
    
    .task-detail-grid {
        grid-template-columns: 1fr;
        gap: 16px;
    }
    
    .task-detail-content {
        padding: 20px;
    }
    
    .task-detail-section {
        margin-bottom: 20px;
    }
}

@media (max-width: 480px) {
    .task-detail-content {
        padding: 16px;
    }
    
    .task-detail-header {
        padding: 20px;
    }
    
    .detail-item {
        flex-direction: column;
        align-items: flex-start;
        gap: 4px;
    }
    
    .detail-value {
        text-align: left;
    }
}

.modal-error-content h3,
.modal-success-content h3,
.modal-warning-content h3,
.modal-info-content h3 {
    margin: 16px 0 8px 0;
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--text-primary);
}

.modal-error-content p,
.modal-success-content p,
.modal-warning-content p,
.modal-info-content p {
    margin: 0 0 16px 0;
    color: var(--text-secondary);
    line-height: 1.5;
}

.modal-icon {
    width: 48px;
    height: 48px;
    margin: 0 auto 16px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
}

.modal-icon.error {
    background: linear-gradient(135deg, rgba(239, 68, 68, 0.1), rgba(220, 38, 38, 0.05));
    color: #dc2626;
}

.modal-icon.success {
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.1), rgba(5, 150, 105, 0.05));
    color: #059669;
}

.modal-icon.warning {
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.1), rgba(217, 119, 6, 0.05));
    color: #d97706;
}

.modal-icon.info {
    background: linear-gradient(135deg, rgba(59, 130, 246, 0.1), rgba(37, 99, 235, 0.05));
    color: #3b82f6;
}

/* Task Detail Modal Styling */
.task-detail-modal {
    max-width: 100%;
}

.task-detail-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 20px;
    gap: 16px;
}

.task-detail-title {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--text-primary);
    margin: 0;
    flex: 1;
}

.task-detail-reward {
    font-size: 1.25rem;
    font-weight: 700;
    color: var(--success-color);
    background: linear-gradient(135deg, rgba(16, 185, 129, 0.1), rgba(5, 150, 105, 0.05));
    padding: 8px 16px;
    border-radius: 12px;
    border: 1px solid rgba(16, 185, 129, 0.2);
    white-space: nowrap;
}

.task-detail-description {
    font-size: 1rem;
    line-height: 1.6;
    color: var(--text-secondary);
    margin-bottom: 20px;
}

.task-detail-instruction {
    background: rgba(59, 130, 246, 0.05);
    border: 1px solid rgba(59, 130, 246, 0.2);
    border-radius: 12px;
    padding: 16px;
    margin-bottom: 20px;
}

.task-detail-instruction h4 {
    font-size: 1rem;
    font-weight: 600;
    color: var(--text-primary);
    margin: 0 0 12px 0;
}

.instruction-content {
    color: var(--text-secondary);
    line-height: 1.5;
    white-space: pre-wrap;
}

.task-detail-meta {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 12px;
}

.meta-item {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 16px;
    background: rgba(248, 250, 252, 0.5);
    border-radius: 8px;
    border: 1px solid rgba(229, 231, 235, 0.3);
}

.meta-label {
    font-weight: 600;
    color: var(--text-primary);
    font-size: 0.875rem;
}

.meta-value {
    color: var(--text-secondary);
    font-size: 0.875rem;
    font-weight: 500;
}

.meta-value.difficulty-easy {
    color: #059669;
    font-weight: 600;
}

.meta-value.difficulty-medium {
    color: #d97706;
    font-weight: 600;
}

.meta-value.difficulty-hard {
    color: #dc2626;
    font-weight: 600;
}

.meta-value.status-available {
    color: #059669;
    font-weight: 600;
}

.meta-value.status-in-progress {
    color: #3b82f6;
    font-weight: 600;
}

.meta-value.status-pending-review {
    color: #d97706;
    font-weight: 600;
}

.meta-value.status-approved {
    color: #059669;
    font-weight: 600;
}

.meta-value.status-rejected {
    color: #dc2626;
    font-weight: 600;
}

.meta-value.status-completed {
    color: #059669;
    font-weight: 600;
}

.meta-value.status-expired {
    color: #dc2626;
    font-weight: 600;
}

.meta-value.status-ended {
    color: #6b7280;
    font-weight: 600;
}

/* Modal Form Styling - Consistent with auth pages */
.modal-form {
    margin: 0;
    padding: 0;
}

.modal-form .form-group {
    margin-bottom: 20px;
}

.modal-form label {
    display: block;
    margin-bottom: 8px;
    font-weight: 500;
    color: var(--text-primary);
    font-size: 0.875rem;
    text-align: left;
}

.modal-form input {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--color-border);
    border-radius: 8px;
    font-size: 0.875rem;
    background: var(--color-surface);
    color: var(--text-primary);
    transition: var(--transition-all);
    box-sizing: border-box;
    font-weight: 400;
}

.modal-form input::placeholder {
    color: var(--text-muted);
    font-weight: 400;
}

.modal-form input:focus {
    outline: none;
    border-color: var(--color-primary);
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.modal-form input.error {
    border-color: var(--color-error);
    box-shadow: 0 0 0 3px rgba(239, 68, 68, 0.1);
}

.modal-form .error-message {
    color: var(--color-error);
    font-size: 0.75rem;
    margin-top: 6px;
    font-weight: 500;
    text-align: left;
}

/* Rejection Modal Specific Styles */
.modal-warning-content {
    display: flex;
    align-items: flex-start;
    gap: 16px;
    padding: 20px;
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.08), rgba(217, 119, 6, 0.05));
    border: 2px solid rgba(245, 158, 11, 0.2);
    border-radius: 12px;
    margin-bottom: 24px;
    position: relative;
    overflow: hidden;
}

.modal-warning-content::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    height: 4px;
    background: linear-gradient(135deg, #f59e0b, #d97706);
}

.modal-warning-icon {
    flex-shrink: 0;
    width: 48px;
    height: 48px;
    background: linear-gradient(135deg, #f59e0b, #d97706);
    border-radius: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    color: white;
    box-shadow: 0 4px 12px rgba(245, 158, 11, 0.3);
    position: relative;
}

.modal-warning-icon::before {
    content: '';
    position: absolute;
    top: -2px;
    left: -2px;
    right: -2px;
    bottom: -2px;
    background: linear-gradient(135deg, rgba(245, 158, 11, 0.2), rgba(217, 119, 6, 0.1));
    border-radius: 14px;
    z-index: -1;
    filter: blur(4px);
}

.modal-warning-text {
    flex: 1;
    min-width: 0;
}

.modal-warning-title {
    font-size: 1.125rem;
    font-weight: 700;
    color: #92400e;
    margin: 0 0 8px 0;
    line-height: 1.3;
}

.modal-warning-description {
    font-size: 0.95rem;
    color: #a16207;
    line-height: 1.5;
    margin: 0;
    font-weight: 500;
}

/* Enhanced form styling for rejection modal */
.modal-form-content .form-group {
    margin-bottom: 24px;
    padding: 0 8px;
}

.modal-form-content .form-group label {
    display: block;
    margin-bottom: 12px;
    font-weight: 700;
    color: #374151;
    font-size: 0.95rem;
    letter-spacing: 0.025em;
    text-transform: uppercase;
    position: relative;
}

.modal-form-content .form-group label::after {
    content: '*';
    color: #ef4444;
    margin-left: 4px;
    font-weight: 700;
}

.modal-form-content .form-group textarea {
    width: 100%;
    padding: 16px 20px;
    border: 2px solid rgba(229, 231, 235, 0.6);
    border-radius: 12px;
    background: #ffffff;
    color: #374151;
    font-size: 0.95rem;
    transition: all 0.3s ease;
    box-sizing: border-box;
    font-weight: 400;
    line-height: 1.5;
    resize: vertical;
    min-height: 120px;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
    font-family: inherit;
}

.modal-form-content .form-group textarea:focus {
    outline: none;
    border-color: #ef4444;
    box-shadow: 0 0 0 4px rgba(239, 68, 68, 0.15), 0 4px 8px rgba(0, 0, 0, 0.1);
    transform: translateY(-2px);
}

.modal-form-content .form-group textarea::placeholder {
    color: #9ca3af;
    font-weight: 400;
    font-style: italic;
}

.modal-form-content .form-group small {
    display: block;
    margin-top: 10px;
    color: #6b7280;
    font-size: 0.85rem;
    line-height: 1.4;
    font-weight: 500;
    padding: 8px 12px;
    background: rgba(59, 130, 246, 0.05);
    border-radius: 6px;
    border-left: 3px solid #3b82f6;
}

/* Enhanced button styling for rejection modal */
.modal-btn-primary {
    background: linear-gradient(135deg, #ef4444, #dc2626);
    color: white;
    border: none;
    box-shadow: 0 4px 12px rgba(239, 68, 68, 0.3);
    position: relative;
    overflow: hidden;
}

.modal-btn-primary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.modal-btn-primary:hover::before {
    left: 100%;
}

.modal-btn-primary:hover {
    background: linear-gradient(135deg, #dc2626, #b91c1c);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(239, 68, 68, 0.4);
}

.modal-btn-primary:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(239, 68, 68, 0.3);
}

.modal-btn-secondary {
    background: linear-gradient(135deg, #6366f1, #8b5cf6);
    color: white;
    border: none;
    box-shadow: 0 4px 12px rgba(99, 102, 241, 0.3);
    position: relative;
    overflow: hidden;
}

.modal-btn-secondary::before {
    content: '';
    position: absolute;
    top: 0;
    left: -100%;
    width: 100%;
    height: 100%;
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
    transition: left 0.5s ease;
}

.modal-btn-secondary:hover::before {
    left: 100%;
}

.modal-btn-secondary:hover {
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    transform: translateY(-2px);
    box-shadow: 0 6px 16px rgba(99, 102, 241, 0.4);
}

.modal-btn-secondary:active {
    transform: translateY(0);
    box-shadow: 0 2px 8px rgba(99, 102, 241, 0.3);
}

/* Loading state for buttons */
.modal-btn-primary:disabled,
.modal-btn-secondary:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

.modal-btn-primary:disabled:hover,
.modal-btn-secondary:disabled:hover {
    transform: none;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.1);
}

/* Spinning animation for loading states */
@keyframes spin {
    from {
        transform: rotate(0deg);
    }
    to {
        transform: rotate(360deg);
    }
}

.modal-btn-primary .btn-icon,
.modal-btn-secondary .btn-icon {
    animation: spin 1s linear infinite;
}

/* Light theme is now the default - no dark mode override needed */
