/*
Theme Name: imta-theme
Description: This is a child theme for Flatsome Theme
Author: UX Themes
Template: flatsome
Version: 3.0
*/

/*************** ADD CUSTOM CSS HERE.   ***************/
/* --- BỐ CỤC KHUNG 3 CỘT TỔNG THỂ --- */
.tu-van-wrapper {
    display: flex;
    justify-content: space-between;
    max-width: 1000px; /* Độ rộng tổng của toàn khu vực */
    margin: 0 auto;
    padding: 40px 20px;
	gap: 30px;
	align-items: flex-start;
}

/* Định dạng cột trái và cột phải rộng bằng nhau */
.col-left, .col-right {
    display: flex;
    flex-direction: column;
    gap: 40px; /* Khoảng cách đứng giữa hàng trên và hàng dưới */
    flex: 1;   /* Chiếm không gian đều nhau hai bên */
}

/* Khối trung tâm chứa logo cố định độ rộng */
.col-center {
    flex: 0 0 260px; /* Khoảng cách bao quanh logo để tạo khoảng trống vừa vặn */
    display: flex;
    align-items: center;
    justify-content: center;
}

.center-logo {
    max-width: 100%;
    height: 75px;
	width: 142px;
    display: block;
}

/* --- XỬ LÝ SẮP XẾP PHẦN TỬ TRONG MỘT DÒNG --- */
.service-item {
    display: flex;
    align-items: center;
    width: 100%;
}

/* Khử lỗi thẻ p tự sinh của WordPress */
.service-item p {
    display: none !important;
}

.service-item .service-text,
.service-item .service-icon {
    margin: 0 !important;
    padding: 0 !important;
}

/* ==========================================================================
   CĂN THẲNG LỀ TUYỆT ĐỐI THEO HAI RÌA TRÁI - PHẢI
   ========================================================================== */

/* CỘT TRÁI: Đẩy Chữ sang kịch lề TRÁI ngoài cùng, Icon sang kịch lề PHẢI */
.item-right {
    justify-content: space-between; 
}
.item-right .service-text {
    text-align: left; /* Chữ căn lề bên trái */
}

/* CỘT PHẢI: Đẩy Icon sang kịch lề TRÁI, Chữ sang kịch lề PHẢI ngoài cùng */
.item-left {
    justify-content: space-between;
}
.item-left .service-text {
    text-align: right; /* Chữ căn lề bên phải */
}

/* --- ĐỊNH DẠNG FONT CHỮ LINK --- */
.service-text {
    flex: 1; /* Cho phép vùng chữ co giãn tự do để đẩy icon về đúng vị trí */
}

.service-text a {
    font-family: sans-serif;
    font-weight: bold;
    color: #1a7fc3;
    font-size: 17px;
    text-decoration: none !important;
    transition: color 0.3s ease;
    display: inline-block;
}

.service-text a:hover {
    color: #10629a;
}

/* --- ĐỊNH DẠNG ICON VÀ HIỆU ỨNG XOAY TRỤC GIỮA --- */
.service-icon {
    width: 60px;
    height: 60px;
    background-color: #10629a;
    border-radius: 50%;
    background-repeat: no-repeat;
    background-position: center;
    background-size: 32px auto;
    flex-shrink: 0;
    
    /* Ghim tâm xoay chuẩn ở giữa trục hình tròn */
    transform-origin: center center !important;
    animation: centerSwing 2.8s ease-in-out infinite;
}

/* Danh sách link 4 file icon */
.service-item.item-4 .service-icon { background-image: url('/wp-content/uploads/2026/05/icon-tuvan11-2459.png'); }
.service-item.item-3 .service-icon { background-image: url('/wp-content/uploads/2026/05/icon-tuvan05-3835.png'); }
.service-item.item-2 .service-icon { background-image: url('/wp-content/uploads/2026/05/icon-tuvan09-7572.png'); }
.service-item.item-1 .service-icon { background-image: url('/wp-content/uploads/2026/05/icon-tuvan03-1068.png'); }

/* Hiệu ứng đung đưa quanh tâm */
@keyframes centerSwing {
    0% { transform: rotate(0deg); }
    25% { transform: rotate(12deg); }
    50% { transform: rotate(0deg); }
    75% { transform: rotate(-12deg); }
    100% { transform: rotate(0deg); }
}

