* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

.hidden {
  display: none !important;
}

:root {
  --bg-dark: #f8fafc;
  --bg-card: rgba(255, 255, 255, 0.9);
  --border-light: rgba(0, 0, 0, 0.06);
  --text-main: #0f172a;
  --text-muted: #64748b;
  --accent-primary: #6366f1;
  --accent-glow: rgba(99, 102, 241, 0.15);
  --success: #10b981;
  --warning: #f59e0b;
  --danger: #ef4444;
  --font-family: 'Inter', system-ui, -apple-system, sans-serif;
}

body {
  font-family: var(--font-family);
  background-color: var(--bg-dark);
  color: var(--text-main);
  line-height: 1.6;
  min-height: 100vh;
  position: relative;
  overflow-x: hidden;
}

.background-mesh {
  position: fixed;
  top: 0;
  left: 0;
  width: 100vw;
  height: 100vh;
  background:
    radial-gradient(circle at 10% 20%, rgba(99, 102, 241, 0.04), transparent 40%),
    radial-gradient(circle at 90% 80%, rgba(139, 92, 246, 0.04), transparent 40%),
    #f8fafc;
  z-index: -1;
  pointer-events: none;
}

.container {
  max-width: 1400px;
  margin: 0 auto;
  padding: 32px;
}

header {
  background: rgba(255, 255, 255, 0.7);
  backdrop-filter: blur(20px) saturate(180%);
  -webkit-backdrop-filter: blur(20px) saturate(180%);
  padding: 28px 40px;
  border-radius: 24px;
  margin-bottom: 32px;
  border: 1px solid rgba(255, 255, 255, 0.2);
  box-shadow: 0 4px 20px rgba(0, 0, 0, 0.03);
  display: flex;
  justify-content: space-between;
  align-items: center;
  flex-wrap: wrap;
  gap: 20px;
}

.header-content {
  display: flex;
  align-items: center;
  gap: 12px;
}

header h1 {
  color: var(--text-main);
  font-size: 24px;
  font-weight: 700;
  letter-spacing: -0.5px;
}

.badge {
  background: rgba(16, 185, 129, 0.1);
  color: #10b981;
  border: 1px solid rgba(16, 185, 129, 0.2);
  padding: 4px 10px;
  border-radius: 100px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
}

.stats {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  margin-bottom: 32px;
}

.stat-card {
  background: white;
  padding: 16px 24px;
  border-radius: 14px;
  min-width: 160px;
  border: 1px solid var(--border-light);
  transition: all 0.2s ease;
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.01);
}

.stat-card:hover {
  background: white;
  transform: translateY(-2px);
  box-shadow: 0 8px 16px rgba(0, 0, 0, 0.04);
  border-color: rgba(0, 0, 0, 0.1);
}

.stat-label {
  display: block;
  font-size: 12px;
  color: var(--text-muted);
  text-transform: uppercase;
  font-weight: 600;
  letter-spacing: 0.5px;
}

.stat-value {
  display: block;
  font-size: 26px;
  font-weight: 700;
  margin-top: 6px;
  color: var(--text-main);
}

.tabs {
  display: flex;
  gap: 10px;
  margin-bottom: 24px;
  background: rgba(0, 0, 0, 0.02);
  padding: 6px;
  border-radius: 12px;
  width: fit-content;
  border: 1px solid var(--border-light);
}

.tab {
  padding: 10px 24px;
  background: transparent;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  color: var(--text-muted);
  transition: all 0.2s ease;
  font-family: var(--font-family);
}

.tab:hover {
  color: var(--text-main);
  background: rgba(0, 0, 0, 0.03);
}

.tab.active {
  background: white;
  color: var(--accent-primary);
  font-weight: 600;
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.05);
}

.tab-content {
  display: none;
  background: var(--bg-card);
  backdrop-filter: blur(12px);
  padding: 32px;
  border-radius: 20px;
  border: 1px solid var(--border-light);
  min-height: 400px;
  box-shadow: 0 4px 30px rgba(0, 0, 0, 0.02);
}

