﻿/*
Theme Name: Nerjmetall ACF Theme Base
Theme URI: https://nerjmetall.ru/
Description: Базовая тема под ACF и Bootstrap для проекта nerjmetall.ru
Version: 1.0.0
Text Domain: nerjmetall
*/


@import url('https://fonts.googleapis.com/css2?family=Great+Vibes&family=Merriweather:ital,opsz,wght@0,18..144,300..900;1,18..144,300..900&family=Nunito+Sans:ital,opsz,wght@0,6..12,200..1000;1,6..12,200..1000&family=Sofia+Sans:ital,wght@0,1..1000;1,1..1000&display=swap');


:root {
  --nm-dark: #1f1f1f;
  --nm-accent: #d18b2c;
  --nm-accent-dark: #b97821;
  --nm-light: #f7f7f7;
  --nm-border: #e5e5e5;
}

html {
  scroll-behavior: smooth;
}

body {
  font-family: "Sofia Sans", sans-serif;
  color: var(--nm-dark);
  background: #fff;
}

a {
  color: var(--nm-dark);
  transition: .2s ease;
}

a:hover {
  color: var(--nm-accent-dark);
}

img {
  max-width: 100%;
  height: auto;
}

main.site-main {
  min-height: 60vh;
}

.section-space {
  padding: 56px 0;
}

.section-title {
  margin-bottom: 28px;
  font-weight: 700;
}

.btn-nm {
  background: var(--nm-accent);
  border: 1px solid var(--nm-accent);
  color: #fff;
  padding: .8rem 1.5rem;
  font-weight: 700;
  text-decoration: none;
}

.btn-nm:hover,
.btn-nm:focus {
  background: var(--nm-accent-dark);
  border-color: var(--nm-accent-dark);
  color: #fff;
}

.btn-outline-nm {
  border: 1px solid var(--nm-dark);
  color: var(--nm-dark);
  padding: .8rem 1.5rem;
  font-weight: 700;
  text-decoration: none;
}

.btn-outline-nm:hover,
.btn-outline-nm:focus {
  background: var(--nm-dark);
  color: #fff;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255,255,255,.96);
  backdrop-filter: blur(8px);
  border-bottom: 1px solid var(--nm-border);
}

.topbar {
  border-bottom: 1px solid var(--nm-border);
  font-size: 14px;
}

.site-logo img {
  max-height: 64px;
  width: auto;
}

.header-phone {
  font-weight: 700;
  text-decoration: none;
  white-space: nowrap;
}

.nm-menu,
.nm-footer-menu {
  list-style: none;
  margin: 0;
  padding: 0;
}

.nm-menu {
  display: flex;
  flex-wrap: wrap;
  gap: 20px;
}

.nm-menu a {
  text-decoration: none;
  font-weight: 700;
  padding: 18px 0;
  display: inline-block;
}

.nm-menu .current-menu-item > a,
.nm-menu .current_page_item > a,
.nm-menu .current-menu-ancestor > a {
  color: var(--nm-accent);
}

.hero-home {
  background: linear-gradient(90deg, rgba(0,0,0,.65), rgba(0,0,0,.2));
  color: #fff;
  min-height: 560px;
  display: flex;
  align-items: center;
  background-size: cover;
  background-position: center;
}

.hero-home__content {
  max-width: 700px;
}

.hero-home__title,
.page-hero__title {
  font-size: clamp(2rem, 4vw, 3.6rem);
  line-height: 1.1;
  font-weight: 800;
}

.hero-home__text,
.page-hero__text {
  font-size: 1.1rem;
}

.page-hero {
  padding: 80px 0;
  color: #fff;
  background-size: cover;
  background-position: center;
  position: relative;
}

.page-hero::before {
  content: "";
  position: absolute;
  inset: 0;
  background: rgba(0,0,0,.65);
}

.page-hero .container {
  position: relative;
  z-index: 1;
}

.stat-card,
.portfolio-card,
.service-card,
.contact-card,
.info-card {
  height: 100%;
  background: #fff;
  border: 1px solid var(--nm-border);
  border-radius: 0;
  transition: transform .2s ease, box-shadow .2s ease;
}

.stat-card:hover,
.portfolio-card:hover,
.service-card:hover,
.contact-card:hover,
.info-card:hover {
  transform: translateY(-4px);
  box-shadow: 0 12px 28px rgba(0,0,0,.08);
}

