/* Compatibility with app.js */
.hidden { display: none !important; }
#landing.hidden, #cabinet-readonly.hidden, #cabinet-onboarding.hidden, #public-stats.hidden { display: none !important; }
#login-modal { display: none; }
#login-modal:not(.hidden) { display: flex !important; }
.cabinet-section.hidden { display: none !important; }
.header-dropdown-title { font-size: 12px; color: var(--text-muted); padding: 8px 12px; }
.header-dropdown-account { padding: 10px 14px; border-radius: 8px; cursor: pointer; }
.header-dropdown-account:hover { background: rgba(255,255,255,0.05); }
.header-dropdown-account.is-active { background: rgba(255,45,123,0.08); }
.header-dropdown-account-type { font-size: 11px; color: var(--text-muted); margin-left: 4px; }
.header-dropdown-account-remove { background: none; border: none; color: #ff4444; cursor: pointer; padding: 0 4px; font-size: 18px; }
.header-dropdown-divider { height: 1px; background: var(--border-color); margin: 6px 0; }
.header-dropdown-add { display: block; width: 100%; text-align: left; padding: 10px 14px; border: none; background: none; color: var(--text-muted); cursor: pointer; font-size: 13px; border-radius: 8px; }
.header-dropdown-add:hover:not(.disabled) { background: rgba(255,255,255,0.05); color: var(--text-primary); }
.header-dropdown-add.disabled { opacity: 0.5; cursor: not-allowed; }
.header-dropdown-logout { display: block; width: 100%; text-align: left; padding: 10px 14px; border: none; background: none; color: #ff4444; cursor: pointer; font-size: 13px; border-radius: 8px; font-family: inherit; }
.header-dropdown-logout:hover { background: rgba(255, 68, 68, 0.08); }

/* Account switcher button (header) */
.header-user-wrap .account-current {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 50px;
  padding: 10px 18px;
  color: var(--text-primary);
  font-family: inherit;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s;
}
.header-user-wrap .account-current:hover {
  border-color: #ff2d7b;
}
.account-badge {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 20px;
}
.account-badge.personal {
  background: rgba(255, 45, 123, 0.15);
  color: #ff2d7b;
}
.account-badge.group {
  background: rgba(0, 212, 255, 0.15);
  color: #00d4ff;
}
#header-account-dropdown {
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 240px;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 8px;
  z-index: 50;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
}
#header-account-dropdown.hidden { display: none !important; }
.film-streaming-btn .streaming-btn-emoji { margin-left: 6px; }
.plan-info { padding: 24px; }
.plan-meta, .plan-date-line, .plan-time-line, .plan-type { font-size: 14px; color: var(--text-muted); }
.plan-title { font-family: 'Unbounded', sans-serif; font-size: 18px; font-weight: 700; color: var(--text-primary); }
.plans-split { display: grid; grid-template-columns: 1fr 1fr; gap: 32px; margin-top: 24px; }
@media (max-width: 768px) { .plans-split { grid-template-columns: 1fr; } }
.plans-today-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 16px; margin-bottom: 24px; }
.plans-today-wrap.hidden { display: none !important; }
.cabinet-plans-today { margin-bottom: 24px; }
.cabinet-subtitle { font-size: 18px; margin-bottom: 16px; }
.empty-hint { color: var(--text-muted); margin-bottom: 16px; }
.plans-empty-actions { display: flex; gap: 12px; flex-wrap: wrap; }
.plans-empty-actions .btn { min-width: 240px; flex: 1 1 0; }
.cabinet-hint { color: var(--text-muted); font-size: 14px; margin-bottom: 20px; }
.section-title-row, .section-unwatched-header { display: flex; align-items: center; justify-content: space-between; flex-wrap: wrap; gap: 16px; margin-bottom: 20px; }
.section-with-search { display: flex; flex-direction: column; gap: 12px; margin-bottom: 20px; }
.section-with-search .section-title { margin-bottom: 0; }
.unwatched-toolbar { display: flex; align-items: center; gap: 12px; }
.unwatched-sort-select { padding: 10px 14px; background: var(--bg-surface); border: 1px solid var(--border-color); border-radius: 8px; color: var(--text-primary); font-size: 14px; }
.section-search { padding: 12px 16px; background: var(--bg-surface); border: 1px solid var(--border-color); border-radius: 8px; color: var(--text-primary); font-size: 14px; flex: 1; min-width: 0; }
.login-status { margin-top: 12px; font-size: 14px; }
.login-status.error { color: #ff4444; }
.login-status.success { color: #4ade80; }
.film-description { font-size: 13px; color: var(--text-muted); margin-top: 4px; }
.btn { padding: 10px 20px; border-radius: 50px; font-size: 14px; font-weight: 600; text-decoration: none; display: inline-flex; align-items: center; }
.btn-small { padding: 10px 16px; font-size: 13px; }
.cabinet-nav { display: flex; gap: 4px; flex-wrap: nowrap; align-items: center; margin-bottom: 24px; border-bottom: 1px solid var(--border-color); overflow-x: auto; padding-bottom: 4px; }
.cabinet-nav-btn { padding: 14px 18px; background: none; border: none; border-bottom: 3px solid transparent; color: var(--text-muted); font-size: 15px; cursor: pointer; display: inline-flex; align-items: center; gap: 6px; flex-shrink: 0; }
.cabinet-nav-btn-emoji { flex-shrink: 0; }
.cabinet-nav-btn.active { color: #ff2d7b; border-bottom-color: #ff2d7b; }
.cabinet-nav-extension { margin-left: auto; flex-shrink: 0; align-self: center; }
.cabinet-nav-extension:hover { transform: none; }
@media (max-width: 768px) { .cabinet-nav-extension { display: none !important; } }
#cabinet-readonly, #cabinet-onboarding { display: none; padding: 40px 24px; max-width: 1200px; margin: 0 auto; }
#cabinet-readonly:not(.hidden), #cabinet-onboarding:not(.hidden) { display: block; }
.cabinet-sections { max-width: 1200px; margin: 0 auto; }
.section-title-emoji { margin-right: 6px; }
.section-title-text { }
.about-project-block { display: flex; flex-direction: column; align-items: center; text-align: center; max-width: 600px; margin: 0 auto; }
.about-photo-wrap { margin-bottom: 20px; }
.about-photo { width: 120px; height: 120px; border-radius: 50%; object-fit: cover; border: 2px solid var(--border-color); }
.about-project-text { text-align: left; }
.about-project-text p { margin-bottom: 16px; line-height: 1.7; }
.about-project-text a { color: #ff2d7b; }
.cabinet-articles { margin-top: 32px; }
.cabinet-articles h3 { font-size: 20px; }
.cabinet-articles .articles-grid { margin-top: 0; }
.onboard-scenarios { display: grid; grid-template-columns: repeat(auto-fit, minmax(260px, 1fr)); gap: 24px; margin-bottom: 24px; }
.onboard-card { background: var(--bg-surface); border: 1px solid var(--border-color); border-radius: 16px; padding: 24px; }
.onboard-card h3 { font-size: 18px; margin-bottom: 12px; }
.onboard-card ul { margin: 12px 0 20px; padding-left: 20px; }
.onboard-card a { color: #ff2d7b; }
.cabinet-welcome { font-size: 28px; margin-bottom: 12px; }
.cabinet-empty-lead { font-size: 18px; color: var(--text-muted); margin-bottom: 24px; }
.cabinet-onboard-intro { margin-bottom: 20px; }
.cabinet-onboard-note { color: var(--text-muted); margin-top: 24px; }
.onboard-empty-hint { color: var(--text-muted); margin-bottom: 20px; }
.article-card-icon { font-size: 28px; }
.article-card-title { font-family: 'Unbounded', sans-serif; font-size: 16px; font-weight: 700; }
.article-card-desc { font-size: 14px; color: var(--text-muted); }
.faq-block { max-width: 800px; margin: 0 auto; }
.faq-block h3, .cabinet-articles h3 { margin-bottom: 16px; }
.faq-head { padding: 20px; cursor: pointer; display: flex; justify-content: space-between; align-items: center; background: var(--bg-surface); font-weight: 600; }
.faq-body { padding: 0 20px; max-height: 0; overflow: hidden; transition: all 0.3s; background: rgba(255,255,255,0.02); }
.faq-item.open .faq-body { padding: 20px; max-height: 500px; }

:root {
  --bg-main: #09090b;
  --bg-surface: #131318;
  --bg-surface-alt: #1a1a22;
  --text-primary: #eeeef0;
  --text-muted: #6b6b76;
  --stats-pink: #ff2d7b;
  --stats-purple: #9b4dff;
  --stats-cyan: #00d4ff;
  --stats-green: #34d399;
  --stats-amber: #fbbf24;
  --gradient: linear-gradient(135deg, #ff2d7b, #9b4dff, #00d4ff);
  --border-color: rgba(255, 255, 255, 0.06);
  --border-color-alt: rgba(255, 255, 255, 0.08);
}

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

html {
  scroll-behavior: smooth;
}

body {
  background: var(--bg-main);
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  font-size: 16px;
  line-height: 1.6;
  overflow-x: hidden;
}

.parallax-bg {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  pointer-events: none;
  z-index: 0;
  overflow: hidden;
}

.parallax-emoji {
  position: absolute;
  pointer-events: none;
  will-change: transform;
}

.content-wrapper {
  position: relative;
  z-index: 1;
}

header {
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(10px);
  background: rgba(9, 9, 11, 0.7);
  border-bottom: 1px solid var(--border-color);
  padding: 16px 24px;
}

.header-content {
  max-width: 1200px;
  margin: 0 auto;
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
  font-family: 'Unbounded', sans-serif;
  font-size: 20px;
  font-weight: 700;
  text-decoration: none;
  color: var(--text-primary);
}

.logo img {
  width: 32px;
  height: 32px;
  border-radius: 8px;
}

.header-buttons {
  display: flex;
  gap: 12px;
  align-items: center;
}


.btn-primary {
  background: linear-gradient(135deg, #ff2d7b, #9b4dff);
  color: white;
  border: none;
  padding: 18px 40px;
  border-radius: 50px;
  font-size: 16px;
  font-weight: 600;
  font-family: 'Inter', sans-serif;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  box-shadow: 0 0 30px rgba(255, 45, 123, 0.3);
  height: 60px;
  box-sizing: border-box;
}

.btn-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 40px rgba(255, 45, 123, 0.5);
}

.btn-secondary {
  background: transparent;
  color: #eeeef0;
  border: 2px solid transparent;
  padding: 16px 38px;
  border-radius: 50px;
  font-size: 16px;
  font-weight: 600;
  font-family: 'Inter', sans-serif;
  cursor: pointer;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  transition: all 0.3s ease;
  background-image: linear-gradient(#09090b, #09090b), linear-gradient(135deg, #ff2d7b, #9b4dff, #00d4ff);
  background-origin: border-box;
  background-clip: padding-box, border-box;
  height: 60px;
  box-sizing: border-box;
}

.btn-secondary:hover {
  transform: translateY(-2px);
}

#landing {
  display: block;
  position: relative;
  z-index: 1;
  padding: 40px 24px 60px;
  max-width: 1200px;
  margin: 0 auto;
  text-align: center;
}

/* app.js uses .hidden to toggle visibility */
#landing.hidden {
  display: none !important;
}

.hero-label {
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 500;
  letter-spacing: 0.2em;
  color: var(--text-muted);
  text-transform: uppercase;
  margin-bottom: 16px;
}

.hero-title {
  font-family: 'Unbounded', sans-serif;
  font-size: clamp(2.5rem, 8vw, 6rem);
  font-weight: 900;
  line-height: 1.1;
  margin-bottom: 16px;
}

.hero-title .gradient {
  background: linear-gradient(135deg, #ff2d7b, #9b4dff, #00d4ff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.hero-subtitle {
  font-size: 22px;
  font-weight: 500;
  color: var(--text-muted);
  margin-bottom: 12px;
}

.hero-description {
  font-size: 16px;
  line-height: 1.6;
  color: var(--text-muted);
  max-width: 700px;
  margin: 0 auto 28px;
}

.hero-buttons {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
  margin-bottom: 24px;
}

.hero-subtext {
  font-size: 14px;
  color: var(--text-muted);
  letter-spacing: 0.05em;
}

/* Баннер розыгрыша (скрывается после 22.03) */
.contest-banner {
  text-align: center;
  padding: 32px 24px;
  margin: 0 auto 0;
  position: relative;
  z-index: 1;
  background: linear-gradient(135deg, rgba(255, 45, 123, 0.08), rgba(155, 77, 255, 0.08));
  border: 1px solid rgba(255, 45, 123, 0.25);
  border-radius: 20px;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  margin-bottom: 0;
}
.contest-banner-btn {
  display: inline-block;
  padding: 18px 40px;
  font-family: 'Unbounded', sans-serif;
  font-size: clamp(1.1rem, 2.5vw, 1.4rem);
  font-weight: 800;
  color: white;
  text-decoration: none;
  border-radius: 50px;
  background: linear-gradient(135deg, #ff2d7b, #9b4dff);
  border: none;
  transition: transform 0.2s, box-shadow 0.2s;
  letter-spacing: 0.02em;
}
.contest-banner-btn:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 40px rgba(255, 45, 123, 0.5);
  color: white;
}
.contest-banner-hint {
  margin: 12px 0 0;
  font-size: 14px;
  color: var(--text-muted);
}

section {
  padding: 60px 24px;
  max-width: 1200px;
  margin: 0 auto;
  position: relative;
  z-index: 1;
}

.what-is {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 48px;
  margin: 60px auto;
  max-width: 800px;
  text-align: center;
  font-size: 18px;
  line-height: 1.7;
  color: var(--text-muted);
}

/* what-is-v2 (redesigned block) */
.what-is-v2 {
  position: relative;
  margin: 60px auto;
  max-width: 900px;
  padding: 56px 48px;
  border-radius: 24px;
  background: var(--bg-surface);
  border: 1px solid var(--border-color-alt, rgba(255,255,255,0.08));
  overflow: hidden;
  text-align: center;
}
.what-is-v2::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 3px;
  background: linear-gradient(135deg, #ff2d7b, #9b4dff, #00d4ff);
}
.what-is-v2::after {
  content: '';
  position: absolute;
  top: -60px; left: 50%;
  transform: translateX(-50%);
  width: 400px; height: 200px;
  background: radial-gradient(ellipse, rgba(155, 77, 255, 0.08) 0%, transparent 70%);
  pointer-events: none;
}
.what-is-v2-label {
  font-family: 'Unbounded', sans-serif;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.2em;
  text-transform: uppercase;
  color: var(--text-muted);
  margin-bottom: 20px;
  position: relative;
  z-index: 1;
}
.what-is-v2-title {
  font-family: 'Unbounded', sans-serif;
  font-size: clamp(1.6rem, 4vw, 2.4rem);
  font-weight: 900;
  line-height: 1.2;
  margin-bottom: 20px;
  position: relative;
  z-index: 1;
  overflow-wrap: break-word;
  word-break: break-word;
}
.what-is-v2-title .gradient-text {
  display: inline-block;
  max-width: 100%;
  white-space: normal;
  overflow-wrap: break-word;
  word-wrap: break-word;
  background: linear-gradient(135deg, #ff2d7b, #9b4dff, #00d4ff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}
.what-is-v2-text {
  font-size: 17px;
  line-height: 1.7;
  color: var(--text-muted);
  max-width: 700px;
  margin: 0 auto 28px;
  position: relative;
  z-index: 1;
}
.what-is-v2-features {
  display: flex;
  justify-content: center;
  gap: 12px 24px;
  flex-wrap: wrap;
  position: relative;
  z-index: 1;
}
.what-is-v2-feature {
  display: flex;
  align-items: center;
  gap: 8px;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-primary);
  padding: 8px 16px;
  border-radius: 50px;
  background: rgba(255,255,255,0.04);
  border: 1px solid var(--border-color);
  transition: all 0.3s;
  white-space: nowrap;
  flex-shrink: 0;
}
.what-is-v2-feature:hover {
  border-color: rgba(255,255,255,0.12);
  background: rgba(255,255,255,0.06);
  transform: translateY(-1px);
}
.what-is-v2-feature .feat-icon { font-size: 18px; }
@media (max-width: 768px) {
  .what-is-v2 { padding: 40px 24px; margin: 40px auto; }
  .what-is-v2-features {
    display: flex;
    flex-wrap: wrap;
    justify-content: center;
    gap: 8px 12px;
    max-width: 100%;
  }
  .what-is-v2-feature {
    font-size: 12px;
    padding: 6px 12px;
  }
}
/* 375×667 и узкие: аккуратный перенос градиентной фразы */
@media (max-width: 420px) {
  .what-is-v2-title {
    font-size: clamp(1.35rem, 5vw, 1.6rem);
    line-height: 1.3;
  }
  .what-is-v2-title .gradient-text {
    word-break: normal;
    overflow-wrap: normal;
  }
}

.section-title {
  font-family: 'Unbounded', sans-serif;
  font-size: clamp(2.5rem, 6vw, 4rem);
  font-weight: 900;
  margin-bottom: 48px;
  text-align: center;
}

.section-title.gradient {
  background: linear-gradient(135deg, #ff2d7b, #9b4dff, #00d4ff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
}

.bento-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(300px, 1fr));
  gap: 16px;
  margin-bottom: 48px;
}

.bento-grid .card:nth-child(1) {
  grid-column: span 2;
}

.bento-grid .card:nth-child(6) {
  grid-column: span 2;
}

.bento-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 32px;
  transition: all 0.3s;
  cursor: pointer;
  position: relative;
  overflow: hidden;
}

.bento-card::before {
  content: '';
  position: absolute;
  top: -100%;
  left: -100%;
  width: 200%;
  height: 200%;
  background: radial-gradient(circle, rgba(255, 45, 123, 0.1), transparent);
  opacity: 0;
  transition: opacity 0.3s;
}

.bento-card:hover {
  border-color: #ff2d7b;
  box-shadow: 0 0 30px rgba(255, 45, 123, 0.2);
}

.bento-card:hover::before {
  opacity: 1;
}

.bento-card h3 {
  font-family: 'Unbounded', sans-serif;
  font-size: 20px;
  font-weight: 700;
  margin-bottom: 12px;
  position: relative;
  z-index: 1;
}

.bento-card p {
  font-size: 15px;
  color: var(--text-muted);
  line-height: 1.6;
  position: relative;
  z-index: 1;
}

.steps {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 32px;
  margin: 60px auto;
}

.step {
  text-align: center;
}

.step-number {
  font-family: 'Unbounded', sans-serif;
  font-size: clamp(2rem, 5vw, 3.5rem);
  font-weight: 900;
  background: linear-gradient(135deg, #ff2d7b, #9b4dff, #00d4ff);
  -webkit-background-clip: text;
  -webkit-text-fill-color: transparent;
  background-clip: text;
  margin-bottom: 16px;
}

.step h3 {
  font-family: 'Unbounded', sans-serif;
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 12px;
}

.step p {
  font-size: 15px;
  color: var(--text-muted);
  line-height: 1.6;
}

.cta-section {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  padding: 64px 32px;
  text-align: center;
  margin: 60px auto;
}

.cta-section .section-title {
  margin-bottom: 16px;
}

.cta-subtitle {
  font-size: 18px;
  color: var(--text-muted);
  margin-bottom: 40px;
}

.faq-list {
  max-width: 800px;
  margin: 0 auto;
}

.faq-item {
  border: 1px solid var(--border-color);
  border-radius: 12px;
  margin-bottom: 12px;
  overflow: hidden;
  transition: all 0.3s;
}

.faq-item:hover {
  border-color: #ff2d7b;
}

.faq-question {
  padding: 20px;
  cursor: pointer;
  display: flex;
  justify-content: space-between;
  align-items: center;
  background: var(--bg-surface);
  font-weight: 600;
  transition: background 0.3s;
}

.faq-item.active .faq-question {
  background: rgba(255, 45, 123, 0.05);
}

.faq-toggle {
  display: inline-block;
  transition: transform 0.3s;
}

.faq-item.active .faq-toggle {
  transform: rotate(180deg);
}

.faq-answer {
  padding: 0 20px;
  max-height: 0;
  overflow: hidden;
  transition: all 0.3s;
  background: rgba(255, 255, 255, 0.02);
}

.faq-item.active .faq-answer {
  padding: 20px;
  max-height: 500px;
}

.faq-answer p {
  color: var(--text-muted);
  line-height: 1.6;
}

.articles-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(280px, 1fr));
  gap: 24px;
  margin: 60px auto;
}

.article-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 24px;
  text-decoration: none;
  color: inherit;
  transition: all 0.3s;
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.article-card:hover {
  border-color: #ff2d7b;
  transform: translateY(-4px);
}

.article-icon {
  font-size: 32px;
}

.article-title {
  font-family: 'Unbounded', sans-serif;
  font-size: 16px;
  font-weight: 700;
}

footer {
  border-top: 1px solid var(--border-color);
  padding: 60px 24px;
  margin-top: 60px;
  position: relative;
  z-index: 1;
}
@media (max-width: 768px) {
  footer { padding: 32px 24px; margin-top: 24px; }
  .footer-bottom { padding-top: 20px; }
}

.footer-content {
  max-width: 1200px;
  margin: 0 auto;
}
.footer-extension-cabinet { display: none; }
body.in-public-stats .footer-extension-cabinet {
  display: flex;
  align-items: center;
  margin-bottom: 24px;
}
.footer-extension-cabinet a { white-space: nowrap; flex-shrink: 0; }
@media (max-width: 768px) {
  body.in-cabinet .footer-extension-cabinet {
    display: flex;
    align-items: center;
    margin-bottom: 24px;
  }
}

.footer-sections {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(250px, 1fr));
  gap: 48px;
  margin-bottom: 48px;
}

.footer-section h4 {
  font-family: 'Unbounded', sans-serif;
  font-weight: 700;
  margin-bottom: 16px;
  font-size: 15px;
}

.footer-links {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.footer-links a {
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  transition: color 0.3s;
}

.footer-links a:hover {
  color: #ff2d7b;
}

.footer-socials {
  display: flex;
  gap: 16px;
  align-items: center;
}

.footer-socials a {
  display: flex;
  align-items: center;
  gap: 8px;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  transition: color 0.3s;
}

.footer-socials a:hover {
  color: #ff2d7b;
}

.footer-bottom {
  border-top: 1px solid var(--border-color);
  padding-top: 32px;
  text-align: center;
  font-size: 14px;
  color: var(--text-muted);
}

.footer a,
.footer-info a,
.footer-link-muted {
  color: var(--text-primary);
}
.footer a:hover,
.footer-info a:hover,
.footer-link-muted:hover {
  color: #ff2d7b;
}

#cabinet {
  display: none;
  position: relative;
  z-index: 1;
  padding: 40px 24px;
}

#cabinet.active {
  display: block;
}

.cabinet-header {
  max-width: 1200px;
  margin: 0 auto 40px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
}

.account-switcher {
  position: relative;
}

.account-current {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 50px;
  padding: 10px 18px;
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s;
}

.account-current:hover {
  border-color: #ff2d7b;
}

.account-name {
  font-weight: 600;
}

.account-badge {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 20px;
  background: rgba(255, 45, 123, 0.15);
  color: #ff2d7b;
}

.account-dropdown {
  display: none;
  position: absolute;
  top: calc(100% + 8px);
  right: 0;
  min-width: 240px;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  padding: 8px;
  z-index: 50;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.5);
}

.account-dropdown.open {
  display: block;
}

.account-dropdown-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 10px 14px;
  border-radius: 8px;
  cursor: pointer;
  transition: background 0.2s;
  font-size: 14px;
  color: var(--text-primary);
}

