/* ===================================
   style3.css — Flash Training
   =================================== */

/* --- Reset & Base --- */
*,
*::before,
*::after {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

/* พื้นหลังทั้งหน้า + ฟอนต์หลัก */

body {
    font-family: 'Kanit', sans-serif;
	font-size:16px;
}
/* กรอบกลางหน้าจำกัดความกว้าง */
.content-container {
    max-width: 100%;
}

/* ===================================
   Top Bar — หัวข้อบนสุด
   =================================== */
.top-bar {
    display: flex;
    align-items: center;
    gap: 20px;
    margin-bottom: 40px;
}

.header-logo {
    height: 60px;
    width: auto;
    object-fit: contain;
    flex-shrink: 0;
}

.header-title {
    font-size: clamp(16px, 3vw, 26px);
    font-weight: 100;
    color: #10275c;
    margin: 0;
}

/* ดัน h2 ให้อยู่กลาง */
.section-title {
    flex: 1;
    text-align: center;
    font-size: 26px;
    font-weight: 800;
    color: #10275c;
    margin: 0;
}

/* ตัวถ่วงขวา ให้กลางจริงๆ */
.top-bar-spacer {
    width: 80px;
    flex-shrink: 0;
}


/* ===================================
   Module Cards — 4 การ์ดโลโก้
   =================================== */
.modules-section {
    margin-bottom: 40px;
}

/* Grid 4 คอลัมน์ */
.card-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 20px;
}

/* การ์ดแต่ละใบ — สี่เหลี่ยมจัตุรัส โค้งมน */
.module-card {
    border-radius: 50px;
    aspect-ratio: 1 / 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    border: 2.5px solid transparent;
    transition: transform 0.3s cubic-bezier(0.175, 0.885, 0.32, 1.275),
        box-shadow 0.3s ease,
        border-color 0.2s ease;
    position: relative;
    overflow: hidden;
}

/* Hover — ยกขึ้น + เงา */
.module-card:hover {
    transform: translateY(-10px);
    box-shadow: 0 20px 40px -10px rgba(24, 33, 41, 0.15);
}


/* Click — ยุบลงเล็กน้อย */
.module-card:active {
    transform: scale(0.96);
}

/* รูปโลโก้ในการ์ด */
.card-icon {
    width: 200px;
    height: 200px;
    object-fit: contain;
    transition: transform 0.3s ease;
}

/* Hover — โลโก้ขยายและหมุนนิดหน่อย */
.module-card:hover .card-icon {
    transform: scale(1.15) rotate(4deg);
}

/* สีพื้นหลังการ์ดแต่ละใบ */
.card-blue-light {
    background-color: #E8F4FD;
    color: #1A6FA8;
}

.card-purple-light {
    background-color: #F0EEFF;
    color: #5B4AC7;
}

.card-green-light {
    background-color: #E8F8F0;
    color: #1A7A4A;
}

.card-red-light {
    background-color: #FEF0F0;
    color: #C0392B;
}

/* ===================================
   Operations Table — ตารางหลักสูตร
   =================================== */
.operations-section {
    margin-bottom: 20px;
}

/* หัวข้อตาราง */
.section-title {
    font-size: 26px;
    font-weight: 800;
    text-align: center;
    margin-bottom: 30px;
    color: #10275c;
}

/* กรอบนอกตาราง — scroll แนวนอนบนมือถือ */
.table-responsive {
    overflow-x: auto;
    -webkit-overflow-scrolling: touch;
    border-radius: 12px;
}

/* ตาราง */
/* เส้นกรอบตาราง */
.ops-table {
    width: 100%;
    border-collapse: collapse;
    border: 2px solid #90b1e2;
    border-radius: 12px;
}

.ops-table th,
.ops-table td {
    border: 1px solid #90b1e2;
}

/* เส้นใต้ thead */
.ops-table thead tr {
    border-bottom: 2px solid #f0f2f5;
}

/* หัวตาราง — พื้นน้ำเงินเข้ม ตัวขาว */
.ops-table th {
    text-align: left;
    padding: 14px 16px;
    font-size: 18px;
    font-weight: 700;
    color: #ffffff;
    background-color: #0d3177;
}

/* มุมโค้งหัวตาราง */
.ops-table thead tr th:first-child {
    border-radius: 10px 0 0 0;
}

.ops-table thead tr th:last-child {
    border-radius: 0 10px 0 0;
}

/* เซลล์ข้อมูล */
.ops-table td {
    padding: 18px 16px;
    border-bottom: 1px solid #90b1e2;
    color: #323f52;
}

/* แถวสุดท้ายไม่มีเส้นล่าง */
.ops-table tbody tr:last-child td {
    border-bottom: none;
}

/* Hover แถว */
.ops-table tbody tr:hover td {
    background-color: #d1e3ff;
}

/* ชื่อหลักสูตร — ตัวหนา */
.course-name {
    font-weight: 600;
    color: #323846;
}

/* ราคา — สีน้ำเงินเข้ม */
.price-text {
    font-weight: 700;
    color: #0d3177;
}

/* ===================================
   Responsive — มือถือ
   =================================== */

/* Tablet & Mobile ≤ 768px */
@media (max-width: 768px) {

    /* การ์ด: ลดเป็น 2 คอลัมน์ */
    .card-grid {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }

    /* โลโก้เล็กลง */
    .card-icon {
        width: 100px;
        height: 100px;
    }

    /* มุมการ์ดลดลง */
    .module-card {
        border-radius: 24px;
    }

    /* ตาราง: ซ่อนคอลัมน์ที่ 2 และ 3 ไว้เฉพาะชื่อหลักสูตร */
    .ops-table thead tr th:nth-child(2),
    .ops-table thead tr th:nth-child(3),
    .ops-table tbody tr td:nth-child(2),
    .ops-table tbody tr td:nth-child(3) {
        display: none;
    }

    .ops-table th,
    .ops-table td {
        padding: 12px;
    }
}