/* BSDS Plugin Styles */
#bsds-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 20px;
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background: #fdf2f8;
    border-radius: 12px;
    box-shadow: 0 4px 20px rgba(233, 30, 99, 0.1);
}

.bsds-header {
    text-align: center;
    margin-bottom: 30px;
    padding: 30px;
    background: linear-gradient(135deg, #E91E63, #AD1457);
    color: white;
    border-radius: 12px;
    box-shadow: 0 4px 15px rgba(233, 30, 99, 0.3);
}

.bsds-header h2 {
    margin: 0 0 10px 0;
    font-size: 28px;
    font-weight: 600;
}

.bsds-header p {
    margin: 0;
    font-size: 16px;
    opacity: 0.9;
}

.bsds-form {
    background: white;
    padding: 30px;
    border-radius: 12px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
}

.bsds-patient-info {
    margin-bottom: 30px;
    padding: 20px;
    background: #FCE4EC;
    border-radius: 8px;
    border-left: 4px solid #E91E63;
}

.bsds-patient-info label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: #E91E63;
    font-size: 16px;
}

.bsds-patient-info input {
    width: 100%;
    padding: 12px;
    border: 2px solid #F8BBD9;
    border-radius: 6px;
    font-size: 16px;
    transition: border-color 0.3s ease;
    box-sizing: border-box;
}

.bsds-patient-info input:focus {
    outline: none;
    border-color: #E91E63;
    box-shadow: 0 0 0 3px rgba(233, 30, 99, 0.1);
}

.bsds-instructions {
    margin-bottom: 30px;
    padding: 20px;
    background: #E8F5E8;
    border-radius: 8px;
    border-left: 4px solid #4CAF50;
}

.bsds-instructions h3 {
    margin: 0 0 10px 0;
    color: #2E7D32;
    font-size: 18px;
}

.bsds-instructions p {
    margin: 0;
    color: #2E7D32;
    line-height: 1.6;
}

.bsds-part1, .bsds-part2 {
    margin-bottom: 30px;
}

.bsds-part1 h3, .bsds-part2 h3 {
    color: #E91E63;
    margin-bottom: 20px;
    font-size: 20px;
    border-bottom: 2px solid #F8BBD9;
    padding-bottom: 10px;
}

.bsds-sentences {
    display: grid;
    gap: 15px;
}

.bsds-sentence {
    background: #FAFAFA;
    border: 1px solid #E0E0E0;
    border-radius: 8px;
    padding: 15px;
    transition: all 0.3s ease;
}

.bsds-sentence:hover {
    background: #FCE4EC;
    border-color: #F8BBD9;
    box-shadow: 0 2px 8px rgba(233, 30, 99, 0.1);
}

.sentence-label {
    display: flex;
    align-items: flex-start;
    cursor: pointer;
    font-size: 15px;
    line-height: 1.5;
    color: #333;
}

.sentence-label input[type="checkbox"] {
    display: none;
}

.checkmark {
    width: 20px;
    height: 20px;
    border: 2px solid #E0E0E0;
    border-radius: 4px;
    margin-right: 12px;
    margin-top: 2px;
    flex-shrink: 0;
    position: relative;
    transition: all 0.3s ease;
}

.sentence-label input[type="checkbox"]:checked + .checkmark {
    background: #E91E63;
    border-color: #E91E63;
}

.sentence-label input[type="checkbox"]:checked + .checkmark::after {
    content: '✓';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    color: white;
    font-weight: bold;
    font-size: 12px;
}

.sentence-text {
    flex: 1;
}

.sentence-label:hover .checkmark {
    border-color: #E91E63;
    background: rgba(233, 30, 99, 0.1);
}

.impact-question {
    background: #FFF3E0;
    padding: 25px;
    border-radius: 10px;
    border: 2px solid #FFE0B2;
}

.question-text {
    font-size: 16px;
    font-weight: 600;
    color: #E65100;
    margin-bottom: 20px;
    line-height: 1.5;
}

