/* ═══════════════════════════════════════════════════════════════
   ICS File Transfer Platform — Custom CSS
   Theme: Deep Mauve / Professional Dark
   No Bootstrap / No external CDN — fully self-hosted
   ═══════════════════════════════════════════════════════════════ */

/* ── Custom Properties ──────────────────────────────────────── */
:root {
  /* Brand */
  --brand: #3e0d81;
  --brand-mid: #5a1db8;
  --brand-light: #7b3fd4;
  --brand-pale: #f0e8ff;
  --brand-glow: rgba(62, 13, 129, 0.35);

  /* Neutrals */
  /*--bg:            #0f0b16;*/
  --bg: #c0c4c5;
  /*--bg-card: #1a1325;*/
  --bg-card: #124164;
  --bg-elevated: #221a33;
  --border: rgba(255, 255, 255, 0.08);
  --border-hover: rgba(122, 63, 212, 0.5);

  /* Text */
  --text-primary: #f0edf8;
  /*--text-secondary: #a89bc4;*/
  --text-secondary: #f6f6f5;
  /*--text-muted: #6b5e8a;*/
  --text-muted: #c03ce5;

  /* Status */
  --success: #22c55e;
  --success-bg: rgba(34, 197, 94, 0.12);
  --error: #f43f5e;
  --error-bg: rgba(244, 63, 94, 0.12);
  --warning: #f59e0b;
  --info: #38bdf8;#124164;

  /* Sizing */
  --radius-sm: 6px;
  --radius: 12px;
  --radius-lg: 18px;
  --radius-xl: 24px;

  /* Shadows */
  --shadow-card:
    0 4px 24px rgba(0, 0, 0, 0.4), 0 1px 0 rgba(255, 255, 255, 0.04) inset;
  --shadow-glow: 0 0 30px rgba(62, 13, 129, 0.4);
  --shadow-btn: 0 4px 15px rgba(62, 13, 129, 0.5);

  /* Typography */
  --font-ui: "Sora", "Segoe UI", system-ui, sans-serif;
  --font-mono: "JetBrains Mono", "Fira Code", "Cascadia Code", monospace;
}

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

html {
  font-size: 15px;
  scroll-behavior: smooth;
}

body {
  font-family: var(--font-ui);
  background: var(--bg);
  color: var(--text-primary);
  line-height: 1.6;
  min-height: 100vh;
  -webkit-font-smoothing: antialiased;
}

a {
  color: var(--brand-light);
  text-decoration: none;
}
a:hover {
  color: var(--brand-pale);
}

button {
  font-family: inherit;
  cursor: pointer;
  border: none;
}
input {
  font-family: inherit;
}

ul {
  list-style: none;
}

/* ── Scrollbar ───────────────────────────────────────────────── */
::-webkit-scrollbar {
  width: 6px;
  height: 6px;
}
::-webkit-scrollbar-track {
  background: var(--bg);
}
::-webkit-scrollbar-thumb {
  background: var(--brand);
  border-radius: 99px;
}
::-webkit-scrollbar-thumb:hover {
  background: var(--brand-mid);
}

/* ═══════════════════════════════════════════════════════════════
   LOGIN PAGE
   ═══════════════════════════#124164;════════════════════════════════════ */
.login-body {
  display: flex;
  align-items: center;
  justify-content: center;
  min-height: 100vh;
  background: var(--bg);
  overflow: hidden;
}

