body {
  background-color: var(--page-bg);
}

header {
  background-color: var(--main-white);
  box-shadow: none;
  transition: box-shadow 0.25s ease;
  left: 0;
  position: fixed;
  right: 0;
  top: 0;
  width: 100%;
  z-index: 10;
}

header.scrolled {
  box-shadow: var(--shadow-soft);
}

.header-main-container {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.header-svg svg {
  padding: 1vh 1vw;
  width: auto;
  height: clamp(48px, 10vh, 72px);
}

.header-burger-menu {
  display: none;
}

.header-sections {
  width: 65%;
  margin-right: 1rem;
  font-size: var(--font-size-body);
}

.header-sections nav ul {
  padding: 0;
  margin: 0;
  list-style-type: none;
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.header-sections a {
  color: var(--text-primary);
  text-decoration: none;
  position: relative;
}

.header-sections svg {
  width: 1.25rem;
}

.header-sections nav ul li a:hover {
  color: var(--main-color);
}

.header-sections nav ul li a:hover svg g {
  stroke: var(--main-color);
}

.header-sections nav ul li a::after {
  content: "";
  position: absolute;
  left: 0;
  bottom: -2px;
  width: 100%;
  height: 2px;
  border-radius: 20px;
  background-color: var(--main-color);
  transform: scaleX(0);
  transition: transform 0.25s ease;
}

.header-sections nav ul li a:hover::after {
  transform: scaleX(1);
}

.language-selector {
  position: relative;
  display: inline-block;
}

.icon-link {
  display: block;
  cursor: pointer;
}

.dropdown-menu {
  font-size: var(--font-size-body);
  max-height: 0;
  overflow: hidden;
  opacity: 0;
  transition: max-height 0.3s ease-out, opacity 0.2s ease-out;
  position: absolute;
  top: 100%;
  right: -80%;
  background-color: var(--main-white);
  box-shadow: var(--shadow-soft);
  border-radius: var(--radius);
  z-index: 1;
}

.dropdown-menu a {
  text-align: right;
  color: var(--text-primary);
  padding: 0.75rem 1rem;
  text-decoration: none;
  display: block;
}

.language-selector:hover .dropdown-menu {
  max-height: 200px;
  opacity: 1;
}

.dropdown-menu a.no-underline::after {
  content: none;
}

.selected-language {
  display: none;
}

.main-container {
  margin-top: clamp(60px, 12vh, 90px);
}

.footer-container {
  position: relative;
  border-top: 1px solid var(--main-muted);
  display: grid;
  grid-template-columns: 1fr 1fr 1fr;
  gap: var(--space-block);
  background-color: var(--page-bg);
  padding: clamp(1rem, 2.5vw, 1.75rem) clamp(1rem, 4vw, 3rem);
}

.footer-logo {
  display: flex;
  align-items: center;
}

.footer-logo svg {
  height: auto;
  width: clamp(80px, 10vw, 140px);
}

.footer-nav ul {
  list-style: none;
  padding: 0;
  margin: 0;
}

.footer-nav li {
  margin: 0.35rem 0;
}

.footer-nav a {
  color: var(--text-primary);
  text-decoration: none;
  font-size: var(--font-size-body);
}

.footer-nav a:hover {
  color: var(--main-color);
}

.footer-contacts {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  gap: 0.6rem;
}

.footer-contacts a {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  color: var(--text-primary);
  text-decoration: none;
  font-size: var(--font-size-body);
  min-width: 0;
}

.footer-contacts a:hover {
  color: var(--main-color);
}

.footer-contacts img {
  width: 1.25rem;
  height: 1.25rem;
  object-fit: contain;
}

.drop-container {
  position: relative;
  width: clamp(32px, 2vw, 40px);
  bottom: 2vh;
  left: 90%;
  padding: 0.5rem;
  background-color: var(--main-white);
  border-radius: 50%;
  box-shadow: var(--shadow-soft);
}

.drop-container img {
  width: 100%;
}

.drop-container span {
  position: absolute;
  top: 50%;
  right: 100%;
  transform: translateY(-50%);
  margin-right: 0.5rem;
  color: var(--text-primary);
  font-size: var(--font-size-body);
  background-color: var(--main-white);
  border-radius: var(--radius);
  padding: 0.35rem 0.75rem;
  white-space: nowrap;
  box-shadow: var(--shadow-soft);
}

.contacts {
  display: flex;
  justify-content: center;
  align-items: center;
  flex-wrap: wrap;
  gap: 1.5rem;
  padding: 1rem 0;
}

.contact-item a {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  text-decoration: none;
  color: var(--text-primary);
  gap: 0.35rem;
}

.contact-item img {
  width: 2rem;
  height: 2rem;
  object-fit: contain;
}

.contact-item-viber {
  background-color: #7452FE;
  padding: 0.2rem;
  border-radius: 30%;
}

.contact-item span {
  font-size: var(--font-size-body);
}

.contact-item:hover a {
  color: var(--main-color);
}

.count-oil-container {
  width: clamp(180px, 20vw, 240px);
}

.count-oil-container .text {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: var(--font-size-body);
  font-weight: 500;
}

.count-oil-container .text p {
  margin: 0;
}

.button-oil-container {
  display: flex;
  align-items: center;
  justify-content: center;
}

.button-oil {
  background-color: var(--main-white);
  border: 0;
  outline: 0;
  color: var(--text-primary);
  width: 200px;
  padding: 20px;
  border-radius: 8px;
  position: relative;
  overflow: hidden;
  cursor: pointer;
  box-shadow: var(--shadow-soft);
}

.liquid-oil {
  background-color: #e8c00a;
  width: 200px;
  height: 70px;
  position: absolute;
  bottom: 0;
  left: 0;
  box-shadow: inset 5px -5px 25px #d4b008, inset -5px 0 25px #e8c00a;
}

.liquid-oil::after {
  content: '';
  width: 450px;
  height: 400px;
  background: var(--main-white);
  z-index: 1;
  position: absolute;
  left: -110px;
  top: -380px;
  border-radius: 45%;
  animation: animate 5s linear 2s infinite;
}

.liquid-oil::before {
  content: '';
  width: 450px;
  height: 400px;
  background-color: #e8c00a;
  z-index: 1;
  position: absolute;
  left: -110px;
  top: -380px;
  border-radius: 40%;
  animation: animate 5s linear 1.8s infinite;
}

.btn-txt-oil {
  position: relative;
  z-index: 1;
  font-size: 1rem;
  font-family: 'Montserrat', sans-serif;
  letter-spacing: 0.5px;
  font-weight: 600;
}

@keyframes animate {
  from { transform: rotate(0deg); }
  to { transform: rotate(360deg); }
}

@media (max-width: 1024px) {
  .footer-container {
    grid-template-columns: 1fr 1fr;
  }
}

@media (max-width: 768px) {
  .language-selector {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 100%;
  }

  .language-icon {
    display: flex;
    align-items: center;
    cursor: pointer;
  }

  .selected-language {
    font-size: clamp(0.9rem, 4vw, 1.1rem);
    margin-left: 0.5rem;
    color: var(--text-primary);
    display: block;
  }

  .language-selector svg {
    width: 1.5rem;
    height: auto;
  }

  .dropdown-menu {
    font-size: var(--font-size-body);
    left: 0;
    right: 0;
    width: 100%;
    background-color: var(--page-bg);
  }

  .language-selector:hover .dropdown-menu {
    max-height: 0;
  }

  .language-selector.active .dropdown-menu {
    max-height: 50vh;
    opacity: 1;
  }

  .dropdown-menu a {
    padding: 0.75rem 1rem;
  }

  .header-sections {
    margin-top: clamp(60px, 12vh, 80px);
    padding-top: 2rem;
    display: block;
    position: fixed;
    top: 0;
    right: -100%;
    background-color: var(--page-bg);
    width: 100%;
    height: 100vh;
    transition: right 0.3s ease-in-out;
    z-index: 99;
    overflow-y: auto;
    margin-right: 0;
  }

  .header-sections.active {
    right: 0;
  }

  .header-burger-menu {
    display: block;
    padding-right: 1rem;
  }

  .header-burger-menu svg {
    width: 2rem;
    height: 2rem;
  }

  .header-sections nav ul {
    margin: 0 auto;
    padding: 2rem 0;
    list-style-type: none;
    width: fit-content;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .header-sections nav ul li {
    margin: 1rem 0;
  }

  .header-sections nav ul li a {
    font-size: clamp(1rem, 5vw, 1.25rem);
  }

  .hamburger {
    cursor: pointer;
  }

  .hamburger input {
    display: none;
  }

  .hamburger svg {
    height: 3em;
    transition: transform 600ms cubic-bezier(0.4, 0, 0.2, 1);
  }

  .line {
    fill: none;
    stroke: var(--text-primary);
    stroke-linecap: round;
    stroke-linejoin: round;
    stroke-width: 3;
    transition: stroke-dasharray 600ms cubic-bezier(0.4, 0, 0.2, 1), stroke-dashoffset 600ms cubic-bezier(0.4, 0, 0.2, 1);
  }

  .line-top-bottom {
    stroke-dasharray: 12 63;
  }

  .hamburger input:checked + svg {
    transform: rotate(-45deg);
  }

  .hamburger input:checked + svg .line-top-bottom {
    stroke-dasharray: 20 300;
    stroke-dashoffset: -32.42;
  }

  .footer-container {
    grid-template-columns: 1fr;
    text-align: center;
  }

  .footer-logo {
    justify-content: center;
  }

  .footer-nav ul {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 0 1.25rem;
  }

  .footer-contacts {
    align-items: center;
    justify-content: center;
  }

  .contacts {
    justify-content: center;
  }

  .contact-item img {
    width: 2rem;
    height: 2rem;
  }

  .drop-container {
    width: 44px;
    left: 80%;
  }

  .count-oil-container {
    width: auto;
    display: flex;
    flex-direction: column;
    align-items: center;
  }

  .count-oil-container .text {
    font-size: clamp(0.75rem, 2.5vw, 0.9rem);
    width: auto;
  }

  .button-oil {
    width: 100px;
    padding: 10px;
  }

  .liquid-oil {
    width: 100px;
    height: 35px;
  }

  .liquid-oil::after {
    width: 190px;
    height: 180px;
    left: -45px;
    top: -160px;
  }

  .liquid-oil::before {
    width: 190px;
    height: 180px;
    left: -45px;
    top: -160px;
  }

  .btn-txt-oil {
    font-size: 0.875rem;
  }

}

@media (max-width: 480px) {
  .footer-container {
    padding: clamp(0.75rem, 2vw, 1.25rem) 1rem;
  }
}
