/* Roadmap page (roadmap.devscenario.com): board columns, requests with votes and replies, and the
 * sign-in / request dialogs. Uses the main site's tokens and surfaces from site.css. */
@keyframes dsIn { from { opacity: 0; transform: translateY(4px); } to { opacity: 1; transform: none; } }
.ds-in { animation: dsIn .3s ease-out both; }

/* Inputs and small controls */
.rm-input { width: 100%; padding: 10px 12px; border: 1px solid var(--h-btn-line); border-radius: 10px; background: #fff; color: var(--h-ink); font: inherit; font-size: 15px; }
.rm-input:focus { outline: 2px solid var(--h-blue); outline-offset: 1px; border-color: transparent; }
textarea.rm-input { resize: vertical; }
.rm-link { border: 0; padding: 0; background: none; color: var(--h-blue); font: inherit; cursor: pointer; }
.rm-link:hover { text-decoration: underline; }
.rm-small { min-height: 28px; padding: 0 10px; border: 1px solid var(--h-btn-line); border-radius: 999px; background: #fff; color: var(--h-nav); font-size: 12.5px; }
.rm-small:hover { border-color: var(--h-blue); color: var(--h-blue); }
.rm-small.danger { margin-left: auto; color: var(--h-bad-ink); }
.rm-small.danger:hover { border-color: var(--h-bad-ink); }
.rm-count { font: 12px var(--h-mono); color: var(--h-text-3); }
.rm-actions { display: flex; justify-content: flex-end; gap: 8px; }

/* Segmented control: the pressed button is the white one */
.seg { display: inline-flex; flex-wrap: wrap; padding: 4px; border-radius: 999px; background: var(--h-tray); border: 1px solid var(--h-tray-line); }
.seg button { min-height: 34px; padding: 0 14px; border: 0; border-radius: 999px; background: none; color: var(--h-text-2); font-size: 14px; }
.seg button[aria-pressed="true"] { background: #fff; color: var(--h-ink); font-weight: 600; box-shadow: 0 1px 3px rgba(20, 40, 100, .12); }
.seg.small button { min-height: 28px; padding: 0 10px; font-size: 12.5px; }

/* Top bar: view switch, who's signed in, request button */
.rm-board-sec .col { padding-top: 40px; }
.rm-bar { display: flex; flex-wrap: wrap; gap: 10px; align-items: center; justify-content: flex-end; }
.rm-me { display: inline-flex; align-items: center; gap: 10px; padding: 5px 12px 5px 5px; border: 1px solid var(--h-card-line); border-radius: 999px; background: #fff; font-size: 13px; }
.rm-me-text { display: flex; flex-direction: column; line-height: 1.2; }
.rm-me-text small { color: var(--h-text-3); font-size: 12px; }
.rm-avatar { flex: none; width: 30px; height: 30px; border-radius: 50%; background: var(--h-tray); color: var(--h-blue-hover); display: inline-flex; align-items: center; justify-content: center; font-size: 12px; font-weight: 700; }
.rm-avatar.team { background: var(--h-blue); color: #fff; }

/* Board */
.rm-board { display: grid; grid-template-columns: repeat(auto-fit, minmax(min(300px, 100%), 1fr)); gap: 8px; align-items: start; margin-top: 20px; }
.rm-col { background: #fff; border: 1px solid var(--h-card-line); border-radius: 12px; padding: 14px; }
.rm-col-head { display: flex; align-items: center; gap: 8px; padding: 4px 4px 12px; }
.rm-col-head h2 { margin: 0; font-size: 16px; font-weight: 600; }
.rm-col-head .rm-small { margin-left: auto; }
.rm-dot { width: 9px; height: 9px; border-radius: 50%; background: var(--h-blue-mute); }
.rm-dot.progress { background: var(--h-blue); }
.rm-dot.done { background: var(--h-ok-ink); }
/* A column scrolls inside its own height, so a long column never pushes the page down. */
.rm-cards { display: flex; flex-direction: column; gap: 6px; max-height: 460px; overflow-y: auto; overscroll-behavior: contain; margin: 0 -6px; padding: 0 6px 2px; scrollbar-width: thin; }
.rm-card { padding: 10px 12px; border: 1px solid var(--h-card-line); border-radius: 10px; background: var(--h-art); }
.rm-card h3 { margin: 0; font-size: 14px; font-weight: 600; line-height: 1.35; }
.rm-card p { margin: 3px 0 0; color: var(--h-text-2); font-size: 13px; display: -webkit-box; -webkit-line-clamp: 2; -webkit-box-orient: vertical; overflow: hidden; }
.rm-new { display: flex; flex-direction: column; gap: 8px; border-color: var(--h-blue); background: #fff; }
.rm-tags { display: flex; flex-wrap: wrap; gap: 6px; align-items: center; margin-top: 8px; }
.rm-tags .chip { font-size: 11.5px; padding: 0 8px; }
.rm-meta { margin-left: auto; font: 12px var(--h-mono); color: var(--h-text-3); }
.rm-meta.progress { color: var(--h-blue); }
.rm-meta.done { color: var(--h-ok-ink); }
.rm-moves { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 8px; padding-top: 8px; border-top: 1px solid var(--h-rule); }
.rm-moves .rm-small { min-height: 24px; padding: 0 8px; font-size: 12px; }
.rm-empty { margin: 4px; color: var(--h-text-3); font-size: 14px; }

/* Requests */
.rm-req-head .lede { margin-top: 12px; }
.rm-req-layout { display: grid; grid-template-columns: 220px minmax(0, 1fr); gap: 24px; align-items: start; margin-top: 28px; }
.rm-side { position: sticky; top: 96px; display: flex; flex-direction: column; gap: 18px; }
.rm-side-group { display: flex; flex-direction: column; gap: 2px; }
.rm-side-label { margin: 0 0 4px 10px; font: 11px var(--h-mono); text-transform: uppercase; letter-spacing: .06em; color: var(--h-text-3); }
.rm-side-item { display: flex; justify-content: space-between; align-items: center; min-height: 34px; padding: 0 10px; border: 0; border-radius: 8px; background: none; color: var(--h-text-2); font-size: 14px; text-align: left; }
.rm-side-item:hover { background: var(--h-tray); }
.rm-side-item[aria-pressed="true"] { background: var(--h-tray); color: var(--h-ink); font-weight: 600; }
.rm-list-bar { display: flex; justify-content: space-between; align-items: center; gap: 12px; margin-bottom: 10px; }
.rm-result { font-size: 13px; color: var(--h-text-3); }
.rm-reqs { display: flex; flex-direction: column; border: 1px solid var(--h-card-line); border-radius: 12px; background: #fff; overflow: hidden; }
.rm-reqs > .rm-empty { margin: 16px; }
.rm-more { align-self: center; margin: 12px; }
.rm-req { border-bottom: 1px solid var(--h-rule); }
.rm-req:last-of-type { border-bottom: 0; }
.rm-req.open { background: var(--h-art); }
.rm-req-row { display: flex; gap: 14px; padding: 12px 16px; align-items: center; }
.rm-vote { flex: none; width: 44px; min-height: 48px; border: 1px solid var(--h-btn-line); border-radius: 10px; background: #fff; color: var(--h-nav); display: flex; flex-direction: column; align-items: center; justify-content: center; line-height: 1.1; }
.rm-vote span { font-size: 10px; }
.rm-vote b { font-size: 14px; }
.rm-vote:hover { border-color: var(--h-blue); color: var(--h-blue); }
.rm-vote[aria-pressed="true"] { background: var(--h-blue); border-color: var(--h-blue); color: #fff; }
.rm-req-main { flex: 1; min-width: 0; display: flex; flex-direction: column; gap: 2px; padding: 0; border: 0; background: none; text-align: left; color: inherit; font: inherit; cursor: pointer; }
.rm-req-title { display: flex; gap: 8px; align-items: center; min-width: 0; }
.rm-req-name { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; font-size: 15px; font-weight: 600; color: var(--h-ink); }
.rm-req-main:hover .rm-req-name { color: var(--h-blue); }
.rm-req-title .rm-status { flex: none; }
.rm-req-desc { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--h-text-2); font-size: 14px; }
.rm-req.open .rm-req-desc { white-space: pre-line; }
.rm-req-meta { font-size: 12.5px; color: var(--h-text-3); }
.rm-kind { flex: none; padding: 1px 8px; border-radius: 999px; font-size: 11.5px; font-weight: 600; }
.rm-kind.bug, .rm-tags .chip.bug { background: #FDECEC; border-color: #F4C7C7; color: var(--h-bad-ink); }
.rm-kind-switch { align-self: flex-start; }
.rm-replies { flex: none; font-size: 12.5px; color: var(--h-text-3); }
.rm-status { padding: 1px 8px; border-radius: 999px; font-size: 11.5px; font-weight: 600; background: var(--h-tray); color: var(--h-blue-hover); }
.rm-status.accepted { background: #E6F5EC; color: var(--h-ok-ink); }
.rm-status.rejected { background: #F1F2F5; color: var(--h-text-3); }
.rm-moderate { display: flex; align-items: center; gap: 10px; font-size: 12px; color: var(--h-text-3); }
.rm-thread { display: flex; flex-direction: column; gap: 12px; padding: 4px 16px 16px 74px; }
.rm-comment { display: flex; gap: 10px; }
.rm-comment-head { font-size: 13px; color: var(--h-text-3); }
.rm-comment-head strong { color: var(--h-ink); }
.rm-comment p { margin: 3px 0 0; color: var(--h-text-2); font-size: 14.5px; white-space: pre-line; }
.rm-hint { margin: 0; font-size: 13px; color: var(--h-text-3); }
.rm-reply { display: flex; gap: 8px; align-items: flex-end; }

/* Dialogs */
.rm-scrim { position: fixed; inset: 0; z-index: 12; display: flex; align-items: center; justify-content: center; padding: 16px; background: rgba(11, 12, 16, .32); -webkit-backdrop-filter: blur(6px); backdrop-filter: blur(6px); }
.rm-dialog { width: 100%; max-height: 100%; overflow-y: auto; background: #fff; border: 1px solid var(--h-card-line); border-radius: 20px; box-shadow: 0 30px 80px rgba(20, 40, 100, .25); }
.rm-signin { max-width: 420px; padding: 32px 26px 24px; display: flex; flex-direction: column; align-items: center; gap: 12px; text-align: center; }
.rm-signin h2 { margin: 4px 0 0; font-size: 22px; font-weight: 600; }
.rm-signin p { margin: 0; color: var(--h-text-2); font-size: 15px; }
.rm-signin small { color: var(--h-text-3); font-size: 12px; }
.rm-google { margin-top: 8px; width: 100%; min-height: 48px; display: inline-flex; align-items: center; justify-content: center; gap: 10px; border: 1px solid #DADCE0; border-radius: 999px; background: #fff; color: #1F1F1F; font-weight: 500; }
.rm-google:hover { border-color: var(--h-blue); }
.rm-form { max-width: 560px; padding: 26px; display: flex; flex-direction: column; gap: 16px; }
.rm-form-head { display: flex; justify-content: space-between; align-items: center; }
.rm-form-head h2 { margin: 0; font-size: 22px; font-weight: 600; }
.rm-close { width: 36px; height: 36px; border: 0; border-radius: 50%; background: var(--h-tray); color: var(--h-nav); }
.rm-form label, .rm-field { display: flex; flex-direction: column; gap: 6px; font-size: 14px; color: var(--h-text-2); }
.rm-platforms { display: flex; flex-wrap: wrap; gap: 6px; }
.rm-pill { min-height: 32px; padding: 0 14px; border: 1px solid var(--h-btn-line); border-radius: 999px; background: #fff; color: var(--h-nav); font-size: 13px; }
.rm-pill[aria-pressed="true"] { background: var(--h-tray); border-color: var(--h-blue); color: var(--h-blue-hover); font-weight: 600; }
.rm-form .rm-check { flex-direction: row; align-items: center; gap: 8px; cursor: pointer; }
.rm-check input { width: 16px; height: 16px; accent-color: var(--h-blue); }
.rm-check strong { color: var(--h-ink); }
.rm-similar { display: flex; flex-direction: column; gap: 8px; margin-top: -6px; padding: 12px; border-radius: 12px; background: var(--h-tray); font-size: 13px; color: var(--h-text-2); }
.rm-similar-row { display: flex; align-items: center; gap: 10px; }
.rm-similar-title { flex: 1; min-width: 0; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; color: var(--h-ink); font-size: 14px; }
.rm-vote.small { width: 40px; min-height: 40px; border-radius: 10px; }
.rm-vote.small b { font-size: 13px; }
.rm-error { margin: 0; color: var(--h-bad-ink); font-size: 14px; }

/* Toast */
.rm-toast { position: fixed; left: 16px; right: 16px; bottom: 24px; z-index: 13; width: fit-content; margin: 0 auto; padding: 10px 18px; border-radius: 999px; font-size: 14px; box-shadow: 0 12px 30px rgba(20, 40, 100, .2); }
.rm-toast.ok { background: var(--h-ink); color: #fff; }
.rm-toast.error { background: #FDECEC; color: var(--h-bad-ink); border: 1px solid #F4C7C7; }

@media (max-width: 860px) {
    .rm-req-layout { grid-template-columns: minmax(0, 1fr); gap: 16px; }
    .rm-side { position: static; gap: 10px; }
    .rm-side-group { flex-direction: row; flex-wrap: wrap; align-items: center; gap: 6px; }
    .rm-side-label { margin: 0 4px 0 0; }
    .rm-side-item { min-height: 30px; gap: 6px; border: 1px solid var(--h-btn-line); border-radius: 999px; font-size: 13px; }
}
@media (max-width: 640px) {
    .rm-thread { padding-left: 16px; }
    .rm-cards { max-height: 360px; }
    .rm-bar { justify-content: flex-start; }
}
@media (prefers-reduced-motion: reduce) {
    .ds-in { animation: none; }
}
