/* Panel Header Layout */
.panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}

.panel-header h1 {
  margin: 0;
  flex-grow: 1;
}

/* Language Selector in Panels */
.language-selector-in-panel {
  margin-left: auto;
}

.language-button-small {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 6px 10px;
  background: var(--gray-1);
  border: none;
  border-radius: 6px;
  cursor: pointer;
  font-size: 11px;
  font-weight: 600;
  color: white;
  transition: all 200ms;
  min-width: 35px;
  height: 28px;
}

.language-button-small:hover {
  background: var(--primary-light);
  color: white;
}

.language-button-small:active {
  background: var(--primary-dark);
  color: white;
}

.language-text {
  font-weight: 600;
  color: inherit;
  font-size: inherit;
}

/* Mobile Responsive */
@media (max-width: 768px) {
  .panel-header {
    flex-direction: column;
    align-items: flex-start;
    gap: 10px;
  }
  
  .language-selector-in-panel {
    margin-left: 0;
    align-self: flex-end;
  }
  
  .language-button-small {
    padding: 5px 8px;
    font-size: 10px;
    min-width: 30px;
    height: 24px;
  }
}

/* Admin panel navbar language selector */
.language-selector-in-nav {
  margin-left: auto;
}

.language-button-nav {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px 12px;
  background: #f8f9fa;
  border: 1px solid #dee2e6;
  border-radius: 6px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
  color: #495057;
  transition: all 200ms;
  min-width: 40px;
  height: 32px;
}

.language-button-nav:hover {
  background: #007bff;
  border-color: #0056b3;
  color: white;
}

.language-button-nav:active {
  background: #0056b3;
  color: white;
}

/* Sign out button */
.sign-out-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 8px 16px;
  background: #dc3545;
  border: 1px solid #dc3545;
  border-radius: 6px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
  color: white;
  transition: all 200ms;
  height: 32px;
  margin-left: 8px;
}

.sign-out-btn:hover {
  background: #c82333;
  border-color: #bd2130;
}

.sign-out-btn:active {
  background: #bd2130;
}

/* Admin panel specific styles */
.admin-page .language-selector-in-panel {
  margin-left: auto;
}

.admin-page .language-button-small {
  background: #f8f9fa;
  border: 1px solid #dee2e6;
  color: #495057;
  box-shadow: 0 2px 4px rgba(0,0,0,0.1);
}

.admin-page .language-button-small:hover {
  background: #007bff;
  border-color: #0056b3;
  color: white;
}

.admin-page .language-button-small:active {
  background: #0056b3;
  color: white;
}

/* Reduced motion */
@media (prefers-reduced-motion: reduce) {
  .language-button-small {
    transition: none;
  }
}