* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 20px;
}

.container {
    width: 100%;
    max-width: 800px;
}

/* Vote Container */
.vote-container {
    background: white;
    border-radius: 20px;
    padding: 40px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
}

.vote-title {
    font-size: 2rem;
    color: #333;
    text-align: center;
    margin-bottom: 40px;
    font-weight: 700;
}

/* Vote Form */
.vote-form {
    display: flex;
    flex-direction: column;
    gap: 35px;
}

.vote-section {
    display: flex;
    flex-direction: column;
    gap: 15px;
}

.vote-label {
    font-size: 1.1rem;
    color: #444;
    font-weight: 600;
}

/* Star Rating */
.star-rating-container {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.stars {
    display: flex;
    flex-direction: row-reverse;
    justify-content: flex-end;
    gap: 10px;
}

.stars input[type="radio"] {
    display: none;
}

.stars label.star {
    font-size: 3rem;
    color: #ddd;
    cursor: pointer;
    transition: all 0.2s ease;
    user-select: none;
}

.stars label.star:hover,
.stars label.star:hover ~ label.star,
.stars input[type="radio"]:checked ~ label.star {
    color: #ffd700;
    transform: scale(1.1);
}

.stars label.star:active {
    transform: scale(0.95);
}

/* Submit Button */
.submit-btn {
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    border: none;
    padding: 15px 40px;
    font-size: 1.1rem;
    font-weight: 600;
    border-radius: 50px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
    margin-top: 20px;
}

.submit-btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
}

.submit-btn:active {
    transform: translateY(0);
}

/* Success Container */
.success-container,
.already-voted-container,
.results-container {
    background: white;
    border-radius: 20px;
    padding: 60px 40px;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.3);
    text-align: center;
}

.success-icon,
.info-icon {
    font-size: 5rem;
    margin-bottom: 20px;
}

.success-icon {
    color: #4caf50;
}

.info-icon {
    color: #2196f3;
}

.success-container h1,
.already-voted-container h1,
.results-container h1 {
    font-size: 2rem;
    color: #333;
    margin-bottom: 15px;
}

.success-container p,
.already-voted-container p {
    font-size: 1.1rem;
    color: #666;
    margin-bottom: 10px;
}

/* Button */
.btn {
    display: inline-block;
    margin-top: 30px;
    padding: 12px 30px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    color: white;
    text-decoration: none;
    border-radius: 50px;
    font-weight: 600;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(102, 126, 234, 0.4);
}

.btn:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(102, 126, 234, 0.6);
}

/* Results */
.results-container {
    text-align: left;
}

.results-container h1 {
    text-align: center;
}

.total-votes {
    text-align: center;
    font-size: 1.1rem;
    color: #666;
    margin-bottom: 40px;
}

.results-section {
    margin-bottom: 30px;
}

.results-section h2 {
    font-size: 1.2rem;
    color: #444;
    margin-bottom: 10px;
}

.result-bar {
    width: 100%;
    height: 30px;
    background: #f0f0f0;
    border-radius: 15px;
    overflow: hidden;
    margin-bottom: 10px;
}

.result-fill {
    height: 100%;
    background: linear-gradient(90deg, #667eea 0%, #764ba2 100%);
    transition: width 0.5s ease;
}

.result-value {
    font-size: 1rem;
    color: #666;
}

.no-votes {
    text-align: center;
    font-size: 1.2rem;
    color: #999;
    margin: 40px 0;
}

/* Error Messages */
.error {
    color: #f44336;
    font-size: 0.9rem;
    margin-top: 5px;
}

/* Alert Messages */
.messages {
    margin-bottom: 20px;
}

.alert {
    padding: 15px 20px;
    border-radius: 10px;
    margin-bottom: 10px;
}

.alert-success {
    background: #d4edda;
    color: #155724;
    border: 1px solid #c3e6cb;
}

.alert-error {
    background: #f8d7da;
    color: #721c24;
    border: 1px solid #f5c6cb;
}

/* Responsive */
@media (max-width: 600px) {
    .vote-container,
    .success-container,
    .already-voted-container,
    .results-container {
        padding: 30px 20px;
    }

    .vote-title {
        font-size: 1.5rem;
    }

    .stars label.star {
        font-size: 2.5rem;
    }

    .submit-btn {
        width: 100%;
    }
}
