/* App shell: notifications, inbox, profile dashboard, radius filter */

:root {
    --shell-green: #05a243;
    --shell-green-dark: #038b38;
    --shell-green-soft: #e8f7ee;
    --shell-yellow: #fbae00;
    --shell-text: #1f2937;
    --shell-muted: #6b7280;
    --shell-border: #e5e7eb;
    --shell-bg: #f8f9fa;
}

/* Shared drawer / panel */
.shell-overlay {
    position: fixed;
    inset: 0;
    z-index: 1500;
    display: none;
}

.shell-overlay.is-open {
    display: block;
}

.shell-backdrop {
    position: absolute;
    inset: 0;
    background: rgba(15, 23, 42, 0.4);
    backdrop-filter: blur(2px);
    border: none;
    padding: 0;
    cursor: pointer;
}

.shell-panel {
    position: absolute;
    top: 0;
    right: 0;
    height: 100%;
    width: min(420px, 100%);
    background: var(--shell-bg);
    box-shadow: -12px 0 40px rgba(15, 23, 42, 0.2);
    display: flex;
    flex-direction: column;
    font-family: 'Poppins', sans-serif;
    transform: translateX(100%);
    transition: transform 0.28s ease;
}

.shell-overlay.is-open .shell-panel {
    transform: translateX(0);
}

.shell-panel-header {
    background: var(--shell-green);
    color: #fff;
    padding: 18px 16px;
    display: flex;
    align-items: center;
    gap: 12px;
    flex-shrink: 0;
}

.shell-panel-header h2 {
    margin: 0;
    font-size: 1.15rem;
    font-weight: 600;
}

.shell-icon-btn {
    border: none;
    background: transparent;
    color: inherit;
    width: 40px;
    height: 40px;
    border-radius: 999px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    font-size: 1.1rem;
}

.shell-icon-btn:hover {
    background: rgba(255, 255, 255, 0.12);
}

.shell-tabs {
    display: flex;
    background: #fff;
    border: 1px solid var(--shell-border);
    border-radius: 10px;
    overflow: hidden;
    margin: 16px;
    flex-shrink: 0;
}

.shell-tab {
    flex: 1;
    border: none;
    background: #fff;
    color: #9ca3af;
    font-weight: 600;
    font-size: 0.85rem;
    padding: 12px 8px;
    cursor: pointer;
    font-family: inherit;
}

.shell-tab.is-active {
    background: var(--shell-green);
    color: #fff;
}

.shell-empty {
    flex: 1;
    display: flex;
    flex-direction: column;
    align-items: center;
    justify-content: center;
    padding: 32px 24px 80px;
    color: rgba(156, 163, 175, 0.95);
    text-align: center;
}

.shell-empty-art {
    position: relative;
    width: 180px;
    height: 180px;
    margin-bottom: 12px;
}

.shell-empty-art .fa-search {
    font-size: 6.5rem;
    color: #91d1ab;
    position: absolute;
    inset: 0;
    display: flex;
    align-items: center;
    justify-content: center;
}

.shell-empty p {
    margin: 0;
    font-size: 1.05rem;
    font-weight: 500;
}

.shell-notif-list {
    list-style: none;
    margin: 0;
    padding: 8px 0 24px;
    overflow: auto;
    flex: 1;
}

.shell-notif-item {
    display: flex;
    gap: 12px;
    padding: 14px 18px;
    border-bottom: 1px solid #eef2f7;
    background: #fff;
}

.shell-notif-item i {
    color: var(--shell-green);
    font-size: 1.1rem;
    margin-top: 2px;
}

.shell-notif-item strong {
    display: block;
    color: var(--shell-text);
    font-size: 0.92rem;
    margin-bottom: 2px;
}

.shell-notif-item span {
    color: var(--shell-muted);
    font-size: 0.8rem;
    line-height: 1.4;
}

/* Radius filter modal */
.radius-modal {
    position: fixed;
    inset: 0;
    z-index: 1600;
    display: none;
    align-items: center;
    justify-content: center;
    padding: 20px;
    font-family: 'Poppins', sans-serif;
}

.radius-modal.is-open {
    display: flex;
}

.radius-dialog {
    position: relative;
    z-index: 1;
    width: min(420px, 100%);
    background: #fff;
    border-radius: 24px;
    padding: 24px;
    box-shadow: 0 24px 60px rgba(15, 23, 42, 0.25);
}

.radius-dialog-head {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 28px;
}

.radius-dialog-head h2 {
    margin: 0;
    font-size: 1.15rem;
    font-weight: 700;
    color: var(--shell-text);
}

.radius-clear {
    border: none;
    background: var(--shell-green);
    color: #fff;
    border-radius: 999px;
    padding: 8px 16px;
    font-weight: 600;
    font-size: 0.85rem;
    cursor: pointer;
    font-family: inherit;
}

