/*
Theme Name: RomanLux | رومان لوکس
Theme URI: https://yourdomain.com
Author: اختصاصی رمان
Description: قالب فوق‌حرفه‌ای و لوکس رمان و کتاب الکترونیک با سیستم اشتراک، کیف پول و درگاه مستقیم
Version: 1.0.0
Text Domain: romanlux
*/

:root {
  --primary: #e91e63;
  --primary-hover: #c2185b;
  --secondary: #9c27b0;
  --accent: #ff4081;
  --gold: #f59e0b;
  --bg: #fff5f7;
  --card-bg: #ffffff;
  --text: #2c3e50;
  --text-muted: #7f8c8d;
  --border: #f3d5dd;
  --radius: 18px;
  --shadow: 0 10px 30px rgba(233, 30, 99, 0.08);
}

body.dark-mode {
  --bg: #121217;
  --card-bg: #1e1e26;
  --text: #f0f0f5;
  --text-muted: #a0a0b2;
  --border: #2d2d3a;
  --shadow: 0 10px 30px rgba(0, 0, 0, 0.3);
}

* {
  box-sizing: border-box;
  margin: 0;
  padding: 0;
  font-family: -apple-system, BlinkMacSystemFont, "Segoe UI", Roboto, "Vazirmatn", Tahoma, sans-serif;
}

body {
  background-color: var(--bg);
  color: var(--text);
  direction: rtl;
  text-align: right;
  line-height: 1.7;
  transition: background 0.3s, color 0.3s;
}

a {
  text-decoration: none;
  color: inherit;
}

.container {
  max-width: 1240px;
  margin: 0 auto;
  padding: 0 20px;
}
/* ======================================================
   استایل‌های مدرن صفحه اصلی و کارت‌های رمان (RomanLux)
   ====================================================== */

/* نوار دسته‌بندی‌ها (ژانرها) */
.genres-bar {
  display: flex;
  gap: 12px;
  overflow-x: auto;
  padding: 10px 0 20px 0;
  scrollbar-width: none;
}
.genres-bar::-webkit-scrollbar { display: none; }
.genre-chip {
  background: var(--card-bg);
  border: 1px solid var(--border);
  padding: 8px 18px;
  border-radius: 30px;
  font-size: 14px;
  font-weight: 600;
  white-space: nowrap;
  box-shadow: 0 3px 10px rgba(0,0,0,0.03);
  transition: all 0.3s ease;
  display: flex;
  align-items: center;
  gap: 6px;
}
.genre-chip:hover, .genre-chip.active {
  background: var(--primary);
  color: #fff;
  border-color: var(--primary);
  transform: translateY(-2px);
  box-shadow: 0 6px 15px rgba(233, 30, 99, 0.25);
}

/* سرتیتر سکشن‌ها */
.section-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin: 35px 0 20px 0;
}
.section-title {
  font-size: 20px;
  font-weight: 800;
  position: relative;
  display: flex;
  align-items: center;
  gap: 8px;
}
.section-title::after {
  content: '';
  position: absolute;
  bottom: -6px;
  right: 0;
  width: 40px;
  height: 3px;
  background: var(--primary);
  border-radius: 4px;
}
.view-all-link {
  font-size: 13px;
  color: var(--primary);
  font-weight: 600;
}

/* گرید شبکه کارت‌های رمان */
.novels-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(200px, 1fr));
  gap: 22px;
}
@media (max-width: 576px) {
  .novels-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 14px;
  }
}

/* کارت تکی رمان */
.novel-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 16px;
  overflow: hidden;
  box-shadow: var(--shadow);
  transition: all 0.3s ease;
  display: flex;
  flex-direction: column;
  position: relative;
}
.novel-card:hover {
  transform: translateY(-5px);
  box-shadow: 0 12px 25px rgba(233, 30, 99, 0.15);
  border-color: #f7a8be;
}

/* کاور کتاب */
.novel-card-cover {
  position: relative;
  width: 100%;
  padding-top: 140%; /* تناسب ۳ به ۴ کتاب */
  background: #f1f5f9;
  overflow: hidden;
}
.novel-card-cover img {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.4s ease;
}
.novel-card:hover .novel-card-cover img {
  transform: scale(1.06);
}

/* بج‌های وضعیت روی کاور */
.novel-badges {
  position: absolute;
  top: 10px;
  right: 10px;
  display: flex;
  flex-direction: column;
  gap: 6px;
  z-index: 2;
}
.badge-item {
  font-size: 11px;
  font-weight: 700;
  padding: 3px 8px;
  border-radius: 20px;
  color: #fff;
  backdrop-filter: blur(4px);
}
.badge-special { background: rgba(245, 158, 11, 0.9); }
.badge-online { 
  background: rgba(239, 68, 68, 0.9); 
  display: flex; 
  align-items: center; 
  gap: 4px; 
}
.pulse-dot {
  width: 6px;
  height: 6px;
  background: #fff;
  border-radius: 50%;
  animation: pulse 1.2s infinite;
}
@keyframes pulse {
  0% { transform: scale(0.9); opacity: 0.7; }
  50% { transform: scale(1.4); opacity: 1; }
  100% { transform: scale(0.9); opacity: 0.7; }
}

/* مشخصات متنی کارت */
.novel-card-body {
  padding: 12px 14px 14px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
}
.novel-card-title {
  font-size: 14px;
  font-weight: 700;
  margin-bottom: 6px;
  line-height: 1.4;
  height: 40px;
  overflow: hidden;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
}
.novel-card-author {
  font-size: 12px;
  color: var(--text-muted);
  margin-bottom: 12px;
}
.novel-card-footer {
  margin-top: auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-top: 1px dashed var(--border);
  padding-top: 10px;
}
.novel-price {
  font-size: 13px;
  font-weight: 800;
  color: var(--primary);
}
.novel-price.free {
  color: #10b981;
}