/* --- ĐÁP ỨNG GIAO DIỆN DI ĐỘNG (RESPONSIVE) --- */
@media (max-width: 768px) {
    .tu-van-wrapper {
        flex-direction: column;
        gap: 30px;
    }
    .col-center {
        order: -1; /* Đưa logo lên đầu hàng */
		flex: 0;
    }
    .item-right, .item-left {
        justify-content: flex-start;
        gap: 20px;
    }
    .item-right {
        flex-direction: row-reverse; /* Đảo icon ra sau chữ trên điện thoại */
    }
    .item-right .service-text, .item-left .service-text {
        text-align: left;
    }
}
/* Khung bao ngoài form màu xanh nhạt, bo góc lớn */
.imta-contact-form {
    background-color: #e6f5ff; /* Màu nền xanh nhạt giống hình */
    border-radius: 24px; /* Bo góc viền ngoài */
    padding: 40px 35px;
    max-width: 550px; /* Độ rộng form */
    margin: 0 auto;
    font-family: sans-serif;
    box-sizing: border-box;
}

/* Tiêu đề ĐĂNG KÝ TƯ VẤN */
.imta-contact-form h2 {
    color: #2b93d1; /* Màu xanh dương của tiêu đề */
    text-align: center;
    font-size: 26px;
    font-weight: bold;
    margin-top: 0;
    margin-bottom: 30px;
    text-transform: uppercase;
}

/* Khoảng cách giữa các ô nhập liệu */
.imta-field-wrap {
    margin-bottom: 16px;
}

/* Định dạng chung cho tất cả các ô input và textarea */
.imta-contact-form input[type="text"],
.imta-contact-form input[type="tel"],
.imta-contact-form input[type="email"],
.imta-contact-form textarea {
    width: 100% !important;
    background-color: #e6f5ff !important; /* Trùng màu nền form hoặc sáng hơn một chút */
    border: 1px solid #b3d7f0 !important; /* Viền mỏng màu xanh */
    border-radius: 8px !important; /* Bo góc ô nhập liệu */
    padding: 12px 16px !important;
    font-size: 15px !important;
    color: #2b93d1 !important; /* Màu chữ khi người dùng gõ vào */
    box-sizing: border-box;
    outline: none;
    transition: all 0.3s ease;
}

/* Định dạng riêng cho chiều cao của ô Nội dung */
.imta-contact-form textarea {
    height: 150px !important;
    resize: none; /* Khóa không cho kéo dãn tự do mất thẩm mỹ */
}

/* Đổi màu chữ gợi ý (Placeholder) thành màu xanh giống hình */
.imta-contact-form ::placeholder {
    color: #2b93d1 !important;
    opacity: 0.8;
}

/* Khi người dùng click vào ô nhập liệu (Focus) */
.imta-contact-form input:focus,
.imta-contact-form textarea:focus {
    border-color: #2b93d1 !important;
    box-shadow: 0 0 5px rgba(43, 147, 209, 0.2);
}

/* Khung chứa nút bấm căn giữa */
.imta-submit-wrap {
    text-align: center;
    margin-top: 25px;
}

/* Đưa khung chứa p về dạng flex để căn giữa input tuyệt đối */
.imta-submit-wrap p {
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative; /* Làm điểm tựa cho spinner */
    margin: 0; /* Xóa margin mặc định của thẻ p */
}

/* Định vị lại spinner để nó không chiếm diện tích, không đẩy nút bấm */
.imta-submit-wrap .wpcf7-spinner {
    position: absolute;
    right: auto;
    /* Bạn có thể chỉnh spinner nằm hẳn sang bên phải nút bấm nếu muốn */
    margin-left: 10px; 
}

/* Định dạng nút ĐĂNG KÝ NGAY */
.imta-contact-form input[type="submit"] {
        background-color: #3ca2d8 !important;
    color: #ffffff !important;
    font-size: 12px !important;
    font-weight: bold !important;
    border: none !important;
    padding: 5px 20px !important;
    border-radius: 0px !important;
    cursor: pointer;
    text-transform: uppercase;
    transition: all 0.3s ease;
}

