:root {
  --bg-darkest: #0a0a1a;
  --bg-dark: #0f0f23;
  --bg-card: #1a1a2e;
  --bg-card-transparent: rgba(255, 255, 255, 0.03);
  --primary: #6C5CE7;
  --primary-hover: #5a4bd1;
  --primary-gradient: linear-gradient(135deg, #6C5CE7, #a855f7);
  --accent: #00cec9;
  --success: #00b894;
  --error: #e17055;
  --warning: #fdcb6e;
  --text-primary: #e8e8f0;
  --text-secondary: #8888a8;
  --text-muted: #555570;
  --border-color: rgba(255, 255, 255, 0.06);
  --border-hover: rgba(255, 255, 255, 0.12);
  --input-bg: rgba(255, 255, 255, 0.04);
  --font-family: 'Inter', -apple-system, BlinkMacSystemFont, sans-serif;
  --transition: 0.25s cubic-bezier(0.4, 0, 0.2, 1);
}

/* Reset & Base */
*, *::before, *::after {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
}

body {
  background-color: var(--bg-darkest);
  color: var(--text-primary);
  font-family: var(--font-family);
  font-size: 15px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
  scroll-behavior: smooth;
  overflow-x: hidden;
}

body.has-results .upload-zone,
body.has-results .url-upload-box,
body.has-results .desktop-app-card,
body.has-results #desktop-app-card {
  display: none !important;
}

::selection {
  background-color: var(--primary);
  color: #fff;
}

/* Typography */
h1, h2, h3, h4, h5, h6 {
  color: var(--text-primary);
  line-height: 1.2;
}

.hero-title {
  font-size: 2.8rem;
  font-weight: 700;
  margin-bottom: 0.75rem;
}

.text-gradient {
  background: var(--primary-gradient);
  -webkit-background-clip: text;
  color: transparent;
}

.hero-subtitle {
  color: var(--text-secondary);
  font-size: 1.1rem;
}

/* Container */
.container {
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 1.5rem;
}

/* Navbar */
.navbar {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  z-index: 1000;
  background: rgba(10, 10, 26, 0.85);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-bottom: 1px solid var(--border-color);
  height: 64px;
}

.navbar .container {
  display: flex;
  justify-content: space-between;
  align-items: center;
  height: 100%;
}

.navbar-brand {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  text-decoration: none;
  color: #fff;
  font-weight: 700;
  font-size: 1.25rem;
}

.brand-icon {
  color: var(--primary);
  width: 28px;
}

.navbar-menu {
  display: flex;
  align-items: center;
  gap: 1rem;
  list-style: none;
}

.nav-link {
  color: var(--text-secondary);
  text-decoration: none;
  transition: color var(--transition);
  font-weight: 500;
}

.nav-link:hover {
  color: #fff;
}

.nav-link-logout {
  color: var(--error);
}

.navbar-user {
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.navbar-toggle {
  display: none;
  background: none;
  border: none;
  color: var(--text-primary);
  font-size: 1.5rem;
  cursor: pointer;
}

/* Main Content */
.main-content {
  padding-top: 100px;
  min-height: calc(100vh - 100px);
}

/* Hero Section */
.hero-section {
  text-align: center;
  margin-bottom: 2.5rem;
}

/* Upload Container */
.upload-container {
  max-width: 700px;
  margin: 0 auto;
}

/* Upload Zone */
.upload-zone {
  background: rgba(255, 255, 255, 0.02);
  border: 2px dashed rgba(255, 255, 255, 0.1);
  border-radius: 16px;
  padding: 3rem 2rem;
  text-align: center;
  cursor: pointer;
  transition: border-color var(--transition), background var(--transition);
}

.upload-zone:hover, .upload-zone.drag-over {
  border-color: var(--primary);
  background: rgba(108, 92, 231, 0.05);
}

.upload-zone.drag-over {
  animation: pulseGlow 1.5s ease-in-out infinite;
}

.upload-icon {
  color: var(--text-secondary);
  margin-bottom: 1rem;
  opacity: 0.6;
  font-size: 3rem;
}

.upload-text {
  font-size: 1.3rem;
  font-weight: 600;
  margin-bottom: 0.5rem;
}

.upload-subtext {
  color: var(--text-secondary);
  font-size: 0.95rem;
  margin-bottom: 1.5rem;
}

.upload-hint {
  color: var(--text-muted);
  font-size: 0.8rem;
  margin-top: 1.5rem;
  display: block;
}

/* Buttons */
.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  padding: 0.65rem 1.5rem;
  border-radius: 8px;
  border: none;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 500;
  cursor: pointer;
  transition: all var(--transition);
  text-decoration: none;
}

