/* Reset and base styles */
* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: Arial, sans-serif;
  line-height: 1.6;
  color: #333;
  background-color: #f9f9f9;
}

.container {
  max-width: 1200px;
  margin: 0 auto;
  padding: 0 20px;
}

h1, h2, h3 {
  font-family: 'Oswald', sans-serif;
  font-size: 2.5rem;
  color: #32CD32;
}

/* Header */
.header {
  background-color: #00008B;
  padding: 20px 0;
  position: fixed;
  width: 100%;
  top: 0;
  z-index: 1000;
}

.header__container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.header__contacts {
  display: flex;
  gap: 20px;
  align-items: center;
}

.header__contact {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #fff;
  text-decoration: none;
  font-size: 1rem;
  transition: color 0.3s;
  fill: #fff;
}

.header__contact:hover {
  color: #32CD32;
}

.header__button {
  background-color: #32CD32;
  color: #fff;
  padding: 10px 20px;
  border-radius: 5px;
  text-decoration: none;
  font-weight: bold;
  transition: background-color 0.3s;
}

.header__button:hover {
  background-color: #28a428;
}

/* Hero */
.hero {
  padding: 100px 0;
  text-align: center;
  background-color: #e6f0fa;
  margin-top: 80px;
}

/* Gallery */
.gallery {
  padding: 40px 0;
}

.gallery__wrapper {
  position: relative;
}

.gallery__grid {
  display: flex;
  overflow-x: auto;
  scroll-snap-type: x mandatory;
  gap: 20px;
  padding-bottom: 10px;
  scrollbar-width: none; /* Firefox */
}

.gallery__grid::-webkit-scrollbar {
  display: none; /* Chrome, Safari */
}

.gallery__card {
  flex: 0 0 300px;
  position: relative;
  overflow: hidden;
  border-radius: 10px;
  scroll-snap-align: start;
}

.gallery__card img {
  width: 600px;
  height: 400px;
  display: block;
  transition: transform 0.3s;
   object-fit: cover;      /* Картинка заполняет блок, обрезая лишнее */
  display: block;
}

.gallery__card:hover img {
  transform: scale(1.1);
}

.gallery__overlay {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transition: opacity 0.3s;
}

.gallery__card:hover .gallery__overlay {
  opacity: 1;
}

.gallery__button {
  background-color: #32CD32;
  color: #fff;
  border: none;
  padding: 10px 20px;
  border-radius: 5px;
  cursor: pointer;
  font-weight: bold;
  transition: background-color 0.3s;
}

.gallery__button:hover {
  background-color: #28a428;
}

.gallery__arrow {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  background-color: #00008B;
  color: #fff; /* Sets SVG fill to white */
  border: none;
  width: 40px;
  height: 40px;
  border-radius: 50%;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background-color 0.3s;
}

.gallery__arrow:hover {
  background-color: #32CD32;
}

.gallery__arrow-icon {
  width: 24px;
  height: 24px;
}

.gallery__arrow--left {
  left: -50px;
}

.gallery__arrow--right {
  right: -50px;
}

/* Modal */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  z-index: 1000;
  align-items: center;
  justify-content: center;
}

.modal--active {
  display: flex;
}

.modal__content {
  position: relative;
  max-width: 90%;
  max-height: 90%;
}

.modal__content img {
  max-width: 100%;
  max-height: 80vh;
  border-radius: 10px;
}

.modal__close {
  position: absolute;
  top: -30px;
  right: -30px;
  background: #32CD32;
  color: #fff;
  border: none;
  width: 30px;
  height: 30px;
  border-radius: 50%;
  cursor: pointer;
  font-size: 1.2rem;
}

/* Advantages */
.advantages {
  padding: 40px 0;
  background-color: #fff;
}

.advantages__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
  text-align: center;
}

.advantages__item {
  padding: 20px;
}

.advantages__item svg {
  margin-bottom: 10px;
}

.advantages__item h3 {
  font-size: 1.5rem;
 
}

/* Materials */
.materials {
  padding: 40px 0;
}

.materials__grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.materials__item {
  position: relative;
  text-align: center;
}

.materials__item img {
  width: 100%;
  height: auto;
  border-radius: 10px;
}

.materials__item h3 {
  position: absolute;
  top: 10px;
  left: 50%;
  transform: translateX(-50%);
  background: rgba(255, 255, 255, 0.8);
  padding: 5px 10px;
  border-radius: 5px;
  color: #00008b;
}

.materials__price {
  position: absolute;
  bottom: 10px;
  left: 10px;
  background: rgba(0, 0, 0, 0.7);
  color: #fff;
  padding: 5px 10px;
  border-radius: 5px;
}

/* Contact Form */
.contact-form {
  padding: 40px 0;
  background-color: #e6f0fa;
}

