/**
 * Telephone Game - CSS Styles
 * ===========================
 *
 * Styling for the V-Model demonstration exercise.
 * Follows the same design language as the quiz system.
 */

/* ============================================
   CONTAINER & LAYOUT
   ============================================ */

.telephone-game-container {
  max-width: 800px;
  margin: 0 auto;
  padding: 1rem;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', Roboto, Oxygen, Ubuntu, sans-serif;
}

.tg-section {
  margin-bottom: 2rem;
}

/* ============================================
   HEADER
   ============================================ */

.tg-header {
  text-align: center;
  margin-bottom: 2rem;
  padding-bottom: 1rem;
  border-bottom: 2px solid #e5e7eb;
}

.tg-title {
  font-size: 1.75rem;
  font-weight: 700;
  margin-bottom: 0.5rem;
  color: #1f2937 !important;
}

.tg-subtitle {
  font-size: 1rem;
  color: #4b5563 !important;
  margin: 0;
}

/* Dark mode - media query */
@media (prefers-color-scheme: dark) {
  .tg-title {
    color: #ffffff !important;
  }
  .tg-subtitle {
    color: #d1d5db !important;
  }
  .tg-header {
    border-bottom-color: #374151;
  }
}

/* Dark mode - data attribute (theme toggle) */
html[data-theme="dark"] .tg-title {
  color: #ffffff !important;
}
html[data-theme="dark"] .tg-subtitle {
  color: #d1d5db !important;
}
html[data-theme="dark"] .tg-header {
  border-bottom-color: #374151;
}

/* ============================================
   AUTHENTICATION
   ============================================ */

.tg-auth {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  padding: 0.75rem 1rem;
  background: #f9fafb;
  border-radius: 8px;
  margin-bottom: 1rem;
  border: 1px solid #e5e7eb;
}

.tg-auth-state {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.tg-loading-spinner {
  width: 20px;
  height: 20px;
  border: 2px solid #e5e7eb;
  border-top-color: #3b82f6;
  border-radius: 50%;
  animation: tg-spin 0.8s linear infinite;
}

@keyframes tg-spin {
  to { transform: rotate(360deg); }
}

.tg-btn-github {
  display: inline-flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.5rem 1rem;
  background: #24292e;
  color: white;
  border: none;
  border-radius: 6px;
  font-size: 0.875rem;
  font-weight: 500;
  cursor: pointer;
  transition: background 0.2s ease;
}

.tg-btn-github:hover {
  background: #1a1e22;
}

.tg-btn-github svg {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

.tg-auth-prompt {
  font-size: 0.875rem;
  color: #6b7280;
}

.tg-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  border: 2px solid #e5e7eb;
}

.tg-user-info {
  display: flex;
  align-items: center;
  gap: 0.75rem;
}

.tg-user-name {
  font-weight: 500;
  color: #374151;
}

.tg-instructor-auth-badge {
  display: inline-block;
  padding: 0.25rem 0.5rem;
  background: #fef3c7;
  color: #92400e;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.tg-btn-logout {
  padding: 0.375rem 0.75rem;
  background: transparent;
  color: #6b7280;
  border: 1px solid #d1d5db;
  border-radius: 4px;
  font-size: 0.75rem;
  cursor: pointer;
  transition: all 0.2s ease;
}

.tg-btn-logout:hover {
  background: #f3f4f6;
  color: #374151;
}

@media (prefers-color-scheme: dark) {
  .tg-auth {
    background: #1f2937;
    border-color: #374151;
  }
  .tg-loading-spinner {
    border-color: #4b5563;
    border-top-color: #60a5fa;
  }
  .tg-auth-prompt {
    color: #9ca3af;
  }
  .tg-avatar {
    border-color: #4b5563;
  }
  .tg-user-name {
    color: #e5e7eb;
  }
  .tg-instructor-auth-badge {
    background: #422006;
    color: #fcd34d;
  }
  .tg-btn-logout {
    color: #9ca3af;
    border-color: #4b5563;
  }
  .tg-btn-logout:hover {
    background: #374151;
    color: #e5e7eb;
  }
}

html[data-theme="dark"] .tg-auth {
  background: #1f2937;
  border-color: #374151;
}
html[data-theme="dark"] .tg-loading-spinner {
  border-color: #4b5563;
  border-top-color: #60a5fa;
}
html[data-theme="dark"] .tg-auth-prompt {
  color: #9ca3af;
}
html[data-theme="dark"] .tg-avatar {
  border-color: #4b5563;
}
html[data-theme="dark"] .tg-user-name {
  color: #e5e7eb;
}
html[data-theme="dark"] .tg-instructor-auth-badge {
  background: #422006;
  color: #fcd34d;
}
html[data-theme="dark"] .tg-btn-logout {
  color: #9ca3af;
  border-color: #4b5563;
}
html[data-theme="dark"] .tg-btn-logout:hover {
  background: #374151;
  color: #e5e7eb;
}

/* ============================================
   INTRO / INSTRUCTIONS
   ============================================ */

.tg-intro {
  background: #f9fafb;
  border-radius: 8px;
  padding: 1rem 1.5rem;
  margin-bottom: 2rem;
  border: 1px solid #e5e7eb;
}

.tg-intro h2,
.tg-intro h3 {
  margin-top: 0;
}

@media (prefers-color-scheme: dark) {
  .tg-intro {
    background: #1f2937;
    border-color: #374151;
  }
}

/* ============================================
   BUTTONS
   ============================================ */

.tg-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  padding: 0.75rem 1.5rem;
  font-size: 1rem;
  font-weight: 600;
  border-radius: 8px;
  border: none;
  cursor: pointer;
  transition: all 0.2s ease;
  text-decoration: none;
}

