.contact-us-banner {
    position: relative;
    z-index: 1;
    color: #fff;
    text-align: center;
    height: 316px;
    background-size: cover;
    background-position: center;
    background-repeat: no-repeat;
    display: flex;
    align-items: center;
    justify-content: center;
}

.contact-us-banner::before {
    content: "";
    position: absolute;
    inset: 0;
    background: #b254173b;
}

.contact-us-banner .container {
    position: relative;
    z-index: 1;
}

.banner-content h1 {
    font-size: 64px;
    font-weight: 700;
}
.contact-us-form {
    background: #fff;
    padding: 58px 0 70px;
}

.contact-form-ghost {
    font-weight: 400;
    font-size: 18px;
    color: #0a0a0a99;
    display: none;
}

.contact-us-form .container {
    max-width: 932px;
}
.form-title {
    max-width: 760px;
    margin-bottom: 34px;
}
.form-title h1 {
    margin: 0 0 8px;
    color: #000;
    font-size: 32px;
    font-weight: 600;
}
.form-title p {
    margin: 0;
    color: #000;
    font-size: 18px;
}
.form-content {
    display: block;
}
.contact-form-layout {
    display: grid;
    grid-template-columns: 280px 571px;
    justify-content: space-between;
    align-items: start;
}
.contact-form-layout[hidden] {
    display: none;
}
.form-side-contact {
    color: #000;
    font-size: 16px;
    max-width: 277px;
    font-weight: 400;
}
.contact-qr-card {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 10px;
    margin-bottom: 25px;
}
.contact-qr-card img {
    width: 100%;
    padding: 12px;
    border: 1px solid #ddd;
    border-radius: 8px;
    object-fit: contain;
}
.contact-qr-card label {
    color: #4fba58;
    font-size: 18px;
    font-weight: 600;
}
.contact-company {
    margin-bottom: 20px;
}
.contact-company strong {
    display: block;
    margin-bottom: 5px;
    font-size: 15px;
}
.contact-company p {
    margin: 0;
    color: #656565;
    font-size: 14px;
}
.contact-details {
    display: grid;
    gap: 25px;
    margin: 0;
    padding: 0;
    list-style: none;
}
.contact-details li {
    display: flex;
    gap: 25px;
    align-items: center;
}
.contact-details i {
    color: #000;
    font-size: 18px;
    text-align: center;
}
.contact-form-container,
.contact-success-container {
    min-height: 520px;
    padding: 25px 30px;
    border: 1px solid #e6e6e6;
    border-radius: 3px;
    box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}
.form-contact {
    display: grid;
    gap: 13px;
}
.form-group {
    display: grid;
    gap: 10px;
}
.form-group label {
    color: #000;
    font-size: 16px;
    font-weight: 400;
}
.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    box-sizing: border-box;
    padding: 0 10px;
    border: 0.8px solid #e4e4e4;
    border-radius: 3px;
    color: #00000080;
    font: inherit;
    font-size: 14px;
}
.form-group input,
.form-group select {
    height: 31px;
}
.form-group textarea {
    min-height: 134px;
    resize: vertical;
}
.form-group select option:hover,
.form-group select option:focus {
    background: #FFF8F6;
    color: #000;
}

/* Custom select (JS-enhanced) — base อยู่ใน style.css (โหลดทุกหน้า) ที่นี่ override เฉพาะค่าที่ต่าง
   (native option ไม่สามารถจัด hover bg / icon ชิดขวาได้ทุกเบราว์เซอร์) */
.custom-select-trigger {
    width: 100%;
    box-sizing: border-box;
    height: 31px;
    padding: 0 10px;
    border: 0.8px solid #e4e4e4;
    border-radius: 3px;
    background: #fff;
    color: #00000080;
    font: inherit;
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 8px;
    cursor: pointer;
    text-align: left;
}
.custom-select-trigger .trigger-chevron {
    flex: 0 0 auto;
    color: #00000080;
    font-size: 12px;
    transition: transform 0.15s ease;
}

/* ขอบ options / สี placeholder ต่างจาก style.css */
.custom-select-options {
    border: 0.8px solid #e4e4e4;
}
.custom-select-option[data-value=""] {
    color: #00000080;
}
.form-group small {
    color: #00000080;
    font-size: 12px;
}
.upload-zone {
    position: relative;
    min-height: 134px;
    border: 1px solid #e5e5e5;
}
.upload-zone input {
    position: absolute;
    inset: 0;
    width: 100%;
    height: 100%;
    opacity: 0;
    cursor: pointer;
    z-index: 2;
}
.upload-default {
    min-height: 134px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 8px;
    color: #888;
    font-size: 10px;
    cursor: pointer;
}
.upload-default[hidden] {
    display: none;
}
.upload-default i {
    color: #000;
    font-size: 23px;
}

