@import url('https://fonts.googleapis.com/css2?family=Assistant:wght@400;600;700&family=Heebo:wght@400;500;700&display=swap');

/* ===== CSS Variables ===== */
:root {
    --primary-color: #147c75;
    --primary-dark: #073f42;
    --primary-light: #e7f2ef;
    --secondary-color: #0d5d73;
    --accent-color: #b99057;
    --rose-light: #f5e7e8;
    --lavender-light: #eee8f1;
    --sky-light: #e6eef2;
    --text-primary: #111918;
    --text-secondary: #566665;
    --text-light: #7b8a89;
    --background: #f6f7f4;
    --white: #ffffff;
    --border-color: #dce8e3;
    --shadow-sm: 0 1px 2px rgba(0, 0, 0, 0.05);
    --shadow-md: 0 12px 26px rgba(7, 63, 66, 0.08);
    --shadow-lg: 0 18px 38px rgba(7, 63, 66, 0.12);
    --radius-sm: 8px;
    --radius-md: 14px;
    --radius-lg: 22px;
    --transition: all 0.3s ease;
    --hero-photo: url('../assets/glowe-bridge.jpg');
    --page-photo: url('../assets/glowe-regrowth.jpg');
}

/* ===== Reset & Base ===== */
* {
    margin: 0;
    padding: 0;
    box-sizing: border-box;
}

body {
    font-family: 'Inter', 'Nunito', system-ui, -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    background: var(--background);
    color: var(--text-primary);
    line-height: 1.6;
    overflow-x: hidden;
}

img,
video,
canvas,
svg {
    max-width: 100%;
    height: auto;
}

.home-page-body,
.organizations-page-body {
    --page-photo: url('../assets/glowe-bridge.jpg');
}

.opportunities-page-body,
.wishing-page-body {
    --page-photo: url('../assets/glowe-field.jpg');
}

.about-page-body {
    --page-photo: url('../assets/glowe-blossoms.jpg');
}

.community-page-body {
    --page-photo: url('../assets/glowe-regrowth.jpg');
}

a {
    text-decoration: none;
    color: inherit;
}

ul {
    list-style: none;
}

/* ===== Container ===== */
.container {
    max-width: 1200px;
    margin: 0 auto;
    padding: 0 20px;
}

/* ===== Buttons ===== */
.btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 12px 24px;
    border-radius: var(--radius-sm);
    font-weight: 600;
    font-size: 1rem;
    cursor: pointer;
    transition: var(--transition);
    border: none;
    font-family: inherit;
}

.btn-primary {
    background: var(--primary-dark);
    color: var(--white);
    box-shadow: 0 12px 22px rgba(33, 143, 130, 0.2);
}

.btn-primary:hover {
    background: var(--primary-color);
    transform: translateY(-2px);
    box-shadow: var(--shadow-md);
}

.btn-outline {
    background-color: rgba(255, 255, 255, 0.76);
    border: 1.5px solid rgba(7, 63, 66, 0.34);
    color: var(--primary-dark);
}

.btn-outline:hover {
    background-color: var(--primary-color);
    color: var(--white);
}

/* FR-GLOWE-013 AC2 — active state for a Save/Saved toggle button. */
.btn.is-saved {
    background-color: var(--primary-color);
    border-color: var(--primary-color);
    color: var(--white);
}

.btn-secondary {
    background-color: var(--secondary-color);
    color: var(--white);
}

.btn-large {
    padding: 16px 32px;
    font-size: 1.1rem;
}

.btn-small {
    padding: 8px 16px;
    font-size: 0.9rem;
}

.btn-block {
    width: 100%;
}

/* ===== Header ===== */
.main-header {
    background-color: rgba(255, 255, 255, 0.92);
    border-bottom: 1px solid rgba(15, 93, 85, 0.12);
    box-shadow: 0 8px 24px rgba(24, 36, 61, 0.04);
    position: sticky;
    top: 0;
    z-index: 100;
    backdrop-filter: blur(14px);
}

.main-header .container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 16px 20px;
    gap: 14px;
}

.logo {
    display: flex;
    align-items: center;
    gap: 10px;
}

.logo-icon {
    width: 42px;
    height: 42px;
    background: url('../assets/glowe-life-flower.png') center / contain no-repeat;
    font-size: 0;
    flex: 0 0 auto;
}

.logo-text {
    font-size: 1.5rem;
    font-weight: 700;
    color: var(--primary-dark);
    letter-spacing: 0;
}

.main-nav {
    display: flex;
    gap: 6px;
    padding: 4px;
    background: rgba(15, 93, 85, 0.06);
    border: 1px solid rgba(15, 93, 85, 0.12);
    border-radius: 999px;
    max-width: 100%;
    overflow-x: auto;
    scrollbar-width: none;
}

.main-nav::-webkit-scrollbar {
    display: none;
}

.nav-link {
    color: var(--text-secondary);
    font-weight: 600;
    font-size: 0.92rem;
    text-transform: none;
    transition: var(--transition);
    padding: 8px 14px;
    position: relative;
    border-radius: 999px;
    white-space: nowrap;
}

.nav-link:hover,
.nav-link.active {
    color: var(--primary-dark);
    background: var(--white);
    box-shadow: 0 6px 16px rgba(15, 93, 85, 0.08);
}

.nav-link.active::after {
    display: none;
}

.auth-buttons {
    display: flex;
    gap: 12px;
    flex: 0 0 auto;
}

.user-menu {
    display: flex;
    align-items: center;
    gap: 10px;
    flex: 0 0 auto;
}

.user-greeting {
    color: var(--text-secondary);
    font-weight: 600;
    text-decoration: none;
}

a.user-greeting:hover {
    color: var(--primary-color);
}

.header-icon-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    border-radius: 50%;
    border: 1px solid var(--border-color);
    background: var(--white);
    color: var(--text-secondary);
    text-decoration: none;
    flex: 0 0 auto;
    transition: color 0.2s ease, border-color 0.2s ease;
}

.header-icon-btn:hover {
    color: var(--primary-color);
    border-color: var(--primary-color);
}

.header-icon-btn svg {
    width: 20px;
    height: 20px;
}

.header-settings-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    gap: 6px;
}

.header-settings-btn svg {
    width: 20px;
    height: 20px;
}

/* Settings/Admin keep their text labels on desktop; icons shown only on
   phone widths (see the max-width: 680px block). */
.header-settings-icon,
.glowe-admin-icon {
    display: none;
}

/* ===== Hero Section ===== */
.hero {
    background:
        linear-gradient(90deg, rgba(246, 247, 244, 0.98), rgba(231, 242, 239, 0.9), rgba(246, 247, 244, 0.62)),
        var(--hero-photo) right center / cover no-repeat;
    padding: 86px 0;
    border-bottom: 1px solid rgba(7, 63, 66, 0.12);
}

.hero .container {
    display: flex;
    align-items: center;
    gap: 60px;
}

.hero-content {
    flex: 1;
}

.hero h1 {
    font-size: clamp(2.6rem, 5vw, 4.9rem);
    line-height: 1.03;
    color: var(--text-primary);
    margin-bottom: 20px;
}

.hero p {
    font-size: 1.25rem;
    color: var(--text-secondary);
    margin-bottom: 32px;
}

.hero-cta {
    display: flex;
    gap: 16px;
}

.hero-image {
    flex: 1;
    display: flex;
    justify-content: center;
}

.glowe-hero-mark {
    width: min(440px, 86vw);
    aspect-ratio: 1;
    margin: 0;
    display: flex;
    align-items: center;
    justify-content: center;
    background: transparent;
    border: 0;
    border-radius: 0;
    box-shadow: none;
}

.glowe-hero-mark img {
    width: 94%;
    height: 94%;
    object-fit: contain;
    filter: drop-shadow(0 18px 28px rgba(7, 63, 66, 0.18));
}

/* ===== Featured Section ===== */
.featured-section {
    padding: 80px 0;
}

.daily-workspace-section,
.core-flow-section,
.smart-matching-section,
.playbooks-section,
.growth-suite-section,
.funding-section,
.engagement-section,
.rewards-section,
.values-section,
.current-state-section {
    padding: 56px 0;
}

.core-flow-section {
    background: var(--white);
    border-bottom: 1px solid var(--border-color);
}

.values-section {
    background: linear-gradient(135deg, #f7faf7, var(--primary-light));
    border-bottom: 1px solid var(--border-color);
}

.daily-workspace-section {
    background: var(--white);
}

.smart-matching-section {
    background: linear-gradient(135deg, var(--primary-light), #f7faf7);
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.growth-suite-section,
.engagement-section,
.current-state-section {
    background: var(--white);
}

.funding-section {
    background: linear-gradient(135deg, #f7faf7 0%, var(--sky-light) 100%);
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.rewards-section {
    background: linear-gradient(135deg, var(--primary-light), #fffaf0);
    border-top: 1px solid var(--border-color);
}

.split-section {
    display: grid;
    grid-template-columns: minmax(0, 0.85fr) minmax(0, 1.15fr);
    gap: 36px;
    align-items: start;
}

.split-section h2,
.daily-workspace-section h2,
.playbooks-section h2 {
    margin-top: 8px;
    font-size: clamp(1.8rem, 3vw, 2.6rem);
}

.split-section p {
    color: var(--text-secondary);
    font-size: 1.08rem;
}

.daily-grid,
.playbook-grid,
.capability-grid,
.values-grid,
.current-actions-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(240px, 1fr));
    gap: 18px;
}

.daily-action-card,
.match-card,
.playbook-card,
.capability-card,
.grant-card,
.leader-card,
.blueprint-panel,
.values-grid article,
.current-actions-grid article {
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 22px;
    box-shadow: 0 10px 30px rgba(24, 36, 61, 0.06);
}

.daily-action-card span,
.playbook-card span,
.capability-label,
.roadmap-row span {
    color: var(--primary-dark);
    font-weight: 800;
    font-size: 0.85rem;
    text-transform: uppercase;
}

.daily-action-card h3,
.playbook-card h3,
.match-card h3,
.capability-card h3,
.grant-card h3,
.leader-card h3,
.values-grid h3 {
    margin: 10px 0;
}

.daily-action-card p,
.playbook-card p,
.match-card p,
.capability-card p,
.grant-card p,
.leader-card p,
.values-grid p,
.role-row p,
.roadmap-row p {
    color: var(--text-secondary);
}

.current-actions-grid article strong,
.current-actions-grid article span {
    display: block;
}

.current-actions-grid article strong {
    color: var(--primary-dark);
    margin-bottom: 8px;
}

.current-actions-grid article span {
    color: var(--text-secondary);
}

.match-list {
    display: grid;
    gap: 14px;
}

.match-card {
    display: grid;
    grid-template-columns: 78px minmax(0, 1fr);
    gap: 18px;
    align-items: start;
}

.grant-list,
.leaderboard-list,
.role-list,
.business-list,
.roadmap-list {
    display: grid;
    gap: 14px;
}

.grant-card,
.leader-card {
    display: grid;
    grid-template-columns: 78px minmax(0, 1fr);
    gap: 18px;
    align-items: start;
}

.grant-card small {
    display: block;
    color: var(--text-light);
    font-weight: 800;
    margin: 10px 0 14px;
}

.leader-rank {
    width: 56px;
    height: 56px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--primary-dark);
    color: var(--white);
    font-weight: 900;
    font-size: 1.15rem;
}

.blueprint-grid {
    display: grid;
    grid-template-columns: minmax(0, 1.25fr) minmax(260px, 0.85fr) minmax(260px, 1fr);
    gap: 18px;
    align-items: start;
}

.flow-board {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
}

.flow-board article {
    position: relative;
    min-height: 190px;
    padding: 22px;
    background: #fbfefd;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
}

.flow-board article span {
    width: 36px;
    height: 36px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    margin-bottom: 16px;
    border-radius: 50%;
    background: var(--primary-dark);
    color: var(--white);
    font-weight: 900;
}

.flow-board h3 {
    margin-bottom: 8px;
}

.flow-board p {
    color: var(--text-secondary);
}

.trust-strip {
    background: var(--white);
    border-bottom: 1px solid var(--border-color);
}

.trust-strip .container,
.trust-panel {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
}

.trust-strip .container {
    padding-top: 18px;
    padding-bottom: 18px;
}

.trust-strip div,
.trust-panel div {
    padding: 16px;
    background: #fbfefd;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
}

.trust-strip strong,
.trust-strip span,
.trust-panel strong,
.trust-panel span {
    display: block;
}

.trust-strip span,
.trust-panel span {
    color: var(--text-secondary);
    font-size: 0.92rem;
}

.blueprint-panel h3 {
    margin-bottom: 14px;
}

.role-row,
.business-row,
.roadmap-row {
    padding: 14px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: #fbfefd;
}

.role-row strong,
.roadmap-row h4 {
    display: block;
    color: var(--text-primary);
    margin-bottom: 4px;
}

.match-score {
    width: 72px;
    height: 72px;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--primary-light);
    color: var(--primary-dark);
    font-weight: 900;
    font-size: 1.2rem;
}

.option-row {
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px;
    margin-bottom: 8px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: #fbfefd;
    font-weight: 700;
}

.featured-section h2,
.how-it-works h2,
.testimonials-section h2,
.stats-section h2 {
    text-align: center;
    font-size: 2.5rem;
    margin-bottom: 16px;
}

.section-subtitle {
    text-align: center;
    color: var(--text-secondary);
    font-size: 1.1rem;
    margin-bottom: 48px;
}

.opportunities-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(320px, 1fr));
    gap: 24px;
    margin-bottom: 40px;
}

.opportunity-composer-section {
    padding: 44px 0 12px;
    background: linear-gradient(180deg, #fbfefd 0%, var(--background) 100%);
}

.opportunity-composer-section .section-toolbar {
    align-items: center;
    padding: 24px;
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

.opportunity-composer-section .section-toolbar p {
    max-width: 720px;
    color: var(--text-secondary);
}

.opportunity-form {
    margin-top: 18px;
}

.form-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 8px;
}

.opportunity-card {
    position: relative;
    background: var(--white);
    border-radius: var(--radius-md);
    padding: 24px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
    transition: var(--transition);
}

.card-more-menu {
    top: 12px;
    right: 12px;
}

.wish-card .card-more-menu {
    top: 56px;
}

.opportunity-card:hover {
    transform: translateY(-4px);
    box-shadow: var(--shadow-lg);
}

.opportunity-header {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 16px;
    padding-right: 44px;
}

.opportunity-org {
    display: flex;
    align-items: center;
    gap: 8px;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.opportunity-badge {
    background-color: var(--primary-light);
    color: var(--primary-dark);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
    font-weight: 600;
}

.opportunity-title {
    font-size: 1.25rem;
    font-weight: 700;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.opportunity-description {
    color: var(--text-secondary);
    margin-bottom: 16px;
    font-size: 0.95rem;
}

.opportunity-details {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    margin-bottom: 20px;
}

.opportunity-detail {
    display: flex;
    align-items: center;
    gap: 6px;
    font-size: 0.9rem;
    color: var(--text-secondary);
}

.opportunity-skills {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-bottom: 20px;
}

.skill-tag {
    background-color: var(--background);
    color: var(--text-secondary);
    padding: 4px 12px;
    border-radius: 20px;
    font-size: 0.8rem;
}

.section-cta {
    text-align: center;
}

/* ===== Stats Section ===== */
.stats-section {
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    padding: 60px 0;
}

.stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 32px;
}

.stat-card {
    text-align: center;
    color: var(--white);
}

.stat-number {
    display: block;
    font-size: 3rem;
    font-weight: 700;
    margin-bottom: 8px;
}

.stat-label {
    font-size: 1.1rem;
    opacity: 0.9;
}

/* ===== How It Works ===== */
.how-it-works {
    padding: 80px 0;
    background-color: var(--white);
}

.steps-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
    gap: 32px;
    margin-top: 48px;
}

.step-card {
    text-align: center;
    padding: 32px;
}

.step-number {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, var(--primary-color) 0%, var(--primary-dark) 100%);
    color: var(--white);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 1.5rem;
    font-weight: 700;
    margin: 0 auto 20px;
}

