/*
Theme Name: Yash Metrology
Theme URI: https://www.yadavmeasurements.com/
Author: Yash Metrology
Description: WordPress conversion of the Sudha_Measurements ASP.NET Core MVC website. Preserves the supplied Bootstrap, Slick, CSS, JavaScript and image assets.
Version: 1.0.0
Requires at least: 6.0
Requires PHP: 7.4
Text Domain: yash-metrology
*/

/* WordPress slider fixes */
#homeSlider { width: 100%; background: #fff !important; overflow: hidden; }
#homeSlider .carousel-inner { background: #fff !important; }
#homeSlider .carousel-item { background: #fff !important; min-height: 0; height: auto; text-align: center; }
#homeSlider .carousel-item img.slider-img { display: block; width: 100%; max-width: 100%; height: auto; max-height: none; margin: 0 auto; object-fit: contain; background: #fff; pointer-events: none; user-select: none; }
@media (min-width: 768px) {
  #homeSlider .carousel-item { min-height: 450px; display: flex; align-items: center; justify-content: center; }
  #homeSlider .carousel-item img.slider-img { width: auto; max-width: 100%; max-height: 450px; }
}


/* Reliable homepage autoplay slider: does not depend on Bootstrap JS */
#homeSlider.ym-home-slider {
    width: 100%;
    overflow: hidden;
    background: #fff;
    position: relative;
}
#homeSlider .ym-slider-track {
    width: 100%;
    position: relative;
    min-height: 320px;
}
#homeSlider .ym-slide {
    display: none;
    width: 100%;
    background: #fff;
    text-align: center;
}
#homeSlider .ym-slide.active {
    display: block;
}
#homeSlider .ym-slide img {
    display: block;
    width: 100%;
    height: auto;
    max-width: 100%;
    margin: 0 auto;
    object-fit: contain;
    pointer-events: none;
    user-select: none;
}
@media (min-width: 768px) {
    #homeSlider .ym-slider-track { min-height: 450px; }
    #homeSlider .ym-slide {
        height: 450px;
        display: none;
        align-items: center;
        justify-content: center;
    }
    #homeSlider .ym-slide.active { display: flex; }
    #homeSlider .ym-slide img {
        width: auto;
        max-width: 100%;
        height: 450px;
    }
}

/* =========================================================
   Yash Metrology - responsive visual refresh
   Keeps the existing theme structure/content and improves
   spacing, typography, navigation, cards, forms and mobile UI.
   ========================================================= */
:root {
  --ym-blue: #007cc3;
  --ym-blue-dark: #005f98;
  --ym-ink: #17324d;
  --ym-muted: #5f6f7d;
  --ym-bg: #f5f7f9;
  --ym-border: #e4e9ee;
  --ym-shadow: 0 10px 30px rgba(21, 47, 70, .08);
  --ym-radius: 14px;
}

html { scroll-behavior: smooth; }
body {
  color: var(--ym-ink);
  background: #fff;
  overflow-x: hidden;
}
img { max-width: 100%; height: auto; }
a { transition: color .2s ease, background-color .2s ease, border-color .2s ease, transform .2s ease; }
.container { width: min(1180px, calc(100% - 40px)); }

