﻿.loan-options {
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    gap: clamp(5px, 2vw, 25px);
}

.loan-card {
    flex: 1 1 0;
    max-width: 200px; /* ใหญ่สุด */
    min-width: 0; /* สำคัญ */
    cursor: pointer;
    border-radius: 12px;
    overflow: hidden;
    border: 3px solid transparent;
    transition: all .3s ease;
}

    .loan-card img {
        width: 100%;
        aspect-ratio: 1.3 / 1; /* รักษาสัดส่วน */
        object-fit: cover;
        display: block;
    }

    /* ไม่ถูกเลือก */
    .loan-card:not(.active) {
      /*  filter: blur(2px) grayscale(70%);*/
        opacity: .5;
    }

    /* ถูกเลือก */
    .loan-card.active {
        border-color: #0d6efd;
        opacity: 1;
    }

.loan-header {
    width: 100%;
    text-align: center;
    margin-bottom: 15px;
}

.loan-label {
    color: darkblue;
    font-weight: 600;
    line-height: 1.3;
    /* Responsive Font */
    font-size: clamp(18px, 3vw, 60px);
}

.car-brand-selector {
    width: 100%;
    height: 46px;
    border: 1px solid #ccc;
    border-radius: 8px;
    padding: 10px;
    cursor: pointer;
    background: #fff;
}

.brand-selector {
    width: 100%;
    height: 45px;
    background: white;
    border: none;
    border-radius: 4px;
    padding: 0 40px 0 14px;
    box-sizing: border-box;
    display: flex;
    align-items: center;
    position: relative;
    color: darkblue;
    font-size: 24px;
    cursor: pointer;
    overflow: hidden;
    white-space: nowrap;
    text-overflow: ellipsis;
}

.brand-arrow {
    position: absolute;
    right: 14px;
    top: 50%;
    transform: translateY(-50%);
    color: #888;
    font-size: 12px;
    pointer-events: none;
}
  

.brand-modal {
    background: #f2f2f2;
    border: 8px solid #f0d300;
    border-radius: 24px;
    padding: 15px;
    box-shadow: none;
}

.brand-title {
    text-align: center;
    font-size: 34px;
    font-weight: bold;
    color: darkblue;
    margin-bottom: 5px;
    padding-top: 20px;
}

.brand-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
}

.brand-item {
    display: flex;
    align-items: center;
    justify-content: center;
    height: 80px;
    cursor: pointer;
    border-radius: 12px;
    transition: .2s;
}

    .brand-item:hover {
        background: rgba(255,255,255,.8);
        transform: scale(1.05);
    }

    .brand-item img {
        max-width: 90px;
        max-height: 60px;
        width: auto;
        height: auto;
    }

@media(max-width:768px) {

    .brand-title {
        font-size: 24px;
    }

    .brand-grid {
        grid-template-columns: repeat(4,1fr);
        gap: 10px;
    }

    .brand-item {
        height: 60px;
    }

        .brand-item img {
            max-width: 60px;
            max-height: 40px;
        }
}

.consent-section {
    text-align: center;
    padding-top: 10px;
}

.consent-text {
    color: #333;
    font-size: 20px;
    line-height: 1.5;
    font-weight: 400;
  
    padding-top: 15px;
    padding-bottom: 15px;
}

.privacy-link {
    color: #0099ff;
    text-decoration: none;
    cursor: pointer;
}

.warning-text {
    color: red;
    font-size: 18px;
}

.submit-section {
    padding: 15px 0;
}

.confirm-button {
    width: 100%;
    margin: 0 auto;
    display: block;
    height: 100px;
    background: #1414b8;
    color: white;
    border: solid 5px white;
    border-radius: 18px;
    font-size: 34px;
    font-weight: 700;
    cursor: pointer;
    transition: .2s;
}

/* Desktop */
@media (min-width: 768px) {

    .confirm-button {
        width: 500px;
        max-width: 90%;
    }
}

    .confirm-button:hover {
        opacity: .9;
    }

@media (max-width: 768px) {

    .consent-text {
        font-size: 14px;
  
    }

    .warning-text {
        font-size: 13px;
    }

    .confirm-button {
        height: 55px;
        font-size: 24px;
        letter-spacing: 2px;
    }
}

#floatingApplyBtn {
    position: fixed;
    left: 50%;
    bottom: 50px;
    transform: translateX(-50%);
    z-index: 9999;
    width: min(500px, 95%);
    height: 60px;
    border: none;
    border-radius: 15px;
    background: #00a2ff;
    color: #fff;
    font-size: 24px;
    font-weight: bold;
    cursor: pointer;
    box-shadow: 0 4px 20px rgba(0,0,0,.25);
    display: none;
    transition: all .3s ease;
    letter-spacing: 2px;
}

    #floatingApplyBtn:hover {
        background: #0088dd;
    }


.bird-card {
    font-family: 'Sarabun', sans-serif;
    letter-spacing: 2px;
    width: 100%;
    background: #FCF3E8;
    border-radius: 15px;
    padding: 15px;
    text-align: center;
}

.bird-title {
    font-size: 16px;
    font-weight: bold;
    color: darkblue;
    margin-bottom: 15px;
}

.bird-list {
    display: inline-block; /* ทำให้ทั้งกลุ่มอยู่กลาง */
    text-align: left; /* แต่ข้อความด้านในชิดซ้าย */
}

.bird-row {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-bottom: 10px;
}

    .bird-row img {
        width: 42px;
        height: auto;
        flex-shrink: 0;
    }

    .bird-row span {
        font-size: 16px;
        color: #444;
    }

