:root {
  --bg-a: #24214f;
  --bg-b: #21194e;
  --cyan: #5cc0c5;
  --lavender: #995c8c;
  --text: #f8f7ff;
  --muted: rgba(248, 247, 255, 0.72);
  --panel: rgba(255, 255, 255, 0.10);
  --panel-strong: rgba(255, 255, 255, 0.16);
  --stroke: rgba(255, 255, 255, 0.20);
  --shadow: rgba(0, 0, 0, 0.34);
}

* { box-sizing: border-box; }
html, body { min-height: 100%; }
body {
  margin: 0;
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: var(--text);
  background:
    radial-gradient(circle at 18% 12%, rgba(92, 192, 197, 0.28), transparent 32rem),
    radial-gradient(circle at 78% 28%, rgba(153, 92, 140, 0.36), transparent 34rem),
    linear-gradient(135deg, var(--bg-a), var(--bg-b));
}

.shell {
  min-height: 100vh;
  display: grid;
  place-items: center;
  padding: 24px;
}

.card {
  width: min(720px, 100%);
  padding: clamp(24px, 5vw, 48px);
  background: linear-gradient(145deg, var(--panel), rgba(255, 255, 255, 0.06));
  border: 1px solid var(--stroke);
  border-radius: 32px;
  box-shadow: 0 28px 70px var(--shadow);
  backdrop-filter: blur(22px);
}

.card.narrow { width: min(540px, 100%); }

.brand {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  font-size: 0.82rem;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: var(--cyan);
  font-weight: 800;
  margin-bottom: 18px;
}

.brand::before {
  content: "";
  width: 10px;
  height: 10px;
  border-radius: 999px;
  background: var(--cyan);
  box-shadow: 0 0 20px var(--cyan);
}

h1 {
  margin: 0;
  font-size: clamp(2.1rem, 6vw, 4rem);
  line-height: 0.96;
  letter-spacing: -0.06em;
}

.lede {
  max-width: 580px;
  margin: 18px 0 28px;
  color: var(--muted);
  font-size: 1.08rem;
  line-height: 1.5;
}

.drop-zone {
  position: relative;
  display: grid;
  place-items: center;
  min-height: 280px;
  margin-top: 26px;
  border: 2px dashed rgba(92, 192, 197, 0.55);
  border-radius: 28px;
  background: rgba(0, 0, 0, 0.14);
  transition: transform 160ms ease, border-color 160ms ease, background 160ms ease;
  cursor: pointer;
  overflow: hidden;
}

.drop-zone.dragging {
  transform: scale(1.01);
  border-color: var(--cyan);
  background: rgba(92, 192, 197, 0.12);
}

.drop-zone input {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
}

.drop-copy {
  display: grid;
  gap: 10px;
  place-items: center;
  text-align: center;
  padding: 24px;
  pointer-events: none;
}

.drop-icon {
  width: 72px;
  height: 72px;
  display: grid;
  place-items: center;
  border-radius: 24px;
  background: linear-gradient(145deg, rgba(92, 192, 197, 0.34), rgba(153, 92, 140, 0.25));
  border: 1px solid var(--stroke);
  font-size: 2.5rem;
  line-height: 1;
}

.drop-copy strong { font-size: 1.45rem; }
.drop-copy span, .drop-copy small, .muted { color: var(--muted); }

.progress-wrap { margin-top: 22px; }
.progress-label {
  display: flex;
  justify-content: space-between;
  margin-bottom: 8px;
  color: var(--muted);
  font-size: 0.95rem;
}
.progress {
  height: 12px;
  overflow: hidden;
  background: rgba(0, 0, 0, 0.22);
  border-radius: 999px;
}
.progress div {
  width: 0%;
  height: 100%;
  border-radius: inherit;
  background: linear-gradient(90deg, var(--cyan), var(--lavender));
  transition: width 120ms ease;
}

.result {
  margin-top: 24px;
  padding: 22px;
  border-radius: 24px;
  background: rgba(0, 0, 0, 0.18);
  border: 1px solid var(--stroke);
}

.result-grid {
  display: grid;
  gap: 16px;
}

.link-box {
  display: flex;
  gap: 10px;
}

.link-box input {
  flex: 1;
  min-width: 0;
  padding: 13px 14px;
  border-radius: 14px;
  border: 1px solid var(--stroke);
  color: var(--text);
  background: rgba(255, 255, 255, 0.09);
}

button, .primary-button, .secondary-button {
  appearance: none;
  border: 0;
  text-decoration: none;
  border-radius: 16px;
  padding: 14px 18px;
  font-weight: 800;
  cursor: pointer;
}

.primary-button {
  display: block;
  width: 100%;
  text-align: center;
  color: #10112b;
  background: var(--cyan);
  margin-top: 24px;
}

.secondary-button, button {
  color: var(--text);
  background: var(--panel-strong);
  border: 1px solid var(--stroke);
}

.file-card {
  display: flex;
  gap: 14px;
  align-items: center;
  margin-top: 26px;
  padding: 16px;
  border-radius: 22px;
  background: rgba(0, 0, 0, 0.18);
  border: 1px solid var(--stroke);
}

