/*** 1 ROOT */
:root {
	--font-family: "Montserrat", sans-serif;
	--numbers-font-family: "Azeret Mono", sans-serif;
	--heading-font-family: 'Lilita One',-apple-system,system-ui,BlinkMacSystemFont,"Segoe UI","Helvetica Neue",Arial,sans-serif;
	--tile-font-family: 'Fredoka',sans-serif;
	--scrabble-board-width:555px;
	--scrabble-window-width:595px;
	--scrabble-window-offset:300px;
	--scrabble-tile-width:37px;
	--scrabble-played-tile-width:35px;
	--scrabble-dragging-tile-width: 80px;
	--scrabble-rack-height: 80px;
	--scrabble-rack-tile-width: 60px;
	--scrabble-font-color:#131128;
	--scrabble-window-tile-font-size:31px;
	--scrabble-tile-played-color:#ffcd62;
	--scrabble-tile-played-color-light:#ffe6c5;
	--scrabble-tile-played-color-dark:#5b371f;
	--scrabble-tile-played-color-light-dark:#bb7f45;
	--scrabble-board-title-font-size:18px;
	--scrabble-color: #6253be;
	/*--scrabble-board-color: #ea7e4f;*/
	--scrabble-board-color: #ffb7b1;
	--scrabble-board-color-light: #eebbff;
	/*--scrabble-board-tile-color: #3b1181;*/
	--scrabble-board-tile-color: #fffcf8;
	--scrabble-rack-color: #e47f55;
	--scrabble-rack-color-dark: #472715;
	--scrabble-rack-color-dark-light: #7c4120;
	--scrabble-rack-color-light: #fff4cf;
	--scrabble-rack-color-empty: #fff8e9;
	
	--scrabble-controller-height: 150px;
	--scrabble-info-height: 100px;
	--scrabble-bars-difference: 0px;
	
	--primary-color-light: #2ad9ff;	
	--accent-color1: #961bff;
	--accent-color1-black: #670ec2;
	--accent-color1-light: #c27aff;
	--scrabble-tp-color: #ff1324;
	/*--accent-color1-light: color-mix(in srgb, var(--accent-color1) 50%, white 50%);*/
	--gray-shadow: 370deg 35% 70%;
	--blue-shadow: 209deg 83% 20%;
	--white2: rgba(255,255,255, 0.2);
	--white3: rgba(255,255,255, 0.4);
	--white4: rgba(255,255,255, 0.8);
	--gray1: #eff3f8;
	--gray2: #e2e9f1;
	--gray3: #d6dde7;
	--gray4: #c4cedb;
	--gray5: #b0bbca;
	--gray6: #747e8a;
	--gray7: #464c54;
	--background-dark: hsl(var(--blue-shadow)/0.8);
	--game-background-color: #8e7bff;

	--accent-color1: #FF4FB3;
	--accent-color1-white: color-mix(in srgb, var(--accent-color1) 10%, white 90%);
	--accent-color1-light: color-mix(in srgb, var(--accent-color1) 50%, white 50%);
	--accent-color1-black: color-mix(in srgb, var(--accent-color1) 80%, black 20%);
	
	--accent-color2: #fff275;
	--accent-color2-white: color-mix(in srgb, var(--accent-color2) 20%, white 80%);
	--accent-color2-light: color-mix(in srgb, var(--accent-color2) 50%, white 50%);
	--accent-color2-black: color-mix(in srgb, var(--accent-color2) 30%, black 70%);
	--accent-color2-medium: color-mix(in srgb, var(--accent-color2) 70%, black 30%);
	
	--invalid-word-color: #ff3030;
	--valid-word-color: #30ff35;
	
	--box-shadow-range: 0 -3px 0 0 hsl(var(--gray-shadow)/0.5), 0 0 10px 12px #fff9e6, 0 12px 7px 0 var(--scrabble-rack-color);
	
	--loader-anim-delay: 1.2s;
	
	--window-padding-bottom: 120px;

	--text-shadow-wood: 0px 2px 2px rgba(252, 186, 127, 0.9);	
}

/*** 2 Globals */
*, *:after, *:before, *:focus, ::after, ::before {
	margin:0;
	padding:0;
    box-sizing: border-box;
	-webkit-user-select: none; /* Safari */
	-moz-user-select: none; /* Firefox */
	-ms-user-select: none; /* Internet Explorer/Edge */
	user-select: none; /* Otros navegadores */
	outline: none;
	-webkit-tap-highlight-color: transparent;
}

/*::selection {
  background: transparent;
}
::placeholder{
	color:var(--scrabble-font-color);
	opacity:0.5;
}*/

::placeholder{
	color:var(--scrabble-font-color);
	opacity:0.5
}
::-moz-selection{
	color:white;
	background:var(--scrabble-color)
}
::selection{
	color:white;
	background:var(--scrabble-color)
}

particle {
  position: fixed;
  top: 0;
  left: 0;
  opacity: 0;
  pointer-events: none;
  background-repeat: no-repeat;
  background-size: contain;
  /*font-family: var(--noto-emoji);*/
  z-index: 15
}

h1, h2, h3, h4 {
	font-family: var(--heading-font-family);
	font-weight: normal;
}

.title2 {
	font-family: var(--heading-font-family);
	font-size: 28px;
	font-weight: normal;
	margin-bottom: 15px;
	text-shadow: var(--text-shadow-wood);
}

/*** 3 Body */
html, body {
	width:100%;
	min-width:100%;
	height:100%;	
	min-height:100%;	
	overflow:hidden;
}

body {
	display:flex;
	flex-direction: column;
	justify-content:center;
	align-items:center;
    font-family: var(--font-family);
    line-height: 1;
    font-weight: 400;
	color: var(--scrabble-font-color);
    position:relative;
	/*background-color: var(--scrabble-color);*/	
	/*touch-action: none;*/
	/*overflow: auto;*/
}

::-webkit-scrollbar{width:4px;background-color:transparent}
::-webkit-scrollbar-track-piece{background-color:transparent}
::-webkit-scrollbar-thumb{background-color:#f7c45b;/*border-radius:10px;*/background-clip:padding-box}

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

/*** SWITCH */
input[type=checkbox] {
	-webkit-appearance: none;
	-moz-appearance: none;
	appearance: none;
	-webkit-tap-highlight-color: transparent;
}
input[type=checkbox]:focus {
	outline: 0;
}

.toggle {
	height: 16px;
	width: 44px;
	border-radius: 16px;
	display: inline-block;
	position: relative;
	margin: 0;
	/*box-shadow:0 -3px 0 0 hsl(var(--gray-shadow)/0.5), 0 0 6px 8px white, 0 8px 6px 0 hsl(var(--gray-shadow)/0.4);*/
	box-shadow:inset 0 1px 4px 2px rgba(0, 0, 0, 0.2), 0 0 0 4px var(--scrabble-rack-color-light), 0 0 0 5px white, 0 2px 3px 5px rgba(0, 0, 0, 0.4);
	background-color: var(--gray2);
	transition: all 0.2s ease;
	z-index: 30;
	cursor:pointer;
}
.toggle::after {
	content: "";
	position: absolute;
	top: -10px;
	left: -6px;
	width: 34px;
	height: 34px;
	border-radius: 50%;
	background-image:linear-gradient(var(--gray2) -50%, var(--gray5) 100%);
	box-shadow:inset 0 0 0 3px var(--gray3), 0 3px 0 0 var(--gray6);
	transition: all 0.2s cubic-bezier(0.9, 0.6, 0.75, 1.35);
	z-index: 31;
}
.toggle:checked {
	border-color: var(--accent-color2);  
}
.toggle:checked::after {
	transform:translateX(24px);
	background-image:linear-gradient(white -50%, var(--accent-color2) 100%);
	box-shadow:inset 0 0 0 3px rgba(255, 255, 255, 0.4), 0 3px 0 0 var(--accent-color2-medium), 0 0 20px 0 var(--accent-color2-light);
}

.options-line {
	width:100%;
	display:flex;
	justify-content:space-between;
	align-items:center;
	margin:0 0 30px;
}

.options-line .label{
	display:inline-block;
	width:260px;
	margin: 0 !important;
}

.iconof {font-family: "fontello";font-style: normal;font-weight:normal;font-size:inherit;speak: never;display: inline-block;text-decoration: inherit;width: 1em;margin-right: .2em;text-align: center;  /* For safety - reset parent styles, that can break glyph codes*/ font-variant: normal;text-transform: none; /* fix buttons height, for twitter bootstrap */ /*line-height: 100%;*/
  /* Animation center compensation - margins should be symmetric */ /* remove if not needed */ margin-left: .2em; /* You can be more comfortable with increased icons size */ /* font-size: 120%; */ /* Font smoothing. That was taken from TWBS */ -webkit-font-smoothing: antialiased; -moz-osx-font-smoothing: grayscale}

#scrabble-background {	
	position:fixed;
	top:0;
	left:0;
	width:100%;
	height:100%;
	background-color: var(--game-background-color);
	background-image:url(../images/game-background.png);
	background-repeat:repeat;
	background-position: center;
	/*background-size: 100%;*/
	z-index:-1;
}

