/* Boss HQ demo: Portal and Comms tabs. */
.pc-wrap {
  display: flex;
  flex-direction: column;
  gap: 14px;
}
.pc-chrome {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 10px;
  font-size: 12.5px;
}
.pc-info {
  flex: 1 1 320px;
  background: var(--info-bg);
  color: var(--info-fg);
  padding: 9px 12px;
  border-radius: 6px;
}
.pc-frame {
  max-width: 1080px;
  width: 100%;
  margin: 0 auto;
  background: #fff;
  color: #1b2226;
  border: 1px solid var(--hair);
  border-radius: 10px;
  overflow: hidden;
  box-shadow: var(--shadow);
}
.pc-top {
  background: #1b2226;
  color: #f2f5f6;
  padding: 14px 22px;
  display: flex;
  justify-content: space-between;
  gap: 12px;
  flex-wrap: wrap;
  font-size: 13px;
}
.pc-top span {
  color: #a2aeb4;
}
.pc-hero {
  position: relative;
  height: 240px;
  background: #e9e8e4;
}
.pc-hero .pc-art {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}
.pc-nophoto {
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
  padding: 20px;
  color: #57636a;
  font-size: 13.5px;
}
.pc-herotxt {
  position: absolute;
  left: 0;
  right: 0;
  bottom: 0;
  padding: 18px 22px;
  color: #fff;
  background: linear-gradient(transparent, rgba(16, 23, 26, 0.88) 55%);
  padding-top: 44px;
}
.pc-herotxt h3,
.pc-herotxt p {
  color: #fff;
  text-shadow: 0 1px 3px rgba(0, 0, 0, 0.55);
}
.pc-hero-none {
  height: auto;
  min-height: 150px;
  display: flex;
  flex-direction: column;
  justify-content: flex-end;
  background: linear-gradient(135deg, #3a4a52, #1b2226);
}
.pc-hero-none .pc-nophoto {
  height: auto;
  position: absolute;
  top: 14px;
  right: 22px;
  padding: 0;
  color: #c9d2d6;
  font-size: 12.5px;
  text-align: right;
}
.pc-hero-none .pc-herotxt h3,
.pc-hero-none .pc-herotxt p {
  color: #fff;
}
.pc-hero-none .pc-herotxt {
  position: static;
  color: #fff;
  background: none;
  padding-top: 44px;
}
.pc-herotxt h3 {
  margin: 0;
  font-size: 22px;
}
.pc-herotxt p {
  margin: 2px 0 0;
  font-size: 13px;
  opacity: 0.9;
}
.pc-body {
  padding: 8px 22px 22px;
  display: grid;
  grid-template-columns: 1fr 1fr;
  gap: 0 28px;
  grid-template-rows: auto 1fr;
  align-items: start;
}
.pc-body section {
  padding-top: 14px;
  min-width: 0;
}
.pc-body section:nth-child(2) {
  grid-row: span 2;
}
.pc-body h4 {
  margin: 0 0 8px;
  font-size: 11px;
  letter-spacing: 0.08em;
  text-transform: uppercase;
  color: #57636a;
}
.pc-body p {
  margin: 0 0 8px;
  font-size: 13.5px;
  line-height: 1.5;
}
.pc-dim {
  color: #57636a;
}
.pc-ms {
  list-style: none;
  margin: 0;
  padding: 0;
}
.pc-ms li {
  display: grid;
  grid-template-columns: 12px 1fr auto;
  gap: 2px 10px;
  align-items: center;
  padding: 8px 0;
  border-bottom: 1px solid #e9e8e4;
  font-size: 13px;
}
.pc-ms .dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  border: 2px solid #88939c;
  grid-row: span 2;
}
.pc-ms li.done .dot {
  background: #3f6b4f;
  border-color: #3f6b4f;
}
.pc-ms li.active .dot {
  background: #6d92a5;
  border-color: #6d92a5;
}
.pc-ms .dt {
  grid-column: 2;
  font-size: 11.5px;
  color: #57636a;
}
.pc-ms .st {
  grid-column: 3;
  grid-row: 1 / span 2;
  font-size: 11.5px;
  color: #57636a;
}
.pc-wait {
  display: flex;
  flex-direction: column;
  gap: 1px;
  padding: 8px 10px;
  margin-bottom: 6px;
  border-radius: 6px;
  background: #f6f1e4;
  font-size: 13px;
}
.pc-wait em {
  font-style: normal;
  font-size: 11.5px;
  color: #8a6a2b;
}
.pc-pics {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(110px, 1fr));
  gap: 8px;
}
.pc-pics figure {
  margin: 0;
}
.pc-pics .pc-art {
  width: 100%;
  height: 76px;
  border-radius: 6px;
  display: block;
}
.pc-pics figcaption {
  font-size: 11px;
  color: #57636a;
  margin-top: 3px;
}
.pc-admin {
  background: var(--sunk);
  border: 1px dashed var(--input);
  border-radius: 6px;
  padding: 12px 14px;
}
.pc-ahead {
  display: flex;
  flex-wrap: wrap;
  gap: 6px 12px;
  align-items: baseline;
  margin-bottom: 10px;
}
.pc-ahead b {
  font-size: 13px;
}
.pc-ahead span {
  font-size: 11.5px;
  color: var(--muted);
}
.pc-agrid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 14px;
}
.pc-thumb {
  width: 150px;
  height: 84px;
  border-radius: 6px;
  overflow: hidden;
  margin-bottom: 8px;
  border: 1px solid var(--hair);
}
.pc-thumb .pc-art {
  width: 100%;
  height: 100%;
  display: block;
  object-fit: cover;
}
.pc-btns {
  display: flex;
  gap: 8px;
  flex-wrap: wrap;
  margin-bottom: 6px;
}
.pc-tiles {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 10px;
}
.pc-tile {
  padding: 0;
  border: 2px solid var(--hair);
  border-radius: 8px;
  background: var(--card);
  color: var(--text);
  cursor: pointer;
  overflow: hidden;
  text-align: left;
  font: inherit;
}
.pc-tile.on {
  border-color: var(--accent);
  box-shadow: 0 0 0 2px var(--info-bg);
}
.pc-tile .pc-art {
  width: 100%;
  height: 96px;
  display: block;
  object-fit: cover;
}
.pc-tile span {
  display: block;
  padding: 6px 9px;
  font-size: 12.5px;
}
.cm-feed .cm-main {
  flex: 1;
  min-width: 0;
}
.cm-top {
  display: flex;
  gap: 10px;
  align-items: baseline;
}
.cm-text {
  margin-top: 2px;
  line-height: 1.45;
  overflow-wrap: anywhere;
}
.cm-chip {
  margin-top: 6px;
  display: inline-flex;
  align-items: center;
  gap: 4px;
}
.cm-foot {
  padding: 10px 18px;
  font-size: 11.5px;
  border-top: 1px solid var(--hair);
}
.cm-add {
  padding: 14px 18px;
  border-top: 1px solid var(--hair);
  background: var(--sunk);
}
.cm-addhead {
  display: flex;
  flex-wrap: wrap;
  gap: 4px 12px;
  align-items: baseline;
  margin-bottom: 8px;
  font-size: 13px;
}
.cm-addrow {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  align-items: center;
}
.cm-in {
  flex: 1 1 220px;
  min-width: 0;
}
.cm-ph {
  font-size: 12.5px;
  display: flex;
  gap: 5px;
  align-items: center;
}
@media (max-width: 900px) {
  .pc-agrid {
    grid-template-columns: 1fr;
  }
  .pc-body {
    grid-template-columns: 1fr;
    padding: 8px 16px 18px;
  }
  .pc-body section:nth-child(2) {
    grid-row: auto;
  }
}
@media (max-width: 600px) {
  .pc-hero {
    height: 180px;
  }
  .pc-top {
    padding: 12px 16px;
  }
  .cm-card .card-head .right {
    width: 100%;
  }
}

