.my-tickets-page {
  padding: 88px 0 48px;
  min-height: 100vh;
}

.my-tickets-shell {
  max-width: 760px;
}

.my-tickets-header {
  display: flex;
  align-items: center;
  gap: 16px;
  margin-bottom: 24px;
}

.my-tickets-avatar {
  width: 48px;
  height: 48px;
  border-radius: 6px;
  border: 2px solid var(--outline);
  object-fit: cover;
  flex-shrink: 0;
}

.my-tickets-header-text {
  flex: 1;
  min-width: 0;
}

.my-tickets-header h1 {
  margin: 0 0 4px;
  font-size: 1.5rem;
  font-weight: 800;
  color: #1a120c;
}

.my-tickets-header p {
  margin: 0;
  font-size: 0.875rem;
  color: var(--text-muted);
}

.my-tickets-new-btn {
  flex-shrink: 0;
  white-space: nowrap;
}

.my-tickets-tabs {
  display: flex;
  gap: 8px;
  margin-bottom: 16px;
  border-bottom: 2px solid rgba(44, 24, 16, 0.1);
  padding-bottom: 0;
}

.my-tickets-tab {
  appearance: none;
  border: none;
  background: transparent;
  font-family: var(--font);
  font-size: 0.9375rem;
  font-weight: 700;
  color: var(--text-muted);
  padding: 10px 16px;
  cursor: pointer;
  border-bottom: 3px solid transparent;
  margin-bottom: -2px;
  display: inline-flex;
  align-items: center;
  gap: 8px;
}

.my-tickets-tab.is-active {
  color: var(--primary-dark);
  border-bottom-color: var(--primary-dark);
}

.my-tickets-tab-count {
  display: inline-flex;
  align-items: center;
  justify-content: center;
  min-width: 22px;
  height: 22px;
  padding: 0 6px;
  border-radius: 6px;
  background: rgba(44, 24, 16, 0.08);
  font-size: 0.75rem;
  font-weight: 800;
}

.my-tickets-tab.is-active .my-tickets-tab-count {
  background: rgba(227, 0, 0, 0.12);
  color: var(--primary-dark);
}

.my-tickets-panel[hidden] {
  display: none !important;
}

.my-tickets-loading,
.my-tickets-empty {
  text-align: center;
  padding: 40px 20px;
  color: var(--text-muted);
}

.my-tickets-spinner {
  width: 28px;
  height: 28px;
  margin: 0 auto 12px;
  border: 3px solid rgba(44, 24, 16, 0.12);
  border-top-color: var(--primary-dark);
  border-radius: 50%;
  animation: my-tickets-spin 0.7s linear infinite;
}

@keyframes my-tickets-spin {
  to { transform: rotate(360deg); }
}

.my-ticket-attachment-pending {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  background: rgba(44, 24, 16, 0.04);
  border-radius: 6px;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--text-muted);
}

.my-tickets-empty i {
  font-size: 2rem;
  margin-bottom: 12px;
  opacity: 0.5;
}

.my-tickets-empty p {
  margin: 0 0 16px;
}

.my-tickets-list {
  display: flex;
  flex-direction: column;
  gap: 10px;
}

.my-ticket-card {
  background: #fff;
  border: 2px solid var(--outline);
  border-radius: 8px;
  box-shadow: 3px 3px 0 var(--outline);
  overflow: hidden;
}

.my-ticket-card.is-open {
  border-color: var(--primary-dark);
  box-shadow: 3px 3px 0 var(--primary-dark);
}

.my-ticket-summary {
  display: flex;
  align-items: center;
  gap: 12px;
  width: 100%;
  padding: 14px 16px;
  background: transparent;
  border: none;
  cursor: pointer;
  text-align: left;
  font-family: var(--font);
}

.my-ticket-status-dot {
  width: 10px;
  height: 10px;
  border-radius: 50%;
  flex-shrink: 0;
}