.account-dropdown-item:hover {
  background: rgba(255, 255, 255, 0.05);
}

.account-dropdown-item.active {
  background: rgba(255, 45, 123, 0.08);
}

.account-item-badge {
  font-size: 11px;
  padding: 2px 8px;
  border-radius: 20px;
}

.account-item-badge.personal {
  background: rgba(255, 45, 123, 0.15);
  color: #ff2d7b;
}

.account-item-badge.group {
  background: rgba(0, 212, 255, 0.15);
  color: #00d4ff;
}

.account-dropdown-divider {
  height: 1px;
  background: var(--border-color);
  margin: 6px 0;
}

.account-dropdown-add,
.account-dropdown-logout {
  display: block;
  width: 100%;
  text-align: left;
  padding: 10px 14px;
  border-radius: 8px;
  border: none;
  background: none;
  cursor: pointer;
  font-family: 'Inter', sans-serif;
  font-size: 13px;
  transition: background 0.2s;
}

.account-dropdown-add {
  color: var(--text-muted);
}

.account-dropdown-add:hover {
  background: rgba(255, 255, 255, 0.05);
  color: var(--text-primary);
}

.account-dropdown-logout {
  color: #ff4444;
}

.account-dropdown-logout:hover {
  background: rgba(255, 68, 68, 0.08);
}

