/* Enterprise interaction system: flashes, toasts, compact dialogs */

/* ---- Django / system flashes (replaces heavy Bootstrap alerts) ---- */
.grc-flash-host {
    display: flex;
    flex-direction: column;
    gap: 8px;
    margin-bottom: 12px;
}

.grc-flash {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 10px;
    padding: 8px 12px;
    font-size: 13px;
    line-height: 1.4;
    border: 1px solid var(--es-border, #e5e7eb);
    border-radius: 0;
    background: #fff;
    color: var(--text, #1f2937);
}

.grc-flash__body {
    flex: 1;
    min-width: 0;
}

.grc-flash__close {
    flex-shrink: 0;
    opacity: 0.55;
    padding: 0;
    background: transparent;
    border: 0;
    line-height: 1;
    font-size: 1.1rem;
    cursor: pointer;
}

.grc-flash__close:hover {
    opacity: 0.9;
}

.grc-flash--success {
    border-color: #d1fae5;
    background: #f8fffc;
    color: #065f46;
}

.grc-flash--info {
    border-color: #e0e7ff;
    background: #fafbff;
    color: #3730a3;
}

.grc-flash--warning {
    border-color: #fde68a;
    background: #fffdf8;
    color: #92400e;
}

.grc-flash--danger,
.grc-flash--error {
    border-color: #fecaca;
    background: #fffafa;
    color: #991b1b;
}

/* Impersonation / system strip */
.grc-system-strip {
    display: flex;
    align-items: center;
    justify-content: center;
    flex-wrap: wrap;
    gap: 8px 12px;
    padding: 8px 14px;
    font-size: 13px;
    border-bottom: 1px solid var(--es-border, #e5e7eb);
    background: #fffef5;
    color: #713f12;
}

.grc-system-strip a {
    color: #92400e;
    font-weight: 500;
}

/* ---- GRC modals (Bootstrap structure; compact) ---- */
.grc-interaction-modal .modal-dialog {
    max-width: 400px;
}

.grc-interaction-modal .modal-header {
    padding: 10px 14px;
}

.grc-interaction-modal .modal-body {
    padding: 12px 14px;
    font-size: 13px;
}

.grc-interaction-modal .modal-footer {
    padding: 10px 14px;
}

.grc-interaction-modal .modal-title {
    font-size: 0.95rem;
    font-weight: 600;
}

/* ---- Toasts ---- */
.grc-toast-host {
    position: fixed;
    bottom: 16px;
    right: 16px;
    z-index: 1086;
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-width: min(360px, calc(100vw - 32px));
    pointer-events: none;
}

.grc-toast {
    pointer-events: auto;
    padding: 10px 12px;
    font-size: 13px;
    line-height: 1.4;
    border: 1px solid var(--es-border, #e5e7eb);
    border-radius: 0;
    background: #fff;
    color: var(--text, #1f2937);
    box-shadow: none;
    opacity: 1;
    transition: opacity 0.2s ease;
}

.grc-toast--out {
    opacity: 0;
}

.grc-toast--success {
    border-color: #bbf7d0;
    background: #f7fef9;
    color: #14532d;
}

.grc-toast--info {
    border-color: #e5e7eb;
    background: #fafafa;
    color: #374151;
}

.grc-toast--warning {
    border-color: #fde68a;
    background: #fffef8;
    color: #78350f;
}

.grc-toast--danger {
    border-color: #fecaca;
    background: #fff8f8;
    color: #7f1d1d;
}

/* ---- Notification center list ---- */
.grc-notify-list {
    display: flex;
    flex-direction: column;
}

.grc-notify-row {
    display: flex;
    gap: 12px;
    padding: 10px 14px;
    text-decoration: none;
    color: inherit;
    border-bottom: 1px solid var(--es-divider, #e5e7eb);
    transition: background 0.12s ease;
}

.grc-notify-row:last-child {
    border-bottom: none;
}

.grc-notify-row:hover {
    background: var(--primary-50, #f9fafb);
}

.grc-notify-row--unread {
    background: #fafbff;
}

.grc-notify-row__badge {
    width: 36px;
    height: 36px;
    border-radius: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    font-size: 12px;
    font-weight: 600;
    border: 1px solid var(--es-border, #e5e7eb);
    background: #fff;
    color: #4b5563;
}

.grc-notify-row__main {
    flex: 1;
    min-width: 0;
}

.grc-notify-row__title {
    font-size: 13px;
    font-weight: 500;
    margin-bottom: 2px;
}

.grc-notify-row--unread .grc-notify-row__title {
    font-weight: 600;
}

.grc-notify-row__meta {
    font-size: 12px;
    color: #6b7280;
}

.grc-notify-row__dot {
    width: 6px;
    height: 6px;
    border-radius: 50%;
    background: #3b82f6;
    flex-shrink: 0;
    margin-top: 6px;
    opacity: 0.75;
}
