/* Affordable Pros hub — brand: green / yellow / black / blue.
   Phone-first: big touch targets, minimal text. */
:root {
  --green: #1a7a2e;
  --green-dark: #0b3d17;
  --yellow: #ffd21f;
  --blue: #1256a0;
  --black: #111111;
  --bg: #f4f6f4;
  --card: #ffffff;
  --muted: #5c665e;
  --red: #b3261e;
}
* { box-sizing: border-box; }
html { -webkit-text-size-adjust: 100%; }
body {
  margin: 0; background: var(--bg); color: var(--black);
  font-family: system-ui, -apple-system, "Segoe UI", Roboto, sans-serif;
  font-size: 18px; line-height: 1.45;
}
a { color: var(--blue); }

.topbar {
  position: sticky; top: 0; z-index: 10;
  display: flex; justify-content: space-between; align-items: center;
  background: var(--green-dark); color: #fff; padding: 12px 16px;
}
.brand {
  color: #fff; text-decoration: none; font-weight: 800; font-size: 22px;
  letter-spacing: .2px;
}
.navbtn {
  color: #fff; text-decoration: none; font-size: 18px; padding: 10px 12px;
  border-radius: 10px; background: rgba(255,255,255,.12); margin-left: 8px;
  display: inline-block; min-height: 48px; line-height: 28px;
}
.badge {
  background: var(--yellow); color: var(--black); font-weight: 800;
  border-radius: 999px; padding: 1px 9px; font-size: 15px;
  vertical-align: middle;
}
main { max-width: 760px; margin: 0 auto; padding: 14px 14px 40px; }