.step-card h3 {
    font-size: 1.25rem;
    margin-bottom: 12px;
    color: var(--text-primary);
}

.step-card p {
    color: var(--text-secondary);
}

/* ===== Testimonials ===== */
.testimonials-section {
    padding: 80px 0;
}

.testimonials-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
    gap: 24px;
    margin-top: 48px;
}

.testimonial-card {
    background: var(--white);
    border-radius: var(--radius-md);
    padding: 32px;
    box-shadow: var(--shadow-sm);
    border: 1px solid var(--border-color);
    text-align: center;
}

.testimonial-avatar {
    width: 56px;
    height: 56px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--primary-light);
    border: 1px solid var(--border-color);
    color: var(--primary-dark);
    font-size: 0.95rem;
    font-weight: 900;
    letter-spacing: 0.04em;
    margin-bottom: 16px;
}

.testimonial-text {
    font-style: italic;
    color: var(--text-secondary);
    margin-bottom: 16px;
    line-height: 1.7;
}

.testimonial-author {
    font-weight: 600;
    color: var(--text-primary);
}

/* ===== CTA Section ===== */
.cta-section {
    background: linear-gradient(135deg, var(--secondary-color) 0%, #2563eb 100%);
    padding: 80px 0;
    text-align: center;
    color: var(--white);
}

.cta-section h2 {
    font-size: 2.5rem;
    margin-bottom: 16px;
}

.cta-section p {
    font-size: 1.2rem;
    opacity: 0.9;
    margin-bottom: 32px;
    max-width: 600px;
    margin-left: auto;
    margin-right: auto;
}

/* ===== Footer ===== */
.main-footer {
    background-color: var(--text-primary);
    color: var(--white);
    padding: 60px 0 20px;
}

.footer-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(200px, 1fr));
    gap: 40px;
    margin-bottom: 40px;
}

.footer-section h4 {
    font-size: 1.2rem;
    margin-bottom: 16px;
    color: var(--primary-color);
}

.footer-section p,
.footer-section a {
    color: var(--text-light);
    display: block;
    margin-bottom: 8px;
    transition: var(--transition);
}

.footer-section a:hover {
    color: var(--primary-color);
}

.footer-bottom {
    border-top: 1px solid rgba(255, 255, 255, 0.1);
    padding-top: 20px;
    text-align: center;
    color: var(--text-light);
}

.footer-bottom p {
    margin: 0;
}

/* ===== Modal ===== */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    min-height: 100dvh;
    background-color: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    justify-content: center;
    align-items: flex-start;
    padding: clamp(14px, 4vh, 44px) 14px;
    overflow-y: auto;
    overscroll-behavior: contain;
    animation: fadeIn 0.3s ease;
}

.modal.active {
    display: flex;
}

@keyframes fadeIn {
    from { opacity: 0; }
    to { opacity: 1; }
}

.modal-content {
    background: var(--white);
    border-radius: var(--radius-lg);
    padding: clamp(22px, 4vw, 40px);
    max-width: 450px;
    width: 90%;
    position: relative;
    max-height: calc(100dvh - 28px);
    overflow-y: auto;
    overscroll-behavior: contain;
    margin: auto 0;
    animation: slideUp 0.3s ease;
}

@keyframes slideUp {
    from {
        opacity: 0;
        transform: translateY(20px);
    }
    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.close-modal {
    position: sticky;
    top: 0;
    float: right;
    z-index: 3;
    width: 38px;
    height: 38px;
    margin: -12px -12px 8px 12px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--white);
    border: 1px solid var(--border-color);
    box-shadow: var(--shadow-sm);
    font-size: 1.35rem;
    line-height: 1;
    cursor: pointer;
    color: var(--text-light);
    transition: var(--transition);
}

.close-modal:hover {
    color: var(--text-primary);
}

.modal-content h2 {
    margin-bottom: 24px;
    text-align: center;
}

.form-group {
    margin-bottom: 20px;
}

.form-group label {
    display: block;
    margin-bottom: 8px;
    font-weight: 600;
    color: var(--text-primary);
}

.form-group input,
.form-group select,
.form-group textarea {
    width: 100%;
    padding: 12px 16px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-size: 1rem;
    font-family: inherit;
    transition: var(--transition);
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
    outline: none;
    border-color: var(--primary-color);
}

.modal-footer-text {
    text-align: center;
    margin-top: 20px;
    color: var(--text-secondary);
}

.modal-footer-text a {
    color: var(--primary-color);
    font-weight: 600;
}

.modal-success {
    text-align: center;
}

.modal-wide {
    max-width: min(760px, calc(100vw - 28px));
}

.modal-intro {
    color: var(--text-secondary);
    margin: -10px 0 20px;
    text-align: center;
}

.modal-actions {
    display: flex;
    gap: 12px;
    flex-wrap: wrap;
}

.modal-actions .btn {
    flex: 1 1 210px;
}

.form-grid-2 {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
}

.registration-modal-content {
    max-width: min(920px, calc(100vw - 28px));
}

.registration-wizard {
    clear: both;
}

.google-auth-btn {
    width: 100%;
    justify-content: center;
    gap: 10px;
    margin: 4px 0 20px;
    border-color: rgba(12, 73, 76, 0.22);
    background: var(--white);
    color: var(--primary-dark);
}

.google-auth-btn:hover {
    background: #f2f8f7;
    border-color: rgba(12, 73, 76, 0.34);
    color: var(--primary-dark);
    box-shadow: var(--shadow-md);
}

.google-auth-btn span {
    display: inline-grid;
    place-items: center;
    width: 24px;
    height: 24px;
    border-radius: 50%;
    background: #f7fbfa;
    color: var(--primary-dark);
    font-weight: 900;
}

.inline-field-action {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 8px;
}

.email-code-group small {
    display: block;
    margin-top: 6px;
    color: var(--text-light);
    font-size: 0.82rem;
}

.wizard-heading {
    max-width: 720px;
    margin-bottom: 22px;
}

.wizard-heading h2 {
    text-align: left;
    margin: 6px 0 10px;
    font-size: clamp(1.8rem, 3vw, 2.7rem);
}

.wizard-heading p {
    color: var(--text-secondary);
}

.wizard-progress {
    display: grid;
    grid-template-columns: repeat(6, 1fr);
    gap: 8px;
    margin-bottom: 24px;
}

.wizard-progress span {
    min-height: 42px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 8px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    background: #fbfefd;
    font-size: 0.82rem;
    font-weight: 900;
    text-align: center;
}

.wizard-progress span.active {
    color: var(--primary-dark);
    background: var(--primary-light);
    border-color: rgba(20, 124, 117, 0.34);
}

.wizard-step {
    display: none;
}

.wizard-step.active {
    display: block;
}

.wizard-step h3 {
    margin-bottom: 18px;
    font-size: 1.45rem;
}

.profile-type-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(190px, 1fr));
    gap: 12px;
    margin-bottom: 18px;
}

.profile-type-card,
.choice-card {
    display: flex;
    align-items: flex-start;
    gap: 10px;
    padding: 14px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: #fbfefd;
    color: var(--text-secondary);
    font-weight: 800;
    cursor: pointer;
}

.profile-type-card span {
    display: grid;
    gap: 5px;
}

.profile-type-card small {
    color: var(--text-muted);
    font-size: 0.86rem;
    font-weight: 600;
    line-height: 1.45;
}

.profile-type-card:has(input:checked),
.choice-card:has(input:checked) {
    color: var(--primary-dark);
    background: var(--primary-light);
    border-color: rgba(20, 124, 117, 0.38);
    box-shadow: inset 0 0 0 1px rgba(20, 124, 117, 0.12);
}

.profile-type-card:has(input:checked) small {
    color: var(--primary-dark);
}

.profile-type-guidance {
    margin: 0 0 18px;
    padding: 16px 18px;
    border: 1px solid rgba(20, 124, 117, 0.18);
    border-radius: var(--radius-md);
    background: linear-gradient(135deg, rgba(232, 246, 241, 0.86), rgba(255, 255, 255, 0.92));
    color: var(--text-secondary);
}

.profile-type-guidance strong {
    display: block;
    margin-bottom: 8px;
    color: var(--primary-dark);
}

.profile-type-guidance ul {
    margin: 0;
    padding-left: 18px;
}

.profile-type-guidance li + li {
    margin-top: 5px;
}

.choice-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(210px, 1fr));
    gap: 10px;
}

.compact-choice-grid {
    grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
}

.wizard-actions {
    position: sticky;
    bottom: -1px;
    z-index: 2;
    display: flex;
    justify-content: flex-end;
    gap: 12px;
    margin: 26px -8px -8px;
    padding: 16px 8px 8px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0), var(--white) 26%);
}

.support-summary {
    margin-bottom: 18px;
    padding: 16px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: var(--primary-light);
}

.support-summary:empty {
    display: none;
}

.support-summary strong,
.support-summary span {
    display: block;
}

.support-summary span,
.support-summary p {
    color: var(--text-secondary);
}

.path-grid {
    display: grid;
    grid-template-columns: repeat(3, 1fr);
    gap: 14px;
}

.path-grid button {
    min-height: 180px;
    padding: 20px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: #fbfefd;
    color: inherit;
    font: inherit;
    text-align: left;
    cursor: pointer;
}

.path-grid button:hover {
    border-color: var(--primary-color);
    background: var(--primary-light);
}

.path-grid strong,
.path-grid span {
    display: block;
}

.path-grid strong {
    margin-bottom: 10px;
    color: var(--primary-dark);
}

.path-grid span {
    color: var(--text-secondary);
}

.workspace-header {
    margin-bottom: 18px;
}

.workspace-steps {
    display: grid;
    grid-template-columns: repeat(4, 1fr);
    gap: 12px;
}

.workspace-steps article {
    min-height: 132px;
    padding: 16px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: #fbfefd;
}

.workspace-steps article.done {
    background: var(--primary-light);
    border-color: rgba(20, 124, 117, 0.25);
}

.workspace-steps strong,
.workspace-steps span {
    display: block;
}

.workspace-steps span {
    color: var(--text-secondary);
    margin-top: 8px;
}

