/* ProNovel — community, membership & messaging UI. */

.pn-muted { color: var(--pn-muted); }
.pn-small { font-size: 13px; }
.pn-form-error { margin: 10px 0; padding: 10px 14px; border-radius: 8px; background: rgba(239, 68, 68, .12); color: #fca5a5; font-size: 14px; }
.pn-form-ok { display: flex; align-items: center; gap: 8px; margin: 0 0 14px; padding: 10px 14px; border-radius: 8px; background: rgba(16, 185, 129, .12); color: #6ee7b7; font-size: 14px; }
.pn-form-ok .pn-icon { width: 16px; height: 16px; }
.pn-link-btn { display: inline-flex; align-items: center; gap: 5px; padding: 0; border: 0; background: none; color: var(--pn-muted); font: inherit; font-size: 13px; cursor: pointer; }
.pn-link-btn:hover { color: var(--pn-text); }
.pn-link-btn .pn-icon { width: 14px; height: 14px; }
.pn-btn-premium { background: linear-gradient(135deg, #f5c542, var(--pn-premium)); color: #1c1408; border: 0; }
.pn-btn-premium:hover { filter: brightness(1.08); color: #1c1408; }

/* ---------- Series page: details below the description ---------- */
.pn-novel-details { display: grid; gap: 12px; padding: 16px; }
.pn-novel-details .pn-stats { margin-bottom: 0; }
/* Desktop: details sit in the left sidebar. Mobile: right under the description. */
.pn-details-mobile { display: none; }
@media (max-width: 767px) {
	.pn-details-desktop { display: none !important; }
	.pn-details-mobile { display: grid; order: 0; }
}
.pn-novel-genres { align-items: center; }
.pn-novel-genres .pn-info-key { display: inline-flex; align-items: center; gap: 6px; margin-right: 4px; color: var(--pn-muted); font-size: 13px; }
.pn-novel-genres .pn-info-key .pn-icon { width: 14px; height: 14px; }
.pn-chapters .pn-ch-list { max-height: calc(var(--pn-ch-visible, 6) * 45px); overscroll-behavior: contain; }

/* ---------- Latest updates: NEW / UNLOCKED ---------- */
.pn-update-cover { position: relative; }
.pn-cover-strip { position: absolute; left: 0; right: 0; bottom: 0; display: flex; align-items: center; justify-content: center; gap: 4px; padding: 4px 2px; font-size: 11px; font-weight: 800; letter-spacing: .02em; color: #fff; }
.pn-cover-strip .pn-icon { width: 12px; height: 12px; }
.pn-cover-strip.is-unlocked { background: var(--pn-badge-unlocked, #10b981); color: #052e1f; }
.pn-cover-strip.is-new { background: var(--pn-badge-new, #0ea5e9); }
.pn-ch-badge { display: inline-flex; align-items: center; gap: 3px; flex: none; padding: 2px 7px; border-radius: 6px; font-size: 10.5px; font-weight: 800; text-transform: uppercase; letter-spacing: .03em; }
.pn-ch-badge .pn-icon { width: 11px; height: 11px; }
.pn-ch-badge.is-new { color: var(--pn-badge-new, #0ea5e9); background: color-mix(in srgb, var(--pn-badge-new, #0ea5e9) 16%, transparent); }
.pn-ch-badge.is-unlocked { color: var(--pn-badge-unlocked, #10b981); background: color-mix(in srgb, var(--pn-badge-unlocked, #10b981) 16%, transparent); }
.pn-update-chapters li { display: flex; align-items: center; gap: 6px; }
.pn-update-chapters li .pn-update-time { margin-left: auto; }

/* ---------- Reader: reactions ---------- */
.pn-reader-react { max-width: var(--pn-reader-w, 860px); margin: 0 auto 20px; padding: 0 16px; }
.pn-react { padding: 22px 16px; text-align: center; }
.pn-react h2 { margin: 0; font-size: 18px; }
.pn-react-total { margin: 4px 0 16px; color: var(--pn-muted); font-size: 14px; }
.pn-react-row { display: flex; justify-content: center; flex-wrap: wrap; gap: 6px; }
.pn-react-btn { display: flex; flex-direction: column; align-items: center; gap: 2px; min-width: 76px; padding: 10px 6px; border: 1px solid transparent; border-radius: 12px; background: none; color: var(--pn-text); cursor: pointer; transition: background .15s, border-color .15s, transform .15s; }
.pn-react-btn:hover { background: rgba(255, 255, 255, .05); }
.pn-react-btn.is-mine { border-color: color-mix(in srgb, var(--pn-accent) 60%, transparent); background: color-mix(in srgb, var(--pn-accent) 14%, transparent); }
.pn-react-emoji { font-size: 38px; line-height: 1.1; transition: transform .2s; }
.pn-react-btn:hover .pn-react-emoji { transform: translateY(-3px) scale(1.08); }
.pn-react-btn.is-pop .pn-react-emoji { animation: pn-pop .4s ease; }
.pn-react-btn strong { font-size: 16px; }
.pn-react-btn small { color: var(--pn-muted); font-size: 12px; }
.pn-react.is-busy { pointer-events: none; }
@keyframes pn-pop { 40% { transform: scale(1.35); } }

/* ---------- Comments ---------- */
.pn-cform { margin: 6px 0 18px; }
.pn-cform-row { display: flex; gap: 12px; align-items: flex-start; }
.pn-cform-ava { flex: none; width: 40px; height: 40px; border-radius: 50%; overflow: hidden; display: grid; place-items: center; background: var(--pn-surface2); color: var(--pn-muted); }
.pn-cform-ava img { width: 100%; height: 100%; object-fit: cover; }
.pn-cform-ava .pn-icon { width: 20px; height: 20px; }
.pn-cform textarea { flex: 1; width: 100%; min-height: 84px; padding: 12px 14px; border: 1px solid var(--pn-border); border-radius: 10px; background: var(--pn-bg); color: var(--pn-text); font: inherit; resize: vertical; }
.pn-cform textarea:focus { outline: none; border-color: var(--pn-accent); }
.pn-cform textarea:disabled { opacity: .6; cursor: not-allowed; }
.pn-cform-submit { display: flex; justify-content: flex-end; gap: 8px; margin: 10px 0 0; }
.pn-cform-note { margin: 8px 0 0 52px; color: var(--pn-muted); font-size: 12px; }
.pn-comments .comment-reply-title:empty { display: none; }
.pn-comments .comment-reply-title { font-size: 14px; margin: 0 0 8px; }
.pn-comments .comment-reply-title small { margin-left: 8px; }
.pn-comment-list, .pn-comment-list .children { list-style: none; margin: 0; padding: 0; }
.pn-comment-list .children { margin-left: 52px; }
.pn-cmt-body, .pn-review { display: flex; gap: 12px; padding: 14px 0; border-top: 1px solid var(--pn-border); }
.pn-cmt-ava { flex: none; width: 40px; height: 40px; border-radius: 50%; position: relative; }
.pn-cmt-ava img { width: 40px; height: 40px; border-radius: 50%; display: block; }
.pn-cmt-ava.is-premium img { box-shadow: 0 0 0 2px var(--pn-surface), 0 0 0 4px #f5c542; }
.pn-cmt-main { flex: 1; min-width: 0; }
.pn-cmt-main header { display: flex; flex-wrap: wrap; align-items: center; gap: 8px; font-size: 14px; }
.pn-cmt-main time, .pn-edited { color: var(--pn-muted); font-size: 12px; font-style: normal; }
.pn-edited { font-style: italic; }
.pn-cmt-text { margin-top: 4px; font-size: 15px; line-height: 1.6; overflow-wrap: anywhere; }
.pn-cmt-text p { margin: 0 0 8px; }
.pn-cmt-actions { display: flex; align-items: center; gap: 14px; margin-top: 2px; font-size: 13px; }
.pn-cmt-actions a { color: var(--pn-muted); }
.pn-cedit textarea { width: 100%; padding: 10px 12px; border: 1px solid var(--pn-border); border-radius: 8px; background: var(--pn-bg); color: var(--pn-text); font: inherit; }
.pn-cedit div { display: flex; justify-content: flex-end; gap: 6px; margin-top: 6px; }
.pn-cmt-empty { margin: 4px 0 0; }
.pn-premium-pill { display: inline-flex; align-items: center; gap: 4px; padding: 1px 8px; border-radius: 999px; background: linear-gradient(135deg, #f5c542, #f59e0b); color: #3b2300; font-size: 11px; font-weight: 800; letter-spacing: .02em; }
.pn-premium-pill .pn-icon { width: 11px; height: 11px; }
.pn-premium-pill-lg { font-size: 12px; padding: 3px 10px; vertical-align: middle; }
.pn-premium-pill-lg .pn-icon { width: 13px; height: 13px; }

/* ---------- Reviews ---------- */
.pn-reviews { padding: 16px; }
.pn-review-list { list-style: none; margin: 0; padding: 0; }
.pn-review .pn-stars { font-size: 12px; }
.pn-review-dialog { width: min(520px, calc(100vw - 32px)); padding: 0; border: 1px solid var(--pn-border); border-radius: 16px; background: var(--pn-surface); color: var(--pn-text); }
.pn-review-dialog::backdrop { background: rgba(0, 0, 0, .65); backdrop-filter: blur(2px); }
.pn-review-form { padding: 18px 20px; }
.pn-review-form header { display: flex; align-items: center; justify-content: space-between; }
.pn-review-form h3 { margin: 0; font-size: 18px; }
.pn-review-form > p { margin: 2px 0 10px; }
.pn-review-stars { display: flex; justify-content: center; gap: 6px; margin: 6px 0 14px; }
.pn-review-stars button { padding: 2px; border: 0; background: none; color: var(--pn-star); cursor: pointer; transition: transform .12s; }
.pn-review-stars button:hover { transform: scale(1.15); }
.pn-review-stars svg { width: 36px; height: 36px; fill: none; stroke: currentColor; stroke-width: 1.5; stroke-linejoin: round; }
.pn-review-stars button.is-on svg { fill: currentColor; }
.pn-review-form textarea { width: 100%; padding: 12px 14px; border: 1px solid var(--pn-border); border-radius: 10px; background: var(--pn-bg); color: var(--pn-text); font: inherit; resize: vertical; }
.pn-review-form footer { display: flex; justify-content: flex-end; gap: 8px; margin-top: 12px; }
.pn-review-note:empty { display: none; }

/* ---------- Recommendations ---------- */
.pn-recs { padding: 16px; }
.pn-recs-grid { display: grid; grid-template-columns: repeat(5, minmax(0, 1fr)); gap: 14px; }
@media (max-width: 1023px) { .pn-recs-grid { grid-template-columns: repeat(4, minmax(0, 1fr)); } }
@media (max-width: 767px) { .pn-recs-grid { grid-template-columns: repeat(2, minmax(0, 1fr)); } }

/* ---------- Header: bell + premium avatar ---------- */
.pn-bell { position: relative; }
.pn-bell-btn { position: relative; width: 40px; height: 40px; border-radius: 50%; background: rgba(0, 0, 0, .14); color: var(--pn-header-text); }
.pn-bell-btn .pn-icon { width: 20px; height: 20px; }
.pn-bell-dot { position: absolute; top: 8px; right: 9px; width: 9px; height: 9px; border-radius: 50%; background: #ef4444; box-shadow: 0 0 0 2px var(--pn-header-bg2); }
.pn-bell-drop { right: -60px; width: min(360px, calc(100vw - 24px)); max-height: 70vh; overflow-y: auto; padding: 6px; }
.pn-bell-drop header { display: flex; justify-content: space-between; align-items: center; padding: 8px 10px; font-size: 14px; }
.pn-bell-drop header a { color: var(--pn-accent); font-size: 13px; }
.pn-bell-item { display: flex; gap: 10px; padding: 10px; border-radius: 10px; color: var(--pn-text); }
a.pn-bell-item:hover { background: rgba(255, 255, 255, .05); color: var(--pn-text); }
.pn-bell-item.is-new { background: color-mix(in srgb, var(--pn-accent) 10%, transparent); }
.pn-bell-ic { flex: none; width: 32px; height: 32px; border-radius: 50%; display: grid; place-items: center; background: color-mix(in srgb, var(--pn-accent) 20%, transparent); color: var(--pn-accent); }
.pn-bell-ic .pn-icon { width: 16px; height: 16px; }
.pn-bell-tx { display: flex; flex-direction: column; gap: 2px; min-width: 0; font-size: 13px; }
.pn-bell-tx small { color: var(--pn-muted); line-height: 1.4; }
.pn-bell-tx time { color: var(--pn-muted); font-size: 11px; }
.pn-bell-empty { margin: 0; padding: 18px; text-align: center; color: var(--pn-muted); font-size: 14px; }
.pn-avatar-btn.is-premium { border: 2px solid #f5c542; box-shadow: 0 0 0 2px rgba(245, 197, 66, .35); }
.pn-ud-promo small .pn-icon { color: #f5c542; }

/* ---------- Profile: premium seal around the avatar ---------- */
.pn-profile-avatar.is-premium { position: relative; overflow: visible; border: 0; background: none; padding: 0; }
.pn-profile-avatar.is-premium > img { position: relative; z-index: 1; width: 72%; height: 72%; margin: 14%; border-radius: 50%; box-shadow: 0 0 0 3px #7c2d12; }
.pn-seal { position: absolute; inset: -16%; z-index: 0; animation: pn-seal-spin 60s linear infinite; filter: drop-shadow(0 6px 14px rgba(0, 0, 0, .45)); }
.pn-seal svg { width: 100%; height: 100%; display: block; }
.pn-seal-ribbon { position: absolute; z-index: 2; left: -18%; right: -18%; bottom: 2%; padding: 3px 0; text-align: center; font: 800 12px/1.2 Georgia, "Times New Roman", serif; font-style: italic; letter-spacing: .04em; color: #fff; background: linear-gradient(180deg, #e11d48, #9f1239); border-radius: 4px; box-shadow: 0 3px 8px rgba(0, 0, 0, .4); clip-path: polygon(0 0, 100% 0, 94% 50%, 100% 100%, 0 100%, 6% 50%); text-shadow: 0 1px 1px rgba(0, 0, 0, .4); }
@keyframes pn-seal-spin { to { transform: rotate(360deg); } }
@media (prefers-reduced-motion: reduce) { .pn-seal { animation: none; } }

/* ---------- Floating help button ---------- */
.pn-chat { position: fixed; right: 18px; bottom: 18px; z-index: 60; display: flex; flex-direction: column; align-items: flex-end; gap: 10px; }
.pn-chat-btn { position: relative; width: 56px; height: 56px; border: 0; border-radius: 50%; background: var(--pn-chat, var(--pn-accent)); color: #fff; cursor: pointer; display: grid; place-items: center; box-shadow: 0 10px 24px -6px color-mix(in srgb, var(--pn-chat, var(--pn-accent)) 70%, transparent); transition: transform .2s; }
.pn-chat-btn:hover { transform: scale(1.06); }
.pn-chat-btn svg { width: 26px; height: 26px; fill: currentColor; }
.pn-chat-btn::after { content: ""; position: absolute; inset: 0; border-radius: 50%; border: 2px solid var(--pn-chat, var(--pn-accent)); animation: pn-chat-ring 2.6s ease-out infinite; }
.pn-chat.is-open .pn-chat-btn::after { animation: none; opacity: 0; }
@keyframes pn-chat-ring { 0% { transform: scale(1); opacity: .7; } 80%, 100% { transform: scale(1.5); opacity: 0; } }
.pn-chat-badge { position: absolute; top: -2px; right: -2px; min-width: 20px; height: 20px; padding: 0 5px; border-radius: 10px; background: #ef4444; color: #fff; font: 700 11px/20px var(--pn-font); font-style: normal; }
.pn-chat-tip { position: absolute; right: 66px; bottom: 10px; pointer-events: none; opacity: 0; transform: translateX(8px); transition: opacity .3s, transform .3s; }
.pn-chat-tip span { display: block; white-space: nowrap; padding: 9px 14px; border-radius: 12px 12px 2px 12px; background: #fff; color: #1d1b22; font-size: 13px; font-weight: 600; box-shadow: 0 8px 20px -6px rgba(0, 0, 0, .5); }
.pn-chat.show-tip .pn-chat-tip { opacity: 1; transform: none; }
.pn-chat-panel { width: min(300px, calc(100vw - 36px)); padding: 8px; border: 1px solid var(--pn-border); border-radius: 16px; background: var(--pn-surface); box-shadow: var(--pn-shadow); }
.pn-chat-panel header { padding: 10px 10px 8px; }
.pn-chat-panel header strong { display: block; font-size: 16px; }
.pn-chat-panel header small { color: var(--pn-muted); font-size: 12px; }
.pn-chat-panel a { display: flex; align-items: center; gap: 10px; padding: 11px 10px; border-radius: 10px; color: var(--pn-text); font-size: 14px; }
.pn-chat-panel a:hover { background: rgba(255, 255, 255, .05); color: var(--pn-text); }
.pn-chat-panel a span { flex: 1; }
.pn-chat-panel a .pn-icon { width: 18px; height: 18px; }
.pn-chat-panel a .pn-icon:first-child { color: var(--pn-chat, var(--pn-accent)); }
body .pn-totop { bottom: 86px; }
body.single-chapter .pn-chat { bottom: 74px; }
body.single-chapter .pn-totop { bottom: 142px; }

/* ---------- Membership page ---------- */
.pn-member-page { max-width: 1000px; }
.pn-member-hero { text-align: center; padding: 28px 0 10px; }
.pn-member-seal { display: inline-grid; place-items: center; width: 64px; height: 64px; border-radius: 50%; background: linear-gradient(135deg, #f5c542, var(--pn-premium)); color: #3b2300; box-shadow: 0 10px 30px -8px rgba(245, 197, 66, .6); }
.pn-member-seal .pn-icon { width: 30px; height: 30px; }
.pn-member-hero h1 { margin: 14px 0 4px; font-size: clamp(28px, 5vw, 44px); }
.pn-member-price strong { font-size: 40px; color: #f5c542; }
.pn-member-price span { color: var(--pn-muted); }
.pn-member-intro { max-width: 600px; margin: 0 auto; color: var(--pn-muted); }
.pn-member-active { display: inline-flex; align-items: center; gap: 8px; margin-top: 14px; padding: 8px 14px; border-radius: 10px; background: rgba(16, 185, 129, .14); color: #6ee7b7; }
.pn-member-active .pn-icon { width: 16px; height: 16px; }
.pn-member-perks { list-style: none; display: flex; flex-wrap: wrap; justify-content: center; gap: 8px 18px; margin: 18px auto 26px; padding: 0; }
.pn-member-perks li { display: flex; align-items: center; gap: 6px; font-size: 14px; }
.pn-member-perks .pn-icon { width: 16px; height: 16px; color: #10b981; }
.pn-member-cards { display: grid; grid-template-columns: repeat(auto-fit, minmax(280px, 1fr)); gap: 18px; }
.pn-member-card { position: relative; display: flex; flex-direction: column; gap: 10px; padding: 24px; border: 1px solid var(--pn-border); border-radius: 18px; background: var(--pn-surface); }
.pn-member-card.is-patreon { border-color: color-mix(in srgb, #f5c542 50%, var(--pn-border)); background: linear-gradient(160deg, rgba(245, 197, 66, .08), var(--pn-surface) 50%); }
.pn-member-card h2 { display: flex; align-items: center; gap: 8px; margin: 0; font-size: 24px; }
.pn-member-card h2 .pn-icon { width: 24px; height: 24px; }
.pn-member-card p { margin: 0; color: var(--pn-muted); }
.pn-member-card .pn-btn { margin-top: auto; justify-content: center; }
.pn-member-card-price { font-size: 26px; font-weight: 800; color: var(--pn-text) !important; }
.pn-member-card-price small { font-size: 14px; font-weight: 500; color: var(--pn-muted); }
.pn-member-tag { position: absolute; top: 16px; right: 16px; padding: 3px 10px; border-radius: 999px; background: rgba(16, 185, 129, .15); color: #6ee7b7; font-size: 12px; font-weight: 700; }
.pn-usdt { display: inline-grid; place-items: center; width: 26px; height: 26px; border-radius: 50%; background: #26a17b; color: #fff; font-size: 15px; }
.pn-member-wallet { display: grid; gap: 6px; padding: 12px; border: 1px solid var(--pn-border); border-radius: 12px; background: var(--pn-bg); }
.pn-member-wallet small { color: var(--pn-muted); font-size: 11px; text-transform: uppercase; letter-spacing: .06em; }
.pn-member-wallet code { overflow-wrap: anywhere; font-size: 13px; }
.pn-member-wallet .pn-btn { justify-self: start; margin: 0; }
.pn-member-warn { padding: 8px 10px; border-radius: 8px; background: rgba(245, 158, 11, .12); color: #fcd34d !important; font-size: 13px; }
.pn-member-help { display: flex; flex-wrap: wrap; align-items: center; justify-content: space-between; gap: 14px; margin: 22px 0; padding: 20px 24px; border: 1px dashed var(--pn-border); border-radius: 18px; }
.pn-member-help h2 { margin: 0 0 4px; font-size: 20px; }
.pn-member-help p { margin: 0; color: var(--pn-muted); }
.pn-member-help-actions { display: flex; flex-wrap: wrap; gap: 8px; }

/* ---------- "Already subscribed?" ---------- */
.pn-proof { padding: 28px; }
.pn-proof h1 { margin: 10px 0 4px; }
.pn-proof-form { display: grid; gap: 14px; margin-top: 18px; }
.pn-proof-methods { display: flex; flex-wrap: wrap; gap: 10px; margin: 0; padding: 0; border: 0; }
.pn-proof-methods legend { margin-bottom: 8px; font-weight: 600; font-size: 14px; }
.pn-proof-method input { position: absolute; opacity: 0; }
.pn-proof-method span { display: inline-flex; align-items: center; gap: 8px; padding: 12px 18px; border: 1px solid var(--pn-border); border-radius: 12px; cursor: pointer; font-weight: 600; transition: border-color .15s, background .15s; }
.pn-proof-method span .pn-icon { width: 18px; height: 18px; }
.pn-proof-method input:checked + span { border-color: var(--pn-accent); background: color-mix(in srgb, var(--pn-accent) 16%, transparent); }
.pn-proof-method input:focus-visible + span { outline: 2px solid var(--pn-accent); }
.pn-field { display: grid; gap: 6px; font-size: 14px; }
.pn-field > span { font-weight: 600; }
.pn-field input[type=text], .pn-field textarea { width: 100%; padding: 11px 14px; border: 1px solid var(--pn-border); border-radius: 10px; background: var(--pn-bg); color: var(--pn-text); font: inherit; }
.pn-field input:focus, .pn-field textarea:focus { outline: none; border-color: var(--pn-accent); }
.pn-file { position: relative; display: grid; gap: 8px; }
.pn-file input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.pn-file-ui { display: flex; align-items: center; gap: 10px; padding: 16px; border: 1px dashed var(--pn-border); border-radius: 12px; color: var(--pn-muted); }
.pn-file-ui em { font-style: normal; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pn-file:hover .pn-file-ui { border-color: var(--pn-accent); }
.pn-file img, .pn-attach img { max-height: 160px; max-width: 100%; border-radius: 8px; object-fit: contain; justify-self: start; }
.pn-proof-alt { margin: 16px 0 0; color: var(--pn-muted); font-size: 14px; }

/* ---------- Messages page ---------- */
.pn-msgs { display: grid; grid-template-columns: 300px minmax(0, 1fr); gap: 18px; padding-top: 24px; padding-bottom: 40px; }
.pn-msgs-list { padding: 12px; align-self: start; }
.pn-msgs-list header { display: flex; justify-content: space-between; align-items: center; padding: 4px 4px 10px; }
.pn-msgs-list h1 { display: flex; align-items: center; gap: 8px; margin: 0; font-size: 20px; }
.pn-msgs-item { display: grid; gap: 2px; padding: 10px 12px; border-radius: 10px; color: var(--pn-text); }
.pn-msgs-item:hover { background: rgba(255, 255, 255, .04); color: var(--pn-text); }
.pn-msgs-item.is-active { background: color-mix(in srgb, var(--pn-accent) 16%, transparent); }
.pn-msgs-item strong { font-size: 14px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pn-msgs-item.is-unread strong::after { content: ""; display: inline-block; width: 8px; height: 8px; margin-left: 6px; border-radius: 50%; background: #ef4444; vertical-align: middle; }
.pn-msgs-item span, .pn-msgs-item time { color: var(--pn-muted); font-size: 12px; }
.pn-msg-tag { display: inline-block; padding: 1px 7px; border-radius: 6px; font-size: 11px; font-style: normal; font-weight: 700; background: rgba(255, 255, 255, .08); }
.pn-msg-tag.is-submit_proof { background: rgba(245, 197, 66, .16); color: #fcd34d; }
.pn-msgs-view { padding: 18px; min-height: 420px; display: flex; flex-direction: column; }
.pn-msgs-view h2 { margin: 0 0 6px; font-size: 20px; }
.pn-msgs-head { display: flex; align-items: center; gap: 10px; padding-bottom: 12px; border-bottom: 1px solid var(--pn-border); }
.pn-msgs-head h2 { margin: 0; flex: 1; }
.pn-chat-thread { flex: 1; display: flex; flex-direction: column; gap: 12px; max-height: 60vh; overflow-y: auto; padding: 16px 2px; }
.pn-cmsg { display: flex; flex-direction: column; max-width: 80%; }
.pn-cmsg.is-me { align-self: flex-end; align-items: flex-end; }
.pn-cmsg-bubble { padding: 10px 14px; border-radius: 16px; background: var(--pn-surface2); border: 1px solid var(--pn-border); overflow-wrap: anywhere; }
.pn-cmsg.is-me .pn-cmsg-bubble { background: var(--pn-accent); color: var(--pn-accent-text); border-color: transparent; border-bottom-right-radius: 4px; }
.pn-cmsg.is-them .pn-cmsg-bubble { border-bottom-left-radius: 4px; }
.pn-cmsg-bubble p { margin: 0 0 6px; }
.pn-cmsg-bubble p:last-child { margin: 0; }
.pn-cmsg.is-me .pn-cmsg-bubble a { color: inherit; text-decoration: underline; }
.pn-cmsg small { margin-top: 3px; color: var(--pn-muted); font-size: 11px; }
.pn-msg-img img { display: block; max-width: 260px; height: auto; margin-top: 6px; border-radius: 10px; }
.pn-msg-form { display: grid; gap: 12px; }
.pn-msg-reply { padding-top: 12px; border-top: 1px solid var(--pn-border); }
.pn-msg-reply textarea { width: 100%; padding: 11px 14px; border: 1px solid var(--pn-border); border-radius: 12px; background: var(--pn-bg); color: var(--pn-text); font: inherit; resize: vertical; }
.pn-msg-bar { display: flex; align-items: center; justify-content: space-between; gap: 10px; }
.pn-attach { position: relative; display: inline-flex; align-items: center; gap: 6px; color: var(--pn-muted); font-size: 13px; cursor: pointer; }
.pn-attach input { position: absolute; inset: 0; opacity: 0; cursor: pointer; }
.pn-attach em { font-style: normal; max-width: 180px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.pn-attach img { max-height: 40px; }
.pn-attach .pn-icon { width: 18px; height: 18px; }

@media (max-width: 767px) {
	.pn-msgs { grid-template-columns: 1fr; }
	.pn-msgs-list { max-height: 260px; overflow-y: auto; }
	.pn-cmsg { max-width: 92%; }
	.pn-react-btn { min-width: 0; flex: 1 1 30%; }
	.pn-react-emoji { font-size: 32px; }
	.pn-comment-list .children { margin-left: 20px; }
	.pn-cform-note { margin-left: 0; }
	.pn-chat { right: 12px; bottom: 12px; }
	.pn-chat-btn { width: 50px; height: 50px; }
	body .pn-totop { bottom: 74px; }
	body.single-chapter .pn-chat { bottom: 64px; }
	body.single-chapter .pn-totop { bottom: 124px; }
	.pn-bell-drop { right: -100px; }
	.pn-bell-btn { width: 36px; height: 36px; }
	.pn-proof { padding: 20px; }
}
.pn-profile-avatar.is-premium + .pn-profile-who { margin-left: 18px; }
@media (max-width: 767px) { .pn-profile-avatar.is-premium + .pn-profile-who { margin-left: 0; margin-top: 14px; } }

/* ---------- Phones: keep the reader clean (no help button / back-to-top over the text) ---------- */
@media (max-width: 767px) {
	body.single-chapter .pn-chat, body.single-chapter .pn-totop { display: none !important; }
}

/* ---------- Phones/tablets: the logo takes turns with "Home" (all visitors) ---------- */
.pn-brand-home { display: none; }
@media (max-width: 1023px) {
	.pn-brand { position: relative; }
	.pn-brand .pn-logo, .pn-brand .pn-logo-mark { animation: pn-brand-a 4s ease-in-out infinite; }
	.pn-brand-home {
		position: absolute; left: 0; top: 50%; display: inline-flex; align-items: center; gap: 6px;
		padding: 6px 12px; border-radius: 999px; background: rgba(0, 0, 0, .14); color: var(--pn-header-text);
		font-weight: 800; font-size: 15px; white-space: nowrap; transform: translateY(-50%);
		animation: pn-brand-b 4s ease-in-out infinite; pointer-events: none;
	}
	.pn-brand-home .pn-icon { width: 18px; height: 18px; }
	.pn-brand .pn-brand-name { display: none; }
}
/* Logo for 1s, swap, "Home" for 1s, swap back. */
@keyframes pn-brand-a { 0%, 35% { opacity: 1; transform: none; } 50%, 85% { opacity: 0; transform: scale(.85); } 100% { opacity: 1; transform: none; } }
@keyframes pn-brand-b { 0%, 35% { opacity: 0; transform: translateY(-50%) scale(.85); } 50%, 85% { opacity: 1; transform: translateY(-50%); } 100% { opacity: 0; transform: translateY(-50%) scale(.85); } }
@media (prefers-reduced-motion: reduce) {
	.pn-brand .pn-logo, .pn-brand-home { animation: none; }
	.pn-brand-home { display: none; }
}

/* ---------- Bottom sheet (notification / sign-up nudges) ---------- */
.pn-sheet { position: fixed; left: 50%; bottom: 18px; z-index: 90; display: flex; gap: 12px; width: min(440px, calc(100vw - 24px)); padding: 16px 18px; border: 1px solid var(--pn-border); border-radius: 16px; background: var(--pn-surface); color: var(--pn-text); box-shadow: 0 20px 50px -12px rgba(0, 0, 0, .7); transform: translate(-50%, 140%); transition: transform .35s cubic-bezier(.2, .9, .3, 1.2); }
.pn-sheet.is-in { transform: translate(-50%, 0); }
.pn-sheet-icon { flex: none; width: 44px; height: 44px; display: grid; place-items: center; border-radius: 12px; background: color-mix(in srgb, var(--pn-accent) 20%, transparent); font-size: 22px; }
.pn-sheet-body strong { display: block; font-size: 16px; }
.pn-sheet-body p { margin: 4px 0 12px; color: var(--pn-muted); font-size: 14px; line-height: 1.45; }
.pn-sheet-actions { display: flex; gap: 8px; justify-content: flex-end; }
.pn-sheet-x { position: absolute; top: 6px; right: 8px; border: 0; background: none; color: var(--pn-muted); font-size: 22px; line-height: 1; cursor: pointer; }

/* ---------- Series chapter list: latest free chapters pinned above the locked ones ---------- */
.pn-ch-list li.is-pinned a { background: color-mix(in srgb, var(--pn-accent) 7%, transparent); }
.pn-ch-list li.is-pinned a:hover { background: color-mix(in srgb, var(--pn-accent) 13%, transparent); }
.pn-ch-list li.is-pinned .pn-ch-badge { margin-left: auto; }
.pn-ch-badge.is-free { color: var(--pn-accent); background: color-mix(in srgb, var(--pn-accent) 16%, transparent); }
.pn-ch-pin-sep { position: relative; height: 22px; display: flex; align-items: center; justify-content: center; }
.pn-ch-pin-sep::before { content: ""; position: absolute; left: 0; right: 0; top: 50%; height: 2px; transform: translateY(-50%); background: linear-gradient(90deg, transparent, var(--pn-accent) 15%, var(--pn-accent) 85%, transparent); box-shadow: 0 0 10px color-mix(in srgb, var(--pn-accent) 60%, transparent); }
.pn-ch-pin-sep span { position: relative; display: inline-flex; align-items: center; gap: 5px; padding: 1px 10px; border-radius: 999px; background: var(--pn-accent); color: var(--pn-accent-text); font-size: 11px; font-weight: 800; letter-spacing: .03em; text-transform: uppercase; }
.pn-ch-pin-sep .pn-icon { width: 11px; height: 11px; }
.pn-chapters .pn-ch-list:has(.pn-ch-pin-sep) { max-height: calc((var(--pn-ch-visible, 6) + var(--pn-pinned, 2)) * 45px + 22px); }
.pn-ch-pin-sep em { font-style: normal; }
.pn-free-in.is-next { display: inline-flex; align-items: center; gap: 4px; flex: none; padding: 2px 8px; border-radius: 6px; background: color-mix(in srgb, var(--pn-badge-unlocked, #10b981) 15%, transparent); color: var(--pn-badge-unlocked, #10b981); font-size: 11.5px; font-weight: 700; white-space: nowrap; }
.pn-free-in.is-next .pn-icon { width: 12px; height: 12px; }
.pn-free-in.is-next [data-pn-countdown] { font-variant-numeric: tabular-nums; }

/* ---------- Free books ---------- */
.pn-free-book { position: absolute; top: 6px; left: 6px; z-index: 2; display: inline-flex; align-items: center; gap: 3px; padding: 3px 8px; border-radius: 6px; background: var(--pn-badge-free, #14b8a6); color: #04201c; font-size: 11px; font-weight: 800; letter-spacing: .03em; text-transform: uppercase; box-shadow: 0 4px 10px -3px rgba(0, 0, 0, .5); }
.pn-free-book .pn-icon { width: 11px; height: 11px; }
.pn-cover-strip.is-freebook { background: var(--pn-badge-free, #14b8a6); color: #04201c; }
.pn-novel-cover { position: relative; }
.pn-novel-cover .pn-cover-strip { font-size: 13px; padding: 7px 4px; }
.pn-filter.is-active { border-color: var(--pn-badge-free, #14b8a6); }

.pn-sheet.is-single .pn-sheet-actions { justify-content: stretch; }
.pn-sheet.is-single [data-yes] { flex: 1; justify-content: center; padding: 11px 16px; font-size: 15px; }

.pn-free-row .pn-title-icon { background: color-mix(in srgb, var(--pn-badge-free, #14b8a6) 20%, transparent); color: var(--pn-badge-free, #14b8a6); }

/* ---------- Bell: announcements with image, tap to read in full ---------- */
.pn-bell-ann { cursor: pointer; }
.pn-bell-ann .pn-bell-ic img { width: 32px; height: 32px; border-radius: 50%; object-fit: cover; }
.pn-ann-full { display: none; }
.pn-bell-ann.is-open .pn-ann-short { display: none; }
.pn-bell-ann.is-open .pn-ann-full { display: grid; gap: 8px; margin-top: 4px; color: var(--pn-text); font-size: 13px; line-height: 1.5; }
.pn-ann-full p { margin: 0; }
.pn-ann-img { width: 100%; height: auto; border-radius: 10px; }
.pn-ann-full .pn-btn { justify-self: start; }

/* ---------- Sign in / password reset ---------- */
.pn-auth-row { display: flex; align-items: center; justify-content: space-between; gap: 10px; flex-wrap: wrap; }
.pn-auth-forgot { font-size: 14px; color: var(--pn-accent); font-weight: 600; }
.pn-auth-switch a { font-weight: 700; color: var(--pn-accent); }
.pn-alert-warn { display: flex; gap: 8px; align-items: flex-start; padding: 10px 12px; border-radius: 10px; background: rgba(245, 158, 11, .12); color: #fcd34d; font-size: 13px; line-height: 1.45; }
.pn-alert-warn .pn-icon { flex: none; width: 16px; height: 16px; margin-top: 1px; }
.pn-code-timer { display: flex; align-items: center; justify-content: center; gap: 8px; margin: 14px 0 4px; padding: 10px; border-radius: 12px; background: color-mix(in srgb, var(--pn-accent) 12%, transparent); font-size: 15px; }
.pn-code-timer .pn-icon { width: 18px; height: 18px; color: var(--pn-accent); }
.pn-code-timer strong { font-variant-numeric: tabular-nums; font-size: 18px; }
.pn-code-timer .pn-code-over { display: none; color: #fca5a5; font-weight: 700; }
.pn-code-timer.is-over { background: rgba(239, 68, 68, .12); }
.pn-code-timer.is-over .pn-code-left { display: none; }
.pn-code-timer.is-over .pn-code-over { display: inline; }
.pn-code-timer.is-low strong { color: #fca5a5; }
.pn-code-input { text-align: center; font-size: 26px !important; letter-spacing: .5em; font-variant-numeric: tabular-nums; }
.pn-code-actions { display: flex; justify-content: space-between; align-items: center; gap: 10px; margin-top: 12px; }
.pn-code-actions form { margin: 0; }
.pn-code-actions .pn-link-btn { color: var(--pn-accent); font-weight: 600; font-size: 14px; }
.pn-code-actions .pn-icon { width: 14px; height: 14px; }
.pn-auth-card.is-expired .pn-code-form, .pn-auth-card.is-expired [data-resend-form] { opacity: .45; pointer-events: none; }
.pn-auth-card.is-expired [data-retry] { padding: 8px 14px; border-radius: 10px; background: var(--pn-accent); color: var(--pn-accent-text); }

/* ---------- Social login ---------- */
.pn-oauth { display: grid; gap: 10px; margin: 6px 0 4px; }
.pn-oauth-btn { display: flex; align-items: center; justify-content: center; gap: 10px; padding: 11px 16px; border-radius: 12px; font-weight: 700; font-size: 15px; transition: transform .12s, filter .12s; }
.pn-oauth-btn:hover { transform: translateY(-1px); filter: brightness(1.05); }
.pn-oauth-btn svg { width: 20px; height: 20px; flex: none; }
.pn-oauth-btn.is-google { background: #fff; color: #1f1f1f; border: 1px solid #dadce0; }
.pn-oauth-btn.is-google:hover { color: #1f1f1f; }
.pn-oauth-btn.is-x { background: #000; color: #fff; border: 1px solid #333; }
.pn-oauth-btn.is-x:hover { color: #fff; }
.pn-oauth-or { position: relative; margin: 6px 0 2px; text-align: center; color: var(--pn-muted); font-size: 13px; }
.pn-oauth-or::before { content: ""; position: absolute; left: 0; right: 0; top: 50%; border-top: 1px solid var(--pn-border); }
.pn-oauth-or span { position: relative; padding: 0 10px; background: var(--pn-surface); }
.pn-oauth { width: 100%; align-self: stretch; }
.pn-oauth-btn { width: 100%; box-sizing: border-box; text-decoration: none; }
.pn-oauth-btn span { color: inherit; white-space: nowrap; }
.pn-oauth-or { width: 100%; }

/* Notice popup */
.pn-notice-link { background: none; border: 0; color: inherit; font: inherit; font-weight: 600; text-align: left; cursor: pointer; padding: 0; }
.pn-notice-btn { border: 0; cursor: pointer; font-family: inherit; }
.pn-notice-dialog { width: min(560px, calc(100vw - 32px)); }
.pn-nd-head { display: flex; align-items: center; gap: 10px; padding: 16px 18px; border-bottom: 1px solid var(--pn-border); }
.pn-nd-head strong { flex: 1; font-size: 1.1em; }
.pn-nd-icon { display: inline-flex; width: 34px; height: 34px; align-items: center; justify-content: center; border-radius: 10px; background: var(--pn-notice-bg); color: #fff; flex: none; }
.pn-nd-body { padding: 16px 18px; max-height: 60vh; overflow: auto; line-height: 1.65; color: var(--pn-text); white-space: normal; }
.pn-nd-body p { margin: 0 0 .8em; }
.pn-nd-body a { color: var(--pn-accent); text-decoration: underline; word-break: break-word; }
.pn-nd-actions { display: flex; justify-content: flex-end; gap: 8px; padding: 12px 18px 16px; border-top: 1px solid var(--pn-border); }
