/* ── Reset & Variables ── */
*,
*::before,
*::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

:root {
  --background: #121113;
  --foreground: #c1c1c1;
  --card: #121212;
  --card-foreground: #c1c1c1;
  --popover: #121113;
  --primary: #e78a53;
  --primary-foreground: #121113;
  --secondary: #5f8787;
  --muted: #222222;
  --muted-foreground: #888888;
  --accent: #333333;
  --accent-foreground: #c1c1c1;
  --border: #222222;
  --input: #1a1a1a;
  --ring: #e78a53;
  --font-sans: 'Geist Mono', ui-monospace, monospace;
  --font-mono: 'JetBrains Mono', monospace;
  --radius: 0.75rem;
}

html,
body {
  height: 100%;
  background: var(--background);
  color: var(--foreground);
  font-family: var(--font-sans);
  font-size: 14px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

/* ── App layout ── */
.app {
  display: flex;
  flex-direction: column;
  height: 100vh;
  max-width: 800px;
  margin: 0 auto;
}

/* ── Header ── */
header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 20px;
  border-bottom: 1px solid var(--border);
  flex-shrink: 0;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 10px;
  min-width: 0;
}

.logo-dot {
  width: 8px;
  height: 8px;
  border-radius: 50%;
  background: var(--primary);
  box-shadow: 0 0 8px var(--primary);
  flex-shrink: 0;
  animation: dot-pulse 2.5s ease-in-out infinite;
}

@keyframes dot-pulse {

  0%,
  100% {
    opacity: 1;
    box-shadow: 0 0 8px var(--primary);
  }

  50% {
    opacity: 0.45;
    box-shadow: 0 0 3px var(--primary);
  }
}

.logo-text {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--foreground);
  flex-shrink: 0;
}

.model-badge {
  font-size: 11px;
  font-family: var(--font-mono);
  color: var(--muted-foreground);
  background: var(--muted);
  border: 1px solid var(--border);
  padding: 2px 8px;
  border-radius: 4px;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 220px;
}

.header-actions {
  display: flex;
  align-items: center;
  gap: 6px;
}

/* ── Icon button (shared) ── */
.btn-icon {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--muted-foreground);
  width: 32px;
  height: 32px;
  border-radius: 8px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: color 0.15s, background 0.15s, border-color 0.15s;
}

.btn-icon:hover {
  color: var(--foreground);
  background: var(--accent);
  border-color: var(--accent);
}

.btn-icon svg {
  width: 16px;
  height: 16px;
}

/* ── Messages ── */
.messages {
  flex: 1;
  overflow-y: auto;
  padding: 28px 20px;
  display: flex;
  flex-direction: column;
  gap: 22px;
  scrollbar-width: thin;
  scrollbar-color: var(--border) transparent;
}

.messages::-webkit-scrollbar {
  width: 4px;
}

.messages::-webkit-scrollbar-track {
  background: transparent;
}

.messages::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 2px;
}

/* ── Empty state ── */
.empty-state {
  flex: 1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 10px;
  color: var(--muted-foreground);
  text-align: center;
  pointer-events: none;
  user-select: none;
}

.empty-icon {
  font-size: 28px;
  opacity: 0.25;
  line-height: 1;
}

.empty-state p {
  font-size: 14px;
  color: var(--foreground);
  opacity: 0.35;
}

.empty-state span {
  font-size: 11px;
  font-family: var(--font-mono);
  opacity: 0.25;
}

/* ── Message ── */
.message {
  display: flex;
  flex-direction: column;
  animation: msg-in 0.18s ease;
}

.message.user {
  align-items: flex-end;
}

.message.ai {
  align-items: flex-start;
}