.stat-card__number {
  font-size: 2rem;
  font-weight: 800;
  color: var(--nm-accent);
}

.service-card__image,
.portfolio-card__image,
.service-detail__image img,
.page-intro__image img,
.contact-map iframe,
.contact-map img {
  display: block;
  width: 100%;
}

.service-card__image,
.portfolio-card__image {
  aspect-ratio: 16 / 11;
  object-fit: cover;
}

.service-card__body,
.portfolio-card__body,
.contact-card__body,
.info-card__body {
  padding: 20px;
}

.service-card__title,
.portfolio-card__title,
.contact-card__title {
  font-size: 1.2rem;
  font-weight: 700;
  margin-bottom: 10px;
}

.service-detail__content .acf-wysiwyg,
.nm-content,
.nm-content .wp-block-group {
  font-size: 1rem;
  line-height: 1.7;
}

.service-detail__content ul,
.nm-content ul {
  padding-left: 1.2rem;
}

.cta-box {
  background: var(--nm-light);
  border: 1px solid var(--nm-border);
  padding: 32px;
}

.contact-map iframe {
  min-height: 420px;
  border: 0;
}

.site-footer {
  padding: 48px 0 24px;
  border-top: 1px solid var(--nm-border);
}

.site-footer__title {
  font-weight: 700;
  margin-bottom: 16px;
}

.nm-footer-menu li + li {
  margin-top: 10px;
}

.footer-bottom {
  border-top: 1px solid var(--nm-border);
  padding-top: 18px;
  margin-top: 24px;
  font-size: 14px;
}

.breadcrumbs-wrap {
  font-size: 14px;
  margin-bottom: 18px;
  color: white;
}

.breadcrumbs-wrap a {
  color: #fff;
  text-decoration: none;
}

.breadcrumbs-wrap a:hover {
  color: #fff;
  text-decoration: underline;
}

@media (max-width: 991.98px) {
  .site-header {
    position: static;
  }

  .nm-menu {
    gap: 12px 18px;
  }

  .nm-menu a {
    padding: 8px 0;
  }

  .hero-home,
  .page-hero {
    min-height: auto;
  }
}

@media (max-width: 767.98px) {
  .section-space {
    padding: 40px 0;
  }

  .topbar .d-flex {
    gap: 10px;
  }

  .hero-home {
    padding: 70px 0;
  }

  .page-hero {
    padding: 56px 0;
  }

  .cta-box {
    padding: 24px;
  }
}

/* WYSIWYG tiles */
.nm-tile {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 0;
  overflow: hidden;
  transition: box-shadow .2s ease, transform .2s ease, border-color .2s ease;
}

.nm-tile:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 28px rgba(0,0,0,.08);
  border-color: #d0d7de;
}

.nm-tile__image {
  display: block;
  width: 100%;
  aspect-ratio: 16 / 10;
  object-fit: cover;
}

.nm-tile__body {
  padding: 24px;
}

.nm-tile__number {
  font-size: 32px;
  line-height: 1;
  font-weight: 700;
  margin-bottom: 12px;
  color: var(--nm-accent, #111827);
}

.nm-tile__title {
  font-size: 22px;
  line-height: 1.25;
  font-weight: 700;
  color: #111827;
  margin-bottom: 12px;
}

.nm-tile__text {
  color: #6b7280;
}

.nm-content .row + .row {
  margin-top: .5rem;
}

.nm-burger {
  border: 1px solid #000;
  padding: 6px 10px;
  background: transparent;
  display: inline-flex;
  flex-direction: column;
  justify-content: center;
  gap: 4px;
  border-radius: 0;
  box-shadow: none;
}

.nm-burger span {
  display: block;
  width: 22px;
  height: 2px;
  background: #000;
}

.nm-burger:focus {
  box-shadow: none;
  outline: none;
}

@media (max-width: 991.98px) {
  #nmMainMenu {
    width: 100%;
    padding-top: 12px;
  }

  #nmMainMenu .nm-menu {
    display: flex;
    flex-direction: column;
    gap: 10px;
    margin: 0;
    padding: 0;
    list-style: none;
  }

  #nmMainMenu .nm-menu li,
  #nmMainMenu .nm-menu a {
    display: block;
    width: 100%;
  }
}