.tab-content.active {
  display: block;
  animation: fadeIn 0.3s ease-out;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(5px);
  }

  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.filters {
  display: flex;
  gap: 16px;
  margin-bottom: 24px;
  flex-wrap: wrap;
}

.filters select {
  padding: 10px 16px;
  border: 1px solid var(--border-light);
  border-radius: 10px;
  font-size: 14px;
  color: var(--text-main);
  background: white;
  cursor: pointer;
  appearance: none;
  background-image: url("data:image/svg+xml;charset=UTF-8,%3csvg xmlns='http://www.w3.org/2000/svg' viewBox='0 0 24 24' fill='none' stroke='%2364748b' stroke-width='2' stroke-linecap='round' stroke-linejoin='round'%3e%3cpolyline points='6 9 12 15 18 9'%3e%3c/polyline%3e%3c/svg%3e");
  background-repeat: no-repeat;
  background-position: right 14px center;
  background-size: 14px;
  padding-right: 40px;
  transition: all 0.2s;
}

.filters select:focus {
  outline: none;
  border-color: var(--accent-primary);
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.filters button {
  padding: 10px 20px;
  background: white;
  color: var(--text-main);
  border: 1px solid var(--border-light);
  border-radius: 10px;
  cursor: pointer;
  font-size: 14px;
  font-weight: 500;
  transition: all 0.2s;
  font-family: var(--font-family);
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.02);
}

.filters button:hover {
  background: #fdfdfd;
  border-color: rgba(0, 0, 0, 0.15);
  box-shadow: 0 2px 4px rgba(0, 0, 0, 0.04);
}

.filter-tabs {
  display: flex;
  gap: 8px;
  background: rgba(0, 0, 0, 0.02);
  padding: 4px;
  border-radius: 10px;
  border: 1px solid var(--border-light);
}

.filter-tab {
  padding: 8px 20px;
  background: transparent;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-size: 13px;
  font-weight: 500;
  color: var(--text-muted);
  transition: all 0.2s ease;
  font-family: var(--font-family);
}

.filter-tab:hover {
  color: var(--text-main);
  background: rgba(0, 0, 0, 0.03);
}

.filter-tab.active {
  background: white;
  color: var(--accent-primary);
  font-weight: 600;
  box-shadow: 0 2px 6px rgba(0, 0, 0, 0.05);
}

table {
  width: 100%;
  border-collapse: separate;
  border-spacing: 0;
}

th {
  padding: 16px;
  text-align: left;
  border-bottom: 1px solid var(--border-light);
  color: var(--text-muted);
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.8px;
}

td {
  padding: 16px;
  border-bottom: 1px solid var(--border-light);
  color: var(--text-main);
  font-size: 14px;
}

tr:last-child td {
  border-bottom: none;
}

tbody tr {
  transition: background 0.15s;
}

tbody tr:hover {
  background: rgba(0, 0, 0, 0.015);
}

.loading {
  text-align: center;
  color: var(--text-muted);
  padding: 60px !important;
  font-style: italic;
}

.status {
  display: inline-flex;
  align-items: center;
  padding: 6px 14px;
  border-radius: 100px;
  font-size: 11px;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 0.5px;
  border: 1px solid transparent;
}

.status.open,
.status.pending {
  background: #fffbeb;
  color: #b45309;
  border-color: #fef3c7;
}

.status.in_progress {
  background: #eff6ff;
  color: #1d4ed8;
  border-color: #dbeafe;
}

.status.resolved,
.status.confirmed {
  background: #ecfdf5;
  color: #047857;
  border-color: #d1fae5;
}

.status.rejected {
  background: #fef2f2;
  color: #b91c1c;
  border-color: #fee2e2;
}

.btn-action {
  padding: 8px 16px;
  border: none;
  border-radius: 8px;
  cursor: pointer;
  font-size: 12px;
  font-weight: 600;
  margin-right: 8px;
  transition: all 0.2s;
  font-family: var(--font-family);
}

.btn-edit {
  background: #f1f5f9;
  color: #475569;
}

.btn-edit:hover {
  background: #e2e8f0;
}

