body { font-family: 'Cairo', sans-serif; margin: 0; background: #F5EEF8; }
.survey-page-wrap { max-width: 820px; margin: 0 auto; padding: 30px 20px 80px; }

/* Top Action Bar & Back Button */
.top-action-bar { display: flex; align-items: center; justify-content: space-between; margin-bottom: 24px; padding-bottom: 16px; border-bottom: 1.5px solid rgba(107, 46, 153, 0.15); }
.btn-back-top { display: inline-flex; align-items: center; gap: 8px; background: transparent; color: #3A1260; border: 2px solid #3A1260; padding: 8px 18px; border-radius: 12px; font-family: 'Cairo', sans-serif; font-size: 0.95rem; font-weight: 700; text-decoration: none; transition: all 0.2s; }
.btn-back-top:hover { background: #3A1260; color: #fff; transform: translateX(3px); }

.survey-intro-card { background: #9589B0; border: 1.5px solid #D9B96A; border-radius: 22px; padding: 28px 34px; margin-bottom: 30px; box-shadow: rgba(212, 160, 23, 0.2) 0px 7px 29px 0px; }
.survey-intro-card h1 { font-size: 1.4rem; font-weight: 900; color: #4a1d78; margin: 0 0 14px; }
.survey-intro-card p { color: #000014; font-weight: 500; font-size: 18px; line-height: 1.9; margin: 0 0 8px; }
.survey-intro-card p.intro-note { font-size: 18px; color: #000014; margin: 10px 0 0; }

/* Error Messages Styling */
.error-alert { background: #FDEDEC; border: 2px solid #E74C3C; border-radius: 12px; padding: 16px 20px; margin-bottom: 28px; text-align: right; }
.error-alert h4 { color: #C0392B; margin: 0 0 10px 0; font-weight: 800; }
.error-alert ul { color: #C0392B; font-weight: 600; margin: 0; padding-right: 20px; }

.survey-accordion { display: flex; flex-direction: column; gap: 24px; }
.q-item { background: #fff; border-radius: 16px; overflow: hidden; box-shadow: 0 1px 10px rgba(107, 46, 153, .06); border: 0.5px solid #3A1260; transition: border 0.3s; }

/* Error Highlighting */
.q-item.has-error { border: 2px solid #E74C3C !important; box-shadow: 0 0 12px rgba(231, 76, 60, 0.3); }
.q-item.has-error .q-header { background: #FDEDEC; color: #C0392B; }
.q-item.has-error .q-header .req-star { color: #E74C3C; }

.q-header { width: 100%; display: flex; align-items: center; justify-content: space-between; gap: 12px; padding: 16px 20px; background: #E1D5EC; border: none; cursor: pointer; font-family: 'Cairo', sans-serif; font-size: .96rem; font-weight: 800; color: #000014; text-align: start; transition: background .2s, color .2s; }
.q-header:hover { opacity: 0.9; }
.q-header .req-star { color: #c9862c; margin-inline-start: 3px; }
.q-header .chevron { flex-shrink: 0; color: #6B2E99; transition: transform .25s ease; }
.q-item.open .q-header .chevron { transform: rotate(180deg); }
.q-item.has-error .q-header .chevron { color: #C0392B; }

.q-body { max-height: 0; overflow: hidden; transition: max-height .3s ease; }
.q-body-inner { padding: 20px 22px 22px; background: #E1D5EC; }
.q-item.has-error .q-body-inner { background: #fdf5f5; }

.option-list { display: flex; flex-direction: column; }
.option-row { display: flex; align-items: center; gap: 10px; padding: 9px 2px; border-bottom: 1px solid rgba(107, 46, 153, 0.1); font-size: .9rem; color: #000014; font-weight: 600; }
.option-row:last-child { border-bottom: none; }
.option-row input[type="checkbox"], .option-row input[type="radio"] { -webkit-appearance: none; appearance: none; width: 24px; height: 24px; cursor: pointer; flex-shrink: 0; background: transparent; border: 2px solid #3A1260; box-sizing: border-box; }
.option-row input[type="checkbox"] { border-radius: 4px; }
.option-row input[type="radio"] { border-radius: 50%; }
.option-row input[type="checkbox"]:checked { background: #3A1260; }
.option-row input[type="checkbox"]:checked::after { content: "✓"; color: #fff; font-size: 16px; position: relative; display: flex; justify-content: center; align-items: center; }
.option-row input[type="radio"]:checked::before { content: ""; display: block; width: 12px; height: 12px; margin: 4px; border-radius: 50%; background: #3A1260; }
.option-row label { flex: 1; cursor: pointer; font-size: 16px; }
.other-input { display: none; margin-top: 10px; }
.other-input.show { display: block; }

.text-field { width: 95%; padding: 12px 16px; border: 1.5px solid transparent; border-radius: 10px; font-family: 'Cairo', sans-serif; font-size: .9rem; color: #2d1445; background: #fff; transition: border-color .2s, box-shadow .2s; }
.text-field:focus { outline: none; border-color: #873EBE; box-shadow: 0 0 0 3px rgba(135, 62, 190, .12); }
textarea.text-field { resize: vertical; min-height: 110px; }

.importance-table-wrap { overflow-x: auto; }
.importance-table { width: 100%; border-collapse: collapse; min-width: 560px; }
.importance-table th { font-size: .78rem; font-weight: 700; color: #000014; padding: 8px 6px; text-align: center; }
.importance-table td { padding: 10px 6px; text-align: center; border-top: 1px solid rgba(107, 46, 153, 0.1); }
.importance-table td.row-label { text-align: start; font-weight: 700; color: #3d1a5c; white-space: nowrap; font-size: .87rem; }
.importance-table input[type="radio"] { -webkit-appearance: none; appearance: none; width: 25px; height: 25px; margin: 0; cursor: pointer; border: 2px solid #3A1260; border-radius: 50%; background: transparent; position: relative; box-sizing: border-box; }
.importance-table input[type="radio"]:checked::after { content: ""; position: absolute; width: 13px; height: 13px; border-radius: 50%; background: #6B2E99; top: 4px; left: 4px; }

.survey-submit-wrap { margin-top: 32px; }
.btn-submit-survey { width: 100%; padding: 17px; background: #3A1260; color: #fff; border: none; border-radius: 14px; font-family: 'Cairo', sans-serif; font-size: 1.05rem; font-weight: 800; cursor: pointer; transition: opacity .2s, transform .15s, box-shadow .2s; display: flex; align-items: center; justify-content: center; gap: 10px; box-shadow: 0 4px 18px rgba(107, 46, 153, .30); }
.btn-submit-survey:hover { opacity: .92; transform: translateY(-2px); box-shadow: 0 8px 24px rgba(107, 46, 153, .35); }
.btn-submit-survey:active { transform: translateY(0); }

@media (max-width: 560px) { 
    .survey-intro-card { padding: 22px 20px; } 
    .q-header { padding: 14px 16px; font-size: .88rem; } 
    .q-body-inner { padding: 16px 16px 18px; } 
}