/* ฟอนต์ */
@import url('https://fonts.googleapis.com/css2?family=K2D:ital,wght@0,100;0,200;0,300;0,400;0,500;0,600;0,700;0,800;1,100;1,200;1,300;1,400;1,500;1,600;1,700;1,800&display=swap');

/* ======= คุมทั้งหมด ======= */
* {
    font-family: "K2D", sans-serif;
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    background-image: url('Flart.jpg'); /* ใส่ URL ของรูป */
    background-size: cover; /* ปรับขนาดรูปให้เต็มพื้นที่ */
    background-position: center; /* จัดตำแหน่งรูปให้อยู่กึ่งกลาง */
    background-repeat: no-repeat; /* ไม่ให้รูปซ้ำ */
    background-attachment: fixed; /* พื้นหลังจะไม่เลื่อนตามเนื้อหา */
    font-size: 16px;
    padding: 20px;
    min-height: 100vh; /* ให้ความสูงของหน้าเต็มจอ */
}

.Header {
    text-align: center;
    position: relative;
    width: 100%;
    max-width: 800px;
    margin: auto;
    padding: 30px;
    background: rgba(255, 255, 255, 0.45); /* Semi-transparent white background */
    border-radius: 15px;
    box-shadow: 0 10px 30px rgb(0, 0, 0);
    backdrop-filter: blur(10px); /* Apply the blur effect */
    -webkit-backdrop-filter: blur(10px); /* For Safari */
}


.center h1 {
    color: #000000;
    font-size: 2rem;
    margin-bottom: 20px;
}

.cardbox {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 20px;
    margin-bottom: 20px;
}

.card {
    text-align: left;
}

.inputpoint {
    width: 100%;
    padding: 10px;
    margin-top: 10px;
    margin-bottom: 10px;
    border: 2px solid #ccc;
    border-radius: 8px;
    font-size: 16px;
    background-color: #fff;
    transition: border-color 0.3s ease;
}

.inputpoint:focus {
    border-color: #007BFF;
    box-shadow: 0 0 5px rgba(0, 123, 255, 0.5);
    outline: none;
}

button {
    padding: 10px 20px;
    font-size: 16px;
    background-color: #007BFF;
    color: #fff;
    border: none;
    border-radius: 8px;
    cursor: pointer;
    margin-top: 20px;
    transition: background-color 0.3s;
}

button:hover {
    background-color: #0056b3;
}

.result {
    margin-top: 20px;
    font-size: 1.2rem;
}

.grade-table {
    margin-top: 30px;
}

.grade-table table {
    width: 100%;
    border-collapse: collapse;
    margin-top: 10px;
    border-radius: 8px;
    overflow: hidden;
}

.grade-table th, .grade-table td {
    padding: 10px;
    text-align: center;
    border: 1px solid #ddd;
}

.grade-table th {
    background-color: #f8f9fa;
}

.grade-table tr:nth-child(even) {
    background-color: #f2f2f2;
}

.grade-table tr:hover {
    background-color: #e1e1e1;
}

@media (max-width: 600px) {
    .cardbox {
        grid-template-columns: 1fr;
    }
}
