.troi-app {
  container-type: inline-size;
  & h2,
  & h3,
  & p {
    margin: 0;
  }
  & .troi-grid {
    display: flex;
    gap: 48px 24px;
    flex-direction: column;
    margin-bottom: var(--wp--custom--min-24-max-56, 24px);
    @container (min-width: 1024px) {
      flex-direction: row;
      align-items: flex-start;
    }
  }
}
.troi-panel,
.troi-results {
  display: flex;
  flex-direction: column;
}
.troi-panel {
  padding: var(--wp--custom--min-24-max-56, 24px);
  box-sizing: border-box;
  @container (min-width: 1024px) {
    max-width: 500px;
  }
  & button.troi-reset {
    margin: 0px auto;
    background: none !important;
    color: #8a8a8a !important;
    display: flex !important;
    gap: 4px;
    & img {
      filter: invert(54%);
    }
  }
}
.troi-results {
  container-type: inline-size;
  @container (min-width: 1024px) {
    position: sticky;
    top: 124px;
    flex: 1;
  }
}
.troi-input-section {
  margin-bottom: var(--wp--custom--min-24-max-56, 24px);
  & .troi-section-title {
    display: flex;
    align-items: center;
    gap: 8px;
    padding-bottom: 24px;
    & .troi-section-num {
      display: inline-flex;
      align-items: center;
      justify-content: center;
      width: 48px;
      height: 48px;
      flex-shrink: 0;
      border-radius: 12px;
      background-color: var(--wp--preset--color--synergy-melon, #ffecbc);
      font-size: 24px;
    }
  }
  .troi-input-row {
    margin-bottom: 24px;
    & .troi-input-label {
      display: block;
    }
    .troi-input-wrap {
      position: relative;
      & .troi-input-prefix,
      & .troi-input-suffix {
        position: absolute;
        top: 53%;
        transform: translateY(-50%);
        color: var(--wp--preset--color--synergy-gunmetal, #6c6c6c);
        pointer-events: none;
      }
      & .troi-input-prefix {
        left: 0.875rem;
      }
      & .troi-input-suffix {
        right: 0.875rem;
      }
      & .troi-input {
        width: 100%;
        color: var(--wp--preset--color--synergy-onyx, #141414);
        font-variant-numeric: tabular-nums;
        &::placeholder {
          color: #8a8a8a !important;
        }
        &.troi-input--prefix {
          padding-left: 1.75rem;
        }
        &.troi-input--suffix {
          padding-right: 1.75rem;
        }
      }
      & .troi-input--select {
        appearance: none;
        background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 12 12'%3E%3Cpath fill='%236c6c6c' d='M6 9L1.5 3.75h9z'/%3E%3C/svg%3E");
        background-repeat: no-repeat;
        background-position: right 0.875rem center;
        padding-right: 2.25rem;
      }
    }
    & .troi-input-hint {
      padding: 5px 16px 0px 16px;
      color: #8a8a8a;
      font-size: 11px;
      line-height: 16px;
      letter-spacing: -0.33px;
    }
    &:last-child {
      margin-bottom: 0;
    }
  }
}
.troi-hero {
  margin: 16px 0px 24px 0px;
  padding: 36px var(--wp--custom--min-24-max-48, 24px);
  display: flex;
  flex-direction: column;
  gap: 24px;
  background-color: var(--wp--preset--color--synergy-melon, #ffecbc);
  text-align: center;
  & p {
    padding-bottom: 0px;
  }
  & .troi-hero__value {
    font-size: var(--wp--custom--min-64-max-72, 64px);
    font-weight: var(--wp--custom--font-weight--medium, 500);
    line-height: var(--wp--custom--min-64-max-72, 64px);
    letter-spacing: -3.6px;
  }
  & .troi-hero__sub {
    color: var(--wp--preset--color--synergy-gunmetal, #6c6c6c);
  }
  & .troi-pills {
    gap: var(--wp--custom--min-16-max-24, 16px);
    justify-content: center;
    & .troi-pill {
      font-size: var(--wp--custom--min-18-max-20, 18px);
      font-weight: var(--wp--custom--font-weight--medium, 500);
      line-height: var(--wp--custom--min-24-max-28, 24px);
      letter-spacing: -0.6px;
      padding: 16px var(--wp--custom--min-12-max-20, 12px);
      border-radius: 20px;
      background: var(--wp--preset--color--synergy-onyx, #141414);
      color: white;
      font-variant-numeric: tabular-nums;
    }
  }
}
.troi-driver-grid {
  gap: 10px 16px;
  margin-bottom: 24px;
  display: flex;
  flex-direction: column;
  @container (min-width:490px) {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 24px 16px;
  }
  & .troi-driver {
    padding: var(--wp--custom--min-16-max-24, 16px) 16px;
    background-color: var(--wp--preset--color--synergy-rhino, #efefef);
    transition:
      background-color 0.3s ease,
      border-color 0.3s ease,
      transform 0.3s ease;
    text-align: center;
    display: flex;
    flex-direction: column;
    gap: 4px;
    @container (min-width: 782px) {
      gap: 12px;
    }
    & p {
      padding-bottom: 0px;
    }
    & .troi-driver__value {
      font-variant-numeric: tabular-nums;
      font-size: var(--wp--custom--min-32-max-48, 32px);
      font-weight: var(--wp--custom--font-weight--medium, 500);
      line-height: var(--wp--custom--min-32-max-48, 32px);
      letter-spacing: -2.4px;
    }
    & .troi-driver__meta {
      min-height: 24px;
      &:empty {
        display: flex !important;
      }
    }
    &.troi-driver--locked {
      border: dashed 1px var(--wp--preset--color--synergy-pebble, #ccc);
      background-color: transparent;
      /* border: none;

  background-image:
    linear-gradient(
      to right,
      var(--wp--preset--color--synergy-pebble, #ccc) 50%,
      transparent 50%
    ),
    linear-gradient(
      to right,
      var(--wp--preset--color--synergy-pebble, #ccc) 50%,
      transparent 50%
    ),
    linear-gradient(
      to bottom,
      var(--wp--preset--color--synergy-pebble, #ccc) 50%,
      transparent 50%
    ),
    linear-gradient(
      to bottom,
      var(--wp--preset--color--synergy-pebble, #ccc) 50%,
      transparent 50%
    );
  background-position:
    left top,
    left bottom,
    left top,
    right top;
  background-size:
    10px 1px,
    10px 1px,
    1px 10px,
    1px 10px;
  background-repeat: repeat-x, repeat-x, repeat-y, repeat-y; */
      & img {
        filter: brightness(0) invert(1) brightness(0.8);
      }
      & p {
        color: var(--wp--preset--color--synergy-pebble, #ccc);
        display: flex;
        align-items: center;
        justify-content: center;
        font-weight: var(--wp--custom--font-weight--medium, 500);
      }
      & .troi-driver__value {
        color: var(--wp--preset--color--synergy-pebble, #ccc);
      }
    }
  }
}
@keyframes troi-unlock {
  0% {
    background-color: var(--wp--preset--color--synergy-melon, #ffecbc);
    border-color: var(--wp--preset--color--synergy-gold, #ffbd01);
    transform: scale(1.03);
  }
  100% {
    transform: scale(1);
  }
}
.troi-driver--unlocked {
  animation: troi-unlock 0.6s ease;
}
.troi-gate {
  padding: 36px var(--wp--custom--min-24-max-48, 24px);
  border-radius: var(--r-40, 40px);
  background: var(--Rhino, #efefef);
  & .troi-gate__title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: var(--wp--custom--min-24-max-32, 24px);
    font-weight: var(--wp--custom--font-weight--medium, 500);
    line-height: var(--wp--custom--min-32-max-40, 32px);
    letter-spacing: -1.6px;
    padding-bottom: 16px;
    & .troi-lock {
      display: inline-flex;
    }
  }
  & .troi-gate__sub {
    margin-bottom: var(--wp--custom--min-8-max-16, 10px);
  }
  & .troi-gate__form {
    margin-top: var(--wp--custom--min-8-max-16, 10px);
    & input {
      background: white;
    }
    & .form-group:has(button[type="submit"]) {
      margin: 0px;
      padding-bottom: 0px;
      display: flex;
      justify-content: center;
    }
  }
  &.troi-gate--success {
    background-color: var(--wp--preset--color--synergy-melon, #fff);
  }
}
@keyframes troi-fadein {
  from {
    opacity: 0;
    transform: translateY(8px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}
.troi-cta {
  text-align: center;
  padding: var(--wp--custom--min-36-max-64, 36px)
    var(--wp--custom--min-24-max-100, 24px);
  & .troi-cta__title {
    color: var(--wp--preset--color--synergy-white, #fff);
    padding-bottom: 24px;
  }
  & .troi-cta__text {
    color: var(--wp--preset--color--synergy-white, #fff);
    margin-bottom: 24px;
  }
  &.troi-cta--show {
    animation: troi-fadein 0.5s ease;
  }
}
.troi-label-row {
  display: flex;
  align-items: center;
  gap: 4px;
  margin-bottom: 6px;
  & .troi-tip-wrap {
    position: relative;
    display: inline-flex;
    align-items: center;
    & .troi-tip-btn {
      display: block;
      cursor: pointer;
      &:hover + .troi-tip {
        display: block;
      }
    }
    & .troi-tip {
      display: none;
      position: absolute;
      bottom: calc(100% + 8px);
      left: 50%;
      translate: -50% 0;
      background-color: var(--wp--preset--color--synergy-onyx, #141414);
      color: #fff;
      font-size: 12px;
      line-height: 16px;
      letter-spacing: -0.12px;
      padding: 4px 8px;
      border-radius: 8px;
      white-space: nowrap;
      pointer-events: none;
      z-index: 100;
    }
  }
}