.btn-primary {
  background: var(--primary-gradient);
  color: #fff;
}

.btn-primary:hover {
  filter: brightness(1.1);
  transform: scale(1.02);
}

.btn-secondary {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
}

.btn-secondary:hover {
  background: rgba(255, 255, 255, 0.1);
}

.btn-danger {
  background: var(--error);
  color: #fff;
}

.btn-danger:hover {
  filter: brightness(1.1);
}

.btn-copy {
  background: rgba(255, 255, 255, 0.06);
  color: var(--text-secondary);
  padding: 0.5rem 0.75rem;
}

.btn-copy:hover {
  color: #fff;
  background: rgba(255, 255, 255, 0.1);
}

.btn-sm {
  padding: 0.4rem 0.8rem;
  font-size: 0.85rem;
}

.btn-block {
  width: 100%;
  justify-content: center;
}

.btn-select {
  position: relative;
  z-index: 2;
}

.btn-upload {
  width: 100%;
  margin-top: 1rem;
  padding: 0.85rem;
  font-size: 1.05rem;
}

/* Button Loader */
.btn-loader {
  width: 20px;
  height: 20px;
  border: 2px solid rgba(255, 255, 255, 0.3);
  border-top-color: #fff;
  border-radius: 50%;
  animation: spin 0.6s linear infinite;
  display: inline-block;
}

/* File List */
.file-list {
  margin-top: 1rem;
  display: flex;
  flex-direction: column;
  gap: 0.5rem;
}

.file-item {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1rem;
  background: rgba(255, 255, 255, 0.03);
  border-radius: 8px;
  border: 1px solid var(--border-color);
}

.file-thumb {
  width: 48px;
  height: 48px;
  border-radius: 6px;
  object-fit: cover;
  background: #1a1a2e;
}

.file-info {
  flex: 1;
  min-width: 0;
}

.file-name {
  font-size: 0.9rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}

.file-size {
  font-size: 0.8rem;
  color: var(--text-secondary);
}

.file-remove {
  background: none;
  border: none;
  color: var(--error);
  cursor: pointer;
  font-size: 1.2rem;
  padding: 0.25rem;
  transition: opacity var(--transition);
}

.file-remove:hover {
  opacity: 0.7;
}

/* Progress */
.upload-progress {
  margin-top: 1.5rem;
}

.progress-bar {
  height: 6px;
  background: rgba(255, 255, 255, 0.06);
  border-radius: 3px;
  overflow: hidden;
}

.progress-fill {
  height: 100%;
  background: var(--primary-gradient);
  border-radius: 3px;
  transition: width 0.3s;
  position: relative;
  width: 0%;
}

.progress-fill::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.2), transparent);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
}

.progress-text {
  display: block;
  text-align: center;
  margin-top: 0.5rem;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

/* Results */
.results-container {
  margin-top: 2rem;
  animation: fadeIn 0.5s;
}

.results-title {
  text-align: center;
  font-size: 1.5rem;
  margin-bottom: 1.5rem;
}

.results-grid {
  display: flex;
  flex-direction: column;
  gap: 1.5rem;
}

/* Result Card */
.result-card {
  background: var(--bg-card-transparent);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  overflow: hidden;
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.2);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

.result-preview {
  max-height: 300px;
  overflow: hidden;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-dark);
}

.result-preview img {
  max-width: 100%;
  max-height: 300px;
  object-fit: contain;
}

.result-links {
  padding: 1.25rem;
}

.link-group {
  margin-bottom: 1rem;
}

.link-group:last-child {
  margin-bottom: 0;
}