.account-remove-btn {
  width: 22px;
  height: 22px;
  border-radius: 50%;
  border: none;
  background: rgba(255, 68, 68, 0.1);
  color: #ff4444;
  font-size: 14px;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: all 0.2s;
  padding: 0;
  line-height: 1;
}

.account-remove-btn:hover {
  background: rgba(255, 68, 68, 0.25);
}

.cabinet-tabs {
  display: flex;
  gap: 4px;
  flex-wrap: nowrap;
  margin-bottom: 40px;
  max-width: 1200px;
  margin-left: auto;
  margin-right: auto;
  border-bottom: 1px solid var(--border-color);
  padding-bottom: 0;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  scrollbar-width: none;
  position: relative;
}

.cabinet-tabs::-webkit-scrollbar {
  display: none;
}

.cabinet-tabs-wrap {
  position: relative;
}

.cabinet-tabs-wrap::after {
  content: '';
  position: absolute;
  right: 0;
  top: 0;
  bottom: 0;
  width: 40px;
  background: linear-gradient(90deg, transparent, var(--bg-main));
  pointer-events: none;
  z-index: 2;
  opacity: 0;
  transition: opacity 0.3s;
}

.cabinet-tabs-wrap.has-overflow::after {
  opacity: 1;
}

.cabinet-tab {
  padding: 16px 20px;
  background: none;
  border: none;
  border-bottom: 3px solid transparent;
  color: var(--text-muted);
  font-family: 'Inter', sans-serif;
  font-size: 15px;
  font-weight: 500;
  cursor: pointer;
  transition: all 0.3s;
}

.cabinet-tab.active {
  color: #ff2d7b;
  border-bottom-color: #ff2d7b;
}

.cabinet-content {
  display: none;
  max-width: 1200px;
  margin: 0 auto;
}

.cabinet-content.active {
  display: block;
}

.cabinet-toolbar {
  display: flex;
  gap: 16px;
  margin-bottom: 24px;
  align-items: center;
}

.cabinet-search {
  flex: 1;
  padding: 12px 16px;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  font-size: 14px;
}

.cabinet-search::placeholder {
  color: var(--text-muted);
}

.cabinet-select {
  padding: 12px 16px;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 8px;
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  cursor: pointer;
}

.cards-list {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 16px;
  margin-bottom: 40px;
}

.card {
  display: flex;
  flex-direction: column;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  overflow: hidden;
  transition: border-color 0.3s, box-shadow 0.3s;
}

.card:hover {
  border-color: #ff2d7b;
  box-shadow: 0 0 20px rgba(255, 45, 123, 0.15);
}

.film-card-main {
  display: flex;
  gap: 16px;
  padding: 16px;
  flex: 1;
  text-decoration: none;
  color: inherit;
}

.card-poster-wrap {
  width: 96px;
  height: 144px;
  flex-shrink: 0;
  border-radius: 8px;
  overflow: hidden;
  background: #1a1a22;
}

.card-poster {
  width: 100%;
  height: 100%;
  object-fit: cover;
}

.film-poster-placeholder {
  width: 100%;
  height: 100%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  background: #1a1a22;
}

.film-info {
  flex: 1;
  min-width: 0;
  display: flex;
  flex-direction: column;
  justify-content: space-between;
}

.film-title {
  font-family: 'Unbounded', sans-serif;
  font-size: 15px;
  font-weight: 700;
  margin-bottom: 6px;
  word-break: break-word;
}

.film-meta {
  font-size: 13px;
  color: var(--text-muted);
  margin-bottom: 4px;
}

.film-status {
  font-size: 13px;
  color: var(--text-muted);
}

.film-buttons {
  display: flex;
  gap: 8px;
  flex-wrap: nowrap;
  padding: 0 16px 16px;
  margin-top: auto;
  align-items: stretch;
  width: 100%;
  box-sizing: border-box;
}
.film-buttons .btn {
  flex: 1 1 0;
  min-width: 0;
  white-space: nowrap;
  justify-content: center;
  padding: 10px 16px;
  font-size: 13px;
  border-radius: 50px;
}
.film-buttons .film-streaming-btn .streaming-btn-emoji { margin-left: 4px; }

