/* FONTY */ @font-face { font-family: 'MPLUSRounded1c-Black'; src: url('../fonts/MPLUSRounded1c-Black.ttf') format('truetype'); /* Možné ďalšie formáty fontov (woff, woff2, svg) a ich cesty by sa tiež mali uviesť */ font-weight: normal; font-style: normal; } @font-face { font-family: 'MPLUSRounded1c-Medium'; src: url('../fonts/MPLUSRounded1c-Medium.ttf') format('truetype'); /* Možné ďalšie formáty fontov (woff, woff2, svg) a ich cesty by sa tiež mali uviesť */ font-weight: normal; font-style: normal; } @font-face { font-family: 'MPLUSRounded1c-ExtraBold'; src: url('../fonts/MPLUSRounded1c-ExtraBold.ttf') format('truetype'); /* Možné ďalšie formáty fontov (woff, woff2, svg) a ich cesty by sa tiež mali uviesť */ font-weight: normal; font-style: normal; } @font-face { font-family: 'MPLUSRounded1c-Bold'; src: url('../fonts/MPLUSRounded1c-Bold.ttf') format('truetype'); /* Možné ďalšie formáty fontov (woff, woff2, svg) a ich cesty by sa tiež mali uviesť */ font-weight: normal; font-style: normal; } body { margin: 0; padding: clamp(10px, 2vw, 20px); min-height: 90vh; display: flex; flex-direction: column; background-image: url('../images/pozadieg.jpg'); background-size: cover; background-position: center; font-family: 'MPLUSRounded1c-Medium', sans-serif; overflow-x: hidden; } .game-container { display: grid; grid-template-columns: repeat(6, 1fr); gap: 10px; max-width: 900px; margin: 20px auto; } /* koniec hry okno */ .modal { display: none; position: fixed; top: 0; left: 0; width: 100%; height: 100%; background-color: rgba(0, 0, 0, 0.7); z-index: 1000; justify-content: center; align-items: center; } .modal-content { background-color: white; padding: 2rem; border-radius: 15px; box-shadow: 0 4px 6px rgba(0, 0, 0, 0.1); text-align: center; max-width: 500px; width: 90%; z-index: 1001; /* Vyšší než modal */ position: relative; } .modal h2 { color: #2c3e50; margin-bottom: 1.5rem; } .game-stats { background-color: #f8f9fa; padding: 1rem; border-radius: 10px; margin: 1.5rem 0; } .game-stats p { margin: 0.5rem 0; color: #2c3e50; } .modal-buttons { display: flex; justify-content: center; gap: 1rem; margin-top: 1.5rem; } .modal-button { padding: 0.8rem 1.5rem; border: none; border-radius: 5px; cursor: pointer; font-size: 1rem; transition: all 0.3s ease; } #restartGameBtn { background-color: #4CAF50; color: white; } #backToMenuBtn { background-color: #2196F3; color: white; } .modal-button:hover { transform: translateY(-2px); opacity: 0.9; } #winnerInfo { margin: 1rem 0; padding: 1rem; background-color: #e8f5e9; border-radius: 10px; } #winnerText { color: #2e7d32; margin: 0; } /* karty */ .card { aspect-ratio: 1; background-image: url("../images/pexeso.png"); background-size: cover; background-position: center; background-repeat: no-repeat; display: flex; flex-direction: column; align-items: center; justify-content: center; cursor: pointer; transition: transform 0.3s; position: relative; overflow: hidden; transform-style: preserve-3d; } .card.flipped { background-image: url("../images/hra.png"); transform: rotateY(0); } .card img { max-width: 70%; max-height: 60%; position: absolute; top: 10%; /* Posun obrázku nahoru */ backface-visibility: hidden; transform: rotateY(180deg); transition: transform 0.3s; } .card-word { font-size: 15px; position: absolute; bottom: 15px; /* Umístění textu dolů */ left: 0; right: 0; text-align: center; color: white; text-shadow: 1px 1px 2px black; backface-visibility: hidden; transform: rotateY(180deg); transition: transform 0.3s; font-family: 'MPLUSRounded1c-Bold', sans-serif; } .card.flipped { transform: rotateY(0); } .card.flipped img, .card.flipped .card-word { transform: rotateY(0); } .stats { text-align: center; margin: 20px; font-size: 1.2em; color: white; } .back-button { position: absolute; top: 20px; left: 20px; text-decoration: none; font-size: 24px; color: black; } .mic-indicator { width: 100%; display: flex; flex-direction: row; /* zmena na row pre horizontálne usporiadanie */ align-items: center; /* vertikálne zarovnanie na stred */ justify-content: center; /* horizontálne zarovnanie na stred */ gap: 10px; /* medzera medzi bodkou a tlačidlom */ margin: 10px 0; } .recording-status { width: 15px; height: 15px; border-radius: 50%; background-color: red; animation: pulse 1s infinite; display: none; } @keyframes pulse { 0% { transform: scale(1); opacity: 1; } 50% { transform: scale(1.2); opacity: 0.7; } 100% { transform: scale(1); opacity: 1; } } .players-container { display: flex; justify-content: center; width: 100%; margin-bottom: 20px; margin-top: 20px; } .player-indicator { background-color: #3a1304; border: 3px double #96530f; border-radius: 0px; padding: 15px; text-align: center; min-width: 250px; transition: all 0.3s ease; margin: 0 10px; } .player-indicator .current-player { font-size: 16px; margin-bottom: 10px; } .player-indicator .player-name { font-weight: bold; } .player-indicator .player-scores { display: flex; flex-direction: column; align-items: center; font-size: 14px; } .player-indicator .player-scores div { margin: 5px 0; } .player-indicator.active-player { transform: scale(1.1); border: 3px solid #1eff00; box-shadow: 0 0 10px rgba(0,0,0,0.1); background-size: 100% 100%; } /* Rozmazané pozadie */ /* Pridáme wrapper pre hlavný obsah */ .game-wrapper { transition: filter 0.3s ease; } /* Keď je speech container aktívny, aplikujeme blur na wrapper */ .blur-background .game-wrapper { filter: blur(5px); z-index: -1; } /* Obrázok slova */ .match-text { font-size: 1.2em; position: relative; color: white; text-shadow: 2px 2px 4px rgba(0,0,0,0.5); margin: 5% auto 5% auto; } /* Tlačidlo mikrofónu */ #micButton { padding: 10px 20px; border-radius: 25px; border: none; cursor: pointer; font-size: 1.2em; background: linear-gradient(45deg, #ff6b6b, #4ecdc4); /* rozprávkové farby */ color: white; transition: all 0.3s ease; } /* Neaktívny stav tlačidla */ #micButton:not(.active) { background: linear-gradient(45deg, #ff9a9e, #fad0c4); } /* Aktívny stav tlačidla */ #micButton.active { background: linear-gradient(45deg, #4facfe, #00f2fe); } /* Text pre zostávajúce pokusy */ .attempts-left { margin-top: 15px; color: #838383; font-size: 0.9em; } .word-image { max-width: 100px; max-height: 100px; height: auto; margin: 2% auto 2% auto; display: block; } .speech-container { position: fixed; top: 50%; left: 50%; transform: translate(-50%, -50%); background-color: #3a1304; border: 3px solid #96530f; padding: 20px; text-align: center; display: none; z-index: 1000; flex-direction: column; align-items: center; min-width: 300px; /* zabezpečí minimálnu šírku pre obsah */ filter: blur(0px); } .feedback-image { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); width: 300px; height: auto; z-index: 1001; /* aby bol nad rozmazaným obsahom */ } /* Média dotaz pro mobilní zařízení */ @media screen and (max-width: 768px) { body { height: 100vh; background-size: cover; background-position: center; } .game-container { grid-template-columns: repeat(4, 1fr); /* Méně sloupců pro menší obrazovky */ gap: 5px; margin: 10px auto; padding: 0 10px; } .card { aspect-ratio: 1; font-size: 12px; } .card img { max-width: 60%; max-height: 50%; top: 15%; /* Mírná úprava pozice */ } .card-word { font-size: 12px; bottom: 10px; } .stats { font-size: 1em; margin: 10px; } .back-button { top: 10px; left: 10px; font-size: 20px; } .speech-container { bottom: 10px; width: 90%; padding: 10px; } .players-container { flex-direction: column; align-items: center; margin-bottom: 10px; margin-top: 10px; } .player-indicator { min-width: 200px; margin: 5px 0; padding: 10px; } .player-indicator .current-player { font-size: 14px; } .modal-content { width: 90%; padding: 20px; } } /* Pro velmi malé obrazovky (mobilní telefony) */ @media screen and (max-width: 480px) { .game-container { grid-template-columns: repeat(3, 1fr); /* Ještě méně sloupců */ gap: 3px; } .card { font-size: 10px; } .card img { max-width: 50%; max-height: 40%; } .card-word { font-size: 10px; } .player-indicator { min-width: 180px; } } /* Responzivní úpravy pro tablety a mobilní zařízení */ @media screen and (max-width: 1024px) { .player-indicator { width: calc(50% - 20px); /* Rozdělení na 2 sloupce */ min-width: 200px; margin: 10px; } } @media screen and (max-width: 768px) { .players-container { flex-direction: column; align-items: center; } .player-indicator { width: 90%; /* Téměř plná šířka */ max-width: 400px; min-width: 180px; margin: 10px 0; } } @media screen and (max-width: 480px) { .player-indicator { width: 95%; /* Ještě větší šířka */ padding: 10px; } .player-indicator .current-player { font-size: 14px; } .player-indicator .player-scores { font-size: 12px; } } /* Zbytek původního CSS zůstává stejný */ .player-indicator .current-player { font-size: 16px; margin-bottom: 10px; } .player-indicator .player-name { font-weight: bold; } .player-indicator .player-scores { display: flex; flex-direction: column; align-items: center; } .player-indicator .player-scores div { margin: 5px 0; } .player-indicator.active-player { transform: scale(1.05); box-shadow: 0 0 10px rgba(0,0,0,0.1); }