/* HTKS overlay: keep the Jilani theme, make layouts fluid on PC / tablet / phone */

html {
  -webkit-text-size-adjust: 100%;
  text-size-adjust: 100%;
}

body {
  overflow-x: hidden;
}

img,
svg,
video,
iframe {
  max-width: 100%;
  height: auto;
}

.wrapper {
  width: 100%;
  max-width: 1375px;
  margin-left: auto;
  margin-right: auto;
  padding-left: clamp(16px, 3vw, 40px);
  padding-right: clamp(16px, 3vw, 40px);
  box-sizing: border-box;
}

.main_logo img,
.logo_slide_right img,
.footer_logo img {
  max-width: 100%;
  height: auto;
}

@media (max-width: 1000px) {
  .main_logo .htks-header-logo,
  .logo_slide_right .htks-header-logo {
    width: auto;
    max-height: 42px;
  }
}

@media (max-width: 767px) {
  .main_logo .htks-header-logo {
    max-height: 38px;
  }
}

.bnr_flex,
.btm1_info_btn {
  display: flex;
  flex-wrap: wrap;
  gap: 12px 16px;
}

.bnr_flex .priBtn,
.btm1_info_btn .priBtn,
.form_btn,
button.priBtn {
  max-width: 100%;
}

#carousel_slider,
.owl-carousel,
.owl-stage-outer {
  overflow: hidden;
}

/* —— Large desktop: keep theme, just prevent edge clipping —— */
@media (min-width: 1201px) {
  .wrapper {
    padding-left: 20px;
    padding-right: 20px;
  }
}

/* —— PC desktop: header layout handled in header.css (Jilani reference) —— */
@media (min-width: 1001px) {
  /* Override theme media.min.css .main_logo width/top rules for green header logo */
  #header .main_logo,
  #header .main_logo.static {
    width: auto !important;
    max-width: none !important;
    top: calc(100% + (var(--htks-nav-bar-height) / 2)) !important;
    transform: translateY(-50%);
    left: max(20px, calc(50% - 667.5px)) !important;
  }

  #header .main_logo .htks-header-logo {
    height: clamp(42px, 3.4vw, 52px);
    width: auto;
    max-width: min(390px, 38vw);
  }
}

@media (min-width: 1001px) and (max-width: 1500px) {
  #header .main_logo .htks-header-logo {
    height: clamp(38px, 3vw, 48px);
    max-width: min(310px, 36vw);
  }
}

@media (min-width: 1001px) and (max-width: 1200px) {
  #header .main_logo .htks-header-logo {
    height: clamp(34px, 2.8vw, 42px);
    max-width: min(250px, 34vw);
  }
}

/* —— Small desktop / large tablet landscape —— */
@media (max-width: 1200px) {
  .headh2,
  #main_area .h1_title,
  .bnr_info h2 {
    word-break: break-word;
  }

  .page_nav ul li a {
    white-space: nowrap;
  }
}

