:root{
  --wonq-blue: #36c4f0;
  --wonq-blue-deep: #1aa3cf;
  --wonq-grey: #0b0d10;
  --wonq-grey-2: #121418;
  --wonq-text: #e8f6ff;
  --wonq-muted: #8fb9cc;
  --wonq-border: #22323a;
}
*{box-sizing:border-box}
body{font-family:system-ui,-apple-system,Segoe UI,Roboto,Ubuntu;max-width:1100px;margin:0 auto;padding:1rem;background:var(--wonq-grey);color:var(--wonq-text)}
header{display:flex;justify-content:space-between;align-items:center;margin-bottom:1rem;border-bottom:1px solid var(--wonq-border)}
header h1{font-size:1.2rem}
nav a{color:var(--wonq-blue); margin-right:.75rem}
nav .user{margin-right:.75rem; color:var(--wonq-muted)}
.login{display:grid;place-items:center;margin-top:6vh}
.login .brand{margin-bottom:1rem;filter:drop-shadow(0 10px 20px rgba(0,0,0,.45));}
.login .brand img{max-width:520px;width:90%;height:auto;border-radius:8px}
.login form{background:var(--wonq-grey-2);border:1px solid var(--wonq-border);padding:1rem 1.25rem;border-radius:12px;box-shadow:0 10px 30px rgba(0,0,0,.35);}
.login label{display:grid;color:var(--wonq-muted);font-size:.9rem;margin-bottom:.5rem}
.login input{padding:.55rem .7rem;border-radius:8px;border:1px solid var(--wonq-border);background:#0e1216;color:var(--wonq-text)}
.error{color:#f66}
.listing{width:100%;border-collapse:collapse;margin-top:1rem}
.listing th,.listing td{border-bottom:1px solid var(--wonq-border);padding:.4rem;text-align:left}
.crumbs a{color:var(--wonq-blue)}
.usage{float:right;color:var(--wonq-muted)}
button{background:linear-gradient(180deg,var(--wonq-blue),var(--wonq-blue-deep));border:0;color:#04222c;border-radius:10px;font-weight:700;box-shadow:0 6px 20px rgba(54,196,240,.25);padding:.5rem .9rem}
button:hover{filter:brightness(1.05)}
.uppy-wrap{margin-top:1rem}


/* ---- Wicked UI facelift ---- */
html, body { height: 100%; }
body{
  background: radial-gradient(1200px 800px at 50% 0%, rgba(20,40,60,.35), rgba(0,0,0,.85) 60%),
              url('/static/bg_wicked.webp') center top / cover no-repeat fixed,
              var(--wonq-grey);
  color: var(--wonq-text);
  font-family: "Hack Nerd Font", "Hack Nerd Mono", "Hack", ui-monospace, SFMono-Regular, Menlo, Consolas, "Liberation Mono", Monaco, monospace;
}
table.listing{
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
  margin-top: 1rem;
  background: rgba(0,0,0,.35) url('/static/bg_grid.webp') left top repeat-y;
  backdrop-filter: blur(2px);
  border: 1px solid var(--wonq-border);
  border-radius: 12px;
  overflow: hidden;
}
.listing thead th{
  text-transform: uppercase;
  letter-spacing: .05em;
  font-size: .8rem;
  background: rgba(20,26,32,.75);
  border-bottom: 1px solid var(--wonq-border);
  padding: .6rem .5rem;
  color: #bfefff;
}
.listing tbody tr{
  border-bottom: 1px solid var(--wonq-border);
}
.listing tbody tr:hover{ background: rgba(54,196,240,.18); }
.listing td{
  padding: .45rem .5rem;
  vertical-align: middle;
}
.listing td.name{
  display: flex;
  align-items: center;
  gap: .5rem;
  font-weight: 600;
  color: #fff;
}
.listing td .icon{ width:20px; height:20px; opacity:.95; filter: drop-shadow(0 0 6px rgba(54,196,240,.35)); }
.listing td.type, .listing td.mtime, .listing td.size{
  color: var(--wonq-muted);
  font-size: .9rem;
}
header, .actions, .uppy-wrap, .crumbs{ 
  background: rgba(10,12,15,.45);
  border: 1px solid var(--wonq-border);
  border-radius: 12px;
  padding: .6rem .8rem;
}
header{ border-bottom: none; }
.crumbs{ display: flex; align-items: center; gap: .5rem; flex-wrap: wrap; }
.crumbs a{ color: var(--wonq-blue); }


/* Fullscreen bg and shifted left */
html, body { height: 100%; }
body{
  max-width: 1400px;
  background:
    radial-gradient(1200px 800px at 50% 0%, rgba(20,40,60,.35), rgba(0,0,0,.85) 60%),
    url('/static/bg_wicked.webp') left -180px top / cover no-repeat fixed,
    var(--wonq-grey);
}
/* Filename links always white, no purple visited */
.listing td.name a,
.listing td.name a:visited,
.listing td.name a:active { color: #fff; text-decoration: none; }
.listing td.name a:hover { text-decoration: underline; }
/* Widen table and nicer layout */
table.listing { table-layout: auto; }
.download-toolbar { margin-top: 1.0rem; }
/* Buttons tiny */
.btn.tiny{ padding: .25rem .5rem; font-size: .85rem; border-radius: 8px; background: linear-gradient(180deg,var(--wonq-blue),var(--wonq-blue-deep)); color:#04222c; display:inline-block }
.btn.tiny:hover{ filter: brightness(1.05) }
.actions { text-align: right; }


/* Toolbar at top */
.toolbar{
  display:flex; align-items:center; gap:.5rem; flex-wrap:wrap;
  background: rgba(10,12,15,.45);
  border: 1px solid var(--wonq-border);
  border-radius: 12px;
  padding: .6rem .8rem;
  margin-bottom: .8rem;
}
.hint{ color: var(--wonq-muted); font-size: .9rem }

.btn{ background:#1b2a33; border:1px solid var(--wonq-border); color:#e8f6ff; padding:.45rem .7rem; border-radius:10px }
.btn.primary{ background:linear-gradient(180deg,var(--wonq-blue),var(--wonq-blue-deep)); color:#04222c; border:0; box-shadow:0 6px 20px rgba(54,196,240,.25) }
.btn.primary:hover{ filter:brightness(1.05) }

/* Responsive table */
@media (max-width: 820px){
  .listing td.type, .listing th:nth-child(3){ display:none; }
  .listing td.mtime, .listing th:nth-child(5){ display:none; }
}
@media (max-width: 560px){
  body{ padding:.5rem }
  .listing td.size, .listing th:nth-child(4){ display:none; }
  .actions .btn.tiny{ padding:.2rem .45rem; font-size:.8rem }
}


/* Sticky bottom upload progress */
.wbx-progress{
  position: fixed; left: 0; right: 0; bottom: 0;
  padding: .6rem .9rem;
  background: rgba(0,0,0,.7);
  border-top: 1px solid var(--wonq-border);
  box-shadow: 0 -8px 30px rgba(0,0,0,.35);
  z-index: 9999;
}
.wbx-progress.hidden{ display: none; }
.wbx-progress .wp-inner{ max-width: 980px; margin: 0 auto; display:flex; align-items:center; gap:.8rem }
.wbx-progress .wp-label{ color:#7fe3ff; font-weight:700; letter-spacing:.08em }
.wbx-progress .wp-bar{ flex:1; height:16px; border:2px solid #36c4f0; border-radius:10px; position:relative; overflow:hidden; background: rgba(10,18,24,.7) }
.wbx-progress .wp-fill{
  position:absolute; left:0; top:0; height:100%; width:0%;
  background: linear-gradient(90deg, rgba(54,196,240,.9), rgba(26,163,207,.9));
  /* diagonal stripes */
  mask-image: linear-gradient( -45deg, rgba(0,0,0,.2) 25%, rgba(0,0,0,.6) 25%, rgba(0,0,0,.6) 50%,
                               rgba(0,0,0,.2) 50%, rgba(0,0,0,.2) 75%, rgba(0,0,0,.6) 75% );
  mask-size: 24px 24px;
  animation: wbx-stripes 1s linear infinite;
}
@keyframes wbx-stripes {
  from { mask-position: 0 0; }
  to   { mask-position: 24px 0; }
}
.wbx-progress .wp-pct{ width:62px; text-align:right; color:#bfefff; font-weight:700 }
@media (max-width: 560px){
  .wbx-progress .wp-inner{ gap:.5rem }
  .wbx-progress .wp-label{ display:none }
}

.btn.danger{ background: linear-gradient(180deg,#ff6a6a,#e03333); color: #230406; border:0; box-shadow:0 6px 20px rgba(224,51,51,.25) }
.btn.danger:hover{ filter:brightness(1.05) }


/* Branding images */
.brand-left { display:flex; align-items:center; gap:.5rem }
.brand-img { height:132px; width:auto; display:block; max-width:40vw; max-height:22vh; }
footer { text-align:center; margin-top:1rem; }
.footer-inner { display:flex; align-items:center; justify-content:center; gap:.6rem; margin-bottom:.35rem }
.wbx-mini { height:26px; width:auto; display:inline-block; vertical-align:middle; filter: drop-shadow(0 4px 12px rgba(54,196,240,.25)); }
footer .credits { color: var(--wonq-muted); font-size:.9rem; }


/* Icon-only square buttons */
.actions{ display:flex; gap:.4rem; justify-content:flex-end; align-items:center; }
.icon-btn{
  width:36px; height:36px; display:inline-grid; place-items:center;
  border-radius:8px; border:0; cursor:pointer; text-decoration:none;
  background:linear-gradient(180deg,var(--wonq-blue),var(--wonq-blue-deep)); color:#04222c;
  box-shadow:0 6px 20px rgba(54,196,240,.25);
}
.icon-btn.dl{}
.icon-btn.danger{
  background:linear-gradient(180deg,#ff6a6a,#e03333); color:#230406;
  box-shadow:0 6px 20px rgba(224,51,51,.25);
}
.icon-btn:hover{ filter:brightness(1.05); }
  .icon-btn svg{ pointer-events:none; /*
     Use a light colour for the SVG icon glyphs so they remain visible on dark
     button backgrounds.  Previously these were nearly black, making the
     icons appear as indistinct squares. */
    color: var(--wonq-text); filter: drop-shadow(0 0 6px rgba(0,0,0,.2)); }

@media (max-width: 640px){
  .brand-img { height:80px; max-height:18vh; }
}


/* Horizontal bricks bar between content and footer */
.wbx-bricks{
  height: 140px;
  background: url('/static/wbx_bricks_bar.png') repeat-x center;
  background-size: auto 100%;
  margin: 1rem 0 .25rem 0;
  opacity: .9;
  filter: drop-shadow(0 -8px 20px rgba(0,0,0,.35));
  border-top: 1px solid var(--wonq-border);
}
@media (max-width: 640px){
  .wbx-bricks{ height: 100px; }
}


.account { max-width: 680px; margin: 1rem auto; padding: 1rem; }
.account .error { color: #f66; font-weight: 600; margin:.5rem 0; }
.account .ok { color: #7fe37f; font-weight: 600; margin:.5rem 0; }
.account-form label { display:block; margin:.5rem 0; }
.account-form .two { display:grid; grid-template-columns: 1fr 1fr; gap: .75rem; }
.account-form input { width:100%; padding:.5rem .6rem; border-radius:.5rem; border:1px solid #334; background:#0b0f14; color:#dfe6ee; }
.account-form .btn { margin-top:.75rem; }

.uploader-embed{margin:0;padding:0}

.mono{font-family: ui-monospace,SFMono-Regular,Menlo,Monaco,Consolas,monospace;}