.impact-update-box {
    margin-top: 18px;
    padding: 18px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: linear-gradient(135deg, var(--primary-light), #fffaf0);
}

.success-icon {
    width: 82px;
    height: 82px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: url('../assets/glowe-life-flower.png') center / 74% no-repeat, var(--primary-light);
    border: 1px solid var(--border-color);
    color: transparent;
    font-size: 0;
    margin: 0 auto 16px;
}

/* ===== Page Styles ===== */
.page-header {
    position: relative;
    overflow: hidden;
    background:
        linear-gradient(90deg, rgba(247, 250, 247, 0.98) 0%, rgba(227, 245, 240, 0.9) 48%, rgba(17, 35, 34, 0.34) 100%),
        var(--page-photo) right center / cover no-repeat;
    padding: 72px 0;
    text-align: center;
    border-bottom: 1px solid rgba(15, 93, 85, 0.12);
}

.page-header::after {
    content: '';
    position: absolute;
    inset: auto 0 0;
    height: 8px;
    background: linear-gradient(90deg, var(--primary-dark), var(--primary-color), #4db2c7, var(--accent-color));
}

.page-header .container {
    position: relative;
    z-index: 1;
}

.page-header h1 {
    max-width: 720px;
    font-size: clamp(2.35rem, 4vw, 4.25rem);
    line-height: 1.02;
    margin-bottom: 16px;
    text-align: left;
}

.page-header p {
    max-width: 620px;
    color: var(--text-secondary);
    font-size: 1.15rem;
    text-align: left;
}

.wishing-hero {
    background:
        linear-gradient(115deg, #e0f8ec 0%, #f8fcfa 52%, #ece8ff 100%);
    text-align: left;
    padding: 64px 0 52px;
}

.wishing-hero .container {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 320px;
    gap: 36px;
    align-items: center;
}

.hero-copy {
    max-width: 760px;
}

.hero-kicker {
    display: inline-flex;
    align-items: center;
    width: fit-content;
    color: var(--primary-dark);
    background: rgba(255, 255, 255, 0.72);
    border: 1px solid rgba(47, 191, 122, 0.22);
    border-radius: 999px;
    padding: 6px 12px;
    font-size: 0.82rem;
    font-weight: 800;
    text-transform: uppercase;
}

.wishing-hero h1 {
    max-width: 680px;
    margin: 18px 0 14px;
    text-align: left;
    font-size: clamp(2.35rem, 4vw, 4.4rem);
    line-height: 1.04;
}

.wishing-hero p {
    max-width: 680px;
    font-size: 1.18rem;
}

.hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
    margin-top: 26px;
}

.well-summary-panel {
    display: grid;
    gap: 12px;
    padding: 18px;
    background: rgba(255, 255, 255, 0.78);
    border: 1px solid rgba(255, 255, 255, 0.9);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
}

.well-summary-panel div {
    display: flex;
    justify-content: space-between;
    align-items: baseline;
    gap: 18px;
    padding: 16px;
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
}

.well-summary-panel strong {
    color: var(--primary-dark);
    font-size: 2rem;
}

.well-summary-panel span {
    color: var(--text-secondary);
    font-weight: 800;
}

/* ===== Filters ===== */
.filters-section {
    background: var(--white);
    padding: 24px 0;
    border-bottom: 1px solid var(--border-color);
    position: sticky;
    top: 80px;
    z-index: 50;
}

.filters-container {
    display: flex;
    flex-wrap: wrap;
    gap: 16px;
    align-items: center;
}

.filter-group {
    display: flex;
    align-items: center;
    gap: 8px;
    min-width: 0;
}

.filter-group label {
    font-weight: 600;
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.filter-group select {
    padding: 8px 16px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-sm);
    font-family: inherit;
    font-size: 0.9rem;
    cursor: pointer;
}

.search-box {
    flex: 1;
    min-width: 200px;
    display: flex;
    align-items: center;
    background: var(--background);
    border-radius: var(--radius-sm);
    padding: 0 16px;
}

.search-box input {
    flex: 1;
    min-width: 0;
    width: 100%;
    border: none;
    background: transparent;
    padding: 10px;
    font-size: 1rem;
    font-family: inherit;
}

.search-box input:focus {
    outline: none;
}

/* ===== Opportunity Detail Page ===== */
.opportunity-detail {
    padding: 60px 0;
}

.opportunity-detail-grid {
    display: grid;
    grid-template-columns: 2fr 1fr;
    gap: 40px;
}

.opportunity-main {
    background: var(--white);
    border-radius: var(--radius-md);
    padding: 40px;
    box-shadow: var(--shadow-sm);
}

.opportunity-main h1 {
    font-size: 2rem;
    margin-bottom: 24px;
}

.opportunity-main h2 {
    font-size: 1.5rem;
    margin: 32px 0 16px;
    color: var(--text-primary);
}

.opportunity-main p,
.opportunity-main li {
    color: var(--text-secondary);
    margin-bottom: 12px;
}

.opportunity-main ul {
    margin-left: 20px;
    list-style: disc;
}

.opportunity-sidebar {
    position: sticky;
    top: 140px;
    height: fit-content;
}

.apply-card {
    background: var(--white);
    border-radius: var(--radius-md);
    padding: 32px;
    box-shadow: var(--shadow-sm);
    text-align: center;
}

.apply-card h3 {
    margin-bottom: 16px;
}

.apply-card .opportunity-details {
    justify-content: center;
    margin-bottom: 24px;
}

.org-info-card {
    background: var(--white);
    border-radius: var(--radius-md);
    padding: 24px;
    box-shadow: var(--shadow-sm);
    margin-top: 24px;
}

.org-info-card h4 {
    margin-bottom: 12px;
    color: var(--text-primary);
}

.org-info-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

/* ===== Event registration (FR-GLOWE-007) ===== */
.event-register-form {
    text-align: right;
    margin-top: 8px;
}

.event-register-form .form-group {
    margin-bottom: 14px;
}

.event-register-status {
    margin: 4px 0 16px;
    color: var(--text-secondary);
}

.event-register-error {
    background: var(--rose-light);
    color: #8a1c2b;
    border-radius: var(--radius-sm);
    padding: 10px 14px;
    margin-bottom: 14px;
    font-size: 0.9rem;
}

.status-badge {
    display: inline-block;
    padding: 3px 12px;
    border-radius: 999px;
    font-size: 0.8rem;
    font-weight: 600;
    background: var(--primary-light);
    color: var(--primary-dark);
}

.status-accepted {
    background: #e2f2ea;
    color: #1a7a4f;
}

.status-pending,
.status-waitlisted {
    background: #fbf1dd;
    color: #8a6314;
}

.status-declined,
.status-cancelled {
    background: var(--rose-light);
    color: #8a1c2b;
}

.my-event-item {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
}

.my-event-item h3 {
    font-size: 1.05rem;
    margin-bottom: 4px;
}

.my-event-item .status-badge {
    margin-top: 6px;
}

/* ===== Organizer portal (FR-GLOWE-007-E) ===== */
.organizer-panel {
    text-align: right;
    margin-top: 8px;
}

.organizer-panel h4 {
    margin-bottom: 4px;
}

.organizer-capacity {
    color: var(--text-secondary);
    font-size: 0.9rem;
    margin-bottom: 12px;
}

.organizer-reg-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.organizer-reg-item {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 12px;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: var(--white);
}

.organizer-reg-item strong {
    margin-inline-end: 8px;
}

.organizer-actions {
    display: flex;
    gap: 6px;
    flex-shrink: 0;
}

.organizer-cancel-event {
    margin-top: 16px;
    padding-top: 12px;
    border-top: 1px solid var(--border-color);
}

.event-link-line {
    margin: 8px 0 14px;
    word-break: break-all;
}

.event-link-line a {
    color: var(--primary-color);
    font-weight: 600;
}

/* ===== Applications Page ===== */
.applications-page,
.personal-area-page {
    padding: 60px 0 86px;
}

.applications-list {
    display: flex;
    flex-direction: column;
    gap: 16px;
}

.personal-shell {
    display: grid;
    grid-template-columns: 300px minmax(0, 1fr);
    gap: 24px;
    align-items: start;
}

.personal-sidebar {
    display: grid;
    gap: 16px;
    position: sticky;
    top: 92px;
}

.personal-nav,
.personal-stats-grid div {
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

/* FR-GLOWE-011 AC1 — profile-card loading skeleton (shown on first Personal
   Area load while the backend profile fetch is in flight). */
.skeleton {
    position: relative;
    overflow: hidden;
    background: #e9edf2;
    border-radius: 8px;
}

.skeleton::after {
    content: '';
    position: absolute;
    inset: 0;
    transform: translateX(-100%);
    background: linear-gradient(90deg, transparent, rgba(255, 255, 255, 0.65), transparent);
    animation: glowe-skeleton-shimmer 1.3s infinite;
}

@keyframes glowe-skeleton-shimmer {
    100% { transform: translateX(100%); }
}

.skeleton-avatar {
    width: 96px;
    height: 96px;
    border-radius: 50%;
    margin: 0 auto 16px;
}

.skeleton-avatar.social-avatar {
    width: 120px;
    height: 120px;
}

.skeleton-line {
    height: 14px;
    width: 80%;
    margin: 10px auto;
}

.skeleton-line-lg { width: 60%; height: 20px; }
.skeleton-line-sm { width: 40%; height: 12px; }

.skeleton-pill {
    height: 22px;
    width: 50%;
    margin: 12px auto;
    border-radius: 999px;
}

.social-profile-hero.is-loading .social-profile-body {
    padding: 24px;
}

@media (prefers-reduced-motion: reduce) {
    .skeleton::after { animation: none; }
}

.profile-status-pill {
    display: inline-flex;
    padding: 6px 10px;
    border-radius: 999px;
    background: var(--primary-light);
    color: var(--primary-dark);
    font-size: 0.78rem;
    font-weight: 900;
}

.personal-nav {
    display: grid;
    padding: 10px;
}

.personal-nav a {
    padding: 11px 12px;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-weight: 800;
}

.personal-nav a:hover {
    background: var(--primary-light);
    color: var(--primary-dark);
}

.personal-main,
.personal-grid,
.personal-list {
    display: grid;
    gap: 20px;
}

.settings-grid {
    display: grid;
    gap: 20px;
    max-width: 720px;
}

.settings-grid .form-group {
    margin-top: 12px;
}

.social-profile-hero {
    overflow: hidden;
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-sm);
}

.social-cover {
    min-height: 170px;
    background:
        linear-gradient(105deg, rgba(231, 245, 240, 0.92), rgba(252, 240, 217, 0.62), rgba(174, 217, 224, 0.72)),
        var(--page-photo) center / cover no-repeat;
    border-bottom: 1px solid var(--border-color);
}

.social-profile-body {
    display: grid;
    gap: 18px;
    padding: 0 28px 28px;
}

.social-profile-head {
    display: flex;
    gap: 22px;
    align-items: flex-end;
}

.social-avatar-wrap {
    position: relative;
    flex-shrink: 0;
    margin-top: -64px;
}

.social-avatar {
    width: 136px;
    height: 136px;
    margin: 0;
    border: 6px solid var(--white);
    box-shadow: var(--shadow-md);
}

.social-avatar-change {
    position: absolute;
    inset-inline-end: -4px;
    inset-block-end: 6px;
    border: 1px solid var(--border-color);
    border-radius: 999px;
    background: var(--white);
    color: var(--primary-dark);
    font: inherit;
    font-size: 0.72rem;
    font-weight: 900;
    padding: 5px 9px;
    cursor: pointer;
    transition: background-color 0.2s;
}

.social-avatar-change:hover {
    background: var(--primary-light);
}

.social-profile-copy {
    min-width: 0;
    padding-bottom: 6px;
}

.social-profile-tags {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 8px;
    margin-bottom: 4px;
}

.social-profile-tags .profile-type {
    margin: 0;
}

.social-profile-copy h2 {
    font-size: clamp(1.6rem, 2.6vw, 2.4rem);
    line-height: 1.1;
    margin: 4px 0 8px;
}

.social-profile-copy p {
    max-width: 720px;
    color: var(--text-secondary);
}

.profile-meta-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
}

.profile-meta-row span {
    padding: 7px 12px;
    border: 1px solid var(--border-color);
    border-radius: 999px;
    background: #fbfefd;
    color: var(--text-secondary);
    font-size: 0.82rem;
    font-weight: 800;
    white-space: nowrap;
}

.personal-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    justify-content: flex-start;
    padding-top: 18px;
    border-top: 1px solid var(--border-color);
}

.personal-stats-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(120px, 1fr));
    gap: 16px;
}

.personal-stats-grid div {
    padding: 20px;
}

.personal-stats-grid strong {
    display: block;
    color: var(--primary-dark);
    font-size: 1.8rem;
}

.personal-stats-grid span {
    color: var(--text-secondary);
    font-weight: 800;
}

.personal-card-header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 18px;
}

.personal-card-header .profile-section-heading {
    margin-bottom: 0;
}

.saved-mini-grid {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
}

.saved-mini-card {
    padding: 18px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: #fbfefd;
}

.saved-mini-card h3 {
    margin: 12px 0 8px;
    font-size: 1.05rem;
}

.saved-mini-card p {
    color: var(--text-secondary);
    margin-bottom: 14px;
}

.compact-empty {
    padding: 24px;
    text-align: left;
}

.application-card {
    background: var(--white);
    border-radius: var(--radius-md);
    padding: 24px;
    box-shadow: var(--shadow-sm);
    display: flex;
    justify-content: space-between;
    align-items: center;
}

.application-info h3 {
    font-size: 1.2rem;
    margin-bottom: 8px;
}

.application-info p {
    color: var(--text-secondary);
    font-size: 0.9rem;
}

.application-status {
    padding: 8px 16px;
    border-radius: 20px;
    font-weight: 600;
    font-size: 0.9rem;
}

.status-pending {
    background-color: #fef3c7;
    color: #d97706;
}

.status-approved {
    background-color: #dcfce7;
    color: #16a34a;
}

.status-declined {
    background-color: #fee2e2;
    color: #dc2626;
}

.status-shortlisted {
    background-color: #dbeafe;
    color: #2563eb;
}

/* ===== Responsive ===== */
@media (max-width: 992px) {
    .main-header .container {
        flex-wrap: wrap;
        align-items: center;
    }

    .main-nav {
        order: 3;
        width: 100%;
        overflow: visible;
        flex-wrap: wrap;
        justify-content: center;
        border-radius: var(--radius-md);
    }

    .nav-link {
        flex: 1 1 128px;
        text-align: center;
    }
    
    .hero .container {
        flex-direction: column;
        text-align: center;
    }
    
    .hero h1 {
        font-size: 2.5rem;
    }
    
    .hero-cta {
        justify-content: center;
    }
    
    .opportunity-detail-grid {
        grid-template-columns: 1fr;
    }
    
    .opportunity-sidebar {
        position: static;
    }
}

@media (max-width: 768px) {
    .hero h1 {
        font-size: 2rem;
    }
    
    .stats-grid {
        grid-template-columns: repeat(2, 1fr);
    }
    
    .application-card {
        flex-direction: column;
        text-align: center;
        gap: 16px;
    }
}

@media (max-width: 480px) {
    .main-header .container {
        padding: 12px 14px;
    }

    .main-nav {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 6px;
    }

    .nav-link {
        min-width: 0;
        padding: 9px 8px;
        font-size: 0.72rem;
        white-space: normal;
    }

    .auth-buttons {
        gap: 8px;
    }
    
    .btn {
        padding: 8px 16px;
        font-size: 0.9rem;
    }
    
    .filters-container {
        flex-direction: column;
        align-items: stretch;
    }
}

/* ===== Alert Box ===== */
.alert {
    padding: 16px 20px;
    border-radius: var(--radius-sm);
    margin-bottom: 20px;
    display: flex;
    align-items: center;
    gap: 12px;
}

.alert-info {
    background-color: #dbeafe;
    color: #1e40af;
    border: 1px solid #93c5fd;
}

.alert-success {
    background-color: #dcfce7;
    color: #166534;
    border: 1px solid #86efac;
}

.alert-warning {
    background-color: #fef3c7;
    color: #92400e;
    border: 1px solid #fcd34d;
}

/* ===== Empty State ===== */
.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: var(--text-secondary);
}

.empty-state-icon {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 120px;
    min-height: 38px;
    padding: 8px 14px;
    border-radius: 999px;
    background: var(--primary-light);
    color: var(--primary-dark);
    border: 1px solid var(--border-color);
    font-size: 0.85rem;
    font-weight: 800;
    text-transform: uppercase;
    margin-bottom: 16px;
}

.empty-state h3 {
    font-size: 1.5rem;
    margin-bottom: 8px;
    color: var(--text-primary);
}

/* ===== Notification Badge ===== */
.notification-badge {
    background-color: #ef4444;
    color: white;
    font-size: 0.75rem;
    padding: 2px 6px;
    border-radius: 10px;
    margin-left: 4px;
}

/* ===== Wishing Well, Community, Profiles ===== */
.well-layout,
.community-layout,
.profile-page {
    padding: 36px 0 80px;
}

.well-layout .container,
.community-layout .container {
    display: grid;
    grid-template-columns: 292px minmax(0, 1fr);
    gap: 28px;
    align-items: start;
}

.well-filters,
.community-sidebar,
.forum-shell {
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    box-shadow: var(--shadow-md);
}

.well-filters {
    position: sticky;
    top: 104px;
}

.well-filters h3,
.community-sidebar h3 {
    margin: 22px 0 10px;
    font-size: 1rem;
}

.filter-heading {
    padding: 14px;
    margin: -4px -4px 18px;
    background: var(--sky-light);
    border: 1px solid #cfe6fb;
    border-radius: var(--radius-sm);
}

.filter-heading span,
.section-toolbar h2 {
    display: block;
    font-weight: 800;
}

.filter-heading small {
    display: block;
    color: var(--text-secondary);
}

.well-filters h3:first-child,
.community-sidebar h3:first-child {
    margin-top: 0;
}

.filter-pill {
    width: 100%;
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 8px;
    padding: 11px 12px;
    margin-bottom: 9px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: #fbfefd;
    color: var(--text-secondary);
    font: inherit;
    font-weight: 700;
    cursor: pointer;
    text-align: left;
}

.filter-pill.active,
.filter-pill:hover {
    border-color: var(--primary-color);
    background: var(--primary-light);
    color: var(--primary-dark);
    box-shadow: inset 0 0 0 1px rgba(47, 191, 122, 0.14);
}

.filter-input {
    width: 100%;
    padding: 12px 14px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-sm);
    font: inherit;
}

.wishes-list,
.feed-list {
    display: grid;
    gap: 18px;
}

.wish-card,
.post-card,
.project-card,
.composer-card {
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 22px;
    box-shadow: 0 10px 30px rgba(24, 36, 61, 0.06);
}

.wish-card {
    position: relative;
    overflow: visible;
}

