/* ---------- کتابخانه‌ی داکس (بنر صفحه اصلی + صفحه لندینگ) ---------- */

/* بنر (صفحه اصلی) */
/* #dux-challenge (بخش مسابقه) با margin-bottom: -100px روی خودش سوار میشه تا
   با فاصله‌ی طبیعی به سکشن بعدی برسه (دقیقا مثل #case-study که margin-top: 165px
   داره تا این overlap رو خنثی کنه). این سکشن قبلاً این جبران رو نداشت، برای
   همین کاملاً زیر باکس مسابقه (که position:relative؛ z-index:9 داره) گم می‌شد.
   margin-top: 100px همون overlap رو خنثی می‌کنه و position/z-index هم به‌عنوان
   محافظ اضافه شده که این سکشن همیشه *روی* سکشن قبلی بشینه، نه زیرش. */
.dux-library-banner-section {
  position: relative;
  z-index: 1;
  margin-top: 150px;
  padding: 0 0 4px;
  max-height: 390px;
}

.library-banner {
  position: relative;
  width: 100%;
  border-radius: 28px;
  padding: 44px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 24px;
  cursor: pointer;
  border: 1px solid rgba(255, 255, 255, 0.08);
  text-align: right;
  overflow: hidden;
  background: linear-gradient(120deg, #0b1a2e 0%, #0f2740 55%, #0a3a5c 100%);
  box-shadow: 0 14px 34px -12px rgba(2, 20, 40, 0.55), inset 0 1px 0 rgba(255, 255, 255, 0.06);
  transition: transform 0.2s ease, box-shadow 0.2s ease, border-color 0.2s ease;
  text-decoration: none;
}

.library-banner:hover {
  transform: translateY(-3px);
  box-shadow: 0 20px 44px -10px rgba(2, 20, 40, 0.65), inset 0 1px 0 rgba(255, 255, 255, 0.08);
  border-color: rgba(51, 181, 234, 0.35);
  color: inherit;
}

.library-banner:active {
  transform: scale(0.98);
}

.library-banner::before,
.library-banner::after {
  content: '';
  position: absolute;
  border-radius: 50%;
  filter: blur(30px);
  opacity: 0.55;
  pointer-events: none;
  animation: library-blob-drift 9s ease-in-out infinite;
}

.library-banner::before {
  width: 160px;
  height: 160px;
  top: -50px;
  inset-inline-start: -30px;
  background: radial-gradient(circle, #33b5ea 0%, transparent 70%);
}

.library-banner::after {
  width: 140px;
  height: 140px;
  bottom: -50px;
  inset-inline-end: -20px;
  background: radial-gradient(circle, #7c3aed 0%, transparent 70%);
  animation-delay: -4.5s;
}

@keyframes library-blob-drift {
  0%, 100% { transform: translate(0, 0) scale(1); }
  50% { transform: translate(10px, -10px) scale(1.12); }
}

/* diagonal shine that sweeps across the banner on hover — the "surprise" */
.library-banner-shine {
  position: absolute;
  inset: 0 auto 0 0;
  z-index: 1;
  width: 45%;
  transform: translateX(-220%) skewX(-20deg);
  background: linear-gradient(
    100deg,
    transparent 0%,
    rgba(255, 255, 255, 0.03) 35%,
    rgba(255, 255, 255, 0.14) 50%,
    rgba(255, 255, 255, 0.03) 65%,
    transparent 100%
  );
  pointer-events: none;
}

.library-banner:hover .library-banner-shine {
  animation: library-shine-sweep 1.1s ease-in-out;
}

@keyframes library-shine-sweep {
  to { transform: translateX(560%) skewX(-20deg); }
}

@media (prefers-reduced-motion: reduce) {
  .library-banner::before,
  .library-banner::after {
    animation: none;
  }
  .library-banner:hover .library-banner-shine {
    animation: none;
  }
}

.library-banner-content {
  position: relative;
  z-index: 2;
  flex: 1 1 380px;
  min-width: 0;
  max-width: 520px;
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.library-banner-title {
  display: block;
  color: #fff;
  font-weight: 800;
  font-size: 36px;
  line-height: 140%;
  margin-bottom: 12px;
}

.library-banner-sub {
  display: block;
  color: #a9c4dd;
  font-size: 14.5px;
  line-height: 180%;
  margin-bottom: 22px;
}

.library-banner-row {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 18px 22px;
}

.library-banner-cta {
  display: inline-flex;
  align-items: center;
  color: #fff;
  font-weight: 700;
  font-size: 14px;
  background: linear-gradient(135deg, #33b5ea, #019dde);
  border-radius: 999px;
  padding: 12px 24px;
  box-shadow: 0 10px 22px -8px rgba(1, 157, 222, 0.6);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  white-space: nowrap;
}

.library-banner:hover .library-banner-cta {
  transform: translateY(-2px);
  box-shadow: 0 14px 28px -8px rgba(1, 157, 222, 0.75);
}

.library-banner-stat {
  display: inline-flex;
  align-items: center;
  gap: 10px;
  color: #91a9c2;
  font-size: 12.5px;
  line-height: 1;
  white-space: nowrap;
}

.library-banner-stat-line {
  flex-shrink: 0;
  width: 26px;
  height: 1px;
}

.library-banner-stat-line-start {
  background: linear-gradient(to left, rgba(169, 196, 221, 0.55), rgba(169, 196, 221, 0));
}

.library-banner-stat-line-end {
  background: linear-gradient(to right, rgba(169, 196, 221, 0.55), rgba(169, 196, 221, 0));
}

@media (max-width: 520px) {
  .library-banner-stat {
    white-space: normal;
  }
}

.library-banner-visual {
  position: relative;
  z-index: 2;
  flex: 1 1 340px;
  max-width: 380px;
  align-self: center;
  pointer-events: none;
}

.library-banner-visual img {
  display: block;
  width: 100%;
  height: auto;
  filter: drop-shadow(0 20px 30px rgba(2, 12, 26, 0.5));
  animation: library-visual-float 5s ease-in-out infinite;
}

@keyframes library-visual-float {
  0%, 100% { transform: translateY(0); }
  50% { transform: translateY(-8px); }
}

@media (prefers-reduced-motion: reduce) {
  .library-banner-visual img {
    animation: none;
  }
}

@media (max-width: 860px) {
  .library-banner {
    flex-wrap: wrap;
    justify-content: center;
    padding: 30px 24px 0;
    text-align: center;
  }

  .library-banner-content {
    align-items: center;
    text-align: center;
    max-width: 100%;
    padding-bottom: 0;
  }

  .library-banner-row {
    justify-content: center;
  }

  .library-banner-visual {
    flex-basis: 100%;
    max-width: 340px;
    margin-top: 20px;
    align-self: center;
  }
}

/* ---------- صفحه لندینگ کتابخانه ---------- */
.library-page {
  --lp-bg: #00202e;
  --lp-bg-2: #0d1f33;
  --lp-card: #142a41;
  --lp-card-2: #17324d;
  --lp-border: #1f3a56;
  --lp-text: #b9cbe0;
  --lp-text-dim: #7f93ab;
  --lp-text-h: #ffffff;
  --lp-accent: #019dde;
  --lp-accent-2: #56c2f5;
  --lp-container: 1240px;

  width: 100%;
  background: var(--lp-bg);
  color: var(--lp-text);
  animation: lp-in 0.28s ease;
}

@keyframes lp-in {
  from { opacity: 0; transform: translateY(12px); }
  to { opacity: 1; transform: translateY(0); }
}

/* هر سکشن خودش کانتینر رو مدیریت می‌کنه تا با بقیه‌ی سایت هم‌عرض بمونه */
.lp-hero-inner,
.lp-stats-wrap,
.lp-stats,
.lp-section {
  width: 100%;
  max-width: var(--lp-container);
  margin-left: auto;
  margin-right: auto;
  box-sizing: border-box;
}

.lp-hero {
  min-height: calc(100vh - 70px);
  display: flex;
  flex-direction: column;
  justify-content: center;
  gap: 44px;
  padding: 90px 24px 28px;
  background:
    radial-gradient(circle at 85% 0%, rgba(1, 157, 222, 0.22), transparent 55%),
    radial-gradient(circle at 15% 30%, rgba(1, 157, 222, 0.14), transparent 50%);
  overflow: hidden;
}

.lp-hero-inner {
  display: grid;
  grid-template-columns: minmax(0, 1.15fr) minmax(0, 0.85fr);
  align-items: center;
  gap: 40px;
  padding: 0 24px;
}

.lp-hero-text {
  text-align: right;
}

.lp-hero-kicker {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  font-size: 12.5px;
  font-weight: 700;
  color: var(--lp-accent-2);
  background: rgba(1, 157, 222, 0.12);
  border: 1px solid rgba(1, 157, 222, 0.3);
  border-radius: 999px;
  padding: 6px 14px;
  margin-bottom: 20px;
}

.lp-hero h1 {
  font-size: clamp(28px, 3.8vw, 50px);
  line-height: 138%;
  color: var(--lp-text-h);
  margin: 0 0 16px;
  font-weight: 800;
}

.lp-hero h1 span {
  background: linear-gradient(90deg, var(--lp-accent-2), var(--lp-accent));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lp-hero p {
  font-size: 15.5px;
  color: var(--lp-text);
  line-height: 180%;
  max-width: 460px;
  margin: 0 0 28px;
}

p.lp-hero-typewriter {
  display: flex;
  align-items: center;
  font-size: 25px;
  font-weight: 700;
  line-height: 150%;
  max-width: 560px;
  margin: 0 0 28px;
  min-height: 38px;
}

.lp-hero-typewriter-static {
  color: var(--lp-text-h);
  flex-shrink: 0;
  white-space: pre;
}

.lp-hero-typewriter #lp-typewriter-text {
  background: linear-gradient(90deg, var(--lp-accent-2), var(--lp-accent));
  -webkit-background-clip: text;
  background-clip: text;
  color: transparent;
}

.lp-typewriter-cursor {
  display: inline-block;
  width: 2px;
  height: 1em;
  margin-inline-start: 3px;
  background: var(--lp-accent-2);
  animation: lp-cursor-blink 0.9s step-end infinite;
}

@keyframes lp-cursor-blink {
  0%, 100% { opacity: 1; }
  50% { opacity: 0; }
}

@media (prefers-reduced-motion: reduce) {
  .lp-typewriter-cursor {
    animation: none;
  }
}

.lp-hero-actions {
  display: flex;
  align-items: center;
  flex-wrap: wrap;
  gap: 12px;
}

.lp-hero-btn {
  border-radius: 14px;
  padding: 14px 26px;
  font-size: 14px;
  font-weight: 700;
  font-family: inherit;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease, background 0.2s ease;
  white-space: nowrap;
}

.lp-hero-btn-primary {
  border: none;
  color: #fff;
  background: linear-gradient(135deg, var(--lp-accent-2), var(--lp-accent));
  box-shadow: 0 10px 22px -10px rgba(1, 157, 222, 0.7);
}

.lp-hero-btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 26px -8px rgba(1, 157, 222, 0.8);
}

.lp-hero-btn-ghost {
  border: 1.5px solid var(--lp-border);
  background: transparent;
  color: var(--lp-text);
}

.lp-hero-btn-ghost:hover {
  border-color: var(--lp-accent);
  color: var(--lp-text-h);
  transform: translateY(-2px);
}

.lp-search {
  display: flex;
  gap: 10px;
  max-width: 460px;
}

.lp-search input {
  flex: 1;
  min-width: 0;
  border-radius: 14px;
  border: 1.5px solid var(--lp-border);
  background: var(--lp-card);
  color: var(--lp-text-h);
  padding: 14px 16px;
  font-size: 14px;
  transition: border-color 0.2s ease;
}

.lp-search input:focus {
  outline: none;
  border-color: var(--lp-accent);
}

.lp-search button {
  flex-shrink: 0;
  border: none;
  border-radius: 14px;
  padding: 0 26px;
  background: linear-gradient(135deg, var(--lp-accent-2), var(--lp-accent));
  color: #fff;
  font-weight: 700;
  font-size: 14px;
  cursor: pointer;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
  box-shadow: 0 10px 22px -10px rgba(1, 157, 222, 0.7);
}

.lp-search button:hover {
  transform: translateY(-2px);
  box-shadow: 0 14px 26px -8px rgba(1, 157, 222, 0.8);
}

/* ویژوال تزئینی سمت هدر — تصویر نمای کتابخانه، هم‌راستا با استایل بلاب بنر */
.lp-hero-visual {
  position: relative;
  height: 460px;
  min-width: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lp-hero-visual img {
  position: relative;
  z-index: 2;
  width: 100%;
  max-width: 580px;
  height: auto;
  filter: drop-shadow(0 20px 34px rgba(2, 12, 26, 0.55));
  animation: library-visual-float 6s ease-in-out infinite;
}

@media (prefers-reduced-motion: reduce) {
  .lp-hero-visual img {
    animation: none;
  }
}

.lp-visual-glow {
  position: absolute;
  border-radius: 50%;
  filter: blur(46px);
  opacity: 0.5;
  pointer-events: none;
  animation: library-blob-drift 9s ease-in-out infinite;
}

.lp-visual-glow-1 {
  width: 180px;
  height: 180px;
  top: -20px;
  inset-inline-end: -30px;
  background: radial-gradient(circle, #33b5ea 0%, transparent 70%);
}

.lp-visual-glow-2 {
  width: 160px;
  height: 160px;
  bottom: -30px;
  inset-inline-start: -20px;
  background: radial-gradient(circle, #019dde 0%, transparent 70%);
  animation-delay: -4.5s;
}

@media (prefers-reduced-motion: reduce) {
  .lp-visual-card,
  .lp-visual-glow {
    animation: none;
  }
}

.lp-stats-wrap {
  display: flex;
  align-items: center;
  gap: 18px;
  padding: 4px 24px 18px;
}

.lp-stats-label {
  flex-shrink: 0;
  font-size: 13px;
  color: var(--lp-text-dim);
  white-space: nowrap;
}

.lp-stats-line {
  flex: 1;
  height: 1px;
  background: linear-gradient(to left, rgba(169, 196, 221, 0.35), rgba(169, 196, 221, 0));
}

/* کاروسل بی‌نهایت: نوار دو بار رندر شده (lp-stats-set) پشت سرهم می‌شینه و
   با translateX تا دقیقاً نصف عرضش (یعنی طول یک ست کامل) جابه‌جا می‌شه؛ چون
   ست دوم عیناً همون ست اوله، لحظه‌ی ریست به ۰ هیچ پرشی حس نمی‌شه — لوپ بی‌درز. */
.lp-stats {
  direction: ltr;
  overflow: hidden;
  padding: 8px 24px 4px;
  -webkit-mask-image: linear-gradient(to right, transparent 0, #000 40px, #000 calc(100% - 40px), transparent 100%);
  mask-image: linear-gradient(to right, transparent 0, #000 40px, #000 calc(100% - 40px), transparent 100%);
}

.lp-stats-track {
  display: flex;
  direction: ltr;
  width: max-content;
  animation: lp-stats-scroll 26s linear infinite;
}

.lp-stats:hover .lp-stats-track {
  animation-play-state: paused;
}

.lp-stats-set {
  display: flex;
  direction: rtl;
  flex-shrink: 0;
  gap: 10px;
  padding-inline-end: 10px;
}

@keyframes lp-stats-scroll {
  from { transform: translateX(0); }
  to { transform: translateX(-25%); }
}

@media (prefers-reduced-motion: reduce) {
  .lp-stats-track {
    animation: none;
  }
}

.lp-stat-chip {
  flex-shrink: 0;
  display: flex;
  align-items: center;
  gap: 7px;
  background: #012d42;
  border: 1px solid var(--lp-border);
  border-radius: 999px;
  padding: 9px 14px;
  font-size: 12.5px;
  color: var(--lp-text);
  white-space: nowrap;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.lp-stat-chip:hover {
  border-color: rgba(1, 157, 222, 0.4);
  transform: translateY(-2px);
}

/* منوی بالای صفحه: پنج آیتم پیل‌مانند، افقی، وسط‌چین، عرضش به‌اندازه‌ی محتواشه */
.lp-top-menu {
  display: flex;
  justify-content: center;
  max-width: var(--lp-container);
  margin: 8px auto 0;
  padding: 0 24px;
  box-sizing: border-box;
}

.lp-top-menu-list {
  display: flex;
  align-items: stretch;
  gap: 4px;
  list-style: none;
  margin: 0;
  padding: 8px;
  max-width: 100%;
  background: linear-gradient(115deg, rgba(113, 144, 168, 0.3), rgba(48, 76, 101, 0.4));
  border: 1px solid var(--lp-border);
  border-radius: 24px;
  overflow-x: auto;
  scrollbar-width: none;
}

.lp-top-menu-list::-webkit-scrollbar {
  display: none;
}

.lp-top-menu-item {
  flex: 0 0 auto;
}

.lp-top-menu-link {
  position: relative;
  display: flex;
  align-items: center;
  gap: 10px;
  height: 61px;
  padding: 0 20px;
  border-radius: 16px;
  color: var(--lp-text);
  text-decoration: none;
  white-space: nowrap;
  font-size: 14px;
  font-weight: 500;
  overflow: hidden;
  transition: background 0.2s ease, color 0.2s ease, transform 0.2s ease;
}

.lp-top-menu-link:hover {
  color: var(--lp-text-h);
  transform: translateY(-1px);
}

.lp-top-menu-link.is-active {
  color: var(--lp-text-h);
  background: linear-gradient(115deg, #7190a8, #304c65);
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.25);
}

.lp-top-menu-link.is-active::before {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(75deg, transparent 20%, rgba(255, 255, 255, 0.28) 42%, transparent 64%);
  background-size: 220% 100%;
  background-position: 130% 0;
  animation: lp-menu-shine 3.2s ease-in-out infinite;
  pointer-events: none;
}

@keyframes lp-menu-shine {
  0%, 35% { background-position: 130% 0; }
  65%, 100% { background-position: -30% 0; }
}

.lp-top-menu-icon {
  position: relative;
  display: flex;
  align-items: center;
  justify-content: center;
  width: 22px;
  height: 22px;
  flex-shrink: 0;
  color: inherit;
}

.lp-top-menu-icon svg {
  width: 100%;
  height: 100%;
}

/* آفست اسکرول برای اینکه سکشن‌ها زیر منوی بالا گم نشن */
.lp-section {
  scroll-margin-top: 110px;
}

@media (prefers-reduced-motion: reduce) {
  .lp-top-menu-link.is-active::before {
    animation: none;
  }
}

@media (max-width: 640px) {
  .lp-top-menu {
    justify-content: flex-start;
  }

  .lp-top-menu-link {
    height: 52px;
    padding: 0 14px;
    font-size: 13px;
  }
}

.lp-section {
  padding: 46px 24px 6px;
  margin-bottom: 48px;
}

.library-page > .lp-section:last-of-type {
  margin-bottom: 0;
  padding-bottom: 48px;
}

.lp-section-head {
  display: flex;
  align-items: baseline;
  justify-content: space-between;
  margin-bottom: 20px;
}

.lp-section-title {
  display: flex;
  align-items: center;
  gap: 10px;
}

.lp-section-head h2 {
  font-size: 21px;
  color: var(--lp-text-h);
  font-weight: 800;
  margin: 0;
}

.lp-section-icon {
  display: flex;
  align-items: center;
  justify-content: center;
  width: 40px;
  height: 40px;
  border-radius: 12px;
  flex-shrink: 0;
  background: linear-gradient(135deg, rgba(255, 255, 255, 0.14), rgba(255, 255, 255, 0.02));
  border: 1px solid var(--lp-border);
  color: #ffffff;
}

.lp-section-icon svg {
  width: 20px;
  height: 20px;
}

.lp-section-link {
  font-size: 13px;
  color: var(--lp-text-dim);
  text-decoration: none;
  background: none;
  border: none;
  cursor: pointer;
  font-family: inherit;
  transition: color 0.2s ease;
}

.lp-section-link:hover {
  color: var(--lp-accent-2);
}

/* گرید سه‌ستونه‌ی دسکتاپ؛ زیر ۷۶۸px تبدیل میشه به ردیف اسکرول‌شونده */
.lp-grid-3 {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 18px;
}

.lp-scroll-row {
  padding-bottom: 6px;
}

/* تازه‌ها */
.lp-news-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.lp-news-item {
  display: flex;
  align-items: center;
  gap: 16px;
  background: #00202e;
  border: 1px solid #0c6b93;
  border-radius: 16px;
  padding: 16px 20px;
  text-decoration: none;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.lp-news-item:hover {
  border-color: rgba(1, 157, 222, 0.6);
  transform: translateY(-2px);
}

.lp-news-icon {
  flex-shrink: 0;
  width: 48px;
  height: 48px;
  border-radius: 13px;
  display: flex;
  align-items: center;
  justify-content: center;
  overflow: hidden;
}

.lp-news-icon img {
  width: 100%;
  height: 100%;
  display: block;
}

.lp-news-text {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  gap: 4px;
}

.lp-news-title {
  font-size: 14px;
  color: var(--lp-text-h);
  line-height: 160%;
}

.lp-news-meta {
  font-size: 12px;
  color: var(--lp-text-dim);
  white-space: nowrap;
}

.lp-news-arrow {
  flex-shrink: 0;
  width: 20px;
  height: 20px;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: color 0.2s ease, transform 0.2s ease;
}

.lp-news-arrow svg {
  width: 100%;
  height: 100%;
}

.lp-news-item:hover .lp-news-arrow {
  color: var(--lp-accent-2);
  transform: translateX(-3px);
}

.lp-news-viewall {
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  width: fit-content;
  margin: 14px auto 0;
  padding: 10px 18px;
  background: #003046;
  border: 1px solid #019dde;
  border-radius: 14px;
  color: var(--lp-text-h);
  font-family: inherit;
  font-size: 14px;
  font-weight: 600;
  cursor: pointer;
  white-space: nowrap;
  transition: border-color 0.2s ease, color 0.2s ease;
}

.lp-news-viewall svg {
  width: 18px;
  height: 18px;
  flex-shrink: 0;
}

.lp-news-viewall:hover {
  border-color: rgba(1, 157, 222, 0.35);
  color: var(--lp-accent-2);
}

/* دیزاین سیستم‌ها */
.lp-ds-card {
  border-radius: 16px;
  overflow: hidden;
  background: linear-gradient(135deg, rgba(113, 144, 168, 0.4), rgba(48, 76, 101, 0.4));
  border: 1px solid var(--lp-border);
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.lp-ds-card:hover {
  border-color: rgba(1, 157, 222, 0.35);
  transform: translateY(-3px);
}

.lp-ds-cover {
  aspect-ratio: 2 / 1;
  overflow: hidden;
  transition: transform 0.35s ease;
}

.lp-ds-card:hover .lp-ds-cover {
  transform: scale(1.035);
}

.lp-ds-cover img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}


.lp-ds-body {
  padding: 14px 16px 16px;
  background: linear-gradient(135deg, rgba(113, 144, 168, 0.4), rgba(48, 76, 101, 0.4));
}

.lp-ds-title {
  font-size: 13.5px;
  color: var(--lp-text-h);
  font-weight: 700;
  margin-bottom: 10px;
}

.lp-tool-tags {
  display: flex;
  gap: 6px;
  flex-wrap: wrap;
}

.lp-tool-tag {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  height: 32px;
  box-sizing: border-box;
  font-size: 14px;
  font-weight: 600;
  color: var(--lp-text-h);
  background: rgba(40, 40, 40, 0.3);
  border: none;
  border-radius: 10px;
  padding: 0 12px;
}

.lp-tool-icon {
  width: auto;
  height: 28px;
  flex-shrink: 0;
}

/* کتابخانه: کارت شاخص + گرید کتاب‌ها */
.lp-library-grid {
  display: grid;
  grid-template-columns: 1fr minmax(0, 320px);
  gap: 20px;
}

.lp-featured-book {
  position: relative;
  overflow: hidden;
  border-radius: 20px;
  border: 1px solid var(--lp-border);
  background: linear-gradient(135deg, rgba(113, 144, 168, 0.4), rgba(48, 76, 101, 0.4));
  padding: 20px 20px 14px;
  display: flex;
  flex-direction: column;
  align-items: center;
  text-align: center;
}

.lp-featured-badge {
  position: absolute;
  top: 0;
  inset-inline-start: 0;
  font-size: 11px;
  font-weight: 700;
  color: #ffffff;
  background: #003046;
  border-radius: 0 20px 0 14px;
  padding: 10px 16px;
}

.lp-featured-covers {
  position: relative;
  display: flex;
  align-items: flex-end;
  justify-content: center;
  gap: -14px;
  height: 130px;
  width: 100%;
  margin: 36px 0 16px;
}

.lp-featured-cover {
  flex-shrink: 0;
  width: 66px;
  height: 92px;
  padding: 0;
  border: none;
  border-radius: 8px;
  overflow: hidden;
  opacity: 0.45;
  cursor: pointer;
  background: none;
  transform: translateY(6px);
  box-shadow: 0 12px 22px -10px rgba(0, 0, 0, 0.6);
  transition: transform 0.3s ease, opacity 0.3s ease, width 0.3s ease, height 0.3s ease, box-shadow 0.3s ease;
}

.lp-featured-cover img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.lp-featured-cover:hover {
  opacity: 0.7;
}

.lp-featured-cover:first-child {
  margin-inline-end: -14px;
}

.lp-featured-cover:last-child {
  margin-inline-start: -14px;
}

.lp-featured-cover.is-active {
  width: 92px;
  height: 130px;
  opacity: 1;
  transform: translateY(0);
  z-index: 2;
  cursor: default;
  box-shadow: 0 16px 26px -8px rgba(0, 0, 0, 0.7);
}

.lp-featured-dots {
  display: flex;
  gap: 6px;
  margin-bottom: 14px;
}

.lp-featured-dots span {
  width: 6px;
  height: 6px;
  border-radius: 50%;
  background: var(--lp-border);
  cursor: pointer;
  transition: width 0.3s ease, background 0.2s ease;
}

.lp-featured-dots span.is-active {
  width: 18px;
  border-radius: 999px;
  background: var(--lp-accent-2);
}

.lp-featured-title {
  font-size: 17px;
  font-weight: 800;
  color: var(--lp-text-h);
  margin-bottom: 18px;
}

.lp-featured-cta {
  display: block;
  width: 100%;
  box-sizing: border-box;
  border: 1.5px solid var(--lp-accent);
  background: #003046;
  color: var(--lp-text-h);
  font-weight: 700;
  font-size: 13.5px;
  border-radius: 12px;
  padding: 12px;
  cursor: pointer;
  text-decoration: none;
  text-align: center;
  transition: background 0.2s ease;
}

.lp-featured-cta:hover {
  background: #001e2c;
  color: #ffffff;
}

.lp-book-grid {
  display: grid;
  grid-template-columns: repeat(2, 1fr);
  gap: 28px;
}

.lp-book-card {
  position: relative;
  overflow: visible;
  min-height: 168px;
  display: flex;
  align-items: flex-end;
  gap: 20px;
  background: linear-gradient(135deg, rgba(113, 144, 168, 0.4), rgba(48, 76, 101, 0.4));
  border: 1px solid var(--lp-border);
  border-radius: 18px;
  padding: 22px;
  padding-top: 40px;
  box-sizing: border-box;
  text-decoration: none;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.lp-book-card:hover {
  border-color: rgba(1, 157, 222, 0.35);
  transform: translateY(-3px);
}

.lp-book-cover {
  flex-shrink: 0;
  width: 124px;
  height: 172px;
  margin-top: -70px;
  border-radius: 12px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
  box-shadow: 0 20px 30px -10px rgba(0, 0, 0, 0.65);
}

.lp-book-body {
  flex: 1;
  min-width: 0;
  height: 100%;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.lp-book-title {
  font-size: 17px;
  font-weight: 700;
  color: var(--lp-text-h);
  line-height: 145%;
  display: -webkit-box;
  -webkit-line-clamp: 3;
  -webkit-box-orient: vertical;
  overflow: hidden;
}

.lp-book-author {
  display: flex;
  align-items: center;
  gap: 10px;
  font-size: 14px;
  font-weight: 600;
  color: var(--lp-text);
  margin-top: 16px;
}

.lp-book-author-icon {
  flex-shrink: 0;
  width: 24px;
  height: 24px;
  border-radius: 8px;
  color: #ffffff;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lp-book-author-icon svg {
  width: 24px;
  height: 24px;
}

.lp-book-year {
  font-size: 12.5px;
  color: var(--lp-text-dim);
  margin-top: 6px;
}

.lp-book-arrow {
  position: absolute;
  bottom: 18px;
  inset-inline-end: 18px;
  width: 38px;
  height: 38px;
  border-radius: 10px;
  background: #162935;
  color: #0095d4;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  transform: translateY(4px);
  transition: opacity 0.25s ease, transform 0.25s ease;
}

.lp-book-arrow svg {
  width: 20px;
  height: 20px;
}

.lp-book-card:hover .lp-book-arrow {
  opacity: 1;
  transform: translateY(0);
}

/* آیکون‌پک */
.lp-icon-pack {
  border-radius: 16px;
  overflow: hidden;
  border: 1px solid var(--lp-border);
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.lp-icon-pack:hover {
  border-color: rgba(1, 157, 222, 0.35);
  transform: translateY(-3px);
}

.lp-icon-pack-top {
  aspect-ratio: 2 / 1;
  overflow: hidden;
}

.lp-icon-pack-top img {
  display: block;
  width: 100%;
  height: 100%;
  object-fit: cover;
  transition: transform 0.35s ease;
}

.lp-icon-pack:hover .lp-icon-pack-top img {
  transform: scale(1.035);
}

.lp-icon-pack-bottom {
  background: linear-gradient(135deg, rgba(113, 144, 168, 0.4), rgba(48, 76, 101, 0.4));
  padding: 12px 16px;
  display: flex;
  align-items: center;
  justify-content: space-between;
  font-size: 12.5px;
}

.lp-icon-pack-count {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  color: #ffffff;
  font-weight: 700;
  background: rgba(40, 40, 40, 0.3);
  border-radius: 999px;
  padding: 6px 12px;
}

.lp-icon-pack-count svg {
  width: 15px;
  height: 15px;
  flex-shrink: 0;
}

/* نرم‌افزار */
.lp-soft-card {
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 18px;
  background: linear-gradient(135deg, rgba(113, 144, 168, 0.4), rgba(48, 76, 101, 0.4));
  border: 1px solid var(--lp-border);
  border-radius: 18px;
  padding: 24px 28px;
  transition: border-color 0.2s ease, transform 0.2s ease;
}

.lp-soft-card:hover {
  border-color: rgba(1, 157, 222, 0.35);
  transform: translateY(-3px);
}

.lp-soft-main {
  display: flex;
  align-items: center;
  gap: 20px;
  min-width: 0;
}

.lp-soft-icon {
  flex-shrink: 0;
  width: 76px;
  height: 76px;
  border-radius: 18px;
  overflow: hidden;
  display: flex;
}

.lp-soft-icon img {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.lp-soft-info {
  display: flex;
  flex-direction: column;
  gap: 14px;
  min-width: 0;
}

.lp-soft-name {
  font-size: 18px;
  color: var(--lp-text-h);
  font-weight: 700;
}

.lp-soft-platforms {
  display: flex;
  gap: 8px;
}

.lp-soft-platform {
  width: 40px;
  height: 40px;
  border-radius: 10px;
  background: rgba(40, 40, 40, 0.3);
  color: var(--lp-text-h);
  display: flex;
  align-items: center;
  justify-content: center;
  text-decoration: none;
  transition: transform 0.2s ease, background 0.2s ease;
}

.lp-soft-platform:hover {
  transform: translateY(-2px);
  background: rgba(40, 40, 40, 0.5);
}

.lp-soft-platform svg {
  width: 20px;
  height: 20px;
}

.lp-soft-platform-globe {
  color: #0489ff;
}

.lp-soft-platform-windows {
  color: #00adef;
}

.lp-soft-download {
  flex-shrink: 0;
  width: 32px;
  height: 32px;
  border-radius: 8px;
  background: none;
  color: var(--lp-text-dim);
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease, color 0.2s ease;
}

.lp-soft-download:hover {
  background: #162935;
  color: #0095d4;
}

.lp-soft-download svg {
  width: 24px;
  height: 24px;
}

/* پیشنهادها */
.lp-rec-card {
  display: flex;
  flex-direction: column;
  aspect-ratio: 1 / 1;
  border-radius: 16px;
  overflow: hidden;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.lp-rec-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 16px 30px -12px rgba(0, 0, 0, 0.55);
}

.lp-rec-card-image {
  flex: 1;
  min-height: 150px;
  background-size: cover;
  background-position: center;
  background-repeat: no-repeat;
}

.lp-rec-card-band {
  padding: 14px 18px;
}

.lp-rec-title {
  display: block;
  font-size: 13.5px;
  font-weight: 800;
  line-height: 155%;
  color: #fff;
}

/* ---------- داستان تجربه‌کاربری ---------- */
.lp-story-card {
  display: flex;
  flex-direction: row-reverse;
  align-items: center;
  gap: 36px;
  max-width: var(--lp-container);
  margin: 0 auto;
  padding: 24px;
  border-radius: 22px;
  background: linear-gradient(180deg, #063950, #052839);
  border: 1px solid var(--lp-border);
}

.lp-story-mock {
  position: relative;
  flex: 1.1;
  min-width: 0;
  border-radius: 16px;
  overflow: hidden;
  animation: library-visual-float 7s ease-in-out infinite;
}

.lp-story-mock img {
  display: block;
  width: 100%;
  height: auto;
  border-radius: 16px;
}

.lp-story-text {
  flex: 1;
  min-width: 0;
}

.lp-story-text h2 {
  font-size: 24px;
  font-weight: 800;
  color: var(--lp-text-h);
  margin: 0 0 14px;
}

.lp-story-text p {
  font-size: 14px;
  line-height: 190%;
  color: var(--lp-text);
  margin: 0 0 22px;
}

.lp-story-text a.lp-hero-btn,
.lp-cycle-text a.lp-hero-btn {
  display: inline-block;
  text-decoration: none;
}

/* ---------- چرخه‌ی ساختن ---------- */
.lp-cycle-card {
  display: flex;
  flex-direction: row-reverse;
  align-items: center;
  gap: 36px;
  max-width: var(--lp-container);
  margin: 0 auto;
  padding: 40px;
  border-radius: 22px;
  background: linear-gradient(180deg, #063950, #052839);
  border: 1px solid var(--lp-border);
}

.lp-cycle-visual {
  position: relative;
  flex: 0.8;
  min-width: 0;
  height: 160px;
  display: flex;
  align-items: center;
  justify-content: center;
}

.lp-cycle-figure-wrap {
  position: relative;
  width: 100%;
  max-width: 140px;
  margin: 0 auto;
}

.lp-cycle-figure {
  display: block;
  width: 100%;
  height: auto;
  animation: library-visual-float 6.5s ease-in-out infinite;
  animation-delay: -2s;
}

.lp-cycle-cursor {
  position: absolute;
  width: 40%;
  height: auto;
  filter: drop-shadow(0 8px 14px rgba(0, 0, 0, 0.4));
}

.lp-cycle-cursor-you {
  top: 46%;
  left: -48%;
  width: 40%;
  transform-origin: 85% 20%;
  animation: library-cursor-point-you 4.5s ease-in-out infinite;
}

.lp-cycle-cursor-dux {
  top: 69%;
  left: 99%;
  width: 48%;
  transform-origin: 10% 15%;
  animation: library-cursor-point-dux 4.5s ease-in-out infinite;
  animation-delay: -2.25s;
}

@keyframes library-cursor-point-you {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  30% { transform: translate(10px, -6px) rotate(-6deg); }
  55% { transform: translate(16px, 2px) rotate(-2deg); }
  80% { transform: translate(4px, 6px) rotate(2deg); }
}

@keyframes library-cursor-point-dux {
  0%, 100% { transform: translate(0, 0) rotate(0deg); }
  30% { transform: translate(-10px, -8px) rotate(6deg); }
  55% { transform: translate(-16px, -2px) rotate(2deg); }
  80% { transform: translate(-4px, -8px) rotate(-2deg); }
}

@media (prefers-reduced-motion: reduce) {
  .lp-cycle-cursor {
    animation: none;
  }
}

.lp-cycle-text {
  flex: 1.2;
  min-width: 0;
}

.lp-cycle-text h2 {
  font-size: 26px;
  font-weight: 800;
  color: var(--lp-text-h);
  margin: 0 0 14px;
}

.lp-cycle-text p {
  font-size: 14px;
  line-height: 190%;
  color: var(--lp-text);
  margin: 0 0 22px;
  max-width: 520px;
}

/* ---------- فوتر صفحه‌ی کتابخانه ---------- */
.lp-page-footer {
  margin-top: 46px;
  padding: 44px 24px 0;
  border-top: 1px solid var(--lp-border);
  background: linear-gradient(180deg, #063950, #052839);
}

.lp-page-footer-inner {
  display: grid;
  grid-template-columns: repeat(3, minmax(0, 1fr)) minmax(0, 1.6fr);
  gap: 28px;
  max-width: var(--lp-container);
  margin: 0 auto;
  padding-bottom: 36px;
}

.lp-footer-col h4 {
  font-size: 13.5px;
  font-weight: 700;
  color: var(--lp-text-h);
  margin: 0 0 16px;
}

.lp-footer-col ul {
  list-style: none;
  margin: 0;
  padding: 0;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.lp-footer-col ul a {
  font-size: 12.5px;
  color: var(--lp-text-dim);
  text-decoration: none;
  transition: color 0.2s ease;
}

.lp-footer-col ul a:hover {
  color: var(--lp-accent-2);
}

.lp-footer-brand-col {
  display: flex;
  flex-direction: column;
  align-items: flex-start;
}

.lp-footer-logo {
  display: flex;
  align-items: center;
  gap: 8px;
  margin-bottom: 16px;
}

.lp-footer-logo span {
  font-size: 13px;
  font-weight: 800;
  line-height: 130%;
  color: var(--lp-text-h);
  font-family: inherit;
}

.lp-footer-brand-col p {
  font-size: 12px;
  line-height: 190%;
  color: var(--lp-text-dim);
  margin: 0 0 18px;
}

.lp-footer-social {
  display: flex;
  align-items: center;
  gap: 14px;
}

.lp-footer-social a {
  display: flex;
  color: var(--lp-text-dim);
  transition: color 0.2s ease;
}

.lp-footer-social a:hover {
  color: var(--lp-accent-2);
}

.lp-page-footer-bottom {
  max-width: var(--lp-container);
  margin: 0 auto;
  padding: 18px 0;
  border-top: 1px solid var(--lp-border);
  text-align: center;
  font-size: 12px;
  color: var(--lp-text-dim);
}

@media (max-width: 860px) {
  .lp-story-card,
  .lp-cycle-card {
    flex-direction: column;
  }

  .lp-story-mock,
  .lp-cycle-visual {
    width: 100%;
  }

  .lp-page-footer-inner {
    grid-template-columns: repeat(2, minmax(0, 1fr));
  }
}

/* ---------- تبلت ---------- */
@media (max-width: 1024px) {
  .lp-hero-inner {
    grid-template-columns: 1fr;
    gap: 28px;
  }

  .lp-hero-visual {
    display: none;
  }

  .lp-library-grid {
    grid-template-columns: 1fr;
  }

  .lp-featured-book {
    flex-direction: row;
    text-align: right;
    align-items: center;
    gap: 20px;
  }

  .lp-featured-covers {
    width: 160px;
    flex-shrink: 0;
    margin-bottom: 0;
  }
}

@media (max-width: 860px) {
  .lp-grid-3 {
    grid-template-columns: repeat(2, 1fr);
  }

  .lp-book-grid {
    grid-template-columns: 1fr;
  }
}

/* ---------- موبایل: ردیف‌های کارتی با اسکرول افقی ---------- */
@media (max-width: 640px) {
  .lp-hero {
    min-height: auto;
    padding: 40px 0 22px;
    text-align: center;
  }

  .lp-hero-inner {
    padding: 0 20px;
  }

  .lp-hero-text {
    text-align: center;
  }

  .lp-hero p {
    margin-left: auto;
    margin-right: auto;
  }

  .lp-search {
    margin: 0 auto;
  }

  .lp-stats-wrap {
    padding: 30px 20px 14px;
  }

  .lp-stats {
    padding: 0 20px 4px;
  }

  .lp-section {
    padding: 32px 20px 6px;
  }

  .lp-section-head h2 {
    font-size: 17px;
  }

  .lp-news-text {
    flex-direction: column;
    align-items: flex-start;
    gap: 5px;
  }

  .lp-featured-book {
    flex-direction: column;
    text-align: center;
    align-items: center;
  }

  .lp-featured-covers {
    width: 100%;
  }

  .lp-grid-3.lp-scroll-row {
    display: flex;
    grid-template-columns: unset;
    gap: 12px;
    overflow-x: auto;
    scroll-snap-type: x proximity;
    scrollbar-width: none;
  }

  .lp-grid-3.lp-scroll-row::-webkit-scrollbar {
    display: none;
  }

  .lp-grid-3.lp-scroll-row > * {
    flex-shrink: 0;
    width: 220px;
    scroll-snap-align: start;
  }

  .lp-grid-3.lp-scroll-row .lp-book-card {
    width: 160px;
  }

  .lp-grid-3 {
    grid-template-columns: 1fr;
  }
}
