/* =========================================================
   Vig Tech X — Global Responsive Fixes (all screens)
   Breakpoints: 1399 / 1199 / 991 / 767 / 575 / 400
   ========================================================= */

html {
  scroll-behavior: smooth;
}

html,
body {
  max-width: 100%;
  overflow-x: hidden;
}

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

iframe {
  width: 100%;
}

.container,
.container-fluid {
  width: 100%;
}

/* Prevent long unbroken strings from overflowing */
a,
p,
li,
span,
td,
th,
h1, h2, h3, h4, h5, h6 {
  overflow-wrap: anywhere;
  word-break: break-word;
}

/* Breadcrumbs — all inner pages */
.rv-breadcrumb {
  overflow: hidden;
}

.rv-breadcrumb .rv-breadcrumb__title {
  max-width: 100%;
  padding-left: 12px !important;
  padding-right: 12px !important;
}

.rv-breadcrumb__nav {
  flex-wrap: wrap;
  row-gap: 6px;
  padding: 0 12px;
}

/* Header mobile sidebar polish — phones only */
@media screen and (max-width: 767px) {
  .rv-37-header .rv-1-header-nav__sidebar {
    padding: 20px 0 40px;
  }

  .rv-37-header .sidebar-heading {
    padding: 10px 20px 16px;
    border-bottom: 1px solid rgba(0, 33, 71, 0.08);
    margin-bottom: 12px;
  }

  .rv-37-header .sidebar-heading img {
    max-height: 42px;
    width: auto;
  }

  .rv-37-header .rv-37-menu-list__ul {
    width: 100%;
    padding: 0 22px !important;
  }

  .rv-37-header .rv-37-menu-list__ul > li {
    width: 100%;
  }

  .rv-37-header .rv-37-menu-list__ul > li > a {
    width: 100%;
    justify-content: space-between;
    padding: 10px 0 !important;
    font-size: 16px !important;
    white-space: normal;
  }

  .rv-37-header .rv-37-menu-list__ul .sub-menu {
    position: static !important;
    width: 100% !important;
    box-shadow: none !important;
    padding: 0 0 8px 12px !important;
    background: transparent !important;
    opacity: 1 !important;
    visibility: visible !important;
    transform: none !important;
    display: none !important;
  }

  .rv-37-header .rv-37-menu-list__ul > li.rv-dropdown-active > .sub-menu {
    display: block !important;
  }

  .rv-37-header .rv-1-header-mobile-menu-btn {
    min-width: 42px;
    min-height: 42px;
    display: inline-flex !important;
    align-items: center;
    justify-content: center;
  }

  .rv-37-header .rv-37-btn {
    background: #D4AF37 !important;
    box-shadow: 0 4px 12px rgba(212, 175, 55, 0.28);
  }

  .rv-37-header .rv-37-menu-list__ul > li > a:hover {
    color: #D4AF37 !important;
  }
}

