:root {
    --border: #eaeaea;
    --w: #ffffff;
    --hsvg: #95A5A6;
    --bbg: #f9fafd;
    --ff: 'IRANYekan', -apple-system, BlinkMacSystemFont, 'Segoe UI', sans-serif;
    --text-primary: #212529;
    --primary: #2e4281;
    --tipbg: #ffffe5;
    --tipb: #acac31;
    --cm: 0 0.75rem;
    --btn-hover: #06237d;
    --fs: 0.875rem;
    --err: #e74c3c;
    --err-hover: #c53324;
}

* {
    padding: 0;
    margin: 0;
    box-sizing: border-box;
    -webkit-user-select: none;
    -ms-user-select: none;
    user-select: none;
    -webkit-tap-highlight-color: transparent;
    direction: rtl;
}

@font-face {
    font-family: 'IRANYekan';
    src: url('/../assets/fonts/YekanBakh-Medium.woff2') format('woff2');
    font-display: swap;
}

#installBtn {
  position: fixed;
  bottom: 20px;
  left: 50%;
  transform: translateX(-50%);
  padding: 15px 30px;
  background: var(--primary);
  color: white;
  border: none;
  border-radius: 25px;
  font-size: 16px;
  cursor: pointer;
  box-shadow: 0 4px 6px rgba(0,0,0,0.2);
  z-index: 1000;
  font-family: var(--ff);
}

#installBtn:hover {
  background: #45a049;
}


html {
    overflow-y: scroll;
    scroll-behavior: smooth;
}

body {
    background-color: var(--bbg);
    font-family: var(--ff);
}

a {
    text-decoration: none;
}

/* badge */
/* Neon Cyan - فیروزه‌ای نئونی */
.badge-premium {
    color: #00F5FF;
}

/* Purple Haze - بنفش مه‌آلود */
.badge-elite {
    color: #9D4EDD;
}

/* Coral Sunset - مرجانی غروب */
.badge-special {
    color: #FF6B9D;
}

/* Electric Blue - آبی الکتریک */
.badge-pro {
    color: #4D9FFF;
}

/* Mint Fresh - نعنایی تازه */
.badge-supporter {
    color: #5FFBF1;
}

/* Gold Shine - طلایی درخشان */
.badge-legend {
    color: #FFD93D;
}

/* Lavender Dream - اسطوخودوسی رویایی */
.badge-member {
    color: #C77DFF;
}

/* Lime Glow - لیمویی درخشان */
.badge-active {
    color: #B4FF39;
}

/* Rose Gold - رزگلد */
.badge-exclusive {
    color: #F4A6C3;
}

/* Teal Magic - سبزآبی جادویی */
.badge-verified {
    color: #1DD3B0;
}

/* Amber Warm - کهربایی گرم */
.badge-trusted {
    color: #FFAB40;
}

/* Indigo Night - نیلی شبانه */
.badge-expert {
    color: #6366F1;
}

/* end badge */

/* Admin - نارنجی طلایی */
.badge-admin {
    color: #F39C12;
}

/* Moderator - سبز */
.badge-moderator {
    color: #2ECC71;
}

/* VIP - صورتی فوشیا */
.badge-vip {
    color: #E91E63;
}

/* Gray - فیروزه‌ای درخشان */
.badge-gray {
    color: #00d2d3;
}

/* Premium - بنفش نئون */
.badge-bluesky {
    color: #b24bf3;
}

/* Gold - زرد لیمویی */
.badge-gold {
    color: #cddc39;
}

/* Silver - آبی یخی */
.badge-silver {
    color: #00bcd4;
}

/* Bronze - نارنجی هویجی */
.badge-bronze {
    color: #ff6f00;
}

/* Pro - صورتی هات */
.badge-darkpurple {
    color: #ff4081;
}

/* Expert - آبی الکتریک */
.badge-darkblue {
    color: #2979ff;
}

/* Verified - سبز لایمی */
.badge-twitterblue {
    color: #76ff03;
}

/* Supporter - قرمز مرجانی */
.badge-red {
    color: #ff5252;
}

/* Elite - بنفش انگوری */
.badge-yashmi {
    color: #7c4dff;
}

/* Legend - نارنجی آتشین */
.badge-redorange {
    color: #ff3d00;
}




