* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
    background-color: #f5f5f5;
    padding: 20px;
}

.container {
    max-width: 1200px;
    margin: 0 auto;
    background-color: white;
    border-radius: 8px;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.1);
    padding: 30px;
}

.header {
    text-align: center;
    margin-bottom: 30px;
}

.title {
    font-size: 28px;
    font-weight: bold;
    color: #333;
    margin-bottom: 10px;
}

.title-line {
    height: 2px;
    background-color: #20B2AA;
    width: 80%;
    margin: 0 auto;
}

.form-section {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.input-group {
    display: flex;
    flex-direction: column;
}

.input-group label {
    font-weight: 600;
    color: #333;
    margin-bottom: 8px;
    font-size: 14px;
}

.input-field {
    padding: 12px;
    border: 2px solid #e0e0e0;
    border-radius: 6px;
    font-size: 14px;
    background-color: #f8f9fa;
    transition: border-color 0.3s ease;
}

.input-field:focus {
    outline: none;
    border-color: #20B2AA;
    background-color: #f0f8ff;
}

.input-field.active {
    border-color: #20B2AA;
    background-color: #f0f8ff;
}

.calculation-section {
    background-color: #f8f9fa;
    padding: 20px;
    border-radius: 6px;
    margin-top: 20px;
    border-left: 4px solid #20B2AA;
}

.calculation-details {
    background-color: white;
    padding: 0;
    border-radius: 6px;
    margin-top: 10px;
    border: 1px solid #e0e0e0;
}

.dose-category {
    background-color: #20B2AA;
    color: white;
    padding: 10px 15px;
    border-radius: 6px 6px 0 0;
    font-weight: 600;
    display: block;
    margin-bottom: 0;
    text-align: center;
    font-size: 16px;
}

.calculation-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 0;
    background-color: white;
}

.calculation-table th {
    background: #b3e0dd !important;
    color: #2d5a58 !important;
    padding: 12px 10px;
    text-align: center;
    font-weight: 700;
    font-size: 14px;
    border: 2px solid #5fd3d0;
}

.calculation-table td {
    padding: 12px 10px;
    border: 2px solid #d0d0d0;
    font-size: 13px;
    color: #000;
    font-weight: 500;
    vertical-align: middle;
}

.calculation-table .threshold-col {
    background-color: #f0f8ff;
    font-weight: 700;
    text-align: left;
    border-right: 3px solid #20B2AA;
    width: 25%;
}

.calculation-table .formula-col {
    font-family: 'Courier New', monospace;
    background-color: #f8f9fa;
    font-size: 12px;
    text-align: left;
    width: 50%;
    padding: 8px 10px;
}

.calculation-table .result-col {
    font-weight: 700;
    color: #20B2AA;
    font-size: 14px;
    text-align: center;
    background-color: #ffffff;
    width: 25%;
}

.calculation-table tbody tr:nth-child(even) {
    background-color: #fafafa;
}

.calculation-table tbody tr:hover {
    background-color: #e6f7ff;
    transition: background-color 0.2s ease;
}

.section-header {
    background: #b3e0dd !important;
    color: #2d5a58 !important;
    padding: 8px 15px;
    font-weight: 700;
    text-align: center;
    font-size: 15px;
}

.calculation-key {
    background-color: #e8f4f8;
    padding: 12px 15px;
    border-top: 2px solid #20B2AA;
    font-size: 12px;
    color: #333;
}

.export-btn {
    background-color: #3498db;
    color: white;
    border: none;
    padding: 12px 24px;
    border-radius: 6px;
    font-size: 16px;
    font-weight: 600;
    cursor: pointer;
    transition: background-color 0.3s ease;
    box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1);
}

.export-btn:hover {
    background-color: #2980b9;
    box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
}

.results-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 15px;
    margin-top: 20px;
}

.result-item {
    background-color: white;
    padding: 15px;
    border-radius: 6px;
    border-left: 4px solid #20B2AA;
}

.result-label {
    font-weight: 600;
    color: #333;
    font-size: 14px;
    margin-bottom: 5px;
}

.result-value {
    font-size: 18px;
    font-weight: bold;
    color: #20B2AA;
}

.info-section {
    background-color: #e8f4f8;
    padding: 15px;
    border-radius: 6px;
    margin-top: 20px;
    border-left: 4px solid #20B2AA;
}

.info-title {
    font-weight: 600;
    color: #333;
    margin-bottom: 10px;
}

.info-text {
    color: #666;
    font-size: 14px;
    line-height: 1.5;
}

.impurity-table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
    background-color: white;
    border: 2px solid #20B2AA;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
}

.impurity-table th {
    background: #b3e0dd !important;
    color: #2d5a58 !important;
    padding: 15px 12px;
    text-align: center;
    font-weight: 700;
    font-size: 15px;
    border: 2px solid #5fd3d0;
    border-bottom: 3px solid #5fd3d0;
}

.impurity-table td {
    padding: 15px 12px;
    border: 2px solid #d0d0d0;
    font-size: 14px;
    color: #000;
    font-weight: 600;
    text-align: center;
    vertical-align: middle;
}

.impurity-table tbody tr:nth-child(odd) {
    background-color: #ffffff;
}

.impurity-table tbody tr:nth-child(even) {
    background-color: #f8f9fa;
}

.impurity-table tbody tr:hover {
    background-color: #e6f7ff;
    transition: background-color 0.2s ease;
}

.impurity-table .threshold-name {
    text-align: left;
    font-weight: 700;
    background-color: #f0f8ff;
    border-right: 3px solid #20B2AA;
}

.impurity-table .note-row td {
    background-color: #e8f4f8 !important;
    font-size: 12px;
    color: #333;
    padding: 10px 15px;
    border: 2px solid #20B2AA;
    border-left: 4px solid #20B2AA;
    font-weight: 600;
    text-align: left;
}

@media (max-width: 768px) {
    .form-section {
        grid-template-columns: 1fr;
    }
    
    .results-grid {
        grid-template-columns: 1fr;
    }
}
