Spaces:
Running
on
T4
Running
on
T4
body { | |
margin: 0; | |
min-height: 100vh; | |
display: flex; | |
flex-direction: column; | |
background: #f0f0f0; | |
font-family: "Press Start 2P", sans-serif; | |
} | |
.container { | |
display: flex; | |
gap: 20px; | |
max-width: 1600px; | |
margin: 0 auto; | |
} | |
.game-section { | |
flex-shrink: 0; | |
} | |
#gameCanvas { | |
border: 1px solid black; | |
display: block; | |
} | |
.chat-section { | |
flex: 1; | |
display: flex; | |
flex-direction: column; | |
min-width: 300px; | |
max-width: 500px; | |
height: 640px; | |
background: white; | |
border-radius: 8px; | |
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); | |
} | |
.chat-messages { | |
flex: 1; | |
padding: 20px; | |
overflow-y: auto; | |
border-bottom: 1px solid #eee; | |
scroll-behavior: smooth; | |
max-height: calc(100% - 180px); | |
font-size: 12px; | |
line-height: 1.6; | |
} | |
.input-area { | |
padding: 20px; | |
background: #f8f8f8; | |
border-radius: 0 0 8px 8px; | |
min-height: 140px; | |
display: flex; | |
flex-direction: column; | |
} | |
#messageInput { | |
width: 100%; | |
padding: 10px; | |
border: 1px solid #ddd; | |
border-radius: 4px; | |
resize: none; | |
margin-bottom: 10px; | |
font-family: "Press Start 2P", sans-serif; | |
font-size: 12px; | |
height: 80px; | |
box-sizing: border-box; | |
line-height: 1.5; | |
} | |
.button-group { | |
display: flex; | |
gap: 10px; | |
} | |
.send-button, | |
.mic-button { | |
padding: 8px 16px; | |
border: none; | |
border-radius: 4px; | |
cursor: pointer; | |
transition: background-color 0.2s; | |
} | |
.send-button:disabled, | |
.mic-button:disabled { | |
background-color: #cccccc; | |
cursor: not-allowed; | |
opacity: 0.7; | |
} | |
.send-button:disabled:hover, | |
.mic-button:disabled:hover { | |
background-color: #cccccc; | |
transform: none; | |
} | |
.send-button { | |
background-color: #007bff; | |
color: white; | |
flex: 1; | |
} | |
.send-button:hover:not(:disabled) { | |
background-color: #0056b3; | |
} | |
.mic-button { | |
background-color: #6c757d; | |
color: white; | |
width: 40px; | |
padding: 8px; | |
transition: background-color 0.3s, transform 0.2s; | |
} | |
.mic-button:hover:not(:disabled) { | |
background-color: #5a6268; | |
} | |
.mic-button.recording { | |
background-color: #dc3545; | |
animation: pulse 1.5s infinite; | |
} | |
@keyframes pulse { | |
0% { | |
transform: scale(1); | |
} | |
50% { | |
transform: scale(1.05); | |
} | |
100% { | |
transform: scale(1); | |
} | |
} | |
/* View Management */ | |
.game-view, | |
.dialogue-view { | |
display: none; | |
flex: 1; | |
padding: 20px; | |
background: #f0f0f0; | |
} | |
.active { | |
display: block; | |
} | |
/* Dialogue View Styles */ | |
.dialogue-container { | |
height: 100%; | |
padding: 20px; | |
} | |
.character-section { | |
height: 100%; | |
display: flex; | |
justify-content: space-between; | |
align-items: center; | |
gap: 20px; | |
} | |
.character-img { | |
width: 100%; | |
height: 100%; | |
display: none; | |
object-fit: cover; | |
} | |
.character { | |
display: flex; | |
align-items: center; | |
justify-content: center; | |
width: 400px; | |
height: 600px; | |
background: #ddd; | |
border-radius: 8px; | |
overflow: hidden; | |
} | |
.dialogue-box { | |
flex: 1; | |
height: 600px; | |
background: white; | |
border-radius: 8px; | |
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); | |
display: flex; | |
flex-direction: column; | |
overflow: hidden; | |
max-height: 600px; | |
} | |
.dialogue-messages { | |
flex: 1; | |
padding: 20px; | |
overflow-y: auto; | |
font-size: 14px; | |
line-height: 1.6; | |
display: flex; | |
flex-direction: column; | |
gap: 15px; | |
height: calc(100% - 80px); | |
} | |
/* Status Bar */ | |
.status-bar { | |
width: 100%; | |
padding: 10px 20px; | |
background: rgba(0, 0, 0, 0.8); | |
color: #fff; | |
box-sizing: border-box; | |
} | |
.status-text { | |
font-size: 12px; | |
} | |
/* Debug Controls */ | |
.debug-controls { | |
width: 100%; | |
padding: 20px; | |
background: #333; | |
display: flex; | |
gap: 10px; | |
justify-content: center; | |
box-sizing: border-box; | |
} | |
.view-controls, | |
.game-controls { | |
display: flex; | |
gap: 5px; | |
} | |
.debug-button { | |
padding: 8px 12px; | |
border-radius: 4px; | |
border: 1px solid #ccc; | |
background: #f0f0f0; | |
cursor: pointer; | |
font-family: "Press Start 2P", monospace; | |
font-size: 12px; | |
} | |
.debug-button:hover { | |
background: #e0e0e0; | |
} | |
/* Chat Message Styles */ | |
.chat-message { | |
margin-bottom: 15px; | |
display: flex; | |
animation: fadeIn 0.3s ease-in; | |
} | |
.chat-message.left-user { | |
justify-content: flex-start; | |
} | |
.chat-message.right-user { | |
justify-content: flex-end; | |
} | |
.message-bubble { | |
max-width: 70%; | |
padding: 10px 15px; | |
border-radius: 15px; | |
font-size: 12px; | |
line-height: 1.6; | |
} | |
.left-user .message-bubble { | |
background-color: #e9ecef; | |
color: #000; | |
border-bottom-left-radius: 5px; | |
} | |
.right-user .message-bubble { | |
background-color: #007bff; | |
color: white; | |
border-bottom-right-radius: 5px; | |
} | |
@keyframes fadeIn { | |
from { | |
opacity: 0; | |
transform: translateY(10px); | |
} | |
to { | |
opacity: 1; | |
transform: translateY(0); | |
} | |
} | |
/* Game Over View Styles */ | |
.game-over-view { | |
display: none; | |
position: fixed; | |
top: 0; | |
left: 0; | |
width: 100%; | |
height: 100%; | |
background: #000; | |
} | |
.game-over-view.active { | |
display: block; | |
} | |
.game-over-content { | |
position: relative; | |
width: 100%; | |
height: 100%; | |
display: flex; | |
flex-direction: column; | |
justify-content: center; | |
align-items: center; | |
gap: 40px; | |
} | |
.game-over-image { | |
position: absolute; | |
top: 0; | |
left: 0; | |
width: 100%; | |
height: 100%; | |
object-fit: contain; | |
opacity: 0.8; | |
} | |
.game-over-controls { | |
position: absolute; | |
bottom: 300px; | |
left: 50%; | |
transform: translateX(-50%); | |
z-index: 1; | |
} | |
.play-again-button { | |
padding: 15px 30px; | |
font-size: 24px; | |
background-color: #ff4444; | |
color: white; | |
border: none; | |
border-radius: 8px; | |
cursor: pointer; | |
transition: transform 0.2s, background-color 0.2s; | |
box-shadow: 0 4px 8px rgba(0, 0, 0, 0.2); | |
font-family: "Press Start 2P", monospace; | |
} | |
.play-again-button:hover { | |
background-color: #ff6666; | |
transform: translateY(-2px); | |
} | |
.play-again-button:active { | |
transform: translateY(0); | |
} | |
/* Dialogue Controls Styles */ | |
.dialogue-controls { | |
position: static; | |
transform: none; | |
padding: 20px; | |
text-align: center; | |
background: white; | |
border-radius: 0 0 8px 8px; | |
height: 80px; | |
box-sizing: border-box; | |
display: flex; | |
justify-content: space-between; | |
align-items: center; | |
} | |
/* Continue and Next Button Styles */ | |
.continue-button, | |
.next-button { | |
padding: 15px 30px; | |
font-size: 14px; | |
background-color: #007bff; | |
color: white; | |
border: none; | |
border-radius: 6px; | |
cursor: pointer; | |
transition: background-color 0.2s, transform 0.2s; | |
box-shadow: 0 2px 4px rgba(0, 0, 0, 0.1); | |
font-family: "Press Start 2P", monospace; | |
} | |
.continue-button:hover, | |
.next-button:hover { | |
background-color: #0056b3; | |
transform: translateY(-2px); | |
} | |
.continue-button:active, | |
.next-button:active { | |
transform: translateY(0); | |
} | |
/* Hide next button by default */ | |
.next-button { | |
display: none; | |
} | |
.game-over-text { | |
position: relative; | |
z-index: 1; | |
color: white; | |
font-size: 28px; | |
text-align: center; | |
text-shadow: 4px 4px 0 #000, -2px -2px 0 #000, 2px -2px 0 #000, -2px 2px 0 #000, 2px 2px 0 #000; | |
margin-bottom: 40px; | |
margin-top: -200px; | |
animation: pixelate 0.5s steps(5) forwards; | |
} | |
@keyframes pixelate { | |
0% { | |
transform: scale(0.8); | |
opacity: 0; | |
} | |
100% { | |
transform: scale(1); | |
opacity: 1; | |
} | |
} | |
/* Add pixel art font to all buttons */ | |
.debug-button, | |
.send-button, | |
.mic-button, | |
.continue-button, | |
.next-button { | |
font-family: "Press Start 2P", monospace; | |
font-size: 12px; | |
} | |
/* Intro View Styles */ | |
.intro-view { | |
display: none; | |
position: fixed; | |
top: 0; | |
left: 0; | |
width: 100%; | |
height: 100%; | |
background: #000; | |
z-index: 1000; | |
} | |
.intro-view.active { | |
display: block; | |
} | |
.intro-content { | |
position: relative; | |
width: 100%; | |
height: 100%; | |
display: flex; | |
flex-direction: column; | |
justify-content: center; | |
align-items: center; | |
gap: 40px; | |
} | |
.intro-image { | |
width: 100%; | |
height: 100%; | |
object-fit: contain; | |
position: absolute; | |
top: 0; | |
left: 0; | |
background: black; | |
} | |
.start-game-button { | |
position: absolute; | |
bottom: 100px; | |
z-index: 1; | |
padding: 20px 40px; | |
font-size: 24px; | |
background-color: rgba(255, 68, 68, 0.9); | |
color: white; | |
border: none; | |
border-radius: 8px; | |
cursor: pointer; | |
transition: transform 0.2s, background-color 0.2s; | |
box-shadow: 0 4px 8px rgba(0, 0, 0, 0.3); | |
font-family: "Press Start 2P", monospace; | |
animation: float 3s ease-in-out infinite; | |
} | |
.start-game-button:hover { | |
background-color: rgba(255, 102, 102, 0.9); | |
transform: translateY(-2px) scale(1.05); | |
} | |
.start-game-button:active { | |
transform: translateY(0) scale(1); | |
} | |
@keyframes float { | |
0% { | |
transform: translateY(0); | |
} | |
50% { | |
transform: translateY(-20px); | |
} | |
100% { | |
transform: translateY(0); | |
} | |
} | |
/* Add this to flip the left character image */ | |
#leftCharacterImg { | |
transform: scaleX(-1); /* This will mirror the image horizontally */ | |
} | |
#rightCharacterImg { | |
transform: scaleX(-1); /* This will mirror the image horizontally */ | |
} | |
/* Loading indicator styles */ | |
.loading-indicator { | |
display: none; | |
padding: 20px; | |
text-align: center; | |
color: #666; | |
font-size: 14px; | |
} | |
.loading-dots::after { | |
content: ""; | |
animation: dots 1.5s steps(5, end) infinite; | |
} | |
@keyframes dots { | |
0%, | |
20% { | |
content: ""; | |
} | |
40% { | |
content: "."; | |
} | |
60% { | |
content: ".."; | |
} | |
80%, | |
100% { | |
content: "..."; | |
} | |
} | |
/* Add this to the existing .dialogue-box styles */ | |
.dialogue-box.loading .loading-indicator { | |
display: block; | |
} | |