/** LOADING AND LOGIN */
#scrabble-loader-container {
	display: flex;
	flex-direction:column;
    justify-content: center;
    align-items: center;
	position:fixed;
	top:0;
	left:0;
	width:100%;
	height:100%;
	font-family:var(--heading-font-family);
	font-size: 40px;
	color:white;
	background-color: var(--game-background-color);
	background-image:url(../images/game-background.png);
	background-repeat:repeat;
	background-position: center;
	/*background-size: 50%;*/
	/*background-image:url(../images/game-background.svg);
	background-repeat:no-repeat;
	background-position: center;
	background-size: cover;*/
	z-index:9999;	
}

#scrabble-loader-container.no-background {
	background-color:transparent;
	background-image:unset;
}

#scrabble-loader.small {
	transform: translateY(-15px) scale(0.4);
}

#scrabble-login, #scrabble-register {
	display: none;
	flex-direction:column;
    justify-content: center;
    align-items: center;
	z-index:4000;
	width: 100%;
}

#scrabble-login, #scrabble-menu-buttons {
	height: 364px !important;
	overflow: hidden;
}

#scrabble-login input, #scrabble-register input {
    margin-top:25px;
    padding:10px 15px;
    font-size:22px;
    width: 300px;
    border: none;
    border-radius: 20px;
	background-color:white;
	box-shadow: 0 0 0 5px #ffe1a6, 0 1px 1px 5px rgba(0, 0, 0, 0.3), 0 1px 2px 9px rgba(0, 0, 0, 0.2), inset 0 2px 5px 2px rgba(0,0,0, 0.1), inset 1px 1px 0 1px rgba(0,0,0, 0.1)
}

#scrabble-login .button-pushable, #scrabble-register .button-pushable {
    margin: 40px 0 0 0 !important;
}

#registration-button {
	font-family: var(--font-family);	
	font-size: 18px;
	color: white;
	margin: 30px 0 0 0;
}

#scrabble-login-text {
	margin-top:20px;
	font-family: var(--font-family);
	font-size: 18px;
	color: white;
}

/** Square */
.square-card {
	align-items: center;
	border-radius: 0.25rem;
	display: flex;
	width: 260px;
	height: 280px;
	justify-content: center;
	position: relative;	
	background-color: transparent;
}

.square-card::before {
  animation: shadow var(--loader-anim-delay) ease-in-out infinite both;
  background-color: rgba(0, 0, 0, 0.2);
  border-radius: 100%;
  bottom: 1.9rem;
  box-shadow: 0 0 0 4px rgba(0, 0, 0, 0.2);
  content: '';
  height: 0.2rem;
  left: 22%;
  position: absolute;
  right: 22%;
}

.down {
  animation: down var(--loader-anim-delay) ease-in infinite both;
  bottom: 2rem;
  position: absolute;
}

.down .up {
  animation: up var(--loader-anim-delay) ease-in-out infinite both;
}

.down .up .squeeze {
  animation: squeeze var(--loader-anim-delay) cubic-bezier(0.72, 0.03, 0.28, 0.97) infinite both;
  transform-origin: 50% 100%;
}

.down .up .squeeze .rotate-in {
  animation: rotate-in var(--loader-anim-delay) ease-out infinite both;
}

.down .up .squeeze .rotate-in .rotate-out {
  animation: rotate-out var(--loader-anim-delay) ease-in infinite both;
}

@keyframes down {
  0% {
    transform: translateY(-10rem);
  }
  20%,
  100% {
    transform: translateY(0);
  }
}

@keyframes up {
  0%,
  75% {
    transform: translateY(0);
  }
  100% {
    transform: translateY(-10rem);
  }
}

@keyframes squeeze {
  0%,
  4% {
    transform: scale(1);
  }
  45% {
    transform: scale(1.6, 0.6);
  }
  100% {
    transform: scale(1);
  }
}

@keyframes rotate-in {
  0% {
    transform: rotate(-180deg);
  }
  20%,
  100% {
    transform: rotate(0deg);
  }
}

@keyframes rotate-out {
  0%,
  80% {
    transform: rotate(0);
  }
  100% {
    transform: rotate(180deg);
  }
}

@keyframes shadow {
  0%,
  100% {
    transform: scale(0.2);
  }
  45%,
  50% {
    transform: scale(0.6);
  }
}
/* End square */   

/** RIBBON */
.banner {
  position: relative;
  display: block;
  margin-top:10px;
  width: 200px;
  height: 40px;
  line-height: 40px;
  font-family:var(--tile-font-family);
  font-size: 18px;
  text-align: center;
  color: #451;
  background: #9b2;
  border-radius: 4px;
  box-shadow: 0 0 30px rgba(0,0,0,.15) inset,
      				0 6px 10px rgba(0,0,0,.15);
}

.banner::before,
.banner::after {
  content: '';
  position: absolute;
  z-index: -1;
  left: -40px;
  top: 17px;
  display: block;
  width: 60px;
  height: 0px;
  border: 20px solid #9b2;
  border-right: 20px solid #791;
  border-bottom-color: #94b81e;
  border-left-color: transparent;
  transform: rotate(-5deg);
}

.banner::after {
  left: auto;
  right: -40px;
  border-left: 20px solid #791;
  border-right: 20px solid transparent;
  transform: rotate(5deg);
}
    
button{text-decoration:none;background:transparent;border-width:0 !important;cursor:pointer}

/*** BUTTONS */
.button-pushable {
	position:relative;
	width:140px;
	border:none;
	background:transparent;
	padding:0;
	outline-offset:4px;
	transition:filter 250ms;
	touch-action:manipulation;
	/*will-change: transform;*/
	z-index:5
}

.button-pushable:hover{
	filter:brightness(110%);
	-webkit-filter:brightness(110%)
}

.button-pushable:focus:not(:focus-visible) {
	outline:none
}

.button-shadow {
	display:block;
	position:absolute;
	top:0;
	left:0;
	width:100%;
	height:100%;
	border-radius:10px;
	background:hsl(var(--gray-shadow) / 0.2);	
	transition: box-shadow 100ms cubic-bezier(.3, .7, .4, 1.1);
	box-shadow:0 0 10px 0 rgba(0,0,0,0.3);
}

.button-pushable:active .button-shadow, .button-pushable:hover .button-shadow {
	box-shadow:0 0 20px 2px rgba(255,255,255,0.6);
}

.button-pushable:active .button-shadow {
	transition: transform 100ms;
	/*box-shadow:0 0 0 0 rgba(0,0,0,0.1);*/
}

.button-edge {
	display:block;
	position:absolute;
	bottom:0;
	left:0;
	width:100%;
	height:100%;
	border-radius:10px;
	background-color:#f4f6ff;	
	/*box-shadow:0 0 0 4px var(--scrabble-rack-color-light),
			   0 0 0 5px white,
			   0 1px 1px 5px rgba(0, 0, 0, 0.3), 
			   0 1px 2px 9px rgba(0, 0, 0, 0.2);*/
	box-shadow: 0 0 0 5px #f4f6ff, 0 0 0 6px white, 0 1px 1px 5px rgba(0, 0, 0, 0.3), 0 1px 3px 9px rgba(0, 0, 0, 0.2);
	z-index:5;
}

.button-front {
    width: 100%;
    height: 40px;
    line-height: 38px;
    display: block;
    position: relative;
    /*border: 2px solid #3f60f5;*/
    border-radius: 10px;
    font-family: var(--heading-font-family);
    font-size: 24px;
    text-align: center;
    text-transform: uppercase;
    letter-spacing: 0px;
    white-space: nowrap;
    color: white;
    background-color: #6c94fe;
	transform:scale(1);
    /*transition: border 100ms, box-shadow 100ms, transform 100ms cubic-bezier(.3, .7, .4, 1.5);*/
    transition: all 100ms cubic-bezier(.3, .7, .4, 1);
	text-shadow: 1px 1px 3px #5473ff, 1px -1px 3px #5473ff, -1px 1px 3px #5473ff, -1px -1px 3px #5473ff, 1px 0px 3px #5473ff, 0px 1px 3px #5473ff, -1px 0px 3px #5473ff, 0px -1px 3px #5473ff;
    /*box-shadow: inset 0 -1px 1px 1px #1b76ff, inset 0 1px 2px 3px #c7d7ff, inset 1px -3px 0 0 #7396ff, inset 0 -10px 3px 5px #5473ff, 0 4px 2px 0 rgba(0, 0, 0, 0.2);*/
	box-shadow: inset 0 0px 3px 1px #1b76ff, inset 0 2px 3px 2px #c7d7ff, inset 1px -2px 0 0 #7396ff, inset 0 -12px 8px 5px #5473ff, 0 4px 2px 0 rgba(0, 0, 0, 0.2);
	z-index:6;
}

.button-pushable .button-front::before {
    content: "";
    position: absolute;
    left: 11px;
    top: 5px;
    width: 5px;
    height: 5px;
    opacity: 0.8;
    background-color: white;
    border-radius: 50%;
    box-shadow: 0 0 6px 1px white;
}

