/* Display Tree Updates */
#tree-updates {
  margin: 50px 0 70px 0;
}

.tree-updates-container {
  max-width: 950px;
  margin: 0 auto;
  padding: 0 20px;
}

.tree-updates-header h2 {
  font-size: 30px !important;
  font-weight: 700 !important;
  text-align: center;
  padding-bottom: 20px;
}

.tree-updates-entries {
  position: relative;
}

.tree-updates-entries .center-line {
  position: absolute;
  height: 100%;
  width: 4px;
  background: #f9f9f9;
  left: 20px;
  top: 20px;
  transform: translateX(-50%);
}

.tree-updates-entries .tree-updates-card {
  display: flex;
  margin: 30px 0 3px 60px;
}

.tree-updates-entries .tree-updates-card section {
  padding: 30px;
  border-radius: 10px;
  background: #fff;
  width: 100%;
  position: relative;
}

.tree-updates-entries .tree-updates-card section::before {
  position: absolute;
  content: "";
  height: 15px;
  width: 15px;
  background: #fff;
  top: 28px;
  left: -7px;
  transform: rotate(45deg);
}

.tree-updates-card section .icon,
.center-line .scroll-icon {
  position: absolute;
  height: 40px;
  width: 40px;
  text-align: center;
  line-height: 40px;
  border-radius: 50%;
  font-size: 17px;
  box-shadow: 0 0 0 4px #fff, inset 0 2px 0 rgba(0, 0, 0, 0.08),
    0 3px 0 4px rgba(0, 0, 0, 0.05);
}

.tree-updates-card section .icon {
  top: 15px;
  left: -60px;
  background: #3a803e;
  color: #fff;
}

.tree-updates-card.perished section .icon {
  background: #c49a6c;
}

.center-line .scroll-icon {
  bottom: 0px;
  left: 50%;
  font-size: 25px;
  transform: translateX(-50%);
  background: #f2f2f2;
  color: #3a803e;
}

.tree-updates-card:last-child {
  margin-bottom: 0;
}

.tree-updates-card h2 {
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 20px !important;
  font-weight: 600 !important;
  margin-bottom: 30px;
}

.tree-updates-card h2 > span {
  font-size: 11px;
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: 0.04em;
  padding: 5px 20px;
  border-radius: 50px;
  background: #53b156;
  color: #fff;
}

.tree-updates-card.perished h2 > span {
  background: #c49a6c;
}

.tree-updates-card .notes {
  margin-bottom: 25px;
}

.tree-updates-card .image-gallery {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 16px;
}

.tree-updates-card .image-gallery .gallery-item {
  overflow: hidden;
  border-radius: 8px;
  box-shadow: 0 4px 8px rgba(0, 0, 0, 0.1);
}

.tree-updates-card .image-gallery .gallery-item img {
  width: 100%;
  height: 110px;
  display: block;
  border-radius: 8px;
  object-fit: cover;
}

.fancybox-active #wpadminbar {
  display: none;
}

@media (max-width: 575.98px) {
  #tree-updates {
    margin: 30px 0 50px 0;
  }

  .tree-updates-header h2 {
    padding-bottom: 30px;
  }

  .tree-updates-card h2 {
    flex-direction: column;
    align-items: flex-start;
  }

  .tree-updates-card h2 > span {
    margin-top: 15px;
    padding: 2px 12px;
  }
}

@media (max-width: 320.98px) {
  .tree-updates-card h2 > span span {
    display: none;
  }
}

@media (min-width: 1024px) {
  body.admin-bar ._fancybox-is-open,
  body.admin-bar .pswp--open {
    margin-top: 32px;
  }
}

/* Custom shortcode to display post type tree for logged-in user */
.tree-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  grid-column-gap: 30px;
  grid-row-gap: 30px;
  overflow: hidden;
}

.tree-grid .post-item {
  display: flex;
  flex-direction: column;
  padding-bottom: 30px;
  border-bottom: 1px dashed rgba(224, 229, 235, 0.8);
}

.tree-grid .post-item > *:not(:last-child) {
  margin-bottom: 15px;
}

.tree-grid .post-item figure {
  position: relative;
}

.tree-grid .post-item span.status {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  position: absolute;
  z-index: 1;
  top: 15px;
  left: 15px;
  height: 28px;
  border-radius: 3px;
  padding: 0 10px !important;
  font-size: 13px;
  font-weight: 600;
  line-height: 0;
  margin: 0 !important;
  color: #fff;
  background-color: #069d1e;
}

.tree-grid .post-item span.status-publish {
  background-color: #069d1e;
}

.tree-grid .post-item span.status-planted {
  background-color: #069d1e;
}

.tree-grid .post-item span.status-perished {
  background-color: #ec0000;
}

.tree-grid .post-item span.status-replaced {
  background-color: #ecca00;
}