@keyframes msg-in {
  from {
    opacity: 0;
    transform: translateY(8px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.bubble {
  padding: 10px 14px;
  border-radius: 12px;
  font-size: 14px;
  line-height: 1.7;
  word-break: break-word;
  cursor: default;
}

.message.user .bubble {
  background: var(--accent);
  color: var(--accent-foreground);
  border-radius: 12px 4px 12px 12px;
  width: auto;
  max-width: 85%;
}

.message.ai .bubble {
  background: var(--card);
  color: var(--card-foreground);
  border: 1px solid var(--border);
  border-radius: 4px 12px 12px 12px;
  width: 100%;
}

/* ── Markdown ── */
.bubble strong {
  color: var(--foreground);
  font-weight: 600;
}

.bubble em {
  color: var(--primary);
  font-style: italic;
}

.bubble h1,
.bubble h2,
.bubble h3 {
  font-weight: 600;
  color: var(--foreground);
  margin: 12px 0 6px;
  line-height: 1.3;
}

.bubble h1:first-child,
.bubble h2:first-child,
.bubble h3:first-child {
  margin-top: 0;
}

.bubble h1 {
  font-size: 16px;
}

.bubble h2 {
  font-size: 15px;
}

.bubble h3 {
  font-size: 14px;
}

/* ── Lists ── */
.bubble ul,
.bubble ol {
  padding-left: 0;
  margin: 8px 0;
  list-style: none;
}

.bubble ul {
  list-style: none;
}

.bubble ol {
  list-style: none;
  counter-reset: ol-counter;
}

.bubble li {
  position: relative;
  padding-left: 20px;
  margin: 4px 0;
  line-height: 1.6;
}

/* Unordered list - bullet points */
.bubble ul > li::before {
  content: '';
  position: absolute;
  left: 6px;
  top: 10px;
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--primary);
}

/* Nested unordered lists */
.bubble ul ul > li::before {
  background: transparent;
  border: 2px solid var(--primary);
  width: 5px;
  height: 5px;
}

.bubble ul ul ul > li::before {
  border-radius: 0;
  background: var(--primary);
  border: none;
  width: 5px;
  height: 5px;
}

/* Ordered list - numbers */
.bubble ol > li {
  counter-increment: ol-counter;
}

.bubble ol > li::before {
  content: counter(ol-counter) '.';
  position: absolute;
  left: 0;
  top: 0;
  font-weight: 500;
  color: var(--primary);
  font-size: 13px;
  min-width: 16px;
  text-align: right;
}

/* Nested ordered lists */
.bubble ol ol {
  counter-reset: ol-counter-nested;
}

.bubble ol ol > li {
  counter-increment: ol-counter-nested;
}

.bubble ol ol > li::before {
  content: counter(ol-counter) '.' counter(ol-counter-nested);
  font-size: 12px;
  min-width: 24px;
}

.bubble a {
  color: var(--primary);
  text-decoration: underline;
  text-underline-offset: 2px;
}

.bubble blockquote {
  border-left: 2px solid var(--primary);
  padding-left: 12px;
  margin: 6px 0;
  color: var(--muted-foreground);
  font-style: italic;
}

.bubble hr {
  border: none;
  border-top: 1px solid var(--border);
  margin: 10px 0;
}

.bubble pre {
  background: var(--muted);
  border: 1px solid var(--border);
  border-radius: 6px;
  padding: 10px 12px;
  margin: 8px 0;
  overflow-x: auto;
  font-family: var(--font-mono);
  font-size: 12px;
  line-height: 1.55;
  white-space: pre;
}

.bubble :not(pre)>code {
  background: var(--muted);
  border: 1px solid var(--border);
  padding: 1px 5px;
  border-radius: 4px;
  font-family: var(--font-mono);
  font-size: 12px;
  color: var(--primary);
}

/* ── Typing indicator ── */
.typing {
  display: flex;
  gap: 5px;
  align-items: center;
  padding: 4px 0;
}

.typing span {
  width: 5px;
  height: 5px;
  border-radius: 50%;
  background: var(--muted-foreground);
  animation: blink 1.2s ease-in-out infinite;
}

.typing span:nth-child(2) {
  animation-delay: 0.2s;
}

.typing span:nth-child(3) {
  animation-delay: 0.4s;
}

@keyframes blink {

  0%,
  100% {
    opacity: 0.25;
    transform: scale(0.8);
  }

  50% {
    opacity: 1;
    transform: scale(1);
  }
}

/* ── Message actions ── */
.msg-actions {
  display: flex;
  gap: 4px;
  margin-top: 5px;
  padding: 0 2px;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.15s;
}

/* Desktop: show on hover of parent message */
@media (hover: hover) {
  .message:hover .msg-actions {
    opacity: 1;
    pointer-events: all;
  }
}

/* Mobile / touch: show when message has .active class (tap) */
.message.active .msg-actions {
  opacity: 1;
  pointer-events: all;
}

.message.user .msg-actions {
  justify-content: flex-end;
}

.message.ai .msg-actions {
  justify-content: flex-start;
}

.action-btn {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--muted-foreground);
  font-family: var(--font-mono);
  font-size: 10px;
  letter-spacing: 0.05em;
  padding: 3px 8px;
  border-radius: 5px;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 4px;
  transition: color 0.12s, background 0.12s, border-color 0.12s;
  height: 22px;
  white-space: nowrap;
}

.action-btn:hover {
  color: var(--foreground);
  background: var(--accent);
  border-color: var(--accent);
}

.action-btn.danger:hover {
  color: #e05555;
  border-color: rgba(224, 85, 85, 0.3);
  background: rgba(224, 85, 85, 0.07);
}

.action-btn svg {
  width: 11px;
  height: 11px;
  flex-shrink: 0;
}

/* ── Edit bar ── */
.edit-bar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 7px 2px 8px;
  gap: 8px;
  max-width: 100%;
  overflow: hidden;
}

