:root {
  --gr-olive: rgba(108, 118, 87, 1);
  --gr-forest: rgba(35, 61, 39, 1);
  --gr-white: #ffffff;
  --gr-cream: rgba(254, 250, 243, 1);
  --gr-menu-hover: #b1ce6c;
  --gr-gradient: linear-gradient(
    160deg,
    rgba(35, 61, 39, 1) 0%,
    rgba(108, 118, 87, 1) 100%
  );
  --e-global-typography-primary-font-family: "IM Fell English SC", "Times New Roman", Times, serif;
  --e-global-typography-text-font-family: "Simonetta", "Times New Roman", Times, serif;
}

/* Preview stand-in only — remove on live WP page */
.gr-preview-hero {
  min-height: 100dvh;
  background: var(--gr-gradient);
}

/* ========== Mobile header bar ========== */
.gr-header {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background: transparent;
  .gr-header-inner {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    padding: 20px 20px 0;
    max-width: 100%;
  }
  .gr-logo {
    a {
      display: inline-block;
      line-height: 0;
    }
    img {
      display: block;
      width: 148px;
      height: auto;
      /* Logo asset is white on black — keep mark, drop black plate */
      mix-blend-mode: screen;
    }
  }
  .gr-hamburger {
    appearance: none;
    background: transparent;
    border: 0;
    padding: 0;
    margin: 0;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 36px;
    height: 27px;
    flex-shrink: 0;
    line-height: 0;
    img {
      display: block;
      width: 36px;
      height: 27px;
      object-fit: contain;
      /* Asset is black bars — invert to white on dark header */
      filter: brightness(0) invert(1);
    }
  }
}

/* ========== Megamenu overlay (Helen pattern) ========== */
/* Scroll lock + scrollbar compensation handled in custom.js */

