/* styles.css */

/* EDIT COLOR SCHEME BELOW TO YOUR LIKING */

:root {
  --color-1: rgb(33, 33, 40);
  --color-2: rgb(74, 75, 82);
  --color-3: rgb(94, 95, 102);
  --color-4: rgb(54, 55, 62);
  --color-5: rgb(25, 27, 31);
  --color-6: rgb(13, 14, 16);
  --color-7: rgba(255, 255, 255, 0.1);
  --color-8: rgba(255, 255, 255, 0.2);
  --color-9: rgb(45, 47, 51);
}

/* EDIT COLOR SCHEME ABOVE TO YOUR LIKING */


/* Chrome, Safari, Edge, Opera */
input::-webkit-outer-spin-button,
input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

/* Firefox */
input[type="number"] {
  -moz-appearance: textfield;
}

/* width */
::-webkit-scrollbar {
  width: 10px;
}

/* Track */
::-webkit-scrollbar-track {
  background: var(--color-1);
}

/* Handle */
::-webkit-scrollbar-thumb {
  background: #888;
}

/* Handle on hover */
::-webkit-scrollbar-thumb:hover {
  background: #555;
}

#integrated-terminal {
  display: flex;
  justify-content: center;

}

#getPhantomBtn,
#connectBtn {
  font-weight: normal;
  width: 175px;
  height: 65px;
  border-radius: 0.75rem;
  background-color: var(--color-5);
}

#getPhantomBtn:hover,
#connectBtn:hover {
  background-color: var(--color-9);
}

#getPhantomBtn:active:focus-within,
#connectBtn:active:focus {
  padding: 2px 0px 0px 2px;
}

#getPhantomBtn > a {
  text-decoration: none;
}

#getPhantomBtn > a:visited {
  color: inherit;
  background-color: var(--color-5);
}

#connectBtn {
  display: none;
}

#swapSection {
  display: none;
  min-width: 350px;
  width: 400px;
  max-width: 98vw;
}

#swapInterface {
  background-color: rgba(0, 0, 0, 0.5);
  border-radius: 0.75rem;
  display: flex;
  flex-direction: column;
  gap: 7px;
}

#misc,
#miscLeft,
#miscRight {
  display: flex;
  position: relative;
}

#misc {
  justify-content: space-between;
  color: white;
  gap: 8px;
}

#miscLeft {
  justify-content: space-between;
  align-items: center;
  gap: 8px;
  font-size: 0.875rem;
  font-weight: bold;
}

#swapLogo {
  animation: rotate360 1s linear infinite;
  animation-fill-mode: forwards;
  animation-play-state: paused;
}

@keyframes rotate360 {
  from {
    transform: rotate(0deg);
  }
  to {
    transform: rotate(360deg);
  }
}

#miscRight {
  justify-content: space-between;
  align-items: center;
  font-size: 0.75rem;
  gap: 5px;
}

#halfBtn,
#maxBtn,
#slippageInput,
#slippageInputWrapper > span {
  background-color: transparent;
  font-weight: normal;
}

#halfBtn,
#maxBtn {
  font-size: 12px;
}

#halfBtn,
#maxBtn,
#slippageInputWrapper {
  color: var(--color-2);
}

#halfBtn,
#maxBtn,
#slippageInputWrapper,
#disconnectBtn {
  border: 1px solid var(--color-7);
  display: flex;
  justify-content: center;
  align-items: center;
  height: 25px;
}

#halfBtn,
#maxBtn {
  font-size: 10px;
  width: 28px;
  height: 25px;
}

#halfBtn,
#maxBtn,
#disconnectBtn {
  border-radius: 4px;
}

#disconnectBtn:active:focus,
#swapTokensBtn:active:focus {
  padding: 1px 0px 0px 1px;
}

#slippageInputWrapper {
  position: relative;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 0 3px;
  border-radius: 1rem;
}

#slippageInputWrapper:focus-within {
  border-color: var(--color-8);
}

#slippageInputWrapper {
  fill: var(--color-2);
}

.slippage-tooltip {
  visibility: hidden;
  width: 120px;
  background-color: #555;
  color: #fff;
  text-align: center;
  padding: 5px 0;
  border-radius: 6px;
  /* Position the tooltip text */
  position: absolute;
  z-index: 1;
  bottom: 125%;
  left: 50%;
  margin-left: -60px;
  /* Fade in tooltip */
  opacity: 0;
  transition: opacity 0.3s;
}

.slippage-tooltip::after {
  content: "";
  position: absolute;
  top: 100%;
  left: 50%;
  margin-left: -5px;
  border-width: 5px;
  border-style: solid;
  border-color: #555 transparent transparent transparent;
}

#slippageInputWrapper:hover .slippage-tooltip {
  transition: 0.15s linear;
  visibility: visible;
  opacity: 1;
}

#slippageInputWrapper:focus-within .slippage-tooltip {
  transition: 0.15s linear;
  visibility: hidden;
  opacity: 0;
}

#halfBtn:hover,
#maxBtn:hover,
#slippageInputWrapper:hover,
#disconnectBtn:hover,
#slippageInputWrapper:focus-within {
  transition: 0.15s linear;
  color: white;
}

#halfBtn:not(hover),
#maxBtn:not(hover),
#slippageInputWrapper:not(hover),
#slippageInputWrapper:not(focus-within) {
  transition: 0.15s linear;
}

#slippageInputWrapper:hover,
#slippageInputWrapper:focus-within {
  transition: 0.15s linear;
  fill: white;
}