.edit-bar.hidden {
  display: none;
}

.edit-label {
  font-size: 11px;
  font-family: var(--font-mono);
  color: var(--primary);
  letter-spacing: 0.04em;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  flex: 1;
  min-width: 0;
}

.edit-actions {
  display: flex;
  gap: 6px;
}

.btn-sm {
  font-size: 11px;
  padding: 5px 12px;
  height: 28px;
  display: flex;
  align-items: center;
}

/* ── Input area ── */
.input-area {
  flex-shrink: 0;
  padding: 14px 20px 18px;
  border-top: 1px solid var(--border);
}

.input-wrapper {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--input);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 0 12px;
  min-height: 46px;
  transition: border-color 0.15s;
}

.input-wrapper:focus-within {
  border-color: var(--ring);
}

#chat-input {
  flex: 1;
  background: transparent;
  border: none;
  outline: none;
  color: var(--foreground);
  font-family: var(--font-sans);
  font-size: 14px;
  line-height: 1.55;
  resize: none;
  min-height: 22px;
  max-height: 140px;
  padding: 12px 0;
  align-self: stretch;
  display: flex;
  align-items: center;
}

#chat-input::placeholder {
  color: var(--muted-foreground);
}

#chat-input::-webkit-scrollbar {
  display: none;
}

#chat-input {
  scrollbar-width: none;
  -ms-overflow-style: none;
}

.send-btn {
  background: var(--primary);
  color: var(--primary-foreground);
  border: none;
  width: 30px;
  height: 30px;
  border-radius: 7px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  transition: opacity 0.15s;
}

.send-btn:hover:not(:disabled) {
  opacity: 0.82;
}

.send-btn:disabled {
  opacity: 0.3;
  cursor: default;
}

.send-btn svg {
  width: 14px;
  height: 14px;
}

/* ── Modal overlay ── */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(5px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 16px;
  z-index: 100;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s ease;
}

.modal-overlay.open {
  opacity: 1;
  pointer-events: all;
}

/* ── Modal ── */
.modal {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: calc(var(--radius) + 4px);
  width: 100%;
  max-width: 480px;
  transform: translateY(10px) scale(0.97);
  transition: transform 0.2s ease;
}

.modal-overlay.open .modal {
  transform: translateY(0) scale(1);
}

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 18px 20px 14px;
  border-bottom: 1px solid var(--border);
}

.modal-title {
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.1em;
  text-transform: uppercase;
  color: var(--foreground);
}

.modal-body {
  padding: 20px;
  display: flex;
  flex-direction: column;
  gap: 18px;
}

/* ── Form field ── */
.field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.field label {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted-foreground);
}

.field input,
.field textarea {
  background: var(--input);
  border: 1px solid var(--border);
  border-radius: 8px;
  color: var(--foreground);
  font-family: var(--font-mono);
  font-size: 13px;
  padding: 9px 12px;
  outline: none;
  width: 100%;
  transition: border-color 0.15s;
}

.field input:focus,
.field textarea:focus {
  border-color: var(--ring);
}

.field input::placeholder,
.field textarea::placeholder {
  color: var(--muted-foreground);
  opacity: 0.7;
}

.field textarea {
  resize: vertical;
  min-height: 88px;
  line-height: 1.55;
}

.field-hint {
  font-size: 11px;
  font-family: var(--font-mono);
  color: var(--muted-foreground);
  line-height: 1.5;
}

.field-hint a {
  color: var(--primary);
  text-decoration: none;
}

.field-hint a:hover {
  text-decoration: underline;
}

.field-hint code {
  background: var(--muted);
  padding: 0 4px;
  border-radius: 3px;
  font-size: 11px;
}

/* ── Error box ── */
.error-box {
  font-size: 12px;
  font-family: var(--font-mono);
  color: #e05555;
  background: rgba(224, 85, 85, 0.07);
  border: 1px solid rgba(224, 85, 85, 0.2);
  border-radius: 7px;
  padding: 9px 12px;
}

.error-box.hidden {
  display: none;
}

