@use "../../../../../styles/abstracts/variables" as *;

.confirm__modal {
  position: fixed;

  inset: 0;

  z-index: 9999;

  display: flex;

  justify-content: center;
  align-items: center;

  padding: 1.5rem;

  overflow-y: auto;

  background: rgba(0, 0, 0, 0.78);

  backdrop-filter: blur(12px);

  scrollbar-width: none;

  -ms-overflow-style: none;

  &::-webkit-scrollbar {
    display: none;
  }

  &__content {
    width: 100%;

    max-width: 500px;

    position: relative;

    border-radius: 24px;

    background: linear-gradient(
      180deg,
      rgba(28, 28, 30, 0.98),
      rgba(18, 18, 20, 0.98)
    );

    border: 1px solid rgba(
      255,
      255,
      255,
      0.06
    );

    box-shadow:
      0 25px 80px rgba(0, 0, 0, 0.55);

    overflow: hidden;

    animation: modalIn 0.25s ease;
  }

  &__content--close {
    position: absolute;

    top: 1rem;
    right: 1rem;

    width: 36px;
    height: 36px;

    display: flex;
    align-items: center;
    justify-content: center;

    border-radius: 50%;

    cursor: pointer;

    background: rgba(
      255,
      255,
      255,
      0.05
    );

    border: 1px solid rgba(
      255,
      255,
      255,
      0.05
    );

    color: rgba(
      255,
      255,
      255,
      0.7
    );

    font-size: 0.75rem;

    transition: all 0.2s ease;

    &:hover {
      background: rgba(
        239,
        68,
        68,
        0.12
      );

      border-color: rgba(
        239,
        68,
        68,
        0.2
      );

      color: #ef4444;
    }
  }

  &__content--details {
    padding: 2rem;
  }

  &__content--details--header {
    margin-bottom: 1.5rem;
  }

  &__content--details--header--helper {
    display: inline-flex;

    align-items: center;

    height: 32px;

    padding: 0 0.9rem;

    border-radius: 999px;

    margin-bottom: 1rem;

    background: rgba(
      247,
      147,
      24,
      0.1
    );

    border: 1px solid rgba(
      247,
      147,
      24,
      0.15
    );

    color: #f79318;

    font-size: 0.72rem;

    font-weight: 600;

    letter-spacing: 0.02em;
  }

  &__content--details--header h2 {
    margin: 0;

    color: #fff;

    font-size: 1rem;

    font-weight: 600;

    letter-spacing: -0.02em;
  }

  &__content--details--header p {
    margin-top: 0.75rem;

    color: rgba(
      255,
      255,
      255,
      0.65
    );

    font-size: 0.85rem;
    font-weight: 400;
    line-height: 1.8;
  }

  form {
    display: flex;

    flex-direction: column;

    gap: 1.25rem;
  }

  form label {
    display: block;

    margin-bottom: 0.55rem;

    color: rgba(
      255,
      255,
      255,
      0.8
    );

    font-size: 0.78rem;

    font-weight: 500;
  }

  form input,
  form select,
  form textarea {
    width: 100%;

    background: rgba(
      255,
      255,
      255,
      0.03
    );

    border: 1px solid rgba(
      255,
      255,
      255,
      0.08
    );

    border-radius: 14px;

    color: #fff;

    font-size: 0.85rem;

    padding: 0.7rem 1rem !important;

    transition: all 0.2s ease;

    outline: none;

    &:focus {
      border-color: rgba(
        247,
        147,
        24,
        0.25
      );

      box-shadow:
        0 0 0 4px rgba(
          247,
          147,
          24,
          0.08
        );
    }

    &::placeholder {
      color: rgba(
        255,
        255,
        255,
        0.4
      );
    }
  }

  form select {
    height: 46px;

    cursor: pointer;
  }

  form textarea {
    min-height: 100px;

    resize: vertical;
  }

  form button {
    height: 46px;

    margin-top: 0.5rem;

    border: none;

    border-radius: 14px;

    background: #f79318;

    color: #0f0f0f;

    font-size: 0.85rem;

    font-weight: 600;

    cursor: pointer;

    transition: all 0.2s ease;

    &:hover:not(:disabled) {
      transform: translateY(-1px);

      background: #ff9d2d;
    }

    &:disabled {
      opacity: 0.6;

      cursor: not-allowed;
    }
  }
}

@keyframes modalIn {
  from {
    opacity: 0;

    transform:
      translateY(12px)
      scale(0.97);
  }

  to {
    opacity: 1;

    transform:
      translateY(0)
      scale(1);
  }
}

@media (max-width: 768px) {
  .confirm__modal {
    padding: 1rem;

    &__content {
      max-width: 100%;
    }

    &__content--details {
      padding: 1.4rem;
    }

    &__content--details--header h2 {
      font-size: 1.05rem;
    }

    &__content--details--header p {
      font-size: 0.82rem;
    }
  }
}