:root {
    --bg: #d5efe8;
    --text: #1a2730;
    --muted: #708089;
    --accent: #ff765d;
    --accent-deep: #ee6048;
    --stroke: rgba(160, 200, 190, 0.58);
    --card: rgba(255, 255, 255, 0.82);
    --shadow: 0 18px 38px rgba(24, 39, 48, 0.08);
}

* {
    box-sizing: border-box;
    margin: 0;
    padding: 0;
}

html,
body {
    width: 100%;
    min-height: 100%;
}

body {
    font-family: "Segoe UI", "Trebuchet MS", sans-serif;
    background:
        radial-gradient(circle at top, rgba(255, 255, 255, 0.38), transparent 36%),
        var(--bg);
    color: var(--text);
}

.page-help {
    min-height: 100dvh;
    overflow-x: hidden;
    overflow-y: auto;
}

.help-screen {
    position: relative;
    width: min(100%, 860px);
    min-height: 100dvh;
    margin: 0 auto;
    padding: clamp(0.6rem, 2vh, 1rem) clamp(1rem, 5vw, 2.4rem) 1.6rem;
    display: grid;
    gap: 0.78rem;
}

.help-glow {
    position: fixed;
    border-radius: 50%;
    filter: blur(28px);
    pointer-events: none;
    opacity: 0.2;
    z-index: 0;
}

.help-glow-a {
    width: 180px;
    height: 180px;
    top: 82px;
    right: -30px;
    background: rgba(255, 170, 92, 0.34);
}

.help-glow-b {
    width: 150px;
    height: 150px;
    bottom: 92px;
    left: -24px;
    background: rgba(61, 220, 151, 0.18);
}

.help-top,
.help-head,
.help-hero,
.help-card,
.help-credit,
.help-toast {
    position: relative;
    z-index: 1;
}

.help-top {
    display: grid;
    grid-template-columns: 1fr auto 1fr;
    align-items: center;
    gap: 0.75rem;
    position: fixed;
    top: 0;
    left: 50%;
    transform: translateX(-50%);
    width: min(100%, 920px);
    box-sizing: border-box;
    background: rgba(213, 239, 232, 0.92);
    backdrop-filter: blur(16px);
    padding: 1.65rem 0;
    border-bottom: 1px solid rgba(160, 200, 190, 0.24);
    box-shadow: 0 14px 30px rgba(24, 39, 48, 0.05);
}

.help-nav-group {
    display: flex;
    align-items: center;
    gap: 1rem;
}

.help-nav-group-start {
    justify-self: start;
}

.help-nav-group-end {
    justify-self: end;
}

.help-message-link,
.help-notifications-link,
.help-explore-link,
.help-profile-link {
    display: inline-flex;
}

.help-center {
    justify-self: center;
    display: grid;
    justify-items: center;
    gap: 0.16rem;
}

.help-title {
    font-size: clamp(1.2rem, 4.1vw, 1.9rem);
    font-weight: 800;
}

.help-icon {
    width: clamp(28px, 7vw, 42px);
    height: auto;
}

.help-icon.is-active {
    width: clamp(34px, 9vw, 50px);
}

.help-notifications-link .help-icon {
    filter: brightness(0) saturate(100%) invert(68%) sepia(64%) saturate(4642%) hue-rotate(321deg) brightness(103%) contrast(102%);
    margin-left: 0.35rem;
}

.help-explore {
    width: clamp(28px, 7.2vw, 42px);
    height: auto;
    filter: drop-shadow(0 6px 12px rgba(25, 25, 40, 0.14));
    margin-right: 0.35rem;
}

.help-head {
    display: grid;
    grid-template-columns: auto 1fr;
    align-items: center;
    gap: 0.7rem;
}

.help-back {
    width: 34px;
    height: 34px;
    border-radius: 50%;
    border: 1px solid rgba(160, 200, 190, 0.3);
    background: rgba(255, 255, 255, 0.86);
    color: var(--text);
    font-size: 0.94rem;
    cursor: pointer;
    display: grid;
    place-items: center;
}