.upload-default span {
    color: #656565;
    font-size: 14px;
}

.file-preview {
    position: relative;
    min-height: 134px;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    gap: 6px;
    color: #555;
    font-size: 11px;
}
.file-preview[hidden] {
    display: none;
}
.file-preview img {
    max-width: 90px;
    max-height: 65px;
    object-fit: contain;
}
.preview-file-icon {
    color: #df4d22;
    font-size: 28px;
}
.preview-remove {
    position: absolute;
    top: 7px;
    right: 7px;
    z-index: 3;
    border: 0;
    background: transparent;
    color: #000;
    cursor: pointer;
}
.upload-error {
    color: #e33b2b !important;
}
.submit-contact-btn {
    width: 135px;
    padding: 8px 12px;
    border: 0;
    border-radius: 20px;
    background: #cc611c;
    color: #fff;
    font: inherit;
    font-size: 16px;
    cursor: pointer;
}
.submit-contact-btn:hover {
    background: #af4703;
}
.contact-success-container[hidden] {
    display: none;
}
.contact-success-container {
    width: min(100%, 700px);
    box-sizing: border-box;
    margin: 0 auto;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    text-align: center;
}
.success-icon {
    display: grid;
    place-items: center;
    width: 77px;
    height: 77px;
    margin-bottom: 14px;
    border-radius: 50%;
    background: #d8521e;
    color: #fff;
    font-size: 34px;
}
.contact-success-container h2 {
    margin: 0 0 14px;
    color: #1f2937;
    font-size: 32px;
    font-weight: 600;
}
.contact-success-container > p {
    margin: 0 0 20px;
    color: #000;
    font-size: 16px;
}
.success-reference {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 14px;
    width: 100%;
    box-sizing: border-box;
    margin-bottom: 16px;
    padding: 11px 20px;
    border-radius: 5px;
    background: #f0f0f0;
    color: #00000080;
    text-align: left;
    font-size: 14px;
}
.success-reference > i {
    color: #d8521e;
    font-size: 36px;
}
.success-reference strong {
    font-size: 16px;
    color: #d8521e;
}
.success-reference p {
    margin: 3px 0 0;
}
.success-actions {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 12px;
    width: 100%;
    padding-top: 13px;
    border-top: 1px solid #eee;
}

.success-actions a {
    box-sizing: border-box;
    padding: 7px 12px;
    border-radius: 26px;
    font: inherit;
    font-size: 14px;
    text-align: center;
    text-decoration: none;
    cursor: pointer;
}

.success-primary {
    background: #d8521e;
    color: #fff;
}

.success-secondary {
    border: 1px solid #d8521e;
    color: #d8521e;
}

.success-primary:hover {
    background: #c53f0a;
}

.success-secondary:hover {
    background: #fcf0f1;
}

.success-footer {
    margin-top: 17px;
    color: #000;
    font-size: 14px;
}
.success-footer p {
    margin: 0;
}
.contact-us-location {
    padding: 0;
    height: 414px;
}
.location-map {
    height: 100%;
    overflow: hidden;
}
.location-map iframe {
    width: 100%;
    height: 100%;
    border: 0;
}

@media (max-width: 768px) {
    .contact-us-banner {
        max-height: 316px;
    }
    .banner-content h1 {
        font-size: 48px;
        font-weight: 600;
    }
    .form-title h1 {
        font-size: 27px;
    }
    .contact-us-form {
        padding: 40px 0 50px;
    }
    .contact-form-ghost {
        display: flex;
    }
    .contact-us-form .container {
        padding: 0 20px;
    }
    .contact-form-layout {
        grid-template-columns: 1fr;
    }
    .form-group input,
    .form-group select,
    .form-group textarea {
        font-size: 15px;
    }
    .form-group input,
    .form-group select,
    .custom-select-trigger {
        height: 35px;
    }
    .form-group small {
        display: none;
    }
    .upload-zone {
        min-height: 125px;
    }
    .upload-default {
        min-height: 125px;
    }
    .file-preview {
        min-height: 125px;
    }
    .form-group textarea {
        min-height: 125px;
    }
    .form-side-contact {
        display: flex;
        flex-direction: column;
        margin: auto;
        gap: 20px;
    }
    .submit-contact-btn {
        margin-top: 40px;
        width: 100%;
    }
    .contact-qr-card {
        grid-row: span 2;
    }
    .contact-qr-card img {
        width: 228px;
    }
    .contact-company strong {
        font-size: 17px;
    }
    .contact-company p {
        font-size: 16px;
    }
    .contact-company {
        margin: 0;
    }
    .contact-details {
        grid-column: 2;
    }
    .contact-form-container,
    .contact-success-container {
        padding: 22px 18px;
    }
    .contact-form-container {
        border: 0;
        box-shadow: none;
    }
}
