
/* === ABOUT === */
.about-flex {
  display: flex;
  align-items: center;
  gap: 2.5rem;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}
.about-img {
  display: block;
  width: 400px;
  height: 600px;
  object-fit: cover;
  border-radius: 20px;
  box-shadow: 0 6px 30px rgba(56, 142, 60, 0.12);
  border: 4px solid #e0e0e0;
  background: #f9fcf9;
}
.about-text {
  flex: 1;
}



/* === VARIABLES === */
:root {
  --color-primary: #388e3c;
  --color-primary-dark: #1b3a1a;
  --color-accent: #ffd448;
  --color-bg-light: #f9fcf9;
  --color-text-dark: #222222;
  --color-text-light: #555;
  --container-max-width: 1200px;
  --border-radius: 12px;
  --transition-speed: 0.25s;
  --font-family: 'Segoe UI', Tahoma, Geneva, Verdana, sans-serif;
}


/* === GLOBAL RESETS === */
*, *::before, *::after {
  box-sizing: border-box;
}

html {
  scroll-behavior: smooth;
  font-size: 16px;
  line-height: 1.5;
  -webkit-font-smoothing: antialiased;
  -moz-osx-font-smoothing: grayscale;
}

body {
  margin: 0;
  font-family: var(--font-family);
  background-color: var(--color-bg-light);
  color: var(--color-text-dark);
  min-height: 100vh;
}


/* === LAYOUT === */
.container {
  width: 90%;
  max-width: var(--container-max-width);
  margin: 0 auto;
  padding-left: 15px;
  padding-right: 15px;
}


/* === HEADER === */
header {
  background-color: var(--color-primary-dark);
  padding: 1rem 0;
  box-shadow: 0 3px 8px rgba(0, 0, 0, 0.15);
  position: sticky;
  top: 0;
  z-index: 1000;
}
header .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  position: relative;
}
header h1 {
  color: var(--color-bg-light);
  font-weight: 700;
  font-size: 1.8rem;
  margin: 0;
  letter-spacing: 0.05em;
  user-select: none;
}
.nav-list {
  list-style: none;
  display: flex;
  gap: 1.8rem;
  margin: 0;
  padding: 0;
}
.nav-list a {
  color: var(--color-bg-light);
  text-decoration: none;
  font-weight: 600;
  font-size: 1rem;
  padding: 0.5rem 0;
  border-bottom: 3px solid transparent;
  transition: border-color var(--transition-speed), color var(--transition-speed);
}
.nav-list a:hover,
.nav-list a:focus {
  color: #fff;
  border-bottom-color: var(--color-accent);
  outline: none;
}


/* === HERO === */
.hero {
  position: relative;
  padding: 5rem 0 4rem;
  text-align: center;
  color: #fff;
  overflow: hidden;
}
.hero-bg {
  position: absolute;
  inset: 0;
  z-index: 0;
  width: 100%;
  height: 100%;
  overflow: hidden;
}
.hero-bg img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  filter: blur(8px) brightness(0.7);
  opacity: 0.85;
  display: block;
}
.hero-bg::after {
  content: "";
  position: absolute;
  inset: 0;
  background: linear-gradient(135deg, rgba(56,142,60,0.55), rgba(27,58,26,0.45));
  z-index: 1;
  pointer-events: none;
}
.hero .container {
  position: relative;
  z-index: 2;
}
.hero h2 {
  color: #fff;
  text-shadow: 0 2px 12px rgba(27,58,26,0.25);
}
.hero p {
  color: #e0ffe0;
  text-shadow: 0 1px 8px rgba(27,58,26,0.18);
}

.btn {
  display: inline-block;
  background-color: var(--color-primary);
  color: #fff;
  padding: 0.85rem 2.5rem;
  font-weight: 700;
  font-size: 1.1rem;
  border-radius: 40px;
  border: none;
  cursor: pointer;
  box-shadow: 0 5px 15px rgba(56, 142, 60, 0.35);
  transition: background-color var(--transition-speed), box-shadow var(--transition-speed), transform var(--transition-speed);
  text-decoration: none;
  user-select: none;
}


/* === SECTION === */
section {
  padding: 4rem 0 3rem;
}
section h2 {
  text-align: center;
  color: var(--color-primary);
  font-weight: 700;
  font-size: 2.25rem;
  margin-bottom: 2rem;
  position: relative;
  display: inline-block;
  padding-bottom: 0.6rem;
}
section h2::after {
  content: "";
  display: block;
  width: 40%;
  height: 4px;
  background: var(--color-accent);
  border-radius: 3px;
  margin: 0.5rem auto 0;
}