/* Animated background shapes */
.login-bg {
  position: fixed;
  inset: 0;
  pointer-events: none;
  z-index: 0;
}
.login-bg-shapes {
  position: relative;#124164;
  width: 100%;
  height: 100%;
}
.shape {
  position: absolute;
  border-radius: 50%;
  filter: blur(80px);
  opacity: 0.25;
  animation: float 8s ease-in-out infinite;
}
.shape-1 {
  width: 500px;
  height: 500px;
  background: var(--brand);
  top: -150px;
  left: -150px;
  animation-delay: 0s;
}
.shape-2 {
  width: 400px;
  height: 400px;
  background: #6b21a8;
  bottom: -100px;
  right: -100px;
  animation-delay: 3s;
}
.shape-3 {
  width: 300px;
  height: 300px;
  background: #1d0a40;
  top: 50%;
  left: 50%;
  transform: translate(-50%, -50%);
  animation-delay: 6s;
}
@keyframes float {
  0%,
  100% {
    transform: scale(1) translate(0, 0);
  }
  50% {
    transform: scale(1.08) translate(15px, -20px);
  }
}

.login-main {
  position: relative;
  z-index: 1;
  width: 100%;
  max-width: 440px;
  padding: 24px 16px;
}

.login-card {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-xl);
  padding: 40px 36px;
  box-shadow:
    var(--shadow-card),
    0 0 60px rgba(62, 13, 129, 0.2);
  backdrop-filter: blur(20px);
  animation: fadeSlideUp 0.45s ease both;
}
@keyframes fadeSlideUp {
  from {
    opacity: 0;
    transform: translateY(20px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.login-brand {
  display: flex;
  align-items: center;
  gap: 14px;
  margin-bottom: 0;
}
.login-logo {
  height: 44px;
  width: auto;
  filter: brightness(1.1);
}
.login-brand-text {
  display: flex;
  flex-direction: column;
}
.brand-title {
  font-size: 1.15rem;
  font-weight: 700;
  color: var(--text-primary);
  letter-spacing: -0.01em;
}
.brand-sub {
  font-size: 0.75rem;
  color: var(--text-muted);
  letter-spacing: 0.04em;
  text-transform: uppercase;
}

.login-divider {
  height: 1px;
  background: linear-gradient(
    90deg,
    transparent,
    var(--border-hover),
    transparent
  );
  margin: 28px 0;
}

.login-alert {
  display: flex;
  align-items: center;
  gap: 10px;
  background: var(--error-bg);
  border: 1px solid rgba(244, 63, 94, 0.3);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  color: var(--error);
  font-size: 0.875rem;
  margin-bottom: 20px;
  animation: shake 0.35s ease;
}
@keyframes shake {
  0%,
  100% {
    transform: translateX(0);
  }
  20% {
    transform: translateX(-6px);
  }
  40% {
    transform: translateX(6px);
  }
  60% {
    transform: translateX(-4px);
  }
  80% {
    transform: translateX(4px);
  }
}

.login-form {
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.field-group {#124164;
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.field-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--text-secondary);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.field-wrap {
  position: relative;
  display: flex;
  align-items: center;
}
.field-icon {
  position: absolute;
  left: 14px;
  color: var(--text-muted);
  font-size: 0.85rem;
  pointer-events: none;
  transition: color 0.2s;
}
.field-input {
  width: 100%;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  padding: 12px 44px;
  color: var(--text-primary);
  font-size: 0.95rem;
  transition:
    border-color 0.2s,
    box-shadow 0.2s;
  outline: none;
}
.field-input::placeholder {
  color: var(--text-muted);
}
.field-input:focus {
  border-color: var(--brand-light);
  box-shadow: 0 0 0 3px var(--brand-glow);
}
.field-input:focus + .field-icon,
.field-wrap:focus-within .field-icon {
  color: var(--brand-light);
}

.field-eye {
  position: absolute;
  right: 12px;
  background: transparent;
  border: none;
  color: var(--text-muted);
  font-size: 0.85rem;
  padding: 4px;
  cursor: pointer;
  transition: color 0.2s;
}
.field-eye:hover {
  color: var(--brand-light);
}

.login-btn {
  display: flex;
  align-items: center;#124164;
  justify-content: center;
  gap: 10px;
  width: 100%;
  padding: 13px 20px;
  background: linear-gradient(135deg, var(--brand-mid), var(--brand));
  color: #fff;
  font-size: 0.95rem;
  font-weight: 600;
  border-radius: var(--radius-sm);
  border: 1px solid rgba(255, 255, 255, 0.1);
  box-shadow: var(--shadow-btn);
  transition:
    transform 0.15s,
    box-shadow 0.15s,
    background 0.2s;
  margin-top: 4px;
}
.login-btn:hover {
  background: linear-gradient(135deg, var(--brand-light), var(--brand-mid));
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(62, 13, 129, 0.6);
}
.login-btn:active {
  transform: translateY(0);
}

.login-footer {
  margin-top: 24px;
  text-align: center;
  font-size: 0.78rem;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
}

/* ═══════════════════════════════════════════════════════════════
   APP LAYOUT
   ═══════════════════════════════════════════════════════════════ */
.app-body {
  display: grid;
  grid-template-rows: auto 1fr auto;
  min-height: 100vh;
  background: var(--bg);
}

/* ── Header ──────────────────────────────────────────────────── */
.app-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 16px;
  padding: 14px 32px;
  background: var(--bg-card);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 2px 20px rgba(0, 0, 0, 0.3);
  position: sticky;
  top: 0;
  z-index: 100;
}

.header-left {
  display: flex;
  align-items: center;
  gap: 14px;
}
.header-logo {
  height: 36px;
  width: auto;
}
.header-title-block {
  display: flex;
  flex-direction: column;
}
.header-title {
  font-size: 1rem;
  font-weight: 700;
  color: var(--text-primary);
}
.header-sub {
  font-size: 0.7rem;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
}

.header-right {
  display: flex;
  align-items: center;
  gap: 12px;
}

.session-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 5px 10px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 99px;
  font-size: 0.78rem;
  color: var(--text-secondary);
  transition:
    border-color 0.3s,
    color 0.3s;
}
.session-badge.warn {
  border-color: rgba(245, 158, 11, 0.5);
  color: var(--warning);
}
.session-badge.danger {
  border-color: rgba(244, 63, 94, 0.5);
  color: var(--error);
}

.user-chip {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 6px 12px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 99px;
  font-size: 0.82rem;
  font-weight: 600;
  color: var(--text-primary);
}
.user-chip i {
  color: var(--brand-light);
}

.logout-btn {
  display: flex;
  align-items: center;
  gap: 7px;
  padding: 7px 14px;
  background: transparent;
  border: 1px solid rgba(244, 63, 94, 0.25);
  border-radius: 99px;
  font-size: 0.82rem;
  color: var(--error);
  transition:
    background 0.2s,
    border-color 0.2s;
}
.logout-btn:hover {
  background: var(--error-bg);
  border-color: rgba(244, 63, 94, 0.5);
  color: var(--error);
}

/* ── Main ────────────────────────────────────────────────────── */
.app-main {
  padding: 32px;
  max-width: 1100px;
  margin: 0 auto;
  width: 100%;
  display: flex;
  flex-direction: column;
  gap: 32px;
}

/* ── Section headers ─────────────────────────────────────────── */
.section-header {
  display: flex;
  align-items: baseline;
  gap: 12px;
  margin-bottom: 18px;
  flex-wrap: wrap;
}
.section-header h2 {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-primary);
  display: flex;
  align-items: center;
  gap: 8px;
}
.section-header h2 i {
  color: var(--brand-light);
  font-size: 0.95rem;
}
.section-header p {
  font-size: 0.82rem;
  color: var(--text-muted);
  margin-left: auto;
}
.files-count {
  margin-left: auto;
  padding: 2px 10px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: 99px;
  font-size: 0.78rem;
  color: var(--text-secondary);
  display: inline-flex;
  align-items: center;
  gap: 5px;
}
.files-count-sep {
  color: var(--text-muted);
  font-size: 0.7rem;
}
#files-total-size {
  color: var(--brand-light);
  font-weight: 600;
}

