/* Jaipur Engineers responsive overrides
   Loaded after the theme responsive stylesheet so these rules can safely
   correct mobile/tablet/large-screen layout without changing the base theme. */

html {
    overflow-x: hidden;
    scroll-behavior: smooth;
}

body {
    overflow-x: clip;
    -webkit-text-size-adjust: 100%;
}

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

img {
    height: auto;
}

input,
select,
textarea,
button {
    max-width: 100%;
}

/* Shared header improvements */
.full-width-header .topbar-area .topbar-contact,
.full-width-header .topbar-area .toolbar-sl-share {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 8px 18px;
}

.full-width-header .topbar-area .topbar-contact li,
.full-width-header .topbar-area .toolbar-sl-share li {
    margin: 0 !important;
}

.full-width-header .menu-area .logo-part img {
    width: auto;
    max-width: 190px;
    height: auto;
}

.full-width-header .menu-area .rs-menu-area,
.full-width-header .menu-area .main-menu {
    min-width: 0;
}

/* Homepage: scalable typography and media */
body.defult-home .rs-banner.style12 .banner-content .title {
    font-size: clamp(2.65rem, 4.2vw, 4rem);
    line-height: 1.12;
    letter-spacing: -0.025em;
}

body.defult-home .rs-banner.style12 .banner-content .desc {
    max-width: 680px;
    font-size: clamp(1rem, 1.25vw, 1.125rem);
    line-height: 1.75;
}

body.defult-home .rs-banner.style12 .banner-img img,
body.defult-home .rs-about .banner-img img {
    display: block;
    width: 100%;
    height: auto;
    object-fit: cover;
}

body.defult-home .rs-banner.style12 .btn-part {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
}

body.defult-home .rs-banner.style12 .btn-part .readon2,
body.defult-home .rs-cta .readon2,
body.defult-home .rs-about .readon2 {
    margin: 0 !important;
}

body.defult-home .rs-features.style4 .row,
body.defult-home .rs-popular-courses .row.grid,
body.defult-home .rs-categories .row,
body.defult-home .rs-testimonial .row {
    row-gap: 24px;
}

body.defult-home .rs-features.style4 .features-wrap,
body.defult-home .rs-popular-courses .courses-item,
body.defult-home .rs-categories .categories-items,
body.defult-home .rs-testimonial .testi-item {
    height: 100%;
}

body.defult-home .rs-popular-courses .courses-item,
body.defult-home .rs-categories .categories-items,
body.defult-home .rs-testimonial .testi-item {
    overflow: hidden;
}

body.defult-home .rs-popular-courses .courses-item .img-part img,
body.defult-home .rs-categories .categories-items .cate-images img {
    display: block;
    width: 100%;
    aspect-ratio: 3 / 2;
    object-fit: cover;
}

body.defult-home .rs-popular-courses .courses-item .content-part,
body.defult-home .rs-categories .categories-items .contents,
body.defult-home .rs-testimonial .testi-item .item-content {
    min-width: 0;
}

body.defult-home .rs-popular-courses .courses-item .title,
body.defult-home .rs-categories .categories-items .title,
body.defult-home .rs-testimonial .testi-item h3 {
    overflow-wrap: anywhere;
}

body.defult-home .gridFilter.style2 {
    display: flex;
    justify-content: center;
    flex-wrap: wrap;
    gap: 10px;
}

body.defult-home .gridFilter.style2 button {
    margin: 0 !important;
}

body.defult-home .rs-cta.home-style14 .row {
    row-gap: 20px;
}

body.defult-home .rs-cta.effects-layer .effects-bg {
    height: 100%;
}

body.defult-home .rs-partner .row > div > a {
    display: block;
    height: 100%;
    padding: 18px 16px;
    border-radius: 10px;
    background: #ffffff;
    box-shadow: 0 8px 30px rgba(0, 0, 0, 0.06);
}

