/* Direction: crisp product-startup feedback board — indigo primary on a soft neutral canvas, Space Grotesk display type */

:root {
  --bg: #f6f6fa;
  --surface: #ffffff;
  --surface-2: #fafafd;
  --text: #17172b;
  --text-2: #52526b;
  --muted: #6f6f87;
  --border: #e6e6ef;
  --border-strong: #d5d5e2;
  --primary: #4f46e5;
  --primary-strong: #4338ca;
  --primary-soft: #edeafd;
  --success: #15803d;
  --success-soft: #e5f5ea;
  --warning: #b45309;
  --warning-soft: #fdf1de;
  --info: #1d4ed8;
  --info-soft: #e7eefc;
  --neutral: #52526b;
  --neutral-soft: #ececf3;
  --danger: #dc2626;
  --danger-soft: #fdecec;
  --radius-s: 8px;
  --radius-m: 12px;
  --radius-l: 16px;
  --shadow-card: 0 1px 2px rgba(23, 23, 43, 0.04), 0 12px 32px -16px rgba(23, 23, 43, 0.16);
  --font-display: "Space Grotesk", "Inter", sans-serif;
  --font-body: "Inter", system-ui, sans-serif;
}

*,
*::before,
*::after {
  box-sizing: border-box;
}

[hidden] {
  display: none !important;
}

body {
  margin: 0;
  background: var(--bg);
  color: var(--text);
  font-family: var(--font-body);
  font-size: 16px;
  line-height: 1.6;
  -webkit-font-smoothing: antialiased;
}

h1,
h2,
h3 {
  font-family: var(--font-display);
  line-height: 1.15;
  letter-spacing: -0.01em;
  margin: 0;
}

p {
  margin: 0;
}

a {
  color: var(--primary);
}

button {
  font: inherit;
  cursor: pointer;
}

svg {
  display: block;
}

.container {
  max-width: 1080px;
  margin-inline: auto;
  padding-inline: 20px;
}

:focus-visible {
  outline: 2px solid var(--primary);
  outline-offset: 2px;
  border-radius: 4px;
}

.site-header {
  position: sticky;
  top: 0;
  z-index: 50;
  background: rgba(255, 255, 255, 0.85);
  backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
}

.site-header__in {
  display: flex;
  align-items: center;
  justify-content: space-between;
  height: 64px;
}

.brand {
  display: flex;
  align-items: center;
  gap: 10px;
  text-decoration: none;
  color: var(--text);
}

.brand__icon {
  display: grid;
  place-items: center;
  width: 32px;
  height: 32px;
  border-radius: 9px;
  background: linear-gradient(135deg, #6366f1, #4f46e5);
  color: #fff;
  box-shadow: 0 4px 10px -3px rgba(79, 70, 229, 0.5);
}

.brand__name {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 19px;
}

.brand__tag {
  font-size: 11px;
  font-weight: 600;
  letter-spacing: 0.07em;
  text-transform: uppercase;
  color: var(--primary);
  background: var(--primary-soft);
  border-radius: 999px;
  padding: 3px 9px;
}

.nav-link {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: var(--text-2);
  text-decoration: none;
  font-weight: 500;
  font-size: 15px;
  padding: 8px 12px;
  border-radius: var(--radius-s);
  transition: color 0.15s ease-out, background 0.15s ease-out;
}

.nav-link:hover {
  color: var(--text);
  background: var(--neutral-soft);
}

.nav-link svg {
  width: 16px;
  height: 16px;
}

.page-head {
  padding: 56px 0 32px;
  max-width: 660px;
}

.page-head h1 {
  font-size: clamp(30px, 4.5vw, 42px);
  font-weight: 700;
}

.page-head p {
  margin-top: 12px;
  color: var(--text-2);
  font-size: 17px;
}

.page-head em {
  font-style: normal;
  color: var(--primary);
  font-weight: 600;
}

.layout {
  display: grid;
  grid-template-columns: 1fr;
  gap: 28px;
  align-items: start;
  padding-bottom: 80px;
}

@media (min-width: 940px) {
  .layout {
    grid-template-columns: 320px minmax(0, 1fr);
    gap: 36px;
  }

  .side {
    position: sticky;
    top: 88px;
  }
}

.card {
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: var(--radius-l);
  box-shadow: var(--shadow-card);
}

.side-card {
  padding: 22px;
}

.side-card + .side-card {
  margin-top: 20px;
}

.side-card--muted {
  background: var(--surface-2);
}

.side-card__title {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 17px;
  font-weight: 600;
  margin-bottom: 16px;
}

.side-card__title svg {
  width: 18px;
  height: 18px;
  color: var(--primary);
}

.form-field {
  display: block;
  font-size: 13.5px;
  font-weight: 600;
  color: var(--text-2);
  margin-bottom: 14px;
}

.form-field input,
.form-field textarea,
.comment-form input,
.comment-form textarea {
  width: 100%;
  margin-top: 6px;
  padding: 10px 12px;
  font: inherit;
  font-size: 15px;
  color: var(--text);
  background: var(--surface-2);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-s);
  transition: border-color 0.15s ease-out, box-shadow 0.15s ease-out, background 0.15s ease-out;
}