.radius-options {
    display: grid;
    gap: 18px;
    margin-bottom: 28px;
}

.radius-option {
    display: flex;
    align-items: center;
    gap: 14px;
    cursor: pointer;
    font-weight: 500;
    color: var(--shell-text);
    font-size: 1.05rem;
}

.radius-option input {
    appearance: none;
    width: 1.4rem;
    height: 1.4rem;
    border: 2px solid var(--shell-green);
    border-radius: 50%;
    display: grid;
    place-content: center;
    margin: 0;
    flex-shrink: 0;
}

.radius-option input::before {
    content: '';
    width: 0.7rem;
    height: 0.7rem;
    border-radius: 50%;
    transform: scale(0);
    background: var(--shell-green);
    transition: transform 0.12s ease;
}

.radius-option input:checked::before {
    transform: scale(1);
}

.radius-apply {
    width: 100%;
    border: none;
    background: var(--shell-green);
    color: #fff;
    border-radius: 12px;
    padding: 12px 16px;
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    font-family: inherit;
}

.radius-apply:hover,
.radius-clear:hover {
    background: var(--shell-green-dark);
}

/* Profile dashboard */
.profile-view {
    display: none;
    position: relative;
    z-index: 50;
    background: var(--shell-bg);
    min-height: calc(100vh - 84px);
    padding: 28px clamp(12px, 3vw, 32px) 48px;
    font-family: 'Poppins', sans-serif;
}

.profile-view.is-open {
    display: block;
}

body.profile-open #pageHome {
    display: none;
}

body.profile-open {
    overflow: auto;
}

.profile-layout {
    max-width: 1120px;
    margin: 0 auto;
    display: grid;
    grid-template-columns: 300px minmax(0, 1fr);
    gap: 24px;
    align-items: start;
}

.profile-sidebar {
    background: #fff;
    border: 1px solid var(--shell-border);
    border-radius: 24px;
    overflow: hidden;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
    position: sticky;
    top: 100px;
    max-height: calc(100vh - 120px);
    display: flex;
    flex-direction: column;
}

.profile-sidebar-head {
    background: var(--shell-green);
    color: #fff;
    text-align: center;
    padding: 28px 16px 20px;
}

.profile-sidebar-head img {
    width: 88px;
    height: 88px;
    border-radius: 50%;
    object-fit: cover;
    border: 3px solid #fff;
    margin-bottom: 10px;
}

.profile-sidebar-head h2 {
    margin: 0;
    font-size: 1.35rem;
}

.profile-sidebar-head p {
    margin: 4px 0 0;
    font-size: 0.85rem;
    opacity: 0.92;
}

.profile-nav {
    overflow: auto;
    padding: 8px 0 12px;
}

.profile-nav-btn {
    width: 100%;
    border: none;
    background: transparent;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 12px 18px;
    cursor: pointer;
    border-right: 4px solid transparent;
    font-family: inherit;
    text-align: left;
}

.profile-nav-btn:hover {
    background: #f9fafb;
}

.profile-nav-btn.is-active {
    background: var(--shell-green-soft);
    border-right-color: var(--shell-green);
}

.profile-nav-main {
    display: flex;
    align-items: center;
    gap: 12px;
    min-width: 0;
}

.profile-nav-icon {
    width: 38px;
    height: 38px;
    border-radius: 50%;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    color: #fff;
    flex-shrink: 0;
}

.profile-nav-btn .nav-text {
    color: var(--shell-green);
    font-weight: 600;
    font-size: 0.98rem;
}

.profile-nav-btn .nav-chevron {
    color: var(--shell-green);
    font-size: 0.8rem;
    opacity: 0;
}

.profile-nav-btn.is-active .nav-chevron,
.profile-nav-btn:hover .nav-chevron {
    opacity: 1;
}

.profile-content {
    background: #fff;
    border: 1px solid var(--shell-border);
    border-radius: 24px;
    box-shadow: 0 1px 2px rgba(15, 23, 42, 0.04);
    padding: 24px;
    min-height: 640px;
}

.profile-content-title {
    margin: 0 0 18px;
    padding-bottom: 14px;
    border-bottom: 1px solid var(--shell-border);
    font-size: 1.4rem;
    font-weight: 700;
    color: var(--shell-text);
}

.dashboard-panel {
    display: none;
}

.dashboard-panel.is-active {
    display: block;
}

.history-tabs {
    display: flex;
    border: 1px solid var(--shell-border);
    border-radius: 10px;
    overflow: hidden;
    margin-bottom: 18px;
    max-width: 560px;
}

.history-tabs button {
    flex: 1;
    border: none;
    background: #fff;
    color: #9ca3af;
    font-weight: 600;
    padding: 12px;
    cursor: pointer;
    font-family: inherit;
}