/* ── Modal footer ── */
.modal-footer {
  display: flex;
  justify-content: flex-end;
  gap: 8px;
  padding: 14px 20px 18px;
  border-top: 1px solid var(--border);
}

.btn {
  font-family: var(--font-sans);
  font-size: 12px;
  font-weight: 500;
  letter-spacing: 0.06em;
  padding: 8px 18px;
  border-radius: 7px;
  cursor: pointer;
  border: 1px solid transparent;
  transition: opacity 0.15s, background 0.15s, border-color 0.15s, color 0.15s;
}

.btn-ghost {
  background: transparent;
  border-color: var(--border);
  color: var(--muted-foreground);
}

.btn-ghost:hover {
  color: var(--foreground);
  background: var(--accent);
  border-color: var(--accent);
}

.btn-primary {
  background: var(--primary);
  color: var(--primary-foreground);
  border-color: var(--primary);
}

.btn-primary:hover {
  opacity: 0.85;
}

.btn-danger {
  background: rgba(224, 85, 85, 0.1);
  color: #e05555;
  border-color: rgba(224, 85, 85, 0.3);
}

.btn-danger:hover {
  background: rgba(224, 85, 85, 0.2);
  border-color: #e05555;
}

/* ── Sliders ── */
.sliders-row {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.slider-field {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.slider-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
}

.slider-header label {
  font-size: 11px;
  font-weight: 500;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: var(--muted-foreground);
}

/* Memory indicator spacing */
.memory-indicator {
  margin-top: 6px;
  font-size: 11px;
  color: var(--primary);
  display: flex;
  align-items: center;
  gap: 6px;
  opacity: 1;
  max-height: 24px;
  /* Fixed height for animation */
  transform: translateY(0);
  transition: opacity 0.5s ease, max-height 0.5s ease, margin 0.5s ease, transform 0.5s ease;
  overflow: hidden;
}

.memory-indicator.fade-out {
  opacity: 0;
  max-height: 0;
  margin-top: 0;
  margin-bottom: 0;
  transform: translateY(-5px);
  pointer-events: none;
}

.memory-indicator svg {
  width: 14px;
  height: 14px;
}



.memory-indicator svg {
  width: 12px;
  height: 12px;
}

@keyframes fade-in {
  from {
    opacity: 0;
    transform: translateY(-2px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.slider-value {
  font-size: 12px;
  font-family: var(--font-mono);
  color: var(--primary);
  font-weight: 500;
  min-width: 28px;
  text-align: right;
}


input[type="range"] {
  -webkit-appearance: none;
  appearance: none;
  width: 100%;
  height: 2px;
  background: var(--border);
  border-radius: 2px;
  outline: none;
  cursor: pointer;
  accent-color: var(--primary);
}

input[type="range"]::-webkit-slider-thumb {
  -webkit-appearance: none;
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--primary);
  border: 2px solid var(--card);
  box-shadow: none;
  cursor: pointer;
  transition: transform 0.1s;
}

input[type="range"]::-webkit-slider-thumb:hover {
  transform: scale(1.15);
}

input[type="range"]::-moz-range-thumb {
  width: 14px;
  height: 14px;
  border-radius: 50%;
  background: var(--primary);
  border: 2px solid var(--card);
  box-shadow: none;
  cursor: pointer;
}


.slider-range-labels {
  display: flex;
  justify-content: space-between;
  font-size: 10px;
  font-family: var(--font-mono);
  color: var(--muted-foreground);
  opacity: 0.6;
  margin-top: -2px;
}

/* ── Sessions Modal ── */
.session-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 300px;
  overflow-y: auto;
  padding-right: 4px;
}

.session-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: var(--input);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 10px 12px;
  transition: border-color 0.15s, background 0.15s;
  cursor: pointer;
}

.session-item:hover {
  background: var(--muted);
  border-color: var(--border);
}

.session-item.active {
  background: var(--muted);
  border-color: var(--primary);
}

.session-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  overflow: hidden;
}

.session-name {
  font-size: 13px;
  font-weight: 500;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  color: var(--foreground);
}

.session-date {
  font-size: 10px;
  font-family: var(--font-mono);
  color: var(--muted-foreground);
}

.session-actions {
  position: relative;
  display: flex;
  align-items: center;
}

.session-menu-btn {
  background: transparent;
  border: none;
  color: var(--muted-foreground);
  padding: 6px;
  border-radius: 6px;
  cursor: pointer;
  display: flex;
  transition: color 0.15s, background 0.15s;
}