.impact-options {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.impact-option {
    display: flex;
    align-items: center;
    padding: 12px 15px;
    background: white;
    border: 2px solid #FFE0B2;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    font-size: 14px;
}

.impact-option:hover {
    background: #FCE4EC;
    border-color: #F8BBD9;
}

.impact-option input[type="radio"] {
    display: none;
}

.radio-mark {
    width: 18px;
    height: 18px;
    border: 2px solid #E0E0E0;
    border-radius: 50%;
    margin-right: 12px;
    position: relative;
    transition: all 0.3s ease;
}

.impact-option input[type="radio"]:checked + .radio-mark {
    border-color: #E91E63;
    background: #E91E63;
}

.impact-option input[type="radio"]:checked + .radio-mark::after {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 8px;
    height: 8px;
    background: white;
    border-radius: 50%;
}

.impact-option:has(input:checked) {
    background: #E8F5E8;
    border-color: #4CAF50;
    color: #2E7D32;
}

.option-text {
    flex: 1;
    line-height: 1.4;
}

.bsds-progress {
    margin-bottom: 30px;
    padding: 20px;
    background: #FCE4EC;
    border-radius: 8px;
    text-align: center;
}

.progress-bar {
    width: 100%;
    height: 8px;
    background: #F8BBD9;
    border-radius: 4px;
    overflow: hidden;
    margin-bottom: 10px;
}

.progress-fill {
    height: 100%;
    background: linear-gradient(90deg, #E91E63, #AD1457);
    width: 0%;
    transition: width 0.3s ease;
    border-radius: 4px;
}

.progress-text {
    margin: 0;
    color: #E91E63;
    font-weight: 600;
    font-size: 16px;
}

.bsds-submit {
    text-align: center;
}

#bsds-submit-btn {
    background: linear-gradient(135deg, #E91E63, #AD1457);
    color: white;
    border: none;
    padding: 15px 40px;
    font-size: 18px;
    font-weight: 600;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.3s ease;
    box-shadow: 0 4px 15px rgba(233, 30, 99, 0.3);
}

#bsds-submit-btn:hover:not(:disabled) {
    background: linear-gradient(135deg, #C2185B, #880E4F);
    transform: translateY(-2px);
    box-shadow: 0 6px 20px rgba(233, 30, 99, 0.4);
}

#bsds-submit-btn:disabled {
    background: #BDBDBD;
    cursor: not-allowed;
    transform: none;
    box-shadow: none;
}

.bsds-loading {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(233, 30, 99, 0.9);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 9999;
}

.loading-content {
    text-align: center;
    color: white;
    padding: 40px;
    background: rgba(255, 255, 255, 0.1);
    border-radius: 12px;
    backdrop-filter: blur(10px);
}

.loading-spinner {
    width: 50px;
    height: 50px;
    border: 4px solid rgba(255, 255, 255, 0.3);
    border-top: 4px solid white;
    border-radius: 50%;
    animation: spin 1s linear infinite;
    margin: 0 auto 20px;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.loading-content h3 {
    margin: 0 0 10px 0;
    font-size: 24px;
}

.loading-content p {
    margin: 0;
    opacity: 0.9;
    font-size: 16px;
}

/* Responsividade */
@media (max-width: 768px) {
    #bsds-container {
        margin: 10px;
        padding: 15px;
    }
    
    .bsds-header {
        padding: 20px;
    }
    
    .bsds-header h2 {
        font-size: 24px;
    }
    
    .bsds-form {
        padding: 20px;
    }
    
    .bsds-sentence {
        padding: 12px;
    }
    
    .sentence-label {
        font-size: 14px;
    }
    
    .impact-question {
        padding: 20px;
    }
    
    .impact-option {
        padding: 10px 12px;
        font-size: 13px;
    }
    
    #bsds-submit-btn {
        padding: 12px 30px;
        font-size: 16px;
    }
}

@media (max-width: 480px) {
    .bsds-sentences {
        gap: 10px;
    }
    
    .bsds-sentence {
        padding: 10px;
    }
    
    .sentence-label {
        font-size: 13px;
    }
    
    .checkmark {
        width: 18px;
        height: 18px;
        margin-right: 10px;
    }
    
    .radio-mark {
        width: 16px;
        height: 16px;
        margin-right: 10px;
    }
    
    .impact-options {
        gap: 8px;
    }
    
    .impact-option {
        padding: 8px 10px;
        font-size: 12px;
    }
}

/* Estados especiais */
.bsds-sentence.answered {
    background: #E8F5E8;
    border-color: #4CAF50;
}

.bsds-sentence.answered .sentence-label {
    color: #2E7D32;
}

/* Animações */
.bsds-sentence {
    animation: fadeInUp 0.3s ease-out;
}

@keyframes fadeInUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

/* Melhorias de acessibilidade */
.sentence-label:focus-within .checkmark,
.impact-option:focus-within .radio-mark {
    box-shadow: 0 0 0 3px rgba(233, 30, 99, 0.3);
}

/* Print styles */
@media print {
    #bsds-container {
        background: white;
        box-shadow: none;
    }
    
    .bsds-loading {
        display: none !important;
    }
    
    #bsds-submit-btn {
        display: none;
    }
}

