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

body {
    font-family: 'Malgun Gothic', 'Apple SD Gothic Neo', sans-serif;
    background-color: #f5f5f5;
    padding: 30px;
    font-size: 20px; /* 18px → 20px */
    line-height: 1.8; /* 1.6 → 1.8 */
}

.container {
    display: flex;
    gap: 30px;
    max-width: 1400px;
    margin: 0 auto;
}

.form-section {
    flex: 1;
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    height: fit-content;
}

.preview-section {
    flex: 1;
    background: white;
    padding: 30px;
    border-radius: 10px;
    box-shadow: 0 2px 10px rgba(0,0,0,0.1);
    height: fit-content;
}

h2, h3 {
    color: #333;
    margin-bottom: 25px;
    font-size: 28px; /* h2, h3 글자 크기 증가 */
}

h2 {
    font-size: 32px;
}

.input-group {
    margin-bottom: 25px; /* 15px → 25px */
}

.input-group label {
    display: block;
    margin-bottom: 8px; /* 5px → 8px */
    font-weight: bold;
    color: #333; /* #555 → #333 (더 진한 색) */
    font-size: 20px; /* 라벨 글자 크기 명시 */
}

.input-group input,
.input-group select {
    width: 100%;
    padding: 15px; /* 10px → 15px */
    border: 2px solid #ddd; /* 1px → 2px */
    border-radius: 8px; /* 5px → 8px */
    font-size: 20px; /* 16px → 20px */
    background-color: white;
    line-height: 1.5;
}

.input-group select {
    cursor: pointer;
}

.utility-section {
    margin: 30px 0;
    padding: 20px;
    background-color: #f8f9fa;
    border-radius: 8px;
}

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

.calculated-result {
    padding: 20px; /* 15px → 20px */
    background-color: #e3f2fd;
    border-radius: 8px; /* 5px → 8px */
    border-left: 6px solid #2196f3; /* 4px → 6px */
    font-weight: bold;
    color: #1565c0;
    font-size: 22px; /* 글자 크기 추가 */
    line-height: 1.6;
}

.apartments-section {
    margin: 30px 0;
}

.apartment-header {
    display: grid;
    grid-template-columns: 100px 1fr 1fr 1.2fr;
    gap: 15px;
    margin-bottom: 10px;
    padding: 0 12px;
    font-weight: bold;
    color: #555;
    font-size: 16px;
    text-align: center;
}

.apartment-header span:first-child {
    text-align: left;
}

.apartment-row {
    display: grid;
    grid-template-columns: 100px 1fr 1fr 1.2fr;
    gap: 15px;
    align-items: center;
    margin-bottom: 15px;
}

.apartment-row label {
    font-weight: bold;
    color: #333; /* #555 → #333 */
    font-size: 20px; /* 글자 크기 추가 */
}

.apartment-row input {
    padding: 12px; /* 8px → 12px */
    border: 2px solid #ddd; /* 1px → 2px */
    border-radius: 6px; /* 4px → 6px */
    font-size: 18px; /* 글자 크기 추가 */
}

.apartment-row input[readonly] {
    background-color: #f8f9fa;
    color: #495057;
    cursor: not-allowed;
}

.button-group {
    display: flex;
    gap: 15px;
    margin-top: 30px;
}

button {
    flex: 1;
    padding: 20px; /* 15px → 20px */
    border: none;
    border-radius: 8px; /* 5px → 8px */
    font-size: 22px; /* 16px → 22px */
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s;
    min-height: 60px; /* 최소 높이 추가 */
}

#generateBtn {
    background-color: #4caf50;
    color: white;
}

#generateBtn:hover {
    background-color: #45a049;
}

#downloadBtn {
    background-color: #2196f3;
    color: white;
}

#downloadBtn:hover:not(:disabled) {
    background-color: #1976d2;
}

#downloadBtn:disabled {
    background-color: #ccc;
    cursor: not-allowed;
}

/* 고지서 스타일 */
.bill-container {
    font-family: 'Malgun Gothic', sans-serif;
    max-width: 600px;
    margin: 0 auto;
    background: white;
    padding: 40px;
    border: 2px solid #333;
}

.bill-title {
    text-align: center;
    font-size: 32px;
    font-weight: bold;
    margin-bottom: 40px;
    color: #333;
}

.bill-table {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 40px;
}

.bill-table th,
.bill-table td {
    border: 2px solid #333;
    padding: 15px;
    text-align: center;
    font-size: 18px;
    font-weight: bold;
}

.bill-table th {
    background-color: #f0f0f0;
    font-size: 18px;
    padding: 10px 6px;
}

.bill-table .th-sub {
    font-size: 13px;
    font-weight: normal;
    color: #555;
}

.bill-table td {
    padding: 12px 6px;
    font-size: 16px;
}

.bill-info {
    margin-bottom: 30px;
}

.bill-info p {
    font-size: 16px;
    margin-bottom: 10px;
    font-weight: bold;
}

.bill-calculation {
    font-size: 20px;
    text-align: center;
    margin-bottom: 20px;
    font-weight: bold;
}

.bill-note {
    font-size: 16px;
    text-align: center;
    color: #666;
    font-weight: bold;
}

@media (max-width: 768px) {
    .container {
        flex-direction: column;
    }

    .apartment-header {
        display: none;
    }

    .apartment-row {
        grid-template-columns: 1fr 1fr;
        gap: 8px;
    }

    .apartment-row label {
        grid-column: 1 / -1;
        margin-bottom: 5px;
    }
}
