body {
  font-family: 'Roboto', sans-serif;
  margin: 0;
  padding: 0;
  background-color: #f0f0f0;
  color: #333;
}

.container {
  width: 100%;
  max-width: 1200px;
  margin: 0 auto;
  padding: 20px;
  box-sizing: border-box;
}

.header {
  background-color: #f2f2f2;
  padding: 10px 0;
}

.popup_n h2 {
  font-weight: bold;
}

.header-content {
  display: flex;
  justify-content: space-between;
  align-items: center;
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
  box-sizing: border-box;
}

.header-logo {
  font-size: 24px;
  font-weight: bold;
  display: flex;
  align-items: center;
}

.header-logo img {
  width: 30px;
  height: 30px;
  margin-right: 10px;
}

.main-content {
  background-image: url('/static/img/mashina.png');
  background-size: cover;
  background-position: center;
  padding: 50px 0;
  text-align: center;
  color: white;
  display: flex;
  flex-direction: column;
  justify-content: center;
  align-items: center;
}

.main-text {
  max-width: 700px;
  margin-bottom: 20px;
  background-color: rgba(128, 128, 128, 0.6);
  padding: 20px;
  border-radius: 10px;
}

.main-content h1 {
  font-size: 3em;
  margin-bottom: 0.5em;
  font-weight: bold;
}

.main-content p {
  font-size: 1.5em;
}

.services {
  background-color: #e0f2f7;
  padding: 50px 0;
  text-align: center;
}

.services-text {
  margin-bottom: 20px;
  text-align: center;
  font-size: 1.4em;
}

.services-container {
  display: flex;
  justify-content: center;
  gap: 20px;
  flex-wrap: wrap;
  max-width: 1000px;
  margin: 0 auto;
}

.service-card {
  background-color: white;
  padding: 20px;
  border-radius: 10px;
  text-align: center;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
  width: 250px;
  box-sizing: border-box;
  margin: 10px;
}

.service-card img {
  width: 50px;
  height: 50px;
  margin: 0 auto 10px;
}

.service-card h3 {
  margin-bottom: 5px;
}

.service-card .feature {
  background-color: white;
  border: 1px solid #797e80;
  padding: 10px 15px;
  border-radius: 5px;
  cursor: pointer;
  display: block;
  margin: 10px auto 0;
  color: black;
  transition: background-color 0.3s ease, color 0.3s ease;
}

.service-card .feature:hover {
  background-color: #797e80;
  color: white;
}

.popup {
  position: fixed;
  top: 50%;
  left: 50%;
  width: auto;
  height: auto;
  background-color: #ffffff;
  z-index: 1000;
  overflow-y: auto;
  display: none;
  justify-content: center;
  align-items: center;
  max-width: 450px;
  border-radius: 10px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
  padding: 30px;
  box-sizing: border-box;
  overflow-x: auto;
  transform: translate(-50%, -50%);
}

.popup_n {
  display: none;
  position: fixed;
  top: 50%;
  left: 50%;
  width: auto;
  height: auto;
  background-color: #ffffff;
  z-index: 1000;
  overflow-y: auto;
  justify-content: center;
  max-width: 500px;
  border-radius: 10px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2);
  padding: 30px;
  box-sizing: border-box;
  overflow-x: auto;
  transform: translate(-50%, -50%);
  align-items: flex-start;
}


.popup .close-button, .popup_n .close-button_n {
  position: absolute;
  top: 10px;
  right: 20px;
  font-size: 2em;
  cursor: pointer;
  color: black;
}

.popup_n .close-button_n {
  color: black;
}

.popup .back-button {
  position: absolute;
  top: 10px;
  left: 20px;
  font-size: 2em;
  cursor: pointer;
}

.popup .close-button, .popup_n .close-button_n {
  color: black;
}

.popup > *, .popup_n > * {
  margin-left: auto;
  margin-right: auto;
  max-width: 100%;
  box-sizing: border-box;
}

.popup table, .popup_n table {
  width: auto;
  border-collapse: collapse;
  margin: 20px auto;
  max-width: 100%;
  box-sizing: border-box;
}

.popup table td, .popup table th, .popup_n table td, .popup_n table th {
  border: 1px solid #ddd;
  padding: 8px;
  text-align: center;
  box-sizing: border-box;
}