/* ── Upload Section ──────────────────────────────────────────── */
.upload-section {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-card);
}

/* Drop Zone */
.drop-zone {
  border: 2px dashed rgba(122, 63, 212, 0.4);
  border-radius: var(--radius);
  background: rgba(62, 13, 129, 0.06);
  transition:
    border-color 0.25s,
    background 0.25s,
    transform 0.15s;
  cursor: pointer;
  position: relative;
}
.drop-zone:hover,
.drop-zone.drag-over {
  border-color: var(--brand-light);
  background: rgba(62, 13, 129, 0.14);
}
.drop-zone.drag-over {
  transform: scale(1.01);
}

.drop-zone-inner {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 48px 24px;
  text-align: center;
  gap: 10px;
}

.drop-icon-wrap {
  width: 72px;
  height: 72px;
  background: linear-gradient(135deg, var(--brand), var(--brand-mid));
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 8px;
  box-shadow: 0 0 30px rgba(62, 13, 129, 0.5);
  transition:
    transform 0.2s,
    box-shadow 0.2s;
}
.drop-zone:hover .drop-icon-wrap,
.drop-zone.drag-over .drop-icon-wrap {
  transform: scale(1.1) translateY(-3px);
  box-shadow: 0 8px 40px rgba(62, 13, 129, 0.7);
}
.drop-icon {
  font-size: 1.8rem;
  color: #fff;
}

