/* ── PL Sentinel — Mission Control (sn- namespace) ───────────────────────────
   Token-driven per the component-styling system: no hardcoded fonts, sizes
   or theme colors (accepted rgba washes only). Purple (--cat4) is Sentinel's
   agent accent, matching the AI action cards in PL Insight. */

.sn-wrap {
    max-width: 1280px;
    margin: 0 auto;
}

/* Header strip: identity + pulse gauge + actions */
.sn-head {
    display: flex;
    align-items: center;
    gap: 16px;
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 14px 18px;
    margin-bottom: 14px;
    background-image: linear-gradient(120deg, rgba(139,92,246,.07), rgba(79,142,247,.04) 55%, transparent);
}

.sn-head-title {
    font-size: var(--fs-2xl);
    font-weight: var(--fw-extrabold);
    letter-spacing: var(--ls-1);
}

.sn-head-sub {
    font-size: var(--fs-sm);
    color: var(--muted);
    line-height: var(--lh-normal, 1.5);
    margin-top: 2px;
}

.sn-pulse {
    display: flex;
    align-items: center;
    gap: 10px;
    margin-left: auto;
}

.sn-pulse-num {
    font-size: var(--fs-8xl);
    font-weight: var(--fw-extrabold);
    line-height: 1;
}

.sn-pulse-lbl {
    font-size: var(--fs-2xs);
    color: var(--muted);
    letter-spacing: var(--ls-8);
    text-transform: uppercase;
    text-align: right;
    line-height: 1.6;
}

/* Two-column mission grid */
.sn-grid {
    display: grid;
    grid-template-columns: 1.25fr 0.95fr;
    gap: 14px;
    align-items: start;
}

@media (max-width: 1250px) {
    .sn-grid { grid-template-columns: 1fr; }
}

.sn-card {
    background: var(--surface);
    border: 1px solid var(--border);
    border-radius: var(--radius-lg);
    padding: 14px 16px;
    margin-bottom: 14px;
}

.sn-card.sn-agent {
    border-color: rgba(139,92,246,.35);
}

.sn-card-title {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: var(--fs-base);
    font-weight: var(--fw-bold);
    margin-bottom: 10px;
}

.sn-card-title .sn-spacer { flex: 1; }

.sn-sub {
    font-size: var(--fs-sm);
    color: var(--muted);
    line-height: 1.6;
}

.sn-narrative {
    font-size: var(--fs-md);
    line-height: 1.7;
    white-space: pre-wrap;
    margin: 4px 0 12px;
}

/* Inbox / chase / feed items */
.sn-item {
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 10px 12px;
    margin-top: 8px;
    background: var(--surface2);
}

.sn-item-head {
    display: flex;
    align-items: center;
    gap: 8px;
    flex-wrap: wrap;
}

.sn-item-title {
    font-size: var(--fs-base);
    font-weight: var(--fw-semibold);
    flex: 1;
    min-width: 0;
}

.sn-item-sub {
    font-size: var(--fs-sm);
    color: var(--muted);
    line-height: 1.55;
    margin-top: 3px;
}

.sn-btn-approve {
    background: rgba(34,197,94,.14);
    border: 1px solid rgba(34,197,94,.35);
    color: #4ade80;
    border-radius: var(--radius-md);
    font-size: var(--fs-xs);
    font-weight: var(--fw-semibold);
    letter-spacing: var(--ls-6);
    padding: 4px 12px;
    cursor: pointer;
    font-family: var(--font);
}

.sn-btn-reject {
    background: transparent;
    border: 1px solid rgba(239,68,68,.35);
    color: var(--danger);
    border-radius: var(--radius-md);
    font-size: var(--fs-xs);
    font-weight: var(--fw-semibold);
    letter-spacing: var(--ls-6);
    padding: 4px 12px;
    cursor: pointer;
    font-family: var(--font);
}

.sn-btn-approve:disabled, .sn-btn-reject:disabled { opacity: .5; cursor: default; }

/* Activity feed */
.sn-feed { max-height: 300px; overflow-y: auto; }

.sn-feed-item {
    display: flex;
    gap: 10px;
    padding: 7px 2px;
    border-top: 1px solid var(--border);
    font-size: var(--fs-sm);
    line-height: 1.5;
}

.sn-feed-item:first-child { border-top: none; }

.sn-feed-time {
    color: var(--muted);
    font-size: var(--fs-xs);
    flex-shrink: 0;
    width: 84px;
    padding-top: 1px;
}

/* Client summary block */
.sn-client-sum {
    margin-top: 12px;
    background: var(--surface2);
    border: 1px solid var(--border);
    border-radius: var(--radius-md);
    padding: 10px 12px;
}

.sn-client-sum .sn-cap {
    font-size: var(--fs-2xs);
    letter-spacing: var(--ls-9);
    color: var(--muted);
    text-transform: uppercase;
    margin-bottom: 4px;
}

.sn-client-sum .sn-text {
    font-size: var(--fs-base);
    line-height: 1.6;
    white-space: pre-wrap;
    user-select: all;
}

/* ── Vish — new-gen chrome (vg- namespace) ───────────────────────────────────
   The Vish gradient (accent → violet) is the agent's brand mark — mirrored
   inside the framed chat page. Everything else stays token-driven. */
.vg-head {
    display: flex;
    align-items: center;
    gap: 14px;
    margin-bottom: 16px;
    padding: 4px 2px;
}

.vg-orb {
    width: 46px;
    height: 46px;
    border-radius: 50%;
    flex: none;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: var(--fs-3xl);
    color: #fff;
    background: linear-gradient(135deg, var(--accent), #8b5cf6);
    box-shadow: 0 0 22px rgba(139,92,246,.45);
}

.vg-title {
    font-size: var(--fs-6xl);
    font-weight: var(--fw-extrabold);
    line-height: 1.05;
    letter-spacing: var(--ls-tight);
    background: linear-gradient(90deg, var(--accent), #8b5cf6);
    -webkit-background-clip: text;
    background-clip: text;
    color: transparent;
}

.vg-sub {
    font-size: var(--fs-sm);
    color: var(--muted);
    margin-top: 3px;
}

.vg-sub b {
    color: var(--text);
    font-weight: var(--fw-semibold);
}

/* The hero chat frame: a 1px gradient ring with an ambient glow. */
.vg-frame {
    border-radius: 16px;
    padding: 1px;
    margin-bottom: 14px;
    background: linear-gradient(135deg, rgba(79,142,247,.55), rgba(139,92,246,.55));
    box-shadow: 0 10px 34px rgba(139,92,246,.14);
}

.vg-frame iframe {
    display: block;
    width: 100%;
    border: 0;
    border-radius: 15px;
    background: var(--bg);
}
