:root {
    --sigf-navy: #1c185d;
    --sigf-indigo: #5952f6;
    --sigf-teal: #8035ea;
    --sigf-bg: #f5f4fb;
    --sigf-text: #1a1a1a;
    --sigf-error: #c0392b;
    --sigf-success: #1f9d55;
    --sigf-sidebar-bg: #ffffff;
    --sigf-border: #ebe9f5;
    --sigf-bubble-theirs: #f0f1f3;
}

* { box-sizing: border-box; }

html, body {
    margin: 0;
    height: 100%;
    font-family: 'Nunito', system-ui, -apple-system, sans-serif;
    background: var(--sigf-bg);
    color: var(--sigf-text);
}

/* ---- Auth pages ---- */
.auth-container {
    max-width: 400px;
    margin: 80px auto;
    padding: 32px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 4px 24px rgba(0,0,0,0.06);
}

.auth-container h1 {
    color: var(--sigf-navy);
    margin-bottom: 4px;
}

.auth-logo {
    display: block;
    max-width: 220px;
    margin: 0 auto 4px;
}

.tagline {
    color: #666;
    margin-top: 0;
    margin-bottom: 24px;
    text-align: center;
}

label {
    display: block;
    margin-bottom: 16px;
    font-weight: 600;
    font-size: 14px;
}

input {
    display: block;
    width: 100%;
    margin-top: 6px;
    padding: 10px 14px;
    border: 1px solid #ddd;
    border-radius: 999px;
    font-size: 14px;
    font-family: inherit;
}

button {
    border: none;
    border-radius: 999px;
    background: linear-gradient(90deg, var(--sigf-indigo), var(--sigf-teal));
    color: #fff;
    font-weight: 700;
    cursor: pointer;
    font-family: inherit;
}

.auth-container button {
    width: 100%;
    padding: 12px;
}

.error { color: var(--sigf-error); font-size: 14px; }
.success { color: var(--sigf-success); font-size: 14px; }

/* ---- App shell ---- */
.app-shell {
    display: flex;
    height: 100vh;
    overflow: hidden;
}

/* ---- Sidebar ---- */
.sidebar {
    width: 320px;
    flex-shrink: 0;
    background: var(--sigf-sidebar-bg);
    border-right: 1px solid var(--sigf-border);
    display: flex;
    flex-direction: column;
}

.sidebar-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 18px;
}

.brand {
    display: flex;
    align-items: center;
    gap: 8px;
}

.brand-logo {
    width: 24px;
    height: 24px;
}

.brand-name {
    font-weight: 800;
    font-size: 18px;
    color: var(--sigf-navy);
    letter-spacing: -0.3px;
}

.my-avatar {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--sigf-indigo), var(--sigf-teal));
    background-size: cover;
    background-position: center;
    color: #fff;
    display: flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
    font-size: 14px;
    border: none;
    cursor: pointer;
    padding: 0;
    font-family: inherit;
}

.search-box {
    position: relative;
    padding: 0 16px 12px;
}

.search-icon {
    position: absolute;
    left: 28px;
    top: 50%;
    transform: translateY(-50%);
    color: #999;
    font-size: 15px;
    pointer-events: none;
}

.search-box input {
    width: 100%;
    margin: 0;
    padding: 9px 14px 9px 34px;
    border-radius: 999px;
    border: none;
    background: var(--sigf-bg);
    font-size: 14px;
}

.search-results {
    display: none;
    position: absolute;
    left: 16px;
    right: 16px;
    top: 46px;
    background: #fff;
    border: 1px solid var(--sigf-border);
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.1);
    max-height: 240px;
    overflow-y: auto;
    z-index: 10;
}

.search-results.visible {
    display: block;
}

.search-result {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 14px;
    cursor: pointer;
    font-size: 14px;
}

.search-result:hover {
    background: var(--sigf-bg);
}

.search-result-text {
    display: flex;
    flex-direction: column;
}

.search-result .username {
    display: block;
    color: #888;
    font-size: 12px;
}

.search-empty {
    padding: 10px 14px;
    color: #888;
    font-size: 13px;
}

.conversation-list {
    list-style: none;
    margin: 0;
    padding: 4px 8px;
    overflow-y: auto;
    flex: 1;
}