.form-field textarea {
  resize: vertical;
  min-height: 96px;
}

.form-field input:focus,
.form-field textarea:focus,
.comment-form input:focus,
.comment-form textarea:focus,
.select:focus {
  outline: none;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(79, 70, 229, 0.15);
  background: #fff;
}

input::placeholder,
textarea::placeholder {
  color: var(--muted);
}

.field-invalid {
  border-color: var(--danger) !important;
}

.form-error {
  color: var(--danger);
  font-size: 13px;
  font-weight: 500;
}

.form-error:empty {
  display: none;
}

.steps {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 12px;
  color: var(--text-2);
  font-size: 14.5px;
}

.steps li {
  display: flex;
  gap: 10px;
  align-items: flex-start;
}

.steps svg {
  width: 16px;
  height: 16px;
  color: var(--primary);
  flex: none;
  margin-top: 4px;
}

.toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}

.chips {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
}

.chip {
  border: 1px solid var(--border-strong);
  background: var(--surface);
  color: var(--text-2);
  border-radius: 999px;
  padding: 7px 14px;
  font-size: 13.5px;
  font-weight: 500;
  transition: border-color 0.15s ease-out, color 0.15s ease-out, background 0.15s ease-out;
}

.chip:hover {
  border-color: var(--primary);
  color: var(--primary);
}

.chip[aria-pressed="true"] {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}

.segmented {
  display: inline-flex;
  background: var(--neutral-soft);
  border-radius: 999px;
  padding: 3px;
}

.segmented__btn {
  border: 0;
  background: transparent;
  color: var(--text-2);
  font-size: 13.5px;
  font-weight: 600;
  padding: 7px 14px;
  border-radius: 999px;
  transition: color 0.15s ease-out;
}

.segmented__btn[aria-pressed="true"] {
  background: #fff;
  color: var(--text);
  box-shadow: 0 1px 3px rgba(23, 23, 43, 0.12);
}

.idea-list {
  display: grid;
  gap: 14px;
}

.idea {
  display: flex;
  gap: 16px;
  padding: 18px;
  transition: box-shadow 0.2s ease-out, border-color 0.2s ease-out;
}

.idea:hover {
  border-color: var(--border-strong);
  box-shadow: 0 2px 4px rgba(23, 23, 43, 0.05), 0 16px 40px -18px rgba(23, 23, 43, 0.2);
}

.vote-btn {
  flex: none;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  gap: 1px;
  width: 64px;
  min-height: 86px;
  align-self: flex-start;
  background: var(--surface);
  color: var(--text-2);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-m);
  transition: border-color 0.15s ease-out, color 0.15s ease-out, background 0.15s ease-out;
}

.vote-btn:hover:not(:disabled) {
  border-color: var(--primary);
  color: var(--primary);
  background: var(--primary-soft);
}

.vote-btn:disabled {
  opacity: 0.6;
  cursor: default;
}

.vote-btn svg {
  width: 18px;
  height: 18px;
}

.vote-btn__count {
  font-family: var(--font-display);
  font-weight: 700;
  font-size: 18px;
  line-height: 1.1;
}

.vote-btn__label {
  font-size: 10.5px;
  font-weight: 600;
  letter-spacing: 0.05em;
  text-transform: uppercase;
}

.vote-btn--voted,
.vote-btn--voted:hover:not(:disabled) {
  background: var(--primary);
  border-color: var(--primary);
  color: #fff;
}

.idea__body {
  flex: 1;
  min-width: 0;
}

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

