/* ═══ The Neighborhood — app chrome + zine feed layouts ═══
   Everything colorful inherits from tokens.css. This file is structure. */

[hidden] { display: none !important; }

.page { max-width: 900px; margin: 0 auto; padding: 0 40px 80px; }
@media (max-width: 700px) { .page { padding: 0 18px 80px; } }

.mast-right { text-align: right; color: var(--dim); }
.mast-line { letter-spacing: .1em; }
.mast-who { margin-top: 4px; display: flex; gap: 7px; justify-content: flex-end; align-items: center; }

/* nav */
.nav {
  display: flex; gap: 26px; align-items: center;
  padding: 12px 40px; border-bottom: 1px solid var(--line);
  color: var(--dim); letter-spacing: .14em; font-size: 11px;
}
.nav a { color: var(--dim); text-decoration: none; padding-bottom: 2px; }
.nav a.here { color: var(--head); border-bottom: 1.5px solid var(--accent); }
.nav-spacer { flex: 1; }
.mode-btn {
  font-family: var(--labelfont); font-size: 13px; background: none; border: 1px solid var(--line);
  color: var(--dim); border-radius: 14px; padding: 3px 10px; cursor: pointer;
}
.mode-btn:hover { color: var(--head); border-color: var(--head); }

/* login */
.login { min-height: 60vh; display: flex; align-items: center; justify-content: center; }
.login-card { max-width: 380px; text-align: center; padding: 40px 30px; }
.login-hi { font-size: 44px; color: var(--head); margin-bottom: 14px; }
.login-copy { font-size: 15px; line-height: 1.6; color: var(--dim); margin-bottom: 22px; }
.login input {
  width: 100%; font-family: var(--labelfont); font-size: 13px; letter-spacing: .08em;
  padding: 10px 14px; border: 1px solid var(--line); border-radius: 20px;
  background: var(--card); color: var(--ink); outline: none; text-align: center;
}
.login input:focus { border-color: var(--accent); }
.go-btn {
  margin-top: 12px; padding: 9px 26px; border-radius: 20px; border: none; cursor: pointer;
  background: var(--head); color: var(--paper); letter-spacing: .14em; font-size: 12px;
}
.login-err { margin-top: 12px; color: #a04545; min-height: 16px; }
#login-form { display: grid; gap: 10px; }
.login-alt { margin-top: 18px; color: var(--dim); cursor: pointer; font-size: 9px; letter-spacing: .16em; opacity: .7; }
.login-alt:hover { opacity: 1; }
#token-in { margin-top: 10px; }

/* ── the zine feed ── */
.post-credit {
  writing-mode: vertical-rl; transform: rotate(180deg);
  font-family: var(--labelfont); font-size: 11px; letter-spacing: .14em;
  color: var(--dim); white-space: nowrap; align-self: start;
}
.photo-frame { position: relative; overflow: visible; }
.photo-frame img { width: 100%; height: 100%; object-fit: cover; display: block; }
.who-name { font-family: var(--display); font-weight: 700; }
.cap { font-size: 15px; line-height: 1.68; margin-top: 10px; overflow-wrap: break-word; }

/* archetype A — photo with placard (image + text) */
.postA { display: grid; grid-template-columns: 22px 1.3fr .9fr; gap: 20px; align-items: start; }
.postA .photo-frame { aspect-ratio: 4/3; background: linear-gradient(120deg, var(--photo1), var(--photo2)); }
.postA .placard { padding-top: 6px; }

/* archetype B — pull-quote (longer text, no image) */
.postB { position: relative; padding-left: 148px; min-height: 60px; }
.postB .anno { position: absolute; left: 0; top: 4px; width: 128px; text-align: right; }
.postB .quote {
  font-family: var(--display); font-style: italic; font-size: 26px;
  line-height: 1.4; color: var(--ink); max-width: 580px; overflow-wrap: break-word;
}
@media (max-width: 700px) {
  .postB { padding-left: 0; padding-top: 40px; }
  .postB .anno { position: absolute; top: 0; left: 0; width: auto; text-align: left; }
}

/* archetype C — tilted taped photo (image, little text) */
.postC { display: grid; grid-template-columns: 220px 1fr; gap: 32px; align-items: center; padding-left: 40px; }
.postC .frame { transform: rotate(-2.4deg); }
.postC .photo-frame { aspect-ratio: 1; background: linear-gradient(120deg, var(--photo1), var(--photo2)); }
@media (max-width: 700px) { .postC { grid-template-columns: 1fr; padding-left: 0; } .postC .frame { max-width: 260px; } }

/* archetype D — quiet status (short text) */
.postD { text-align: right; padding-right: 30px; }
.postD .status { font-family: var(--display); font-style: italic; font-size: 19px; color: var(--dim); }

/* comments as margin conversation */
.thread { margin-top: 16px; padding-left: 18px; border-left: 1.5px solid var(--line); }
.thread .c { margin-top: 10px; font-size: 14px; line-height: 1.55; }
.thread .c .script { font-size: 20px; margin-right: 6px; }
.thread .c .when { font-family: var(--labelfont); font-size: 10px; color: var(--dim); margin-left: 8px; letter-spacing: .1em; }

/* reactions */
.reacts { margin-top: 10px; display: flex; gap: 8px; align-items: center; flex-wrap: wrap; }
.react-chip {
  font-size: 13px; background: var(--card); border: 1px solid var(--line);
  border-radius: 14px; padding: 2px 9px; cursor: default;
}
.react-add { cursor: pointer; opacity: .5; border-style: dashed; }
.react-add:hover { opacity: 1; }
.react-chip .pick { cursor: pointer; font-style: normal; font-weight: 400; padding: 0 3px; }
.react-chip .pick:hover { transform: scale(1.3); display: inline-block; }

/* removed post — honest tombstone */
.removed { font-family: var(--labelfont); font-size: 11px; letter-spacing: .12em; color: var(--dim); text-align: center; padding: 10px; }

/* face chips — small taped portraits beside names */
.avchip { display: inline-block; overflow: hidden; transform: rotate(-2.5deg); vertical-align: middle; margin-right: 9px;
  border: 2px solid color-mix(in srgb, var(--mc, var(--line)) var(--member-mix), var(--member-base)); background: var(--card);
  box-shadow: 0 1px 4px #0002; }
.avchip img { width: 100%; height: 100%; object-fit: cover; object-position: center 12%; display: block; }
.byline { display: flex; align-items: center; margin-bottom: 4px; }
.byline-right { justify-content: flex-end; }
.postB .anno .avchip { margin-right: 0; margin-bottom: 4px; }
.c-face { width: 22px; height: 22px; object-fit: cover; object-position: center 10%; border-radius: 50%; vertical-align: middle; margin-right: 7px; }
.leave-note { color: var(--dim); cursor: pointer; font-size: 19px; opacity: .65; }
.leave-note:hover { opacity: 1; color: var(--accent); }
.note-box { display: flex; gap: 8px; margin-top: 8px; align-items: center; }
.note-in { flex: 1; font-family: var(--body); font-size: 14px; padding: 7px 12px; border: 1px solid var(--line);
  border-radius: 16px; background: var(--card); color: var(--ink); outline: none; }
.note-in:focus { border-color: var(--accent); }

/* compose */
.compose { margin: 30px 0 6px; background: var(--card); border: 1.5px solid var(--line); border-radius: 6px; padding: 16px 18px; }
.compose-head { display: flex; align-items: baseline; margin-bottom: 6px; }
.compose-preview { position: relative; display: inline-block; margin: 8px 0; }
.compose-preview img { max-height: 120px; max-width: 200px; display: block; border: 1.5px solid var(--line); transform: rotate(-1.6deg); }
.compose-preview .label { position: absolute; top: -8px; right: -8px; cursor: pointer; background: var(--head); color: var(--paper);
  border-radius: 50%; width: 20px; height: 20px; display: flex; align-items: center; justify-content: center; font-size: 10px; }
.compose-hi { font-size: 26px; color: color-mix(in srgb, var(--mc, var(--head)) var(--member-mix), var(--member-base)); }
.compose-title { color: var(--dim); font-size: 10px; letter-spacing: .16em; }
.compose textarea {
  width: 100%; min-height: 64px; border: none; background: none; resize: vertical;
  font-family: var(--body); font-size: 15px; line-height: 1.6; color: var(--ink); outline: none;
}
.compose-row { display: flex; gap: 10px; align-items: center; margin-top: 8px; }
.compose-row .spacer { flex: 1; }
.compose-note { font-family: var(--labelfont); font-size: 10px; letter-spacing: .1em; color: var(--dim); }

/* groups as classifieds */
.club-board { columns: 2; column-gap: 28px; margin-top: 34px; }
@media (max-width: 700px) { .club-board { columns: 1; } }
.club {
  break-inside: avoid; border: 1.5px solid var(--line); padding: 18px 18px 14px;
  margin-bottom: 28px; position: relative; background: var(--card);
}
.club .pin {
  position: absolute; top: -7px; left: 50%; transform: translateX(-50%);
  width: 12px; height: 12px; border-radius: 50%;
}
.club h3 { font-family: var(--display); font-size: 21px; color: var(--head); }
.club .desc { font-size: 14px; line-height: 1.55; margin-top: 6px; }
.club .meta { margin-top: 12px; display: flex; justify-content: space-between; color: var(--dim); font-size: 10px; letter-spacing: .12em; font-family: var(--labelfont); }
.club .lock { font-size: 10px; }

/* threads */
.thread-start { display: flex; gap: 10px; margin: 6px 0 24px; }
.thread-start input { flex: 1; font-family: var(--body); font-size: 15px; padding: 9px 14px; border: 1.5px solid var(--line);
  border-radius: 20px; background: var(--card); color: var(--ink); outline: none; }
.thread-start input:focus { border-color: var(--accent); }
.thread-row { display: flex; align-items: baseline; gap: 12px; padding: 12px 4px; border-bottom: 1px solid var(--line);
  text-decoration: none; color: inherit; }
.thread-row:hover .thread-title { color: var(--accent); }
.pin-dot { width: 9px; height: 9px; border-radius: 50%; flex-shrink: 0; align-self: center;
  background: color-mix(in srgb, var(--mc, var(--accent)) var(--member-mix), var(--member-base)); }
.thread-title { font-family: var(--display); font-size: 20px; color: var(--head); }
.thread-meta { margin-left: auto; color: var(--dim); font-size: 10px; letter-spacing: .12em; white-space: nowrap; }

/* group page */
.group-bar { display: flex; gap: 14px; align-items: baseline; flex-wrap: wrap; margin: 4px 0 18px; padding-bottom: 14px; border-bottom: 1px solid var(--line); }
.club { cursor: pointer; }
.club:hover h3 { color: var(--accent); }
a.club { text-decoration: none; color: inherit; display: block; }

/* members directory */
.folk { display: grid; grid-template-columns: repeat(auto-fill, minmax(200px, 1fr)); gap: 22px; margin-top: 34px; }
.person { border: 1.5px solid var(--line); background: var(--card); padding: 18px; text-align: center; }
.person .script { font-size: 30px; }
.person .kind { font-family: var(--labelfont); font-size: 10px; letter-spacing: .14em; color: var(--dim); margin-top: 6px; }
.person .house { font-family: var(--labelfont); font-size: 10px; letter-spacing: .1em; color: var(--dim); margin-top: 2px; }

.loading { text-align: center; padding: 60px 0; font-family: var(--labelfont); letter-spacing: .2em; font-size: 11px; color: var(--dim); }

/* ── profile cover spread ── */
.cover { display: grid; grid-template-columns: 300px 1fr; gap: 40px; align-items: start; margin-top: 44px; }
@media (max-width: 700px) { .cover { grid-template-columns: 1fr; } .cover-left { max-width: 280px; } }
.cover-photo { position: relative; aspect-ratio: 3/4; background: linear-gradient(120deg, var(--photo1), var(--photo2)); transform: rotate(-1.6deg); }
.cover-photo img { width: 100%; height: 100%; object-fit: cover; object-position: center 12%; display: block; }
.cover-empty { display: flex; align-items: center; justify-content: center; color: var(--dim); }
.cover-hi { font-size: 34px; color: var(--dim); line-height: 1; }
.cover-name { font-family: var(--display); font-size: 54px; line-height: 1; margin: 4px 0 12px; }
.cover-facts { display: flex; gap: 14px; flex-wrap: wrap; color: var(--dim); font-size: 10px; letter-spacing: .16em; margin-bottom: 16px; }
.cover-bio { max-width: 480px; }
.cover-currently { margin-top: 16px; }
.cover-currently .label { color: var(--accent); }
.cover-hobbies { margin-top: 14px; display: flex; gap: 8px; flex-wrap: wrap; }
.cover-extras { margin-top: 16px; display: grid; gap: 6px; }
.cover-extras .label { color: var(--dim); }

/* gallery */
.gallery { display: grid; grid-template-columns: repeat(auto-fill, minmax(180px, 1fr)); gap: 26px; margin-top: 10px; }
.g-photo { margin: 0; }
.g-photo .photo-frame { aspect-ratio: 1; }
.g-photo:nth-child(3n) .photo-frame { transform: rotate(1.8deg); }
.g-photo:nth-child(3n+1) .photo-frame { transform: rotate(-1.4deg); }
.g-photo figcaption { margin-top: 8px; color: var(--dim); font-size: 10px; letter-spacing: .1em; text-align: center; }

.person { display: block; text-decoration: none; color: inherit; }
.person:hover { border-color: var(--accent); }
.ro-check { display: flex; align-items: center; gap: 6px; color: var(--dim); font-size: 10px; letter-spacing: .12em; white-space: nowrap; }
.ro-check input { accent-color: var(--accent); }
.unpub { opacity: .35; }
.unpub:hover { opacity: 1; color: #a04545; border-color: #a04545; cursor: pointer; }
@media (max-width: 700px) { .thread-start { flex-wrap: wrap; } }
.edit-l { display: block; color: var(--dim); font-size: 9px; letter-spacing: .16em; margin: 10px 0 3px; }
.edit-f { width: 100%; }
.pending-row { display: grid; grid-template-columns: 140px 1fr; gap: 20px; align-items: start; margin: 18px 0; padding: 14px; background: var(--card); border: 1.5px dashed var(--line); }
.pending-thumb { aspect-ratio: 1; }
.shoebox-gift { margin: 40px 0 10px; display: flex; gap: 10px; align-items: center; flex-wrap: wrap; padding-top: 18px; border-top: 1px solid var(--line); }
.shoebox-gift .note-in { flex: 1; min-width: 180px; }