.wish-card::before {
    content: '';
    position: absolute;
    inset: 0 auto 0 0;
    width: 5px;
    background: var(--tag-color, var(--primary-color));
}

.wish-card-top,
.card-actions {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    flex-wrap: wrap;
}

.wish-type {
    color: var(--primary-dark);
    background: var(--primary-light);
    border-radius: 999px;
    padding: 7px 12px;
    font-weight: 800;
    font-size: 0.9rem;
}

.entity-mark,
.avatar,
.profile-avatar,
.wish-image {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    flex: 0 0 auto;
    border-radius: 50%;
    background: var(--primary-light);
    border: 1px solid rgba(7, 63, 66, 0.14);
    color: var(--primary-dark);
    font-weight: 900;
    letter-spacing: 0.04em;
}

.entity-mark {
    width: 34px;
    height: 34px;
    font-size: 0.72rem;
}

.card-open-button {
    width: 100%;
    min-height: 132px;
    margin: 14px 0 2px;
    border: 1px solid rgba(15, 93, 85, 0.1);
    border-radius: var(--radius-sm);
    background:
        linear-gradient(135deg, rgba(255,255,255,0.5), rgba(255,255,255,0.82)),
        linear-gradient(135deg, var(--tag-color, var(--primary-light)), #ffffff);
    cursor: pointer;
}

.wish-image {
    width: 76px;
    height: 76px;
    background: rgba(255, 255, 255, 0.75);
    box-shadow: var(--shadow-sm);
    font-size: 1.2rem;
}

.wish-card h3 button {
    border: 0;
    background: transparent;
    color: inherit;
    font: inherit;
    font-weight: 800;
    text-align: left;
    cursor: pointer;
}

.wish-card h3 button:hover {
    color: var(--primary-dark);
}

.wish-detail-hero {
    margin: -8px -8px 20px;
    padding: 28px;
    border-radius: var(--radius-sm);
    background:
        linear-gradient(135deg, rgba(255, 255, 255, 0.72), rgba(255, 255, 255, 0.92)),
        linear-gradient(135deg, var(--tag-color, var(--primary-light)), var(--sky-light));
}

.wish-detail-hero h2 {
    margin: 16px 0 12px;
    font-size: 1.9rem;
}

.wish-detail-scroll {
    display: grid;
    gap: 16px;
}

.wish-detail-description {
    color: var(--text-secondary);
    font-size: 1rem;
}

.wish-detail-actions {
    position: sticky;
    bottom: -1px;
    z-index: 2;
    margin: 4px -8px -8px;
    padding: 14px 8px 8px;
    background: linear-gradient(180deg, rgba(255, 255, 255, 0), var(--white) 22%);
}

.dream-box {
    margin: 20px 0;
    padding: 20px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: #fbfefd;
}

.dream-box h3 {
    margin: 0 0 8px;
}

.dream-box h3 + p,
.dream-box h3 + .opportunity-skills {
    margin-bottom: 18px;
}

.impact-signals {
    display: grid;
    gap: 10px;
    margin: 12px 0 18px;
}

.impact-signals span {
    display: block;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: var(--primary-light);
}

.impact-signals strong,
.impact-signals small {
    display: block;
}

.impact-signals small {
    color: var(--text-secondary);
}

.sr-only {
    position: absolute;
    width: 1px;
    height: 1px;
    padding: 0;
    margin: -1px;
    overflow: hidden;
    clip: rect(0, 0, 0, 0);
    white-space: nowrap;
    border: 0;
}

.low-data-mode,
.low-data-mode .page-header,
.low-data-mode .wishing-hero,
.low-data-mode .hero,
.low-data-mode .smart-matching-section,
.low-data-mode .stats-section,
.low-data-mode .cta-section {
    background-image: none !important;
}

.low-data-mode * {
    animation: none !important;
    transition-duration: 0.01ms !important;
}

.low-data-mode .opportunity-card,
.low-data-mode .wish-card,
.low-data-mode .daily-action-card,
.low-data-mode .match-card,
.low-data-mode .playbook-card {
    box-shadow: none;
}

.heart-button {
    width: 58px;
    height: 36px;
    border-radius: 999px;
    border: 1px solid var(--border-color);
    background: var(--white);
    color: var(--text-secondary);
    font-size: 0.76rem;
    font-weight: 800;
    cursor: pointer;
}

.wish-card h3,
.post-card h3,
.project-card h3 {
    margin: 14px 0 10px;
    font-size: 1.25rem;
    line-height: 1.25;
}

.share-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin-top: 16px;
    padding-top: 14px;
    border-top: 1px solid var(--border-color);
}

.share-row button {
    border: 1px solid var(--border-color);
    background: #fbfefd;
    color: var(--text-secondary);
    border-radius: 999px;
    padding: 7px 11px;
    font: inherit;
    font-size: 0.78rem;
    font-weight: 800;
    cursor: pointer;
}

.share-row button:hover {
    border-color: var(--primary-color);
    color: var(--primary-dark);
    background: var(--primary-light);
}

.wish-author,
.post-author,
.person-row > a {
    display: flex;
    align-items: center;
    gap: 10px;
    color: var(--text-secondary);
    margin-bottom: 12px;
}

.wish-author small,
.post-author small,
.person-row small {
    display: block;
    color: var(--text-light);
}

.post-author-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
}

.post-card-tools {
    display: flex;
    align-items: center;
    gap: 8px;
    flex: 0 0 auto;
}

.post-more-menu {
    position: absolute;
    top: 14px;
    right: 14px;
    z-index: 12;
}

.post-more-menu summary {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    border: 1px solid transparent;
    color: var(--text-secondary);
    font-weight: 900;
    line-height: 1;
    cursor: pointer;
    list-style: none;
}

.post-more-menu summary::-webkit-details-marker {
    display: none;
}

.post-more-menu summary:hover,
.post-more-menu[open] summary {
    background: var(--primary-light);
    border-color: rgba(15, 93, 85, 0.16);
    color: var(--primary-dark);
}

.post-more-panel {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    z-index: 20;
    min-width: 188px;
    display: grid;
    gap: 2px;
    padding: 8px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: var(--white);
    box-shadow: var(--shadow-lg);
}

.post-more-panel button {
    width: 100%;
    border: 0;
    border-radius: var(--radius-sm);
    background: transparent;
    color: var(--text-secondary);
    font: inherit;
    font-weight: 800;
    text-align: left;
    padding: 10px 12px;
    cursor: pointer;
}

.post-more-panel button:hover {
    background: var(--primary-light);
    color: var(--primary-dark);
}

.post-type-tag {
    flex: 0 0 auto;
    padding: 7px 12px;
    border-radius: 999px;
    background: var(--primary-light);
    border: 1px solid rgba(7, 63, 66, 0.14);
    color: var(--primary-dark);
    font-size: 0.78rem;
    font-weight: 900;
    text-transform: uppercase;
    white-space: nowrap;
}

.post-tag-row {
    display: flex;
    flex-wrap: wrap;
    gap: 8px;
    margin: 14px 0;
}

.post-tag-row span {
    padding: 5px 10px;
    border-radius: 999px;
    background: #fbfefd;
    border: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-size: 0.78rem;
    font-weight: 800;
}

.spotlight-block {
    margin-top: 32px;
    background: linear-gradient(120deg, var(--primary-light), var(--sky-light));
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 28px;
}

.section-toolbar {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 16px;
    margin-bottom: 16px;
}

.section-toolbar h2 {
    font-size: 1.9rem;
    margin-top: 8px;
}

.toolbar-note {
    color: var(--text-secondary);
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: 999px;
    padding: 8px 12px;
    font-weight: 800;
    white-space: nowrap;
}

.avatar {
    width: 42px;
    height: 42px;
    font-size: 0.78rem;
}

.person-row {
    display: grid;
    gap: 8px;
    padding: 12px 0;
    border-bottom: 1px solid var(--border-color);
}

.person-actions {
    display: flex;
    gap: 8px;
    padding-left: 52px;
}

.person-actions button {
    border: 1px solid var(--border-color);
    border-radius: 999px;
    background: #fbfefd;
    color: var(--text-secondary);
    font: inherit;
    font-size: 0.78rem;
    font-weight: 800;
    padding: 6px 10px;
    cursor: pointer;
}

.community-sidebar a {
    display: block;
    margin-bottom: 10px;
    color: var(--text-secondary);
    font-weight: 700;
}

.composer-card {
    display: flex;
    justify-content: space-between;
    align-items: center;
    gap: 16px;
    margin-bottom: 20px;
    color: var(--text-secondary);
}

.composer-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.composer-card button,
.composer-card a,
.post-actions button,
.post-actions a {
    border: none;
    background: transparent;
    color: var(--text-secondary);
    font: inherit;
    font-weight: 700;
    cursor: pointer;
}

.inline-composer {
    display: none;
}

.inline-composer.active {
    display: block;
}

.inline-post-form {
    margin-bottom: 20px;
    padding: 22px;
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: var(--shadow-md);
}

.compact-toolbar {
    align-items: center;
}

.post-actions {
    display: flex;
    gap: 10px;
    flex-wrap: wrap;
}

.post-actions button,
.post-actions a {
    padding: 7px 10px;
    border: 1px solid var(--border-color);
    border-radius: 999px;
    background: #fbfefd;
}

.post-actions button:hover,
.post-actions a:hover,
.person-actions button:hover {
    border-color: var(--primary-color);
    background: var(--primary-light);
    color: var(--primary-dark);
}

.post-comments {
    margin-top: 16px;
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
}

.comment-summary {
    margin-bottom: 10px;
    color: var(--text-secondary);
    font-weight: 800;
    font-size: 0.86rem;
}

.comment-row {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 10px;
    padding: 10px 0;
    border-bottom: 1px solid rgba(15, 93, 85, 0.08);
}

.comment-avatar {
    width: 32px;
    height: 32px;
    font-size: 0.68rem;
}

.comment-row p {
    margin: 3px 0 0;
    color: var(--text-secondary);
}

.comment-form {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px;
    margin-top: 12px;
}

.comment-form input {
    min-width: 0;
    border: 1px solid var(--border-color);
    border-radius: 999px;
    padding: 10px 14px;
    font: inherit;
}

.comment-form button {
    border: 1px solid var(--primary-color);
    border-radius: 999px;
    padding: 10px 16px;
    background: var(--primary-color);
    color: var(--white);
    font: inherit;
    font-weight: 800;
    cursor: pointer;
}

.topic-groups-list {
    display: grid;
    gap: 8px;
}

.group-link-pill {
    display: flex !important;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    text-decoration: none;
}

.forum-group-card,
.thread-row,
.saved-item-card {
    display: grid;
    gap: 12px;
    padding: 18px;
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: 0 10px 30px rgba(24, 36, 61, 0.05);
}

.forum-group-card {
    color: inherit;
    text-decoration: none;
}

.forum-group-card > span,
.saved-item-card small {
    color: var(--text-light);
    font-size: 0.82rem;
    font-weight: 800;
}

.forum-group-card h3,
.thread-row h3,
.saved-item-card h3 {
    margin: 0;
}

.forum-thread-list,
.saved-list {
    display: grid;
    gap: 14px;
}

.forum-workbench {
    display: grid;
    grid-template-columns: minmax(240px, 0.9fr) minmax(0, 1.45fr);
    gap: 22px;
    align-items: start;
    padding: 24px;
    margin: 18px 0 28px;
    background:
        linear-gradient(135deg, rgba(232, 247, 243, 0.9), rgba(255, 255, 255, 0.96)),
        var(--white);
    border: 1px solid rgba(20, 124, 117, 0.18);
    border-radius: var(--radius-lg);
    box-shadow: 0 18px 46px rgba(24, 36, 61, 0.07);
}

.forum-workbench h2 {
    margin: 6px 0 12px;
    font-size: clamp(1.7rem, 3vw, 2.55rem);
}

.forum-workbench p {
    color: var(--text-secondary);
    line-height: 1.7;
}

.forum-question-form {
    display: grid;
    gap: 14px;
    padding: 18px;
    background: rgba(255, 255, 255, 0.86);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
}

.forum-leaders-grid {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 14px;
    margin-bottom: 28px;
}

.forum-leader-card {
    display: grid;
    gap: 12px;
    padding: 16px;
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    box-shadow: 0 10px 30px rgba(24, 36, 61, 0.05);
}

.forum-leader-main {
    display: flex;
    gap: 10px;
    align-items: center;
    color: inherit;
    text-decoration: none;
}

.forum-leader-main span {
    display: grid;
    gap: 2px;
}

.forum-leader-main small,
.forum-leader-card p {
    color: var(--text-light);
}

.forum-leader-card p {
    margin: 0;
    line-height: 1.55;
}

.organization-filter-panel {
    display: grid;
    gap: 18px;
    margin-bottom: 28px;
    padding: 24px;
    background:
        linear-gradient(135deg, rgba(232, 247, 243, 0.88), rgba(255, 255, 255, 0.96)),
        var(--white);
    border: 1px solid rgba(20, 124, 117, 0.18);
    border-radius: var(--radius-lg);
    box-shadow: 0 18px 44px rgba(24, 36, 61, 0.06);
}

.organization-filter-panel h2 {
    margin: 6px 0 8px;
    font-size: clamp(1.6rem, 3vw, 2.35rem);
}

.organization-filter-panel p {
    color: var(--text-secondary);
}

.organization-filter-grid {
    display: grid;
    grid-template-columns: minmax(220px, 1.25fr) minmax(160px, 0.8fr) minmax(160px, 0.8fr) auto;
    gap: 14px;
    align-items: end;
}

.filter-results-note {
    margin: 0;
    font-weight: 800;
    color: var(--primary-dark);
}

.organizations-empty-state {
    grid-column: 1 / -1;
}

.thread-row,
.saved-item-card {
    grid-template-columns: minmax(0, 1fr) auto;
    align-items: center;
}

.saved-shell {
    display: grid;
    gap: 22px;
}

.saved-card-actions {
    display: flex;
    gap: 8px;
    flex-wrap: wrap;
    justify-content: flex-end;
}

.group-stats-row {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    margin-top: 16px;
}

.group-stats-row span,
.clean-step-list li {
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.78);
}

.group-stats-row span {
    padding: 8px 12px;
    font-weight: 800;
    color: var(--primary-dark);
}

.discussion-layout .inline-composer {
    margin-bottom: 22px;
}

.discussion-main h2 {
    margin-bottom: 14px;
}

.clean-step-list {
    display: grid;
    gap: 8px;
    padding: 0;
    margin: 12px 0 16px;
    list-style: none;
}

.clean-step-list li {
    padding: 10px 12px;
    color: var(--text-secondary);
}

/* ===== Write Post Page ===== */
.write-post-page {
    padding: 36px 0 80px;
}

.write-post-page .container {
    display: grid;
    grid-template-columns: 280px minmax(0, 1fr) 320px;
    gap: 24px;
    align-items: start;
}

.topic-panel,
.write-post-form-panel,
.preview-panel {
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    box-shadow: var(--shadow-md);
}

.topic-panel,
.preview-panel {
    position: sticky;
    top: 104px;
}