.gr-megamenu-container {
  position: relative;
  .megamenu-fixed-wrapper {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: auto;
    z-index: 9999;
    background-color: var(--gr-forest);
    background-image: url("https://gardenrestoration.kinsta.cloud/wp-content/uploads/2026/08/leaf_png.png"), var(--gr-gradient);
    background-repeat: no-repeat, no-repeat;
    background-size: cover, cover;
    background-position: center, center;
    overflow-y: auto;
    -webkit-overflow-scrolling: touch;
    scrollbar-width: none;
    -ms-overflow-style: none;
    transition: transform 0.5s ease;
    transform: translateY(-100%);
    display: flex;
    flex-direction: column;
    padding: 32px 28px;
    box-sizing: border-box;
    &.megamenu-open {
      transition: transform 0.5s ease;
      transform: translateY(0%);
    }
    &::-webkit-scrollbar {
      display: none;
    }
  }

  .megamenu-logo-close-btn {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    justify-content: space-between;
    width: 100%;
    flex-shrink: 0;
    .logo-wrapper {
      img {
        display: block;
        width: 325px;
        height: auto;
        mix-blend-mode: screen;
      }
    }
    .close-btn {
      appearance: none;
      background: transparent;
      border: 0;
      padding: 0;
      margin: 0;
      cursor: pointer;
      line-height: 0;
      width: 34px;
      display: inline-flex;
      align-items: center;
      justify-content: center;
      flex-shrink: 0;
      img {
        display: block;
        width: 34px;
        height: 30px;
        object-fit: contain;
        margin-bottom: 45px;
        /* Asset is white X on black — show X only on green overlay */
        mix-blend-mode: screen;
      }
    }
  }

  .megamenu-mobile-wrapper {
    display: flex;
    flex-direction: column;
    align-items: center;
    text-align: center;
    padding: 45px 0 45px;
    ul {
      padding: 0;
      margin: 0;
      list-style: none;
    }
    .gr-mobile-menu {
      display: flex;
      flex-direction: column;
      align-items: center;
      gap: 29px;
      margin-bottom: 50px;
      .menu-item {
        a {
          font-family: var(--e-global-typography-primary-font-family);
          font-weight: 400;
          font-style: normal;
          font-size: 16px;
          line-height: 100%;
          letter-spacing: 0.05em;
          text-transform: uppercase;
          text-decoration: none;
          color: var(--gr-cream);
          transition: color 0.3s ease;
          &:hover {
            color: var(--gr-menu-hover);
          }
        }
      }
    }
    .gr-menu-contact {
      display: flex;
      flex-direction: column;
      align-items: center;
      /* Live WP markup: .gr-contact-menu > li.menu-item > a (3 items) */
      .gr-contact-menu {
        display: flex;
        flex-direction: column;
        align-items: center;
        width: 100%;
        .menu-item {
          list-style: none;
          /* 1 — CONTACT US label */
          &:nth-child(1) {
            margin: 0 0 7px;
            a {
              font-family: var(--e-global-typography-primary-font-family);
              font-weight: 400;
              font-style: normal;
              font-size: 15px;
              line-height: 100%;
              letter-spacing: 0.05em;
              text-align: center;
              text-transform: uppercase;
              text-decoration: none;
              color: var(--gr-cream);
              transition: color 0.3s ease;
              &:hover {
                color: var(--gr-menu-hover);
              }
            }
          }
          /* 2 — phone */
          &:nth-child(2) {
            margin: 0 0 32px;
            a {
              font-family: var(--e-global-typography-text-font-family);
              font-weight: 400;
              font-style: normal;
              font-size: 24px;
              line-height: 140%;
              letter-spacing: 0.04em;
              text-align: center;
              text-decoration: none;
              color: var(--gr-cream);
              transition: color 0.3s ease;
              &:hover {
                color: var(--gr-menu-hover);
              }
            }
          }
          /* 3 — SEND A MESSAGE ghost button */
          &:nth-child(3) {
            a {
              display: inline-flex;
              align-items: center;
              justify-content: center;
              gap: 10px;
              width: fit-content;
              height: 55px;
              padding: 18px 20px;
              box-sizing: border-box;
              border: 1px solid var(--gr-cream);
              background: transparent;
              font-family: var(--e-global-typography-primary-font-family);
              font-weight: 400;
              font-style: normal;
              font-size: 15px;
              line-height: 100%;
              letter-spacing: 0.05em;
              text-align: center;
              text-transform: uppercase;
              text-decoration: none;
              color: var(--gr-cream);
              transition: background-color 0.3s ease, color 0.3s ease;
              &:hover {
                background-color: var(--gr-cream);
                color: var(--gr-forest);
              }
            }
          }
        }
      }
    }
  }
}