.button-pushable .button-front::after {
   	content: "";
    position: absolute;
    left: 8px;
    top: 9px;
    width: 3px;
    height: 3px;
    opacity: 1;
    background-color: white;
    border-radius: 50%;
    box-shadow: 0 0 6px 1px white;
}

#scrabble-menu .button-pushable:active .button-front, .button-pushable:active .button-front {
	border: 2px solid #2f50e6;
	transform:scale(0.98);
	filter: brightness(100%);
	box-shadow:inset 0 -1px 0 0 #5473ff, 
			   inset 0 1px 0 0 #c7d7ff, 
			   inset 0 -1px 0 0 #7396ff, 
			   inset 0 -40px 2px 10px #5473ff;
}

#scrabble-menu .button-pushable {
	width:220px;	
	margin:10px 0;
	z-index:30002;
} 

#scrabble-menu .button-edge {
	border-radius:20px;
}

#scrabble-menu .button-pushable .button-front {
    height: 56px;
    line-height: 54px;
	font-size: 26px;
	border-radius:20px;
	/*box-shadow: inset 0 3px 1px 2px #c7d7ff, inset 0 8px 15px 2px #5b84f0, inset 1px -2px 0 0 #7396ff, inset 0 -3px 1px 5px #5473ff, inset 0 -10px 10px 5px #7c94ff, 0 4px 2px 0 rgba(0, 0, 0, 0.2);*/
	/*box-shadow: inset 0 0px 5px 1px #1b76ff, inset 0 3px 4px 2px #c7d7ff, inset 1px -2px 0 0 #7396ff, inset 0 -20px 6px 5px #5473ff, 0 4px 2px 0 rgba(0, 0, 0, 0.2);*/
	box-shadow: 
		inset 0 0 2px 1px #1f71ef, 
		inset 0 3px 5px 3px #c7d7ff, 
		inset 1px -2px 0 0 #7396ff, 
		inset -3px -8px 8px -3px #3d59de, 
		inset 0 -20px 15px 5px #5473ff, 
		0 4px 2px 0 rgba(0, 0, 0, 0.2);
}

.button-pushable:active .button-front::before, .button-pushable:active .button-front::after {
	display:none;
}

/*.button-pushable.special {
	-webkit-filter: brightness(100%) hue-rotate(36deg);
	filter: brightness(100%) hue-rotate(58deg);		
}*/

.button-pushable.special .button-edge {
	background-color:#fffaf4;	
	box-shadow: 0 0 0 5px #fffaf4, 0 0 0 6px white, 0 1px 1px 5px rgba(0, 0, 0, 0.3), 0 1px 2px 9px rgba(0, 0, 0, 0.2);
}

.button-pushable.special .button-front {
	background-color: #fe906c;
	border: 1px solid #db1a17;
	text-shadow: 1px 1px 3px #ff5c1b, 1px -1px 3px #ff5c1b, -1px 1px 3px #ff5c1b, -1px -1px 3px #ff5c1b, 1px 0px 3px #ff5c1b, 0px 1px 3px #ff6b31, -1px 0px 3px #ff5c1b, 0px -1px 3px #ff5c1b;
    /*box-shadow: inset 0 -1px 1px 1px #ff5c1b, inset 0 1px 2px 3px #ffd5c7, inset 1px -3px 0 0 #ff9e00, inset 0 -10px 3px 5px #ff4d29, 0 4px 2px 0 rgba(0, 0, 0, 0.2);*/
	box-shadow: inset 0 0px 3px 1px #ff5c1b, inset 0 2px 3px 2px #ffd5c7, inset 1px -2px 0 0 #ff9e00, inset 0 -12px 8px 5px #ff4d29, 0 4px 2px 0 rgba(0, 0, 0, 0.2);
}

#scrabble-menu .button-pushable.special .button-front {
	/*box-shadow: inset 0 3px 1px 2px #ffd5c7, inset 0 8px 15px 2px #eb9100, inset 1px -2px 0 0 #ff9e00, inset 0 -3px 1px 5px #ff4d29, inset 0 -10px 10px 5px #ff9720, 0 4px 2px 0 rgba(0, 0, 0, 0.1);*/
	/*box-shadow: inset 0 0px 5px 1px #ff5c1b, inset 0 3px 4px 2px #ffd5c7, inset 1px -2px 0 0 #ff9e00, inset 0 -20px 6px 5px #ff4d29, 0 4px 2px 0 rgba(0, 0, 0, 0.2);*/
	box-shadow: 
		inset 0 -2px 2px 1px #ff5c1b, 
		inset 0 3px 5px 3px #ffd5c7, 
		inset 1px -2px 0 0 #ff9e00, 
		inset -3px -8px 8px -3px #db3f1f, 
		inset 0 -20px 15px 5px #ff4d29, 
		0 4px 2px 0 rgba(0, 0, 0, 0.2);
}

#scrabble-menu .button-pushable.special:active .button-front, .button-pushable.special:active .button-front {
	border: 2px solid #f1312e;
	transform:scale(0.98);
	filter: brightness(100%);
	box-shadow:inset 0 -1px 0 0 #ff411b, 
			   inset 0 1px 0 0 #ffd5c7, 
			   inset 0 -1px 0 0 #ff9e00, 
			   inset 0 -40px 2px 10px #ff5c1b;
}

.button-pushable.special:hover {
	/*-webkit-filter: brightness(110%) hue-rotate(36deg);
	filter: brightness(110%) hue-rotate(58deg);*/
	filter: brightness(110%);
}

#change-letters-button, #cancel-change-letters-button, #call-letters-button {
	display: none;
}

.button-svg {
    width: 60px;
    height: 60px;    
    background-size: contain;
    border: none;
    cursor: pointer;
}

#active-change-letters-button {
	background: url('../images/change.svg') no-repeat center;
}

#mix-letters-button {
	background: url('../images/shuffle.svg') no-repeat center;
}

#call-letters-button {
	background: url('../images/call.svg') no-repeat center;
}

#play-letters-button.disabled, #active-change-letters-button.disabled {
	-webkit-filter: brightness(130%) grayScale(90%);
	filter: brightness(130%) grayScale(90%);
	pointer-events: none;
}

/*** FADE IN y FADE OUT */
.fadeIn50 {
  opacity: 0;
  animation: fadeInAnimation 0.05s ease-in-out forwards;
}
.fadeIn100 {
  opacity: 0;
  animation: fadeInAnimation 0.1s ease-in-out forwards;
}
.fadeIn200 {
  opacity: 0;
  animation: fadeInAnimation 0.2s ease-in-out forwards;
}

@keyframes fadeInAnimation {
  from {opacity:0}
  to {opacity:1}
}

.fadeOut50 {
  opacity: 1;
  animation: fadeOutAnimation 0.05s ease-in-out forwards;
}
.fadeOut100 {
  opacity: 1;
  animation: fadeOutAnimation 0.1s ease-in-out forwards;
}
.fadeOut200 {
  opacity: 1;
  animation: fadeOutAnimation 0.2s ease-in-out forwards;
}

@keyframes fadeOutAnimation {
  from {opacity:1}
  to {opacity:0}
}

/** RANGE */
.range {
  appearance:none;
  width:180px;
  height:30px;
  background-color:#d6cdc8;
  border-radius:20px;
  background-image:linear-gradient(white -20%, var(--accent-color1) 80%);
  background-size:50% 100%;
  background-repeat:no-repeat;
  z-index: 3001;
  box-shadow:inset 0 1px 8px 2px rgba(0,0,0,0.2),
			0 0 0 4px var(--scrabble-rack-color-light),
			0 0 0 5px white,
			0 2px 3px 5px rgba(0,0,0,0.4);
}

.range::-webkit-slider-thumb{
	/*opacity:0.5;*/
  appearance:none;
  height:48px;
  width:48px;
  /*transform:translateY(-4px);*/
  border-radius:100%;
  background-image:radial-gradient(circle, #ff8cca 0%, #ff7fbf 100%);
  box-shadow:inset 0 0 0 4px #ffb3dc;
  border:0;
  cursor:pointer;
  -webkit-tap-highlight-color: transparent;
	-webkit-touch-callout: none; /* iOS Safari */
    -webkit-user-select: none; /* Safari */
            user-select: none
}

.range::-moz-range-thumb {
  appearance:none;
  height:46px;
  width:46px;
  /*transform:translateY(-4px);*/
  border-radius:100%;
  background-image:radial-gradient(circle, #ff8cca 0%, #ff7fbf 100%);
  box-shadow:inset 0 0 0 3px #ffb3dc, 0 3px 0 0 #ff61b8, 0 10px 6px 0 hsl(var(--gray-shadow)/0.4);
  border:0;
  cursor:pointer;
  -moz-user-select: none; /* Old versions of Firefox */
  user-select:none
}

.range::-ms-thumb {
  appearance:none;
  height:46px;
  width:46px;
  /*transform:translateY(-4px);*/
  border-radius:100%;
  background-image:radial-gradient(circle, #ff8cca 0%, #ff7fbf 100%);
  box-shadow:inset 0 0 0 3px #ffb3dc, 0 3px 0 0 #ff61b8, 0 10px 6px 0 hsl(var(--gray-shadow)/0.4);
  border:0;
  cursor:pointer;
  -ms-user-select: none; /* Internet Explorer/Edge */
  user-select: none
}

#range-music-volume, #range-sounds-volume {
	width:100%;
	height:auto;
	display:flex;
	flex-direction:column;
	justify-content:space-evenly;
	align-items:center;
	margin:15px 0 30px;
}

#range-sounds-volume {
	margin:0 0 15px;
}

#music-volume {
  background-size:35% 100%;
}

