/* Add padding and alignment for flag icons and text */
select option 
{
	display: flex;
	align-items: center;
	gap: 10px;
	font-size: 16px;
}

select 
{
	padding-left: 5px;
}

.input-field>label 
{
	color: #6c6c6c;
    position: relative;
    top: -6.8em;
    font-size: 0.8em;
}

.speaker_icon 
{
    border: solid 1px #000000 !important;
    font-size: 2.5em;
    padding: 0em 0.1em;
    margin-left: 0.1em;
    border-radius: 0.1em;
    vertical-align: text-bottom;
    transition: 0.25s;
    background-color: #ffffff;
}

.speaker_icon:hover 
{
    background-color: #35a77a;
    color: white;
    scale: 1.1;
    transition: 0.25s;
    cursor: pointer;
}

.dropdown-content 
{
	min-width: fit-content;
	position: fixed;
	top: 50% !important;
	left: 50% !important;
	transform: translate(-50%, -50%) !important;
}

.dropdown-content li>a, .dropdown-content li>span 
{
	color: #000000;
}

/* Custom style for flags inside the dropdown */
.flag 
{
	width: 30px;
	height: 18px;
	margin-right: 10px;
	display: inline-block;
	background-size: cover;
	border: 1px solid #ddd;
}

.flag_row 
{
	display: flex !important;
	align-items: center !important;
	gap: 0.1em;
	padding-bottom: 1em !important;
}

.flag-en { background-image: url('https://flagcdn.com/w40/gb.png'); height: 21px !important; }
.flag-it { background-image: url('https://flagcdn.com/w40/it.png'); height: 27px !important; }
.flag-fr { background-image: url('https://flagcdn.com/w40/fr.png'); height: 27px !important; }
.flag-ar { background-image: url('https://flagcdn.com/w40/sa.png'); height: 28px !important; }
.flag-gr { background-image: url('https://flagcdn.com/w40/gr.png'); height: 28px !important; }
.flag-de { background-image: url('https://flagcdn.com/w40/de.png'); height: 27px !important; }
.flag-es { background-image: url('https://flagcdn.com/w40/es.png'); height: 28px !important; }
.flag-ua { background-image: url('https://flagcdn.com/w40/ua.png'); height: 28px !important; }

.col.l6.adapt_length 
{
	width: fit-content !important;
	margin-left: auto;
}

#Lang_Dict_1 
{
    display: flex;
    font-size: 2em;
    padding: 0.2em 0.4em;
    border-radius: 0.2em;
    align-items: center;
    width: fit-content;
    color: black;
    transition: 0.5s;
    background-color: white;
}

#Lang_Dict_1:hover 
{
	background-color: #aadfb8;
	transition: 0.5s;
}

#Lang_Dict_2
{
	display: flex;
    font-size: 2em;
    padding: 0.2em 0.4em;
    border-radius: 0.2em;
    align-items: center;
    width: fit-content;
    color: black;
    transition: 0.5s;
    background-color: white;
}

#Lang_Dict_2:hover 
{
	background-color: #aadfb8;
	transition: 0.5s;
}

#Lang_Duolingo 
{
	display: flex;
    font-size: 2em;
    padding: 0.2em 0.4em;
    border-radius: 0.2em;
    align-items: center;
    width: fit-content;
    color: black;
    transition: 0.25s;
    background-color: white;
}

#Lang_Duolingo:hover 
{
	background-color: #35a77a;
	color: #ffffff;
	scale: 1.1;
	transition: 0.25s;
}

.duolingo-trigger 
{
	display: block;
	width: 0;
}



.Duolingo_Language 
{
	display: flex;
	gap: 1em;
    justify-content: flex-start;
}

#input_word 
{
	margin-top: 4.5em;
	margin-bottom: 0;
}

.dictionary
{
	padding-top: 0em;
}

.container
{
	padding: 2em;
	background-color: #e7e9e8;
	margin-top: 1em;
	border-radius: 0.6em;
	margin-bottom: 4em;
}

