/**
 * Voting System CSS
 * Modern, responsive Design für die Voting-Listen
 */

.voting-list {
    max-width: 1000px;
    margin: 0 auto;
    padding: 20px 0;
}

/* Liste Header */
.voting-list-header {
    margin-bottom: 30px;
    text-align: center;
    padding: 25px;
    background: #333;
    color: white;
    border-radius: 12px;
}

.voting-list-title {
    color: #fff !important;
	margin: 0;
    font-size: 28px;
    font-weight: 700;
}

.voting-list-description {
    margin: 0;
    font-size: 16px;
    opacity: 0.9;
    line-height: 1.5;
}

.voting-item {
    display: flex;
    align-items: flex-start;
    gap: 20px;
    padding: 25px;
    margin-bottom: 20px;
    background: #ffffff;
    border-radius: 12px;
    position: relative;
}

.voting-item-rank {
    flex-shrink: 0;
    width: 40px;
    height: 40px;
    background: #65513d;
    color: white;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: bold;
    font-size: 16px;
}

.voting-item-thumbnail {
    flex-shrink: 0;
    width: 80px;
    height: 80px;
    overflow: hidden;
    border-radius: 8px;
}

.voting-item-thumbnail img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.voting-item-content {
    flex: 1;
    min-width: 0;
}

.voting-item-title {
    margin: 0 0 10px 0;
    font-size: 20px;
    font-weight: 600;
    color: #2c3e50;
    line-height: 1.3;
}

.voting-item-description {
    margin: 0 0 10px 0;
    color: #666;
    font-size: 14px;
    line-height: 1.5;
}

.voting-item-meta {
    display: flex;
    gap: 10px;
    margin-bottom: 10px;
    flex-wrap: wrap;
}

.voting-item-category {
    display: inline-block;
    padding: 4px 12px;
    background: #f8f9fa;
    color: #495057;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

/* Kategorie-spezifische Farben */
.voting-item-category.category-feature {
    background: #d4edda;
    color: #155724;
}

.voting-item-category.category-improvement {
    background: #cce7ff;
    color: #004085;
}

.voting-item-category.category-bugfix {
    background: #f8d7da;
    color: #721c24;
}

.voting-item-category.category-design {
    background: #e2e3e5;
    color: #383d41;
}

.voting-item-priority {
    display: inline-block;
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.voting-item-priority.priority-low {
    background: #d1ecf1;
    color: #0c5460;
}

.voting-item-priority.priority-high {
    background: #fff3cd;
    color: #856404;
}

.voting-item-priority.priority-urgent {
    background: #f8d7da;
    color: #721c24;
    animation: urgent-pulse 2s infinite;
}

@keyframes urgent-pulse {
    0%, 100% { opacity: 1; }
    50% { opacity: 0.7; }
}

/* Prioritäts-spezifische Item-Styles */
.voting-item.priority-urgent {
    border-left: 4px solid #dc3545;
}

.voting-item.priority-high {
    border-left: 4px solid #ffc107;
}

.voting-item-category {
    display: inline-block;
    padding: 4px 12px;
    background: #f8f9fa;
    color: #495057;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.5px;
    margin-bottom: 10px;
}

.voting-item-content-text {
    color: #555;
    font-size: 14px;
    line-height: 1.6;
}

.voting-item-content-text p {
    margin-bottom: 10px;
}

.voting-item-actions {
    flex-shrink: 0;
    text-align: center;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 12px;
}

.vote-count {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 2px;
}

.vote-number {
    font-size: 24px;
    font-weight: bold;
    color: #2c3e50;
    line-height: 1;
}

.vote-text {
    font-size: 12px;
    color: #666;
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.vote-button {
    background: #8c1812;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    white-space: nowrap;
    min-width: 200px;
}

.vote-button:hover:not(:disabled) {
    background: #430704;
}

.vote-button:active:not(:disabled) {
    transform: translateY(0);
}

.vote-button.voted {
    background: #aaa;
    cursor: default;
}

.vote-button.voting-in-progress {
    background: #6c757d;
    cursor: wait;
}

.vote-button:disabled {
    opacity: 0.7;
    cursor: not-allowed;
    transform: none;
}

.login-to-vote {
    display: inline-block;
    background: #f8f9fa;
    color: #495057;
    border: 2px solid #dee2e6;
    padding: 10px 20px;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
    transition: all 0.3s ease;
    white-space: nowrap;
    min-width: 120px;
    text-align: center;
}

.login-to-vote:hover {
    background: #e9ecef;
    border-color: #adb5bd;
    color: #495057;
    text-decoration: none;
}

/* Voting Message Styles */
.voting-message {
    position: fixed;
    top: 20px;
    right: 20px;
    padding: 15px 25px;
    border-radius: 8px;
    font-weight: 500;
    z-index: 9999;
    max-width: 300px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.voting-message.success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.voting-message.error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

.voting-message.info {
    background: #d1ecf1;
    color: #0c5460;
    border: 1px solid #bee5eb;
}

.voting-disabled {
    display: inline-block;
    background: #6c757d;
    color: white;
    padding: 10px 20px;
    border-radius: 25px;
    font-size: 14px;
    font-weight: 600;
    white-space: nowrap;
    min-width: 120px;
    text-align: center;
    opacity: 0.7;
}

/* Responsive Design */
@media (max-width: 768px) {
    .voting-list-header {
        padding: 20px 15px;
        margin-bottom: 20px;
    }
    
    .voting-list-title {
        font-size: 24px;
    }
    
    .voting-list-description {
        font-size: 14px;
    }
@media (max-width: 768px) {
    .voting-item {
        flex-direction: column;
        align-items: stretch;
        gap: 15px;
        padding: 20px;
    }
    
    .voting-item-rank {
        align-self: flex-start;
        position: absolute;
        top: 15px;
        right: 15px;
    }
    
    .voting-item-thumbnail {
        width: 60px;
        height: 60px;
        align-self: flex-start;
    }
    
    .voting-item-actions {
        flex-direction: row;
        justify-content: space-between;
        align-items: center;
    }
    
    .vote-count {
        flex-direction: row;
        gap: 8px;
        align-items: baseline;
    }
    
    .vote-number {
        font-size: 20px;
    }
    
    .voting-message {
        position: relative;
        top: auto;
        right: auto;
        margin: 20px 0;
        max-width: none;
    }
}

@media (max-width: 480px) {
    .voting-list {
        padding: 10px;
    }
    
    .voting-item {
        padding: 15px;
        margin-bottom: 15px;
    }
    
    .voting-item-title {
        font-size: 18px;
        margin-right: 50px; /* Platz für Rank-Badge */
    }
    
    .vote-button,
    .login-to-vote {
        min-width: 100px;
        padding: 8px 16px;
        font-size: 13px;
    }
}

/* Accessibility Improvements */
.vote-button:focus,
.login-to-vote:focus,
.voting-item-rank:focus {
    outline: 2px solid #667eea;
    outline-offset: 2px;
}

/* Animation für Vote Count Updates */
@keyframes vote-count-update {
    0% { transform: scale(1); }
    50% { transform: scale(1.2); color: #28a745; }
    100% { transform: scale(1); }
}

.vote-number.updated {
    animation: vote-count-update 0.6s ease;
}

/* Loading State */
.voting-item.loading::after {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.8);
    display: flex;
    align-items: center;
    justify-content: center;
}

/* Hover Effects für bessere UX */
.voting-item-content:hover .voting-item-title {
    color: #667eea;
    transition: color 0.2s ease;
}