.container {
    width: 100%;
    max-width: 512px;
    margin: auto;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

header {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    border: 1px solid var(--border);
    padding-bottom: 1rem;
    padding: 0.5rem 1rem;
    background-color: var(--w);
    width: 100%;
    max-width: 512px;
    margin: 0 auto;
    min-height: 52.6px;
}

.userImg {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    overflow: hidden;
}

.userImg img {
    width: 100%;
    height: auto;
    display: flex;
    align-items: center;
    justify-content: center;
}

.gootenLogo {
    width: 25px;
    height: 25px;
    overflow: hidden;
}

.gootenLogo img {
    width: 100%;
    height: auto;
    display: flex;
    align-items: center;
    justify-content: center;
}

.searchIcon {
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    cursor: pointer;
}

.searchIcon i {
    color: var(--hsvg);
    font-size: 1.1em;
}

.searchIcon p {
    font-size: 0.75rem;
    color: var(--hsvg);
}

.mainFeed {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    padding: 0 1rem;
    margin-bottom: 4rem;
}

.feedItem {
    display: flex;
    flex-direction: column;
    gap: 1.5rem;
    background-color: var(--w);
    padding: 1rem;
    border-radius: 0.5rem;
    border: 1px solid var(--border);
    position: relative;
}

.feedHeader {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    flex-wrap: wrap;
}

.feedUserMeta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.feedUserAvatar {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    overflow: hidden;
    background-color: var(--border);
}

.feedUserAvatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.feedMeta {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.userMeta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.feedUserNickName {
    font-size: 0.78rem;
    color: var(--text-primary);
    max-width: 100px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.feedUserName {
    font-size: 0.72rem;
    color: var(--hsvg);
    direction: ltr;
    max-width: 100px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.feedTime {
    font-size: 0.6rem;
    color: var(--hsvg);
}

.feedHeaderAction {
    font-size: 1.3rem;
    color: var(--hsvg);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    position: relative;
    width: 40px;
    height: 40px;
}

.feedHeaderAction i {
    color: var(--hsvg);
    font-size: 0.8em;
}

.feedActionBox {
    position: absolute;
    background-color: var(--w);
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    width: 100px;
    display: flex;
    flex-direction: column;
    top: 100%;
    left: 0;
    box-shadow: rgba(0, 0, 0, 0.09) 0px 1px 5px;
    opacity: 1;
    visibility: visible;
    transition: opacity 0.2s ease, visibility 0.2s ease;
    overflow: hidden;
    z-index: 9999;
}

.feedActionBox.hidden {
    /* opacity: 0;
    visibility: hidden;
    pointer-events: none; */
    display: none;
}

.feedActionBox button,
.feedActionBox a {
    font-size: 0.7rem;
    color: var(--text-primary);
    padding: 0.5rem 0.75rem;
    border-radius: 0.25rem;
    background-color: transparent;
    border: 0;
    outline: 0;
    text-align: right;
    font-family: var(--ff);
    cursor: pointer;
}

.feedActionBox button:hover,
.feedActionBox a:hover {
    background-color: var(--bbg);
}

/* modal */
.modal {
    display: none;
    position: fixed;
    bottom: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    align-items: flex-end;
    justify-content: center;
}

.modal.modal-show {
    display: flex;
}

.modal-content {
    background: var(--w);
    padding: 1rem;
    border-radius: 0.5rem 0.5rem 0 0;
    max-width: 512px;
    width: 100%;
    min-height: 150px;
    display: flex;
    flex-direction: column;
    gap: 1rem;
    bottom: 0;
    position: absolute;
}

.modal-content #confirmMessage {
    font-size: 0.8rem;
    color: var(--text-primary);
    line-height: 1.8;
}

.modal-content #reportReason {
    border: 1px solid var(--border);
    outline: 0;
    background: var(--bbg);
    border-radius: 0.5rem;
    padding: 1rem;
    color: var(--text-primary);
    font-family: var(--ff);
    font-size: 0.8rem;
    line-height: 1.8;
}

.modal-actions {
    display: flex;
    gap: 1rem;
    justify-content: space-between;
    margin-top: auto;
}

.modal-actions button {
    width: 100%;
    height: 40px;
    border: 0;
    outline: 0;
    font-size: 0.8rem;
    font-family: var(--ff);
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    border-radius: 0.5rem;
}

.modal-actions .btn-danger {
    color: var(--w);
    background-color: var(--err);
}

.modal-actions .btn-secondary {
    color: var(--w);
    background-color: var(--hsvg);
}

/* end modal */

.feedBody {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.feedBody {
    position: relative;
}

.feedBody.locked .feedContent,
.feedBody.locked .feedImage {
    filter: blur(10px);
    pointer-events: none;
    user-select: none;
}

.locked-overlay {
    position: absolute;
    top: 0;
    left: 0;
    right: 0;
    bottom: 0;
    background: rgba(255, 255, 255, 0.1);
    backdrop-filter: blur(5px);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10;
}

.locked-content {
    text-align: center;
    display: flex;
    align-items: center;
    justify-content: center;
    gap: 0.5rem;
    background-color: var(--primary);
    height: 40px;
    padding: 0 0.5rem;
    border-radius: 0.5rem;
}

.locked-content i {
    font-size: 1rem;
    color: var(--w);
}

.locked-content p {
    font-size: 0.8rem;
    color: var(--text-primary);
}

.unlock-btn {
    background: var(--primary-color);
    color: var(--w);
    border: none;
    cursor: pointer;
    font-size: 0.8rem;
    font-family: var(--ff);
    transition: all 0.2s;
    display: flex;
    align-items: center;
    justify-content: center;
    height: 100%;
    border-right: 2px solid var(--w);
    padding: 0 1.5rem 0 1rem;
}

.feedContent {
    font-size: 0.8rem;
    color: var(--text-primary);
    line-height: 1.8;
    margin-bottom: 1rem;
}

.feedImage {
    width: 100%;
    max-width: 512px;
    height: 100%;
     /*max-height: 512px; */
    border-radius: 0.5rem;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
}

.feedImage img {
    width: 100%;
    height: 100%;
    display: flex;
    align-items: center;
    justify-content: center;
}

.feedFooter {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
}

.feedLike {
    display: flex;
    align-items: center;
    cursor: pointer;
    gap: 0.5rem;
    flex: 1;
    font-size: 0.75rem;
    color: var(--hsvg);
}

.liked {
    color: #E0245E;
}

.feedLikeBtn {
    font-size: 0.75rem;
    color: var(--hsvg);
}

.feedLikeCount {
    font-size: 0.75rem;
    color: var(--hsvg);
}

.feedComment {
    display: flex;
    align-items: center;
    cursor: pointer;
    gap: 0.5rem;
    flex: 1;
}


.feedCommentBtn {
    font-size: 0.75rem;
    color: var(--hsvg);
}

.feedCommentCount {
    font-size: 0.75rem;
    color: var(--hsvg);
}

.feedRepost {
    display: flex;
    align-items: center;
    cursor: pointer;
    gap: 0.5rem;
    flex: 1;
}

.unavailablePostMessage {
    color: gray;
    font-size: 0.8rem;
}


.feedRepostBtn,
.feedRepostCount {
    font-size: 0.75rem;
    color: var(--hsvg);
}

.feedRepostCount {
    font-size: 0.75rem;
    color: var(--hsvg);
}

.feedView {
    display: flex;
    align-items: center;
    cursor: pointer;
    gap: 0.5rem;
}


.feedViewBtn,
.feedViewCount {
    font-size: 0.75rem;
    color: var(--hsvg);
}

.feedViewBtn,
.feedViewCount {
    font-size: 0.75rem;
    color: var(--hsvg);
}

footer {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    max-width: 512px;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    padding: 0.5rem 1rem;
    height: 50px;
    background-color: var(--w);
    border: 1px solid var(--border);
    z-index: 1000;
}

footer a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 35px;
    height: 35px;
    border-radius: 50%;
}

footer a:hover {
    background-color: var(--primary);
}

footer a:hover>i {
    color: var(--w);
}

footer i {
    color: var(--hsvg);
}

footer .notification {
    position: relative;
}

.notification .fa-bell {
    display: inline-block;
    transition: transform 0.3s ease;
}

/* وقتی نوتیف داریم، آیکون زنگ تکون بخوره */
.notification.has-unread .fa-bell {
    animation: bell-ring 0.8s ease-in-out infinite;
}

@keyframes bell-ring {

    0%,
    100% {
        transform: rotate(0deg);
    }

    10% {
        transform: rotate(15deg);
    }

    20% {
        transform: rotate(-15deg);
    }

    30% {
        transform: rotate(10deg);
    }

    40% {
        transform: rotate(-10deg);
    }

    50% {
        transform: rotate(5deg);
    }

    60% {
        transform: rotate(-5deg);
    }

    70% {
        transform: rotate(0deg);
    }
}

footer a {
    position: relative;
}

footer .activeTabF {
    position: absolute;
    content: '';
    width: 5px;
    height: 5px;
    background: #2e4281b3;
    border-radius: 50%;
    bottom: 4px;
    right: 50%;
    transform: translate(50%, 100%);
}

/* نقطه قرمز - به صورت پیش‌فرض مخفی */
.has-notification {
    position: absolute;
    width: 6px;
    height: 6px;
    top: -2px;
    right: -2px;
    border-radius: 50%;
    background-color: #E74C3C;
    display: none;
}

/* وقتی نوتیف داریم، نقطه قرمز نمایش داده بشه */
.notification.has-unread .has-notification {
    display: block;
    animation: notification-pulse 1.5s ease-in-out infinite;
}

.notification.has-unread .has-notification::before {
    content: '';
    position: absolute;
    top: 50%;
    left: 50%;
    transform: translate(-50%, -50%);
    width: 100%;
    height: 100%;
    border-radius: 50%;
    background-color: #E74C3C;
    opacity: 0.6;
    animation: notification-wave 1.5s ease-out infinite;
}

@keyframes notification-pulse {

    0%,
    100% {
        transform: scale(1);
    }

    50% {
        transform: scale(1.35);
    }
}

@keyframes notification-wave {
    0% {
        transform: translate(-50%, -50%) scale(1);
        opacity: 0.6;
    }

    100% {
        transform: translate(-50%, -50%) scale(2.5);
        opacity: 0;
    }
}

.addPostFlt {
    position: fixed;
    bottom: 70px;
    right: 46%;
    transform: translateX(50%);
    max-width: 512px;
    width: 100%;
    display: flex;
    justify-content: flex-end;
    padding-right: 20px;
    z-index: 999;
}

.addPostFlt a {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    height: 40px;
    background-color: var(--primary);
    color: white;
    border-radius: 50%;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.15);
    transition: all 0.3s ease;
}

.addPostFlt i {
    font-size: 0.8rem;
}

.addPostFlt a:hover {
    transform: scale(1.1);
    box-shadow: 0 6px 16px rgba(0, 0, 0, 0.2);
}

/* menu page */
.menuList {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.userStuff,
.shopStuff,
.termsStuff,
.sysStuff,
.searchStuff {
    background-color: var(--w);
    border: 1px solid var(--border);
    padding: 1rem;
    border-radius: 0.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.searchStuff i {
    transform: rotate(90deg);
}

.menuList i:not(.menuLogout i) {
    color: var(--hsvg);
    font-size: 1rem;
}

.menuList a,
.menuList p {
    font-size: 0.75rem;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.menuList a:not(.menuLogout) {
    color: var(--text-primary);
}

.menuLogout {
    color: var(--err);
    cursor: pointer;
}

.menuLogout i {
    font-size: 1rem;
}

.menuList p {
    color: gray;
}


.menuList a:not(:last-child) {
    border-bottom: 1px solid var(--border);
    padding-bottom: 1rem;
}

/* notifications page */
.notificationHeader {
    height: 57.45px;
}

.notificationList {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.notifItem {
    background-color: var(--w);
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    padding: 1rem;
}

.notifText {
    display: none;
}

.notificationList .feedUserMeta {
    position: relative;
}

.emptyNotification {
    font-size: 0.75rem;
    color: var(--hsvg);
    text-align: center;
}

.notification-icon {
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 0.8rem;
    position: absolute;
    top: 0;
    right: -9px;
}

.notification-icon.fa-heart {
    color: #E0245E;
}

.notification-icon.fa-comment {
    color: #1DA1F2;
}

.notification-icon.fa-at {
    color: #794BC4;
}

.notification-icon.fa-user-check {
    color: #17BF63;
}

.notification-icon.fa-repeat {
    color: #00BA7C;
}

.notification-icon.fa-reply {
    color: #657786;
}

.notifItem .feedHeaderAction {
    width: auto;
}

/* add post */
#addPostForm,
#editPostForm,
#repostForm {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin-bottom: 3rem;
}

#imagePreviewWrap {
    display: none;
    position: relative;
    border-radius: 0.5rem;
    overflow: hidden;
    background: #000;
}

#imagePreview {
    width: 100%;
    height: auto;
    display: block;
    /* max-height: 400px; */
    object-fit: contain;
}

#resizeImageBtn {
    cursor: pointer;
    font-family: var(--ff);
}

#removeImageBtn {
    position: absolute;
    top: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.7);
    color: var(--w);
    background-color: #80808042;
    border: none;
    border-radius: 50%;
    width: 32px;
    height: 32px;
    cursor: pointer;
    display: flex;
    align-items: center;
    justify-content: center;
    font-size: 18px;
    transition: background 0.2s;
}