.link-group label {
  display: block;
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-bottom: 0.35rem;
  font-weight: 500;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.link-input-group {
  display: flex;
  gap: 0.5rem;
}

.link-input {
  flex: 1;
  background: var(--input-bg);
  border: 1px solid var(--border-color);
  border-radius: 6px;
  padding: 0.55rem 0.75rem;
  color: var(--text-primary);
  font-size: 0.85rem;
  font-family: monospace;
}

.link-input:focus {
  border-color: var(--primary);
  outline: none;
}

/* Viewer */
.viewer-container {
  max-width: 900px;
  margin: 0 auto;
}

.viewer-image {
  background: var(--bg-dark);
  border-radius: 12px;
  overflow: hidden;
  margin-bottom: 1.5rem;
  text-align: center;
  min-height: 200px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.viewer-image img {
  max-width: 100%;
  max-height: 75vh;
  object-fit: contain;
}

.viewer-info {
  background: var(--bg-card-transparent);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 1.5rem;
  backdrop-filter: blur(20px);
}

.info-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(150px, 1fr));
  gap: 1rem;
  margin-bottom: 1.5rem;
  padding-bottom: 1.5rem;
  border-bottom: 1px solid var(--border-color);
}

.info-item {
  display: flex;
  flex-direction: column;
  gap: 0.25rem;
}

.info-label {
  font-size: 0.75rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.5px;
  font-weight: 500;
}

.info-value {
  font-size: 0.95rem;
  font-weight: 500;
}

.link-panels .link-group {
  margin-bottom: 1rem;
}

.link-panels .link-group:last-child {
  margin-bottom: 0;
}

/* Auth */
.auth-container {
  display: flex;
  justify-content: center;
  align-items: center;
  min-height: calc(100vh - 200px);
}

.auth-card {
  background: var(--bg-card-transparent);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 2.5rem;
  width: 100%;
  max-width: 420px;
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
}

.auth-title {
  text-align: center;
  font-size: 1.75rem;
  margin-bottom: 2rem;
}

.auth-form {
  display: flex;
  flex-direction: column;
  gap: 1.25rem;
}

.auth-footer {
  text-align: center;
  margin-top: 1.5rem;
  color: var(--text-secondary);
  font-size: 0.9rem;
}

.auth-footer a {
  color: var(--primary);
  text-decoration: none;
}

.auth-footer a:hover {
  text-decoration: underline;
}

/* Forms */
.form-group {
  display: flex;
  flex-direction: column;
  gap: 0.4rem;
}

.form-group label {
  font-size: 0.9rem;
  font-weight: 500;
  color: var(--text-secondary);
}

.form-input {
  background: var(--input-bg);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  padding: 0.75rem 1rem;
  color: var(--text-primary);
  font-size: 0.95rem;
  font-family: inherit;
  transition: border-color 0.25s, box-shadow 0.25s;
}

.form-input:focus {
  border-color: var(--primary);
  outline: none;
  box-shadow: 0 0 0 3px rgba(108, 92, 231, 0.15);
}

/* Alerts */
.alert {
  padding: 0.85rem 1.15rem;
  border-radius: 8px;
  font-size: 0.9rem;
  margin-bottom: 1rem;
}

.alert-error {
  background: rgba(225, 112, 85, 0.1);
  border: 1px solid rgba(225, 112, 85, 0.3);
  color: var(--error);
}

.alert-success {
  background: rgba(0, 184, 148, 0.1);
  border: 1px solid rgba(0, 184, 148, 0.3);
  color: var(--success);
}

/* Gallery */
.gallery-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 2rem;
}

.gallery-stats {
  display: flex;
  gap: 0.75rem;
}

.stat-badge {
  background: rgba(255, 255, 255, 0.04);
  padding: 0.5rem 1rem;
  border-radius: 8px;
  font-size: 0.9rem;
  border: 1px solid var(--border-color);
}

/* Gallery Grid */
.gallery-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 1.25rem;
}

.gallery-item {
  background: var(--bg-card-transparent);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  overflow: hidden;
  transition: transform var(--transition), border-color var(--transition);
}

.gallery-item:hover {
  transform: translateY(-3px);
  border-color: var(--border-hover);
}

.gallery-thumb {
  display: block;
  position: relative;
  aspect-ratio: 1;
  overflow: hidden;
}

.gallery-thumb img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.gallery-overlay {
  position: absolute;
  inset: 0;
  background: linear-gradient(transparent 60%, rgba(0, 0, 0, 0.7));
  display: flex;
  align-items: flex-end;
  justify-content: flex-end;
  padding: 0.75rem;
  opacity: 0;
  transition: opacity var(--transition);
}