.drop-primary {
  font-size: 1.05rem;
  font-weight: 700;
  color: var(--text-primary);
}
.drop-secondary {
  font-size: 0.82rem;
  color: var(--text-muted);
}

.drop-browse-btn {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  padding: 9px 20px;
  background: linear-gradient(135deg, var(--brand-mid), var(--brand));
  color: #fff;
  font-size: 0.88rem;
  font-weight: 600;
  border-radius: 99px;
  cursor: pointer;
  border: none;
  box-shadow: var(--shadow-btn);
  transition:
    transform 0.15s,
    box-shadow 0.15s;
}
.drop-browse-btn:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(62, 13, 129, 0.6);
}

.drop-hint {
  font-size: 0.74rem;
  color: var(--text-muted);
  max-width: 480px;
  line-height: 1.5;
  margin-top: 4px;
}
.drop-hint strong {
  color: var(--error);
}

/* ── Upload Queue ────────────────────────────────────────────── */
.upload-queue {
  margin-top: 20px;
  background: var(--bg-elevated);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  overflow: hidden;
}

.queue-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-secondary);
}
.queue-actions {
  display: flex;
  gap: 8px;
}

.btn-clear {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 14px;
  background: transparent;
  border: 1px solid rgba(244, 63, 94, 0.3);
  border-radius: 99px;
  font-size: 0.8rem;
  color: var(--error);
  transition:
    background 0.2s,
    border-color 0.2s;
}
.btn-clear:hover {
  background: var(--error-bg);
  border-color: rgba(244, 63, 94, 0.5);
}

.btn-upload {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 16px;
  background: linear-gradient(135deg, var(--brand-mid), var(--brand));
  border: none;
  border-radius: 99px;
  font-size: 0.8rem;
  color: #fff;
  font-weight: 600;
  box-shadow: var(--shadow-btn);
  transition:
    transform 0.15s,
    box-shadow 0.15s;
}
.btn-upload:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(62, 13, 129, 0.6);
}
.btn-upload:disabled {
  opacity: 0.5;
  cursor: not-allowed;
  transform: none;
}

/* Global progress bar */
.global-progress-wrap {
  padding: 14px 18px;
  border-bottom: 1px solid var(--border);
  background: rgba(62, 13, 129, 0.08);
}
.global-progress-info {
  display: flex;
  align-items: center;
  font-size: 0.8rem;
  color: var(--text-secondary);
  margin-bottom: 8px;
  gap: 8px;
}
.global-progress-info #global-progress-label {
  flex: 1;
  font-weight: 600;
  color: var(--text-primary);
}
.global-progress-sizes {
  font-size: 0.75rem;
  color: var(--text-muted);
  margin-top: 5px;
  text-align: right;
}