#removeImageBtn:hover {
    background: rgba(229, 57, 53, 0.9);
}

#processCanvas {
    display: none;
}

.addPostTopOptions {
    display: flex;
    align-items: center;
    justify-content: space-between;
}

.characterCount {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.8rem;
    color: gray;
}

.imageInputLabel p {
    font-size: 0.75rem;
    height: 40px;
    padding: 0 1rem;
    display: flex;
    align-items: center;
    justify-content: center;
    background-color: var(--hsvg);
    color: var(--w);
    border-radius: 0.5rem;
    cursor: pointer;
}

#addPostForm textarea,
#editPostForm textarea,
#repostForm textarea {
    border: 1px solid var(--border);
    background-color: var(--w);
    padding: 1rem;
    border-radius: 0.5rem;
    outline: 0;
    font-family: var(--ff);
    font-size: 0.8rem;
    line-height: 1.8;
    min-height: 150px;
    color: var(--text-primary);
}

.postOptions {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    background-color: var(--w);
    padding: 1rem;
    border-radius: 0.5rem;
    border: 1px solid var(--border);
}

.premiumPostLabel {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-size: 0.75rem;
    color: var(--text-primary);
    cursor: pointer;
}

.is_premiumPost {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 0.5rem;
    font-size: 0.75rem;
    color: var(--text-primary);
}

#postCost {
    height: 40px;
    padding: 0.5rem;
    background-color: var(--bbg);
    border: 1px solid var(--border);
    outline: 0;
    border-radius: 0.5rem;
    color: var(--text-primary);
    font-size: 0.75rem;
    font-family: var(--ff);
    text-align: left;
    direction: ltr;
}

#addPostForm .postActions,
#editPostForm .postActions,
#repostForm .postActions {
    position: fixed;
    bottom: 0;
    left: 50%;
    transform: translateX(-50%);
    max-width: 512px;
    width: 100%;
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    background: var(--w);
    border: 1px solid var(--border);
    padding: 1rem;
    z-index: 100;
}

#addPostForm .postActions button,
#editPostForm .postActions button,
#repostForm .postActions button {
    height: 40px;
    width: 100%;
    padding: 0 1rem;
    border-radius: 0.5rem;
    border: 0;
    outline: 0;
    font-size: 0.8rem;
    font-family: var(--ff);
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
}

#addPostForm .postActions #submitBtn,
#editPostForm .postActions #submitBtn,
#repostForm .postActions #submitBtn {
    background-color: var(--primary);
    color: var(--w);
}

#addPostForm .postActions #backBtn,
#editPostForm .postActions #backBtn,
#repostForm .postActions #backBtn {
    background-color: var(--hsvg);
    color: var(--w);
}

/* repost */
.repostItem {
    border: 1px solid #eee;
    border-radius: 8px;
    overflow: hidden;
    background: white;
}

.repostHeader {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.75rem 1rem;
    font-size: 0.875rem;
    color: #666;
    background: #f9f9f9;
}

.repostHeader i {
    color: #00ba7c;
}

.repostHeader a {
    color: #333;
    font-weight: 600;
    text-decoration: none;
}

.repostHeader a:hover {
    text-decoration: underline;
}

.reposterContent {
    padding: 1rem;
    border-bottom: 1px solid #eee;
}

.reposterContent .feedContent {
    margin: 0;
}

.embeddedPostWrapper {
    border-radius: 0.5rem;
    background: #fafafa;
    border: 1px solid var(--border);
}

.embeddedPostWrapper .feedBody {
    padding: 0 1rem;
}

.embeddedPost {
    border-radius: 6px;
    overflow: hidden;
    position: relative;
    color: gray;
}

.embeddedPost .feedHeader {
    padding: 0.75rem 1rem;
}

.embeddedPost .feedBody {
    padding: 0 1rem 0.75rem;
}

.embeddedPost .feedFooter {
    padding: 0.5rem 1rem;
    border-top: 1px solid #f0f0f0;
}

.embeddedPost .feedLikeBtn.disabled,
.embeddedPost .feedRepostBtn.disabled {
    cursor: default;
    opacity: 0.6;
}

.embeddedPost .feedRepostBtn.disabled:hover {
    background: transparent;
}

.postBadges {
    width: 100%;
    display: flex;
    align-items: center;
    margin-bottom: -10px;
    gap: 0.35rem;
}

.postBadges i,
.postBadges p {
    font-size: 0.7rem;
    color: var(--hsvg);
}

.postBadges p {
    margin-left: 1rem;
}

/* Comment Styles */
.commentsSection {
    padding: 0 1rem;
    margin-bottom: 5rem;
}

.commentInputWrapper {
    display: flex;
    gap: 0.75rem;
    padding: 1rem;
    background: #f8f9fa;
    border-radius: 12px;

    position: fixed;
    z-index: 9;
    bottom: 0;

    width: 100%;
    max-width: 512px;

    left: 50%;
    transform: translateX(-50%);
    flex-wrap: wrap;

}

.reply-indicator {
    width: 100%;
    background: #e3e3e3;
    font-size: 0.75rem;
    padding: 0.25rem 0.5rem;
    display: flex;
    align-items: center;
    gap: 0.75rem;
    border-radius: 0.25rem;
    color: var(--text-primary);
}

.cancel-reply {
    width: 30px;
    background-color: transparent;
    border: 0;
    outline: 0;
    font-size: 1rem;
    font-weight: bold;
    cursor: pointer;
}

.commentInputWrapper textarea,
.commentInputWrapper .commentInput {
    flex: 1;
    height: 44px;
    padding: 0.75rem;
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    font-family: var(--ff);
    font-size: 0.75rem;
    resize: vertical;
    transition: border-color 0.2s;
    transition: height 0.5s;
}