/* —— Tablet + phone: hamburger nav is already in theme at 1000px —— */
@media (max-width: 1000px) {
  .header_con,
  .head_info,
  .header_info ul {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
  }

  .header_info ul {
    gap: 10px 18px;
    flex-wrap: wrap;
    justify-content: center;
    padding: 0;
    margin: 0;
  }

  .header_info ul li {
    list-style: none;
  }

  .social_media ul {
    display: flex;
    justify-content: center;
    gap: 10px;
    padding: 8px 0 0;
    margin: 0;
  }

  .nav_toggle_button .toggle_holder,
  .hamburger {
    min-width: 44px;
    min-height: 44px;
  }

  .toggle_right_nav .page_nav {
    max-width: min(320px, 86vw);
  }

  .page_nav ul {
    display: block;
  }

  .page_nav ul li a {
    white-space: normal;
    display: block;
    padding: 12px 16px;
    font-size: 16px;
    font-weight: 700;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    line-height: 1.35;
  }

  .page_nav .sub-menu {
    position: static;
    width: 100%;
    box-shadow: none;
  }

  .bnr_info {
    width: 100%;
    max-width: 100%;
    padding: 36px 20px;
    text-align: center;
  }

  body.front_page .bnr_info {
    padding: 45px 25px;
  }

  .bnr_info h2,
  .bnr_info .headh2 {
    font-size: clamp(1.7rem, 6vw, 3.2rem);
    line-height: 1.15;
  }

  .bnr_flex {
    justify-content: center;
  }

  .bnr_flex .priBtn {
    flex: 1 1 220px;
    text-align: center;
    justify-content: center;
  }

  body.front_page .bnr_flex .priBtn {
    flex: 0 0 auto;
    width: 100%;
  }

  .non_home_page .page_title {
    width: 100%;
  }

  .non_home_page .page_title .h1_title {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }

  .btm2_boxes,
  .btm3_boxes,
  .btm5_boxes,
  .flex-4box,
  .flex-3box {
    display: flex;
    flex-wrap: wrap;
    gap: 18px;
    justify-content: center;
  }

  .btm2_boxes section,
  .flex-4box section {
    flex: 1 1 calc(50% - 18px);
    width: auto;
    max-width: 100%;
    min-height: 0;
  }

  .btm3_boxes section,
  .btm5_boxes section,
  .flex-3box section {
    flex: 1 1 calc(50% - 18px);
    width: auto;
    max-width: 100%;
  }

  .btm4_con {
    display: flex;
    flex-direction: column;
    gap: 36px;
  }

  .btm4_info,
  .btm4_faq_con {
    width: 100%;
    max-width: 100%;
    float: none;
  }

  footer .footer_top_con {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    gap: 28px;
  }

  footer .footer_separators {
    display: none !important;
  }

  footer .footer_accreditions {
    flex-direction: row;
    flex-wrap: wrap;
    justify-content: center;
    gap: 14px 20px;
  }

  footer .footer_form,
  footer .contact_list,
  footer .footer_logo,
  footer .footer_accreditions {
    width: 100%;
    max-width: 660px;
  }

  footer .footer_form {
    min-width: min(100%, 500px);
    max-width: 660px !important;
  }

  footer .form_flex {
    display: flex;
    flex-direction: column;
    gap: 12px;
  }

  footer .form_flex input,
  footer .form_flex textarea,
  footer .footer_form form input,
  footer .footer_form textarea,
  footer .footer_form .disclaimer,
  footer .footer_form .disclaimer p,
  footer .footer_form .disclaimer p b {
    width: 100%;
    max-width: 100%;
    box-sizing: border-box;
  }

  footer .footer_nav ul {
    display: flex;
    flex-wrap: wrap;
    justify-content: flex-start;
    gap: 8px 20px;
  }

  footer .copyright,
  footer .footer_btm_con {
    text-align: center;
  }

  /* Products listing */
  #nh_serv .services_con {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 80px 20px;
    padding: 90px 0 60px;
  }

  #nh_serv .services_con section {
    width: calc(50% - 12px);
    max-width: none;
    min-height: 0;
    padding: 180px 16px 20px;
  }

  #nh_serv .main_con h2 {
    font-size: clamp(2rem, 6vw, 3.2rem);
    line-height: 1.15;
    margin-bottom: 20px;
  }

  #nh_serv .main_con p {
    width: 100%;
    max-width: 42rem;
  }

  /* About mission / vision */
  #about_con .mv_holder section,
  #about_con .mv_holder section.nh_m,
  #about_con .mv_holder section.nh_v {
    display: flex;
    flex-direction: column;
    min-height: 0;
    text-align: left;
  }

  #about_con .mv_holder section figure,
  #about_con .mv_holder section:first-child figure {
    width: 100%;
    max-width: 100%;
  }

  #about_con .mv_holder section .mv_info {
    margin-top: 18px;
    width: 100%;
  }

  #about_con .mv_holder section h2,
  #about_con .mv_holder section:first-child h2 {
    font-size: clamp(1.7rem, 5vw, 2.5rem);
    padding: 0;
    margin-bottom: 16px;
    line-height: 1.2;
  }

  #about_con .mv_holder section p {
    padding: 22px 18px;
    font-size: 16px;
    line-height: 1.65;
  }

  .about_info {
    padding: 24px 0 48px;
  }
}

/* —— Phone —— */
@media (max-width: 767px) {
  .main_logo,
  .main_logo.static {
    width: min(210px, 62vw);
  }

  .header_info ul li {
    font-size: 13px;
    line-height: 1.4;
  }

  .bnr_info {
    padding: 28px 16px 32px;
  }

  #about_con {
    padding-top: 24px;
  }

  .bnr_flex {
    flex-direction: column;
    align-items: stretch;
  }

  .bnr_flex .priBtn {
    flex: 1 1 auto;
    width: 100%;
  }

  .slider img,
  .rslides img,
  .box_skitter img,
  .non_ban_img img {
    width: 100%;
    height: auto;
    object-fit: cover;
  }

  #main_area .h1_title,
  .h1_title.headh2 {
    font-size: clamp(1.55rem, 7vw, 2.2rem);
    line-height: 1.2;
  }

  .btm1_info h2,
  .btm2_info h2,
  .btm3_info h2,
  .btm4_info h2,
  .btm5_info h2 {
    font-size: clamp(1.6rem, 7vw, 2.4rem);
    line-height: 1.2;
  }

  .btm1_info_btn {
    flex-direction: column;
    align-items: stretch;
    max-width: 100%;
  }

  .btm2_boxes section,
  .btm3_boxes section,
  .btm5_boxes section,
  .flex-4box section,
  .flex-3box section {
    flex: 1 1 100%;
  }

  #nh_serv .services_con {
    gap: 70px 0;
    padding: 70px 0 40px;
  }

  #nh_serv .services_con section {
    width: 100%;
    padding: 160px 14px 18px;
  }

  .contact-meta,
  .htks-contact-form .form-row.split {
    grid-template-columns: 1fr;
  }

  .htks-contact-form .priBtn,
  .htks-contact-form button[type="submit"] {
    width: 100%;
    min-width: 0;
  }

  footer .disclaimer {
    text-align: left;
  }

  footer .captcha_button_holder {
    flex-direction: column;
    align-items: stretch;
  }

  footer .captcha_button_holder .priBtn,
  footer .captcha_button_holder .form_btn {
    width: 100%;
    justify-content: center;
    text-align: center;
  }
}