.tg-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

.tg-btn-primary {
  background: #2563eb;
  color: white;
}

.tg-btn-primary:hover:not(:disabled) {
  background: #1d4ed8;
}

.tg-btn-secondary {
  background: #f3f4f6;
  color: #374151;
  border: 1px solid #d1d5db;
}

.tg-btn-secondary:hover:not(:disabled) {
  background: #e5e7eb;
}

.tg-btn-large {
  padding: 1rem 2rem;
  font-size: 1.125rem;
}

@media (prefers-color-scheme: dark) {
  .tg-btn-secondary {
    background: #374151;
    color: #f3f4f6;
    border-color: #4b5563;
  }
  .tg-btn-secondary:hover:not(:disabled) {
    background: #4b5563;
  }
}

/* ============================================
   INPUTS
   ============================================ */

.tg-input {
  width: 100%;
  padding: 0.75rem 1rem;
  font-size: 1rem;
  border: 2px solid #d1d5db;
  border-radius: 8px;
  background: white;
  transition: border-color 0.2s ease;
  box-sizing: border-box;
}

.tg-input:focus {
  outline: none;
  border-color: #2563eb;
}

.tg-input-group {
  margin-bottom: 1rem;
}

.tg-input-group label {
  display: block;
  margin-bottom: 0.5rem;
  font-weight: 600;
  color: #374151;
}

.tg-textarea {
  width: 100%;
  padding: 1rem;
  font-size: 1rem;
  border: 2px solid #d1d5db;
  border-radius: 8px;
  resize: vertical;
  min-height: 150px;
  font-family: inherit;
  line-height: 1.5;
  box-sizing: border-box;
}

.tg-textarea:focus {
  outline: none;
  border-color: #2563eb;
}

.tg-textarea:disabled {
  background: #f3f4f6;
  color: #6b7280;
}

.tg-select {
  padding: 0.5rem 1rem;
  font-size: 1rem;
  border: 2px solid #d1d5db;
  border-radius: 8px;
  background: white;
  cursor: pointer;
  box-sizing: border-box;
}

@media (prefers-color-scheme: dark) {
  .tg-input,
  .tg-textarea,
  .tg-select {
    background: #1f2937;
    border-color: #4b5563;
    color: #f3f4f6;
  }
  .tg-input-group label {
    color: #e5e7eb;
  }
  .tg-textarea:disabled {
    background: #374151;
    color: #9ca3af;
  }
}

/* ============================================
   LOBBY / JOIN SECTION
   ============================================ */

.tg-join-box {
  max-width: 400px;
  margin: 0 auto;
  background: white;
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  border: 1px solid #e5e7eb;
}

.tg-join-box h2 {
  margin-top: 0;
  margin-bottom: 1.5rem;
  text-align: center;
  color: #1f2937;
}