.commentInputWrapper textarea:focus,
.commentInputWrapper .commentInput:focus {
    outline: none;
    border-color: #007bff;
    height: 100px;
}

.commentInputWrapper .btn {
    align-self: flex-start;
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.commentInputWrapper .btn-primary {
    background: var(--primary);
    color: var(--w);
    margin-top: auto;
    font-size: 0.75rem;
    font-family: var(--ff);
    cursor: pointer;
}

.commentsContainer {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

/* Comment Item */
.commentItem,
.commentReply {
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 12px;
    padding: 1rem;
    transition: all 0.3s;
}

.commentItem.comment-target {
    border-color: #007bff;
    box-shadow: 0 0 0 3px rgba(0, 123, 255, 0.1);
}

.commentItem.highlight {
    background: #fff3cd;
}

.commentReply {
    margin-right: 2rem;
    margin-top: 0.75rem;
    border-right: 3px solid #007bff;
}

/* Comment Header */
.commentHeader {
    display: flex;
    justify-content: space-between;
    align-items: flex-start;
    margin-bottom: 0.75rem;
}

.commentUserMeta {
    display: flex;
    gap: 0.75rem;
    text-decoration: none;
    color: inherit;
    flex: 1;
}

.commentUserAvatar {
    width: 40px;
    height: 40px;
    border-radius: 50%;
    overflow: hidden;
    flex-shrink: 0;
}

.commentUserAvatar img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.commentMeta {
    display: flex;
    flex-direction: column;
    gap: 0.25rem;
    flex: 1;
}

.userMeta {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.commentUserNickName {
    font-weight: 600;
    font-size: 0.95rem;
    color: #1a1a1a;
}

.commentUserName {
    font-size: 0.85rem;
    color: #666;
}

.commentTime {
    font-size: 0.8rem;
    color: #999;
}

/* .admin-badge,
.verified-badge {
    color: #007bff;
    font-size: 1rem;
    margin-right: 0.25rem;
}

.admin-badge {
    color: #dc3545;
} */

/* Comment Header Action */
.commentHeaderAction {
    position: relative;
}

.commentMenuBtn {
    padding: 0.5rem;
    cursor: pointer;
    color: #666;
    transition: color 0.2s;
}

.commentMenuBtn:hover {
    color: #1a1a1a;
}

.commentActionBox {
    position: absolute;
    left: 0;
    top: 100%;
    background: white;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    box-shadow: 0 4px 12px rgba(0, 0, 0, 0.1);
    min-width: 150px;
    z-index: 100;
    overflow: hidden;
    transition: opacity 0.2s, transform 0.2s;
}

.commentActionBox.hidden {
    display: none;
}

.commentActionBox button,
.commentActionBox a {
    display: block;
    width: 100%;
    padding: 0.75rem 1rem;
    border: none;
    background: none;
    text-align: right;
    cursor: pointer;
    font-size: 0.9rem;
    color: #333;
    text-decoration: none;
    transition: background 0.2s;
}

.commentActionBox button:hover,
.commentActionBox a:hover {
    background: #f8f9fa;
}

.comment-delete-btn {
    color: #dc3545;
}

.comment-report-btn {
    color: #ffc107;
}

/* Comment Body */
.commentBody {
    margin-bottom: 0.75rem;
}

.replyToBox {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem;
    background: #f8f9fa;
    border-radius: 6px;
    margin-bottom: 0.5rem;
    font-size: 0.85rem;
}

.replyToBox i {
    color: #007bff;
}

.replyToUser {
    color: #007bff;
    text-decoration: none;
    font-weight: 500;
}

.replyToUser:hover {
    text-decoration: underline;
}

.replyToContent {
    color: #666;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
    max-width: 200px;
}

.commentContent {
    font-size: 0.95rem;
    line-height: 1.6;
    color: #333;
    word-wrap: break-word;
}

.edited-badge {
    font-size: 0.8rem;
    color: #999;
    font-style: italic;
    margin-right: 0.5rem;
}

/* Comment Footer */
.commentFooter {
    display: flex;
    gap: 1rem;
}

.commentReplyBtn {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    padding: 0.5rem 1rem;
    border: none;
    background: #f8f9fa;
    border-radius: 6px;
    cursor: pointer;
    font-size: 0.85rem;
    color: #666;
    transition: all 0.2s;
}

.commentReplyBtn:hover {
    background: #e9ecef;
    color: #333;
}

.commentReplyBtn i {
    font-size: 0.9rem;
}

/* Comment Replies Container */
.commentReplies {
    margin-top: 1rem;
    display: flex;
    flex-direction: column;
    gap: 0.75rem;
}

/* Modal Styles */
.modal {
    display: none;
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background: rgba(0, 0, 0, 0.5);
    z-index: 1000;
    align-items: center;
    justify-content: center;
}

.modal.modal-show {
    display: flex;
}

/* .modal-content {
    background: white;
    border-radius: 12px;
    padding: 2rem;
    max-width: 500px;
    width: 90%;
    box-shadow: 0 8px 24px rgba(0, 0, 0, 0.2);
} */

.modal-content textarea {
    width: 100%;
    min-height: 100px;
    padding: 0.75rem;
    border: 1px solid #e0e0e0;
    border-radius: 8px;
    font-family: inherit;
    font-size: 0.95rem;
    resize: vertical;
    margin-bottom: 1rem;
}

.modal-content textarea:focus {
    outline: none;
    border-color: #007bff;
}

.modal-content p {
    font-size: 1rem;
    color: #333;
    margin-bottom: 1.5rem;
    text-align: center;
}

.modal-actions {
    display: flex;
    gap: 0.75rem;
    justify-content: flex-end;
}

.modal-actions .btn {
    padding: 0.75rem 1.5rem;
    border: none;
    border-radius: 8px;
    font-weight: 500;
    cursor: pointer;
    transition: all 0.2s;
}

.btn-danger {
    background: #dc3545;
    color: white;
}

.btn-danger:hover {
    background: #c82333;
}

.btn-secondary {
    background: #6c757d;
    color: white;
}

.btn-secondary:hover {
    background: #5a6268;
}

/* Load More Trigger */
#comments-load-more-trigger {
    height: 1px;
    margin-top: 2rem;
}

/* کامنت */
.singlePostFeed {
    margin-bottom: 0;
}


/* ================================
   Header
================================ */

/* Hidden class — important */
.hidden {
    display: none !important;
}

/* ================================
   Reply Info
================================ */
.comment-reply-badge {
    display: inline-block;
    background: #eef5ff;
    color: #2c73d2;
    padding: 4px 10px;
    font-size: 13px;
    border-radius: 6px;
    margin-bottom: 8px;
}

/* Parent comment preview */
.comment-parent-summary {
    background: #f9f9f9;
    padding: 10px;
    border-right: 3px solid #ccc;
    border-radius: 8px;
    margin-bottom: 10px;
    font-size: 13px;
    color: #555;
}

/* ================================
   Content
================================ */
.comment-body {
    margin-top: 10px;
}

.comment-content {
    font-size: 15px;
    line-height: 1.7;
    color: #333;
    margin: 8px 0;
}

/* ================================
   Footer Buttons
================================ */
/* .comment-footer {
    margin-top: 6px;
} */

.comment-reply-btn {
    background: transparent;
    border: 0;
    outline: 0;
    color: var(--hsvg);
    font-size: 0.75rem;
    width: 44px;
    display: flex;
    align-items: center;
    gap: 0.5rem;
    font-family: var(--ff);
    cursor: pointer;
}

/* ================================
   Loader
================================ */
.comments-loader {
    display: flex;
    justify-content: center;
    padding: 16px;
}

.spinner {
    width: 26px;
    height: 26px;
    border: 3px solid #ddd;
    border-top-color: #0077ff;
    border-radius: 50%;
    animation: spin 0.6s linear infinite;
}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

.reply-banner {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    gap: 1rem;
    background: #fafafa;
    border: 1px solid var(--border);
    padding: 1rem;
    border-radius: 0.5rem;
}

.reply-content {
    display: flex;
    align-items: center;
}

.reply-content .parent-summary {
    font-size: 0.8rem;
    color: gray;
    line-height: 1.8;
}

/* ================================
   Error Box
================================ */
.comments-error {
    background: #ffe5e5;
    padding: 12px;
    border-radius: 8px;
    color: #b30000;
    text-align: center;
    margin-top: 15px;
    font-size: 15px;
}

/* Comment Modals - Unique Styles */
.cmt-modal-overlay {
    position: fixed;
    top: 0;
    left: 0;
    width: 100%;
    height: 100%;
    background-color: rgba(0, 0, 0, 0.6);
    display: flex;
    align-items: center;
    justify-content: center;
    z-index: 10000;
    backdrop-filter: blur(4px);
}

.cmt-modal-container {
    background: var(--w);
    border-radius: 0.5rem 0.5rem 0 0;
    width: 100%;
    max-width: 500px;
    box-shadow: 0 10px 40px rgba(0, 0, 0, 0.2);
    animation: cmtModalSlideIn 0.3s ease;
    position: absolute;
    bottom: 0;
}

@keyframes cmtModalSlideIn {
    from {
        opacity: 0;
        transform: translateY(-30px);
    }

    to {
        opacity: 1;
        transform: translateY(0);
    }
}

.cmt-modal-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding: 20px 24px;
    border-bottom: 1px solid #e5e7eb;
}

.cmt-modal-body {
    padding: 24px;
}

.cmt-delete-message {
    font-size: 0.8rem;
    color: #374151;
    line-height: 1.6;
    margin: 0;
}

.cmt-form-label {
    display: block;
    font-size: 14px;
    font-weight: 500;
    color: #374151;
    margin-bottom: 8px;
}

.cmt-form-textarea {
    width: 100%;
    padding: 12px;
    border: 1px solid #d1d5db;
    border-radius: 8px;
    font-size: 14px;
    font-family: inherit;
    resize: vertical;
    transition: border-color 0.2s;
}

.cmt-form-textarea:focus {
    outline: none;
    border-color: #3b82f6;
    box-shadow: 0 0 0 3px rgba(59, 130, 246, 0.1);
}

.cmt-error-message {
    margin-top: 8px;
    padding: 8px 12px;
    background-color: #fef2f2;
    border: 1px solid #fecaca;
    border-radius: 6px;
    color: #dc2626;
    font-size: 13px;
}

.cmt-modal-footer {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    padding: 16px 24px;
}

/* Character Counter */
.cmt-char-counter {
    text-align: left;
    font-size: 12px;
    color: #6b7280;
    margin-top: 4px;
}

.cmt-char-counter span {
    font-weight: 500;
    color: #374151;
}

/* Edited Badge */
.comment-edited-badge {
    font-size: 11px;
    color: #6b7280;
    font-style: italic;
    margin-right: 8px;
}

.resizeImageBtn {
    position: absolute;
    bottom: 10px;
    left: 10px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    border: none;
    border-radius: 6px;
    padding: 6px 12px;
    font-size: 13px;
    cursor: pointer;
    transition: background 0.2s;
}

#rotateImageBtn {
    position: absolute;
    bottom: 10px;
    right: 10px;
    background: rgba(0, 0, 0, 0.7);
    color: white;
    border: none;
    border-radius: 6px;
    padding: 6px 12px;
    font-size: 13px;
    cursor: pointer;
    transition: background 0.2s;
}