/* ========== Our Work — project portfolio ========== */
.gr-our-work {
  background-color: var(--gr-cream);
  .gr-our-work-heading {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 12px;
    margin-bottom: 48px;
    max-width: 1203px; /* 590px × 2 + 23px gap */
    margin-left: auto;
    margin-right: auto;
    img {
      display: block;
      width: 28px;
      height: auto;
      mix-blend-mode: multiply;
    }
    span {
      font-family: var(--e-global-typography-primary-font-family);
      font-weight: 400;
      font-size: 14px;
      line-height: 100%;
      letter-spacing: 0.2em;
      text-transform: uppercase;
      color: var(--gr-forest);
    }
  }
  .gr-our-work-list {
    max-width: 1203px; /* 590px × 2 + 23px gap */
    margin: 0 auto;
  }
  .gr-work-item {
    padding: 84px 0 26px;
    border-top: 1px solid var(--gr-forest);
    &:first-child {
      border-top: 0;
      padding-top: 0;
    }
    &:last-child {
      border-bottom: 1px solid var(--gr-forest);
    }
    .gr-work-title {
      margin: 0 0 19px;
      font-family: var(--e-global-typography-primary-font-family);
      font-weight: 400;
      font-style: normal;
      font-size: 52px;
      line-height: 115%;
      letter-spacing: -0.02em;
      color: var(--gr-forest);
      opacity: 0;
      transform: translateX(-40px);
    }
    .gr-work-excerpt {
      margin: 0 0 32px;
      max-width: 790px;
      font-family: var(--e-global-typography-text-font-family);
      font-weight: 400;
      font-style: normal;
      font-size: 18px;
      line-height: 135%;
      letter-spacing: 0;
      color: var(--gr-forest);
      opacity: 0;
      transform: translateX(-40px);
    }
    &.gr-in-view {
      .gr-work-title,
      .gr-work-excerpt,
      .gr-work-meta-row {
        animation: gr-fade-in-left 0.8s ease forwards;
      }
      .gr-work-excerpt {
        animation-delay: 0.15s;
      }
      .gr-work-meta-row {
        animation-delay: 0.3s;
      }
      .gr-work-slider {
        animation: gr-fade-up 0.8s ease forwards;
        animation-delay: 0.45s;
      }
    }
    .gr-work-meta-row {
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      justify-content: space-between;
      gap: 20px;
      margin-bottom: 42px;
      opacity: 0;
      transform: translateX(-40px);
    }
    .gr-work-tags {
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      gap: 10px;
      padding: 0;
      margin: 0;
      list-style: none;
      .gr-work-tag {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        font-family: var(--e-global-typography-primary-font-family);
        font-weight: 400;
        font-style: normal;
        font-size: 14px;
        line-height: 100%;
        letter-spacing: 0.05em;
        text-align: center;
        text-transform: uppercase;
        color: var(--gr-forest);
        background-color: var(--gr-cream);
        padding: 9px 16px 7px 16px;
        border: 1px solid var(--gr-forest);
        border-radius: 100px;
      }
    }
    .gr-work-nav {
      display: flex;
      flex-wrap: wrap;
      align-items: center;
      gap: 10px;
      flex-shrink: 0;
      button {
        appearance: none;
        border: 0;
        margin: 0;
        padding: 0;
        width: 45px;
        height: 45px;
        border-radius: 100%;
        background-color: var(--gr-olive);
        cursor: pointer;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        line-height: 0;
        text-align: center;
        box-sizing: border-box;
        font-size: 0;
        transition: background-color 0.3s ease;
        img {
          display: block;
          width: 15px;
          height: 15px;
          margin: 0;
          padding: 0;
          object-fit: contain;
          flex-shrink: 0;
        }
        &.gr-work-prev img {
          transform: translateX(-2px);
        }
        &.gr-work-next img {
          transform: translateX(2px);
        }
        &:hover {
          background-color: var(--gr-forest);
        }
        &:disabled {
          opacity: 0.3;
          cursor: default;
          &:hover {
            background-color: var(--gr-olive);
          }
        }
      }
    }
    .gr-work-slider {
      margin: 0 -11.5px;
      opacity: 0;
      transform: translateY(40px);
      &:not(.slick-initialized) {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 590px));
        gap: 23px;
        margin: 0;
        .gr-work-slide {
          padding: 0;
        }
      }
      .gr-work-slide {
        padding: 0 11.5px;
        box-sizing: border-box;
        a {
          display: block;
          cursor: zoom-in;
          line-height: 0;
        }
        img {
          display: block;
          width: 100%;
          max-width: 590px;
          height: 412px;
          max-height: 412px;
          object-fit: cover;
        }
      }
      .slick-list {
        overflow: hidden;
      }
      .slick-track {
        display: flex;
        align-items: stretch;
      }
    }
  }
}

/* ========== Services carousel — prev/next button design + position ========== */
.gr-services-slider {
  position: relative;

  .elementor-swiper-button {
    position: absolute !important;
    top: 0 !important;
    z-index: 2;
    width: 45px;
    height: 45px;
    min-width: 45px;
    min-height: 45px;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 100%;
    background-color: var(--gr-olive);
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    line-height: 0;
    text-align: center;
    box-sizing: border-box;
    font-size: 0;
    cursor: pointer;
    transform: none !important;
    transition: background-color 0.3s ease;

    svg {
      display: block !important;
      width: 15px !important;
      height: 15px !important;
      margin: 0 !important;
      padding: 0 !important;
      flex-shrink: 0;
    }

    &:hover {
      background-color: var(--gr-forest);
    }

    &.swiper-button-disabled {
      opacity: 0.3;
      pointer-events: none;
      cursor: default;
    }
  }

  .elementor-swiper-button-next {
    right: 0;
    left: auto !important;
    svg {
      transform: translateX(2px);
    }
  }

  .elementor-swiper-button-prev {
    right: 55px;
    left: auto !important;
    svg {
      transform: translateX(-2px);
    }
  }
}

