:root {
    --tve-navy: #062d70;
    --tve-blue: #0d64c8;
    --tve-line: #d9e2ee;
    --tve-text: #183653;
    --tve-soft: #f5f8fc;
}

html, body, button, input, select, textarea,
h1, h2, h3, h4, h5, h6, p, a, li, label, table {
    font-family: Roboto, Arial, sans-serif;
}

.tve-footer { background: var(--tve-navy); color: #fff; }
.tve-footer .footer_top { padding: 34px 0 26px; }
.tve-footer .tve-footer-grid { align-items: flex-start; }
.tve-footer .tve-footer-section { height: 100%; padding: 0 12px; }
.tve-footer h3 { color: #fff; font-size: 17px; line-height: 1.45; margin: 0 0 17px; font-weight: 700; }
.tve-footer address { font-style: normal; }
.tve-footer-contact p { display: flex; gap: 9px; align-items: flex-start; margin: 0 0 10px; color: #fff; line-height: 1.55; }
.tve-footer-contact i { width: 16px; margin-top: 4px; text-align: center; flex: 0 0 16px; }
.tve-footer a { color: #fff; }
.tve-footer a:hover { color: #f3a323; }
.tve-footer-menu ul { margin: 0; list-style: none; }
.tve-footer-menu li { border: 0; margin: 0; }
.tve-footer-menu a { display: block; padding: 7px 0; font-size: 16px; font-weight: 400; text-transform: none !important; text-decoration: none !important; }
.tve-social-links { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 16px; }
.tve-social { display: inline-flex; min-height: 34px; align-items: center; justify-content: center; border: 1px solid rgba(255,255,255,.62); border-radius: 5px; padding: 6px 13px; font-weight: 700; }
.tve-social:hover { background: #fff; color: var(--tve-navy); }
.tve-social-icon { width: 42px; height: 42px; padding: 8px; border-color: rgba(255,255,255,.45); border-radius: 50%; background: #fff; }
.tve-social-icon img { width: 24px; height: 24px; object-fit: contain; }
.tve-footer-map iframe { width: 100%; height: 205px; display: block; border: 0; border-radius: 3px; }

.tve-support-card { border: 1px solid var(--tve-line); background: #fff; padding: 14px 16px; color: var(--tve-text); }
.tve-support-card p { display: flex; align-items: center; gap: 9px; margin: 0 0 9px; line-height: 1.45; overflow-wrap: anywhere; }
.tve-support-card p:last-child { margin-bottom: 0; }
.tve-support-card strong { color: var(--tve-navy); }
.tve-support-card i { width: 20px; color: var(--tve-blue); text-align: center; flex: 0 0 20px; }
.tve-support-card .tve-support-icon { width: 20px; height: 20px; object-fit: contain; flex: 0 0 20px; }
.partner-thumbnail p { display: flex; align-items: center; gap: 8px; }
.partner-thumbnail p img { flex: 0 0 auto; }

.tve-news-category-tree ul { list-style: none; margin: 0; padding: 0; }
.tve-news-category-tree li { position: relative; margin: 0; border-bottom: 1px solid #e5eaf0; }
.tve-news-category-tree li:last-child { border-bottom: 0; }
.tve-news-category-tree a { display: block; padding: 10px 36px 10px 12px; color: var(--tve-text); line-height: 1.35; }
.tve-news-category-tree .children { margin: 0; padding-left: 13px; background: #f8fafc; }
.tve-news-category-tree .children a { font-size: 14px; padding-top: 8px; padding-bottom: 8px; }
.tve-news-category-tree li.has-child > .toggle { position: absolute; right: 4px; top: 4px; width: 32px; height: 34px; margin: 0; padding: 0; border: 0; background: transparent; color: var(--tve-navy); opacity: .75; }
.tve-news-category-tree li.has-child > .toggle:hover { opacity: 1; }
.tve-news-category-tree li.has-child > .toggle i { top: 0; font-size: 17px; }
.tve-news-category-tree li.has-child > ul.children { display: none; }
.tve-news-category-tree li.has-child.active > ul.children { display: block; }

.tve-info-page { color: var(--tve-text); }
.tve-page-hero { display: flex; min-height: 132px; flex-direction: column; align-items: center; justify-content: center; background: var(--tve-soft); border-left: 4px solid var(--tve-blue); padding: 24px 28px; margin-bottom: 26px; text-align: center; }
.tve-page-hero h1 { color: var(--tve-navy); font-size: 28px; margin: 0 0 10px; font-weight: 700; }
.tve-page-hero p { margin: 0; line-height: 1.65; text-align: center; }
.tve-info-grid { display: grid; grid-template-columns: repeat(2, minmax(0,1fr)); gap: 20px; margin: 24px 0; }
.tve-info-card { border: 1px solid var(--tve-line); border-radius: 5px; padding: 21px; background: #fff; }
.tve-info-card h2, .tve-info-card h3 { color: var(--tve-navy); font-size: 20px; margin: 0 0 10px; }
.tve-info-card p, .tve-info-card li { line-height: 1.65; }
.tve-info-card ul { margin-bottom: 0; }
.tve-company-letter { max-width: 1040px; margin: 0 auto 28px; padding: 30px 34px; border: 1px solid var(--tve-line); background: #fff; }
.tve-company-letter p, .tve-company-letter li { color: var(--tve-text); line-height: 1.72; }
.tve-company-letter h2 { color: var(--tve-navy); font-size: 22px; margin: 24px 0 12px; }
.tve-company-letter ol { margin-left: 20px; }
.tve-company-contact { max-width: 1040px; margin-left: auto; margin-right: auto; }
.tve-quote-page, .tve-quote-page input, .tve-quote-page textarea, .tve-quote-page button { font-family: Roboto, Arial, sans-serif; }

/* Bộ chuyển ngôn ngữ nằm cùng hàng menu, sát lề phải. */
#wide-nav { position: relative; }
#wide-nav .flex-row.container { position: relative; align-items: center; }
#wide-nav .nav > li > a { display: flex; min-height: 64px; align-items: center; justify-content: center; text-align: center; line-height: 1.25; }
#wide-nav .tve-menu-language { position: absolute !important; top: 50% !important; right: 12px !important; bottom: auto !important; left: auto !important; transform: translateY(-50%) !important; display: flex !important; align-items: center; justify-content: center; height: auto !important; margin: 0; z-index: 40 !important; }
#wide-nav .tve-menu-language #gt_float_wrapper { position: static !important; inset: auto !important; display: flex !important; align-items: center; justify-content: center; }
#wide-nav .tve-menu-language .gt_float_switcher { font-family: Roboto, Arial, sans-serif !important; font-size: 14px !important; line-height: 18px !important; border: 1px solid rgba(255,255,255,.32); border-radius: 4px; box-shadow: none; background: rgba(255,255,255,.1); }
#wide-nav .tve-menu-language .gt-selected,
#wide-nav .tve-menu-language .gt-current-lang { background: transparent !important; color: #fff !important; }
#wide-nav .tve-menu-language .gt-current-lang { display: flex !important; align-items: center; justify-content: center; gap: 4px; min-height: 40px; padding: 7px 9px !important; text-align: center; text-decoration: none !important; }
#wide-nav .tve-menu-language .gt-current-lang img { width: 25px !important; margin-right: 4px !important; }
#wide-nav .tve-menu-language .gt-lang-code { display: inline-flex; align-items: center; justify-content: center; color: #fff !important; line-height: 1 !important; text-align: center; text-decoration: none !important; }
#wide-nav .tve-menu-language .gt_options { position: absolute !important; right: 0; top: 100%; bottom: auto; min-width: 112px; background: #fff; border-radius: 0 0 4px 4px; box-shadow: 0 6px 18px rgba(0,0,0,.18); }

/* Ba thẻ thông tin báo giá bằng nhau và trạng thái gửi không làm lệch nút. */
.page-id-48 .tve-quote-page .row { align-items: stretch; }
.page-id-48 .tve-quote-page .row > .col { display: flex; }
.page-id-48 .tve-quote-page .row > .col > .col-inner,
.page-id-48 .tve-quote-page .banner-address { width: 100%; height: 100%; }
.page-id-48 .tve-quote-submit { position: relative; min-height: 48px; }
.page-id-48 .tve-quote-submit .wpcf7-spinner { position: absolute; left: calc(50% + 145px); top: 12px; margin: 0; }
.page-id-48 #tve-quote-form { scroll-margin-top: 190px; }
.page-id-48 .box-address h4 { white-space: normal !important; overflow-wrap: anywhere; max-width: 100%; }

.tve-top-contact ul { display: flex; align-items: center; gap: 22px; margin: 0; }
.tve-top-contact li, .tve-top-contact p { margin: 0; }
.tve-top-contact a { color: inherit; }

/* Product search directly above the homepage product cards. */
.tve-product-search-toolbar { position: relative; z-index: 70; width: 100%; margin: 0 0 14px; padding: 0 5px; background: transparent; border: 0; text-align: left; }
.tve-product-search-inner { width: 100%; max-width: none; margin: 0; padding: 0; }
.tve-product-search-form { position: relative; display: flex; margin: 0; }
.tve-search-label { position: absolute; width: 1px; height: 1px; padding: 0; margin: -1px; overflow: hidden; clip: rect(0,0,0,0); white-space: nowrap; border: 0; }
.tve-product-search-form input[type="search"] { width: 100%; height: 46px; min-width: 0; margin: 0 !important; padding: 0 18px; color: var(--tve-text); background: #fff; border: 2px solid var(--tve-blue); border-right: 0; border-radius: 8px 0 0 8px; box-shadow: none !important; font-size: 15px; }
.tve-product-search-form input[type="search"]:focus { border-color: var(--tve-navy); box-shadow: 0 0 0 3px rgba(13,100,200,.13) !important; outline: 0; }
.tve-product-search-button { display: inline-flex; flex: 0 0 auto; min-width: 126px; height: 46px; margin: 0 !important; padding: 0 18px; align-items: center; justify-content: center; gap: 8px; border: 0; border-radius: 0 8px 8px 0; color: #fff; background: var(--tve-navy); font-size: 14px; font-weight: 700; text-transform: none; }
.tve-product-search-button:hover { color: #fff; background: var(--tve-blue); }
.tve-product-search-button svg { width: 20px; height: 20px; fill: currentColor; }
.tve-product-search-results { position: absolute; top: calc(100% + 6px); left: 0; right: 0; max-height: min(470px, 70vh); overflow-y: auto; background: #fff; border: 1px solid #cdd9e7; border-radius: 8px; box-shadow: 0 14px 34px rgba(6,45,112,.18); }
.tve-product-search-results[hidden] { display: none !important; }
.tve-search-result { display: grid; grid-template-columns: 64px minmax(0,1fr) auto; gap: 12px; align-items: center; min-height: 82px; padding: 9px 13px; color: var(--tve-text); border-bottom: 1px solid #e6ebf2; text-decoration: none !important; }
.tve-search-result:last-child { border-bottom: 0; }
.tve-search-result:hover, .tve-search-result.is-active { color: var(--tve-navy); background: #f0f6fd; }
.tve-search-result > img { width: 64px; height: 64px; padding: 3px; object-fit: contain; background: #fff; border: 1px solid #e3e8ef; border-radius: 5px; }
.tve-search-result-body { display: flex; min-width: 0; flex-direction: column; gap: 5px; }
.tve-search-result-body strong { color: var(--tve-navy); font-size: 14px; line-height: 1.35; text-transform: none; }
.tve-search-result-body small { color: #68798d; font-size: 12px; line-height: 1.35; }
.tve-search-contact { padding: 5px 8px; color: #b0441d; background: #fff1e9; border-radius: 4px; font-size: 12px; font-weight: 700; white-space: nowrap; }
.tve-search-status { padding: 18px; color: #5d6f83; text-align: center; font-size: 14px; }

/* Khung hãng trên trang Đối tác. */
.tve-brand-showcase { margin: 30px 0; border: 2px solid #1595d3; border-radius: 10px; padding: 42px 48px 30px; position: relative; background: #fff; }
.tve-brand-showcase h2 { position: absolute; top: -23px; left: 50%; transform: translateX(-50%); display: flex !important; align-items: center !important; justify-content: center !important; min-height: 44px; margin: 0; padding: 9px 30px; color: #fff; background: #1595d3; font-size: 20px; font-weight: 500; border-radius: 4px; white-space: nowrap; text-align: center !important; }
.tve-brand-carousel { position: relative; overflow: hidden; }
.tve-brand-track { display: flex; gap: 18px; overflow-x: auto; scroll-behavior: smooth; scrollbar-width: none; padding: 8px 2px; }
.tve-brand-track::-webkit-scrollbar { display: none; }
.tve-brand-card { flex: 0 0 190px; height: 108px; display: flex; align-items: center; justify-content: center; text-align: center; border: 1px solid #87bfe5; border-radius: 7px; padding: 14px; color: var(--tve-navy); background: #fff; }
.tve-brand-card img { display: block; width: 100%; height: 70px; object-fit: contain; object-position: center; }
.tve-brand-nav { position: absolute; top: 50%; transform: translateY(-50%); width: 34px; height: 44px; border: 0; background: rgba(255,255,255,.92); color: #168fc9; font-size: 28px; padding: 0; z-index: 2; box-shadow: 0 2px 8px rgba(0,0,0,.08); }
.tve-brand-prev { left: 4px; }
.tve-brand-next { right: 4px; }

/* Tiêu đề các khối trên trang chủ được căn đúng tâm của thanh tiêu đề. */
.home .widgettitle { display: flex; min-height: 49px; align-items: center; justify-content: center; text-align: center; line-height: 1.3; }
.home .section-title { align-items: center; justify-content: center; text-align: center; }
.home .section-title > b { flex: 1 1 0; }
.home .section-title .section-title-main { flex: 0 0 auto; text-align: center; }

@media (max-width: 849px) {
    .tve-footer .footer_top { padding: 26px 0 16px; }
    .tve-footer .tve-footer-section { padding: 0 4px 24px; }
    .tve-info-grid { grid-template-columns: 1fr; }
    .tve-page-hero { padding: 20px; }
    .tve-company-letter { padding: 22px 18px; }
    #top-bar { display: none !important; }
    #gt_float_wrapper { display: block !important; }
    .tve-product-search-toolbar { margin-bottom: 12px; padding: 0; }
    .tve-product-search-inner { padding: 0; }
    .tve-product-search-form input[type="search"] { height: 44px; padding: 0 12px; font-size: 14px; }
    .tve-product-search-button { min-width: 48px; width: 48px; height: 44px; padding: 0; }
    .tve-product-search-button span { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0,0,0,0); }
    .tve-product-search-results { max-height: min(420px, 65vh); }
    .tve-search-result { grid-template-columns: 54px minmax(0,1fr); min-height: 72px; gap: 9px; padding: 8px 9px; }
    .tve-search-result > img { width: 54px; height: 54px; }
    .tve-search-contact { grid-column: 2; justify-self: start; margin-top: -3px; }
    .tve-brand-showcase { padding: 38px 34px 22px; }
    .tve-brand-showcase h2 { font-size: 16px; padding: 8px 18px; }
    .tve-brand-card { flex-basis: 150px; height: 82px; font-size: 15px; }
    .tve-brand-card img { height: 54px; }
    .page-id-48 .tve-quote-page,
    .page-id-48 .tve-quote-page .section-content { width: 100% !important; max-width: 100% !important; overflow-x: clip; }
    .page-id-48 .tve-quote-page .row { width: 100% !important; max-width: 100% !important; margin-left: 0 !important; margin-right: 0 !important; padding: 0 10px; box-sizing: border-box; }
    .page-id-48 .tve-quote-page .row > .col { display: block; width: 100% !important; max-width: 100% !important; min-width: 0 !important; flex: 0 0 100% !important; padding: 0 0 20px !important; box-sizing: border-box; }
    .page-id-48 .tve-quote-page .row > .col > .col-inner,
    .page-id-48 .tve-quote-page .banner-address,
    .page-id-48 .tve-quote-page .box-text,
    .page-id-48 .tve-quote-page .box-text-inner,
    .page-id-48 .tve-quote-page .box-address { width: 100% !important; max-width: 100% !important; min-width: 0 !important; box-sizing: border-box; }
    .page-id-48 .tve-quote-page .box-address h4,
    .page-id-48 .tve-quote-page .box-address p,
    .page-id-48 .tve-quote-page .box-address a { max-width: 100%; overflow-wrap: anywhere; word-break: normal; }
    .page-id-48 .tve-quote-page > .section-content > .button.expand { display: block; width: calc(100% - 20px) !important; max-width: calc(100% - 20px) !important; margin-left: 10px !important; margin-right: 10px !important; box-sizing: border-box; }
    .page-id-48 .tve-quote-submit .wpcf7-spinner { left: auto; right: 6px; }
    .page-id-48 .tve-quote-page .button.expand { width: 100%; max-width: 100%; height: auto !important; min-height: 48px; padding: 10px 14px !important; font-size: 14px; line-height: 1.35; white-space: normal !important; }
    .page-id-48 .tve-quote-page .button.expand span { white-space: normal !important; }
}
