:root {
  --sky-wash: #eaf5ff;
  --cloud: #f9fcff;
  --ink: #17243b;
  --muted: #65728a;
  --line: rgba(53, 84, 128, 0.18);
  --glass: rgba(250, 253, 255, 0.86);
  --cyan: #1d8fba;
  --cyan-dark: #0f688d;
  --sakura: #e786a7;
  --success: #197b62;
  --danger: #b84757;
  font-family: "Avenir Next", "Noto Sans SC", "PingFang SC", "Microsoft YaHei", sans-serif;
  color: var(--ink);
  background: var(--sky-wash);
  font-synthesis: none;
}

* { box-sizing: border-box; }

html, body { min-height: 100%; }

body {
  margin: 0;
  min-width: 320px;
  background:
    linear-gradient(105deg, rgba(237, 247, 255, 0.2), rgba(230, 241, 255, 0.45)),
    url("/miku.png") center / cover fixed no-repeat;
}

button, input { font: inherit; }

button:focus-visible,
.drop-zone:focus-visible {
  outline: 3px solid rgba(29, 143, 186, 0.35);
  outline-offset: 3px;
}

.shell {
  width: min(1160px, calc(100% - 40px));
  min-height: calc(100vh - 64px);
  margin: 32px auto;
  display: grid;
  grid-template-columns: minmax(300px, 0.78fr) minmax(440px, 1.22fr);
  border: 1px solid rgba(255, 255, 255, 0.82);
  border-radius: 28px;
  overflow: hidden;
  box-shadow: 0 28px 80px rgba(26, 61, 106, 0.25);
  backdrop-filter: blur(18px) saturate(0.9);
  -webkit-backdrop-filter: blur(18px) saturate(0.9);
}

.intro,
.desk { padding: clamp(32px, 5vw, 68px); }

.intro {
  display: flex;
  flex-direction: column;
  background: linear-gradient(155deg, rgba(19, 73, 111, 0.88), rgba(28, 77, 111, 0.68));
  color: white;
}

.brand-row { display: flex; align-items: center; gap: 12px; }

.brand-mark {
  width: 34px;
  height: 34px;
  display: grid;
  place-items: center;
  border: 1px solid rgba(255, 255, 255, 0.65);
  border-radius: 50%;
  font: 700 15px/1 Georgia, serif;
}

.brand-copy,
.eyebrow,
.route-label,
.file-type {
  font-family: "SFMono-Regular", Consolas, "Liberation Mono", monospace;
  letter-spacing: 0.13em;
}

.brand-copy { font-size: 11px; font-weight: 700; }

.intro-copy { margin: auto 0; padding: 70px 0; }

.eyebrow {
  margin: 0 0 14px;
  font-size: 11px;
  font-weight: 700;
  color: var(--cyan-dark);
}

