:root {
  color-scheme: light dark;
  --bg: #0f1420;
  --panel: #171e2e;
  --border: #2a3348;
  --text: #e6e9ef;
  --muted: #9aa4b8;
  --accent: #5b8def;
  --accent-text: #0b1020;
  --danger: #e5484d;
  --success: #3dd68c;
  --radius: 10px;
}

@media (prefers-color-scheme: light) {
  :root {
    --bg: #f5f6f9;
    --panel: #ffffff;
    --border: #dde1ea;
    --text: #1a1f2b;
    --muted: #5b6478;
    --accent: #006c85;
    --accent-text: #ffffff;
  }
}

* {
  box-sizing: border-box;
}

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, sans-serif;
  display: flex;
  justify-content: center;
  padding: 2.5rem 1rem;
}

.container {
  width: 100%;
  max-width: 560px;
}
.logo{text-align:center;border-bottom: 1px solid #ddd;}
h1 {
  font-size: 1.4rem;
  margin-bottom: 0.25rem;
}

.subtitle {
  color: var(--muted);
  margin-top: 0;
  margin-bottom: 1.5rem;
  font-size: 0.95rem;
}

.panel {
  background: var(--panel);
  border: 1px solid var(--border);
  border-radius: var(--radius);
  padding: 1.5rem;
  margin-bottom: 1rem;
}

.info-toggle {
  padding: 1rem 1.5rem;
}

.info-toggle summary {
  cursor: pointer;
  font-weight: 600;
  font-size: 0.95rem;
  list-style: none;
}

.info-toggle summary::-webkit-details-marker {
  display: none;
}

.info-toggle summary::before {
  content: "▸";
  display: inline-block;
  width: 1em;
  margin-right: 0.4rem;
  transition: transform 0.15s ease;
}

.info-toggle[open] summary::before {
  transform: rotate(90deg);
}

.info-content {
  margin-top: 1rem;
  font-size: 0.9rem;
  color: var(--muted);
}

.info-content p {
  margin: 0 0 0.75rem 0;
}

.info-content p:last-child {
  margin-bottom: 0;
}

.info-content strong {
  color: var(--text);
}

.mode-switch {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 1.25rem;
}

.mode-switch button {
  flex: 1;
  padding: 0.7rem;
  border-radius: var(--radius);
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text);
  cursor: pointer;
  font-size: 0.95rem;
}

.mode-switch button.active {
  background: var(--accent);
  color: var(--accent-text);
  border-color: var(--accent);
}

label {
  display: block;
  margin-bottom: 0.4rem;
  font-size: 0.9rem;
  color: var(--muted);
}

input[type="text"],
input[type="password"],
select {
  width: 100%;
  padding: 0.65rem 0.75rem;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text);
  font-size: 1rem;
  margin-bottom: 1rem;
}

.row {
  display: flex;
  gap: 0.75rem;
}

.row > div {
  flex: 1;
}

.checkbox-row {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  margin-bottom: 1rem;
}

.checkbox-row input {
  width: auto;
  margin: 0;
}

.checkbox-row label {
  margin: 0;
  color: var(--text);
}

button.primary {
  width: 100%;
  padding: 0.8rem;
  border-radius: 8px;
  border: none;
  background: var(--accent);
  color: var(--accent-text);
  font-size: 1rem;
  font-weight: 600;
  cursor: pointer;
}

button.primary:disabled {
  opacity: 0.6;
  cursor: not-allowed;
}

button.secondary {
  width: 100%;
  padding: 0.6rem;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text);
  cursor: pointer;
  margin-top: 0.5rem;
}

.error-box {
  background: color-mix(in srgb, var(--danger) 15%, transparent);
  border: 1px solid var(--danger);
  color: var(--danger);
  padding: 0.75rem 1rem;
  border-radius: 8px;
  margin-bottom: 1rem;
  font-size: 0.9rem;
}

.hint {
  font-size: 0.8rem;
  color: var(--muted);
  margin-top: -0.6rem;
  margin-bottom: 1rem;
}

.result-box {
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 1rem;
  margin-bottom: 1rem;
}

.result-box .link-row {
  display: flex;
  gap: 0.5rem;
  margin-bottom: 0.5rem;
}

.result-box input[type="text"] {
  margin-bottom: 0;
  font-family: monospace;
  font-size: 0.85rem;
}

.result-box .link-row button {
  flex-shrink: 0;
  padding: 0.6rem 0.9rem;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: transparent;
  color: var(--text);
  cursor: pointer;
}

.secret-display {
  font-family: monospace;
  font-size: 1.1rem;
  padding: 1rem;
  background: color-mix(in srgb, var(--success) 12%, transparent);
  border: 1px solid var(--success);
  border-radius: 8px;
  word-break: break-all;
  margin-bottom: 1rem;
}

.meta-note {
  font-size: 0.85rem;
  color: var(--muted);
}

.hint-lead {
  margin-top: 0;
}

.result-title {
  margin-top: 0;
  font-size: 1.1rem;
}

.mailto-link {
  font-size: 0.85rem;
  color: var(--accent);
}

[hidden] {
  display: none !important;
}