#slippageInput {
  cursor: pointer;
  text-align: right;
  border: none;
  width: 40px;
}

#slippageInput:focus {
  outline: none;
  cursor: text;
}

#walletLogo {
  width: 16px;
  height: 16px;
}

#walletAddressWrapper {
  display: flex;
  margin-left: 5px;
  padding: 0px 10px 0px 5px;
  gap: 3px;
  justify-content: space-between;
  align-items: center;
  background-color: var(--color-5);
  border-radius: 1rem;
}

#walletAddressWrapper:hover #walletLogo,
#walletAddressWrapper:hover #walletAddressSpan {
  display: none;
  transition: 0.15s linear;
  cursor: pointer;
}

#walletAddressWrapper:hover #disconnectBtn {
  display: block;
}

#walletAddressWrapper:not(hover) {
  transition: 0.15s linear;
}

#disconnectBtn {
  display: none;
  width: 88.4px;
  background-color: var(--color-5);
  border-radius: 1rem;
}

.tokenLogo,
#swapLogo {
  width: 24px;
  height: 24px;
}

.tokenItem,
.tokenInput,
#swapBtn {
  font-weight: normal;
  font-size: 18px;
}

.tokenFieldBottomLeft,
.tokenFieldBottomRight,
#txDetailsField {
  font-weight: normal;
  font-size: 12px;
}

.tokenField {
  display: flex;
  flex-direction: column;
  gap: 10px;
  background-color: var(--color-1);
  border-radius: 0.75rem;
  padding: 20px 16px;
  width: 100%;
}

.tokenFieldTop {
  width: 100%;
  display: flex;
  justify-content: space-between;
}

.select2-dropdown {
  background-color: var(--color-1) !important;
  width: 200px !important;
  border: none !important;
  border-radius: 0.5rem !important;
}

.select2-selection__arrow {
  margin-top: 10px;
}

.select2-search__field {
  background-color: var(--color-1);
}

.select2-selection {
  border: 1px solid var(--color-4) !important;
  border-radius: 1rem !important;
  background-color: var(--color-4) !important;
}

.select2-results__option--selected {
  background-color: var(--color-1) !important;
}

.select2-results__option--highlighted {
  background-color: var(--color-4) !important;
}

.select2-selection:hover {
  border: 1px solid var(--color-2) !important;
  background-color: var(--color-2) !important;
  transition: 0.15s linear;
}

.select2-results__option:hover {
  background-color: var(--color-2) !important;
  transition: 0.15s linear;
}

.select2-selection:not(hover) {
  transition: 0.15s linear;
}

.select2-search,
.select2-results__message {
  font-weight: bold;
}

.select2-search__field {
  color: white;
  border: 1px solid var(--color-2) !important;
}

.select2-search__field:focus {
  outline: 1px solid var(--color-3);
}

#select2-tokenInMenu-container,
#select2-tokenOutMenu-container {
  padding: 0px;
}

#select2-tokenInMenu-container,
#select2-tokenOutMenu-container,
.select2-selection--single,
.selection {
  display: inline-flex !important;
}

.select2-selection,
#select2-tokenInMenu-container,
#select2-tokenOutMenu-container,
.tokenItem {
  height: 48px !important;
}

.tokenItem {
  color: magenta;
  -webkit-text-stroke-color: magenta;
  text-shadow: 0 1px 8px #ff00b2;
  display: inline-flex;
  justify-content: center;
  align-items: center;
  gap: 10px;
  padding-left: 15px;
  padding-right: 25px;
}

.tokenInput {
  color: white;
  text-align: right;
  border: none;
  background-color: transparent;
  width: 150px;
  min-width: 100px;
}

.tokenInput:focus {
  outline: none;
}

.tokenFieldBottom {
  width: 100%;
  display: flex;
  justify-content: space-between;
}

#swapTokensBtn {
  margin: 0 auto;
  width: 40px;
  height: 40.11px;
  background-color: black;
  border: 3px solid var(--color-4);
  border-radius: 20px;
  display: inline-flex;
  justify-content: center;
  align-items: center;
}

#swapTokensBtn:hover {
  color: white;
  background-color: var(--color-5);
  transition: 0.15s linear;
}

#swapTokensBtn:not(hover) {
  transition: 0.15s linear;
}

.animation-up {
  animation: moveUp 0.15s linear;
}

.animation-down {
  animation: moveDown 0.15s linear;
}

@keyframes moveUp {
  0% {
    transform: translateY(200px);
  }
  100% {
    transform: translateY(0);
  }
}

@keyframes moveDown {
  0% {
    transform: translateY(-200px);
  }
  100% {
    transform: translateY(0);
  }
}

#getPhantomBtn > a,
#connectBtn > span,
#swapBtn > span {
  background-image: linear-gradient(to right, #9945ff, #14f195);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  animation: rainbow-animation 1750s linear infinite;
}

#swapBtn {
  height: 58px;
  border-radius: 0.75rem;
  background-color: var(--color-5);
}

#swapBtn:hover {
  background-color: var(--color-9);
}

#swapBtn:active:focus {
  padding: 2px 0px 0px 2px;
}

#swapBtn:disabled {
  background-color: var(--color-6);
}

@keyframes rainbow-animation {
  to {
    background-position: 4500vh;
  }
}

#txDetailsField {
  text-align: center;
  background-color: rgba(0, 0, 0, 0.5);
  margin-top: 5px;
  border: 1px solid var(--color-7);
  border-radius: 0.75rem;
  font-size: 14px;
}
