:root {
  color-scheme: light;
  --bg: #f6f8fb;
  --card: #ffffff;
  --text: #1f2937;
  --muted: #6b7280;
  --accent: #0b5cff;
  --accent-hover: #0047d4;
  --border: #e5e7eb;
}

body {
  margin: 0;
  font-family: -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
  background: radial-gradient(circle at top right, #e9f0ff, var(--bg));
  color: var(--text);
}

.wrap {
  max-width: 900px;
  margin: 40px auto;
  padding: 0 20px;
}

.card {
  background: var(--card);
  border: 1px solid var(--border);
  border-radius: 12px;
  padding: 24px;
  box-shadow: 0 8px 24px rgba(15, 23, 42, 0.06);
  margin-bottom: 18px;
}

h1 {
  margin: 0 0 8px;
  font-size: 30px;
}

h2 {
  margin: 0 0 10px;
  font-size: 20px;
}

p,
li {
  color: var(--muted);
  line-height: 1.55;
}

code {
  background: #eef2ff;
  padding: 2px 6px;
  border-radius: 6px;
  word-break: break-all;
}

.btn {
  display: inline-block;
  text-decoration: none;
  background: var(--accent);
  color: #fff;
  padding: 10px 16px;
  border-radius: 8px;
  font-weight: 600;
}

.btn:hover {
  background: var(--accent-hover);
}

.btn-secondary {
  background: #111827;
}

.btn-secondary:hover {
  background: #0f172a;
}

.mono-block {
  background: #111827;
  color: #f9fafb;
  border-radius: 8px;
  padding: 12px;
  overflow: auto;
  font-size: 13px;
}

.row {
  display: flex;
  gap: 10px;
  flex-wrap: wrap;
  align-items: center;
}

.small-link {
  color: var(--accent);
  text-decoration: none;
  font-weight: 600;
}

.meta-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
  gap: 10px;
  margin-top: 12px;
}

.meta-item {
  border: 1px solid var(--border);
  border-radius: 10px;
  padding: 10px;
  background: #f9fbff;
}

.meta-label {
  display: block;
  font-size: 12px;
  color: var(--muted);
  margin-bottom: 4px;
}

.meta-value {
  font-weight: 700;
  color: var(--text);
}

.error {
  color: #b91c1c;
  font-weight: 600;
}

.quality-banner {
  margin-top: 12px;
  padding: 10px 12px;
  border-radius: 10px;
  border: 1px solid var(--border);
  background: #f8fafc;
  display: inline-flex;
  gap: 8px;
  align-items: center;
  font-weight: 600;
}

.quality-dot {
  width: 10px;
  height: 10px;
  border-radius: 999px;
  display: inline-block;
}

.quality-good {
  color: #166534;
  background: #ecfdf3;
  border-color: #86efac;
}

.quality-good .quality-dot {
  background: #16a34a;
}

.quality-warn {
  color: #92400e;
  background: #fff7ed;
  border-color: #fdba74;
}

.quality-warn .quality-dot {
  background: #ea580c;
}

.quality-bad {
  color: #991b1b;
  background: #fef2f2;
  border-color: #fca5a5;
}

.quality-bad .quality-dot {
  background: #dc2626;
}

.motivation-shell {
  margin: 14px 0 16px;
  padding: 14px 16px;
  border-radius: 12px;
  border: 1px solid #bfdbfe;
  background: linear-gradient(135deg, #eff6ff 0%, #f8fbff 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.7);
}

.motivation-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 6px;
}

.motivation-kicker {
  display: inline-block;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  font-weight: 700;
  color: #1d4ed8;
  margin-bottom: 0;
}

.motivation-icon {
  width: 30px;
  height: 30px;
  border-radius: 999px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  border: 1px solid currentColor;
  color: #1d4ed8;
  background: rgba(255, 255, 255, 0.7);
  box-shadow: 0 4px 10px rgba(29, 78, 216, 0.12);
  font-size: 14px;
  font-weight: 700;
}

.motivation-icon::before {
  content: "\223C";
}

.motivation-message {
  margin: 0;
  padding: 0;
  border: 0;
  background: transparent;
  color: #1e3a8a;
  line-height: 1.5;
  font-weight: 600;
}

.motivation-paragraph {
  margin: 0;
}

.motivation-paragraph + .motivation-paragraph {
  margin-top: 10px;
}

.motivation-shell.sentiment-positive {
  border-color: #86efac;
  background: linear-gradient(135deg, #ecfdf3 0%, #f6fff8 100%);
}

.motivation-shell.sentiment-positive .motivation-kicker {
  color: #166534;
}

.motivation-shell.sentiment-positive .motivation-message {
  color: #14532d;
}

.motivation-shell.sentiment-positive .motivation-icon {
  color: #166534;
  box-shadow: 0 4px 10px rgba(22, 101, 52, 0.15);
}

.motivation-shell.sentiment-positive .motivation-icon::before {
  content: "\25B2";
}

.motivation-shell.sentiment-neutral {
  border-color: #bfdbfe;
  background: linear-gradient(135deg, #eff6ff 0%, #f8fbff 100%);
}

.motivation-shell.sentiment-neutral .motivation-kicker {
  color: #1d4ed8;
}

.motivation-shell.sentiment-neutral .motivation-message {
  color: #1e3a8a;
}

.motivation-shell.sentiment-neutral .motivation-icon {
  color: #1d4ed8;
  box-shadow: 0 4px 10px rgba(29, 78, 216, 0.12);
}

.motivation-shell.sentiment-neutral .motivation-icon::before {
  content: "\223C";
}

.motivation-shell.sentiment-cautious {
  border-color: #fdba74;
  background: linear-gradient(135deg, #fff7ed 0%, #fffaf4 100%);
}

.motivation-shell.sentiment-cautious .motivation-kicker {
  color: #c2410c;
}

.motivation-shell.sentiment-cautious .motivation-message {
  color: #9a3412;
}

.motivation-shell.sentiment-cautious .motivation-icon {
  color: #c2410c;
  box-shadow: 0 4px 10px rgba(194, 65, 12, 0.14);
}

.motivation-shell.sentiment-cautious .motivation-icon::before {
  content: "!";
}