#sounds-volume {
  background-size:65% 100%;
}

#scrabble-menu-options .label {
	font-family: var(--heading-font-family);
	font-size:22px;
	font-weight:400;
	color: white;
	margin:15px 0 25px;
}

/*.menu-back-button {
	margin-top: 20px !important;
}*/

#scrabble-windows-bar-top, #scrabble-windows-bar-bottom {
	position:absolute;
	left:0;	
	width: 100%;
	height: 60px;
	display: flex;
	flex-direction:row;
	justify-content:space-between;
	align-items:center;
}

#scrabble-windows-bar-top {
	top: 30px;
	/*background-color: rgba(0,0,0,0.5);*/
}

#scrabble-windows-bar-bottom {
	bottom: 15px;
	justify-content:center;
}

#scrabble-windows-bar-top .scrabble-windows-bar-left, #scrabble-windows-bar-top .scrabble-windows-bar-right{
	width: 150px;
	height: 100%;
	margin: 0 0 0 30px;
	display: flex;
	flex-direction:row;
	justify-content:space-between;
	align-items:center;
}

#scrabble-windows-bar-top .scrabble-windows-bar-right{
	justify-content:end;
	margin: 0 30px 0 0;
}

#scrabble-windows-bar-top button, #scrabble-windows-bar-bottom button {
	width: 44px;
	height: 44px;
	font-family: var(--font-family);
}

#scrabble-windows-bar-top #user-button, #scrabble-windows-bar-top #close-session-button {
	width: auto;
	color: white;
	font-size: 20px;
	display: flex;
	flex-direction:row;
	justify-content:start;
	align-items:center;
}

/*#scrabble-windows-bar-top #close-session-button {
	width: auto;
}*/

#scrabble-windows-bar-top .iconof {
	font-size: 30px;
	margin:0;
}

#scrabble-windows-bar-top button span {
	margin-left: 10px;
}

.scrabble-windows-bar-txt {
	font-family: var(--heading-font-family);
	font-size: 22px;
	color: white;
}

/*** 4 SCRABBLE CONTAINERS */
/*#scrabble-app {
	position:relative;
	width: 100%;
	min-width:100%;
	height:100%;
	min-height:100%;
	display: flex;
	flex-direction:column;
    justify-content: center;
    align-items: center;
	overflow: auto;
}

#scrabble-game-container {
	display: flex;
    justify-content: center;
    align-items: center;
	position:relative;
	min-width:var(--scrabble-window-width);
	min-height:var(--scrabble-window-width);
	margin-bottom:var(--scrabble-bars-difference);
	touch-action: none;
}

#scrabble-layers {
	display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    width:var(--scrabble-board-width);
	height:var(--scrabble-board-width);
	transform: scale(1);
	transform-origin:center center; 
}*/

#scrabble-app {
    position: relative;
    width: 100vw;
    height: 100vh;
    overflow: hidden;
}

#scrabble-game-container {
    position: relative;
    display: flex;
    justify-content: center;
    align-items: center;
    width: 100%;
    height: 100%;
	transform: translateY(-25px);
	touch-action: none;
}

#scrabble-layers {
    position: relative;    
    width: var(--scrabble-board-width);
    height: var(--scrabble-board-height);
	transform-origin: center center;
    transform: scale(1);
}

/** 5 SCRABBLE HINT */
#scrabble-hint-container, #scrabble-message-container {
	position: fixed;
	bottom:160px;
	left:50%;
	min-height:60px;
	width:auto;
	transform: translate(-50%, 0);
	display: none;
    justify-content: center;
    align-items: center;		
	z-index:2000;
}

#scrabble-message-container {	
	bottom:140px;
	width: 340px;
	max-width: 340px;
	/*display:flex;*/
}

#scrabble-hint-content, #scrabble-message-content {
	display: flex;
	position:relative;
	flex-direction:column;
    justify-content: space-evenly;
    align-items: start;
	background-color:white;	
    height: auto;
	padding:10px 15px 10px 70px;
	border-radius:10px;
	box-shadow:0 0 0px 2px var(--accent-color2);
}

#scrabble-hint-content {
	width: 270px;
	background-image:url("../images/hint.svg");
	background-size:40px auto;
	background-position:15px center;
	background-repeat:no-repeat;
}

#scrabble-message-content {
	max-width: 340px;
	padding:10px 15px;
}

#scrabble-hint-container p {
	line-height:1.5;
}

#scrabble-hint-container p:last-child {
	font-family:var(--heading-font-family);
	font-size:24px;
}

#scrabble-inactive {
	position: absolute;
	top:0;
	left:0;
	width:100%;
	height:100%;
	background-color:transparent;
	z-index:9999;
	display:none;
}

/*** SCRABBLE INFO */
#scrabble-info-container {
	display: flex;
	flex-direction:row;
    justify-content: center;
    align-items: center;
	gap: 50px;
	position: fixed;
	top:0;
	left:50%;
	transform: translate(-50%, 0);
	width:var(--scrabble-board-width);
	height:var(--scrabble-info-height);	
	padding: 20px 0;
	/*background-color: white;
	border-radius: 0 0 20px 20px;
	background-color: #5532c6;
    border-bottom:2px solid #180c52;
	box-shadow: inset 0 -5px 8px 10px #4325a3, inset 0 10px 20px 30px #6641dd;*/
	/*box-shadow: inset 0 -5px 0 var(--scrabble-rack-color-light-dark);
	border-bottom:3px solid var(--scrabble-rack-color-dark);
	background-color: var(--scrabble-rack-color);
	background-image:url("../images/wood_texture.svg"); 
	background-size:1600px;*/
	z-index:3000;
}

#scrabble-info-container h1 {
	font-family: var(--tile-font-family);
	font-weight: 600;
	font-size: 36px;
}

#scrabble-info-container div h2, #scrabble-word-container h3 {
	font-family: var(--heading-font-family);
	font-size: 16px;
	font-weight:400;
	padding: 0;
	margin: 0 0 5px 0;
}

#scrabble-info-container div h2 {
	display:none;
	font-family: var(--heading-font-family);
	color:white;
	margin: 0 0 10px 0;
}

.scrabble-info-module {
	position:relative;
	width:auto;		
	text-align: center;
}
.scrabble-info-points-module, .scrabble-info-aipoints-module {
	width:125px;
}
.scrabble-info-bag-module {
	width:90px;	
}
.scrabble-info-clock-module {
	width:115px;	
}
.scrabble-info-menu-module {
	position: absolute;
	right: -15px;
	top: 30px;
	width: 40px;	
}

.scrabble-info-module div {
	width:100%;
	height:40px;
	line-height:40px;
	font-size: 29px;
	font-weight:600;
	font-family:var(--tile-font-family);
	text-align: right;
	color: #ca480a;
	/*text-shadow: -3px 0 #7f57ff, 0 3px #7f57ff, 3px 0 #7f57ff, 0 -3px #7f57ff;*/
	/*text-shadow: 0 0 13px #7f57ff, 0 0 17px #7f57ff, 0 0 15px black, 0 0 15px black;*/
	background-color:#fff2d6;
	box-shadow:inset 0 0 0 2px var(--scrabble-rack-color), inset 0 0 15px 0 var(--scrabble-rack-color), 0 0 0 3px white;
	padding:0 15px 0 40px;
	border-radius:30px;
}

.scrabble-info-module img {
	position:absolute;
	left:-25px;
	bottom:-10px;
	width:60px;
	height:60px;
}

.scrabble-info-module span {
	position:absolute;
	right:0;
	bottom:-80px;
	width:100%;
	height:60px;
	color: white;
	pointer-events: none;
}

.opacity-down {
	opacity: 0.5;
	transition: opacity 0.2s ease-in;
}

.zoom-bounce {
	animation: zoomBounce 0.3s ease-out;
  }
  
  @keyframes zoomBounce {
	0% {
	  transform: scale(1);
	  opacity: 0.5;
	}
	40% {
	  transform: scale(1.35);
	}
	60% {
	  transform: scale(0.87);
	}
	80% {
	  transform: scale(1.13);
	}
	100% {
	  transform: scale(1);
	  opacity: 1;
	}
  }


#menu-button {

	cursor:pointer;
}

#menu-button .button-front {
	height:100%;
}