/* Wide desktop */
@media (min-width: 1400px) {
    .container {
        max-width: 1320px;
    }

    .full-width-header .menu-area .container-fluid {
        padding-left: 40px !important;
        padding-right: 40px !important;
    }

    body.defult-home .rs-banner.style12 .banner-content {
        max-width: 720px;
    }

    body.defult-home .rs-banner.style12 .banner-img {
        max-width: 700px;
        margin-left: auto;
    }
}

/* Laptop / smaller desktop */
@media (max-width: 1199.98px) {
    .full-width-header .menu-area .container-fluid {
        padding-left: 18px !important;
        padding-right: 18px !important;
    }

    .full-width-header .menu-area .logo-part img {
        max-width: 165px;
    }

    body.defult-home .rs-banner.style12 .col-lg-6.pl-100 {
        padding-left: 40px !important;
    }

    body.defult-home .rs-banner.style12 .banner-content .title {
        font-size: clamp(2.35rem, 4vw, 3.25rem);
    }
}

/* Tablet and below */
@media (max-width: 991.98px) {
    .full-width-header .topbar-area .row > [class*="col-"] {
        flex: 0 0 100%;
        max-width: 100%;
        text-align: center !important;
    }

    .full-width-header .topbar-area .topbar-contact,
    .full-width-header .topbar-area .toolbar-sl-share {
        justify-content: center;
    }

    .full-width-header .topbar-area .toolbar-sl-share .opening {
        width: 100%;
        justify-content: center;
    }

    .full-width-header .menu-area .container-fluid {
        padding: 10px 18px !important;
    }

    .full-width-header .menu-area .row {
        align-items: center;
    }

    .full-width-header .menu-area .logo-part img {
        max-width: 170px;
    }

    .full-width-header .mobile-menu {
        display: flex;
        justify-content: flex-end;
        align-items: center;
        min-height: 48px;
    }

    .full-width-header .mobile-menu .rs-menu-toggle {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 46px;
        height: 46px;
        border-radius: 8px;
        cursor: pointer;
    }

    .full-width-header .rs-menu .nav-menu a {
        white-space: normal;
        overflow-wrap: anywhere;
    }

    body.defult-home .rs-banner.style12 .row {
        text-align: center;
    }

    body.defult-home .rs-banner.style12 .col-lg-6.pl-100 {
        padding-left: 15px !important;
    }

    body.defult-home .rs-banner.style12 .banner-content,
    body.defult-home .rs-banner.style12 .banner-content .desc {
        margin-left: auto;
        margin-right: auto;
    }

    body.defult-home .rs-banner.style12 .banner-content .title {
        font-size: clamp(2.3rem, 6vw, 3.25rem);
    }

    body.defult-home .rs-banner.style12 .btn-part {
        justify-content: center;
    }

    body.defult-home .rs-banner.style12 .banner-img {
        max-width: 620px;
        margin: 35px auto 0;
    }

    body.defult-home .rs-features.style4 .features-wrap {
        max-width: 720px;
        margin-left: auto;
        margin-right: auto;
    }

    body.defult-home .rs-cta.home-style14 .content-part,
    body.defult-home .rs-cta.home-style14 .btn-part {
        text-align: center !important;
    }

    body.defult-home .rs-about .banner-img {
        max-width: 720px;
        margin: 35px auto 0;
    }

    body.defult-home .rs-cta.effects-layer .row {
        row-gap: 24px;
    }

    body.defult-home .rs-cta.effects-layer .effects-bg {
        min-height: 330px;
    }
}