.gallery-item:hover .gallery-overlay {
  opacity: 1;
}

.gallery-views {
  font-size: 0.85rem;
  color: #fff;
}

.gallery-info {
  padding: 0.75rem;
}

.gallery-name {
  display: block;
  font-size: 0.85rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  margin-bottom: 0.25rem;
  color: var(--text-primary);
  text-decoration: none;
}

.gallery-meta {
  font-size: 0.75rem;
  color: var(--text-secondary);
}

.gallery-actions {
  display: flex;
  gap: 0.5rem;
  padding: 0 0.75rem 0.75rem;
}

/* Pagination */
.pagination {
  display: flex;
  justify-content: center;
  gap: 0.5rem;
  margin-top: 2rem;
}

.pagination a, .pagination span {
  padding: 0.5rem 0.85rem;
  border-radius: 6px;
  font-size: 0.9rem;
  text-decoration: none;
}

.pagination a {
  background: rgba(255, 255, 255, 0.04);
  color: var(--text-secondary);
  border: 1px solid var(--border-color);
  transition: background var(--transition), color var(--transition);
}

.pagination a:hover {
  background: rgba(255, 255, 255, 0.08);
  color: #fff;
}

.pagination .active {
  background: var(--primary-gradient);
  color: #fff;
  border: none;
}

/* Toast */
#toast-container {
  position: fixed;
  top: 80px;
  right: 1.5rem;
  z-index: 10000;
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
}

.toast {
  padding: 0.85rem 1.25rem;
  border-radius: 10px;
  font-size: 0.9rem;
  animation: toastSlideIn 0.4s;
  max-width: 350px;
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
}

.toast-success {
  background: rgba(0, 184, 148, 0.15);
  border: 1px solid rgba(0, 184, 148, 0.3);
  color: var(--success);
}

.toast-error {
  background: rgba(225, 112, 85, 0.15);
  border: 1px solid rgba(225, 112, 85, 0.3);
  color: var(--error);
}

.toast-info {
  background: rgba(108, 92, 231, 0.15);
  border: 1px solid rgba(108, 92, 231, 0.3);
  color: #a29bfe;
}

.toast.fade-out {
  animation: toastSlideOut 0.4s forwards;
}

/* Footer */
.site-footer {
  margin-top: 3rem;
  padding: 1.5rem 0;
  border-top: 1px solid var(--border-color);
  text-align: center;
  color: var(--text-muted);
  font-size: 0.85rem;
}

/* Animations */
@keyframes spin {
  to { transform: rotate(360deg); }
}

@keyframes fadeIn {
  from { opacity: 0; transform: translateY(10px); }
  to { opacity: 1; transform: translateY(0); }
}

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

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

@keyframes shimmer {
  0% { background-position: -200% 0; }
  100% { background-position: 200% 0; }
}

@keyframes pulseGlow {
  0%, 100% { box-shadow: 0 0 15px rgba(108, 92, 231, 0.2); }
  50% { box-shadow: 0 0 30px rgba(108, 92, 231, 0.4); }
}

/* Empty State */
.empty-state {
  text-align: center;
  padding: 3rem;
  color: var(--text-secondary);
}

.empty-state-icon {
  font-size: 3rem;
  margin-bottom: 1rem;
  opacity: 0.5;
}

.empty-state-text {
  font-size: 1.1rem;
}

/* Responsive */
@media (max-width: 768px) {
  .hero-title {
    font-size: 1.8rem;
  }
  
  .upload-zone {
    padding: 2rem 1.25rem;
  }
  
  .gallery-grid {
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
  }
  
  .info-grid {
    grid-template-columns: 1fr 1fr;
  }
  
  .navbar-toggle {
    display: flex;
  }
  
  .navbar-menu {
    display: none;
    position: absolute;
    top: 64px;
    right: 0;
    flex-direction: column;
    background: rgba(10, 10, 26, 0.95);
    padding: 1rem;
    border-radius: 0 0 12px 12px;
    border: 1px solid var(--border-color);
    width: 200px;
    backdrop-filter: blur(20px);
  }
  
  .navbar-menu.active {
    display: flex;
  }
  
  .auth-card {
    padding: 1.5rem;
  }
  
  .container {
    padding: 0 1rem;
  }
}

