/* Support contact form + admin tickets — Athar dark / red */

body[data-page="support"] .site-code-panels {
  display: none !important;
}

.support-main {
  position: relative;
  z-index: 2;
  padding: clamp(32px, 6vw, 72px) 16px 88px;
}

.support-inner {
  max-width: 1100px;
  margin: 0 auto;
}

.support-hero {
  margin-bottom: clamp(24px, 4vw, 40px);
}

.support-hero .hero__title {
  margin-bottom: 12px;
}

/* مربع زجاجي للنص التمهيدي — بلور أقوى من بطاقة النموذج ليقرأ فوق الخلفية */
.support-hero-glass {
  max-width: 640px;
  margin: 0 0 4px;
  padding: clamp(16px, 3.2vw, 22px) clamp(18px, 3.5vw, 26px);
  border-radius: 14px;
  border: 1px solid rgba(224, 49, 49, 0.48);
  background: rgba(6, 6, 10, 0.42);
  backdrop-filter: blur(28px) saturate(160%);
  -webkit-backdrop-filter: blur(28px) saturate(160%);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.07) inset,
    0 18px 56px rgba(0, 0, 0, 0.42),
    0 0 100px rgba(224, 49, 49, 0.1);
}

.support-hero-glass__text {
  margin: 0;
  color: rgba(242, 244, 250, 0.96);
  font-size: 0.98rem;
  line-height: 1.68;
}

.support-columns {
  display: grid;
  gap: clamp(20px, 4vw, 32px);
  grid-template-columns: 1fr;
  align-items: stretch;
}

@media (min-width: 960px) {
  .support-columns {
    grid-template-columns: minmax(0, 1fr) minmax(0, 1.15fr);
  }
}

/* Decorative side — tech feel */
.support-aside {
  border-radius: 16px;
  border: 1px solid rgba(224, 49, 49, 0.38);
  background: rgba(10, 10, 14, 0.72);
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.04) inset,
    0 20px 60px rgba(0, 0, 0, 0.45);
  padding: 20px 18px;
  font-family: ui-monospace, "Cascadia Code", Consolas, monospace;
  font-size: 12px;
  line-height: 1.55;
  color: rgba(210, 215, 228, 0.55);
}

.support-aside__label {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  font-size: 11px;
  font-weight: 700;
  letter-spacing: 0.14em;
  text-transform: uppercase;
  color: rgba(224, 49, 49, 0.85);
  margin-bottom: 14px;
}

.support-aside pre {
  margin: 0;
  white-space: pre-wrap;
  word-break: break-word;
}

/* My tickets — customer panel (replaces code aside) */
.support-aside.support-my-panel {
  font-family: inherit;
  font-size: 14px;
  line-height: 1.55;
  color: rgba(218, 222, 235, 0.92);
  display: flex;
  flex-direction: column;
  overflow: hidden;
  min-height: min(70vh, 560px);
}

.support-my-hint {
  margin: 0 0 12px;
  padding: 10px 12px;
  font-size: 13px;
  line-height: 1.5;
  color: rgba(200, 204, 218, 0.88);
  border-radius: 10px;
  border: 1px solid rgba(224, 49, 49, 0.25);
  background: rgba(224, 49, 49, 0.07);
}