@media (max-width: 480px) {
  .wrapper {
    padding-left: 14px;
    padding-right: 14px;
  }

  .mv_holder section p {
    padding: 18px 14px;
  }
}

/* —— Tablet (iPad / medium screens) —— */
@media (min-width: 768px) and (max-width: 1000px) {
  .wrapper {
    padding-left: 24px;
    padding-right: 24px;
  }

  /* Header: logo + contact in one clean row */
  #header .header_con {
    display: grid !important;
    grid-template-columns: 200px 1fr;
    grid-template-rows: auto auto;
    align-items: center;
    gap: 10px 20px;
    text-align: left;
  }

  .main_logo,
  .main_logo.static {
    width: 190px;
    grid-row: 1 / span 2;
    margin: 0;
    position: static !important;
    top: auto !important;
  }

  #header .head_info {
    display: contents !important;
  }

  #header .header_info ul {
    display: flex !important;
    flex-direction: row !important;
    flex-wrap: wrap;
    justify-content: flex-start;
    align-items: center;
    gap: 6px 18px;
    text-align: left;
  }

  #header .header_info ul li {
    font-size: 13px;
    line-height: 1.35;
  }

  #header .social_media {
    grid-column: 2;
    justify-self: end;
    align-self: end;
  }

  #header .social_media ul {
    justify-content: flex-end;
    padding-top: 0;
  }

  #header .header_info {
    grid-column: 2;
    grid-row: 1;
    justify-self: start;
    align-self: center;
    width: 100%;
    max-width: calc(100% - 92px);
  }

  /* Hero */
  body:not(.front_page) .bnr_info {
    padding: 48px 28px;
  }

  body:not(.front_page) .bnr_flex .priBtn {
    flex: 0 1 auto;
    min-width: 200px;
  }

  /* Featured products header row */
  .btm1_info {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    text-align: left;
  }

  .btm1_info_btn {
    justify-content: flex-end;
    max-width: none;
  }

  /* Homepage cards: tidy 2-column */
  .btm2_boxes section,
  .btm3_boxes section,
  .btm5_boxes section,
  .flex-4box section,
  .flex-3box section {
    flex: 1 1 calc(50% - 12px);
    max-width: calc(50% - 12px);
  }

  .btm4_con {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 28px;
    align-items: start;
  }

  /* Footer top: 2-column layout */
  footer .footer_top {
    padding: 48px 0 !important;
  }

  footer .footer_top_con {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(500px, 1.1fr);
    gap: 28px 32px;
    align-items: start;
    text-align: left;
  }

  footer .footer_logo {
    grid-column: 1;
    margin: 0;
    justify-self: start;
  }

  footer .footer_accreditions {
    grid-column: 1;
    justify-content: flex-start;
  }

  footer .contact_list {
    grid-column: 1;
    margin-top: 0;
  }

  footer .footer_separators {
    display: none !important;
  }

  footer .footer_form {
    grid-column: 2;
    grid-row: 1 / span 4;
    max-width: none !important;
    width: 100%;
    min-width: 500px;
  }

  footer .footer_form h2 {
    text-align: left;
    font-size: 32px;
  }

  /* Footer nav — compact left-aligned bar */
  footer .footer_btm .footer_nav {
    height: 40px;
    min-height: 40px;
    max-height: 40px;
    padding: 0;
    justify-content: flex-start;
  }

  footer .footer_btm .footer_nav ul {
    gap: 0 20px;
    justify-content: flex-start;
  }

  footer .footer_btm .footer_nav ul li a {
    padding: 0 !important;
    min-height: 40px;
    height: 40px;
    line-height: 40px;
    border: none !important;
    border-radius: 0 !important;
    font-size: 15px;
  }

  footer .footer_btm .footer_nav ul li a:hover,
  footer .footer_btm .footer_nav ul li.current_page_item a,
  footer .footer_btm .footer_nav ul li.current-menu-item a {
    background: transparent !important;
    opacity: 0.9;
  }

  /* Products page */
  #nh_serv {
    padding-top: 32px;
  }

  #nh_serv .main_con h2 {
    font-size: 2.6rem;
  }

  #nh_serv .services_con {
    gap: 40px 20px;
    padding: 48px 0 56px;
  }

  #nh_serv .services_con section {
    width: calc(50% - 12px);
    padding: 150px 18px 22px;
  }

  /* About page */
  #about_con .mv_holder section {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px;
    align-items: center;
    margin-bottom: 40px;
  }

  #about_con .mv_holder section figure {
    width: 100%;
  }

  #about_con .mv_holder section .mv_info {
    margin-top: 0;
  }

  #about_con .mv_holder section p {
    padding: 28px 24px;
  }

  .contact-meta {
    grid-template-columns: repeat(3, 1fr);
  }
}

