* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

body {
    font-family: 'Hiragino Sans', 'Yu Gothic', 'Meiryo', sans-serif;
    line-height: 1.6;
    color: #333;
    background-color: #f5f5f5;
    padding: 20px;
}

.container {
    max-width: 800px;
    margin: 0 auto;
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
}

h1 {
    text-align: center;
    color: #2c3e50;
    margin-bottom: 10px;
    font-size: 2.5em;
}

p {
    text-align: center;
    color: #7f8c8d;
    margin-bottom: 30px;
}

.input-section,
.options-section,
.convert-section,
.output-section {
    margin-bottom: 25px;
}

label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: #2c3e50;
}

textarea {
    width: 100%;
    padding: 12px;
    border: 2px solid #bdc3c7;
    border-radius: 5px;
    font-size: 14px;
    font-family: inherit;
    resize: vertical;
    min-height: 200px;
    transition: border-color 0.3s ease;
}

textarea:focus {
    outline: none;
    border-color: #3498db;
}

#outputText {
    background-color: #f8f9fa;
}

.options-section h3 {
    margin-bottom: 15px;
    color: #2c3e50;
    border-bottom: 2px solid #3498db;
    padding-bottom: 5px;
}

.checkbox-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 10px;
    margin-bottom: 20px;
}

.checkbox-grid label {
    display: flex;
    align-items: center;
    font-weight: normal;
    margin-bottom: 0;
    padding: 8px;
    border-radius: 5px;
    transition: background-color 0.2s ease;
    cursor: pointer;
}

.checkbox-grid label:hover {
    background-color: #ecf0f1;
}

.checkbox-grid input[type="checkbox"] {
    margin-right: 8px;
    transform: scale(1.2);
}

.control-buttons {
    display: flex;
    gap: 10px;
    margin-bottom: 20px;
}

.control-buttons button {
    padding: 8px 16px;
    border: 1px solid #bdc3c7;
    background: white;
    border-radius: 5px;
    cursor: pointer;
    font-size: 14px;
    transition: all 0.3s ease;
}

.control-buttons button:hover {
    background-color: #ecf0f1;
    border-color: #95a5a6;
}

.convert-section {
    text-align: center;
}

#convertBtn {
    background-color: #3498db;
    color: white;
    border: none;
    padding: 15px 40px;
    font-size: 18px;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

#convertBtn:hover {
    background-color: #2980b9;
}

#convertBtn:active {
    transform: translateY(1px);
}

.output-section {
    position: relative;
}

#copyBtn {
    margin-top: 10px;
    background-color: #27ae60;
    color: white;
    border: none;
    padding: 10px 20px;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s ease;
}

#copyBtn:hover {
    background-color: #219a52;
}

#copyBtn:disabled {
    background-color: #bdc3c7;
    cursor: not-allowed;
}

footer {
    max-width: 800px;
    margin: 20px auto 0;
    text-align: center;
    padding: 20px;
}

footer a {
    color: #7f8c8d;
    text-decoration: none;
    font-size: 14px;
    transition: color 0.3s ease;
}

footer a:hover {
    color: #3498db;
    text-decoration: underline;
}

@media (max-width: 600px) {
    .container {
        padding: 20px;
    }
    
    h1 {
        font-size: 2em;
    }
    
    .checkbox-grid {
        grid-template-columns: 1fr;
    }
    
    .control-buttons {
        flex-direction: column;
    }
}