.nm-service-hero {
  position: relative;
  background-position: center;
  background-size: cover;
  background-repeat: no-repeat;
}

.nm-service-hero__overlay {
  background: rgba(0, 0, 0, 0.45);
  padding: 100px 0;
}

.nm-service-hero__title {
  color: #fff;
  margin-bottom: 20px;
}

.nm-service-hero__text {
  color: #fff;
  font-size: 18px;
  max-width: 760px;
}

.nm-olive-block {
  background: #92955e;
  color: #fff;
}

.nm-olive-block__text {
  font-size: 18px;
}

.nm-side-image {
  display: block;
  width: 100%;
  height: 100%;
  min-height: 320px;
  object-fit: cover;
}

.nm-static-card {
  height: 100%;
  padding: 32px;
  background: #fff;
  border: 1px solid #e5e5e5;
}

.nm-static-card__title {
  margin-bottom: 20px;
}

.nm-content p:last-child,
.nm-static-card__text p:last-child,
.nm-olive-block__text p:last-child {
  margin-bottom: 0;
}

.nm-wysiwyg-tiles .nm-tile {
  height: 100%;
}

.nm-wysiwyg-tiles .n2-ss-slider,
.nm-examples-slider .n2-ss-slider {
  display: block;
  width: 100% !important;
}

@media (max-width: 991.98px) {
  .nm-service-hero__overlay {
    padding: 70px 0;
  }

  .nm-service-hero__text,
  .nm-olive-block__text {
    font-size: 16px;
  }

  .nm-static-card {
    padding: 24px;
  }

  .nm-side-image {
    min-height: 220px;
  }
}

.cf7-compact .form-label {
  margin-bottom: 4px;
  font-size: 14px;
}

.cf7-compact .form-control {
  padding: 8px 12px;
  font-size: 14px;
  min-height: auto;
}

.cf7-compact textarea.form-control {
  min-height: 90px;
}

.cf7-compact .wpcf7-form-control-wrap {
  display: block;
  margin: 0;
}

.cf7-compact .wpcf7-list-item {
  margin: 0;
}

.cf7-compact .wpcf7-list-item-label {
  font-size: 13px;
}

.cf7-compact .btn {
  padding: 8px 18px;
  font-size: 14px;
}

 #cookie-consent {
    position: fixed;
    bottom: 20px;
    right: 20px;
    max-width: 300px;
    background-color: #ffffff;
    color: #000000;
    padding: 15px 20px 15px 15px;
    border: 1px solid #cccccc;
    border-radius: 4px;
    font-size: 14px;
    box-shadow: 0 2px 6px rgba(0,0,0,0.2);
    z-index: 10000;
  }
  #cookie-consent a {
    color: #000000;
    text-decoration: underline;
  }
  #cookie-consent .close-btn {
    position: absolute;
    top: 5px;
    right: 8px;
    font-size: 16px;
    font-weight: bold;
    color: #666666;
    cursor: pointer;
  }
  #cookie-consent .close-btn:hover {
    color: #000000;
  }

.cf7-compact p {
  margin-bottom: 0;
}