/* About page — top spacing below banner (loads after about-styles.min.css) */
#about_con {
  padding-top: 36px;
}

/* Footer brand colors — must load after theme media queries */
footer .footer_btm,
footer#contact .footer_btm,
footer .footer_btm .wrapper,
footer .footer_btm_con,
footer .footer_btm .footer_nav {
  --gradientColor: var(--htks-brand-green);
  background: var(--htks-brand-green) !important;
  background-color: var(--htks-brand-green) !important;
  background-image: none !important;
}

footer .footer_btm .footer_btm_con {
  min-height: 40px !important;
  height: 40px;
}

footer .footer_btm .footer_nav {
  height: 40px;
  min-height: 40px;
  max-height: 40px;
}

footer .footer_btm .footer_nav::before {
  background: var(--htks-brand-green) !important;
  background-image: none !important;
}

footer > .copyright,
footer#contact > .copyright,
footer .footer_btm .copyright {
  display: block;
  width: 100vw;
  max-width: 100vw;
  margin: 0;
  margin-left: calc(50% - 50vw);
  margin-right: calc(50% - 50vw);
  padding: 18px clamp(16px, 3vw, 40px);
  text-align: center;
  font-size: 14px;
  line-height: 1.5;
  background: #3e95c3 !important;
  background-color: #3e95c3 !important;
  background-image: none !important;
}

footer > .copyright .copyrigh_text,
footer#contact > .copyright .copyrigh_text {
  font-size: 14px;
  line-height: 1.5;
}

footer .footer_top,
footer#contact .footer_top,
footer .footer_top .wrapper,
footer .footer_top_con {
  --terColor: #3e95c3;
  background: #3e95c3 !important;
  background-color: #3e95c3 !important;
  background-image: none !important;
}

/* Best seller heading — white text on blue section (loads after global .headh2) */
#bottom3 .btm3_info h2,
#bottom3 .btm3_info h2.headh2,
#bottom3 .btm3_info .headh2 {
  color: #fff !important;
  -webkit-text-fill-color: #fff !important;
  background: none !important;
  background-color: transparent !important;
}

/* Why Choose HTKS — green/blue gradient icons */
.btm2_boxes section::before {
  content: '' !important;
  display: block;
  width: 90px;
  height: 90px;
  max-width: 90px;
  margin: 0 auto;
  background: linear-gradient(135deg, var(--htks-brand-green) 0%, var(--htks-brand-blue) 100%) !important;
  -webkit-mask-repeat: no-repeat;
  -webkit-mask-position: center;
  -webkit-mask-size: contain;
  -webkit-mask-mode: luminance;
  mask-repeat: no-repeat;
  mask-position: center;
  mask-size: contain;
  mask-mode: luminance;
}

.btm2_boxes section:nth-child(1)::before {
  -webkit-mask-image: url('/assets/theme/images/icons/btm2-box1.png');
  mask-image: url('/assets/theme/images/icons/btm2-box1.png');
}

.btm2_boxes section:nth-child(2)::before {
  -webkit-mask-image: url('/assets/theme/images/icons/btm2-box2.png');
  mask-image: url('/assets/theme/images/icons/btm2-box2.png');
}

.btm2_boxes section:nth-child(3)::before {
  -webkit-mask-image: url('/assets/theme/images/icons/btm2-box3.png');
  mask-image: url('/assets/theme/images/icons/btm2-box3.png');
}

.btm2_boxes section:nth-child(4)::before {
  -webkit-mask-image: url('/assets/theme/images/icons/btm2-box4.png');
  mask-image: url('/assets/theme/images/icons/btm2-box4.png');
}