/* Кнопки на всю ширину карточки, овальные (50px) */
.card .film-buttons,
.card.series-card .film-buttons {
  width: 100%;
  min-width: 0;
}
.card .film-buttons .btn,
.card.series-card .film-buttons .btn {
  border-radius: 50px;
  flex: 1 1 0;
  min-width: 0;
}

.film-buttons .btn-sm {
  padding: 10px 16px;
  border-radius: 50px;
  font-size: 13px;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  transition: all 0.3s;
}

.btn-sm-primary {
  background: linear-gradient(135deg, #ff2d7b, #9b4dff);
  color: white;
  border: none;
}

.btn-sm-primary:hover {
  transform: translateY(-1px);
}

.btn-sm-secondary {
  background: transparent;
  color: #eeeef0;
  border: 1px solid rgba(255, 255, 255, 0.15);
}

.btn-sm-secondary:hover {
  border-color: #ff2d7b;
  color: #ff2d7b;
}

.plan-card {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 16px;
  overflow: hidden;
  transition: all 0.3s;
  color: var(--text-primary);
  text-decoration: none;
}

.plan-card:hover {
  border-color: #ff2d7b;
  box-shadow: 0 0 20px rgba(255, 45, 123, 0.15);
}

.plan-card-poster {
  width: 100%;
  height: 240px;
  object-fit: cover;
  background: #1a1a22;
  display: block;
}

.plan-card-info {
  padding: 24px;
}

.plan-card-title {
  font-family: 'Unbounded', sans-serif;
  font-size: 18px;
  font-weight: 700;
  margin-bottom: 12px;
}

.plan-card-meta {
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 16px;
  line-height: 1.6;
}

.plan-card-buttons {
  display: flex;
  gap: 12px;
  padding: 12px 16px 16px;
  margin-top: auto;
}

.plan-card-buttons .btn-small,
.plan-card-buttons .btn-sm {
  padding: 8px 16px;
  font-size: 13px;
  border-radius: 50px;
  font-weight: 600;
  text-decoration: none;
  display: inline-flex;
  align-items: center;
  transition: all 0.3s;
  width: auto;
  min-width: max-content;
  flex: 0 0 auto;
}

.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.8);
  z-index: 100;
  align-items: center;
  justify-content: center;
  backdrop-filter: blur(4px);
}

.modal.active {
  display: flex;
}

.modal-content {
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 20px;
  padding: 40px 36px;
  max-width: 420px;
  width: 90%;
  position: relative;
}

.modal-close {
  position: absolute;
  top: 14px;
  right: 14px;
  width: 36px;
  height: 36px;
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid var(--border-color);
  border-radius: 50%;
  color: var(--text-muted);
  font-size: 20px;
  cursor: pointer;
  transition: all 0.3s;
  display: flex;
  align-items: center;
  justify-content: center;
}

.modal-close:hover {
  color: #ff2d7b;
  border-color: #ff2d7b;
}

.modal-title {
  font-family: 'Unbounded', sans-serif;
  font-size: 22px;
  font-weight: 700;
  margin-bottom: 8px;
}

.modal-hint {
  font-family: 'Inter', sans-serif;
  font-size: 14px;
  color: var(--text-muted);
  margin-bottom: 24px;
  line-height: 1.5;
}

.modal-form {
  display: flex;
  gap: 10px;
  margin-bottom: 0;
}

.modal-input {
  flex: 1;
  padding: 14px 16px;
  background: var(--bg-main);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  font-size: 18px;
  text-align: center;
  letter-spacing: 0.2em;
  outline: none;
  transition: border-color 0.3s;
}

.modal-input:focus {
  border-color: #9b4dff;
}

.modal-input::placeholder {
  color: rgba(255, 255, 255, 0.15);
  letter-spacing: 0.3em;
}

.modal-divider {
  display: flex;
  align-items: center;
  gap: 12px;
  margin: 20px 0;
  color: var(--text-muted);
  font-size: 13px;
  font-family: 'Inter', sans-serif;
}

.modal-divider::before,
.modal-divider::after {
  content: '';
  flex: 1;
  height: 1px;
  background: var(--border-color);
}

.modal-button {
  border: none;
  padding: 14px 24px;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 600;
  font-family: 'Inter', sans-serif;
  cursor: pointer;
  transition: all 0.3s;
  text-decoration: none;
  display: flex;
  align-items: center;
  justify-content: center;
  text-align: center;
}

.modal-button-primary {
  background: linear-gradient(135deg, #ff2d7b, #9b4dff);
  color: white;
  white-space: nowrap;
  padding: 14px 28px;
}

.modal-button-primary:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 30px rgba(255, 45, 123, 0.3);
}