.idea__title {
  font-size: 17.5px;
  font-weight: 600;
}

.idea__desc {
  margin-top: 6px;
  color: var(--text-2);
  font-size: 14.5px;
  overflow-wrap: anywhere;
  display: -webkit-box;
  -webkit-line-clamp: 4;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.idea__foot {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-top: 12px;
}

.comment-toggle {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  border: 0;
  background: none;
  color: var(--text-2);
  font-size: 13.5px;
  font-weight: 500;
  padding: 6px 8px;
  margin-left: -8px;
  border-radius: var(--radius-s);
  transition: color 0.15s ease-out, background 0.15s ease-out;
}

.comment-toggle:hover {
  color: var(--primary);
  background: var(--primary-soft);
}

.comment-toggle svg {
  width: 15px;
  height: 15px;
}

.comment-toggle .chev {
  transition: transform 0.2s ease-out;
}

.idea--open .comment-toggle .chev {
  transform: rotate(180deg);
}

.idea__date {
  margin-left: auto;
  color: var(--muted);
  font-size: 13px;
}

.badge {
  display: inline-flex;
  align-items: center;
  gap: 5px;
  font-size: 12px;
  font-weight: 600;
  letter-spacing: 0.02em;
  padding: 4px 10px;
  border-radius: 999px;
  white-space: nowrap;
}

.badge--review {
  background: var(--neutral-soft);
  color: var(--neutral);
}

.badge--planned {
  background: var(--info-soft);
  color: var(--info);
}

.badge--progress {
  background: var(--warning-soft);
  color: var(--warning);
}

.badge--done {
  background: var(--success-soft);
  color: var(--success);
}

.comments {
  margin-top: 14px;
  border-top: 1px solid var(--border);
  padding-top: 14px;
}

.comments__list {
  list-style: none;
  margin: 0;
  padding: 0;
  display: grid;
  gap: 10px;
}

.comment {
  background: var(--surface-2);
  border: 1px solid var(--border);
  border-radius: var(--radius-m);
  padding: 10px 14px;
}

.comment__head {
  display: flex;
  align-items: baseline;
  gap: 8px;
}

.comment__author {
  font-weight: 600;
  font-size: 13.5px;
}

.comment__date {
  color: var(--muted);
  font-size: 12px;
}

.comment__body {
  margin-top: 2px;
  font-size: 14px;
  color: var(--text-2);
  overflow-wrap: anywhere;
}

.comments__empty {
  color: var(--muted);
  font-size: 13.5px;
  padding: 2px 0 8px;
}

.comment-form {
  display: grid;
  gap: 8px;
  margin-top: 12px;
}

.comment-form input,
.comment-form textarea {
  margin-top: 0;
  background: var(--surface-2);
}

.comment-form textarea {
  resize: vertical;
  min-height: 0;
}

.comment-form__foot {
  display: flex;
  align-items: center;
  justify-content: flex-end;
  gap: 12px;
}

.comment-form__foot .form-error {
  margin-right: auto;
}

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  border: 1px solid transparent;
  border-radius: 10px;
  padding: 11px 18px;
  font-weight: 600;
  font-size: 15px;
  min-height: 44px;
  text-decoration: none;
  transition: background 0.15s ease-out, border-color 0.15s ease-out, color 0.15s ease-out, transform 0.1s ease-out;
}

.btn svg {
  width: 17px;
  height: 17px;
}

.btn--primary {
  background: var(--primary);
  color: #fff;
  box-shadow: 0 6px 16px -8px rgba(79, 70, 229, 0.6);
}

.btn--primary:hover:not(:disabled) {
  background: var(--primary-strong);
}

.btn--primary:active:not(:disabled) {
  transform: translateY(1px);
}

.btn:disabled {
  opacity: 0.55;
  cursor: default;
}

.btn--ghost {
  background: transparent;
  border-color: var(--border-strong);
  color: var(--text-2);
}

.btn--ghost:hover:not(:disabled) {
  border-color: var(--primary);
  color: var(--primary);
}

.btn--danger {
  background: var(--danger);
  color: #fff;
}

.btn--danger:hover:not(:disabled) {
  background: #b91c1c;
}

.btn--danger-ghost {
  background: transparent;
  border-color: var(--border-strong);
  color: var(--danger);
}