.resizeImageBtn:hover {
    background: rgba(0, 0, 0, 0.85);
}

.resizeImageBtn:disabled {
    opacity: 0.5;
    cursor: not-allowed;
}

.highlighted-comment {
    
    animation: highlight-fade 3s ease-out;
}

@keyframes highlight-fade {
    0% {
        background: rgba(255, 215, 0, 0.3);
    }

    100% {
        background: var(--w);
    }
}


/* read more */
.feedContent.collapsed {
    display: -webkit-box;
    -webkit-line-clamp: 4;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.show-more-btn {
    background: none;
    border: none;
    color: gray;
    cursor: pointer;
    font-size: 0.75rem;
    padding: 4px 0;
    font-family: var(--ff);
    text-align: right;
}

/* toast */
.toast {
    position: fixed;
    top: 16px;
    left: 50%;
    transform: translateX(-50%);
    font-size: 0.75rem;
    color: var(--w);
    padding: 0.5rem 1rem;
    border-radius: 0.25rem;
}

.toast-success {
    background-color: #2ECC71;
}

.toast-error {
    background-color: var(--err);
}

/* profile */
.profilePage {

    display: flex;

    flex-direction: column;

    gap: 1rem;
    padding: 0 1rem;

}



.profileBanner {

    width: 100%;

    height: 120px;

    overflow: hidden;

    border-radius: 0.5rem;

    display: flex;

    align-items: center;

    justify-content: center;

    background-color: gray;

}



.profileBanner img {

    width: 100%;

    height: 100%;

    object-fit: cover;

}



.profileInfo {

    display: flex;

    align-items: center;

    justify-content: space-between;

    background-color: var(--w);

    border: 1px solid var(--border);

    border-radius: 0.5rem;

    padding: 1rem;

}



.profileUserMeta {

    display: flex;

    align-items: center;

    gap: 0.5rem;

}

.profileUserNameId {
    display: flex;
    flex-direction: column;
    align-items: flex-start;
    max-width: 150px;
    overflow: hidden;
    white-space: nowrap;
    position: relative;
}

.profileUserNameId .userNickName {

    font-size: 0.85rem;

    color: var(--text-primary);
    

}

.profileUserNameId .userNickName.animate-marquee {
    animation: marquee 5s linear infinite;
}


@keyframes marquee {
    0%, 20% {
        transform: translateX(0);
    }
    80%, 100% {
        transform: translateX(calc(100% + 100px));
    }
}




.profileUserNameId .userUserName {

    font-size: 0.8rem;

    color: gray;

    direction: ltr;

}



.profileUserImgPlaceholder {

    width: 60px;

    height: 60px;

    border-radius: 50%;

    display: flex;

    align-items: center;

    justify-content: center;

    position: relative;

}



.profileUserImg {

    width: 60px;

    height: 60px;

    border-radius: 50%;

    display: flex;

    align-items: center;

    justify-content: center;

    overflow: hidden;

}



.profileUserImg img {

    width: 100%;

    height: auto;

    object-fit: cover;

}



.profileUserImgPlaceholder .userBadge {

    top: -2px;

    right: -2px;

}



.profileUserFollow {

    height: 40px;

    width: 100%;

    display: flex;

    align-items: center;

    justify-content: center;

    background-color: var(--primary);

    border-radius: 0.5rem;

    cursor: pointer;

    border: 0;

    outline: 0;

    color: var(--w);

    font-size: 0.8rem;

    font-family: var(--ff);

}



.profileUserCounter {

    display: flex;

    align-items: center;

    justify-content: space-between;

    gap: 1rem;

}



.profileUserCounter div {

    background-color: var(--w);

    border: 1px solid var(--border);

    border-radius: 0.5rem;

    width: 100%;

    height: 80px;

    display: flex;

    flex-direction: column;

    align-items: center;

    justify-content: center;

    font-size: 0.8rem;

    color: gray;

}



.profileUserCounter .profileUserCounterCount {

    font-weight: bold;

    font-size: 1.2rem;

    color: var(--text-primary);

}



.profileBlockMsg {

    display: flex;

    align-items: center;

    justify-content: center;

    color: gray;

    font-size: 0.875rem;

    margin: 2rem 0;

}



.userPoints {

    display: flex;

    flex-direction: column;

    align-items: center;

}



.userPointsT {

    display: flex;

    align-items: center;

    justify-content: center;

}



.userPointsT svg {

    width: 20px;

    height: auto;

    color: #FFD700;

}



.userPointsN {

    font-size: 0.85rem;

    color: gray;

    font-weight: bold;

    letter-spacing: 1px;

}



.profileUserBtns {

    display: flex;

    align-items: center;

    justify-content: space-between;

    gap: 1rem;

}



.profileBlockBtn {

    display: flex;

    align-items: center;

    justify-content: center;

    width: 100%;

    height: 40px;

    font-family: var(--ff);

    font-size: 0.8rem;

    border: 0;

    outline: 0;

    border-radius: 0.5rem;

    cursor: pointer;

}



.profileBlockBtn[data-action="block"] {

    background: var(--err);

    color: var(--w);

    width: 80px;

}



.profileBlockBtn[data-action="unblock"] {

    background: var(--err);

    color: var(--w);

}



.profileUserBio {

    background-color: var(--w);

    border: 1px solid var(--border);

    border-radius: 0.5rem;

    width: 100%;

    padding: 1rem;

    font-size: 0.8rem;

    color: var(--text-primary);

    position: relative;

    overflow: hidden;

}



.profileUserBio p {

    position: relative;

    z-index: 2;

}



.profileUserBio::after {

    content: '“';

    top: 45px;

    left: 0;

    transform: translate(50%, -50%);

    color: lightgray;

    font-size: 4rem;

    position: absolute;

}



.profileUserPostsContainer {

    display: flex;

    flex-direction: column;

    gap: 1rem;

}

.followlistPage {
    padding: 1rem;
}

.follow-list-header {
    background: var(--w);

    border: 1px solid var(--border);

    padding: 1rem;

    display: flex;

    align-items: center;

    justify-content: space-between;
    width: 100%;
    max-width: 512px;
    margin: 0 auto;

}



.follow-list-header h1 {

    font-size: 0.875rem;
    color: var(--hsvg);

}

.follow-list-header a i {
    color: var(--hsvg);
    font-size: 1.1em;
}

.tabs {

    display: flex;

    background: var(--w);

    border: 1px solid var(--border);
    border-radius: 0.5rem 0.5rem 0 0;

}

.tabs a {

    flex: 1;

    text-align: center;

    padding: 12px 0;

    text-decoration: none;

    color: gray;

    font-size: 0.85rem;

    font-weight: normal;

    border-bottom: 2px solid transparent;

    transition: .2s;

}

.tabs a.active {

    color: #262626;

    border-bottom-color: #262626;

}



#followList {

    display: flex;

    flex-direction: column;

    gap: 1rem;

    margin: 1rem 0;

}