.contact-form__container {
  display: flex;
  gap: 40px;
}

.contact-form__form {
  flex: 1;
  border: 2px solid #00008B;
  border-radius: 10px;
  padding: 20px;
  background-color: #fff;
}

.contact-form__form h2{
	color: #00008B;
}

.contact-form__steps {
  flex: 1;
}

.steps__list {
  list-style: none;
}

.steps__item {
  background: #fff;
  padding: 20px;
  margin-bottom: 20px;
  border-radius: 10px;
  box-shadow: 0 2px 5px rgba(0, 0, 0, 0.1);
}

.steps__item h3 {
  font-size: 1.5rem;
  color: #00008B;
}

/* Form Styles */
.form-row {
  display: flex;
  gap: 20px;
}

.form-group {
  margin-bottom: 20px;
  flex: 1;
}

.form-control {
  width: 100%;
  padding: 10px;
  border: 1px solid #ccc;
  border-radius: 5px;
}

.form-attach__wrapper {
  border: 2px dashed #00008B;
  padding: 20px;
  text-align: center;
  border-radius: 5px;
}

.form-attach__wrapper.dragover {
  background-color: #e6f0fa;
}

.form-attach__items {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  margin-top: 10px;
}

.form-attach__item {
  position: relative;
  width: 100px;
  height: 100px;
}

.form-attach__item img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  border-radius: 5px;
}

.form-attach__item-remove {
  position: absolute;
  top: -10px;
  right: -10px;
  background: #32CD32;
  color: #fff;
  border: none;
  width: 20px;
  height: 20px;
  border-radius: 50%;
  cursor: pointer;
}

.form-captcha {
  display: flex;
  align-items: center;
  gap: 10px;
}

.form-submit button {
  background-color: #32CD32;
  color: #fff;
  padding: 10px 20px;
  border: none;
  border-radius: 5px;
  cursor: pointer;
  transition: background-color 0.3s;
}

.form-submit button:hover {
  background-color: #28a428;
}

.invalid-feedback {
  color: red;
  font-size: 0.8rem;
  display: none;
}

.agreement-modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
}

.agreement-modal .modal-content {
  background: #fff;
  padding: 30px;
  max-width: 800px;
  max-height: 80vh;
  overflow-y: auto;
  border-radius: 10px;
  box-shadow: 0 0 10px rgba(0, 0, 0, 0.3);
  color: #333;
}

.agreement-modal .modal-content h2 {
  margin-bottom: 20px;
  color: #00008B;
  font-size: 1.5rem;
}

.agreement-modal .modal-body {
  font-size: 1rem;
  line-height: 1.6;
  max-height: 60vh;
  overflow-y: auto;
}

.agreement-modal .close-modal {
  margin-top: 20px;
  text-align: right;
  color: #32CD32;
  cursor: pointer;
  font-weight: bold;
}


/* Footer */
.footer {
  background-color: #00008B;
  padding: 20px 0;
  color: #fff;
}

.footer__container {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.footer__contacts {
  display: flex;
  gap: 20px;
}

.footer__contact {
  display: flex;
  align-items: center;
  gap: 8px;
  color: #fff;
  text-decoration: none;
  transition: color 0.3s;
}

.footer__contact:hover {
  color: #32CD32;
}

.footer__contact svg{
	fill: #fff;
}

/* Responsive Design */
@media (max-width: 1024px) {
  .gallery__grid {
    flex: 0 0 200px;
  }

  .gallery__arrow--left {
    left: -40px;
  }

  .gallery__arrow--right {
    right: -40px;
  }

  .advantages__grid, .materials__grid {
    grid-template-columns: repeat(2, 1fr);
  }

  .contact-form__container {
    flex-direction: column;
  }
}

@media (max-width: 768px) {
  .header__container {
    flex-direction: column;
    gap: 20px;
  }

  .header__contacts {
    flex-direction: column;
    text-align: center;
  }

  .gallery__grid {
    flex: 0 0 150px;
  }

  .gallery__arrow--left {
    left: -30px;
  }

  .gallery__arrow--right {
    right: -30px;
  }

  .advantages__grid, .materials__grid {
    grid-template-columns: 1fr;
  }

  h1, h2, h3 {
    font-size: 2rem;
  }
  
   h1{
	   
	   display: block;
	   position: relative;
	   top: 90px;
   }
  
}

@media (max-width: 320px) {
  .container {
    padding: 0 10px;
  }

  .gallery__grid {
    flex: 0 0 100px;
  }

  .gallery__arrow--left {
    left: -15px;
  }

  .gallery__arrow--right {
    right: -15px;
  }

  h1, h2, h3 {
    font-size: 1.5rem;
  }

  .form-row {
    flex-direction: column;
  }
}