/* ── RESET & TOKENS ───────────────────────────────────────── */
*, *::before, *::after { box-sizing: border-box; margin: 0; padding: 0; }

:root {
  --bg: #0f0f14;
  --surface: #16161f;
  --surface2: #1e1e2a;
  --border: #2a2a3a;
  --accent: #7c6af7;
  --accent2: #a78bfa;
  --accent3: #38bdf8;
  --green: #34d399;
  --yellow: #fbbf24;
  --red: #f87171;
  --text: #e2e0f0;
  --text2: #9490b5;
  --text3: #5e5a7a;
  --sidebar-w: 240px;
  --radius: 12px;
  --radius-sm: 8px;
  --shadow: 0 4px 24px rgba(0,0,0,.45);
}
body.light {
  --bg: #f0f0f8;
  --surface: #ffffff;
  --surface2: #f5f5fc;
  --border: #e0dff0;
  --text: #1a1a2e;
  --text2: #4a4a6a;
  --text3: #9090aa;
  --shadow: 0 4px 24px rgba(100,100,160,.15);
}

html { font-size: 15px; }
body {
  font-family: 'Inter', sans-serif;
  background: var(--bg);
  color: var(--text);
  display: flex;
  min-height: 100vh;
  transition: background .3s, color .3s;
}

/* ── SCROLLBAR ───────────────────────────────────────────── */
::-webkit-scrollbar { width: 6px; }
::-webkit-scrollbar-track { background: var(--surface); }
::-webkit-scrollbar-thumb { background: var(--border); border-radius: 6px; }

/* ── SIDEBAR ─────────────────────────────────────────────── */
.sidebar {
  width: var(--sidebar-w);
  background: var(--surface);
  border-right: 1px solid var(--border);
  display: flex;
  flex-direction: column;
  position: fixed;
  top: 0; left: 0; bottom: 0;
  z-index: 100;
  overflow-y: auto;
  transition: transform .3s ease;
}
.sidebar.closed { transform: translateX(-100%); }

.sidebar-logo {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 20px 16px;
  font-size: 1.1rem;
  font-weight: 800;
  letter-spacing: -.5px;
  border-bottom: 1px solid var(--border);
  color: var(--accent2);
}
.logo-icon {
  width: 34px; height: 34px;
  background: linear-gradient(135deg, var(--accent), var(--accent3));
  border-radius: 10px;
  display: flex; align-items: center; justify-content: center;
  font-size: .9rem;
  box-shadow: 0 4px 12px rgba(124,106,247,.4);
}

.sidebar-nav { padding: 16px 12px; flex: 1; }
.nav-label {
  font-size: .65rem;
  text-transform: uppercase;
  letter-spacing: 1.5px;
  color: var(--text3);
  padding: 0 6px;
  margin-bottom: 6px;
  font-weight: 600;
}
.sidebar-nav ul { list-style: none; }
.nav-item {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 8px 10px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-size: .85rem;
  color: var(--text2);
  transition: all .15s;
  margin-bottom: 2px;
  position: relative;
  user-select: none;
}
.nav-item:hover { background: var(--surface2); color: var(--text); }
.nav-item.active {
  background: linear-gradient(135deg, rgba(124,106,247,.2), rgba(56,189,248,.1));
  color: var(--accent2);
  font-weight: 600;
}
.nav-item .badge {
  margin-left: auto;
  background: var(--surface2);
  color: var(--text3);
  border-radius: 20px;
  padding: 1px 7px;
  font-size: .7rem;
  font-weight: 600;
  min-width: 20px;
  text-align: center;
}
.nav-item.active .badge { background: rgba(124,106,247,.25); color: var(--accent2); }
.nav-icon { font-size: 1rem; }

.sidebar-footer {
  padding: 12px;
  border-top: 1px solid var(--border);
}
.stats-mini { display: flex; gap: 6px; }
.stat-chip {
  flex: 1;
  background: var(--surface2);
  border-radius: var(--radius-sm);
  padding: 6px 8px;
  font-size: .75rem;
  color: var(--text2);
  text-align: center;
}
.stat-chip span { color: var(--accent2); font-weight: 700; }

/* ── MAIN ────────────────────────────────────────────────── */
.main {
  margin-left: var(--sidebar-w);
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 100vh;
  transition: margin .3s;
}
.main.full { margin-left: 0; }

