/* UnityReal - partner portal "My portfolio" + owner "Partner portal" page (partner-portal.js, portal-admin.js) */
.pp-tour {
    --pp-card: var(--bg-card, #fff);
    --pp-line: var(--border-light, #e2e8f0);
    --pp-text: var(--text-primary, #0f172a);
    --pp-muted: var(--text-muted, #64748b);
    --pp-accent: #6366f1;
}
.pp {
    --pp-card: var(--bg-card, #fff);
    --pp-line: var(--border-light, #e2e8f0);
    --pp-text: var(--text-primary, #0f172a);
    --pp-muted: var(--text-muted, #64748b);
    --pp-accent: #6366f1;
    color: var(--pp-text);
    max-width: 1180px;
    margin: 0 auto;
    padding: 0 0.25rem 2rem;
}
.pp[dir='rtl'] {
    text-align: right;
}
.pp-preview {
    background: #e0e7ff;
    color: #3730a3;
    border-radius: 10px;
    padding: 0.55rem 0.9rem;
    margin-bottom: 0.8rem;
    font-size: 0.85rem;
}
.pp-top {
    display: flex;
    flex-wrap: wrap;
    gap: 0.8rem;
    align-items: flex-end;
    justify-content: space-between;
    margin-bottom: 0.9rem;
}
.pp-brand {
    font-size: 0.75rem;
    letter-spacing: 0.04em;
    color: var(--pp-muted);
}
.pp-hello {
    margin: 0.1rem 0 0;
    font-size: 1.5rem;
    font-weight: 700;
}
.pp-top-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
}
.pp-seg {
    display: inline-flex;
    border: 1px solid var(--pp-line);
    border-radius: 10px;
    overflow: hidden;
    background: var(--pp-card);
}
.pp-seg button {
    border: 0;
    background: transparent;
    color: var(--pp-text);
    padding: 0.4rem 0.8rem;
    cursor: pointer;
    font-size: 0.85rem;
}
.pp-seg button.on {
    background: var(--pp-accent);
    color: #fff;
}
.pp-tabs {
    display: flex;
    gap: 0.35rem;
    overflow-x: auto;
    padding-bottom: 0.35rem;
    border-bottom: 1px solid var(--pp-line);
    margin-bottom: 1rem;
    scrollbar-width: thin;
}
.pp-tabs button {
    border: 0;
    background: transparent;
    padding: 0.55rem 0.95rem;
    border-radius: 10px 10px 0 0;
    cursor: pointer;
    white-space: nowrap;
    color: var(--pp-muted);
    font-weight: 600;
    font-size: 0.92rem;
}
.pp-tabs button.on {
    color: var(--pp-accent);
    box-shadow: inset 0 -3px 0 var(--pp-accent);
}
.pp-count {
    font-weight: 700;
    color: #dc2626;
}
.pp-loading {
    padding: 2.5rem;
    text-align: center;
    color: var(--pp-muted);
}
.pp-sec-t {
    font-size: 1.05rem;
    font-weight: 700;
    margin: 1.2rem 0 0.6rem;
}
.pp-sub {
    font-size: 0.8rem;
    color: var(--pp-muted);
}
.pp-l {
    font-size: 0.72rem;
    color: var(--pp-muted);
    text-transform: uppercase;
    letter-spacing: 0.03em;
}
.pp-v {
    font-size: 1.05rem;
    font-weight: 700;
}
.pos {
    color: #16a34a;
}
.neg {
    color: #dc2626;
}
.pp-kpis {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 0.8rem;
    margin-bottom: 0.6rem;
}
.pp-kpi {
    display: flex;
    gap: 0.8rem;
    align-items: center;
    background: var(--pp-card);
    border: 1px solid var(--pp-line);
    border-radius: 14px;
    padding: 0.95rem 1.05rem;
}
.pp-kpi-i {
    width: 44px;
    height: 44px;
    border-radius: 12px;
    display: grid;
    place-items: center;
    color: #fff;
    flex-shrink: 0;
}
.pp-kpi-l {
    font-size: 0.72rem;
    color: var(--pp-muted);
}
.pp-kpi-v {
    font-size: 1.2rem;
    font-weight: 700;
    line-height: 1.25;
}
.pp-kpi-s {
    font-size: 0.75rem;
    color: var(--pp-muted);
}
.pp-hint {
    display: inline-grid;
    place-items: center;
    width: 14px;
    height: 14px;
    border-radius: 50%;
    background: var(--pp-line);
    font-size: 0.65rem;
    cursor: help;
}
.pp-card {
    background: var(--pp-card);
    border: 1px solid var(--pp-line);
    border-radius: 14px;
    padding: 1rem 1.1rem;
}
.pp-empty {
    color: #16a34a;
    font-weight: 600;
}
.pp-units {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(340px, 1fr));
    gap: 0.9rem;
}
.pp-unit {
    background: var(--pp-card);
    border: 1px solid var(--pp-line);
    border-radius: 14px;
    padding: 1rem 1.1rem;
}
.pp-unit-h {
    display: flex;
    justify-content: space-between;
    gap: 0.6rem;
    margin-bottom: 0.7rem;
}
.pp-unit-t {
    font-weight: 700;
}
.pp-badge {
    display: inline-block;
    background: #eef2ff;
    color: #4338ca;
    border-radius: 999px;
    padding: 0.15rem 0.6rem;
    font-size: 0.75rem;
    font-weight: 700;
    white-space: nowrap;
    height: fit-content;
}
.pp-badge.ok {
    background: #dcfce7;
    color: #166534;
}
.pp-badge.bad {
    background: #fee2e2;
    color: #991b1b;
}
.pp-grid4 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 0.6rem 1rem;
}
.pp-bar {
    height: 8px;
    border-radius: 99px;
    background: var(--pp-line);
    overflow: hidden;
    margin: 0.25rem 0;
}
.pp-bar i {
    display: block;
    height: 100%;
    background: linear-gradient(90deg, #6366f1, #22c55e);
    border-radius: 99px;
}
.pp-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
}
.pp-chip {
    background: var(--pp-line);
    border-radius: 999px;
    padding: 0.2rem 0.65rem;
    font-size: 0.78rem;
}
.pp-chip.ok {
    background: #dcfce7;
    color: #166534;
}
.pp-chip.warn {
    background: #fef3c7;
    color: #92400e;
}
.pp-next {
    margin-top: 0.7rem;
    background: #eef2ff;
    border-radius: 10px;
    padding: 0.55rem 0.75rem;
    font-size: 0.85rem;
}
.pp-next.late {
    background: #fee2e2;
}
.pp-co {
    margin-top: 0.6rem;
    display: flex;
    gap: 0.35rem;
    flex-wrap: wrap;
    align-items: center;
}
.pp-tbl-wrap {
    overflow-x: auto;
}
.pp-tbl {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.88rem;
}
.pp-tbl th,
.pp-tbl td {
    padding: 0.55rem 0.7rem;
    border-bottom: 1px solid var(--pp-line);
    text-align: start;
    vertical-align: top;
}
.pp-tbl th {
    font-size: 0.72rem;
    text-transform: uppercase;
    color: var(--pp-muted);
    letter-spacing: 0.03em;
}
.pp-pay {
    background: var(--pp-card);
    border: 1px solid var(--pp-line);
    border-radius: 14px;
    padding: 0.9rem 1.1rem;
    margin-bottom: 0.7rem;
}
.pp-pay.late {
    border-color: #fca5a5;
}
.pp-pay-h {
    display: flex;
    justify-content: space-between;
    gap: 1rem;
    align-items: flex-start;
}
.pp-pay-a {
    font-size: 1.2rem;
    font-weight: 800;
    text-align: end;
    white-space: nowrap;
}
.pp-det {
    margin-top: 0.7rem;
}
.pp-det summary {
    cursor: pointer;
    font-weight: 600;
    color: var(--pp-accent);
    margin-bottom: 0.5rem;
}
.pp-pd-r {
    display: flex;
    align-items: center;
    gap: 0.6rem;
    padding: 0.35rem 0;
    border-bottom: 1px dashed var(--pp-line);
    flex-wrap: wrap;
}
.pp-pd-r .pp-l {
    min-width: 110px;
    text-transform: none;
}
.pp-pd-v {
    flex: 1;
    font-family: ui-monospace, Consolas, monospace;
    word-break: break-all;
    font-weight: 600;
}
.pp-copy,
.pp-btn {
    border: 0;
    background: var(--pp-accent);
    color: #fff;
    border-radius: 9px;
    padding: 0.45rem 0.9rem;
    cursor: pointer;
    font-weight: 600;
    font-size: 0.85rem;
    text-decoration: none;
    display: inline-flex;
    gap: 0.4rem;
    align-items: center;
}
.pp-copy {
    background: var(--pp-line);
    color: var(--pp-text);
    padding: 0.25rem 0.6rem;
    font-size: 0.75rem;
}
.pp-btn.ghost {
    background: transparent;
    color: var(--pp-accent);
    border: 1px solid var(--pp-line);
}
.pp-btn:disabled {
    opacity: 0.6;
    cursor: wait;
}
.pp-form {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 0.8rem 1rem;
}
.pp-form label {
    display: flex;
    flex-direction: column;
    gap: 0.3rem;
    font-size: 0.82rem;
    color: var(--pp-muted);
    font-weight: 600;
}
.pp-form .wide {
    grid-column: 1 / -1;
}
.pp-form input,
.pp-form select,
.pp-form textarea,
.pp-in,
.pp-inline select {
    border: 1px solid var(--pp-line);
    background: var(--pp-card);
    color: var(--pp-text);
    border-radius: 9px;
    padding: 0.5rem 0.65rem;
    font: inherit;
    font-weight: 400;
}
.pp-row {
    display: flex;
    gap: 1rem;
    align-items: center;
    flex-wrap: wrap;
    margin-bottom: 0.9rem;
}
.pp-inline {
    display: inline-flex;
    gap: 0.5rem;
    align-items: center;
}
.pp-feed {
    list-style: none;
    margin: 0;
    padding: 0;
}
.pp-feed li {
    display: flex;
    gap: 0.8rem;
    padding: 0.6rem 0;
    border-bottom: 1px solid var(--pp-line);
}
.pp-feed-i {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: #eef2ff;
    color: #4338ca;
    display: grid;
    place-items: center;
    flex-shrink: 0;
}
.pp-gallery {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(170px, 1fr));
    gap: 0.7rem;
}
.pp-gallery a {
    display: block;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--pp-line);
    color: inherit;
    text-decoration: none;
    background: var(--pp-card);
}
.pp-gallery img {
    width: 100%;
    height: 130px;
    object-fit: cover;
    display: block;
}
.pp-gallery span {
    display: block;
    font-size: 0.72rem;
    padding: 0.35rem 0.5rem;
    color: var(--pp-muted);
}
.pp-chipbtn {
    border: 1px solid var(--pp-line);
    background: var(--pp-card);
    color: var(--pp-text);
    padding: 0.3rem 0.8rem;
    border-radius: 999px;
    cursor: pointer;
    font-size: 0.82rem;
}
.pp-chipbtn.on {
    background: var(--pp-accent);
    color: #fff;
    border-color: var(--pp-accent);
}
.pp-doc {
    display: flex;
    align-items: center;
    gap: 0.8rem;
    padding: 0.6rem 0;
    border-bottom: 1px solid var(--pp-line);
}
.pp-doc > i {
    font-size: 1.4rem;
    color: var(--pp-accent);
}
.pp-doc-m {
    flex: 1;
    min-width: 0;
}
.pp-doc-n {
    font-weight: 600;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.pp-msg {
    padding: 0.7rem 0.9rem;
    border-radius: 12px;
    background: #f1f5f9;
    margin-bottom: 0.6rem;
}
.pp-msg.out {
    background: #eef2ff;
}
.pp-msg-b {
    white-space: pre-wrap;
    font-size: 0.9rem;
}
.pp-foot {
    margin-top: 1.2rem;
    text-align: center;
}
.pp-logo {
    font-size: 0.8rem;
    font-weight: 700;
    line-height: 1.2;
    display: block;
    white-space: normal;
}
.pp-linkbox {
    width: 100%;
    border: 1px solid var(--pp-line);
    border-radius: 9px;
    padding: 0.5rem;
    font-family: ui-monospace, Consolas, monospace;
    font-size: 0.8rem;
    background: var(--pp-card);
    color: var(--pp-text);
}
.pa-mail {
    margin-top: 0.8rem;
    background: #fff;
    padding: 1rem;
    border: 1px dashed var(--pp-line);
    border-radius: 10px;
    color: #111;
}
/* first-time tour */
.pp-tour {
    position: fixed;
    inset: 0;
    background: rgba(15, 23, 42, 0.6);
    display: grid;
    place-items: center;
    z-index: 100000;
    padding: 1rem;
}
.pp-tour-box {
    background: var(--bg-card, #fff);
    color: var(--text-primary, #0f172a);
    border-radius: 18px;
    max-width: 440px;
    width: 100%;
    padding: 1.6rem;
    box-shadow: 0 25px 60px rgba(0, 0, 0, 0.35);
}
.pp-tour-box h3 {
    margin: 0.6rem 0 0.4rem;
    font-size: 1.25rem;
}
.pp-tour-box p {
    margin: 0 0 1.2rem;
    line-height: 1.6;
    color: var(--text-secondary, #475569);
    text-align: justify;
    text-align-last: start;
}
.pp-tour-box {
    text-align: start;
}
.pp-tour-dots {
    display: flex;
    gap: 6px;
}
.pp-tour-dots i {
    width: 22px;
    height: 5px;
    border-radius: 9px;
    background: #cbd5e1;
}
.pp-tour-dots i.on {
    background: #6366f1;
}
.pp-tour-btns {
    display: flex;
    gap: 0.5rem;
    align-items: center;
}

#current-page-title {
    white-space: nowrap;
}
/* ---- partners: nothing that edits is visible (the server refuses it anyway) ---- */
body.partner-view [onclick*='sendWelcomeEmails'],
body.partner-view [onclick*='inboxCompose'],
body.partner-view [onclick*='sendReminder'],
body.partner-view [onclick*='sendWhatsApp'],
body.partner-view [onclick*='openWhatsApp'],
body.partner-view [onclick*='sendEmail'],
body.partner-view .pp-hidden-write,
body.partner-view
    .main-content
    .page:not(#page-myportal)
    :is(.btn-danger, .bulk-actions, .action-btn.danger, [data-write-action]),
body.partner-view .header-right :is(.quick-add, .add-new, #quick-add-btn) {
    display: none !important;
}

@media (max-width: 640px) {
    .pp-hello {
        font-size: 1.2rem;
    }
    .pp-units {
        grid-template-columns: 1fr;
    }
    .pp-pay-h {
        flex-direction: column;
    }
    .pp-pay-a {
        text-align: start;
    }
}

/* ---------- overview 2.0 (2026-10-18): hero, money flow, charts, map, unit pictures, new tab menu ---------- */
.pp-tabs {
    gap: 0.4rem;
    border-bottom: 0;
    padding: 0.35rem;
    background: var(--pp-card);
    border: 1px solid var(--pp-line);
    border-radius: 14px;
    position: sticky;
    top: 0;
    z-index: 5;
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.05);
}
.pp-tabs button {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    border-radius: 10px;
    padding: 0.5rem 0.85rem;
    transition:
        background 0.15s,
        color 0.15s;
}
.pp-tabs button i {
    font-size: 0.85rem;
    opacity: 0.8;
}
.pp-tabs button:hover {
    background: rgba(99, 102, 241, 0.08);
    color: var(--pp-accent);
}
.pp-tabs button.on {
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    color: #fff;
    box-shadow: 0 6px 14px rgba(79, 70, 229, 0.28);
}
.pp-tabs button.on i {
    opacity: 1;
}
.pp-nav .pp-nav-sub {
    padding-inline-start: 1.6rem;
    font-size: 0.9em;
}
.pp-nav .pp-nav-sub .nav-icon {
    font-size: 0.85em;
    opacity: 0.75;
}

.pp-hero2 {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1.2rem;
    padding: 1.4rem 1.6rem;
    border-radius: 20px;
    color: #fff;
    background:
        radial-gradient(120% 140% at 100% 0%, rgba(255, 255, 255, 0.18), transparent 50%),
        linear-gradient(135deg, #312e81 0%, #4f46e5 50%, #7c3aed 100%);
    box-shadow: 0 18px 40px rgba(79, 70, 229, 0.3);
    margin-bottom: 0.6rem;
    position: relative;
    overflow: hidden;
}
.pp-hero2::after {
    content: '';
    position: absolute;
    inset: auto -40px -60px auto;
    width: 220px;
    height: 220px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.07);
}
.pp-hero2-l {
    opacity: 0.85;
    font-size: 0.9rem;
}
.pp-hero2-v {
    font-size: clamp(1.8rem, 4vw, 2.6rem);
    font-weight: 800;
    letter-spacing: -0.5px;
    margin: 0.15rem 0 0.5rem;
}
.pp-hero2-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}
.pp-hchip {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    padding: 0.3rem 0.7rem;
    border-radius: 999px;
    background: rgba(255, 255, 255, 0.16);
    font-weight: 600;
    font-size: 0.85rem;
}
.pp-hchip.up {
    background: rgba(16, 185, 129, 0.9);
}
.pp-hchip.down {
    background: rgba(239, 68, 68, 0.9);
}
.pp-hero2-sub {
    margin-top: 0.6rem;
    font-size: 0.82rem;
    opacity: 0.8;
}
.pp-hero2-ring {
    position: relative;
    width: 150px;
    height: 150px;
    flex: none;
    z-index: 1;
}
.pp-ring-c {
    position: absolute;
    inset: 0;
    display: grid;
    place-content: center;
    justify-items: center;
    text-align: center;
    pointer-events: none;
}
.pp-ring-c b {
    font-size: 1.7rem;
    line-height: 1;
}
.pp-ring-c span {
    font-size: 0.7rem;
    opacity: 0.85;
    max-width: 90px;
    margin-top: 0.2rem;
}

.pp-flow {
    display: grid;
    grid-template-columns: 1fr 1.2fr 1fr 1fr;
    gap: 0.9rem;
    align-items: stretch;
}
.pp-fl-split {
    position: relative;
    display: grid;
    gap: 0.6rem;
}
.pp-fl {
    position: relative;
    display: grid;
    gap: 0.15rem;
    padding: 0.85rem 1rem;
    border-radius: 14px;
    background: var(--pp-card);
    border: 1px solid var(--pp-line);
}
.pp-fl i {
    width: 30px;
    height: 30px;
    display: grid;
    place-items: center;
    border-radius: 9px;
    background: #eef2ff;
    color: #4f46e5;
    margin-bottom: 0.25rem;
}
.pp-fl span {
    font-size: 0.78rem;
    color: var(--pp-muted);
}
.pp-fl b {
    font-size: 1.15rem;
}
.pp-fl.ok i {
    background: #dcfce7;
    color: #16a34a;
}
.pp-fl.warn i {
    background: #fef3c7;
    color: #d97706;
}
.pp-fl.val i {
    background: #e0f2fe;
    color: #0284c7;
}
.pp-fl.gain {
    background: linear-gradient(135deg, #059669, #10b981);
    color: #fff;
    border: 0;
}
.pp-fl.gain.neg {
    background: linear-gradient(135deg, #b91c1c, #ef4444);
}
.pp-fl.gain span {
    color: rgba(255, 255, 255, 0.85);
}
.pp-fl.gain i {
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
}
/* arrows between the steps */
.pp-flow > .pp-fl:not(:last-child)::after,
.pp-flow > .pp-fl-split::after {
    content: '\203A';
    position: absolute;
    inset-inline-end: -0.78rem;
    top: 50%;
    transform: translateY(-50%);
    font-size: 1.3rem;
    font-weight: 700;
    color: #a5b4fc;
    z-index: 2;
}
.pp[dir='rtl'] .pp-flow > .pp-fl:not(:last-child)::after,
.pp[dir='rtl'] .pp-flow > .pp-fl-split::after {
    content: '\2039';
}

.pp-charts {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 0.8rem;
}
.pp-chart {
    background: var(--pp-card);
    border: 1px solid var(--pp-line);
    border-radius: 16px;
    padding: 0.9rem 1rem;
}
.pp-chart.wide {
    grid-column: 1 / -1;
}
.pp-chart-t {
    font-weight: 700;
    margin-bottom: 0.5rem;
}
.pp-chart-c {
    position: relative;
    height: 280px;
}
.pp-chart-c.short {
    height: 220px;
}

.pp-map-card {
    padding: 0;
    overflow: hidden;
}
.pp-map {
    height: 340px;
}
.pp-map iframe,
.pp-u-map iframe {
    width: 100%;
    height: 100%;
    border: 0;
}
.pp-pin span {
    width: 30px;
    height: 30px;
    display: grid;
    place-items: center;
    color: #fff;
    border-radius: 50% 50% 50% 0;
    transform: rotate(-45deg);
    box-shadow: 0 4px 10px rgba(0, 0, 0, 0.3);
    border: 2px solid #fff;
}
.pp-pin span i {
    transform: rotate(45deg);
    font-size: 0.75rem;
}

.pp-units2 {
    grid-template-columns: repeat(auto-fill, minmax(360px, 1fr));
}
.pp-unit2 {
    padding: 0;
    overflow: hidden;
    display: flex;
    flex-direction: column;
    transition:
        box-shadow 0.2s,
        transform 0.2s;
}
.pp-unit2:hover {
    box-shadow: 0 14px 34px rgba(15, 23, 42, 0.1);
    transform: translateY(-2px);
}
.pp-u-media {
    position: relative;
    background: #0f172a;
}
.pp-u-cover {
    display: block;
    width: 100%;
    height: 190px;
    border: 0;
    padding: 0;
    cursor: zoom-in;
    background: #0f172a;
}
.pp-u-cover img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}
.pp-u-count {
    position: absolute;
    inset-inline-end: 0.6rem;
    top: 0.6rem;
    background: rgba(15, 23, 42, 0.7);
    color: #fff;
    padding: 0.2rem 0.55rem;
    border-radius: 999px;
    font-size: 0.75rem;
}
.pp-u-share {
    position: absolute;
    inset-inline-start: 0.6rem;
    top: 0.6rem;
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    color: #fff;
    padding: 0.25rem 0.65rem;
    border-radius: 999px;
    font-size: 0.78rem;
    font-weight: 700;
    box-shadow: 0 4px 12px rgba(79, 70, 229, 0.4);
}
.pp-u-thumbs {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 2px;
    background: #0f172a;
}
.pp-u-thumbs button {
    border: 0;
    padding: 0;
    height: 56px;
    cursor: zoom-in;
    background: #1e293b;
    overflow: hidden;
}
.pp-u-thumbs button.plan {
    background: #fff;
}
.pp-u-thumbs img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    transition: transform 0.25s;
}
.pp-u-thumbs button.plan img {
    object-fit: contain;
}
.pp-u-thumbs button:hover img {
    transform: scale(1.08);
}
.pp-u-nopic {
    height: 150px;
    display: grid;
    place-content: center;
    justify-items: center;
    gap: 0.4rem;
    color: #a5b4fc;
    background: linear-gradient(135deg, #1e1b4b, #312e81);
    font-size: 0.85rem;
}
.pp-u-nopic i {
    font-size: 2rem;
}
.pp-u-body {
    padding: 0.95rem 1.05rem 1.05rem;
}
.pp-vt {
    width: 100%;
    border-collapse: collapse;
    font-size: 0.86rem;
    margin: 0.2rem 0 0.6rem;
}
.pp-vt th {
    font-size: 0.72rem;
    font-weight: 600;
    color: var(--pp-muted);
    text-align: end;
    padding: 0.3rem 0.4rem;
}
.pp-vt td {
    padding: 0.38rem 0.4rem;
    border-top: 1px solid var(--pp-line);
    text-align: end;
    white-space: nowrap;
}
.pp-vt td:first-child {
    text-align: start;
    color: var(--pp-muted);
    white-space: normal;
}
.pp-vt .mine {
    background: rgba(99, 102, 241, 0.06);
    font-weight: 700;
}
.pp-vt th.mine {
    color: #4f46e5;
    border-radius: 8px 8px 0 0;
}
.pp-vt tr.g td {
    font-weight: 700;
}
.pp-u-row {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 0.5rem;
}
.pp-u-actions {
    display: flex;
    gap: 0.5rem;
    flex-wrap: wrap;
    margin-top: 0.8rem;
}
.pp-u-map {
    height: 200px;
    margin-top: 0.6rem;
    border-radius: 12px;
    overflow: hidden;
    border: 1px solid var(--pp-line);
}

.pp-lb {
    position: fixed;
    inset: 0;
    z-index: 10000;
    background: rgba(2, 6, 23, 0.92);
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.6rem;
    padding: 1rem;
}
.pp-lb figure {
    margin: 0;
    max-width: min(1100px, 86vw);
    text-align: center;
}
.pp-lb img {
    max-width: 100%;
    max-height: 80vh;
    border-radius: 10px;
    background: #fff;
}
.pp-lb figcaption {
    color: #cbd5e1;
    font-size: 0.85rem;
    margin-top: 0.5rem;
}
.pp-lb button {
    border: 0;
    background: rgba(255, 255, 255, 0.12);
    color: #fff;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    cursor: pointer;
    font-size: 1.1rem;
}
.pp-lb .pp-lb-x {
    position: absolute;
    top: 1rem;
    right: 1rem;
}

@media (max-width: 900px) {
    .pp-flow {
        grid-template-columns: 1fr 1fr;
    }
    .pp-flow > .pp-fl::after,
    .pp-flow > .pp-fl-split::after {
        display: none;
    }
    .pp-charts {
        grid-template-columns: 1fr;
    }
}
@media (max-width: 560px) {
    .pp-hero2 {
        flex-direction: column;
        align-items: flex-start;
    }
    .pp-hero2-ring {
        align-self: center;
        width: 130px;
        height: 130px;
    }
    .pp-units2 {
        grid-template-columns: 1fr;
    }
    .pp-flow {
        grid-template-columns: 1fr;
    }
}

.pp-tbl td {
    white-space: nowrap;
}
.pp-tbl td:last-child {
    white-space: normal;
    min-width: 140px;
}

/* your units first, the value of your share as a small card on the side (owner, 2026-10-18) */
.pp-lead {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 270px;
    gap: 1rem;
    align-items: start;
}
.pp-lead-main .pp-units2 {
    grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
}
.pp-lead-side {
    position: sticky;
    top: 70px;
    margin-top: 2.35rem;
}
.pp-hero2.side {
    flex-direction: column;
    align-items: stretch;
    gap: 0.6rem;
    padding: 1.1rem 1.1rem 1rem;
    border-radius: 18px;
}
.pp-hero2.side .pp-hero2-v {
    font-size: 1.6rem;
    margin: 0.1rem 0 0.4rem;
}
.pp-hero2.side .pp-hero2-ring {
    width: 120px;
    height: 120px;
    align-self: center;
}
.pp-hero2.side .pp-ring-c b {
    font-size: 1.35rem;
}
.pp-off {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    height: 100%;
    min-height: 90px;
    text-align: center;
    color: var(--pp-muted);
    font-size: 0.86rem;
    padding: 0.8rem;
}
.pp-map-off {
    height: auto;
    padding: 0.6rem 0.9rem 0.9rem;
}
.pp-map-off .pp-off {
    min-height: 0;
    justify-content: flex-start;
}
.pp-off-links {
    display: flex;
    flex-wrap: wrap;
    gap: 0.45rem;
}
.pp-off-links a {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.4rem 0.7rem;
    border-radius: 999px;
    border: 1px solid var(--pp-line);
    color: var(--pp-accent);
    text-decoration: none;
    font-size: 0.82rem;
    font-weight: 600;
}
.pp-off-links a:hover {
    background: rgba(99, 102, 241, 0.08);
}
.pp-u-map.pp-map-off {
    height: auto;
}
@media (max-width: 1000px) {
    .pp-lead {
        grid-template-columns: 1fr;
    }
    .pp-lead-side {
        position: static;
        margin-top: 0;
    }
}

/* the value of your share as a slim bar above the units (same look as the menu bar) - owner, 2026-10-18 */
.pp-valbar {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 0.5rem 0.9rem;
    padding: 0.55rem 0.9rem;
    margin: 0.2rem 0 0.4rem;
    background: var(--pp-card);
    border: 1px solid var(--pp-line);
    border-radius: 14px;
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.05);
    font-size: 0.85rem;
    color: var(--pp-muted);
}
.pp-vb-main {
    display: inline-flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.3rem 0.8rem 0.3rem 0.35rem;
    border-radius: 10px;
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    color: #fff;
    box-shadow: 0 6px 14px rgba(79, 70, 229, 0.28);
}
.pp-vb-main i {
    width: 26px;
    height: 26px;
    display: grid;
    place-items: center;
    border-radius: 8px;
    background: rgba(255, 255, 255, 0.18);
    font-size: 0.8rem;
}
.pp-vb-l {
    opacity: 0.85;
    font-size: 0.8rem;
}
.pp-vb-main b {
    font-size: 1.02rem;
    letter-spacing: -0.2px;
}
.pp-vb-chip {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
    padding: 0.25rem 0.6rem;
    border-radius: 999px;
    font-weight: 700;
    font-size: 0.8rem;
}
.pp-vb-chip.up {
    background: #dcfce7;
    color: #15803d;
}
.pp-vb-chip.down {
    background: #fee2e2;
    color: #b91c1c;
}
.pp-vb-item {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}
.pp-vb-item + .pp-vb-item::before {
    content: '';
    width: 1px;
    height: 16px;
    background: var(--pp-line);
    margin-inline-end: 0.55rem;
}
.pp-vb-paid {
    display: inline-flex;
    align-items: center;
    gap: 0.4rem;
    margin-inline-start: auto;
}
.pp-vb-paid b {
    color: var(--pp-text);
}
.pp-vb-track {
    width: 90px;
    height: 7px;
    border-radius: 99px;
    background: #e2e8f0;
    overflow: hidden;
}
.pp-vb-track i {
    display: block;
    height: 100%;
    border-radius: 99px;
    background: linear-gradient(90deg, #6366f1, #10b981);
}

/* three units to a row */
.pp-units3 {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.8rem;
}
.pp-units3 .pp-u-cover {
    height: 160px;
}
.pp-units3 .pp-u-thumbs button {
    height: 46px;
}
.pp-units3 .pp-u-body {
    padding: 0.8rem 0.85rem 0.9rem;
}
.pp-units3 .pp-unit-t {
    font-size: 0.98rem;
}
.pp-units3 .pp-vt {
    font-size: 0.78rem;
}
.pp-units3 .pp-vt th {
    font-size: 0.66rem;
    padding: 0.25rem 0.3rem;
}
.pp-units3 .pp-vt td {
    padding: 0.32rem 0.3rem;
}
.pp-units3 .pp-btn {
    font-size: 0.78rem;
    padding: 0.38rem 0.7rem;
}
@media (max-width: 1150px) {
    .pp-units3 {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}
@media (max-width: 680px) {
    .pp-units3 {
        grid-template-columns: 1fr;
    }
    .pp-vb-paid {
        margin-inline-start: 0;
    }
}

/* ---------- your money at a glance: one compact panel (owner, 2026-10-18) ---------- */
.pp-money {
    background: var(--pp-card);
    border: 1px solid var(--pp-line);
    border-radius: 16px;
    box-shadow: 0 4px 14px rgba(15, 23, 42, 0.05);
    padding: 0.9rem 1rem 0.8rem;
    margin-top: 1.1rem;
}
.pp-money-h {
    font-weight: 700;
    margin-bottom: 0.7rem;
}
.ppv-i {
    display: block;
    flex: none;
}
.pp-m-stats {
    display: grid;
    grid-template-columns: repeat(5, minmax(0, 1fr));
    gap: 0.5rem;
}
.pp-m-s {
    display: flex;
    align-items: center;
    gap: 0.55rem;
    padding: 0.55rem 0.65rem;
    border-radius: 12px;
    background: #f8fafc;
    min-width: 0;
}
.pp-m-s small {
    display: block;
    font-size: 0.7rem;
    color: var(--pp-muted);
    line-height: 1.25;
}
.pp-m-s b {
    display: block;
    font-size: 0.98rem;
    white-space: nowrap;
}
.pp-m-i {
    width: 32px;
    height: 32px;
    border-radius: 9px;
    display: grid;
    place-items: center;
    flex: none;
    background: #eef2ff;
    color: #4f46e5;
}
.pp-m-s.ok .pp-m-i {
    background: #dcfce7;
    color: #16a34a;
}
.pp-m-s.warn .pp-m-i {
    background: #fef3c7;
    color: #d97706;
}
.pp-m-s.val .pp-m-i {
    background: #e0f2fe;
    color: #0284c7;
}
.pp-m-s.gain {
    background: linear-gradient(135deg, #059669, #10b981);
    color: #fff;
}
.pp-m-s.gain.neg {
    background: linear-gradient(135deg, #b91c1c, #ef4444);
}
.pp-m-s.gain small {
    color: rgba(255, 255, 255, 0.85);
}
.pp-m-s.gain .pp-m-i {
    background: rgba(255, 255, 255, 0.2);
    color: #fff;
}
.pp-m-viz {
    margin: 0.8rem 0 0.2rem;
    display: grid;
    gap: 0.4rem;
}
.pp-m-row {
    display: grid;
    grid-template-columns: 110px minmax(0, 1fr) 130px;
    align-items: center;
    gap: 0.6rem;
    font-size: 0.8rem;
    color: var(--pp-muted);
}
.pp-m-row b {
    color: var(--pp-text);
    text-align: end;
    font-size: 0.85rem;
}
.pp-m-track {
    height: 14px;
    border-radius: 99px;
    background: #f1f5f9;
    overflow: hidden;
}
.pp-m-fill {
    display: flex;
    height: 100%;
}
.pp-m-fill i {
    display: block;
    height: 100%;
}
.pp-m-fill i:last-child {
    flex: 1;
}
.pp-m-fill .paid,
.pp-m-key .paid {
    background: #6366f1;
}
.pp-m-fill .left,
.pp-m-key .left {
    background: #fcd34d;
}
.pp-m-fill .base {
    background: #c7d2fe;
}
.pp-m-fill .gain,
.pp-m-key .gain {
    background: #10b981;
}
.pp-m-key {
    display: flex;
    flex-wrap: wrap;
    gap: 0.9rem;
    font-size: 0.72rem;
    color: var(--pp-muted);
    padding-inline-start: calc(110px + 0.6rem);
}
.pp-m-key span {
    display: inline-flex;
    align-items: center;
    gap: 0.3rem;
}
.pp-m-key i {
    width: 10px;
    height: 10px;
    border-radius: 3px;
    display: inline-block;
}
.pp-m-foot {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem 1.2rem;
    margin-top: 0.7rem;
    padding-top: 0.6rem;
    border-top: 1px solid var(--pp-line);
    font-size: 0.8rem;
    color: var(--pp-muted);
}
.pp-m-foot span {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}
.pp-m-foot b {
    color: var(--pp-text);
}
.pp-m-foot .ppv-i {
    color: #6366f1;
}

/* ---------- charts and map drawn in the page (pp-visuals.js) ---------- */
.pp-charts {
    gap: 0.7rem;
}
.pp-chart {
    padding: 0.8rem 0.9rem;
}
.pp-chart-t {
    font-size: 0.9rem;
}
.ppv-svg {
    width: 100%;
    height: auto;
    display: block;
    max-height: 260px;
}
.ppv-grid {
    stroke: rgba(15, 23, 42, 0.07);
}
.ppv-ax {
    font-size: 10.5px;
    fill: #94a3b8;
    font-family: inherit;
}
.ppv-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 0.4rem 1rem;
    font-size: 0.75rem;
    color: var(--pp-muted);
    margin-top: 0.3rem;
}
.ppv-legend.top {
    margin: 0 0 0.6rem;
}
.ppv-legend span {
    display: inline-flex;
    align-items: center;
    gap: 0.35rem;
}
.ppv-legend i {
    width: 14px;
    height: 4px;
    border-radius: 2px;
    display: inline-block;
}
.ppv-legend.top i {
    height: 10px;
    width: 10px;
    border-radius: 3px;
}
.ppv-donut {
    display: flex;
    align-items: center;
    gap: 1rem;
}
.ppv-dsvg {
    width: 150px;
    height: 150px;
    flex: none;
}
.ppv-dc-b {
    font-size: 17px;
    font-weight: 800;
    fill: var(--pp-text);
}
.ppv-dc-s {
    font-size: 9.5px;
    fill: #94a3b8;
}
.ppv-dlegend {
    display: grid;
    gap: 0.4rem;
    flex: 1;
    min-width: 0;
}
.ppv-dl {
    display: grid;
    grid-template-columns: 10px minmax(0, 1fr) auto 38px;
    align-items: center;
    gap: 0.45rem;
    font-size: 0.8rem;
}
.ppv-dl i {
    width: 10px;
    height: 10px;
    border-radius: 3px;
}
.ppv-dl span {
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.ppv-dl small {
    color: var(--pp-muted);
    text-align: end;
}
.ppv-pr {
    display: grid;
    grid-template-columns: 120px minmax(0, 1fr);
    gap: 0.6rem;
    align-items: center;
    padding: 0.35rem 0;
    border-top: 1px solid var(--pp-line);
    font-size: 0.8rem;
}
.ppv-pr-l {
    font-weight: 600;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}
.ppv-pr-bars {
    display: grid;
    gap: 0.25rem;
}
.ppv-bar {
    display: flex;
    align-items: center;
    gap: 0.4rem;
}
.ppv-bar i {
    display: block;
    height: 10px;
    border-radius: 0 6px 6px 0;
    min-width: 2px;
}
.ppv-bar b {
    font-size: 0.74rem;
    font-weight: 600;
    white-space: nowrap;
}
.ppv-cols {
    display: grid;
    grid-auto-flow: column;
    grid-auto-columns: minmax(0, 1fr);
    gap: 0.35rem;
    height: 170px;
    align-items: end;
}
.ppv-col {
    display: flex;
    flex-direction: column;
    justify-content: flex-end;
    align-items: center;
    height: 100%;
    gap: 0.2rem;
    min-width: 0;
}
.ppv-col i {
    display: block;
    width: 70%;
    max-width: 38px;
    border-radius: 6px 6px 2px 2px;
    background: linear-gradient(180deg, #818cf8, #6366f1);
}
.ppv-col:first-child i {
    background: linear-gradient(180deg, #fbbf24, #f59e0b);
}
.ppv-col b {
    font-size: 0.66rem;
    color: var(--pp-text);
    white-space: nowrap;
}
.ppv-col span {
    font-size: 0.66rem;
    color: #94a3b8;
    white-space: nowrap;
}
.ppv-empty {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    min-height: 90px;
    color: #16a34a;
    font-size: 0.86rem;
}
.pp-map-svg {
    height: auto;
}
.ppv-map {
    width: 100%;
    height: auto;
    display: block;
}
.ppv-m-sea {
    fill: #dbeafe;
}
.ppv-m-land {
    fill: #f8f5ee;
    stroke: #c9d8ee;
    stroke-width: 1.5;
}
.ppv-m-creek {
    fill: none;
    stroke: #bfdbfe;
    stroke-width: 7;
    stroke-linecap: round;
}
.ppv-m-road {
    fill: none;
    stroke: #fde68a;
    stroke-width: 4;
    stroke-linecap: round;
}
.ppv-m-palm {
    stroke: #eadfc8;
    stroke-linecap: round;
}
.ppv-m-area {
    font-size: 11px;
    fill: #94a3b8;
    font-family: inherit;
    letter-spacing: 0.03em;
}
.ppv-m-note {
    font-size: 10px;
    fill: #7aa0cf;
    font-style: italic;
}
.ppv-pin-tag {
    fill: #fff;
    stroke: #e2e8f0;
}
.ppv-pin-t {
    font-size: 11px;
    font-weight: 700;
    fill: #0f172a;
    font-family: inherit;
}
@media (max-width: 1000px) {
    .pp-m-stats {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}
@media (max-width: 640px) {
    .pp-m-stats {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
    .pp-m-row {
        grid-template-columns: 80px minmax(0, 1fr) 100px;
    }
    .pp-m-key {
        padding-inline-start: 0;
    }
    .ppv-donut {
        flex-direction: column;
        align-items: stretch;
    }
    .ppv-dsvg {
        align-self: center;
    }
}

/* ---------- cash flow: period cards (also the filter), chart, list of every payment ---------- */
.pp-cf-cards {
    display: grid;
    grid-template-columns: repeat(6, minmax(0, 1fr));
    gap: 0.5rem;
    margin-bottom: 0.8rem;
}
.pp-cf-card {
    display: grid;
    gap: 0.15rem;
    text-align: start;
    padding: 0.65rem 0.8rem;
    border-radius: 14px;
    border: 1px solid var(--pp-line);
    background: var(--pp-card);
    cursor: pointer;
    font-family: inherit;
    color: var(--pp-text);
    transition:
        border-color 0.15s,
        box-shadow 0.15s,
        transform 0.15s;
}
.pp-cf-card span {
    font-size: 0.74rem;
    color: var(--pp-muted);
}
.pp-cf-card b {
    font-size: 1rem;
    white-space: nowrap;
}
.pp-cf-card small {
    font-size: 0.7rem;
    color: var(--pp-muted);
}
.pp-cf-card:hover {
    border-color: #c7d2fe;
    transform: translateY(-1px);
}
.pp-cf-card.total {
    background: #f5f3ff;
    border-color: #ddd6fe;
}
.pp-cf-card.on {
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    border-color: transparent;
    color: #fff;
    box-shadow: 0 8px 18px rgba(79, 70, 229, 0.28);
}
.pp-cf-card.on span,
.pp-cf-card.on small {
    color: rgba(255, 255, 255, 0.85);
}
.pp-cf-chart {
    margin-bottom: 0.4rem;
}
.ppv-cols.dense {
    gap: 2px;
}
.ppv-cols.dense .ppv-col i {
    width: 80%;
    border-radius: 3px 3px 1px 1px;
}
.pp-cf-tbl tr.late td {
    background: #fef2f2;
}
.pp-cf-tbl tfoot td {
    border-top: 2px solid var(--pp-line);
    padding-top: 0.6rem;
}
@media (max-width: 1000px) {
    .pp-cf-cards {
        grid-template-columns: repeat(3, minmax(0, 1fr));
    }
}
@media (max-width: 560px) {
    .pp-cf-cards {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

/* ---------- map: all units (drawing) + one unit on Google Maps ---------- */
.pp-map-card {
    padding: 0.6rem;
}
.pp-map-tabs {
    display: flex;
    flex-wrap: wrap;
    gap: 0.35rem;
    margin-bottom: 0.55rem;
}
.pp-map-tabs button {
    border: 1px solid var(--pp-line);
    background: var(--pp-card);
    color: var(--pp-muted);
    border-radius: 999px;
    padding: 0.32rem 0.75rem;
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
    font-family: inherit;
}
.pp-map-tabs button:hover {
    border-color: #c7d2fe;
    color: var(--pp-accent);
}
.pp-map-tabs button.on {
    background: linear-gradient(135deg, #4f46e5, #7c3aed);
    border-color: transparent;
    color: #fff;
}
.pp-map {
    border-radius: 12px;
    overflow: hidden;
}
.pp-gmap-box,
.pp-u-map {
    position: relative;
}
.pp-gmap {
    display: block;
    width: 100%;
    height: 380px;
    border: 0;
    border-radius: 12px;
}
.pp-u-map .pp-gmap {
    height: 220px;
}
.pp-u-map {
    height: auto;
    border: 0;
}
.pp-gm-open {
    position: absolute;
    right: 10px;
    bottom: 10px;
    background: #fff;
    color: #1a73e8;
    font-size: 0.78rem;
    font-weight: 600;
    text-decoration: none;
    padding: 0.35rem 0.65rem;
    border-radius: 8px;
    box-shadow: 0 2px 8px rgba(15, 23, 42, 0.2);
}
.pp-map-hint {
    margin-top: 0.45rem;
    font-size: 0.75rem;
}
.ppv-pin:hover path {
    filter: brightness(1.1);
}