.btn-view {
  background: rgba(99, 102, 241, 0.1);
  color: #4f46e5;
}

.btn-view:hover {
  background: rgba(99, 102, 241, 0.18);
}

.btn-activate {
  background: rgba(16, 185, 129, 0.1);
  color: #059669;
}

.btn-activate:hover {
  background: rgba(16, 185, 129, 0.18);
}

.btn-danger {
  background: rgba(239, 68, 68, 0.08) !important;
  color: #dc2626 !important;
  border: 1px solid rgba(239, 68, 68, 0.15) !important;
}

.btn-danger:hover {
  background: rgba(239, 68, 68, 0.12) !important;
}

.btn-primary,
.btn-success {
  width: 100%;
  padding: 14px;
  border-radius: 10px;
  border: none;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
  font-family: var(--font-family);
}

.btn-primary {
  background: var(--accent-primary);
  color: white;
  box-shadow: 0 4px 14px var(--accent-glow);
}

.btn-primary:hover {
  background: #4f46e5;
  transform: translateY(-1px);
}

.btn-success {
  background: var(--success);
  color: white;
  box-shadow: 0 4px 14px rgba(16, 185, 129, 0.15);
}

.btn-success:hover {
  background: #059669;
}

.modal {
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(15, 23, 42, 0.3);
  backdrop-filter: blur(8px);
  z-index: 1000;
  display: flex;
  align-items: center;
  justify-content: center;
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.2s;
}

.modal:not(.hidden) {
  opacity: 1;
  pointer-events: auto;
}

.modal-content {
  background: white;
  border: 1px solid var(--border-light);
  padding: 32px;
  border-radius: 20px;
  width: 90%;
  max-width: 440px;
  position: relative;
  box-shadow: 0 20px 40px -12px rgba(0, 0, 0, 0.1);
  transform: translateY(20px);
  transition: transform 0.3s cubic-bezier(0.16, 1, 0.3, 1);
}

.modal:not(.hidden) .modal-content {
  transform: translateY(0);
}

.modal h2 {
  color: var(--text-main);
  margin-bottom: 24px;
  font-size: 20px;
}

.close {
  position: absolute;
  top: 24px;
  right: 24px;
  font-size: 24px;
  color: var(--text-muted);
  cursor: pointer;
  transition: color 0.2s;
}

.close:hover {
  color: var(--text-main);
}

.form-group {
  margin-bottom: 20px;
}

.form-group label {
  display: block;
  margin-bottom: 8px;
  color: var(--text-muted);
  font-size: 13px;
  font-weight: 500;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  background: #f8fafc;
  border: 1px solid var(--border-light);
  padding: 12px 16px;
  border-radius: 10px;
  color: var(--text-main);
  font-family: inherit;
  transition: all 0.2s;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: var(--accent-primary);
  background: white;
  box-shadow: 0 0 0 3px var(--accent-glow);
}

.detail-row {
  display: flex;
  justify-content: space-between;
  padding: 12px 0;
  border-bottom: 1px solid var(--border-light);
}

.detail-label {
  color: var(--text-muted);
}

.issue-display {
  background: #f1f5f9;
  border: 1px solid var(--border-light);
  padding: 16px;
  border-radius: 10px;
  color: var(--text-main);
  max-height: 200px;
  overflow-y: auto;
  font-size: 14px;
}

.warning-text {
  background: #fffbeb;
  color: #92400e;
  padding: 12px;
  border-radius: 8px;
  font-size: 13px;
  margin-bottom: 20px;
  border: 1px solid #fef3c7;
}

.image-modal-content {
  background: transparent;
  padding: 0;
  max-width: 90vw;
  max-height: 90vh;
  box-shadow: none;
  border: none;
  display: flex;
  justify-content: center;
  align-items: center;
}

.image-modal-content img {
  max-width: 100%;
  max-height: 85vh;
  border-radius: 12px;
  box-shadow: 0 25px 50px -12px rgba(0, 0, 0, 0.2);
}