.topic-list {
    display: grid;
    gap: 10px;
}

.topic-choice {
    display: block;
    width: 100%;
    padding: 14px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: #fbfefd;
    color: inherit;
    font: inherit;
    text-align: left;
    cursor: pointer;
}

.topic-choice strong,
.topic-choice span,
.topic-prompt strong,
.topic-prompt span,
.guideline-box strong,
.guideline-box span {
    display: block;
}

.topic-choice strong {
    color: var(--primary-dark);
}

.topic-choice span,
.topic-prompt span,
.guideline-box span {
    color: var(--text-secondary);
    font-size: 0.92rem;
}

.topic-choice.active,
.topic-choice:hover {
    border-color: var(--primary-color);
    background: var(--primary-light);
}

.topic-prompt,
.guideline-box {
    margin-bottom: 18px;
    padding: 16px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: var(--primary-light);
}

.forum-categories {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(220px, 1fr));
    gap: 12px;
    margin: 24px 0;
}

.forum-stats {
    background: var(--primary-color);
    border-radius: var(--radius-md);
    padding: 24px;
    margin-bottom: 32px;
}

.profile-page {
    padding: 44px 0 80px;
}

.profile-cover {
    position: relative;
    margin-bottom: 24px;
    padding: 0;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: var(--white);
    box-shadow: var(--shadow-md);
    overflow: hidden;
}

.profile-story-cover {
    border-radius: var(--radius-lg);
}

.profile-cover-band {
    min-height: clamp(120px, 18vw, 210px);
    background:
        linear-gradient(115deg, rgba(7, 63, 66, 0.28), rgba(231, 242, 239, 0.72)),
        var(--page-photo) right center / cover no-repeat;
    border-bottom: 1px solid var(--border-color);
}

.profile-hero {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr);
    gap: 22px;
    align-items: start;
    padding: 0 28px 24px;
}

.profile-summary h1 {
    font-size: clamp(2rem, 3.8vw, 3.5rem);
    line-height: 1.06;
    margin: 6px 0 12px;
    max-width: 780px;
}

.profile-summary > p {
    max-width: 760px;
    color: var(--text-secondary);
    font-size: 1.08rem;
    line-height: 1.55;
}

.profile-avatar {
    width: clamp(96px, 12vw, 132px);
    height: clamp(96px, 12vw, 132px);
    margin-top: calc(clamp(48px, 6vw, 66px) * -1);
    border: 6px solid var(--white);
    font-size: 1.45rem;
    box-shadow: 0 18px 34px rgba(7, 63, 66, 0.14);
}

.profile-avatar-img {
    display: block;
    object-fit: cover;
    border-radius: 50%;
    border: 2px solid var(--white);
    background: var(--primary-light);
}

.profile-type {
    color: var(--text-secondary);
    font-weight: 800;
    margin: 4px 0 12px;
}

.profile-actions {
    grid-column: 1 / -1;
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-items: center;
    justify-content: flex-end;
    margin-top: 16px;
}

.profile-more-menu {
    position: relative;
}

.profile-more-menu summary {
    width: 44px;
    height: 44px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border: 1.5px solid rgba(7, 63, 66, 0.22);
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.76);
    color: var(--primary-dark);
    font-weight: 900;
    cursor: pointer;
    list-style: none;
}

.profile-more-menu summary::-webkit-details-marker {
    display: none;
}

.profile-more-menu div {
    position: absolute;
    top: calc(100% + 8px);
    right: 0;
    z-index: 30;
    min-width: 190px;
    display: grid;
    padding: 8px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: var(--white);
    box-shadow: var(--shadow-lg);
}

.profile-more-menu button {
    border: 0;
    border-radius: var(--radius-sm);
    background: transparent;
    color: var(--text-secondary);
    font: inherit;
    font-weight: 800;
    text-align: left;
    padding: 10px 12px;
    cursor: pointer;
}

.profile-more-menu button:hover {
    background: var(--primary-light);
    color: var(--primary-dark);
}

.profile-stats {
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 14px;
    padding: 0 28px 28px;
    margin-top: 0;
}

.profile-stats div {
    min-width: 0;
    background: rgba(251, 254, 253, 0.95);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 18px;
    text-align: center;
}

.profile-stats strong {
    display: block;
    font-size: 1.8rem;
    color: var(--primary-dark);
}

.profile-stats span {
    color: var(--text-secondary);
}

.trust-panel {
    margin: 18px 0 20px;
}

.profile-grid {
    display: grid;
    grid-template-columns: minmax(0, 1fr) 330px;
    gap: 24px;
    align-items: start;
}

.profile-main-column {
    display: grid;
    gap: 20px;
}

.profile-section-card {
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 24px;
    box-shadow: var(--shadow-sm);
}

.profile-story-card {
    padding: clamp(22px, 3vw, 34px);
}

.profile-section-heading {
    display: flex;
    align-items: center;
    gap: 12px;
    margin-bottom: 18px;
}

.profile-section-heading span {
    width: 34px;
    height: 34px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--primary-light);
    color: var(--primary-dark);
    font-weight: 900;
    font-size: 0.85rem;
}

.profile-section-heading h2 {
    margin: 0;
}

.questionnaire-type-badge {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-inline-start: auto;
    padding-inline: 12px 8px;
    padding-block: 5px;
    border-radius: 999px;
    background: var(--primary-light);
    color: var(--primary-dark);
    font-size: 0.78rem;
    font-weight: 900;
}

/* When the toggle is present it carries the auto-margin instead, so the badge
   sits directly before it rather than getting pushed to opposite ends. */
.profile-section-heading:has(.section-collapse-toggle) .questionnaire-type-badge {
    margin-inline-start: auto;
}

.profile-section-heading:has(.section-collapse-toggle) .questionnaire-type-badge ~ .section-collapse-toggle {
    margin-inline-start: 0;
}

.questionnaire-badge-close {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    width: 18px;
    height: 18px;
    border: none;
    border-radius: 50%;
    background: transparent;
    color: inherit;
    font-size: 1rem;
    line-height: 1;
    cursor: pointer;
}

.questionnaire-badge-close:hover {
    background: rgba(0, 0, 0, 0.08);
}

.section-collapse-toggle {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    margin-inline-start: auto;
    padding: 6px 12px;
    border: 1px solid var(--border-color);
    border-radius: 999px;
    background: var(--white);
    color: var(--primary-dark);
    font: inherit;
    font-size: 0.8rem;
    font-weight: 900;
    cursor: pointer;
    transition: background-color 0.2s;
}

.section-collapse-toggle:hover {
    background: var(--primary-light);
}

.collapse-chevron {
    font-size: 0.7rem;
    transition: transform 0.2s;
}

.profile-section-card:not(.is-collapsed) .collapse-chevron {
    transform: rotate(180deg);
}

.profile-section-card.is-collapsed .section-collapsible {
    display: none;
}

.profile-info-list {
    display: grid;
    gap: 12px;
}

.profile-info-list p {
    display: grid;
    grid-template-columns: 150px minmax(0, 1fr);
    gap: 16px;
    padding-bottom: 12px;
    border-bottom: 1px solid var(--border-color);
}

.profile-info-list.compact {
    gap: 8px;
}

.profile-info-list.compact p {
    grid-template-columns: 92px minmax(0, 1fr);
    gap: 10px;
    font-size: 0.95rem;
}

.profile-info-list a {
    color: var(--primary-dark);
    font-weight: 800;
    overflow-wrap: anywhere;
}

.profile-lead-text {
    max-width: 820px;
    color: var(--text-secondary);
    font-size: 1.08rem;
    line-height: 1.7;
}

.profile-narrative-grid,
.profile-impact-story {
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 14px;
    margin-top: 22px;
}

.profile-narrative-grid p,
.profile-impact-story > div,
.profile-learning-panel p {
    margin: 0;
    padding: 18px;
    border: 1px solid rgba(20, 124, 117, 0.14);
    border-radius: var(--radius-md);
    background: rgba(251, 254, 253, 0.88);
}

.profile-narrative-grid strong,
.profile-impact-story strong,
.profile-learning-panel strong {
    display: block;
    margin-bottom: 8px;
    color: var(--primary-dark);
    font-size: 0.92rem;
}

.profile-narrative-grid span,
.profile-impact-story p,
.profile-learning-panel span {
    color: var(--text-secondary);
    line-height: 1.6;
}

.profile-learning-panel {
    display: grid;
    gap: 12px;
}

.profile-learning-panel p {
    display: grid;
    grid-template-columns: 190px minmax(0, 1fr);
    gap: 18px;
    align-items: start;
}

.profile-contact-card a {
    color: var(--primary-dark);
    font-weight: 800;
    overflow-wrap: anywhere;
}

.profile-info-list p:last-child {
    border-bottom: 0;
    padding-bottom: 0;
}

.profile-info-list strong {
    color: var(--primary-dark);
}

.profile-info-list span,
.muted-note {
    color: var(--text-secondary);
}

.profile-sidebar {
    display: grid;
    gap: 16px;
    position: sticky;
    top: 92px;
}

.mini-need-list {
    display: grid;
    gap: 14px;
    margin-bottom: 22px;
}

.mini-need-list article {
    padding: 18px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: #fbfefd;
}

.mini-need-list h3 {
    margin: 12px 0 8px;
}

.mini-need-list p {
    color: var(--text-secondary);
}

.mini-opportunity-list,
.profile-post-list,
.profile-check-list {
    display: grid;
    gap: 14px;
}

.mini-opportunity-list article,
.profile-post-list article {
    padding: 18px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: #fbfefd;
}

.mini-opportunity-list h3,
.profile-post-list h3 {
    margin: 12px 0 8px;
}

.mini-opportunity-list p,
.profile-post-list p {
    color: var(--text-secondary);
}

.profile-check-list span {
    display: block;
    padding: 10px 0 10px 24px;
    border-bottom: 1px solid var(--border-color);
    color: var(--text-secondary);
    font-weight: 700;
    position: relative;
}

.profile-check-list span::before {
    content: '';
    position: absolute;
    left: 2px;
    top: 17px;
    width: 8px;
    height: 8px;
    border-radius: 50%;
    background: var(--primary-color);
}

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

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

    .modal {
        padding: 8px;
    }

    .modal-content {
        width: min(100%, 680px);
        max-height: calc(100dvh - 16px);
        border-radius: var(--radius-sm);
    }

    .modal-wide {
        max-width: calc(100vw - 16px);
    }

    .wizard-progress {
        grid-template-columns: repeat(3, 1fr);
    }

    .profile-type-grid,
    .choice-grid,
    .compact-choice-grid,
    .form-grid-2,
    .organization-filter-grid {
        grid-template-columns: 1fr;
    }

    .wizard-actions {
        display: grid;
        grid-template-columns: 1fr;
    }

    .inline-field-action {
        grid-template-columns: 1fr;
    }

    .close-modal {
        width: 42px;
        height: 42px;
        margin: -10px -10px 6px 10px;
    }

    .wish-detail-hero {
        margin: 0 0 16px;
        padding: 20px;
    }

    .wish-detail-actions {
        display: grid;
        grid-template-columns: 1fr;
    }

    .page-header {
        background:
            linear-gradient(180deg, rgba(247, 250, 247, 0.96), rgba(227, 245, 240, 0.92)),
            var(--page-photo) center / cover no-repeat;
        padding: 48px 0;
    }

    .page-header h1,
    .page-header p {
        text-align: left;
    }

    .wishing-hero .container,
    .well-layout .container,
    .community-layout .container,
    .write-post-page .container,
    .blueprint-grid,
    .flow-board,
    .trust-strip .container,
    .trust-panel,
    .workspace-steps,
    .profile-grid,
    .profile-hero,
    .personal-shell,
    .personal-stats-grid,
    .forum-workbench {
        grid-template-columns: 1fr;
    }

    .personal-sidebar {
        position: static;
    }

    .social-profile-head {
        flex-direction: column;
        align-items: flex-start;
        gap: 12px;
    }

    .social-avatar-wrap {
        margin-top: -76px;
    }

    .saved-mini-grid {
        grid-template-columns: 1fr;
    }

    .personal-actions .btn {
        flex: 1 1 auto;
    }

    .profile-cover {
        padding: 0;
    }

    .profile-actions {
        grid-column: 1 / -1;
    }

    .profile-stats {
        grid-template-columns: repeat(2, 1fr);
        padding: 0 22px 22px;
    }

    .profile-narrative-grid,
    .profile-impact-story,
    .profile-learning-panel p {
        grid-template-columns: 1fr;
    }

    .profile-sidebar {
        position: static;
    }

    .profile-info-list p,
    .profile-info-list.compact p {
        grid-template-columns: 1fr;
        gap: 4px;
    }

    .wishing-hero {
        padding: 42px 0 34px;
    }

    .wishing-hero h1 {
        font-size: 2.45rem;
    }

    .well-summary-panel {
        grid-template-columns: repeat(3, 1fr);
    }

    .well-summary-panel div {
        display: block;
        text-align: center;
    }

    .well-filters {
        position: static;
        display: flex;
        flex-wrap: wrap;
        gap: 8px;
        order: 2;
    }

    .wishes-column {
        order: 1;
    }

    .filter-heading,
    .well-filters h3,
    .well-filters .filter-input,
    #clear-wish-filters {
        width: 100%;
    }

    .well-filters .filter-pill {
        width: auto;
        margin-bottom: 0;
        flex: 1 1 190px;
        justify-content: center;
        text-align: center;
    }

    .profile-actions {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .path-grid,
    .form-grid-2 {
        grid-template-columns: 1fr;
    }

    .thread-row,
    .saved-item-card,
    .comment-form {
        grid-template-columns: 1fr;
    }

    .saved-card-actions {
        justify-content: flex-start;
    }

.topic-panel,
.preview-panel {
    position: static;
}
}

.impact-home-hero {
    background:
        linear-gradient(90deg, rgba(250, 255, 253, 0.96), rgba(250, 255, 253, 0.8), rgba(250, 255, 253, 0.48)),
        var(--hero-photo) right center / cover no-repeat;
}

.impact-home-hero .container {
    min-height: 650px;
}

.impact-home-hero .hero-content {
    max-width: 660px;
}

.impact-home-hero h1 {
    max-width: 720px;
}

.glowe-system-figure,
.ecosystem-image,
.ecosystem-map {
    margin: 0;
    display: grid;
    place-items: center;
}

.glowe-system-figure img {
    width: min(500px, 100%);
    filter: drop-shadow(0 24px 42px rgba(19, 87, 91, 0.18));
}