.floating-contacts {
  position: fixed;
  right: 20px;
  bottom: 20px;
  z-index: 1050;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.floating-contact {
  width: 58px;
  height: 58px;
  border-radius: 50%;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  color: #fff;
  box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
  transition: transform .2s ease, box-shadow .2s ease, opacity .2s ease;
}

.floating-contact i {
  font-size: 24px;
  line-height: 1;
}

.floating-contact:hover {
  color: #fff;
  transform: translateY(-2px);
  box-shadow: 0 10px 28px rgba(0, 0, 0, 0.28);
}

.floating-contact:focus {
  color: #fff;
}

.floating-contact--call {
  background: #212529;
}

.floating-contact--wa {
  background: #25D366;
}

.floating-contact--tg {
  background: #229ED9;
}

@media (max-width: 575.98px) {
  .floating-contacts {
    right: 14px;
    bottom: 14px;
    gap: 10px;
  }

  .floating-contact {
    width: 52px;
    height: 52px;
  }

  .floating-contact i {
    font-size: 21px;
  }
}

.carousel-item {
  background: #fff;
}

.carousel-item img {
  display: block;
  width: 100%;
  height: 420px;
  object-fit: contain;
  object-position: center;
  background: #fff;
}

.carousel-control-prev,
.carousel-control-next {
  width: 8%;
}

.carousel-control-prev-icon,
.carousel-control-next-icon {
  width: 42px;
  height: 42px;
  background-size: 55% 55%;
  background-color: rgba(0, 0, 0, 0.35);
  border-radius: 50%;
  filter: invert(1);
}

.carousel-indicators [data-bs-target] {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background-color: #222;
}

@media (max-width: 767.98px) {
  .carousel-item img {
    height: 240px;
  }

  .carousel-control-prev-icon,
  .carousel-control-next-icon {
    width: 36px;
    height: 36px;
  }
}




.nm-portfolio-card {
  background: #fff;
  border: 1px solid #e5e5e5;
  height: 100%;
  display: flex;
  flex-direction: column;
}

.nm-portfolio-card__image-wrap {
  display: block;
  background: #f8f8f8;
  text-decoration: none;
  overflow: hidden;
}

.nm-portfolio-card__image {
  display: block;
  width: 100%;
  height: 220px;
  object-fit: cover;
  transition: transform .25s ease;
}

.nm-portfolio-card__image-wrap:hover .nm-portfolio-card__image {
  transform: scale(1.03);
}

.nm-portfolio-card__body {
  padding: 16px;
  display: flex;
  flex-direction: column;
  gap: 14px;
  flex: 1 1 auto;
}

.nm-portfolio-card__title {
  font-weight: 700;
  line-height: 1.35;
  min-height: 44px;
}

.nm-portfolio-modal-image {
  max-height: 80vh;
  object-fit: contain;
  background: #fff;
}

#portfolioImageModal .modal-content {
  box-shadow: none;
}

@media (max-width: 991.98px) {
  .nm-portfolio-card__image {
    height: 200px;
  }
}

@media (max-width: 575.98px) {
  .nm-portfolio-card__image {
    height: 220px;
  }

  .nm-portfolio-card__body {
    padding: 14px;
  }
}







.nm-home-clients {
  overflow: hidden;
}

.nm-home-clients .carousel {
  padding: 0 50px;
}

.nm-client-tile {
  display: flex;
  flex-direction: column;
  height: 100%;
  background: #f3f3f3;
  border: 1px solid #dcdcdc;
  color: #212529;
  transition: transform .2s ease, box-shadow .2s ease;
}

.nm-client-tile:hover {
  color: #212529;
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(0, 0, 0, 0.08);
}

.nm-client-tile__image {
  display: flex;
  align-items: center;
  justify-content: center;
  height: 180px;
  padding: 20px;
  background: #5f5f5f;
  border-bottom: 1px solid #dcdcdc;
  overflow: hidden;
}

.nm-client-tile__image img {
  max-width: 100%;
  max-height: 100%;
  width: auto;
  height: auto;
  object-fit: contain;
  display: block;
  background: transparent;
}

.nm-client-tile__desc {
  display: block;
  padding: 16px;
  font-size: 15px;
  line-height: 1.4;
  font-weight: 500;
  min-height: 110px;
}

.nm-home-clients .carousel-control-prev,
.nm-home-clients .carousel-control-next {
  width: 50px;
}

.nm-home-clients .carousel-control-prev-icon,
.nm-home-clients .carousel-control-next-icon {
  width: 40px;
  height: 40px;
  background-size: 55% 55%;
  background-color: rgba(0, 0, 0, 0.35);
  border-radius: 50%;
  filter: invert(1);
}

.nm-home-clients .carousel-indicators [data-bs-target] {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background-color: #222;
}

@media (max-width: 991.98px) {
  .nm-home-clients .carousel {
    padding: 0 40px;
  }

  .nm-client-tile__image {
    height: 160px;
  }

  .nm-client-tile__desc {
    min-height: 96px;
  }
}

@media (max-width: 575.98px) {
  .nm-home-clients .carousel {
    padding: 0 32px;
  }

  .nm-client-tile__image {
    height: 150px;
    padding: 16px;
  }

  .nm-client-tile__desc {
    min-height: auto;
    padding: 14px;
    font-size: 14px;
  }

  .nm-home-clients .carousel-control-prev-icon,
  .nm-home-clients .carousel-control-next-icon {
    width: 34px;
    height: 34px;
  }
}