.support-my-list {
  list-style: none;
  margin: 0;
  padding: 0;
  flex: 1;
  overflow-y: auto;
  min-height: 120px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.support-my-row {
  margin: 0;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(6, 8, 12, 0.55);
  cursor: pointer;
  transition:
    background 0.12s,
    border-color 0.12s;
}

.support-my-row:hover,
.support-my-row:focus {
  outline: none;
  border-color: rgba(224, 49, 49, 0.42);
  background: rgba(224, 49, 49, 0.09);
}

.support-my-row__main {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 8px 12px;
}

.support-my-row__subj {
  font-weight: 600;
  color: #f0f2f6;
  flex: 1;
  min-width: 0;
  overflow: hidden;
  text-overflow: ellipsis;
  white-space: nowrap;
}

.support-my-row__meta {
  margin-top: 6px;
  font-size: 12px;
  color: rgba(170, 176, 192, 0.72);
}

.cust-badge {
  flex-shrink: 0;
  font-size: 11px;
  font-weight: 700;
  padding: 3px 10px;
  border-radius: 999px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  white-space: nowrap;
}

.cust-badge--open {
  color: #ffb74d;
  border-color: rgba(255, 183, 77, 0.35);
}

.cust-badge--pending {
  color: #64b5f6;
  border-color: rgba(100, 181, 246, 0.35);
}

.cust-badge--replied {
  color: #81c784;
  border-color: rgba(129, 199, 132, 0.35);
}

.cust-badge--closed {
  color: #9e9e9e;
  border-color: rgba(158, 158, 158, 0.35);
}

#supportPanelListRoot {
  display: flex;
  flex-direction: column;
  flex: 1;
  min-height: 0;
}

.support-my-detail-root {
  flex: 1;
  display: flex;
  flex-direction: column;
  min-height: 0;
  overflow: hidden;
}

.support-my-back {
  align-self: stretch;
  margin-top: 14px;
  margin-bottom: 0;
  padding: 8px 14px;
  font-size: 14px;
  font-family: inherit;
  font-weight: 600;
  color: rgba(240, 242, 248, 0.92);
  cursor: pointer;
  border-radius: 10px;
  border: 1px solid rgba(224, 49, 49, 0.35);
  background: rgba(224, 49, 49, 0.1);
  transition:
    background 0.12s,
    border-color 0.12s;
}

.support-my-back:hover {
  background: rgba(224, 49, 49, 0.18);
  border-color: rgba(224, 49, 49, 0.5);
}

.support-my-detail-inner {
  flex: 1;
  overflow-y: auto;
  min-height: 0;
  padding-inline-end: 4px;
}

.support-my-reply {
  flex-shrink: 0;
  margin-top: 12px;
  padding-top: 12px;
  border-top: 1px solid rgba(255, 255, 255, 0.08);
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.support-my-reply__label {
  font-size: 13px;
  font-weight: 700;
  color: rgba(224, 49, 49, 0.9);
  letter-spacing: 0.04em;
}

.support-my-reply__textarea {
  width: 100%;
  min-height: 88px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: rgba(12, 14, 18, 0.95);
  color: #f0f2f5;
  font-size: 14px;
  font-family: inherit;
  line-height: 1.5;
  resize: vertical;
  outline: none;
}

.support-my-reply__textarea:focus {
  border-color: rgba(224, 49, 49, 0.55);
  box-shadow: 0 0 0 3px rgba(224, 49, 49, 0.14);
}

.support-my-reply__submit {
  align-self: flex-start;
  padding: 8px 16px;
  font-size: 14px;
  font-weight: 600;
  font-family: inherit;
  cursor: pointer;
  border-radius: 10px;
  border: 1px solid rgba(224, 49, 49, 0.45);
  background: rgba(224, 49, 49, 0.22);
  color: #fff;
  transition:
    background 0.12s,
    border-color 0.12s;
}

.support-my-reply__submit:hover:not(:disabled) {
  background: rgba(224, 49, 49, 0.35);
}

.support-my-reply__submit:disabled {
  opacity: 0.55;
  cursor: not-allowed;
}

.support-my-reply__err {
  margin: 0;
  font-size: 13px;
  color: #ffb4b4;
}

.support-detail__head {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  justify-content: space-between;
  gap: 10px;
  margin-bottom: 10px;
}

.support-detail__ref {
  font-family: ui-monospace, monospace;
  font-size: 12px;
  letter-spacing: 0.04em;
  color: rgba(190, 196, 212, 0.85);
}

.support-detail__title {
  margin: 0 0 6px;
  font-size: 1.05rem;
  font-weight: 700;
  color: #f4f5f8;
  line-height: 1.4;
}

.support-detail__meta {
  margin: 0 0 16px;
  font-size: 13px;
  color: rgba(170, 176, 192, 0.8);
}

.support-detail__h {
  margin: 0 0 8px;
  font-size: 13px;
  font-weight: 700;
  color: rgba(224, 49, 49, 0.88);
  text-transform: uppercase;
  letter-spacing: 0.06em;
}

.support-detail__body {
  margin: 0;
  white-space: pre-wrap;
  word-break: break-word;
  font-size: 14px;
  line-height: 1.6;
  color: rgba(220, 224, 235, 0.95);
}

.support-detail__user {
  margin-bottom: 18px;
  padding: 14px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.08);
  background: rgba(0, 0, 0, 0.22);
}