.modal-button-telegram {
  width: 100%;
  background: linear-gradient(135deg, #ff2d7b, #9b4dff);
  color: white;
  margin-bottom: 0;
}

.modal-button-telegram:hover {
  transform: translateY(-2px);
  box-shadow: 0 0 30px rgba(255, 45, 123, 0.3);
}

.about-content {
  max-width: 600px;
  margin: 0 auto;
  text-align: center;
}

.about-author {
  width: 120px;
  height: 120px;
  border-radius: 50%;
  margin: 0 auto 24px;
  object-fit: cover;
  border: 2px solid var(--border-color);
}

.about-bio {
  font-size: 16px;
  line-height: 1.7;
  color: var(--text-muted);
  margin-bottom: 32px;
}

.about-contact { font-size: 15px; margin-bottom: 32px; }
.about-contact a { color: #ff2d7b; text-decoration: none; }
.about-contact a:hover { text-decoration: underline; }
.about-links {
  display: flex;
  gap: 16px;
  justify-content: center;
  flex-wrap: wrap;
}
.about-links a {
  padding: 10px 16px;
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 50px;
  color: var(--text-muted);
  text-decoration: none;
  font-size: 14px;
  transition: all 0.3s;
}
.about-links a:hover { border-color: #ff2d7b; color: #ff2d7b; }

/* ===== TABLET (768px) ===== */
@media (max-width: 768px) {
  #landing {
    padding: 28px 20px 48px;
  }

  .hero-title {
    font-size: clamp(2rem, 7vw, 3.5rem);
  }

  .hero-subtitle {
    font-size: 18px;
  }

  .hero-description {
    font-size: 15px;
    margin-bottom: 24px;
  }

  .hero-buttons {
    flex-direction: column;
    gap: 12px;
  }

  .hero-buttons .btn-primary,
  .hero-buttons .btn-secondary {
    width: 100%;
    font-size: 15px;
    padding: 16px 24px;
    height: 54px;
  }

  .section-title {
    font-size: clamp(1.8rem, 5vw, 2.5rem);
    margin-bottom: 32px;
  }

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

  .bento-grid .card:nth-child(1),
  .bento-grid .card:nth-child(6) {
    grid-column: span 1;
  }

  .bento-card {
    padding: 24px;
  }

  .steps {
    grid-template-columns: 1fr;
    gap: 24px;
  }

  .what-is {
    padding: 32px 24px;
    font-size: 16px;
  }

  .footer-sections {
    grid-template-columns: 1fr;
    gap: 32px;
  }

  .cabinet-header .section-title {
    font-size: clamp(1.6rem, 5vw, 2.5rem) !important;
  }

  .account-current {
    padding: 8px 12px;
    font-size: 13px;
  }

  .account-dropdown {
    min-width: 200px;
  }

  .cabinet-tab {
    white-space: nowrap;
    flex-shrink: 0;
    font-size: 13px;
    padding: 10px 14px;
  }

  .cards-list {
    grid-template-columns: 1fr;
    gap: 16px;
  }

  .header-content {
    flex-direction: row;
    gap: 12px;
  }

  .logo {
    font-size: 16px;
  }

  .logo img {
    width: 28px;
    height: 28px;
  }

  .header-buttons .btn-primary {
    padding: 10px 20px;
    font-size: 14px;
    height: auto;
  }

  .plan-card {
    max-width: 100%;
  }

  .plan-card-buttons {
    flex-direction: column;
  }

  .plan-card-buttons .btn-small,
  .plan-card-buttons .btn-sm {
    width: 100%;
    text-align: center;
    justify-content: center;
  }

  .modal-content {
    padding: 32px 24px;
    margin: 16px;
  }

  .modal-title {
    font-size: 20px;
  }

  .modal-form {
    flex-direction: column;
    gap: 12px;
  }

  .modal-button-primary {
    width: 100%;
  }

  section {
    padding: 40px 20px;
  }

  .faq-answer {
    font-size: 14px;
  }

  .about-author {
    width: 100px;
    height: 100px;
  }

  .about-links {
    flex-wrap: wrap;
    justify-content: center;
  }
}

/* ===== MOBILE SMALL (480px) ===== */
@media (max-width: 480px) {
  #landing {
    padding: 20px 16px 40px;
  }

  .hero-label {
    font-size: 11px;
    letter-spacing: 0.15em;
    margin-bottom: 10px;
  }

  .hero-title {
    font-size: clamp(1.6rem, 8vw, 2.4rem);
    margin-bottom: 12px;
  }

  .hero-subtitle {
    font-size: 15px;
    margin-bottom: 8px;
  }

  .hero-description {
    font-size: 14px;
    margin-bottom: 20px;
  }

  .hero-buttons .btn-primary,
  .hero-buttons .btn-secondary {
    font-size: 14px;
    padding: 14px 20px;
    height: 48px;
  }

  section {
    padding: 32px 16px;
  }

  .section-title {
    font-size: clamp(1.4rem, 6vw, 2rem);
    margin-bottom: 24px;
  }

  .bento-card {
    padding: 20px;
  }

  .bento-card h3 {
    font-size: 17px;
  }

  .bento-card p {
    font-size: 14px;
  }

  .step-number {
    font-size: 32px;
  }

  .what-is {
    padding: 24px 20px;
    font-size: 15px;
    margin: 32px auto;
  }

  .faq-question {
    font-size: 15px;
    padding: 16px;
  }

  .faq-answer {
    padding: 0 16px 16px;
    font-size: 13px;
  }

  header {
    padding: 12px 16px;
  }

  .logo {
    font-size: 14px;
    gap: 8px;
  }

  .logo img {
    width: 24px;
    height: 24px;
  }

  .header-buttons .btn-primary {
    padding: 8px 16px;
    font-size: 13px;
  }

  .modal-content {
    padding: 28px 20px;
    border-radius: 16px;
  }

  .modal-title {
    font-size: 18px;
  }

  .modal-hint {
    font-size: 13px;
  }

  .modal-input {
    font-size: 16px;
    padding: 12px 14px;
  }

  .footer-content {
    padding: 40px 16px 20px;
  }

  .footer-logo {
    font-size: 18px;
  }

  .about-content h3 {
    font-size: 20px;
  }

  .about-content p {
    font-size: 14px;
  }

  .plan-card {
    padding: 16px;
  }

  .plan-card h3 {
    font-size: 15px;
  }

  .plan-card p {
    font-size: 13px;
  }

  .cards-list {
    gap: 12px;
  }
}

/* Subpages: terms, articles */
.subpage-wrapper { min-height: 100vh; }
.site-header-subpage {
  position: sticky;
  top: 0;
  z-index: 10;
  backdrop-filter: blur(10px);
  background: rgba(9, 9, 11, 0.7);
  border-bottom: 1px solid var(--border-color);
  padding: 16px 24px;
}
.subpage-main { padding: 40px 24px 60px; max-width: 800px; margin: 0 auto; }
.article-content { padding: 0; }
.article-content h1 { font-family: 'Unbounded', sans-serif; font-size: 28px; font-weight: 700; margin-bottom: 12px; }
.article-content .date { color: var(--text-muted); font-size: 14px; margin-bottom: 24px; }
.article-content h2 { font-family: 'Unbounded', sans-serif; font-size: 20px; font-weight: 700; margin: 28px 0 12px; }
.article-content p, .article-content li { margin-bottom: 12px; line-height: 1.7; color: var(--text-muted); }
.article-content ul, .article-content ol { margin-bottom: 20px; padding-left: 24px; }
.article-content a { color: var(--text-primary); }
.article-content a:hover { color: #ff2d7b; }
.article-content code { background: rgba(255, 45, 123, 0.15); padding: 2px 6px; border-radius: 4px; font-size: 14px; }
.terms-page .terms-title { font-family: 'Unbounded', sans-serif; font-size: 28px; font-weight: 700; margin-bottom: 16px; }
.terms-lead { font-size: 18px; color: var(--text-muted); line-height: 1.7; margin-bottom: 32px; }
.terms-block { margin-bottom: 36px; }
.terms-block h2 { font-family: 'Unbounded', sans-serif; font-size: 20px; font-weight: 700; margin-bottom: 12px; }
.terms-block p, .terms-block li { color: var(--text-muted); }
.terms-block code { background: rgba(255, 45, 123, 0.15); padding: 2px 6px; border-radius: 4px; }
.terms-footer-note { margin-top: 40px; font-size: 14px; color: var(--text-muted); }
.back-links { margin-top: 32px; font-size: 15px; }
.back-links a { color: var(--text-primary); }
.back-links a:hover { color: #ff2d7b; }
.article-content table { width: 100%; border-collapse: collapse; margin: 20px 0; }
.article-content th, .article-content td { border: 1px solid var(--border-color); padding: 12px 16px; text-align: left; color: var(--text-muted); }
.article-content th { background: var(--bg-surface); font-weight: 600; color: var(--text-primary); }

/* Ratings: member filter (group cabinets) */
.section-ratings-toolbar { display: flex; align-items: center; gap: 12px; margin-bottom: 16px; }
.ratings-member-select { padding: 10px 14px; background: var(--bg-surface); border: 1px solid var(--border-color); border-radius: 8px; color: var(--text-primary); font-size: 14px; }

/* Stats section */
.month-selector { display: flex; align-items: center; gap: 12px; margin-bottom: 24px; flex-wrap: wrap; }
.month-pills { display: flex; gap: 6px; flex-wrap: wrap; }
.month-pill { padding: 8px 16px; border-radius: 50px; font-size: 13px; font-weight: 600; font-family: inherit; cursor: pointer; border: 1px solid var(--border-color-alt, rgba(255,255,255,0.08)); background: var(--bg-surface); color: var(--text-muted); transition: all 0.3s ease; }
.month-pill:hover { color: var(--text-primary); border-color: rgba(255,255,255,0.15); background: var(--bg-surface-alt, #1a1a22); }
.month-pill.active { background: linear-gradient(135deg, #ff2d7b, #9b4dff); color: white; border-color: transparent; }
.year-select { padding: 8px 16px; border-radius: 50px; font-size: 13px; font-weight: 600; font-family: inherit; border: 1px solid var(--border-color-alt, rgba(255,255,255,0.08)); background: var(--bg-surface); color: var(--text-primary); cursor: pointer; appearance: none; -webkit-appearance: none; background-image: url("data:image/svg+xml,%3Csvg xmlns='http://www.w3.org/2000/svg' width='12' height='12' viewBox='0 0 24 24' fill='none' stroke='%236b6b76' stroke-width='2'%3E%3Cpath d='M6 9l6 6 6-6'/%3E%3C/svg%3E"); background-repeat: no-repeat; background-position: right 14px center; padding-right: 36px; }

.stats-month-selector { display: flex; align-items: center; gap: 12px; margin-bottom: 24px; flex-wrap: wrap; }
.stats-month-selector label { font-size: 14px; font-weight: 600; color: var(--text-muted); }
.stats-debug-link { font-size: 12px; color: var(--text-muted); margin-left: auto; }
.stats-debug-link:hover { color: var(--primary-color); }
.stats-month-select, .stats-year-select { padding: 10px 14px; background: var(--bg-surface); border: 1px solid var(--border-color); border-radius: 8px; color: var(--text-primary); font-size: 14px; }
.stats-loading, .stats-error { margin-bottom: 20px; color: var(--text-muted); }
.stats-error { color: #ff4444; }
.stats-summary { display: grid; grid-template-columns: repeat(auto-fit, minmax(160px, 1fr)); gap: 16px; margin-bottom: 32px; }
.stat-card { background: var(--bg-surface); border: 1px solid var(--border-color); border-radius: 16px; padding: 20px; }
.stat-card-value { font-family: 'Unbounded', sans-serif; font-size: 28px; font-weight: 900; line-height: 1; margin-bottom: 4px; }
.stat-card-label { font-size: 13px; color: var(--text-muted); }
.stats-grid { display: grid; grid-template-columns: 1fr 1fr; gap: 24px; }
@media (max-width: 768px) { .stats-grid { grid-template-columns: 1fr; } }
.stats-block { background: var(--bg-surface); border: 1px solid var(--border-color); border-radius: 16px; padding: 24px; }
.stats-block-full { grid-column: 1 / -1; }
.stats-block-title { font-family: 'Unbounded', sans-serif; font-size: 18px; font-weight: 700; margin-bottom: 16px; }
.top-film-row { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--border-color); }
.top-film-row:last-child { border-bottom: none; }
.top-film-rank { font-family: 'Unbounded', sans-serif; font-size: 20px; font-weight: 900; width: 36px; text-align: center; flex-shrink: 0; }
.top-film-row:nth-child(1) .top-film-rank { color: #fbbf24; }
.top-film-row:nth-child(2) .top-film-rank { color: #c0c0c0; }
.top-film-row:nth-child(3) .top-film-rank { color: #cd7f32; }
.top-film-row:nth-child(n+4) .top-film-rank { color: var(--text-muted); }
.top-film-poster { width: 40px; height: 56px; border-radius: 6px; object-fit: cover; flex-shrink: 0; }
.top-film-info { flex: 1; min-width: 0; }
.top-film-name { font-weight: 600; font-size: 14px; }
.top-film-meta { font-size: 12px; color: var(--text-muted); }
.top-film-rating { font-family: 'Unbounded', sans-serif; font-size: 18px; font-weight: 700; flex-shrink: 0; }
.top-films-expand-wrap { margin-top: 12px; }
.top-films-expand-btn { padding: 8px 16px; border-radius: 50px; font-size: 13px; font-weight: 600; cursor: pointer; background: var(--bg-surface-alt, #1a1a22); color: var(--text-primary); border: 1px solid var(--border-color); font-family: inherit; transition: all 0.2s; }
.top-films-expand-btn:hover { border-color: #ff2d7b; color: #ff2d7b; }
.rating-bar-row { display: flex; align-items: center; gap: 10px; margin-bottom: 8px; }
.rating-bar-label { font-size: 14px; font-weight: 600; width: 24px; text-align: right; flex-shrink: 0; }
.rating-bar-track { flex: 1; height: 24px; background: var(--bg-surface-alt); border-radius: 6px; overflow: hidden; }
.rating-bar-fill { height: 100%; border-radius: 6px; display: flex; align-items: center; justify-content: center; font-size: 11px; font-weight: 700; color: white; transition: width 0.6s ease; }
.platform-row { display: flex; justify-content: space-between; align-items: center; padding: 8px 0; border-bottom: 1px solid var(--border-color); }
.watched-block-wrap { }
.watched-list-collapsed .watched-item:nth-child(n+17) { display: none; }
@media (max-width: 768px) {
  .watched-list-collapsed .watched-item:nth-child(n+8) { display: none; }
}
.watched-expand-wrap { margin-top: 16px; }
.watched-expand-btn { padding: 10px 20px; border-radius: 50px; font-size: 14px; font-weight: 600; cursor: pointer; background: var(--bg-surface-alt, #1a1a22); color: var(--text-primary); border: 1px solid var(--border-color); font-family: inherit; transition: all 0.2s; }
.watched-expand-btn:hover { border-color: #ff2d7b; color: #ff2d7b; }

.watched-list { display: grid; grid-template-columns: repeat(auto-fill, minmax(280px, 1fr)); gap: 12px; }
.watched-item { display: flex; align-items: center; gap: 14px; padding: 12px 16px; background: var(--bg-surface-alt, #1a1a22); border: 1px solid var(--border-color); border-radius: 14px; transition: all 0.2s; }
.watched-item:hover { border-color: rgba(255,255,255,0.12); transform: translateY(-1px); }
.watched-poster { width: 40px; height: 56px; border-radius: 6px; object-fit: cover; flex-shrink: 0; background: var(--bg-main, #09090b); }
.watched-info { flex: 1; min-width: 0; }
.watched-name { font-weight: 600; font-size: 14px; white-space: nowrap; overflow: hidden; text-overflow: ellipsis; }
.watched-meta { font-size: 12px; color: var(--text-muted); }
.watched-badge { font-size: 11px; font-weight: 700; padding: 4px 10px; border-radius: 50px; flex-shrink: 0; }
.badge-film { background: rgba(255, 45, 123, 0.15); color: #ff2d7b; }
.badge-series { background: rgba(0, 212, 255, 0.15); color: #00d4ff; }
.badge-cinema { background: rgba(251, 191, 36, 0.15); color: #fbbf24; }

.watched-row { display: flex; align-items: center; gap: 12px; padding: 10px 0; border-bottom: 1px solid var(--border-color); }
.watched-row:last-child { border-bottom: none; }
.film-rated-date { font-size: 12px; color: var(--text-muted); margin-top: 4px; }

/* Group stats */
.stats-group-header { display: flex; justify-content: space-between; align-items: flex-start; gap: 16px; flex-wrap: wrap; margin-bottom: 24px; min-width: 0; }
.stats-group-header-inner { flex: 1; min-width: 0; overflow: hidden; }
.stats-group-title { font-family: 'Unbounded', sans-serif; font-size: 22px; font-weight: 700; margin: 0 0 4px; overflow: hidden; text-overflow: ellipsis; word-break: break-word; }
.stats-group-name { background: linear-gradient(135deg, #ff2d7b, #9b4dff); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.stats-group-meta { font-size: 14px; color: var(--text-muted); }
.stats-personal-share { margin-bottom: 24px; }
.stats-share-views { font-size: 13px; color: rgba(255,255,255,0.6); margin-top: 8px; }
.stats-personal-share-note { font-size: 14px; color: var(--text-muted); }
.stats-personal-share-note a { color: #ff2d7b; text-decoration: none; }
.stats-personal-share-note a:hover { text-decoration: underline; }
.stats-group-share { display: flex; align-items: center; gap: 8px; background: var(--bg-surface); border: 1px solid var(--border-color-alt, rgba(255,255,255,0.08)); border-radius: 12px; padding: 8px 12px 8px 16px; font-size: 13px; color: var(--text-muted); min-width: 0; }
.stats-group-share-url { overflow: hidden; text-overflow: ellipsis; white-space: nowrap; flex: 1; min-width: 0; }
.stats-group-copy-btn { flex-shrink: 0; }
.stats-group-copy-btn { padding: 6px 14px; border-radius: 8px; background: linear-gradient(135deg, #ff2d7b, #9b4dff); color: white; border: none; font-size: 12px; font-weight: 600; cursor: pointer; white-space: nowrap; font-family: inherit; }

.stat-card-pink .stat-card-value { color: #ff2d7b; }
.stat-card-purple .stat-card-value { color: #9b4dff; }
.stat-card-cyan .stat-card-value { color: #00d4ff; }
.stat-card-green .stat-card-value { color: #34d399; }
.stat-card-amber .stat-card-value { color: #fbbf24; }
.stat-card-icon { font-size: 24px; margin-bottom: 8px; }
.stats-group-summary .stat-card { position: relative; overflow: hidden; }
.stats-group-summary .stat-card::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px; border-radius: 16px 16px 0 0; }
.stat-card-pink::before { background: #ff2d7b; }
.stat-card-purple::before { background: #9b4dff; }
.stat-card-cyan::before { background: #00d4ff; }
.stat-card-green::before { background: #34d399; }
.stat-card-amber::before { background: #fbbf24; }

.stats-mvp-card { background: linear-gradient(135deg, rgba(255,45,123,0.08), rgba(155,77,255,0.08)); border: 1px solid rgba(255,45,123,0.2); border-radius: 20px; padding: 32px; text-align: center; margin-bottom: 32px; position: relative; }
.stats-mvp-card::before { content: ''; position: absolute; top: 0; left: 0; right: 0; height: 3px; background: linear-gradient(135deg, #ff2d7b, #9b4dff); border-radius: 20px 20px 0 0; }
.stats-mvp-crown { font-size: 36px; margin-bottom: 8px; }
.stats-mvp-card .avatar { margin-left: auto; margin-right: auto; }
.stats-mvp-title { font-family: 'Unbounded', sans-serif; font-size: 12px; text-transform: uppercase; letter-spacing: 0.15em; color: var(--text-muted); margin-bottom: 12px; }
.stats-mvp-name { font-family: 'Unbounded', sans-serif; font-size: 22px; font-weight: 700; background: linear-gradient(135deg, #ff2d7b, #9b4dff); -webkit-background-clip: text; -webkit-text-fill-color: transparent; background-clip: text; }
.stats-mvp-meta { font-size: 13px; color: var(--text-muted); margin-top: 4px; margin-bottom: 16px; }
.stats-mvp-stats { display: flex; justify-content: center; gap: 28px; flex-wrap: wrap; }
.stats-mvp-stat { text-align: center; }
.stats-mvp-stat-val { font-family: 'Unbounded', sans-serif; font-size: 18px; font-weight: 700; display: block; }
.stats-mvp-stat-lbl { font-size: 12px; color: var(--text-muted); }

.avatar { width: 40px; height: 40px; border-radius: 50%; display: flex; align-items: center; justify-content: center; font-weight: 700; font-size: 16px; flex-shrink: 0; color: white; }
.avatar-sm { width: 32px; height: 32px; font-size: 13px; }
.avatar-xl { width: 72px; height: 72px; font-size: 28px; }
.stats-top-chip { display: inline-flex; align-items: center; gap: 3px; padding: 2px 7px; border-radius: 50px; font-size: 10px; font-weight: 600; background: var(--bg-surface-alt, #1a1a22); border: 1px solid var(--border-color); margin-right: 4px; margin-top: 4px; }
.stats-top-voters { display: flex; gap: 4px; flex-wrap: wrap; margin-top: 4px; }
.top-film-avg-sub { font-size: 10px; color: var(--text-muted); }
.stats-block-sub { font-size: 13px; color: var(--text-muted); margin: -12px 0 16px; }

.rating-bar-count { font-size: 13px; color: var(--text-muted); width: 28px; flex-shrink: 0; text-align: right; }

.stats-lb-tabs { display: flex; gap: 4px; margin-bottom: 16px; overflow-x: auto; -webkit-overflow-scrolling: touch; flex-shrink: 0; padding-bottom: 4px; }
.stats-lb-tab { padding: 6px 14px; flex-shrink: 0; border-radius: 8px; font-size: 12px; font-weight: 600; cursor: pointer; background: var(--bg-surface-alt, #1a1a22); color: var(--text-muted); border: 1px solid var(--border-color); transition: all 0.2s; font-family: inherit; }
.stats-lb-tab:hover { color: var(--text-primary); }
.stats-lb-tab.active { background: #9b4dff; color: white; border-color: #9b4dff; }
.stats-lb-row { display: flex; align-items: center; gap: 14px; padding: 14px 0; border-bottom: 1px solid var(--border-color); }
.stats-lb-row:last-child { border-bottom: none; }
.stats-lb-rank { font-family: 'Unbounded', sans-serif; font-size: 18px; font-weight: 900; width: 28px; text-align: center; flex-shrink: 0; }
.stats-lb-row:nth-child(1) .stats-lb-rank { color: #fbbf24; }
.stats-lb-row:nth-child(2) .stats-lb-rank { color: #c0c0c0; }
.stats-lb-row:nth-child(3) .stats-lb-rank { color: #cd7f32; }
.stats-lb-info { flex: 1; min-width: 0; overflow: hidden; }
.stats-lb-name { font-weight: 600; font-size: 15px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; }
.stats-lb-bar-wrap { flex: 1; height: 8px; background: var(--bg-surface-alt, #1a1a22); border-radius: 4px; overflow: hidden; min-width: 60px; max-width: 140px; flex-shrink: 0; }
.stats-lb-bar { height: 100%; border-radius: 4px; transition: width 0.8s ease; }
.stats-lb-value { font-family: 'Unbounded', sans-serif; font-size: 20px; font-weight: 700; flex-shrink: 0; }

.stats-contro-row { display: flex; align-items: center; gap: 16px; padding: 14px 0; border-bottom: 1px solid var(--border-color); }
.stats-contro-row:last-child { border-bottom: none; }
.stats-contro-poster { width: 48px; height: 68px; border-radius: 8px; object-fit: cover; flex-shrink: 0; background: var(--bg-surface-alt, #1a1a22); }
.stats-contro-info { flex: 1; min-width: 0; }
.stats-contro-title { font-weight: 600; font-size: 15px; }
.stats-contro-year { color: var(--text-muted); font-weight: 400; font-size: 13px; }
.stats-contro-ratings { display: flex; gap: 6px; margin-top: 6px; flex-wrap: wrap; }
.stats-contro-chip { display: inline-flex; align-items: center; gap: 4px; padding: 3px 10px; border-radius: 50px; font-size: 11px; font-weight: 600; background: var(--bg-surface-alt, #1a1a22); border: 1px solid var(--border-color-alt, rgba(255,255,255,0.08)); }
.stats-contro-spread { font-family: 'Unbounded', sans-serif; font-size: 16px; font-weight: 700; color: #ff2d7b; flex-shrink: 0; text-align: center; min-width: 50px; }
.stats-contro-spread-lbl { font-size: 10px; color: var(--text-muted); font-weight: 500; }

.stats-compat-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(160px, 1fr)); gap: 12px; }
.stats-compat-card { background: var(--bg-surface-alt, #1a1a22); border: 1px solid var(--border-color); border-radius: 14px; padding: 16px; text-align: center; transition: all 0.3s; }
.stats-compat-card:hover { border-color: rgba(255,255,255,0.12); }
.stats-compat-avatars { display: flex; justify-content: center; align-items: center; gap: -10px; margin-bottom: 10px; }
.stats-compat-avatars .avatar:last-child { margin-left: -10px; }
.stats-compat-ring { width: 80px; height: 80px; margin: 0 auto 8px; position: relative; }
.stats-compat-ring svg { transform: rotate(-90deg); }
.stats-compat-value { position: absolute; top: 50%; left: 50%; transform: translate(-50%, -50%); font-family: 'Unbounded', sans-serif; font-size: 18px; font-weight: 700; }
.stats-compat-label { font-size: 11px; color: var(--text-muted); margin-top: 4px; }

.stats-genre-row { display: flex; align-items: center; gap: 8px; margin-bottom: 10px; }
.stats-genre-row:last-child { margin-bottom: 0; }
.stats-genre-label { font-size: 12px; font-weight: 600; width: 90px; text-align: right; flex-shrink: 0; color: var(--text-muted); }
.stats-genre-bars { flex: 1; display: flex; flex-direction: column; gap: 3px; }
.stats-genre-bar-line { display: flex; align-items: center; gap: 6px; }
.stats-genre-bar-user { font-size: 10px; color: var(--text-muted); width: 16px; flex-shrink: 0; }
.stats-genre-bar-track { flex: 1; height: 14px; background: var(--bg-surface-alt, #1a1a22); border-radius: 4px; overflow: hidden; }
.stats-genre-bar-fill { height: 100%; border-radius: 4px; display: flex; align-items: center; padding-left: 6px; font-size: 10px; font-weight: 700; color: white; transition: width 0.6s ease; min-width: 20px; }
.stats-genre-legend { display: flex; gap: 12px; margin-bottom: 16px; flex-wrap: wrap; font-size: 12px; color: var(--text-muted); }
.stats-genre-legend span { display: flex; align-items: center; gap: 6px; }

.stats-achievements-grid { display: grid; grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); gap: 12px; }
.stats-achievement { position: relative; display: flex; flex-direction: column; align-items: center; min-width: 0; overflow: hidden; background: var(--bg-surface-alt, #1a1a22); border: 1px solid var(--border-color); border-radius: 14px; padding: 16px; text-align: center; transition: all 0.3s; box-sizing: border-box; }
.stats-achievement:hover { transform: translateY(-2px); }
.stats-achievement.earned { border-color: rgba(251, 191, 36, 0.3); }
.stats-achievement.earned::after { content: ''; position: absolute; inset: 0; background: radial-gradient(ellipse at center, rgba(251,191,36,0.06) 0%, transparent 70%); border-radius: 14px; pointer-events: none; }
.stats-achievement-icon { font-size: 32px; margin-bottom: 8px; flex-shrink: 0; }
.stats-achievement-name { width: 100%; font-size: 11px; font-weight: 700; margin-bottom: 4px; overflow-wrap: break-word; word-break: break-word; }
.stats-achievement-desc { width: 100%; font-size: 11px; color: var(--text-muted); line-height: 1.3; overflow-wrap: break-word; word-break: break-word; }
.stats-achievement-holder { width: 100%; font-size: 11px; color: #fbbf24; font-weight: 600; margin-top: 6px; overflow-wrap: break-word; word-break: break-word; }
.stats-achievement-locked { color: var(--text-muted); }

.stats-heatmap-wrap { overflow-x: auto; padding: 16px 0; min-height: 140px; }
.stats-heatmap { display: flex; gap: 6px; }
.stats-heatmap-col { display: flex; flex-direction: column; gap: 6px; }
.stats-heatmap-day { font-size: 10px; color: var(--text-muted); text-align: center; margin-bottom: 4px; }
.stats-heatmap-cell { width: 24px; height: 24px; min-width: 24px; min-height: 24px; border-radius: 4px; background: var(--bg-surface-alt, #1a1a22); transition: all 0.2s; }
.stats-heatmap-cell:hover { transform: scale(1.3); z-index: 1; position: relative; }
.stats-heatmap-cell.l1 { background: rgba(155, 77, 255, 0.2); }
.stats-heatmap-cell.l2 { background: rgba(155, 77, 255, 0.4); }
.stats-heatmap-cell.l3 { background: rgba(155, 77, 255, 0.6); }
.stats-heatmap-cell.l4 { background: rgba(155, 77, 255, 0.85); }
.stats-heatmap-legend { display: flex; gap: 8px; margin-bottom: 12px; font-size: 11px; color: var(--text-muted); }
.stats-heatmap-legend span { display: flex; align-items: center; gap: 4px; }
.stats-heatmap-legend-bar { display: flex; align-items: center; gap: 6px; margin-top: 12px; font-size: 11px; color: var(--text-muted); }
@media (max-width: 600px) {
  .stats-heatmap-cell { width: 28px; height: 28px; min-width: 28px; min-height: 28px; }
  .stats-heatmap { gap: 4px; }
  .stats-heatmap-col { gap: 4px; }
}

/* Stats profile (compact header for public stats page) */
.stats-profile {
  background: var(--bg-surface);
  border: 1px solid var(--border-color-alt, rgba(255,255,255,0.08));
  border-radius: 20px;
  padding: 24px 28px;
  margin-bottom: 28px;
  position: relative;
  overflow: hidden;
}
.stats-profile::before {
  content: '';
  position: absolute;
  top: 0; left: 0; right: 0;
  height: 2px;
  background: linear-gradient(135deg, #ff2d7b, #9b4dff, #00d4ff);
}
.stats-profile-top { display: flex; align-items: center; gap: 16px; flex-wrap: wrap; }
.stats-profile-avatar {
  width: 48px; height: 48px; border-radius: 50%;
  background: #9b4dff;
  display: flex; align-items: center; justify-content: center;
  font-size: 20px; font-weight: 700; color: white;
  flex-shrink: 0;
}
.stats-profile-info { flex: 1; min-width: 180px; }
.stats-profile-name { font-family: 'Unbounded', sans-serif; font-size: 18px; font-weight: 700; line-height: 1.2; }
.stats-profile-meta { font-size: 12px; color: var(--text-muted); margin-top: 2px; display: flex; gap: 12px; flex-wrap: wrap; }
.stats-profile-badges { display: flex; align-items: center; gap: 6px; flex-wrap: wrap; margin-top: 14px; }
.badge-mini {
  display: inline-flex; align-items: center; gap: 5px;
  padding: 4px 12px; border-radius: 50px; font-size: 12px; font-weight: 600;
  background: rgba(255,255,255,0.04); border: 1px solid var(--border-color);
  transition: all 0.25s; cursor: default; position: relative;
}
.badge-mini:hover { transform: translateY(-1px); border-color: rgba(255,255,255,0.15); }
.badge-mini-icon { font-size: 14px; }
.badge-mini.rare { border-color: rgba(0,212,255,0.2); background: rgba(0,212,255,0.05); }
.badge-mini.rare .badge-mini-name { color: #00d4ff; }
.badge-mini.epic { border-color: rgba(155,77,255,0.2); background: rgba(155,77,255,0.05); }
.badge-mini.epic .badge-mini-name { color: #9b4dff; }
.badge-mini.legendary {
  border-color: rgba(251,191,36,0.25);
  background: linear-gradient(135deg, rgba(251,191,36,0.06), rgba(255,45,123,0.04));
}
.badge-mini.legendary .badge-mini-name {
  background: linear-gradient(135deg, #fbbf24, #ff2d7b);
  -webkit-background-clip: text; -webkit-text-fill-color: transparent;
  background-clip: text;
}
.badge-mini .badge-tip {
  position: absolute; bottom: calc(100% + 8px); left: 50%; transform: translateX(-50%);
  background: #1e1e28; border: 1px solid var(--border-color-alt, rgba(255,255,255,0.08));
  border-radius: 10px; padding: 10px 14px; min-width: 180px;
  font-size: 11px; color: var(--text-muted); opacity: 0; pointer-events: none;
  transition: opacity 0.2s; z-index: 10; text-align: center; line-height: 1.4; white-space: normal;
}
.badge-mini .badge-tip strong { display: block; color: var(--text-primary); font-size: 12px; margin-bottom: 3px; }
.badge-mini:hover .badge-tip { opacity: 1; }
.badges-more {
  display: inline-flex; align-items: center; gap: 4px;
  padding: 4px 14px; border-radius: 50px; font-size: 12px; font-weight: 600;
  color: #9b4dff; background: rgba(155,77,255,0.08); border: 1px solid rgba(155,77,255,0.15);
  cursor: pointer; text-decoration: none; transition: all 0.25s;
}
.badges-more:hover { background: rgba(155,77,255,0.15); transform: translateY(-1px); }

/* Achievement panel (Все ачивки) */
.ach-panel {
  display: none;
  background: var(--bg-surface, #131318);
  border: 1px solid var(--border-color-alt, rgba(255,255,255,0.08));
  border-radius: 20px;
  padding: 28px;
  margin-bottom: 28px;
  animation: achPanelSlide 0.3s ease;
}
.ach-panel.open { display: block; }
@keyframes achPanelSlide {
  from { opacity: 0; transform: translateY(-10px); }
  to { opacity: 1; transform: translateY(0); }
}
.ach-panel-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 20px;
}
.ach-panel-title {
  font-family: 'Unbounded', sans-serif;
  font-size: 18px;
  font-weight: 700;
}
.ach-panel-close {
  width: 32px; height: 32px; border-radius: 50%;
  background: var(--bg-surface-alt, #1a1a22);
  border: 1px solid var(--border-color);
  color: var(--text-muted);
  font-size: 16px; cursor: pointer;
  display: flex; align-items: center; justify-content: center;
  transition: all 0.2s;
}
.ach-panel-close:hover { color: var(--text-primary); border-color: rgba(255,255,255,0.15); }
.ach-panel-filters {
  display: flex;
  gap: 16px;
  margin-bottom: 20px;
  flex-wrap: wrap;
  overflow-x: auto;
  -webkit-overflow-scrolling: touch;
  padding-bottom: 4px;
}
.ach-panel-filters .ach-panel-filter-btn { flex-shrink: 0; }
.ach-panel-grid {
  display: flex;
  flex-direction: column;
  gap: 24px;
}
.ach-panel-category { }
.ach-panel-category-title {
  font-family: 'Unbounded', sans-serif;
  font-size: 14px;
  font-weight: 700;
  color: var(--text-muted);
  margin-bottom: 10px;
}
.ach-panel-category-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(240px, 1fr));
  gap: 12px;
}
.ach-panel-card {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px 16px;
  border-radius: 14px;
  background: var(--bg-surface-alt, #1a1a22);
  border: 1px solid var(--border-color);
  transition: all 0.2s;
}
.ach-panel-card:hover { border-color: rgba(255,255,255,0.1); transform: translateY(-1px); }
.ach-panel-card.locked { opacity: 0.35; }
.ach-panel-card.earned { border-color: rgba(251,191,36,0.2); }
.ach-panel-icon { font-size: 24px; flex-shrink: 0; }
.ach-panel-info { flex: 1; min-width: 0; }
.ach-panel-name { font-weight: 700; font-size: 13px; }
.ach-panel-desc { font-size: 11px; color: var(--text-muted); line-height: 1.3; }
.ach-panel-rarity {
  font-size: 9px; font-weight: 700; text-transform: uppercase;
  letter-spacing: 0.08em; padding: 2px 8px; border-radius: 50px;
  flex-shrink: 0;
}
.ach-panel-rarity.r-common { background: rgba(107,107,118,0.15); color: var(--text-muted); }
.ach-panel-rarity.r-rare { background: rgba(0,212,255,0.12); color: #00d4ff; }
.ach-panel-rarity.r-epic { background: rgba(155,77,255,0.12); color: #9b4dff; }
.ach-panel-rarity.r-legendary { background: rgba(251,191,36,0.12); color: #fbbf24; }
.ach-panel-progress {
  height: 4px; background: var(--bg-main, #09090b);
  border-radius: 2px; margin-top: 6px; overflow: hidden;
}
.ach-panel-progress-fill { height: 100%; border-radius: 2px; }
.ach-panel-filter-btn {
  font-size: 13px; color: var(--text-muted); cursor: pointer; padding: 4px 8px; border-radius: 6px;
  transition: all 0.2s;
}
.ach-panel-filter-btn:hover { color: var(--text-primary); }

@media (max-width: 768px) {
  .stats-profile-top { flex-direction: column; text-align: center; align-items: center; }
  .stats-profile-badges { justify-content: center; }
  .stats-profile-meta { justify-content: center; }
  .ach-panel-category-grid { grid-template-columns: 1fr; }
}

/* Public stats page (share link) */
#public-stats { padding: 32px 0 80px; min-height: 100vh; }
@media (max-width: 768px) {
  #public-stats { padding: 24px 0 32px; min-height: auto; }
}
#public-stats .container { max-width: 1200px; margin: 0 auto; padding: 0 24px; }
@media (max-width: 420px) {
  #public-stats .container { padding: 0 12px; }
  .stats-block { padding: 16px; }
  #public-stats-content { overflow-x: hidden; max-width: 100%; }
}
.public-stats-header-wrap {
  max-width: 1200px;
  margin: 0 auto 24px;
  padding: 0 24px;
  display: flex;
  flex-direction: column;
  gap: 4px;
}
.public-stats-header-wrap .logo { display: inline-flex; align-items: center; gap: 8px; color: var(--text-primary); text-decoration: none; font-family: 'Unbounded', sans-serif; font-weight: 700; font-size: 20px; }
.public-stats-header-wrap .logo img { width: 32px; height: 32px; border-radius: 8px; }
.public-stats-subtitle { font-size: 18px; color: var(--text-muted); margin: 12px 0 0; }
.public-stats-selector { margin-bottom: 24px; }

@media (max-width: 768px) {
  .stats-compat-grid { grid-template-columns: 1fr; }
  .stats-group-header { flex-direction: column; flex-wrap: wrap; }
  .stats-group-header-inner { min-width: 0; max-width: 100%; }
  .stats-group-title { font-size: 18px; overflow: hidden; text-overflow: ellipsis; white-space: nowrap; max-width: 100%; }
  .stats-group-name { display: inline-block; max-width: 100%; overflow: hidden; text-overflow: ellipsis; vertical-align: bottom; }
  .stats-group-share { min-width: 0; max-width: 100%; }
  .stats-group-share-url { min-width: 0; }
  .stats-achievements-grid { grid-template-columns: repeat(auto-fill, minmax(140px, 1fr)); }
  .stats-grid, .stats-group-grid { min-width: 0; grid-template-columns: 1fr; }
  .stats-block { min-width: 0; max-width: 100%; overflow: hidden; box-sizing: border-box; }
  .rating-bar-row { min-width: 0; }
  .rating-bar-track { min-width: 0; }
  #section-stats, #section-stats .stats-content, #section-stats .stats-group-grid { overflow-x: hidden; max-width: 100%; }
  /* Блок «Всё просмотренное»: minmax(280px) вызывал overflow на 375px */
  .watched-list { grid-template-columns: minmax(0, 1fr); }
  /* Leaderboard mobile: hide bar, show colored value */
  .stats-lb-bar-wrap { display: none; }
  .stats-lb-value { padding: 4px 12px; border-radius: 8px; font-size: 16px; }
  .stats-lb-value.value-high { background: linear-gradient(135deg, rgba(52,211,153,0.25), rgba(251,191,36,0.2)); color: #34d399; }
  .stats-lb-value.value-mid { background: rgba(255,255,255,0.06); color: var(--text-primary); }
  .stats-lb-value.value-low { background: rgba(107,107,118,0.15); color: var(--text-muted); }
  /* Карточки: кнопка «На стриминг» только иконка ▶️, в один ряд с «В Telegram» */
  .film-buttons .film-streaming-btn .streaming-btn-text { display: none; }
  .film-buttons .film-streaming-btn .streaming-btn-emoji { margin-left: 0; }
  .film-buttons .film-streaming-btn { min-width: 0; padding: 6px 10px; }
}

/* ── Watched ⋮ three-dots menu (stats section) ── */
.watched-item-actions {
  position: relative;
  flex-shrink: 0;
  margin-left: auto;
}
.watched-menu-dots {
  width: 32px;
  height: 32px;
  border: none;
  background: none;
  border-radius: 8px;
  cursor: pointer;
  font-size: 20px;
  line-height: 1;
  color: var(--text-muted);
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s, color 0.2s;
  font-family: inherit;
}
.watched-menu-dots:hover {
  background: rgba(255, 255, 255, 0.07);
  color: var(--text-primary);
}
.watched-menu-dropdown {
  position: absolute;
  right: 0;
  top: calc(100% + 4px);
  background: var(--bg-surface);
  border: 1px solid var(--border-color);
  border-radius: 12px;
  box-shadow: 0 12px 40px rgba(0, 0, 0, 0.55);
  z-index: 200;
  min-width: 220px;
  padding: 6px;
}
.watched-menu-dropdown.hidden { display: none; }
.watched-menu-dropdown button {
  display: block;
  width: 100%;
  padding: 10px 14px;
  text-align: left;
  border: none;
  background: none;
  cursor: pointer;
  font-size: 14px;
  color: var(--text-primary);
  border-radius: 8px;
  font-family: 'Inter', sans-serif;
  transition: background 0.15s;
}
.watched-menu-dropdown button:hover {
  background: rgba(255, 45, 123, 0.1);
  color: #ff2d7b;
}

/* ── Change month modal selects ── */
.change-month-fields {
  display: flex;
  gap: 16px;
  margin: 20px 0 24px;
  align-items: center;
  flex-wrap: wrap;
}
.change-month-fields label {
  font-size: 14px;
  color: var(--text-muted);
  display: flex;
  align-items: center;
  gap: 8px;
}
.change-month-fields select {
  padding: 10px 14px;
  font-size: 14px;
  border: 1px solid var(--border-color);
  border-radius: 10px;
  background: var(--bg-main);
  color: var(--text-primary);
  font-family: 'Inter', sans-serif;
  outline: none;
  cursor: pointer;
  transition: border-color 0.2s;
}
.change-month-fields select:focus {
  border-color: #9b4dff;
}
