/* Microsoft Forms inspired styling */
.survey-container {
    max-width: 80%;
    margin: 0 auto;
    background: #ffffff;
    border-radius: 4px;
    box-shadow: 0 1.6px 3.6px rgba(0, 0, 0, 0.132), 0 0.3px 0.9px rgba(0, 0, 0, 0.108);
    overflow: hidden;
    border-radius:15px;
}

.survey-header {
    background: #0c6980;
    color: white;
    padding: 32px;
    text-align: center;
}

.survey-header h2 {
    margin: 0 0 8px 0;
    font-size: 28px;
    font-weight: 400;
    line-height: 1.2;
    color:#fff
}

.survey-description {
    margin: 0;
    font-size: 14px;
    opacity: 0.9;
}

.survey-form {
    padding: 24px 32px 32px;
}

.survey-question {
    margin-bottom: 32px;
}

.question-label {
    display: block;
    font-size: 14px;
    font-weight: 600;
    color: #323130;
    margin-bottom: 8px;
    line-height: 20px;
}

.required {
    color: #d13438;
    margin-left: 3px;
}

/* Text inputs */
.survey-textarea {
    width: 100%;
    min-height: 80px;
    padding: 8px 12px;
    border: 1px solid #0c6980;
    border-radius: 2px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    font-size: 14px;
    line-height: 20px;
    resize: vertical;
    transition: border-color 0.1s ease;
}

.survey-textarea:focus{
    outline: none;
    border-color: #0c6980;
    border-width: 2px;
    padding: 7px 11px;
}

.survey-textarea::placeholder {
    color: #0c6980;
}



/* Star Rating */
.rating-container {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 4px;
}

.star-label {
    cursor: pointer;
    margin: 0;
    display: inline-block;
}

.star-label input[type="radio"] {
    display: none;
}

.star {
    font-size: 30px;
    color: #d2d0ce;
    transition: color 0.1s ease;
    user-select: none;
}

.star:hover,
.star.hovered {
    color: #ffb900;
}

.star.selected {
    color: #ffb900;
}

.rating-text {
    font-size: 12px;
    color: #605e5c;
    margin-left: 12px;
    flex-basis: 100%;
    margin-top: 8px;
}


/* Checkboxes */
.checkbox-container {
    display: flex;
    flex-direction: column;
    gap: 0px;
}

.checkbox-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 14px;
    color: #323130;
    margin: 0;
    padding: 8px 0;
    position: relative;
}

.checkbox-label input[type="checkbox"] {
    display: none;
}

.checkmark {
    width: 20px;
    height: 20px;
    border: 1px solid #8a8886;
    border-radius: 2px;
    margin-right: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.1s ease;
    flex-shrink: 0;
}

.checkbox-label:hover .checkmark {
    border-color: #0078d4;
}

.checkmark.checked {
    background-color: #0078d4;
    border-color: #0078d4;
}

.checkmark.checked::after {
    content: '✓';
    color: white;
    font-size: 12px;
    font-weight: bold;
}

/* Submit Button */
.survey-actions {
    margin-top: 32px;
    padding-top: 16px;
    border-top: 1px solid #edebe9;
}

.submit-button {
    background: #0078d4;
    color: white;
    border: 1px solid #0078d4;
    border-radius: 2px;
    padding: 8px 24px;
    font-size: 14px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.1s ease;
    min-width: 80px;
}

.submit-button:hover {
    background: #106ebe;
    border-color: #106ebe;
}

.submit-button:active {
    background: #005a9e;
    border-color: #005a9e;
}

/* Success Message */
.survey-success {
    text-align: center;
    padding: 48px 32px;
    background: #f3f2f1;
}

.success-icon {
    width: 64px;
    height: 64px;
    border-radius: 50%;
    background: #107c10;
    color: white;
    font-size: 32px;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    margin: 0 auto 24px;
}

.survey-success h3 {
    font-size: 20px;
    font-weight: 400;
    color: #323130;
    margin: 0 0 8px 0;
}

.survey-success p {
    font-size: 14px;
    color: #605e5c;
    margin: 0 0 24px 0;
}

.account-link {
    display: inline-block;
    background: #0078d4;
    color: white;
    text-decoration: none;
    padding: 8px 24px;
    border-radius: 2px;
    font-size: 14px;
    font-weight: 600;
    transition: background-color 0.1s ease;
}

.account-link:hover {
    background: #106ebe;
    color: white;
    text-decoration: none;
}

/* Responsive Design */
@media (max-width: 768px) {
    .survey-container {
        /* margin: 0 16px; */
        max-width: none;
        width:100%;
    }
    
    .survey-header {
        padding: 24px 20px;
    }
    
    .survey-header h2 {
        font-size: 24px;
    }
    
    .survey-form {
        padding: 20px;
    }
    
    .survey-success {
        padding: 32px 20px;
    }
    
    /* .rating-container {
        flex-direction: column;
        align-items: flex-start;
    } */
    
    .rating-text {
        margin-left: 0;
        margin-top: 8px;
    }
}

/* Focus styles for accessibility */
.submit-button:focus,
.survey-textarea:focus,
.checkbox-label:focus-within .checkmark,
.star-label:focus-within .star {
    outline: 2px solid #0078d4;
    outline-offset: 2px;
}

/* Loading state */
.submit-button:disabled {
    background: #a19f9d;
    border-color: #a19f9d;
    cursor: not-allowed;
}

/* Radio Buttons */
.radio-container {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.radio-label {
    display: flex;
    align-items: center;
    cursor: pointer;
    font-size: 14px;
    color: #323130;
    margin: 0;
    padding: 8px 0;
    position: relative;
}

.radio-label input[type="radio"] {
    display: none;
}

.radio-button {
    width: 20px;
    height: 20px;
    border: 1px solid #8a8886;
    border-radius: 50%;
    margin-right: 12px;
    display: flex;
    align-items: center;
    justify-content: center;
    transition: all 0.1s ease;
    flex-shrink: 0;
    position: relative;
}

.radio-label:hover .radio-button {
    border-color: #0078d4;
}

.radio-button.selected {
    border-color: #0078d4;
    border-width: 2px;
}

.radio-button.selected::after {
    content: '';
    width: 10px;
    height: 10px;
    background-color: #0078d4;
    border-radius: 50%;
    display: block;
}

/* Error States */
.survey-question.error .question-label {
    color: #d13438;
}

.survey-question.error::after {
    content: 'This field is required';
    color: #d13438;
    font-size: 12px;
    display: block;
    margin-top: 4px;
}

.survey-textarea.error {
    border-color: #d13438;
    border-width: 2px;
    padding: 7px 11px;
}

.survey-question.error .radio-button,
.survey-question.error .checkmark {
    border-color: #d13438;
}

.survey-question.error .star {
    color: #d13438;
}