.progress-bar-track {
  width: 100%;
  height: 6px;
  background: var(--bg-card);
  border-radius: 99px;
  overflow: hidden;
}
.progress-bar-fill {
  height: 100%;
  background: linear-gradient(90deg, var(--brand-mid), var(--brand-light));
  border-radius: 99px;
  transition: width 0.2s ease;
}
.global-track {
  height: 8px;
}

/* File queue list */
.file-queue-list {
  padding: 8px 0;
}
.queue-item {
  display: grid;
  grid-template-columns: auto 1fr auto;
  align-items: center;
  gap: 12px;
  padding: 10px 18px;
  border-bottom: 1px solid var(--border);
  transition: background 0.15s;
}
.queue-item:last-child {
  border-bottom: none;
}
.queue-item:hover {
  background: rgba(255, 255, 255, 0.02);
}

.qi-icon {
  font-size: 1.1rem;
  color: var(--brand-light);
  width: 20px;
  text-align: center;
}
.qi-info {
  min-width: 0;
}
.qi-name {
  font-size: 0.85rem;
  font-weight: 600;
  color: var(--text-primary);
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
}
.qi-meta {
  font-size: 0.73rem;
  color: var(--text-muted);
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.qi-progress-wrap {
  width: 100%;
  margin-top: 5px;
}
.qi-progress-track {
  width: 100%;
  height: 4px;
  background: var(--bg-card);
  border-radius: 99px;
  overflow: hidden;
}
.qi-progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--brand-mid), var(--brand-light));
  border-radius: 99px;
  transition: width 0.15s;
}

.qi-status {
  font-size: 0.78rem;
  font-weight: 600;
  white-space: nowrap;
}
.qi-status.pending {
  color: var(--text-muted);
}
.qi-status.uploading {
  color: var(--brand-light);
}
.qi-status.done {
  color: var(--success);
}
.qi-status.error {
  color: var(--error);
}

/* Upload results */
.upload-results {
  margin-top: 16px;
  padding: 16px;
  border-radius: var(--radius-sm);
  font-size: 0.85rem;
}
.result-success {
  background: var(--success-bg);
  border: 1px solid rgba(34, 197, 94, 0.25);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  color: var(--success);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
}
.result-error {
  background: var(--error-bg);
  border: 1px solid rgba(244, 63, 94, 0.25);
  border-radius: var(--radius-sm);
  padding: 12px 14px;
  color: var(--error);
  margin-bottom: 8px;
  display: flex;
  align-items: center;
  gap: 8px;
}

/* ── Files Section ───────────────────────────────────────────── */
.files-section {
  background: var(--bg-card);
  border: 1px solid var(--border);
  border-radius: var(--radius-lg);
  padding: 28px;
  box-shadow: var(--shadow-card);
}

.files-empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 64px 24px;
  gap: 12px;
  color: var(--text-muted);
  text-align: center;
}
.files-empty i {
  font-size: 2.5rem;
  opacity: 0.4;
}
.files-empty p {
  font-size: 0.9rem;
}

.files-table-wrap {
  overflow-x: auto;
  border-radius: var(--radius-sm);
}

.files-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 0.875rem;
}
.files-table thead tr {
  background: var(--bg-elevated);
  border-bottom: 1px solid var(--border);
}
.files-table th {
  padding: 10px 14px;
  text-align: left;
  font-size: 0.74rem;
  font-weight: 700;
  color: var(--text-muted);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  white-space: nowrap;
  user-select: none;
}
.files-table th[data-sort] {
  cursor: pointer;
  transition: color 0.2s;
}
.files-table th[data-sort]:hover {
  color: var(--brand-light);
}
.files-table th i {
  font-size: 0.65rem;
  margin-left: 4px;
}