.help-kicker,
.help-hero-kicker {
    font-size: 0.7rem;
    font-weight: 700;
    letter-spacing: 0.06em;
    text-transform: uppercase;
    color: rgba(26, 39, 48, 0.48);
}

.help-heading {
    font-size: clamp(1.1rem, 3.6vw, 1.6rem);
    font-weight: 800;
}

.help-hero {
    display: flex;
    align-items: end;
    justify-content: space-between;
    gap: 1.1rem;
    padding: 1.3rem 1.25rem;
    border-radius: 28px;
    background: linear-gradient(145deg, rgba(255, 255, 255, 0.9), rgba(255, 255, 255, 0.58));
    border: 1px solid rgba(150, 200, 190, 0.42);
    box-shadow: 0 22px 44px rgba(24, 39, 48, 0.08);
}

.help-hero-title {
    font-size: clamp(1.15rem, 3.8vw, 1.7rem);
    margin-top: 0.18rem;
}

.help-hero-copy {
    margin-top: 0.3rem;
    color: var(--muted);
    line-height: 1.42;
    max-width: 48ch;
}

.help-hero-link,
.help-submit {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.7rem 1rem;
    border-radius: 999px;
    border: 0;
    background: var(--accent);
    color: #1a1b23;
    font-weight: 700;
    text-decoration: none;
    cursor: pointer;
    transition: transform 180ms ease, box-shadow 180ms ease, opacity 180ms ease;
}

.help-card {
    display: grid;
    gap: 0.78rem;
    padding: 1rem;
    border-radius: 22px;
    background: var(--card);
    border: 1px solid var(--stroke);
    box-shadow: 0 8px 24px rgba(24, 39, 48, 0.07);
}

.help-topic,
.help-faq,
.help-field {
    transition: transform 180ms ease, box-shadow 180ms ease, border-color 180ms ease;
}

@media (hover: hover) and (pointer: fine) {
    .help-hero-link:hover,
    .help-submit:hover,
    .help-topic:hover,
    .help-faq:hover {
        transform: translateY(-1px);
    }

    .help-hero-link:hover,
    .help-submit:hover {
        box-shadow: 0 14px 22px rgba(240, 96, 72, 0.22);
    }
}

/* ── Touch optimizations ── */
.help-hero-link,
.help-submit,
.help-topic,
.help-faq,
.help-back { touch-action: manipulation; }

.help-section-head {
    display: grid;
    gap: 0.18rem;
}

.help-section-title {
    font-size: 0.88rem;
    font-weight: 800;
    color: rgba(26, 39, 48, 0.78);
}

.help-section-hint {
    color: var(--muted);
    font-size: 0.8rem;
}

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

.help-contact-grid {
    display: grid;
    grid-template-columns: repeat(3, minmax(0, 1fr));
    gap: 0.8rem;
}

.help-topic,
.help-faq,
.help-field {
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.74);
    border: 1px solid rgba(160, 200, 190, 0.34);
}

.help-topic {
    padding: 0.82rem 0.88rem;
}

.help-contact-item {
    display: grid;
    gap: 0.35rem;
    padding: 1rem;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.74);
    border: 1px solid rgba(160, 200, 190, 0.34);
}

.help-contact-item p {
    color: var(--muted);
    line-height: 1.42;
    font-size: 0.86rem;
}

.help-contact-item .help-email-link {
    width: fit-content;
}

.help-social-links {
    margin-top: 0.35rem;
}

.help-topic p {
    margin-top: 0.3rem;
    color: var(--muted);
    line-height: 1.42;
    font-size: 0.86rem;
}

.help-faqs {
    display: grid;
    gap: 0.7rem;
}

.help-faq {
    padding: 0.82rem 0.9rem;
}

.help-faq summary {
    cursor: pointer;
    font-weight: 700;
}

.help-faq p {
    margin-top: 0.55rem;
    color: var(--muted);
    line-height: 1.45;
    font-size: 0.88rem;
}

.help-form {
    display: grid;
    gap: 0.8rem;
}

.help-permission-panel {
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 0.9rem;
    align-items: center;
    padding: 1rem;
    border-radius: 20px;
    background: rgba(255, 255, 255, 0.74);
    border: 1px solid rgba(160, 200, 190, 0.34);
}