/* Checkbox & Remember Me */
.form-checkbox {
  flex-direction: row;
  align-items: center;
}

.checkbox-label {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  cursor: pointer;
  font-size: 0.85rem;
  color: var(--text-secondary);
}

.checkbox-label input[type="checkbox"] {
  accent-color: var(--primary);
  width: 16px;
  height: 16px;
  cursor: pointer;
}

/* Folder Bar */
.folder-bar {
  display: flex;
  flex-wrap: wrap;
  gap: 0.5rem;
  margin-bottom: 1.5rem;
  align-items: center;
}

.folder-chip {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 0.4rem 0.85rem;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  text-decoration: none;
  font-size: 0.85rem;
  transition: all var(--transition);
}

.folder-chip:hover, .folder-chip.active {
  background: var(--primary-gradient);
  color: #fff;
  border-color: transparent;
}

.btn-folder-delete {
  background: none;
  border: none;
  color: rgba(255, 255, 255, 0.6);
  font-size: 0.8rem;
  cursor: pointer;
  margin-left: 0.2rem;
  padding: 0 2px;
}

.btn-folder-delete:hover {
  color: #fff;
}

/* Filter Toolbar */
.filter-toolbar {
  display: flex;
  gap: 1rem;
  margin-bottom: 1.5rem;
  flex-wrap: wrap;
  align-items: center;
  background: rgba(255, 255, 255, 0.02);
  padding: 0.75rem 1rem;
  border-radius: 12px;
  border: 1px solid var(--border-color);
}

.search-input-group {
  display: flex;
  gap: 0.5rem;
  flex: 1;
  min-width: 220px;
}

.search-input {
  flex: 1;
  padding: 0.45rem 0.75rem;
  font-size: 0.85rem;
}

.format-filter-group select {
  padding: 0.45rem 0.75rem;
  font-size: 0.85rem;
  border-radius: 8px;
  background: var(--input-bg);
  color: var(--text-primary);
  border: 1px solid var(--border-color);
  cursor: pointer;
}

.format-filter-group select option {
  background: var(--bg-dark);
  color: var(--text-primary);
}

/* Favorite Star Button */
.btn-fav-star {
  position: absolute;
  top: 8px;
  left: 8px;
  z-index: 10;
  background: rgba(0, 0, 0, 0.6);
  backdrop-filter: blur(4px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  color: #fff;
  border-radius: 50%;
  width: 32px;
  height: 32px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1rem;
  cursor: pointer;
  transition: transform var(--transition), color var(--transition);
}

.btn-fav-star:hover {
  transform: scale(1.15);
}

.btn-fav-star.is-fav {
  color: #ffd700;
  border-color: rgba(255, 215, 0, 0.4);
}

/* Move to Folder Dropdown */
.gallery-folder-select {
  padding: 0 0.75rem 0.5rem;
}

.select-folder-move {
  width: 100%;
  background: rgba(255, 255, 255, 0.04);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  font-size: 0.75rem;
  border-radius: 6px;
  padding: 0.3rem 0.5rem;
  cursor: pointer;
}

.select-folder-move option {
  background: var(--bg-dark);
  color: var(--text-primary);
}

/* Modal */
.modal {
  position: fixed;
  inset: 0;
  z-index: 20000;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(10px);
  display: flex;
  align-items: center;
  justify-content: center;
  padding: 1rem;
}

.modal-content {
  background: var(--bg-card);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 1.5rem 2rem;
  width: 100%;
  max-width: 400px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
}

/* User Navbar Dropdown */
.user-dropdown {
  position: relative;
  display: inline-block;
}

.user-dropdown-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  color: var(--text-primary);
  padding: 0.45rem 0.9rem;
  border-radius: 8px;
  font-size: 0.9rem;
  font-family: inherit;
  font-weight: 500;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 0.4rem;
  transition: all var(--transition);
}

.user-dropdown-btn:hover {
  background: rgba(255, 255, 255, 0.1);
  border-color: var(--border-hover);
}

.user-dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  width: 200px;
  background: var(--bg-dark);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  z-index: 2000;
  padding: 0.5rem 0;
  animation: fadeIn 0.2s ease-out;
}

.user-dropdown.active .user-dropdown-menu {
  display: block;
}