/* === SERVICES === */
.services-list {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  justify-content: center;
}
.service {
  background-color: #fff;
  border-radius: var(--border-radius);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.07);
  padding: 2rem 1.5rem 1.5rem 1.5rem;
  flex: 1 1 280px;
  max-width: 320px;
  cursor: default;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.7rem;
  transition: box-shadow 0.25s ease, transform 0.25s ease;
}

.service-img {
  display: block;
  width: 100%;
  max-width: 240px;
  height: 240px;
  object-fit: cover;
  border-radius: 16px;
  margin: 0 0 0.7rem 0;
  box-shadow: 0 2px 8px rgba(56,142,60,0.10);
  background: #f9fcf9;
  border: 2px solid #e0e0e0;
}

.service:hover,
.service:focus-within {
  box-shadow: 0 12px 35px rgba(56, 142, 60, 0.3);
  transform: translateY(-6px);
  outline: none;
}

.service h3 {
  color: var(--color-primary);
  font-size: 1.3rem;
  margin-bottom: 1rem;
  font-weight: 700;
  background-color: var(--color-accent);
  padding: 0.4rem 1rem;
  border-radius: 8px;
  display: inline-block;
  user-select: none;
}

.service p {
  color: var(--color-text-light);
  font-size: 1rem;
  line-height: 1.4;
}


/* === DISTRICTS === */
.districts-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
  gap: 2rem;
}
.district-card {
  background-color: #fff;
  border-radius: var(--border-radius);
  box-shadow: 0 3px 14px rgba(0, 0, 0, 0.06);
  padding: 1.8rem 1.4rem;
  display: flex;
  flex-direction: column;
  gap: 0.7rem;
  transition: box-shadow 0.25s ease, transform 0.25s ease;
}

.district-card:hover,
.district-card:focus-within {
  box-shadow: 0 12px 35px rgba(56, 142, 60, 0.3);
  transform: translateY(-6px);
  outline: none;
}

.district-card h3 {
  font-size: 1.15rem;
  color: var(--color-primary);
  margin: 0;
  background-color: var(--color-accent);
  border-radius: 6px;
  padding: 0.25rem 1rem;
  user-select: none;
}

.district-card p {
  font-size: 1rem;
  color: var(--color-text-light);
  margin: 0;
}


/* === ADVANTAGES === */
.advantages-list {
  display: flex;
  flex-wrap: wrap;
  gap: 2rem;
  justify-content: center;
  margin-top: 1rem;
}
.advantage {
  background-color: #fff;
  border-radius: var(--border-radius);
  box-shadow: 0 3px 12px rgba(0, 0, 0, 0.06);
  padding: 1.8rem 1.4rem;
  flex: 1 1 280px;
  max-width: 320px;
  color: var(--color-primary-dark);
  font-size: 1.05rem;
  line-height: 1.4;
  cursor: default;
  transition: box-shadow 0.25s ease, transform 0.25s ease;
}

.advantage:hover,
.advantage:focus-within {
  box-shadow: 0 12px 35px rgba(56, 142, 60, 0.3);
  transform: translateY(-6px);
  outline: none;
}

.advantage strong {
  color: var(--color-primary);
  background-color: var(--color-accent);
  border-radius: 6px;
  padding: 0.25rem 0.75rem;
  user-select: none;
}


/* === ABOUT SECTION === */
#about .container {
  background-color: #fff;
  border-radius: 20px;
  box-shadow: 0 6px 30px rgba(56,142,60,0.12);
  padding: 3rem 2.5rem;
  margin-top: 2rem;
  max-width: 900px;
  margin-left: auto;
  margin-right: auto;
}
#about p {
  font-size: 1.15rem;
  color: var(--color-primary-dark);
  line-height: 1.6;
  font-weight: 500;
  user-select: text;
}



/* === CONTACT FORM === */
#contact .container {
  background-color: #fff;
  max-width: 600px;
  padding: 3rem 2.5rem;
  border-radius: 20px;
  box-shadow: 0 6px 30px rgba(56,142,60,0.12);
  margin: 0 auto 3rem;
}

#contact h2 {
  color: var(--color-primary);
  font-weight: 700;
  font-size: 2rem;
  text-align: center;
  margin-bottom: 2rem;
  user-select: none;
  display: block;
}

#contact form {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

#contact label {
  font-weight: 600;
  color: var(--color-text-dark);
  font-size: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
  user-select: none;
}

