/* Mobile-only extras previously in index.html tail */
@media (max-width: 1024px) {
  /* Ensure gray background fill on mobile footer */
  html body footer { background-color: #666666 !important; min-height: 200px !important; }
  /* Красим вложенные контейнеры тоже в серый, чтобы не было белых просветов */
  html body footer .container,
  html body footer .row,
  html body footer .card-body,
  html body footer .footer-text1,
  html body footer .footer-text3,
  html body footer .footerLogo,
  html body footer .footerIcon { background-color: #666666 !important; }
  html body footer .footer-bottom { background-color: #313131 !important; }
  .social-icon.is-active { filter: none !important; }
  .iconAbout.is-active {
    transform: none !important;
    filter: none !important;
    box-shadow: none !important;
    border-radius: 0 !important;
    outline: none !important;
    outline-offset: 0 !important;
  }
}

/* Remove thick outline/ring on burger button after close */
.navbar-toggler:focus,
.navbar-toggler:active {
  outline: none !important;
  box-shadow: none !important;
}
/* Also suppress focus-visible ring and bootstrap var-driven ring */
.navbar-toggler:focus-visible { outline: none !important; box-shadow: none !important; }
.navbar-toggler { --bs-navbar-toggler-focus-width: 0 !important; }
/* Extracted from index.html <style> blocks. Keep last to preserve priority. */

/* Contacts page: enforce readable dark text on light background */
html body main.contacts,
html body main.contacts h1,
html body main.contacts h2,
html body main.contacts h3,
html body main.contacts h4,
html body main.contacts h5,
html body main.contacts h6,
html body main.contacts p,
html body main.contacts a,
html body main.contacts dt,
html body main.contacts dd {
  color: #111111 !important;
}
html body main.contacts a:hover, html body main.contacts a:focus { color: #000000 !important; }

/* Footer base styles are centralized in css/footer-styles.css */

/* Split footer-bottom into 2 columns on phones */
@media (max-width: 767px) {
  /* Prevent horizontal overflow on phones */
  html, body { overflow-x: hidden !important; }
  /* Cancel full-bleed sections that use 100vw and negative margins */
  html body .index-section {
    width: 100% !important;
    left: auto !important;
    right: auto !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
  }
  html body footer .footer-bottom { 
    display: flex !important; 
    align-items: center !important; 
    justify-content: space-between !important;
  }
  html body footer .footer-bottom .col-sm-1 { display: none !important; }
  html body footer .footer-bottom .footer-bottom_p1,
  html body footer .footer-bottom .footer-bottom_p2 {
    flex: 0 0 50% !important;
    max-width: 50% !important;
    width: 50% !important;
    padding: 0 8px !important;
    display: flex !important;
    align-items: center !important;
  }
  html body footer .footer-bottom .footer-bottom_p1 { text-align: left !important; }
  html body footer .footer-bottom .footer-bottom_p2 { text-align: right !important; margin-left: 0 !important; }
}

/* Remove bottom margins from divs within footer-bottom (all viewports) */
html body footer .footer-bottom > div { margin-bottom: 0 !important; }

/* Right-align the developer credit block */
html body footer .footer-bottom .footer-bottom_p2 {
  margin-left: auto !important;
  text-align: right !important;
  display: flex !important;
  justify-content: flex-end !important;
  align-items: center !important;
}

/* Remove padding from developer text block */
html body footer .footer-bottom .footer-bottom_p2,
html body footer .footer-bottom .footer-bottom_p2 p,
html body footer .footer-bottom .footer-bottom_p2 a { padding: 0 !important; }

/* Add small right padding to developer text */
html body footer .footer-bottom .footer-bottom_p2 { padding-right: 20px !important; }

/* Mobile: break line after "Для писем:" label */
@media (max-width: 767px) {
  html body footer .footer-text3 .letters-label::after {
    content: "\A";
    white-space: pre; /* ensure the newline renders */
  }
}

/* Phone: remove caption background and controls on first carousel slide */
@media (max-width: 767px) {
  /* Remove any background/overlay behind caption on slide1 */
  #carouselSlides .carousel-item.slide1 .carousel-caption,
  #carouselSlides .carousel-item.slide1 .carousel-caption::before,
  #carouselSlides .carousel-item.slide1 .carousel-caption * {
    background: transparent !important;
    background-color: transparent !important;
    box-shadow: none !important;
    text-shadow: none !important;
    backdrop-filter: none !important;
  }
  /* Hide prev/next controls on phones */
  #carouselSlides .carousel-control-prev,
  #carouselSlides .carousel-control-next { display: none !important; }
}

/* Phone: remove dark overlay on first slide entirely */
@media (max-width: 767px) {
  #carouselSlides .carousel-item.slide1::before,
  #carouselSlides .carousel-item.slide1::after,
  #carouselSlides .carousel-item::before,
  #carouselSlides .carousel-item::after {
    content: none !important;
    display: none !important;
    background: none !important;
    background-image: none !important;
    opacity: 0 !important;
  }
  #carouselSlides .carousel-item.slide1 picture,
  #carouselSlides .carousel-item.slide1 img {
    filter: none !important;
    opacity: 1 !important;
    mix-blend-mode: normal !important;
  }
}

/* Force white text in footer */
footer,
footer h1,
footer h2,
footer h3,
footer h4,
footer h5,
footer h6,
footer p,
footer span,
footer div,
body footer h1,
body footer h2,
body footer h3,
body footer h4,
body footer h5,
body footer h6,
body footer p,
body footer span,
body footer div,
body footer a {
    color: #fff !important;
}

/* Mobile activation: swap icons like :hover */
#icon_1About.is-active { content: url("../../images/Icon/reward1.png") !important; }
#icon_2About.is-active { content: url("../../images/Icon/individualApproach1.png") !important; }
#icon_3About.is-active { content: url("../../images/Icon/present1.png") !important; }

/* WhyChooseUs icons */
#icon_1WhyChooseUs.is-active { content: url("../../images/Icon2/highQuality1.png") !important; }
#icon_2WhyChooseUs.is-active { content: url("../../images/Icon2/professionalism1.png") !important; }
#icon_3WhyChooseUs.is-active { content: url("../../images/Icon2/individualApproach1.png") !important; }
#icon_4WhyChooseUs.is-active { content: url("../../images/Icon2/calendar1.png") !important; }
#icon_5WhyChooseUs.is-active { content: url("../../images/Icon2/competitivePrices1.png") !important; }

/* Keep carousel text white */
#carouselSlides .carousel-caption h1,
#carouselSlides .carousel-caption h2,
#carouselSlides .carousel-caption h3,
#carouselSlides .carousel-caption h4,
#carouselSlides .carousel-caption h5,
#carouselSlides .carousel-caption h6,
#carouselSlides .carousel-caption p,
#carouselSlides .carousel-caption span,
#carouselSlides .carousel-caption div,
.carousel-caption h1,
.carousel-caption h2,
.carousel-caption h3,
.carousel-caption h4,
.carousel-caption h5,
.carousel-caption h6,
.carousel-caption p,
.carousel-caption span,
.carousel-caption div {
    color: #fff !important;
}

.sloganIndexWhyChooseUscontainer h2 { font-size: 35px !important; }
.sloganIndexWhyChooseUscontainer { margin-bottom: 130px !important; }
.partners-section { margin-bottom: 0 !important; }
.partners-header h2 { font-size: 38px !important; }

/* Make 'Что мы предлагаем' section full-width */
html body .ourServices-block {
  width: 100% !important;
  max-width: 100% !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
  box-sizing: border-box !important;
}
html body .ourServices-block > .ourOffersBlock,
html body .ourServices-block > .container,
html body .ourServices-block .container {
  width: 100% !important;
  max-width: 100% !important;
  padding-left: 0 !important;
  padding-right: 0 !important;
  box-sizing: border-box !important;
}

/* Mobile: prevent heading clipping in 'Что мы предлагаем' */
@media (max-width: 767px) {
  html body .ourServices-block h2 {
    padding-left: 12px !important;
    padding-right: 12px !important;
    white-space: normal !important;
    overflow: visible !important;
    text-overflow: clip !important;
    word-break: break-word !important;
    width: 100% !important;
    max-width: 100% !important;
    min-width: 280px !important;
    line-height: 1.4 !important;
    font-size: 29px !important; /* +4 пункта к 25px */
    font-weight: 500 !important; /* medium weight only on phones */
    min-height: 2.8em !important; /* reserve space for two lines */
    margin-left: auto !important;
    margin-right: auto !important;
    position: relative !important;
    z-index: 10 !important;
    margin-top: 12px !important;
    margin-bottom: 12px !important;
    display: block !important;
    clear: both !important;
    box-sizing: border-box !important;
  }
  /* Only on phones: remove top margin of services section (override mt-5) */
  html body .ourServices-block { margin-top: 0 !important; }
  /* Only on phones: remove bottom margin on .cardtAny */
  html body .cardtAny { margin-bottom: 0 !important; margin-block-end: 0 !important; }
  html body .ourServices-block { overflow: visible !important; padding-bottom: 12px !important; }
  html body .ourServices-block .ourOffersBlock { margin-top: 16px !important; position: relative !important; z-index: 0 !important; clear: both !important; }
}

/* Fix for Google Translate wrapping text with <font> tags causing clipping */
html body .ourServices-block h2 font {
  display: inline-block !important;
  white-space: normal !important;
  line-height: 1.25 !important;
}

/* Ensure heading never clips on any viewport */
html body .ourServices-block h2 {
  white-space: normal !important;
  overflow: visible !important;
  text-overflow: clip !important;
  word-break: break-word !important;
  font-weight: 400 !important;
}

/* Make inner service sliders full-width on phones/tablets */
@media (max-width: 1024px) {
  /* make the section container full-bleed */
  html body .ourServices-block {
    width: 100% !important;
    max-width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
    padding-left: 0 !important;
    padding-right: 0 !important;
    box-sizing: border-box !important;
  }

  html body .ourServices-block,
  html body .ourServices-block > .ourOffersBlock,
  html body .ourOffersBlock .container,
  html body .ourOffersBlock .row,
  html body .ourOffersBlock [class*="col-"] {
    padding-left: 0 !important;
    padding-right: 0 !important;
  }

  /* remove Bootstrap gutters inside this section */
  html body .ourOffersBlock .row {
    --bs-gutter-x: 0 !important;
    --bs-gutter-y: 0 !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
  }
  html body .ourOffersBlock [class^="col-"],
  html body .ourOffersBlock [class*=" col-"] {
    padding-left: 0 !important;
    padding-right: 0 !important;
  }

  html body #publishing-slider,
  html body #photo-slider,
  html body #aerial-slider {
    width: 100% !important;
    max-width: 100% !important;
    margin-left: 0 !important;
    margin-right: 0 !important;
  }

  html body .carouselImg {
    margin-left: 0 !important;
    margin-right: 0 !important;
    width: 100% !important;
  }
  /* Footer: place email on its own line */
  html body footer .footer-email { display: block !important; width: 100% !important; text-align: center !important; margin-top: 6px !important; }
  /* Force email to a new line and full width on phones */
  html body footer .footer-text3 .footer-email { display: block !important; width: 100% !important; white-space: normal !important; }
}