.follow-item {

    display: flex;

    align-items: center;

    justify-content: space-between;

    background-color: var(--w);

    border: 1px solid var(--border);

    border-radius: 0.5rem;

    padding: 1rem;

}



.follow-item a {

    display: flex;

    align-items: center;

    gap: 0.5rem;

}

.follow-item .postProfileImgPlaceholder {
    display: flex;
    align-items: center;
}

.follow-item .postProfileImg {
    width: 35px;
    height: 35px;
    border-radius: 50%;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.follow-item .postProfileImg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.follow-item .postUserDetails {
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.follow-item .pudetailMeta {
    line-height: 1.2;
    display: flex;
    flex-direction: column;
    align-items: flex-start;
}

.follow-item .postUserName {
    font-size: 0.8rem;
    color: var(--text-primary);
    max-width: 100px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

.follow-item .postUsername {
    font-size: 0.8rem;
    color: gray;
    direction: ltr;
    max-width: 100px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;
}

#followList .pufbtn {

    height: 30px;

    width: 90px;

    display: flex;

    align-items: center;

    justify-content: center;

    border-radius: 0.5rem;

    font-size: 0.7rem;

    font-family: var(--ff);

    cursor: pointer;

    transition: .2s;

    white-space: nowrap;

    outline: 0;

}



.pufbtn--unfollow {

    background: var(--w);

    color: #262626;

    border: 1px solid var(--primary);

}



.pufbtn--follow {

    background: var(--primary);
    border: 0;
    color: var(--w);

}



.pufbtn:hover {
    opacity: .85;
}

.pufbtn:disabled {
    opacity: 0.6;
    cursor: not-allowed;
}



.empty-state {

    text-align: center;

    padding: 60px 20px;

    color: #8e8e8e;

    font-size: 14px;

}



.loading {

    text-align: center;

    padding: 40px;

    color: #8e8e8e;

}

.loading::after {

    content: '';

    display: inline-block;

    width: 24px;

    height: 24px;

    border: 3px solid #dbdbdb;

    border-top-color: #262626;

    border-radius: 50%;

    animation: spin .6s linear infinite;

}

@keyframes spin {
    to {
        transform: rotate(360deg);
    }
}

/* profile edit */
.profileEditPage {
    margin-bottom: 4rem;
    padding: 0 1rem;
}

.profileEditPage .profileBanner,

.profileEditPage .profileUserImgPlaceholder {

    position: relative;

}



.profileEditPage #changeBannerBtn,

.profileEditPage #changeAvatarBtn {

    position: absolute;

    top: 50%;

    right: 50%;

    transform: translate(50%, -50%);

    width: 40px;

    height: 40px;

    border-radius: 50%;

    border: 0;

    outline: 0;

    background-color: #33333394;
    cursor: pointer;

}



.profileEditPage #changeBannerBtn svg {

    color: var(--w);

}



.profileEditPage .profileUserMeta {

    display: flex;

    align-items: center;

    justify-content: space-between;

    width: 100%;

    gap: 3rem;

}



.profileEditPage .profileUserImgPlaceholder, 

.profileEditPage .profileUserImg {

    width: 80px;

    height: 80px;

}



.profileEditPage .predpr {

    background: var(--tipbg);

    color: var(--tipb);

    padding: 0.5rem 1rem;

    border: 1px solid var(--tipb);

    border-radius: 0.5rem;

    font-size: 0.8rem;

}



.profileEditPage .label p {

    font-size: 0.7rem;

    color: gray;

    margin-bottom: 0.25rem;

}



.profileEditPage input, .profileEditPage textarea {

    height: 40px;

    width: 100%;

    padding: 0.5rem 1rem;

    background-color: var(--w);

    border: 1px solid var(--border);

    border-radius: 0.5rem;

    font-size: 0.8rem;

    font-family: var(--ff);

}



.profileEditPage input:read-only {

    background-color: #d3d3d340;

    color: gray;

}



.profileEditPage input::placeholder, .profileEditPage textarea::placeholder {

    font-size: 0.75rem;

    color: gray;

}



.profileEditPage textarea {

    height: 100px;

    line-height: 1.8;

}



.profileEditPass {

    display: flex;

    flex-direction: column;

    gap: 1rem;

}



.fixedSaveBtn {

    position: fixed;

    bottom: 0;

    left: 50%;

    transform: translateX(-50%);

    z-index: 9999;

    width: 100%;

    max-width: 496px;

    height: 40px;

    background: var(--primary);

    color: var(--w);

    border: 0;

    outline: 0;

    border-radius: 0.5rem 0.5rem 0 0;

    font-family: var(--ff);

    font-size: 0.875rem;

    cursor: pointer;

}

/* leader board */
.searchPage {
    padding: 0 1rem;
}

.leaderTitle {

    display: flex;

    align-items: center;

    gap: 0.5rem;

    color: var(--text-primary);

    font-size: 0.875rem;

}