/* ── TOPBAR ──────────────────────────────────────────────── */
.topbar {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 20px;
  background: var(--surface);
  border-bottom: 1px solid var(--border);
  position: sticky; top: 0; z-index: 50;
  backdrop-filter: blur(10px);
}
.hamburger {
  background: var(--surface2);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: var(--radius-sm);
  padding: 6px 10px;
  cursor: pointer;
  font-size: 1.1rem;
  transition: all .15s;
}
.hamburger:hover { background: var(--accent); color: #fff; }

.search-wrap {
  flex: 1;
  display: flex;
  align-items: center;
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: 30px;
  padding: 0 14px;
  gap: 8px;
  transition: border-color .2s;
}
.search-wrap:focus-within { border-color: var(--accent); }
.search-icon { font-size: .9rem; color: var(--text3); }
#searchInput {
  background: none;
  border: none;
  outline: none;
  flex: 1;
  color: var(--text);
  font-size: .9rem;
  font-family: 'Inter', sans-serif;
  padding: 8px 0;
}
#searchInput::placeholder { color: var(--text3); }
.clear-search {
  background: none; border: none; color: var(--text3);
  cursor: pointer; font-size: .8rem; padding: 2px;
  display: none;
}
.clear-search.visible { display: block; }

.topbar-actions { display: flex; gap: 8px; }
.btn-icon {
  background: var(--surface2);
  border: 1px solid var(--border);
  color: var(--text);
  border-radius: var(--radius-sm);
  padding: 7px 10px;
  cursor: pointer;
  font-size: .95rem;
  transition: all .15s;
}
.btn-icon:hover { background: var(--accent); color: #fff; border-color: var(--accent); }

.btn-add {
  background: linear-gradient(135deg, var(--accent), var(--accent3));
  border: none;
  color: #fff;
  border-radius: 20px;
  padding: 6px 14px;
  cursor: pointer;
  font-size: .85rem;
  font-weight: 600;
  transition: all .15s;
  font-family: 'Inter', sans-serif;
  box-shadow: 0 4px 12px rgba(124,106,247,.3);
}
.btn-add:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(124,106,247,.5);
}

/* ── PROGRESS ────────────────────────────────────────────── */
.progress-section {
  padding: 14px 20px 0;
}
.progress-info {
  display: flex;
  justify-content: space-between;
  font-size: .8rem;
  color: var(--text2);
  margin-bottom: 6px;
}
#progressPct { color: var(--green); font-weight: 700; }
.progress-bar-bg {
  height: 6px;
  background: var(--surface2);
  border-radius: 6px;
  overflow: hidden;
}
.progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--accent), var(--green));
  border-radius: 6px;
  transition: width .5s cubic-bezier(.4,0,.2,1);
  box-shadow: 0 0 12px rgba(52,211,153,.4);
}

/* ── ACTIVE FILTERS ──────────────────────────────────────── */
.active-filters {
  display: flex;
  flex-wrap: wrap;
  gap: 6px;
  padding: 10px 20px 0;
  min-height: 0;
}
.filter-tag {
  display: flex;
  align-items: center;
  gap: 6px;
  background: rgba(124,106,247,.15);
  color: var(--accent2);
  border: 1px solid rgba(124,106,247,.3);
  border-radius: 20px;
  padding: 3px 10px;
  font-size: .75rem;
  font-weight: 500;
}
.filter-tag button {
  background: none; border: none; cursor: pointer;
  color: var(--accent2); font-size: .8rem; padding: 0;
}

/* ── CARDS CONTAINER ─────────────────────────────────────── */
.cards-container {
  padding: 16px 20px 40px;
  flex: 1;
}

/* LIST VIEW */
.cards-container.list-view {
  display: flex;
  flex-direction: column;
  gap: 8px;
}

/* GRID VIEW */
.cards-container.grid-view {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 14px;
}

/* ── CATEGORY HEADER ─────────────────────────────────────── */
.category-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 0 4px;
  margin-top: 8px;
  font-weight: 700;
  font-size: .9rem;
  color: var(--accent2);
  border-bottom: 1px solid var(--border);
  margin-bottom: 6px;
}
.category-header .cat-emoji { font-size: 1.2rem; }
.category-header .cat-count {
  margin-left: auto;
  background: rgba(124,106,247,.15);
  color: var(--accent);
  border-radius: 20px;
  padding: 2px 10px;
  font-size: .75rem;
  font-weight: 600;
}