/* Desktop/tablet: show address and email on separate lines, and keep 'Для писем:' with address on one line */
@media (min-width: 768px) {
  html body footer .footer-text3 p { display: block !important; margin: 0 !important; }
  html body footer .footer-text3 .footer-email { display: block !important; margin-top: 6px !important; }
  /* Keep label and address together on one line */
  html body footer .footer-text3 p:nth-of-type(3) { white-space: nowrap !important; text-align: right !important; }
  html body footer .footer-text3 .letters-label::after { content: none !important; }
  /* Align like other pages: address (2nd p) and 'Для писем' (3rd p) to the right */
  html body footer .footer-text3 p:nth-of-type(2),
  html body footer .footer-text3 p:nth-of-type(3) { text-align: right !important; }
}

/* Footer logo sizing centralized in footer-styles.css; avoid overrides here */

/* WhyChooseUs icons sizing */
.indexWhyChooseUs1 .iconAbout,
.indexWhyChooseUs2 .iconAbout,
.indexWhyChooseUs1 span[class*="iconAbout"] {
    width: 60px !important;
    height: 60px !important;
    background-size: contain !important;
    background-position: center !important;
    background-repeat: no-repeat !important;
}

/* (reverted) do not hide slides pre-initialization */

/* Hover effects for About icons */
#icon_1About:hover,
#icon_2About:hover,
#icon_3About:hover {
    transform: scale(1.1) !important;
    transition: all 0.3s ease !important;
}