.intro .eyebrow { color: #c8edfb; }

h1 {
  margin: 0;
  font-family: "Songti SC", "Noto Serif SC", Georgia, serif;
  font-size: clamp(38px, 5.2vw, 68px);
  font-weight: 700;
  line-height: 1.14;
  letter-spacing: -0.035em;
}

.lead {
  max-width: 33em;
  margin: 25px 0 0;
  color: rgba(255, 255, 255, 0.78);
  font-size: 14px;
  line-height: 1.85;
}

.facts { margin: 0; display: grid; gap: 14px; }

.facts div {
  display: grid;
  grid-template-columns: 80px 1fr;
  gap: 12px;
  padding-top: 13px;
  border-top: 1px solid rgba(255, 255, 255, 0.23);
}

.facts dt { color: rgba(255, 255, 255, 0.62); font-size: 12px; }
.facts dd { margin: 0; font-size: 13px; font-weight: 600; word-break: break-all; }

.desk {
  display: flex;
  flex-direction: column;
  background: var(--glass);
}

.desk-header { display: flex; align-items: flex-start; justify-content: space-between; gap: 20px; }

h2 { margin: 0; font-size: 30px; line-height: 1.2; letter-spacing: -0.04em; }

.secure-badge {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  padding: 7px 10px;
  border: 1px solid rgba(25, 123, 98, 0.24);
  border-radius: 999px;
  color: var(--success);
  background: rgba(255, 255, 255, 0.48);
  font-size: 11px;
  white-space: nowrap;
}

.secure-badge i { width: 6px; height: 6px; border-radius: 50%; background: currentColor; }

.drop-zone {
  position: relative;
  min-height: 238px;
  margin-top: 36px;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 28px;
  border: 1.5px dashed rgba(39, 91, 130, 0.38);
  border-radius: 18px;
  background: rgba(255, 255, 255, 0.5);
  cursor: pointer;
  transition: border-color 180ms ease, background-color 180ms ease, transform 180ms ease;
}

.drop-zone:hover,
.drop-zone.is-dragging { border-color: var(--cyan); background: rgba(255, 255, 255, 0.78); transform: translateY(-2px); }
.drop-zone.is-dragging { box-shadow: inset 0 0 0 2px rgba(29, 143, 186, 0.12); }

.upload-icon {
  width: 47px;
  margin-bottom: 17px;
  fill: none;
  stroke: var(--cyan-dark);
  stroke-width: 1.7;
  stroke-linecap: round;
  stroke-linejoin: round;
}

.drop-zone strong { font-size: 17px; }
.drop-zone > span:not(.choose-button) { margin-top: 7px; color: var(--muted); font-size: 12px; }

.choose-button {
  margin-top: 20px;
  padding: 9px 18px;
  border-radius: 999px;
  color: white;
  background: var(--cyan-dark);
  font-size: 12px;
  font-weight: 700;
}

.queue-wrap { margin-top: 26px; }
.queue-heading, .file-line, .file-meta { display: flex; justify-content: space-between; gap: 16px; }
.queue-heading { padding-bottom: 10px; color: var(--muted); font-size: 11px; }
.queue { max-height: 285px; margin: 0; padding: 0; overflow: auto; list-style: none; }

.queue-item {
  display: grid;
  grid-template-columns: 38px minmax(0, 1fr) auto;
  align-items: center;
  gap: 13px;
  padding: 14px 0;
  border-top: 1px solid var(--line);
}

.file-type {
  width: 38px;
  height: 38px;
  display: grid;
  place-items: center;
  border-radius: 11px;
  color: var(--cyan-dark);
  background: rgba(29, 143, 186, 0.1);
  font-size: 8px;
  font-weight: 700;
  overflow: hidden;
}

.file-main { min-width: 0; }
.file-name { min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 12px; }
.file-percent { flex: 0 0 auto; color: var(--cyan-dark); font: 700 10px/1.4 "SFMono-Regular", Consolas, monospace; }

.progress-track { height: 3px; margin: 8px 0 7px; overflow: hidden; border-radius: 99px; background: rgba(39, 91, 130, 0.12); }
.progress-track i { display: block; width: 0; height: 100%; border-radius: inherit; background: linear-gradient(90deg, var(--cyan-dark), var(--sakura)); transition: width 180ms linear; }
.file-meta { color: var(--muted); font-size: 10px; }
.file-status.is-error { color: var(--danger); }
.file-status.is-success { color: var(--success); }

.file-action {
  padding: 5px 0;
  border: 0;
  color: var(--muted);
  background: transparent;
  font-size: 11px;
  cursor: pointer;
}
.file-action:hover { color: var(--cyan-dark); }

.route { display: grid; grid-template-columns: auto 1fr 22px auto; align-items: center; gap: 10px; margin-top: auto; padding-top: 32px; }
.route-label { color: var(--muted); font-size: 9px; }
.route-line { height: 1px; overflow: hidden; background: repeating-linear-gradient(90deg, var(--line) 0 5px, transparent 5px 10px); }
.route-line i { display: block; width: 0; height: 1px; background: var(--cyan-dark); transition: width 260ms ease; }
.route svg { width: 20px; fill: none; stroke: var(--cyan-dark); stroke-width: 1.5; stroke-linecap: round; stroke-linejoin: round; }

.global-message { margin: 13px 0 0; color: var(--muted); font-size: 11px; line-height: 1.55; }

@media (max-width: 820px) {
  body { background-attachment: scroll; }
  .shell { width: min(100% - 24px, 620px); min-height: auto; margin: 12px auto; grid-template-columns: 1fr; border-radius: 22px; }
  .intro, .desk { padding: 28px; }
  .intro-copy { padding: 52px 0; }
  .desk { min-height: 580px; }
}

@media (max-width: 480px) {
  .shell { width: 100%; margin: 0; border: 0; border-radius: 0; }
  .intro, .desk { padding: 25px 20px; }
  .intro-copy { padding: 45px 0; }
  h1 { font-size: 40px; }
  .drop-zone { min-height: 210px; margin-top: 28px; }
  .queue-item { grid-template-columns: 34px minmax(0, 1fr); }
  .file-action { grid-column: 2; justify-self: end; margin-top: -8px; }
}

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after { scroll-behavior: auto !important; transition-duration: 0.01ms !important; }
}