/* ── CARD ────────────────────────────────────────────────── */
.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 14px 16px;
  display: flex;
  align-items: center;
  gap: 14px;
  cursor: pointer;
  transition: all .2s;
  position: relative;
  overflow: hidden;
}
.card::before {
  content: '';
  position: absolute;
  left: 0; top: 0; bottom: 0;
  width: 3px;
  background: var(--status-color, var(--border));
  transition: background .2s;
}
.card:hover {
  border-color: var(--accent);
  transform: translateY(-1px);
  box-shadow: var(--shadow);
}
.card.status-done { --status-color: var(--green); }
.card.status-watching { --status-color: var(--accent3); }
.card.status-todo { --status-color: var(--yellow); }
.card.status-default { --status-color: var(--border); }

/* GRID card variant */
.grid-view .card {
  flex-direction: column;
  align-items: flex-start;
  gap: 10px;
  padding: 16px;
}
.grid-view .card .card-thumb {
  width: 100%;
  height: 140px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  flex-shrink: 0;
}
.grid-view .card .card-thumb img {
  width: 100%; height: 100%; object-fit: cover;
}
.grid-view .card .card-meta { flex-wrap: wrap; }

.card-thumb {
  width: 80px; height: 52px;
  border-radius: var(--radius-sm);
  overflow: hidden;
  flex-shrink: 0;
  background: var(--surface2);
  position: relative;
}
.card-thumb img {
  width: 100%; height: 100%; object-fit: cover;
  display: block;
}
.card-thumb .play-overlay {
  position: absolute; inset: 0;
  display: flex; align-items: center; justify-content: center;
  background: rgba(0,0,0,.4);
  opacity: 0;
  transition: opacity .2s;
  font-size: 1.4rem;
}
.card:hover .play-overlay { opacity: 1; }
.card-thumb.no-img {
  display: flex; align-items: center; justify-content: center;
  font-size: 1.5rem;
  color: var(--text3);
}

.card-body { flex: 1; min-width: 0; }
.card-title {
  font-size: .88rem;
  font-weight: 500;
  color: var(--text);
  line-height: 1.4;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 6px;
}
.card-meta {
  display: flex;
  align-items: center;
  gap: 6px;
  flex-wrap: wrap;
}
.cat-badge {
  font-size: .7rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 20px;
  background: rgba(124,106,247,.15);
  color: var(--accent2);
  border: 1px solid rgba(124,106,247,.2);
}
.status-badge {
  font-size: .7rem;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 20px;
}
.status-badge.todo { background: rgba(251,191,36,.1); color: var(--yellow); border: 1px solid rgba(251,191,36,.2); }
.status-badge.watching { background: rgba(56,189,248,.1); color: var(--accent3); border: 1px solid rgba(56,189,248,.2); }
.status-badge.done { background: rgba(52,211,153,.1); color: var(--green); border: 1px solid rgba(52,211,153,.2); }
.status-badge.trash { background: rgba(248,113,113,.1); color: var(--red); border: 1px solid rgba(248,113,113,.2); }

.card-actions {
  display: flex;
  flex-direction: column;
  align-items: flex-end;
  gap: 6px;
  flex-shrink: 0;
}
.action-btn {
  background: none;
  border: none;
  cursor: pointer;
  font-size: .95rem;
  padding: 4px 6px;
  border-radius: 6px;
  transition: all .15s;
  color: var(--text3);
  line-height: 1;
}
.action-btn:hover { background: var(--surface2); color: var(--text); transform: scale(1.15); }
.action-btn.fav-on { color: var(--yellow); }
.action-btn.ext-btn:hover { color: var(--accent3); }

/* ── MODAL ───────────────────────────────────────────────── */
.modal-overlay {
  position: fixed; inset: 0;
  background: rgba(0,0,0,.8);
  backdrop-filter: blur(8px);
  z-index: 200;
  opacity: 0; pointer-events: none;
  transition: opacity .25s;
}
.modal-overlay.open { opacity: 1; pointer-events: all; }