.rule-image {
    width: 75%;
    height: auto;
    display: block;
    margin: 0 auto;
}

.compare-table-wrapper {
    max-width: 900px;
    margin: 20px auto;
    font-family: "Sarabun", sans-serif;
}

    .compare-table-wrapper h2 {
        text-align: center;
        color: #0b2f6b;
        font-size: 30px;
        margin-bottom: 20px;
        font-weight: 700;
    }

.compare-table {
    width: 100%;
    border-collapse: collapse;
}

    .compare-table th,
    .compare-table td {
        padding: 14px 18px;
        vertical-align: middle;
        border-bottom: 1px solid #173a7a;
    }

    .compare-table th {
        color: #0b2f6b;
        font-size: 14px;
        font-weight: 700;
        text-align: center;
    }

    .compare-table td {
        font-size: 14px;
        line-height: 1.6;
    }

    .compare-table .row-title {
        color: #0b2f6b;
        font-weight: 700;
        white-space: nowrap;
        width: 25%;
    }

    .compare-table tbody tr:last-child td {
        border-bottom: 0;
    }

/* Mobile */
@media (max-width: 768px) {

    .compare-table-wrapper h2 {
        font-size: 14px;
    }

    .compare-table th,
    .compare-table td {
        font-size: 14px;
        padding: 10px;
    }

    .compare-table .row-title {
        width: 30%;
    }
}

.faq-title {
    font-size: 18px;
    font-weight: bold;
    color: darkblue;
    margin-bottom: 15px;
}

.faq-item {
    border-bottom: 1px solid #ddd;
}

.faq-question {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 12px 0;
    cursor: pointer;
    color: darkblue;
    font-size: 15px;
    font-weight: 500;
}

.faq-arrow {
    transition: transform .3s ease;
}

.faq-item.active .faq-arrow {
    transform: rotate(180deg);
}

.faq-answer {
    display: none;
    padding: 0 0 15px 0;
    color: darkblue;
    font-size: 14px;
    line-height: 1.6;
}

.faq-item.active .faq-answer {
    display: block;
}

.custom-input {
    height: 45px !important;
    font-size: 24px; /* เพิ่มขนาดตัวอักษร */

    padding: 0 14px;
    border: none !important;
    box-shadow: none !important;
    outline: none !important;
    background-color: white;
    color: darkblue !important;
}

    .custom-input:focus {
        border: none !important;
        box-shadow: none !important;
        outline: none !important;
    }

    .custom-input::placeholder {
        color: #999;
        opacity: 1;
    }

.custom-select-input {
    height: 45px !important;
    font-size: 24px !important;
    border: none !important;
    box-shadow: none !important;
    background-color: white !important;
    color: darkblue;
    padding-left: 14px !important;
    padding-right: 35px !important;
}

    .custom-select-input:focus {
        border: none !important;
        box-shadow: none !important;
        outline: none !important;
    }

.select2-container .select2-selection--single {
    height: 45px !important;
    background: white !important;
    border: none !important;
    box-shadow: none !important;
}

.select2-container--default
.select2-selection--single
.select2-selection__rendered {
    line-height: 45px !important;
    font-size: 24px !important;
    color: darkblue !important;
    padding-left: 14px !important;
}

.select2-container--default
.select2-selection--single
.select2-selection__arrow {
    height: 45px !important;
}

.banner-img {
    width: 100%;
    height: auto;
    display: block;
    object-fit: contain;
}

@media (min-width: 768px) {
    .banner-img {
        max-height: 350px;
    }
}

@media (max-width: 767px) {
    .banner-img {
        max-height: 180px;
    }
}

input:-webkit-autofill,
input:-webkit-autofill:hover,
input:-webkit-autofill:focus,
input:-webkit-autofill:active {
    -webkit-text-fill-color: darkblue !important;
    transition: background-color 5000s ease-in-out 0s;
}
.loan-dropdown {
    position: relative;
    width: 100%;
    max-width: 500px;
    margin: auto;
}

.loan-selector {
    background: #fff;
    border: none !important;
    box-shadow: none !important;
    border-radius: 12px;
    padding: 12px;
    display: flex;
    align-items: center;
    cursor: pointer;
    color: darkblue;
    font-weight: 600;
}

    .loan-selector img {
        width: 42px;
        margin-right: 10px;
    }

    .loan-selector span {
        font-size: 20px;
        color: darkblue;
    }
 
.loan-menu {
    display: none;
    background: #fff;
    border: none !important;
    box-shadow: none !important;
    border-radius: 12px;
    margin-top: 5px;
    overflow: hidden;
    /* ให้ลอยทับ Content */
    position: absolute;
    z-index: 9999;
    width: 100%;
}

.loan-item {
    display: flex;
    align-items: center;
    padding: 12px;
    cursor: pointer;
    color: darkblue;
    border-bottom: 1px solid #e5e5e5;
    background: #fff;
}

    .loan-item:hover {
        background: #f5f5f5;
    }

    .loan-item:last-child {
        border-bottom: none;
    }

    .loan-item img {
        width: 42px;
        margin-right: 12px;
    }

    .loan-item span {
        font-size: 18px;
        color: darkblue;
    }

.checkmark {
    margin-left: auto;
    color: #4CAF50;
    font-size: 22px;
    font-weight: bold;
}

.loan-item:not(.active) .checkmark {
    display: none;
}

.loan-arrow {
    margin-left: auto;
    color: darkblue;
    transition: .3s;
}

.loan-selector.open .loan-arrow {
    transform: rotate(180deg);
}