h3
{
    font-size: 2.3em;
    line-height: 100%;
    margin: 0.2em 0 0.2em 0;
    color: #595959;
    font-weight: 600;
}

.Duolingo_Title
{
    display: flex;
    align-items: center;
}

.Duolingo_Enonce 
{
    color: #000000;
    font-weight: 600;
    font-style: italic;
    text-decoration: underline;
}

input[type=text]:not(.browser-default):focus:not([readonly])
{
	border-bottom: 1px solid #009426;
	box-shadow: 0 1px 0 0 #009426;
}
input[type=text]:not(.browser-default):focus:not([readonly])+label
{
	color: #009426;
}

.duolingo_img 
{
	max-width: 100%;
	cursor: pointer;
	border: 1px solid grey;
	transition: 0.1s;
}

.duolingo_img:hover
{
	filter: brightness(1.1);
	transition: 0.1s;
}

#Duolingo_Word
{
	background: #f5e512;
	color: #000000;
	line-height: 2em;
}

#Duolingo_Sound
{
	font-size: 0.5em;
	vertical-align: middle;
}

.C2
{
	margin-bottom: 2em;
	padding: 1.5em;
}

div#toast-container 
{
	position: fixed;
	display: flex;
	width: 100%;
	top: 10%;
	flex-direction: column;
	align-items: center !important;
}

.toast
{
	justify-content: center;
}

.img_size 
{
	height: 350px;
	display: flex;
	align-items: center;
}

.filters_title 
{
	color: #000000;
	font-weight: 800;
	font-style: italic;
	text-decoration: underline;
	margin-bottom: 1em;
}

span.filters 
{
	color: #808080;
	font-weight: 500;
}

/* Default desktop view */
.autocomplete-content li 
{
	display: flex;
	align-items: center;
	flex-wrap: nowrap;
	flex-direction: row; /* Word and filters inline */
}

.autocomplete-content
{
	overflow-x: hidden;
	height: auto !important;
	max-height: 50% !important;
}

/* Word styling */
.autocomplete-content li .word-text 
{
	font-weight: bold;
	color: black;
	margin-right: 0;        /* Remove margin */
	/*margin-bottom: 2px;      Small margin between word and filters */
	white-space: nowrap;
	width: 100%;            /* Occupies full width, aligns left */
}

/* Filter badges styling */
.autocomplete-content li .filter-text 
{
	font-size: 0.9em;
	color: white;
	background-color: #ff9800;
	padding: 3px 8px;
	border-radius: 5px;
	margin-right: 3px;
	margin-top: 2px; 
	margin-bottom: 2px;
	white-space: nowrap;
}

#autocomplete-input 
{
    background-color: #ffffff;
    border-bottom: none;
    border-radius: 0.4em;
}

#word-input-2
{
	background-color: #ffffff;
    border-bottom: none;
    border-radius: 0.4em;
}


/* Wrapper for filters */
.filters-wrapper 
{
	display: flex;
	flex-wrap: wrap;
	width: 100%;              /* Match the width of parent */
	margin-left: 0;           /* No indent */
	padding-left: 0;          /* Remove left padding */
}

[type="checkbox"]:checked+span:not(.lever):before 
{
	top: -4px;
	left: -5px;
	width: 12px;
	height: 22px;
	border-top: 2px solid transparent;
	border-left: 2px solid transparent;
	border-right: 3px solid #aa1714;
    border-bottom: 3px solid #aa1714;
	-webkit-transform: rotate(40deg);
	transform: rotate(40deg);
	-webkit-backface-visibility: hidden;
	backface-visibility: hidden;
	-webkit-transform-origin: 100% 100%;
	transform-origin: 100% 100%;
}


@keyframes goodAnswerAnimation-glow {
  0% {
	left: -110%;
  }
  50% {
	left: 50%; /* Midway through */
  }
  100% {
	left: 110%; /* End */
  }
}