.btn--danger-ghost:hover:not(:disabled),
.btn--danger-ghost.armed {
  background: var(--danger);
  border-color: var(--danger);
  color: #fff;
}

.btn--sm {
  min-height: 36px;
  padding: 7px 14px;
  font-size: 13.5px;
  border-radius: 8px;
}

.btn--block {
  width: 100%;
}

.state-box {
  padding: 48px 24px;
  text-align: center;
  color: var(--text-2);
  border: 1px dashed var(--border-strong);
  border-radius: var(--radius-l);
  background: var(--surface);
  display: grid;
  gap: 12px;
  justify-items: center;
}

.state-box svg {
  width: 28px;
  height: 28px;
  color: var(--muted);
}

.state-box--error {
  border-color: var(--danger);
  color: var(--danger);
}

.toasts {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  display: grid;
  gap: 8px;
  justify-items: center;
  z-index: 100;
  pointer-events: none;
}

.toast {
  background: var(--text);
  color: #fff;
  padding: 10px 18px;
  border-radius: 999px;
  font-size: 14px;
  font-weight: 500;
  box-shadow: 0 10px 30px -10px rgba(0, 0, 0, 0.4);
  opacity: 0;
  transform: translateY(8px);
  transition: opacity 0.25s ease-out, transform 0.25s ease-out;
}

.toast--in {
  opacity: 1;
  transform: translateY(0);
}

.toast--error {
  background: var(--danger);
}

.site-footer {
  border-top: 1px solid var(--border);
  background: var(--surface);
  margin-top: 40px;
}

.site-footer__in {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
  justify-content: space-between;
  padding-block: 20px;
  color: var(--muted);
  font-size: 13.5px;
}

.site-footer a {
  color: var(--text-2);
}

.login-wrap {
  display: grid;
  place-items: center;
  padding: 64px 0;
  min-height: 60vh;
}

.login-card {
  width: min(400px, 100%);
  padding: 28px;
}

.login-card h1 {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 22px;
}

.login-card h1 svg {
  width: 22px;
  height: 22px;
  color: var(--primary);
}

.login-card > p {
  color: var(--text-2);
  font-size: 14.5px;
  margin: 6px 0 16px;
}

.login-card .btn {
  width: 100%;
  margin-top: 4px;
}

.admin-main {
  padding: 40px 0 80px;
}

.admin-head {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 18px;
}

.admin-head h1 {
  font-size: 26px;
  display: flex;
  align-items: center;
  gap: 10px;
}

.count-pill {
  font-family: var(--font-body);
  background: var(--primary-soft);
  color: var(--primary);
  border-radius: 999px;
  padding: 2px 10px;
  font-size: 14px;
}

.admin-list {
  display: grid;
  gap: 12px;
}

.admin-row {
  display: flex;
  flex-wrap: wrap;
  gap: 16px;
  padding: 16px 18px;
  align-items: flex-start;
}

.admin-row__main {
  flex: 1;
  min-width: 240px;
}

.admin-row__main h3 {
  font-size: 16.5px;
}

.admin-row__main > p {
  color: var(--text-2);
  font-size: 14px;
  margin-top: 4px;
  overflow-wrap: anywhere;
}

.admin-row__meta {
  display: flex;
  flex-wrap: wrap;
  gap: 14px;
  margin-top: 8px;
  color: var(--muted);
  font-size: 13px;
}

.admin-row__meta span {
  display: inline-flex;
  align-items: center;
  gap: 5px;
}

.admin-row__meta svg {
  width: 14px;
  height: 14px;
}

.admin-row__side {
  display: flex;
  gap: 10px;
  align-items: flex-end;
}

.select-label {
  font-size: 12.5px;
  font-weight: 600;
  color: var(--text-2);
}

.select {
  margin-top: 4px;
  min-width: 150px;
  padding: 9px 32px 9px 12px;
  font: inherit;
  font-size: 14px;
  font-weight: 500;
  color: var(--text);
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-s);
  appearance: none;
  background: #fff
    url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%2352526b' stroke-width='2.5' stroke-linecap='round' stroke-linejoin='round'%3E%3Cpath d='m6 9 6 6 6-6'/%3E%3C/svg%3E")
    no-repeat right 10px center;
  transition: border-color 0.15s ease-out, box-shadow 0.15s ease-out;
}

.select:disabled {
  opacity: 0.6;
}

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