/* Tablet (<=1024px) */
@media (max-width: 1024px) {
    nav.navbar .container { display: flex !important; align-items: center !important; }
    nav.navbar .navbar-toggler { align-self: center !important; display: flex !important; align-items: center !important; margin-top: 0 !important; margin-bottom: 0 !important; }
    body { font-size: 16px !important; line-height: 1.6 !important; }
    .navbar { padding: 0.5rem 0 !important; }
    .navbar-brand img { max-height: 40px !important; width: auto !important; }
    .container { padding-left: 15px !important; padding-right: 15px !important; }
    #carouselSlides .carousel-caption.text-center h1,
    #carouselSlides .carousel-caption.text-center h2,
    #carouselSlides .carousel-caption.text-center h3 { font-size: 52px !important; inline-size: 90vw !important; line-height: 1.2 !important; padding: 4px 8px !important; }
    .indexAbout h2, .additional-block h2, .ourServices-block h2, .sloganIndexWhyChooseUscontainer h2 { font-size: 25px !important; }
    .smallShow.ourService-title h5, .ourServices-block h5 { font-size: 25px !important; }
    .ourServices-text p, .ourServices-text_2 p { font-size: 15px !important; text-align: center !important; white-space: normal !important; padding-left: 10px !important; padding-right: 10px !important; }
    .ourServices.ourServices-text p, .ourServices.ourServices-text_2 p { text-align: center !important; display: block !important; margin-left: auto !important; margin-right: auto !important; padding-left: 10px !important; padding-right: 10px !important; }
    .smallShow.ourService-title { text-align: center !important; margin: 0 auto !important; padding-left: 0 !important; padding-right: 0 !important; display: flex !important; justify-content: center !important; align-items: center !important; width: 100% !important; }
    .smallShow.ourService-title h5 { text-align: center !important; margin: 0 auto !important; display: block !important; width: 100% !important; }
    .indexWhyChooseUs1 { block-size: 250px !important; }
    .indexWhyChooseUs1 .equal-grid { grid-template-columns: repeat(2, 1fr) !important; gap: 20px !important; }
    .indexWhyChooseUs2 .row { flex-direction: column !important; }
    .indexWhyChooseUs2 .col-md-2 { display: none !important; }
    .indexWhyChooseUs2 .col-md-4 { width: 100% !important; margin-bottom: 20px !important; }
    .carousel-caption h1, .carousel-caption h2, .carousel-caption h3, .carousel-caption h4, .carousel-caption h5, .carousel-caption h6, .carousel-caption p, .carousel-caption span, .carousel-caption div { color: #fff !important; }
    footer, footer h1, footer h2, footer h3, footer h4, footer h5, footer h6, footer p, footer span, footer div, footer a { color: #fff !important; }
}

/* Phone (<=767px) */
@media (max-width: 767px) {
    body { font-size: 14px !important; line-height: 1.5 !important; }
    .navbar { padding: 0.25rem 0 !important; }
    .navbar-brand img { max-height: 35px !important; width: auto !important; }
    .navbar-toggler { padding: 0.25rem 0.5rem !important; font-size: 1rem !important; }
    .container { padding-left: 10px !important; padding-right: 10px !important; }
    section { margin-bottom: 2rem !important; padding: 1rem 0 !important; }
    img { max-width: 100% !important; height: auto !important; }
    .card { margin-bottom: 1rem !important; border-radius: 8px !important; }
    .card-body { padding: 1rem !important; }
    #carouselSlides .carousel-caption.text-center h1, 
    #carouselSlides .carousel-caption.text-center h2,
    #carouselSlides .carousel-caption.text-center h3 { font-size: 31px !important; inline-size: 95vw !important; padding: 3px 6px !important; line-height: 1.1 !important; }
    
    /* Уменьшенный шрифт только для первого слайда с брошюрами */
    #carouselSlides .carousel-item.slide1 .carousel-caption.text-center h1,
    #carouselSlides .carousel-item.slide1 .carousel-caption.text-center h2,
    #carouselSlides .carousel-item.slide1 .carousel-caption.text-center h3 { 
        font-size: 27px !important; 
        font-weight: 700 !important;
        -webkit-text-stroke: none !important;
        text-stroke: none !important;
    }

    /* Убираем обводку и делаем жирнее для остальных слайдов */
    #carouselSlides .carousel-item:not(.slide1) .carousel-caption.text-center h1,
    #carouselSlides .carousel-item:not(.slide1) .carousel-caption.text-center h2,
    #carouselSlides .carousel-item:not(.slide1) .carousel-caption.text-center h3 { 
        font-weight: 700 !important;
        -webkit-text-stroke: none !important;
        text-stroke: none !important;
    }
    .indexAbout h2, .additional-block h2, .ourServices-block h2, .sloganIndexWhyChooseUscontainer h2 { font-size: 25px !important; }
    .smallShow.ourService-title h5, .ourServices-block h5 { font-size: 25px !important; }
    .ourServices-text p, .ourServices-text_2 p { font-size: 15px !important; text-align: center !important; white-space: normal !important; }
    .ourServices.ourServices-text p, .ourServices.ourServices-text_2 p { text-align: center !important; display: block !important; margin-left: auto !important; margin-right: auto !important; }
    .smallShow.ourService-title { text-align: center !important; margin: 0 auto !important; padding-left: 0 !important; padding-right: 0 !important; }
    .aerial-title, .smallShow.ourService-title { text-align: center !important; margin: 0 auto !important; padding-left: 0 !important; padding-right: 0 !important; display: flex !important; justify-content: center !important; align-items: center !important; width: 100% !important; }
    .smallShow.ourService-title h5 { text-align: center !important; margin: 0 auto !important; display: block !important; width: 100% !important; }
    .indexWhyChooseUs1 { block-size: auto !important; margin: 20px 0 50px !important; }
    .indexWhyChooseUs1 .equal-grid { grid-template-columns: 1fr !important; gap: 15px !important; padding-left: 15px !important; padding-right: 15px !important; }
    .indexWhyChooseUs2 { margin-block-end: 50px !important; }
    .indexWhyChooseUs2 .row { flex-direction: column !important; }
    .indexWhyChooseUs2 .col-md-2 { display: none !important; }
    .indexWhyChooseUs2 .col-md-4 { width: 100% !important; margin-bottom: 15px !important; }
    .card-title { font-size: 20px !important; }
    .card-text { font-size: 14px !important; }
    .iconAbout { width: 50px !important; height: 50px !important; }
    .footerImg { height: 135px !important; }
    .sloganIndexWhyChooseUscontainer { margin-bottom: 60px !important; }
    .sloganIndexWhyChooseUscontainer { min-height: calc(100% + 85px) !important; padding-top: 85px !important; padding-bottom: 85px !important; }
    /* Add inner horizontal padding for the slogan block on mobile */
    html body .sloganIndexWhyChooseUscontainer { padding-left: 5px !important; padding-right: 5px !important; }
    html body .sloganIndexWhyChooseUscontainer h2 { padding-left: 5px !important; padding-right: 5px !important; }
    .sloganOurPartners h2, .partners-header h2 { font-size: 21.5px !important; }
    .footer .row { display: flex !important; flex-direction: column !important; align-items: center !important; text-align: center !important; }
    .footer .col-lg-4, .footer .col-md-6, .footer .col-12 { width: 100% !important; max-width: 100% !important; margin-bottom: 20px !important; text-align: center !important; }
    .footer .footerIcon { display: flex !important; justify-content: center !important; align-items: center !important; width: 100% !important; }
    .footer .footerLogo { display: flex !important; justify-content: center !important; align-items: center !important; width: 100% !important; }
    .footer .footerImg { display: block !important; margin: 0 auto !important; }
    .footer .footer-text1, .footer .footer-text3 { text-align: center !important; width: 100% !important; }
    .footer .footer-bottom { text-align: center !important; margin-top: 20px !important; }
    .carousel-caption h1, .carousel-caption h2, .carousel-caption h3, .carousel-caption h4, .carousel-caption h5, .carousel-caption h6, .carousel-caption p, .carousel-caption span, .carousel-caption div { color: #fff !important; }
    footer, footer h1, footer h2, footer h3, footer h4, footer h5, footer h6, footer p, footer span, footer div, footer a { color: #fff !important; }
}

/* Very small screens (<=480px) */
@media (max-width: 480px) {
    .navbar-brand img { max-height: 30px !important; }
    .container { padding-left: 8px !important; padding-right: 8px !important; }
    h1, h2, h3, h4, h5, h6 { margin-bottom: 0.5rem !important; }
    .btn { padding: 0.375rem 0.75rem !important; font-size: 0.875rem !important; }
    p { margin-bottom: 0.75rem !important; line-height: 1.4 !important; }
    .marquee img { block-size: 75px !important; }
    .marquee-container { margin-top: 5px !important; margin-bottom: 5px !important; }
}

/* Landscape phones */
@media (max-width: 767px) and (orientation: landscape) {
    .navbar { padding: 0.125rem 0 !important; }
    .navbar-brand img { max-height: 25px !important; }
    section { margin-bottom: 1rem !important; padding: 0.5rem 0 !important; }
}

/* Mobile performance tweaks */
@media (max-width: 1024px) {
    @media (prefers-reduced-motion: reduce) {
        *, *::before, *::after { animation-duration: 0.01ms !important; animation-iteration-count: 1 !important; transition-duration: 0.01ms !important; }
    }
    .btn, .navbar-toggler, a { min-height: 44px !important; min-width: 44px !important; display: inline-flex !important; align-items: center !important; justify-content: center !important; }
    html { scroll-behavior: smooth !important; -webkit-overflow-scrolling: touch !important; }
    .carousel-item img { object-fit: cover !important; object-position: center !important; }
    .card, .btn, .navbar-nav .nav-link { margin-bottom: 0.5rem !important; }
    .marquee img { block-size: 75px !important; }
    .marquee-container { margin-top: 10px !important; margin-bottom: 10px !important; }
}

/* Footer layout/height is controlled by footer-styles.css */

/* Remove extra spacing above footer-bottom on desktop too */
footer .container { margin-bottom: 0 !important; padding-bottom: 0 !important; }
footer .container > .row { margin-bottom: 0 !important; }

/* Final strongest selectors */
html body #carouselSlides .carousel-caption h1,
html body #carouselSlides .carousel-caption h2,
html body #carouselSlides .carousel-caption h3,
html body #carouselSlides .carousel-caption h4,
html body #carouselSlides .carousel-caption h5,
html body #carouselSlides .carousel-caption h6,
html body #carouselSlides .carousel-caption p,
html body #carouselSlides .carousel-caption span,
html body #carouselSlides .carousel-caption div,
html body footer,
html body footer h1,
html body footer h2,
html body footer h3,
html body footer h4,
html body footer h5,
html body footer h6,
html body footer p,
html body footer span,
html body footer div,
html body footer a,
html body footer .card-body { color: #ffffff !important; }

/* Add spacing below the top slider across all viewports */
html body #carouselSlides { margin-bottom: 15px !important; }


/* Mobile footer hard overrides (ensure apply on phones/tablets) */
@media (max-width: 1024px) {
  html body footer .row { display: flex !important; flex-direction: column !important; align-items: center !important; text-align: center !important; min-height: 200px !important; }
  html body footer .col-md-4, html body footer .col-sm-12, html body footer .col-lg-4, html body footer .col-md-6, html body footer .col-12 {
    width: 100% !important; max-width: 100% !important; margin: 0 0 20px 0 !important; padding: 0 !important; text-align: center !important;
  }
  html body footer .footerIcon, html body footer .footerLogo { display: flex !important; justify-content: center !important; align-items: center !important; width: 100% !important; }
  html body footer .footerImg { display: block !important; margin: 0 auto !important; height: 135px !important; width: auto !important; }
  html body footer .footer-text1, html body footer .footer-text3 { text-align: center !important; width: 100% !important; }
  html body footer .footer-bottom { display: flex !important; align-items: center !important; justify-content: space-between !important; width: 100% !important; text-align: center !important; margin: 0 !important; padding: 10px 0 !important; }
  /* Убираем отступы у контейнера над footer-bottom */
  html body footer .container { margin-bottom: 0 !important; padding-bottom: 0 !important; }
  html body footer .container > .row { margin-bottom: 0 !important; }
  html body footer .footer-bottom .footer-bottom_p2 { text-align: right !important; margin-left: auto !important; }
  html body footer .footer-bottom p { font-size: 11px !important; line-height: 1.2 !important; margin: 0 !important; }
  html body footer .footer-text3 p.contact-phoneFooter, html body footer .footer-text3 p, html body footer .footer-text3 p a.contact-phoneFooter {
    line-height: 29px !important; height: 29px !important; min-height: 29px !important; max-height: 29px !important; margin: 0 !important; padding: 0 !important; display: inline-block !important; white-space: nowrap !important;
  }
  html body footer .footer-bottom .footer-copyright .unp-sep { display: none !important; }
  html body footer .footer-bottom .footer-unp { display: block !important; }
}

/* Remove any remaining gap above footer-bottom (all viewports) */
footer .container { margin-bottom: 0 !important; padding-bottom: 0 !important; }
footer .container > .row { margin-bottom: 0 !important; min-height: auto !important; }
footer .row { min-height: auto !important; }
footer .card-body { padding-top: 0 !important; padding-bottom: 0 !important; }
footer .footerIcon, footer .footerLogo, footer .footer-text1, footer .footer-text3 { margin: 0 !important; padding: 0 !important; }




/* Strong centering for footer logo to avoid right shift on server */
html body footer .footerIcon,
html body footer .footerLogo { display: flex !important; justify-content: center !important; align-items: center !important; }
html body footer .footerLogo img.footerImg { display: block !important; margin-left: auto !important; margin-right: auto !important; float: none !important; }
/* Remove potential column padding causing horizontal shift */
html body footer .row > .col-md-4:first-child { padding-left: 0 !important; padding-right: 0 !important; margin-left: 0 !important; margin-right: 0 !important; }
/* On phones ensure the first footer column spans full width and is centered */
@media (max-width: 767px) {
  html body footer .row { justify-content: center !important; }
  html body footer .row > .col-md-4:first-child { width: 100% !important; max-width: 100% !important; text-align: center !important; }
}

/* Consistent inner padding for text blocks on phones */
@media (max-width: 767px) {
  /* Apply to headings and paragraphs inside main sections */
  html body main section h1,
  html body main section h2,
  html body main section h3,
  html body main section h4,
  html body main section h5,
  html body main section h6,
  html body main section p {
    padding-left: 20px !important;
    padding-right: 20px !important;
  }
  /* Ensure service text paragraphs also get 20px */
  html body .ourServices-text p,
  html body .ourServices-text_2 p {
    padding-left: 20px !important;
    padding-right: 20px !important;
  }
  /* Do not add padding inside carousel captions */
  html body #carouselSlides .carousel-caption h1,
  html body #carouselSlides .carousel-caption h2,
  html body #carouselSlides .carousel-caption h3,
  html body #carouselSlides .carousel-caption h4,
  html body #carouselSlides .carousel-caption h5,
  html body #carouselSlides .carousel-caption h6,
  html body #carouselSlides .carousel-caption p {
    padding-left: 0 !important;
    padding-right: 0 !important;
  }
}

/* Stronger mobile override so weight applies after global rule */
@media (max-width: 767px) {
  html body .ourServices-block h2 { font-weight: 500 !important; }
}

/* Mobile: left-align navbar brand and keep burger at right across pages */
@media (max-width: 767px) {
  nav#overlay .container { position: relative !important; }
  nav#overlay .navbar-brand { display: block !important; margin-left: 0 !important; margin-right: 0 !important; text-align: left !important; padding-left: 15px !important; }
  nav#overlay .navbar-brand picture,
  nav#overlay .navbar-brand img { display: block !important; margin-left: 0 !important; margin-right: 0 !important; }
  nav#overlay .navbar-toggler { position: absolute !important; right: 15px !important; top: 50% !important; transform: translateY(-50%) !important; }
  nav#overlay .col-md-3, nav#overlay .col-md-9 { width: 100% !important; max-width: 100% !important; }
  /* Force flex left align for the logo column */
  nav#overlay .col-md-3 { display: flex !important; justify-content: flex-start !important; align-items: center !important; }
  
  /* Hide H1 main heading on mobile devices but keep for SEO */
  html body main h1 {
    position: absolute !important;
    left: -9999px !important;
    width: 1px !important;
    height: 1px !important;
    overflow: hidden !important;
    clip: rect(0, 0, 0, 0) !important;
    white-space: nowrap !important;
    border: 0 !important;
  }
}

/* Footer hover effects for desktop only */
@media (min-width: 768px) {
  /* Add transition for smooth hover effect */
  html body footer a.linkServicesFooter,
  html body footer a.contact-phoneFooter {
    transition: color 0.3s ease !important;
  }
  
  /* Hover effect for service links in footer */
  html body footer a.linkServicesFooter:hover {
    color: rgb(51, 55, 140) !important;
    text-decoration: none !important;
  }
  
  /* Hover effect for phone links in footer */
  html body footer a.contact-phoneFooter:hover {
    color: rgb(51, 55, 140) !important;
    text-decoration: none !important;
  }
}

/* Desktop: right-align "ФОТОГРАФИЧЕСКИЕ УСЛУГИ" title */
@media (min-width: 768px) {
  /* Target the second service title (ФОТОГРАФИЧЕСКИЕ УСЛУГИ) - more specific selector */
  html body .ourServices-block .smallShow.ourService-title:nth-of-type(2),
  html body .ourServices-block .smallShow.ourService-title:nth-child(3) {
    text-align: right !important;
  }
  
  /* Target the h3 inside the second service title */
  html body .ourServices-block .smallShow.ourService-title:nth-of-type(2) h3,
  html body .ourServices-block .smallShow.ourService-title:nth-child(3) h3 {
    text-align: right !important;
  }
  
  /* Also target the hidden version */
  html body .ourServices-block .smallDontShow h3:contains("ФОТОГРАФИЧЕСКИЕ УСЛУГИ") {
    text-align: right !important;
  }
}
