/* My Home dashboard - zipBuilder design language */
:root {
  --navy: #0b3b7a;
  --deep: #072a58;
  --red: #c8102e;
  --red-dark: #a30d26;
  --bg: #f3f7fb;
  --line: #dde7f2;
  --ink: #1c2b3a;
  --muted: #5c6c7e;
  --radius: 14px;
  --shadow-sm: 0 1px 2px rgba(11,59,122,.06), 0 2px 8px rgba(11,59,122,.06);
  --shadow-md: 0 4px 14px rgba(11,59,122,.10), 0 10px 32px rgba(11,59,122,.08);
  --font-head: "Rubik","Segoe UI",Arial,sans-serif;
  --font-body: "Open Sans","Segoe UI",Arial,sans-serif;
}
* { box-sizing: border-box; }
html { overflow-y: scroll; scrollbar-gutter: stable; } /* no sideways hop between short and tall pages */
body { margin: 0; background: var(--bg); color: var(--ink); font-family: var(--font-body); font-size: 16px; line-height: 1.55; }
h1,h2,h3 { font-family: var(--font-head); color: var(--navy); margin: 0 0 .4rem; line-height: 1.2; }
h1 { font-size: clamp(1.6rem, 3vw, 2.2rem); }
h2 { font-size: 1.25rem; }
h3 { font-size: 1.02rem; }
a { color: var(--navy); }
p { margin: .35rem 0; }
code { background: #eef3f9; padding: .1rem .4rem; border-radius: 6px; font-size: .85em; }

.mh-container { max-width: 1080px; margin: 0 auto; padding: 0 1.25rem; }
.mh-wide { max-width: 1280px; }

.mh-header { background: linear-gradient(135deg, var(--navy), var(--deep)); color: #fff; }
.mh-header-inner { display: flex; align-items: center; justify-content: space-between; gap: 1rem; padding: 1.05rem 1.25rem; flex-wrap: wrap; }
.brand { font-family: var(--font-head); font-weight: 700; font-size: 1.5rem; color: #fff; text-decoration: none; }
.brand .zip { color: #ff5a72; }
.mh-tag { font-size: .8rem; font-weight: 500; opacity: .85; border: 1px solid rgba(255,255,255,.35); border-radius: 999px; padding: .1rem .6rem; margin-left: .4rem; vertical-align: middle; }
.mh-nav { display: flex; align-items: center; gap: 1rem; flex-wrap: wrap; }
.mh-nav a { color: rgba(255,255,255,.9); text-decoration: none; font-size: .95rem; }
.mh-nav a.on { color: #fff; font-weight: 600; border-bottom: 2px solid #ff5a72; }
.mh-nav .who { color: rgba(255,255,255,.7); font-size: .85rem; }

.id-strip {
  background: #e9f0f9;
  border-bottom: 1px solid var(--line);
  font-family: var(--font-head);
  font-size: .85rem;
  font-weight: 400;
  color: var(--navy);
  text-align: right;
}
.id-strip .mh-container { padding-top: .45rem; padding-bottom: .45rem; }
.id-strip .sep { color: var(--muted); margin: 0 .5rem; font-weight: 400; }

main.mh-container { padding: 2.25rem 1.25rem 3rem; }
.page-head { margin-bottom: 2rem; }
.page-head .sub { color: var(--muted); max-width: 720px; margin-bottom: 0; }
.muted-h { color: var(--muted); font-weight: 400; font-size: .8em; }
.crumbs { font-size: .85rem; color: var(--muted); }
.report-head { display: flex; justify-content: space-between; align-items: flex-end; gap: 1rem; flex-wrap: wrap; }

.panel { background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-sm); padding: 1.5rem; margin-bottom: 1.5rem; }
.panel-head { display: flex; justify-content: space-between; align-items: baseline; gap: 1rem; flex-wrap: wrap; margin-bottom: .75rem; }
.panel-actions { display: flex; gap: .5rem; flex-wrap: wrap; }
.proj-actions { flex-direction: column; align-items: flex-end; gap: .6rem; margin-top: .4rem; }
.proj-head { align-items: flex-start; }
.pa-row { display: flex; align-items: center; gap: .75rem; }
.sel-label { display: inline-flex; align-items: center; gap: .45rem; font-size: .85rem; font-weight: 600; color: var(--navy); }
.sel-label select { font: inherit; font-size: .9rem; padding: .42rem .55rem; border-radius: 8px; border: 1px solid var(--line); background: #fff; }
.collapse-btn { width: 34px; height: 34px; border: 1px solid var(--line); border-radius: 8px; background: #eef3fa;
  color: var(--navy); font-size: .8rem; line-height: 1; cursor: pointer; }
.collapse-btn:hover { background: var(--navy); color: #fff; border-color: var(--navy); }
.panel.collapsed .proj-body { display: none; }
.panel.collapsed .panel-head { margin-bottom: 0; }

.btn { display: inline-block; border-radius: 10px; padding: .5rem 1rem; font-family: var(--font-head); font-weight: 600; font-size: .92rem; text-decoration: none; cursor: pointer; border: 1px solid transparent; }
.btn-red { background: var(--red); color: #fff; }
.btn-red:hover { background: var(--red-dark); }
.btn-outline { background: #fff; color: var(--navy); border-color: var(--line); }
.btn-outline:hover { border-color: var(--navy); }
.btn-lg { padding: .7rem 1.4rem; width: 100%; }
.btn-x { background: none; border: none; color: var(--muted); font-size: 1.1rem; cursor: pointer; padding: 0 .3rem; }
.btn-x:hover { color: var(--red); }
.inline { display: inline; }

.note { border-radius: 10px; padding: .6rem 1rem; margin-bottom: 1rem; font-size: .95rem; }
.note.ok { background: #e8f6ec; border: 1px solid #bfe4c8; color: #14532d; }
.note.err { background: #fdecee; border: 1px solid #f5c2c9; color: #7f1d1d; }

.stat-row { display: grid; grid-template-columns: repeat(auto-fit, minmax(140px, 1fr)); gap: .75rem; margin: .75rem 0 1rem; }
.stat { background: var(--bg); border: 1px solid var(--line); border-radius: 10px; padding: .7rem .9rem; text-decoration: none; color: var(--ink); font-size: .85rem; }
.stat .n { display: block; font-family: var(--font-head); font-weight: 700; font-size: 1.3rem; color: var(--navy); }

.two-col { display: grid; grid-template-columns: 1fr 1fr; gap: 1.5rem; }
.list-card { display: flex; flex-direction: column; }

.card-link {
  margin-top: auto;
  margin-left: auto;
  padding-top: .9rem;
  font-family: var(--font-head);
  font-weight: 600;
  font-size: .9rem;
  color: var(--red);
  text-decoration: none;
}
.card-link:hover { color: var(--red-dark); text-decoration: underline; }


/* section mini-titles inside panels: kicker treatment so page parts announce themselves */
.panel h3 {
  font-size: 1.25rem;
  color: var(--navy);
  margin: 0 0 .5rem;
  padding-bottom: .5rem;
  border-bottom: 2px solid var(--line);
}

.ti { vertical-align: -3px; margin-right: .4rem; }

.mini-list { list-style: none; margin: .3rem 0 0; padding: 0; }
.mini-list li { padding: .35rem 0; border-bottom: 1px solid var(--line); font-size: .93rem; }

.tag { display: inline-block; background: #eef3f9; color: var(--navy); border-radius: 999px; padding: .05rem .6rem; font-size: .78rem; font-weight: 600; }
.tag-repair, .tag-spam { background: #fdecee; color: var(--red-dark); }
.tag-install, .tag-sold { background: #e8f6ec; color: #14532d; }
.tag-inspection, .tag-routed { background: #fff7e6; color: #92400e; }
.tag-sale, .tag-appraisal { background: #ede9fe; color: #5b21b6; }

.grid-form { display: grid; grid-template-columns: repeat(auto-fit, minmax(200px, 1fr)); gap: .8rem 1rem; align-items: end; }
.grid-form label { display: flex; flex-direction: column; font-size: .82rem; font-weight: 600; color: var(--muted); gap: .25rem; }
.grid-form label.short { max-width: 160px; }
.grid-form label.full { grid-column: 1 / -1; }
.grid-form input, .grid-form select, .grid-form textarea {
  font: inherit; font-size: .95rem; padding: .5rem .65rem; border: 1px solid var(--line); border-radius: 8px; background: #fff; color: var(--ink); }
.grid-form textarea { min-height: 70px; resize: vertical; }
.grid-form input:focus, .grid-form select:focus, .grid-form textarea:focus { outline: 2px solid rgba(11,59,122,.25); }
.grid-form button { justify-self: start; }

.tabbar { display: flex; gap: .5rem; margin-bottom: 1rem; flex-wrap: wrap; }
.tab {
  font-family: var(--font-head); font-weight: 600; font-size: .95rem;
  color: var(--navy); text-decoration: none; background: #fff;
  border: 1px solid var(--line); border-radius: 10px 10px 0 0; padding: .5rem 1.1rem;
}
.tab.on { background: var(--navy); color: #fff; border-color: var(--navy); }
.tab .count { background: rgba(200,16,46,.12); color: var(--red); border-radius: 999px; padding: 0 .5rem; font-size: .8rem; margin-left: .25rem; }
.tab.on .count { background: rgba(255,255,255,.2); color: #fff; }

.bell-link { position: relative; display: inline-flex; color: rgba(255,255,255,.9); }
.bell-link.on { color: #fff; }
.dot-badge {
  position: absolute; top: -2px; right: -3px; width: 9px; height: 9px;
  background: #ff5a72; border-radius: 50%; border: 2px solid var(--deep);
}

.bell-wrap { position: relative; display: inline-flex; }
.bell-menu {
  display: none; position: absolute; left: 50%; transform: translateX(-50%);
  top: 100%; padding-top: 12px; width: 320px; z-index: 50;
}
.bell-wrap.open .bell-menu { display: block; }
.bell-menu-box {
  background: #fff; border: 1px solid var(--line);
  border-radius: 12px; box-shadow: var(--shadow-md); overflow: hidden;
}
.bm-item {
  display: flex; align-items: center; gap: .5rem; padding: .6rem .9rem;
  text-decoration: none; color: var(--ink); font-size: .85rem;
  border-bottom: 1px solid var(--line);
}
.bm-item:hover { background: var(--bg); }
.bm-item.unread { background: #f6f9ff; }
.bm-dot { width: 8px; height: 8px; background: var(--red); border-radius: 50%; flex-shrink: 0; }
.bm-title { flex: 1; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.bm-time { color: var(--muted); font-size: .75rem; white-space: nowrap; }
.bm-empty { padding: .9rem; color: var(--muted); font-size: .85rem; text-align: center; }
.bm-all {
  display: block; padding: .6rem .9rem; text-align: center; text-decoration: none;
  font-family: var(--font-head); font-weight: 600; font-size: .85rem; color: var(--red);
}
.bm-all:hover { background: var(--bg); }

.notif-list { list-style: none; margin: 0; padding: 0; }
.notif-list li { display: flex; align-items: flex-start; gap: .8rem; padding: .8rem 0; border-bottom: 1px solid var(--line); }
.notif-list li.unread { background: #f6f9ff; margin: 0 -1.5rem; padding: .8rem 1.5rem; }
.notif-list .notif-body { flex: 1; }
.notif-list .btn { white-space: nowrap; }
.tag-lead { background: #e8f0fb; color: var(--navy); }
.tag-info { background: #eef3f9; color: var(--muted); }

.locked { color: var(--muted); font-size: .85rem; font-style: italic; }
.nowrap { white-space: nowrap; }

.consent { display: flex; gap: .5rem; align-items: flex-start; font-size: .85rem !important; font-weight: 400 !important; }
.consent input { margin-top: .2rem; }

.legal h3 { border-bottom: none; padding-bottom: 0; margin-top: 1.25rem; font-size: 1.05rem; }
.legal p { color: var(--ink); }

.table { width: 100%; border-collapse: collapse; font-size: .92rem; }
.table th { text-align: left; color: var(--muted); font-size: .78rem; text-transform: uppercase; letter-spacing: .04em; padding: .4rem .6rem; border-bottom: 2px solid var(--line); }
.table td { padding: .55rem .6rem; border-bottom: 1px solid var(--line); vertical-align: top; }
.table tr:last-child td { border-bottom: none; }
.table tr.overdue td { background: #fff8f8; }
.small { font-size: .85rem; }
.muted { color: var(--muted); }

.timeline { position: relative; }
.tl-item { display: grid; grid-template-columns: 120px 1fr; gap: 1rem; padding: .9rem 0; border-bottom: 1px solid var(--line); }
.tl-item:last-child { border-bottom: none; }
.tl-date { color: var(--muted); font-size: .88rem; font-weight: 600; padding-top: .1rem; }
.tl-top { display: flex; align-items: center; gap: .6rem; flex-wrap: wrap; }
.tl-top .cost { margin-left: auto; font-family: var(--font-head); font-weight: 700; color: var(--navy); }
.tl-actions { display: flex; gap: 1rem; align-items: center; margin-top: .3rem; font-size: .85rem; }
.doc-chip { display: inline-block; background: var(--bg); border: 1px solid var(--line); border-radius: 999px; padding: .1rem .7rem; font-size: .8rem; text-decoration: none; margin-top: .3rem; }

.cal-grid { display: grid; grid-template-columns: repeat(7, 1fr); gap: 4px; }
.cal-head { text-align: center; font-size: .75rem; font-weight: 700; color: var(--muted); padding: .3rem 0; }
.cal-cell { min-height: 84px; background: var(--bg); border: 1px solid var(--line); border-radius: 8px; padding: .3rem; font-size: .78rem; }
.cal-cell.empty { background: transparent; border: none; }
.cal-cell.today { outline: 2px solid var(--red); }
.cal-cell .d { font-weight: 700; color: var(--muted); }
.cal-dot { display: block; background: var(--navy); color: #fff; border-radius: 6px; padding: .05rem .4rem; margin-top: .2rem; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.cal-dot.done { background: #9fb4cc; text-decoration: line-through; }

/* ---------- Project Gantt ---------- */
.gantt { font-size: .8rem; overflow-x: auto; }
.g-row { display: grid; grid-template-columns: 140px 1fr; align-items: center; min-height: 34px; border-bottom: 1px solid var(--line); }
.g-row:last-child { border-bottom: none; }
.g-headrow { min-height: 24px; border-bottom: 2px solid var(--line); }
.g-label { font-family: var(--font-head); font-weight: 600; color: var(--navy); text-decoration: none;
  overflow: hidden; text-overflow: ellipsis; white-space: nowrap; padding-right: .6rem; }
.g-track { position: relative; height: 26px; background:
  repeating-linear-gradient(to right, transparent, transparent calc(100% / 6 - 1px), var(--line) calc(100% / 6 - 1px), var(--line) calc(100% / 6)); }
.g-head { background: none; height: 18px; }
.g-tick { position: absolute; top: 0; transform: translateX(-50%); color: var(--muted); font-size: .7rem; white-space: nowrap; }
.g-bar { position: absolute; top: 3px; height: 20px; border-radius: 5px; color: #fff; text-decoration: none;
  font-size: .7rem; line-height: 20px; padding: 0 .4rem; overflow: hidden; white-space: nowrap; text-overflow: ellipsis;
  background: var(--navy); box-shadow: var(--shadow-sm); }
.g-bar.s-proposed { background: #fff; color: var(--navy); border: 2px dashed var(--navy); line-height: 16px; }
.g-bar.s-done { background: #2e8b57; }
.g-bar.s-internal { background: #9fb4cc; color: #fff; }
.g-today { position: absolute; top: 0; bottom: 0; width: 2px; background: var(--red); opacity: .65; z-index: 2; }

.cal-dot.proj { background: #2e8b57; }
.cal-dot.proj.done { background: #9cc9ae; }

.auth-card { max-width: 420px; margin: 3rem auto; background: #fff; border: 1px solid var(--line); border-radius: var(--radius); box-shadow: var(--shadow-md); padding: 2rem; }
.auth-card h1 { font-size: 1.4rem; }
.auth-card .sub { color: var(--muted); font-size: .95rem; margin-bottom: 1rem; }
.auth-card form { display: flex; flex-direction: column; gap: .9rem; }
.auth-card label { display: flex; flex-direction: column; gap: .25rem; font-size: .82rem; font-weight: 600; color: var(--muted); }
.auth-card input { font: inherit; padding: .6rem .7rem; border: 1px solid var(--line); border-radius: 8px; }
.auth-card .swap { font-size: .9rem; color: var(--muted); margin-top: 1rem; }

.picker select { font: inherit; font-size: .9rem; padding: .3rem .5rem; border-radius: 8px; border: 1px solid var(--line); }
.route-form { display: flex; gap: .3rem; align-items: center; margin-top: .3rem; flex-wrap: wrap; }
.route-form select { max-width: 160px; font-size: .85rem; }
.route-form .price { width: 70px; font-size: .85rem; }
.route-form select, .route-form input { padding: .3rem .4rem; border: 1px solid var(--line); border-radius: 6px; }

.mh-footer { border-top: 1px solid var(--line); color: var(--muted); font-size: .85rem; padding: 1.2rem 0 2rem; background: #fff; }
.add-panel h2 { margin-bottom: .8rem; }

@media (max-width: 760px) {
  .two-col { grid-template-columns: 1fr; }
  .tl-item { grid-template-columns: 1fr; gap: .2rem; }
  .cal-cell { min-height: 56px; }
  .cal-dot { display: none; }
  .cal-cell.today { background: #fdecee; }
}
@media print {
  .mh-header, .mh-footer, .btn, .panel-actions { display: none !important; }
  .panel { box-shadow: none; border-color: #ccc; break-inside: avoid; }
  body { background: #fff; }
}

/* ============================================================
   Console layer (Pro sweep, 2026-07-17): ported from the
   homeowner console pass so both shells speak one language.
   Dense zebra tables, pills, glyph chips, stat tiles, modals.
   ============================================================ */
.panel-flush { padding: 4px 10px; }
.mtable { width:100%; border-collapse:collapse; font-size:13.5px; }
.mtable th { text-align:left; font-size:10.5px; font-weight:800; text-transform:uppercase; letter-spacing:.06em;
  color:var(--muted); padding:9px 10px 7px; border-bottom:1.5px solid var(--line); font-family:var(--font-head); }
.mtable td { padding:7px 10px; border-bottom:1px solid #edf2f8; vertical-align:middle; }
.mtable tbody tr:last-child td { border-bottom:none; }
.mtable tbody tr:nth-child(even) td { background:#f7fafc; }
.mtable tbody tr:hover td { background:#eef4fb; }
.mtable tbody tr.r-over td { background:#fdf1f3; }
.mtable tbody tr.r-over:hover td { background:#fbe9ec; }
.mtable .t-name { font-weight:600; }
.mtable .t-notes { color:var(--muted); font-size:11.5px; margin-top:1px; }
.mtable td.num, .mtable th.num { text-align:right; white-space:nowrap; }
.mtable.facts .f-k { color:var(--muted); font-weight:600; width:180px; }
.mtable.facts td { padding:6px 10px; }
.mtable.facts tbody tr:nth-child(even) td { background:transparent; }
.mtable tr.add-row td { background:#fbfdfe !important; border-bottom:none; padding:6px 10px; }
.mtable.inner { font-size:12.5px; }
.mtable.inner th { font-size:10px; }
.mtable.inner tbody tr:nth-child(even) td { background:transparent; }
tr.detail-row > td { background:#f7fafd !important; padding:12px 16px 14px; }
.nowrap { white-space:nowrap; }
@media(max-width:700px){ .mtable .hide-m, .mtable th.hide-m { display:none; } }

.pill { display:inline-block; border-radius:999px; padding:2px 10px; font-size:11.5px; font-weight:700; white-space:nowrap; }
.pill-red{background:#fbe9ec;color:var(--red);}
.pill-amber{background:#fdf3e0;color:#92400e;}
.pill-green{background:#e5f4ea;color:#14532d;}
.pill-navy{background:#e8f0f9;color:var(--navy);}
.pill-gray{background:#eef2f6;color:var(--muted);}
h1 .pill { vertical-align:middle; margin-left:10px; }
.head-pills { display:flex; gap:8px; flex-wrap:wrap; align-items:center; }
.page-head-row { display:flex; justify-content:space-between; align-items:flex-start; gap:1rem; flex-wrap:wrap; margin-bottom:2rem; }
.page-head-row .page-head { margin-bottom:0; }

.gchip { display:inline-flex; align-items:center; gap:5px; border-radius:999px; padding:2px 9px;
  font-size:11.5px; font-weight:700; white-space:nowrap; }
.gchip svg { flex-shrink:0; }
.gchip-red{background:#fbe9ec;color:var(--red);}
.gchip-amber{background:#fdf3e0;color:#92400e;}
.gchip-navy{background:#e8f0f9;color:var(--navy);}
.gchip-gray{background:#eef2f6;color:var(--muted);}
.gchip-green{background:#e5f4ea;color:#14532d;}
.gchip-purple{background:#ede9fe;color:#5b21b6;}

.btn-done { padding:3px 11px; font-size:12px; border-radius:7px; border:1px solid var(--line); background:#fff; color:var(--navy); font-family:var(--font-head); font-weight:600; cursor:pointer; }
.btn-done:hover { border-color:var(--navy); }
.btn-done.btn-red { background:var(--red); border-color:var(--red); color:#fff; }
.btn-done.btn-red:hover { background:var(--red-dark); }
.btn-sm { padding:.3rem .8rem; font-size:.85rem; }
.row-actions { display:flex; gap:6px; justify-content:flex-end; align-items:center; }
.btn-addline { border:1px solid var(--line); background:#fff; color:var(--navy);
  font-size:12px; font-weight:700; padding:4px 12px; border-radius:8px; cursor:pointer; font-family:var(--font-head); }
.btn-addline:hover { background:#e8f0f9; border-color:#c5d5e8; }
.caret-btn { transition:transform .15s; }
.caret-btn.open { transform:rotate(180deg); }
.locked-pill { display:inline-block; background:#eef2f6; color:var(--muted); border:1px dashed #c9d6e4;
  border-radius:8px; padding:3px 10px; font-size:11.5px; font-weight:600; }

.stat-row .stat .lbl { font-size:.72rem; color:var(--muted); font-weight:600; }
.stat.stat-warn { border-color:#f2cf9d; background:#fffaf1; }
.stat.stat-warn .n { color:#92400e; }
.stat.stat-alert { border-color:#f0b6c0; background:#fdf4f5; }
.stat.stat-alert .n { color:var(--red); }

.empty { text-align:center; color:var(--muted); font-size:14px; padding:34px 16px; }
.empty strong { display:block; color:var(--ink); font-size:15px; margin-bottom:4px; font-family:var(--font-head); }
.empty .btn { margin-top:12px; }

.overlay { display:none; position:fixed; inset:0; background:rgba(7,42,88,.45); z-index:90;
  align-items:center; justify-content:center; padding:18px; }
.overlay.open { display:flex; }
.modal { background:#fff; border-radius:14px; box-shadow:0 24px 70px rgba(7,42,88,.35);
  width:100%; max-width:460px; padding:22px 24px; max-height:92vh; overflow:auto; }
.modal h3 { font-size:17px; font-weight:800; color:var(--deep); margin:0 0 16px; padding:0; border:none; }
.frow { margin-bottom:12px; }
.frow label { display:block; font-size:12px; font-weight:700; color:var(--muted); margin-bottom:4px; letter-spacing:.02em; }
.frow input, .frow select, .frow textarea { width:100%; font:inherit; font-size:14px; padding:8px 10px;
  border:1px solid var(--line); border-radius:8px; background:#fff; color:var(--ink); }
.frow input:focus, .frow select:focus, .frow textarea:focus { outline:2px solid rgba(11,59,122,.25); }
.frow textarea { resize:vertical; min-height:64px; }
.frow2 { display:grid; grid-template-columns:1fr 1fr; gap:12px; }
.frow3 { display:grid; grid-template-columns:1fr 1fr 1fr; gap:12px; }
.modal-actions { display:flex; justify-content:flex-end; gap:9px; margin-top:18px; }

.consent-line { display:flex; gap:9px; align-items:flex-start; font-size:13.5px; padding:6px 0; }
.consent-line input { margin-top:3px; }
.chips { display:flex; gap:6px; flex-wrap:wrap; }
.chips .tag { font-size:.8rem; }
.desc-block { font-size:13.5px; color:var(--ink); background:var(--bg); border:1px solid var(--line);
  border-radius:10px; padding:10px 14px; }
.contact-line a { text-decoration:none; }

/* flush-panel headers (title + hint on one line) */
.prop-panel-head { display:flex; align-items:baseline; gap:12px; flex-wrap:wrap; padding:12px 10px 4px; }
.prop-panel-head .p-title { font-weight:800; font-size:14px; color:var(--deep); font-family:var(--font-head); }
.prop-panel-head .btn, .prop-panel-head .btn-addline { margin-left:auto; }

/* ---------- contractor schedule: month-grid pills + hover cards ----------
   Status colours deliberately match the Gantt bars above (.g-bar.s-*) so the
   same job reads identically in the month view and inside a project card. */
/* `repeat(7, 1fr)` above resolves to minmax(auto, 1fr), so a single long
   nowrap pill title sets the min-content width of every column and the grid
   overflows its panel. minmax(0, 1fr) + min-width:0 lets columns shrink and
   hands the truncation back to the pill's own ellipsis. */
.cal-grid { grid-template-columns: repeat(7, minmax(0, 1fr)); }
.cal-cell { min-width: 0; }
.cal-daynum { display:block; font-size:.72rem; font-weight:700; color:var(--muted); }
.cal-cell.today .cal-daynum { color:var(--red); }
.cal-item { position:relative; display:block; max-width:100%; margin-top:.18rem;
  text-decoration:none; color:inherit; }
.cal-pill { display:block; font-size:.68rem; font-weight:700; line-height:1.35; border-radius:6px;
  padding:1px 6px; white-space:nowrap; overflow:hidden; text-overflow:ellipsis;
  color:#fff; background:var(--navy); max-width:100%; }
.cal-pill.s-proposed { background:#fff; color:var(--navy); border:1px dashed var(--navy); padding:0 5px; }
.cal-pill.s-done { background:#2e8b57; }
.cal-pill.s-internal { background:#9fb4cc; }
.cal-more { display:block; font-size:.68rem; font-weight:700; color:var(--muted); margin-top:.15rem; }
.cal-pop { display:none; position:absolute; left:0; top:calc(100% + 4px); z-index:70; width:232px;
  background:#fff; border:1px solid var(--line); border-radius:10px; box-shadow:var(--shadow-md);
  padding:10px 12px; white-space:normal; }
.cal-item:hover .cal-pop { display:block; }
.cal-pop .p-title { display:block; font-weight:700; font-size:.78rem; color:var(--deep); }
.cal-pop .p-line { display:block; font-size:.72rem; color:var(--muted); margin-top:2px; }
/* the 7 .cal-head cells are also grid children, and 7 is a whole row, so this
   modular arithmetic still lands on the last two columns. Flip the card inward
   there so it never runs off the right edge. */
.cal-grid > .cal-cell:nth-child(7n) .cal-pop,
.cal-grid > .cal-cell:nth-child(7n-1) .cal-pop { left:auto; right:0; }
.cal-legend { display:flex; gap:1rem; flex-wrap:wrap; align-items:center;
  font-size:.72rem; color:var(--muted); margin-top:.7rem; }
.cal-legend .k { display:inline-block; width:10px; height:10px; border-radius:3px;
  margin-right:.35rem; vertical-align:-1px; }
.cal-legend .k.s-confirmed { background:var(--navy); }
.cal-legend .k.s-proposed { background:#fff; border:1px dashed var(--navy); }
.cal-legend .k.s-done { background:#2e8b57; }
.cal-legend .k.s-internal { background:#9fb4cc; }
@media (max-width: 780px) {
  .cal-cell { min-height:64px; }
  .cal-pop { display:none !important; }   /* hover cards are useless on touch */
}