/* بنر بزرگ دعوت به نویسندگی و عضویت */
.promo-banner {
  background: linear-gradient(135deg, #e91e63, #9c27b0);
  border-radius: 20px;
  padding: 35px 30px;
  margin: 50px 0;
  color: #fff;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
  box-shadow: 0 15px 30px rgba(233, 30, 99, 0.25);
}
.promo-btn {
  background: #fff;
  color: var(--primary);
  padding: 12px 28px;
  border-radius: 30px;
  font-weight: bold;
  font-size: 14px;
  transition: all 0.3s;
}
.promo-btn:hover {
  background: #ffe3ec;
  transform: translateY(-2px);
}
/* ======================================================
   استایل‌های اختصاصی صفحه داخلی رمان (Single Novel)
   ====================================================== */

/* مسیر راهنما */
.breadcrumb-nav {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 25px;
  flex-wrap: wrap;
}
.breadcrumb-nav a {
  color: var(--text-muted);
  transition: color 0.2s;
}
.breadcrumb-nav a:hover {
  color: var(--primary);
}

/* کارت اصلی اطلاعات رمان */
.novel-detail-card {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 30px;
  box-shadow: var(--shadow);
  display: flex;
  gap: 35px;
  margin-bottom: 35px;
}
@media (max-width: 768px) {
  .novel-detail-card {
    flex-direction: column;
    padding: 20px;
  }
}

/* کاور رمان در صفحه داخلی */
.novel-single-cover {
  flex: 0 0 260px;
  max-width: 100%;
  position: relative;
}
.novel-single-cover img {
  width: 100%;
  height: auto;
  border-radius: 16px;
  box-shadow: 0 10px 25px rgba(0,0,0,0.18);
  display: block;
}

/* جدول مشخصات سریع */
.novel-meta-list {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(180px, 1fr));
  gap: 15px;
  background: #fff8f9;
  border: 1px solid #ffe3ec;
  border-radius: 14px;
  padding: 16px 20px;
  margin: 20px 0;
  list-style: none;
}
.novel-meta-item {
  font-size: 14px;
  color: var(--text);
  display: flex;
  align-items: center;
  gap: 8px;
}
.novel-meta-item strong {
  color: var(--text-muted);
  font-weight: normal;
}

/* باکس هشدار بدون سانسور */
.warning-box {
  background: #fff1f2;
  border-right: 4px solid #f43f5e;
  color: #9f1239;
  padding: 12px 18px;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 25px;
  display: flex;
  align-items: center;
  gap: 10px;
}

/* باکس‌های دانلود و دکمه‌ها */
.download-section-box {
  background: var(--card-bg);
  border: 2px dashed #f7a8be;
  border-radius: 18px;
  padding: 25px;
  margin: 35px 0;
  text-align: center;
}
.download-btn-group {
  display: flex;
  flex-wrap: wrap;
  gap: 15px;
  justify-content: center;
  margin-top: 18px;
}
.btn-dl-pdf {
  background: linear-gradient(135deg, #e91e63, #d81b60);
  color: #fff !important;
  padding: 14px 28px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 15px;
  display: inline-flex;
  align-items: center;
  gap: 10px;
  box-shadow: 0 6px 18px rgba(233, 30, 99, 0.3);
  transition: all 0.3s;
}
.btn-dl-pdf:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 24px rgba(233, 30, 99, 0.4);
}
.btn-dl-telegram {
  background: #229ed9;
  color: #fff !important;
  padding: 14px 25px;
  border-radius: 12px;
  font-weight: 700;
  font-size: 14px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 6px 18px rgba(34, 158, 217, 0.25);
  transition: all 0.3s;
}
.btn-dl-telegram:hover {
  transform: translateY(-2px);
  background: #1c88bd;
}

/* بخش نظرات و فرم */
.novel-comments-area {
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 20px;
  padding: 30px;
  margin-top: 40px;
  box-shadow: var(--shadow);
}
.novel-comment-form input,
.novel-comment-form textarea {
  width: 100%;
  padding: 12px 15px;
  border: 1px solid var(--border);
  border-radius: 10px;
  font-family: inherit;
  font-size: 14px;
  margin-bottom: 15px;
  outline: none;
  background: #fafafa;
  transition: border-color 0.3s;
}
.novel-comment-form input:focus,
.novel-comment-form textarea:focus {
  border-color: var(--primary);
  background: #fff;
}
.btn-submit-comment {
  background: var(--primary);
  color: #fff;
  border: none;
  padding: 12px 30px;
  border-radius: 30px;
  font-weight: bold;
  font-family: inherit;
  cursor: pointer;
  transition: background 0.3s;
}
.btn-submit-comment:hover {
  background: #c2185b;
}
/* ======================================================
   قابلیت‌های لوکس: نوار شناور موبایل و بوک‌مارک
   ====================================================== */

/* دکمه بوک‌مارک */
.btn-bookmark {
  background: #fff;
  border: 1px solid var(--border);
  color: var(--text);
  padding: 8px 16px;
  border-radius: 30px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  display: inline-flex;
  align-items: center;
  gap: 6px;
  transition: all 0.3s ease;
}
.btn-bookmark.saved {
  background: #ffe3ec;
  color: var(--primary);
  border-color: #f7a8be;
}
.btn-bookmark:hover {
  transform: translateY(-2px);
  border-color: var(--primary);
}

