/* scrabbler-style.css - Kompletní styly pro hru Scrabbler (Letter Links 5×5) */

/* Reset a základní styly */
.scrabbler-container {
    max-width: 900px;
    margin: 0 auto;
    padding: 10px;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
    user-select: none;
    -webkit-user-select: none;
}

.scrabbler-container * {
    box-sizing: border-box;
}

/* Horní info panel */
.scrabbler-top-panel {
  display: flex;
  align-items: center;
  gap: 15px;
  padding: 10px 15px;
  background: linear-gradient(135deg, #805937 0%, #de7d27 100%);
  border-radius: 12px;
  margin-bottom: 15px;
  box-shadow: 0 4px 15px rgba(0, 0, 0, 0.49);
}

.scrabbler-logo {
    font-size: 1.8rem;
    font-weight: 900;
    color: white;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    letter-spacing: 1px;
    white-space: nowrap;
}

.scrabbler-progress-wrapper {
  flex: 1;
  position: relative;
  height: 45px;
 /* background: #e0e0e0;*/
  border-radius: 25px;
  overflow: hidden;
  box-shadow: inset 0 2px 5px rgba(66, 23, 2, 0.75);
}

.scrabbler-progress-fill {
    position: absolute;
    top: 0;
    left: 0;
    height: 100%;
    background: linear-gradient(90deg, #4caf50, #81c784);
    transition: width 0.4s ease;
    border-radius: 25px;
}

.scrabbler-progress-number {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    font-size: 1.8rem;
    font-weight: 900;
    color: #ff9800;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
    z-index: 2;
}

/* Skrýt staré hlavičky */
.scrabbler-hlavicka {
    display: none;
}

.scrabbler-skore {
    display: none;
}

.scrabbler-progress-container {
    display: none;
}

/* Herní deska 5×5 */
.scrabbler-deska-wrapper {
    display: flex;
    justify-content: center;
    margin: 0;
}

/* Layout deska + rack vedle sebe na desktopu */
.scrabbler-hlavni-layout {
    display: flex;
    gap: 15px;
    justify-content: center;
    align-items: flex-start;
    margin: 15px 0;
}

@media (max-width: 900px) {
    .scrabbler-hlavni-layout {
        flex-direction: column;
        align-items: center;
        gap: 10px;
    }
}

.scrabbler-herni-deska {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 4px;
  background: #372d1c;
  padding: 8px;
  border-radius: 12px;
  box-shadow: 0 6px 15px rgba(0, 0, 0, 0.56);
  width: min(450px, 90vw);
  height: min(450px, 90vw);
}

/* Pole na desce */
.deska-pole {
    aspect-ratio: 1;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    cursor: pointer;
    transition: box-shadow 0.2s ease;
    position: relative;
    border-radius: 6px;
    font-size: clamp(0.8rem, 2.5vw, 1.1rem);
    color: rgba(255, 255, 255, 0.7);
}

/* Normální pole - světle zelené */
.deska-pole.normal {
    background: #e8f5e9;
    color: rgba(0, 0, 0, 0.3);
}

/* Střed se hvězdou - žluté */
.deska-pole.stred {
    background: linear-gradient(135deg, #ffd54f, #ffca28);
    position: relative;
}

.hvezda-stred {
    font-size: 2em;
    color: rgba(255, 152, 0, 0.3);
    position: absolute;
}

/* Double Word - růžová/červená */
.deska-pole.dw {
    background: #ff5858;
    color: rgba(255, 255, 255, 0.9);
    font-weight: 700;
    box-shadow: inset 0 2px 4px rgba(0,0,0,0.1);
}

/* Double Letter - světle modrá */
.deska-pole.dl {
    background: #4ebcff;
}

/* Pole s písmeny */
.deska-pole.ma-dlazdici {
    cursor: pointer;
}

/* Validní/nevalidní slova - BARVA PÍSMEN místo rámečku */
.deska-pole.validni .dlazdice-na-desce .pismeno {
    color: #008000 !important;
}

.deska-pole.nevalidni .dlazdice-na-desce .pismeno {
    color: #c80000 !important;
    animation: shake 0.4s;
}

@keyframes shake {
    0%, 100% { transform: translateX(0); }
    25% { transform: translateX(-5px); }
    75% { transform: translateX(5px); }
}

/* Hover na prázdná pole - BEZ SCALE */
.deska-pole:not(.ma-dlazdici):hover {
    box-shadow: 0 0 10px rgba(52, 152, 219, 0.4);
    z-index: 2;
}

/* Drop hover pro PC - tmavší overlay */
.deska-pole.drop-hover::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(52, 152, 219, 0.25);
    border-radius: 6px;
    pointer-events: none;
    z-index: 1;
}

/* Touch hover - tmavší overlay pro všechny typy polí */
.deska-pole.touch-hover::before {
    content: '';
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(0, 0, 0, 0.2);
    border-radius: 6px;
    pointer-events: none;
    z-index: 1;
}

.scrabbler-stojan.rack-hover {
    background: rgba(52, 152, 219, 0.1);
    box-shadow: inset 0 4px 20px rgba(52, 152, 219, 0.3);
}

/* Dlaždice na desce - DŘEVĚNÝ VZHLED */
.dlazdice-na-desce {
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 90%;
    height: 90%;
    background: linear-gradient(145deg, #e2bb71 0%, #ffd5a9 100%);
    border: 3px solid #333;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    transition: box-shadow 0.2s ease, transform 0.2s ease;
}

.dlazdice-na-desce:hover {
    transform: translate(-50%, -50%) scale(0.95);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.5);
    z-index: 10;
}

.dlazdice-na-desce .pismeno {
    font-size: clamp(1.5rem, 4.5vw, 2.5rem);
    font-weight: 900;
    color: #2c3e50;
}

.dlazdice-na-desce .body {
    position: absolute;
    bottom: 4px;
    right: 6px;
    font-size: clamp(0.7rem, 2vw, 1rem);
    color: #2c3e50;
    font-weight: 900;
}

/* Wildcard dlaždice na desce - fialové žolíkové */
.dlazdice-na-desce.wildcard {
    background: linear-gradient(145deg, #a959ea 0%, #cb86d7 50%, #e9bcf1 100%);
    border-color: #8e24aa;
    box-shadow: 0 3px 8px rgba(142, 36, 170, 0.3), inset 0 1px 2px rgba(255,255,255,0.6);
}

.dlazdice-na-desce.wildcard .pismeno {
    color: #4a148c;
    text-shadow: 0 1px 2px rgba(255,255,255,0.8);
}

/* Powerup dlaždice na desce - zelené bonusové */
.dlazdice-na-desce.powerup {
    background: linear-gradient(145deg, #348b22 0%, #a5d6a7 50%, #bfe6b7 100%);
    border-color: #388e3c;
    box-shadow: 0 3px 10px rgba(76, 175, 80, 0.4), inset 0 1px 2px rgba(255,255,255,0.6);
    animation: pulse 2s infinite;
}

.dlazdice-na-desce.powerup .pismeno {
  /*  color: #1b5e20;*/
    text-shadow: 0 1px 2px rgba(255,255,255,0.9);
}

@keyframes pulse {
    0%, 100% { box-shadow: 0 4px 15px rgba(76, 175, 80, 0.5); }
    50% { box-shadow: 0 4px 25px rgba(76, 175, 80, 0.8); }
}

/* Stojan s dlaždicemi - PEVNÁ VÝŠKA A 5 SLOUPCŮ */
.scrabbler-stojan-wrapper {
  display: flex;
  flex-direction: column;
  justify-content: flex-start;
  /*min-width: 300px;*/
  gap: 5px;
}

.scrabbler-stojan {
  display: grid;
  grid-template-columns: repeat(5, 1fr);
  gap: 10px;
  padding: 15px;
  background: linear-gradient(190deg, #ededed, #9c9c9c);
  border-radius: 15px;
  box-shadow: inset 0 4px 15px rgba(0, 0, 0, 0.6);
  border: 2px solid #bdbdbdb8;
  min-height: 350px;
  min-width: 420px;
  align-content: start;
}

/* Tlačítka panel pod stojanem - PŘEHOZENO: ikony vlevo, ODESLAT vpravo */
.scrabbler-tlacitka-panel {
    display: flex;
    gap: 10px;
    align-items: center;
}

.scrabbler-mini-tlacitka {
    display: flex;
    gap: 8px;
    order: 1; /* Ikony vlevo */
}

.scrabbler-btn-odeslat {
    flex: 1;
    padding: 18px 32px;
    font-size: 1.2rem;
    font-weight: 900;
    order: 2; /* ODESLAT vpravo */
}

.scrabbler-btn-icon {
    width: 55px;
    height: 55px;
    padding: 0;
    font-size: 1.8rem;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    background: linear-gradient(145deg, #e0e0e0, #f5f5f5);
}

.scrabbler-btn-icon:hover {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3);
}

.scrabbler-btn-icon:active {
    transform: translateY(-1px);
}

/* Dlaždice v racku - DŘEVĚNÝ VZHLED */
.dlazdice {
    width: 70px;
    aspect-ratio: 1;
    background: linear-gradient(145deg, #e2bb71 0%, #ffd5a9 100%);
    border: 2px solid #495057;
    border-radius: 8px;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: grab;
    transition: box-shadow 0.2s ease, transform 0.2s ease;
    box-shadow: 0 3px 10px rgba(0, 0, 0, 0.15), inset 0 1px 2px rgba(255,255,255,0.8);
    position: relative;
}

.dlazdice:hover {
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.45), inset 0 1px 2px rgba(255,255,255,0.8);
}

.dlazdice.aktivni {
    transform: scale(1.05);
    box-shadow: 0 0 20px rgba(13, 110, 253, 0.7);
    border-color: #0d6efd;
}

.dlazdice.tahnuta {
    opacity: 0.3;
    cursor: grabbing;
}

.dlazdice-na-desce.tahnuta {
    opacity: 0.3;
}

.dlazdice .pismeno {
    font-size: 2.5rem;
    font-weight: 900;
    color: #212529;
    text-shadow: 0 1px 2px rgba(255,255,255,0.8);
}

.dlazdice .body {
    position: absolute;
    bottom: 3px;
    right: 3px;
    font-size: 0.9rem;
    color: #495057;
    font-weight: 900;
}

/* Wildcard dlaždice v racku - fialové žolíkové */
.dlazdice.wildcard {
    background: linear-gradient(145deg, #a959ea 0%, #cb86d7 50%, #e9bcf1 100%);
    border-color: #8e24aa;
    box-shadow: 0 3px 10px rgba(142, 36, 170, 0.3), inset 0 1px 2px rgba(255,255,255,0.6);
}
.dlazdice.wildcard:hover {
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.45), inset 0 1px 2px rgba(255,255,255,0.8);
}
.dlazdice.wildcard .pismeno,
.dlazdice.wildcard .body {
    color: #4a148c;
    text-shadow: 0 1px 2px rgba(255,255,255,0.8);
}

/* Powerup dlaždice v racku - zelené bonusové */
.dlazdice.powerup {
    background: linear-gradient(145deg, #348b22 0%, #a5d6a7 50%, #bfe6b7 100%);
    border-color: #388e3c;
    box-shadow: 0 3px 10px rgba(76, 175, 80, 0.4), inset 0 1px 2px rgba(255,255,255,0.6);
   
}
.dlazdice.powerup:hover {
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.45), inset 0 1px 2px rgba(255,255,255,0.8);
}
.dlazdice.powerup .pismeno,
.dlazdice.powerup .body {
  /*  color: #1b5e20;*/
    text-shadow: 0 1px 2px rgba(255,255,255,0.9);
}

/* Tlačítka */
.scrabbler-tlacitka {
    display: flex;
    gap: 15px;
    justify-content: center;
    margin: 30px 0;
    flex-wrap: wrap;
}

.scrabbler-btn {
    padding: 16px 32px;
    font-size: 1.1rem;
    font-weight: 700;
    border: none;
    border-radius: 10px;
    cursor: pointer;
    transition: all 0.2s ease;
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.2);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.scrabbler-btn:hover:not(:disabled) {
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(0, 0, 0, 0.3);
}

.scrabbler-btn:active:not(:disabled) {
    transform: translateY(-1px);
}

/* Odstranění disabled stylu - řídí se ručně přes opacity v JS */
.scrabbler-btn-odeslat {
    transition: opacity 0.2s ease, transform 0.2s ease;
}

.scrabbler-btn-primary {
    background: linear-gradient(145deg, #ff9800, #f57c00);
    color: white;
}

.scrabbler-btn-secondary {
    background: linear-gradient(145deg, #42a5f5, #1e88e5);
    color: white;
}

.scrabbler-btn-danger {
    background: linear-gradient(145deg, #ef5350, #e53935);
    color: white;
}

/* Seznam slov */
.scrabbler-seznam-slov {
  max-width: 100%;
  margin: 20px auto;
  padding: 2px 10px;
  background: #f8f9fa;
  border-radius: 12px;
  min-height: 80px;
  border: 2px solid #e0e0e0;
}

.slovo-polozka {
  display: inline-block;
  padding: 3px 8px;
  margin: 3px 0px;
  border-radius: 15px;
  font-weight: 500;
  font-size: 0.85rem;
}

.slovo-polozka.validni {
    background: linear-gradient(145deg, #c8e6c9, #a5d6a7);
    color: #1b5e20;
}

.slovo-polozka.neplatni {
    background: linear-gradient(145deg, #ffcdd2, #ef9a9a);
    color: #b71c1c;
}

.slovo-body {
  font-size: 0.8rem;
  opacity: 0.7;
  margin-left: 2px;
}

/* Pravidla */
.scrabbler-pravidla {
  max-width: 800px;
  margin: 0px auto;
  padding: 15px;
  background: white;
  border-radius: 12px;
  border: 1px solid #a6a6a6;
  box-shadow: 0 2px 15px rgba(0, 0, 0, 0.3);
}

.scrabbler-pravidla h2 {
    color: #2c3e50;
    margin-bottom: 20px;
    font-size: 1.7rem;
    text-align:center;
}

.scrabbler-pravidla h3 {
    color: #34495e;
    margin-top: 25px;
    margin-bottom: 12px;
    font-size: 1.3rem;
}

.scrabbler-pravidla p {
    line-height: 1.5;
    color: #555;
    margin-bottom: 15px;
}

.scrabbler-pravidla ul {
    list-style-type: none;
    padding-left: 0;
}

.scrabbler-pravidla li {
    margin: 2px 0;
    padding-left: 30px;
    position: relative;
    color: #555;
    line-height: 1.5;
}

.scrabbler-pravidla li:before {
    content: "▸";
    position: absolute;
    left: 0;
    color: #3498db;
    font-weight: 900;
    font-size: 1.2em;
}

.scrabbler-pravidla strong {
    color: #2c3e50;
}

.scrabbler-pravidla-toggle {
  display: block;
  margin: 15px auto;
  padding: 8px 10px;
  background: linear-gradient(145deg, #545454, #9a9a9a);
  color: white;
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 0.8rem;
  font-weight: 400;
  transition: all 0.2s;
  box-shadow: 0 4px 10px rgba(0,0,0,0.2);
}

.scrabbler-pravidla-toggle:hover {
    transform: translateY(-2px);
    box-shadow: 0 6px 15px rgba(0,0,0,0.3);
}

/* Legenda barev */
.scrabbler-legenda {
    display: flex;
    justify-content: center;
    gap: 20px;
    flex-wrap: wrap;
    margin: 25px 0;
    font-size: 0.95rem;
}

.scrabbler-legenda-polozka {
    display: flex;
    align-items: center;
    gap: 8px;
    font-weight: 600;
    color: #555;
}

.scrabbler-legenda-box {
    width: 28px;
    height: 28px;
    border-radius: 5px;
    border: 2px solid #333;
}

/* Modální okna */
.scrabbler-modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.85);
    z-index: 1000;
    align-items: center;
    justify-content: center;
    animation: fadeIn 0.2s;
    backdrop-filter: blur(5px);
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.scrabbler-modal-obsah {
    background: white;
    padding: 40px;
    border-radius: 20px;
    max-width: 700px;
    width: 90%;
    box-shadow: 0 20px 60px rgba(0, 0, 0, 0.6);
    position: relative;
    animation: slideUp 0.3s;
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

@keyframes slideUp {
    from { transform: translateY(50px); opacity: 0; }
    to { transform: translateY(0); opacity: 1; }
}

.scrabbler-modal-obsah h2 {
    margin: 0 0 15px 0;
    color: #2c3e50;
    font-size: 2rem;
    text-align: center;
}

.scrabbler-modal-obsah p {
    text-align: center;
    color: #7f8c8d;
    font-size: 1.1rem;
    margin-bottom: 25px;
}

.scrabbler-modal-zavrit {
    position: absolute;
    top: 15px;
    right: 20px;
    font-size: 2.5rem;
    cursor: pointer;
    color: #95a5a6;
    border: none;
    background: none;
    line-height: 1;
    transition: color 0.2s;
    font-weight: 300;
}

.scrabbler-modal-zavrit:hover {
    color: #e74c3c;
    transform: scale(1.1);
}

/* Wildcard výběr písmen - MENŠÍ ČTVERCOVÁ TLAČÍTKA */
.scrabbler-wildcard-pismena {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(45px, 1fr));
    gap: 8px;
    margin-top: 20px;
    max-height: 400px;
    overflow-y: auto;
    padding: 5px;
}

.wildcard-pismeno {
    padding: 0;
    width: 45px;
    height: 45px;
    font-size: 1.5rem;
    font-weight: 600;
    background: linear-gradient(145deg, #c6c6c6, #f5f5f5);
    border: 2px solid #666;
    border-radius: 8px;
    cursor: pointer;
    transition: all 0.2s ease;
    color: #2c3e50;
    display: flex;
    align-items: center;
    justify-content: center;
    box-shadow: 0 3px 6px rgba(0, 0, 0, 0.15), 
                0 1px 3px rgba(0, 0, 0, 0.1);
    font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, 'Helvetica Neue', Arial, sans-serif;
}

.wildcard-pismeno:hover {
    transform: translateY(-3px);
    background: linear-gradient(145deg, #a959ea, #cb86d7);
    color: white;
    box-shadow: 0 6px 12px rgba(142, 36, 170, 0.4),
                0 3px 6px rgba(142, 36, 170, 0.2);
    border-color: #8e24aa;
}

.wildcard-pismeno:active {
    transform: translateY(-1px);
    box-shadow: 0 2px 4px rgba(142, 36, 170, 0.3);
}

/* Výsledek */
.scrabbler-vysledek-skore {
    text-align: center;
    font-size: 4rem;
    color: #27ae60;
    font-weight: 900;
    margin: 30px 0;
    text-shadow: 0 3px 6px rgba(0,0,0,0.1);
}

.scrabbler-finalni-slova {
    max-height: 350px;
    overflow-y: auto;
    margin: 25px 0;
}

/* Toast zprávy - nahoře uprostřed - NOVÝ DESIGN */
.toast {
    padding: 12px 28px;
    border-radius: 12px;
    background: #1a1a1a;
    color: white;
    font-weight: 400;
    font-size: 0.95rem;
    min-width: 250px;
    max-width: 90vw;
    text-align: center;
    white-space: normal;
    word-wrap: break-word;
    line-height: 1.4;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.6);
    border: 2px solid transparent;
}

.toast-success {
    border-color: #4caf50;
    color: #4caf50;
}

.toast-error {
    border-color: #e53935;
    color: #e53935;
}

.toast-info {
    border-color: #1e88e5;
    color: #1e88e5;
}

.toast-warning {
    border-color: #ffa726;
    color: #ffa726;
}

/* Touch klon - duch při přetahování */
#touch-klon {
    pointer-events: none !important;
    opacity: 0.85;
    transform: scale(1.4) rotate(5deg);
    box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
    z-index: 9999;
}

/* Responzivita pro mobil */
@media (max-width: 768px) {
    .scrabbler-container {
        padding: 8px;
    }
    
    .scrabbler-top-panel {
        padding: 10px 15px;
        margin-bottom: 10px;
        gap: 10px;
    }
    
    .scrabbler-logo {
        font-size: 1.3rem;
    }
    
    .scrabbler-progress-wrapper {
        height: 38px;
    }
    
    .scrabbler-progress-number {
        font-size: 1.5rem;
    }
    
    /* Na mobilu pod sebou */
    .scrabbler-hlavni-layout {
        flex-direction: column;
        align-items: center;
        gap: 8px;
    }
    
    .scrabbler-herni-deska {
        width: 95vw;
        height: 95vw;
        max-width: 380px;
        max-height: 380px;
        gap: 3px;
        padding: 6px;
    }
    
    .scrabbler-stojan-wrapper {
        width: 95vw;
        max-width: 380px;
        min-width: auto;
    }
    
    /* Na mobilu 6 sloupců místo 5 */
    .scrabbler-stojan {
        grid-template-columns: repeat(6, 1fr);
        gap: 4px;
        padding: 10px;
        min-height: 140px;
        min-width: 300px;
    }
    
    /* MENŠÍ DLAŽDICE NA MOBILU - 6 VEDLE SEBE */
    .dlazdice {
        width: 100%;
        max-width: 60px;
        aspect-ratio: 1;
    }
    
    .dlazdice .pismeno {
        font-size: 1.4rem;
    }
    
    .dlazdice .body {
        font-size: 0.65rem;
        bottom: 2px;
        right: 2px;
    }
    
    .scrabbler-btn-odeslat {
        padding: 14px 20px;
        font-size: 1rem;
    }
    
    .scrabbler-btn-icon {
        width: 48px;
        height: 48px;
        font-size: 1.5rem;
    }
}

@media (max-width: 480px) {
    .scrabbler-logo {
        font-size: 1.1rem;
    }
    
    .scrabbler-progress-wrapper {
        height: 35px;
    }
    
    .scrabbler-progress-number {
        font-size: 1.3rem;
    }
    
    .scrabbler-stojan {
        gap: 3px;
        padding: 8px;
        min-height: 120px;
        min-width: 300px;
    }
    
    /* JEŠTĚ MENŠÍ DLAŽDICE NA MALÝCH MOBILECH */
    .dlazdice {
        max-width: 55px;
    }
    
    .dlazdice .pismeno {
        font-size: 1.2rem;
    }
    
    .dlazdice .body {
        font-size: 0.6rem;
    }
    
    .scrabbler-wildcard-pismena {
        grid-template-columns: repeat(auto-fill, minmax(35px, 1fr));
        gap: 6px;
    }
    
    .wildcard-pismeno {
        width: 40px;
        height: 40px;
        font-size: 1.2rem;
    }
    
    .scrabbler-modal-obsah {
        padding: 20px;
        max-width: 95%;
    }
    
    .scrabbler-modal-obsah h2 {
        font-size: 1.5rem;
        margin-bottom: 10px;
    }
    
    .scrabbler-modal-obsah p {
        font-size: 0.95rem;
        margin-bottom: 15px;
    }
    
    .scrabbler-tlacitka-panel {
        gap: 8px;
    }
    
    .scrabbler-btn-icon {
        width: 45px;
        height: 45px;
        font-size: 1.3rem;
    }
}

/* Přidat do scrabbler-style.css */

.scrabbler-result-screen {
    max-width: 900px;
    margin: 0 auto;
    padding: 20px;
}

.scrabbler-result-container {
    background: white;
    border-radius: 15px;
    padding: 30px;
    box-shadow: 0 6px 25px rgba(0, 0, 0, 0.25);
}

.scrabbler-result-stats {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 15px;
    margin: 30px 0;
}

.scrabbler-result-stat-box {
    background: linear-gradient(135deg, #667eea, #764ba2);
    border-radius: 12px;
    padding: 20px 15px;
    text-align: center;
    box-shadow: 0 4px 15px rgba(0, 0, 0, 0.2);
    color: white;
}

.scrabbler-result-stat-value {
    font-size: 2rem;
    font-weight: 700;
    margin: 5px 0;
    color: #ffd700;
    text-shadow: 0 2px 4px rgba(0, 0, 0, 0.3);
}

.scrabbler-result-stat-label {
    font-size: 0.9rem;
    color: rgba(255, 255, 255, 0.9);
    text-transform: uppercase;
    letter-spacing: 0.5px;
}

.scrabbler-result-deska {
    max-width: 400px;
    margin: 0 auto;
}

.scrabbler-result-slova {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: center;
    margin: 20px 0;
}

.scrabbler-result-slovo {
    padding: 10px 20px;
    background: linear-gradient(145deg, #c8e6c9, #a5d6a7);
    color: #1b5e20;
    border-radius: 20px;
    font-weight: 600;
    font-size: 1.1rem;
}

@media (max-width: 768px) {
    .scrabbler-result-stats {
        grid-template-columns: repeat(2, 1fr);
        gap: 12px;
    }
    
    .scrabbler-result-stat-value {
        font-size: 1.5rem;
    }
    
    .scrabbler-result-stat-label {
        font-size: 0.75rem;
    }
}



/* final result */

.scrabbler-result-container-final {
    background: linear-gradient(135deg, #3b1e0c 0%, #3a1c09 50%, #291305 100%);
    border-radius: 20px;
    padding: 40px 30px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.6);
    position: relative;
    overflow: hidden;
}

.scrabbler-result-container-final::before {
    content: '';
    position: absolute;
    top: -50%;
    left: -50%;
    width: 200%;
    height: 200%;
    background: linear-gradient(
        45deg,
        transparent,
        rgba(255, 255, 255, 0.1),
        transparent
    );
    animation: shine 5s infinite;
}

@keyframes shine {
    0% { transform: translateX(-100%) translateY(-100%) rotate(45deg); }
    100% { transform: translateX(100%) translateY(100%) rotate(45deg); }
}

.scrabbler-result-stats-final {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
    margin: 30px 0;
    position: relative;
    z-index: 1;
}

.scrabbler-result-stat-box-final {
    background: linear-gradient(135deg, #3b1e0c 0%, #3a1c09 50%, #291305 100%);
    border: 2px solid rgba(255, 215, 0, 0.3);
    border-radius: 15px;
    padding: 15px 10px;
    text-align: center;
    backdrop-filter: blur(10px);
    transition: all 0.3s ease;
}

.scrabbler-result-stat-box-final:hover {
    transform: translateY(-5px);
    border-color: rgba(255, 215, 0, 0.6);
    box-shadow: 0 5px 20px rgba(255, 215, 0, 0.3);
}

.scrabbler-result-stat-value-final {
    font-size: 2rem;
    font-weight: 900;
    color: #ffd700;
    text-shadow: 0 3px 10px rgba(255, 215, 0, 0.5);
    margin: 5px 0;
}

.scrabbler-result-stat-label-final {
    font-size: 0.85rem;
    color: rgba(255, 255, 255, 0.8);
    text-transform: uppercase;
    letter-spacing: 1px;
}

@media (max-width: 768px) {
    .scrabbler-result-stats-final {
        grid-template-columns: repeat(2, 1fr);
        gap: 10px;
    }
    
    .scrabbler-result-stat-value-final {
        font-size: 1.5rem;
    }
}



/* Scrollbar styling */
.scrabbler-seznam-slov::-webkit-scrollbar,
.scrabbler-finalni-slova::-webkit-scrollbar,
.scrabbler-wildcard-pismena::-webkit-scrollbar {
    width: 10px;
}

.scrabbler-seznam-slov::-webkit-scrollbar-track,
.scrabbler-finalni-slova::-webkit-scrollbar-track,
.scrabbler-wildcard-pismena::-webkit-scrollbar-track {
    background: #f1f1f1;
    border-radius: 10px;
}

.scrabbler-seznam-slov::-webkit-scrollbar-thumb,
.scrabbler-finalni-slova::-webkit-scrollbar-thumb,
.scrabbler-wildcard-pismena::-webkit-scrollbar-thumb {
    background: #888;
    border-radius: 10px;
}

.scrabbler-seznam-slov::-webkit-scrollbar-thumb:hover,
.scrabbler-finalni-slova::-webkit-scrollbar-thumb:hover,
.scrabbler-wildcard-pismena::-webkit-scrollbar-thumb:hover {
    background: #555;
}


.scrabbler-result-deska .deska-modal-pole {
    font-size: 0.9em !important;
    padding: 2px;
}

.scrabbler-result-deska .deska-modal-pole.powerup,
.scrabbler-result-deska .deska-modal-pole.wildcard {
    font-weight: 700;
}