.modal {
  position: fixed;
  top: 50%; left: 50%;
  transform: translate(-50%, -48%) scale(.96);
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 18px;
  padding: 0;
  width: min(600px, 92vw);
  max-height: 90vh;
  overflow-y: auto;
  z-index: 201;
  opacity: 0; pointer-events: none;
  transition: all .28s cubic-bezier(.4,0,.2,1);
  box-shadow: 0 32px 100px rgba(0,0,0,.6);
}
.modal.open {
  opacity: 1; pointer-events: all;
  transform: translate(-50%, -50%) scale(1);
}
/* Cinema mode: wider modal for the player */
.modal.cinema {
  width: min(860px, 94vw);
  max-height: 92vh;
}

.modal-close {
  position: absolute; top: 12px; right: 12px;
  background: rgba(0,0,0,.55);
  border: 1px solid rgba(255,255,255,.12);
  color: #fff;
  border-radius: 8px;
  padding: 5px 11px;
  cursor: pointer;
  font-size: .85rem;
  z-index: 10;
  transition: all .15s;
  backdrop-filter: blur(4px);
}
.modal-close:hover { background: var(--red); border-color: var(--red); }

/* ── PLAYER ──────────────────────────────────────────────── */
.modal-player {
  width: 100%;
  aspect-ratio: 16/9;
  background: #000;
  border-radius: 18px 18px 0 0;
  overflow: hidden;
  position: relative;
  flex-shrink: 0;
}
.modal-player iframe {
  width: 100%; height: 100%;
  border: none;
  display: block;
}
.modal-player.no-player {
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
  color: var(--text3);
  background: var(--surface2);
}

