/* TycoonTube — white, quiet, business-like. One accent (emerald), gold only for
   the Helpful Solution. Desktop: sidebar / feed / rail. Phone: one column with a
   bottom bar; dialogs become full-screen sheets. */

:root {
  --bg: #f6f7f9;
  --card: #ffffff;
  --ink: #111827;
  --ink-2: #374151;
  --muted: #6b7280;
  --line: #e5e7eb;
  --line-2: #d1d5db;
  --accent: #0f766e;
  --accent-ink: #ffffff;
  --accent-soft: #e6f4f2;
  --gold: #a16207;
  --gold-soft: #fef6e0;
  --danger: #b91c1c;
  --focus: #2563eb;
  --radius: 12px;
  --shadow: 0 1px 2px rgba(17, 24, 39, 0.05);
  color-scheme: light;
}

* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--ink);
  font: 15px/1.55 Inter, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
}
body.has-modal { overflow: hidden; }
a { color: var(--accent); text-decoration: none; }
a:hover { text-decoration: underline; }
button, input, select, textarea { font: inherit; color: inherit; }
img { max-width: 100%; }
[hidden] { display: none !important; }
:focus-visible { outline: 3px solid var(--focus); outline-offset: 2px; border-radius: 6px; }
.sr { position: absolute; width: 1px; height: 1px; overflow: hidden; clip: rect(0 0 0 0); white-space: nowrap; }
.skip { position: absolute; left: -999px; top: 8px; background: #fff; padding: 8px 12px; border-radius: 8px; z-index: 100; }
.skip:focus { left: 8px; }
.muted { color: var(--muted); }
.warn { color: var(--danger); }
.center { text-align: center; }
.lede { margin-top: -6px; }

/* ---- logo ---- */
.logo { font-weight: 800; letter-spacing: 0.06em; font-size: 18px; color: var(--ink); white-space: nowrap; }
.logo b { color: var(--accent); font-weight: 800; }
.logo:hover { text-decoration: none; }
.logo--lg { font-size: 22px; }
.boot { min-height: 100vh; display: grid; place-items: center; opacity: 0.6; }

/* ---- buttons ---- */
.btn {
  display: inline-flex; align-items: center; justify-content: center; gap: 6px;
  border: 1px solid var(--line-2); background: #fff; color: var(--ink); border-radius: 10px;
  padding: 8px 14px; font-weight: 600; cursor: pointer; line-height: 1.2; text-decoration: none; min-height: 38px;
}
.btn:hover { background: #f9fafb; text-decoration: none; }
.btn:disabled { opacity: 0.55; cursor: not-allowed; }
.btn--primary { background: var(--accent); border-color: var(--accent); color: var(--accent-ink); }
.btn--primary:hover { background: #0d6961; }
.btn--danger { background: var(--danger); border-color: var(--danger); color: #fff; }
.btn--danger:hover { background: #991b1b; }
.btn--ghost { border-color: transparent; background: transparent; }
.btn--sm { padding: 5px 10px; min-height: 32px; font-size: 14px; }
.btn--lg { padding: 12px 20px; font-size: 16px; min-height: 48px; }
.btn--block { width: 100%; margin-top: 8px; }
.icon-btn { border: 0; background: transparent; border-radius: 8px; width: 34px; height: 34px; cursor: pointer; color: var(--muted); font-size: 18px; line-height: 1; }
.icon-btn:hover { background: #f3f4f6; color: var(--ink); }
.icon-btn:disabled { opacity: 0.35; cursor: default; }
.linkbtn { border: 0; background: none; padding: 0; color: var(--muted); font-weight: 600; font-size: 13px; cursor: pointer; }
.linkbtn:hover { color: var(--accent); text-decoration: underline; }
.linkbtn--gold { color: var(--gold); }

/* ---- header ---- */
.top { position: sticky; top: 0; z-index: 30; background: rgba(255, 255, 255, 0.96); backdrop-filter: blur(6px); border-bottom: 1px solid var(--line); }
.top__in { max-width: 1240px; margin: 0 auto; height: 60px; display: flex; align-items: center; gap: 16px; padding: 0 16px; }
.search { position: relative; flex: 1; max-width: 420px; margin-left: 24px; }
.search input { width: 100%; border: 1px solid var(--line); background: #f3f4f6; border-radius: 999px; padding: 8px 14px; }
.search input:focus { background: #fff; border-color: var(--line-2); }
.search__results { position: absolute; top: 44px; left: 0; right: 0; background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 8px 24px rgba(0, 0, 0, 0.08); padding: 6px; }
.search__row { display: flex; align-items: center; gap: 10px; padding: 8px; border-radius: 8px; color: var(--ink); font-weight: 600; }
.search__row:hover, .search__row:focus { background: #f3f4f6; text-decoration: none; }
.search__none { margin: 8px; color: var(--muted); }
.bell { position: relative; margin-left: auto; color: var(--ink-2); width: 40px; height: 40px; display: grid; place-items: center; border-radius: 10px; }
.bell:hover { background: #f3f4f6; }
.bell__count { position: absolute; top: 3px; right: 2px; background: var(--danger); color: #fff; border-radius: 999px; font-size: 11px; font-weight: 700; min-width: 18px; height: 18px; display: grid; place-items: center; padding: 0 4px; }
.me { position: relative; }
.me__btn { border: 0; background: none; padding: 2px; border-radius: 50%; cursor: pointer; display: flex; }
.menu { position: absolute; right: 0; top: 46px; background: #fff; border: 1px solid var(--line); border-radius: 12px; box-shadow: 0 10px 30px rgba(0, 0, 0, 0.1); padding: 6px; min-width: 190px; z-index: 40; }
.menu a, .menu button { display: block; width: 100%; text-align: left; padding: 9px 12px; border: 0; background: none; border-radius: 8px; color: var(--ink); cursor: pointer; font-weight: 500; }
.menu a:hover, .menu button:hover, .menu a:focus, .menu button:focus { background: #f3f4f6; text-decoration: none; }
.menu .danger { color: var(--danger); }
.menu--right { top: 36px; }

/* ---- layout ---- */
.layout { max-width: 1240px; margin: 0 auto; display: grid; grid-template-columns: 220px minmax(0, 640px) 300px; gap: 24px; padding: 20px 16px 60px; justify-content: center; }
.side { position: sticky; top: 80px; align-self: start; display: flex; flex-direction: column; gap: 2px; }
.side a { display: flex; align-items: center; gap: 10px; padding: 9px 12px; border-radius: 10px; color: var(--ink-2); font-weight: 600; }
.side a span[aria-hidden] { width: 18px; text-align: center; color: var(--muted); }
.side a:hover { background: #eef0f3; text-decoration: none; }
.side a[aria-current="page"] { background: var(--accent-soft); color: var(--accent); }
.side a[aria-current="page"] span[aria-hidden] { color: var(--accent); }
.side__ext { font-weight: 500 !important; color: var(--muted) !important; }
.side__post { margin-top: 12px; }
.pill { margin-left: auto; background: var(--danger); color: #fff; font-size: 11px; font-weight: 700; border-radius: 999px; padding: 1px 7px; }
#main { min-width: 0; outline: none; }
.rail { position: sticky; top: 80px; align-self: start; display: flex; flex-direction: column; gap: 14px; max-height: calc(100vh - 100px); overflow: auto; padding-bottom: 8px; }
.bottomnav { display: none; }

/* ---- cards & lists ---- */
.card { background: var(--card); border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow); padding: 16px; }
.list > .card, .stack > * + *, #main > .card + .card, #main > .card + .filters { margin-top: 12px; }
.list__more { margin-top: 12px; }
.page-title { font-size: 24px; line-height: 1.25; margin: 0 0 12px; letter-spacing: -0.01em; }
.page-head { display: flex; align-items: center; justify-content: space-between; gap: 12px; margin-bottom: 4px; }
.page-head .page-title { margin: 0; }
.section-title { font-size: 16px; margin: 20px 0 10px; }
.section-head { display: flex; align-items: baseline; justify-content: space-between; gap: 8px; }
.section-head h2 { font-size: 17px; margin: 0 0 8px; }
.back { display: inline-block; margin-bottom: 10px; font-weight: 600; color: var(--muted); }
.grid { display: grid; grid-template-columns: 1fr; gap: 12px; margin-top: 12px; }
.group + .group { margin-top: 8px; }

/* ---- avatar ---- */
.avatar { width: 40px; height: 40px; flex: none; display: inline-grid; place-items: center; border-radius: 50%; background: #e5e7eb; color: var(--ink-2); font-weight: 700; overflow: hidden; }
.avatar img { width: 100%; height: 100%; object-fit: cover; }
.avatar--ghost { background: #f3f4f6; }
.name { font-weight: 700; color: var(--ink); }

/* ---- badges & chips ---- */
.badge { display: inline-block; font-size: 12px; font-weight: 700; padding: 2px 8px; border-radius: 999px; background: #f3f4f6; color: var(--ink-2); white-space: nowrap; }
.badge--progress { background: #e0f2fe; color: #075985; }
.badge--advice { background: #fef3c7; color: #92400e; }
.badge--idea { background: #ede9fe; color: #5b21b6; }
.badge--help { background: #fee2e2; color: #991b1b; }
.badge--milestone { background: #dcfce7; color: #166534; }
.badge--goal_update { background: var(--accent-soft); color: var(--accent); }
.badge--stage { background: #eef2ff; color: #3730a3; }
.badge--status-completed { background: #dcfce7; color: #166534; }
.badge--status-in_progress { background: #e0f2fe; color: #075985; }
.badge--status-paused { background: #fef3c7; color: #92400e; }
.badge--status-cancelled { background: #f3f4f6; color: var(--muted); }
.chips { display: flex; flex-wrap: wrap; gap: 6px; margin-top: 10px; }
.chip { display: inline-flex; align-items: center; gap: 2px; font-size: 13px; padding: 3px 10px; border-radius: 999px; border: 1px solid var(--line); color: var(--ink-2); background: #fff; }
.chip--link { color: var(--accent); border-color: #c7e5e1; background: var(--accent-soft); }
.chip--solved { border-color: #f1d79a; background: var(--gold-soft); color: var(--gold); font-weight: 700; }
.chip--flag { border-color: #c7e5e1; color: var(--accent); font-weight: 600; }

/* ---- composer & filters ---- */
.composer { display: grid; grid-template-columns: 40px 1fr; gap: 10px 12px; align-items: center; }
.composer__prompt { text-align: left; border: 1px solid var(--line); background: #f9fafb; border-radius: 999px; padding: 10px 16px; color: var(--muted); cursor: pointer; }
.composer__prompt:hover { background: #f3f4f6; }
.composer__quick { grid-column: 2; display: flex; flex-wrap: wrap; gap: 6px; }
.filters { display: flex; gap: 6px; overflow-x: auto; padding: 14px 0 4px; scrollbar-width: none; }
.filters::-webkit-scrollbar { display: none; }
.filter { flex: none; border: 1px solid var(--line); background: #fff; border-radius: 999px; padding: 6px 13px; font-weight: 600; font-size: 14px; color: var(--ink-2); cursor: pointer; }
.filter:hover { border-color: var(--line-2); }
.filter[aria-selected="true"] { background: var(--ink); border-color: var(--ink); color: #fff; }
.newpill { display: block; margin: 10px auto 0; border: 0; background: var(--accent); color: #fff; font-weight: 700; padding: 7px 16px; border-radius: 999px; cursor: pointer; box-shadow: 0 4px 12px rgba(15, 118, 110, 0.3); }

/* ---- post ---- */
.post__head { display: flex; gap: 10px; align-items: flex-start; }
.post__who { flex: 1; min-width: 0; }
.post__meta { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 13px; color: var(--muted); }
.post__title { font-size: 17px; line-height: 1.35; margin: 10px 0 4px; word-break: break-word; }
.post__title a { color: var(--ink); }
.post__title--lg { font-size: 22px; }
.post__body, .text, .comment__body, .solution__body, .phead__desc, .prof__bio { white-space: pre-wrap; word-break: break-word; overflow-wrap: anywhere; color: var(--ink-2); }
.post__more { font-weight: 600; font-size: 14px; }
.post__acts { display: flex; gap: 4px; margin-top: 12px; padding-top: 8px; border-top: 1px solid var(--line); }
.act { flex: 1; border: 0; background: none; border-radius: 8px; padding: 7px 4px; color: var(--muted); font-weight: 600; cursor: pointer; font-size: 14px; }
.act:hover { background: #f3f4f6; color: var(--ink); }
.act--on { color: var(--accent); }
.more { position: relative; }

/* ---- comments & solution ---- */
.solution { background: var(--gold-soft); border: 1px solid #f1d79a; border-radius: var(--radius); padding: 14px 16px; }
.solution__title { font-size: 15px; margin: 0 0 8px; color: var(--gold); }
.solution__who { display: flex; align-items: center; gap: 8px; margin-bottom: 6px; }
.solution__jump { display: inline-block; margin-top: 8px; font-size: 13px; font-weight: 600; color: var(--gold); }
.thread__title { font-size: 16px; margin: 0 0 12px; }
.cform { display: grid; grid-template-columns: 32px 1fr; gap: 10px; margin-bottom: 14px; }
.cform textarea { width: 100%; border: 1px solid var(--line-2); border-radius: 10px; padding: 9px 12px; resize: vertical; min-height: 44px; }
.cform__acts { display: flex; justify-content: flex-end; gap: 6px; margin-top: 6px; }
.comment { display: grid; grid-template-columns: 32px 1fr; gap: 10px; padding: 10px 0; border-top: 1px solid #f1f2f4; outline: none; }
.comment:focus-visible { box-shadow: 0 0 0 3px #bfdbfe; border-radius: 8px; }
.comment--reply { margin-left: 42px; border-top: 0; padding-top: 4px; }
.comment--accepted > .comment__main { background: var(--gold-soft); border-radius: 10px; padding: 8px 10px; margin: -4px 0; }
.comment__head { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 14px; }
.comment__head .more { margin-left: auto; }
.comment__acts { display: flex; gap: 14px; margin-top: 4px; }
.comment__reply:not(:empty) { margin-top: 8px; }

/* ---- forms ---- */
.form { display: flex; flex-direction: column; gap: 14px; }
.field { display: flex; flex-direction: column; gap: 5px; border: 0; padding: 0; margin: 0; min-width: 0; }
.field__label { font-weight: 600; font-size: 14px; color: var(--ink); padding: 0; }
.req { color: var(--danger); }
.field input[type="text"], .field input[type="url"], .field input[type="number"], .field input[type="date"], .field select, .field textarea, .ms__add input, .quick input, .quick select {
  width: 100%; border: 1px solid var(--line-2); background: #fff; border-radius: 10px; padding: 9px 12px; min-height: 40px;
}
.field textarea { resize: vertical; }
.field__foot { display: flex; justify-content: space-between; gap: 8px; font-size: 12px; color: var(--muted); }
.field__hint { font-size: 12px; color: var(--muted); }
.form__row { display: grid; grid-template-columns: 1fr 1fr; gap: 12px; }
.form__row--3 { grid-template-columns: 1fr 1fr 1fr; }
.form__actions { display: flex; justify-content: flex-end; gap: 8px; flex-wrap: wrap; }
.form__error { color: var(--danger); margin: 0; font-weight: 600; font-size: 14px; }
.types { display: grid; grid-template-columns: repeat(3, 1fr); gap: 8px; }
.type { border: 1px solid var(--line-2); background: #fff; border-radius: 10px; padding: 10px 8px; font-weight: 600; cursor: pointer; color: var(--ink-2); }
.type:hover { border-color: var(--accent); }
.type[aria-checked="true"] { border-color: var(--accent); background: var(--accent-soft); color: var(--accent); box-shadow: inset 0 0 0 1px var(--accent); }
.radios, .checks { display: grid; grid-template-columns: 1fr 1fr; gap: 6px 12px; }
.radio, .check { display: flex; align-items: center; gap: 8px; font-weight: 500; cursor: pointer; }
.radio input, .check input { width: 18px; height: 18px; accent-color: var(--accent); }

/* ---- dialogs ---- */
.modal { position: fixed; inset: 0; z-index: 60; display: grid; place-items: center; padding: 24px 16px; }
.modal__backdrop { position: absolute; inset: 0; background: rgba(17, 24, 39, 0.45); }
.modal__panel { position: relative; width: 100%; max-width: 520px; max-height: calc(100vh - 48px); overflow: auto; background: #fff; border-radius: 16px; box-shadow: 0 20px 50px rgba(0, 0, 0, 0.2); }
.modal__panel--wide { max-width: 700px; }
.modal__head { display: flex; align-items: center; justify-content: space-between; padding: 14px 16px 0 20px; position: sticky; top: 0; background: #fff; z-index: 1; }
.modal__title { font-size: 18px; margin: 0; }
.modal__body { padding: 16px 20px 20px; }
.modal__float { position: sticky; top: 0; display: flex; justify-content: flex-end; padding: 8px 8px 0; height: 0; z-index: 2; }
.modal__float .icon-btn { background: #fff; box-shadow: 0 1px 4px rgba(0, 0, 0, 0.15); }
.modal-post .card { box-shadow: none; }
.modal-post > .stack > .card:first-child, .modal-post .stack > * + * { margin-top: 12px; }

/* ---- toasts ---- */
.toasts { position: fixed; left: 50%; bottom: 24px; transform: translateX(-50%); z-index: 80; display: flex; flex-direction: column; gap: 8px; align-items: center; width: max-content; max-width: calc(100vw - 32px); }
.toast { background: var(--ink); color: #fff; padding: 10px 16px; border-radius: 10px; font-weight: 600; box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2); transition: opacity 0.3s, transform 0.3s; }
.toast--error { background: var(--danger); }
.toast--out { opacity: 0; transform: translateY(8px); }

/* ---- states ---- */
.empty { text-align: center; padding: 32px 16px; background: #fff; border: 1px dashed var(--line-2); border-radius: var(--radius); margin-top: 12px; }
.empty__title { font-weight: 700; font-size: 16px; margin: 0 0 4px; }
.empty .btn { margin-top: 10px; }
.empty--error { border-color: #fecaca; }
.skel { margin-top: 12px; }
.skel__row { display: flex; gap: 10px; align-items: center; margin-bottom: 12px; }
.skel__dot { width: 40px; height: 40px; border-radius: 50%; background: #eef0f3; }
.skel__line { display: block; height: 12px; border-radius: 6px; background: linear-gradient(90deg, #eef0f3, #f6f7f9, #eef0f3); background-size: 200% 100%; animation: shimmer 1.2s infinite linear; margin-top: 8px; }
.skel__line--short { width: 30%; margin: 0; }
.skel__line--mid { width: 60%; }
@keyframes shimmer { to { background-position: -200% 0; } }
@media (prefers-reduced-motion: reduce) { .skel__line { animation: none; } .toast { transition: none; } }

/* ---- progress ---- */
.progress { height: 8px; background: #eef0f3; border-radius: 999px; overflow: hidden; flex: 1; }
.progress__fill { display: block; height: 100%; background: var(--accent); border-radius: 999px; }

/* ---- projects & goals ---- */
.pcard__top, .gcard__top { display: flex; align-items: flex-start; justify-content: space-between; gap: 10px; }
.pcard__name, .gcard__title { font-size: 16px; margin: 0; }
.pcard__name a, .gcard__title a { color: var(--ink); }
.pcard__desc { color: var(--ink-2); margin: 8px 0; white-space: pre-wrap; }
.pcard__meta, .gcard__meta, .phead__meta { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 14px; }
.pcard__owner { display: inline-flex; align-items: center; gap: 6px; }
.pcard__progress, .gcard__bar { display: flex; align-items: center; gap: 10px; margin-top: 10px; }
.gcard__pct { font-weight: 700; font-size: 14px; min-width: 40px; text-align: right; }
.gcard__bar--lg .progress { height: 12px; }
.gcard__meta { margin-top: 8px; color: var(--ink-2); }
.phead__top { display: flex; justify-content: space-between; align-items: flex-start; gap: 12px; }
.phead__top .page-title { margin-bottom: 6px; }
.phead__acts { display: flex; gap: 8px; align-items: center; flex-wrap: wrap; justify-content: flex-end; }
.phead__desc { margin: 14px 0 8px; }
.phead__mission { margin: 8px 0; color: var(--ink-2); }
.phead__facts { display: flex; flex-wrap: wrap; gap: 14px; margin-top: 8px; font-size: 14px; }
.ghead > * + * { margin-top: 12px; }
.milestones { list-style: none; margin: 12px 0 0; padding: 0; }
.ms { display: flex; align-items: center; gap: 10px; padding: 8px 0; border-top: 1px solid #f1f2f4; }
.ms__main { display: flex; align-items: center; gap: 10px; flex: 1; min-width: 0; cursor: pointer; }
.ms__main input { width: 18px; height: 18px; accent-color: var(--accent); flex: none; }
.ms--done .ms__title { text-decoration: line-through; color: var(--muted); }
.ms__due { font-size: 13px; white-space: nowrap; }
.ms__acts { display: flex; }
.ms__add { display: grid; grid-template-columns: 1fr 150px auto; gap: 8px; margin-top: 12px; }
.quick { display: flex; flex-wrap: wrap; align-items: flex-end; gap: 10px; padding: 12px; background: #f9fafb; border-radius: 10px; }
.quick__field { display: flex; flex-direction: column; gap: 4px; font-size: 13px; font-weight: 600; }
.quick__field input { width: 130px; }
.people { list-style: none; margin: 12px 0 0; padding: 8px 16px; }
.people li { display: flex; align-items: center; gap: 10px; padding: 6px 0; }

/* ---- profile ---- */
.prof { display: flex; gap: 20px; align-items: flex-start; }
.prof__main { flex: 1; min-width: 0; }
.prof__main .page-title { margin-bottom: 2px; }
.prof__headline { font-size: 16px; color: var(--ink-2); margin: 0; font-weight: 500; }
.prof__bio { margin: 12px 0 0; }
.prof__skills { margin: 8px 0 0; font-size: 14px; color: var(--ink-2); }
.prof__stats { margin: 10px 0 0; font-size: 14px; }
.prof__acts { display: flex; gap: 8px; margin-top: 12px; flex-wrap: wrap; }
.stat { display: flex; flex-wrap: wrap; align-items: baseline; gap: 10px; margin-top: 12px; }
.stat__num { font-size: 30px; font-weight: 800; color: var(--gold); }
.stat__label { font-weight: 600; }
.stat__projects { flex-basis: 100%; margin: 0; color: var(--ink-2); font-size: 14px; }
.contribs { list-style: none; padding: 4px 16px; margin: 12px 0 0; }
.contrib { display: flex; gap: 12px; padding: 10px 0; border-top: 1px solid #f1f2f4; }
.contrib:first-child { border-top: 0; }
.contrib p { margin: 0; }
.contrib__icon { color: var(--gold); font-size: 18px; }

/* ---- notifications ---- */
.notes { list-style: none; padding: 4px; margin: 12px 0 0; }
.note__link { display: flex; align-items: center; gap: 12px; padding: 10px 12px; border-radius: 10px; color: var(--ink); }
.note__link:hover { background: #f9fafb; text-decoration: none; }
.note--unread .note__link { background: var(--accent-soft); }
.note__text { flex: 1; min-width: 0; display: flex; flex-direction: column; }
.note__snip { color: var(--ink-2); overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.note__text time { font-size: 13px; }
.note__dot { width: 9px; height: 9px; background: var(--accent); border-radius: 50%; flex: none; }

/* ---- moderation ---- */
.report + .report { margin-top: 12px; }
.report__head, .report__who { display: flex; flex-wrap: wrap; align-items: center; gap: 6px; font-size: 14px; }
.report__who { margin: 10px 0; }
.report__text { white-space: pre-wrap; word-break: break-word; font: inherit; background: #f9fafb; border-radius: 8px; padding: 10px; max-height: 220px; overflow: auto; }

/* ---- rail ---- */
.rail__box { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); padding: 14px; }
.rail__head { display: flex; justify-content: space-between; align-items: baseline; margin-bottom: 6px; }
.rail__head h2 { font-size: 14px; margin: 0; }
.rail__head a { font-size: 13px; font-weight: 600; }
.rail__row { display: flex; flex-direction: column; gap: 4px; padding: 7px 0; color: var(--ink); border-top: 1px solid #f3f4f6; }
.rail__row:first-of-type { border-top: 0; }
.rail__row:hover { text-decoration: none; }
.rail__row:hover .rail__name { color: var(--accent); }
.rail__name { font-weight: 600; font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rail__sub { font-size: 12px; display: block; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.rail__person { display: flex; gap: 10px; align-items: center; padding: 6px 0; min-width: 0; }
.rail__person > div { min-width: 0; }
.rail__empty { font-size: 13px; margin: 4px 0 0; }

/* ---- landing ---- */
.landing { min-height: 100vh; display: flex; flex-direction: column; background: #fff; }
.landing__top { padding: 22px 24px; max-width: 1100px; width: 100%; margin: 0 auto; }
.landing__main { flex: 1; max-width: 760px; margin: 0 auto; padding: 8vh 24px 40px; text-align: center; }
.landing__title { font-size: clamp(32px, 6vw, 56px); line-height: 1.08; letter-spacing: -0.025em; margin: 0 0 18px; }
.landing__title--sm { font-size: 32px; }
.landing__lede { font-size: 19px; color: var(--ink-2); max-width: 620px; margin: 0 auto 28px; }
.landing__note { color: var(--muted); font-weight: 600; }
.landing__actions { display: flex; gap: 12px; justify-content: center; flex-wrap: wrap; margin: 8px 0 40px; }
.landing__points { list-style: none; padding: 0; margin: 0 auto; display: grid; grid-template-columns: repeat(3, 1fr); gap: 16px; text-align: left; max-width: 760px; }
.landing__points li { border-top: 2px solid var(--accent); padding-top: 10px; color: var(--ink-2); font-size: 14px; }
.landing__foot { display: flex; gap: 16px; justify-content: center; padding: 20px; color: var(--muted); font-size: 13px; border-top: 1px solid var(--line); }

/* ---- sign up / log in ---- */
.landing__main--split { max-width: 1100px; display: grid; grid-template-columns: minmax(0, 1fr) 400px; gap: 48px; align-items: start; text-align: left; padding-top: 6vh; }
.landing__main--split .landing__lede { margin-left: 0; }
.landing__main--split .landing__points { grid-template-columns: 1fr; max-width: 520px; margin: 28px 0 0; }
.authcard { padding: 22px; }
.authcard__title { font-size: 20px; margin: 0 0 4px; }
.authcard__tabs { display: grid; grid-template-columns: 1fr 1fr; background: #f3f4f6; border-radius: 10px; padding: 4px; margin-bottom: 16px; }
.authcard__tab { border: 0; background: none; border-radius: 8px; padding: 8px; font-weight: 700; color: var(--muted); cursor: pointer; }
.authcard__tab[aria-selected="true"] { background: #fff; color: var(--ink); box-shadow: var(--shadow); }
.authcard .field input[type="email"], .authcard .field input[type="password"] { width: 100%; border: 1px solid var(--line-2); background: #fff; border-radius: 10px; padding: 9px 12px; min-height: 40px; }
.authcard__row { display: flex; justify-content: flex-end; margin-top: -8px; }
.authcard__or { display: flex; align-items: center; gap: 10px; color: var(--muted); font-size: 13px; margin: 14px 0; }
.authcard__or::before, .authcard__or::after { content: ""; flex: 1; height: 1px; background: var(--line); }
.authcard__fine { font-size: 12px; color: var(--muted); margin: 4px 0 0; }
.authcard .linkbtn { font-size: 13px; color: var(--accent); }
.btn--google { gap: 10px; }
.gicon { display: inline-flex; }
.bday { display: grid; grid-template-columns: 1.4fr 1fr 1.1fr; gap: 8px; }
.bday select { width: 100%; border: 1px solid var(--line-2); background: #fff; border-radius: 10px; padding: 9px 8px; min-height: 40px; }

/* ---- responsive ---- */
@media (max-width: 1180px) {
  .layout { grid-template-columns: 200px minmax(0, 1fr) 280px; }
}
@media (max-width: 960px) {
  .layout { grid-template-columns: 200px minmax(0, 1fr); }
  .rail { display: none; }
}
@media (max-width: 720px) {
  body { padding-bottom: calc(64px + env(safe-area-inset-bottom)); }
  .top__in { gap: 10px; height: 56px; }
  .search { margin-left: 4px; }
  .layout { grid-template-columns: minmax(0, 1fr); padding: 12px 12px 24px; gap: 0; }
  .side { display: none; }
  .card { padding: 14px; }
  .bottomnav {
    display: flex; position: fixed; left: 0; right: 0; bottom: 0; z-index: 30; background: #fff; border-top: 1px solid var(--line);
    padding: 4px 4px calc(4px + env(safe-area-inset-bottom)); justify-content: space-around; align-items: center;
  }
  .bottomnav a { position: relative; flex: 1; display: flex; flex-direction: column; align-items: center; gap: 1px; font-size: 11px; font-weight: 600; color: var(--muted); padding: 6px 0; }
  .bottomnav a span[aria-hidden] { font-size: 18px; line-height: 1.1; }
  .bottomnav a[aria-current="page"] { color: var(--accent); }
  .bottomnav a:hover { text-decoration: none; }
  .bottomnav .pill { position: absolute; top: 0; left: 55%; }
  .bottomnav__post { width: 50px; height: 50px; border-radius: 50%; border: 0; background: var(--accent); color: #fff; font-size: 28px; line-height: 1; cursor: pointer; box-shadow: 0 6px 16px rgba(15, 118, 110, 0.35); margin-top: -18px; flex: none; }
  .modal { padding: 0; place-items: stretch; }
  .modal__panel, .modal__panel--wide { max-width: none; max-height: none; height: 100%; border-radius: 0; }
  .form__row, .form__row--3 { grid-template-columns: 1fr; }
  .types { grid-template-columns: 1fr 1fr; }
  .radios, .checks { grid-template-columns: 1fr; }
  .ms__add { grid-template-columns: 1fr auto; }
  .ms__add input[type="date"] { grid-column: 1; }
  .prof { flex-direction: column; gap: 12px; }
  .phead__top { flex-direction: column; }
  .phead__acts { justify-content: flex-start; }
  .landing__points { grid-template-columns: 1fr; }
  .landing__main--split { grid-template-columns: 1fr; gap: 24px; padding-top: 2vh; }
  .landing__main--split .landing__points { display: none; }
  .comment--reply { margin-left: 28px; }
  .toasts { bottom: calc(76px + env(safe-area-inset-bottom)); }
}