.dropdown-item {
  display: flex;
  align-items: center;
  gap: 0.6rem;
  padding: 0.6rem 1rem;
  color: var(--text-primary);
  text-decoration: none;
  font-size: 0.88rem;
  transition: background var(--transition);
}

.dropdown-item:hover {
  background: rgba(255, 255, 255, 0.06);
}

.dropdown-item-admin {
  color: #a29bfe;
  font-weight: 600;
}

.dropdown-item-logout {
  color: var(--error);
}

.dropdown-divider {
  height: 1px;
  background: var(--border-color);
  margin: 0.35rem 0;
}

/* Admin Panel Styles */
.admin-stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
  gap: 1.25rem;
}

.admin-stat-card {
  background: var(--bg-card-transparent);
  border: 1px solid var(--border-color);
  border-radius: 14px;
  padding: 1.5rem;
  backdrop-filter: blur(20px);
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.stat-icon {
  font-size: 2.2rem;
  margin-bottom: 0.5rem;
}

.stat-number {
  font-size: 1.8rem;
  font-weight: 700;
  color: #fff;
}

.stat-label {
  font-size: 0.85rem;
  color: var(--text-secondary);
  margin-top: 0.2rem;
}

/* Admin Table */
.table-responsive {
  width: 100%;
  overflow: visible;
  border-radius: 12px;
  border: 1px solid var(--border-color);
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  text-align: left;
  font-size: 0.88rem;
  background: rgba(255, 255, 255, 0.02);
}

.admin-table th {
  background: rgba(255, 255, 255, 0.04);
  padding: 0.85rem 1rem;
  font-weight: 600;
  color: var(--text-secondary);
  border-bottom: 1px solid var(--border-color);
  text-transform: uppercase;
  font-size: 0.75rem;
  letter-spacing: 0.5px;
}

.admin-table td {
  padding: 0.85rem 1rem;
  border-bottom: 1px solid var(--border-color);
  color: var(--text-primary);
  vertical-align: middle;
  position: relative;
}

.admin-table tr:last-child td {
  border-bottom: none;
}

.admin-table tr:hover td {
  background: rgba(255, 255, 255, 0.03);
}

.log-tag {
  display: inline-block;
  padding: 0.2rem 0.6rem;
  border-radius: 12px;
  font-size: 0.75rem;
  font-weight: 600;
}

.tag-upload { background: rgba(0, 206, 201, 0.15); color: #00cec9; }
.tag-login_success { background: rgba(0, 184, 148, 0.15); color: #00b894; }
.tag-login_failed { background: rgba(225, 112, 85, 0.15); color: #e17055; }
.tag-visit { background: rgba(255, 255, 255, 0.06); color: var(--text-secondary); }

/* User Action Dropdown (3-Dots) */
.user-action-dropdown {
  position: relative;
  display: inline-block;
}

.btn-action-dots {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid var(--border-color);
  color: var(--text-secondary);
  border-radius: 6px;
  padding: 0.35rem 0.75rem;
  font-size: 0.9rem;
  cursor: pointer;
  letter-spacing: 2px;
  transition: all var(--transition);
}

.btn-action-dots:hover {
  background: rgba(255, 255, 255, 0.12);
  color: #fff;
}

.action-dropdown-menu {
  display: none;
  position: absolute;
  top: calc(100% + 4px);
  right: 0;
  width: 200px;
  background: #0f0f23;
  border: 1px solid rgba(255, 255, 255, 0.15);
  border-radius: 12px;
  box-shadow: 0 10px 30px rgba(0, 0, 0, 0.8);
  z-index: 99999;
  padding: 0.4rem 0;
  text-align: left;
}

.user-action-dropdown.active .action-dropdown-menu {
  display: block;
}

.action-item {
  width: 100%;
  display: block;
  padding: 0.55rem 0.85rem;
  background: none;
  border: none;
  color: var(--text-primary);
  text-decoration: none;
  font-size: 0.82rem;
  font-family: inherit;
  cursor: pointer;
  transition: background var(--transition);
  text-align: left;
}

.action-item:hover {
  background: rgba(255, 255, 255, 0.06);
}

.action-item.item-danger {
  color: var(--error);
}

.action-item.item-danger:hover {
  background: rgba(225, 112, 85, 0.15);
}

.action-item.item-success {
  color: var(--success);
}