/* Header */
.header {
  position: sticky;
  top: 0;
  padding: 10px 0;
  background: rgba(255,255,255,.97);
  box-shadow: 0 2px 16px rgba(15,42,62,.06);
  backdrop-filter: blur(8px);
}
.header .wrapper { min-height: 58px; }
.header-item-left { flex-basis: 110px; }
.header-item-center { flex-basis: calc(100% - 170px); justify-content: flex-end; }
.header-item-right { flex-basis: 60px; }
.LogoWebSite { width: 62px; max-height: 52px; object-fit: contain; }
.header .menu>ul>li { margin-left: 18px; line-height: 2.8rem; }
.header .menu>ul>li>a { font-size: 15px; font-weight: 500; }
.header .menu>ul>li>a i.ion { font-size: 13px; margin-left: 3px; }
.header .menu>ul>li .menu-subs {
  margin-top: 8px !important;
  border: 1px solid var(--ym-border);
  border-radius: 10px;
  box-shadow: 0 16px 40px rgba(20,45,65,.13);
}
.header .menu>ul>li .menu-subs.menu-mega { padding: 20px; }
.header .menu>ul>li .menu-subs>ul>li>a { font-size: 15px; }
.header .menu>ul>li .menu-subs .submenu { margin: 0; }
.header .menu>ul>li .menu-subs .submenu a { color: #29475e; }

/* Hero / sliders */
#homeSlider.ym-home-slider { background: #eef5f9; }
#homeSlider .ym-slider-track { min-height: clamp(240px, 48vw, 560px); }
#homeSlider .ym-slide { background: #eef5f9; }
#homeSlider .ym-slide img { width: 100%; height: clamp(240px, 48vw, 560px); object-fit: cover; }
#homeSlider .ym-slide.active { animation: ymFade .65s ease; }
@keyframes ymFade { from { opacity: .35; } to { opacity: 1; } }

.PageDetailBox {
  padding: 52px 0;
  background: linear-gradient(135deg,#f4f7f9,#eef4f8);
  border-bottom: 1px solid var(--ym-border);
}
.PageHeading {
  margin: 0 0 10px;
  color: var(--ym-ink);
  font-size: clamp(30px, 4vw, 46px);
  line-height: 1.15;
  font-weight: 600;
}
.PageDescrp {
  max-width: 900px;
  color: var(--ym-muted);
  font-size: clamp(16px, 1.7vw, 19px);
  line-height: 1.7;
}
.WhiteBgLeftTextBox { padding: 64px 0; }
.MainHeading { color: var(--ym-ink); font-size: clamp(26px, 3vw, 36px); line-height: 1.25; font-weight: 600; }
.MainDescription { color: #405466; font-size: 17px; line-height: 1.8; }
.MainDescription p { margin-bottom: 20px; }
.MainDescription h2 { color: var(--ym-blue-dark); font-size: clamp(24px, 2.7vw, 32px); margin: 30px 0 12px; font-weight: 600; }

/* General cards / content blocks */
.card, .OurMaketsBoxes .card {
  border: 1px solid var(--ym-border);
  border-radius: var(--ym-radius);
  box-shadow: var(--ym-shadow);
  overflow: hidden;
  background: #fff;
}
.card img { object-fit: cover; }
.card-body { padding: 22px; }

/* Vision & Mission */
.vision-slider-section { background: #eef5f9; padding: 0; }
.vision-slider { max-width: 1180px; margin: 0 auto; }
.vision-slide { height: clamp(280px, 48vw, 540px); background: #eef5f9; }
.vision-slide img { width: 100%; height: 100%; max-width: none; object-fit: cover; }
.ym-vision-mission .WhiteBgLeftTextBox .MainDescription {
  max-width: 980px;
  margin: 0 auto;
}

/* Forms */
.form-group { margin-bottom: 18px; }
.form-control, .form-select, textarea.form-control {
  min-height: 48px;
  border: 1px solid #d7e0e7;
  border-radius: 8px;
  padding: 11px 14px;
  box-shadow: none;
}
.form-control:focus, .form-select:focus, textarea.form-control:focus {
  border-color: var(--ym-blue);
  box-shadow: 0 0 0 3px rgba(0,124,195,.12);
}
.YMPLButton, button[type="submit"], input[type="submit"] {
  min-height: 46px;
  padding: 10px 24px;
  border: 0;
  border-radius: 8px;
  background: var(--ym-blue);
  color: #fff;
  font-weight: 600;
  transition: transform .2s ease, background .2s ease, box-shadow .2s ease;
}
.YMPLButton:hover, button[type="submit"]:hover, input[type="submit"]:hover {
  background: var(--ym-blue-dark);
  transform: translateY(-1px);
  box-shadow: 0 8px 18px rgba(0,124,195,.2);
}

/* Location rows */
.location-contact .container, .location-page .container { max-width: 1180px; }
.location-contact .row, .location-page .location-row {
  border-bottom: 1px solid var(--ym-border);
  padding: 24px 0;
}
.location-contact .GetInTouch, .location-page .GetInTouch {
  border-radius: 8px;
  padding: 13px 18px;
  background: var(--ym-blue);
  color: #fff !important;
  font-weight: 600;
}

/* FAQ */
.main-faq-page .faq-item, .ym-faqs .faq-item {
  margin-bottom: 14px;
  border: 1px solid #d9e1e7;
  border-radius: 8px;
  overflow: hidden;
  background: #fff;
  box-shadow: 0 4px 16px rgba(20,45,65,.04);
}
.main-faq-page .faq-question, .ym-faqs .faq-question {
  padding: 17px 20px;
  background: #f6f7f8;
  color: var(--ym-ink);
  font-weight: 600;
}
.main-faq-page .faq-answer, .ym-faqs .faq-answer { padding: 18px 20px; line-height: 1.7; }

/* Footer */
footer { margin-top: 40px; }
footer .GrayBg {
  padding: 48px 0 36px;
  background: #f1f4f6;
  border-top: 1px solid var(--ym-border);
}
footer .GrayBg > div { padding-left: 24px; padding-right: 24px; }
footer h5 { color: var(--ym-ink); font-size: 18px; margin-bottom: 14px; font-weight: 600; }
footer ul { padding-left: 0; list-style: none; }
footer li { margin-bottom: 8px; }
footer li a { color: #526474; }
footer li a:hover { color: var(--ym-blue); }
footer img { width: 66px; max-height: 58px; object-fit: contain; }
.SocialMediaFooter { display: flex; gap: 10px; }
.SocialMediaFooter li { margin: 0; }
.SocialMediaFooter a {
  width: 38px; height: 38px; display: grid; place-items: center;
  border-radius: 50%; background: #fff; border: 1px solid var(--ym-border);
}

/* Better keyboard/focus states */
a:focus-visible, button:focus-visible, input:focus-visible, select:focus-visible, textarea:focus-visible {
  outline: 3px solid rgba(0,124,195,.25);
  outline-offset: 2px;
}

/* Tablet */
@media (max-width: 992px) {
  .container { width: min(100% - 32px, 760px); }
  .header { padding: 7px 0; }
  .header .wrapper { min-height: 54px; }
  .header-item-left { flex-basis: auto; }
  .header-item-center { flex-basis: 0; }
  .header-item-right { flex-basis: auto; }
  .header .menu-mobile-trigger { margin-left: 10px; }
  .header .menu { width: min(88vw, 360px); }
  .header .menu>ul>li>a { font-size: 16px; }
  .header .menu>ul>li .menu-subs { border-radius: 0; }
  .PageDetailBox { padding: 42px 0; }
  .WhiteBgLeftTextBox { padding: 48px 0; }
  footer .GrayBg > div { padding-left: 14px; padding-right: 14px; }
}

/* Phone */
@media (max-width: 767px) {
  .container { width: calc(100% - 28px); }
  .header { padding: 6px 0; }
  .LogoWebSite { width: 54px; max-height: 48px; }
  .header-item-right a i::before { font-size: 22px; }
  #homeSlider .ym-slider-track { min-height: 220px; }
  #homeSlider .ym-slide img { height: auto; min-height: 220px; max-height: 430px; object-fit: cover; }
  .PageDetailBox { padding: 34px 0; }
  .PageHeading { font-size: 31px; }
  .PageDescrp { font-size: 16px; line-height: 1.6; }
  .WhiteBgLeftTextBox { padding: 38px 0; }
  .MainHeading { font-size: 27px; }
  .MainDescription { font-size: 16px; line-height: 1.7; }
  .vision-slide { height: auto; min-height: 230px; }
  .vision-slide img { height: auto; min-height: 230px; max-height: 430px; object-fit: cover; }
  .row { --bs-gutter-x: 1rem; }
  .card-body { padding: 18px; }
  footer { margin-top: 20px; }
  footer .GrayBg { padding: 34px 0 22px; }
  footer .GrayBg > .col-md-3 { margin-bottom: 26px; }
  footer .GrayBg > .col-md-3:last-child { margin-bottom: 0; }
  footer h5 { font-size: 17px; }
}

@media (max-width: 420px) {
  .container { width: calc(100% - 22px); }
  .PageHeading { font-size: 28px; }
  .PageDescrp { font-size: 15px; }
  .MainDescription { font-size: 15.5px; }
  .YMPLButton, button[type="submit"], input[type="submit"] { width: 100%; }
}

@media (prefers-reduced-motion: reduce) {
  html { scroll-behavior: auto; }
  *, *::before, *::after { animation-duration: .01ms !important; animation-iteration-count: 1 !important; transition-duration: .01ms !important; }
}

/* =========================================================
   Premium corporate homepage
   ========================================================= */
.ym-homepage { background:#fff; }
.ym-hero { position:relative; overflow:hidden; background:#102d43; }
.ym-hero-track { position:relative; min-height:clamp(520px, 66vh, 720px); }
.ym-hero-slide { position:absolute; inset:0; opacity:0; visibility:hidden; transition:opacity .8s ease, visibility .8s ease; }
.ym-hero-slide.is-active { opacity:1; visibility:visible; z-index:1; }
.ym-hero-slide > img { width:100%; height:100%; object-fit:contain; object-position:center; display:block; background:#fff;}
.ym-hero-overlay { position:absolute; inset:0; background:linear-gradient(90deg,rgba(5,25,41,.30) 0%,rgba(7,37,59,.18) 43%,rgba(7,37,59,.04) 100%); }
.ym-hero-content { position:relative; z-index:2; min-height:clamp(520px, 66vh, 720px); display:flex; flex-direction:column; justify-content:center; align-items:flex-start; padding-top:55px; padding-bottom:55px; color:#fff; }
.ym-eyebrow,.ym-kicker { display:inline-block; font-size:12px; letter-spacing:.16em; font-weight:700; text-transform:uppercase; color:#0087cf; }
.ym-hero .ym-eyebrow { color:#72c8f2; margin-bottom:16px; }
.ym-hero h1,.ym-hero h2 { 
  margin:0 0 18px; 
  color:#fff; 
  font-size:clamp(38px,5.2vw,70px); 
  line-height:1.06; 
  font-weight:700; 
  letter-spacing:-.02em; 
  max-width:760px; 
  text-shadow: 0 2px 14px rgba(0,0,0,.6);
}
.ym-hero p { 
  max-width:670px; 
  margin:0 0 28px; 
  color:rgba(255,255,255,.9); 
  font-size:clamp(16px,1.7vw,20px); 
  line-height:1.65; 
  text-shadow: 0 1px 10px rgba(0,0,0,.5);
}
.ym-hero-actions { display:flex; gap:12px; flex-wrap:wrap; }
.ym-btn { display:inline-flex; align-items:center; justify-content:center; min-height:48px; padding:12px 22px; border-radius:7px; font-weight:700; text-decoration:none !important; border:1px solid transparent; transition:transform .2s ease, box-shadow .2s ease, background .2s ease; }
.ym-btn:hover { transform:translateY(-2px); }
.ym-btn-primary { background:#0087cf; color:#fff !important; box-shadow:0 10px 25px rgba(0,135,207,.25); }
.ym-btn-primary:hover { background:#006fae; box-shadow:0 14px 30px rgba(0,135,207,.3); }
.ym-btn-light { background:#fff; color:#17324d !important; }
.ym-btn-light:hover { background:#eef7fb; }
.ym-btn-outline { color:#006fae !important; border-color:#b9d5e3; background:#fff; }
.ym-btn-outline:hover { border-color:#0087cf; background:#f3fbff; }
.ym-hero-dots { position:absolute; z-index:5; left:50%; bottom:26px; transform:translateX(-50%); display:flex; gap:8px; }
.ym-hero-dots button { width:9px; height:9px; padding:0; border:0; border-radius:50%; background:rgba(255,255,255,.55); cursor:pointer; }
.ym-hero-dots button.is-active { width:28px; border-radius:10px; background:#fff; }
.ym-trust-strip { background:#fff; border-bottom:1px solid #e7edf1; box-shadow:0 5px 18px rgba(20,45,65,.04); position:relative; z-index:3; }
.ym-trust-grid { display:grid; grid-template-columns:repeat(4,1fr); }
.ym-trust-grid > div { padding:22px 20px; border-right:1px solid #e7edf1; display:flex; flex-direction:column; gap:4px; }
.ym-trust-grid > div:last-child { border-right:0; }
.ym-trust-grid strong { color:#17324d; font-size:14px; }
.ym-trust-grid span { color:#71808c; font-size:13px; line-height:1.45; }
.ym-section { padding:92px 0; }
.ym-services-section { background:#f7f9fb; }
.ym-section-heading { max-width:760px; margin:0 auto 46px; text-align:center; }
.ym-section-heading h2,.ym-vm-content h2,.ym-about-grid h2,.ym-cta-card h2 { color:#17324d; font-size:clamp(30px,3.6vw,46px); line-height:1.15; margin:10px 0 14px; font-weight:700; letter-spacing:-.02em; }
.ym-section-heading p { color:#667786; font-size:17px; line-height:1.7; margin:0; }
.ym-service-grid { display:grid; grid-template-columns:repeat(4,1fr); gap:22px; }
.ym-service-card { display:flex; flex-direction:column; background:#fff; border:1px solid #e3e9ee; border-radius:14px; overflow:hidden; text-decoration:none !important; color:inherit; box-shadow:0 8px 26px rgba(21,47,70,.06); transition:transform .25s ease, box-shadow .25s ease, border-color .25s ease; }
.ym-service-card:hover { transform:translateY(-7px); box-shadow:0 18px 42px rgba(21,47,70,.13); border-color:#c9dce7; }
.ym-service-image { height:205px; overflow:hidden; background:#edf4f7; }
.ym-service-image img { width:100%; height:100%; object-fit:cover; transition:transform .45s ease; }
.ym-service-card:hover .ym-service-image img { transform:scale(1.045); }
.ym-service-body { padding:22px 22px 24px; display:flex; flex-direction:column; flex:1; }
.ym-service-number { color:#0087cf; font-weight:800; font-size:12px; letter-spacing:.1em; }
.ym-service-body h3 { margin:8px 0 9px; color:#17324d; font-size:21px; }
.ym-service-body p { color:#667786; line-height:1.65; font-size:14px; margin:0 0 18px; }
.ym-read-more,.ym-text-link { color:#0078b8 !important; font-weight:700; font-size:14px; margin-top:auto; }
.ym-read-more span,.ym-text-link span { display:inline-block; margin-left:5px; transition:transform .2s ease; }
.ym-service-card:hover .ym-read-more span,.ym-text-link:hover span { transform:translateX(4px); }
.ym-vm-section { background:#fff; }
.ym-vm-grid { display:grid; grid-template-columns:minmax(0,1fr) minmax(0,1.05fr); gap:70px; align-items:center; }
.ym-vm-image { position:relative; border-radius:18px; overflow:hidden; min-height:520px; box-shadow:0 20px 55px rgba(20,45,65,.13); }
.ym-vm-image:after { content:""; position:absolute; inset:0; background:linear-gradient(180deg,rgba(5,25,41,0) 55%,rgba(5,25,41,.38)); pointer-events:none; }
.ym-vm-image img { width:100%; height:100%; min-height:520px; object-fit:cover; display:block; }
.ym-vm-badge { position:absolute; z-index:2; left:24px; bottom:24px; padding:14px 18px; border-radius:9px; background:rgba(255,255,255,.95); box-shadow:0 10px 30px rgba(0,0,0,.12); display:flex; flex-direction:column; }
.ym-vm-badge strong { color:#17324d; font-size:16px; }
.ym-vm-badge span { color:#0087cf; font-size:13px; }
.ym-vm-content h2 { margin-bottom:28px; }
.ym-vm-item { display:grid; grid-template-columns:46px 1fr; gap:16px; margin-bottom:26px; }
.ym-vm-icon { width:46px; height:46px; border-radius:12px; background:#e8f6fc; color:#0078b8; display:grid; place-items:center; font-weight:800; }
.ym-vm-item h3 { color:#17324d; margin:0 0 7px; font-size:21px; }
.ym-vm-item p { color:#657686; margin:0; font-size:15px; line-height:1.75; }
.ym-about-section { background:#f3f8fb; }
.ym-about-grid { display:grid; grid-template-columns:1fr 1fr; gap:80px; align-items:center; }
.ym-about-grid h2 { max-width:520px; }
.ym-about-grid p { color:#627485; font-size:17px; line-height:1.8; margin:0 0 20px; }
.ym-cert-section { background:#fff; }
.ym-cert-grid { display:grid; grid-template-columns:repeat(3,1fr); gap:22px; }
.ym-cert-card { background:#fff; border:1px solid #e2e8ed; border-radius:13px; overflow:hidden; text-decoration:none !important; box-shadow:0 7px 25px rgba(20,45,65,.05); transition:transform .22s ease, box-shadow .22s ease; }
.ym-cert-card:hover { transform:translateY(-5px); box-shadow:0 16px 35px rgba(20,45,65,.1); }
.ym-cert-image { height:210px; background:#f4f7f9; display:flex; align-items:center; justify-content:center; overflow:hidden; }
.ym-cert-image img { width:100%; height:100%; object-fit:contain; padding:14px; }
.ym-cert-card > div:last-child { padding:18px 20px 21px; }
.ym-cert-card h3 { color:#17324d; font-size:18px; margin:0 0 6px; }
.ym-cert-card span { color:#0078b8; font-size:13px; font-weight:700; }
.ym-cert-badge-card { display:flex; flex-direction:column; }
.ym-cert-badge { height:210px; display:flex; align-items:center; justify-content:center; background:#f7fafc; }
.ym-cert-badge img { max-width:180px; max-height:160px; object-fit:contain; }
.ym-centered-link { text-align:center; margin-top:30px; }
.ym-cta-section { padding:0 0 92px; background:#fff; }
.ym-cta-card { padding:42px 48px; border-radius:18px; background:linear-gradient(115deg,#0e3048,#075e8d); color:#fff; display:flex; align-items:center; justify-content:space-between; gap:35px; box-shadow:0 20px 50px rgba(9,65,96,.18); }
.ym-cta-card .ym-kicker { color:#78c9ef; }
.ym-cta-card h2 { color:#fff; margin-top:8px; max-width:720px; font-size:clamp(27px,3vw,40px); }
.ym-cta-card p { color:rgba(255,255,255,.82); margin:0; line-height:1.6; max-width:700px; }

@media (max-width:1100px) {
  .ym-service-grid { grid-template-columns:repeat(2,1fr); }
  .ym-vm-grid { gap:42px; }
}
@media (max-width:900px) {
  .ym-trust-grid { grid-template-columns:repeat(2,1fr); }
  .ym-trust-grid > div:nth-child(2) { border-right:0; }
  .ym-vm-grid,.ym-about-grid { grid-template-columns:1fr; gap:40px; }
  .ym-vm-image,.ym-vm-image img { min-height:400px; }
  .ym-cert-grid { grid-template-columns:1fr 1fr; }
  .ym-cta-card { flex-direction:column; align-items:flex-start; }
}
@media (max-width:767px) {
  .ym-hero-track,.ym-hero-content { min-height:560px; }
  .ym-hero-slide > img { object-position:center; }
  .ym-hero-overlay { background:linear-gradient(90deg,rgba(5,25,41,.30),rgba(7,37,59,.12)); }
  .ym-hero h1,.ym-hero h2 { font-size:36px; }
  .ym-hero p { font-size:16px; }
  .ym-section { padding:62px 0; }
  .ym-section-heading { margin-bottom:32px; }
  .ym-service-grid,.ym-cert-grid { grid-template-columns:1fr; }
  .ym-service-image { height:220px; }
  .ym-vm-image,.ym-vm-image img { min-height:320px; }
  .ym-about-grid { gap:24px; }
  .ym-trust-grid { grid-template-columns:1fr; }
  .ym-trust-grid > div { border-right:0; border-bottom:1px solid #e7edf1; }
  .ym-trust-grid > div:last-child { border-bottom:0; }
  .ym-cta-section { padding-bottom:62px; }
  .ym-cta-card { padding:30px 24px; }
  .ym-cta-card .ym-btn { width:100%; }
}
@media (prefers-reduced-motion: reduce) {
  .ym-hero-slide,.ym-service-card,.ym-service-image img { transition:none !important; }
}
