/* ================= RESET ================= */
* {
  box-sizing: border-box;
  font-family: "Inter", system-ui, -apple-system, BlinkMacSystemFont;
}

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 20% 20%, #1e1b4b, transparent 40%),
    radial-gradient(circle at 80% 10%, #020617, transparent 40%),
    linear-gradient(135deg, #020617, #020617);
  color: #e5e7eb;
}

/* ================= GLASS ================= */
.glass {
  background: rgba(255, 255, 255, 0.06);
  backdrop-filter: blur(20px);
  -webkit-backdrop-filter: blur(20px);
  border-radius: 22px;
  border: 1px solid rgba(255,255,255,0.08);
}

/* ================= BUTTONS ================= */
button {
  border: none;
  cursor: pointer;
  border-radius: 14px;
  padding: 12px 16px;
  font-size: 14px;
  font-weight: 600;
  transition: all 0.25s ease;
}

/* 🔥 NEON PRIMARY */
.primary {
  background: linear-gradient(135deg, #22d3ee, #6366f1);
  color: #020617;
  box-shadow: 0 0 18px rgba(99,102,241,0.45);
}

.primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 28px rgba(34,211,238,0.7);
}

/* 🔥 NEON SECONDARY */
.secondary {
  background: linear-gradient(135deg, #a78bfa, #22d3ee);
  color: #020617;
  box-shadow: 0 0 14px rgba(167,139,250,0.5);
}

/* 🔴 DANGER */
.danger {
  background: linear-gradient(135deg, #f43f5e, #ef4444);
  color: white;
  box-shadow: 0 0 14px rgba(239,68,68,0.5);
}

/* ================= TOP BAR ================= */
.topbar {
  margin: 20px;
  padding: 20px 24px;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.topbar h2 {
  margin: 0;
  font-weight: 700;
  letter-spacing: 0.4px;
}

/* ================= PANELS ================= */
.panel {
  margin: 20px;
  padding: 20px 22px;
}

/* ================= CONTROLS ================= */
.controls {
  display: flex;
  justify-content: space-between;
  align-items: center;
  gap: 14px;
}

.controls button {
  background: rgba(255,255,255,0.1);
  color: #e5e7eb;
}

.controls button.active {
  background: linear-gradient(135deg, #22d3ee, #6366f1);
  color: #020617;
}

/* ================= INPUTS ================= */
select,
input[type="file"],
input[type="email"],
input[type="password"],
input[type="text"] {
  background: rgba(255,255,255,0.08);
  border: 1px solid rgba(255,255,255,0.15);
  color: #e5e7eb;
  padding: 14px 14px;
  border-radius: 14px;
  outline: none;
}

/* ================= STORAGE BAR ================= */
.progress {
  margin-top: 12px;
  width: 100%;
  height: 10px;
  background: rgba(255,255,255,0.12);
  border-radius: 10px;
}

#storageBar {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, #22d3ee, #6366f1);
  border-radius: 10px;
}

/* ================= UPLOAD PANEL ================= */
.upload-panel {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  align-items: center;
}

.upload-panel .hint {
  opacity: 0.6;
  font-size: 13px;
}

/* ================= FILE GRID ================= */
.files-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 22px;
  padding: 20px;
}

.files-grid.list {
  display: flex;
  flex-direction: column;
}

/* ================= FILE CARD ================= */
.file-card {
  padding: 18px;
  border-radius: 22px;
  transition: all 0.3s ease;
}

.file-card:hover {
  transform: translateY(-6px);
  box-shadow:
    0 10px 40px rgba(0,0,0,0.5),
    0 0 22px rgba(99,102,241,0.25);
}

.file-name {
  font-weight: 600;
  margin-bottom: 6px;
  word-break: break-word;
}

.file-size,
.file-folder {
  font-size: 13px;
  opacity: 0.7;
}

/* ================= ACTIONS ================= */
.actions {
  display: flex;
  gap: 10px;
  margin-top: 16px;
}

.actions button {
  flex: 1;
  background: rgba(255,255,255,0.12);
  color: #e5e7eb;
}

.actions button:hover {
  background: linear-gradient(135deg, #22d3ee, #6366f1);
  color: #020617;
}

/* ================= DRAG & DROP ================= */
.drag {
  outline: 2px dashed #22d3ee;
  background: rgba(34,211,238,0.08);
}

/* ================= TOAST ================= */
#toast {
  position: fixed;
  bottom: 90px;
  left: 50%;
  transform: translateX(-50%);
  background: #020617;
  padding: 14px 22px;
  border-radius: 16px;
  font-size: 14px;
  display: none;
  box-shadow: 0 0 30px rgba(99,102,241,0.45);
}

/* ================= MOBILE BAR ================= */
.mobile-bar {
  display: none;
}

.mobile-bar button {
  background: linear-gradient(135deg, #22d3ee, #6366f1);
  color: #020617;
}

/* ================= AUTH PAGE ================= */
.auth-bg {
  display: flex;
  justify-content: center;
  align-items: center;
  height: 100vh;
}

.auth-card {
  width: 380px;
  padding: 34px;
  text-align: center;
}

.auth-card h2 {
  margin-bottom: 6px;
  font-weight: 700;
}

.auth-card .muted {
  opacity: 0.7;
  margin-bottom: 24px;
}

/* 🔥 FLOATING INPUTS (FIXED ISSUE) */
.field {
  position: relative;
  margin-top: 22px;
}

.field input {
  width: 100%;
  padding: 16px 14px;
  background: rgba(255,255,255,0.06);
}

.field label {
  position: absolute;
  left: 14px;
  top: 50%;
  transform: translateY(-50%);
  font-size: 14px;
  color: rgba(229,231,235,0.7);
  pointer-events: none;
  transition: all 0.2s ease;
}

/* ✅ FLOAT ON FOCUS / FILLED */
.field input:focus + label,
.field input:not(:placeholder-shown) + label {
  top: 6px;
  font-size: 11px;
  color: #22d3ee;
}

/* PASSWORD TOGGLE */
#togglePwd {
  position: absolute;
  right: 14px;
  top: 50%;
  transform: translateY(-50%);
  cursor: pointer;
  opacity: 0.7;
}

/* ================= RESPONSIVE ================= */
@media (max-width: 700px) {
  .controls {
    flex-direction: column;
    align-items: stretch;
  }

  .upload-panel {
    flex-direction: column;
    align-items: stretch;
  }

  .mobile-bar {
    display: flex;
    position: fixed;
    bottom: 12px;
    left: 12px;
    right: 12px;
    padding: 16px;
    gap: 14px;
    justify-content: space-around;
    border-radius: 24px;
  }
}




/* ===== MODAL ===== */
.modal-backdrop {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0,0,0,0.6);
  justify-content: center;
  align-items: center;
  z-index: 50;
}

.modal {
  width: 360px;
  padding: 26px;
  text-align: center;
}

.modal h3 {
  margin-bottom: 16px;
}

.modal input {
  width: 100%;
  padding: 14px;
  border-radius: 14px;
  margin-bottom: 16px;
}

.modal-actions {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.modal-actions button {
  width: 100%;
}





.auth-tabs {
  display: flex;
  gap: 10px;
  margin-bottom: 20px;
}

.auth-tabs button {
  flex: 1;
  background: rgba(255,255,255,0.1);
  color: #e5e7eb;
}

.auth-tabs button.active {
  background: linear-gradient(135deg, #22d3ee, #6366f1);
  color: #020617;
}

.full {
  width: 100%;
}

.msg {
  margin-top: 16px;
  font-size: 14px;
  min-height: 18px;
}

.hint {
  font-size: 12px;
  opacity: 0.7;
  margin-bottom: 12px;
}