.conversation-item {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 10px 10px;
    border-radius: 12px;
    cursor: pointer;
}

.conversation-item:hover {
    background: var(--sigf-bg);
}

.conversation-item.active {
    background: #f1eefc;
}

.avatar {
    width: 44px;
    height: 44px;
    border-radius: 50%;
    flex-shrink: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    font-weight: 700;
    font-size: 16px;
    position: relative;
    background-size: cover;
    background-position: center;
}

.avatar.avatar-sm {
    width: 32px;
    height: 32px;
    font-size: 13px;
}

.avatar.online::after {
    content: '';
    position: absolute;
    right: -1px;
    bottom: -1px;
    width: 12px;
    height: 12px;
    background: #22c55e;
    border: 2px solid #fff;
    border-radius: 50%;
}

.conv-info {
    min-width: 0;
    flex: 1;
}

.conv-top-row {
    display: flex;
    align-items: baseline;
    justify-content: space-between;
    gap: 8px;
}

.conv-name {
    font-weight: 700;
    font-size: 14.5px;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.conv-time {
    font-size: 11.5px;
    color: #999;
    flex-shrink: 0;
}

.conv-preview {
    display: block;
    font-size: 13px;
    color: #888;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.empty-hint {
    color: #888;
    font-size: 13px;
    padding: 16px;
}

.sidebar-footer {
    padding: 12px 18px;
    border-top: 1px solid var(--sigf-border);
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.presence-toggle {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 12.5px;
    color: #666;
    cursor: pointer;
    margin: 0;
    font-weight: 400;
}

.presence-toggle input {
    display: inline-block;
    width: 14px;
    height: 14px;
    margin: 0;
    padding: 0;
    border: 1px solid #ccc;
    border-radius: 4px;
    accent-color: var(--sigf-teal);
}

.logout-link {
    color: #888;
    font-size: 13px;
    text-decoration: none;
}

.logout-link:hover {
    color: var(--sigf-navy);
}

/* ---- Message panel ---- */
.message-panel {
    flex: 1;
    display: flex;
    flex-direction: column;
    background: var(--sigf-bg);
    min-width: 0;
}

.message-panel-header {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 22px;
    border-bottom: 1px solid var(--sigf-border);
    background: #fff;
    min-height: 30px;
}

.message-panel-header.empty {
    color: #999;
    font-size: 14px;
}

.header-info {
    display: flex;
    flex-direction: column;
}

.header-name {
    font-weight: 700;
    font-size: 15px;
}

.header-username {
    font-size: 12px;
    color: #999;
}

.message-list {
    flex: 1;
    overflow-y: auto;
    padding: 20px;
    display: flex;
    flex-direction: column;
    gap: 8px;
}

.message-row {
    display: flex;
    align-items: flex-end;
    gap: 4px;
    max-width: 82%;
}

.message-row.mine {
    align-self: flex-end;
    flex-direction: row-reverse;
}

.message-row.theirs {
    align-self: flex-start;
    flex-direction: row;
}

.message-bubble-column {
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.message-row.mine .message-bubble-column {
    align-items: flex-end;
}

.message-row.theirs .message-bubble-column {
    align-items: flex-start;
}

.message-bubble {
    padding: 9px 14px;
    border-radius: 18px;
    font-size: 14.5px;
    line-height: 1.4;
    position: relative;
    max-width: 100%;
}

.message-bubble.mine {
    background: linear-gradient(135deg, var(--sigf-indigo), var(--sigf-teal));
    color: #fff;
    border-bottom-right-radius: 5px;
}

.message-bubble.theirs {
    background: var(--sigf-bubble-theirs);
    color: var(--sigf-text);
    border-bottom-left-radius: 5px;
}

.message-bubble.highlight-flash,
.message-row.highlight-flash .message-bubble {
    animation: bubble-flash 1.2s ease;
}

@keyframes bubble-flash {
    0%, 100% { box-shadow: none; }
    30% { box-shadow: 0 0 0 3px var(--sigf-teal); }
}

.message-text {
    display: block;
    white-space: pre-wrap;
    word-break: break-word;
}

.message-time {
    display: block;
    font-size: 10.5px;
    opacity: 0.65;
    margin-top: 3px;
    text-align: right;
}

.message-bubble.expiring {
    opacity: 0;
    transform: scale(0.95);
    transition: opacity 0.3s ease, transform 0.3s ease;
}

.self-destruct-badge {
    display: inline-block;
    font-size: 11px;
    margin-left: 8px;
    opacity: 0.75;
}

/* ---- Bericht-acties (reageren/antwoorden) ---- */
.message-actions {
    display: flex;
    align-items: center;
    gap: 2px;
    opacity: 0;
    transition: opacity 0.15s ease;
    flex-shrink: 0;
    padding-bottom: 4px;
}

.message-row:hover .message-actions {
    opacity: 1;
}

.message-action-btn {
    width: 28px;
    height: 28px;
    border-radius: 50%;
    background: #fff;
    background-image: none;
    border: 1px solid var(--sigf-border);
    color: var(--sigf-text);
    font-size: 14px;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
    box-shadow: 0 1px 3px rgba(0,0,0,0.08);
}

.message-action-btn:hover {
    background: var(--sigf-bg);
}

@media (max-width: 720px) {
    .message-actions {
        opacity: 0.55;
    }
}

/* ---- Geciteerd bericht (antwoord) ---- */
.reply-quote {
    display: flex;
    flex-direction: column;
    gap: 1px;
    padding: 6px 10px;
    margin-bottom: 6px;
    border-left: 3px solid var(--sigf-teal);
    border-radius: 6px;
    background: rgba(0,0,0,0.06);
    cursor: pointer;
    max-width: 100%;
}

.message-bubble.mine .reply-quote {
    background: rgba(255,255,255,0.18);
    border-left-color: rgba(255,255,255,0.7);
}

.reply-quote-sender {
    font-size: 12px;
    font-weight: 700;
    opacity: 0.9;
}

.reply-quote-snippet {
    font-size: 12.5px;
    opacity: 0.75;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

/* ---- Reactiebalk onder een bericht ---- */
.reactions-bar {
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    margin-top: 4px;
}

.reaction-pill {
    display: inline-flex;
    align-items: center;
    gap: 4px;
    background: #fff;
    border: 1px solid var(--sigf-border);
    border-radius: 999px;
    padding: 2px 8px;
    font-size: 12px;
    color: var(--sigf-text);
    line-height: 1.6;
}

.reaction-pill span {
    font-size: 11px;
    color: #888;
    font-weight: 700;
}

.reaction-pill.mine {
    background: #f1eefc;
    border-color: var(--sigf-teal);
}

.reaction-pill.mine span {
    color: var(--sigf-teal);
}

.reaction-pill:hover {
    background: var(--sigf-bg);
}

/* ---- Zwevend emoji-reactiekeuzepaneel ---- */
.reaction-picker {
    position: fixed;
    display: flex;
    flex-wrap: wrap;
    gap: 4px;
    max-width: 220px;
    background: #fff;
    border-radius: 16px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.18);
    padding: 8px;
    z-index: 50;
}

.reaction-picker-option {
    width: 34px;
    height: 34px;
    border-radius: 8px;
    background: none;
    background-image: none;
    font-size: 19px;
    padding: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.reaction-picker-option:hover {
    background: var(--sigf-bg);
}

/* ---- "Antwoorden op..."-balk boven het invoerveld ---- */
.reply-preview-bar {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 20px;
    background: #f1eefc;
    border-top: 1px solid #e4def9;
}

.reply-preview-content {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

#reply-preview-sender {
    font-size: 12px;
    font-weight: 700;
    color: var(--sigf-navy);
}

#reply-preview-snippet {
    font-size: 12.5px;
    color: #666;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.reply-preview-bar button {
    width: 26px;
    height: 26px;
    border-radius: 50%;
    background: none;
    background-image: none;
    color: #888;
    font-size: 16px;
    padding: 0;
    flex-shrink: 0;
}

.reply-preview-bar button:hover {
    background: rgba(0,0,0,0.06);
}

/* ---- Emoji-picker ---- */
.emoji-picker {
    display: none;
    grid-template-columns: repeat(10, 1fr);
    gap: 2px;
    max-width: 360px;
    margin: 0 20px 8px auto;
    padding: 10px;
    background: #fff;
    border: 1px solid var(--sigf-border);
    border-radius: 14px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.12);
    max-height: 200px;
    overflow-y: auto;
}

.emoji-option {
    background: none;
    background-image: none;
    border-radius: 8px;
    font-size: 19px;
    padding: 4px;
    line-height: 1.4;
    cursor: pointer;
}

.emoji-option:hover {
    background: var(--sigf-bg);
}

/* ---- Input bar ---- */
.message-form {
    display: flex;
    align-items: center;
    gap: 8px;
    padding: 14px 20px;
    background: #fff;
    border-top: 1px solid var(--sigf-border);
}

.icon-button {
    width: 38px;
    height: 38px;
    flex-shrink: 0;
    border-radius: 50%;
    background: var(--sigf-bg);
    background-image: none;
    color: #555;
    display: flex;
    align-items: center;
    justify-content: center;
    padding: 0;
}

.icon-button:hover {
    background: #e9edf0;
}

.send-button {
    background: linear-gradient(135deg, var(--sigf-indigo), var(--sigf-teal));
    background-image: linear-gradient(135deg, var(--sigf-indigo), var(--sigf-teal));
    color: #fff;
}

.timer-select {
    border-radius: 999px;
    border: none;
    background: var(--sigf-bg);
    padding: 0 8px;
    height: 38px;
    font-size: 13px;
    flex-shrink: 0;
    width: 56px;
}

.message-input {
    flex: 1;
    margin: 0;
    border-radius: 999px;
    border: none;
    background: var(--sigf-bg);
    padding: 10px 16px;
    font-size: 14.5px;
}

/* ---- Attachments ---- */
.attachment-preview {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 8px 20px;
    background: #f1eefc;
    border-top: 1px solid #e4def9;
    font-size: 13px;
}

.attachment-preview button {
    width: auto;
    background: none;
    background-image: none;
    color: #888;
    font-size: 18px;
    padding: 0 6px;
    cursor: pointer;
}

.message-bubble.image-only {
    background: none;
    padding: 0;
    display: inline-block;
    position: relative;
    line-height: 0;
}

.message-bubble.image-only .attachment-image-link {
    background: none;
    padding: 0;
    margin: 0;
    border-radius: 14px;
    overflow: hidden;
    display: block;
    box-shadow: 0 1px 3px rgba(0,0,0,0.15);
}

.message-bubble.image-only .attachment-image {
    border-radius: 0;
    margin: 0;
}

.message-bubble.image-only .message-time {
    position: absolute;
    right: 8px;
    bottom: 8px;
    background: rgba(0,0,0,0.5);
    color: #fff;
    padding: 3px 9px;
    border-radius: 999px;
    font-size: 10.5px;
    margin: 0;
    opacity: 1;
}

.message-bubble.image-only .self-destruct-badge {
    position: absolute;
    left: 8px;
    bottom: 8px;
    background: rgba(0,0,0,0.5);
    color: #fff;
    padding: 3px 9px;
    border-radius: 999px;
    margin: 0;
    opacity: 1;
}
.attachment-image-link {
    display: block;
    background: #fff;
    border-radius: 14px;
    padding: 4px;
    margin-bottom: 4px;
    width: fit-content;
}

.attachment-image {
    display: block;
    max-width: 240px;
    max-height: 240px;
    border-radius: 10px;
}

.attachment-file-link {
    display: flex;
    align-items: center;
    gap: 6px;
    padding: 10px 12px;
    background: #fff;
    border-radius: 12px;
    font-size: 13px;
    text-decoration: none;
    color: var(--sigf-text);
    margin-bottom: 4px;
    width: fit-content;
}

.attachment-size {
    opacity: 0.6;
    font-size: 11px;
}

/* ---- Terugknop (alleen mobiel zichtbaar) ---- */
.back-button {
    display: none;
    margin-right: 2px;
}

/* ---- Responsive (mobiel) ---- */
@media (max-width: 720px) {
    .app-shell {
        position: relative;
        height: 100dvh;
        overflow: hidden;
    }

    .sidebar,
    .message-panel {
        width: 100%;
        height: 100%;
    }

    /* Standaard: alleen de gesprekslijst, het gesprek staat klaar maar verborgen */
    .message-panel {
        display: none;
    }

    /* Zodra een gesprek geopend is: lijst weg, gesprek schermvullend */
    .app-shell.show-chat .sidebar {
        display: none;
    }

    .app-shell.show-chat .message-panel {
        display: flex;
    }

    .back-button {
        display: flex;
    }

    .message-bubble {
        max-width: 82%;
    }

    .modal {
        max-width: 92%;
    }

    .emoji-picker {
        max-width: calc(100vw - 32px);
        margin-right: 16px;
    }
}

/* ---- Instellingen-modal ---- */
.modal-overlay {
    position: fixed;
    inset: 0;
    background: rgba(15, 15, 30, 0.45);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 100;
}

.modal {
    background: #fff;
    border-radius: 18px;
    width: 90%;
    max-width: 380px;
    max-height: 85vh;
    overflow-y: auto;
    box-shadow: 0 20px 60px rgba(0,0,0,0.25);
}

.modal-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 18px 20px 0;
}

.modal-header h2 {
    margin: 0;
    font-size: 18px;
    color: var(--sigf-navy);
}

.modal-body {
    padding: 16px 20px;
}

.modal-footer {
    padding: 0 20px 20px;
}

.modal-footer .primary-button {
    width: 100%;
    padding: 11px;
}

.settings-avatar-row {
    display: flex;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
}

.settings-avatar-preview {
    width: 72px;
    height: 72px;
    border-radius: 50%;
    background: linear-gradient(135deg, var(--sigf-indigo), var(--sigf-teal));
    background-size: cover;
    background-position: center;
    color: #fff;
    font-size: 26px;
    font-weight: 700;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.settings-avatar-actions {
    display: flex;
    flex-direction: column;
    gap: 4px;
    align-items: flex-start;
}

.secondary-button {
    background: var(--sigf-bg);
    background-image: none;
    color: var(--sigf-navy);
    font-size: 13px;
    font-weight: 600;
    padding: 8px 14px;
    width: auto;
}

.text-button {
    background: none;
    background-image: none;
    color: #999;
    font-size: 12.5px;
    font-weight: 400;
    padding: 2px 4px;
    width: auto;
}

.text-button:hover {
    color: var(--sigf-error);
}

.primary-button {
    background: linear-gradient(135deg, var(--sigf-indigo), var(--sigf-teal));
    color: #fff;
    font-weight: 700;
    width: auto;
    padding: 10px 20px;
}

.primary-button:disabled {
    opacity: 0.6;
    cursor: default;
}

.settings-label {
    display: block;
    font-size: 13px;
    font-weight: 600;
    color: #444;
    margin-bottom: 18px;
}

.settings-label input {
    margin-top: 6px;
}

.settings-presence-row {
    margin-bottom: 4px;
}

.settings-hint {
    font-size: 12px;
    color: #999;
    margin: 0 0 12px;
}

.settings-feedback {
    font-size: 13px;
    color: var(--sigf-success);
    min-height: 18px;
}

.settings-feedback.error {
    color: var(--sigf-error);
}

/* ---- Vrienden uitnodigen ---- */
.settings-divider {
    border: none;
    border-top: 1px solid var(--sigf-border);
    margin: 18px 0;
}

.invite-section h3 {
    margin: 0 0 6px;
    font-size: 15px;
    color: var(--sigf-navy);
}

.invite-link-row {
    display: flex;
    gap: 8px;
    margin-bottom: 10px;
}

.invite-link-row input {
    flex: 1;
    margin: 0;
    font-size: 12.5px;
    background: var(--sigf-bg);
    border: none;
    color: #555;
}

.invite-link-row .secondary-button {
    flex-shrink: 0;
}

.invite-share-button {
    width: 100%;
}

.invite-banner {
    background: #f1eefc;
    color: var(--sigf-navy);
    border-radius: 12px;
    padding: 10px 14px;
    font-size: 13.5px;
    text-align: center;
    margin-bottom: 16px;
}

/* ---- GDPR: gegevensbeheer ---- */
.gdpr-section h3 {
    margin: 0 0 12px;
    font-size: 15px;
    color: var(--sigf-navy);
}

.gdpr-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 0;
    border-bottom: 1px solid var(--sigf-border);
}

.gdpr-row strong {
    font-size: 13.5px;
    color: var(--sigf-text);
}

.gdpr-row .settings-hint {
    margin: 2px 0 0;
    max-width: 260px;
}

.gdpr-row form {
    margin: 0;
    flex-shrink: 0;
}

.danger-button {
    background: var(--sigf-error);
    color: #fff;
    font-weight: 700;
    width: auto;
    padding: 8px 16px;
    font-size: 13px;
    flex-shrink: 0;
}

.delete-confirm-box {
    margin-top: 12px;
    padding: 14px;
    background: #fdeceb;
    border-radius: 12px;
}

.delete-confirm-box p {
    margin: 0 0 10px;
    font-size: 13px;
    color: var(--sigf-error);
}

.delete-confirm-box input {
    margin-bottom: 8px;
}

.delete-confirm-actions {
    display: flex;
    justify-content: flex-end;
    gap: 10px;
    align-items: center;
}

/* ---- Groepen ---- */
.new-group-button {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 8px;
    margin: 0 16px 14px;
    width: calc(100% - 32px);
    background: #fff;
    background-image: none;
    color: var(--sigf-indigo);
    font-weight: 700;
    font-size: 13.5px;
    padding: 10px 14px;
    border-radius: 999px;
    border: 1.5px solid #ece9f7;
    transition: background 0.15s ease, border-color 0.15s ease;
}

.new-group-button svg {
    flex-shrink: 0;
}

.new-group-button:hover {
    background: #f6f4fd;
    border-color: var(--sigf-indigo);
}

.header-clickable-area {
    display: flex;
    align-items: center;
    gap: 12px;
    cursor: pointer;
    flex: 1;
}

.message-sender-name {
    display: block;
    font-size: 12px;
    font-weight: 700;
    margin-bottom: 2px;
}

.group-member-chips {
    display: flex;
    flex-wrap: wrap;
    gap: 6px;
    margin-bottom: 16px;
    min-height: 20px;
}

.member-chip {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: #f1eefc;
    color: var(--sigf-navy);
    padding: 4px 6px 4px 10px;
    border-radius: 999px;
    font-size: 12.5px;
    font-weight: 600;
}

.chip-remove {
    width: auto;
    background: none;
    background-image: none;
    color: #888;
    font-size: 15px;
    padding: 0 4px;
    cursor: pointer;
}

.group-participant-list {
    list-style: none;
    margin: 0 0 8px;
    padding: 0;
    max-height: 280px;
    overflow-y: auto;
}

.group-participant-item {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 8px 0;
    border-bottom: 1px solid #f3f2fa;
}

.participant-name {
    flex: 1;
    font-size: 13.5px;
}

.remove-participant-btn {
    color: var(--sigf-error);
    font-size: 12px;
}

.admin-badge {
    display: inline-block;
    padding: 2px 8px;
    border-radius: 999px;
    font-size: 10.5px;
    font-weight: 700;
    background: #f1eefc;
    color: var(--sigf-teal);
    margin-left: 4px;
}

/* ---- Bellen ---- */
.header-call-buttons {
    display: flex;
    gap: 4px;
    margin-left: auto;
}

.call-overlay {
    position: fixed;
    inset: 0;
    background: #0f0f2d;
    z-index: 200;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    color: #fff;
}

/* ---- Inkomende oproep ---- */
.incoming-call-box {
    text-align: center;
}

.incoming-call-avatar {
    display: flex;
    justify-content: center;
    margin-bottom: 20px;
}

.incoming-call-avatar .avatar {
    width: 96px;
    height: 96px;
    font-size: 34px;
}

.incoming-call-box h2 {
    margin: 0 0 6px;
    font-size: 22px;
}

.incoming-call-box p {
    color: rgba(255,255,255,0.7);
    margin: 0 0 40px;
}

.incoming-call-actions {
    display: flex;
    gap: 40px;
    justify-content: center;
}

.call-action-btn {
    width: 60px;
    height: 60px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    background: #333;
    background-image: none;
    color: #fff;
    padding: 0;
}

.call-action-btn.accept {
    background: #1f9d55;
    background-image: none;
}

.call-action-btn.decline {
    background: var(--sigf-error);
    background-image: none;
}

.call-action-btn.control {
    width: 52px;
    height: 52px;
    background: rgba(255,255,255,0.15);
    background-image: none;
}

.call-action-btn.control.off {
    background: var(--sigf-error);
    background-image: none;
}

/* ---- Actief gesprek ---- */
.in-call-header {
    position: absolute;
    top: 20px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    gap: 12px;
    color: rgba(255,255,255,0.85);
    font-size: 14px;
}

.call-tiles {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 12px;
    width: 100%;
    max-width: 1000px;
    padding: 0 20px;
    margin-bottom: 100px;
}

.call-tile {
    position: relative;
    background: #1a1a3a;
    border-radius: 16px;
    overflow: hidden;
    aspect-ratio: 4 / 3;
    display: flex;
    align-items: center;
    justify-content: center;
}

.call-tile video {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.call-tile audio {
    display: none;
}

.call-tile-label {
    position: absolute;
    left: 10px;
    bottom: 8px;
    font-size: 12px;
    background: rgba(0,0,0,0.5);
    padding: 3px 9px;
    border-radius: 999px;
    z-index: 2;
}

.call-controls {
    position: absolute;
    bottom: 30px;
    left: 0;
    right: 0;
    display: flex;
    justify-content: center;
    gap: 20px;
}

/* ---- Call-event regel (gemist/geweigerd/beëindigd) ---- */
.call-event-pill {
    align-self: center;
    display: flex;
    align-items: center;
    gap: 8px;
    background: #f0eefb;
    color: var(--sigf-navy);
    font-size: 12.5px;
    font-weight: 600;
    padding: 6px 14px;
    border-radius: 999px;
    margin: 4px 0;
}

.call-event-time {
    color: #999;
    font-weight: 400;
    font-size: 11px;
}

/* ---- Bijlage-menu (bestand vs. camera) ---- */
.attach-menu-wrapper {
    position: relative;
}

.attach-menu {
    position: absolute;
    bottom: 48px;
    left: 0;
    background: #fff;
    border-radius: 12px;
    box-shadow: 0 8px 24px rgba(0,0,0,0.15);
    padding: 6px;
    min-width: 170px;
    z-index: 20;
}

.attach-menu button {
    display: flex;
    align-items: center;
    gap: 10px;
    width: 100%;
    background: none;
    background-image: none;
    color: var(--sigf-text);
    font-weight: 600;
    font-size: 13.5px;
    padding: 9px 10px;
    border-radius: 8px;
    text-align: left;
}

.attach-menu button:hover {
    background: var(--sigf-bg);
}

/* ---- In-app camera ---- */
#camera-preview {
    width: 100%;
    height: 100%;
    object-fit: cover;
    position: absolute;
    inset: 0;
}

.camera-controls {
    position: absolute;
    bottom: 30px;
    left: 0;
    right: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 40px;
    z-index: 2;
}

.camera-shutter-btn {
    width: 68px;
    height: 68px;
    border-radius: 50%;
    background: #fff;
    border: 4px solid rgba(255,255,255,0.4);
    padding: 0;
}

#camera-feedback {
    position: absolute;
    top: 20px;
    left: 20px;
    right: 20px;
    text-align: center;
    color: #ff8a80;
    z-index: 2;
}

/* ---- Installeer-banner ---- */
.install-banner {
    display: flex;
    align-items: center;
    gap: 8px;
    margin: 0 16px 14px;
    padding: 10px 12px;
    background: #f1eefc;
    border-radius: 12px;
}

.install-banner-text {
    flex: 1;
    display: flex;
    flex-direction: column;
    min-width: 0;
}

.install-banner-text strong {
    font-size: 13px;
    color: var(--sigf-navy);
}

.install-banner-text span {
    font-size: 11.5px;
    color: #777;
}

.install-banner .secondary-button {
    flex-shrink: 0;
    padding: 7px 12px;
    font-size: 12.5px;
}

.install-banner .text-button {
    flex-shrink: 0;
    font-size: 15px;
    color: #999;
}

.ios-install-steps {
    padding-left: 20px;
    font-size: 14px;
    line-height: 1.8;
}

.ios-share-icon {
    display: inline-block;
    font-weight: 700;
}

/* ---- Meer-opties-menu (blokkeren/rapporteren) ---- */
.header-more-wrapper {
    position: relative;
}