/* نوار دسترسی سریع پایین صفحه مخصوص موبایل (Mobile Bottom Bar) */
.mobile-floating-bar {
  display: none;
}
@media (max-width: 768px) {
  .mobile-floating-bar {
    display: flex;
    position: fixed;
    bottom: 0;
    left: 0;
    right: 0;
    background: rgba(255, 255, 255, 0.95);
    backdrop-filter: blur(12px);
    border-top: 1px solid var(--border);
    padding: 10px 15px;
    z-index: 999;
    box-shadow: 0 -5px 20px rgba(0,0,0,0.08);
    justify-content: space-between;
    align-items: center;
    gap: 10px;
  }
  .mobile-floating-title {
    font-size: 13px;
    font-weight: 700;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
    max-width: 50%;
  }
  .mobile-floating-btn {
    background: var(--primary);
    color: #fff !important;
    padding: 9px 18px;
    border-radius: 25px;
    font-size: 12px;
    font-weight: bold;
    display: flex;
    align-items: center;
    gap: 6px;
    flex-shrink: 0;
  }
}
/* ======================================================
   استایل‌های پنجره ورود و ثبت‌نام (Auth Modal)
   ====================================================== */

.auth-modal-overlay {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(15, 23, 42, 0.6);
  backdrop-filter: blur(8px);
  z-index: 10000;
  align-items: center;
  justify-content: center;
  padding: 15px;
  animation: fadeIn 0.25s ease;
}
.auth-modal-overlay.active {
  display: flex;
}

.auth-modal-card {
  background: #ffffff;
  width: 100%;
  max-width: 420px;
  border-radius: 24px;
  padding: 30px;
  box-shadow: 0 25px 50px -12px rgba(233, 30, 99, 0.25);
  position: relative;
  animation: scaleUp 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

@keyframes fadeIn {
  from { opacity: 0; }
  to { opacity: 1; }
}
@keyframes scaleUp {
  from { opacity: 0; transform: scale(0.92); }
  to { opacity: 1; transform: scale(1); }
}

.auth-modal-close {
  position: absolute;
  top: 18px;
  left: 18px;
  background: #f1f5f9;
  border: none;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  font-size: 16px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--text-muted);
  transition: all 0.2s;
}
.auth-modal-close:hover {
  background: #ffe3ec;
  color: var(--primary);
}

/* تب‌های سوییچ بین ورود و ثبت نام */
.auth-tabs {
  display: flex;
  background: #fdf2f5;
  padding: 5px;
  border-radius: 14px;
  margin-bottom: 25px;
}
.auth-tab-btn {
  flex: 1;
  text-align: center;
  padding: 10px;
  font-weight: 700;
  font-size: 14px;
  border: none;
  background: transparent;
  color: var(--text-muted);
  border-radius: 10px;
  cursor: pointer;
  transition: all 0.25s ease;
  font-family: inherit;
}
.auth-tab-btn.active {
  background: #ffffff;
  color: var(--primary);
  box-shadow: 0 4px 12px rgba(233, 30, 99, 0.12);
}

/* فرم‌ها و اینپوت‌ها */
.auth-form {
  display: none;
}
.auth-form.active {
  display: block;
}
.auth-form-group {
  margin-bottom: 16px;
}
.auth-form-group label {
  display: block;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 6px;
  color: var(--text);
}
.auth-form-group input {
  width: 100%;
  padding: 12px 14px;
  border: 1.5px solid var(--border);
  border-radius: 12px;
  font-size: 14px;
  font-family: inherit;
  outline: none;
  transition: border-color 0.2s;
  background: #fcfcfd;
}
.auth-form-group input:focus {
  border-color: var(--primary);
  background: #fff;
}

.auth-submit-btn {
  width: 100%;
  padding: 13px;
  background: linear-gradient(135deg, var(--primary), var(--primary-hover));
  color: #fff;
  border: none;
  border-radius: 14px;
  font-weight: 700;
  font-size: 15px;
  font-family: inherit;
  cursor: pointer;
  box-shadow: 0 6px 18px rgba(233, 30, 99, 0.25);
  transition: all 0.3s ease;
  margin-top: 10px;
}
.auth-submit-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 10px 22px rgba(233, 30, 99, 0.35);
}

/* پیام‌های وضعیت (موفق / خطا) */
.auth-feedback-msg {
  display: none;
  padding: 10px 14px;
  border-radius: 10px;
  font-size: 13px;
  font-weight: 600;
  margin-bottom: 16px;
  text-align: center;
}
.auth-feedback-msg.error {
  display: block;
  background: #fff1f2;
  color: #be123c;
  border: 1px solid #fecdd3;
}
.auth-feedback-msg.success {
  display: block;
  background: #f0fdf4;
  color: #15803d;
  border: 1px solid #bbf7d0;
}

/* منوی پروفایل کاربر در هدر */
.user-header-menu {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  cursor: pointer;
}
.user-avatar-small {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  border: 2px solid var(--primary);
  object-fit: cover;
}
.user-dropdown-panel {
  display: none;
  position: absolute;
  top: 115%;
  left: 0;
  background: #fff;
  border: 1px solid var(--border);
  border-radius: 16px;
  min-width: 190px;
  box-shadow: var(--shadow);
  padding: 8px 0;
  z-index: 1000;
}
.user-dropdown-panel.show {
  display: block;
}
.user-dropdown-item {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 10px 18px;
  font-size: 13px;
  font-weight: 600;
  color: var(--text);
  transition: background 0.2s, color 0.2s;
}
.user-dropdown-item:hover {
  background: #fff0f5;
  color: var(--primary);
}
/* ======================================================
   هدر اصلی رومان لوکس
   ====================================================== */

.main-header {
  position: sticky;
  top: 0;
  width: 100%;
  z-index: 900;
  background: rgba(255, 255, 255, 0.96);
  border-bottom: 1px solid var(--border);
  box-shadow: 0 4px 18px rgba(44, 62, 80, 0.06);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
}

/* جلوگیری از تداخل هدر با نوار مدیریت وردپرس */
body.admin-bar .main-header {
  top: 32px;
}

.header-container {
  width: 100%;
  min-height: 76px;
  display: flex;
  align-items: center;
  gap: 24px;
  padding-top: 10px;
  padding-bottom: 10px;
}

