/* صفحة الدعم — تصميم مميز */
.page-support .site-main { padding-top: 0; }

.support-page {
  --sp-primary: #1a4d8c;
  --sp-primary-dark: #153d6e;
  --sp-accent: #0d9488;
  --sp-glow: rgba(26, 77, 140, 0.15);
  background: linear-gradient(180deg, #f0f4fa 0%, #f8fafc 40%, #fff 100%);
  margin: 0 -0.5rem;
  padding-bottom: 4rem;
}

/* Hero */
.support-hero {
  position: relative;
  overflow: hidden;
  padding: 3.5rem 0 4rem;
  margin-bottom: -2rem;
  background: linear-gradient(135deg, #153d6e 0%, #1a4d8c 40%, #2563a8 70%, #0d9488 100%);
  color: #fff;
  border-radius: 0 0 32px 32px;
}
.support-hero::before {
  content: '';
  position: absolute;
  inset: 0;
  background:
    radial-gradient(circle at 20% 80%, rgba(255,255,255,0.12) 0%, transparent 45%),
    radial-gradient(circle at 85% 20%, rgba(13,148,136,0.35) 0%, transparent 40%);
  pointer-events: none;
}
.support-hero::after {
  content: '';
  position: absolute;
  width: 320px;
  height: 320px;
  border-radius: 50%;
  background: rgba(255,255,255,0.06);
  top: -120px;
  left: -80px;
}
.support-hero-inner {
  position: relative;
  z-index: 1;
  display: grid;
  grid-template-columns: 1fr auto;
  gap: 2rem;
  align-items: center;
}
@media (max-width: 768px) {
  .support-hero-inner { grid-template-columns: 1fr; }
}
.support-hero-badge {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  background: rgba(255,255,255,0.15);
  backdrop-filter: blur(8px);
  padding: 0.35rem 0.9rem;
  border-radius: 50px;
  font-size: 0.8rem;
  font-weight: 600;
  margin-bottom: 1rem;
  border: 1px solid rgba(255,255,255,0.2);
}
.support-hero h1 {
  margin: 0 0 0.75rem;
  font-size: clamp(1.75rem, 4vw, 2.35rem);
  font-weight: 800;
  line-height: 1.3;
}
.support-hero h1 i {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  width: 52px;
  height: 52px;
  background: rgba(255,255,255,0.2);
  border-radius: 14px;
  margin-inline-end: 0.65rem;
  vertical-align: middle;
  font-size: 1.35rem;
}
.support-hero-desc {
  margin: 0;
  font-size: 1.05rem;
  opacity: 0.92;
  max-width: 520px;
  line-height: 1.7;
}
.support-hero-stats {
  display: flex;
  flex-direction: column;
  gap: 0.75rem;
  min-width: 200px;
}
.support-hero-stat {
  background: rgba(255,255,255,0.12);
  backdrop-filter: blur(10px);
  border: 1px solid rgba(255,255,255,0.18);
  border-radius: 14px;
  padding: 0.85rem 1.1rem;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.support-hero-stat i {
  font-size: 1.25rem;
  opacity: 0.9;
}
.support-hero-stat strong {
  display: block;
  font-size: 1.1rem;
  font-weight: 800;
}
.support-hero-stat span {
  font-size: 0.78rem;
  opacity: 0.85;
}

/* قنوات التواصل */
.support-channels {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 1rem;
  margin-bottom: 2rem;
  position: relative;
  z-index: 2;
}
@media (max-width: 768px) {
  .support-channels { grid-template-columns: 1fr; }
}
.support-channel {
  background: #fff;
  border-radius: 16px;
  padding: 1.25rem 1.35rem;
  display: flex;
  align-items: flex-start;
  gap: 1rem;
  box-shadow: 0 8px 24px var(--sp-glow);
  border: 1px solid #e8eef5;
  transition: transform 0.2s, box-shadow 0.2s;
}
.support-channel:hover {
  transform: translateY(-3px);
  box-shadow: 0 12px 32px var(--sp-glow);
}
.support-channel-icon {
  width: 48px;
  height: 48px;
  border-radius: 12px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.2rem;
  flex-shrink: 0;
}
.support-channel-icon.teal { background: #ecfdf5; color: #0d9488; }
.support-channel-icon.blue { background: #eff6ff; color: #1a4d8c; }
.support-channel-icon.amber { background: #fffbeb; color: #d97706; }
.support-channel h3 {
  margin: 0 0 0.25rem;
  font-size: 0.95rem;
  font-weight: 700;
  color: #0f172a;
}
.support-channel p {
  margin: 0;
  font-size: 0.82rem;
  color: #64748b;
  line-height: 1.5;
}

/* التنبيهات */
.support-alert {
  display: flex;
  align-items: flex-start;
  gap: 0.75rem;
  padding: 1rem 1.25rem;
  border-radius: 14px;
  margin-bottom: 1.5rem;
  font-weight: 500;
  animation: supportFadeIn 0.4s ease;
}
.support-alert i { font-size: 1.25rem; margin-top: 0.1rem; }
.support-alert.success {
  background: linear-gradient(135deg, #ecfdf5, #d1fae5);
  color: #065f46;
  border: 1px solid #6ee7b7;
}
.support-alert.error {
  background: linear-gradient(135deg, #fef2f2, #fee2e2);
  color: #991b1b;
  border: 1px solid #fca5a5;
}
@keyframes supportFadeIn {
  from { opacity: 0; transform: translateY(-8px); }
  to { opacity: 1; transform: translateY(0); }
}

/* الشبكة الرئيسية */
.support-layout {
  display: grid;
  grid-template-columns: 1.15fr 0.85fr;
  gap: 1.75rem;
  align-items: start;
}
@media (max-width: 992px) {
  .support-layout { grid-template-columns: 1fr; }
}

.support-card {
  background: #fff;
  border-radius: 20px;
  border: 1px solid #e8eef5;
  box-shadow: 0 4px 20px rgba(26, 77, 140, 0.06);
  overflow: hidden;
}
.support-card-head {
  padding: 1.35rem 1.5rem;
  border-bottom: 1px solid #f1f5f9;
  display: flex;
  align-items: center;
  gap: 0.75rem;
}
.support-card-head-icon {
  width: 44px;
  height: 44px;
  border-radius: 12px;
  background: linear-gradient(135deg, #1a4d8c, #2563a8);
  color: #fff;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 1.1rem;
}
.support-card-head h2 {
  margin: 0;
  font-size: 1.15rem;
  font-weight: 800;
  color: #0f172a;
}
.support-card-head p {
  margin: 0.15rem 0 0;
  font-size: 0.8rem;
  color: #64748b;
}
.support-card-body { padding: 1.5rem; }

/* النموذج */
.support-form .form-group { margin-bottom: 1.15rem; }
.support-form label {
  display: block;
  font-weight: 600;
  font-size: 0.88rem;
  color: #334155;
  margin-bottom: 0.45rem;
}
.support-input-wrap {
  position: relative;
}
.support-input-wrap i {
  position: absolute;
  top: 50%;
  transform: translateY(-50%);
  inset-inline-start: 1rem;
  color: #94a3b8;
  pointer-events: none;
}
.support-input-wrap input,
.support-input-wrap select,
.support-input-wrap textarea {
  width: 100%;
  padding: 0.75rem 1rem 0.75rem 2.75rem;
  border: 2px solid #e2e8f0;
  border-radius: 12px;
  font-family: inherit;
  font-size: 0.95rem;
  transition: border-color 0.2s, box-shadow 0.2s;
  background: #fafbfc;
}
.support-input-wrap textarea { padding-top: 0.85rem; min-height: 130px; resize: vertical; }
.support-input-wrap select { cursor: pointer; }
.support-input-wrap input:focus,
.support-input-wrap select:focus,
.support-input-wrap textarea:focus {
  outline: none;
  border-color: var(--sp-primary);
  box-shadow: 0 0 0 4px var(--sp-glow);
  background: #fff;
}
.support-input-wrap.textarea-wrap i { top: 1rem; transform: none; }

.support-subject-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 0.5rem;
  margin-bottom: 1.15rem;
}
@media (max-width: 600px) {
  .support-subject-grid { grid-template-columns: repeat(2, 1fr); }
}
.support-subject-opt { position: relative; }
.support-subject-opt input {
  position: absolute;
  opacity: 0;
  width: 0;
  height: 0;
}
.support-subject-opt label {
  display: flex;
  flex-direction: column;
  align-items: center;
  gap: 0.35rem;
  padding: 0.75rem 0.5rem;
  border: 2px solid #e2e8f0;
  border-radius: 12px;
  cursor: pointer;
  text-align: center;
  font-size: 0.75rem;
  font-weight: 600;
  color: #475569;
  transition: all 0.2s;
  margin: 0;
  background: #fafbfc;
}
.support-subject-opt label i { font-size: 1.15rem; color: #94a3b8; }
.support-subject-opt input:checked + label {
  border-color: var(--sp-primary);
  background: #eff6ff;
  color: var(--sp-primary);
  box-shadow: 0 0 0 3px var(--sp-glow);
}
.support-subject-opt input:checked + label i { color: var(--sp-primary); }

.support-submit {
  width: 100%;
  padding: 1rem 1.5rem;
  border: none;
  border-radius: 14px;
  background: linear-gradient(135deg, #1a4d8c, #2563a8);
  color: #fff;
  font-family: inherit;
  font-size: 1rem;
  font-weight: 700;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 0.5rem;
  transition: transform 0.2s, box-shadow 0.2s;
  box-shadow: 0 8px 20px rgba(26, 77, 140, 0.35);
}
.support-submit:hover {
  transform: translateY(-2px);
  box-shadow: 0 12px 28px rgba(26, 77, 140, 0.4);
}

/* الأسئلة الشائعة */
.support-faq-list { padding: 0; margin: 0; list-style: none; }
.support-faq-item {
  border-bottom: 1px solid #f1f5f9;
}
.support-faq-item:last-child { border-bottom: none; }
.support-faq-q {
  width: 100%;
  display: flex;
  align-items: center;
  justify-content: space-between;
  gap: 1rem;
  padding: 1rem 1.5rem;
  border: none;
  background: none;
  font-family: inherit;
  font-size: 0.95rem;
  font-weight: 700;
  color: #0f172a;
  cursor: pointer;
  text-align: start;
  transition: background 0.15s;
}
.support-faq-q:hover { background: #f8fafc; }
.support-faq-q i {
  color: var(--sp-primary);
  transition: transform 0.25s;
  flex-shrink: 0;
}
.support-faq-item.open .support-faq-q i { transform: rotate(180deg); }
.support-faq-a {
  max-height: 0;
  overflow: hidden;
  transition: max-height 0.3s ease;
}
.support-faq-item.open .support-faq-a { max-height: 200px; }
.support-faq-a-inner {
  padding: 0 1.5rem 1.15rem;
  font-size: 0.9rem;
  color: #64748b;
  line-height: 1.7;
}

/* التذاكر */
.support-tickets-section { margin-top: 1.75rem; }
.support-ticket-card {
  background: #fff;
  border: 1px solid #e8eef5;
  border-radius: 16px;
  padding: 1.25rem 1.35rem;
  margin-bottom: 1rem;
  position: relative;
  overflow: hidden;
}
.support-ticket-card::before {
  content: '';
  position: absolute;
  inset-inline-start: 0;
  top: 0;
  bottom: 0;
  width: 4px;
  background: linear-gradient(180deg, #1a4d8c, #0d9488);
  border-radius: 4px 0 0 4px;
}
.support-ticket-top {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 0.75rem;
  margin-bottom: 0.65rem;
}
.support-ticket-top strong {
  font-size: 1rem;
  color: #0f172a;
}
.support-ticket-date {
  font-size: 0.78rem;
  color: #94a3b8;
  margin-bottom: 0.5rem;
}
.support-ticket-msg {
  font-size: 0.9rem;
  color: #475569;
  line-height: 1.65;
  margin: 0;
}
.support-ticket-status {
  font-size: 0.72rem;
  font-weight: 700;
  padding: 0.3rem 0.65rem;
  border-radius: 50px;
  white-space: nowrap;
}
.support-ticket-status.open { background: #fef3c7; color: #92400e; }
.support-ticket-status.answered { background: #dbeafe; color: #1d4ed8; }
.support-ticket-status.closed { background: #f1f5f9; color: #64748b; }

.support-reply-box {
  margin-top: 1rem;
  padding: 1rem 1.15rem;
  background: linear-gradient(135deg, #eff6ff, #ecfdf5);
  border-radius: 12px;
  border: 1px solid #bfdbfe;
}
.support-reply-box strong {
  display: flex;
  align-items: center;
  gap: 0.4rem;
  color: #1a4d8c;
  font-size: 0.85rem;
  margin-bottom: 0.5rem;
}
.support-reply-box p {
  margin: 0;
  font-size: 0.9rem;
  color: #334155;
  line-height: 1.65;
}

.support-empty {
  text-align: center;
  padding: 2rem 1rem;
  color: #94a3b8;
}
.support-empty i {
  font-size: 2.5rem;
  margin-bottom: 0.75rem;
  opacity: 0.5;
}
