/* =========================================================
   WeLUX — Services & Directions (Figma pixel-perfect)
   ========================================================= */

/* Page backgrounds */
body.page-template-page-services,
body.page-template-page-directions,
body.tax-welux_direction,
body.tax-welux_task,
.page--services-tasks,
.page--services-directions,
.page--services,
.page--directions {
  background-color: #f0f0f0 !important;
}

body.page-template-page-services .main,
body.page-template-page-directions .main,
body.tax-welux_direction .main,
body.tax-welux_task .main {
  background-color: #f0f0f0 !important;
}

.srv,
.directions {
  width: 100%;
  background-color: #f0f0f0 !important;
  padding-block: 28px 80px;
}

/* Breadcrumbs */
.srv .breadcrumbs,
.directions .breadcrumbs {
  margin-bottom: 20px;
  font-size: 13px;
  color: #8a8a8a;
}
.srv .breadcrumbs a,
.directions .breadcrumbs a {
  color: #8a8a8a;
  text-decoration: none;
}
.srv .breadcrumbs a:hover,
.directions .breadcrumbs a:hover {
  color: #2d2d2d;
}

/* Page titles */
.srv__title,
.directions__title {
  font-family: var(--font-display, "Wix Madefor Display", sans-serif);
  font-weight: 500;
  font-size: clamp(36px, 4vw, 56px);
  line-height: 1.05;
  letter-spacing: -0.01em;
  color: #232323;
  margin-top: 0;
  margin-bottom: 24px;
}

/* Switch (По направлению / По задаче) */
.srv__switch,
.directions__switch {
  display: inline-flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 32px;
  font-size: 14px;
  color: #232323;
  user-select: none;
}

.srv__switch-label,
.directions__switch-label {
  background: none;
  border: 0;
  padding: 0;
  font-family: inherit;
  font-size: 14px;
  font-weight: 400;
  color: #232323;
  cursor: pointer;
  line-height: 1;
  text-decoration: none;
  transition: color 0.2s ease, font-weight 0.2s ease;
}

.srv__switch-label.is-active,
.directions__switch-label.is-active {
  font-weight: 500;
  color: #1a1a1a;
}

.toggle,
[data-catalog-switch] {
  padding: 0;
  background: none;
  border: 0;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  flex-shrink: 0;
  outline: none;
}

.toggle__track {
  width: 59px;
  height: 19px;
  background: rgba(157, 155, 122, 0.3) !important;
  border-radius: 999px;
  position: relative;
  display: inline-block;
  transition: background var(--tr);
}

