* {
  box-sizing: border-box;
}

body {
  margin: 0;
  font-family: -apple-system, Segoe UI, Roboto, Helvetica, Arial, sans-serif;
  background: #f4f5f7;
  color: #1c1e21;
}

header {
  background: #fff;
  padding: 24px 32px;
  border-bottom: 1px solid #e4e6eb;
}

header h1 {
  margin: 0 0 4px;
  font-size: 24px;
}

.subtitle {
  margin: 0;
  color: #65676b;
}

main {
  max-width: 760px;
  margin: 24px auto;
  padding: 0 16px 48px;
  display: flex;
  flex-direction: column;
  gap: 20px;
}

.card {
  background: #fff;
  border: 1px solid #e4e6eb;
  border-radius: 10px;
  padding: 20px 24px;
}

.card h2 {
  margin-top: 0;
  font-size: 18px;
}

.hint {
  color: #65676b;
  font-size: 14px;
  margin-top: -4px;
}

.status-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 12px;
}

.status-item {
  display: flex;
  flex-direction: column;
  gap: 2px;
  background: #f7f8fa;
  border-radius: 8px;
  padding: 10px 14px;
}

.status-item .label {
  font-size: 12px;
  color: #65676b;
}

.status-item .value {
  font-size: 16px;
  font-weight: 600;
}

.form-grid {
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 14px;
}

.form-grid label {
  display: flex;
  flex-direction: column;
  font-size: 13px;
  gap: 6px;
  color: #444;
}

.form-grid input {
  padding: 8px 10px;
  border: 1px solid #ccd0d5;
  border-radius: 6px;
  font-size: 14px;
}

.form-grid button {
  grid-column: 1 / -1;
}

.form-message {
  min-height: 18px;
  font-size: 13px;
}

.form-message.error {
  color: #d32f2f;
}

.form-message.ok {
  color: #2e7d32;
}

.button-row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  margin-bottom: 12px;
}

button {
  background: #1877f2;
  color: #fff;
  border: none;
  border-radius: 6px;
  padding: 10px 16px;
  font-size: 14px;
  cursor: pointer;
}

button:disabled {
  background: #a8c7f7;
  cursor: not-allowed;
}

button.secondary {
  background: #e4e6eb;
  color: #1c1e21;
}

button.secondary:disabled {
  background: #f0f1f3;
  color: #aaa;
}

button.danger {
  background: #fa3e3e;
}

button.danger:disabled {
  background: #f7b8b8;
}

.button-link {
  display: inline-flex;
  align-items: center;
  background: #42b72a;
  color: #fff;
  text-decoration: none;
  border-radius: 6px;
  padding: 10px 16px;
  font-size: 14px;
}

.log-box {
  background: #0e0e10;
  color: #d6d6d6;
  border-radius: 8px;
  padding: 12px 14px;
  height: 180px;
  overflow-y: auto;
  font-size: 12px;
  white-space: pre-wrap;
  margin: 0;
}
