@import url('https://fonts.googleapis.com/css2?family=Noto+Sans+KR:wght@400;500;700&display=swap');

:root {
    --primary-color: #4a90e2;
    --secondary-color: #f5f7fa;
    --text-color: #333;
    --border-color: #e0e0e0;
    --background-color: #ffffff;
    --hover-color: #357abd;
}

body {
    font-family: 'Noto Sans KR', sans-serif;
    background-color: var(--secondary-color);
    color: var(--text-color);
    margin: 0;
    padding: 20px;
    line-height: 1.6;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    background-color: var(--background-color);
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

h1 {
    font-size: 2em;
    color: var(--primary-color);
    text-align: center;
    margin-bottom: 10px;
    font-weight: 700;
}

h2 {
    font-size: 1.4em;
    color: var(--text-color);
    border-bottom: 2px solid var(--primary-color);
    padding-bottom: 10px;
    margin-top: 30px;
    margin-bottom: 20px;
    font-weight: 500;
}

.description {
    text-align: center;
    color: #666;
    margin-bottom: 30px;
}

.card {
    background-color: #fff;
    border: 1px solid var(--border-color);
    border-radius: 8px;
    padding: 20px;
    margin-bottom: 20px;
}

textarea#passage {
    width: 100%;
    padding: 10px;
    border-radius: 5px;
    border: 1px solid var(--border-color);
    font-size: 1em;
    box-sizing: border-box;
}

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

.option-group {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.option-group label {
    font-weight: 500;
}

.pos-group {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
    gap: 15px;
}

.pos-checkbox {
    display: flex;
    align-items: center;
    background-color: var(--secondary-color);
    padding: 10px;
    border-radius: 5px;
}

.pos-checkbox input[type="checkbox"] {
    margin-right: 10px;
}

button#generate-btn {
    width: 100%;
    padding: 15px;
    font-size: 1.2em;
    font-weight: 700;
    color: #fff;
    background-color: var(--primary-color);
    border: none;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s;
}

button#generate-btn:hover {
    background-color: var(--hover-color);
}

#result-container {
    margin-top: 30px;
}

.result-version {
    margin-bottom: 30px;
    padding: 20px;
    border: 1px solid var(--border-color);
    border-radius: 8px;
}

.result-version h3 {
    color: var(--primary-color);
    margin-top: 0;
}

.result-passage {
    font-size: 1.1em;
    line-height: 1.8;
}

.answer-key {
    background-color: var(--secondary-color);
    padding: 15px;
    margin-top: 15px;
    border-radius: 5px;
}

.answer-key h4 {
    margin: 0 0 10px 0;
}

.answer-list {
    list-style-type: none;
    padding-left: 0;
}

.hidden {
    display: none;
}

#loading {
    text-align: center;
    padding: 20px;
}

.spinner {
    border: 4px solid rgba(0, 0, 0, 0.1);
    width: 36px;
    height: 36px;
    border-radius: 50%;
    border-left-color: var(--primary-color);
    animation: spin 1s ease infinite;
    margin: 0 auto 10px;
}

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