.toggle__thumb {
  position: absolute;
  top: 1.5px;
  left: 2px;
  width: 16px;
  height: 16px;
  background: #565541 !important;
  border-radius: 50%;
  transition: transform 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

.toggle.is-on .toggle__thumb,
.toggle[aria-pressed="true"] .toggle__thumb {
  transform: translateX(39px) !important;
}

/* =========================================================
   ACCORDIONS (Services)
   ========================================================= */
.srv-acc {
  display: flex;
  flex-direction: column;
  gap: 10px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.srv-acc__item {
  background: transparent !important;
  border: none !important;
  border-radius: 20px;
  overflow: visible;
  list-style: none;
}

.srv-acc__head {
  width: 100%;
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 20px;
  background: #ffffff;
  border: none;
  border-radius: 20px;
  padding: 10px 24px 10px 14px;
  min-height: 80px;
  cursor: pointer;
  text-align: left;
  font: inherit;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
  transition: background 0.2s ease, box-shadow 0.2s ease;
}

.srv-acc__head:hover {
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.04);
}

.srv-acc__item.is-open > .srv-acc__head,
.srv-acc__head[aria-expanded="true"] {
  background: #f4f4e1 !important;
}

.srv-acc__icon {
  width: 59px;
  height: 59px;
  border-radius: 50%;
  background: transparent !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
}

.srv-acc__icon img,
.srv-acc__icon svg {
  width: 100% !important;
  height: 100% !important;
  object-fit: contain;
  display: block;
}

.srv-acc__name {
  font-family: var(--font-display, "Wix Madefor Display", sans-serif);
  font-size: 18px;
  font-weight: 500;
  color: #232323;
  line-height: 1.3;
}

.srv-acc__plus {
  width: 14px;
  height: 14px;
  position: relative;
  display: inline-block;
  font-size: 0;
  color: transparent;
  flex-shrink: 0;
  transition: transform 0.25s ease;
}

.srv-acc__plus::before,
.srv-acc__plus::after {
  content: "";
  position: absolute;
  background-color: #232323;
  border-radius: 1px;
}

.srv-acc__plus::before {
  top: 0;
  left: 6px;
  width: 2px;
  height: 14px;
}

.srv-acc__plus::after {
  top: 6px;
  left: 0;
  width: 14px;
  height: 2px;
}

.srv-acc__head[aria-expanded="true"] .srv-acc__plus,
.srv-acc__item.is-open > .srv-acc__head .srv-acc__plus {
  transform: rotate(45deg);
}

.srv-acc__body {
  padding: 14px 0 6px 0;
  background: transparent !important;
}

/* Tag list inside open accordion */
.tag-list {
  display: flex;
  flex-wrap: wrap;
  gap: 10px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.tag-list li {
  list-style: none;
}

.tag {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  background: #ffffff !important;
  border: none !important;
  border-radius: 12px;
  padding: 6px 10px 6px 16px;
  min-height: 38px;
  font-size: 13.5px;
  font-weight: 400;
  color: #232323 !important;
  text-decoration: none;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.tag:hover {
  opacity: 1;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.06);
  transform: translateY(-1px);
}

.tag__arrow {
  width: 19px;
  height: 19px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: transform 0.2s ease;
}

.tag__arrow svg {
  width: 19px;
  height: 19px;
  display: block;
}

.tag:hover .tag__arrow {
  transform: translate(1px, -1px);
}

/* =========================================================
   COMPLEXES SECTION (Inside open task)
   ========================================================= */
.complex__title {
  font-family: var(--font-display, inherit);
  font-size: 26px;
  font-weight: 500;
  color: #232323;
  margin: 28px 0 18px 0;
  line-height: 1.15;
}

.complex-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 18px;
  margin-bottom: 24px;
}

.complex-card {
  display: flex;
  flex-direction: column;
  background: transparent !important;
  gap: 12px;
}

.complex-card__media {
  width: 100%;
  aspect-ratio: 1.35 / 1;
  border-radius: 14px;
  overflow: hidden;
  background: #e0e0e0;
}

.complex-card__media img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  display: block;
}

.complex-card__title {
  font-family: var(--font-display, inherit);
  font-size: 17px;
  font-weight: 600;
  color: #1a1a1a;
  line-height: 1.25;
  text-transform: uppercase;
  margin: 0;
}

.complex-card__desc {
  font-size: 12.5px;
  line-height: 1.45;
  color: #666666;
  margin: 0;
}

.complex-card__more {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 13.5px;
  font-weight: 400;
  color: #232323;
  text-decoration: underline;
  text-underline-offset: 3px;
  margin-top: auto;
}

.complex-card__more-circle {
  width: 19px;
  height: 19px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  text-decoration: none;
  transition: transform 0.2s ease;
}

.complex-card__more-circle svg {
  width: 19px;
  height: 19px;
  display: block;
}

.complex-card__more:hover .complex-card__more-circle {
  transform: translate(1px, -1px);
}

/* =========================================================
   DIRECTIONS PAGE
   ========================================================= */
.dir-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
  list-style: none;
  padding: 0;
  margin: 0;
}

.dir-item {
  list-style: none;
}

