:root {
  --bg-primary: #0a0e14;
  --bg-card: #111318;
  --bg-input: #0d1117;
  --border-color: rgba(255, 255, 255, 0.08);
  --text-primary: #fff;
  --text-secondary: rgba(255, 255, 255, 0.5);
  --accent-green: #10b981;
  --accent-cyan: #06b6d4;
  --accent-red: #ef4444;
}

* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

html {
  background: #0a0e14 !important;
  background-color: #0a0e14 !important;
}

body {
  font-family: 'Inter', system-ui, -apple-system, sans-serif;
  background: #0a0e14 !important;
  background-color: #0a0e14 !important;
  color: var(--text-primary, #fff);
  min-height: 100vh;
  padding-bottom: env(safe-area-inset-bottom);
}

.header {
  display: flex;
  align-items: center;
  padding: 1rem;
  position: sticky;
  top: 0;
  background: #0a0e14 !important;
  background-color: #0a0e14 !important;
  z-index: 10;
  border-bottom: 1px solid var(--border-color);
}

.back-btn {
  width: 40px;
  height: 40px;
  display: flex;
  align-items: center;
  justify-content: center;
  background: none;
  border: none;
  color: var(--text-primary);
  cursor: pointer;
}

.header-title {
  flex: 1;
  text-align: center;
  font-size: 1.1rem;
  font-weight: 600;
  margin-right: 40px;
}

.main-content {
  padding: 1.5rem 1rem;
  max-width: 480px;
  margin: 0 auto;
}

.profile-section {
  text-align: center;
  padding: 1.5rem;
  margin-bottom: 1.5rem;
}

.profile-avatar {
  width: 80px;
  height: 80px;
  border-radius: 50%;
  background: linear-gradient(135deg, var(--accent-orange), #ea580c);
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem;
  font-size: 2rem;
  font-weight: 700;
  color: #fff;
}

.profile-name {
  font-size: 1.25rem;
  font-weight: 600;
  margin-bottom: 0.25rem;
}

.profile-email {
  font-size: 0.9rem;
  color: var(--text-secondary);
}

.profile-uid {
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-top: 0.5rem;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.copy-uid {
  background: none;
  border: none;
  color: var(--accent-orange);
  cursor: pointer;
  padding: 0.25rem;
}

.section-title {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin: 1.5rem 0 0.75rem;
}

.settings-list {
  background: rgba(13, 17, 23, 0.9) !important;
  border: 1px solid var(--border-color);
  border-radius: 0.75rem;
  overflow: hidden;
}

.settings-item {
  display: flex;
  align-items: center;
  padding: 1rem;
  border-bottom: 1px solid var(--border-color);
  cursor: pointer;
  transition: background 0.2s;
}

.settings-item:last-child {
  border-bottom: none;
}

.settings-item:hover {
  background: rgba(13, 17, 23, 0.9) !important;
}

.settings-icon {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: rgba(13, 17, 23, 0.9) !important;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-right: 1rem;
  color: var(--text-secondary);
}

.settings-content {
  flex: 1;
}

.settings-label {
  font-size: 0.95rem;
  font-weight: 500;
  margin-bottom: 0.125rem;
}

.settings-value {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.settings-arrow {
  color: var(--text-secondary);
}

.toggle-switch {
  position: relative;
  width: 48px;
  height: 28px;
  background: rgba(255, 255, 255, 0.15);
  border-radius: 14px;
  cursor: pointer;
  transition: background 0.3s;
}

.toggle-switch::after {
  content: '';
  position: absolute;
  top: 2px;
  left: 2px;
  width: 24px;
  height: 24px;
  background: #fff;
  border-radius: 50%;
  transition: transform 0.3s;
}

.toggle-switch.active {
  background: var(--accent-green);
}

.toggle-switch.active::after {
  transform: translateX(20px);
}

.danger-section {
  margin-top: 2rem;
}

.danger-btn {
  width: 100%;
  padding: 1rem;
  background: rgba(239, 68, 68, 0.1);
  border: 1px solid rgba(239, 68, 68, 0.25);
  border-radius: 0.75rem;
  color: var(--accent-red);
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  margin-bottom: 0.75rem;
  transition: background 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
}

.danger-btn:hover {
  background: rgba(239, 68, 68, 0.15);
}

.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.85);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  z-index: 100;
  opacity: 0;
  visibility: hidden;
  transition: all 0.25s;
}

.modal-overlay.active {
  opacity: 1;
  visibility: visible;
}

.modal {
  background: #1a1a1a;
  border-radius: 1rem;
  padding: 1.5rem;
  max-width: 340px;
  width: 100%;
  transform: scale(0.9);
  transition: transform 0.25s;
}

.modal-overlay.active .modal {
  transform: scale(1);
}

.modal-icon {
  width: 64px;
  height: 64px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin: 0 auto 1rem;
}

.modal-icon.warning {
  background: rgba(239, 68, 68, 0.15);
  color: var(--accent-red);
}

.modal-title {
  font-size: 1.1rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
  text-align: center;
}

.modal-text {
  font-size: 0.9rem;
  color: var(--text-secondary);
  text-align: center;
  margin-bottom: 1rem;
  line-height: 1.5;
}

.form-group {
  margin-bottom: 1rem;
}

.form-label {
  display: block;
  font-size: 0.85rem;
  margin-bottom: 0.5rem;
  color: var(--text-secondary);
}

.form-input {
  width: 100%;
  padding: 0.75rem 1rem;
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  color: var(--text-primary);
  font-size: 0.9rem;
  outline: none;
}

.form-input:focus {
  border-color: var(--accent-orange);
}

.modal-btn {
  width: 100%;
  padding: 0.75rem;
  border: none;
  border-radius: 0.5rem;
  font-size: 0.95rem;
  font-weight: 600;
  cursor: pointer;
  margin-top: 0.5rem;
}

.modal-btn.primary {
  background: linear-gradient(135deg, var(--accent-orange), #ea580c);
  color: #fff;
}

.modal-btn.danger {
  background: var(--accent-red);
  color: #fff;
}

.modal-btn.secondary {
  background: rgba(255, 255, 255, 0.1);
  color: #fff;
}

/* Language Items */
.lang-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  cursor: pointer;
  border-radius: 0.5rem;
  transition: background 0.2s;
  font-size: 0.95rem;
}

.lang-item:hover {
  background: rgba(13, 17, 23, 0.9) !important;
}

.lang-item.selected {
  background: rgba(245, 158, 11, 0.15);
  color: var(--accent-orange);
}

.lang-flag {
  font-size: 1.25rem;
}

#languageSearch {
  background: var(--bg-input);
  border: 1px solid var(--border-color);
  border-radius: 0.5rem;
  padding: 0.75rem 1rem;
  color: var(--text-primary);
  width: 100%;
}

#languageSearch:focus {
  outline: none;
  border-color: var(--accent-orange);
}