/* لوگوی سایت */
.brand-logo {
  flex: 0 0 auto;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
  justify-content: center;
  color: var(--text);
  line-height: 1.25;
  white-space: nowrap;
}

.brand-name {
  display: block;
  color: var(--primary);
  font-size: 21px;
  font-weight: 900;
  line-height: 1.4;
}

.brand-badge {
  display: block;
  margin-top: 1px;
  color: var(--text-muted);
  font-size: 10px;
  font-weight: 600;
}

/* فرم جستجو */
.main-header .search-form {
  position: relative;
  flex: 1 1 420px;
  width: 100%;
  max-width: 520px;
  min-width: 180px;
  margin: 0;
}

.main-header .search-icon {
  position: absolute;
  top: 50%;
  right: 15px;
  z-index: 2;
  display: flex;
  align-items: center;
  justify-content: center;
  transform: translateY(-50%);
  color: var(--text-muted);
  font-size: 15px;
  line-height: 1;
  pointer-events: none;
}

.main-header .search-input {
  width: 100%;
  height: 44px;
  display: block;
  margin: 0;
  padding: 8px 43px 8px 15px;
  color: var(--text);
  background: #fffafb;
  border: 1px solid var(--border);
  border-radius: 8px;
  outline: none;
  font-family: inherit;
  font-size: 13px;
  transition:
    border-color 0.2s ease,
    background-color 0.2s ease,
    box-shadow 0.2s ease;
}

.main-header .search-input::placeholder {
  color: #9ca3af;
  opacity: 1;
}

.main-header .search-input:hover {
  border-color: #e9a8ba;
}

.main-header .search-input:focus {
  background: #fff;
  border-color: var(--primary);
  box-shadow: 0 0 0 3px rgba(233, 30, 99, 0.1);
}

/* بخش حساب کاربری */
.header-user-actions {
  flex: 0 0 auto;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  min-width: max-content;
}

.btn-login {
  min-height: 42px;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  gap: 7px;
  padding: 9px 18px;
  color: #fff;
  background: var(--primary);
  border: 1px solid var(--primary);
  border-radius: 8px;
  outline: none;
  box-shadow: 0 5px 14px rgba(233, 30, 99, 0.2);
  font-family: inherit;
  font-size: 13px;
  font-weight: 700;
  line-height: 1.5;
  white-space: nowrap;
  cursor: pointer;
  transition:
    background-color 0.2s ease,
    border-color 0.2s ease,
    box-shadow 0.2s ease,
    transform 0.2s ease;
}

.btn-login:hover {
  color: #fff;
  background: var(--primary-hover);
  border-color: var(--primary-hover);
  box-shadow: 0 7px 18px rgba(233, 30, 99, 0.28);
  transform: translateY(-1px);
}

.btn-login:focus-visible {
  box-shadow: 0 0 0 3px rgba(233, 30, 99, 0.18);
}

/* کاربر واردشده */
.user-header-menu {
  position: relative;
  min-height: 44px;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 3px 5px;
  border-radius: 8px;
  cursor: pointer;
  user-select: none;
}

.user-header-menu:hover {
  background: #fff0f5;
}

.user-header-menu > span {
  white-space: nowrap;
}

.user-avatar-small {
  width: 40px;
  height: 40px;
  flex: 0 0 40px;
  display: block;
  border: 2px solid var(--primary);
  border-radius: 50%;
  object-fit: cover;
}

/* منوی کشویی حساب */
.user-dropdown-panel {
  display: none;
  position: absolute;
  top: calc(100% + 10px);
  left: 0;
  z-index: 1200;
  width: 230px;
  min-width: 230px;
  padding: 7px 0;
  overflow: hidden;
  background: var(--card-bg);
  border: 1px solid var(--border);
  border-radius: 8px;
  box-shadow: 0 15px 35px rgba(44, 62, 80, 0.14);
  cursor: default;
}

.user-dropdown-panel.show {
  display: block;
  animation: romanluxDropdown 0.18s ease-out;
}

