/* Daily Missions Page Styles */
/* Unique prefix: ms- to avoid conflicts */
/* Consistent with site design - No box-shadow */

.ms-container {
  width: 100%;
  padding: ;
  padding-bottom: 100px;
  margin: 0;
}

/* Remove main-content padding for tasks page */
#tasks-page.page-content {
  margin-left: -3px;
  margin-right: -3px;
}

#tasks-page .ms-container {
  padding: 0 2px;
}

/* Mission hint message - shows inside mission element */
.ms-mission-hint {
  position: absolute;
  bottom: 100%;
  left: 50%;
  transform: translateX(-50%);
  background: linear-gradient(135deg, #ff6b35, #f7931e);
  color: white;
  padding: 6px 12px;
  border-radius: 8px;
  font-size: 12px;
  font-weight: 500;
  white-space: nowrap;
  opacity: 0;
  visibility: hidden;
  transition: all 0.3s ease;
  z-index: 10;
  margin-bottom: 8px;
}

.ms-mission-hint::after {
  content: '';
  position: absolute;
  top: 100%;
  left: 50%;
  transform: translateX(-50%);
  border: 6px solid transparent;
  border-top-color: #f7931e;
}

.ms-mission-hint.ms-hint-show {
  opacity: 1;
  visibility: visible;
}

/* Make mission item relative for hint positioning */
.ms-mission-item,
.ms-item {
  position: relative;
}

/* Dark mode hint */
[data-theme="dark"] .ms-mission-hint,
.dark-theme .ms-mission-hint {
  background: linear-gradient(135deg, #ff6b35, #f7931e);
}

/* Dark mode container */
[data-theme="dark"] .ms-container,
.dark-theme .ms-container {
  background-color: #1a1a1a;
  color: #f5f5f5;
}

/* Missions Header */
.ms-header {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  margin-bottom: 20px;
  padding: 16px;
  background: var(--card-bg);
  border-radius: 12px;
  border: 1px solid var(--border-color);
}

/* Dark mode header */
[data-theme="dark"] .ms-header,
.dark-theme .ms-header {
  background: #2a2a2a;
  border-color: #3a3a3a;
}

.ms-title-section h2 {
  font-size: 20px;
  font-weight: 700;
  color: var(--text-color);
  margin: 0 0 4px 0;
}

/* Dark mode title */
[data-theme="dark"] .ms-title-section h2,
.dark-theme .ms-title-section h2 {
  color: #f5f5f5;
}

.ms-subtitle {
  font-size: 13px;
  color: var(--light-text);
  margin: 0;
}

/* Dark mode subtitle */
[data-theme="dark"] .ms-subtitle,
.dark-theme .ms-subtitle {
  color: #aaaaaa;
}

.ms-streak-badge {
  display: flex;
  align-items: center;
  gap: 6px;
  padding: 8px 14px;
  background: linear-gradient(135deg, #ff6b35, #f7931e);
  border-radius: 20px;
  color: white;
  font-weight: 600;
  font-size: 14px;
}

.ms-streak-badge i {
  font-size: 16px;
}

/* Missions Section */
.ms-section {
  background: var(--card-bg);
  border-radius: 12px;
  border: 1px solid var(--border-color);
  margin-bottom: 16px;
  overflow: hidden;
}

/* Dark mode section - using actual theme system classes */
[data-theme="dark"] .ms-section,
.dark-theme .ms-section {
  background: #2a2a2a;
  border-color: #3a3a3a;
}

.ms-section-header {
  display: flex;
  align-items: center;
  gap: 10px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border-color);
  background: var(--bg-color);
}

/* Dark mode section header */
[data-theme="dark"] .ms-section-header,
.dark-theme .ms-section-header {
  background: #333333;
  border-bottom-color: #3a3a3a;
}

.ms-section-header i {
  font-size: 16px;
  color: var(--primary-color);
}

.ms-section-header h3 {
  font-size: 15px;
  font-weight: 600;
  color: var(--text-color);
  margin: 0;
  flex: 1;
}

/* Dark mode section header h3 */
[data-theme="dark"] .ms-section-header h3,
.dark-theme .ms-section-header h3 {
  color: #f5f5f5;
}

.ms-section-bonus {
  font-size: 13px;
  font-weight: 600;
  color: #10b981;
  background: rgba(16, 185, 129, 0.1);
  padding: 4px 10px;
  border-radius: 12px;
}

/* Login Streak */
.ms-streak-container {
  padding: 16px;
}

/* Dark mode streak container */
[data-theme="dark"] .ms-streak-container,
.dark-theme .ms-streak-container {
  background: #2a2a2a;
}

.ms-streak-days {
  display: flex;
  justify-content: space-between;
  gap: 8px;
  margin-bottom: 16px;
}

.ms-streak-day {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 6px;
  flex: 1;
}

.ms-day-circle {
  width: 40px;
  height: 40px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  background: var(--bg-color);
  border: 2px solid var(--border-color);
  color: var(--light-text);
  font-weight: 600;
  font-size: 14px;
  transition: all 0.3s ease;
}

/* Dark mode day circle */
[data-theme="dark"] .ms-day-circle,
.dark-theme .ms-day-circle {
  background: #333333;
  border-color: #444444;
  color: #aaaaaa;
}

.ms-streak-day.completed .ms-day-circle {
  background: linear-gradient(135deg, #10b981, #059669) !important;
  border-color: #10b981 !important;
  color: white !important;
}

.ms-streak-day.current .ms-day-circle {
  border-color: var(--primary-color) !important;
  color: var(--primary-color) !important;
  animation: ms-pulse-border 2s infinite !important;
}

.ms-streak-day.special .ms-day-circle {
  background: linear-gradient(135deg, #f59e0b, #d97706);
  border-color: #f59e0b;
  color: white;
}

.ms-streak-day.special.completed .ms-day-circle {
  background: linear-gradient(135deg, #10b981, #059669);
  border-color: #10b981;
}

@keyframes ms-pulse-border {
  0%, 100% { transform: scale(1); }
  50% { transform: scale(1.05); }
}

.ms-day-reward {
  font-size: 11px;
  color: var(--light-text);
  font-weight: 500;
}

/* Dark mode day reward */
[data-theme="dark"] .ms-day-reward,
.dark-theme .ms-day-reward {
  color: #aaaaaa;
}

.ms-streak-day.completed .ms-day-reward {
  color: #10b981;
}

.ms-claim-daily-btn {
  width: 100%;
  padding: 12px 40px;
  background: linear-gradient(135deg, var(--primary-color), #5a4fcf);
  color: white;
  border: none;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.3s ease;
  position: relative;
  text-align: center;
}

.ms-claim-daily-btn i {
  position: absolute;
  left: 16px;
  top: 50%;
  transform: translateY(-50%);
}

.ms-claim-daily-btn span {
  display: inline-block;
  position: relative;
  left: -5px;
}

.ms-claim-daily-btn:hover {
  opacity: 0.9;
}

.ms-claim-daily-btn:disabled {
  background: var(--border-color);
  color: var(--light-text);
  cursor: not-allowed;
}

/* Dark mode disabled button */
[data-theme="dark"] .ms-claim-daily-btn:disabled,
.dark-theme .ms-claim-daily-btn:disabled {
  background: #333333;
  color: #666666;
}

.ms-claim-daily-btn.claimed {
  background: #10b981;
}

/* Missions List */
.ms-list {
  padding: 0;
}

.ms-item {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 14px 16px;
  border-bottom: 1px solid var(--border-color);
  transition: background 0.2s ease;
}

/* Dark mode item */
[data-theme="dark"] .ms-item,
.dark-theme .ms-item {
  border-bottom-color: #3a3a3a;
}

.ms-item:last-child {
  border-bottom: none;
}

.ms-item:hover {
  background: var(--bg-color);
}

/* Dark mode item hover */
[data-theme="dark"] .ms-item:hover,
.dark-theme .ms-item:hover {
  background: #333333;
}

.ms-item.completed {
  opacity: 0.7;
  pointer-events: none;
}

/* إخفاء الزر عند إكمال المهمة وإظهار علامة ✓ */
.ms-item.completed .ms-btn {
  background: #22c55e !important;
  border-color: #22c55e !important;
  color: white !important;
  pointer-events: none;
  cursor: default;
}

.ms-item.completed .ms-btn span {
  display: none;
}

.ms-item.completed .ms-btn::after {
  content: "✓";
  font-size: 16px;
  font-weight: bold;
}

.ms-icon {
  width: 42px;
  height: 42px;
  border-radius: 10px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 18px;
  flex-shrink: 0;
}

.ms-icon.twitter {
  background: rgba(0, 0, 0, 0.1);
  color: #000;
}

/* Dark mode twitter icon - using actual theme system classes */
[data-theme="dark"] .ms-icon.twitter,
.dark-theme .ms-icon.twitter {
  background: #333333;
  color: #f5f5f5;
}

.ms-icon.telegram {
  background: rgba(0, 136, 204, 0.1);
  color: #0088cc;
}

.ms-icon.activity {
  background: rgba(99, 102, 241, 0.1);
  color: #6366f1;
}

.ms-icon.transaction {
  background: rgba(16, 185, 129, 0.1);
  color: #10b981;
}

.ms-icon.referral {
  background: rgba(245, 158, 11, 0.1);
  color: #f59e0b;
}

.ms-icon.profile {
  background: rgba(139, 92, 246, 0.1);
  color: #8b5cf6;
}

.ms-icon.network {
  background: rgba(59, 130, 246, 0.1);
  color: #3b82f6;
}

.ms-info {
  flex: 1;
  min-width: 0;
}

.ms-title {
  display: block;
  font-size: 14px;
  font-weight: 600;
  color: var(--text-color);
  margin-bottom: 2px;
}

/* Dark mode title */
[data-theme="dark"] .ms-title,
.dark-theme .ms-title {
  color: #f5f5f5;
}

.ms-desc {
  display: block;
  font-size: 12px;
  color: var(--light-text);
}

/* Dark mode description */
[data-theme="dark"] .ms-desc,
.dark-theme .ms-desc {
  color: #aaaaaa;
}

.ms-reward {
  display: flex;
  align-items: center;
  gap: 4px;
  font-size: 14px;
  font-weight: 600;
  color: #10b981;
  flex-shrink: 0;
}

.ms-reward-icon {
  width: 16px;
  height: 16px;
  object-fit: contain;
}

.ms-btn {
  padding: 8px 16px;
  background: var(--primary-color);
  color: white;
  border: none;
  border-radius: 8px;
  font-size: 13px;
  font-weight: 600;
  cursor: pointer;
  transition: opacity 0.2s ease;
  flex-shrink: 0;
}

.ms-btn:hover {
  opacity: 0.9;
}

.ms-btn.completed {
  background: #10b981;
  pointer-events: none;
}

.ms-btn.completed::after {
  content: '✓';
}

.ms-btn.completed span {
  display: none;
}

.ms-btn.pending {
  background: var(--border-color);
  color: var(--light-text);
}

/* Dark mode pending button */
[data-theme="dark"] .ms-btn.pending,
.dark-theme .ms-btn.pending {
  background: #333333;
  color: #666666;
}

.ms-btn.verify {
  background: #f59e0b;
}

/* Bonus Section */
.ms-bonus-section {
  background: linear-gradient(135deg, var(--card-bg), var(--bg-color));
}

/* Dark mode bonus section */
[data-theme="dark"] .ms-bonus-section,
.dark-theme .ms-bonus-section {
  background: linear-gradient(135deg, #2a2a2a, #333333);
}

.ms-bonus-container {
  padding: 16px;
}

.ms-bonus-info {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 10px;
}

.ms-bonus-info span:first-child {
  font-size: 13px;
  color: var(--text-color);
}

/* Dark mode bonus info */
[data-theme="dark"] .ms-bonus-info span:first-child,
.dark-theme .ms-bonus-info span:first-child {
  color: #f5f5f5;
}

.ms-bonus-amount {
  font-size: 14px;
  font-weight: 700;
  color: #f59e0b;
}

.ms-bonus-progress-bar {
  height: 8px;
  background: var(--border-color);
  border-radius: 4px;
  overflow: hidden;
  margin-bottom: 8px;
}

/* Dark mode progress bar */
[data-theme="dark"] .ms-bonus-progress-bar,
.dark-theme .ms-bonus-progress-bar {
  background: #333333;
}

.ms-bonus-progress {
  height: 100%;
  background: linear-gradient(90deg, #f59e0b, #fbbf24);
  border-radius: 4px;
  transition: width 0.5s ease;
  width: 0%;
}

.ms-bonus-status {
  font-size: 12px;
  color: var(--light-text);
  text-align: center;
}

/* Dark mode bonus status */
[data-theme="dark"] .ms-bonus-status,
.dark-theme .ms-bonus-status {
  color: #aaaaaa;
}

.ms-claim-bonus-btn {
  width: calc(100% - 32px);
  margin: 0 16px 16px;
  padding: 12px;
  background: linear-gradient(135deg, #f59e0b, #d97706);
  color: white;
  border: none;
  border-radius: 10px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.ms-claim-bonus-btn:disabled {
  background: var(--border-color);
  color: var(--light-text);
  cursor: not-allowed;
}

/* Dark mode disabled bonus button */
[data-theme="dark"] .ms-claim-bonus-btn:disabled,
.dark-theme .ms-claim-bonus-btn:disabled {
  background: #333333;
  color: #666666;
}

.ms-claim-bonus-btn.claimed {
  background: #10b981;
}

/* Reset Timer */
.ms-reset-timer {
  text-align: center;
  padding: 12px;
  font-size: 13px;
  color: var(--light-text);
  background: var(--bg-color);
  border-radius: 10px;
  margin-top: 8px;
}

/* Dark mode reset timer */
[data-theme="dark"] .ms-reset-timer,
.dark-theme .ms-reset-timer {
  background: #333333;
  color: #aaaaaa;
}

.ms-reset-timer span {
  color: var(--primary-color);
  font-weight: 600;
}

/* Verification Modal */
.ms-modal-overlay {
  position: fixed;
  top: 0;
  left: 0;
  right: 0;
  bottom: 0;
  background: rgba(0, 0, 0, 0.7);
  display: flex;
  align-items: center;
  justify-content: center;
  z-index: 99999;
  padding: 20px;
}

/* Dark mode modal overlay - using actual theme system classes */
[data-theme="dark"] .ms-modal-overlay,
.dark-theme .ms-modal-overlay {
  background: rgba(0, 0, 0, 0.8);
}

/* Light mode modal */
.ms-modal {
  background: #ffffff !important;
  border-radius: 16px;
  width: 100%;
  max-width: 360px;
  overflow: hidden;
  border: 1px solid #e5e7eb;
  box-shadow: 0 25px 50px rgba(0, 0, 0, 0.25);
}

/* Dark mode modal - using actual theme system classes */
[data-theme="dark"] .ms-modal,
.dark-theme .ms-modal {
  background: #2a2a2a !important;
  border: 1px solid #3a3a3a;
}

/* Light mode header */
.ms-modal-header {
  padding: 18px 20px;
  border-bottom: 1px solid #e5e7eb;
  display: flex;
  align-items: center;
  justify-content: space-between;
  background: #f9fafb !important;
}

/* Dark mode header - using actual theme system classes */
[data-theme="dark"] .ms-modal-header,
.dark-theme .ms-modal-header {
  background: #333333 !important;
  border-bottom: 1px solid #3a3a3a;
}

.ms-modal-header h3 {
  font-size: 17px;
  font-weight: 700;
  color: #2a2a2a;
  margin: 0;
}

[data-theme="dark"] .ms-modal-header h3,
.dark-theme .ms-modal-header h3 {
  color: #f5f5f5;
}

.ms-modal-close {
  width: 32px;
  height: 32px;
  border-radius: 8px;
  border: none;
  background: #e5e7eb;
  color: #374151;
  cursor: pointer;
  font-size: 20px;
  font-weight: 400;
  display: flex;
  align-items: center;
  justify-content: center;
  transition: background 0.2s ease;
}

[data-theme="dark"] .ms-modal-close,
.dark-theme .ms-modal-close {
  background: #333333;
  color: #f5f5f5;
}

.ms-modal-close:hover {
  background: #d1d5db;
}

[data-theme="dark"] .ms-modal-close:hover,
.dark-theme .ms-modal-close:hover {
  background: #444444;
}

/* Light mode body */
.ms-modal-body {
  padding: 24px 20px;
  text-align: center;
  background: #ffffff !important;
}

/* Dark mode body - using actual theme system classes */
[data-theme="dark"] .ms-modal-body,
.dark-theme .ms-modal-body {
  background: #2a2a2a !important;
}

.ms-modal-icon {
  width: 72px;
  height: 72px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 32px;
  margin: 0 auto 20px;
}

.ms-modal-icon.twitter {
  background: #f3f4f6;
  color: #000;
}

[data-theme="dark"] .ms-modal-icon.twitter,
.dark-theme .ms-modal-icon.twitter {
  background: #333333;
  color: #fff;
}

.ms-modal-icon.telegram {
  background: rgba(0, 136, 204, 0.15);
  color: #0088cc;
}

.ms-modal-text {
  font-size: 15px;
  color: #374151;
  margin-bottom: 24px;
  line-height: 1.6;
  font-weight: 500;
}

[data-theme="dark"] .ms-modal-text,
.dark-theme .ms-modal-text {
  color: #aaaaaa;
}

/* Light mode steps */
.ms-modal-steps {
  text-align: left;
  margin-bottom: 24px;
  background: #f9fafb !important;
  border-radius: 12px;
  padding: 6px;
  border: 1px solid #e5e7eb;
}

/* Dark mode steps - using actual theme system classes */
[data-theme="dark"] .ms-modal-steps,
.dark-theme .ms-modal-steps {
  background: #1a1a1a !important;
  border: 1px solid #3a3a3a;
}

.ms-modal-step {
  display: flex;
  align-items: center;
  gap: 12px;
  padding: 12px;
}

.ms-modal-step:not(:last-child) {
  border-bottom: 1px solid #e5e7eb;
}

[data-theme="dark"] .ms-modal-step:not(:last-child),
.dark-theme .ms-modal-step:not(:last-child) {
  border-bottom: 1px solid #3a3a3a;
}

.ms-step-number {
  width: 28px;
  height: 28px;
  border-radius: 50%;
  background: var(--primary-color);
  color: white;
  font-size: 13px;
  font-weight: 700;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.ms-step-text {
  font-size: 14px;
  color: #374151;
  line-height: 1.4;
}

[data-theme="dark"] .ms-step-text,
.dark-theme .ms-step-text {
  color: #aaaaaa;
}

.ms-modal-actions {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.ms-action-btn {
  width: 100%;
  padding: 14px;
  border: none;
  border-radius: 12px;
  font-size: 15px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 10px;
  transition: all 0.2s ease;
}

.ms-action-btn.primary {
  background: var(--primary-color);
  color: white;
}

.ms-action-btn.primary:hover {
  opacity: 0.9;
}

/* Light mode secondary button */
.ms-action-btn.secondary {
  background: #f3f4f6;
  color: #374151;
  border: 2px solid #e5e7eb;
}

/* Dark mode secondary button - using actual theme system classes */
[data-theme="dark"] .ms-action-btn.secondary,
.dark-theme .ms-action-btn.secondary {
  background: #333333;
  color: #aaaaaa;
  border: 2px solid #444444;
}

.ms-action-btn.secondary:hover {
  border-color: var(--primary-color);
}

.ms-action-btn:disabled {
  opacity: 0.5;
  cursor: not-allowed;
}

/* Light mode timer */
.ms-verify-timer {
  font-size: 14px;
  color: #374151;
  margin-top: 16px;
  padding: 12px;
  background: #f3f4f6;
  border-radius: 10px;
  border: 1px solid #e5e7eb;
}

/* Dark mode timer - using actual theme system classes */
[data-theme="dark"] .ms-verify-timer,
.dark-theme .ms-verify-timer {
  color: #aaaaaa;
  background: #333333;
  border: 1px solid #3a3a3a;
}

.ms-verify-timer strong {
  color: var(--primary-color);
}

/* Mobile Responsive */
@media (max-width: 480px) {
  .ms-container {
    padding: 12px;
  }
  
  .ms-header {
    flex-direction: column;
    gap: 12px;
  }
  
  .ms-streak-badge {
    align-self: flex-start;
  }
  
  .ms-day-circle {
    width: 36px;
    height: 36px;
    font-size: 12px;
  }
  
  .ms-day-reward {
    font-size: 10px;
  }
  
  .ms-item {
    gap: 10px;
    padding: 12px 14px;
  }
  
  .ms-icon {
    width: 38px;
    height: 38px;
    font-size: 16px;
  }
  
  .ms-title {
    font-size: 13px;
  }
  
  .ms-desc {
    font-size: 11px;
  }
  
  .ms-btn {
    padding: 6px 12px;
    font-size: 12px;
  }

  .ms-modal {
    max-width: 340px;
  }

  .ms-modal-body {
    padding: 20px 16px;
  }

  .ms-modal-icon {
    width: 64px;
    height: 64px;
    font-size: 28px;
  }
}

/* Animation for completed missions */
@keyframes ms-complete-anim {
  0% { transform: scale(1); }
  50% { transform: scale(1.05); }
  100% { transform: scale(1); }
}

.ms-item.just-completed {
  animation: ms-complete-anim 0.5s ease;
}

/* RTL Support for Arabic language */
html[dir="rtl"] .ms-modal-header,
html[lang="ar"] .ms-modal-header {
  flex-direction: row-reverse;
}

html[dir="rtl"] .ms-modal-header h3,
html[lang="ar"] .ms-modal-header h3 {
  flex-direction: row-reverse;
}

html[dir="rtl"] .ms-modal-steps,
html[lang="ar"] .ms-modal-steps {
  text-align: right;
}

html[dir="rtl"] .ms-modal-step,
html[lang="ar"] .ms-modal-step {
  flex-direction: row-reverse;
}

html[dir="rtl"] .ms-modal-actions,
html[lang="ar"] .ms-modal-actions {
  flex-direction: row-reverse;
}

html[dir="rtl"] .ms-action-btn,
html[lang="ar"] .ms-action-btn {
  flex-direction: row-reverse;
}

html[dir="rtl"] .ms-modal-body,
html[lang="ar"] .ms-modal-body {
  text-align: right;
}

html[dir="rtl"] .ms-username-input input,
html[lang="ar"] .ms-username-input input {
  text-align: right;
  direction: ltr;
}

/* RTL Support for Daily Missions Page - Arabic */
/* Only apply RTL to header and daily section, NOT social/activity tasks */
html[dir="rtl"] .ms-header,
html[lang="ar"] .ms-header {
  direction: rtl;
}

/* Header: NO row-reverse - RTL direction handles it automatically */
/* Title section on right, Streak badge on left (automatic with RTL) */

html[dir="rtl"] .ms-title-section,
html[lang="ar"] .ms-title-section {
  text-align: right;
}

html[dir="rtl"] .ms-title-section h2,
html[lang="ar"] .ms-title-section h2 {
  text-align: right;
}

html[dir="rtl"] .ms-title-section p,
html[lang="ar"] .ms-title-section p {
  text-align: right;
}

/* Streak badge stays on left side */
html[dir="rtl"] .ms-streak-badge,
html[lang="ar"] .ms-streak-badge {
  text-align: center;
}

/* Keep ms-item LTR for all languages - no RTL */

/* Keep ms-info LTR for all languages - no RTL */

/* Only Daily section gets RTL - using ID to not affect others */
html[dir="rtl"] #ms-daily-section,
html[lang="ar"] #ms-daily-section {
  direction: rtl;
}

html[dir="rtl"] .ms-daily-container,
html[lang="ar"] .ms-daily-container {
  direction: rtl;
}

html[dir="rtl"] .ms-streak-days,
html[lang="ar"] .ms-streak-days {
  flex-direction: row-reverse;
}

/* Only Daily section header RTL - using ID */
html[dir="rtl"] #ms-daily-header,
html[lang="ar"] #ms-daily-header {
  flex-direction: row-reverse;
  justify-content: flex-end;
}

html[dir="rtl"] #ms-daily-header h3,
html[lang="ar"] #ms-daily-header h3 {
  flex: none;
  text-align: right;
}

html[dir="rtl"] #ms-daily-header i,
html[lang="ar"] #ms-daily-header i {
  margin-right: 0;
  margin-left: 0;
}

/* Bonus section RTL - using ID to not affect others */
html[dir="rtl"] #ms-bonus-section,
html[lang="ar"] #ms-bonus-section {
  direction: rtl;
}

html[dir="rtl"] #ms-bonus-header,
html[lang="ar"] #ms-bonus-header {
  flex-direction: row-reverse;
  justify-content: flex-end;
}

html[dir="rtl"] #ms-bonus-header h3,
html[lang="ar"] #ms-bonus-header h3 {
  flex: none;
  text-align: right;
}

html[dir="rtl"] #ms-bonus-header i,
html[lang="ar"] #ms-bonus-header i {
  margin-right: 0;
  margin-left: 0;
}

/* Keep +0.05 in correct order (+ before number) in Arabic */
html[dir="rtl"] #ms-bonus-section .ms-bonus-amount,
html[lang="ar"] #ms-bonus-section .ms-bonus-amount {
  direction: ltr;
  display: inline-block;
}

/* Force LTR for Social and Activity sections only */
html[dir="rtl"] .ms-section:not(#ms-daily-section):not(#ms-bonus-section),
html[lang="ar"] .ms-section:not(#ms-daily-section):not(#ms-bonus-section) {
  direction: ltr;
  text-align: left;
}