.dir-item__link {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 20px;
  background: #ffffff !important;
  border: none !important;
  border-radius: 20px !important;
  padding: 10px 24px 10px 14px;
  min-height: 80px;
  text-decoration: none;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
  transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.dir-item__link:hover {
  opacity: 1;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.05);
  transform: translateY(-1px);
}

.dir-item__icon {
  width: 59px;
  height: 59px;
  border-radius: 50%;
  background: transparent !important;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  overflow: hidden;
}

.dir-item__icon img,
.dir-item__icon svg {
  width: 100% !important;
  height: 100% !important;
  object-fit: contain;
  display: block;
}

.dir-item__name {
  font-family: var(--font-display, "Wix Madefor Display", sans-serif);
  font-size: 18px;
  font-weight: 500;
  color: #232323;
  line-height: 1.3;
}

.dir-item__arrow {
  width: 38px;
  height: 38px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: transform 0.2s ease;
}

.dir-item__arrow svg {
  width: 38px;
  height: 38px;
  display: block;
}

.dir-item__link:hover .dir-item__arrow {
  transform: translate(2px, -2px);
}

/* =========================================================
   RESPONSIVE (Mobile 375 - 768)
   ========================================================= */
@media (max-width: 1200px) {
  .complex-grid {
    grid-template-columns: repeat(3, 1fr);
  }
}

@media (max-width: 900px) {
  .complex-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

@media (max-width: 768px) {
  .srv,
  .directions {
    padding-block: 16px 50px;
  }

  .srv__title,
  .directions__title {
    font-size: 32px;
    margin-bottom: 18px;
  }

  .srv__switch,
  .directions__switch {
    margin-bottom: 24px;
    gap: 12px;
  }

  .srv-acc {
    gap: 8px;
  }

  .srv-acc__head,
  .dir-item__link {
    min-height: 60px;
    padding: 8px 16px 8px 10px;
    border-radius: 14px !important;
    gap: 14px;
  }

  .srv-acc__icon,
  .dir-item__icon {
    width: 42px;
    height: 42px;
  }

  .srv-acc__name,
  .dir-item__name {
    font-size: 15px;
  }

  .srv-acc__plus {
    width: 12px;
    height: 12px;
  }

  .srv-acc__plus::before {
    left: 5px;
    width: 2px;
    height: 12px;
  }

  .srv-acc__plus::after {
    top: 5px;
    width: 12px;
    height: 2px;
  }

  .dir-item__arrow {
    width: 32px;
    height: 32px;
  }

  .dir-item__arrow svg {
    width: 32px;
    height: 32px;
  }

  .srv-acc__body {
    padding: 10px 0 4px 0;
  }

  .tag-list {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 8px;
  }

  .tag {
    min-height: 36px;
    padding: 6px 8px 6px 12px;
    font-size: 13px;
    border-radius: 10px;
    gap: 6px;
  }

  .tag__arrow {
    width: 17px;
    height: 17px;
  }

  .tag__arrow svg {
    width: 17px;
    height: 17px;
  }

  /* Complexes on mobile: single white card container, hide images */
  .complex__title {
    font-size: 20px;
    margin: 22px 0 14px 0;
  }

  .complex-grid {
    display: flex;
    flex-direction: column;
    background: #ffffff !important;
    border-radius: 16px;
    padding: 18px;
    gap: 14px;
    margin-bottom: 16px;
    box-shadow: 0 1px 3px rgba(0, 0, 0, 0.02);
  }

  .complex-card {
    gap: 8px;
  }

  .complex-card + .complex-card {
    border-top: 1px solid #ebebeb;
    padding-top: 14px;
  }

  .complex-card__media {
    display: none !important;
  }

  .complex-card__title {
    font-size: 14px;
    line-height: 1.25;
  }

  .complex-card__desc {
    font-size: 12px;
    line-height: 1.4;
  }

  .complex-card__more {
    font-size: 13px;
  }
}
