/* Feedback Board — tokens & component styles */

:root {
  --accent: #3e63dd;
  --accent-strong: #3050c4;
  --accent-soft: #eef1fd;
  --accent-line: #c9d3f6;
  --paper: #fafaf8;
  --card: #ffffff;
  --ink: #1d1d22;
  --ink-2: #57575f;
  --ink-3: #8d8d96;
  --line: #e6e6e9;
  --line-strong: #d7d7dc;
}

html { -webkit-text-size-adjust: 100%; }

body {
  margin: 0;
  background: var(--paper);
  color: var(--ink);
  font-family: ui-sans-serif, system-ui, -apple-system, "Segoe UI", Roboto, "Helvetica Neue", Arial, "Noto Sans", sans-serif;
  font-size: 14.5px;
  line-height: 1.55;
  -webkit-font-smoothing: antialiased;
  text-rendering: optimizeLegibility;
}

button { font-family: inherit; }
::selection { background: var(--accent-soft); }

.t2 { color: var(--ink-2); }
.t3 { color: var(--ink-3); }

/* ---------- header ---------- */

.logo {
  flex: none;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 38px;
  height: 38px;
  border-radius: 11px;
  background: var(--accent);
  box-shadow: 0 1px 2px rgba(48, 80, 196, 0.35);
}

.stat {
  display: inline-flex;
  align-items: center;
  gap: 7px;
  height: 30px;
  padding: 0 12px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 9px;
  font-size: 13px;
  color: var(--ink-2);
}
.stat b { font-weight: 600; color: var(--ink); font-variant-numeric: tabular-nums; }