/* Home */
@media screen and (max-width: 1199px) {
  .be-home-hero__text {
    font-size: 16px;
    padding: 0 8px;
  }

  .be-home-why__grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media screen and (max-width: 991px) {
  .be-home-hero {
    padding-top: 24px;
  }

  .be-home-hero .rv-37-banner__title,
  .be-home-hero__title {
    font-size: clamp(28px, 6vw, 40px) !important;
    line-height: 1.25 !important;
  }

  .be-home-trust {
    margin-top: 10px;
    padding: 0 4px;
  }

  .be-home-trust__grid {
    grid-template-columns: 1fr 1fr;
    gap: 10px;
    padding: 14px;
  }

  .be-home-products .rv-37-service-item {
    margin-bottom: 16px;
  }

  .be-home-services {
    padding: 60px 0 50px;
  }

  .be-home-services__grid {
    grid-template-columns: 1fr;
  }

  .be-home-why,
  .be-home-steps {
    padding-left: 0;
    padding-right: 0;
  }

  .be-home-cta__box {
    flex-direction: column;
    align-items: flex-start;
  }
}

@media screen and (max-width: 767px) {
  .rv-37-gallary .rv-37-section-header {
    flex-direction: column !important;
    align-items: flex-start !important;
    gap: 12px !important;
  }

  .rv-37-gallary .rv-37-section-header-text {
    text-align: left !important;
  }

  .rv-37-abt .row,
  .rv-37-pricing .row {
    --bs-gutter-y: 24px;
  }

  .rv-37-abt__img img,
  .rv-37-pricing img {
    width: 100%;
  }
}

@media screen and (max-width: 575px) {
  .be-home-hero__copy {
    margin-bottom: 18px;
  }

  .be-home-trust__grid,
  .be-home-why__grid,
  .be-home-steps__grid {
    grid-template-columns: 1fr;
  }

  .be-home-trust__item strong {
    font-size: 20px;
  }

  .be-home-cta {
    padding: 10px 0 40px;
  }
}

/* Contact */
@media screen and (max-width: 1199px) {
  .rv-contact-shell {
    gap: 22px;
  }
}

@media screen and (max-width: 991px) {
  .rv-contact-page {
    padding: 48px 0 28px;
  }

  .rv-contact-aside,
  .rv-contact-form-panel {
    border-radius: 18px;
  }

  .rv-contact-map__frame {
    height: 280px;
  }
}

@media screen and (max-width: 575px) {
  .rv-contact-aside {
    padding: 26px 18px;
  }

  .rv-contact-form-panel {
    padding: 24px 16px;
  }

  .rv-contact-actions {
    flex-direction: column;
  }

  .rv-contact-action {
    width: 100%;
    justify-content: center;
  }

  .rv-contact-map__meta {
    flex-direction: column;
    align-items: flex-start;
  }

  .rv-contact-map__link {
    width: 100%;
  }

  .rv-contact-map__frame {
    height: 240px;
  }
}

/* About */
@media screen and (max-width: 1199px) {
  .rv-about-story {
    gap: 28px;
  }
}

@media screen and (max-width: 991px) {
  .rv-about-page {
    padding: 48px 0 32px;
  }

  .rv-about-story__visual img {
    min-height: 280px;
  }

  .rv-about-stats {
    grid-template-columns: 1fr 1fr;
  }
}

@media screen and (max-width: 575px) {
  .rv-about-story__title {
    font-size: 28px;
  }

  .rv-about-story__chip {
    left: 12px;
    right: 12px;
    bottom: 12px;
    max-width: none;
  }

  .rv-about-mission__main,
  .rv-about-mission__side {
    padding: 22px 18px;
  }

  .rv-about-offer {
    padding: 14px 14px;
    gap: 12px;
  }

  .rv-about-stats {
    grid-template-columns: 1fr;
  }
}

/* Services */
@media screen and (max-width: 1199px) {
  .rv-service-features__grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media screen and (max-width: 991px) {
  .rv-service-page {
    padding: 48px 0 28px;
  }

  .rv-service-aside,
  .rv-service-content {
    border-radius: 18px;
  }
}

@media screen and (max-width: 575px) {
  .rv-service-aside {
    padding: 26px 18px;
  }

  .rv-service-content {
    padding: 24px 16px;
  }

  .rv-service-features__grid {
    grid-template-columns: 1fr;
  }

  .rv-service-actions {
    flex-direction: column;
  }

  .rv-service-action {
    width: 100%;
    justify-content: center;
  }

  .rv-service-content__media img {
    max-height: 200px;
  }
}

/* Products */
@media screen and (max-width: 1199px) {
  .rv-product-intro {
    gap: 28px;
  }
}

@media screen and (max-width: 991px) {
  .rv-product-page {
    padding: 48px 0 28px;
  }

  .rv-product-intro__title {
    font-size: clamp(26px, 6vw, 34px);
  }

  .rv-product-modules__grid {
    grid-template-columns: 1fr;
  }
}

@media screen and (max-width: 575px) {
  .rv-product-intro__media img {
    max-height: 260px;
    padding: 12px;
  }

  .rv-product-module {
    grid-template-columns: 44px 1fr;
    padding: 16px 14px;
  }

  .rv-product-cta {
    padding: 22px 16px;
  }

  .rv-product-intro__actions {
    flex-direction: column;
  }

  .rv-product-btn {
    width: 100%;
    justify-content: center;
  }
}

/* Footer */
@media screen and (max-width: 1199px) {
  .be-footer__touch-grid {
    grid-template-columns: 1fr 1fr;
  }

  .be-footer__touch-action {
    grid-column: 1 / -1;
    justify-content: flex-start;
  }
}

@media screen and (max-width: 991px) {
  .be-footer__top {
    grid-template-columns: 1fr;
  }
}

@media screen and (max-width: 767px) {
  .be-footer__cols {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .be-footer__touch-grid {
    grid-template-columns: 1fr;
  }

  .be-footer__cta {
    width: 100%;
    justify-content: center;
  }
}

@media screen and (max-width: 575px) {
  .be-footer.rv-37-footer,
  .be-footer.rv-34-footer {
    padding-top: 40px;
  }

  .be-footer__cols {
    grid-template-columns: 1fr;
  }
}

/* Generic inner page spacing */
@media screen and (max-width: 991px) {
  .rv-breadcrumb.pt-120 {
    padding-top: 110px !important;
  }

  .rv-breadcrumb.pb-120 {
    padding-bottom: 70px !important;
  }

  .rv-section-spacing {
    padding-top: 60px !important;
    padding-bottom: 60px !important;
  }
}

@media screen and (max-width: 575px) {
  .rv-breadcrumb.pt-120 {
    padding-top: 100px !important;
  }

  .rv-breadcrumb.pb-120 {
    padding-bottom: 50px !important;
  }

  .rv-breadcrumb .rv-breadcrumb__title {
    font-size: 28px !important;
    line-height: 1.25 !important;
    margin-bottom: 10px !important;
  }

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

/* Extra small phones */
@media screen and (max-width: 400px) {
  .rv-breadcrumb .rv-breadcrumb__title {
    font-size: 24px !important;
  }

  .be-home-hero .rv-37-banner__title,
  .be-home-hero__title {
    font-size: 26px !important;
  }

  .rv-37-header .rv-37-logo img {
    max-width: 130px !important;
    max-height: 40px !important;
  }

  .rv-37-header a.rv-37-btn.hide-for-devices {
    display: none !important;
  }
}

/* Large desktops — keep content readable */
@media screen and (min-width: 1400px) {
  .be-footer .container,
  .rv-contact-page .container,
  .rv-about-page .container,
  .rv-service-page .container,
  .rv-product-page .container {
    max-width: 1320px;
  }
}

/* =========================================================
   Extra cross-device hardening (mobile / tablet / laptop)
   ========================================================= */

/* Safe area + tap targets */
button,
.be-home-btn,
.rv-product-btn,
.rv-service-action,
.rv-contact-action,
.be-header__btn,
.rv-33-btn {
  min-height: 44px;
}

.be-header__icon-btn,
.rv-1-header-mobile-menu-btn {
  min-width: 44px;
  min-height: 44px;
}

/* Tablet landscape / small laptops */
@media screen and (max-width: 1199px) {
  .container {
    padding-left: 20px;
    padding-right: 20px;
  }

  .be-home-services__grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
    max-width: none;
  }

  .rv-product-modules__grid {
    grid-template-columns: 1fr 1fr;
  }

  .rv-service-features__grid {
    grid-template-columns: 1fr 1fr;
  }
}

/* Tablets */
@media screen and (max-width: 991px) {
  .be-home-services__grid {
    grid-template-columns: 1fr;
    max-width: 560px;
    margin-left: auto;
    margin-right: auto;
  }

  .rv-product-intro__actions,
  .rv-product-cta > div[style],
  .rv-service-actions,
  .rv-contact-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
  }

  .rv-product-intro {
    text-align: left;
  }

  .rv-product-intro__actions {
    justify-content: flex-start;
  }

  .be-footer__top {
    gap: 28px;
  }

  .be-footer__cols {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 22px;
  }

  .be-home-hero__media,
  .be-home-hero__media img {
    width: 100%;
    max-width: 100%;
  }

  .rv-37-service .row > [class*="col-"] {
    margin-bottom: 16px;
  }
}

/* Phones + small tablets */
@media screen and (max-width: 767px) {
  .container,
  .container-fluid {
    padding-left: 16px !important;
    padding-right: 16px !important;
  }

  .rv-breadcrumb {
    padding-top: 100px !important;
    padding-bottom: 56px !important;
  }

  .rv-breadcrumb .rv-breadcrumb__title {
    font-size: clamp(24px, 7vw, 34px) !important;
    line-height: 1.2 !important;
  }

  .rv-product-modules__grid,
  .rv-service-features__grid,
  .be-home-why__grid,
  .be-home-trust__grid {
    grid-template-columns: 1fr !important;
  }

  .be-footer__cols {
    grid-template-columns: 1fr;
  }

  .be-footer__touch-grid {
    grid-template-columns: 1fr !important;
  }

  .rv-product-intro__actions .rv-product-btn,
  .rv-service-actions .rv-service-action,
  .rv-contact-actions .rv-contact-action {
    width: 100%;
    justify-content: center;
  }

  .rv-product-cta {
    flex-direction: column;
    align-items: stretch !important;
    text-align: left;
    gap: 14px;
  }

  .rv-product-cta .rv-product-btn {
    width: 100%;
  }

  .rv-service-pills,
  .rv-product-intro__pills {
    justify-content: flex-start;
  }

  .admin-app,
  .be-header,
  .be-footer,
  main,
  section {
    max-width: 100vw;
  }

  /* Swiper / gallery overflow guard */
  .swiper,
  .swiper-wrapper,
  .be-home-features,
  .rv-37-gallary-container {
    max-width: 100%;
  }
}

/* Small phones */
@media screen and (max-width: 575px) {
  .be-home-hero__media,
  .be-home-hero__media img,
  .rv-training-page__photo,
  .rv-service-content__media img {
    min-height: 200px !important;
    max-height: 280px;
    object-fit: cover;
  }

  .be-home-label,
  .rv-product-modules__label,
  .rv-service-features__label,
  .rv-contact-aside__brand {
    font-size: 12px;
  }

  .be-home-section-text,
  .rv-product-intro__text,
  .rv-service-aside__text,
  .rv-contact-aside__text {
    font-size: 14px !important;
    line-height: 1.65 !important;
  }

  .rv-37-section-title,
  .be-home-services__title,
  .rv-product-intro__title,
  .rv-service-aside__title {
    font-size: clamp(22px, 6.5vw, 30px) !important;
    line-height: 1.25 !important;
  }

  .be-footer__touch-item,
  .be-footer__brand,
  .be-footer__col {
    width: 100%;
  }

  .rv-contact-form-panel,
  .rv-contact-aside,
  .rv-service-aside,
  .rv-service-content {
    padding-left: 18px !important;
    padding-right: 18px !important;
  }

  input,
  select,
  textarea,
  button {
    font-size: 16px !important; /* prevents iOS zoom */
  }
}

/* Very small phones */
@media screen and (max-width: 400px) {
  .container,
  .container-fluid {
    padding-left: 12px !important;
    padding-right: 12px !important;
  }

  .be-home-btn,
  .rv-product-btn,
  .rv-service-action,
  .rv-contact-action {
    font-size: 13px !important;
    padding-left: 14px !important;
    padding-right: 14px !important;
  }
}

/* Laptop comfort (no cramped tables / cards) */
@media screen and (min-width: 992px) and (max-width: 1366px) {
  .be-home-hero__slide {
    gap: 28px;
  }

  .rv-service-shell,
  .rv-contact-shell,
  .rv-product-intro {
    gap: 24px;
  }
}