.my-ticket-status-dot.pending { background: #f59e0b; }
.my-ticket-status-dot.under-review { background: #3b82f6; }
.my-ticket-status-dot.accepted,
.my-ticket-status-dot.resolved,
.my-ticket-status-dot.reviewed { background: #22c55e; }
.my-ticket-status-dot.rejected { background: #ef4444; }

.my-ticket-summary-main {
  flex: 1;
  min-width: 0;
}

.my-ticket-title {
  display: block;
  font-size: 0.9375rem;
  font-weight: 800;
  color: #1a120c;
  margin-bottom: 4px;
}

.my-ticket-meta {
  display: flex;
  flex-wrap: wrap;
  align-items: center;
  gap: 8px;
  font-size: 0.75rem;
  color: var(--text-muted);
}

.my-ticket-badge {
  display: inline-flex;
  padding: 2px 8px;
  border-radius: 4px;
  font-size: 0.6875rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.02em;
}

.my-ticket-badge.pending { background: rgba(245, 158, 11, 0.15); color: #b45309; }
.my-ticket-badge.under-review { background: rgba(59, 130, 246, 0.15); color: #1d4ed8; }
.my-ticket-badge.accepted,
.my-ticket-badge.resolved,
.my-ticket-badge.reviewed { background: rgba(34, 197, 94, 0.15); color: #15803d; }
.my-ticket-badge.rejected { background: rgba(239, 68, 68, 0.15); color: #b91c1c; }

.my-ticket-chevron {
  font-size: 0.75rem;
  color: rgba(26, 18, 12, 0.45);
  transition: transform 0.18s ease;
}

.my-ticket-card.is-open .my-ticket-chevron {
  transform: rotate(180deg);
}

.my-ticket-detail {
  display: none;
  padding: 0 16px 16px;
  border-top: 1px solid rgba(44, 24, 16, 0.1);
}

.my-ticket-card.is-open .my-ticket-detail {
  display: block;
}

.my-ticket-detail-section {
  margin-top: 14px;
}

.my-ticket-detail-section h4 {
  margin: 0 0 6px;
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
}

.my-ticket-detail-section p,
.my-ticket-detail-section dd {
  margin: 0;
  font-size: 0.875rem;
  line-height: 1.55;
  color: #1a120c;
  white-space: pre-wrap;
}

.my-ticket-detail-dl {
  margin: 14px 0 0;
}

.my-ticket-detail-dl dt {
  font-size: 0.75rem;
  font-weight: 800;
  text-transform: uppercase;
  letter-spacing: 0.04em;
  color: var(--text-muted);
  margin-top: 12px;
}

.my-ticket-detail-dl dt:first-child {
  margin-top: 0;
}

.my-ticket-attachments {
  display: flex;
  flex-wrap: wrap;
  gap: 8px;
  margin-top: 8px;
}

.my-ticket-attachments a {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 6px 10px;
  background: rgba(44, 24, 16, 0.06);
  border-radius: 6px;
  font-size: 0.8125rem;
  font-weight: 600;
  color: var(--primary-dark);
  text-decoration: none;
}

.my-tickets-refresh {
  display: inline-flex;
  align-items: center;
  gap: 8px;
  margin-top: 20px;
  padding: 8px 0;
  background: none;
  border: none;
  font-family: var(--font);
  font-size: 0.875rem;
  font-weight: 700;
  color: var(--text-muted);
  cursor: pointer;
}

.my-tickets-refresh:hover {
  color: var(--primary-dark);
}

.my-tickets-error {
  padding: 16px;
  background: rgba(239, 68, 68, 0.08);
  border: 2px solid rgba(239, 68, 68, 0.25);
  border-radius: 8px;
  color: #b91c1c;
  font-size: 0.875rem;
  font-weight: 600;
}

@media (max-width: 640px) {
  .my-tickets-header {
    flex-wrap: wrap;
  }

  .my-tickets-new-btn {
    width: 100%;
    justify-content: center;
  }
}