/* Error overlay shown when YouTube blocks embed */
.player-error-overlay {
  position: absolute; inset: 0;
  background: rgba(15,15,20,.92);
  backdrop-filter: blur(4px);
  display: none;
  align-items: center;
  justify-content: center;
  border-radius: inherit;
  z-index: 5;
}
.player-error-inner {
  text-align: center;
  padding: 24px;
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 12px;
}
.player-error-icon { font-size: 2.4rem; }
.player-error-msg {
  font-size: .9rem;
  color: var(--text2);
  line-height: 1.5;
}
.player-error-btn {
  display: inline-block;
  padding: 10px 22px;
  background: linear-gradient(135deg, #ff0000, #cc0000);
  color: #fff;
  border-radius: 30px;
  font-size: .85rem;
  font-weight: 700;
  text-decoration: none;
  transition: all .15s;
  box-shadow: 0 4px 16px rgba(255,0,0,.35);
}
.player-error-btn:hover { transform: translateY(-1px); box-shadow: 0 6px 20px rgba(255,0,0,.5); }

/* ── MODAL BODY ──────────────────────────────────────────── */
.modal-body-row {
  display: flex;
  gap: 16px;
  padding: 18px 20px 20px;
  flex-wrap: wrap;
}
.modal-info {
  flex: 1;
  min-width: 0;
}
.modal-controls {
  display: flex;
  flex-direction: column;
  gap: 10px;
  min-width: 180px;
}
.modal-title {
  font-size: 1rem;
  font-weight: 700;
  line-height: 1.45;
  margin-bottom: 10px;
  color: var(--text);
}
.modal-tags { display: flex; gap: 6px; flex-wrap: wrap; }
.cat-badge.fav-tag {
  background: rgba(251,191,36,.15);
  color: var(--yellow);
  border-color: rgba(251,191,36,.3);
}
.modal-actions {
  display: flex; gap: 8px; flex-wrap: wrap;
}
.modal-btn {
  flex: 1;
  padding: 9px 12px;
  border-radius: var(--radius-sm);
  border: none; cursor: pointer;
  font-size: .8rem; font-weight: 600;
  transition: all .15s;
  font-family: 'Inter', sans-serif;
  white-space: nowrap;
}
.modal-btn.primary {
  background: linear-gradient(135deg, var(--accent), var(--accent3));
  color: #fff;
  box-shadow: 0 4px 16px rgba(124,106,247,.4);
}
.modal-btn.primary:hover { transform: translateY(-1px); box-shadow: 0 6px 20px rgba(124,106,247,.5); }
.modal-btn.secondary {
  background: var(--surface2);
  color: var(--text);
  border: 1px solid var(--border);
}
.modal-btn.secondary:hover { border-color: var(--accent); color: var(--accent2); }
.modal-btn.done-btn {
  background: rgba(52,211,153,.12);
  color: var(--green);
  border: 1px solid rgba(52,211,153,.25);
}
.modal-btn.done-btn:hover { background: var(--green); color: #000; }
.modal-btn.danger { background: rgba(248,113,113,.1); color: var(--red); border: 1px solid rgba(248,113,113,.2); }
.modal-btn.danger:hover { background: var(--red); color: #fff; }

.status-select-wrap { display: flex; flex-direction: column; gap: 6px; }
.status-select-label { font-size: .8rem; color: var(--text2); font-weight: 600; }
.status-select {
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  padding: 8px 12px;
  font-size: .85rem;
  font-family: 'Inter', sans-serif;
  cursor: pointer;
  outline: none;
  transition: border-color .15s;
}
.status-select:focus { border-color: var(--accent); }

/* ── ADD MODAL ───────────────────────────────────────────── */
.add-modal {
  width: min(480px, 90vw);
  padding: 24px;
}
.add-modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
  padding-bottom: 14px;
  border-bottom: 1px solid var(--border);
}
.add-modal-title {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--text);
}
.add-form {
  display: flex;
  flex-direction: column;
  gap: 16px;
}
.add-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}
.add-label {
  font-size: .85rem;
  font-weight: 600;
  color: var(--text2);
}
.add-label .required { color: var(--red); }
.add-input, .add-select {
  background: var(--surface2);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  color: var(--text);
  padding: 10px 12px;
  font-size: .9rem;
  font-family: 'Inter', sans-serif;
  transition: border-color .15s;
  width: 100%;
  outline: none;
}
.add-input:focus, .add-select:focus {
  border-color: var(--accent);
}
.url-input-row {
  display: flex;
  gap: 8px;
}
.fetch-btn {
  background: var(--surface2);
  border: 1px solid var(--accent);
  color: var(--accent2);
  border-radius: var(--radius-sm);
  padding: 0 14px;
  font-weight: 600;
  cursor: pointer;
  transition: all .15s;
  white-space: nowrap;
}
.fetch-btn:hover:not(:disabled) {
  background: var(--accent);
  color: #fff;
}
.fetch-btn:disabled {
  opacity: .5;
  cursor: not-allowed;
  border-color: var(--border);
  color: var(--text3);
}
.add-hint {
  font-size: .75rem;
  margin-top: 2px;
}
.thumb-preview {
  display: flex;
  align-items: center;
  gap: 12px;
  background: var(--surface2);
  padding: 8px;
  border-radius: var(--radius-sm);
  border: 1px solid var(--border);
}
.thumb-preview img {
  width: 80px;
  height: 45px;
  object-fit: cover;
  border-radius: 4px;
}
.thumb-badge {
  font-size: .8rem;
  color: var(--green);
  font-weight: 600;
}
.add-actions {
  display: flex;
  justify-content: flex-end;
  gap: 10px;
  margin-top: 10px;
  padding-top: 16px;
  border-top: 1px solid var(--border);
}
.add-btn-cancel {
  background: transparent;
  border: 1px solid var(--border);
  color: var(--text2);
  padding: 8px 16px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-weight: 600;
  transition: all .15s;
}
.add-btn-cancel:hover {
  background: var(--surface2);
  color: var(--text);
}
.add-btn-submit {
  background: linear-gradient(135deg, var(--accent), var(--accent3));
  border: none;
  color: #fff;
  padding: 8px 20px;
  border-radius: var(--radius-sm);
  cursor: pointer;
  font-weight: 600;
  box-shadow: 0 4px 12px rgba(124,106,247,.3);
  transition: all .15s;
}
.add-btn-submit:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 16px rgba(124,106,247,.5);
}

.category-checkboxes-container {
  max-height: 120px;
  overflow-y: auto;
  border: 1px solid var(--border);
  background: var(--surface2);
  border-radius: var(--radius-sm);
  padding: 10px;
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(130px, 1fr));
  gap: 8px;
}
.cat-checkbox-item {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: .8rem;
  color: var(--text2);
  cursor: pointer;
  user-select: none;
  padding: 4px;
  border-radius: 4px;
  transition: background .15s, color .15s;
}
.cat-checkbox-item:hover {
  background: rgba(255,255,255,.03);
  color: var(--text);
}
.cat-checkbox-item input {
  cursor: pointer;
  accent-color: var(--accent);
}
.new-cat-row {
  display: flex;
  gap: 8px;
  margin-top: 6px;
}

