body {
    font-family: 'Noto Sans Gujarati', Arial, sans-serif;
    background-color: #f0f2f5;
    color: #333;
    display: flex;
    justify-content: center;
    align-items: center;
    min-height: 100vh;
    margin: 0;
}

.main-container {
    background-color: white;
    padding: 25px;
    border-radius: 10px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    width: 90%;
    max-width: 900px;
    text-align: center;
}

h1 {
    color: #0056b3;
}

.setup-area {
    display: flex;
    justify-content: center;
    gap: 30px;
    margin-bottom: 20px;
}

.team-setup input {
    width: 80px;
    font-size: 1.2em;
    text-align: center;
    border: 2px solid #ccc;
    border-radius: 5px;
}

.competition-area {
    display: flex;
    justify-content: space-around;
    gap: 20px;
    margin-top: 20px;
}

.team-column {
    width: 48%;
    border: 1px solid #ddd;
    border-radius: 8px;
    padding: 15px;
    background-color: #fafafa;
}

.speak-btn, .controls button {
    background-color: #28a745;
    color: white;
    border: none;
    padding: 10px 20px;
    font-size: 1em;
    border-radius: 5px;
    cursor: pointer;
    margin-bottom: 15px;
    transition: background-color 0.3s;
}

.speak-btn:hover, .controls button:hover {
    background-color: #218838;
}

.speak-btn:disabled {
    background-color: #6c757d !important;
    color: #fff !important;
    cursor: not-allowed !important;
    opacity: 0.5 !important;
}

.controls {
    margin-top: 30px;
    border-top: 1px solid #eee;
    padding-top: 20px;
}

.controls button {
    background-color: #007bff;
    margin: 0 10px;
    font-weight: bold;
    min-width: 120px;
    position: relative;
    z-index: 10;
}

.controls button:hover {
    background-color: #0056b3;
    transform: translateY(-2px);
    box-shadow: 0 4px 8px rgba(0,0,0,0.2);
}

.controls button:active {
    transform: translateY(0);
    box-shadow: 0 2px 4px rgba(0,0,0,0.2);
}

/* End button styling */
#end-btn {
    background: linear-gradient(135deg, #dc3545, #c82333);
    font-size: 16px;
    padding: 12px 24px;
    border: 2px solid #dc3545;
}

#end-btn:hover {
    background: linear-gradient(135deg, #c82333, #bd2130);
    transform: translateY(-3px);
    box-shadow: 0 6px 15px rgba(220, 53, 69, 0.4);
}

/* Modal styling */
.modal {
    display: none;
    position: fixed;
    z-index: 1000;
    left: 0;
    top: 0;
    width: 100%;
    height: 100%;
    background-color: rgb(0 0 0 / 50%);
    justify-content: center;
    align-items: center;
}

.modal-content {
    background: #fff;
    padding: 30px;
    border-radius: 12px;
    width: 90%;
    max-width: 500px;
    text-align: center;
    position: relative;
    overflow: hidden;
}

.winner-announcement h2 {
    color: #28a745;
    margin-bottom: 15px;
}

.winner-team {
    font-size: 1.5em;
    font-weight: bold;
    margin: 10px 0;
    color: #333;
}

.final-scores {
    margin-top: 15px;
}

.score-display {
    font-size: 1.2em;
    margin: 5px 0;
}

.modal-content button {
    margin-top: 20px;
    background-color: #007bff;
    color: white;
    border: none;
    padding: 10px 20px;
    font-size: 1em;
    border-radius: 5px;
    cursor: pointer;
    transition: background-color 0.3s;
}

.modal-content button:hover {
    background-color: #0056b3;
}

/* Confetti */
.confetti {
    position: absolute;
    width: 10px;
    height: 10px;
    top: 0;
    animation: fall linear forwards;
}

@keyframes fall {
    to {
        transform: translateY(100vh) rotate(720deg);
    }
}

/* Word states */
.word-accepted {
  color: green;
  font-weight: bold;
}

.word-repeated {
  color: red;
  text-decoration: line-through;
}

.word-invalid {
  color: #dc3545;
  font-style: italic;
}

/* Floating messages */
.message {
  position: fixed;
  top: 20px;
  left: 50%;
  transform: translateX(-50%);
  padding: 10px 20px;
  border-radius: 6px;
  font-size: 1.1em;
  color: #fff;
  z-index: 2000;
  opacity: 0.95;
  transition: opacity 0.5s ease;
}
.message.success {
  background-color: #28a745;
}
.message.error {
  background-color: #dc3545;
}
.message.warning {
  background-color: #ffc107;
  color: #333;
}
.message.fade-out {
  opacity: 0;
}