#contact input,
#contact textarea {
  font-family: var(--font-family);
  font-size: 1rem;
  padding: 0.75rem 1rem;
  border: 2px solid #c8e6c9;
  border-radius: 10px;
  background-color: var(--color-bg-light);
  color: var(--color-text-dark);
  transition: border-color var(--transition-speed), box-shadow var(--transition-speed);
  resize: vertical;
  min-height: 40px;
  outline-offset: 3px;
}

#contact textarea {
  min-height: 100px;
}

#contact input:focus,
#contact textarea:focus {
  border-color: var(--color-primary);
  box-shadow: 0 0 6px 2px rgba(56, 142, 60, 0.5);
  outline: none;
}

#contact button.btn {
  display: inline-block;
  background-color: var(--color-primary);
  color: #fff;
  padding: 0.85rem 2.5rem;
  font-weight: 700;
  font-size: 1.1rem;
  border-radius: 40px;
  border: none;
  cursor: pointer;
  box-shadow: 0 5px 15px rgba(56, 142, 60, 0.35);
  transition: background-color var(--transition-speed), box-shadow var(--transition-speed), transform var(--transition-speed);
  text-decoration: none;
  user-select: none;
}

#contact button.btn:hover,
#contact button.btn:focus {
  background-color: var(--color-primary-dark);
  box-shadow: 0 8px 25px rgba(27, 58, 26, 0.45);
  transform: translateY(-3px);
  outline: none;
}

/* Счётчики символов */
#contact span[id$="Count"] {
  font-size: 0.9rem;
  color: var(--color-primary);
  align-self: flex-end;
  user-select: none;
}

/* Контактный телефон */
.contact-phone {
  margin-top: 2rem;
  text-align: center;
  font-weight: 700;
  color: var(--color-primary-dark);
  font-size: 1.1rem;
}

.contact-phone a {
  color: var(--color-primary);
  text-decoration: none;
  transition: color var(--transition-speed);
}

.contact-phone a:hover,
.contact-phone a:focus {
  color: var(--color-primary-dark);
  text-decoration: underline;
  outline: none;
}


/* === FOOTER === */
footer {
  background-color: var(--color-primary-dark);
  color: var(--color-bg-light);
  padding: 3rem 0 2rem;
  user-select: none;
}
.footer-content.container {
  display: flex;
  flex-wrap: wrap;
  gap: 3rem;
  justify-content: space-between;
  max-width: var(--container-max-width);
}

.footer-contacts,
.footer-info {
  flex: 1 1 320px;
  min-width: 280px;
}

.footer-contacts h3,
.footer-info h3 {
  font-size: 1.3rem;
  font-weight: 700;
  margin-bottom: 1rem;
  color: var(--color-bg-light);
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.3);
  user-select: none;
}

.contacts-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

.contact-item {
  display: flex;
  align-items: center;
  gap: 1rem;
  font-size: 1.05rem;
  user-select: text;
}

.contact-label {
  min-width: 110px;
  font-weight: 600;
  color: var(--color-bg-light);
  user-select: none;
}

.contact-item a {
  color: var(--color-bg-light);
  text-decoration: none;
  transition: color var(--transition-speed);
}

.contact-item a:hover,
.contact-item a:focus {
  color: #fff;
  text-decoration: underline;
  outline: none;
}

/* Нижняя часть футера */
.footer-bottom {
  text-align: center;
  font-size: 1rem;
  margin-top: 2rem;
  opacity: 0.85;
  user-select: none;
}


