/* CENTR Permissions Manager - app.css */

/* Layout */
body {
    background-color: #f8f9fa;
}

/* Admin sidebar */
.admin-sidebar {
    background: #fff;
    border-right: 1px solid #dee2e6;
    min-height: calc(100vh - 80px);
    padding: 1.5rem 1rem;
    position: sticky;
    top: 0;
}

.admin-sidebar .sidebar-heading {
    text-transform: uppercase;
    font-size: 0.7rem;
    letter-spacing: 0.1em;
    color: #6c757d;
    margin-bottom: 0.75rem;
}

.admin-sidebar .nav-link {
    color: #343a40;
    padding: 0.4rem 0.75rem;
    border-radius: 0.375rem;
    font-size: 0.9rem;
}

.admin-sidebar .nav-link:hover {
    background-color: #e9ecef;
    color: #0d6efd;
}

.admin-sidebar .nav-link.active {
    background-color: #0d6efd;
    color: #fff;
}

/* Permission table */
.permission-table {
    font-size: 0.875rem;
}

.data-category-col {
    min-width: 180px;
    width: 25%;
}

.permission-col {
    min-width: 90px;
}

/* Approved orgs sub-panel */
.approved-orgs-subpanel {
    background-color: #f0f4ff;
    border: 1px solid #b8cdf8;
    border-radius: 0.375rem;
}

/* Tooltip icon */
.tooltip-icon {
    display: inline-block;
    color: #6c757d;
    font-size: 0.75rem;
    cursor: help;
    margin-left: 0.25rem;
    border-bottom: 1px dotted #6c757d;
}

/* Section card */
.section-card {
    box-shadow: 0 0.125rem 0.25rem rgba(0, 0, 0, 0.075);
}

/* TLD switcher */
.tld-switcher {
    display: flex;
    align-items: center;
}

/* Matrix table */
.matrix-table th,
.matrix-table td {
    font-size: 0.8rem;
    white-space: nowrap;
}

.matrix-table tbody tr td:first-child {
    white-space: normal;
    min-width: 120px;
}

/* Diff view */
.diff-table .diff-field-col {
    width: 22%;
}

.diff-row-changed {
    background-color: #fff8e1;
}

.diff-row-changed td {
    border-color: #ffe082 !important;
}

.diff-changed-indicator {
    color: #f59e0b;
    font-size: 0.6rem;
    vertical-align: middle;
}

.diff-value-new {
    color: #0d6efd;
    font-weight: 500;
}

/* Pending badge in nav */
.pending-badge {
    font-size: 0.65rem;
    vertical-align: middle;
}

/* Status badges */
.badge.bg-primary {
    font-size: 0.7rem;
}

/* Form layout improvements */
.permissions-form .table th {
    font-size: 0.8rem;
    font-weight: 600;
}

/* Alert refinements */
.alert {
    border-left: 4px solid;
}

.alert-success { border-left-color: #198754; }
.alert-danger  { border-left-color: #dc3545; }
.alert-warning { border-left-color: #ffc107; }
.alert-info    { border-left-color: #0dcaf0; }

/* Details/summary for history */
details > summary {
    list-style: none;
}
details > summary::-webkit-details-marker {
    display: none;
}
details > summary::before {
    content: '▶ ';
    font-size: 0.75rem;
}
details[open] > summary::before {
    content: '▼ ';
}

/* Admin table action column widths */
.col-actions-sm  { width: 100px; }
.col-actions-md  { width: 160px; }
.col-actions-lg  { width: 180px; }
.col-actions-xl  { width: 220px; }

/* Settings card constraint */
.settings-card { max-width: 600px; }

/* History summary clickable */
.history-summary { cursor: pointer; }