.support-detail__staff {
  padding: 14px;
  border-radius: 12px;
  border: 1px solid rgba(129, 199, 132, 0.28);
  background: rgba(16, 80, 48, 0.12);
}

.support-detail__empty {
  margin: 0;
  font-size: 14px;
  line-height: 1.55;
  color: rgba(180, 186, 200, 0.78);
}

.support-detail__err {
  margin: 0;
  color: #ffb4b4;
  font-size: 14px;
}

@media (min-width: 960px) {
  .support-columns > .support-card {
    height: 100%;
  }
}

/* Form card */
.support-card {
  border-radius: 16px;
  border: 1px solid rgba(224, 49, 49, 0.45);
  background: linear-gradient(
    165deg,
    rgba(14, 14, 20, 0.92) 0%,
    rgba(8, 8, 12, 0.88) 50%,
    rgba(6, 6, 10, 0.94) 100%
  );
  box-shadow:
    0 0 0 1px rgba(255, 255, 255, 0.05) inset,
    0 24px 80px rgba(0, 0, 0, 0.5),
    0 0 120px rgba(224, 49, 49, 0.09);
  padding: clamp(22px, 4vw, 32px);
}

.support-card__head {
  margin-bottom: 22px;
}

.support-card__head h2 {
  margin: 0 0 8px;
  font-size: clamp(1.15rem, 2.5vw, 1.35rem);
  font-weight: 700;
  color: #f4f5f8;
}

.support-card__head p {
  margin: 0;
  color: rgba(190, 196, 212, 0.82);
  font-size: 0.95rem;
  line-height: 1.6;
}

.support-form__grid {
  display: grid;
  gap: 16px;
}

@media (min-width: 560px) {
  .support-form__grid--2 {
    grid-template-columns: 1fr 1fr;
  }
}

.support-field {
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.support-field label {
  font-size: 13px;
  font-weight: 600;
  color: #c9cdd3;
}

.support-field .input,
.support-field .select,
.support-field textarea {
  width: 100%;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(12, 14, 18, 0.95);
  color: #f0f2f5;
  font-size: 15px;
  outline: none;
  transition:
    border-color 0.15s,
    box-shadow 0.15s;
}

.support-field textarea {
  min-height: 160px;
  resize: vertical;
}

.support-field .input:focus,
.support-field .select:focus,
.support-field textarea:focus {
  border-color: rgba(224, 49, 49, 0.65);
  box-shadow: 0 0 0 3px rgba(224, 49, 49, 0.16);
}

.support-field .input.is-identity-locked,
.support-field .input[readonly] {
  cursor: not-allowed;
  color: rgba(230, 232, 240, 0.88);
  background: rgba(18, 18, 24, 0.92);
  border-color: rgba(255, 255, 255, 0.06);
}

.support-identity-hint {
  margin: 0 0 14px;
  padding: 10px 12px;
  font-size: 13px;
  line-height: 1.45;
  color: rgba(200, 204, 218, 0.78);
  border-radius: 10px;
  border: 1px solid rgba(224, 49, 49, 0.22);
  background: rgba(224, 49, 49, 0.06);
}

.support-hp {
  position: absolute;
  left: -9999px;
  width: 1px;
  height: 1px;
  opacity: 0;
  pointer-events: none;
}

.support-actions {
  margin-top: 8px;
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
}

.support-msg {
  font-size: 14px;
  margin: 0;
  padding: 12px 14px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.1);
}