#languageSearch::placeholder {
  color: var(--text-secondary);
}

.toast {
  position: fixed;
  bottom: 2rem;
  left: 50%;
  transform: translateX(-50%) translateY(100px);
  background: var(--accent-green);
  color: #fff;
  padding: 0.75rem 1.5rem;
  border-radius: 0.5rem;
  font-size: 0.9rem;
  font-weight: 500;
  opacity: 0;
  transition: all 0.3s;
  z-index: 100;
}

.toast.show {
  transform: translateX(-50%) translateY(0);
  opacity: 1;
}

.inline-style-2c8110d4ee {
  max-width: 400px;
}

.inline-style-f267e3ca68 {
  margin-bottom: 1rem;
}

.inline-style-8c3ecf0432 {
  max-height: 350px;
  overflow-y: auto;
}

.inline-style-067d8a829f {
  border: none;
}

.inline-style-04c14b5508 {
  max-height: 300px;
  overflow-y: auto;
}

/* Theme Toggle */
.theme-toggle-group {
  display: flex;
  gap: 0.25rem;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 0.5rem;
  padding: 0.25rem;
}

.theme-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 32px;
  height: 32px;
  border: none;
  border-radius: 0.375rem;
  background: transparent;
  color: var(--text-secondary);
  cursor: pointer;
  transition: all 0.2s;
}

.theme-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  color: var(--text-primary);
}

.theme-btn.active {
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  color: #fff;
  box-shadow: 0 2px 8px rgba(99, 102, 241, 0.4);
}

/* Light mode overrides for theme toggle */
html.theme-light .theme-toggle-group {
  background: rgba(15, 23, 42, 0.06);
}

html.theme-light .theme-btn {
  color: rgba(15, 23, 42, 0.5);
}

html.theme-light .theme-btn:hover {
  background: rgba(15, 23, 42, 0.1);
  color: #0f172a;
}

html.theme-light .theme-btn.active {
  background: linear-gradient(135deg, #6366f1, #8b5cf6);
  color: #fff;
}