.tree-grid .post-item .image-container {
  display: inline-flex;
  overflow: hidden;
  vertical-align: middle;
  position: relative;
  width: 100%;
}

.tree-grid .post-item .image-container img {
  max-width: 100%;
  height: auto;
  border-radius: inherit;
  object-fit: cover;
  object-position: 50% 50%;
  /* aspect-ratio: 9/16; */
  aspect-ratio: 2/3;
}

.tree-grid .post-item .post-title {
  margin-top: 0;
  font-size: 18px;
  line-height: 1.3;
}

.tree-grid .post-item > div {
  font-size: 15px;
}

.tree-grid .post-item svg {
  vertical-align: middle;
}

@media (max-width: 1199.98px) {
  .tree-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }
}

@media (max-width: 991.98px) {
  .tree-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (max-width: 767.98px) {
  .tree-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }
}

@media (max-width: 575.98px) {
  .tree-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

@media (max-width: 320.98px) {
  .tree-grid {
    grid-template-columns: repeat(1, minmax(0, 1fr));
  }
}

/* Custom shortcode to display post type tree group by Parent(Order ID) for logged-in user */
.order-group {
  margin-bottom: 25px;
}

.order-group .order-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 35px;
  background: #c49a6c;
}

.order-group .order-header .order-id {
  text-transform: uppercase;
  font-size: 24px;
  font-weight: 600;
  background: #fff;
  padding-right: 15px;
}

.order-group .order-header .order-date {
  color: #fff;
  font-size: 14px;
  font-weight: 600;
  padding-right: 15px;
  padding-left: 15px;
}

.order-group .tree-grid {
  display: grid;
  grid-template-columns: repeat(6, minmax(0, 1fr));
  grid-column-gap: 25px;
  grid-row-gap: 25px;
  overflow: hidden;
}

.order-group .tree-grid .tree-item {
  display: flex;
  flex-direction: column;
  padding-bottom: 30px;
}

.order-group .tree-grid .tree-item > *:not(:last-child) {
  margin-bottom: 14px;
}

.order-group .tree-grid .tree-item figure {
  position: relative;
}

.order-group .tree-grid .tree-item span.status {
  display: inline-flex !important;
  align-items: center;
  justify-content: center;
  position: absolute;
  z-index: 1;
  top: 12px;
  left: 12px;
  height: 24px;
  border-radius: 3px;
  padding: 0 10px !important;
  font-size: 12px;
  font-weight: 600;
  line-height: 0;
  margin: 0 !important;
  color: #fff;
  background-color: #069d1e;
}

.order-group .tree-grid .tree-item span.status-publish {
  background-color: #069d1e;
}

.order-group .tree-grid .tree-item span.status-planted {
  background-color: #069d1e;
}

.order-group .tree-grid .tree-item span.status-perished {
  background-color: #ec0000;
}

.order-group .tree-grid .tree-item span.status-replaced {
  background-color: #ecca00;
}

.order-group .tree-grid .tree-item .image-container {
  display: inline-flex;
  overflow: hidden;
  vertical-align: middle;
  position: relative;
  width: 100%;
}

.order-group .tree-grid .tree-item .image-container img {
  max-width: 100%;
  height: auto;
  border-radius: 8px;
  object-fit: cover;
  object-position: 50% 50%;
  /* aspect-ratio: 9/16; */
  aspect-ratio: 2/3;
}

.order-group .tree-grid .tree-item .post-title {
  margin-top: 0;
  font-size: 16px;
  line-height: 1.3;
}

.order-group .tree-grid .tree-item > div {
  font-size: 13px;
}

.order-group .tree-grid .tree-item svg {
  vertical-align: middle;
}

@media (max-width: 1199.98px) {
  .order-group .tree-grid {
    grid-template-columns: repeat(6, minmax(0, 1fr));
  }
}

@media (max-width: 991.98px) {
  .order-group .tree-grid {
    grid-template-columns: repeat(4, minmax(0, 1fr));
  }
}

@media (max-width: 767.98px) {
  .order-group .tree-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
  }

  .order-group .order-header .order-id {
    font-size: 20px;
  }

  .order-group .order-header .order-date {
    font-size: 12px;
  }
}

@media (max-width: 575.98px) {
  .order-group .tree-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .order-group .order-header .order-id {
    font-size: 20px;
  }

  .order-group .order-header .order-date {
    font-size: 12px;
  }
}

@media (max-width: 320.98px) {
  .order-group .tree-grid {
    grid-template-columns: repeat(1, minmax(0, 1fr));
  }

  .order-group .order-header .order-id {
    font-size: 14px;
  }

  .order-group .order-header .order-date {
    font-size: 12px;
  }
}

/* woocommerce registration form */
form.woocommerce-form-register .description {
  font-size: 80%;
  line-height: 15px;
  display: block;
  margin-top: 10px;
  color: #777;
}
