/* Activity Superdesign */
.activity-super {
  --f-accent: var(--rdx-accent, #615dfa);
  --f-text: var(--rdx-text, #3e3f5e);
  --f-text-muted: var(--rdx-text-muted, #8f91ac);
  --f-surface: var(--rdx-surface, #fff);
  --f-border: var(--rdx-border, #eaeaf5);
  
  display: block;
  text-decoration: none !important;
  color: inherit;
  border-radius: 18px;
  overflow: hidden;
  background: var(--f-surface);
  border: 1px solid var(--f-border);
  transition: transform 0.28s cubic-bezier(0.4, 0, 0.2, 1), box-shadow 0.28s cubic-bezier(0.4, 0, 0.2, 1);
  position: relative;
  box-shadow: 0 4px 12px rgba(0,0,0,0.03);
}

.activity-super:hover {
  transform: translateY(-6px);
  box-shadow: 0 16px 32px rgba(97, 93, 250, 0.12);
}

.activity-super-banner {
  height: 140px;
  background-size: cover;
  background-position: center;
  position: relative;
  display: flex;
  align-items: flex-end;
  padding: 20px;
  overflow: hidden;
}

.activity-super-banner::before {
  content: '';
  position: absolute;
  inset: 0;
  background: rgba(30, 31, 57, 0.2);
  transition: background 0.3s ease;
}

.activity-super:hover .activity-super-banner::before {
  background: rgba(30, 31, 57, 0.1);
}

.activity-super-banner::after {
  content: '';
  position: absolute;
  inset: 0;
  background: linear-gradient(to bottom, transparent 0%, rgba(0,0,0,0.7) 100%);
}

.activity-super-category {
  position: relative;
  z-index: 2;
  background: var(--f-accent);
  color: #fff;
  padding: 6px 14px;
  border-radius: 30px;
  font-size: 0.7rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.05em;
  display: inline-flex;
  align-items: center;
  gap: 8px;
  box-shadow: 0 4px 12px rgba(0,0,0,0.2);
}

.activity-super-category i {
  font-size: 0.85rem;
}

.activity-super-content {
  padding: 24px;
  background: var(--f-surface);
}

.activity-super-title {
  font-size: 1.35rem;
  font-weight: 800;
  color: var(--f-text);
  margin-bottom: 12px;
  line-height: 1.25;
  transition: color 0.2s ease;
}

.activity-super:hover .activity-super-title {
  color: var(--f-accent);
}

.activity-super-excerpt {
  font-size: 0.95rem;
  color: var(--f-text-muted);
  line-height: 1.7;
  height: 3.4em;
  display: -webkit-box;
  -webkit-line-clamp: 2;
  -webkit-box-orient: vertical;
  overflow: hidden;
  margin-bottom: 20px;
}

.activity-super-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding-top: 18px;
  border-top: 1px solid var(--f-border);
}

.activity-super-stats {
  display: flex;
  gap: 16px;
}

.activity-super-stat {
  display: flex;
  align-items: center;
  gap: 6px;
  color: var(--f-text-muted);
  font-size: 0.85rem;
  font-weight: 700;
}

.activity-super-stat i {
  color: var(--f-accent);
  font-size: 1rem;
}

.activity-super-more {
  color: var(--f-accent);
  font-size: 0.85rem;
  font-weight: 800;
  display: flex;
  align-items: center;
  gap: 6px;
}

.activity-super-more i {
  transition: transform 0.2s ease;
}

.activity-super:hover .activity-super-more i {
  transform: translateX(4px);
}

/* RTL Adjustments */
[dir="rtl"] .activity-super-more i {
  transform: scaleX(-1);
}
[dir="rtl"] .activity-super:hover .activity-super-more i {
  transform: scaleX(-1) translateX(4px);
}

/* Shared Comment Composer */
.forum-rdx-comment-form-shell {
  --comment-surface: #ffffff;
  --comment-surface-alt: #f7f8fd;
  --comment-border: #e7e9f4;
  --comment-text: #3e3f5e;
  --comment-text-muted: #8f91ac;
  --comment-accent: #615dfa;
  --comment-accent-strong: #504be5;
  --comment-accent-ring: rgba(97, 93, 250, 0.16);
  --comment-shadow: 0 18px 36px rgba(94, 92, 154, 0.1);

  display: flex;
  align-items: flex-start;
  gap: 16px;
  padding: 22px 24px;
  border-radius: 16px;
  background: linear-gradient(180deg, #fff 0%, #f9faff 100%);
  box-shadow: var(--comment-shadow);
}

.forum-rdx-comment-form-shell .user-avatar {
  position: relative;
  top: auto;
  left: auto;
  flex-shrink: 0;
  margin-top: 6px;
}

.forum-rdx-comment-form-shell .form {
  min-width: 0;
  flex: 1;
}

.forum-rdx-comment-form-shell .form-row,
.forum-rdx-comment-form-shell .form-item {
  margin: 0;
}

.forum-rdx-comment-form-shell .forum-rdx-comment-form-main {
  width: 100%;
}

.forum-rdx-comment-form-shell .forum-rdx-comment-composer {
  padding: 14px 16px;
  border: 1px solid var(--comment-border);
  border-radius: 16px;
  background: linear-gradient(180deg, rgba(252, 252, 253, 0.98) 0%, rgba(246, 247, 252, 0.98) 100%);
  box-shadow: inset 0 1px 0 rgba(255, 255, 255, 0.8);
  transition: border-color 0.18s ease, box-shadow 0.18s ease, background-color 0.18s ease, transform 0.18s ease;
}

.forum-rdx-comment-form-shell .forum-rdx-comment-composer:focus-within {
  border-color: rgba(97, 93, 250, 0.28);
  background: linear-gradient(180deg, #fff 0%, #fbfbff 100%);
  box-shadow:
    0 0 0 4px rgba(97, 93, 250, 0.08),
    0 20px 40px rgba(94, 92, 154, 0.12);
  transform: translateY(-1px);
}

.forum-rdx-comment-form-shell .forum-rdx-comment-toolbar {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  margin-bottom: 10px;
  padding-bottom: 12px;
  border-bottom: 1px solid rgba(231, 233, 244, 0.95);
}

.forum-rdx-comment-form-shell .forum-rdx-tool-btn {
  width: 34px;
  height: 34px;
  border-radius: 10px;
  border: 1px solid var(--comment-border);
  background: rgba(255, 255, 255, 0.8);
  color: var(--comment-text-muted);
  display: inline-flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  box-shadow: 0 6px 14px rgba(94, 92, 154, 0.05);
  transition: border-color 0.15s ease, color 0.15s ease, background-color 0.15s ease, transform 0.15s ease, box-shadow 0.15s ease;
}

.forum-rdx-comment-form-shell .forum-rdx-tool-btn:hover,
.forum-rdx-comment-form-shell .forum-rdx-tool-btn:focus-visible {
  outline: 0;
  border-color: rgba(97, 93, 250, 0.18);
  color: var(--comment-accent);
  background: rgba(97, 93, 250, 0.08);
  box-shadow: 0 10px 18px rgba(94, 92, 154, 0.08);
  transform: translateY(-1px);
}

.forum-rdx-comment-form-shell .forum-rdx-comment-input {
  min-height: 98px;
  max-height: 280px;
  width: 100%;
  padding: 0;
  border: 0;
  background: transparent;
  resize: vertical;
  color: var(--comment-text);
  font-size: 0.9rem;
  font-weight: 600;
  line-height: 1.7;
}

.forum-rdx-comment-form-shell .forum-rdx-comment-input::placeholder {
  color: #9b9db8;
  font-weight: 600;
}

.forum-rdx-comment-form-shell .forum-rdx-comment-input:focus {
  outline: 0;
}

.forum-rdx-comment-form-shell .forum-rdx-comment-footer {
  display: flex;
  justify-content: flex-end;
  align-items: center;
  margin-top: 14px;
  padding-top: 10px;
  border-top: 1px solid rgba(231, 233, 244, 0.9);
}

.forum-rdx-comment-form-shell .forum-rdx-comment-send {
  min-width: 42px;
  width: 42px;
  height: 42px;
  padding: 0;
  border: 0;
  border-radius: 12px;
  background: linear-gradient(135deg, var(--comment-accent) 0%, var(--comment-accent-strong) 100%);
  color: #fff;
  display: inline-flex;
  align-items: center;
  justify-content: center;
  box-shadow: 0 12px 24px rgba(97, 93, 250, 0.28);
  transition: opacity 0.15s ease, transform 0.18s ease, box-shadow 0.18s ease, filter 0.18s ease;
}

.forum-rdx-comment-form-shell .forum-rdx-comment-send:hover,
.forum-rdx-comment-form-shell .forum-rdx-comment-send:focus-visible {
  outline: 0;
  transform: translateY(-1px);
  filter: brightness(1.02);
  box-shadow:
    0 0 0 4px var(--comment-accent-ring),
    0 18px 30px rgba(97, 93, 250, 0.34);
}

.forum-rdx-comment-form-shell .forum-rdx-comment-send .interactive-input-icon {
  width: 18px;
  height: 18px;
  fill: currentColor;
}

@media screen and (max-width: 640px) {
  .forum-rdx-comment-form-shell {
    gap: 12px;
    padding: 16px;
  }

  .forum-rdx-comment-form-shell .forum-rdx-comment-composer {
    padding: 12px;
    border-radius: 14px;
  }

  .forum-rdx-comment-form-shell .forum-rdx-comment-toolbar {
    gap: 6px;
    margin-bottom: 8px;
    padding-bottom: 10px;
  }

  .forum-rdx-comment-form-shell .forum-rdx-tool-btn {
    width: 32px;
    height: 32px;
    border-radius: 9px;
  }

  .forum-rdx-comment-form-shell .forum-rdx-comment-input {
    min-height: 88px;
    font-size: 0.85rem;
  }

  .forum-rdx-comment-form-shell .forum-rdx-comment-footer {
    margin-top: 12px;
    padding-top: 8px;
  }

  .forum-rdx-comment-form-shell .forum-rdx-comment-send {
    min-width: 40px;
    width: 40px;
    height: 40px;
    border-radius: 11px;
  }
}

html[dir="rtl"] .forum-rdx-comment-form-shell {
  direction: rtl;
}

html[dir="rtl"] .forum-rdx-comment-form-shell .forum-rdx-comment-footer {
  justify-content: flex-start;
}