.session-menu-btn:hover {
  color: var(--foreground);
  background: var(--accent);
}

/* ── Dropdown ── */
.dropdown-menu {
  position: absolute;
  top: 100%;
  right: 0;
  margin-top: 4px;
  background: var(--popover);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.3);
  min-width: 140px;
  z-index: 2000;
  display: flex;
  flex-direction: column;
  padding: 4px;
  opacity: 0;
  transform: translateY(-5px);
  pointer-events: none;
  transition: opacity 0.1s, transform 0.1s;
}

.dropdown-menu.open {
  opacity: 1;
  transform: translateY(0);
  pointer-events: all;
}

.dropdown-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  font-size: 12px;
  color: var(--foreground);
  border-radius: 4px;
  cursor: pointer;
  background: transparent;
  border: none;
  width: 100%;
  text-align: left;
  font-family: var(--font-sans);
}

.dropdown-item:hover {
  background: var(--accent);
}

.dropdown-item.danger {
  color: #e05555;
}

.dropdown-item.danger:hover {
  background: rgba(224, 85, 85, 0.1);
}

/* ── Long press indicator ── */
.message.long-pressing .bubble {
  transform: scale(0.98);
  transition: transform 0.2s;
  opacity: 0.8;
}

/* ── Memory Section in Settings ── */
.memory-section {
  margin-top: 24px;
  border-top: 1px solid var(--border);
  padding-top: 20px;
}

.memory-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
}

.memory-header h3 {
  font-size: 13px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  color: var(--foreground);
  margin: 0;
}

.memory-list {
  display: flex;
  flex-direction: column;
  gap: 8px;
  max-height: 50vh;
  overflow-y: auto;
  padding-right: 2px;
  background: var(--input);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 8px;
}

.memory-item {
  display: flex;
  gap: 8px;
  background: var(--background);
  padding: 8px 10px;
  border-radius: 6px;
  font-size: 13px;
  align-items: flex-start;
  border: 1px solid transparent;
  transition: border-color 0.2s;
}

.memory-item:hover {
  border-color: var(--border);
}

.memory-content {
  flex: 1;
  word-break: break-word;
  color: var(--foreground);
  outline: none;
  background: transparent;
  padding: 2px 4px;
  border-radius: 4px;
  line-height: 1.4;
}

.memory-content:focus {
  background: var(--muted);
  box-shadow: 0 0 0 1px var(--primary);
}

.memory-actions {
  display: flex;
  gap: 2px;
  opacity: 0.4;
  transition: opacity 0.2s;
}

.memory-item:hover .memory-actions {
  opacity: 1;
}

.memory-btn {
  background: none;
  border: none;
  cursor: pointer;
  color: var(--muted-foreground);
  padding: 4px;
  border-radius: 4px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.memory-btn:hover {
  background: var(--accent);
  color: var(--foreground);
}

.memory-btn.danger:hover {
  color: #ef4444;
  background: rgba(239, 68, 68, 0.1);
}

/* Memory Empty State */
.memory-empty {
  font-size: 12px;
  color: var(--muted-foreground);
  text-align: center;
  padding: 20px 0;
  font-style: italic;
}

/* Memory Modal - specific overrides */
#memory-overlay .memory-list {
  border: none;
  background: transparent;
  padding: 0;
  max-height: 50vh;
  overflow-y: auto;
}

/* Scrollbar for memory list */
#memory-overlay .memory-list::-webkit-scrollbar {
  width: 4px;
}

#memory-overlay .memory-list::-webkit-scrollbar-track {
  background: transparent;
}

#memory-overlay .memory-list::-webkit-scrollbar-thumb {
  background: var(--border);
  border-radius: 2px;
}

/* ── Google Auth Section ── */
.auth-section {
  background: var(--input);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 12px;
}

.auth-state {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
}

.auth-state.hidden {
  display: none;
}

.auth-status {
  font-size: 13px;
  color: var(--muted-foreground);
}

.auth-user {
  display: flex;
  align-items: center;
  gap: 10px;
  flex: 1;
  min-width: 0;
}

.auth-avatar {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  flex-shrink: 0;
  background-size: cover;
  background-position: center;
  background-color: var(--muted);
}

.auth-user-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  min-width: 0;
}

.auth-user-name {
  font-size: 13px;
  font-weight: 500;
  color: var(--foreground);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.auth-user-email {
  font-size: 11px;
  color: var(--muted-foreground);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

/* ── Login Button ── */
#login-btn {
  display: flex;
  align-items: center;
  gap: 8px;
}

#login-btn svg {
  flex-shrink: 0;
}