/** SCRABBLE PLAY POINTS AND WORD  */
#scrabble-play-points, #scrabble-play-word {
	display: none;
    justify-content: center;
    align-items: center;
	position: absolute;
	top:0;
	left:0;
	width:30px;
	height:30px;
	padding-top:3px;
	font-family: var(--tile-font-family);
	font-weight: 800;
    font-size: 11px;
	color: white;
	pointer-events: none;
	background-color:transparent;
	/*border: 1px solid white;
	border-radius:50%;*/
	z-index:5;
	background-image:url(../images/star.svg);
	background-size:cover;
	text-shadow: -1px 0 #094b1c, 0 1px #094b1c, 1px 0 #094b1c, 0 -1px #094b1c;
	transition: transform 0.1s ease-in;
	animation: springScale 0.2s cubic-bezier(0.68, -0.55, 0.27, 1.55);
}

#scrabble-play-word:hover {
	transform: scale(1.2);
}

#scrabble-play-word {
	background-image:url(../images/search.svg);
	background-size:cover;
	cursor: pointer;
	pointer-events: auto;
}

@keyframes springScale {
  0% {
    transform: scale(0);
  }
  80% {
    transform: scale(1.2); /* Escala un poco más para dar la sensación de resorte */
  }
  100% {
    transform: scale(1);
  }
}

/*** Scrabble board */
#scrabble-board {
	width: var(--scrabble-board-width);
    height: var(--scrabble-board-width);
	background-color: var(--scrabble-board-color);
	background-image: url('../images/board.png');
	background-size: 555px 555px;
	background-position: center;
	box-shadow: 0 0 0 10px var(--scrabble-board-color), 0 0 0 18px #c23276, 0 0 0 20px #811b5e;
	border-radius: 10px;
	z-index: 1;	
	overflow: visible;
}

#scrabble-canvas {
	display:none;
	/*visibility: hidden;*/
	position: absolute;
	top:0;
	left:0;
	width: var(--scrabble-board-width);
    height: var(--scrabble-board-width);
	/*transform: scale(1);*/
	z-index: 2;
}

#scrabble-canvas-temp, #scrabble-canvas-plays, #scrabble-canvas-boxes {
	position: absolute;
	top:0;
	left:0;
	width: var(--scrabble-board-width);
    height: var(--scrabble-board-width);
	/*background-color:rgba(255,255,255,0.1);*/
	z-index: 3;
	cursor: default;
}

#scrabble-canvas-temp {
	z-index: 4;
}

#scrabble-canvas-boxes {
	z-index: 2;
}

#scrabble-ai-messages {
	display: none;
	justify-content: flex-end;
	align-items: end;
	flex-direction:column;
	position: fixed;
    right: 0;
    bottom: 160px;
	width: 360px;
    height: 100%;
	/*background-color: rgba(255,255,255, 0.5);*/
	z-index:1500;
	pointer-events: none;
}

#scrabble-ai-messages .message {
	display: flex;
	justify-content: center;
	align-items: center;
	width:auto;	
	height:auto;
	font-size: 18px; 
	line-height:22px;
	background-color: white;
	padding:10px 20px;
	margin: 15px 30px 0 30px;
	border-radius: 10px 10px 0 10px;
}

/** SCRABBLE WINDOWS */
#scrabble-windows-container {
	display: none;
	position: fixed;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    overflow: hidden;
	flex-direction:row;
    justify-content: center;
    align-items: center;
	backdrop-filter:blur(10px);
	background-color:hsl(221.54deg 87.1% 16.41% / 70%);
	z-index:2000;
}

.scrabble-window-content {
    position: absolute;
    min-width: 330px;
    max-width: 340px;
    height: auto;
    top: calc(50% - 20px);
    left: 50%;
    transform: translate(-50%, -50%);
    margin: auto;
    background-color: transparent;	
}

.scrabble-window, .window-button-base {
	border-radius:40px;
	padding:5px;
	background-color: var(--scrabble-rack-color);
	background-image:url("../images/wood_texture.png");
	background-size: 1500px 260px;
	box-shadow:	inset 0 0 1px 3px rgba(255, 174, 112, 0.5), 0 14px 0 0 #9d3a1b, 0 15px 0 3px #562012, 0 0 0 3px #562012, rgba(0, 0, 0, 0.06) 0px 2px 1px, rgba(0, 0, 0, 0.09) 0px 4px 20px, rgba(0, 0, 0, 0.09) 0px 8px 4px, rgba(0, 0, 0, 0.09) 0px 16px 8px, rgba(0, 0, 0, 0.09) 0px 32px 16px;
}

.window-title {
	width: 370px;
	height:100px;
	position:absolute;
	top:-55px;
	left:50%;
	transform: translate(-50%, 0);
	background-image:url("../images/ribbon.png"); 
	background-size:370px auto;
	background-repeat: no-repeat;
	z-index:20;
}

.window-button-base {
	width:200px;
	height:70px;
	position:absolute;
	bottom:-90px;
	left:50%;
	transform:translate(-50%,0);
	background-size:600%;
}

.scrabble-window-paper {
	width:100%;
	min-height:100px;
	position:relative;
	/*border-radius:15px;
	background-color: var(--scrabble-rack-color-light);*/
    /*border:2px solid var(--scrabble-rack-color-dark-light);*/
	/*box-shadow: 0px 1px 1px 1px var(--scrabble-rack-color-dark-light),
				inset 0 -2px 1px 1px var(--scrabble-rack-color-light), 				
				inset 0 2px 25px 30px var(--scrabble-tile-played-color-light), 
				0px 2px 3px 4px rgba(0, 0, 0, 0.2);*/
	background-image: url("../images/paper_body.png");
	background-size: 100% auto;
	background-repeat: repeat-y;
	z-index: 13;
}

.scrabble-window-paper::before {
	content: '';
	position:absolute;
	top:-20px;
	left:0;
	width:100%;
	height:47px;
	background-image: url("../images/paper_top.png");
	background-size: 100% auto;
	background-repeat: no-repeat;
	z-index: 1;
}

.scrabble-window-paper::after {
	content: '';
	position:absolute;
	bottom:-20px;
	left:0;
	width:100%;
	height:47px;
	background-image: url("../images/paper_bottom.png");
	background-size: 100% auto;
	background-repeat: no-repeat;
	z-index:2;
}

.scrabble-window-paper div {
	z-index:3;
	padding:0 20px;
}

#scrabble-word-meaning-container {
	z-index:3;
	padding:0 24px;
	width:100%;
}

/** SCRABBLE WINDOWS ALL */
#scrabble-menu, #scrabble-resume, #scrabble-letters-bag, #scrabble-letter-select, #scrabble-word-container {
	display: none;
	position:relative;
	flex-direction:column;
    justify-content: space-evenly;
    align-items: center;
	width: 340px;
    height: auto;
	font-size: 14px;
	font-weight: 500;
	/*padding:40px 20px var(--window-padding-bottom);*/
	padding:40px 20px;
	/*will-change: transform;*/
}

#scrabble-word-container {
	padding: 30px 10px 25px;
}



#scrabble-word-container h3 {
	margin-top:15px;
	z-index:20;
}

#scrabble-word-container div {
    display: flex;
	flex-direction:column;
	justify-content:start;
	align-items:center;	
}

#ok-button {
	margin-top:35px;
	z-index:10000;
}

#scrabble-word-anagrams {
	line-height:1.2;
}

#scrabble-menu {
	justify-content: start;
	/*margin-top:-100px;*/
	padding:0;
}

#scrabble-menu .menu-module {
	display: flex;
	flex-direction:column;
    justify-content: start;
    align-items: center;
	width:100%;
	height:auto;
	/*margin-bottom:15px;*/
	z-index: 6000;
}

#scrabble-menu h2 {
	font-size: 50px;
	color: white;
	margin-bottom: 20px;
}

#scrabble-menu #scrabble-menu-buttons, #scrabble-menu #scrabble-menu-options, #scrabble-menu #scrabble-menu-games, #scrabble-menu #scrabble-menu-scores {
	display: none;
}

/** BUTTONS MENU */
#scrabble-menu #new-game-button, #solo-game-button {
	margin-top:30px !important;
}

/** LOGO */
#scrabble-logo-container {
	display:none;
	position: relative;
	width: 400px;
	height: 300px;
	z-index:1000;
}

.scrabble-logo {
	width:400px;
	height:auto;
	position:absolute;
	top:50%;
	left:50%;
	transform: translate(-50%, -50%);
	z-index:1001;
}

.radial-stripes {
	position: absolute;
	top:-100px;
	left:50%;
	width:500px;
	height:500px;
	transform: translate(-50%, 0);
	background-image:url(../images/stripes.svg);
	background-repeat: no-repeat;
	background-origin: center;
	background-size: cover;
	opacity:0.6;	
	z-index:1000;
}

.rotate-stripes {
	animation:rotate-stripes 3s infinite steps(60);
}

@keyframes rotate-stripes {
    0% {transform:translate(-50%, 0) rotate(0deg) scale(0.8);}
    50% {transform:translate(-50%, 0) rotate(180deg) scale(1);}
    100% {transform:translate(-50%, 0) rotate(360deg) scale(0.8);}
}

