/* ============================================================
   ARC — Phase 19: Outcome Tracking CSS
   ============================================================ */

/* ── Outcome Container ───────────────────────────────────── */
.outcome-container {
    max-width: 800px;
    margin: 0 auto;
    padding: 24px 0;
}

.outcome-header h2 {
    font-size: 20px;
    font-weight: 700;
    color: #1D1D1F;
    margin: 0 0 4px;
}

.outcome-subtitle {
    font-size: 13px;
    color: #8E8E93;
    margin: 0 0 20px;
}

/* ── Status Banner ───────────────────────────────────────── */
.outcome-status-banner {
    display: flex;
    align-items: center;
    justify-content: space-between;
    background: #FAFAFA;
    border-radius: 10px;
    padding: 12px 16px;
    margin-bottom: 20px;
}

.outcome-status-banner-left {
    display: flex;
    align-items: center;
    gap: 10px;
}

.outcome-status-dot {
    width: 10px;
    height: 10px;
    border-radius: 50%;
    flex-shrink: 0;
}

.outcome-status-text {
    font-weight: 600;
    font-size: 14px;
    color: #1D1D1F;
}

.outcome-status-date {
    font-size: 12px;
    color: #8E8E93;
}

/* ── Decision Snapshot ───────────────────────────────────── */
.outcome-snapshot {
    background: #F9F9FB;
    border: 1px solid var(--border-light, #E5E5EA);
    border-radius: 12px;
    padding: 16px 20px;
    margin-bottom: 20px;
}

.outcome-snapshot-title {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #8E8E93;
    margin-bottom: 12px;
}

.outcome-snapshot-grid {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 16px;
}

.outcome-snapshot-item {
    display: flex;
    flex-direction: column;
    gap: 4px;
}

.outcome-snapshot-label {
    font-size: 11px;
    color: #8E8E93;
    font-weight: 500;
}

.outcome-snapshot-value {
    font-size: 15px;
    font-weight: 600;
    color: #1D1D1F;
}

/* ── Form ────────────────────────────────────────────────── */
.outcome-form {
    background: #fff;
    border: 1px solid var(--border-light, #E5E5EA);
    border-radius: 12px;
    padding: 20px;
}

.outcome-form-row {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    margin-bottom: 16px;
}

.outcome-field {
    margin-bottom: 14px;
}

.outcome-field-label {
    display: block;
    font-size: 12px;
    font-weight: 600;
    color: #1D1D1F;
    margin-bottom: 6px;
    letter-spacing: -0.01em;
}

.outcome-field-select,
.outcome-field-input,
.outcome-field-textarea {
    width: 100%;
    padding: 8px 12px;
    border: 1px solid var(--border-light, #E5E5EA);
    border-radius: 8px;
    font-size: 13px;
    font-family: inherit;
    color: #1D1D1F;
    background: #FAFAFA;
    transition: border-color 0.15s, box-shadow 0.15s;
    box-sizing: border-box;
}

.outcome-field-select:focus,
.outcome-field-input:focus,
.outcome-field-textarea:focus {
    outline: none;
    border-color: var(--primary, #F97216);
    box-shadow: 0 0 0 3px rgba(249, 114, 22, 0.1);
    background: #fff;
}

.outcome-field-textarea {
    resize: vertical;
    min-height: 60px;
}

.outcome-field-status {
    margin-bottom: 0;
}

/* ── Custom Fields ───────────────────────────────────────── */
.outcome-custom-fields {
    border-top: 1px solid var(--border-light, #E5E5EA);
    padding-top: 16px;
    margin-top: 8px;
}

.outcome-custom-fields-title {
    font-size: 11px;
    font-weight: 700;
    text-transform: uppercase;
    letter-spacing: 0.06em;
    color: #8E8E93;
    margin-bottom: 12px;
}

/* ── Actions ─────────────────────────────────────────────── */
.outcome-actions {
    display: flex;
    justify-content: flex-end;
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--border-light, #E5E5EA);
}

.outcome-save-btn {
    min-width: 140px;
}

/* ── Outcome Pill (Progress Bar) ─────────────────────────── */
.stage-pill-outcome {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 6px 14px;
    border-radius: 20px;
    font-size: 12px;
    font-weight: 600;
    background: #F9F9FB;
    border: 1px solid var(--border-light, #E5E5EA);
    color: #8E8E93;
    cursor: pointer;
    transition: all 0.15s;
    white-space: nowrap;
    margin-left: 8px;
}

.stage-pill-outcome:hover {
    background: #F2F2F7;
    color: #1D1D1F;
}

.stage-pill-outcome.active {
    background: var(--primary, #F97216);
    color: #fff;
    border-color: var(--primary, #F97216);
}

.stage-pill-outcome.has-outcome {
    background: rgba(52, 199, 89, 0.08);
    border-color: rgba(52, 199, 89, 0.3);
    color: #34C759;
}

.stage-pill-outcome.has-outcome.active {
    background: #34C759;
    color: #fff;
    border-color: #34C759;
}

.stage-pill-outcome-icon {
    font-size: 14px;
}

/* ── Analytics: Outcome KPIs ─────────────────────────────── */
.outcome-kpi-grid {
    display: grid;
    grid-template-columns: 1fr 1fr;
    gap: 16px;
    padding: 16px;
}

.outcome-kpi {
    text-align: center;
}

.outcome-kpi-value {
    font-size: 28px;
    font-weight: 700;
    color: #1D1D1F;
    line-height: 1.2;
}

.outcome-kpi-label {
    font-size: 11px;
    color: #8E8E93;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.04em;
    margin-top: 2px;
}

/* ── Analytics: Scatter Container ────────────────────────── */
.outcome-scatter-container {
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 12px;
    min-height: 180px;
}

.outcome-scatter-empty {
    font-size: 12px;
    color: #8E8E93;
    text-align: center;
    padding: 40px 20px;
}

/* ── Analytics: Section Header ───────────────────────────── */
.ana-section-header {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 0 4px;
}

.ana-section-header h3 {
    font-size: 16px;
    font-weight: 700;
    color: #1D1D1F;
    margin: 0;
}

.ana-section-badge {
    font-size: 11px;
    font-weight: 600;
    color: #8E8E93;
    background: #F2F2F7;
    padding: 2px 8px;
    border-radius: 10px;
}

/* ── Pipeline Outcome Badge ──────────────────────────────── */
.sol-outcome-badge {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    font-size: 10px;
    font-weight: 600;
    padding: 2px 8px;
    border-radius: 10px;
    margin-left: 6px;
}

/* ── Print Styles ────────────────────────────────────────── */
@media print {
    .outcome-actions { display: none; }
    .outcome-container { max-width: 100%; }
}