.belonging-strip {
    padding: 22px 0;
    background: linear-gradient(90deg, #eef8f4 0%, #fffaf2 54%, #f6f2fb 100%);
    border-top: 1px solid rgba(15, 93, 85, 0.1);
    border-bottom: 1px solid rgba(15, 93, 85, 0.1);
}

.belonging-strip p {
    max-width: 980px;
    margin: 0 auto;
    color: var(--text-secondary);
    font-size: 1.08rem;
    line-height: 1.7;
    text-align: center;
}

.belonging-strip strong {
    color: var(--primary-dark);
}

.home-intro-section,
.home-ecosystem-section,
.home-audience-section,
.community-layers-section,
.journey-section {
    padding: 76px 0;
    background: var(--white);
}

.home-intro-section .container,
.home-ecosystem-section .container {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(280px, 440px);
    gap: 48px;
    align-items: center;
}

.intro-copy h2,
.ecosystem-copy h2 {
    font-size: clamp(2rem, 4vw, 3.4rem);
    line-height: 1.06;
    margin-bottom: 18px;
}

.intro-copy p,
.ecosystem-copy p {
    color: var(--text-secondary);
    font-size: 1.08rem;
    line-height: 1.75;
}

.home-sdg-strip {
    display: flex;
    flex-wrap: wrap;
    gap: 10px;
    align-content: center;
}

.home-sdg-strip span {
    padding: 10px 14px;
    border: 1px solid var(--border-color);
    border-radius: 999px;
    background: var(--primary-light);
    color: var(--primary-dark);
    font-weight: 900;
}

.home-action-board article {
    min-height: 230px;
}

.community-layers-section {
    background:
        linear-gradient(180deg, #f8fcfb 0%, #ffffff 100%),
        var(--white);
}

.community-layers-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 18px;
    margin-top: 26px;
}

.community-layer-card {
    display: grid;
    gap: 14px;
    min-height: 330px;
    padding: 28px;
    border: 1px solid rgba(15, 93, 85, 0.14);
    border-radius: var(--radius-md);
    background: var(--white);
    box-shadow: 0 18px 42px rgba(7, 63, 66, 0.07);
    position: relative;
    overflow: hidden;
}

.community-layer-card::before {
    content: "";
    position: absolute;
    inset: 0;
    height: 7px;
    background: var(--layer-accent, var(--primary-color));
}

.community-layer-card > span {
    color: var(--primary-dark);
    font-size: 0.82rem;
    font-weight: 900;
    text-transform: uppercase;
}

.community-layer-card h3 {
    margin: 0;
    font-size: 1.42rem;
    line-height: 1.18;
}

.community-layer-card p {
    color: var(--text-secondary);
    line-height: 1.7;
}

.community-layer-card a {
    align-self: end;
    color: var(--primary-dark);
    font-weight: 900;
}

.local-layer {
    --layer-accent: #73b69e;
}

.expert-layer {
    --layer-accent: #5f9fb5;
}

.global-layer {
    --layer-accent: #d4b66a;
}

.community-layers-flow {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 12px;
    margin-top: 18px;
}

.community-layers-flow span {
    padding: 14px;
    text-align: center;
    border: 1px solid rgba(15, 93, 85, 0.12);
    border-radius: var(--radius-sm);
    background: rgba(255, 255, 255, 0.86);
    color: var(--primary-dark);
    font-weight: 900;
}

.journey-section {
    background: linear-gradient(180deg, #ffffff 0%, #f8fcfb 100%);
}

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

.journey-grid article {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 12px;
    min-height: 260px;
    padding: 26px;
    border: 1px solid rgba(15, 93, 85, 0.14);
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.92);
    box-shadow: 0 16px 36px rgba(7, 63, 66, 0.07);
}

.journey-grid article > span {
    color: var(--primary-dark);
    font-size: 0.82rem;
    font-weight: 900;
    text-transform: uppercase;
}

.journey-grid h3 {
    margin: 0;
    color: var(--text-primary);
}

.journey-grid p {
    flex: 1;
    margin: 0;
    color: var(--text-secondary);
    line-height: 1.65;
}

.home-ecosystem-section {
    background: linear-gradient(180deg, #ffffff 0%, #f5fbf9 100%);
}

.ecosystem-map {
    position: relative;
    min-height: 470px;
    border: 1px solid rgba(15, 93, 85, 0.14);
    border-radius: var(--radius-lg);
    background:
        radial-gradient(circle at center, rgba(255, 255, 255, 0.98) 0 30%, rgba(231, 242, 239, 0.82) 31% 56%, rgba(255, 255, 255, 0.62) 57%),
        linear-gradient(135deg, #ffffff 0%, #f1faf7 100%);
    box-shadow: var(--shadow-md);
    overflow: hidden;
    padding: 28px;
}

.ecosystem-map::before {
    content: "";
    position: absolute;
    inset: 34px;
    border: 1px dashed rgba(15, 93, 85, 0.22);
    border-radius: 50%;
}

.ecosystem-core {
    position: relative;
    z-index: 2;
    width: 190px;
    height: 190px;
    border-radius: 50%;
    display: grid;
    place-items: center;
    background: rgba(255, 255, 255, 0.9);
    border: 1px solid rgba(15, 93, 85, 0.16);
    box-shadow: 0 22px 42px rgba(7, 63, 66, 0.14);
}

.ecosystem-core img {
    width: 98px;
    filter: drop-shadow(0 10px 18px rgba(7, 63, 66, 0.18));
}

.ecosystem-core strong {
    font-size: 1.4rem;
    color: var(--primary-dark);
}

.ecosystem-points {
    position: absolute;
    inset: 20px;
}

.ecosystem-points span {
    position: absolute;
    width: 148px;
    min-height: 54px;
    display: inline-flex;
    align-items: center;
    justify-content: center;
    text-align: center;
    padding: 10px 12px;
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.88);
    border: 1px solid rgba(15, 93, 85, 0.13);
    color: var(--primary-dark);
    font-weight: 800;
    line-height: 1.2;
    box-shadow: 0 10px 20px rgba(7, 63, 66, 0.08);
}

.ecosystem-points span:nth-child(1) { top: 4%; left: 50%; transform: translateX(-50%); }
.ecosystem-points span:nth-child(2) { top: 17%; right: 2%; }
.ecosystem-points span:nth-child(3) { top: 50%; right: 0; transform: translateY(-50%); }
.ecosystem-points span:nth-child(4) { right: 7%; bottom: 14%; }
.ecosystem-points span:nth-child(5) { left: 50%; bottom: 2%; transform: translateX(-50%); }
.ecosystem-points span:nth-child(6) { left: 7%; bottom: 14%; }
.ecosystem-points span:nth-child(7) { top: 50%; left: 0; transform: translateY(-50%); }
.ecosystem-points span:nth-child(8) { top: 17%; left: 2%; }

.ecosystem-points span:nth-child(2n) {
    background: rgba(245, 231, 232, 0.9);
}

.ecosystem-points span:nth-child(3n) {
    background: rgba(230, 238, 242, 0.92);
}

.ecosystem-points span:nth-child(5n) {
    background: rgba(238, 232, 241, 0.92);
}

.ecosystem-photo {
    margin: 0;
    position: relative;
    border-radius: var(--radius-lg);
    overflow: hidden;
    min-height: 420px;
    box-shadow: var(--shadow-lg);
    border: 1px solid rgba(15, 93, 85, 0.14);
    background: var(--primary-light);
}

.ecosystem-photo img {
    width: 100%;
    height: 100%;
    min-height: 420px;
    display: block;
    object-fit: cover;
}

.ecosystem-photo figcaption {
    position: absolute;
    left: 18px;
    right: 18px;
    bottom: 18px;
    display: grid;
    gap: 4px;
    padding: 16px 18px;
    border-radius: var(--radius-md);
    color: var(--white);
    background: rgba(5, 50, 48, 0.82);
    backdrop-filter: blur(10px);
}

.ecosystem-photo figcaption strong {
    font-size: 1.05rem;
}

.ecosystem-photo figcaption span {
    color: rgba(255, 255, 255, 0.86);
    line-height: 1.45;
}

.home-live-section {
    background: var(--background-soft);
}

.cta-section .cta-heading-final + h2 {
    display: none;
}

.daily-workspace-section,
.smart-matching-section,
.playbooks-section,
.growth-suite-section,
.funding-section,
.engagement-section,
.rewards-section,
.how-it-works,
.testimonials-section {
    display: none;
}

.whats-next-hero {
    background:
        linear-gradient(100deg, rgba(250, 255, 253, 0.96), rgba(250, 255, 253, 0.74)),
        var(--page-photo) center / cover no-repeat;
}

.whats-next-hero .container {
    max-width: 920px;
}

.whats-next-hero p {
    max-width: 760px;
}

.next-story-section,
.next-roadmap-section {
    padding: 76px 0;
    background: var(--white);
}

.next-story-section .container {
    display: grid;
    grid-template-columns: minmax(0, 1fr) minmax(300px, 460px);
    gap: 42px;
    align-items: start;
}

.next-story-copy h2 {
    font-size: clamp(2rem, 4vw, 3.2rem);
    line-height: 1.08;
    margin-bottom: 18px;
}

.next-story-copy p,
.next-roadmap-section .section-subtitle {
    color: var(--text-secondary);
    font-size: 1.06rem;
    line-height: 1.75;
}

.next-principle-list,
.next-roadmap-grid {
    display: grid;
    gap: 16px;
}

.next-principle-list article,
.next-roadmap-grid article,
.about-next-callout {
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    background: var(--white);
    padding: 22px;
    box-shadow: var(--shadow-sm);
}

.next-principle-list span {
    display: inline-flex;
    width: 34px;
    height: 34px;
    align-items: center;
    justify-content: center;
    border-radius: 50%;
    background: var(--primary-light);
    color: var(--primary-dark);
    font-weight: 900;
    margin-bottom: 12px;
}

.next-roadmap-section {
    background: linear-gradient(180deg, #ffffff 0%, #f5fbf9 100%);
}

.next-roadmap-grid {
    grid-template-columns: repeat(3, minmax(0, 1fr));
}

.next-roadmap-grid h3,
.next-principle-list h3 {
    margin-bottom: 8px;
}

.next-roadmap-grid p,
.next-principle-list p {
    color: var(--text-secondary);
    line-height: 1.65;
}

.about-next-callout {
    margin: 34px 0;
    background: var(--primary-light);
}

.legal-hero {
    background:
        linear-gradient(120deg, rgba(5, 50, 48, 0.82), rgba(15, 93, 85, 0.66)),
        url('../assets/glowe-regrowth.jpg') center / cover no-repeat;
}

.volunteer-network-hero {
    background:
        linear-gradient(110deg, rgba(250, 255, 253, 0.95), rgba(231, 242, 239, 0.84), rgba(230, 238, 242, 0.62)),
        url('../assets/glowe-field.jpg') center / cover no-repeat;
}

.volunteer-network-page .page-header .container {
    max-width: 880px;
}

.admin-hero {
    background:
        linear-gradient(110deg, rgba(250, 255, 253, 0.96), rgba(231, 242, 239, 0.86), rgba(230, 238, 242, 0.62)),
        url('../assets/glowe-bridge.jpg') center / cover no-repeat;
}

.admin-dashboard-section {
    padding: 64px 0 88px;
    background: linear-gradient(180deg, #ffffff, var(--primary-light));
}

.admin-stats {
    display: grid;
    grid-template-columns: repeat(auto-fit, minmax(130px, 1fr));
    gap: 16px;
    margin-bottom: 28px;
}

.admin-stats article,
.admin-panel,
.admin-card {
    border: 1px solid rgba(15, 93, 85, 0.13);
    border-radius: var(--radius-md);
    background: rgba(255, 255, 255, 0.92);
    box-shadow: var(--shadow-soft);
}

.admin-stats article {
    padding: 20px;
}

.admin-stats strong,
.admin-stats span {
    display: block;
}

.admin-stats strong {
    font-size: 2.1rem;
    color: var(--primary-dark);
}

.admin-stats span {
    color: var(--text-secondary);
    font-weight: 800;
}

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

.admin-panel {
    padding: 22px;
}

.admin-panel-wide {
    grid-column: 1 / -1;
}

.admin-list {
    display: grid;
    gap: 14px;
}

.admin-card {
    padding: 18px;
}

.admin-card h3 {
    margin: 10px 0 6px;
}

.admin-card p,
.admin-card small {
    color: var(--text-secondary);
}

.admin-note-label {
    display: block;
    margin: 12px 0 6px;
    font-size: 0.82rem;
    color: var(--text-secondary);
}

.admin-note-required {
    color: var(--primary-dark);
    font-style: italic;
}

.admin-note-label input,
.admin-note-label textarea {
    display: block;
    width: 100%;
    margin-top: 4px;
    padding: 8px 10px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    font: inherit;
    resize: vertical;
}

/* Accordion rows for pending org list */
.admin-org-accordion {
    border: 1px solid rgba(15, 93, 85, 0.15);
    border-radius: var(--radius-md);
    background: rgba(255,255,255,0.96);
    overflow: hidden;
}

.admin-org-accordion + .admin-org-accordion {
    margin-top: 8px;
}

.admin-org-summary {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 14px 18px;
    cursor: pointer;
    list-style: none;
    user-select: none;
}

.admin-org-summary::-webkit-details-marker { display: none; }

.admin-org-accordion[open] .admin-org-summary {
    border-bottom: 1px solid rgba(15, 93, 85, 0.12);
    background: var(--primary-light);
}

.admin-org-summary-name {
    font-weight: 700;
    color: var(--primary-dark);
    flex: 1;
    min-width: 0;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.admin-org-summary-meta {
    font-size: 0.82rem;
    color: var(--text-secondary);
    flex-shrink: 0;
}

.admin-org-summary-date {
    font-size: 0.78rem;
    color: var(--text-secondary);
    flex-shrink: 0;
}

.admin-org-summary-chevron {
    font-size: 0.9rem;
    color: var(--text-secondary);
    flex-shrink: 0;
    transition: transform 0.2s;
}

.admin-org-accordion[open] .admin-org-summary-chevron {
    transform: rotate(180deg);
}

.admin-org-detail {
    padding: 0;
}

.admin-org-detail .admin-card {
    border: none;
    border-radius: 0;
    box-shadow: none;
}

.report-target-box {
    display: grid;
    gap: 2px;
    margin-bottom: 16px;
    padding: 12px 14px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: var(--primary-light);
}

.report-target-box span {
    color: var(--text-secondary);
    font-size: 0.82rem;
    font-weight: 800;
    text-transform: uppercase;
}

.report-target-box strong {
    color: var(--primary-dark);
}

/* ===== LinkedIn-style Community Feed ===== */
.community-main {
    background:
        linear-gradient(180deg, rgba(231, 242, 239, 0.8), rgba(238, 243, 241, 0.98) 260px),
        #eef3f1;
    min-height: calc(100dvh - 76px);
}

.linkedin-community-layout {
    padding: 28px 0 84px;
}

.linkedin-community-layout .container {
    display: grid;
    grid-template-columns: minmax(210px, 250px) minmax(0, 1fr) minmax(260px, 320px);
    gap: 18px;
    align-items: start;
}

.community-left-rail,
.community-right-rail {
    display: grid;
    gap: 14px;
    position: static;
    align-self: start;
}

.community-feed-column {
    min-width: 0;
    display: grid;
    gap: 14px;
}

.community-profile-card,
.community-mini-card,
.community-feed-header,
.community-feed-controls,
.linkedin-composer,
.feed-filter-bar,
.linkedin-community-layout .post-card {
    background: var(--white);
    border: 1px solid rgba(15, 93, 85, 0.12);
    border-radius: var(--radius-md);
    box-shadow: 0 8px 24px rgba(24, 36, 61, 0.06);
}

.community-profile-card {
    overflow: hidden;
}

.community-feed-header {
    display: flex;
    align-items: flex-start;
    justify-content: space-between;
    gap: 18px;
    padding: 20px;
}

.community-feed-header h1 {
    margin: 6px 0 8px;
    font-size: clamp(1.65rem, 3vw, 2.45rem);
    line-height: 1.08;
}

.community-feed-header p {
    color: var(--text-secondary);
    max-width: 620px;
}

.community-feed-controls {
    display: grid;
    gap: 12px;
    padding: 14px;
}

.community-feed-controls input {
    width: 100%;
    min-height: 44px;
    padding: 11px 14px;
    border: 1px solid var(--border-color);
    border-radius: var(--radius-sm);
    background: #fbfefd;
    font: inherit;
}

.community-feed-tabs {
    display: flex;
    gap: 8px;
    overflow-x: auto;
    padding-bottom: 2px;
}

.community-feed-tabs button {
    flex: 0 0 auto;
    min-height: 38px;
    padding: 8px 13px;
    border: 1px solid var(--border-color);
    border-radius: 999px;
    background: var(--white);
    color: var(--text-secondary);
    font: inherit;
    font-weight: 850;
    cursor: pointer;
}

.community-feed-tabs button.active,
.community-feed-tabs button:hover {
    background: var(--primary-dark);
    border-color: var(--primary-dark);
    color: var(--white);
}

.profile-cover {
    height: 76px;
    background:
        linear-gradient(135deg, rgba(20, 124, 117, 0.74), rgba(13, 93, 115, 0.52)),
        url('../assets/glowe-roundtable-conference.png') center / cover no-repeat;
}

.community-profile-body {
    display: grid;
    gap: 10px;
    justify-items: center;
    text-align: center;
    padding: 0 18px 20px;
}

.large-avatar {
    width: 72px;
    height: 72px;
    margin-top: -36px;
    background: var(--white);
    border: 3px solid var(--white);
    box-shadow: var(--shadow-md);
}

.community-profile-body h2 {
    font-size: 1.1rem;
    color: var(--text-primary);
}

.community-profile-body p {
    color: var(--text-secondary);
    font-size: 0.92rem;
    line-height: 1.45;
}

.community-profile-stats {
    width: 100%;
    display: grid;
    grid-template-columns: repeat(2, minmax(0, 1fr));
    gap: 8px;
    padding: 10px 0;
    border-top: 1px solid var(--border-color);
    border-bottom: 1px solid var(--border-color);
}

.community-profile-stats span {
    display: grid;
    gap: 2px;
    color: var(--text-secondary);
    font-size: 0.78rem;
    font-weight: 800;
}

.community-profile-stats strong {
    color: var(--primary-dark);
    font-size: 1rem;
}

.community-mini-card {
    padding: 16px;
}

.community-mini-card h3 {
    margin-bottom: 12px;
    font-size: 1rem;
    color: var(--text-primary);
}

.community-mini-card > a,
.community-mini-card .group-link-pill {
    display: flex;
    justify-content: space-between;
    align-items: center;
    width: 100%;
    margin-bottom: 8px;
    padding: 9px 10px;
    border-radius: var(--radius-sm);
    color: var(--text-secondary);
    font-weight: 800;
}

.community-mini-card > a:hover,
.community-mini-card .group-link-pill:hover {
    background: var(--primary-light);
    color: var(--primary-dark);
}

.linkedin-composer {
    display: grid;
    grid-template-columns: auto minmax(0, 1fr) auto;
    align-items: center;
    gap: 12px;
    margin-bottom: 12px;
    padding: 14px;
}

.composer-quick-actions {
    grid-column: 1 / -1;
    display: grid;
    grid-template-columns: repeat(4, minmax(0, 1fr));
    gap: 8px;
    padding-top: 12px;
    border-top: 1px solid var(--border-color);
}

.composer-quick-actions button {
    min-height: 36px;
    border: 0;
    border-radius: var(--radius-sm);
    background: transparent;
    color: var(--text-secondary);
    font: inherit;
    font-size: 0.9rem;
    font-weight: 800;
    cursor: pointer;
}

.composer-quick-actions button:hover {
    background: var(--primary-light);
    color: var(--primary-dark);
}

.composer-input-button {
    min-height: 44px;
    width: 100%;
    padding: 10px 16px;
    border: 1px solid var(--border-color);
    border-radius: 999px;
    background: #f7fbfa;
    color: var(--text-secondary);
    font: inherit;
    font-weight: 700;
    text-align: left;
    cursor: pointer;
}

.composer-input-button:hover {
    border-color: rgba(15, 93, 85, 0.28);
    background: var(--primary-light);
    color: var(--primary-dark);
}

.feed-filter-bar {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 12px;
    margin-bottom: 12px;
    padding: 12px 16px;
}

.feed-filter-bar span {
    color: var(--text-primary);
    font-weight: 900;
}

.feed-filter-bar small {
    color: var(--text-secondary);
    font-weight: 700;
}

.linkedin-community-layout .feed-list {
    gap: 12px;
}

.linkedin-community-layout .post-card {
    position: relative;
    padding: 0;
    overflow: visible;
}

.linkedin-community-layout .post-author-row {
    align-items: flex-start;
    padding: 18px 62px 0 18px;
}

.linkedin-community-layout .post-card h3,
.linkedin-community-layout .post-card > p,
.linkedin-community-layout .post-tag-row {
    margin-left: 18px;
    margin-right: 18px;
}

.linkedin-community-layout .post-card h3 {
    font-size: 1.22rem;
    margin-top: 12px;
}

.linkedin-community-layout .post-card > p {
    color: var(--text-secondary);
    line-height: 1.62;
}

.post-engagement-row {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 10px;
    margin: 16px 18px 0;
    padding: 10px 0;
    border-top: 1px solid rgba(220, 232, 227, 0.75);
    color: var(--text-light);
    font-size: 0.86rem;
    font-weight: 800;
}

.linkedin-community-layout .post-actions {
    margin-top: 0;
    padding: 10px 14px;
    border-top: 1px solid var(--border-color);
    justify-content: space-between;
}

.linkedin-community-layout .post-actions button,
.linkedin-community-layout .post-actions a {
    flex: 1 1 auto;
    justify-content: center;
    text-align: center;
    background: transparent;
    border-color: transparent;
}

.linkedin-community-layout .post-actions button:hover,
.linkedin-community-layout .post-actions a:hover {
    background: var(--primary-light);
    color: var(--primary-dark);
}

.community-news-card p {
    color: var(--text-secondary);
    margin-bottom: 8px;
}

.community-news-card strong {
    color: var(--primary-dark);
}

.linkedin-community-layout .post-comments,
.linkedin-community-layout .share-row {
    margin-left: 18px;
    margin-right: 18px;
}

.linkedin-community-layout .share-row {
    margin-bottom: 18px;
}

.linkedin-community-layout .person-row {
    border-bottom: 0;
    padding: 10px 0;
}

.linkedin-community-layout .person-actions {
    padding-left: 0;
    flex-wrap: wrap;
}

.linkedin-community-layout .person-actions button {
    flex: 1 1 auto;
    font-size: 0.74rem;
    padding: 6px 8px;
}

.community-page-body,
.community-main,
.linkedin-community-layout,
.linkedin-community-layout .container,
.community-feed-column,
.community-left-rail,
.community-right-rail,
.linkedin-community-layout .feed-list {
    height: auto !important;
    max-height: none !important;
    overflow: visible !important;
}

.community-left-rail,
.community-right-rail {
    position: relative !important;
    top: auto !important;
}

.legal-section {
    padding: 56px 0 82px;
    background: linear-gradient(180deg, var(--background-light), #ffffff 48%, var(--mint-light));
}

.legal-document {
    max-width: 920px;
    margin: 0 auto;
    background: rgba(255, 255, 255, 0.92);
    border: 1px solid rgba(15, 93, 85, 0.12);
    border-radius: var(--radius-lg);
    box-shadow: var(--shadow-soft);
    padding: clamp(26px, 5vw, 58px);
}

.legal-document h2 {
    margin-top: 34px;
    margin-bottom: 12px;
    color: var(--primary-dark);
    font-size: clamp(1.35rem, 2vw, 1.75rem);
}

.legal-document h2:first-of-type {
    margin-top: 22px;
}

.legal-document h3 {
    margin-top: 22px;
    margin-bottom: 8px;
    color: var(--text-primary);
    font-size: 1.1rem;
}

.legal-document p,
.legal-document li {
    color: var(--text-secondary);
    line-height: 1.78;
}

.legal-document ul {
    margin: 10px 0 18px;
    padding-left: 24px;
}

.legal-document a {
    color: var(--primary-dark);
    font-weight: 800;
    text-decoration: underline;
    text-decoration-thickness: 1px;
    text-underline-offset: 3px;
}

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

    .well-summary-panel {
        grid-template-columns: 1fr;
    }

    .hero-actions,
    .post-author-row,
    .composer-card,
    .section-toolbar {
        align-items: stretch;
        flex-direction: column;
    }

    .post-type-tag {
        width: fit-content;
    }

    .hero-actions .btn,
    .section-toolbar .toolbar-note {
        width: 100%;
    }
}

@media (max-width: 880px) {
    .next-story-section .container,
    .next-roadmap-grid {
        grid-template-columns: 1fr;
    }
}

/* ===== Cross-device responsive refinements ===== */
@media (max-width: 1180px) {
    .container {
        padding-left: clamp(18px, 3vw, 32px);
        padding-right: clamp(18px, 3vw, 32px);
    }

    .main-header .container {
        flex-wrap: wrap;
    }

    .main-nav {
        order: 3;
        flex: 1 1 100%;
        justify-content: center;
    }

    .home-intro-section .container,
    .home-ecosystem-section .container,
    .next-story-section .container,
    .journey-grid,
    .community-layers-grid,
    .community-layers-flow,
    .personal-layout,
    .profile-layout,
    .write-post-page .container,
    .well-layout .container,
    .community-layout .container {
        grid-template-columns: 1fr;
    }

    .community-sidebar,
    .well-sidebar,
    .personal-sidebar,
    .profile-sidebar,
    .topic-panel,
    .preview-panel {
        position: static;
        width: 100%;
    }

    .organization-filter-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .ecosystem-map {
        width: min(100%, 680px);
        margin-inline: auto;
    }
}

@media (max-width: 900px) {
    .hero,
    .impact-home-hero,
    .page-header,
    .wishing-hero {
        padding-top: 58px;
        padding-bottom: 58px;
    }

    .hero .container,
    .wishing-hero .container,
    .profile-hero,
    .wish-detail-hero {
        grid-template-columns: 1fr;
        flex-direction: column;
        text-align: center;
    }

    .impact-home-hero .container {
        min-height: auto;
    }

    .hero-content,
    .impact-home-hero .hero-content,
    .hero h1,
    .impact-home-hero h1 {
        max-width: 100%;
    }

    .hero-cta,
    .hero-actions,
    .profile-actions,
    .post-actions,
    .saved-card-actions {
        justify-content: center;
        flex-wrap: wrap;
    }

    .home-intro-section,
    .journey-section,
    .home-ecosystem-section,
    .home-audience-section,
    .next-story-section,
    .next-roadmap-section,
    .legal-section {
        padding-top: 54px;
        padding-bottom: 54px;
    }

    .belonging-strip p {
        text-align: left;
    }

    .values-grid,
    .current-actions-grid,
    .daily-grid,
    .playbook-grid,
    .capability-grid,
    .organization-grid,
    .opportunities-grid,
    .volunteer-grid,
    .next-roadmap-grid {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .admin-grid,
    .admin-stats {
        grid-template-columns: 1fr;
    }

    .ecosystem-map {
        min-height: auto;
        display: block;
        padding: 24px;
    }

    .ecosystem-map::before {
        display: none;
    }

    .ecosystem-core {
        margin: 0 auto 20px;
        width: 160px;
        height: 160px;
    }

    .ecosystem-points {
        position: static;
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        gap: 10px;
    }

    .ecosystem-points span {
        position: static;
        transform: none !important;
        width: 100%;
        min-height: 58px;
    }

    .organization-filter-grid {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 680px) {
    .main-header {
        position: sticky;
    }

    .main-header .container {
        padding: 12px 14px;
        gap: 10px;
    }

    .logo-icon {
        width: 36px;
        height: 36px;
    }

    .logo-text {
        font-size: 1.25rem;
    }

    .auth-buttons {
        width: 100%;
        justify-content: stretch;
        gap: 8px;
    }

    .auth-buttons .btn {
        flex: 1 1 0;
        min-width: 0;
    }

    /* On phones the user-menu collapses to compact icon buttons aligned to the
       end of the header, rather than full-width text buttons. */
    .user-menu {
        width: auto;
        justify-content: flex-end;
        gap: 8px;
    }

    .user-menu .header-icon-btn,
    .user-menu a.header-settings-btn,
    .user-menu a.glowe-admin-link {
        flex: 0 0 auto;
        width: 40px;
        height: 40px;
        min-width: 40px;
        padding: 0;
        border-radius: 50%;
    }

    .header-settings-label,
    .glowe-admin-label {
        display: none;
    }

    .header-settings-icon,
    .glowe-admin-icon {
        display: inline-flex;
    }

    .user-greeting {
        display: none;
    }

    .main-nav {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
        border-radius: var(--radius-md);
        width: 100%;
    }

    .nav-link {
        padding: 9px 8px;
        font-size: 0.82rem;
        white-space: normal;
        text-align: center;
    }

    .hero h1,
    .page-header h1,
    .wishing-hero h1 {
        font-size: clamp(2rem, 11vw, 2.7rem);
        line-height: 1.06;
    }

    .hero p,
    .page-header p,
    .wishing-hero p {
        font-size: 1.02rem;
    }

    .hero-cta,
    .hero-actions,
    .composer-actions,
    .section-toolbar,
    .filter-row,
    .post-author-row {
        flex-direction: column;
        align-items: stretch;
    }

    .hero-cta .btn,
    .hero-actions .btn,
    .composer-actions button,
    .post-actions button,
    .post-actions a,
    .saved-card-actions .btn,
    .saved-card-actions a,
    .filter-row select,
    .filter-row input {
        width: 100%;
    }

    .values-grid,
    .current-actions-grid,
    .daily-grid,
    .playbook-grid,
    .capability-grid,
    .organization-grid,
    .opportunities-grid,
    .volunteer-grid,
    .next-roadmap-grid,
    .admin-grid,
    .admin-stats,
    .ecosystem-points,
    .footer-grid,
    .stats-grid,
    .profile-stats,
    .well-summary-panel,
    .form-grid-2,
    .choice-grid,
    .profile-type-grid {
        grid-template-columns: 1fr;
    }

    .modal {
        padding: 10px;
    }

    .modal-content {
        width: min(100%, 680px);
        max-height: calc(100dvh - 20px);
        overflow-y: auto;
        border-radius: var(--radius-md);
    }

    .legal-document {
        padding: 24px 18px;
    }

    .ecosystem-photo,
    .ecosystem-photo img {
        min-height: 360px;
    }

    .ecosystem-photo figcaption {
        position: static;
        border-radius: 0;
        background: var(--primary-dark);
    }
}

@media (max-width: 420px) {
    .container {
        padding-left: 14px;
        padding-right: 14px;
    }

    .main-nav {
        grid-template-columns: 1fr;
    }

    .btn,
    .btn-large {
        width: 100%;
        padding: 11px 14px;
        font-size: 0.95rem;
    }

    .glowe-system-figure img {
        width: min(320px, 92vw);
    }

    .ecosystem-core {
        width: 138px;
        height: 138px;
    }

    .ecosystem-core img {
        width: 78px;
    }

    .ecosystem-core strong {
        font-size: 1.15rem;
    }

    .ecosystem-photo,
    .ecosystem-photo img {
        min-height: 300px;
    }
}

@media (min-width: 1181px) {
    .linkedin-community-layout .container {
        grid-template-columns: minmax(210px, 250px) minmax(0, 1fr) minmax(260px, 320px);
    }
}

@media (min-width: 761px) and (max-width: 1180px) {
    .linkedin-community-layout .container {
        grid-template-columns: minmax(190px, 230px) minmax(0, 1fr);
    }

    .community-right-rail {
        grid-column: 1 / -1;
        position: static;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }
}

@media (max-width: 760px) {
    .linkedin-community-layout .container {
        grid-template-columns: 1fr;
    }

    .community-left-rail,
    .community-right-rail {
        position: static;
    }

    .community-feed-header {
        display: grid;
    }

    .linkedin-composer {
        grid-template-columns: auto minmax(0, 1fr);
    }

    .linkedin-composer .btn {
        grid-column: 1 / -1;
        width: 100%;
    }

    .composer-quick-actions {
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .feed-filter-bar {
        align-items: flex-start;
        flex-direction: column;
    }

    .post-engagement-row {
        align-items: flex-start;
        flex-direction: column;
        gap: 4px;
    }

    .linkedin-community-layout .post-actions {
        display: grid;
        grid-template-columns: repeat(2, minmax(0, 1fr));
    }

    .post-author-row {
        align-items: flex-start;
    }

    .post-card-tools {
        align-items: flex-end;
        flex-direction: column;
    }

    .linkedin-community-layout .post-author-row {
        padding-right: 58px;
    }

    .profile-hero {
        grid-template-columns: 1fr;
        gap: 10px;
        padding: 0 20px 20px;
    }

    .profile-avatar {
        margin-top: -52px;
    }

    .profile-actions {
        grid-column: 1;
        width: 100%;
    }

    .profile-actions .btn {
        flex: 1 1 140px;
    }

    .profile-more-menu {
        flex: 0 0 auto;
    }

    .profile-summary h1 {
        font-size: clamp(1.9rem, 10vw, 2.6rem);
    }

    .profile-stats {
        grid-template-columns: 1fr;
        padding: 0 20px 20px;
    }
}

/* ===== Mobile Bottom Navigation Bar ===== */
.mobile-bottom-nav {
    display: none;
}

@media (max-width: 680px) {
    body {
        padding-bottom: calc(70px + env(safe-area-inset-bottom, 0px)) !important;
    }

    .main-nav {
        display: none !important;
    }

    .mobile-bottom-nav {
        display: flex;
        position: fixed;
        bottom: 0;
        left: 0;
        width: 100%;
        background-color: var(--white);
        box-shadow: 0 -2px 10px rgba(0, 0, 0, 0.08);
        z-index: 1000;
        padding-bottom: env(safe-area-inset-bottom, 0px);
        border-top: 1px solid var(--border-color);
    }

    .bottom-nav-link {
        flex: 1;
        display: flex;
        flex-direction: column;
        align-items: center;
        justify-content: center;
        padding: 10px 4px;
        color: var(--text-secondary);
        text-decoration: none;
        transition: color 0.2s ease, transform 0.2s ease;
    }

    .bottom-nav-link:hover, .bottom-nav-link:active {
        background-color: var(--primary-light);
    }

    .bottom-nav-link.active {
        color: var(--primary-dark);
    }

    .nav-icon {
        width: 24px;
        height: 24px;
        margin-bottom: 4px;
    }

    .nav-icon svg {
        width: 100%;
        height: 100%;
        transition: transform 0.2s ease;
    }

    .bottom-nav-link.active .nav-icon svg {
        transform: scale(1.1);
    }

    .nav-label {
        font-size: 0.7rem;
        font-weight: 800;
        text-align: center;
    }
}

/* ── GloWe onboarding (FR-GLOWE-002) ───────────────────────────────────── */
.onboarding-type-choice {
    display: grid;
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
}

@media (max-width: 600px) {
    .onboarding-type-choice {
        grid-template-columns: 1fr;
    }
}

.onboarding-type-card {
    display: flex;
    flex-direction: column;
    gap: 6px;
    padding: 16px;
    border: 2px solid var(--border-color);
    border-radius: var(--radius-md);
    cursor: pointer;
    transition: var(--transition);
    background: var(--white);
}

.onboarding-type-card:hover {
    border-color: var(--primary-light);
}

.onboarding-type-card:has(input:checked) {
    border-color: var(--primary-color);
    background: var(--mint-light);
    box-shadow: var(--shadow-sm);
}

.onboarding-type-card input {
    margin: 0 0 4px;
}

.onboarding-type-title {
    font-weight: 800;
    color: var(--text-primary);
}

.onboarding-type-desc {
    font-size: 0.85rem;
    color: var(--text-secondary);
}

#onboarding-org-fields {
    margin-top: 6px;
    padding-top: 16px;
    border-top: 1px solid var(--border-color);
}

.onboarding-review-note {
    background: var(--mint-light);
    border-radius: var(--radius-md);
    padding: 12px 14px;
    font-size: 0.9rem;
    color: var(--text-secondary);
    margin-bottom: 16px;
}

/* ===== FR-GLOWE-004: Hebrew interface + RTL ===== */
/* Hebrew typography. dir="rtl" on <html> handles most layout mirroring
   (flex order, default alignment, list markers) automatically; the rules
   below cover spots with explicit physical alignment. */
html[dir="rtl"] body,
body.lang-he {
    font-family: 'Assistant', 'Heebo', 'Rubik', 'Noto Sans Hebrew', 'Inter', system-ui, sans-serif;
    line-height: 1.7;
    letter-spacing: normal;
}

html[dir="rtl"] {
    text-align: right;
}

/* Mirror the in-scope blocks that hard-code text-align:left. */
html[dir="rtl"] .page-header h1,
html[dir="rtl"] .page-header p,
html[dir="rtl"] .wizard-heading h2,
html[dir="rtl"] .path-grid button,
html[dir="rtl"] .modal-content,
html[dir="rtl"] .form-group label,
html[dir="rtl"] .footer-section,
html[dir="rtl"] .settings-grid {
    text-align: right;
}

/* Inputs/selects keep their own direction so placeholders sit on the right. */
html[dir="rtl"] input,
html[dir="rtl"] select,
html[dir="rtl"] textarea {
    text-align: right;
}

/* Keep brand/identifier values left-to-right inside RTL text. */
html[dir="rtl"] .logo-text,
html[dir="rtl"] .lang-toggle {
    direction: ltr;
}

/* Header language switch — visible only for anonymous visitors (removed on sign-in). */
.lang-toggle {
    flex: 0 0 auto;
    min-width: 42px;
    height: 36px;
    padding: 0 12px;
    border-radius: 999px;
    border: 1px solid rgba(15, 93, 85, 0.25);
    background: var(--white);
    color: var(--primary-dark);
    font-weight: 700;
    font-size: 0.9rem;
    cursor: pointer;
    transition: var(--transition);
}

.lang-toggle:hover {
    background: rgba(15, 93, 85, 0.08);
    box-shadow: 0 6px 16px rgba(15, 93, 85, 0.08);
}

/* ===== Member home (FR-GLOWE-016) ===== */
/* When a signed-in member is on the home page, the marketing sections are
   hidden and the personalized member-home section takes over the same container. */
body.glowe-member-home main > section:not(#member-home) {
    display: none;
}

.member-home {
    background: var(--background);
    padding: 48px 0 72px;
}

.member-home-inner {
    display: flex;
    flex-direction: column;
    gap: 40px;
}

.member-hero {
    display: flex;
    flex-wrap: wrap;
    align-items: flex-end;
    justify-content: space-between;
    gap: 24px;
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-lg);
    padding: 36px;
    box-shadow: var(--shadow-md);
}

.member-hero-copy {
    max-width: 620px;
}

.member-hero-copy h1 {
    margin: 8px 0 12px;
    font-size: clamp(1.6rem, 3vw, 2.4rem);
    color: var(--primary-dark);
}

.member-hero-copy p {
    color: var(--text-secondary);
}

.member-hero-actions {
    display: flex;
    flex-wrap: wrap;
    gap: 12px;
}

.member-section {
    display: flex;
    flex-direction: column;
    gap: 18px;
}

.member-feed-grid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
    gap: 20px;
}

.member-feed-card {
    display: flex;
    flex-direction: column;
    gap: 8px;
    background: var(--white);
    border: 1px solid var(--border-color);
    border-radius: var(--radius-md);
    padding: 20px;
    text-decoration: none;
    color: inherit;
    box-shadow: var(--shadow-sm);
    transition: var(--transition);
}

.member-feed-card:hover {
    box-shadow: var(--shadow-md);
    transform: translateY(-2px);
}

.member-feed-type {
    font-size: 0.78rem;
    font-weight: 700;
    letter-spacing: 0.02em;
    text-transform: uppercase;
    color: var(--primary-color);
}

.member-feed-card h3 {
    font-size: 1.1rem;
    color: var(--primary-dark);
}

.member-feed-card p {
    color: var(--text-secondary);
    font-size: 0.95rem;
}

.member-feed-author {
    margin-top: auto;
    font-size: 0.85rem;
    color: var(--text-light);
}

@media (max-width: 640px) {
    .member-hero {
        padding: 24px;
    }
    .member-hero-actions .btn {
        flex: 1 1 100%;
    }
}

/* FR-TRANSLATE-005 — "Show original" toggle injected on translated UGC cards. */
.tr-toggle {
    display: inline-block;
    margin-top: 8px;
    padding: 2px 8px;
    border: 1px solid var(--primary-light);
    border-radius: 999px;
    background: transparent;
    color: var(--primary-color);
    font-size: 0.78rem;
    font-weight: 600;
    cursor: pointer;
}

.tr-toggle:hover {
    background: var(--primary-light);
}

/* ── FR-GLOWE-016 — adaptive create system ─────────────────────────────── */
.bottom-nav-create {
    display: none;
}

@media (max-width: 680px) {
    .bottom-nav-create {
        display: flex;
        align-items: center;
        justify-content: center;
        align-self: center;
        width: 52px;
        height: 52px;
        min-width: 52px;
        margin: 0 6px;
        border: none;
        border-radius: 50%;
        background: var(--primary-color);
        color: var(--white);
        box-shadow: 0 4px 12px rgba(0, 0, 0, 0.18);
        cursor: pointer;
        transform: translateY(-10px);
    }

    .bottom-nav-create svg {
        width: 26px;
        height: 26px;
    }

    .header-create-btn {
        display: none;
    }
}

.create-menu-options {
    display: grid;
    gap: 12px;
    margin-top: 12px;
}

.create-menu-option {
    display: flex;
    flex-direction: column;
    gap: 4px;
    text-align: start;
    padding: 14px 16px;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: var(--white);
    cursor: pointer;
    transition: border-color 0.2s ease, background 0.2s ease;
}

.create-menu-option:hover {
    border-color: var(--primary-color);
    background: var(--primary-light);
}

.create-menu-option strong {
    font-size: 1rem;
}

.create-menu-option span {
    color: var(--text-secondary);
    font-size: 0.85rem;
}

/* Save/unsave toggle inside a card's "..." menu keeps the plain menu look. */
.post-menu-action {
    display: block;
    width: 100%;
    text-align: start;
    border: none;
    background: none;
    cursor: pointer;
}

.post-menu-action.is-saved,
.heart-button.is-saved,
.btn.is-saved {
    color: var(--primary-dark);
    font-weight: 700;
}

/* ── FR-GLOWE-016 AC6 — direct messages (KC shared chat backend) ───────── */
.chat-inbox-list {
    display: flex;
    flex-direction: column;
    gap: 10px;
}

.chat-inbox-row {
    display: flex;
    align-items: center;
    gap: 12px;
    padding: 12px 16px;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: var(--white);
    text-decoration: none;
    color: inherit;
    transition: border-color 0.2s ease, background 0.2s ease;
}

.chat-inbox-row:hover {
    border-color: var(--primary-color);
    background: var(--primary-light);
}

.chat-inbox-row.has-unread strong {
    color: var(--primary-dark);
}

.chat-inbox-main {
    flex: 1;
    display: flex;
    flex-direction: column;
    gap: 2px;
    min-width: 0;
}

.chat-inbox-main small {
    color: var(--text-secondary);
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.chat-inbox-side {
    display: flex;
    flex-direction: column;
    align-items: flex-end;
    gap: 4px;
    color: var(--text-secondary);
}

.chat-unread-badge {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 20px;
    height: 20px;
    padding: 0 6px;
    border-radius: 999px;
    background: var(--primary-color);
    color: var(--white);
    font-size: 0.72rem;
    font-weight: 800;
}

.user-menu .header-icon-btn {
    position: relative;
}

.user-menu .header-icon-btn .chat-unread-badge {
    position: absolute;
    top: -6px;
    inset-inline-end: -6px;
}

.chat-thread {
    display: flex;
    flex-direction: column;
    gap: 12px;
}

.chat-thread-header {
    display: flex;
    align-items: center;
    gap: 12px;
}

.chat-thread-messages {
    display: flex;
    flex-direction: column;
    gap: 8px;
    max-height: 55vh;
    overflow-y: auto;
    padding: 12px;
    border: 1px solid var(--border-color);
    border-radius: 12px;
    background: var(--white);
}

.chat-bubble {
    max-width: 80%;
    align-self: flex-start;
    padding: 10px 14px;
    border-radius: 14px;
    background: var(--primary-light);
}

.chat-bubble.mine {
    align-self: flex-end;
    background: var(--primary-color);
    color: var(--white);
}

.chat-bubble.system {
    align-self: center;
    background: transparent;
    border: 1px dashed var(--border-color);
    color: var(--text-secondary);
    font-size: 0.85rem;
}

.chat-bubble p {
    margin: 0;
    white-space: pre-wrap;
    word-break: break-word;
}

.chat-bubble small {
    display: block;
    margin-top: 4px;
    font-size: 0.7rem;
    opacity: 0.75;
}

.chat-send-form {
    display: flex;
    gap: 8px;
}

.chat-send-form input {
    flex: 1;
    padding: 12px 14px;
    border: 1px solid var(--border-color);
    border-radius: 999px;
}
