html, body {
    height: 100%;
    margin: 0;
    font-family: Arial, sans-serif;
    background-color: #f4f7f9;
    color: #333;
    line-height: 1.6;
}

body {
    display: flex;
    flex-direction: column;
}

header {
    flex-shrink: 0;
    background: #fff;
    box-shadow: 0 2px 8px rgba(0,0,0,0.05);
}

main {
    flex: 1 0 auto;
    display: block;
    padding: 20px;
}

footer {
    flex-shrink: 0;
    background: #fff;
    padding: 20px;
    text-align: center;
    border-top: 1px solid #eee;
}

.container {
    background-color: #fff;
    padding: 30px 40px;
    border-radius: 10px;
    box-shadow: 0 4px 20px rgba(0, 0, 0, 0.1);
    width: 100%;
    max-width: 1000px;
    margin: 0 auto;
}

h1 {
    color: #0056b3;
    text-align: center;
    margin-bottom: 10px;
}

p {
    text-align: center;
    margin-bottom: 30px;
    color: #666;
}

.input-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 25px;
    margin-bottom: 30px;
}

.input-group {
    position: relative;
}

.input-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: bold;
    color: #555;
    font-size: 14px;
}

.input-group input {
    width: 100%;
    padding: 12px;
    border: 1px solid #ccc;
    border-radius: 5px;
    box-sizing: border-box;
    transition: border-color 0.3s, box-shadow 0.3s;
}

.input-group input:focus {
    border-color: #0056b3;
    box-shadow: 0 0 5px rgba(0, 86, 179, 0.2);
    outline: none;
}

/* Tô màu cho các trường mới */
.new-field label {
    color: #d9534f;
}

.info-icon {
    position: absolute;
    top: 2px;
    right: 0;
    background-color: #007bff;
    color: white;
    width: 18px;
    height: 18px;
    border-radius: 50%;
    text-align: center;
    font-size: 12px;
    line-height: 18px;
    cursor: help;
}

.info-icon:hover::after {
    content: attr(data-info);
    position: absolute;
    bottom: 25px;
    left: 50%;
    transform: translateX(-50%);
    background-color: #333;
    color: white;
    padding: 10px;
    border-radius: 5px;
    z-index: 10;
    width: 300px;
    font-size: 13px;
    text-align: left;
    white-space: normal;
    box-shadow: 0 2px 10px rgba(0,0,0,0.2);
}

button {
    display: block;
    width: 100%;
    padding: 15px;
    background-color: #28a745;
    color: white;
    border: none;
    border-radius: 5px;
    font-size: 18px;
    font-weight: bold;
    cursor: pointer;
    transition: background-color 0.3s;
}

button:hover {
    background-color: #218838;
}

.hidden {
    display: none;
}

#result-container {
    margin-top: 40px;
    border-top: 2px solid #eee;
    padding-top: 30px;
}

.result-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 20px;
    margin-bottom: 30px;
}

.result-card {
    background-color: #f9f9f9;
    border: 1px solid #eee;
    border-radius: 8px;
    padding: 20px;
    text-align: center;
}

.result-card h3 {
    margin-top: 0;
    color: #0056b3;
}

.result-card div:first-of-type {
    font-size: 22px;
    font-weight: bold;
    margin: 15px 0;
}

.risk-badge {
    font-size: 16px;
    font-weight: bold;
    padding: 8px 15px;
    border-radius: 20px;
    color: white;
    display: inline-block;
}

#result-details {
    width: 100%;
    border-collapse: collapse;
    margin-top: 20px;
}

#result-details th, #result-details td {
    border: 1px solid #ddd;
    padding: 12px;
    text-align: left;
}

#result-details th {
    background-color: #f2f2f2;
    font-weight: bold;
}