.tg-join-box .tg-btn {
  width: 100%;
  margin-top: 0.5rem;
}

.tg-divider {
  display: flex;
  align-items: center;
  margin: 1.5rem 0;
  color: #9ca3af;
}

.tg-divider::before,
.tg-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: #e5e7eb;
}

.tg-divider span {
  padding: 0 1rem;
  font-size: 0.875rem;
}

@media (prefers-color-scheme: dark) {
  .tg-join-box {
    background: #1f2937;
    border-color: #374151;
  }
  .tg-join-box h2 {
    color: #f3f4f6;
  }
  .tg-divider::before,
  .tg-divider::after {
    background: #4b5563;
  }
}

/* ============================================
   WAITING ROOM
   ============================================ */

.tg-waiting-box {
  background: white;
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  border: 1px solid #e5e7eb;
}

.tg-waiting-box h2 {
  margin-top: 0;
  text-align: center;
}

.tg-room-code-display {
  text-align: center;
  padding: 1rem;
  background: #f3f4f6;
  border-radius: 8px;
  margin-bottom: 1.5rem;
}

.tg-room-label {
  display: block;
  font-size: 0.875rem;
  color: #6b7280;
  margin-bottom: 0.25rem;
}

.tg-room-code {
  font-size: 2.5rem;
  font-weight: 700;
  font-family: 'Courier New', monospace;
  letter-spacing: 0.25em;
  color: #2563eb;
}

.tg-participants h3 {
  font-size: 1rem;
  margin-bottom: 0.75rem;
  color: #374151;
}

.tg-participant-list {
  list-style: none;
  padding: 0;
  margin: 0;
  display: grid;
  gap: 0.5rem;
}

.tg-participant-item {
  display: flex;
  align-items: center;
  padding: 0.5rem 0.75rem;
  background: #f9fafb;
  border-radius: 6px;
  gap: 0.75rem;
}

.tg-participant-self {
  background: #dbeafe;
  border: 1px solid #93c5fd;
}

.tg-participant-position {
  width: 24px;
  height: 24px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #e5e7eb;
  border-radius: 50%;
  font-size: 0.75rem;
  font-weight: 600;
  color: #374151;
}

.tg-participant-name {
  flex: 1;
  font-weight: 500;
}

.tg-instructor-badge {
  color: #f59e0b;
  font-size: 1rem;
}

.tg-instructor-controls {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid #e5e7eb;
  text-align: center;
}

.tg-instructor-hint {
  font-size: 0.875rem;
  color: #6b7280;
  margin-bottom: 1rem;
}

.tg-duration-selector {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.75rem;
  margin-bottom: 1.25rem;
  padding: 0.75rem 1rem;
  background: #f9fafb;
  border-radius: 8px;
  border: 1px solid #e5e7eb;
}

.tg-duration-selector label {
  font-size: 0.875rem;
  font-weight: 500;
  color: #374151;
}

.tg-duration-selector .tg-select {
  min-width: 160px;
}

@media (prefers-color-scheme: dark) {
  .tg-duration-selector {
    background: #374151;
    border-color: #4b5563;
  }
  .tg-duration-selector label {
    color: #e5e7eb;
  }
}

.tg-waiting-message {
  text-align: center;
  color: #6b7280;
  font-style: italic;
  margin-top: 1.5rem;
}

@media (prefers-color-scheme: dark) {
  .tg-waiting-box {
    background: #1f2937;
    border-color: #374151;
  }
  .tg-room-code-display {
    background: #374151;
  }
  .tg-room-code {
    color: #60a5fa;
  }
  .tg-participants h3 {
    color: #e5e7eb;
  }
  .tg-participant-item {
    background: #374151;
  }
  .tg-participant-self {
    background: #1e3a5f;
    border-color: #3b82f6;
  }
  .tg-participant-position {
    background: #4b5563;
    color: #e5e7eb;
  }
  .tg-instructor-controls {
    border-top-color: #4b5563;
  }
}

/* ============================================
   ACTIVE ROUND
   ============================================ */

.tg-round-box {
  background: white;
  border-radius: 12px;
  padding: 1.5rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  border: 1px solid #e5e7eb;
}

.tg-round-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 1.5rem;
  padding-bottom: 1rem;
  border-bottom: 1px solid #e5e7eb;
}

