:root {
  font-family: Inter, ui-sans-serif, system-ui, -apple-system, BlinkMacSystemFont, "Segoe UI", sans-serif;
  color: #e8ecf3;
  background: #0d1117;
  font-synthesis: none;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  background:
    radial-gradient(circle at 20% 0%, rgba(70, 110, 255, 0.14), transparent 28rem),
    #0d1117;
}

button, input, select, textarea { font: inherit; }

.shell {
  width: min(860px, calc(100% - 32px));
  margin: 0 auto;
  padding: 56px 0;
}

.card {
  border: 1px solid #2a313c;
  border-radius: 18px;
  background: rgba(19, 24, 32, 0.96);
  padding: 28px;
  box-shadow: 0 20px 60px rgba(0, 0, 0, 0.28);
}

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

.eyebrow {
  margin: 0 0 8px;
  font-size: 12px;
  letter-spacing: 0.16em;
  color: #8ea8ff;
}

h1, h2, p { margin-top: 0; }
h1 { margin-bottom: 8px; font-size: clamp(28px, 5vw, 40px); }
h2 { margin-bottom: 0; font-size: 16px; }
.subtitle { margin-bottom: 0; color: #9ea9b8; line-height: 1.6; }

.badge {
  flex: 0 0 auto;
  border: 1px solid #3e4b62;
  border-radius: 999px;
  padding: 7px 10px;
  color: #b9c8ed;
  font-size: 12px;
}

.notice, .warning, .profile {
  border-radius: 10px;
  padding: 12px 14px;
  line-height: 1.55;
}

.notice {
  margin-bottom: 24px;
  border: 1px solid #244832;
  background: #13291c;
  color: #b8e8c5;
}

.field { margin-bottom: 18px; }
label { display: block; margin-bottom: 8px; font-weight: 650; }

input, select, textarea {
  width: 100%;
  border: 1px solid #37404d;
  border-radius: 10px;
  background: #0e141c;
  color: #f2f5f9;
  padding: 12px 13px;
  outline: none;
}

input:focus, select:focus, textarea:focus {
  border-color: #6d8eff;
  box-shadow: 0 0 0 3px rgba(109, 142, 255, 0.14);
}

textarea { resize: vertical; min-height: 82px; }
code { font-family: "Cascadia Code", "SFMono-Regular", Consolas, monospace; }

.input-row { display: flex; gap: 8px; }
.input-row input { min-width: 0; }

.grid-two {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 16px;
}

.checkbox-field { display: flex; align-items: end; }
.checkbox-label {
  display: flex;
  align-items: center;
  gap: 9px;
  min-height: 46px;
  margin: 0;
  font-weight: 500;
}
.checkbox-label input { width: auto; }

.hint { margin: 7px 0 0; color: #7f8a98; font-size: 13px; }
.archive-format-hint {
  user-select: none;
  -webkit-user-select: none;
  -moz-user-select: none;
  -ms-user-select: none;
}
.expiry-unlock-target {
  user-select: none;
  -webkit-user-select: none;
}

.expiry-unlock-target.unlock-flash {
  animation: expiry-unlock-flash 420ms ease-out;
}

@keyframes expiry-unlock-flash {
  0% { opacity: 1; }
  40% { opacity: 0.25; }
  100% { opacity: 1; }
}

.profile { margin-bottom: 16px; background: #111923; color: #aeb9c8; border: 1px solid #273340; font-size: 14px; }
.warning { margin-bottom: 16px; background: #2a2112; border: 1px solid #5c4720; color: #f0d59a; }
.hidden { display: none !important; }

.actions { display: flex; flex-wrap: wrap; gap: 10px; }
button {
  border: 1px solid transparent;
  border-radius: 10px;
  padding: 11px 15px;
  cursor: pointer;
  font-weight: 650;
}
button:disabled { cursor: not-allowed; opacity: 0.45; }
.primary { background: #6488ff; color: #081020; }
.secondary { background: #171e28; border-color: #354052; color: #d9e0ea; }
.compact { padding: 8px 11px; }

.progress-wrap {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 16px;
}
.progress-track {
  flex: 1;
  height: 8px;
  border-radius: 999px;
  overflow: hidden;
  background: #242c37;
}
.progress-bar {
  width: 0%;
  height: 100%;
  background: #6d8eff;
  transition: width 120ms linear;
}
.progress-wrap span { width: 46px; text-align: right; color: #9ba7b6; font-size: 13px; }

.result-section {
  margin-top: 28px;
  border-top: 1px solid #29313d;
  padding-top: 24px;
}
.result-heading { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 10px; }
.status { min-height: 1.4em; margin: 8px 0 0; color: #9ba7b6; font-size: 13px; }
.status.error { color: #ff9f9f; }
.status.success { color: #9ee3b2; }

.details { margin-top: 24px; color: #aab4c1; }
.details summary { cursor: pointer; color: #d7dde7; }
.details ul { line-height: 1.7; padding-left: 22px; }

@media (max-width: 640px) {
  .shell { width: min(100% - 20px, 860px); padding: 20px 0; }
  .card { padding: 18px; }
  .header { flex-direction: column; }
  .grid-two { grid-template-columns: 1fr; gap: 0; }
  .checkbox-field { align-items: flex-start; }
}
