* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Poppins';
    background: linear-gradient(135deg, #282828, #292c32);
    background-color: #1a1b1e;
    color: white;
    display: flex;
    flex-direction: column;
    min-height: 100vh;
}

nav {
    background-color: #2c2f36;
    padding: 2px 10px;
    display: flex;
    justify-content: center;
    align-items: center;
    flex-wrap: wrap;
    flex-direction: row;
}

.nav-center {
	display: flex;
  flex-direction: column;
  align-items: center;
}

nav .logo {
    font-size: 32px;
    display:table;
    overflow-wrap: anywhere;
    cursor: default;
}

nav .logo_text1 {
	display:table-cell;
	vertical-align:middle;
	font-weight: bold;
	color: #2172e5;
}

nav .logo_text2 {
	display:table-cell;
	vertical-align:middle;
	color: #ffdd55;
}

nav ul {
    list-style-type: none;
    display: flex;
    flex-wrap: wrap;
    gap: 20px;
}

nav ul li a {
    color: white;
    text-decoration: none;
    font-size: 16px;
}

nav ul li a:hover {
    color: #2172e5;
}

a {
    color: white;
    text-decoration: none;
}

a:hover {
    color: #2172e5;
}

.container {
    text-align: center;
    flex-grow: 1;
    display: flex;
    flex-direction: column;
    justify-content: center;
    align-items: center;
}

h1 {
    margin-bottom: 20px;
    color: #ffffff;
}

.swap-box {
    display: flex;
    justify-content: space-between;
    align-items: center;
    border-radius: 12px;
    width: 100%;
    flex-direction: column;
}

.all-box {
    border-radius: 12px;
    justify-content: space-between;
    max-width: 95vw;
    
}

#options {
	display: flex;
	align-items: center;
	/*padding-bottom: 5px;*/
	justify-content: flex-end;
}

.token-selection, .amount-input {
    display: flex;
    flex-direction: column;
    align-items: center;
    
}

.amount-input {
	margin: 20px;
}

.token-selection label, .amount-input label {
    font-size: 14px;
}


.scrollable-list ul {
		max-height: 65vh;
    overflow-y: scroll;
}

.token-list {
    list-style-type: none;
    padding: 0;
    margin: 0;
    width: 100%;
    background-color: #1f2125;
}

.token-list li {
    padding: 10px;
    text-align: left;
    cursor: pointer;
    font-size: 20px;
}

.token-list li:hover {
    background-color: #2172e5;
    color: white;
}

.amount-input input {
    background-color: #00000000;
    color: white;
    border: none;
    padding: 10px;
    border-radius: 8px;
    width: 100%;
    min-width: 100px;
    font-size: 16px;
    text-align: right;
}

.tok-input {
    margin-top: 5px;
    background-color: #1f2125;
    color: white;
    border: none;
    padding: 5px;
    border-radius: 8px;
    width: 150px;
    min-width: 120px;
    font-size: 16px;
    text-align: left;
}


.opt-input {
    margin-top: 5px;
    background-color: #1f2125;
    color: white;
    border: none;
    padding: 5px;
    border-radius: 8px;
    font-size: 16px;
    text-align: left;
    width: 35pt;
    text-align: center;
}

.tok-input-btn {
    background-color: #1f2125;
    border: none;
    padding: 5px;
    margin: 0;
    border-radius: 8px;
    font-size: 16px;
    text-align: right;
    cursor: pointer;
}

.arrow {
    font-size: 32px;
    color: #ffffff;
    margin: 10px 20px 20px;
}

.swap-button {
    margin-top: 20px;
    margin-bottom: 20px;
}

button {
    background-color: #2172e5;
    color: white;
    padding: 0px 10px  0px 10px;
    text-align: center;
    border: none;
    border-radius: 12px;
    font-size: 25px;
    cursor: pointer;
}

button:active {
  transform: scale(0.95);
}

#options-btn {
	margin: 10px;
	margin-right: 0px;
}



