/* CSV Cleaner by SWC - Glow aesthetic */
:root{
  --bg1: #0b1020;
  --bg2: radial-gradient(1200px 800px at 10% 10%, rgba(60,120,255,0.18), transparent),
          radial-gradient(1000px 700px at 90% 30%, rgba(255,80,180,0.15), transparent),
          radial-gradient(800px 600px at 50% 90%, rgba(120,255,200,0.12), transparent);
  --card: rgba(255,255,255,0.06);
  --text: #e6ecff;
  --muted: #a7b0d0;
  --accent: #7aa8ff;
  --accent2: #ff6ad5;
  --shadow: 0 0 25px rgba(122,168,255,0.35), 0 0 60px rgba(255,106,213,0.2);
  --radius: 18px;
}

*{box-sizing:border-box}
html,body{height:100%}
body{
  margin:0;
  font-family: ui-sans-serif, system-ui, -apple-system, Segoe UI, Roboto, Helvetica, Arial;
  background: var(--bg1);
  color: var(--text);
  background-image: var(--bg2);
  background-attachment: fixed;
}

.app{max-width:1200px; margin:0 auto; padding:24px;}

.topbar{
  display:flex; align-items:center; justify-content:space-between;
  margin-bottom:16px;
}
.topbar h1{font-size:28px; letter-spacing:0.4px}
.topbar .by{font-weight:600; color:var(--accent2); text-shadow:var(--shadow)}

.actions{display:flex; gap:12px}

.btn{
  background: linear-gradient(135deg, rgba(122,168,255,0.25), rgba(255,106,213,0.25));
  border:1px solid rgba(255,255,255,0.15);
  padding:10px 16px; border-radius:14px; color:var(--text);
  backdrop-filter: blur(6px);
  box-shadow: var(--shadow);
  cursor:pointer; transition: transform .12s ease, background .2s;
}
.btn:disabled{opacity:.5; cursor:not-allowed; box-shadow:none}
.btn:hover{transform: translateY(-1px) scale(1.01)}

.btn.ghost{
  background: transparent;
  border:1px solid rgba(255,255,255,0.12);
  box-shadow:none;
}

.invisible{display:none}

.uploader{
  margin:6px 0 18px 0;
}
.dropzone{
  position:relative;
  border:1px dashed rgba(255,255,255,0.25);
  border-radius: var(--radius);
  padding:28px;
  text-align:center;
  background: rgba(255,255,255,0.03);
  box-shadow: var(--shadow);
  cursor:pointer;
}
.dropzone:hover{background: rgba(255,255,255,0.05)}
.dropzone input[type=file]{
  position:absolute; inset:0; width:100%; height:100%; opacity:0; cursor:pointer;
}
.dropzone .hint{color:var(--muted); margin-top:6px}

.card{
  background: var(--card);
  border:1px solid rgba(255,255,255,0.12);
  border-radius: var(--radius);
  padding:18px;
  box-shadow: var(--shadow);
  margin-bottom:16px;
}

.controls h2, .preview h2{margin:0 0 12px 0}

.grid{
  display:grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap:12px;
}
.field{display:flex; flex-direction:column; gap:6px}
.field select{
  width:100%; padding:8px; border-radius:12px;
  background: rgba(0,0,0,0.25); color:var(--text);
  border:1px solid rgba(255,255,255,0.18);
  min-height:120px;
}

.switch{
  display:flex; gap:10px; align-items:center;
  padding:10px 12px; border-radius:12px; background: rgba(255,255,255,0.04);
  border:1px solid rgba(255,255,255,0.1);
}

.previewHead{display:flex; align-items:center; justify-content:space-between; margin-bottom:8px}
.meta{display:flex; gap:10px; color:var(--muted)}
.tableWrap{overflow:auto; border-radius:12px; border:1px solid rgba(255,255,255,0.1)}
.table{width:100%; border-collapse: collapse; font-size:14px; background: rgba(0,0,0,0.2)}
.table th, .table td{padding:8px 10px; border-bottom:1px solid rgba(255,255,255,0.08)}
.table th{position:sticky; top:0; background: rgba(20,20,40,0.8); backdrop-filter: blur(6px)}

.foot{display:flex; align-items:center; justify-content:space-between; color:var(--muted)}

@media (max-width: 760px){
  .grid{grid-template-columns: 1fr}
}
