:root {
    --sn-green: #0f8b4c;
    --sn-green-deep: #0a5d34;
    --sn-yellow: #f4c433;
    --sn-white: #ffffff;
    --sn-blue: #1d6fe8;
    --sn-orange: #f68b1f;
    --sn-ink: #17312a;
    --sn-muted: #68867a;
    --sn-bg: #f4f8f3;
    --sn-card: #ffffff;
    --sn-border: rgba(15, 139, 76, 0.12);
    --sn-shadow: 0 18px 45px rgba(16, 62, 38, 0.12);
    --sn-gold-soft: #fff4cf;
    --sn-gold-ink: #8a5d00;
    --sn-green-soft: #dcf4e6;
    --sn-green-ink: #0b6b3d;
    --sn-red-soft: #ffe2e7;
    --sn-red-ink: #b42345;
    --sn-stone-soft: #edf4f1;
    --sn-stone-ink: #557168;
    --bs-success-rgb: 15, 139, 76;
}

* {
    box-sizing: border-box;
}

body {
    margin: 0;
    min-height: 100vh;
    font-family: 'Manrope', sans-serif;
    color: var(--sn-ink);
    background:
        radial-gradient(circle at top left, rgba(244, 196, 51, 0.22), transparent 32%),
        radial-gradient(circle at top right, rgba(29, 111, 232, 0.12), transparent 24%),
        linear-gradient(180deg, #fefefe 0%, var(--sn-bg) 100%);
}

h1,
h2,
h3,
h4,
h5,
h6,
.btn,
.brand-link strong,
.sidebar-link,
.stat-card h3 {
    font-family: 'Outfit', sans-serif;
}

a {
    text-decoration: none;
}

.brand-link {
    display: inline-flex;
    align-items: center;
    gap: 0.85rem;
    color: var(--sn-ink);
}

.brand-copy {
    display: flex;
    flex-direction: column;
    gap: 0.2rem;
}

.brand-link small {
    display: block;
    color: var(--sn-muted);
}

.notification-topbar-btn {
    display: inline-flex;
    align-items: center;
    gap: 0.65rem;
}

.notification-bell-wrap {
    position: relative;
    display: inline-flex;
    align-items: center;
    justify-content: center;
}

.notification-count {
    position: absolute;
    top: -0.5rem;
    right: -0.65rem;
    min-width: 1.2rem;
    height: 1.2rem;
    padding: 0 0.28rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: linear-gradient(135deg, #dc3545, #ff6b6b);
    color: #fff;
    font-size: 0.68rem;
    font-weight: 800;
    line-height: 1;
    box-shadow: 0 8px 18px rgba(220, 53, 69, 0.28);
}

.brand-logo-badge {
    min-width: clamp(8.75rem, 18vw, 11rem);
    height: 3.4rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.45rem 0.8rem;
    border-radius: 1.1rem;
    background: linear-gradient(135deg, var(--sn-green), var(--sn-yellow));
    box-shadow: 0 10px 24px rgba(15, 139, 76, 0.22);
}

.brand-logo-image {
    display: block;
    width: 100%;
    max-width: 9.75rem;
    height: auto;
    object-fit: contain;
    object-position: center;
}

.brand-link-sidebar {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.55rem;
    text-align: center;
}

.brand-logo-badge-sidebar {
    width: min(100%, 11rem);
    min-width: 0;
    height: auto;
    padding: 0.55rem 0.8rem;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.14);
    box-shadow: none;
}

.sidebar-brand {
    display: flex;
    justify-content: center;
}

.sidebar-panel .brand-copy small {
    color: rgba(255, 255, 255, 0.74);
    text-align: center;
}

.public-topbar,
.public-footer {
    background: rgba(255, 255, 255, 0.9);
    backdrop-filter: blur(14px);
}

.brand-logo-plain {
    display: block;
    width: auto;
    height: auto;
}

.public-topbar .brand-link-topbar {
    gap: 1rem;
}

.public-topbar .brand-logo-plain {
    height: clamp(4rem, 9vw, 4.9rem);
    max-width: min(15rem, 42vw);
    object-fit: contain;
    object-position: left center;
}

.hero-card,
.section-card,
.stat-card,
.action-card,
.table-card,
.profile-card,
.auth-card,
.receipt-card {
    border: 1px solid var(--sn-border);
    border-radius: 1.5rem;
    background: var(--sn-card);
    box-shadow: var(--sn-shadow);
}

.hero-card {
    position: relative;
    overflow: hidden;
}

.hero-card::after {
    content: '';
    position: absolute;
    inset: auto -4rem -4rem auto;
    width: 14rem;
    height: 14rem;
    border-radius: 50%;
    background: radial-gradient(circle, rgba(244, 196, 51, 0.45), transparent 70%);
}

.hero-card .badge-soft {
    display: inline-flex;
    gap: 0.5rem;
    align-items: center;
    padding: 0.65rem 1rem;
    border-radius: 999px;
    background: rgba(15, 139, 76, 0.08);
    color: var(--sn-green-deep);
    font-weight: 700;
}

.section-title {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.25rem;
}

.section-title p {
    margin: 0.4rem 0 0;
    color: var(--sn-muted);
}

.stat-card {
    padding: 1.4rem;
    height: 100%;
}

.stat-card .icon {
    width: 3.25rem;
    height: 3.25rem;
    border-radius: 1rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-size: 1.1rem;
    color: var(--sn-white);
    background: linear-gradient(135deg, var(--sn-green), var(--sn-green-deep));
    margin-bottom: 1rem;
}

.stat-card h3 {
    font-size: 1.9rem;
    margin-bottom: 0.35rem;
}

.stat-card p {
    color: var(--sn-muted);
    margin: 0;
}

.status-card {
    position: relative;
    overflow: hidden;
}

.status-card::after {
    content: '';
    position: absolute;
    inset: 0 0 auto;
    height: 4px;
}

.status-card--recorded {
    background: linear-gradient(180deg, #fffdf6 0%, #ffffff 100%);
    border-color: rgba(244, 196, 51, 0.2);
}

.status-card--recorded::after {
    background: linear-gradient(90deg, var(--sn-yellow), var(--sn-orange));
}

.status-card--recorded .icon {
    background: linear-gradient(135deg, var(--sn-yellow), var(--sn-orange));
    box-shadow: 0 12px 24px rgba(246, 139, 31, 0.2);
}

.status-card--recorded p {
    color: var(--sn-gold-ink);
}

.status-card--validated {
    background: linear-gradient(180deg, #f7fffb 0%, #ffffff 100%);
    border-color: rgba(15, 139, 76, 0.18);
}

.status-card--validated::after {
    background: linear-gradient(90deg, var(--sn-green), var(--sn-green-deep));
}

.status-card--validated .icon {
    box-shadow: 0 12px 24px rgba(15, 139, 76, 0.2);
}

.status-card--validated p {
    color: var(--sn-green-ink);
}

.status-card--pending {
    background: linear-gradient(180deg, #fffdf7 0%, #ffffff 100%);
    border-color: rgba(244, 196, 51, 0.24);
}

.status-card--pending::after {
    background: linear-gradient(90deg, #f7b500, #f68b1f);
}

.status-card--pending .icon {
    background: linear-gradient(135deg, #f7b500, #f68b1f);
    box-shadow: 0 12px 24px rgba(246, 139, 31, 0.18);
}

.status-card--pending p {
    color: var(--sn-gold-ink);
}

.status-card--late {
    background: linear-gradient(180deg, #f8fcfb 0%, #ffffff 100%);
    border-color: rgba(104, 134, 122, 0.22);
}

.status-card--late::after {
    background: linear-gradient(90deg, #7a9288, #516a61);
}

.status-card--late .icon {
    background: linear-gradient(135deg, #7a9288, #516a61);
    box-shadow: 0 12px 24px rgba(81, 106, 97, 0.18);
}

.status-card--late p {
    color: var(--sn-stone-ink);
}

.status-card--refused {
    background: linear-gradient(180deg, #fff9fa 0%, #ffffff 100%);
    border-color: rgba(220, 53, 69, 0.18);
}

.status-card--refused::after {
    background: linear-gradient(90deg, #d63384, #dc3545);
}

.status-card--refused .icon {
    background: linear-gradient(135deg, #d63384, #dc3545);
    box-shadow: 0 12px 24px rgba(220, 53, 69, 0.18);
}

.status-card--refused p {
    color: var(--sn-red-ink);
}

.status-pill {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
    padding: 0.48rem 0.8rem;
    border-radius: 999px;
    border: 1px solid transparent;
    font-size: 0.82rem;
    font-weight: 800;
    line-height: 1;
    white-space: nowrap;
}

.status-pill i {
    font-size: 0.78rem;
}

.status-pill--validated {
    background: var(--sn-green-soft);
    border-color: rgba(15, 139, 76, 0.18);
    color: var(--sn-green-ink);
}

.status-pill--regulariser {
    background: var(--sn-gold-soft);
    border-color: rgba(244, 196, 51, 0.35);
    color: var(--sn-gold-ink);
}

.status-pill--submitted {
    background: rgba(29, 111, 232, 0.1);
    border-color: rgba(29, 111, 232, 0.2);
    color: var(--sn-blue);
}

.status-pill--refused {
    background: var(--sn-red-soft);
    border-color: rgba(220, 53, 69, 0.22);
    color: var(--sn-red-ink);
}

.status-pill--late {
    background: var(--sn-stone-soft);
    border-color: rgba(104, 134, 122, 0.3);
    color: var(--sn-stone-ink);
}

.status-pill--neutral {
    background: rgba(29, 111, 232, 0.08);
    border-color: rgba(29, 111, 232, 0.16);
    color: var(--sn-blue);
}

.status-pill--missing {
    background: rgba(104, 134, 122, 0.12);
    border-color: rgba(104, 134, 122, 0.24);
    color: var(--sn-stone-ink);
}

[data-async-panel-root] {
    transition: opacity 0.18s ease, transform 0.18s ease;
}

[data-async-panel-root].async-panel-loading {
    opacity: 0.62;
    pointer-events: none;
}

[data-users-detail-panel],
[data-admin-tontine-detail] {
    scroll-margin-top: 6rem;
}

.async-detail-panel-focus {
    animation: asyncDetailPulse 1.2s ease;
}

.admin-pin-button {
    width: 2.45rem;
    height: 2.45rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1px solid rgba(15, 139, 76, 0.16);
    border-radius: 0.9rem;
    background: #fff;
    color: var(--sn-muted);
    transition: transform 0.18s ease, box-shadow 0.18s ease, border-color 0.18s ease, color 0.18s ease, background 0.18s ease;
}

.admin-pin-button:hover {
    color: var(--sn-green-deep);
    border-color: rgba(15, 139, 76, 0.3);
    box-shadow: 0 12px 24px rgba(15, 139, 76, 0.12);
    transform: translateY(-1px);
}

.admin-pin-button.is-pinned {
    color: var(--sn-gold-ink);
    border-color: rgba(244, 196, 51, 0.45);
    background: linear-gradient(135deg, #fff9df, #fff1bc);
    box-shadow: 0 12px 22px rgba(244, 196, 51, 0.18);
}

.table tr.is-pinned-row > * {
    background: linear-gradient(90deg, rgba(244, 196, 51, 0.08), rgba(255, 255, 255, 0));
}

.table tr.is-pinned-row > :first-child {
    box-shadow: inset 4px 0 0 var(--sn-yellow);
}

@keyframes asyncDetailPulse {
    0% {
        transform: translateY(0);
        filter: saturate(1);
    }
    35% {
        transform: translateY(-4px);
        filter: saturate(1.08);
    }
    100% {
        transform: translateY(0);
        filter: saturate(1);
    }
}

.app-shell {
    display: flex;
    min-height: 100vh;
}

.mobile-nav-bar,
.sidebar-mobile-head,
.sidebar-backdrop {
    display: none;
}

.sidebar-panel {
    width: 300px;
    padding: 1.1rem;
    color: var(--sn-white);
    background:
        linear-gradient(180deg, rgba(8, 65, 37, 0.96), rgba(15, 139, 76, 0.96)),
        linear-gradient(135deg, rgba(244, 196, 51, 0.12), transparent);
    position: sticky;
    top: 0;
    height: 100vh;
    display: flex;
    flex-direction: column;
    gap: 0.9rem;
    overflow: hidden;
}

.sidebar-user-card {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.9rem;
    border-radius: 1.2rem;
    background: rgba(255, 255, 255, 0.08);
}

.avatar-circle {
    width: 3rem;
    height: 3rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: rgba(244, 196, 51, 0.2);
    font-weight: 800;
    color: var(--sn-yellow);
    overflow: hidden;
    flex-shrink: 0;
}

.avatar-photo {
    display: block;
    object-fit: cover;
    object-position: center;
    padding: 0;
    background: rgba(255, 255, 255, 0.12);
    border: 2px solid rgba(255, 255, 255, 0.18);
}

.avatar-photo-large {
    width: 4.5rem;
    height: 4.5rem;
}

.sidebar-nav {
    display: flex;
    flex-direction: column;
    gap: 0.35rem;
    flex: 1;
    min-height: 0;
    overflow-y: auto;
    padding-right: 0.25rem;
    scrollbar-width: thin;
    scrollbar-color: rgba(255, 255, 255, 0.25) transparent;
}

.sidebar-link {
    display: flex;
    align-items: center;
    gap: 0.85rem;
    padding: 0.8rem 0.95rem;
    border-radius: 1rem;
    color: rgba(255, 255, 255, 0.84);
    transition: all 0.2s ease;
}

.sidebar-link:hover,
.sidebar-link.active {
    background: rgba(255, 255, 255, 0.12);
    color: var(--sn-white);
    transform: translateX(4px);
}

.sidebar-link-badge {
    margin-left: auto;
    min-width: 1.5rem;
    height: 1.5rem;
    padding: 0 0.35rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 999px;
    background: rgba(244, 196, 51, 0.18);
    color: var(--sn-yellow);
    font-size: 0.74rem;
    font-weight: 800;
}

.sidebar-footer {
    flex-shrink: 0;
    padding-top: 0.35rem;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.sidebar-nav::-webkit-scrollbar {
    width: 8px;
}

.sidebar-nav::-webkit-scrollbar-track {
    background: transparent;
}

.sidebar-nav::-webkit-scrollbar-thumb {
    background: rgba(255, 255, 255, 0.2);
    border-radius: 999px;
}

.sidebar-nav::-webkit-scrollbar-thumb:hover {
    background: rgba(255, 255, 255, 0.32);
}

.app-main {
    flex: 1;
    min-width: 0;
}

.app-main-inner {
    padding: 2rem;
}

.page-header {
    margin-bottom: 1.5rem;
}

.page-header h1 {
    font-size: clamp(1.8rem, 3vw, 2.6rem);
    margin-bottom: 0.4rem;
}

.page-header p {
    color: var(--sn-muted);
    margin: 0;
}

.page-header-row {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    margin-bottom: 1.5rem;
}

.page-header-row .page-header {
    margin-bottom: 0;
}

.action-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 1rem;
}

.action-card {
    padding: 1.3rem;
    display: flex;
    flex-direction: column;
    justify-content: space-between;
    gap: 1rem;
    min-height: 170px;
}

.action-card .action-icon {
    width: 3.1rem;
    height: 3.1rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 1rem;
    color: var(--sn-white);
    font-size: 1.1rem;
}

.action-card.wave .action-icon,
.btn-wave {
    background: linear-gradient(135deg, #0b57cf, var(--sn-blue));
    color: var(--sn-white);
}

.action-card.orange .action-icon,
.btn-orange {
    background: linear-gradient(135deg, #d86700, var(--sn-orange));
    color: var(--sn-white);
}

.action-card.cash .action-icon,
.btn-cash {
    background: linear-gradient(135deg, var(--sn-green-deep), var(--sn-green));
    color: var(--sn-white);
}

.action-card.profile .action-icon {
    background: linear-gradient(135deg, var(--sn-green), var(--sn-yellow));
}

.action-card.unavailable-card,
.coming-soon-card {
    position: relative;
    border: 1px solid rgba(15, 139, 76, 0.12);
    background:
        linear-gradient(180deg, rgba(255, 255, 255, 0.96), rgba(247, 250, 248, 0.96)),
        radial-gradient(circle at top right, rgba(244, 196, 51, 0.12), transparent 35%);
}

.action-card.unavailable-card::after,
.coming-soon-card::after {
    content: "Bientot";
    position: absolute;
    top: 1rem;
    right: 1rem;
    padding: 0.28rem 0.65rem;
    border-radius: 999px;
    font-size: 0.74rem;
    font-weight: 800;
    letter-spacing: 0.04em;
    text-transform: uppercase;
    color: #7d6206;
    background: rgba(244, 196, 51, 0.18);
}

.coming-soon-grid {
    display: grid;
    gap: 1rem;
}

.coming-soon-card {
    padding: 1.25rem;
    border-radius: 1.2rem;
}

.coming-soon-card .action-icon {
    width: 3.1rem;
    height: 3.1rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 1rem;
    color: var(--sn-white);
    font-size: 1.1rem;
}

.coming-soon-card.wave .action-icon {
    background: linear-gradient(135deg, #0b57cf, var(--sn-blue));
}

.coming-soon-card.orange .action-icon {
    background: linear-gradient(135deg, #d86700, var(--sn-orange));
}

.coming-soon-card.cardbank .action-icon {
    background: linear-gradient(135deg, #0c5b48, #173b6a);
}

.beneficiary-drag-handle {
    width: 2.75rem;
    height: 2.75rem;
    border: 1px dashed rgba(15, 139, 76, 0.28);
    border-radius: 0.95rem;
    background: rgba(15, 139, 76, 0.06);
    color: var(--sn-green-deep);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: grab;
    transition: transform 0.18s ease, background 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease;
}

.beneficiary-drag-handle:hover,
.beneficiary-drag-handle:focus-visible {
    background: rgba(15, 139, 76, 0.12);
    border-color: rgba(15, 139, 76, 0.5);
    box-shadow: 0 10px 22px rgba(15, 139, 76, 0.12);
    transform: translateY(-1px);
}

.beneficiary-drag-handle:active {
    cursor: grabbing;
}

.beneficiary-drag-handle--inline {
    width: 2.25rem;
    height: 2.25rem;
}

.position-arrow-stack {
    display: inline-flex;
    align-items: center;
    gap: 0.45rem;
}

.beneficiary-order-arrow {
    width: 2.25rem;
    height: 2.25rem;
    border: 1px solid rgba(15, 139, 76, 0.2);
    border-radius: 0.8rem;
    background: #fff;
    color: var(--sn-green-deep);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    transition: transform 0.18s ease, background 0.18s ease, border-color 0.18s ease, box-shadow 0.18s ease, opacity 0.18s ease;
}

.beneficiary-order-arrow:hover,
.beneficiary-order-arrow:focus-visible {
    background: rgba(15, 139, 76, 0.08);
    border-color: rgba(15, 139, 76, 0.42);
    box-shadow: 0 10px 20px rgba(15, 139, 76, 0.12);
    transform: translateY(-1px);
}

.beneficiary-order-arrow:disabled {
    opacity: 0.45;
    cursor: not-allowed;
    box-shadow: none;
    transform: none;
}

.beneficiary-position-badge {
    min-width: 2.4rem;
    height: 2.25rem;
    padding: 0 0.85rem;
    border-radius: 999px;
    background: rgba(15, 139, 76, 0.12);
    color: var(--sn-green-deep);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    font-weight: 700;
}

[data-sortable-position-row] {
    transition: background-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

[data-import-sortable-row] {
    transition: background-color 0.18s ease, box-shadow 0.18s ease, transform 0.18s ease;
}

.beneficiary-row-dragging {
    opacity: 0.72;
    background: rgba(15, 139, 76, 0.08);
}

.beneficiary-row-drop-target td {
    box-shadow: inset 0 3px 0 var(--sn-yellow);
}

.live-filter-toolbar {
    padding: 1rem 1.1rem;
    border: 1px solid rgba(15, 139, 76, 0.12);
    border-radius: 1rem;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0.98), rgba(247, 255, 251, 0.92));
}

.live-filter-meta {
    display: inline-flex;
    align-items: center;
    justify-content: flex-end;
    min-height: 2.75rem;
    font-weight: 600;
}

.pwa-install-button {
    position: fixed;
    right: 1rem;
    bottom: 1rem;
    z-index: 1085;
    border: 0;
    border-radius: 999px;
    padding: 0.9rem 1.15rem;
    background: linear-gradient(135deg, var(--sn-green), var(--sn-green-deep));
    color: #fff;
    box-shadow: 0 18px 34px rgba(15, 139, 76, 0.28);
    display: inline-flex;
    align-items: center;
    gap: 0.6rem;
    font-weight: 700;
    transition: transform 0.18s ease, box-shadow 0.18s ease, opacity 0.18s ease;
}

.pwa-install-button:hover,
.pwa-install-button:focus-visible {
    transform: translateY(-2px);
    box-shadow: 0 24px 40px rgba(15, 139, 76, 0.35);
}

.pwa-install-button i {
    font-size: 1rem;
}

@media (max-width: 575.98px) {
    .pwa-install-button {
        right: 0.75rem;
        left: 0.75rem;
        bottom: 0.85rem;
        justify-content: center;
    }
}

.action-card .btn[disabled],
.coming-soon-card .btn[disabled] {
    opacity: 1;
    cursor: not-allowed;
    box-shadow: none;
}

.action-card .btn-outline-dark[disabled],
.coming-soon-card .btn-outline-dark[disabled] {
    color: #22303a;
    border-color: rgba(34, 48, 58, 0.28);
    background: rgba(255, 255, 255, 0.85);
}

.btn {
    border-radius: 1rem;
    font-weight: 700;
}

.btn-lg {
    padding: 0.95rem 1.2rem;
}

.btn-success,
.btn-outline-success:hover {
    background-color: var(--sn-green);
    border-color: var(--sn-green);
}

.table-card,
.section-card,
.profile-card,
.receipt-card,
.auth-card {
    padding: 1.4rem;
}

.table thead th {
    border-bottom-width: 1px;
    color: var(--sn-muted);
    font-size: 0.9rem;
}

.table tbody tr {
    vertical-align: middle;
}

.table tbody tr.payment-row {
    transition: transform 0.16s ease, box-shadow 0.18s ease;
}

.table tbody tr.payment-row > td {
    background-clip: padding-box;
    transition: background-color 0.18s ease, border-color 0.18s ease;
}

.table tbody tr.payment-row > td:first-child {
    border-left: 4px solid transparent;
}

.table tbody tr.payment-row:hover {
    transform: translateY(-1px);
}

.table tbody tr.payment-row:hover > td {
    box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.55), inset 0 -1px 0 rgba(12, 38, 26, 0.04);
}

.table tbody tr.payment-row--validated > td {
    background: rgba(15, 139, 76, 0.06);
}

.table tbody tr.payment-row--validated > td:first-child {
    border-left-color: var(--sn-green);
}

.table tbody tr.payment-row--validated:hover > td {
    background: rgba(15, 139, 76, 0.1);
}

.table tbody tr.payment-row--regulariser > td {
    background: rgba(244, 196, 51, 0.12);
}

.table tbody tr.payment-row--regulariser > td:first-child {
    border-left-color: var(--sn-yellow);
}

.table tbody tr.payment-row--regulariser:hover > td {
    background: rgba(244, 196, 51, 0.18);
}

.table tbody tr.payment-row--refused > td {
    background: rgba(220, 53, 69, 0.08);
}

.table tbody tr.payment-row--refused > td:first-child {
    border-left-color: #dc3545;
}

.table tbody tr.payment-row--refused:hover > td {
    background: rgba(220, 53, 69, 0.13);
}

.table tbody tr.payment-row--late > td {
    background: rgba(104, 134, 122, 0.11);
}

.table tbody tr.payment-row--late > td:first-child {
    border-left-color: #68867a;
}

.table tbody tr.payment-row--late:hover > td {
    background: rgba(104, 134, 122, 0.17);
}

.table tbody tr.payment-row--neutral > td {
    background: rgba(29, 111, 232, 0.06);
}

.table tbody tr.payment-row--neutral > td:first-child {
    border-left-color: var(--sn-blue);
}

.table tbody tr.payment-row--neutral:hover > td {
    background: rgba(29, 111, 232, 0.1);
}

.auth-shell {
    min-height: 100vh;
    display: grid;
    place-items: center;
    padding: 2rem 1rem;
}

.auth-card {
    width: min(100%, 1080px);
    overflow: hidden;
}

.auth-split {
    display: grid;
    grid-template-columns: 1.2fr 0.9fr;
    gap: 0;
}

.auth-showcase {
    padding: 2.5rem;
    color: var(--sn-white);
    background:
        linear-gradient(135deg, rgba(15, 139, 76, 0.96), rgba(10, 93, 52, 0.95)),
        radial-gradient(circle at top right, rgba(244, 196, 51, 0.35), transparent 30%);
}

.auth-logo {
    display: flex;
    justify-content: center;
}

.auth-logo-frame {
    width: min(100%, 13rem);
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.7rem 0.9rem;
    border-radius: 1.15rem;
    background: rgba(255, 255, 255, 0.08);
    border: 1px solid rgba(255, 255, 255, 0.14);
    box-shadow: 0 18px 34px rgba(6, 34, 21, 0.16);
}

.auth-logo-image {
    display: block;
    width: 100%;
    max-width: 10.75rem;
    height: auto;
    object-fit: contain;
    object-position: center;
}

.auth-showcase .mini-stat {
    padding: 1rem;
    border-radius: 1rem;
    background: rgba(255, 255, 255, 0.08);
}

.auth-form-panel {
    padding: 2.5rem;
    background: rgba(255, 255, 255, 0.92);
}

.dashboard-user-shell {
    padding: 1.6rem 0 3rem;
}

.timeline-item {
    display: flex;
    align-items: center;
    gap: 1rem;
    padding: 0.95rem 0;
    border-bottom: 1px dashed rgba(104, 134, 122, 0.25);
}

.timeline-item:last-child {
    border-bottom: 0;
}

.timeline-bullet {
    width: 2.7rem;
    height: 2.7rem;
    border-radius: 0.9rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    background: rgba(15, 139, 76, 0.12);
    color: var(--sn-green);
    flex-shrink: 0;
}

.receipt-card {
    max-width: 900px;
    margin: 2rem auto;
}

.receipt-head {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 1rem;
    padding-bottom: 1rem;
    border-bottom: 1px solid rgba(104, 134, 122, 0.2);
}

.receipt-brand {
    display: inline-flex;
    align-items: center;
    gap: 1rem;
    flex-wrap: wrap;
}

.receipt-brand-badge {
    width: clamp(10.5rem, 18vw, 12.25rem);
    min-width: clamp(10.5rem, 18vw, 12.25rem);
    height: 4.25rem;
    padding: 0.5rem 0.95rem;
    flex-shrink: 0;
}

.receipt-brand-logo {
    display: block;
    width: 100%;
    max-width: none;
    max-height: 5.35rem;
    height: auto;
    object-fit: contain;
    object-position: center;
}

.receipt-brand-copy {
    display: flex;
    flex-direction: column;
    justify-content: center;
    min-width: 0;
}

.receipt-brand-copy small {
    color: var(--sn-muted);
    font-size: 1.05rem;
}

.receipt-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.receipt-box {
    padding: 1rem;
    border-radius: 1rem;
    background: rgba(15, 139, 76, 0.05);
}

.notification-item {
    display: flex;
    gap: 1rem;
    padding: 1rem 0;
    border-bottom: 1px dashed rgba(104, 134, 122, 0.25);
}

.notification-item:last-child {
    border-bottom: 0;
    padding-bottom: 0;
}

.notification-item.unread {
    background: linear-gradient(90deg, rgba(29, 111, 232, 0.06), transparent 32%);
    border-radius: 1rem;
    padding: 1rem;
    margin-bottom: 0.85rem;
    border: 1px solid rgba(29, 111, 232, 0.12);
}

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

.notification-icon {
    width: 3rem;
    height: 3rem;
    border-radius: 1rem;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
    color: #fff;
    background: linear-gradient(135deg, var(--sn-blue), #3d87f2);
}

.notification-icon.success {
    background: linear-gradient(135deg, var(--sn-green), var(--sn-green-deep));
}

.notification-icon.warning {
    background: linear-gradient(135deg, var(--sn-yellow), #f68b1f);
}

.notification-icon.danger {
    background: linear-gradient(135deg, #d63384, #dc3545);
}

.profile-reminder-alert {
    display: flex;
    align-items: center;
    border-radius: 1rem;
    border: 1px solid rgba(190, 31, 31, 0.18);
    box-shadow: 0 16px 32px rgba(181, 31, 31, 0.1);
}

.identity-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.identity-card {
    padding: 1rem;
    border: 1px solid var(--sn-border);
    border-radius: 1rem;
    background: rgba(255, 255, 255, 0.92);
}

.identity-preview-image {
    display: block;
    width: 100%;
    height: 12rem;
    object-fit: cover;
    border-radius: 0.9rem;
    border: 1px solid rgba(15, 139, 76, 0.12);
}

.identity-empty {
    display: grid;
    place-items: center;
    min-height: 12rem;
    padding: 1rem;
    text-align: center;
    border-radius: 0.9rem;
    border: 1px dashed rgba(15, 139, 76, 0.22);
    color: var(--sn-muted);
    background: rgba(15, 139, 76, 0.04);
}

.identity-gallery {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 1rem;
}

.tontine-checklist {
    display: grid;
    gap: 0.85rem;
}

.tontine-check {
    display: flex;
    gap: 0.85rem;
    align-items: flex-start;
    padding: 0.9rem 1rem;
    border: 1px solid var(--sn-border);
    border-radius: 1rem;
    background: rgba(255, 255, 255, 0.88);
    transition: border-color 0.2s ease, box-shadow 0.2s ease, transform 0.2s ease;
}

.tontine-check:hover {
    border-color: rgba(15, 139, 76, 0.35);
    box-shadow: 0 10px 24px rgba(15, 139, 76, 0.08);
    transform: translateY(-1px);
}

.tontine-check .form-check-input {
    float: none;
    margin: 0.15rem 0 0;
    flex-shrink: 0;
}

.tontine-check .form-check-label {
    width: 100%;
    cursor: pointer;
}

.empty-state {
    padding: 2rem;
    border-radius: 1.5rem;
    text-align: center;
    background: rgba(255, 255, 255, 0.74);
    border: 1px dashed rgba(15, 139, 76, 0.2);
}

.metric-pill {
    display: inline-flex;
    gap: 0.5rem;
    align-items: center;
    padding: 0.65rem 1rem;
    border-radius: 999px;
    font-weight: 700;
    background: rgba(244, 196, 51, 0.18);
    color: #7d6206;
}

.invitation-card {
    padding: 1rem 1.1rem;
    border-radius: 1.15rem;
    border: 1px solid rgba(15, 139, 76, 0.16);
    background: linear-gradient(180deg, rgba(244, 248, 243, 0.9), rgba(255, 255, 255, 0.98));
}

.invitation-code {
    display: inline-flex;
    align-items: center;
    padding: 0.55rem 0.9rem;
    border-radius: 0.85rem;
    background: rgba(15, 139, 76, 0.1);
    color: var(--sn-green-deep);
    font-family: 'Outfit', sans-serif;
    font-size: 1.05rem;
    font-weight: 800;
    letter-spacing: 0.08em;
}

.invitation-qr-panel {
    min-width: 140px;
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 0.55rem;
}

.invitation-qr {
    width: 128px;
    min-height: 128px;
    padding: 0.45rem;
    display: grid;
    place-items: center;
    border-radius: 1rem;
    background: #ffffff;
    border: 1px solid rgba(15, 139, 76, 0.12);
    box-shadow: 0 8px 24px rgba(15, 139, 76, 0.08);
}

.invitation-qr img,
.invitation-qr canvas {
    display: block;
    max-width: 100%;
    height: auto;
}

.invitation-history {
    margin-bottom: 1rem;
    display: grid;
    gap: 0.75rem;
}

.whatsapp-share-panel {
    padding-top: 0.25rem;
}

.invitation-history-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 0.85rem 1rem;
    border-radius: 1rem;
    background: rgba(255, 255, 255, 0.88);
    border: 1px solid rgba(15, 139, 76, 0.1);
}

@media (max-width: 991.98px) {
    .app-shell {
        display: block;
        min-height: auto;
    }

    .mobile-nav-bar {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 1rem;
        position: sticky;
        top: 0;
        z-index: 1045;
        padding: 0.9rem 1rem;
        background:
            linear-gradient(180deg, rgba(8, 65, 37, 0.98), rgba(15, 139, 76, 0.98)),
            linear-gradient(135deg, rgba(244, 196, 51, 0.14), transparent);
        box-shadow: 0 10px 28px rgba(10, 40, 24, 0.18);
    }

    .mobile-nav-brand {
        display: inline-flex;
        align-items: center;
    }

    .mobile-nav-actions {
        display: inline-flex;
        align-items: center;
        gap: 0.7rem;
    }

    .mobile-nav-logo {
        display: block;
        width: auto;
        height: 2.3rem;
        object-fit: contain;
        object-position: center;
    }

    .mobile-nav-notification,
    .mobile-nav-logout,
    .mobile-nav-toggle,
    .sidebar-mobile-close {
        width: 2.85rem;
        height: 2.85rem;
        display: inline-flex;
        align-items: center;
        justify-content: center;
        border: 1px solid rgba(255, 255, 255, 0.16);
        border-radius: 0.95rem;
        background: rgba(255, 255, 255, 0.08);
        color: #ffffff;
        font-size: 1.2rem;
        box-shadow: none;
        text-decoration: none;
    }

    .sidebar-backdrop {
        display: block;
        position: fixed;
        inset: 0;
        border: 0;
        padding: 0;
        background: rgba(7, 24, 16, 0.48);
        opacity: 0;
        pointer-events: none;
        transition: opacity 0.25s ease;
        z-index: 1048;
    }

    .sidebar-panel {
        width: min(300px, 86vw);
        height: 100dvh;
        position: fixed;
        inset: 0 auto 0 0;
        z-index: 1049;
        overflow: hidden;
        transform: translateX(-100%);
        transition: transform 0.25s ease;
        box-shadow: 0 22px 48px rgba(5, 26, 16, 0.3);
        padding-top: 0.95rem;
    }

    .sidebar-mobile-head {
        display: flex;
        align-items: center;
        justify-content: space-between;
        gap: 1rem;
    }

    .sidebar-mobile-title {
        font-family: 'Outfit', sans-serif;
        font-size: 1.1rem;
        font-weight: 700;
        color: rgba(255, 255, 255, 0.88);
    }

    .sidebar-nav {
        overflow-y: auto;
        min-height: 0;
        padding-right: 0;
    }

    .sidebar-footer {
        display: none;
    }

    body.sidebar-open {
        overflow: hidden;
    }

    body.sidebar-open .sidebar-panel {
        transform: translateX(0);
    }

    body.sidebar-open .sidebar-backdrop {
        opacity: 1;
        pointer-events: auto;
    }

    .auth-split,
    .receipt-grid {
        grid-template-columns: 1fr;
    }

    .invitation-history-item {
        flex-direction: column;
        align-items: flex-start;
    }
}

@media (max-width: 767.98px) {
    .app-main-inner,
    .auth-showcase,
    .auth-form-panel {
        padding: 1.25rem;
    }

    .brand-link {
        align-items: flex-start;
    }

    .receipt-brand {
        gap: 0.75rem;
    }

    .receipt-brand-badge {
        width: 11.25rem;
        min-width: 11.25rem;
        height: 4rem;
        padding: 0.45rem 0.85rem;
    }

    .receipt-brand-logo {
        max-height: 3.05rem;
    }

    .receipt-brand-copy small {
        font-size: 0.95rem;
    }

    .brand-logo-badge {
        min-width: 0;
        width: 100%;
        max-width: 10.5rem;
    }

    .identity-grid,
    .identity-gallery {
        grid-template-columns: 1fr;
    }

    .page-header-row {
        flex-direction: column;
        align-items: stretch;
    }

    .page-header h1 {
        font-size: 1.7rem;
    }

    .invitation-qr-panel {
        width: 100%;
    }
}

@media print {
    .public-topbar,
    .public-footer,
    .btn,
    .no-print {
        display: none !important;
    }

    body {
        background: #fff;
    }

    .receipt-card {
        box-shadow: none;
        border: 0;
        margin: 0;
        max-width: 100%;
    }
}