.history-tabs button.is-active {
    background: var(--shell-green);
    color: #fff;
}

.profile-card {
    background: #fff;
    border: 1px solid var(--shell-border);
    border-radius: 16px;
    padding: 18px;
    margin-bottom: 14px;
}

.profile-card h3 {
    margin: 0 0 10px;
    color: var(--shell-green);
    font-size: 1.05rem;
}

.profile-card ol {
    margin: 0;
    padding-left: 18px;
    color: var(--shell-text);
}

.verify-level {
    border-radius: 16px;
    padding: 18px;
    margin-bottom: 12px;
    color: #fff;
    background: var(--shell-green);
}

.verify-level.is-pending {
    background: #fff;
    color: var(--shell-text);
    border: 1px solid var(--shell-border);
}

.verify-level-top {
    display: flex;
    justify-content: space-between;
    font-weight: 700;
    margin-bottom: 8px;
}

.wallet-card {
    background: linear-gradient(135deg, #3bde86, #12a15c);
    color: #fff;
    border-radius: 22px;
    padding: 24px;
    margin-bottom: 18px;
}

.wallet-card .balance {
    text-align: center;
    margin: 18px 0 22px;
}

.wallet-card .balance strong {
    display: block;
    font-size: 2.2rem;
    color: #ffdf00;
}

.wallet-meta {
    display: flex;
    justify-content: space-between;
    gap: 12px;
    font-size: 0.9rem;
}

.wallet-actions {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
}

.wallet-action {
    border: 2px solid var(--shell-green);
    background: #fff;
    border-radius: 14px;
    padding: 16px 10px;
    text-align: center;
    font-weight: 600;
    font-size: 0.82rem;
    color: var(--shell-text);
    cursor: pointer;
    font-family: inherit;
}

.wallet-action i {
    display: block;
    color: var(--shell-green);
    font-size: 1.4rem;
    margin-bottom: 8px;
}

.stats-row {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    border: 1px solid var(--shell-border);
    border-radius: 16px;
    overflow: hidden;
    margin-bottom: 16px;
}

.stats-row div {
    text-align: center;
    padding: 14px 8px;
    border-right: 1px solid var(--shell-border);
}

.stats-row div:last-child {
    border-right: none;
}

.stats-row strong {
    display: block;
    font-size: 1.05rem;
    color: var(--shell-text);
}

.profile-menu-list {
    border: 1px solid var(--shell-border);
    border-radius: 16px;
    overflow: hidden;
    margin-bottom: 16px;
}

.profile-menu-list button {
    width: 100%;
    border: none;
    border-bottom: 1px solid #f3f4f6;
    background: #fff;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    padding: 14px 16px;
    text-align: left;
    cursor: pointer;
    font-family: inherit;
}

.profile-menu-list button:last-child {
    border-bottom: none;
}

.profile-menu-list strong {
    display: block;
    color: var(--shell-text);
    font-size: 0.95rem;
}

.profile-menu-list span {
    color: var(--shell-muted);
    font-size: 0.8rem;
}

.settings-list {
    display: grid;
    gap: 10px;
    margin-bottom: 18px;
}

.settings-list button {
    width: 100%;
    border: 1px solid var(--shell-border);
    background: #fff;
    border-radius: 14px;
    padding: 16px;
    display: flex;
    align-items: center;
    justify-content: space-between;
    cursor: pointer;
    font-family: inherit;
    font-weight: 500;
    color: var(--shell-text);
}

.sign-out-btn {
    width: 100%;
    border: none;
    background: var(--shell-green);
    color: #fff;
    border-radius: 999px;
    padding: 14px;
    font-weight: 700;
    cursor: pointer;
    font-family: inherit;
    margin-bottom: 18px;
}

.faq-acc details {
    background: #fff;
    border: 1px solid var(--shell-border);
    border-radius: 14px;
    margin-bottom: 10px;
    padding: 4px 0;
}

.faq-acc summary {
    list-style: none;
    cursor: pointer;
    padding: 14px 16px;
    font-weight: 600;
    color: var(--shell-text);
    display: flex;
    justify-content: space-between;
    gap: 12px;
}

.faq-acc summary::-webkit-details-marker {
    display: none;
}

.faq-acc p {
    margin: 0;
    padding: 0 16px 14px;
    color: var(--shell-muted);
    line-height: 1.5;
}

@media (max-width: 900px) {
    .profile-layout {
        grid-template-columns: 1fr;
    }

    .profile-sidebar {
        position: static;
        max-height: none;
    }

    .profile-content {
        min-height: 0;
        padding: 18px;
    }

    .profile-content-title {
        display: none;
    }
}

@media (max-width: 576px) {
    .wallet-actions {
        grid-template-columns: 1fr;
    }

    .shell-panel {
        width: 100%;
    }
}