.help-permission-panel p {
    margin-top: 0.25rem;
    color: var(--muted);
    line-height: 1.42;
    font-size: 0.86rem;
}

.help-browser-btn {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    padding: 0.7rem 1rem;
    border-radius: 999px;
    border: 1px solid rgba(255, 111, 90, 0.28);
    background: rgba(255, 255, 255, 0.92);
    color: var(--accent-deep);
    font: inherit;
    font-weight: 800;
    cursor: pointer;
}

.help-browser-btn.is-disabled {
    background: rgba(26, 39, 48, 0.06);
    border-color: transparent;
    color: #3d545d;
    cursor: default;
}

.help-volunteer {
    border-radius: 18px;
    background: rgba(255, 255, 255, 0.74);
    border: 1px solid rgba(160, 200, 190, 0.34);
    padding: 0.95rem 1rem;
}

.help-volunteer-copy {
    color: var(--muted);
    line-height: 1.5;
    font-size: 0.92rem;
    max-width: 52ch;
}

.help-email-link {
    color: var(--accent-deep);
    font-weight: 800;
    text-decoration: none;
}

.help-email-link:hover,
.help-email-link:focus {
    text-decoration: underline;
}

.help-field {
    display: grid;
    gap: 0.45rem;
    padding: 0.88rem 0.95rem;
}

.help-field span {
    font-size: 0.86rem;
    font-weight: 700;
}

.help-field input,
.help-field select,
.help-field textarea {
    border: 0;
    outline: none;
    background: transparent;
    color: var(--text);
    font: inherit;
}

.help-field textarea {
    resize: vertical;
    min-height: 116px;
}

.help-field-upload {
    gap: 0.65rem;
}

.help-upload-row {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.65rem;
}

.help-upload-button,
.help-upload-clear {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-height: 44px;
    padding: 0.72rem 1rem;
    border-radius: 999px;
    border: 1px solid rgba(160, 200, 190, 0.34);
    background: rgba(255, 255, 255, 0.88);
    color: var(--text);
    font: inherit;
    font-weight: 800;
    cursor: pointer;
}

.help-upload-button {
    background: rgba(255, 118, 93, 0.14);
    border-color: rgba(255, 118, 93, 0.28);
    color: var(--accent-deep);
}

.help-upload-clear {
    background: rgba(26, 39, 48, 0.06);
    color: #51626b;
}

.help-field-upload input[type="file"] {
    position: absolute;
    width: 1px;
    height: 1px;
    opacity: 0;
    pointer-events: none;
}

.help-upload-note {
    color: var(--muted);
    font-size: 0.82rem;
    line-height: 1.45;
}

.help-upload-preview {
    display: block;
    overflow: hidden;
    border-radius: 18px;
    border: 1px solid rgba(160, 200, 190, 0.28);
    background: rgba(255, 255, 255, 0.66);
}

.help-upload-preview img {
    width: 100%;
    max-height: 280px;
    object-fit: cover;
    display: block;
}

.help-form-actions {
    display: flex;
    flex-wrap: wrap;
    align-items: center;
    gap: 0.8rem;
}

.help-form-note {
    color: var(--muted);
    font-size: 0.84rem;
}

.help-toast {
    position: fixed;
    left: 50%;
    bottom: 1rem;
    transform: translate(-50%, 12px);
    background: rgba(26, 39, 48, 0.78);
    color: #fff;
    padding: 0.72rem 1rem;
    border-radius: 999px;
    font-size: 0.84rem;
    font-weight: 700;
    opacity: 0;
    pointer-events: none;
    transition: opacity 180ms ease, transform 180ms ease;
    z-index: 1000;
}

.help-toast.is-visible {
    opacity: 1;
    transform: translate(-50%, 0);
}

.help-credit {
    text-align: center;
    color: rgba(255, 113, 94, 0.85);
    font-size: clamp(0.72rem, 2vw, 0.9rem);
}