.tg-round-info {
  display: flex;
  align-items: center;
  gap: 1rem;
}

.tg-round-number {
  font-size: 1.25rem;
  font-weight: 600;
  color: #374151;
}

.tg-role-badge {
  display: inline-block;
  padding: 0.25rem 0.75rem;
  border-radius: 9999px;
  font-size: 0.875rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.tg-role-badge.role-1 {
  background: #dcfce7;
  color: #166534;
}

.tg-role-badge.role-2 {
  background: #dbeafe;
  color: #1e40af;
}

.tg-role-badge.role-3 {
  background: #fef3c7;
  color: #92400e;
}

.tg-role-badge.role-4 {
  background: #fce7f3;
  color: #9d174d;
}

.tg-timer {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  font-size: 1.5rem;
  font-weight: 700;
  font-family: 'Courier New', monospace;
  color: #374151;
}

.tg-timer-icon {
  font-size: 1.25rem;
}

.tg-timer-warning .tg-timer-value {
  color: #f59e0b;
}

.tg-timer-critical .tg-timer-value {
  color: #ef4444;
  animation: pulse 1s infinite;
}

@keyframes pulse {
  0%, 100% { opacity: 1; }
  50% { opacity: 0.5; }
}

.tg-role-description {
  background: #f3f4f6;
  padding: 1rem;
  border-radius: 8px;
  margin-bottom: 1.5rem;
  font-size: 1rem;
  line-height: 1.5;
  color: #374151;
}

.tg-previous-input {
  margin-bottom: 1.5rem;
}

.tg-previous-input h4,
.tg-current-input h4 {
  font-size: 0.875rem;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: #6b7280;
  margin-bottom: 0.5rem;
}

.tg-previous-text {
  background: #fefce8;
  border: 1px solid #fde047;
  border-radius: 8px;
  padding: 1rem;
  white-space: pre-wrap;
  font-family: inherit;
  line-height: 1.5;
}

.tg-compare-box {
  display: grid;
  gap: 1rem;
}

.tg-compare-original,
.tg-compare-final {
  padding: 1rem;
  border-radius: 8px;
}

.tg-compare-original {
  background: #dcfce7;
  border: 1px solid #86efac;
}

.tg-compare-final {
  background: #fee2e2;
  border: 1px solid #fca5a5;
}

.tg-compare-original strong,
.tg-compare-final strong {
  display: block;
  margin-bottom: 0.5rem;
  font-size: 0.875rem;
}

.tg-auto-save {
  font-size: 0.75rem;
  color: #9ca3af;
  margin-top: 0.5rem;
  text-align: right;
}

.tg-round-controls {
  margin-top: 1.5rem;
  padding-top: 1.5rem;
  border-top: 1px solid #e5e7eb;
  text-align: center;
}

@media (prefers-color-scheme: dark) {
  .tg-round-box {
    background: #1f2937;
    border-color: #374151;
  }
  .tg-round-header {
    border-bottom-color: #4b5563;
  }
  .tg-round-number {
    color: #e5e7eb;
  }
  .tg-timer {
    color: #e5e7eb;
  }
  .tg-role-description {
    background: #374151;
    color: #e5e7eb;
  }
  .tg-previous-text {
    background: #422006;
    border-color: #854d0e;
  }
  .tg-round-controls {
    border-top-color: #4b5563;
  }
}

/* ============================================
   RESULTS
   ============================================ */

.tg-results-box {
  background: white;
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  border: 1px solid #e5e7eb;
}

.tg-results-box h2 {
  margin-top: 0;
  text-align: center;
}

.tg-results-intro {
  text-align: center;
  color: #6b7280;
  margin-bottom: 1.5rem;
}

.tg-chain-selector {
  display: flex;
  align-items: center;
  gap: 1rem;
  margin-bottom: 2rem;
  justify-content: center;
}

.tg-chain-selector label {
  font-weight: 600;
  color: #374151;
}

.tg-chain-display {
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  overflow: hidden;
}

.tg-chain-step {
  padding: 1.5rem;
  border-bottom: 1px solid #e5e7eb;
}

.tg-chain-step:last-child {
  border-bottom: none;
}

.tg-chain-header {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  margin-bottom: 0.75rem;
}

.tg-chain-round {
  width: 28px;
  height: 28px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: #e5e7eb;
  border-radius: 50%;
  font-weight: 700;
  font-size: 0.875rem;
}

.tg-chain-role {
  font-size: 0.75rem;
  font-weight: 700;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
}

.tg-chain-role.customer {
  background: #dcfce7;
  color: #166534;
}

.tg-chain-role.analyst {
  background: #dbeafe;
  color: #1e40af;
}

.tg-chain-role.developer {
  background: #fef3c7;
  color: #92400e;
}

.tg-chain-role.tester {
  background: #fce7f3;
  color: #9d174d;
}

.tg-chain-author {
  color: #6b7280;
  font-size: 0.875rem;
  margin-left: auto;
}

.tg-chain-text {
  background: #f9fafb;
  padding: 1rem;
  border-radius: 8px;
  white-space: pre-wrap;
  line-height: 1.5;
  min-height: 60px;
}

.tg-chain-arrow {
  text-align: center;
  font-size: 1.5rem;
  color: #9ca3af;
  padding: 0.5rem;
  background: #f3f4f6;
}

.tg-chain-final {
  background: #fffbeb;
}

.tg-discussion {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid #e5e7eb;
}

.tg-discussion h3 {
  margin-top: 0;
  margin-bottom: 1rem;
  color: #374151;
}

.tg-discussion ul {
  margin: 0;
  padding-left: 1.5rem;
}

.tg-discussion li {
  margin-bottom: 0.5rem;
  line-height: 1.5;
}

.tg-new-game {
  margin-top: 2rem;
  padding-top: 1.5rem;
  border-top: 1px solid #e5e7eb;
  text-align: center;
}

@media (prefers-color-scheme: dark) {
  .tg-results-box {
    background: #1f2937;
    border-color: #374151;
  }
  .tg-chain-selector label {
    color: #e5e7eb;
  }
  .tg-chain-display {
    border-color: #4b5563;
  }
  .tg-chain-step {
    border-bottom-color: #4b5563;
  }
  .tg-chain-round {
    background: #4b5563;
  }
  .tg-chain-text {
    background: #374151;
  }
  .tg-chain-arrow {
    background: #374151;
  }
  .tg-chain-final {
    background: #422006;
  }
  .tg-discussion {
    border-top-color: #4b5563;
  }
  .tg-discussion h3 {
    color: #e5e7eb;
  }
  .tg-new-game {
    border-top-color: #4b5563;
  }
}

/* ============================================
   ROOM HISTORY
   ============================================ */

.tg-history-box {
  background: white;
  border-radius: 12px;
  padding: 2rem;
  box-shadow: 0 4px 6px -1px rgba(0, 0, 0, 0.1);
  border: 1px solid #e5e7eb;
}

.tg-history-box h2 {
  margin-top: 0;
  text-align: center;
}

.tg-history-intro {
  text-align: center;
  color: #6b7280;
  margin-bottom: 1.5rem;
}

.tg-history-filters {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
}

.tg-filter-btn {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
  font-weight: 500;
  border: 2px solid #e5e7eb;
  border-radius: 8px;
  background: white;
  color: #6b7280;
  cursor: pointer;
  transition: all 0.2s ease;
}

.tg-filter-btn:hover {
  border-color: #2563eb;
  color: #2563eb;
}

.tg-filter-btn.tg-filter-active {
  background: #2563eb;
  border-color: #2563eb;
  color: white;
}

.tg-room-list {
  display: grid;
  gap: 1rem;
  margin-bottom: 1.5rem;
  max-height: 500px;
  overflow-y: auto;
}

.tg-room-card {
  background: #f9fafb;
  border-radius: 8px;
  padding: 1rem;
  border: 2px solid #e5e7eb;
  transition: all 0.2s ease;
}

.tg-room-card:hover {
  border-color: #2563eb;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.05);
}

.tg-room-card.tg-status-active {
  border-left: 4px solid #3b82f6;
}

.tg-room-card.tg-status-completed {
  border-left: 4px solid #22c55e;
}

.tg-room-card.tg-status-waiting {
  border-left: 4px solid #f59e0b;
}

.tg-room-card-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 0.75rem;
  padding-bottom: 0.75rem;
  border-bottom: 1px solid #e5e7eb;
}