/* ========== Contact slider — prev/next button design + position ========== */
.slider-arrow-contact {
  position: relative;

  .elementor-swiper-button {
    position: absolute !important;
    bottom: 56px;
    top: auto !important;
    z-index: 2;
    width: 45px;
    height: 45px;
    min-width: 45px;
    min-height: 45px;
    margin: 0;
    padding: 0;
    border: 0;
    border-radius: 100%;
    background-color: var(--gr-olive);
    display: inline-flex !important;
    align-items: center !important;
    justify-content: center !important;
    line-height: 0;
    text-align: center;
    box-sizing: border-box;
    font-size: 0;
    cursor: pointer;
    transform: none !important;
    transition: background-color 0.3s ease;

    &:hover {
      background-color: var(--gr-forest);
    }

    svg {
      display: none;
    }

    &::after {
      content: "";
      display: block;
      width: 15px;
      height: 15px;
      margin: 0;
      padding: 0;
      flex-shrink: 0;
      background-repeat: no-repeat;
      background-position: center;
      background-size: contain;
    }

    &.swiper-button-disabled {
      opacity: 0.3;
      pointer-events: none;
      cursor: default;
    }
  }

  .elementor-swiper-button-next {
    right: 56px !important;
    left: auto !important;
    &::after {
      background-image: url("https://gardenrestoration.kinsta.cloud/wp-content/uploads/2026/08/Polygon-1.svg");
    }
  }

  .elementor-swiper-button-prev {
    right: 111px;
    left: auto !important;
    &::after {
      background-image: url("https://gardenrestoration.kinsta.cloud/wp-content/uploads/2026/08/Polygon-2-4.svg");
    }
  }
}

/* ========== Footer phone + CTA ========== */
/* Live: .gr-footer li.footer-mobile-number > a, .gr-footer li.footer-send-button > a */
.gr-footer {
  .footer-mobile-number {
    margin-bottom: 34px !important;
    a {
      font-family: var(--e-global-typography-text-font-family) !important;
      font-weight: 400 !important;
      font-style: normal !important;
      font-size: 24px !important;
      line-height: 140% !important;
      letter-spacing: 0.04em !important;
      text-decoration: none !important;
      color: var(--gr-cream) !important;
      transition: color 0.3s ease;
      &:hover {
        color: var(--gr-menu-hover) !important;
      }
    }
  }
  .footer-send-button {
    margin: 0 !important;
    text-align: right !important;
    display: flex !important;
    justify-content: flex-end !important;
    a {
      display: inline-flex !important;
      align-items: center !important;
      justify-content: center !important;
      gap: 10px;
      width: fit-content;
      margin-left: auto;
      height: auto;
      max-height: 50px;
      padding: 18px 20px !important;
      box-sizing: border-box;
      border: 1px solid var(--gr-cream) !important;
      background: transparent !important;
      font-family: var(--e-global-typography-primary-font-family) !important;
      font-weight: 400 !important;
      font-style: normal !important;
      font-size: 15px !important;
      line-height: 100% !important;
      letter-spacing: 0.05em !important;
      text-align: center !important;
      text-transform: uppercase !important;
      text-decoration: none !important;
      color: var(--gr-cream) !important;
      transition: background-color 0.3s ease, color 0.3s ease;
      &:hover {
        background-color: var(--gr-cream) !important;
        color: var(--gr-forest) !important;
      }
    }
  }
}

@keyframes gr-fade-in-left {
  from {
    opacity: 0;
    transform: translateX(-40px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@keyframes gr-fade-up {
  from {
    opacity: 0;
    transform: translateY(40px);
  }
  to {
    opacity: 1;
    transform: none;
  }
}

@media (prefers-reduced-motion: reduce) {
  .gr-our-work .gr-work-item {
    .gr-work-title,
    .gr-work-excerpt,
    .gr-work-meta-row,
    .gr-work-slider {
      opacity: 1;
      transform: none;
      animation: none !important;
    }
  }
}
