body {
    margin: 0;
    font-family: Arial, sans-serif;
    background: #f5f7fb;
    color: #1c2431;
}
.container {
    max-width: 1100px;
    margin: 0 auto;
    padding: 24px;
}
.site-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 24px;
}
.site-header h1 { margin: 0 0 6px; }
.site-header p { margin: 0; color: #5a6577; }
nav a, .button {
    display: inline-block;
    padding: 10px 14px;
    background: #0b63ce;
    color: #fff;
    border-radius: 8px;
    text-decoration: none;
    border: 0;
    cursor: pointer;
}
.button.secondary {
    background: #6b7a90;
}
.button.danger {
    background: #b91c1c;
}
nav a + a, .button + .button { margin-left: 8px; }
.card {
    background: #fff;
    border-radius: 14px;
    box-shadow: 0 4px 18px rgba(0,0,0,0.08);
    padding: 20px;
    margin-bottom: 20px;
}
.grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 16px;
}
label {
    display: block;
    font-weight: 700;
    margin-bottom: 6px;
}
input[type="text"], input[type="email"], input[type="password"], input[type="number"], textarea, select {
    width: 100%;
    box-sizing: border-box;
    padding: 10px 12px;
    border: 1px solid #cad3e0;
    border-radius: 8px;
    font: inherit;
}
textarea { min-height: 110px; }
.table-wrap { overflow-x: auto; }
table {
    width: 100%;
    border-collapse: collapse;
}
th, td {
    text-align: left;
    padding: 10px;
    border-bottom: 1px solid #e5eaf1;
    vertical-align: top;
}
.notice { padding: 12px 14px; border-radius: 8px; margin-bottom: 16px; }
.notice.success { background: #e8f7ea; color: #0c6a1b; }
.notice.error { background: #fde9e9; color: #9e1b1b; }
.small { color: #627086; font-size: 0.9rem; }
.question { margin-bottom: 22px; }
.actions { margin-top: 16px; }
.tight-actions { margin-top: 0; }
.code {
    font-family: Consolas, monospace;
    background: #f0f3f8;
    padding: 3px 6px;
    border-radius: 6px;
    word-break: break-all;
}
.inline-list label { font-weight: 400; margin-bottom: 8px; }


.section-head {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    gap: 16px;
    margin-bottom: 14px;
}
.option-builder, .preview-box {
    margin-top: 18px;
    border: 1px solid #dbe3ef;
    border-radius: 12px;
    padding: 16px;
    background: #f9fbfe;
}
.option-row {
    display: grid;
    grid-template-columns: 1fr auto;
    gap: 10px;
    margin-bottom: 10px;
}
.preview-question-card {
    border: 1px solid #dde6f2;
    border-radius: 12px;
    padding: 16px;
    background: #fff;
    margin-bottom: 14px;
}
.live-preview-card {
    margin-bottom: 0;
}
.survey-preview-list {
    display: grid;
    gap: 14px;
}
.sortable-card {
    cursor: move;
}
.sortable-card.dragging {
    opacity: 0.55;
    border-style: dashed;
}
.drag-handle {
    font-weight: 700;
    color: #0b63ce;
}
@media (max-width: 700px) {
    .section-head {
        flex-direction: column;
    }
    .option-row {
        grid-template-columns: 1fr;
    }
}


.stats-grid {
    align-items: stretch;
}
.stat-card {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-height: 120px;
}
.stat-label {
    font-size: 0.95rem;
    color: #627086;
    margin-bottom: 8px;
    font-weight: 700;
}
.stat-value {
    font-size: 2rem;
    font-weight: 700;
}
.stat-link {
    font-size: 0.95rem;
}
.chart-card h3 {
    margin-top: 0;
}
.chart-wrap {
    position: relative;
    width: 100%;
    height: 320px;
    margin: 16px 0 22px;
}
.text-answer-list {
    display: grid;
    gap: 12px;
    margin-top: 14px;
}
.text-answer-item {
    background: #f9fbfe;
    border: 1px solid #dbe3ef;
    border-radius: 10px;
    padding: 12px 14px;
}
.raw-response-card {
    margin-top: 16px;
    background: #fcfdff;
}