.files-table tbody tr {
  border-bottom: 1px solid var(--border);
  transition: background 0.15s;
}
.files-table tbody tr:last-child {
  border-bottom: none;
}
.files-table tbody tr:hover {
  background: rgba(62, 13, 129, 0.07);
}

.files-table td {
  padding: 11px 14px;
  vertical-align: middle;
}

.col-name {
  min-width: 220px;
}
.col-name span {
  display: flex;
  align-items: center;
  gap: 9px;
}
.file-type-icon {
  color: var(--brand-light);
  font-size: 0.9rem;
  width: 16px;
  flex-shrink: 0;
}

.col-type {
  color: var(--text-muted);
  font-size: 0.78rem;
  font-family: var(--font-mono);
}
.col-size {
  color: var(--text-secondary);
  white-space: nowrap;
}
.col-date {
  color: var(--text-muted);
  white-space: nowrap;
  font-size: 0.82rem;
}
.col-action {
  text-align: center;
}

.dl-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 34px;
  height: 34px;
  background: rgba(62, 13, 129, 0.2);
  border: 1px solid rgba(122, 63, 212, 0.3);
  border-radius: var(--radius-sm);
  color: var(--brand-light);
  font-size: 0.85rem;
  transition:
    background 0.2s,
    border-color 0.2s,
    transform 0.15s,
    color 0.2s;
}
.dl-btn:hover {
  background: var(--brand);
  border-color: var(--brand-light);
  color: #fff;
  transform: translateY(-1px);
}

/* Row newly added (from JS) */
.files-table tbody tr.row-new {
  animation: rowAppear 0.4s ease both;
}
@keyframes rowAppear {
  from {
    opacity: 0;
    background: rgba(62, 13, 129, 0.25);
  }
  to {
    opacity: 1;
    background: transparent;
  }
}

/* ── Footer ──────────────────────────────────────────────────── */
.app-footer {
  display: flex;
  align-items: center;
  justify-content: space-between;
  flex-wrap: wrap;
  gap: 8px;
  padding: 14px 32px;
  border-top: 1px solid var(--border);
  background: var(--bg-card);
  font-size: 0.75rem;
  color: var(--text-muted);
}

/* ═══════════════════════════════════════════════════════════════
   RESPONSIVE
   ═══════════════════════════════════════════════════════════════ */
@media (max-width: 768px) {
  .app-header {
    padding: 12px 16px;
    flex-wrap: wrap;
  }
  .app-main {
    padding: 16px;
  }
  .upload-section,
  .files-section {
    padding: 18px;
  }
  .drop-zone-inner {
    padding: 32px 16px;
  }
  .app-footer {
    padding: 12px 16px;
    flex-direction: column;
    text-align: center;
  }
  .header-right {
    gap: 8px;
  }
  .logout-btn span {
    display: none;
  }
  .session-badge span {
    display: none;
  }
  .files-table .col-type,
  .files-table .col-date {
    display: none;
  }
}

@media (max-width: 480px) {
  .login-card {
    padding: 28px 20px;
  }
  .queue-item {
    grid-template-columns: 1fr auto;
  }
  .qi-icon {
    display: none;
  }
}

/* ═══════════════════════════════════════════════════════════════
   BULK SELECT — Checkboxes & Toolbar
   ═══════════════════════════════════════════════════════════════ */

