body {
  font-family: Arial;
  text-align: center;
  background-color: #a1cd87; 
  color: #080808;
}
video {
  border: 3px solid #fff;
  margin-top: 20px;
}
input {
  padding: 10px;
  font-size: 16px;
}
button {
  padding: 10px;
  font-size: 16px;
  margin-left: 5px;
}
.guess-box {
  margin: 20px auto;
  display: flex;
  justify-content: center;
  gap: 10px;
  flex-wrap: wrap; /* optional if screen is narrow */
}
#guess {
  padding: 10px;
  font-size: 1rem;
  border: 2px solid #2e7d32;
  border-radius: 6px;
  background-color: #f9f9f9;
  color: #2e7d32;
  box-sizing: border-box;
}

#submit-btn, #give-up-btn {
  font-family: 'Shrikhand', cursive;
  color: #2e7d32;
  border-radius: 6px;
  border: none;
  background-color: #ffffff;
}

#submit-btn:hover {
  background-color: #c8f0b7;
}

#give-up-btn:hover {
  background-color: #e8bfbf;
}

.tile-row {
  display: flex;
  gap: 8px;
  margin-top: 16px;
  justify-content: center;
}
.tile {
  width: 100px;
  height: 60px;
  background-color: #e2e2e2;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-weight: bold;
  font-size: 14px;
}
.tile.header {
  background-color: #333;
  color: white;
  font-size: 13px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}


.grid {
  display: grid;
  grid-template-columns: repeat(7, 100px);
  grid-auto-rows: 60px;
  gap: 8px;
  margin-top: 16px;
  justify-content: center;
}
.tile.grid-tile {
  background-color: #f0f0f0;
  border-radius: 6px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 13px;
  font-weight: bold;
}
.match-green {
  background-color: #2e7d32 !important;
  color: #ffffff;
  font-weight: bold;
  border: none;
  box-shadow: 0 0 8px rgba(46, 125, 50, 0.6);
  transition: background-color 0.3s ease;
}
.match-yellow {
  background-color: #f0d72f !important;
  color: #ffffff;
  font-weight: bold;
  border: none;
  box-shadow: 0 0 8px #f0d72f;
  transition: background-color 0.3s ease;
}

/* Top Banner */
#top-banner {
  display: flex;
  justify-content: center;
  align-items: center;
  gap: 24px;
  height: 120px;
  background-color: #2e7d32;
  padding: 0 24px;
}

#banner-logo {
  height: 100px;
  width: auto; /* preserves aspect ratio */
}

#banner-controls {
  display: flex;
  gap: 16px;
  align-items: center;
}

#banner-center {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 8px;
}

#mode-select {
  padding: 6px 12px;
  font-family: 'Shrikhand', cursive;
  font-size: 18px;
  color: #2e7d32;
  border-radius: 6px;
  border: none;
}

#sub-title {
  font-family: 'Shrikhand', cursive;
  color: #2e7d32;
  border-radius: 6px;
  border: none;
}

@media (max-width: 600px) {
  #top-banner {
    flex-direction: column;
    height: auto;
    padding: 16px;
  }

  #banner-logo {
    height: 80px;
  }
}

/* ─── Help Modal ─────────────────────────────────────────────────────────── */
.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0,0,0,0.6);
  display: flex;
  justify-content: center;
  align-items: center;
  z-index: 9998;
}

.modal.hidden {
  display: none;
}

.modal-content {
  background: rgb(163, 226, 144);
  padding: 24px 32px;
  border-radius: 12px;
  max-width: 500px;
  text-align: left;
  color: #333;
  box-shadow: 0 8px 24px rgba(0,0,0,0.3);
}

#help-button {
  background-color: #ffffff;
  color: #2e7d32;
  border: 2px solid #ffffff;
  padding: 8px 16px;
  border-radius: 6px;
  cursor: pointer;
  font-family: 'Shrikhand', cursive;
  font-size: 18px;
}

#help-button:hover {
  background-color: #e1e0e0;
}

.contact-button {
  background-color: #ffffff;
  color: #2e7d32;
  border: 2px solid #ffffff;
  padding: 8px 16px;
  border-radius: 6px;
  cursor: pointer;
  font-family: 'Shrikhand', cursive;
  font-size: 18px;
  text-decoration: none;
}
.contact-button:hover {
  background-color: #e1e0e0;
}


/* ─── End Round Tile (Inline Replacement) ───────────────────────────────── */
#end-round-tile {
  display: none;
  background-color: #f4dac3;
  border: 2px solid #2e7d32;
  padding: 20px;
  color: #2e7d32;
  text-align: center;
  margin: 30px auto;
  max-width: 500px;
  border-radius: 12px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

#end-round-tile.visible {
  display: block;
}

#end-round-message {
  font-family: 'Shrikhand', cursive;
  font-size: 20px;
  margin-bottom: 16px;
}

#end-round-actions {
  display: flex;
  justify-content: center;
  flex-wrap: wrap;
  gap: 12px;
}

#end-round-actions button {
  background-color: #ffffff;
  color: #2e7d32;
  border: 2px solid #2e7d32;
  font-family: 'Shrikhand', cursive;
  padding: 10px 20px;
  border-radius: 6px;
  cursor: pointer;
  font-size: 16px;
  transition: background-color 0.2s ease;
}

#end-round-actions button:hover {
  background-color: #d8f2cd;
}

/* Shake Animation for invalid guess */
.feedback-message {
  font-family: 'Shrikhand', cursive;
  margin-top: 8px;
  font-size: 1rem;
  color: rgb(246, 50, 50);
  text-align: center;
  min-height: 1.2em; /* prevents layout shift */
}

.shake {
  animation: shake 0.3s;
}

@keyframes shake {
  0% { transform: translateX(0); }
  25% { transform: translateX(-5px); }
  50% { transform: translateX(5px); }
  75% { transform: translateX(-5px); }
  100% { transform: translateX(0); }
}

/*Toast for clipboard message*/
.toast {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  background: #333;
  color: #fff;
  padding: 10px 16px;
  border-radius: 6px;
  font-size: 14px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.4s ease, transform 0.4s ease;
  z-index: 1000;
}

.toast.show {
  opacity: 1;
  transform: translateX(-50%) translateY(-10px);
}

/*Right Side Ad*/
.sidebar-ad {
  position: fixed;
  top: 100px;
  right: 10px;
  width: 160px;
  height: 600px;
  z-index: 1000;
}

/* Hide on Mobile */
@media (max-width: 768px) {
  .sidebar-ad {
    display: none;
  }
}


