/* Sidebar sections (Map, Deals, Relationships) and the pages they open. Loaded last, after ui22.css. */

/* The sidebar: quiet rows, one marked as where you are */
.side .side-people { border: 0; background: none; margin: 0; padding: 8px 10px; border-radius: 8px; font-size: 13.5px; font-weight: 500; color: var(--ink-2); }
.side .side-people + .side-people { margin-top: 0; }
.side .side-people:hover { background: rgba(28, 34, 48, .05); border: 0; }
.side .side-people[aria-current="page"] { background: #fff; color: var(--ink); box-shadow: 0 0 0 1px var(--line); }
.side .side-people svg { color: var(--mute); flex: none; }
.side .side-people[aria-current="page"] svg { color: var(--blue); }
.side-n-quiet { background: none; color: var(--mute); padding: 0; font-weight: 400; }

/* A card shown as a page: it fills the space beside the sidebar instead of floating over the map */
@media (min-width: 821px) {
  .ppl-card.as-page { top: 0; bottom: 0; left: 256px; right: 0; width: auto; max-width: none; max-height: none; margin: 0; transform: none; border: 0; border-left: 1px solid var(--line); border-radius: 0; box-shadow: none; background: var(--bg); }
  body.no-side .ppl-card.as-page { left: 0; }
  #ibScrim, #pplScrim, #dlScrim { display: none; }
  .ppl-card.as-page .ppl-card-h, .ppl-card.as-page .ppl-card-b { padding-left: max(32px, calc((100% - 1040px) / 2)); padding-right: max(32px, calc((100% - 1040px) / 2)); }
  .ppl-card.as-page .ppl-card-h { padding-top: 30px; }
}

/* Deals */
.dl-search { display: block; width: 100%; max-width: 360px; margin: 4px 0 18px; }
.dl-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(230px, 1fr)); gap: 18px; }
.dl-card { display: grid; gap: 2px; align-content: start; text-align: left; font: inherit; color: var(--ink); text-decoration: none; background: #fff; border: 1px solid var(--line); border-radius: 14px; padding: 0 0 14px; overflow: hidden; cursor: pointer; transition: border-color .15s, transform .15s; }
.dl-card:hover { border-color: var(--blue); transform: translateY(-1px); }
.dl-card:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
.dl-img { display: grid; place-items: center; aspect-ratio: 16 / 10; margin-bottom: 10px; background: #e9e6dd center / cover no-repeat; font: 500 34px var(--serif, Georgia, serif); color: #b9b4a6; }
.dl-card b { font: 500 17px/1.25 var(--serif, Georgia, serif); padding: 0 14px; }
.dl-meta { font-size: 12.5px; color: var(--mute); padding: 0 14px; min-height: 1.2em; }
.dl-price { font-size: 13.5px; font-weight: 600; padding: 4px 14px 0; font-variant-numeric: tabular-nums; }

/* Relationships */
.rel-top { display: grid; gap: 16px; margin: 4px 0 22px; }
.rel-figs { display: grid; grid-template-columns: repeat(3, minmax(0, 1fr)); background: #fff; border: 1px solid var(--line); border-radius: 12px; }
.rel-figs > div { display: grid; gap: 1px; padding: 14px 16px; border-left: 1px solid var(--line); min-width: 0; }
.rel-figs > div:first-child { border-left: 0; }
.rel-figs small { font-size: 12px; color: var(--mute); }
.rel-figs b { font: 500 26px/1.15 var(--serif, Georgia, serif); font-variant-numeric: tabular-nums; }
.rel-figs span { font-size: 12px; color: var(--mute); }
.rel-board { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 10px; }
.rel-col { display: grid; gap: 6px; align-content: start; background: rgba(28, 34, 48, .035); border-radius: 12px; padding: 8px; min-width: 0; }
.rel-col.on { box-shadow: inset 0 0 0 1.5px var(--blue); background: var(--blue-soft); }
.rel-colh { display: flex; justify-content: space-between; align-items: baseline; gap: 6px; font: inherit; font-size: 12px; font-weight: 600; color: var(--ink-2); background: none; border: 0; padding: 2px 4px 4px; cursor: pointer; text-align: left; }
.rel-colh em { font-style: normal; font-weight: 400; color: var(--mute); font-variant-numeric: tabular-nums; }
.rel-p { display: grid; gap: 1px; text-align: left; font: inherit; background: #fff; border: 1px solid var(--line); border-radius: 9px; padding: 7px 9px; cursor: pointer; min-width: 0; }
.rel-p:hover { border-color: var(--blue); }
.rel-p.ready { box-shadow: inset 3px 0 0 var(--blue); }
.rel-p b { font-size: 13px; font-weight: 500; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.rel-p span { font-size: 11.5px; color: var(--mute); white-space: nowrap; overflow: hidden; text-overflow: ellipsis; min-height: 1.2em; }
.rel-due { font-style: normal; font-size: 11px; color: var(--warn, #a8661a); }
.rel-more { font: inherit; font-size: 12px; color: var(--blue); background: none; border: 0; padding: 2px 4px; text-align: left; cursor: pointer; }
.rel-colh:focus-visible, .rel-p:focus-visible, .rel-more:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
@media (max-width: 820px) {
  .rel-figs b { font-size: 21px; } .rel-figs > div { padding: 10px 11px; }
  .rel-board { grid-auto-flow: column; grid-auto-columns: 62%; grid-template-columns: none; overflow-x: auto; padding-bottom: 4px; scroll-snap-type: x proximity; }
  .rel-col { scroll-snap-align: start; }
  .dl-grid { grid-template-columns: 1fr 1fr; gap: 12px; } .dl-card b { font-size: 15px; }
}

/* One button opens and closes the menu. With the menu open it sits at the menu's top-right edge;
   with the menu closed it waits in the top-left corner of whatever screen you are on. */
.nav-toggle { display: none; }
@media (min-width: 821px) {
  .nav-toggle { display: grid; place-items: center; position: fixed; top: 12px; left: 214px; z-index: 75; width: 32px; height: 32px; border-radius: 8px; color: var(--mute); background: none; border: 0; cursor: pointer; transition: left .25s ease, background .15s, color .15s; }
  .nav-toggle:hover { background: rgba(28, 34, 48, .07); color: var(--ink); }
  .nav-toggle:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
  body.no-side .nav-toggle { left: 12px; background: #fff; color: var(--ink-2); box-shadow: 0 0 0 1px var(--line), 0 2px 8px -4px rgba(12, 29, 51, .35); }
  .side .side-top [data-toggle="side"], .show-side, .mapside { display: none !important; }
  .side .side-top { min-height: 32px; padding-right: 40px; }
  body.no-side .bar { padding-left: 56px; }
  body.no-side .ppl-card.as-page .ppl-card-h { padding-left: max(60px, calc((100% - 1040px) / 2)); }
  body.portfolio.no-side .pcard { margin-left: 44px; }
}

/* Today's quota: one number, on the Relationships page and in the sidebar */
.rel-week { display: grid; gap: 12px; background: #fff; border: 1px solid var(--line); border-radius: 12px; padding: 18px 20px 20px; }
.rel-q { display: flex; flex-wrap: wrap; align-items: baseline; gap: 4px 12px; }
.rel-q b { font: 500 46px/1 var(--serif, Georgia, serif); font-variant-numeric: tabular-nums; }
.rel-q b i { font-style: normal; color: var(--mute); }
.rel-q span { font-size: 15px; color: var(--ink-2); }
.rel-bar { display: block; height: 8px; background: var(--line); border-radius: 4px; overflow: hidden; }
.rel-bar > span { display: block; height: 100%; background: var(--blue); border-radius: 4px; transition: width .3s; }
.hit .rel-bar > span { background: var(--ink); }
.rel-owed { margin: 0; font-size: 12px; color: var(--mute); overflow-wrap: anywhere; }
.rel-owed .linkbtn { font-size: 12px; }
.side .side-quota { display: grid; gap: 7px; align-self: stretch; margin: 6px 10px 0; padding: 12px 0 2px; border: 0; border-top: 1px solid var(--line); border-radius: 0; background: none; text-align: left; font: inherit; font-size: 12.5px; color: var(--ink-2); cursor: pointer; }
.side .side-quota b { font: 500 19px/1 var(--serif, Georgia, serif); font-variant-numeric: tabular-nums; color: var(--ink); margin-right: 7px; }
.side .side-quota .rel-bar { height: 4px; }
.side .side-quota:focus-visible { outline: 2px solid var(--blue); outline-offset: 3px; }
@media (max-width: 560px) { .rel-week { padding: 14px 14px 16px; } .rel-q b { font-size: 38px; } }
@media (prefers-reduced-motion: reduce) { .rel-bar > span { transition: none; } }

/* The menu holds the sections and nothing else: deals live on the Deals page and as dots on the map, and Team is a
   quiet link at the foot. A shared link keeps its one deal in the list, because it has no Deals page. */
body:not(.share) .side #search, body:not(.share) .side #deals { display: none; }
.side .side-people[data-team-toggle] { display: none; }
.side-foot { margin-top: auto; align-self: flex-start; padding: 6px 10px; border: 0; border-radius: 8px; background: none; font: inherit; font-size: 12.5px; color: var(--mute); cursor: pointer; }
.side-foot:hover { background: rgba(28, 34, 48, .05); color: var(--ink); }
.side-foot:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
body:not(.share) .side .side-out, body:not(.share) .side .side-signin { margin-top: auto; }
.side .side-foot ~ .side-out, .side .side-foot ~ .side-signin { margin-top: 0; }

/* Account foot: your name, a gear for settings (owner) and Sign out. */
.side-out span { margin-right: auto; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.side-out .side-gear { display: grid; place-items: center; padding: 6px; border-radius: 8px; color: var(--mute); }
.side-out .side-gear:hover { background: rgba(28, 34, 48, .05); color: var(--ink); }
.side-out button:focus-visible { outline: 2px solid var(--blue); outline-offset: 2px; }
body.signed-out .side-out { display: none; }

/* ==== Shell polish (8 Oct) ==== */
/* Deals sits in the same frame as Relationships: same left edge, same title line, so the title does not jump between them */
@media (min-width: 821px) {
  #dlCard.as-page .ppl-card-h { align-items: center; padding-top: 24px; padding-bottom: 16px; }
  #dlCard.as-page .ppl-card-h, #dlCard.as-page .ppl-card-b { padding-left: max(28px, calc((100% - 1240px) / 2)); padding-right: max(28px, calc((100% - 1240px) / 2)); }
  body.no-side #dlCard.as-page .ppl-card-h { padding-left: max(60px, calc((100% - 1240px) / 2)); }
  /* the page glides with the menu instead of jumping while the menu slides */
  .ppl-card.as-page { transition: left .25s ease; }
  .dl-grid { grid-template-columns: repeat(auto-fill, minmax(220px, 1fr)); }
}
@media (prefers-reduced-motion: reduce) { .ppl-card.as-page, .nav-toggle, .side { transition: none !important; } }
/* painted from the first frame when the address says Deals (the class is set in the page head and taken off by nav.js) */
html.boot-deals #dlCard[hidden] { display: flex; }
html.boot-home body:not(.portfolio):not(.full) :is(.main, .resizer), html.boot-deals body:not(.portfolio):not(.full) :is(.main, .resizer) { display: none; }
html.boot-home body:not(.portfolio):not(.full) .mappane, html.boot-deals body:not(.portfolio):not(.full) .mappane { flex: 1; width: auto; max-width: none; margin: 0; }
html.boot-people :is(.main, .resizer, .mappane) { visibility: hidden; }
/* the search box: the same box as on Relationships, a frame that darkens, no blue ring */
.dl-search { max-width: 320px; height: 42px; margin: 0 0 18px; padding: 0 14px 0 39px; font-size: 14px; border: 0; border-radius: 12px; outline: 0; -webkit-appearance: none; appearance: none;
  box-shadow: inset 0 0 0 1px var(--line); transition: box-shadow .15s;
  background: #fff url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%237a8596' stroke-width='2' stroke-linecap='round'%3E%3Ccircle cx='11' cy='11' r='7'/%3E%3Cpath d='m20 20-3.5-3.5'/%3E%3C/svg%3E") 14px 50% / 15px no-repeat; }
.dl-search:focus, .dl-search:focus-visible { outline: 0; box-shadow: inset 0 0 0 1px var(--ink-2); }
.dl-grid > .ppl-empty { grid-column: 1 / -1; margin: 0; padding: 20px 0; }
.dl-card { transition: border-color .15s, box-shadow .15s; }
.dl-card:hover { transform: none; box-shadow: 0 6px 18px -12px rgba(12, 29, 51, .35); }
.dl-card b { overflow-wrap: anywhere; }
@media (hover: none) { .dl-card:hover { border-color: var(--line); box-shadow: none; } }  /* a tapped card does not stay lit on a touch screen */
/* New deal opens over the page you are on */
#ndScrim { z-index: 66; } .nd-card { z-index: 67; }
/* phone: the open menu dims what is behind it and sits above it */
#sideScrim { display: none; }
@media (max-width: 820px) {
  body.side-open #sideScrim { display: block; position: fixed; inset: 0; z-index: 64; background: rgba(15, 22, 36, .28); }
  body.side-closing:not(.side-open) #sideScrim { display: block; position: fixed; inset: 0; z-index: 64; background: none; }
  body.side-open .side { z-index: 65; }
  .dl-search { max-width: none; font-size: 16px; }
  .side .side-top [data-toggle="side"] { display: grid; place-items: center; color: var(--mute); }
  /* narrow windows and phones: Deals and Relationships are pages here too (they were floating sheets with a close button
     and no way to the menu): full screen, no close button, the menu button at the top left */
  .ppl-card.as-page { top: 0; bottom: 0; left: 0; right: 0; width: auto; max-height: none; border: 0; border-radius: 0; box-shadow: none; background: var(--bg); }
  #dlScrim, #pplScrim { display: none; }
  #pplCard.as-page [data-ppl-toggle].icon, #dlCard.as-page [data-dl-toggle].icon { display: none; }
  .ppl-card.as-page .ppl-card-h { padding-top: calc(14px + env(safe-area-inset-top, 0px)); padding-left: 64px; min-height: 60px; box-sizing: border-box; }
  body.dl-on .nav-toggle, body.ppl-on .nav-toggle { display: grid; place-items: center; position: fixed; z-index: 63; top: calc(12px + env(safe-area-inset-top, 0px)); left: 12px; width: 40px; height: 40px;
    border: 0; border-radius: 10px; background: #fff; color: var(--ink-2); box-shadow: 0 0 0 1px var(--line); cursor: pointer; }
}
@media (min-width: 561px) and (max-width: 820px) { .dl-grid { grid-template-columns: repeat(auto-fill, minmax(210px, 1fr)); gap: 16px; } }
/* ==== end shell polish ==== */

/* Deals grid: drag a card to a new place (11 Oct) */
.dl-grid.dl-sort .dl-card { cursor: grab; -webkit-user-drag: none; -webkit-touch-callout: none; user-select: none; -webkit-user-select: none; }
.dl-card.dl-moving { opacity: .28; border-style: dashed; border-color: var(--blue); box-shadow: none; }
.dl-card.dl-ghost { position: fixed; z-index: 9999; margin: 0; pointer-events: none; cursor: grabbing; transform: rotate(1.2deg) scale(1.03); box-shadow: 0 22px 44px -18px rgba(12, 29, 51, .5); border-color: var(--blue); transition: none; }
body.dl-dragging, body.dl-dragging * { cursor: grabbing !important; user-select: none; -webkit-user-select: none; }
.dl-say { position: fixed; left: 50%; bottom: 26px; transform: translate(-50%, 12px); z-index: 10000; padding: 9px 16px; border-radius: 99px; background: #0c1d33; color: #fff; font-size: 13px; font-weight: 600; opacity: 0; pointer-events: none; transition: opacity .18s, transform .18s; }
.dl-say.on { opacity: 1; transform: translate(-50%, 0); } .dl-say.bad { background: #a3271f; }

/* 11 Oct 2026: on a phone the menu is closed, so a signed-out visitor gets Sign in in the Deals header too. */
.dl-signin { display: none; }
@media (max-width: 820px) { .dl-signin { flex: none; align-self: center; display: inline-flex; align-items: center; min-height: 38px; padding: 0 16px; border-radius: 99px; background: var(--blue); color: #fff; font-size: 14px; font-weight: 600; text-decoration: none; white-space: nowrap; } }