/* ---------- phone (m6) ---------- */
@media (max-width: 768px) {
  .pc-chrome {
    gap: 8px;
  }
  .pc-info {
    flex: 1 1 100%;
  }
  .pc-chrome .btn,
  .pc-btns .btn,
  .cm-addrow .btn,
  .cm-card .card-head .btn,
  .cm-card .card-head .sel {
    min-height: 44px;
    padding-left: 14px;
    padding-right: 14px;
  }
  .pc-chrome .btn {
    flex: 1 1 auto;
  }
  .pc-frame {
    border-radius: 8px;
  }
  .pc-herotxt h3 {
    font-size: 19px;
    overflow-wrap: anywhere;
  }
  .pc-top {
    flex-direction: column;
    gap: 2px;
  }
  .pc-ms li {
    grid-template-columns: 12px 1fr;
  }
  .pc-ms .st {
    grid-column: 2;
    grid-row: auto;
  }
  .pc-pics {
    grid-template-columns: repeat(2, 1fr);
  }
  .pc-admin {
    padding: 12px;
  }
  .pc-tiles {
    gap: 8px;
  }
  .pc-tile {
    min-height: 44px;
  }
  .cm-card .card-head .right {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
  }
  .cm-card .card-head .right > * {
    flex: 1 1 130px;
  }
  .cm-feed li {
    padding: 12px 14px;
  }
  .cm-top {
    flex-wrap: wrap;
    gap: 2px 10px;
  }
  .cm-foot a,
  .cm-addhead a,
  .cm-card .empty .tiny a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
  }
  .cm-add {
    padding: 14px;
  }
  .cm-addrow {
    flex-direction: column;
    align-items: stretch;
    gap: 10px;
  }
  .cm-addrow > * {
    width: 100%;
  }
  .cm-addrow .sel {
    min-height: 44px;
  }
  .cm-in,
  .cm-addrow input[type='text'],
  .cm-addrow input:not([type]) {
    flex: none;
    min-height: 44px;
    font-size: 16px;
  }
  .cm-ph {
    min-height: 44px;
    font-size: 14px;
    gap: 10px;
  }
  .cm-ph input {
    width: 22px;
    height: 22px;
    margin: 0;
  }
}
/* F14D2: the How Comms works link is a 44px target on touch widths including 768 */
@media (max-width: 900px) {
  .cm-foot a {
    display: inline-flex;
    align-items: center;
    min-height: 44px;
  }
}
/* F16F2: the homeowner page follows HQ's theme in the real app (app.js:8438), so dark mode gets a dark page, not a white slab */
:root[data-theme='dark'] .pc-frame {
  background: #1b2226;
  color: #e6ebed;
  opacity: 1;
}
:root[data-theme='dark'] .pc-body h4,
:root[data-theme='dark'] .pc-dim,
:root[data-theme='dark'] .pc-ms .dt,
:root[data-theme='dark'] .pc-ms .st,
:root[data-theme='dark'] .pc-pics figcaption {
  color: #a6b1b7;
}
:root[data-theme='dark'] .pc-ms li {
  border-bottom-color: #2c363b;
}
:root[data-theme='dark'] .pc-wait {
  background: #2e2a1f;
}
:root[data-theme='dark'] .pc-wait em {
  color: #d9b66b;
}
