/* Governance Page Styles */

/* Governance Overview */
.governance-overview {
    margin-bottom: 2rem;
}

/* RACI Cards Grid */
.raci-cards {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(280px, 1fr));
    gap: 1.5rem;
    margin-top: 1.5rem;
}

.raci-card {
    background: white;
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    border-left: 4px solid #1e3a8a;
}

.raci-card .raci-header {
    display: flex;
    align-items: center;
    gap: 0.75rem;
    margin-bottom: 1rem;
}

.raci-card h3 {
    font-size: 1rem;
    color: #1e3a8a;
    margin: 0;
}

.raci-card .responsibilities {
    margin: 0;
    padding-left: 1.25rem;
    font-size: 0.9rem;
    color: #475569;
}

.raci-card .responsibilities li {
    margin-bottom: 0.5rem;
    line-height: 1.4;
}

/* RACI Badges */
.raci-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 28px;
    height: 28px;
    border-radius: 6px;
    font-weight: 700;
    font-size: 0.85rem;
}

.raci-badge.raci-a,
.raci-a {
    background: #dc2626;
    color: white;
}

.raci-badge.raci-r,
.raci-r {
    background: #f59e0b;
    color: white;
}

.raci-badge.raci-c,
.raci-c {
    background: #3b82f6;
    color: white;
}

.raci-badge.raci-i,
.raci-i {
    background: #10b981;
    color: white;
}

.raci-badge.raci-a-r {
    background: linear-gradient(135deg, #dc2626 50%, #f59e0b 50%);
    color: white;
}

/* Filter Bar (reuse from portfolio) */
.filter-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 1rem;
    padding: 1rem 1.5rem;
    background: white;
    border-radius: 8px;
    margin-bottom: 1.5rem;
    align-items: center;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.filter-group {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.filter-group label {
    font-weight: 500;
    color: #475569;
    font-size: 0.9rem;
    white-space: nowrap;
}

.filter-group select {
    padding: 0.5rem 2rem 0.5rem 0.75rem;
    border: 1px solid #e2e8f0;
    border-radius: 6px;
    font-size: 0.9rem;
    background: white;
    cursor: pointer;
}

.filter-results {
    margin-left: auto;
    font-size: 0.9rem;
    color: #64748b;
}

.filter-clear {
    padding: 0.5rem 1rem;
    background: #64748b;
    color: white;
    border: none;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.9rem;
    transition: background 0.3s ease;
}

.filter-clear:hover {
    background: #475569;
}

/* Ownership Grid */
.ownership-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
    gap: 1.5rem;
}

/* Ownership Card */
.ownership-card {
    background: white;
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.ownership-card .card-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.ownership-card .offer-name {
    font-size: 1.1rem;
    color: #1e3a8a;
    margin: 0;
}

.ownership-card .view-link {
    font-size: 0.8rem;
    color: #3b82f6;
    text-decoration: none;
}

.ownership-card .view-link:hover {
    text-decoration: underline;
}

/* Ownership Section */
.ownership-section {
    border-top: 1px solid #e2e8f0;
    padding-top: 0.75rem;
}

.ownership-section h4 {
    font-size: 0.8rem;
    color: #64748b;
    text-transform: uppercase;
    letter-spacing: 0.05em;
    margin: 0 0 0.5rem 0;
}

.owners-list,
.leads-list {
    display: flex;
    flex-wrap: wrap;
    gap: 0.5rem;
}

.owner-name {
    background: #1e3a8a;
    color: white;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.85rem;
    font-weight: 500;
}

.lead-name {
    background: #f1f5f9;
    color: #475569;
    padding: 0.25rem 0.75rem;
    border-radius: 20px;
    font-size: 0.85rem;
}

.owner-tbd {
    color: #94a3b8;
    font-style: italic;
    font-size: 0.85rem;
}

/* Card Stats */
.card-stats {
    display: flex;
    gap: 1.5rem;
    padding-top: 0.75rem;
    border-top: 1px solid #e2e8f0;
}

.card-stats .stat {
    text-align: center;
}

.card-stats .stat-value {
    display: block;
    font-size: 1.25rem;
    font-weight: 700;
    color: #1e3a8a;
}

.card-stats .stat-label {
    font-size: 0.75rem;
    color: #64748b;
}

.card-stats .stat.has-questions .stat-value {
    color: #dc2626;
}

/* Questions Preview */
.questions-preview {
    background: #fffbeb;
    border-radius: 6px;
    padding: 0.75rem;
    margin-top: 0.5rem;
}

.questions-preview h4 {
    font-size: 0.75rem;
    color: #92400e;
    text-transform: uppercase;
    margin: 0 0 0.5rem 0;
}

.question-item {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    margin-bottom: 0.5rem;
}

.question-item:last-child {
    margin-bottom: 0;
}

.question-text {
    font-size: 0.85rem;
    color: #78350f;
}

.question-session {
    font-size: 0.75rem;
    color: #92400e;
}

/* Questions Summary */
.questions-summary {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
}

.session-questions {
    background: white;
    border-radius: 8px;
    padding: 1.5rem;
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.session-questions h4 {
    color: #1e3a8a;
    margin: 0 0 1rem 0;
    padding-bottom: 0.5rem;
    border-bottom: 2px solid #e2e8f0;
}

.questions-list {
    display: flex;
    flex-direction: column;
    gap: 0.5rem;
}

.question-row {
    display: grid;
    grid-template-columns: 200px 1fr 80px;
    gap: 1rem;
    padding: 0.5rem;
    background: #f8fafc;
    border-radius: 4px;
    align-items: center;
}

.question-offer {
    font-weight: 500;
    color: #1e3a8a;
    font-size: 0.85rem;
}

.question-text {
    color: #475569;
    font-size: 0.9rem;
}

.question-status {
    text-align: center;
    padding: 0.2rem 0.5rem;
    border-radius: 4px;
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: capitalize;
}

.question-status.open {
    background: #fee2e2;
    color: #991b1b;
}

.question-status.in-progress {
    background: #fef3c7;
    color: #92400e;
}

.question-status.resolved {
    background: #d1fae5;
    color: #065f46;
}

/* RACI Matrix Table */
.raci-matrix {
    width: 100%;
    border-collapse: collapse;
    margin-bottom: 1rem;
}

.raci-matrix th {
    background: #1e3a8a;
    color: white;
    padding: 0.75rem;
    text-align: left;
    font-weight: 500;
}

.raci-matrix td {
    padding: 0.75rem;
    border-bottom: 1px solid #e2e8f0;
}

.raci-matrix tbody tr:nth-child(even) {
    background: #f8fafc;
}

.raci-matrix td.raci-a,
.raci-matrix td.raci-r,
.raci-matrix td.raci-c,
.raci-matrix td.raci-i {
    text-align: center;
    font-weight: 700;
}

/* RACI Legend */
.raci-legend {
    display: flex;
    flex-wrap: wrap;
    gap: 1.5rem;
    padding: 1rem;
    background: #f8fafc;
    border-radius: 6px;
}

.raci-legend .legend-item {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.9rem;
    color: #475569;
}

/* No Results */
.no-results {
    text-align: center;
    padding: 2rem;
    color: #64748b;
    font-style: italic;
}

/* Responsive */
@media (max-width: 768px) {
    .raci-cards {
        grid-template-columns: 1fr;
    }

    .ownership-grid {
        grid-template-columns: 1fr;
    }

    .question-row {
        grid-template-columns: 1fr;
        gap: 0.25rem;
    }

    .filter-bar {
        flex-direction: column;
        align-items: stretch;
    }

    .filter-results {
        margin-left: 0;
    }
}