/* ── EMPTY STATE ─────────────────────────────────────────── */
.empty-state {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 80px 20px;
  text-align: center;
  color: var(--text3);
}
.empty-icon { font-size: 3rem; margin-bottom: 14px; }
.empty-state h3 { font-size: 1.1rem; color: var(--text2); margin-bottom: 6px; }

/* ── TOAST ───────────────────────────────────────────────── */
.toast {
  position: fixed;
  bottom: 24px; right: 24px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 12px 20px;
  font-size: .85rem;
  color: var(--text);
  box-shadow: var(--shadow);
  z-index: 10000;
  transform: translateY(80px);
  opacity: 0;
  transition: all .3s cubic-bezier(.4,0,.2,1);
  max-width: 280px;
}
.toast.show { transform: translateY(0); opacity: 1; }

/* ── ANIMATIONS ──────────────────────────────────────────── */
@keyframes fadeIn {
  from { opacity: 0; transform: translateY(8px); }
  to   { opacity: 1; transform: translateY(0); }
}
.card { animation: fadeIn .2s ease both; }

/* ── RESPONSIVE ──────────────────────────────────────────── */
@media (max-width: 640px) {
  :root { --sidebar-w: 0px; }
  .sidebar { transform: translateX(-240px); width: 240px; }
  .sidebar.open { transform: translateX(0); }
  .main { margin-left: 0 !important; }
  .cards-container.grid-view {
    grid-template-columns: 1fr;
  }
}

/* ── GOOGLE LOGIN SYSTEM ─────────────────────────────────── */
.login-screen-overlay {
  position: fixed;
  inset: 0;
  background: radial-gradient(circle at top left, var(--surface), rgba(10, 10, 15, 0.98));
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 9999;
  backdrop-filter: blur(16px);
  animation: fadeIn 0.4s ease;
}

.login-card {
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  border-radius: var(--radius);
  padding: 40px;
  width: 100%;
  max-width: 420px;
  text-align: center;
  box-shadow: 0 20px 50px rgba(0, 0, 0, 0.4);
  backdrop-filter: blur(8px);
}

.login-logo {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  margin-bottom: 16px;
}

.login-logo .logo-icon {
  font-size: 2.2rem;
  background: linear-gradient(135deg, var(--accent), var(--accent3));
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
}

.login-logo span {
  font-size: 1.8rem;
  font-weight: 800;
  letter-spacing: -1px;
  color: var(--text);
}

.login-subtitle {
  color: var(--text3);
  font-size: 0.9rem;
  line-height: 1.5;
  margin-bottom: 32px;
}

.google-login-btn-wrapper {
  display: flex;
  justify-content: center;
  margin-bottom: 24px;
}

.google-login-btn {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 12px;
  background: #ffffff;
  color: #1f1f1f;
  border: none;
  border-radius: 24px;
  padding: 12px 24px;
  font-size: 0.95rem;
  font-weight: 600;
  font-family: 'Roboto', 'Inter', sans-serif;
  cursor: pointer;
  box-shadow: 0 4px 12px rgba(0,0,0,0.15);
  transition: all 0.2s ease;
  width: 100%;
}

.google-login-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 6px 20px rgba(0,0,0,0.25);
  background: #f8f9fa;
}

.google-login-btn img {
  width: 20px;
  height: 20px;
}

.login-disclaimer {
  font-size: 0.75rem;
  color: var(--text3);
}

/* Sidebar User Profile Info */
.sidebar-user-profile {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid var(--border);
  padding: 10px 12px;
  border-radius: var(--radius-sm);
  margin-bottom: 12px;
}

.user-avatar {
  width: 36px;
  height: 36px;
  border-radius: 50%;
  object-fit: cover;
  border: 2px solid var(--accent);
  background: var(--surface3);
}

.sidebar-user-profile .user-info {
  display: flex;
  flex-direction: column;
  gap: 2px;
  flex: 1;
  overflow: hidden;
}

.sidebar-user-profile .user-name {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.logout-link {
  font-size: 0.7rem;
  color: var(--red);
  background: none;
  border: none;
  cursor: pointer;
  padding: 0;
  text-align: left;
  width: fit-content;
  transition: opacity 0.15s;
}

.logout-link:hover {
  text-decoration: underline;
  opacity: 0.8;
}