/* ── Custom checkbox ─────────────────────────────────────────── */
.cb-wrap {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  line-height: 1;
}
.cb-wrap input[type="checkbox"] {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
  pointer-events: none;
}
.cb-box {
  display: inline-block;
  width: 17px;
  height: 17px;
  border: 1.5px solid rgba(122, 63, 212, 0.45);
  border-radius: 4px;
  background: var(--bg-elevated);
  transition: border-color 0.15s, background 0.15s, box-shadow 0.15s;
  position: relative;
  flex-shrink: 0;
}
/* Tick mark */
.cb-box::after {
  content: '';
  position: absolute;
  display: none;
  left: 4px;
  top: 1px;
  width: 5px;
  height: 9px;
  border: 2px solid #fff;
  border-top: none;
  border-left: none;
  transform: rotate(45deg);
}
.cb-wrap input:checked ~ .cb-box {
  background: linear-gradient(135deg, var(--brand-mid), var(--brand-light));
  border-color: var(--brand-light);
  box-shadow: 0 0 0 3px var(--brand-glow);
}
.cb-wrap input:checked ~ .cb-box::after {
  display: block;
}
/* Indeterminate — for select-all */
.cb-wrap input:indeterminate ~ .cb-box {
  background: linear-gradient(135deg, var(--brand-mid), var(--brand-light));
  border-color: var(--brand-light);
}
.cb-wrap input:indeterminate ~ .cb-box::after {
  display: block;
  top: 50%;
  left: 3px;
  width: 9px;
  height: 0;
  border: none;
  border-top: 2px solid #fff;
  transform: translateY(-50%);
}
.cb-wrap:hover .cb-box {
  border-color: var(--brand-light);
}

/* ── Column sizing ───────────────────────────────────────────── */
.col-check {
  width: 38px;
  text-align: center;
  padding: 10px 6px 10px 14px !important;
}
.col-check-hidden {
  display: none;
}
th.col-check {
  padding: 10px 6px 10px 14px !important;
}

/* ── Selected row highlight ──────────────────────────────────── */
.files-table tbody tr.row-selected {
  background: rgba(62, 13, 129, 0.13) !important;
}
.files-table tbody tr.row-selected:hover {
  background: rgba(62, 13, 129, 0.18) !important;
}
/* Make entire non-action row feel clickable */
.files-table tbody tr {
  cursor: default;
}

/* ── Bulk toolbar ────────────────────────────────────────────── */
.bulk-toolbar[hidden] {
  display: none !important;
}
.bulk-toolbar {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 10px 16px;
  margin-bottom: 12px;
  background: rgba(62, 13, 129, 0.12);
  border: 1px solid rgba(122, 63, 212, 0.35);
  border-radius: var(--radius-sm);
  animation: toolbarSlide 0.2s ease both;
}
@keyframes toolbarSlide {
  from { opacity: 0; transform: translateY(-6px); }
  to   { opacity: 1; transform: translateY(0); }
}
.bulk-info {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 0.83rem;
  font-weight: 600;
  color: var(--brand-pale);
}
.bulk-info i {
  color: var(--brand-light);
  font-size: 0.9rem;
}
.bulk-actions {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
}

.btn-bulk-deselect {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 13px;
  background: transparent;
  border: 1px solid rgba(244, 63, 94, 0.3);
  border-radius: 99px;
  font-size: 0.79rem;
  color: var(--error);
  transition: background 0.2s, border-color 0.2s;
}
.btn-bulk-deselect:hover {
  background: var(--error-bg);
  border-color: rgba(244, 63, 94, 0.55);
}

.btn-bulk-download {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 16px;
  background: linear-gradient(135deg, var(--brand-mid), var(--brand));
  border: none;
  border-radius: 99px;
  font-size: 0.79rem;
  color: #fff;
  font-weight: 600;
  box-shadow: var(--shadow-btn);
  transition: transform 0.15s, box-shadow 0.15s, opacity 0.2s;
}
.btn-bulk-download:hover {
  transform: translateY(-1px);
  box-shadow: 0 6px 20px rgba(62, 13, 129, 0.6);
}
.btn-bulk-download:disabled {
  opacity: 0.55;
  cursor: not-allowed;
  transform: none;
}

/* ── Responsive ──────────────────────────────────────────────── */
@media (max-width: 768px) {
  .bulk-toolbar {
    flex-direction: column;
    align-items: flex-start;
    gap: 8px;
  }
  .col-check { padding: 10px 4px 10px 10px !important; }
}