/* Animación de rotación */
@keyframes rotate {
	0% { transform: translate(-50%, -50%) rotate(0deg); }
	50% { transform: translate(-50%, -50%) rotate(360deg); }
	100% { transform: translate(-50%, -50%) rotate(720deg); }
}

#scrabble-resume-info {
	width:100%;
	height:auto;
	margin:0 0 40px 0;
	font-size: 28px;
	font-weight: 800;
	line-height:35px;
	text-shadow: var(--text-shadow-wood);
	text-align:center;
}

#scrabble-resume-info .icon {
	font-size: 48px;
}

#scrabble-blur-overlay {
	display:none;
	position:absolute;
	left:0;
	top:0;
	width:100%;
	height:100%;
	backdrop-filter:blur(5px);
	background-color:var(--background-dark);
	z-index:1999;
	/*animation: fadeInAnimation 0.2s ease-in-out forwards;*/
}

/*#scrabble-word-container {
	display: flex;
}*/

/*** Scrabble word */
#scrabble-word {
	position:absolute;
	top:12px;
	left:50%;
	margin-top:0 !important;
	transform: translate(-50%,0);
	font-family: var(--heading-font-family) !important;
	font-size: 32px;
	color:white;
	text-shadow: 2px 2px 0 #670253, 2px -2px 0 #670253, -2px 2px 0 #670253, -2px -2px 0 #670253, 2px 0px 0 #670253, 0px 2px 0 #670253, -2px 0px 0 #670253, 0px -2px 0 #670253;
}

#scrabble-word-meaning {
	display:block !important;
	min-height:auto;
	max-height:200px;
	width:100%;
	padding:0 10px 0 0;
	margin-bottom:20px;
	overflow-y:auto;
	overflow-x:hidden;
	/*transition: min-height .5s;
	interpolate-size: allow-keywords;*/
}

#scrabble-word-meaning p {
	padding:5px 0 5px 12px;
	line-height: 1.2;
}

#scrabble-word-meaning h3 {
	padding:0 0 0 12px;
	margin-top:5px;
}

#scrabble-word-meaning-loader {
	display:none;
}

#verb-link {
	text-transform: uppercase;
	font-weight: 700;
	color:#b054ff;
	cursor: pointer;
}

#scrabble-word-options {
	position: relative;
	display: flex;
    justify-content: space-evenly;
    align-items: center;
	width:100%;
	padding:20px 0 0;	
}

.close {
	position: absolute;	
	top:-20px;
	right:-2px;
	display:flex;
    justify-content: center;
    align-items: center;
	width:40px;
	height:40px;
	font-weight:900;
	font-size: 26px;
	color:#000;
	background-color: var(--scrabble-rack-color);
	box-shadow:0 2px 0 4px var(--scrabble-rack-color-dark-light), 0 2px 0 8px var(--scrabble-rack-color-dark);
	border-radius: 20%;
	user-select: none;
	cursor: pointer;
	z-index:20;
}

.scrabble-window-paper .close {
	top:-100px;
	right:-22px;
}

#scrabble-hint-content .close {
	top:-18px;
	right:-18px;
	width:36px;
	height:36px;
	background-color: yellow;
	box-shadow:unset;
}

.letters-line {
	display: flex;
    justify-content: space-evenly;
    align-items: center;
}

.letters-line div {
	display: flex;
    justify-content: center;
    align-items: center;
    width: 40px;
    height: 40px;
	margin: 5px;
    background-color: var(--scrabble-rack-color-light);
    border:1px solid var(--scrabble-rack-color-dark);
	font-family: var(--tile-font-family);
    font-size: calc(var(--scrabble-window-tile-font-size) + 1px);
    font-weight: 600;
    position: relative;
	text-shadow: 0 1px 0 #fff;
	border-radius: 6px;
	z-index:2004;
	box-shadow: inset 0 0 4px #fff;
	user-select: none;
}

.letters-line div span {
	display: flex;
    justify-content: center;
    align-items: center;
	position: absolute;
    right: -6px;
    bottom: -6px;
	width: 18px;
	height:18px;
	line-height: 18px;
	border-radius:5px;
	background-color: #196aaf;
	font-family: var(--tile-font-family);
	font-weight: 500;
    font-size: 12px;
	color: #fff;
	text-shadow: none;
	pointer-events: none;
}

.letter-empty {
	background-color: var(--scrabble-rack-color-empty) !important;
	color: #afa6a2 !important;
	border:1px solid #a6744c !important;
}

.letter-empty span {
	background-color: #f11123 !important;
}

#scrabble-letter-select .letters-line div {
	cursor:pointer;
}

/*** Scrabble Controller */
#scrabble-controller {
	display: flex;
	flex-direction:column;
    justify-content: center;
    align-items: center;
	position: fixed;
	bottom:0;
	left:0;
	width:100%;
	height:var(--scrabble-controller-height);
	background-color: transparent;
	z-index:3000;
}

.controller-section {
	display: flex;
	align-items: center;
	justify-content: center;
	background-color: transparent;
	width:140px;
	height: 60px;
	overflow:visible;
}

#scrabble-dot{
	display:none;
	position: absolute;
	top:0;
	left:0;
	height:10px;
	width:10px;
	background-color:red;
	border-radius:50%;
	z-index:9998;
	pointer-events: none;
}

/*** SCRABBLE RACK CONTAINER */
#rack-container {
	position:relative;
    display: flex;
    justify-content: center;
    align-items: center;
	/*gap: 6px;*/
    width: 100%;
    height: var(--scrabble-rack-height);
	background-color: transparent;
	cursor: grab;
	z-index:52;
}

#rack-container::before {
	content:"";
	position: absolute;
	top:26px;
	left:0;
    width: 100%;
    height: calc(var(--scrabble-rack-height) - 30px);
	box-shadow: inset 0 5px 0 rgba(255,244,207,0.8);
	border-top:3px solid var(--scrabble-rack-color-dark);
	background-color: var(--scrabble-rack-color);
	background-image:url("../images/wood_texture.png");
	background-size:1500px 260px;
	background-position:bottom left;
	background-repeat: repeat-x;
	z-index:50;
}

#rack-container::after {
	content:"";
	position: absolute;
	left:0;
	top:21px;
    width: 100%;
    height: var(--scrabble-controller-height);
	box-shadow: inset 0 5px 0 0 rgba(255,244,207,0.8), 0 2px 0 0 rgba(0, 0, 0, 0.2), 0 5px 0 0 rgba(0, 0, 0, 0.1);
	margin-top:40px;
	border-bottom:1px solid var(--scrabble-rack-color-dark);
	border-top:3px solid var(--scrabble-rack-color-dark);
	background-color: var(--scrabble-rack-color);
	background-image:url("../images/wood_texture.png");
	background-size:1500px 260px;
	background-position:bottom left;
	background-repeat: repeat-x;
	z-index:51;
}

#rack-container div {
    margin-bottom: 0;
}

/*** SCRABBLE USER OPTIONS */
#user-options {
	position: relative;
	display: flex;
    justify-content: center;
    align-items: start;
	gap: 80px;
	width:100%;
	height:70px;
	z-index:200;
}

/*#user-options .button-svg {
	margin-top:-2px
}*/

/*#user-options .button-pushable {
	margin-top:8px
}*/

.rotated-svg {
    transform: rotate(90deg);
    transform-origin: center; /* El centro del elemento */
}

/*** SCRABBLE SCORES */
#scrabble-menu #scrabble-menu-scores {
    justify-content: space-between;
	height:580px;
}

#stats {
	width: 100%;
	height: auto;
	overflow-y: scroll;
	padding: 5px 10px;
	margin-bottom: 10px;
}

.stats-line {
	width: 100%;
	height: 56px;
	display:flex;
	flex-direction: row;
	justify-content: space-evenly;
	align-items: center;
	margin-bottom: 20px;
}

.stats-line .separator {
	width: 1px;
	height: 100%;
	background-color: lavender;
	opacity: 0.5;
}

.stats-line .letters-line div {
    width: 26px;
    height: 26px;
    margin: 0;
	line-height: 24px;
    font-size: calc(var(--scrabble-window-tile-font-size) - 8px);
}

.stat {
	width: auto;
	height: 100%;
	display: flex;
	flex-direction: column;
	justify-content: space-between;
	align-items: center;
}

#stats h3 {
	font-family: var(--heading-font-family);
    font-weight: 400;
    font-size: 28px;
    color: var(--scrabble-font-color);
    text-align: center;
    margin: 15px 0;
    padding: 5px;
    border-radius: 20px;
    background-color: #ffe53b;
}

#stats h4 {
	font-family: var(--font-family);
	font-weight: 400;
	font-size: 13px;
	color: white;
}

#stats .stat-number {
	font-family: var(--heading-font-family);
	font-weight: normal;
	font-size: 32px;
	color: white;
}

.podio {
	margin-top: 2rem;
	display:none;
}

.podio li {
	list-style: none;
	background: rgba(255,255,255,0.1);
	margin: 0.4rem 0;
	padding: 0.6rem 1rem;
	border-radius: 20px;
	display: flex;
	justify-content: space-between;
	align-items: center;
}

.rank {
	font-weight: bold;
	color: #FFD700;
}