@keyframes romanluxDropdown {
  from {
    opacity: 0;
    transform: translateY(-5px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.user-dropdown-panel > div {
  overflow: hidden;
}

.user-dropdown-panel > div > div {
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.user-dropdown-item {
  min-height: 42px;
  display: flex;
  align-items: center;
  gap: 9px;
  padding: 9px 16px;
  color: var(--text);
  font-size: 13px;
  font-weight: 600;
  transition:
    color 0.2s ease,
    background-color 0.2s ease;
}

.user-dropdown-item:hover {
  color: var(--primary);
  background: #fff0f5;
}

/* حالت تیره */
body.dark-mode .main-header {
  background: rgba(30, 30, 38, 0.96);
}

body.dark-mode .main-header .search-input {
  color: var(--text);
  background: #181820;
  border-color: var(--border);
}

body.dark-mode .main-header .search-input:focus {
  background: #20202a;
}

body.dark-mode .user-header-menu:hover,
body.dark-mode .user-dropdown-item:hover {
  background: #292934;
}

/* ======================================================
   هدر در تبلت
   ====================================================== */

@media (max-width: 900px) {
  .header-container {
    gap: 14px;
  }

  .brand-name {
    font-size: 19px;
  }

  .main-header .search-form {
    flex-basis: 300px;
  }

  .user-header-menu > span {
    display: none;
  }
}

/* ======================================================
   هدر در موبایل
   ====================================================== */

@media (max-width: 700px) {
  body.admin-bar .main-header {
    top: 46px;
  }

  .header-container {
    min-height: auto;
    display: grid;
    grid-template-columns: minmax(0, 1fr) auto;
    gap: 10px 12px;
    padding-top: 10px;
    padding-bottom: 10px;
  }

  .brand-logo {
    min-width: 0;
    align-items: flex-start;
  }

  .brand-name {
    max-width: 100%;
    overflow: hidden;
    font-size: 18px;
    text-overflow: ellipsis;
    white-space: nowrap;
  }

  .brand-badge {
    font-size: 9px;
  }

  .header-user-actions {
    justify-self: end;
    min-width: 0;
  }

  .main-header .search-form {
    grid-column: 1 / -1;
    grid-row: 2;
    width: 100%;
    max-width: none;
    min-width: 0;
  }

  .main-header .search-input {
    height: 42px;
    font-size: 12px;
  }

  .btn-login {
    min-height: 39px;
    padding: 8px 13px;
    font-size: 12px;
  }

  .user-header-menu {
    min-height: 40px;
  }

  .user-avatar-small {
    width: 38px;
    height: 38px;
    flex-basis: 38px;
  }

  .user-dropdown-panel {
    top: calc(100% + 8px);
    left: 0;
    width: min(230px, calc(100vw - 30px));
    min-width: 0;
  }
}

/* گوشی‌های کوچک */
@media (max-width: 380px) {
  .container {
    padding-right: 14px;
    padding-left: 14px;
  }

  .brand-name {
    font-size: 16px;
  }

  .btn-login {
    max-width: 145px;
    padding-right: 10px;
    padding-left: 10px;
    overflow: hidden;
    text-overflow: ellipsis;
  }
}
/* ================= پروفایل کاربری رومان لوکس ================= */

.profile-header-card {
    background: #fff;
    border: 1px solid #fce7f3;
    border-radius: 18px;
    padding: 25px;
    display: flex;
    align-items: center;
    gap: 20px;
    flex-wrap: wrap;
    box-shadow: 0 6px 24px rgba(236, 72, 153, 0.08);
    margin-bottom: 25px;
}
.profile-avatar-wrap img {
    width: 96px; height: 96px;
    border-radius: 50%;
    border: 3px solid #f9a8d4;
}
.profile-name-title {
    font-size: 22px; font-weight: 800; color: #1f2937; margin: 0 0 10px;
}
.profile-meta-chips { display: flex; flex-wrap: wrap; gap: 8px; }
.profile-chip {
    background: #fdf2f8; color: #db2777;
    border: 1px solid #fbcfe8;
    padding: 5px 14px; border-radius: 999px;
    font-size: 13px; font-weight: 600;
}
.profile-header-actions { margin-right: auto; }
.btn-profile-logout {
    background: #ef4444; color: #fff;
    padding: 10px 20px; border-radius: 12px;
    text-decoration: none; font-weight: 700; font-size: 14px;
    transition: 0.2s;
}
.btn-profile-logout:hover { background: #dc2626; }

/* تب‌ها */
.profile-tabs-nav {
    display: flex; gap: 10px; flex-wrap: wrap; margin-bottom: 20px;
}
.profile-tab-btn {
    background: #fff; border: 1px solid #fbcfe8; color: #db2777;
    padding: 10px 20px; border-radius: 12px;
    font-family: inherit; font-size: 14px; font-weight: 700;
    cursor: pointer; transition: 0.2s;
}
.profile-tab-btn:hover { background: #fdf2f8; }
.profile-tab-btn.active {
    background: #db2777; color: #fff; border-color: #db2777;
}

/* پنل‌ها */
.profile-tab-pane { display: none; animation: rlxFade 0.3s ease; }
.profile-tab-pane.active { display: block; }
@keyframes rlxFade { from { opacity: 0; transform: translateY(8px); } to { opacity: 1; transform: none; } }

.profile-pane-header {
    display: flex; justify-content: space-between; align-items: center;
    flex-wrap: wrap; gap: 10px; margin-bottom: 18px;
}
.profile-pane-header h3 { font-size: 18px; color: #1f2937; margin: 0; }
.btn-clear-bookmarks {
    background: #fee2e2; color: #b91c1c; border: none;
    padding: 8px 16px; border-radius: 10px;
    font-family: inherit; font-weight: 700; font-size: 13px; cursor: pointer;
}
.btn-clear-bookmarks:hover { background: #fecaca; }

/* کارت‌های رمان نشان‌شده */
#profileBookmarkGrid {
    display: grid;
    grid-template-columns: repeat(auto-fill, minmax(160px, 1fr));
    gap: 18px;
}
.novel-card {
    background: #fff; border: 1px solid #fce7f3; border-radius: 16px;
    overflow: hidden; box-shadow: 0 4px 16px rgba(236, 72, 153, 0.07);
    transition: 0.25s; display: flex; flex-direction: column;
}
.novel-card:hover { transform: translateY(-4px); box-shadow: 0 10px 26px rgba(236, 72, 153, 0.15); }
.novel-card-cover img { width: 100%; height: 230px; object-fit: cover; display: block; }
.novel-card-body { padding: 12px; display: flex; flex-direction: column; gap: 8px; flex: 1; }
.novel-card-title { font-size: 14px; margin: 0; line-height: 1.6; }
.novel-card-title a { color: #1f2937; text-decoration: none; }
.novel-card-title a:hover { color: #db2777; }
.novel-card-author { font-size: 12px; color: #9ca3af; }
.btn-remove-bm {
    margin-top: auto; background: #fdf2f8; color: #db2777;
    border: 1px solid #fbcfe8; border-radius: 8px;
    padding: 6px; font-family: inherit; font-size: 12px; font-weight: 700; cursor: pointer;
}
.btn-remove-bm:hover { background: #fce7f3; }

/* پیام خالی */
.profile-empty-message {
    grid-column: 1 / -1;
    background: #fff; border: 2px dashed #fbcfe8;
    border-radius: 16px; padding: 40px 20px;
    text-align: center; color: #9ca3af; font-size: 14px;
}

/* لیست دیدگاه‌ها */
.profile-comments-list { display: flex; flex-direction: column; gap: 14px; }
.profile-comment-item {
    background: #fff; border: 1px solid #fce7f3;
    border-radius: 14px; padding: 16px 20px;
}
.profile-comment-meta { font-size: 13px; color: #6b7280; margin-bottom: 8px; }
.profile-comment-meta a { color: #db2777; font-weight: 700; text-decoration: none; }
.profile-comment-date {
    background: #fdf2f8; color: #db2777;
    border-radius: 999px; padding: 2px 12px; margin-right: 10px; font-size: 12px;
}
.profile-comment-text { font-size: 14px; color: #374151; line-height: 2; }

/* تنظیمات حساب */
.profile-info-grid { display: flex; flex-direction: column; gap: 14px; max-width: 500px; }
.profile-info-box { display: flex; flex-direction: column; gap: 6px; }
.profile-info-box label { font-size: 13px; font-weight: 700; color: #6b7280; }
.profile-info-box input {
    background: #fdf2f8; border: 1px solid #fbcfe8; border-radius: 10px;
    padding: 10px 14px; font-family: inherit; font-size: 14px; color: #1f2937;
}
.profile-info-box input:disabled { opacity: 0.85; }
.btn-password-reset {
    display: inline-block; background: #db2777; color: #fff;
    padding: 12px 24px; border-radius: 12px;
    text-decoration: none; font-weight: 700; font-size: 14px; transition: 0.2s;
}
.btn-password-reset:hover { background: #be185d; }

@media (max-width: 600px) {
    .profile-header-card { flex-direction: column; text-align: center; }
    .profile-header-actions { margin-right: 0; }
    .profile-meta-chips { justify-content: center; }
}
/* بخش‌بندی صفحه اصلی */
.novel-section-block {
    margin-bottom: 45px;
}
.section-badge-info {
    font-size: 0.85rem;
    color: #9ca3af;
    font-weight: normal;
}
.btn-card-action {
    color: #e11d48;
    font-size: 12px;
    font-weight: 700;
    text-decoration: none;
    transition: 0.2s;
}
.btn-card-action:hover {
    color: #be123c;
    transform: translateX(-3px);
}
.card-vip-highlight {
    border: 1px solid #fde68a !important;
    box-shadow: 0 4px 15px rgba(245, 158, 11, 0.08) !important;
}
.novel-no-cover {
    display: flex;
    height: 100%;
    align-items: center;
    justify-content: center;
    color: #9ca3af;
    font-size: 13px;
    background: #f8fafc;
}
/* ==========================================================================
   طراحی هیرو بنر جذاب ویترینی (۳ کارت شناور و خرید VIP)
   ========================================================================== */

.main-site-wrapper {
    max-width: 1240px;
    margin: 0 auto;
    padding: 24px 20px 80px;
    font-family: inherit;
}

/* ۱. هیرو بنر ویترینی */
.hero-banner-showcase {
    background: linear-gradient(135deg, #1e112a 0%, #3b143f 40%, #160d20 100%);
    border-radius: 28px;
    padding: 50px 60px;
    margin-bottom: 45px;
    position: relative;
    overflow: hidden;
    box-shadow: 0 20px 50px rgba(30, 17, 42, 0.35);
}

.hero-banner-showcase::before {
    content: '';
    position: absolute;
    top: -50%;
    right: -20%;
    width: 500px;
    height: 500px;
    background: radial-gradient(circle, rgba(236, 72, 153, 0.25) 0%, rgba(0,0,0,0) 70%);
    border-radius: 50%;
    pointer-events: none;
}

.hero-inner-container {
    display: flex;
    align-items: center;
    justify-content: space-between;
    gap: 40px;
    position: relative;
    z-index: 2;
}

.hero-text-side {
    flex: 1.1;
    max-width: 560px;
}

.hero-badge {
    display: inline-block;
    background: rgba(255, 255, 255, 0.12);
    backdrop-filter: blur(10px);
    color: #fbcfe8;
    font-size: 13px;
    font-weight: 700;
    padding: 6px 16px;
    border-radius: 30px;
    margin-bottom: 18px;
    border: 1px solid rgba(255, 255, 255, 0.15);
}

.hero-main-title {
    font-size: 36px;
    font-weight: 900;
    color: #ffffff;
    line-height: 1.35;
    margin: 0 0 16px;
    letter-spacing: -0.5px;
}

.hero-subtitle {
    font-size: 15px;
    line-height: 1.8;
    color: #e2e8f0;
    margin: 0 0 28px;
}

.hero-action-buttons {
    display: flex;
    align-items: center;
    gap: 15px;
    margin-bottom: 35px;
}

/* دکمه خرید اشتراک VIP با افکت درخشش طلایی */
.btn-hero-vip {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: #ffffff !important;
    font-size: 14.5px;
    font-weight: 800;
    padding: 14px 28px;
    border-radius: 16px;
    text-decoration: none;
    box-shadow: 0 10px 25px rgba(245, 158, 11, 0.4);
    transition: all 0.3s ease;
}

.btn-hero-vip:hover {
    transform: translateY(-3px) scale(1.03);
    box-shadow: 0 14px 30px rgba(245, 158, 11, 0.6);
    background: linear-gradient(135deg, #fbbf24, #d97706);
}

.vip-icon {
    font-size: 18px;
}

.btn-hero-explore {
    display: inline-flex;
    align-items: center;
    gap: 8px;
    background: rgba(255, 255, 255, 0.1);
    color: #ffffff !important;
    font-size: 14px;
    font-weight: 700;
    padding: 14px 24px;
    border-radius: 16px;
    text-decoration: none;
    border: 1px solid rgba(255, 255, 255, 0.2);
    backdrop-filter: blur(8px);
    transition: all 0.3s ease;
}

.btn-hero-explore:hover {
    background: rgba(255, 255, 255, 0.2);
    transform: translateY(-2px);
}

.hero-stats-row {
    display: flex;
    align-items: center;
    gap: 20px;
    padding-top: 15px;
    border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.hero-stat-item strong {
    display: block;
    color: #ffffff;
    font-size: 18px;
    font-weight: 900;
}

.hero-stat-item span {
    font-size: 12px;
    color: #cbd5e1;
}

.stat-divider {
    width: 1px;
    height: 28px;
    background: rgba(255, 255, 255, 0.15);
}

/* اسلایدر چرخشی خودکار کارت‌های هیرو */
.hero-cards-showcase {
    flex: 0.9;
    display: flex;
    justify-content: center;
    align-items: center;
    position: relative;
    height: 330px;
    perspective: 1000px;
}

.hero-floating-card {
    position: absolute;
    width: 180px;
    height: 260px;
    border-radius: 16px;
    overflow: hidden;
    text-decoration: none;
    border: 2px solid rgba(255, 255, 255, 0.2);
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5);
    transition: all 0.6s cubic-bezier(0.25, 1, 0.5, 1);
    cursor: pointer;
}

.hero-floating-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.card-mini-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 12px 10px;
    background: linear-gradient(transparent, rgba(0,0,0,0.88));
    color: #ffffff;
}

.card-mini-title {
    display: block;
    font-size: 12.5px;
    font-weight: 800;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.card-mini-author {
    display: block;
    font-size: 10.5px;
    color: #cbd5e1;
    margin-top: 2px;
}

/* وضعیت‌های ۳‌بعدی اسلایدر */
.hero-floating-card.pos-center {
    transform: translateX(0) translateY(-6px) scale(1.08) rotate(0deg);
    z-index: 5;
    opacity: 1;
    border-color: rgba(245, 158, 11, 0.7);
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.75);
    pointer-events: auto;
}

.hero-floating-card.pos-left {
    transform: translateX(95px) translateY(12px) scale(0.88) rotate(-10deg);
    z-index: 3;
    opacity: 0.8;
    pointer-events: auto;
}

.hero-floating-card.pos-right {
    transform: translateX(-95px) translateY(12px) scale(0.88) rotate(10deg);
    z-index: 3;
    opacity: 0.8;
    pointer-events: auto;
}

.hero-floating-card.pos-hidden {
    transform: translateX(0) translateY(30px) scale(0.6);
    opacity: 0;
    z-index: 1;
    pointer-events: none;
}

/* دکمه‌های تغییر اسلاید */
.hero-slider-nav {
    position: absolute;
    bottom: -10px;
    display: flex;
    gap: 12px;
    z-index: 10;
}

.hero-slider-nav button {
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.15);
    backdrop-filter: blur(6px);
    border: 1px solid rgba(255, 255, 255, 0.25);
    color: #ffffff;
    font-size: 16px;
    font-weight: bold;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.2s ease;
}

.hero-slider-nav button:hover {
    background: #ec4899;
    border-color: #ec4899;
    transform: scale(1.1);
}


.hero-floating-card {
    position: absolute;
    width: 180px;
    height: 260px;
    border-radius: 16px;
    overflow: hidden;
    box-shadow: 0 15px 35px rgba(0, 0, 0, 0.5);
    transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
    text-decoration: none;
    border: 2px solid rgba(255, 255, 255, 0.2);
}

.hero-floating-card img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
}

.card-mini-info {
    position: absolute;
    bottom: 0;
    left: 0;
    right: 0;
    padding: 12px 10px;
    background: linear-gradient(transparent, rgba(0,0,0,0.85));
    color: #ffffff;
}

.card-mini-title {
    display: block;
    font-size: 12px;
    font-weight: 800;
    white-space: nowrap;
    overflow: hidden;
    text-overflow: ellipsis;
}

.card-mini-author {
    display: block;
    font-size: 10px;
    color: #cbd5e1;
    margin-top: 2px;
}

/* موقعیت‌دهی ۳ کارت */
.card-pos-1 {
    transform: translateX(85px) translateY(10px) rotate(-10deg) scale(0.9);
    z-index: 1;
    opacity: 0.85;
}

.card-pos-2 {
    transform: translateX(0) translateY(-10px) rotate(0deg) scale(1.05);
    z-index: 3;
    box-shadow: 0 20px 45px rgba(0, 0, 0, 0.7);
    border-color: rgba(245, 158, 11, 0.6);
}

.card-pos-3 {
    transform: translateX(-85px) translateY(10px) rotate(10deg) scale(0.9);
    z-index: 2;
    opacity: 0.85;
}

.hero-floating-card:hover {
    z-index: 10 !important;
    transform: translateY(-15px) scale(1.1) rotate(0deg) !important;
    opacity: 1;
}

/* ۳. نوار ژانرها */
.genres-bar-section {
    margin-bottom: 45px;
}

.genres-scroll-container {
    display: flex;
    gap: 12px;
    overflow-x: auto;
    padding-bottom: 8px;
    scrollbar-width: none;
}
.genres-scroll-container::-webkit-scrollbar { display: none; }

.genre-pill-item {
    white-space: nowrap;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    color: #475569;
    padding: 10px 22px;
    border-radius: 100px;
    font-size: 13.5px;
    font-weight: 700;
    text-decoration: none;
    transition: all 0.25s ease;
    box-shadow: 0 2px 6px rgba(0,0,0,0.03);
}

.genre-pill-item:hover {
    background: #fdf2f8;
    color: #db2777;
    border-color: #fbcfe8;
    transform: translateY(-2px);
}

.genre-pill-item.active {
    background: linear-gradient(135deg, #ec4899, #be185d);
    color: #ffffff;
    border-color: #ec4899;
    box-shadow: 0 4px 15px rgba(236, 72, 153, 0.35);
}

/* ۴. سرتیتر سکشن‌ها */
.novels-feed-section {
    margin-bottom: 55px;
}

.section-title-wrap {
    display: flex;
    align-items: center;
    justify-content: space-between;
    margin-bottom: 22px;
}

.section-title {
    font-size: 21px;
    font-weight: 900;
    color: #1e293b;
    margin: 0 0 5px;
    display: flex;
    align-items: center;
    gap: 8px;
}

.title-decor {
    display: inline-block;
    width: 6px;
    height: 20px;
    background: #ec4899;
    border-radius: 4px;
}
.title-decor.gold { background: #f59e0b; }
.title-decor.blue { background: #3b82f6; }

.section-sub {
    font-size: 13px;
    color: #64748b;
    margin: 0;
}

.section-vip-link {
    font-size: 13px;
    font-weight: 800;
    color: #d97706;
    text-decoration: none;
    background: #fef3c7;
    padding: 6px 14px;
    border-radius: 12px;
    transition: all 0.2s;
}
.section-vip-link:hover {
    background: #fde68a;
}

/* ۵. کارت‌های ۵ ستونه رمان */
.novel-grid-5 {
    display: grid;
    grid-template-columns: repeat(5, 1fr);
    gap: 20px;
}

.novel-card-box {
    display: flex;
    flex-direction: column;
    transition: transform 0.3s ease;
}

.novel-card-box:hover {
    transform: translateY(-6px);
}

.novel-poster-wrap {
    position: relative;
    width: 100%;
    aspect-ratio: 2 / 2.9;
    border-radius: 16px;
    overflow: hidden;
    background: #f1f5f9;
    box-shadow: 0 8px 18px rgba(0, 0, 0, 0.05);
}

.novel-poster-wrap img {
    width: 100%;
    height: 100%;
    object-fit: cover;
    display: block;
    transition: transform 0.5s ease;
}

.novel-card-box:hover .novel-poster-wrap img {
    transform: scale(1.08);
}

.novel-top-tags {
    position: absolute;
    bottom: 10px;
    right: 10px;
    z-index: 2;
}

.tag-live {
    display: inline-flex;
    align-items: center;
    gap: 6px;
    background: rgba(15, 23, 42, 0.8);
    backdrop-filter: blur(6px);
    color: #ffffff;
    font-size: 11px;
    font-weight: 700;
    padding: 4px 10px;
    border-radius: 20px;
}

.live-dot {
    width: 6px;
    height: 6px;
    background: #ef4444;
    border-radius: 50%;
    box-shadow: 0 0 0 2px rgba(239, 68, 68, 0.4);
}

.tag-vip {
    background: linear-gradient(135deg, #f59e0b, #d97706);
    color: #ffffff;
    font-size: 11px;
    font-weight: 800;
    padding: 4px 10px;
    border-radius: 20px;
}

.btn-fav-bookmark {
    position: absolute;
    top: 10px;
    left: 10px;
    width: 32px;
    height: 32px;
    border-radius: 50%;
    background: rgba(255, 255, 255, 0.85);
    backdrop-filter: blur(6px);
    border: none;
    color: #64748b;
    display: flex;
    align-items: center;
    justify-content: center;
    cursor: pointer;
    transition: all 0.25s ease;
    z-index: 3;
}

.btn-fav-bookmark:hover {
    background: #ffffff;
    color: #ec4899;
    transform: scale(1.15);
}

.btn-fav-bookmark.active {
    background: #ec4899;
    color: #ffffff;
}

.novel-card-info {
    padding-top: 12px;
}

.novel-title {
    font-size: 14.5px;
    font-weight: 800;
    line-height: 1.4;
    margin: 0 0 4px;
    display: -webkit-box;
    -webkit-line-clamp: 1;
    -webkit-box-orient: vertical;
    overflow: hidden;
}

.novel-title a {
    color: #1e293b;
    text-decoration: none;
    transition: color 0.2s;
}

.novel-title a:hover {
    color: #ec4899;
}

.novel-author {
    font-size: 12px;
    color: #64748b;
    display: block;
}

/* ۶. صفحه‌بندی */
.feed-pagination {
    text-align: center;
    margin-top: 35px;
}

.feed-pagination .page-numbers {
    display: inline-flex;
    align-items: center;
    justify-content: center;
    min-width: 38px;
    height: 38px;
    padding: 0 10px;
    margin: 0 3px;
    border-radius: 10px;
    background: #ffffff;
    border: 1px solid #e2e8f0;
    color: #334155;
    font-size: 13px;
    font-weight: 700;
    text-decoration: none;
    transition: 0.2s ease;
}

.feed-pagination .page-numbers.current {
    background: #ec4899;
    color: #ffffff;
    border-color: #ec4899;
}

.feed-pagination .page-numbers:hover:not(.current) {
    background: #fdf2f8;
    color: #ec4899;
    border-color: #fbcfe8;
}

/* ریسپانسیو موبایل و تبلت */
@media (max-width: 1024px) {
    .hero-banner-showcase { padding: 40px 30px; }
    .hero-main-title { font-size: 28px; }
    .novel-grid-5 { grid-template-columns: repeat(4, 1fr); }
}

@media (max-width: 768px) {
    .hero-inner-container { flex-direction: column-reverse; text-align: center; }
    .hero-action-buttons, .hero-stats-row { justify-content: center; }
    .hero-cards-showcase { height: 260px; width: 100%; margin-bottom: 20px; }
    .hero-floating-card { width: 140px; height: 200px; }
    .card-pos-1 { transform: translateX(60px) rotate(-8deg) scale(0.9); }
    .card-pos-3 { transform: translateX(-60px) rotate(8deg) scale(0.9); }
    .novel-grid-5 { grid-template-columns: repeat(2, 1fr); gap: 14px; }
}