.allLeader {

    display: flex;

    flex-direction: column;

    gap: 1rem;

    margin: 1rem 0;

}



.allLeader .rank {

    color: var(--text-primary);

}



.leader-item {

    display: flex;

    align-items: center;

    justify-content: space-between;

    gap: 0.5rem;

    padding: 0.5rem 1rem;

    border: 1px solid var(--border);

    background-color: var(--w);

    border-radius: 0.5rem;

}



.leaderItemImg {

    width: 40px;

    height: 40px;

    display: flex;

    align-items: center;

    justify-content: center;

    border-radius: 50%;

    overflow: hidden;

    margin-left: auto;

    margin-right: 1rem;

}



.leaderItemImg img {

    width: 100%;

    height: 100%;

    object-fit: cover;

}



.leader-item .user-info {

    margin-left: auto;

    display: flex;

    flex-direction: column;

    align-items: flex-start;

    line-height: 1.2;

}



.leader-item .name {

    font-size: 0.85rem;

    color: var(--text-primary);
    max-width: 100px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;

}



.leader-item .username {

    font-size: 0.75rem;

    color: gray;

    direction: ltr;
    max-width: 100px;
    overflow: hidden;
    text-overflow: ellipsis;
    white-space: nowrap;

}



.leader-item .points {

    display: flex;

    align-items: center;

    gap: 0.3rem;

    color: gray;

    font-size: 0.8rem;

}



.leader-item .points svg {

    width: 20px;

    color: #FFD700; 

}



.allLeader .leader-item .rank {

    width: 20px;

    height: 20px;

    display: flex;

    align-items: center;

    justify-content: center;

    border-radius: 50%;

}



.allLeader .leader-item:nth-child(1) {

    /* background: linear-gradient(135deg, #FFD700, #FFA500);

    color: #fff;

    font-weight: bold;

    box-shadow: 0 4px 15px rgba(255, 215, 0, 0.4); */

    border: 3px solid #FFD700;

}



.allLeader .leader-item:nth-child(2) {

    /* background: linear-gradient(135deg, #C0C0C0, #A8A8A8);

    color: #fff;

    font-weight: bold;

    box-shadow: 0 4px 15px rgba(192, 192, 192, 0.4); */

    border: 2px solid #C0C0C0;

}



.allLeader .leader-item:nth-child(3) {

    /* background: linear-gradient(135deg, #CD7F32, #8B4513);

    color: #fff;

    font-weight: bold;

    box-shadow: 0 4px 15px rgba(205, 127, 50, 0.4); */

    border: 2px solid #CD7F32;

}



.leader-item.current-user {

    border: 2px solid var(--primary);

}

.footerSearch {
    display: flex;
    align-items: center;
    justify-content: center;
    width: 40px;
    background: transparent;
    border: 0;
    outline: 0;
    cursor: pointer;
}

.footerSearch i {
    color: var(--hsvg);
    font-size: 1rem;
}

/* search */

.searchHeader {
    width: 100%;
    max-width: 512px;
    margin: 0 auto;
    display: flex;
    align-items: center;
    gap: 10px;
    padding: 12px 16px;
    border: 1px solid var(--border);
    position: sticky;
    top: 0;
    background: #fff;
    z-index: 10;
}

.searchInputWrapper {

    flex: 1;

}



.searchInput {

    width: 100%;

    border: 1px solid #ddd;

    border-radius: 0.5rem;

    padding: 9px 16px;

    font-size: 0.85rem;

    outline: none;

    background: #f5f5f5;

    transition: all 0.2s;

    font-family: var(--ff);

    text-align: right;

}


.searchInput:focus {

    border-color: #aaa;

    background: #fff;

}

.searchResults {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    margin: 1rem 0;
}

.searchUserItem {
    display: flex;
    align-items: center;
    gap: 0.5rem;
    background-color: var(--w);
    padding: 1rem;
    border-radius: 0.5rem;
    border: 1px solid var(--border);
}

.searchUserItem .postProfileImg {
    width: 40px;
    height: 40px;
    display: flex;
    align-items: center;
    justify-content: center;
    overflow: hidden;
    border-radius: 50%;
}

.searchUserItem .postProfileImg img {
    width: 100%;
    height: 100%;
    object-fit: cover;
}

.searchUserItem .postUserName {
    color: var(--text-primary);
    font-size: 0.8rem;
}

.searchUserItem .postUsername {
    color: var(--hsvg);
    font-size: 0.75rem;
    direction: ltr;
    display: flex;
    justify-content: flex-end;
}

/* ─── States ─── */

.searchInitial,

.searchEmpty,

.searchLoading {

    display: flex;

    flex-direction: column;

    align-items: center;

    justify-content: center;

    gap: 12px;

    padding: 60px 16px;

    color: #bbb;

    font-size: 14px;

}



.searchLoading .spinner {

    width: 32px;

    height: 32px;

    border: 3px solid #eee;

    border-top-color: #888;

    border-radius: 50%;

    animation: spin 0.7s linear infinite;

}



@keyframes spin {

    to { transform: rotate(360deg); }

}



/* ─── Load more spinner ─── */

.loadMoreSpinner {

    display: flex;

    justify-content: center;

    padding: 16px;

}



.loadMoreSpinner .spinner {

    width: 24px;

    height: 24px;

    border: 2px solid #eee;

    border-top-color: #888;

    border-radius: 50%;

    animation: spin 0.7s linear infinite;

}



#searchSentinel {

    height: 1px;

}

/* login & register */
.loginPage {
    min-height: 100vh;
    display: flex;
    align-items: center;
    justify-content: center;
}

.register_container {
    display: flex;
    flex-direction: column;
    align-items: center;
    gap: 1rem;
    width: 100%;
}

.register_logo {
    width: 80px;
    height: auto;
    overflow: hidden;
    display: flex;
    align-items: center;
    justify-content: center;
}

.register_logo img {
    width: 100%;
}

.register_form {
    display: flex;
    flex-direction: column;
    gap: 1rem;
    width: 100%;
}

.register_form small {
    text-align: center;
    color: red;
    font-size: 0.8rem;
}

.register_form label {
    /* margin-bottom: -1rem; */
    color: gray;
    font-size: 0.7rem;
}

.lru {
    position: relative;
    width: 100%;
}

.register_form input {
    background-color: var(--w);
    padding: 0.5rem 1rem;
    border: 1px solid var(--border);
    border-radius: 0.5rem;
    height: 40px;
    color: var(--text-primary);
    font-size: 0.85rem;
    font-family: var(--ff);
    width: 100%;
}

.register_form button {
    background-color: var(--primary);
    height: 40px;
    border-radius: 0.5rem;
    color: var(--w);
    font-size: 0.8rem;
    font-family: var(--ff);
    cursor: pointer;
    border: 0;
    outline: 0;
}

.loginFooter {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 1rem;
    margin-top: 1rem;
}

.loginFooter a {
    color: var(--primary);
    font-size: 0.8rem;
}

/* terms */
.termsPage {
    padding: 1rem;
    margin-bottom: 2rem;
}

.termsPage .topHeader {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 2rem;
}

.termsPage .termsHeader {
    display: flex;
    align-items: center;
}

.termsHeader img {
    width: 60px;
    height: auto;
}

.termsPage .createAcc {
    font-size: 0.9rem;
    color: var(--primary);
}

.termsPage h1 {
    font-size: 1rem;
    margin-bottom: 1rem;
    color: var(--text-primary);
}

.termsPage h2 {
    font-size: 0.9rem;
    margin: 1rem 0 0.5rem 0;
    color: var(--text-primary);
}

.termsPage p, .termsPage ul {
    font-size: 0.8rem;
    color: var(--text-primary);
    line-height: 1.8;
}

.termsPage ul {
    margin: 0.5rem 2rem 0.5rem 0;

}

