/* Community and mentoring pages: light/dark surfaces, readable text and responsive posters. */
.community-page,
.mentoring-page,
.mentor-profile-page,
.mentoring-chat-page {
    min-height: 100vh;
    background: var(--theme-page);
    color: var(--theme-text);
}
.community-page,
.mentoring-page { padding: 26px 28px 48px; }
.community-page .community-header,
.mentoring-page .mentorship-header {
    margin-bottom: 30px;
    padding-bottom: 18px;
    border-bottom: 1px solid var(--theme-border);
}
.community-page .community-header :is(h1, h2, h3),
.mentoring-page .mentorship-header :is(h1, h2, h3) { color: var(--theme-text); }
.community-page .community-header p,
.mentoring-page .mentorship-header p { color: var(--theme-muted); }

.community-poster-card,
.mentor-poster-card {
    background: var(--theme-surface-raised);
    border: 1px solid var(--theme-border);
    box-shadow: 0 14px 30px rgba(42, 17, 34, .12);
}
.community-poster-card:hover,
.mentor-poster-card:hover { box-shadow: 0 22px 42px rgba(42, 17, 34, .22); }
.mpc-badge {
    position: absolute;
    top: 16px;
    right: 16px;
    z-index: 6;
    max-width: calc(100% - 96px);
}
.mentoring-page .mpc-badge { top: 54px; }
.mpc-category { display: flex; justify-content: center; margin-bottom: 8px; }
.mpc-category .member-category-badge { margin: 0 auto; }
.community-page .mpc-name-box,
.mentoring-page .mpc-name-box { background: rgba(120, 58, 104, .84); }
.community-page .mpc-action-overlay .btn,
.mentoring-page .mpc-action-overlay .btn { border-radius: 9px; }

/* Internal tabs are theme-aware instead of hard-coded black/white. */
.mentoring-tabs {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 24px;
    border-bottom: 1px solid var(--theme-border);
}
.mentoring-tabs a {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    margin-bottom: -1px;
    padding: 10px 18px;
    border-bottom: 2px solid transparent;
    color: var(--theme-muted);
    font-size: 14px;
    font-weight: 600;
    text-decoration: none;
}
.mentoring-tabs a:hover { color: #b01779; }
.mentoring-tabs a.is-active {
    border-bottom-color: #a31672;
    color: var(--theme-text);
}
html[data-theme="dark"] .mentoring-tabs a:hover,
html[data-theme="dark"] .mentoring-tabs a.is-active { border-bottom-color: #ff8bd0; color: #ffb3dc; }

/* Empty states */
html body :is(.community-page, .mentoring-page) .bg-white.bd-one {
    border-color: var(--theme-border) !important;
    background: var(--theme-surface) !important;
    color: var(--theme-text) !important;
    box-shadow: none;
}
html body :is(.community-page, .mentoring-page) .bg-white.bd-one p { color: var(--theme-muted) !important; }

/* Mentor detail / plans */
.mentor-profile-page { padding: 34px 18px 56px; }
.mentor-profile-page .container { max-width: 1120px; }
.mentor-profile-page .mentor-profile-header,
html body .mentor-profile-page .about-card,
html body .mentor-profile-page .pricing-card {
    border-color: var(--theme-border);
    background: var(--theme-surface);
    box-shadow: 0 12px 32px rgba(41, 20, 37, .07);
    color: var(--theme-text);
}
.mentor-profile-page .mentor-avatar { border-color: var(--theme-surface); }
.mentor-profile-page .nav-btn {
    border-color: var(--theme-border);
    background: var(--theme-surface);
    color: var(--theme-text);
}
.mentor-profile-page .nav-btn:hover { background: var(--theme-surface-raised); }
.mentor-profile-page .nav-btn.active {
    border-color: #a31672;
    background: #a31672;
    color: #fff;
}
.mentor-profile-page .nav-btn.active i { color: #fff; }
.mentor-profile-page :is(.about-card h4, .info-value, .plan-type, .plan-price) { color: var(--theme-text); }
.mentor-profile-page .plan-price { color: #a31672; }
.mentor-profile-page .bio-content,
.mentor-profile-page .plan-features li { color: var(--theme-muted); }
.mentor-profile-page .info-label { color: var(--theme-muted); }
.mentor-profile-page .info-list li,
.mentor-profile-page .plan-features li { border-color: var(--theme-border); }
.mentor-profile-page .pricing-card.disabled {
    background: var(--theme-surface-raised);
    opacity: .72;
}
.mentor-profile-page .plan-badge-ribbon {
    background: #a31672;
    color: #fff;
}
.mentor-profile-page .mentor-detail-badges {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 4px;
}
html[data-theme="dark"] .mentor-profile-page .mentor-avatar { border-color: var(--theme-surface); box-shadow: 0 6px 20px rgba(0, 0, 0, .35); }
html[data-theme="dark"] .mentor-profile-page .nav-btn.active,
html[data-theme="dark"] .mentor-profile-page .plan-price { color: #fff; }
html[data-theme="dark"] .mentor-profile-page .plan-price { color: #ff9fd5; }
html[data-theme="dark"] .mentor-profile-page :is(.badge.bg-light, .badge.text-dark) {
    border-color: var(--theme-border) !important;
    background: var(--theme-surface-raised) !important;
    color: var(--theme-text) !important;
}
html[data-theme="dark"] .mentor-profile-page .btn-select-plan:disabled {
    background: #3a323d !important;
    color: #b9aebb !important;
}

/* Mentoring group chat */
.mentoring-chat-page { --msg-other-bg: var(--theme-surface); }
html body .mentoring-chat-page .chat-container {
    border-color: var(--theme-border);
    background: var(--theme-surface);
    box-shadow: 0 14px 34px rgba(41, 20, 37, .09);
}
html body .mentoring-chat-page .chat-messages { background: var(--theme-page); }
html body .mentoring-chat-page .msg-other .msg-bubble {
    border: 1px solid var(--theme-border);
    background: var(--theme-surface);
    color: var(--theme-text);
}
html body .mentoring-chat-page .msg-sender { color: var(--theme-muted); }
html body .mentoring-chat-page .chat-input-area {
    border-color: var(--theme-border);
    background: var(--theme-surface);
}
html body .mentoring-chat-page .chat-input {
    border-color: transparent;
    background: var(--theme-control);
    color: var(--theme-text);
}
html body .mentoring-chat-page .chat-input:focus {
    border-color: #c2308e;
    background: var(--theme-control);
}
html[data-theme="dark"] .mentoring-chat-page .chat-container { box-shadow: 0 14px 34px rgba(0, 0, 0, .28); }

@media (max-width: 767.98px) {
    .community-page,
    .mentoring-page { padding: 18px 12px 42px; }
    .community-page .community-header,
    .mentoring-page .mentorship-header { margin-bottom: 22px; }
    .mpc-badge { top: 12px; right: 12px; }
    .mentoring-page .mpc-badge { top: 48px; }
    .mpc-badge .member-category-badge { font-size: 9px; }
    .mentor-profile-page { padding: 20px 10px 40px; }
}