.swap-button button {
    background-color: #2172e5;
    color: white;
    padding: 15px 40px;
    border: none;
    border-radius: 12px;
    font-size: 16px;
    cursor: pointer;
}

.swap-button button:hover {
    background-color: #1b5bbf;
}

footer {
    background-color: #2c2f36;
    padding: 10px;
    text-align: center;
    color: #ffffff;
    font-size: 14px;
    position: relative;
    bottom: 0;
    width: 100%;
}

input::-webkit-outer-spin-button,
input::-webkit-inner-spin-button {
  -webkit-appearance: none;
  margin: 0;
}

input[type=number] {
  -moz-appearance: textfield;
}

button:disabled,
button[disabled]{
  border: 1px solid #999999;
  background-color: #cccccc;
  color: #666666;
}

textarea:focus, input:focus{
    outline: none;
}


.amount-element {
	background-color: #1f2125;
	border-radius: 8px;
	width: 100%;
}

.amount-header {
	margin: 5px;
	text-align: left;
	color: #ffffff88;
}

.amount-field {
    display: flex;
    flex-direction: row;
    align-items: center;
}

.amount-field input {
    background-color: #00000000;
    color: white;
    border: none;
    padding: 10px;
    font-size: 25px;
    text-align: right;
    width: 100%;
}

.amount-field button {
    background-color: #00000000;
    font-weight: bold;
}

.amount-footer {
    display:flex;
    justify-content: space-between;
    padding: 0 15px;
}

.arrow_ {
  border: solid white;
  border-width: 0 3px 3px 0;
  display: inline-block;
  padding: 3px;
  margin-bottom: 5px;
  margin-left: 3px;
}

.down {
  transform: rotate(45deg);
  -webkit-transform: rotate(45deg);
}

button {
    font-family: inherit;
}

input {
    font-family: inherit;
}

.wallet-element {
	display: flex;
	position: absolute;
	right: 10px;
	background-color: #2172e5;
	padding: 10px;
	border-radius: 5px
}

.token-list-el {
	display: flex;
	align-items: center;
	cursor:pointer;
}

.token-list-el:hover {
	background-color: #1f1f1f;
}

@media only screen and (max-width: 768px) {
  .wallet-element {
		position: static;
  }
  
  nav ul {
		flex-direction: column;
		align-items: center;
		margin-bottom: 20px;
  }
}

.popup-overlay {
	display: none;
	position: fixed;
	top: 0;
	left: 0;
	width: 100%;
	height: 100%;
	background-color: rgba(0, 0, 0, 0.7);
	z-index: 1000;
}

.popup-window {
	position: fixed;
	top: 50%;
	left: 50%;
	transform: translate(-50%, -50%); /* Center the popup */
	background-color: #2c2f36;
	padding: 20px;
	border-radius: 10px;
	box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
	width: min(80vw, 600px);
	display: flex;
	flex-direction: column;
	justify-content: center;
	z-index: 1001; /* Ensures the popup is above the overlay */
}
        
.token-list-el img {
	height:50px;
	margin-left: 5px;
}

.option {
	display: flex;
	justify-content: space-between;
	margin: 5px;
	font-size: 20px;
	align-items: baseline;
}


.option-field {
	background-color: #1f2125;
	border-radius: 8px;
	font-size: 15px;
	width: max(10vw, 120px);
	
	display: flex;
	flex-direction: row;
	align-items: center;     
}

.option-field input {
    background-color: #00000000;
    color: white;
    border: none;
    padding: 10px;
    font-size: 20px;
    text-align: right;
    width: 100%;
}

.option-field button {
    background-color: #00000000;
    font-weight: bold;
    white-space: nowrap;
    color: #ffffff88;
}


.spinner {
	width: 75px;
	height: 75px;
	border: 8px solid #2172e5;
	border-bottom-color: transparent;
	border-radius: 50%;
	display: inline-block;
	box-sizing: border-box;
	animation: spinner_rotation 1s linear infinite;
}

@keyframes spinner_rotation {
	0% { transform: rotate(0deg); }
	100% { transform: rotate(360deg); }
} 
    