.support-msg--error {
  background: rgba(180, 40, 40, 0.2);
  border-color: rgba(255, 100, 100, 0.35);
  color: #ffc9c9;
}

.support-msg--ok {
  background: rgba(16, 120, 72, 0.18);
  border-color: rgba(64, 200, 130, 0.35);
  color: #c8f5df;
}

/* Admin tickets */
.admin-tickets-wrap {
  max-width: 1200px;
  margin: 0 auto;
  padding: clamp(28px, 5vw, 56px) 16px 100px;
}

.admin-tickets-toolbar {
  display: flex;
  flex-wrap: wrap;
  gap: 12px;
  align-items: center;
  margin-bottom: 20px;
}

.admin-tickets-toolbar label {
  font-size: 13px;
  color: var(--muted, #9aa);
  margin-inline-end: 8px;
}

.admin-tickets-toolbar select {
  padding: 8px 12px;
  border-radius: 10px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: #0f1116;
  color: #fff;
}

.admin-table-wrap {
  overflow: auto;
  border-radius: 14px;
  border: 1px solid rgba(224, 49, 49, 0.32);
  background: rgba(10, 10, 14, 0.75);
}

.admin-table {
  width: 100%;
  border-collapse: collapse;
  font-size: 14px;
}

.admin-table th,
.admin-table td {
  padding: 12px 14px;
  text-align: start;
  border-bottom: 1px solid rgba(255, 255, 255, 0.06);
}

.admin-table th {
  background: rgba(224, 49, 49, 0.1);
  color: rgba(240, 242, 248, 0.92);
  font-weight: 600;
}

.admin-table tbody tr {
  cursor: pointer;
  transition: background 0.12s;
}

.admin-table tbody tr:hover,
.admin-table tbody tr.is-active {
  background: rgba(224, 49, 49, 0.07);
}

.admin-ticket-detail {
  margin-top: 22px;
  padding: 22px;
  border-radius: 14px;
  border: 1px solid rgba(255, 255, 255, 0.1);
  background: rgba(8, 8, 12, 0.9);
}

.admin-ticket-detail h3 {
  margin-top: 0;
}

.admin-ticket-detail .body-block {
  white-space: pre-wrap;
  color: rgba(220, 224, 235, 0.92);
  line-height: 1.55;
}

.badge-status {
  display: inline-block;
  padding: 2px 10px;
  border-radius: 999px;
  font-size: 12px;
  font-weight: 600;
  border: 1px solid rgba(255, 255, 255, 0.12);
}

.badge-status--open {
  color: #ffb74d;
  border-color: rgba(255, 183, 77, 0.35);
}
.badge-status--in_progress {
  color: #64b5f6;
  border-color: rgba(100, 181, 246, 0.35);
}
.badge-status--resolved {
  color: #81c784;
  border-color: rgba(129, 199, 132, 0.35);
}
.badge-status--closed {
  color: #9e9e9e;
}

.admin-ticket-detail select,
.admin-ticket-detail textarea {
  width: 100%;
  margin-top: 6px;
  padding: 10px 12px;
  border-radius: 12px;
  border: 1px solid rgba(255, 255, 255, 0.12);
  background: #0f1116;
  color: #fff;
  font-size: 14px;
}

.admin-ticket-detail textarea {
  font-family: inherit;
  line-height: 1.5;
}

.admin-forbidden {
  text-align: center;
  padding: 48px 16px;
  color: rgba(255, 200, 200, 0.9);
}
