/* Voddit. The brand color is navy #232D4B; the type is Roboto. */

/* Roboto (SIL Open Font License, see fonts/Roboto-OFL.txt), served from this site. */
@font-face {
  font-family: "Roboto";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("../fonts/roboto-latin-ext.536359ff0fc9.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Roboto";
  font-style: normal;
  font-weight: 100 900;
  font-display: swap;
  src: url("../fonts/roboto-latin.b7627e3c9663.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}
/* Caveat, the handwriting on the How it works sticky note (SIL Open Font License, see fonts/Caveat-OFL.txt). */
@font-face {
  font-family: "Caveat";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("../fonts/caveat-latin-ext.f438d3567fa1.woff2") format("woff2");
  unicode-range: U+0100-02BA, U+02BD-02C5, U+02C7-02CC, U+02CE-02D7, U+02DD-02FF, U+0304, U+0308, U+0329, U+1D00-1DBF, U+1E00-1E9F, U+1EF2-1EFF, U+2020, U+20A0-20AB, U+20AD-20C4, U+2113, U+2C60-2C7F, U+A720-A7FF;
}
@font-face {
  font-family: "Caveat";
  font-style: normal;
  font-weight: 400 700;
  font-display: swap;
  src: url("../fonts/caveat-latin.1fde3bbfa795.woff2") format("woff2");
  unicode-range: U+0000-00FF, U+0131, U+0152-0153, U+02BB-02BC, U+02C6, U+02DA, U+02DC, U+0304, U+0308, U+0329, U+2000-206F, U+20AC, U+2122, U+2191, U+2193, U+2212, U+2215, U+FEFF, U+FFFD;
}

:root {
  color-scheme: light dark;
  --bg: #f4f6fa;
  --surface: #ffffff;
  --surface-2: #f0f2f7;
  --surface-3: #e4e8f0;
  --border: #e0e4ec;
  --border-strong: #c8cfdc;
  --text: #232d4b;
  --text-2: #4a5470;
  --text-3: #646c88;
  --brand: #232d4b;
  --brand-hover: #313e66;
  --brand-text: #232d4b;
  --brand-soft: #e8ebf3;
  --on-brand: #ffffff;
  --up: #232d4b;
  --up-soft: #e3e7f1;
  --down: #c94f1a;
  --down-soft: #fdeee6;
  --danger: #b8322a;
  --danger-solid: #c0352b;
  --danger-soft: #fdecea;
  --success: #1d7a46;
  --success-soft: #e6f5ec;
  --warning: #855600;
  --warning-soft: #fff4dc;
  --tile-0: #eceef4;
  --tile-0-text: #7a8199;
  --tile-1: #dde2ee;
  --tile-1-text: #232d4b;
  --tile-2: #b4bdd4;
  --tile-2-text: #1b2340;
  --tile-3: #5c6990;
  --tile-3-text: #ffffff;
  --tile-4: #232d4b;
  --tile-4-text: #ffffff;
  --radius: 14px;
  --radius-sm: 10px;
  --shadow-sm: 0 1px 2px rgb(35 45 75 / 0.06);
  --shadow: 0 1px 3px rgb(35 45 75 / 0.08), 0 12px 32px -12px rgb(35 45 75 / 0.2);
  --focus: 0 0 0 3px rgb(35 45 75 / 0.25);
  --font: "Roboto", system-ui, -apple-system, "Segoe UI", "Helvetica Neue", Arial, sans-serif;
}

@media (prefers-color-scheme: dark) {
  :root {
    --bg: #0e1322;
    --surface: #151b2e;
    --surface-2: #1b2339;
    --surface-3: #252e48;
    --border: #252e48;
    --border-strong: #36405e;
    --text: #e7ebf5;
    --text-2: #b3bbd1;
    --text-3: #8b94ad;
    --brand: #3d4f86;
    --brand-hover: #4a5d97;
    --brand-text: #a9b9ea;
    --brand-soft: #1f2947;
    --up: #a9b9ea;
    --up-soft: #222c4d;
    --down: #ff8b59;
    --down-soft: #3a2218;
    --danger: #ff8077;
    --danger-solid: #c0352b;
    --danger-soft: #3a1d1b;
    --success: #64d597;
    --success-soft: #16301f;
    --warning: #f2c264;
    --warning-soft: #33280f;
    --tile-0: #1b2339;
    --tile-0-text: #707a96;
    --tile-1: #212a47;
    --tile-1-text: #c3cdef;
    --tile-2: #2c385f;
    --tile-2-text: #dfe5fa;
    --tile-3: #3d4c80;
    --tile-3-text: #ffffff;
    --tile-4: #5468ad;
    --tile-4-text: #ffffff;
    --shadow-sm: none;
    --shadow: 0 0 0 1px rgb(255 255 255 / 0.04), 0 16px 40px -16px rgb(0 0 0 / 0.7);
    --focus: 0 0 0 3px rgb(169 185 234 / 0.4);
  }
}

/* ---------- Base ---------- */

*, *::before, *::after { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0;
  font-family: var(--font);
  font-size: 16px;
  line-height: 1.5;
  color: var(--text);
  background: var(--bg);
  -webkit-font-smoothing: antialiased;
}
a { color: var(--brand-text); text-underline-offset: 2px; }
img { max-width: 100%; }
h1, h2, h3 { line-height: 1.25; }
button, input, select, textarea { font: inherit; }
:focus-visible { outline: 2px solid var(--brand); outline-offset: 2px; }
[hidden] { display: none !important; }

.icon {
  width: 1.15em;
  height: 1.15em;
  flex: none;
  fill: none;
  stroke: currentColor;
  stroke-width: 2;
  stroke-linecap: round;
  stroke-linejoin: round;
  vertical-align: -0.2em;
}

.visually-hidden {
  position: absolute !important;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0 0 0 0);
  white-space: nowrap;
  border: 0;
}
.skip-link { position: absolute; left: 12px; top: -48px; z-index: 100; padding: 8px 14px; border-radius: 8px; background: var(--brand); color: var(--on-brand); font-weight: 600; }
.skip-link:focus { top: 12px; }
.muted { color: var(--text-3); }
.small { font-size: 13.5px; }
.hide-small { display: none; }
.dot { color: var(--border-strong); }

.container { width: 100%; max-width: 1120px; margin-inline: auto; padding-inline: 16px; }
.main { padding-block: 20px 56px; min-height: 60vh; }
.layout { display: grid; gap: 20px; }
.sidebar { display: grid; gap: 16px; align-content: start; }

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

@media (min-width: 640px) {
  .hide-small { display: inline; }
  .card { padding: 20px; }
}
@media (min-width: 960px) {
  .layout { grid-template-columns: minmax(0, 1fr) 300px; gap: 24px; align-items: start; }
  .sidebar { position: sticky; top: 84px; }
}

/* ---------- Buttons ---------- */

.btn {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 6px;
  min-height: 38px;
  padding: 0 16px;
  border: 1px solid transparent;
  border-radius: 999px;
  font-size: 14.5px;
  font-weight: 600;
  line-height: 1;
  text-decoration: none;
  white-space: nowrap;
  cursor: pointer;
  transition: background-color 0.15s, border-color 0.15s, color 0.15s;
}
.btn .icon { width: 18px; height: 18px; }
.btn-primary { background: var(--brand); color: var(--on-brand); }
.btn-primary:hover { background: var(--brand-hover); }
.btn-ghost { background: var(--surface); color: var(--text); border-color: var(--border-strong); }
.btn-ghost:hover { background: var(--surface-2); }
.btn-small { min-height: 32px; padding: 0 12px; font-size: 13.5px; }
.btn-small .icon { width: 16px; height: 16px; }
.btn-large { min-height: 46px; padding: 0 22px; font-size: 16px; }
.btn-block { width: 100%; }
.btn-danger { color: var(--danger); }
.btn-danger-solid { background: var(--danger-solid); color: #fff; }
.btn-danger-solid:hover { filter: brightness(1.08); }
.btn[aria-disabled="true"] { opacity: 0.65; cursor: progress; }

/* "Continue with Google", styled per Google's sign-in branding guidelines. */
.btn-google { border-color: #747775; background: #fff; color: #1f1f1f; font-weight: 500; }
.btn-google:hover { background: #f6f8fb; }
.icon-google { stroke: none; }
.btn .icon-google { width: 18px; height: 18px; }
.google-form { margin: 0; }
.or-divider { display: flex; align-items: center; gap: 12px; margin: 18px 0; color: var(--text-3); font-size: 13px; }
.or-divider::before, .or-divider::after { content: ""; flex: 1; height: 1px; background: var(--border); }
.connected { display: flex; align-items: center; gap: 8px; margin: 0; font-weight: 500; }
.connected .icon-google { width: 20px; height: 20px; }
@media (prefers-color-scheme: dark) {
  .btn-google { border-color: #8e918f; background: #131314; color: #e3e3e3; }
  .btn-google:hover { background: #1f1f20; }
}

/* ---------- Header ---------- */

.site-header {
  position: sticky;
  top: 0;
  z-index: 20;
  background: var(--surface);
  background: color-mix(in srgb, var(--surface) 88%, transparent);
  backdrop-filter: saturate(1.4) blur(10px);
  -webkit-backdrop-filter: saturate(1.4) blur(10px);
  border-bottom: 1px solid var(--border);
}
.header-inner { display: flex; align-items: center; gap: 8px; height: 60px; }
.brand { flex: none; color: var(--text); font-size: 22px; font-weight: 700; letter-spacing: -0.01em; line-height: 1; text-decoration: none; }
.state-jump { flex: 1 1 auto; min-width: 0; max-width: 240px; display: flex; gap: 6px; }
.state-jump select {
  min-width: 0;
  padding: 7px 32px 7px 12px;
  border-radius: 999px;
  border-color: var(--border);
  background-color: var(--surface-2);
  font-weight: 600;
}
.header-actions { margin-left: auto; display: flex; align-items: center; gap: 8px; flex: none; }
.header-actions .btn { min-height: 36px; padding: 0 12px; font-size: 14px; }
@media (max-width: 359px) {
  .state-jump { display: none; } /* No room on the smallest phones; the home page map and list cover it. */
}

.unlock-pill {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 7px 12px;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand-text);
  font-size: 13.5px;
  font-weight: 650;
  font-variant-numeric: tabular-nums;
  text-decoration: none;
  white-space: nowrap;
}
.unlock-pill .icon { width: 16px; height: 16px; }
.unlock-pill:hover { filter: brightness(0.97); }

.avatar {
  display: grid;
  place-items: center;
  width: 30px;
  height: 30px;
  border-radius: 999px;
  background: var(--brand);
  color: var(--on-brand);
  font-weight: 700;
  font-size: 14px;
  flex: none;
}
.avatar-large { width: 64px; height: 64px; font-size: 26px; }

.user-menu { position: relative; }
.user-menu summary {
  display: flex;
  align-items: center;
  gap: 8px;
  padding: 3px;
  border: 1px solid var(--border);
  border-radius: 999px;
  background: var(--surface);
  font-size: 14px;
  font-weight: 600;
  list-style: none;
  cursor: pointer;
}
.user-menu summary::-webkit-details-marker { display: none; }
.user-menu-name { display: none; max-width: 130px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.menu {
  position: absolute;
  right: 0;
  top: calc(100% + 8px);
  z-index: 30;
  display: grid;
  min-width: 210px;
  padding: 6px;
  background: var(--surface);
  border: 1px solid var(--border);
  border-radius: 12px;
  box-shadow: var(--shadow);
}
.menu a, .menu button {
  display: flex;
  align-items: center;
  justify-content: space-between;
  width: 100%;
  padding: 9px 12px;
  border: 0;
  border-radius: 8px;
  background: none;
  color: var(--text);
  font-size: 14.5px;
  text-align: left;
  text-decoration: none;
  cursor: pointer;
}
.menu a:hover, .menu button:hover { background: var(--surface-2); }
.menu form { margin: 4px 0 0; padding-top: 4px; border-top: 1px solid var(--border); }

@media (min-width: 640px) {
  .header-inner { gap: 16px; height: 64px; }
  .brand { font-size: 26px; }
  .header-actions .btn { padding: 0 14px; font-size: 14.5px; }
  .user-menu summary { padding: 3px 12px 3px 3px; }
  .user-menu-name { display: inline; }
}

/* ---------- Messages ---------- */

.flashes { display: grid; gap: 8px; margin-bottom: 16px; }
.flash, .notice {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 14px;
  border: 1px solid transparent;
  border-radius: var(--radius-sm);
  font-size: 14.5px;
  font-weight: 500;
}
.notice { display: block; margin-bottom: 16px; }
.flash-success { background: var(--success-soft); color: var(--success); }
.flash-info, .flash-debug { background: var(--brand-soft); color: var(--brand-text); }
.flash-warning, .notice-warning { background: var(--warning-soft); color: var(--warning); }
.flash-error, .notice-error { background: var(--danger-soft); color: var(--danger); }
.flash-close { padding: 0 4px; border: 0; background: none; color: inherit; font-size: 22px; line-height: 1; cursor: pointer; }

.toasts {
  position: fixed;
  left: 50%;
  bottom: 16px;
  z-index: 50;
  display: grid;
  gap: 8px;
  width: min(460px, calc(100% - 32px));
  transform: translateX(-50%);
  pointer-events: none;
}
.toast {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 12px;
  padding: 12px 16px;
  border-radius: 12px;
  background: var(--text);
  color: var(--bg);
  box-shadow: 0 12px 32px -12px rgb(0 0 0 / 0.45);
  font-size: 14.5px;
  font-weight: 500;
  pointer-events: auto;
  animation: toast-in 0.2s ease-out;
}
.toast a { color: inherit; font-weight: 700; white-space: nowrap; }
.toast-error { background: var(--danger-solid); color: #fff; }
@keyframes toast-in { from { opacity: 0; transform: translateY(8px); } }
@media (prefers-reduced-motion: reduce) { .toast { animation: none; } .tile { transition: none; } }

/* ---------- Home ---------- */

.lede { max-width: 62ch; margin: 0 0 16px; color: var(--text-2); font-size: 17px; line-height: 1.55; }

/* The welcome banner: full width, like the map card under it. */
.hero {
  margin-bottom: 24px;
  padding: 36px 20px;
  border-radius: var(--radius);
  background: var(--brand);
  color: var(--on-brand);
  text-align: center;
}
.hero h1 { margin: 0 auto 12px; font-size: clamp(30px, 5.4vw, 58px); line-height: 1.08; letter-spacing: -0.02em; }
.hero .lede { max-width: 44em; margin: 0 auto; color: rgb(255 255 255 / 0.85); font-size: clamp(16px, 1.7vw, 19px); }
.hero-actions { display: flex; flex-wrap: wrap; justify-content: center; gap: 10px; margin-top: 24px; }
.hero .btn-primary { background: #fff; color: var(--brand); }
.hero .btn-primary:hover { background: #e8ebf3; }
.hero .btn-ghost { border-color: rgb(255 255 255 / 0.55); background: transparent; color: #fff; }
.hero .btn-ghost:hover { background: rgb(255 255 255 / 0.12); }
.hero :focus-visible { outline-color: #fff; }
@media (min-width: 640px) {
  .hero { padding: 64px 40px; }
}

.map-card { margin-bottom: 24px; }
.section-head { display: flex; flex-wrap: wrap; align-items: baseline; justify-content: space-between; gap: 4px 12px; }
.section-head h2 { margin: 0; font-size: 18px; }
.section-head p { margin: 0; font-size: 14px; }

.tile-map {
  display: grid;
  grid-template-columns: repeat(11, minmax(0, 1fr));
  gap: 3px;
  max-width: 720px;
  margin: 16px auto 12px;
}
.tile {
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  aspect-ratio: 1;
  border-radius: 5px;
  background: var(--tile-0);
  color: var(--tile-0-text);
  font-weight: 750;
  line-height: 1;
  text-decoration: none;
  transition: transform 0.12s ease, box-shadow 0.12s ease;
}
.tile:hover, .tile:focus-visible { transform: translateY(-2px); box-shadow: 0 6px 14px -6px rgb(35 45 75 / 0.45); }
.tile-code { font-size: clamp(9px, 2.5vw, 15px); letter-spacing: 0.02em; }
.tile-count { display: none; margin-top: 4px; font-size: 11.5px; font-weight: 600; opacity: 0.85; }
.l1 { background: var(--tile-1); color: var(--tile-1-text); }
.l2 { background: var(--tile-2); color: var(--tile-2-text); }
.l3 { background: var(--tile-3); color: var(--tile-3-text); }
.l4 { background: var(--tile-4); color: var(--tile-4-text); }
.l0.swatch { background: var(--tile-0); }
.c0 { grid-column: 1; } .c1 { grid-column: 2; } .c2 { grid-column: 3; } .c3 { grid-column: 4; }
.c4 { grid-column: 5; } .c5 { grid-column: 6; } .c6 { grid-column: 7; } .c7 { grid-column: 8; }
.c8 { grid-column: 9; } .c9 { grid-column: 10; } .c10 { grid-column: 11; }
.r0 { grid-row: 1; } .r1 { grid-row: 2; } .r2 { grid-row: 3; } .r3 { grid-row: 4; }
.r4 { grid-row: 5; } .r5 { grid-row: 6; } .r6 { grid-row: 7; } .r7 { grid-row: 8; }
/* USA: the nationwide board, 2x2 squares in the top-left corner. */
.tile-big { grid-column-end: span 2; grid-row-end: span 2; border-radius: 9px; box-shadow: inset 0 0 0 2px var(--brand); }
.tile-big .tile-code { font-size: clamp(15px, 4.6vw, 28px); }
.tile-big.l0 { background: var(--surface); color: var(--brand-text); } /* No ideas yet: an outlined button. */
.tile-sub { display: none; margin-top: 4px; font-size: 11.5px; font-weight: 600; opacity: 0.85; }
@media (min-width: 640px) {
  .tile-map { gap: 6px; }
  .tile { border-radius: 9px; }
  .tile-count { display: block; }
  .tile-big { border-radius: 14px; }
  .tile-sub { display: block; }
}

.map-legend { display: flex; align-items: center; justify-content: center; gap: 4px; color: var(--text-3); font-size: 12.5px; }
.map-legend span:first-child { margin-right: 4px; }
.map-legend span:last-child { margin-left: 4px; }
.swatch { width: 14px; height: 14px; border-radius: 4px; }

.state-index { margin-top: 14px; border-top: 1px solid var(--border); padding-top: 12px; }
.state-index summary { cursor: pointer; font-weight: 600; font-size: 14.5px; color: var(--brand-text); }
.state-list { columns: 2 150px; column-gap: 24px; margin: 12px 0 0; padding: 0; list-style: none; font-size: 14.5px; }
.state-list li { display: flex; justify-content: space-between; gap: 8px; padding: 4px 0; break-inside: avoid; }
.state-list a { color: var(--text); text-decoration: none; }
.state-list a:hover { color: var(--brand-text); text-decoration: underline; }

/* ---------- Feeds ---------- */

.feed { min-width: 0; }
.feed-head { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 10px; margin-bottom: 12px; }
.feed-head h2 { margin: 0; font-size: 18px; }
.feed-head .sort-bar { margin: 0; }
.sort-bar { display: flex; flex-wrap: wrap; align-items: center; gap: 10px; margin-bottom: 12px; }
.sort-tabs { display: inline-flex; padding: 3px; border: 1px solid var(--border); border-radius: 999px; background: var(--surface-2); }
.tab { padding: 6px 14px; border-radius: 999px; color: var(--text-2); font-size: 14px; font-weight: 600; text-decoration: none; }
.tab:hover { color: var(--text); }
.tab.is-active { background: var(--surface); color: var(--brand-text); box-shadow: 0 1px 3px rgb(16 24 40 / 0.12); }
.period-picker select { width: auto; padding: 6px 32px 6px 12px; border-radius: 999px; font-size: 14px; }

.idea-list { display: grid; gap: 10px; margin: 0; padding: 0; list-style: none; }
.idea-card {
  display: grid;
  grid-template-columns: auto minmax(0, 1fr) auto;
  gap: 10px;
  align-items: start;
  padding: 10px 14px 12px 6px;
  border: 1px solid var(--border);
  border-radius: var(--radius);
  background: var(--surface);
  box-shadow: var(--shadow-sm);
  transition: border-color 0.15s;
}
.idea-card:hover { border-color: var(--border-strong); }
.idea-main { min-width: 0; padding-top: 4px; }
.idea-title { margin: 0 0 4px; font-size: 16.5px; font-weight: 650; line-height: 1.35; overflow-wrap: anywhere; }
.idea-title a { color: var(--text); text-decoration: none; }
.idea-title a:hover { text-decoration: underline; text-underline-offset: 3px; }
.idea-meta { display: flex; flex-wrap: wrap; align-items: center; gap: 4px 8px; margin: 0; color: var(--text-3); font-size: 13px; }
.idea-meta a { color: var(--text-2); text-decoration: none; }
.idea-meta a:hover { text-decoration: underline; }
.idea-meta .state-chip { color: var(--brand-text); }
.state-chip { display: inline-flex; padding: 2px 9px; border-radius: 999px; background: var(--brand-soft); color: var(--brand-text); font-size: 12px; font-weight: 650; }
.idea-snippet {
  display: -webkit-box;
  margin: 8px 0 0;
  overflow: hidden;
  color: var(--text-2);
  font-size: 14.5px;
  overflow-wrap: anywhere;
  -webkit-line-clamp: 3;
  line-clamp: 3;
  -webkit-box-orient: vertical;
}
.link-chip {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  max-width: 100%;
  margin-top: 8px;
  padding: 4px 10px;
  border: 1px solid var(--border);
  border-radius: 999px;
  color: var(--text-2);
  font-size: 13px;
  text-decoration: none;
}
.link-chip span { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.link-chip:hover { border-color: var(--border-strong); color: var(--text); }
.idea-thumb { position: relative; display: block; width: 72px; height: 72px; margin-top: 4px; overflow: hidden; border-radius: 10px; background: var(--surface-2); }
.idea-thumb img { display: block; width: 100%; height: 100%; object-fit: cover; }
.thumb-count { position: absolute; right: 4px; bottom: 4px; padding: 1px 6px; border-radius: 999px; background: rgb(0 0 0 / 0.65); color: #fff; font-size: 12px; font-weight: 600; }
@media (min-width: 640px) {
  .idea-card { padding: 12px 16px 14px 8px; gap: 12px; }
  .idea-thumb { width: 96px; height: 96px; }
}

.badge { display: inline-flex; align-items: center; gap: 4px; padding: 2px 8px; border-radius: 999px; background: var(--surface-3); color: var(--text-2); font-size: 11.5px; font-weight: 700; vertical-align: middle; }
.badge .icon { width: 13px; height: 13px; }
.badge-team { background: var(--brand-soft); color: var(--brand-text); }
.badge-success { padding: 6px 12px; font-size: 13px; background: var(--success-soft); color: var(--success); }
.badge-danger { background: var(--danger-soft); color: var(--danger); }

.pagination { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-top: 16px; font-size: 14px; }
.empty { padding: 36px 20px; text-align: center; }
.empty h3 { margin: 0 0 6px; font-size: 18px; }
.empty p { margin: 0 auto; max-width: 46ch; }
.empty-actions { margin-top: 16px; }

/* ---------- Votes ---------- */

.vote { display: flex; flex-direction: column; align-items: center; gap: 1px; min-width: 44px; margin: 0; }
.vote-btn {
  display: grid;
  place-items: center;
  width: 36px;
  height: 32px;
  padding: 0;
  border: 0;
  border-radius: 8px;
  background: transparent;
  color: var(--text-3);
  cursor: pointer;
  transition: background-color 0.12s, color 0.12s;
}
.vote-btn .icon { width: 21px; height: 21px; stroke-width: 1.8; }
.vote-btn:disabled { opacity: 0.35; cursor: not-allowed; }
.vote-up:hover:not(:disabled) { background: var(--up-soft); color: var(--up); }
.vote-down:hover:not(:disabled) { background: var(--down-soft); color: var(--down); }
.vote-up[aria-pressed="true"] { background: var(--up-soft); color: var(--up); }
.vote-down[aria-pressed="true"] { background: var(--down-soft); color: var(--down); }
.vote-btn[aria-pressed="true"] .icon { fill: currentColor; }
.vote-score { min-width: 2ch; font-size: 15px; font-weight: 750; font-variant-numeric: tabular-nums; text-align: center; }
.vote[data-state="up"] .vote-score { color: var(--up); }
.vote[data-state="down"] .vote-score { color: var(--down); }

/* ---------- State boards ---------- */

.breadcrumbs { display: flex; flex-wrap: wrap; gap: 8px; margin-bottom: 12px; color: var(--text-3); font-size: 13.5px; }
.breadcrumbs a { color: var(--text-2); text-decoration: none; }
.breadcrumbs a:hover { text-decoration: underline; }
.board-header { display: grid; grid-template-columns: auto minmax(0, 1fr); align-items: center; gap: 14px; margin-bottom: 20px; }
.board-badge { display: grid; place-items: center; width: 56px; height: 56px; border-radius: 16px; background: var(--brand); color: var(--on-brand); font-size: 20px; font-weight: 800; letter-spacing: 0.02em; }
.board-badge-wide { font-size: 17px; }
.board-title h1 { margin: 0; font-size: 26px; line-height: 1.15; letter-spacing: -0.01em; }
.board-title p { margin: 2px 0 0; }
.board-actions { grid-column: 1 / -1; }
@media (min-width: 640px) {
  .board-header { grid-template-columns: auto minmax(0, 1fr) auto; }
  .board-actions { grid-column: auto; }
}

.side-card h2 { margin: 0 0 6px; font-size: 16px; }
.side-card p { margin: 0 0 10px; font-size: 14.5px; }
.side-card .btn-block + .side-cta { margin-top: 10px; }
.side-cta .btn { width: 100%; }
.rules { display: grid; gap: 6px; margin: 8px 0 0; padding-left: 18px; color: var(--text-2); font-size: 14.5px; }
.steps { display: grid; gap: 12px; margin: 12px 0; padding: 0; list-style: none; counter-reset: step; }
.steps li { position: relative; min-height: 26px; padding-left: 38px; color: var(--text-2); font-size: 14.5px; line-height: 1.45; counter-increment: step; }
.steps li::before {
  content: counter(step);
  position: absolute;
  left: 0;
  top: -2px;
  display: grid;
  place-items: center;
  width: 26px;
  height: 26px;
  border-radius: 999px;
  background: var(--brand-soft);
  color: var(--brand-text);
  font-size: 13px;
  font-weight: 700;
}
.steps strong { color: var(--text); }

/* ---------- Idea page ---------- */

.idea-full { display: grid; grid-template-columns: auto minmax(0, 1fr); gap: 10px; padding: 14px 16px 16px 6px; }
.idea-full-main { min-width: 0; padding-top: 4px; }
.idea-full-title { margin: 10px 0 14px; font-size: clamp(22px, 3.4vw, 30px); line-height: 1.2; letter-spacing: -0.02em; overflow-wrap: anywhere; }
.link-card {
  display: flex;
  align-items: center;
  gap: 12px;
  margin-bottom: 16px;
  padding: 12px 14px;
  border: 1px solid var(--border);
  border-radius: var(--radius-sm);
  background: var(--surface-2);
  color: var(--text);
  text-decoration: none;
}
.link-card:hover { border-color: var(--border-strong); }
.link-card .icon { width: 22px; height: 22px; color: var(--brand-text); }
.link-card-text { display: grid; min-width: 0; }
.link-card-url { overflow: hidden; color: var(--text-3); font-size: 13px; text-overflow: ellipsis; white-space: nowrap; }
.idea-text { font-size: 16.5px; line-height: 1.65; overflow-wrap: anywhere; }
.idea-text p { margin: 0 0 1em; }
.gallery { display: grid; gap: 6px; margin: 16px 0; overflow: hidden; border-radius: var(--radius-sm); }
.gallery a { display: block; min-height: 0; background: var(--surface-2); }
.gallery img { display: block; width: 100%; height: 100%; object-fit: cover; }
.gallery-1 img { height: auto; max-height: 640px; margin: 0 auto; object-fit: contain; }
.gallery-2, .gallery-4 { grid-template-columns: 1fr 1fr; }
.gallery-2 a { aspect-ratio: 1; }
.gallery-4 a { aspect-ratio: 4 / 3; }
.gallery-3 { grid-template-columns: 2fr 1fr; grid-template-rows: 1fr 1fr; aspect-ratio: 3 / 2; }
.gallery-3 a:first-child { grid-row: 1 / 3; }
.idea-stats { margin: 12px 0 0; font-size: 14px; }
.certified { display: flex; align-items: flex-start; gap: 8px; margin: 12px 0 0; padding: 10px 12px; border-radius: var(--radius-sm); background: var(--success-soft); color: var(--success); font-size: 13px; }
.certified .icon { width: 17px; height: 17px; margin-top: 1px; }
.idea-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin-top: 14px; padding-top: 14px; border-top: 1px solid var(--border); }
.idea-actions form { margin: 0; }
.idea-actions .small { display: inline-flex; align-items: center; gap: 4px; }
.mod-tools { margin-top: 16px; padding: 12px; border: 1px dashed var(--warning); border-radius: var(--radius-sm); background: var(--warning-soft); }
.mod-title { margin: 0 0 8px; color: var(--warning); font-size: 12px; letter-spacing: 0.06em; text-transform: uppercase; }
.mod-remove { display: flex; flex-wrap: wrap; gap: 8px; margin: 0; }
.mod-remove input { flex: 1; min-width: 200px; padding: 6px 10px; font-size: 14px; }
@media (min-width: 640px) {
  .idea-full { padding: 18px 24px 22px 10px; gap: 14px; }
}

/* ---------- Forms ---------- */

input[type="text"], input[type="password"], input[type="url"], select, textarea {
  width: 100%;
  padding: 10px 12px;
  border: 1px solid var(--border-strong);
  border-radius: var(--radius-sm);
  background-color: var(--surface);
  color: var(--text);
  font-size: 16px;
}
select {
  appearance: none;
  padding-right: 34px;
  background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='8' viewBox='0 0 12 8'%3E%3Cpath d='M1 1.5 6 6.5 11 1.5' fill='none' stroke='%23878da3' stroke-width='1.8' stroke-linecap='round' stroke-linejoin='round'/%3E%3C/svg%3E");
  background-position: right 12px center;
  background-repeat: no-repeat;
  cursor: pointer;
}
textarea { min-height: 150px; line-height: 1.5; resize: vertical; }
input:focus, select:focus, textarea:focus { outline: none; border-color: var(--brand); box-shadow: var(--focus); }
[aria-invalid="true"] { border-color: var(--danger) !important; }
::placeholder { color: var(--text-3); opacity: 1; }

.form-card h1 { margin: 0 0 4px; font-size: 24px; letter-spacing: -0.01em; }
.form-card h2 { margin: 0 0 12px; font-size: 18px; }
.form-card > .muted { margin: 0 0 20px; }
.form-card.narrow { max-width: 620px; margin: 0 auto; }
.form { margin: 0; }
.field { min-width: 0; margin: 0 0 18px; padding: 0; border: 0; }
.field > label, .field > .label, .field > legend { display: block; margin-bottom: 6px; padding: 0; font-size: 14.5px; font-weight: 650; }
.optional { margin-left: 4px; color: var(--text-3); font-size: 13px; font-weight: 500; }
.help { margin: 6px 0 0; color: var(--text-3); font-size: 13px; }
.field-foot { display: flex; align-items: flex-start; justify-content: space-between; gap: 12px; }
.counter { padding-top: 6px; color: var(--text-3); font-size: 12.5px; font-variant-numeric: tabular-nums; white-space: nowrap; }
.counter.is-near { color: var(--warning); font-weight: 600; }
.errorlist { margin: 6px 0 0; padding: 0; color: var(--danger); font-size: 13.5px; font-weight: 500; list-style: none; }
.field-error { margin: 6px 0 0; color: var(--danger); font-size: 13.5px; }
.field-error:empty { display: none; }
.check { display: flex; align-items: flex-start; gap: 10px; margin: 0; font-weight: 500; cursor: pointer; }
.check input { flex: none; width: 18px; height: 18px; margin: 2px 0 0; accent-color: var(--brand); cursor: pointer; }
.check-strong { font-weight: 650; }
.radio-list { display: grid; gap: 10px; margin-top: 4px; }
.fine-print { color: var(--text-3); font-size: 12.5px; line-height: 1.5; }
.form-foot { display: flex; flex-wrap: wrap; align-items: center; justify-content: flex-end; gap: 12px; margin-top: 8px; }
.form-foot .fine-print { flex: 1 1 220px; margin: 0; }
.honeypot { position: absolute; left: -10000px; width: 1px; height: 1px; overflow: hidden; }

.attest { margin: 6px 0 18px; padding: 14px; border: 1px solid var(--border-strong); border-radius: var(--radius-sm); background: var(--surface-2); }
.attest.has-error { border-color: var(--danger); background: var(--danger-soft); }
.attest .errorlist { margin-left: 28px; }
.robot-notice { margin: 8px 0 0 28px; color: var(--text-3); font-size: 11.5px; line-height: 1.45; }

.photo-picker { position: relative; }
.photo-picker input[type="file"] { display: block; margin-top: 10px; font-size: 14px; }
.js .photo-picker input[type="file"] { position: absolute; width: 1px; height: 1px; margin: 0; opacity: 0; overflow: hidden; clip: rect(0 0 0 0); }
.dropzone {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 4px;
  padding: 22px 16px;
  border: 2px dashed var(--border-strong);
  border-radius: var(--radius);
  background: var(--surface-2);
  color: var(--text-2);
  font-weight: 500;
  text-align: center;
  cursor: pointer;
  transition: border-color 0.15s, background-color 0.15s;
}
.dropzone .icon { width: 28px; height: 28px; color: var(--brand-text); }
.dropzone .help { margin: 0; }
.dropzone:hover, .photo-picker.is-dragging .dropzone { border-color: var(--brand); background: var(--brand-soft); }
.photo-picker:has(input:focus-visible) .dropzone { border-color: var(--brand); box-shadow: var(--focus); }
.photo-previews { display: grid; grid-template-columns: repeat(4, minmax(0, 1fr)); gap: 8px; margin: 10px 0 0; padding: 0; list-style: none; }
.photo-previews:empty { display: none; }
.photo-previews li { position: relative; aspect-ratio: 1; overflow: hidden; border-radius: 10px; background: var(--surface-3); }
.photo-previews img { display: block; width: 100%; height: 100%; object-fit: cover; }
.photo-remove { position: absolute; top: 4px; right: 4px; display: grid; place-items: center; width: 28px; height: 28px; padding: 0; border: 0; border-radius: 999px; background: rgb(0 0 0 / 0.65); color: #fff; font-size: 18px; line-height: 1; cursor: pointer; }

.certify { margin: 0 0 18px; padding: 14px; border: 1px solid var(--border-strong); border-radius: var(--radius-sm); background: var(--surface-2); }
.certify .fine-print { margin: 8px 0 0 28px; }
.certify .errorlist { margin-left: 28px; }

/* ---------- Accounts ---------- */

.auth { display: grid; gap: 24px; max-width: 940px; margin: 8px auto 0; }
.auth-single { max-width: 440px; }
.auth-card h1 { margin: 0 0 4px; font-size: 26px; letter-spacing: -0.01em; }
.auth-card > .muted { margin: 0 0 20px; }
.auth-card .fine-print { margin: 12px 0 0; text-align: center; }
.auth-card .research-notice { margin: -6px 0 16px; text-align: left; }
.auth-switch { margin: 18px 0 0; color: var(--text-2); font-size: 14.5px; text-align: center; }
.auth-aside { padding: 4px; }
.auth-aside h2 { margin: 8px 0 4px; font-size: 16px; }
@media (min-width: 860px) {
  .auth:not(.auth-single) { grid-template-columns: minmax(0, 1fr) 320px; align-items: start; }
  .auth-aside { padding: 20px 8px; }
}

.profile-header { display: flex; flex-wrap: wrap; align-items: center; gap: 16px; margin-bottom: 20px; }
.profile-title { flex: 1 1 220px; min-width: 0; }
.profile-title h1 { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; margin: 0; font-size: 24px; letter-spacing: -0.01em; overflow-wrap: anywhere; }
.profile-title p { margin: 2px 0 0; }
.profile-actions { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; }
.profile-feed { max-width: 820px; }

.settings { display: grid; gap: 16px; max-width: 620px; margin: 0 auto; }
.settings > h1 { margin: 0; font-size: 26px; }
.danger-zone { border-color: var(--danger-soft); }
.danger-zone .check { margin-bottom: 12px; }

.lock-card { max-width: 620px; margin: 24px auto; padding: 36px 24px; text-align: center; }
.lock-icon { display: grid; place-items: center; width: 64px; height: 64px; margin: 0 auto 14px; border-radius: 20px; background: var(--brand-soft); color: var(--brand-text); }
.lock-icon .icon { width: 30px; height: 30px; }
.lock-card h1 { margin: 0 0 10px; font-size: clamp(22px, 3.6vw, 28px); letter-spacing: -0.02em; }
.lock-card .lede { margin-inline: auto; }
.progress-block { max-width: 360px; margin: 22px auto; }
.progress-block p { margin: 8px 0 0; font-variant-numeric: tabular-nums; }
.lock-actions { margin-bottom: 18px; }
progress { display: block; width: 100%; height: 12px; overflow: hidden; border: 0; border-radius: 999px; background: var(--surface-3); appearance: none; }
progress::-webkit-progress-bar { border-radius: 999px; background: var(--surface-3); }
progress::-webkit-progress-value { border-radius: 999px; background: var(--brand); }
progress::-moz-progress-bar { border-radius: 999px; background: var(--brand); }

/* ---------- Content pages ---------- */

.prose-page { max-width: 780px; margin: 0 auto; padding: 28px clamp(18px, 4vw, 44px) 36px; }
.prose-page h1 { margin: 0 0 8px; font-size: clamp(26px, 4vw, 34px); letter-spacing: -0.02em; }
.prose-page h2 { margin: 30px 0 8px; font-size: 19px; }
.prose-page p, .prose-page li { color: var(--text-2); font-size: 15.5px; line-height: 1.65; }
.prose-page ul { padding-left: 20px; }
.prose-page li + li { margin-top: 6px; }
.prose-page strong { color: var(--text); }

/* The sticky note at the top of How it works. */
.sticky-note {
  position: relative;
  max-width: 560px;
  margin: 10px auto 40px;
  padding: 30px 28px 24px;
  background: linear-gradient(180deg, #fff7b0, #ffef85);
  color: #232d4b;
  font-family: "Caveat", "Comic Sans MS", cursive;
  font-size: 23px;
  font-weight: 500;
  line-height: 1.3;
  transform: rotate(-1.2deg);
  box-shadow: 0 2px 3px rgb(35 45 75 / 0.1), 0 16px 26px -14px rgb(35 45 75 / 0.45);
}
.sticky-note::before {
  content: ""; /* A strip of tape holding the note on. */
  position: absolute;
  top: -13px;
  left: 50%;
  width: 120px;
  height: 28px;
  background: rgb(214 222 236 / 0.75);
  box-shadow: 0 1px 2px rgb(35 45 75 / 0.12);
  transform: translateX(-50%) rotate(-2deg);
}
.sticky-note p { margin: 0 0 12px; color: inherit; font-size: inherit; line-height: inherit; }
.sticky-note p:last-child { margin-bottom: 0; }
.sticky-note .sticky-note-title { padding-right: 64px; font-size: 31px; font-weight: 700; line-height: 1.1; }
.sticker {
  position: absolute;
  top: -18px;
  right: -14px;
  display: grid;
  place-content: center;
  width: 84px;
  height: 84px;
  border-radius: 50%;
  background: #232d4b;
  color: #fff;
  font-family: var(--font);
  font-size: 15px;
  font-weight: 800;
  line-height: 1.1;
  text-align: center;
  box-shadow: 0 0 0 3px #fff, 0 6px 14px -6px rgb(35 45 75 / 0.6);
  transform: rotate(12deg);
}
@media (max-width: 639px) {
  .sticky-note { padding: 28px 20px 20px; font-size: 21px; transform: rotate(-0.8deg); }
  .sticky-note .sticky-note-title { font-size: 27px; }
  .sticker { right: -6px; width: 70px; height: 70px; font-size: 13px; }
}
@media (prefers-color-scheme: dark) {
  .sticky-note { background: linear-gradient(180deg, #f3e796, #eadb72); }
}
.table-wrap { margin: 12px 0; overflow-x: auto; border: 1px solid var(--border); border-radius: var(--radius-sm); }
table { width: 100%; border-collapse: collapse; font-size: 14.5px; }
th, td { padding: 10px 12px; border-bottom: 1px solid var(--border); text-align: left; }
thead th { background: var(--surface-2); font-weight: 650; }
tbody tr:last-child td { border-bottom: 0; }
.highlight td { background: var(--brand-soft); color: var(--text); }

.error-card { max-width: 560px; margin: 40px auto; padding: 40px 24px; text-align: center; }
.error-code { margin: 0; color: var(--brand-text); font-size: 14px; font-weight: 750; letter-spacing: 0.12em; }
.error-card h1 { margin: 6px 0 10px; font-size: 28px; letter-spacing: -0.02em; }
.error-card .lede { margin-inline: auto; }

/* ---------- Footer ---------- */

.site-footer { padding: 24px 0 32px; border-top: 1px solid var(--border); background: var(--surface); }
.footer-inner { display: grid; gap: 8px; }
.footer-brand { margin: 0; color: var(--text-2); font-size: 14px; }
.footer-links { display: flex; flex-wrap: wrap; gap: 8px 18px; }
.footer-links a { color: var(--text-2); font-size: 14px; text-decoration: none; }
.footer-links a:hover { color: var(--brand-text); text-decoration: underline; }
.footer-note { margin: 0; color: var(--text-3); font-size: 12.5px; }
