@use './variables.scss' as vars;
.botfoundry {
  // Buttons
  .botfoundry-btn {
    padding: 8px 10px;
    border: 0;
    pointer-events: auto;

    &.std-button {
      border-radius: 6px;
      background: vars.$primary-color;
      color: #fff;
    }
    &.active {
      background-color: vars.$primary-color;
      color: #fff;
    }
    &:hover {
      cursor: pointer;
      background-color: vars.$primary-color-hover;
      color: #fff;
    }
    &:active {
      background-color: vars.$primary-color-dark;
      color: #fff;
    }

    &.remove {
      background-color: vars.$color-red;
    }
    &:disabled {
      background-color: vars.$color-muted;
      color: #fff;
      cursor: not-allowed;
    }
  }

  // Inputs
  .botfoundry-input {
    display: flex;
    flex-direction: column;
    .botfoundry-label {
      padding-bottom: 0.5rem;
    }

    input {
      border-radius: 4px;
      &:focus {
        outline: none;
        border-color: vars.$primary-color;
        box-shadow: 0 0 0 1px vars.$primary-color;
      }
    }
  }
  .extra-large-input {
    width: 100%;
  }

  // Modal
  .botfoundry-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.8); /* Darker overlay */
    z-index: 1000;
    display: none;
    &.open {
      display: block;
    }
  }

  /* Modal styling */
  .botfoundry-modal {
    position: fixed;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    background-color: white;
    padding: 20px;
    border-radius: 8px;
    box-shadow: 0 4px 6px rgba(0, 0, 0, 0.2);
    z-index: 1001;
    max-width: 500px;
    width: 90%;
  }

  .botfoundry-modal-header {
    font-size: 1.25rem;
    margin-bottom: 10px;
  }

  .botfoundry-modal-content {
    margin-bottom: 20px;
  }

  .botfoundry-modal-close {
    position: absolute;
    top: 14px;
    right: 14px;
    font-size: 1rem;
    cursor: pointer;
  }

  // Typography
  label {
    font-weight: 500;
  }

  h4 {
    font-size: 0.875rem;
    font-weight: 600;
  }

  // Helper classes
  .d-flex {
    display: flex;
  }
  .justify-content-center {
    justify-content: center;
  }
  .justify-content-between {
    justify-content: space-between;
  }
  .align-items-center {
    align-items: center;
  }
  .flex-column {
    flex-direction: column;
  }

  .small-input {
    width: 100px;
  }

  .medium-input {
    width: 200px;
  }

  .large-input {
    width: 100%;
    max-width: 400px;
  }

  .text-muted {
    font-weight: 500;
    color: vars.$color-muted;
  }

  .m-auto {
    margin: auto;
  }

  .mt-auto {
    margin-top: auto;
  }
  .mb-auto {
    margin-bottom: auto;
  }
  .mr-auto {
    margin-right: auto;
  }

  .ml-auto {
    margin-left: auto;
  }
  .m-0 {
    margin: 0;
  }
  .mb-0 {
    margin-bottom: 0;
  }
  .mt-0 {
    margin-top: 0;
  }
  .ml-0 {
    margin-left: 0;
  }
  .mr-0 {
    margin-right: 0;
  }

  .m-4 {
    margin: 4px;
  }
  .mb-4 {
    margin-bottom: 4px;
  }
  .mt-4 {
    margin-top: 4px;
  }
  .ml-4 {
    margin-left: 4px;
  }
  .mr-4 {
    margin-right: 4px;
  }

  .m-8 {
    margin: 8px;
  }
  .mt-8 {
    margin-top: 8px;
  }
  .mb-8 {
    margin-bottom: 8px;
  }
  .ml-8 {
    margin-left: 8px;
  }
  .mr-8 {
    margin-right: 8px;
  }

  .m-16 {
    margin: 16px;
  }
  .mt-16 {
    margin-top: 16px;
  }

  .mr-16 {
    margin-right: 16px;
  }

  .mb-16 {
    margin-bottom: 16px;
  }

  .pb-4 {
    padding-bottom: 4px;
  }

  .pb-8 {
    padding-bottom: 8px;
  }
  .m-24 {
    margin: 24px;
  }
  .mt-24 {
    margin-top: 24px;
  }
  .mb-24 {
    margin-bottom: 24px;
  }
  .ml-24 {
    margin-left: 24px;
  }
  .pb-24 {
    padding-bottom: 24px;
  }
  .pt-24 {
    padding-top: 24px;
  }
  .pl-24 {
    padding-left: 24px;
  }
  .pr-24 {
    padding-right: 24px;
  }
  .p-24 {
    padding: 24px;
  }

  .h-100 {
    height: 100%;
  }
  .w-100 {
    width: 100%;
  }
  .gap-8 {
    gap: 8px;
  }
  .gap-16 {
    gap: 16px;
  }
  .gap-24 {
    gap: 24px;
  }
  hr {
    margin: 0;
    border: none;
    border-top: 1px solid #e0e0e0;
  }
  // Animations
  .ease-in-out {
    transition: 0.2s ease-in-out;
  }

  @keyframes blink {
    0% {
      content: '';
    }
    33% {
      content: '.';
    }
    66% {
      content: '..';
    }
    100% {
      content: '...';
    }
  }

  .dots::after {
    content: '';
    animation: blink 1s steps(4, end) infinite;
  }

  // Pages
  // Premium features
  .botfoundry-pill-container {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 16px;
    margin-bottom: 16px;
    .botfoundry-pill {
      padding: 4px 10px;
      border-radius: 12px;
      background-color: vars.$primary-color;
      color: #fff;
      font-size: 0.75rem;
      display: flex;
      align-items: center;
      gap: 4px;
      .botfoundry-pill-icon {
        font-size: 0.75rem;
      }
      &:hover {
        cursor: pointer;
        background-color: vars.$primary-color-hover;
        color: #fff;
      }
    }
  }

  // Activate premium
  .stripe-checkout,
  .stripe-success {
    section {
      background: #f2f2f2;
      display: flex;
      flex-direction: column;
      width: 400px;
      height: 112px;
      border-radius: 6px;
      justify-content: space-between;
      margin: 10px;

      #checkout-and-portal-button {
        height: 36px;
        background: #556cd6;
        color: white;
        width: 100%;
        font-size: 14px;
        border: 0;
        font-weight: 500;
        cursor: pointer;
        letter-spacing: 0.6;
        border-radius: 0 0 6px 6px;
        transition: all 0.2sease;
        box-shadow: 0px 4px 5.5px 0px rgba(0, 0, 0, 0.07);
      }
      .product {
        display: flex;
      }
      .description {
        display: flex;
        flex-direction: column;
        justify-content: center;
      }
      svg {
        border-radius: 6px;
        margin: 10px;
        width: 54px;
        height: 57px;
      }
      h5 {
        opacity: 0.5;
      }
      h3,
      h5 {
        font-style: normal;
        font-weight: 500;
        font-size: 14px;
        line-height: 20px;
        letter-spacing: -0.154px;
        color: #242d60;
        margin: 0;
      }
    }
    .product {
      display: flex;
    }
  }
  .premium-list {
    gap: 8px;
    display: flex;
    flex-direction: column;
    font-size: 14px;
  }

  .premium-features {
    background: #f2f2f2;
    border-radius: 12px;
    padding: 16px;

    &.disabled {
      input {
        pointer-events: none;
        opacity: 0.5;
      }
      div {
        pointer-events: none;
        opacity: 0.8;
      }
    }
  }

  // Utils
  .disabled {
    pointer-events: none;
    opacity: 0.5;
  }
}
