/* ---------- USLUGI ---------- */
#uslugi {
  padding: 50px 20px;
  background: white;
  text-align: center; 
}

#uslugi h2 {
  margin-bottom: 30px;
  font-size: 2rem;
  font-weight: bold;
}

.uslugi-scroll { 
  display: flex;
  flex-wrap: wrap; 
  gap: 20px;
  justify-content: center; 
  padding: 10px 0;
  overflow-x: auto; 
}

.uslugi-scroll::-webkit-scrollbar {
  display: none;
}

.usluga {
  flex: 0 0 auto;
  width: 220px; 
  background: #fafafa;
  border-radius: 12px;
  padding: 15px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
  text-align: center;
  transition: transform 0.3s ease;
  display: block;     
  text-decoration: none;
  color: inherit; 
  cursor: pointer;
}

.usluga:hover {
  transform: translateY(-5px);
}

.usluga img {
  width: 100%;
  height: 160px;
  object-fit: cover;
  border-radius: 10px;
}

.usluga p {
  margin-top: 12px;
  color: #333;
  font-size: 1rem;
  font-weight: 600;
  line-height: 1.3;
}

/* ---------- MODAL ---------- */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0,0,0,0.5);
  display: flex;
  justify-content: center;
  align-items: center;
  padding: 10px;
}

.modal-content {
  background: #fff;
  border-radius: 12px;
  width: 95%;
  max-width: 600px;
  max-height: 90vh;
  overflow-y: auto; 
  position: relative;
  padding: 50px 20px 20px 20px; 
  box-shadow: 0 4px 15px rgba(0,0,0,0.1);
}

.modal-content h2 {
  margin-top: 0;
  margin-bottom: 15px;
  font-size: 1.8rem;
  text-align: center;
}

.modal-text p,
.modal-text ul,
.modal-text div {
  margin-bottom: 1em;
  font-size: 1rem;
  line-height: 1.5;
}

.modal-text ul {
  padding-left: 20px;
}

.close {
  position: absolute;
  top: 10px; 
  right: 15px;
  font-size: 24px;
  font-weight: bold;
  color: #333;
  cursor: pointer;
  z-index: 100;
  background: #fff;
  border-radius: 50%;
  width: 35px;
  height: 35px;
  text-align: center;
  line-height: 35px;
}

.close:hover {
  color: #ff0000;
  background: #f0f0f0;
}

strong, b {
  font-weight: bold; 
}

/* ---------- ADAPTIVE ---------- */
@media (max-width: 1024px) {
  .usluga { width: 200px; }
  .usluga img { height: 140px; }
  .modal-content h2 { font-size: 1.6rem; }
  .modal-text p, .modal-text ul, .modal-text div { font-size: 0.95rem; }
}

@media (max-width: 767px) {
  .uslugi-scroll { flex-direction: column; align-items: center; }
  .usluga { width: 90%; max-width: 300px; }
  .usluga img { height: 180px; }
  .modal-content { width: 95%; padding: 15px; }
  .modal-content h2 { font-size: 1.4rem; }
  .modal-text p, .modal-text ul, .modal-text div { font-size: 0.9rem; }
  .modal-text ul { padding-left: 18px; }
}

@media (max-width: 480px) {
  .modal-content {
    padding: 50px 10px 10px 10px;
  }

  .close {
    width: 30px;
    height: 30px;
    line-height: 30px;
    font-size: 20px;
  }

  .modal-text p,
  .modal-text ul,
  .modal-text div {
    font-size: 0.8rem;
  }
}

@media (max-width: 360px) {
  .modal-content h2 { font-size: 1.1rem; }
  .modal-text p, .modal-text ul, .modal-text div { font-size: 0.75rem; }
  .close { font-size: 20px; }
}

/* ---------- MODAL ---------- */
.modal {
  display: none;
  position: fixed;
  z-index: 1000;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background-color: rgba(0, 0, 0, 0.5);
  justify-content: center;
  align-items: center;
}

.modal-content {
  background: #fff;
  padding: 20px;
  border-radius: 12px;
  max-width: 600px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.1);
  position: relative;
  text-align: left;
}

.close {
  position: absolute;
  top: 10px;
  right: 15px;
  font-size: 24px;
  font-weight: bold;
  color: #333;
  cursor: pointer;
}

.close:hover {
  color: #ff0000;
}

strong, b {
  font-weight: bold; 
}

body.modal-open #page-content {
  filter: blur(5px);   /* сам блюр */
  pointer-events: none; 
  user-select: none; 
}
