* {
    box-sizing: border-box;
}

body {
    margin: 0;
    font-family: Arial, sans-serif;
    background: #f5f7fb;
    color: #111827;
}

main {
    width: 90%;
    max-width: 520px;
    margin: 120px auto;
    background: #ffffff;
    padding: 50px 40px;
    border-radius: 24px;
    text-align: center;
    box-shadow: 0 20px 50px rgba(0, 0, 0, 0.08);
}

h1 {
    margin-top: 0;
    margin-bottom: 24px;
    font-size: 36px;
    line-height: 1.3;
}

p {
    margin: 14px 0;
    font-size: 18px;
    line-height: 1.6;
    color: #4b5563;
}

button {
    width: 100%;
    margin-top: 28px;
    padding: 18px 20px;
    border: none;
    border-radius: 14px;
    background: #2563eb;
    color: white;
    font-size: 18px;
    font-weight: 700;
    cursor: pointer;
}

button:hover {
    background: #1d4ed8;
}

.hidden {
    display: none;
}

.step {
    color: #2563eb;
    font-size: 15px;
    font-weight: 700;
}

h2 {
    margin: 20px 0 30px;
    font-size: 28px;
    line-height: 1.4;
}

.answer-button {
    margin-top: 12px;
    background: #ffffff;
    color: #111827;
    border: 1px solid #d1d5db;
}

.answer-button:hover {
    background: #f3f4f6;
}

.progress {
    width: 100%;
    height: 8px;
    margin: 15px 0 30px;
    background: #e5e7eb;
    border-radius: 10px;
    overflow: hidden;
}

#progress-bar {
    width: 0;
    height: 100%;
    background: #2563eb;
    border-radius: 10px;
    transition: width 0.3s ease;
}

#answer-area {
    width: 100%;
}

.back-button {
    margin-top: 20px;
    background: transparent;
    color: #6b7280;
    border: none;
    font-size: 15px;
    font-weight: 500;
}

.back-button:hover {
    background: transparent;
    color: #2563eb;
}

.answer-button.selected {
    background: #eff6ff;
    border: 2px solid #2563eb;
    color: #2563eb;
}

#answer-area.grid-layout {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
}

#answer-area.grid-layout .answer-button {
    margin-top: 0;
}

.form-group {
    margin-top: 18px;
    text-align: left;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-size: 15px;
    font-weight: 700;
    color: #374151;
}

.form-group input {
    width: 100%;
    padding: 16px 18px;
    border: 1px solid #d1d5db;
    border-radius: 12px;
    font-size: 16px;
    outline: none;
}

.form-group input:focus {
    border-color: #2563eb;
}

.privacy-area {
    margin-top: 18px;
    text-align: left;
}

.privacy-label {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 14px;
    color: #4b5563;
}

.privacy-detail-button {
    width: auto;
    margin-top: 8px;
    padding: 0;
    background: transparent;
    color: #2563eb;
    font-size: 14px;
    font-weight: 600;
}

.privacy-detail-button:hover {
    background: transparent;
    color: #1d4ed8;
}

#submit-button {
    margin-top: 24px;
}

.result-grade {
    width: 72px;
    height: 72px;
    margin: 10px auto 20px;
    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 50%;
    background: #eff6ff;

    color: #2563eb;
    font-size: 32px;
    font-weight: 800;
}

.result-summary {
    margin-top: 24px;
    padding: 18px;

    background: #f8fafc;
    border-radius: 14px;

    text-align: left;
}

.result-summary p {
    margin: 7px 0;

    font-size: 14px;
    line-height: 1.5;
}

.result-notice {
    margin-top: 20px;

    font-size: 12px;
    line-height: 1.6;

    color: #9ca3af;
}

.success-icon {
    width: 74px;
    height: 74px;
    margin: 5px auto 20px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 50%;

    background: #2563eb;
    color: #ffffff;

    font-size: 36px;
    font-weight: 700;
}

.success-info {
    margin-top: 25px;
    padding: 18px 20px;

    background: #f8fafc;
    border-radius: 14px;

    color: #6b7280;
    font-size: 14px;
    line-height: 1.7;
}

#restart-button {
    margin-top: 25px;
}