.tg-room-code-badge {
  font-family: 'Courier New', monospace;
  font-size: 1.25rem;
  font-weight: 700;
  color: #2563eb;
  letter-spacing: 0.1em;
}

.tg-room-status-badge {
  padding: 0.25rem 0.5rem;
  border-radius: 4px;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  background: #e5e7eb;
  color: #374151;
}

.tg-room-card.tg-status-active .tg-room-status-badge {
  background: #dbeafe;
  color: #1e40af;
}

.tg-room-card.tg-status-completed .tg-room-status-badge {
  background: #dcfce7;
  color: #166534;
}

.tg-room-card-body {
  display: grid;
  gap: 0.5rem;
  margin-bottom: 0.75rem;
}

.tg-room-info-row {
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.tg-room-label {
  font-size: 0.875rem;
  color: #6b7280;
}

.tg-room-value {
  font-size: 0.875rem;
  font-weight: 600;
  color: #374151;
}

.tg-room-card-actions {
  display: flex;
  justify-content: flex-end;
}

.tg-btn-small {
  padding: 0.5rem 1rem;
  font-size: 0.875rem;
}

.tg-empty-state {
  text-align: center;
  padding: 2rem;
  color: #9ca3af;
}

.tg-history-actions {
  text-align: center;
  padding-top: 1.5rem;
  border-top: 1px solid #e5e7eb;
}

@media (prefers-color-scheme: dark) {
  .tg-history-box {
    background: #1f2937;
    border-color: #374151;
  }
  .tg-filter-btn {
    background: #374151;
    border-color: #4b5563;
    color: #9ca3af;
  }
  .tg-filter-btn:hover {
    border-color: #60a5fa;
    color: #60a5fa;
  }
  .tg-room-card {
    background: #374151;
    border-color: #4b5563;
  }
  .tg-room-card:hover {
    border-color: #60a5fa;
  }
  .tg-room-card-header {
    border-bottom-color: #4b5563;
  }
  .tg-room-code-badge {
    color: #60a5fa;
  }
  .tg-room-status-badge {
    background: #4b5563;
    color: #e5e7eb;
  }
  .tg-room-value {
    color: #e5e7eb;
  }
  .tg-history-actions {
    border-top-color: #4b5563;
  }
}

/* ============================================
   NOTIFICATIONS
   ============================================ */

.tg-notifications {
  position: fixed;
  bottom: 1rem;
  right: 1rem;
  z-index: 1000;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
  max-width: 350px;
}

.tg-notification {
  padding: 0.75rem 1rem;
  border-radius: 8px;
  font-size: 0.875rem;
  font-weight: 500;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
  animation: slideIn 0.3s ease;
}

@keyframes slideIn {
  from {
    transform: translateX(100%);
    opacity: 0;
  }
  to {
    transform: translateX(0);
    opacity: 1;
  }
}

.tg-notification-fade {
  animation: fadeOut 0.3s ease;
}

@keyframes fadeOut {
  to {
    opacity: 0;
    transform: translateY(10px);
  }
}

.tg-notification-info {
  background: #dbeafe;
  color: #1e40af;
  border: 1px solid #93c5fd;
}

.tg-notification-success {
  background: #dcfce7;
  color: #166534;
  border: 1px solid #86efac;
}

.tg-notification-error {
  background: #fee2e2;
  color: #991b1b;
  border: 1px solid #fca5a5;
}

/* ============================================
   RESPONSIVE
   ============================================ */

@media (max-width: 640px) {
  .telephone-game-container {
    padding: 0.5rem;
  }

  .tg-title {
    font-size: 1.5rem;
  }

  .tg-join-box,
  .tg-waiting-box,
  .tg-round-box,
  .tg-results-box {
    padding: 1rem;
  }

  .tg-room-code {
    font-size: 2rem;
  }

  .tg-round-header {
    flex-direction: column;
    gap: 1rem;
    text-align: center;
  }

  .tg-timer {
    font-size: 1.25rem;
  }

  .tg-chain-header {
    flex-wrap: wrap;
  }

  .tg-chain-author {
    width: 100%;
    margin-left: 0;
    margin-top: 0.25rem;
  }

  .tg-notifications {
    left: 1rem;
    right: 1rem;
    max-width: none;
  }
}