.popup table th, .popup_n table th {
  background-color: #f2f2f2;
  box-sizing: border-box;
}

.popup > table > tr > td > button {
  background-color: white;
  border: 1px solid #797e80;
  padding: 10px 15px;
  border-radius: 5px;
  cursor: pointer;
  display: block;
  margin: 0 auto;
  color: black;
  transition: background-color 0.3s ease, color 0.3s ease;
  box-sizing: border-box;
}

.popup > table > tr > td > button:hover {
  background-color: #797e80;
  color: white;
}

.popup button, .popup_n button {
  padding: 10px 15px;
  margin: 5px;
  cursor: pointer;
  background-color: white;
  border: 1px solid #797e80;
  color: black;
  border-radius: 5px;
  transition: background-color 0.3s ease, color 0.3s ease;
  box-sizing: border-box;
}

.popup button:hover, .popup_n button:hover {
  background-color: #797e80;
  color: white;
}

.popup > h2, .popup_n h1 {
  text-align: center;
  box-sizing: border-box;
}

.popup input, .popup_n input {
  padding: 10px;
  margin: 10px;
  border: 1px solid #ddd;
  box-sizing: border-box;
}

.modal {
  display: none;
  position: fixed;
  z-index: 1001;
  left: 0;
  top: 0;
  width: 100%;
  height: 100%;
  overflow: auto;
  background-color: rgba(0, 0, 0, 0.5);
}

.modal-content {
  background-color: #fefefe;
  margin: 15% auto;
  padding: 20px;
  border: 1px solid #888;
  width: 80%;
  max-width: 600px;
  position: relative;
  box-shadow: 0 4px 8px 0 rgba(0, 0, 0, 0.2), 0 6px 20px 0 rgba(0, 0, 0, 0.19);
}

.close-modal {
  color: #aaa;
  float: right;
  font-size: 28px;
  font-weight: bold;
  cursor: pointer;
}

.modal-body {
  padding: 20px;
}

.about {
  padding: 30px 0;
  text-align: center;
}

.contact {
  padding: 30px 0;
  background-color: #e0f2f7; 
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2); 
  border-radius: 10px;
  margin-top: 20px;
}

#contactcontainer {
  text-align: center;
  padding: 20px;
}


#contactcontainer h2 {
  margin-bottom: 15px;
  color: #333;
}

#contactcontainer p {
  margin-bottom: 10px;
  font-size: 1.1em;
   color: #555;
}

#map {
  width: 100%;
  height: 300px;
  box-sizing: border-box;
  border-radius: 10px;
  margin-top: 20px; /* Добавляем отступ сверху для карты */
}

.footer {
  background-color: #333;
  color: white;
  padding: 20px 0;
  text-align: center;
}

@media (max-width: 768px) {
  .header-content {
      flex-direction: column;
      text-align: center;
  }

  .header-logo {
      margin-bottom: 10px;
      justify-content: center;
  }

  .services-container {
      flex-direction: column;
      align-items: center;
  }

  #map {
      height: 200px;
  }

  input[type="tel"] {
    padding: 10px;
    box-sizing: border-box;
    border-radius: 4px;
}
}

.table-scroll-wrapper {
  overflow: auto; 
  max-height: 500px;
}

table {
  border-collapse: collapse;
  width: 100%; 
}

th, td {
  border: 1px solid #ddd; 
  padding: 8px;
  text-align: left;
}

th {
  background-color: #f2f2f2; 
}

.button-container { 
  display: flex;
  flex-wrap: wrap; 
  justify-content: center; 
  width: 100%; 
  box-sizing: border-box;
}

.popup button {
  background-color: #797e80;
  color: white;
}
.popup table, .popup_n table {
  width: 100%;
  border-collapse: collapse;
  margin: 15px 0;
  box-sizing: border-box;
}

.popup table td, .popup table th, .popup_n table td, .popup_n table th {
  border: 1px solid #ddd;
  padding: 8px;
  box-sizing: border-box;
}

.popup table th, .popup_n table th {
  background-color: #f2f2f2;
}

.popup table td > button {
  display: block;
  margin: 5px auto;
}

.popup .back-button, .popup_n .back-button {
  position: absolute;
  top: 10px;
  left: 10px;
  cursor: pointer;
}
.popup .back-button i, .popup_n .back-button i {
  font-size: 0.5em; 
}