.file-icon {
  flex: 0 0 auto;
  width: 48px;
  height: 48px;
  display: grid;
  place-items: center;
  border-radius: 16px;
  background: rgba(92, 192, 197, 0.22);
  color: var(--cyan);
  font-size: 1.6rem;
  font-weight: 900;
}

.file-name {
  font-weight: 850;
  overflow-wrap: anywhere;
}

.qr-wrap {
  display: grid;
  place-items: center;
  gap: 8px;
  margin-top: 24px;
  text-align: center;
}

.qr-wrap img {
  width: 180px;
  height: 180px;
  background: white;
  padding: 10px;
  border-radius: 18px;
}

.error {
  color: #ffd5d5;
  font-weight: 750;
}

@media (max-width: 560px) {
  .shell { padding: 14px; }
  .card { border-radius: 24px; padding: 22px; }
  .drop-zone { min-height: 230px; }
  .link-box { flex-direction: column; }
}

.section-label {
  margin-bottom: 10px;
  color: var(--muted);
  font-size: 0.82rem;
  font-weight: 800;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.expiry-picker {
  margin: 22px 0 6px;
}

.expiry-grid {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 10px;
}

.expiry-option {
  position: relative;
  cursor: pointer;
}

.expiry-option input {
  position: absolute;
  opacity: 0;
  pointer-events: none;
}

.expiry-option span {
  display: grid;
  place-items: center;
  min-height: 46px;
  padding: 10px 8px;
  border-radius: 16px;
  border: 1px solid var(--stroke);
  background: rgba(0, 0, 0, 0.16);
  color: var(--muted);
  font-weight: 850;
  text-align: center;
  transition: 140ms ease;
}

.expiry-option input:checked + span {
  border-color: rgba(92, 192, 197, 0.8);
  background: rgba(92, 192, 197, 0.18);
  color: var(--text);
  box-shadow: 0 0 24px rgba(92, 192, 197, 0.18);
}

.success-heading {
  display: flex;
  align-items: flex-start;
  justify-content: space-between;
  gap: 14px;
}

.action-grid {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr));
  gap: 10px;
}

.primary-button.compact,
.secondary-button.compact,
.danger-button.compact {
  margin-top: 0;
  display: grid;
  place-items: center;
  width: 100%;
  text-align: center;
}

.danger-button {
  color: #ffd5d5;
  background: rgba(255, 70, 70, 0.13);
  border: 1px solid rgba(255, 120, 120, 0.32);
}

.danger-button:disabled {
  opacity: 0.65;
  cursor: wait;
}

.full-width {
  display: block;
  width: 100%;
  text-align: center;
  margin-top: 18px;
}

.spaced {
  margin-top: 18px;
}

.meta-grid {
  display: grid;
  grid-template-columns: repeat(2, minmax(0, 1fr));
  gap: 12px;
  margin-top: 16px;
}

.meta-tile {
  padding: 14px;
  border: 1px solid var(--stroke);
  border-radius: 18px;
  background: rgba(0, 0, 0, 0.16);
}

.meta-tile span,
.meta-tile small {
  display: block;
  color: var(--muted);
}

.meta-tile span {
  font-size: 0.72rem;
  font-weight: 850;
  letter-spacing: 0.12em;
  text-transform: uppercase;
}

.meta-tile strong {
  display: block;
  margin-top: 5px;
  font-size: 1.25rem;
  color: var(--text);
}

.meta-tile small {
  margin-top: 3px;
  font-size: 0.82rem;
}

@media (max-width: 560px) {
  .expiry-grid {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }

  .action-grid,
  .meta-grid {
    grid-template-columns: 1fr;
  }

  .link-box {
    flex-direction: column;
  }
}

.multi-file-list {
  display: grid;
  gap: 12px;
}

.multi-file-row {
  display: grid;
  gap: 12px;
  padding: 14px;
  border: 1px solid var(--stroke);
  border-radius: 18px;
  background: rgba(0, 0, 0, 0.16);
}

.multi-file-row.deleted {
  opacity: 0.62;
}

.multi-file-main {
  display: grid;
  gap: 5px;
  min-width: 0;
}

.multi-file-main strong {
  overflow-wrap: anywhere;
}

.multi-file-main span {
  color: var(--muted);
  font-size: 0.9rem;
}

.multi-share-url {
  width: 100%;
  min-width: 0;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid var(--stroke);
  color: var(--text);
  background: rgba(255, 255, 255, 0.08);
  font-size: 0.85rem;
}

.multi-actions {
  display: grid;
  grid-template-columns: repeat(4, minmax(0, 1fr));
  gap: 8px;
}

.tiny {
  display: grid;
  place-items: center;
  min-height: 38px;
  padding: 9px 10px;
  margin-top: 0;
  text-align: center;
  font-size: 0.82rem;
}

.warning-box {
  padding: 14px;
  border: 1px solid rgba(255, 214, 102, 0.35);
  border-radius: 18px;
  background: rgba(255, 214, 102, 0.08);
  color: var(--muted);
}

.warning-box strong {
  color: #fff4c2;
}

.warning-box p {
  margin: 6px 0 0;
}

@media (max-width: 560px) {
  .multi-actions {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}