.animation_green 
{
	color: #ffffff !important; 
	background: linear-gradient(to bottom, #65d281, #00691b);
	font-size: 2em;
	font-weight: bold;
	overflow: hidden;
}

.animation_green::before {
  content: "";
  position: absolute;
  top: 0;
  left: -108%;
  width: 100%;
  height: 100%;
  background: linear-gradient(
	120deg,
	transparent,
	rgba(255, 255, 255, 0.6), /* white glow */
	transparent
  );
  transform: skewX(-20deg);
  animation: goodAnswerAnimation-glow 0.5s ease-in-out;
}

@keyframes badAnswerAnimation 
{
	0% 
	{
		background: linear-gradient(to bottom, #f66d6d, #8b0000);
		transform: translateX(0);
	}
	10% 
	{
		transform: translateX(-6px);
	}
	20% 
	{
		transform: translateX(6px);
	}
	30% 
	{
		transform: translateX(-6px);
	}
	40% 
	{
		transform: translateX(6px);
	}
	50% 
	{
		transform: translateX(-6px);
	}
	60% 
	{
		transform: translateX(6px);
	}
	70% 
	{
		transform: translateX(-6px);
	}
	80% 
	{
		transform: translateX(6px);
	}
	90% 
	{
		transform: translateX(-6px);
	}
	100%
	{
		background: linear-gradient(to bottom, #f66d6d, #8b0000);
		transform: translateX(0);
	}
}

.animation_red 
{
	background: linear-gradient(to bottom, #f66d6d, #8b0000);
	animation: badAnswerAnimation 0.5s ease-in-out;
	color: white;
	font-weight: bold;
	font-size: 2em;
}



@media screen and (min-width : 100px) and (max-width : 600px) 
{
	h4
	{
		font-size: 1.4em;
	}
	.C1
	{
		margin-top: 6em;
	}
	.C2 
	{
		margin-bottom: 2em;
	}
	div#toast-container 
	{
		position: fixed;
		display: flex;
		width: 100%;
		padding: 1em;
		top: 0%;
		flex-direction: column;
		align-items: center;
	}
	.img_size 
	{
		height: 180px;
		display: flex;
		align-items: center;
	}

	.autocomplete-content li 
	{
		flex-direction: column;
		align-items: flex-start;
		margin-bottom: 0px;
	}

	.autocomplete-content li .word-text 
	{
		margin-bottom: 0px; /* Space between word and filters */
		padding: 10px 10px 0px 16px;
	}

	.filters-wrapper 
	{
		display: flex;
		flex-wrap: wrap;
		width: 100%;
		margin-left: 1em;
	}

	.autocomplete-content li .filter-text 
	{
		margin-bottom: 5px;
	}

	h4.Duolingo_Title 
	{
		line-height: 2em;
	}
	.Duolingo_Language 
	{
		display: flex;
		gap: 0em;
		flex-direction: column;
		margin-bottom: 1em;
	}
	.container 
	{
		margin-top: 2em;
	}
}

@media screen and (min-width : 601px) and (max-width : 992px) 
{
	h4
	{
		font-size: 1.4em;
	}
	.C1
	{
		margin-top: 6em;
	}
	.C2 
	{
		margin-bottom: 2em;
	}
	div#toast-container 
	{
		position: fixed;
		display: flex;
		width: 100%;
		top: 5%;
		flex-direction: column;
		align-items: center;
	}
	.img_size 
	{
		height: 250px;
		display: flex;
		align-items: center;
	}

	.autocomplete-content li 
	{
		flex-direction: column;
		align-items: flex-start;
		margin-bottom: 0px;
	}

	.autocomplete-content li .word-text 
	{
		margin-bottom: 0px; /* Space between word and filters */
		padding: 20px 10px 0px 16px;
	}

	.filters-wrapper 
	{
		display: flex;
		flex-wrap: wrap;
		width: 100%;
		margin-left: 1em;
	}

	.autocomplete-content li .filter-text 
	{
		margin-bottom: 5px;
	}

	h4.Duolingo_Title 
	{
		line-height: 2em;
	}
	.container 
	{
		margin-top: 2em;
	}
}