.image-modal-content .close {
  top: -40px;
  right: 0;
  color: white;
  background: rgba(255, 255, 255, 0.2);
  width: 32px;
  height: 32px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
}

@media (max-width: 768px) {
  .container {
    padding: 12px;
    padding-bottom: 40px;
  }

  header {
    padding: 20px;
    border-radius: 16px;
    margin-bottom: 20px;
  }

  header h1 {
    font-size: 20px;
    width: 100%;
    text-align: center;
  }

  .stats {
    display: flex;
    overflow-x: auto;
    padding: 4px 0 12px;
    gap: 12px;
    width: 100%;
    scrollbar-width: none;
  }

  .stats::-webkit-scrollbar {
    display: none;
  }

  .stat-card {
    min-width: 150px;
    padding: 16px;
    flex-shrink: 0;
  }

  .tabs {
    width: 100%;
    justify-content: center;
    margin-bottom: 20px;
  }

  .tab {
    padding: 10px 16px;
    font-size: 13px;
    flex: 1;
    text-align: center;
  }

  .tab-content {
    padding: 16px;
    border-radius: 16px;
  }

  .filters {
    flex-direction: column;
    gap: 10px;
  }

  .filters select,
  .filters button {
    width: 100%;
    padding: 12px;
    font-size: 14px;
  }

  .filter-tabs {
    width: 100%;
    justify-content: stretch;
  }

  .filter-tab {
    flex: 1;
    text-align: center;
    font-size: 12px;
    padding: 10px 12px;
  }

  table,
  thead,
  tbody,
  th,
  td,
  tr {
    display: block;
  }

  thead {
    display: none;
  }

  tbody tr {
    background: white;
    border: 1px solid var(--border-light);
    border-radius: 16px;
    margin-bottom: 16px;
    padding: 24px 20px 20px 20px;
    position: relative;
    box-shadow: 0 2px 10px rgba(0, 0, 0, 0.04);
    padding-top: 56px;
  }

  td {
    border: none;
    padding: 8px 0;
    display: flex;
    justify-content: space-between;
    align-items: center;
    font-size: 14px;
    border-bottom: 1px solid rgba(0, 0, 0, 0.02);
  }

  td:last-child {
    border-bottom: none;
    padding-top: 16px;
    margin-top: 4px;
    justify-content: flex-end;
    gap: 8px;
  }

  td::before {
    content: attr(data-label);
    color: var(--text-muted);
    font-size: 11px;
    font-weight: 600;
    text-transform: uppercase;
    letter-spacing: 0.5px;
  }

  td[data-label="ID"] {
    position: absolute;
    top: 24px;
    left: 20px;
    border: none;
    padding: 0;
    font-size: 12px;
    color: var(--text-muted);
    font-weight: 700;
    opacity: 0.8;
  }

  td[data-label="ID"]::before {
    display: none;
  }

  td[data-label="Phone"] {
    display: block;
    font-size: 18px;
    font-weight: 700;
    color: var(--accent-primary);
    border-bottom: 2px solid var(--accent-glow);
    padding-bottom: 12px;
    margin-bottom: 12px;
    text-align: left;
  }

  td[data-label="Phone"]::before {
    display: none;
  }

  td[data-label="Actions"]::before,
  td[data-label="Activate"]::before,
  td[data-label="Screenshot"]::before {
    display: none;
  }

  td[data-label="Actions"],
  td[data-label="Activate"] {
    justify-content: center;
    width: 100%;
    padding: 0;
  }

  .btn-action {
    flex: 1;
    margin: 0;
    padding: 12px;
    font-size: 14px;
    text-align: center;
  }

  td[data-label="Status"] {
    position: absolute;
    top: 20px;
    right: 20px;
    border: none;
    padding: 0;
  }

  td[data-label="Status"]::before {
    display: none;
  }

  .modal-content {
    width: 100%;
    height: 100%;
    max-width: none;
    border-radius: 0;
    padding: 24px;
    padding-top: 60px;
    display: flex;
    flex-direction: column;
    overflow-y: auto;
  }

  .close {
    top: 20px;
    right: 20px;
    background: #f1f5f9;
    width: 44px;
    height: 44px;
    border-radius: 50%;
    display: flex;
    align-items: center;
    justify-content: center;
    border: 1px solid var(--border-light);
  }

  .form-group label {
    font-size: 14px;
  }

  .btn-primary,
  .btn-success {
    padding: 16px;
    font-size: 16px;
  }

  td.loading {
    padding: 40px !important;
    text-align: center;
    width: 100%;
    display: block;
  }
}