/* Phones */
@media (max-width: 767.98px) {
    body {
        font-size: 16px;
    }

    input,
    select,
    textarea {
        font-size: 16px !important;
    }

    .container,
    .container-fluid {
        padding-left: 16px;
        padding-right: 16px;
    }

    .full-width-header .topbar-area {
        padding: 0 !important;
    }

    .full-width-header .topbar-area .container-fluid {
        padding: 8px 12px !important;
    }

    .full-width-header .topbar-area .toolbar-sl-share {
        display: none;
    }

    .full-width-header .topbar-area .topbar-contact {
        gap: 6px 14px;
        font-size: 13px;
        line-height: 1.4;
    }

    .full-width-header .topbar-area .topbar-contact li {
        display: inline-flex;
        align-items: center;
    }

    .full-width-header .menu-area .container-fluid {
        padding: 9px 14px !important;
    }

    .full-width-header .menu-area .logo-part img {
        max-width: 145px;
    }

    .full-width-header .mobile-menu .rs-menu-toggle {
        width: 44px;
        height: 44px;
        font-size: 21px;
    }

    .full-width-header .rs-menu .nav-menu,
    .full-width-header .rs-menu .sub-menu {
        max-width: 100%;
    }

    .full-width-header .rs-menu .nav-menu li > a {
        min-height: 44px;
        display: flex;
        align-items: center;
        line-height: 1.35;
    }

    body.defult-home .rs-banner.style12 {
        padding-top: 46px;
    }

    body.defult-home .rs-banner.style12 .banner-content .sub-text,
    body.defult-home .sec-title6 .sub-text {
        display: inline-block;
        line-height: 1.45;
    }

    body.defult-home .rs-banner.style12 .banner-content .title {
        margin-top: 12px;
        font-size: clamp(2rem, 9vw, 2.55rem);
        line-height: 1.12;
    }

    body.defult-home .rs-banner.style12 .banner-content .desc {
        font-size: 1rem;
        line-height: 1.65;
    }

    body.defult-home .rs-banner.style12 .btn-part {
        flex-direction: column;
        width: 100%;
        gap: 10px;
    }

    body.defult-home .rs-banner.style12 .btn-part .readon2,
    body.defult-home .rs-cta.home-style14 .readon2,
    body.defult-home .rs-about .readon2,
    body.defult-home .rs-cta.effects-layer .readon2 {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        width: 100%;
        max-width: 360px;
        min-height: 48px;
        padding-left: 18px;
        padding-right: 18px;
        white-space: normal;
        text-align: center;
    }

    body.defult-home .rs-banner.style12 .banner-img {
        margin-top: 28px;
        max-width: 500px;
    }

    body.defult-home .rs-features.style4 {
        padding-top: 28px !important;
    }

    body.defult-home .rs-features.style4 .features-wrap {
        display: flex;
        align-items: flex-start;
        gap: 14px;
        padding: 18px;
    }

    body.defult-home .rs-features.style4 .icon-part {
        flex: 0 0 54px;
    }

    body.defult-home .rs-features.style4 .icon-part img {
        width: 52px;
        height: auto;
    }

    body.defult-home .rs-features.style4 .content-part {
        min-width: 0;
        text-align: left;
    }

    body.defult-home .rs-features.style4 .content-part .title {
        font-size: 18px;
        line-height: 1.35;
    }

    body.defult-home .pt-100 {
        padding-top: 65px !important;
    }

    body.defult-home .pb-100 {
        padding-bottom: 65px !important;
    }

    body.defult-home .pb-90 {
        padding-bottom: 55px !important;
    }

    body.defult-home .sec-title6 {
        margin-bottom: 28px !important;
    }

    body.defult-home .sec-title6 .title,
    body.defult-home .rs-cta .title,
    body.defult-home .rs-about .sec-title6 .title {
        font-size: clamp(1.7rem, 7vw, 2.15rem) !important;
        line-height: 1.22 !important;
    }

    body.defult-home .gridFilter.style2 {
        justify-content: flex-start;
        flex-wrap: nowrap;
        overflow-x: auto;
        overscroll-behavior-inline: contain;
        -webkit-overflow-scrolling: touch;
        scrollbar-width: thin;
        padding: 2px 2px 10px;
    }

    body.defult-home .gridFilter.style2 button {
        flex: 0 0 auto;
        white-space: nowrap;
        min-height: 42px;
        padding-left: 16px;
        padding-right: 16px;
    }

    body.defult-home .rs-popular-courses .courses-item,
    body.defult-home .rs-categories .categories-items,
    body.defult-home .rs-testimonial .testi-item {
        max-width: 560px;
        margin-left: auto;
        margin-right: auto;
    }

    body.defult-home .rs-popular-courses .courses-item .content-part,
    body.defult-home .rs-categories .categories-items .contents {
        padding-left: 18px;
        padding-right: 18px;
    }

    body.defult-home .rs-popular-courses .courses-item .title,
    body.defult-home .rs-categories .categories-items .title {
        font-size: 20px !important;
        line-height: 1.35 !important;
    }

    body.defult-home .je-java-card-tags {
        display: flex;
        flex-wrap: wrap;
        gap: 7px;
    }

    body.defult-home .rs-cta.home-style14 {
        padding: 46px 0;
    }

    body.defult-home .rs-cta.home-style14 .btn-part {
        display: flex;
        justify-content: center;
    }

    body.defult-home .rs-categories .categories-items .contents {
        display: flex;
        align-items: flex-start;
        gap: 12px;
    }

    body.defult-home .rs-categories .categories-items .contents .img-part {
        flex: 0 0 50px;
    }

    body.defult-home .rs-categories .categories-items .contents .img-part img {
        width: 46px;
    }

    body.defult-home .rs-categories .categories-items .contents .content-wrap {
        min-width: 0;
    }

    body.defult-home .rs-about .sec-title6,
    body.defult-home .rs-about .sec-title6 p {
        text-align: left;
    }

    body.defult-home .rs-about .banner-img {
        margin-top: 28px;
    }

    body.defult-home .rs-cta.effects-layer .effects-bg {
        min-height: 0;
    }

    body.defult-home .rs-cta.effects-layer .content-part {
        padding: 34px 24px !important;
    }

    body.defult-home .rs-cta.effects-layer .content-part .title {
        font-size: 26px !important;
    }

    body.defult-home .rs-testimonial .testi-item .item-content {
        padding: 24px 20px;
    }

    body.defult-home .rs-partner .row > div {
        margin-bottom: 14px !important;
    }

    body.defult-home .rs-partner .row > div > a {
        padding: 16px 14px;
    }

    .je-footer-directory {
        margin-top: 35px !important;
        padding: 22px 16px !important;
    }
}