/*** SCRABBLE TILES */
.tile, .tile-temp, .tile-played, .square {
    position: relative;
	width: var(--scrabble-rack-tile-width);
    height: var(--scrabble-rack-tile-width);
	background-image: url('../images/letters.png');
 	background-size: 600px 180px;
	z-index:3003;
	cursor: grab;
}

.tile-no-points-bg {
	background-image: url('../images/letters-no-points.png') !important;
}

.tile-played-bg {
	background-image: url('../images/letters-played.png') !important;
}

.tile-played-no-points-bg {
	background-image: url('../images/letters-played-no-points.png') !important;
}

/* Primera fila: A-I */
.letterW { background-position: 0 0; }
.letterA { background-position: calc(var(--scrabble-rack-tile-width) * -1) 0; }
.letterB { background-position: calc(var(--scrabble-rack-tile-width) * -2) 0; }
.letterC { background-position: calc(var(--scrabble-rack-tile-width) * -3) 0; }
.letterD { background-position: calc(var(--scrabble-rack-tile-width) * -4) 0; }
.letterE { background-position: calc(var(--scrabble-rack-tile-width) * -5) 0; }
.letterF { background-position: calc(var(--scrabble-rack-tile-width) * -6) 0; }
.letterG { background-position: calc(var(--scrabble-rack-tile-width) * -7) 0; }
.letterH { background-position: calc(var(--scrabble-rack-tile-width) * -8) 0; }
.letterI { background-position: calc(var(--scrabble-rack-tile-width) * -9) 0; }

/* Segunda fila: J-S */
.letterJ { background-position: 0 calc(var(--scrabble-rack-tile-width) * -1); }
.letterL { background-position: calc(var(--scrabble-rack-tile-width) * -1) calc(var(--scrabble-rack-tile-width) * -1); }
.letterM { background-position: calc(var(--scrabble-rack-tile-width) * -2) calc(var(--scrabble-rack-tile-width) * -1); }
.letterN { background-position: calc(var(--scrabble-rack-tile-width) * -3) calc(var(--scrabble-rack-tile-width) * -1); }
.letterÑ { background-position: calc(var(--scrabble-rack-tile-width) * -4) calc(var(--scrabble-rack-tile-width) * -1); }
.letterO { background-position: calc(var(--scrabble-rack-tile-width) * -5) calc(var(--scrabble-rack-tile-width) * -1); }
.letterP { background-position: calc(var(--scrabble-rack-tile-width) * -6) calc(var(--scrabble-rack-tile-width) * -1); }
.letterQ { background-position: calc(var(--scrabble-rack-tile-width) * -7) calc(var(--scrabble-rack-tile-width) * -1); }
.letterR { background-position: calc(var(--scrabble-rack-tile-width) * -8) calc(var(--scrabble-rack-tile-width) * -1); }
.letterS { background-position: calc(var(--scrabble-rack-tile-width) * -9) calc(var(--scrabble-rack-tile-width) * -1); }

/* Tercera fila: T-Z (solo 6 letras) */
.letterT { background-position: 0 calc(var(--scrabble-rack-tile-width) * -2); }
.letterU { background-position: calc(var(--scrabble-rack-tile-width) * -1) calc(var(--scrabble-rack-tile-width) * -2); }
.letterV { background-position: calc(var(--scrabble-rack-tile-width) * -2) calc(var(--scrabble-rack-tile-width) * -2); }
.letterX { background-position: calc(var(--scrabble-rack-tile-width) * -3) calc(var(--scrabble-rack-tile-width) * -2); }
.letterY { background-position: calc(var(--scrabble-rack-tile-width) * -4) calc(var(--scrabble-rack-tile-width) * -2); }
.letterZ { background-position: calc(var(--scrabble-rack-tile-width) * -5) calc(var(--scrabble-rack-tile-width) * -2); }

.square {	
	/*box-shadow: inset 0 0 0 2px var(--scrabble-tile-played-color-light),
			  inset 0 2px 0 3px #fff, 				
			  inset 0 2px 5px 9px var(--scrabble-tile-played-color-light);*/
	will-change: transform;
}

.square-small {
	width: calc(var(--scrabble-rack-tile-width)/2);
    height: calc(var(--scrabble-rack-tile-width)/2);
}

.tile-temp, .tile-played {
	position: absolute;
	width: var(--scrabble-played-tile-width);
    height: var(--scrabble-played-tile-width);
	background-size: 350px 105px;
	margin:0;
}

.tile-played {
	user-select: none;
	outline: 2px solid rgba(255, 215, 0, 0);
	/*-webkit-filter: saturate(1) hue-rotate(0.89turn);
	filter: saturate(1) hue-rotate(0.89turn);*/
}

.tile-played.highlighted {
	outline: 2px solid rgba(255, 215, 0, 1);
	box-shadow: 0 0 8px 4px rgba(255, 215, 0, 0.6);
}

.tile-played.letterW,.tile-temp.letterW { background-position: 0 0; }
.tile-played.letterA,.tile-temp.letterA { background-position: calc(var(--scrabble-played-tile-width) * -1) 0; }
.tile-played.letterB,.tile-temp.letterB { background-position: calc(var(--scrabble-played-tile-width) * -2) 0; }
.tile-played.letterC,.tile-temp.letterC { background-position: calc(var(--scrabble-played-tile-width) * -3) 0; }
.tile-played.letterD,.tile-temp.letterD { background-position: calc(var(--scrabble-played-tile-width) * -4) 0; }
.tile-played.letterE,.tile-temp.letterE { background-position: calc(var(--scrabble-played-tile-width) * -5) 0; }
.tile-played.letterF,.tile-temp.letterF { background-position: calc(var(--scrabble-played-tile-width) * -6) 0; }
.tile-played.letterG,.tile-temp.letterG { background-position: calc(var(--scrabble-played-tile-width) * -7) 0; }
.tile-played.letterH,.tile-temp.letterH { background-position: calc(var(--scrabble-played-tile-width) * -8) 0; }
.tile-played.letterI,.tile-temp.letterI { background-position: calc(var(--scrabble-played-tile-width) * -9) 0; }

/* Segunda fila: J-S */
.tile-played.letterJ,.tile-temp.letterJ { background-position: 0 calc(var(--scrabble-played-tile-width) * -1); }
.tile-played.letterL,.tile-temp.letterL { background-position: calc(var(--scrabble-played-tile-width) * -1) calc(var(--scrabble-played-tile-width) * -1); }
.tile-played.letterM,.tile-temp.letterM { background-position: calc(var(--scrabble-played-tile-width) * -2) calc(var(--scrabble-played-tile-width) * -1); }
.tile-played.letterN,.tile-temp.letterN { background-position: calc(var(--scrabble-played-tile-width) * -3) calc(var(--scrabble-played-tile-width) * -1); }
.tile-played.letterÑ,.tile-temp.letterÑ { background-position: calc(var(--scrabble-played-tile-width) * -4) calc(var(--scrabble-played-tile-width) * -1); }
.tile-played.letterO,.tile-temp.letterO { background-position: calc(var(--scrabble-played-tile-width) * -5) calc(var(--scrabble-played-tile-width) * -1); }
.tile-played.letterP,.tile-temp.letterP { background-position: calc(var(--scrabble-played-tile-width) * -6) calc(var(--scrabble-played-tile-width) * -1); }
.tile-played.letterQ,.tile-temp.letterQ { background-position: calc(var(--scrabble-played-tile-width) * -7) calc(var(--scrabble-played-tile-width) * -1); }
.tile-played.letterR,.tile-temp.letterR { background-position: calc(var(--scrabble-played-tile-width) * -8) calc(var(--scrabble-played-tile-width) * -1); }
.tile-played.letterS,.tile-temp.letterS { background-position: calc(var(--scrabble-played-tile-width) * -9) calc(var(--scrabble-played-tile-width) * -1); }

/* Tercera fila: T-Z (solo 6 letras) */
.tile-played.letterT,.tile-temp.letterT { background-position: 0 calc(var(--scrabble-played-tile-width) * -2); }
.tile-played.letterU,.tile-temp.letterU { background-position: calc(var(--scrabble-played-tile-width) * -1) calc(var(--scrabble-played-tile-width) * -2); }
.tile-played.letterV,.tile-temp.letterV { background-position: calc(var(--scrabble-played-tile-width) * -2) calc(var(--scrabble-played-tile-width) * -2); }
.tile-played.letterX,.tile-temp.letterX { background-position: calc(var(--scrabble-played-tile-width) * -3) calc(var(--scrabble-played-tile-width) * -2); }
.tile-played.letterY,.tile-temp.letterY { background-position: calc(var(--scrabble-played-tile-width) * -4) calc(var(--scrabble-played-tile-width) * -2); }
.tile-played.letterZ,.tile-temp.letterZ { background-position: calc(var(--scrabble-played-tile-width) * -5) calc(var(--scrabble-played-tile-width) * -2); }

.tile:not(.dragging) {
	transition: transform 0.1s ease-in;
	/*will-change: transform;*/
}