/* === MEDIA QUERIES === */
@media (max-width: 900px) {
  .about-flex {
    flex-direction: column;
    gap: 1.2rem;
    padding: 2rem 1rem;
  }
  .about-img {
    width: 140px;
    height: 140px;
    border-radius: 14px;
    margin-bottom: 0.8rem;
  }
  .advantages-list {
    flex-direction: column;
    align-items: flex-start;
    gap: 1.5rem;
  }
  .advantage {
    display: inline-block;
    width: auto;
    min-width: 0;
    max-width: 95vw;
    padding: 1rem 0.7rem;
    font-size: 0.97rem;
    box-sizing: border-box;
    flex: none;
    margin-left: auto;
    margin-right: auto;
    text-align: left;
    vertical-align: top;
  }
  .footer-content.container {
    flex-direction: column;
    gap: 2rem;
  }
  .nav-list {
    gap: 1rem;
  }
  .services-list,
  .advantages-list {
    flex-direction: column;
    gap: 1.5rem;
  }
  .districts-list {
    grid-template-columns: 1fr;
    gap: 1.5rem;
  }
  .service-img {
    max-width: 160px;
    height: 110px;
    margin-bottom: 0.5rem;
  }
  .service {
    padding: 1.2rem 1rem 1rem 1rem;
    gap: 0.5rem;
  }
}
@media (max-width: 600px) {
  header h1 {
    font-size: 1.5rem;
  }
  .hero h2 {
    font-size: 2rem;
  }
  section h2 {
    font-size: 1.75rem;
  }
  #contact .container {
    padding: 2rem 1.5rem;
  }
  #contact h2 {
    font-size: 1.5rem;
  }
  .contact-item {
    font-size: 0.95rem;
    word-break: break-word;
    flex-direction: column;
    align-items: flex-start;
    gap: 0.2rem;
  }
  .contact-label {
    margin-bottom: 2px;
    font-size: 1em;
    display: block;
  }
  .contact-item a, .contact-item span {
    font-size: 1em;
    display: block;
    max-width: 100%;
    overflow-wrap: break-word;
    word-break: break-word;
  }
  .site-logo {
    width: 36px;
    height: 36px;
    margin-right: 0.5rem;
  }
  .logo-title {
    gap: 0.5rem;
  }
}




/* === TOASTS === */
.custom-toast {
  position: fixed;
  left: 50%;
  top: 30px;
  transform: translateX(-50%);
  background: #fff;
  color: #222;
  border-radius: 8px;
  box-shadow: 0 4px 16px rgba(56,142,60,0.18);
  padding: 1rem 2rem;
  font-weight: 600;
  font-size: 1.1rem;
  opacity: 0;
  pointer-events: none;
  z-index: 9999;
  transition: opacity 0.3s, top 0.3s;
}
.custom-toast.show {
  opacity: 1;
  top: 60px;
}
.custom-toast.error {
  background: #ffeaea;
  color: #b71c1c;
}
.custom-toast.success {
  background: #eaffea;
  color: #388e3c;
}

.site-logo {
  display: inline-block;
  vertical-align: middle;
  width: 48px;
  height: 48px;
  object-fit: contain;
  background: none;
  margin-right: 0.7rem;
}
.logo-title {
  display: flex;
  align-items: center;
  gap: 0.7rem;
}
@media (max-width: 600px) {
  .site-logo {
    width: 36px;
    height: 36px;
    margin-right: 0.5rem;
  }
  .logo-title {
    gap: 0.5rem;
  }
}

/* === BURGER MENU & MOBILE NAV === */
.burger-menu {
  display: none;
  flex-direction: column;
  justify-content: center;
  align-items: center;
  gap: 7px;
  width: 48px;
  height: 48px;
  cursor: pointer;
  position: absolute;
  right: 0;
  top: 50%;
  transform: translateY(-50%);
  background: transparent;
  border: none;
  box-shadow: none;
  z-index: 2002;
  padding: 0;
  transition: background 0.2s;
}
.burger-menu span {
  display: block;
  height: 4px;
  width: 32px;
  background-color: var(--color-bg-light);
  border-radius: 2px;
  transition: all 0.3s cubic-bezier(.4,1.7,.7,1.24);
  box-shadow: 0 1px 4px rgba(0,0,0,0.10);
}
.burger-menu.active span:nth-child(1) {
  transform: rotate(45deg) translateY(8px);
}
.burger-menu.active span:nth-child(2) {
  opacity: 0;
}
.burger-menu.active span:nth-child(3) {
  transform: rotate(-45deg) translateY(-8px);
}
.mobile-nav {
  position: fixed;
  top: 70px;
  right: 20px;
  background: var(--color-primary-dark);
  border-radius: 10px;
  overflow: hidden;
  display: none;
  flex-direction: column;
  box-shadow: 0 6px 20px rgba(0,0,0,0.25);
  z-index: 2001;
  min-width: 180px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.25s, top 0.25s;
}
.mobile-nav a {
  padding: 1rem 1.5rem;
  color: var(--color-bg-light);
  text-decoration: none;
  font-weight: 600;
  border-bottom: 1px solid rgba(255,255,255,0.1);
  transition: background 0.3s ease;
}
.mobile-nav a:hover {
  background: var(--color-primary);
}
.mobile-nav.show {
  display: flex;
  opacity: 1;
  pointer-events: auto;
}
@media (max-width: 900px) {
  nav .nav-list {
    display: none;
  }
  .burger-menu {
    display: flex;
    position: absolute;
    right: 0;
    top: 50%;
    transform: translateY(-50%);
  }
}
