/* ============================================================
   THO.com.vn Theme CSS v1.0 | Author: dev.com.vn
   ============================================================ */

/* =============================================
   HEADER
   ============================================= */
.tho-header {
  height: 74px; background: #fff; border-bottom: 1px solid #e9f0fb;
  position: sticky; top: 0; z-index: 60;
}
.tho-header-inner {
  max-width: 1130px; margin: 0 auto; padding: 0 18px;
  height: 74px; display: flex; align-items: center; gap: 28px;
}

/* Brand logo */
.tho-brand {
  display: flex; align-items: center; gap: 10px;
  width: 235px; flex: 0 0 235px; text-decoration: none;
}
.tho-mascot {
  width: 44px; height: 44px; border-radius: 50%;
  background: linear-gradient(135deg, #ffd45e, #ff9b16);
  display: grid; place-items: center; font-size: 26px;
  box-shadow: 0 8px 20px rgba(255,151,15,.24); flex-shrink: 0;
}
.tho-brand-text strong {
  display: block; color: #123170; font-size: 28px; line-height: .95;
  font-weight: 900; letter-spacing: -1px;
}
.tho-brand-text strong span { font-size: 18px; color: #1d365d; }
.tho-brand-text small { display: block; color: #65758e; font-size: 11px; font-weight: 700; margin-top: 3px; }

/* Primary nav */
.tho-nav {
  flex: 1; display: flex; align-items: center; justify-content: center;
  gap: 0; height: 100%; list-style: none; margin: 0; padding: 0;
}
.tho-menu-item { position: relative; }
.tho-menu-link {
  height: 74px; display: flex; align-items: center; gap: 4px;
  color: #263956; font-size: 13px; font-weight: 800;
  white-space: nowrap; padding: 0 14px; position: relative; text-decoration: none;
  transition: color .15s;
}
.tho-menu-link:hover,
.tho-menu-link.active { color: var(--blue, #1266d8); }
.tho-menu-link.active::after {
  content: ''; position: absolute; left: 14px; right: 14px;
  bottom: 0; height: 3px; background: var(--blue, #1266d8);
  border-radius: 3px 3px 0 0;
}
.tho-arrow { font-size: 10px; color: var(--muted, #7f8da2); transition: transform .2s; }
.tho-menu-item:hover .tho-arrow { transform: rotate(180deg); }

/* Dropdown */
.tho-nav .sub-menu {
  position: absolute; top: 100%; left: 0; min-width: 210px;
  background: #fff; border: 1px solid #e5edf8; border-radius: 10px;
  box-shadow: 0 20px 40px rgba(18,39,90,.14); padding: 8px 0;
  list-style: none; opacity: 0; visibility: hidden; transform: translateY(6px);
  transition: opacity .2s, transform .2s; z-index: 200;
}
.tho-nav .sub-menu.align-right { left: auto; right: 0; }
.tho-menu-item:hover > .sub-menu {
  opacity: 1; visibility: visible; transform: translateY(0);
}
.tho-nav .sub-menu li a {
  display: block; padding: 9px 18px;
  font-size: 12.5px; color: #344060; font-weight: 700; transition: .15s;
}
.tho-nav .sub-menu li a:hover { color: var(--blue, #1266d8); background: #f0f7ff; }
/* Level 3 */
.tho-nav .sub-menu .sub-menu {
  top: 0; left: 100%; margin-top: 0;
}

/* Header actions */
.tho-header-actions { display: flex; align-items: center; gap: 10px; }
.tho-btn-login {
  height: 38px; border-radius: 8px; font-size: 12px; font-weight: 900;
  display: inline-flex; align-items: center; padding: 0 17px;
  border: 1px solid #bdd4f5; color: #164b9e; background: #fff;
  cursor: pointer; transition: .2s; text-decoration: none;
}
.tho-btn-login:hover { background: #edf5ff; }
.tho-btn-signup {
  height: 38px; border-radius: 8px; font-size: 12px; font-weight: 900;
  display: inline-flex; align-items: center; padding: 0 17px;
  background: var(--orange, #ff970f); color: #fff; border: none;
  cursor: pointer; transition: .2s; text-decoration: none;
}
.tho-btn-signup:hover { background: #e08500; }

.tho-menu-toggle {
  display: none; width: 40px; height: 40px;
  border: 1px solid #dfe8f6; border-radius: 9px; background: #fff;
  color: var(--blue, #1266d8); font-size: 22px; cursor: pointer;
  margin-left: auto; align-items: center; justify-content: center;
}

/* =============================================
   HERO SECTION
   ============================================= */
.tho-hero {
  position: relative; background: #eef6ff; overflow: hidden; min-height: 340px;
}
.tho-hero-bg {
  position: absolute; right: 0; top: 0; bottom: 0; width: 56%; z-index: 0;
}
.tho-hero-bg img { width: 100%; height: 100%; object-fit: cover; }
.tho-hero::after {
  content: ''; position: absolute; inset: 0; z-index: 1;
  background: linear-gradient(90deg, #fff 0%, rgba(255,255,255,.96) 38%, rgba(255,255,255,.58) 62%, rgba(255,255,255,.03) 100%);
}
.tho-hero-grid {
  position: relative; z-index: 2; max-width: 1130px; margin: 0 auto; padding: 0 18px;
  display: grid; grid-template-columns: .95fr 1.05fr; align-items: center; min-height: 320px;
}
.tho-hero-copy { padding: 45px 0 62px; }
.tho-hero h1 {
  font-size: 38px; line-height: 1.18; color: #11285d; font-weight: 900;
  letter-spacing: -.75px; margin-bottom: 14px;
}
.tho-hero h1 span { color: var(--orange, #ff970f); }
.tho-hero-sub { max-width: 520px; color: #4b5b78; font-size: 15px; line-height: 1.75; margin-bottom: 22px; }

/* Hero feature pills */
.tho-hero-features { display: grid; grid-template-columns: repeat(3, 1fr); gap: 14px; max-width: 620px; }
.tho-hero-feature { display: grid; grid-template-columns: 38px 1fr; gap: 10px; align-items: center; }
.tho-hero-feature i {
  width: 34px; height: 34px; border-radius: 9px; background: #fff; color: var(--blue, #1266d8);
  border: 1px solid #dce8fb; display: grid; place-items: center;
  font-style: normal; font-size: 18px; box-shadow: 0 8px 22px rgba(8,57,139,.08);
}
.tho-hero-feature strong { display: block; color: #25395d; font-size: 12px; font-weight: 900; }
.tho-hero-feature span { display: block; color: #78869c; font-size: 10.5px; line-height: 1.38; }

/* Live card */
.tho-live-card {
  position: absolute; right: 68px; bottom: 40px; z-index: 3;
  background: #fff; border-radius: 10px; box-shadow: 0 15px 35px rgba(8,57,139,.14);
  padding: 14px 18px; min-width: 150px;
}
.tho-live-card small {
  display: flex; align-items: center; gap: 7px;
  color: #52647d; font-size: 11px; font-weight: 800;
}
.tho-live-card small::before {
  content: ''; width: 8px; height: 8px; border-radius: 50%; background: #17c964; flex-shrink: 0;
}
.tho-live-card strong { display: block; color: var(--blue, #1266d8); font-size: 28px; line-height: 1; margin: 8px 0 4px; }
.tho-live-card span { font-size: 11px; color: #7f8da2; font-weight: 700; }

/* Search panel */
.tho-search-panel {
  position: relative; z-index: 5; margin-top: -42px;
  max-width: 1130px; margin-left: auto; margin-right: auto; padding: 0 18px;
}

/* =============================================
   PROMO BANNER
   ============================================= */
.tho-promo-banner {
  background: linear-gradient(100deg, #0860dc, #0875f3);
  border-radius: 10px; margin: 20px 0 18px; color: #fff;
  display: grid; grid-template-columns: 210px 1fr 170px;
  gap: 20px; align-items: center; overflow: hidden; padding: 20px 26px;
}
.tho-promo-mascot { height: 92px; display: grid; place-items: center; position: relative; }
.tho-promo-mascot::before { content: '👷‍♂️'; font-size: 64px; }
.tho-promo-label {
  position: absolute; right: 0; top: 15px;
  background: #ffd33d; color: #16406e; font-weight: 900; font-size: 13px;
  border-radius: 12px; padding: 10px 14px; box-shadow: 0 10px 22px rgba(0,0,0,.16);
}
.tho-promo-banner h2 { font-size: 22px; color: #fff; font-weight: 900; margin-bottom: 4px; }
.tho-promo-banner h2 span { color: #ffd33d; }
.tho-promo-banner p { font-size: 13px; color: #dff0ff; }
.tho-promo-banner a {
  height: 44px; border-radius: 8px; background: #fff; color: #0a55c3;
  display: flex; align-items: center; justify-content: center;
  font-size: 14px; font-weight: 900; text-decoration: none; white-space: nowrap;
}
.tho-promo-banner a:hover { background: #f0f5ff; }

/* Why strip */
.tho-why-strip {
  display: grid; grid-template-columns: repeat(6, 1fr);
  background: #fff; border: 1px solid #dfe8f6; border-radius: 11px;
  box-shadow: 0 8px 22px rgba(8,57,139,.08); overflow: hidden;
}
.tho-why-item {
  display: grid; grid-template-columns: 40px 1fr; gap: 10px;
  align-items: center; padding: 17px 14px; border-right: 1px solid #dfe8f6;
}
.tho-why-item:last-child { border-right: 0; }
.tho-why-item i {
  width: 36px; height: 36px; border-radius: 50%; background: var(--soft-blue, #edf5ff);
  color: var(--blue, #1266d8); display: grid; place-items: center;
  font-style: normal; font-size: 20px;
}
.tho-why-item strong { display: block; color: #2f3d60; font-size: 12px; font-weight: 900; }
.tho-why-item span { font-size: 10.5px; color: #7c8494; line-height: 1.42; }

/* Process steps */
.tho-process-wrap { display: grid; grid-template-columns: 1fr 250px; gap: 24px; align-items: center; }
.tho-process-grid {
  display: grid; grid-template-columns: repeat(6, 1fr); gap: 24px; position: relative;
}
.tho-process-grid::before {
  content: ''; position: absolute; left: 7%; right: 7%;
  top: 28px; height: 2px; background: #d8e6f8;
}
.tho-process-item { position: relative; z-index: 2; text-align: center; }
.tho-process-item::after {
  content: '→'; position: absolute; right: -16px; top: 18px;
  color: #8bb1e8; font-weight: 900;
}
.tho-process-item:last-child::after { display: none; }
.tho-process-icon {
  width: 58px; height: 58px; border-radius: 50%; background: var(--soft-blue, #edf5ff);
  color: var(--blue, #1266d8); display: grid; place-items: center;
  font-style: normal; font-size: 24px; margin: 0 auto 11px;
  border: 7px solid #fff; box-shadow: 0 8px 22px rgba(8,57,139,.08);
}
.tho-process-item strong { display: block; color: #203866; font-size: 12px; font-weight: 900; margin-bottom: 4px; }
.tho-process-item span { display: block; color: #7a879e; font-size: 10.5px; line-height: 1.4; }
.tho-call-card {
  background: var(--soft-blue, #edf5ff); border-radius: 12px; padding: 22px; text-align: center;
}
.tho-call-card i {
  width: 48px; height: 48px; border-radius: 50%; background: #fff;
  color: var(--blue, #1266d8); display: grid; place-items: center;
  margin: 0 auto 10px; font-style: normal; font-size: 24px;
  box-shadow: 0 8px 22px rgba(8,57,139,.08);
}
.tho-call-card p { color: #243b66; font-size: 15px; font-weight: 900; line-height: 1.4; }
.tho-call-card strong { display: block; color: var(--orange, #ff970f); font-size: 28px; line-height: 1.1; margin-top: 10px; }

/* =============================================
   FOOTER
   ============================================= */
.tho-footer { background: linear-gradient(180deg, #06275a, #041b40); color: #fff; padding: 36px 0 14px; }
.tho-footer-inner { max-width: 1130px; margin: 0 auto; padding: 0 18px; }
.tho-footer-grid { display: grid; grid-template-columns: 1.5fr repeat(3, 1fr) 1.15fr; gap: 30px; }
.tho-footer .tho-brand-text strong { color: #fff; }
.tho-footer .tho-brand-text strong span { color: #c9ddff; }
.tho-footer .tho-brand-text small { color: #c8d9f6; }
.tho-footer-desc { margin-top: 12px; font-size: 12px; color: #cbd9f7; line-height: 1.75; }
.tho-footer-socials { display: flex; gap: 9px; margin-top: 16px; }
.tho-social-icon {
  width: 32px; height: 32px; border-radius: 50%;
  background: rgba(255,255,255,.12); display: grid; place-items: center;
  font-size: 14px; color: #fff; transition: background .2s;
}
.tho-social-icon:hover { background: rgba(255,255,255,.25); }
.tho-footer h3 { font-size: 13px; text-transform: uppercase; color: #fff; margin-bottom: 14px; }
.tho-footer ul { list-style: none; display: grid; gap: 6px; }
.tho-footer ul li a { font-size: 12px; color: #cbd9f7; line-height: 1.75; transition: color .15s; }
.tho-footer ul li a:hover { color: #fff; }
.tho-footer-contact p { font-size: 12px; color: #cbd9f7; line-height: 2; }
.tho-footer-contact a { color: #cbd9f7; }
.tho-footer-contact a:hover { color: #fff; }
.tho-footer-bottom {
  border-top: 1px solid rgba(255,255,255,.13); margin-top: 28px; padding-top: 14px;
  color: #a9bce2; font-size: 12px; text-align: center;
}

/* =============================================
   SINGLE WORKER PAGE
   ============================================= */
.tho-worker-single { max-width: 1130px; margin: 0 auto; padding: 24px 18px; }
.tho-worker-single .tho-worker-header {
  display: grid; grid-template-columns: 260px 1fr; gap: 30px;
  background: #fff; border: 1px solid var(--line, #dfe8f6);
  border-radius: 14px; box-shadow: var(--shadow-soft); padding: 28px; margin-bottom: 28px;
}
.tho-worker-avatar { width: 100%; aspect-ratio: 1; border-radius: 12px; overflow: hidden; background: var(--soft-blue, #edf5ff); }
.tho-worker-avatar img { width: 100%; height: 100%; object-fit: cover; }
.tho-worker-avatar .tho-avatar-initials { font-size: 64px; height: 100%; border-radius: 12px; }
.tho-worker-info h1 { font-size: 26px; color: var(--ink, #12275a); font-weight: 900; margin-bottom: 4px; }
.tho-worker-info .tho-worker-role-big { font-size: 15px; color: var(--muted, #7f8da2); margin-bottom: 14px; }
.tho-worker-stats { display: flex; flex-wrap: wrap; gap: 20px; margin-bottom: 18px; }
.tho-worker-stat strong { display: block; font-size: 22px; color: var(--blue, #1266d8); font-weight: 900; }
.tho-worker-stat span { font-size: 11px; color: var(--muted, #7f8da2); }
.tho-worker-actions { display: flex; gap: 12px; flex-wrap: wrap; }

/* =============================================
   SINGLE SERVICE PAGE
   ============================================= */
.tho-service-single { max-width: 1130px; margin: 0 auto; padding: 24px 18px; }
.tho-service-banner { width: 100%; height: 360px; border-radius: 14px; overflow: hidden; margin-bottom: 28px; }
.tho-service-banner img { width: 100%; height: 100%; object-fit: cover; }
.tho-service-info-bar {
  display: grid; grid-template-columns: repeat(4, 1fr); gap: 16px;
  background: #fff; border: 1px solid var(--line, #dfe8f6);
  border-radius: 10px; padding: 18px; margin-bottom: 24px;
  box-shadow: var(--shadow-soft);
}
.tho-service-info-item strong { display: block; font-size: 15px; color: var(--blue, #1266d8); font-weight: 900; }
.tho-service-info-item span { font-size: 11.5px; color: var(--muted, #7f8da2); }

/* =============================================
   RESPONSIVE – HEADER
   ============================================= */
@media (max-width: 1024px) {
  .tho-nav { gap: 0; }
  .tho-menu-link { padding: 0 10px; font-size: 12px; }
}

@media (max-width: 820px) {
  .tho-header { height: auto; }
  .tho-header-inner { height: 64px; flex-wrap: wrap; }
  .tho-brand { width: auto; flex: 1; }
  .tho-brand-text strong { font-size: 24px; }

  .tho-nav {
    display: none; position: absolute; left: 0; right: 0; top: 64px;
    background: #fff; border-bottom: 1px solid var(--line, #dfe8f6);
    box-shadow: 0 16px 28px rgba(18,103,216,.13); height: auto;
    flex-direction: column; align-items: stretch; padding: 8px 14px; z-index: 70;
  }
  .tho-nav.open { display: flex; }
  .tho-menu-link { height: 44px; border-bottom: 1px solid var(--line, #dfe8f6); }
  .tho-menu-link.active::after { display: none; }
  .tho-nav .sub-menu { position: static; opacity: 1; visibility: visible; transform: none; box-shadow: none; border: 0; padding: 0 0 0 14px; background: #f7fbff; }
  .tho-nav .sub-menu.align-right { left: 0; right: auto; }

  .tho-btn-login, .tho-btn-signup { display: none; }
  .tho-menu-toggle { display: flex; }

  .tho-hero-grid { grid-template-columns: 1fr; }
  .tho-hero-bg { width: 100%; opacity: .4; }
  .tho-hero h1 { font-size: 28px; }
  .tho-hero-features { grid-template-columns: 1fr; }
  .tho-live-card { display: none; }

  .tho-process-wrap { grid-template-columns: 1fr; }
  .tho-process-grid { grid-template-columns: repeat(3, 1fr); }
  .tho-process-grid::before, .tho-process-item::after { display: none; }

  .tho-why-strip { grid-template-columns: repeat(3, 1fr); }
  .tho-why-item:nth-child(3) { border-right: 0; }

  .tho-promo-banner { grid-template-columns: 1fr; text-align: center; }
  .tho-promo-mascot { height: 70px; }

  .tho-footer-grid { grid-template-columns: 1fr 1fr; }
  .tho-footer-grid > div:first-child { grid-column: 1 / -1; }

  .tho-worker-single .tho-worker-header { grid-template-columns: 180px 1fr; }
}

@media (max-width: 520px) {
  .tho-hero h1 { font-size: 24px; }
  .tho-hero-copy { padding: 30px 0 60px; }
  .tho-search-panel { margin-top: -30px; }
  .tho-why-strip { grid-template-columns: repeat(2, 1fr); }
  .tho-process-grid { grid-template-columns: repeat(2, 1fr); }
  .tho-footer-grid { grid-template-columns: 1fr 1fr; }
  .tho-footer-grid > div:first-child { grid-column: auto; }
  .tho-worker-single .tho-worker-header { grid-template-columns: 1fr; }
}


/* === ChatGPT bugfix v1.0.1: chống co/vỡ header + overflow === */
html, body { max-width:100%; overflow-x:hidden; }
.tho-header-inner { display:flex; align-items:center; gap:18px; flex-wrap:nowrap; max-width:1200px; margin:0 auto; padding-left:16px; padding-right:16px; }
.tho-brand { flex:0 0 auto; min-width:0; display:flex; align-items:center; gap:10px; }
.tho-brand img, .tho-brand .custom-logo { max-height:56px; width:auto; object-fit:contain; }
.tho-nav { flex:1 1 auto; min-width:0; display:flex; justify-content:center; align-items:center; gap:4px; list-style:none; margin:0; padding:0; }
.tho-nav > li, .tho-menu-item { list-style:none; margin:0; }
.tho-header-actions { flex:0 0 auto; display:flex; align-items:center; gap:8px; flex-wrap:nowrap; }
img { max-width:100%; height:auto; }
@media (max-width:991px){ .tho-nav{display:none}.tho-menu-toggle{display:inline-flex!important}.tho-header-inner{justify-content:space-between}.tho-btn-login,.tho-btn-signup{display:none!important} }