/* Pricing Section */
.pricing-container {
  display: flex;
  flex-direction: column;
  gap: 32px;
}

.pricing-section {
  background: white;
  border: 1px solid var(--border-light);
  border-radius: 16px;
  padding: 24px;
}

.pricing-section-title {
  font-size: 18px;
  font-weight: 700;
  color: var(--text-main);
  margin-bottom: 20px;
  padding-bottom: 12px;
  border-bottom: 1px solid var(--border-light);
}

.pricing-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(220px, 1fr));
  gap: 16px;
}

.pricing-plan-card {
  background: #f8fafc;
  border: 1px solid var(--border-light);
  border-radius: 12px;
  padding: 16px;
  transition: all 0.2s;
}

.pricing-plan-card:hover {
  border-color: rgba(0, 0, 0, 0.12);
  box-shadow: 0 2px 8px rgba(0, 0, 0, 0.04);
}

.plan-header {
  font-size: 16px;
  font-weight: 700;
  color: var(--accent-primary);
  margin-bottom: 12px;
  display: flex;
  align-items: center;
  gap: 8px;
}

.popular-badge {
  background: rgba(99, 102, 241, 0.1);
  color: var(--accent-primary);
  font-size: 10px;
  font-weight: 600;
  padding: 2px 8px;
  border-radius: 100px;
  text-transform: uppercase;
  letter-spacing: 0.5px;
}

.pricing-form .form-group {
  margin-bottom: 12px;
}

.pricing-form .form-group label {
  font-size: 12px;
  margin-bottom: 4px;
}

.pricing-form .form-group input {
  padding: 10px 12px;
  font-size: 14px;
}

@media (max-width: 768px) {
  .pricing-grid {
    grid-template-columns: 1fr;
  }

  .pricing-section {
    padding: 16px;
  }
}

/* Toast Notifications */
.notification-container {
  position: fixed;
  top: 24px;
  right: 24px;
  z-index: 9999;
  display: flex;
  flex-direction: column;
  gap: 12px;
  pointer-events: none;
}

.notification {
  pointer-events: auto;
  min-width: 300px;
  max-width: 450px;
  background: white;
  padding: 16px 20px;
  border-radius: 16px;
  box-shadow: 0 10px 25px rgba(0, 0, 0, 0.1);
  display: flex;
  align-items: center;
  gap: 12px;
  transform: translateX(120%);
  transition: transform 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275), opacity 0.4s;
  border: 1px solid var(--border-light);
  backdrop-filter: blur(10px);
}

.notification.show {
  transform: translateX(0);
}

.notification-icon {
  width: 24px;
  height: 24px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
}

.notification-message {
  font-size: 14px;
  font-weight: 500;
  color: var(--text-main);
  line-height: 1.4;
  white-space: pre-wrap;
}

.notification-success {
  border-left: 4px solid var(--success);
}

.notification-success .notification-icon {
  background: rgba(16, 185, 129, 0.1);
  color: var(--success);
}

.notification-error {
  border-left: 4px solid var(--danger);
}

.notification-error .notification-icon {
  background: rgba(239, 68, 68, 0.1);
  color: var(--danger);
}

.notification-info {
  border-left: 4px solid var(--accent-primary);
}

.notification-info .notification-icon {
  background: var(--accent-glow);
  color: var(--accent-primary);
}

@media (max-width: 768px) {
  .notification-container {
    top: auto;
    bottom: 24px;
    right: 12px;
    left: 12px;
  }

  .notification {
    min-width: 0;
    max-width: none;
    width: 100%;
    transform: translateY(120%);
  }

  .notification.show {
    transform: translateY(0);
  }
}