.dot { width: 7px; height: 7px; border-radius: 50%; flex: none; }
.dot-open { background: #98a2b3; }
.dot-planned { background: #e0a114; }
.dot-done { background: #2ea563; }

/* ---------- cards ---------- */

.card {
  display: flex;
  gap: 14px;
  background: var(--card);
  border: 1px solid var(--line);
  border-radius: 14px;
  padding: 15px 16px;
  box-shadow: 0 1px 2px rgba(29, 29, 34, 0.04);
  transition: border-color 0.15s ease, box-shadow 0.2s ease;
}
@media (hover: hover) and (pointer: fine) {
  .card:hover { border-color: var(--line-strong); }
}
.card-new { border-color: var(--accent-line); box-shadow: 0 0 0 3px var(--accent-soft); }

.card-title {
  margin: 1px 0 0;
  font-size: 15px;
  font-weight: 600;
  line-height: 1.4;
  letter-spacing: -0.006em;
  overflow-wrap: break-word;
}
.card-details {
  margin: 5px 0 0;
  font-size: 14px;
  line-height: 1.6;
  color: var(--ink-2);
  white-space: pre-line;
  overflow-wrap: break-word;
}
.meta { font-size: 12px; }

/* ---------- vote pill ---------- */

.vote-pill {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 3px;
  flex: none;
  width: 46px;
  min-height: 62px;
  padding: 8px 0 6px;
  border: 1px solid var(--line);
  border-radius: 11px;
  background: var(--card);
  color: var(--ink-2);
  cursor: pointer;
  transition: border-color 0.15s ease, background-color 0.15s ease, color 0.15s ease, transform 0.12s ease;
}
.vote-pill .n { font-size: 14px; font-weight: 600; line-height: 1; font-variant-numeric: tabular-nums; }
.vote-pill:active { transform: scale(0.96); }
@media (hover: hover) and (pointer: fine) {
  .vote-pill:hover { border-color: var(--accent-line); color: var(--accent-strong); background: #fbfcff; }
}
.vote-pill.on {
  background: var(--accent);
  border-color: var(--accent);
  color: #fff;
  box-shadow: 0 1px 2px rgba(48, 80, 196, 0.3);
}

/* ---------- badges ---------- */

.badge {
  display: inline-flex;
  align-items: center;
  gap: 4px;
  height: 24px;
  padding: 0 8px;
  border-radius: 999px;
  border: 1px solid transparent;
  font-size: 11.5px;
  font-weight: 600;
  letter-spacing: 0.01em;
  white-space: nowrap;
}
.badge svg { opacity: 0.75; }
.badge-feature { background: var(--accent-soft); border-color: var(--accent-line); color: #3448ae; }
.badge-bug { background: #fdf0ed; border-color: #f5d3cb; color: #b13a24; }
.badge-other { background: #f4f4f5; border-color: #e4e4e7; color: #5b5b64; }
.badge-open { background: #eff3f9; border-color: #dbe3ee; color: #48607e; }
.badge-planned { background: #fff6e2; border-color: #f0dfae; color: #9a6207; }
.badge-done { background: #ecf9f0; border-color: #c5e9d0; color: #197d43; }

button.badge-status {
  cursor: pointer;
  padding: 0 7px 0 9px;
  transition: border-color 0.15s ease, transform 0.12s ease;
}
button.badge-status svg { opacity: 0.5; }
button.badge-status:active { transform: scale(0.96); }
@media (hover: hover) and (pointer: fine) {
  button.badge-status:hover { border-color: currentColor; }
}

/* ---------- filter chips ---------- */

.chip {
  height: 30px;
  padding: 0 13px;
  border: 1px solid var(--line);
  border-radius: 999px;
  background: var(--card);
  color: var(--ink-2);
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: border-color 0.15s ease, background-color 0.15s ease, color 0.15s ease, transform 0.12s ease;
}
.chip:active { transform: scale(0.97); }
@media (hover: hover) and (pointer: fine) {
  .chip:hover:not(.on) { border-color: var(--line-strong); color: var(--ink); }
}
.chip.on { background: var(--ink); border-color: var(--ink); color: #fff; }

/* ---------- segmented controls ---------- */

.seg {
  display: inline-flex;
  gap: 2px;
  padding: 3px;
  background: #ececee;
  border-radius: 9px;
}
.seg-btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 5px;
  border: 0;
  background: transparent;
  border-radius: 7px;
  padding: 4px 10px;
  font-size: 13px;
  font-weight: 600;
  color: var(--ink-2);
  cursor: pointer;
  transition: background-color 0.15s ease, color 0.15s ease, transform 0.12s ease;
}
.seg-btn:active { transform: scale(0.97); }
.seg-btn.on { background: var(--card); color: var(--ink); box-shadow: 0 1px 2px rgba(29, 29, 34, 0.1); }
.seg-full { display: flex; width: 100%; }
.seg-full .seg-btn { flex: 1; padding: 6px 8px; }

/* ---------- form ---------- */

.form-card { flex-direction: column; gap: 13px; }
.form-title { margin: 0; font-size: 15px; font-weight: 600; letter-spacing: -0.006em; }
.field-row { display: flex; flex-direction: column; }
.label { display: flex; align-items: baseline; gap: 6px; margin-bottom: 5px; font-size: 12.5px; font-weight: 600; }
.label .opt { font-weight: 500; color: var(--ink-3); }

.field {
  width: 100%;
  padding: 8px 10px;
  border: 1px solid var(--line);
  border-radius: 9px;
  background: #fff;
  color: var(--ink);
  font: inherit;
  font-size: 14px;
  transition: border-color 0.15s ease, box-shadow 0.15s ease;
}
.field::placeholder { color: var(--ink-3); }
.field:focus { outline: none; border-color: var(--accent); box-shadow: 0 0 0 3px var(--accent-soft); }
textarea.field { resize: vertical; min-height: 64px; line-height: 1.5; }

.counter { margin-top: 4px; text-align: right; font-size: 11px; color: var(--ink-3); font-variant-numeric: tabular-nums; }

.btn-primary {
  margin-top: 2px;
  height: 38px;
  border: 1px solid var(--accent);
  border-radius: 10px;
  background: var(--accent);
  color: #fff;
  font: inherit;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  transition: background-color 0.15s ease, transform 0.12s ease;
}
.btn-primary:hover { background: var(--accent-strong); }
.btn-primary:active { transform: scale(0.985); }
.btn-primary:disabled { opacity: 0.5; cursor: default; transform: none; }

.form-note { margin: 0; padding: 8px 11px; border-radius: 9px; font-size: 13px; }
.form-ok { background: #ecf9f0; border: 1px solid #c5e9d0; color: #197d43; }
.form-error { background: #fdf0ed; border: 1px solid #f5d3cb; color: #b13a24; }

/* ---------- focus ---------- */

:where(a, button, input, textarea, select):focus-visible { outline: 2px solid var(--accent); outline-offset: 2px; }
.field:focus-visible { outline: none; }

/* ---------- empty & error states ---------- */

.empty {
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
  padding: 44px 20px;
  background: var(--card);
  border: 1px dashed var(--line-strong);
  border-radius: 14px;
}
.empty-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 42px;
  height: 42px;
  border-radius: 50%;
  background: #f1f1f3;
  color: var(--ink-3);
  margin-bottom: 12px;
}
.empty-title { margin: 0; font-size: 14.5px; font-weight: 600; }
.empty-body { margin: 4px 0 0; font-size: 13.5px; max-width: 36ch; }
.empty .chip { margin-top: 14px; }

/* ---------- skeleton ---------- */

.skel-pill { flex: none; width: 46px; height: 62px; border-radius: 11px; background: #f1f1f3; animation: pulse 1.4s ease-in-out infinite; }
.skel-line { height: 11px; border-radius: 6px; background: #f1f1f3; animation: pulse 1.4s ease-in-out infinite; }
@keyframes pulse { 0%, 100% { opacity: 1; } 50% { opacity: 0.45; } }
.w55 { width: 55%; } .w88 { width: 88%; } .w40 { width: 40%; }

/* ---------- footer ---------- */

.foot { margin-top: 36px; display: flex; flex-direction: column; gap: 3px; font-size: 12.5px; }
.foot p { margin: 0; }

@media (prefers-reduced-motion: reduce) {
  *, *::before, *::after {
    animation-duration: 0.01ms !important;
    animation-iteration-count: 1 !important;
    transition-duration: 0.01ms !important;
    scroll-behavior: auto !important;
  }
}