.termsPage hr {
    border: 0;
    border-top: 1px solid var(--border);
    margin: 0.75rem 0;
}

/* shop */
.shopPage {
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.packageShopTitle {
    background-color: var(--w);
    border: 1px solid var(--border);
    padding: 1rem;
    border-radius: 0.5rem;
    display: flex;
    flex-direction: column;
    gap: 1rem;
}

.shopPackageTitle {
    color: var(--text-primary);
    font-size: 1.1rem;
}

.packageShopTitle ul {
    margin: 0 0.75rem;
}

.packageShopTitle li {
    color: var(--text-primary);
    font-size: 0.8rem;
    padding: 0.25rem 0;
}

.shopCard {
    display: flex;
    align-items: center;
    flex-wrap: wrap;
    gap: 20px;
    background: linear-gradient(135deg, #667eea 0%, #764ba2 100%);
    border-radius: 16px;
    padding: 20px 24px;
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.shopCard-silver {
    background: linear-gradient(135deg, #c0c0c0 0%, #808080 100%);
}

.shopCard-diamond {
    background: linear-gradient(135deg, #00d4ff 0%, #0099cc 100%);
}

.shopCard-premium {
    background: linear-gradient(135deg, #ff6b6b 0%, #ee5a24 100%);
    border: 1px solid rgba(255, 215, 0, 0.3);
}

.coin-badge {
    width: 60px;
    height: 60px;
    background: linear-gradient(135deg, #ffd700, #ffed4e);
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    flex-shrink: 0;
}

.coin-badge i {
    font-size: 28px;
    color: #ff6b35;
}

.coin-badge-silver {
    background: linear-gradient(135deg, #e8e8e8, #b8b8b8);
}

.coin-badge-silver i {
    color: #606060;
}

.coin-badge-diamond {
    background: linear-gradient(135deg, #b3f5ff, #4dd0e1);
}

.coin-badge-diamond i {
    color: #006d8f;
}

.coin-badge-premium {
    background: linear-gradient(135deg, #ffd700, #ff8c00);
}

.coin-badge-premium i {
    color: #8b0000;
}

.card-content {
    flex: 1;
    text-align: right;
}

.shopCard h2 {
    font-size: 24px;
    font-weight: 700;
    color: #fff;
    margin: 0 0 4px 0;
}

.coin-label {
    font-size: 13px;
    color: rgba(255, 255, 255, 0.75);
    margin: 0;
    font-weight: 500;
}

.buy-btn {
    background: rgba(255, 255, 255, 0.25);
    border: 1px solid rgba(255, 255, 255, 0.3);
    color: #fff;
    padding: 10px 24px;
    border-radius: 12px;
    font-size: 15px;
    font-weight: 600;
    cursor: pointer;
    display: inline-flex;
    align-items: center;
    gap: 8px;
    flex-shrink: 0;
    font-family: var(--ff);
}

/* shop lock */
/* بسته یک ماهه */
.shopCard-lock {
    background: linear-gradient(135deg, #a855f7 0%, #7c3aed 100%);
}

/* بسته سه ماهه */
.shopCard-lock-premium {
    background: linear-gradient(135deg, #ec4899 0%, #be185d 100%);
    border: 1px solid rgba(236, 72, 153, 0.4);
}

/* بج قفل یک ماهه */
.coin-badge-lock {
    background: linear-gradient(135deg, #c084fc, #a855f7);
}

.coin-badge-lock i {
    color: #581c87;
}

/* بج قفل سه ماهه */
.coin-badge-lock-premium {
    background: linear-gradient(135deg, #fbbf24, #f59e0b);
}

.coin-badge-lock-premium i {
    color: #92400e;
}

/* shop character long */
/* بسته افزایش کاراکتر */
.shopCard-character {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
}

.coin-badge-character {
    background: linear-gradient(135deg, #6ee7b7, #34d399);
}

.coin-badge-character i {
    color: #064e3b;
}

/* اضافه کن به فایل CSS */

.buy-btn.purchased,
.buy-btn.subscribed {
    background: linear-gradient(135deg, #10b981 0%, #059669 100%);
    cursor: default;
    pointer-events: none;
    width: 100%;
}

.buy-btn.purchased span,
.buy-btn.subscribed span {
    font-weight: 600;
}

.buy-btn small {
    display: block;
    font-size: 0.75rem;
    opacity: 0.9;
}

/* order page */

.transactions-page {
    padding: 0 1rem;
}

.transactions-header {
    margin-bottom: 30px;
}

.transactions-header h1 {
    font-size: 0.9rem;
    font-weight: normal;
    color: var(--text-primary);
    background: var(--w);
    border: 1px solid var(--border);
    padding: 0.5rem 1rem;
    border-radius: 0.5rem;
}

.transactions-container {
    display: flex;
    flex-direction: column;
    gap: 15px;
    margin-bottom: 2rem;
}

.transaction-item {
    background: #fff;
    border: 1px solid var(--border);
    border-radius: 0.5rem 0 0 0.5rem;
    padding: 15px;
    transition: box-shadow 0.2s;
}

.transaction-item:hover {
    box-shadow: 0 2px 8px rgba(0,0,0,0.1);
}

.transaction-header {
    display: flex;
    justify-content: space-between;
    align-items: center;
    margin-bottom: 10px;
}

.transaction-type {
    font-weight: 600;
    font-size: 0.9rem;
    color: #555;
}

.transaction-amount {
    font-weight: bold;
    font-size: 0.9rem;
    direction: ltr;
    display: flex;
    align-items: center;
    gap: 0.5rem;
}

.tadiv {
    direction: ltr;
}

.amount-positive {
    color: #22c55e;
}

.amount-negative {
    color: #ef4444;
}

.transaction-body {
    margin-bottom: 10px;
}

.transaction-description {
    color: #666;
    font-size: 0.8rem;
    margin: 0.75rem 0;
}

.transaction-post-link {
    color: var(--primary);
    text-decoration: none;
    font-size: 0.8rem;
}

.transaction-post-link:hover {
    text-decoration: underline;
}

.transaction-footer {
    display: flex;
    justify-content: space-between;
    align-items: center;
    padding-top: 10px;
    border-top: 1px solid #f0f0f0;
}

.transaction-date {
    font-size: 12px;
    color: #999;
}

.transaction-id {
    font-size: 12px;
    color: #bbb;
}

/* رنگ‌بندی براساس نوع */
.transaction-unlock {
    border-right: 4px solid #ef4444;
}

.transaction-income {
    border-right: 4px solid #22c55e;
}

.transaction-purchase {
    border-right: 4px solid #f59e0b;
}

.transaction-admin {
    border-right: 4px solid #8b5cf6;
}

.transaction-reward {
    border-right: 4px solid #06b6d4;
}

.transaction-other {
    border-right: 4px solid #6b7280;
}

.loader {
    display: flex;
    justify-content: center;
    padding: 40px;
}

.spinner {
    width: 40px;
    height: 40px;
    border: 4px solid #f3f3f3;
    border-top: 4px solid #3b82f6;
    border-radius: 50%;
    animation: spin 1s linear infinite;
}

@keyframes spin {
    0% { transform: rotate(0deg); }
    100% { transform: rotate(360deg); }
}

.empty-state {
    text-align: center;
    padding: 60px 20px;
    color: #999;
}

.load-more-btn {
    display: block;
    width: 100%;
    max-width: 300px;
    margin: 30px auto;
    padding: 12px 24px;
    background: var(--primary);
    color: white;
    border: none;
    border-radius: 8px;
    font-size: 0.8rem;
    font-family: var(--ff);
    cursor: pointer;
    transition: background 0.2s;
}

.load-more-btn:hover {
    background: var(--btn-hover);
}

.load-more-btn:disabled {
    background: #cbd5e1;
    cursor: not-allowed;
}