/* Small phones */
@media (max-width: 575.98px) {
    .full-width-header .topbar-area .topbar-contact {
        flex-direction: column;
        gap: 4px;
    }

    .full-width-header .menu-area .logo-part img {
        max-width: 132px;
    }

    body.defult-home .rs-banner.style12 {
        padding-top: 36px;
    }

    body.defult-home .rs-banner.style12 .banner-content .title {
        font-size: clamp(1.85rem, 9.5vw, 2.25rem);
    }

    body.defult-home .rs-banner.style12 .banner-content .desc {
        line-height: 1.6;
    }

    body.defult-home .rs-features.style4 .features-wrap {
        padding: 16px 14px;
    }

    body.defult-home .rs-categories .categories-items .contents {
        display: block;
    }

    body.defult-home .rs-categories .categories-items .contents .img-part {
        margin-bottom: 10px;
    }

    body.defult-home .rs-cta.effects-layer .content-part {
        padding: 30px 18px !important;
    }

    body.defult-home .rs-partner .text-center.mt-20 {
        line-height: 2;
    }
}

/* Very narrow devices */
@media (max-width: 389.98px) {
    .container,
    .container-fluid {
        padding-left: 12px;
        padding-right: 12px;
    }

    .full-width-header .menu-area .container-fluid {
        padding-left: 10px !important;
        padding-right: 10px !important;
    }

    body.defult-home .rs-banner.style12 .banner-content .title {
        font-size: 1.8rem;
    }

    body.defult-home .sec-title6 .title,
    body.defult-home .rs-cta .title,
    body.defult-home .rs-about .sec-title6 .title {
        font-size: 1.65rem !important;
    }
}

/* Landscape phones: avoid oversized hero taking the whole viewport */
@media (max-width: 900px) and (orientation: landscape) {
    body.defult-home .rs-banner.style12 {
        padding-top: 30px;
    }

    body.defult-home .rs-banner.style12 .banner-img {
        max-width: 430px;
    }
}

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