@import url("https://fonts.googleapis.com/css2?family=IBM+Plex+Sans+JP:wght@400;600&display=swap");

:root {
  --bg: #0c0c10;
  --surface: #15171f;
  --border: #2a2f3b;
  --text: #e8e6e3;
  --muted: #9a9590;
  --accent: var(--app-accent, #7ae47a);
  --danger: #e85050;
}

* { box-sizing: border-box; }

body {
  margin: 0;
  min-height: 100vh;
  background: var(--bg);
  color: var(--text);
  font-family: "IBM Plex Sans JP", system-ui, sans-serif;
  line-height: 1.55;
}

.wrap {
  max-width: 520px;
  margin: 0 auto;
  padding: 1.25rem 1rem 2.5rem;
}

header { margin-bottom: 1.25rem; }

.badge {
  display: inline-block;
  font-size: 0.7rem;
  color: var(--muted);
  letter-spacing: 0.04em;
  margin-bottom: 0.35rem;
}

h1 {
  font-size: 1.25rem;
  font-weight: 600;
  margin: 0 0 0.25rem;
}

.lead {
  margin: 0;
  color: var(--muted);
  font-size: 0.88rem;
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 1rem;
  margin-bottom: 0.75rem;
}

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

input[type="text"],
input[type="number"],
input[type="date"],
textarea,
select {
  width: 100%;
  padding: 0.55rem 0.65rem;
  border-radius: 8px;
  border: 1px solid var(--border);
  background: var(--bg);
  color: var(--text);
  font: inherit;
}

textarea { min-height: 88px; resize: vertical; }

.row { display: flex; gap: 0.5rem; flex-wrap: wrap; }
.row > * { flex: 1; min-width: 120px; }

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 0.35rem;
  padding: 0.55rem 1rem;
  border-radius: 999px;
  border: none;
  background: var(--accent);
  color: #0a1a0a;
  font: inherit;
  font-weight: 600;
  cursor: pointer;
}

.btn.secondary {
  background: transparent;
  color: var(--text);
  border: 1px solid var(--border);
}

.btn:disabled { opacity: 0.45; cursor: not-allowed; }

.actions { display: flex; gap: 0.5rem; flex-wrap: wrap; margin-top: 0.75rem; }

.stat {
  font-size: 2rem;
  font-weight: 600;
  color: var(--accent);
  margin: 0.25rem 0;
}

.timer-display {
  font-size: 2.5rem;
  font-weight: 600;
  text-align: center;
  font-variant-numeric: tabular-nums;
  margin: 0.5rem 0;
}

.list { list-style: none; padding: 0; margin: 0; }
.list li {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.45rem 0;
  border-bottom: 1px solid var(--border);
}
.list li:last-child { border-bottom: none; }

pre.output {
  background: var(--bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  padding: 0.75rem;
  overflow: auto;
  font-size: 0.78rem;
  white-space: pre-wrap;
  word-break: break-word;
  margin: 0.5rem 0 0;
}

.toast {
  position: fixed;
  bottom: 1rem;
  left: 50%;
  transform: translateX(-50%) translateY(120%);
  background: var(--surface);
  border: 1px solid var(--accent);
  color: var(--text);
  padding: 0.6rem 1rem;
  border-radius: 999px;
  font-size: 0.85rem;
  transition: transform 0.25s;
  z-index: 99;
}
.toast.show { transform: translateX(-50%) translateY(0); }

footer {
  margin-top: 1.5rem;
  font-size: 0.75rem;
  color: var(--muted);
  text-align: center;
}

.progress-bar {
  height: 8px;
  background: var(--border);
  border-radius: 4px;
  overflow: hidden;
  margin: 0.5rem 0;
}
.progress-bar > span {
  display: block;
  height: 100%;
  background: var(--accent);
  transition: width 0.2s;
}

.mode-tag {
  display: inline-block;
  padding: 0.2rem 0.55rem;
  border-radius: 6px;
  font-size: 0.75rem;
  background: var(--bg);
  border: 1px solid var(--border);
  margin-bottom: 0.5rem;
}
