/* Page-specific residual styles for /learn/proxy-vs-vpn-differences/.
   Prefix: pvvd- (proxy vs vpn differences). Everything else on the page
   comes from the shared pxa- article system (article_assets.html).
   Colours are CSS variables only -- no raw hex. */

    /* ---------- Observer map (inline SVG + legend + reading grid) ---------- */

    .pvvd-map {
        margin: 2rem 0 2.25rem;
        padding: 1.35rem 1.35rem 1.15rem;
        background: var(--bg-secondary);
        border: 1px solid var(--border);
        border-radius: 14px;
    }

    .pvvd-map-head {
        margin-bottom: 1rem;
    }

    .pvvd-map .pvvd-map-title {
        margin: 0 0 0.3rem;
        font-family: var(--font-heading);
        font-size: 1.05rem;
        font-weight: 700;
        color: var(--text-primary);
    }

    .pvvd-map-sub {
        margin: 0;
        font-size: 0.9rem;
        color: var(--text-secondary);
    }

    .pvvd-map-svg {
        display: block;
        width: 100%;
        height: auto;
        min-width: 640px;
        color: var(--text-primary);
        overflow: visible;
    }

    /* The SVG keeps its aspect ratio; on narrow screens the wrapper scrolls
       horizontally rather than shrinking the labels into illegibility. */
    .pvvd-map-svg-scroll {
        overflow-x: auto;
        padding-bottom: 0.35rem;
    }

    .pvvd-node {
        fill: var(--bg-tertiary);
        stroke: var(--border);
        stroke-width: 1;
    }

    .pvvd-node--origin {
        stroke: var(--primary);
        stroke-dasharray: 4 3;
    }

    .pvvd-node--operator {
        fill: var(--bg-secondary);
        stroke: var(--primary);
        stroke-width: 1.5;
    }

    .pvvd-node--target {
        stroke: var(--success);
    }

    .pvvd-node-name {
        fill: var(--text-primary);
        font-family: var(--font-heading);
        font-size: 12px;
        font-weight: 700;
        text-anchor: middle;
    }

    .pvvd-node-sub {
        fill: var(--text-secondary);
        font-family: var(--font-mono);
        font-size: 9px;
        text-anchor: middle;
    }

    .pvvd-rail-caption {
        fill: var(--text-primary);
        font-family: var(--font-heading);
        font-size: 12px;
        font-weight: 800;
        letter-spacing: 0.01em;
    }

    .pvvd-band {
        fill: var(--primary);
        fill-opacity: 0.09;
        stroke: var(--primary);
        stroke-opacity: 0.45;
        stroke-width: 1;
        stroke-dasharray: 6 4;
    }

    .pvvd-band-note,
    .pvvd-branch-note {
        fill: var(--text-secondary);
        font-size: 10.5px;
        text-anchor: middle;
    }

    .pvvd-branch-note {
        fill: var(--warning);
    }

    .pvvd-arrow {
        fill: currentColor;
        opacity: 0.55;
    }

    .pvvd-branch {
        fill: none;
        stroke: var(--warning);
        stroke-width: 1.5;
        stroke-dasharray: 5 4;
        opacity: 0.85;
    }

    /* ---------- Three-state legend + observer grid ---------- */

    .pvvd-legend {
        display: flex;
        flex-wrap: wrap;
        gap: 0.35rem 1.1rem;
        list-style: none;
        margin: 0.9rem 0 0.9rem;
        padding: 0;
        font-size: 0.82rem;
        color: var(--text-secondary);
    }

    .pvvd-legend li {
        display: flex;
        align-items: center;
        gap: 0.4rem;
    }

    .pvvd-state {
        display: inline-block;
        width: 9px;
        height: 9px;
        flex: 0 0 auto;
        border-radius: 50%;
        margin-right: 0.4rem;
        vertical-align: middle;
        background: var(--text-secondary);
    }

    .pvvd-legend .pvvd-state {
        margin-right: 0;
    }

    .pvvd-state--content {
        background: var(--warning);
    }

    .pvvd-state--meta {
        background: var(--primary);
    }

    .pvvd-state--none {
        background: var(--success);
    }

    .pvvd-map .pxa-table-wrap {
        margin: 0;
    }

    .pvvd-obs td {
        font-size: 0.85rem;
        line-height: 1.5;
        vertical-align: top;
    }

    .pvvd-obs td strong {
        color: var(--text-primary);
    }

    /* ---------- Router strip ---------- */

    .pvvd-router {
        display: flex;
        flex-direction: column;
        gap: 0.55rem;
        margin: 1.75rem 0 2rem;
    }

    .pvvd-router-row {
        display: grid;
        grid-template-columns: minmax(210px, 1.05fr) 9.5rem minmax(240px, 1.6fr);
        align-items: center;
        gap: 0.75rem 1rem;
        padding: 0.85rem 1rem;
        background: var(--bg-secondary);
        border: 1px solid var(--border);
        border-left: 3px solid var(--border);
        border-radius: 10px;
        transition: border-color 0.2s;
    }

    .pvvd-router-row:hover {
        border-left-color: var(--primary);
    }

    .pvvd-router-when {
        display: flex;
        align-items: center;
        gap: 0.5rem;
        font-weight: 600;
        color: var(--text-primary);
        font-size: 0.93rem;
    }

    .pvvd-router-when .pxm2-icon {
        color: var(--primary);
        flex: 0 0 auto;
    }

    .pvvd-router-answer {
        display: inline-flex;
        align-items: center;
        justify-content: center;
        text-align: center;
        padding: 0.3rem 0.6rem;
        border-radius: 999px;
        border: 1px solid var(--border);
        font-family: var(--font-mono);
        font-size: 0.74rem;
        font-weight: 700;
        letter-spacing: 0.02em;
        text-transform: uppercase;
        color: var(--text-primary);
        background: var(--bg-tertiary);
    }

    .pvvd-router-answer--vpn {
        border-color: var(--primary);
        color: var(--primary);
        box-shadow: 0 0 12px -6px var(--glow-color);
    }

    .pvvd-router-answer--proxy {
        border-color: var(--success);
        color: var(--success);
    }

    .pvvd-router-answer--both {
        border-color: var(--warning);
        color: var(--warning);
    }

    .pvvd-router-answer--neither {
        border-style: dashed;
        color: var(--text-secondary);
    }

    .pvvd-router-why {
        font-size: 0.87rem;
        line-height: 1.55;
        color: var(--text-secondary);
    }

    @media (max-width: 860px) {
        .pvvd-map {
            padding: 1.1rem 0.9rem 1rem;
        }

        .pvvd-router-row {
            grid-template-columns: 1fr;
            gap: 0.45rem;
        }

        .pvvd-router-answer {
            justify-self: start;
        }
    }