/* Hiệu ứng đổi màu nhẹ khi hover qua nút bấm */
.imta-contact-form input[type="submit"]:hover {
    background-color: #2b93d1 !important;
}

/* Ẩn các thông báo lỗi mặc định của CF7 nếu nó làm lệch khung */
.imta-contact-form .wpcf7-not-valid-tip {
    font-size: 13px;
    color: #ff0000;
    margin-top: 5px;
}
@media only screen and (max-width: 48em) {
/*************** ADD MOBILE ONLY CSS HERE  ***************/


}
/* Tổng quan khung form liên hệ */
.imta-contact-page-form {
    width: 100%;
    max-width: 850px; /* Bạn có thể tùy chỉnh độ rộng theo layout trang liên hệ */
    margin: 0 auto;
    font-family: system-ui, -apple-system, sans-serif;
    box-sizing: border-box;
}

/* Xử lý chia cột (Hàng) */
.imta-form-row {
    display: flex;
    gap: 20px;
}

/* Các cột chiếm 50% độ rộng */
.imta-form-col {
    flex: 1;
}

/* Các ô chiếm toàn bộ độ rộng */
.imta-form-full {
    width: 100%;
}

/* Định dạng chung cho tất cả ô nhập liệu */
.imta-contact-page-form input[type="text"],
.imta-contact-page-form input[type="tel"],
.imta-contact-page-form input[type="email"],
.imta-contact-page-form textarea {
    width: 100% !important;
    background-color: #ffffff !important;
    border: 1px solid #ccd0d4 !important; /* Viền mỏng màu xám nhạt như hình */
    border-radius: 4px !important; /* Bo góc nhẹ */
    padding: 12px 15px !important;
    font-size: 16px !important;
    color: #333333 !important;
    box-sizing: border-box;
    outline: none;
    transition: border-color 0.2s ease;
}

/* Chiều cao cố định cho ô nội dung */
.imta-contact-page-form textarea {
    height: 120px !important;
    resize: vertical;
}

/* Khi người dùng click vào ô (Focus) */
.imta-contact-page-form input:focus,
.imta-contact-page-form textarea:focus {
    border-color: #2b93d1 !important;
}

/* Màu chữ xám mờ của Placeholder giống hình gốc */
.imta-contact-page-form ::placeholder {
    color: #777777 !important;
    opacity: 0.8;
}

/* --- ĐỊNH DẠNG HÀNG NÚT BẤM --- */
.imta-form-buttons {
    display: flex;
    gap: 10px;
    align-items: center;
    margin-top: 20px;
}

/* Xử lý thẻ p tự động sinh ra của CF7 để nút Gửi không bị lệch dòng */
.imta-form-buttons p {
    margin: 0 !important;
    display: flex;
    align-items: center;
    position: relative;
}

/* Nút Gửi (Xanh dương) */
.imta-contact-page-form input[type="submit"] {
    background-color: #1d72b2 !important; /* Màu xanh dương đậm chuẩn */
    color: #ffffff !important;
    font-size: 16px !important;
    font-weight: normal !important;
    border: none !important;
    padding: 0px 25px !important;
    border-radius: 4px !important;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.imta-contact-page-form input[type="submit"]:hover {
    background-color: #16598c !important;
}

/* Nút Nhập lại (Xám đậm) */
.imta-btn-reset {
    background-color: #5c6b73 !important; /* Màu xám đá giống hình */
    color: #ffffff !important;
    font-size: 16px !important;
    font-weight: normal !important;
    border: none !important;
    padding: 0px 22px !important;
    border-radius: 4px !important;
    cursor: pointer;
    transition: background-color 0.2s ease;
}

.imta-btn-reset:hover {
    background-color: #475359 !important;
}

/* Xử lý cục spinner của CF7 để tránh cấn nút Nhập lại */
.imta-form-buttons .wpcf7-spinner {
    position: absolute;
    left: 100%;
    margin-left: 5px;
}

/* --- ĐÁP ỨNG DI ĐỘNG (RESPONSIVE) --- */
@media (max-width: 600px) {
    .imta-form-row {
        flex-direction: column; /* Chuyển thành 1 cột dọc trên điện thoại */
        gap: 18px;
    }
}