.banner {
  border-radius: 12px; padding: 12px 14px; margin: 10px 0; font-size: 16px;
}
.banner-warn { background: #fff3cd; border: 1px solid #e6c200; }
.banner-demo { background: #e7f0ff; border: 1px solid var(--blue); }

.bigbtn {
  display: flex; flex-direction: column; align-items: center; gap: 6px;
  width: 100%; min-height: 84px; padding: 20px 16px; margin: 12px 0;
  border: none; border-radius: 18px; cursor: pointer;
  font-size: 24px; font-weight: 800; text-decoration: none; text-align: center;
  justify-content: center;
}
.btn-green { background: var(--green); color: #fff; }
.btn-blue { background: var(--blue); color: #fff; }
.btn-red { background: var(--red); color: #fff; }

/* Home: one big button per business */
.homewrap { padding-top: 8px; }
.area-btn {
  background: var(--card); color: var(--black);
  border: 4px solid var(--area-color, var(--green));
  box-shadow: 0 3px 10px rgba(0,0,0,.10);
  min-height: 132px; align-items: stretch; text-align: left;
  position: relative;
}
.area-label { font-size: 32px; font-weight: 900; }
.area-number { font-size: 18px; color: var(--muted); font-weight: 600; }
.bigbadge {
  align-self: flex-start; background: var(--red); color: #fff;
  border-radius: 999px; padding: 4px 14px; font-size: 18px; font-weight: 800;
}
.badge-zero { background: #e2e8e2; color: var(--muted); }

.areahead { margin: 6px 0 10px; border-left: 8px solid var(--area-color, var(--green)); padding-left: 12px; }
.areahead h2 { margin: 2px 0; font-size: 28px; }
.backlink { font-size: 18px; text-decoration: none; font-weight: 700; }

.subnav { display: flex; gap: 8px; flex-wrap: wrap; margin: 10px 0 14px; }
.chip {
  border: 2px solid #c9d2c9; background: var(--card); color: var(--black);
  border-radius: 999px; padding: 10px 16px; font-size: 17px; font-weight: 700;
  text-decoration: none; min-height: 48px; display: inline-flex; align-items: center;
  cursor: pointer;
}
.chip-on { background: var(--green-dark); color: #fff; border-color: var(--green-dark); }

.threadlist, .calllist, .alertlist { display: flex; flex-direction: column; gap: 10px; }
.threadrow {
  display: flex; justify-content: space-between; gap: 10px;
  background: var(--card); border-radius: 14px; padding: 16px;
  text-decoration: none; color: var(--black); min-height: 76px;
  box-shadow: 0 1px 4px rgba(0,0,0,.06); align-items: center;
}
.threadrow.unread { border-left: 8px solid var(--yellow); }
.t-link { flex: 1; display: flex; flex-direction: column; gap: 2px; min-width: 0; text-decoration: none; color: inherit; }
.t-main { display: flex; flex-direction: column; gap: 2px; min-width: 0; }

/* Pinned / PRIORITY — deliberately LOUD: black band, big yellow words.
   Not color alone: large bold text + thick borders + top placement. */
.priority-band {
  background: var(--black); color: var(--yellow);
  font-size: 24px; font-weight: 900; letter-spacing: 1px;
  text-align: center; padding: 14px 10px; margin: 10px 0;
  border-radius: 12px; border: 4px solid var(--yellow);
}
.threadwrap.pinned .threadrow {
  border: 4px solid var(--black); background: #fff8d6;
}
.pinform { margin: 0; }
.pinbtn {
  min-height: 56px; min-width: 118px; padding: 10px 14px;
  border-radius: 12px; border: 3px solid var(--black);
  background: #fff; color: var(--black);
  font-size: 17px; font-weight: 900; cursor: pointer; white-space: nowrap;
}
.pinbtn.pin-on { background: var(--black); color: var(--yellow); }
section > .pinform { margin: 8px 0; }
section > .pinform .pinbtn { width: 100%; min-height: 64px; font-size: 20px; }

/* Automated message marker inside a thread */
.b-auto {
  display: inline-block; background: var(--black); color: var(--yellow);
  font-weight: 900; font-size: 13px; letter-spacing: .5px;
  border-radius: 6px; padding: 3px 9px; margin-bottom: 6px;
}
.t-name { font-weight: 800; font-size: 19px; }
.t-snippet { color: var(--muted); font-size: 16px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; max-width: 46ch; }
.t-side { color: var(--muted); font-size: 15px; white-space: nowrap; }
.demo-tag { background: var(--blue); color: #fff; border-radius: 6px; padding: 0 7px; font-size: 13px; font-weight: 800; }

.threadview { display: flex; flex-direction: column; gap: 8px; margin: 12px 0; }
.bubble { max-width: 86%; padding: 12px 14px; border-radius: 16px; }
.bubble.in { background: var(--card); align-self: flex-start; border: 1px solid #dfe5df; }
.bubble.out { background: #dcf3e0; align-self: flex-end; }
.b-time { display: block; color: var(--muted); font-size: 13px; margin-top: 4px; }
.b-status { display: block; color: var(--muted); font-size: 13px; font-style: italic; }
/* Internal attribution — team-only, never sent to the customer */
.b-by { display: block; color: var(--blue); font-size: 13px; font-weight: 700; margin-top: 2px; }
.who { font-weight: 700; }
.resetform { display: flex; gap: 6px; margin-top: 6px; }
.resetform input {
  font-size: 15px; padding: 8px; border-radius: 8px;
  border: 2px solid #c9d2c9; font-family: inherit; min-width: 0;
}
button.chip { font-family: inherit; cursor: pointer; }
.b-media { display: block; font-size: 14px; color: var(--blue); }

.tplrow { display: flex; gap: 8px; flex-wrap: wrap; margin: 10px 0; }
.tplcard { background: var(--card); border-radius: 14px; padding: 14px 16px; margin: 10px 0; }
.tplcard h3 { margin: 0 0 6px; font-size: 19px; }
.tplcard p { margin: 0; color: #333; }

.sendbox { display: flex; flex-direction: column; gap: 10px; margin-top: 10px; }
.sendbox textarea, .sendbox input, .loginbox input {
  font-size: 18px; padding: 14px; border-radius: 12px; border: 2px solid #c9d2c9;
  width: 100%; font-family: inherit; background: #fff;
}
.callrow { margin: 6px 0; }
.callrow2 {
  display: flex; justify-content: space-between; gap: 10px;
  background: var(--card); border-radius: 12px; padding: 14px 16px;
  min-height: 56px; align-items: center;
}
.alertrow {
  display: flex; justify-content: space-between; gap: 10px;
  background: var(--card); border-radius: 12px; padding: 14px 16px;
}
.alertrow.unread { border-left: 8px solid var(--yellow); font-weight: 700; }

.muted { color: var(--muted); }
.center { text-align: center; }
.pad { padding: 24px 10px; }
.error { color: var(--red); font-weight: 700; }

.loginbody { display: flex; min-height: 100vh; align-items: center; justify-content: center; background: var(--green-dark); }
.loginbox {
  background: var(--card); border-radius: 20px; padding: 28px 22px;
  width: min(92vw, 380px); display: flex; flex-direction: column; gap: 12px;
  text-align: center;
}
.logomark {
  width: 84px; height: 84px; border-radius: 20px; margin: 0 auto;
  background: var(--green); color: var(--yellow); font-size: 38px;
  font-weight: 900; display: flex; align-items: center; justify-content: center;
}
.loginbox h1 { margin: 4px 0 0; font-size: 28px; }
section h3 { margin: 22px 0 8px; }
.calls-h { margin: 18px 0 8px; }
.vm-transcript {
  background: #fff8d6; border: 2px solid var(--black); border-radius: 12px;
  padding: 12px 14px; font-size: 17px; margin: 4px 0 10px;
}