@media (max-width: 720px) {
    .help-screen {
        gap: 0.7rem;
        padding: 0.4rem 0.95rem 1rem;
    }

    .help-head {
        gap: 0.55rem;
    }

    .help-card {
        padding: 0.9rem;
        border-radius: 20px;
    }

    .help-topic,
    .help-contact-item,
    .help-faq,
    .help-permission-panel,
    .help-volunteer {
        border-radius: 16px;
    }

    .help-grid {
        grid-template-columns: 1fr;
    }

    .help-contact-grid {
        grid-template-columns: 1fr;
    }

    .help-permission-panel {
        grid-template-columns: 1fr;
    }
}

@media (max-width: 420px) {
    .help-screen {
        gap: 0.65rem;
        padding: 0.35rem 0.82rem 0.95rem;
    }

    .help-head {
        gap: 0.48rem;
    }

    .help-heading {
        font-size: 1rem;
    }

    .help-section-hint,
    .help-topic p,
    .help-faq p {
        font-size: 0.8rem;
        line-height: 1.34;
    }

    .help-card {
        padding: 0.85rem;
        border-radius: 18px;
    }

    .help-topic,
    .help-contact-item,
    .help-faq,
    .help-permission-panel,
    .help-volunteer,
    .help-field {
        border-radius: 14px;
    }

    .help-browser-btn,
    .help-submit {
        min-height: 44px;
    }
}

body.theme-super-admin .help-screen,
body.theme-super-admin .help-top,
body.theme-super-admin .help-head,
body.theme-super-admin .help-hero,
body.theme-super-admin .help-card,
body.theme-super-admin .help-topic,
body.theme-super-admin .help-contact-item,
body.theme-super-admin .help-faq,
body.theme-super-admin .help-permission-panel,
body.theme-super-admin .help-volunteer,
body.theme-super-admin .help-field {
    background: linear-gradient(160deg, rgba(12, 18, 25, 0.96), rgba(18, 26, 34, 0.9)) !important;
    border-color: rgba(160, 200, 190, 0.16) !important;
    color: var(--text) !important;
    box-shadow: 0 18px 40px rgba(2, 8, 12, 0.24) !important;
}

body.theme-super-admin .help-hero-link,
body.theme-super-admin .help-submit,
body.theme-super-admin .help-back,
body.theme-super-admin .help-browser-btn {
    background: rgba(18, 26, 34, 0.92) !important;
    border-color: rgba(160, 200, 190, 0.16) !important;
    color: var(--text) !important;
}

body.theme-super-admin .help-hero-link,
body.theme-super-admin .help-submit {
    background: rgba(255, 120, 94, 0.18) !important;
    color: #ffcabd !important;
}

body.theme-super-admin .help-browser-btn.is-disabled {
    background: rgba(160, 200, 190, 0.08) !important;
    color: var(--muted) !important;
}

body.theme-super-admin .help-topic p,
body.theme-super-admin .help-contact-item p,
body.theme-super-admin .help-faq p,
body.theme-super-admin .help-permission-panel p,
body.theme-super-admin .help-section-hint,
body.theme-super-admin .help-form-note,
body.theme-super-admin .help-upload-note,
body.theme-super-admin .help-volunteer-copy,
body.theme-super-admin .help-kicker,
body.theme-super-admin .help-hero-kicker {
    color: var(--text) !important;
}

body.theme-super-admin .help-faq summary,
body.theme-super-admin .help-topic strong,
body.theme-super-admin .help-contact-item strong,
body.theme-super-admin .help-permission-panel strong,
body.theme-super-admin .help-section-title,
body.theme-super-admin .help-heading,
body.theme-super-admin .help-hero-title {
    color: var(--text) !important;
}

body.theme-super-admin .help-upload-button,
body.theme-super-admin .help-upload-clear {
    background: rgba(18, 26, 34, 0.92) !important;
    border-color: rgba(160, 200, 190, 0.16) !important;
    color: var(--text) !important;
}

body.theme-super-admin .help-upload-button {
    background: rgba(255, 120, 94, 0.18) !important;
    color: #ffcabd !important;
}

body.theme-super-admin .help-upload-preview {
    background: linear-gradient(160deg, rgba(12, 18, 25, 0.96), rgba(18, 26, 34, 0.9)) !important;
    border-color: rgba(160, 200, 190, 0.16) !important;
}