.tile-temp:not(.dragging) {
	transition: left 0.06s ease, top 0.06s ease, transform 0.06s ease-out;
}

.tile.change {
	-webkit-filter: saturate(2) hue-rotate(0.41turn);
	filter: saturate(2) hue-rotate(0.41turn);
	transform: translateY(-15px);
}

/* Ficha arrastrada */
.dragging {
    display: block !important;
	position: absolute;
    pointer-events: none; /* Evita que el clon interfiera con eventos del mouse */
	width: var(--scrabble-dragging-tile-width);
    height: var(--scrabble-dragging-tile-width);
    z-index: 4000 !important;
	background-size: 800px 240px;
	will-change: left, top;
}

.dragging.letterW { background-position: 0 0; }
.dragging.letterA { background-position: calc(var(--scrabble-dragging-tile-width) * -1) 0; }
.dragging.letterB { background-position: calc(var(--scrabble-dragging-tile-width) * -2) 0; }
.dragging.letterC { background-position: calc(var(--scrabble-dragging-tile-width) * -3) 0; }
.dragging.letterD { background-position: calc(var(--scrabble-dragging-tile-width) * -4) 0; }
.dragging.letterE { background-position: calc(var(--scrabble-dragging-tile-width) * -5) 0; }
.dragging.letterF { background-position: calc(var(--scrabble-dragging-tile-width) * -6) 0; }
.dragging.letterG { background-position: calc(var(--scrabble-dragging-tile-width) * -7) 0; }
.dragging.letterH { background-position: calc(var(--scrabble-dragging-tile-width) * -8) 0; }
.dragging.letterI { background-position: calc(var(--scrabble-dragging-tile-width) * -9) 0; }

/* Segunda fila: J-S */
.dragging.letterJ { background-position: 0 calc(var(--scrabble-dragging-tile-width) * -1); }
.dragging.letterL { background-position: calc(var(--scrabble-dragging-tile-width) * -1) calc(var(--scrabble-dragging-tile-width) * -1); }
.dragging.letterM { background-position: calc(var(--scrabble-dragging-tile-width) * -2) calc(var(--scrabble-dragging-tile-width) * -1); }
.dragging.letterN { background-position: calc(var(--scrabble-dragging-tile-width) * -3) calc(var(--scrabble-dragging-tile-width) * -1); }
.dragging.letterÑ { background-position: calc(var(--scrabble-dragging-tile-width) * -4) calc(var(--scrabble-dragging-tile-width) * -1); }
.dragging.letterO { background-position: calc(var(--scrabble-dragging-tile-width) * -5) calc(var(--scrabble-dragging-tile-width) * -1); }
.dragging.letterP { background-position: calc(var(--scrabble-dragging-tile-width) * -6) calc(var(--scrabble-dragging-tile-width) * -1); }
.dragging.letterQ { background-position: calc(var(--scrabble-dragging-tile-width) * -7) calc(var(--scrabble-dragging-tile-width) * -1); }
.dragging.letterR { background-position: calc(var(--scrabble-dragging-tile-width) * -8) calc(var(--scrabble-dragging-tile-width) * -1); }
.dragging.letterS { background-position: calc(var(--scrabble-dragging-tile-width) * -9) calc(var(--scrabble-dragging-tile-width) * -1); }

/* Tercera fila: T-Z (solo 6 letras) */
.dragging.letterT { background-position: 0 calc(var(--scrabble-dragging-tile-width) * -2); }
.dragging.letterU { background-position: calc(var(--scrabble-dragging-tile-width) * -1) calc(var(--scrabble-dragging-tile-width) * -2); }
.dragging.letterV { background-position: calc(var(--scrabble-dragging-tile-width) * -2) calc(var(--scrabble-dragging-tile-width) * -2); }
.dragging.letterX { background-position: calc(var(--scrabble-dragging-tile-width) * -3) calc(var(--scrabble-dragging-tile-width) * -2); }
.dragging.letterY { background-position: calc(var(--scrabble-dragging-tile-width) * -4) calc(var(--scrabble-dragging-tile-width) * -2); }
.dragging.letterZ { background-position: calc(var(--scrabble-dragging-tile-width) * -5) calc(var(--scrabble-dragging-tile-width) * -2); }

.placeholder {
	visibility: hidden;
    background-color: transparent;
	width: var(--scrabble-rack-tile-width) !important;
    height: var(--scrabble-rack-tile-width) !important;
	z-index:3002;
}

.hide {
    display: none;
}

/** SCRABBLE PLAY BOX */
.tile-box {
	position:absolute;
	top:0;
	left:0;
	width:var(--scrabble-tile-width);
	height:var(--scrabble-tile-width);
	border-radius: 6px;
	z-index:2;
}

.tile-box.invalid {
	background-color:var(--invalid-word-color);
	box-shadow:0 0 8px 2px var(--invalid-word-color);
}

.tile-box.valid {
	background-color:var(--valid-word-color);
	box-shadow:0 0 8px 2px var(--valid-word-color);
}

/** SCRABBLE MEDIAS */
@media (min-width: 1071px) {
	#scrabble-app {
		justify-content: center;
	}
}	

@media (max-width: 600px) or (max-height: 840px) { 
	:root {
		--scrabble-board-width:360px;
		--scrabble-window-width:380px;
		--scrabble-window-offset:320px;
		--scrabble-tile-width:24px;
		--scrabble-played-tile-width:24px;
		--scrabble-dragging-tile-width:70px;
		--scrabble-rack-tile-width:50px;
		--scrabble-board-title-font-size:11px;
	}
	/*#scrabble-game-container {
		min-width:710px;
		height:950px;
	}*/
	/*#scrabble-layers {
		will-change: transform;
	}*/
	#user-options .button-pushable{
		width:120px;
	}
	
	#scrabble-info-container {
		justify-content: space-evenly;
		gap: 0;
	}
	.scrabble-info-module img {
		left:-15px;
		bottom:-5px;
		width:44px;
		height:44px;
	}
	.scrabble-info-module div {
		height:34px;
		width: auto;
		line-height:34px;
		font-size:18px;
		padding: 0 10px 0 35px;
	}
	.scrabble-info-points-module, .scrabble-info-aipoints-module {
		width:85px;	
	}
	.scrabble-info-bag-module {
		width:65px;	
	}
	
	.scrabble-info-clock-module {
		width:80px;	
	}
	/*.scrabble-info-menu-module {
		width:30px;	
	}*/
	
	#scrabble-menu, #scrabble-resume, #scrabble-letters-bag, #scrabble-letter-select, #scrabble-word-container {
		width: 340px;
	}
	#scrabble-menu {
		margin-top:20px;
	}
	#scrabble-menu .scrabble-logo {
		width:320px;
		position:absolute;
	}
	.line {
		height: 400px;
	}
	.button-front {
		font-size: 20px;
	}

	#scrabble-ai-messages .message {		
		font-size: 16px; 
		line-height:20px;
	}

	#scrabble-windows-bar-top {
		top: 10px;
	}

	#scrabble-logo-container {
		width: 360px;
		height: 260px;
	}

	#scrabble-windows-bar-top .iconof {
		font-size: 24px;
		margin:0;
	}

	#scrabble-windows-bar-top button span {
		margin-left: 8px;
	}

	#scrabble-windows-bar-top #user-button, #scrabble-windows-bar-top #close-session-button {
		font-size: 16px;
	}

	.scrabble-windows-bar-txt {
		font-size: 20px;
	}

	#scrabble-login, #scrabble-register {
	    justify-content: start;
	}

	#scrabble-login-text {
		margin-top:10px;
	}
		
	#scrabble-menu .button-pushable {
		width:220px;	
		margin:10px 0;
	} 

	#scrabble-menu .button-front {
		height: 58px;
		line-height: 56px;
		font-size: 26px;
	}
	#scrabble-menu #new-game-button {
		margin-top:10px;
	}
	#range-sounds-volume {
		margin:0 0 15px;
	}
	#scrabble-board {
		background-size: 360px 360px;
		box-shadow: 0 0 0 5px var(--scrabble-board-color), 0 0 0 8px #c23276, 0 0 0 10px #811b5e;
		border-radius: 4px;
	}
	#user-options {
		justify-content: space-evenly;
		gap: 0;
	}
	.scrabble-file div{
		border-radius: 4px;
	}

	.controller-section {
		margin-top: -2px;
	}

	.tile, .square {
		background-size: 500px 150px;
	}
	.tile-temp, .tile-played {
		background-size: 240px 72px;
	}
	.dragging {
		background-size: 700px 210px;
	}

	#rack-container {
		width: 100%
	}

	#rack-container::before {
		height: calc(var(--scrabble-rack-height) - 22px);
		/*background-size:500px 150px;*/
	}
	#rack-container::after {
		top:16px;
		/*background-size:500px 150px;*/
	}

	#scrabble-hint-container, #scrabble-message-container {
		bottom:147px;
	}
}

/*@media (max-width: 380px){
	:root {
		--scrabble-window-width:380px;
	}
}*/

@media (max-width: 360px){
	:root {
		--scrabble-window-width:360px;
	}
}