* {
  margin: 0;
  padding: 0;
  box-sizing: border-box;
}

body {
  font-family: "Inter", sans-serif;
  background: #f1f5f9;
  color: #1e293b;
  overflow-x: hidden;
}

.app {
  display: flex;
  min-height: 100vh;
  position: relative;
}

/* ========== SIDEBAR ========== */
.sidebar {
  width: 280px;
  background: linear-gradient(180deg, #0f3b2c 0%, #0a2a1f 100%);
  color: white;
  display: flex;
  flex-direction: column;
  position: fixed;
  height: 100vh;
  left: 0;
  top: 0;
  z-index: 1000;
  transition: transform 0.3s ease;
  box-shadow: 2px 0 10px rgba(0, 0, 0, 0.1);
}

@media (max-width: 768px) {
  .sidebar {
    transform: translateX(-100%);
  }
  .sidebar.open {
    transform: translateX(0);
  }
}

.sidebar-header {
  padding: 28px 24px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.1);
  display: flex;
  justify-content: space-between;
  align-items: center;
}

.logo {
  display: flex;
  align-items: center;
  gap: 12px;
}

.logo i {
  font-size: 32px;
  color: #fbbf24;
}

.logo h2 {
  font-size: 20px;
  font-weight: 700;
}

.logo p {
  font-size: 11px;
  opacity: 0.7;
  margin-top: 4px;
}

.sidebar-close {
  display: none;
  background: none;
  border: none;
  color: white;
  font-size: 24px;
  cursor: pointer;
}

@media (max-width: 768px) {
  .sidebar-close {
    display: block;
  }
}

.sidebar-nav {
  flex: 1;
  padding: 24px 16px;
  display: flex;
  flex-direction: column;
  gap: 8px;
}

.nav-link {
  display: flex;
  align-items: center;
  gap: 14px;
  padding: 12px 20px;
  border-radius: 12px;
  color: rgba(255, 255, 255, 0.7);
  text-decoration: none;
  transition: all 0.2s;
}

.nav-link i {
  width: 22px;
  font-size: 18px;
}

.nav-link:hover {
  background: rgba(255, 255, 255, 0.1);
  color: white;
}

.nav-link.active {
  background: #fbbf24;
  color: #0a2a1f;
  font-weight: 600;
}

.sidebar-footer {
  padding: 20px 24px;
  border-top: 1px solid rgba(255, 255, 255, 0.1);
}

.admin-info {
  display: flex;
  align-items: center;
  gap: 12px;
  background: rgba(255, 255, 255, 0.1);
  padding: 12px;
  border-radius: 12px;
}

.admin-info i {
  font-size: 28px;
  color: #25d366;
}

.admin-info small {
  font-size: 10px;
  opacity: 0.7;
}

.admin-info strong {
  font-size: 13px;
}

.wa-number {
  font-size: 11px;
  opacity: 0.8;
  margin-top: 4px;
}

.mobile-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  z-index: 999;
  backdrop-filter: blur(2px);
}

.mobile-overlay.active {
  display: block;
}

/* ========== MAIN CONTENT ========== */
.main {
  flex: 1;
  margin-left: 280px;
  min-height: 100vh;
  background: #f1f5f9;
}

@media (max-width: 768px) {
  .main {
    margin-left: 0;
  }
}

.topbar {
  background: white;
  padding: 16px 32px;
  display: flex;
  justify-content: space-between;
  align-items: center;
  border-bottom: 1px solid #e2e8f0;
  position: sticky;
  top: 0;
  z-index: 100;
}

.menu-toggle {
  display: none;
  background: none;
  border: none;
  font-size: 24px;
  cursor: pointer;
  color: #1e293b;
  padding: 8px;
  border-radius: 8px;
}

@media (max-width: 768px) {
  .menu-toggle {
    display: block;
  }
}

.topbar-info {
  display: flex;
  gap: 24px;
  align-items: center;
}

.date-time {
  font-weight: 500;
  color: #475569;
  font-size: 14px;
}

@media (max-width: 500px) {
  .date-time {
    font-size: 11px;
  }
}

.stats-mini {
  background: #f1f5f9;
  padding: 6px 14px;
  border-radius: 30px;
  font-size: 14px;
  font-weight: 600;
  color: #0f3b2c;
}

.content {
  padding: 32px;
}

@media (max-width: 768px) {
  .content {
    padding: 20px 16px;
  }
}

/* ========== PAGES ========== */
.page {
  display: none;
  animation: fadeIn 0.3s ease;
}

.page.active {
  display: block;
}

@keyframes fadeIn {
  from {
    opacity: 0;
    transform: translateY(10px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.page-title {
  margin-bottom: 28px;
}

.page-title h1 {
  font-size: 28px;
  font-weight: 700;
  color: #0f3b2c;
}

@media (max-width: 500px) {
  .page-title h1 {
    font-size: 22px;
  }
}

.page-title p {
  color: #64748b;
  margin-top: 6px;
}

/* ========== STATS GRID ========== */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(4, 1fr);
  gap: 20px;
  margin-bottom: 32px;
}

@media (max-width: 768px) {
  .stats-grid {
    grid-template-columns: repeat(2, 1fr);
    gap: 12px;
  }
}

@media (max-width: 480px) {
  .stats-grid {
    grid-template-columns: 1fr;
  }
}

.stat-card {
  background: white;
  border-radius: 20px;
  padding: 20px;
  display: flex;
  align-items: center;
  gap: 18px;
  box-shadow: 0 1px 3px rgba(0, 0, 0, 0.05);
  transition: transform 0.2s;
}

.stat-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 10px 25px -5px rgba(0, 0, 0, 0.1);
}

.stat-icon {
  width: 56px;
  height: 56px;
  border-radius: 18px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 26px;
}

.stat-icon.green {
  background: #dcfce7;
  color: #166534;
}
.stat-icon.blue {
  background: #dbeafe;
  color: #1e40af;
}
.stat-icon.orange {
  background: #ffedd5;
  color: #9a3412;
}
.stat-icon.purple {
  background: #f3e8ff;
  color: #6b21a5;
}

.stat-details h3 {
  font-size: 32px;
  font-weight: 800;
}

@media (max-width: 500px) {
  .stat-details h3 {
    font-size: 24px;
  }
}

.stat-details p {
  color: #64748b;
  font-size: 13px;
}

/* ========== CHART ========== */
.chart-wrapper {
  background: white;
  border-radius: 20px;
  padding: 24px;
  margin-bottom: 32px;
}

.chart-wrapper h3 {
  margin-bottom: 20px;
  font-size: 18px;
}

.chart-bars {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
}

.chart-item {
  flex: 1;
  min-width: 100px;
}

.chart-label {
  font-size: 13px;
  font-weight: 500;
  margin-bottom: 8px;
  color: #475569;
}

.chart-bar {
  height: 36px;
  background: #0f3b2c;
  border-radius: 8px;
  display: flex;
  align-items: center;
  justify-content: flex-end;
  padding-right: 12px;
  color: white;
  font-weight: 600;
  font-size: 14px;
  transition: width 0.5s;
}

/* ========== FORM ========== */
.form-container {
  background: white;
  border-radius: 24px;
  padding: 32px;
}

@media (max-width: 768px) {
  .form-container {
    padding: 20px;
  }
}

.form-row {
  display: flex;
  gap: 24px;
  margin-bottom: 20px;
  flex-wrap: wrap;
}

.form-group {
  flex: 1;
  min-width: 200px;
}

.form-group.full-width {
  width: 100%;
}

.form-group label {
  display: block;
  margin-bottom: 8px;
  font-weight: 600;
  font-size: 14px;
  color: #334155;
}

.form-group input,
.form-group select,
.form-group textarea {
  width: 100%;
  padding: 12px 16px;
  border: 1.5px solid #e2e8f0;
  border-radius: 12px;
  font-family: inherit;
  font-size: 14px;
  background: #fafbfc;
}

.form-group input:focus,
.form-group select:focus,
.form-group textarea:focus {
  outline: none;
  border-color: #0f3b2c;
  box-shadow: 0 0 0 3px rgba(15, 59, 44, 0.1);
}

.priority-group {
  display: flex;
  gap: 16px;
  flex-wrap: wrap;
  padding-top: 6px;
}

.priority-radio {
  display: flex;
  align-items: center;
  gap: 8px;
  cursor: pointer;
  padding: 8px 16px;
  background: #f1f5f9;
  border-radius: 30px;
  font-size: 13px;
  font-weight: 500;
}

.priority-radio input {
  width: auto;
  margin: 0;
}

.file-drop {
  border: 2px dashed #cbd5e1;
  border-radius: 12px;
  padding: 24px;
  text-align: center;
  cursor: pointer;
  transition: all 0.2s;
  background: #fafbfc;
}

.file-drop:hover {
  border-color: #0f3b2c;
  background: #f0fdf4;
}

.file-drop i {
  font-size: 32px;
  color: #94a3b8;
  margin-bottom: 8px;
}

.file-drop p {
  font-size: 13px;
  color: #64748b;
}

.preview-img {
  margin-top: 12px;
}

.preview-img img {
  max-width: 200px;
  border-radius: 12px;
  border: 1px solid #e2e8f0;
}

.char-count {
  text-align: right;
  font-size: 12px;
  color: #94a3b8;
  margin-top: 6px;
}

.form-buttons {
  display: flex;
  gap: 16px;
  margin-top: 16px;
}

.btn-submit {
  flex: 1;
  padding: 14px;
  background: #0f3b2c;
  border: none;
  border-radius: 40px;
  color: white;
  font-weight: 700;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-submit:hover {
  background: #0a2a1f;
  transform: scale(1.01);
}

.btn-cancel {
  flex: 1;
  padding: 14px;
  background: #64748b;
  border: none;
  border-radius: 40px;
  color: white;
  font-weight: 700;
  font-size: 16px;
  cursor: pointer;
  transition: all 0.2s;
}

.btn-cancel:hover {
  background: #475569;
}

/* ========== FILTER BAR ========== */
.filter-bar {
  display: flex;
  gap: 16px;
  margin-bottom: 28px;
  flex-wrap: wrap;
}

.search-box {
  flex: 2;
  min-width: 200px;
  display: flex;
  align-items: center;
  background: white;
  border: 1px solid #e2e8f0;
  border-radius: 40px;
  padding: 8px 20px;
  gap: 12px;
}

.search-box i {
  color: #94a3b8;
}

.search-box input {
  flex: 1;
  border: none;
  background: none;
  font-size: 14px;
}

.search-box input:focus {
  outline: none;
}

.filter-select {
  padding: 8px 20px;
  border: 1px solid #e2e8f0;
  border-radius: 40px;
  background: white;
  font-size: 14px;
  cursor: pointer;
}

.btn-export {
  padding: 8px 24px;
  background: #0f3b2c;
  border: none;
  border-radius: 40px;
  color: white;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  gap: 8px;
}

@media (max-width: 640px) {
  .filter-bar {
    flex-direction: column;
  }
  .search-box,
  .filter-select,
  .btn-export {
    width: 100%;
    justify-content: center;
  }
}

/* ========== REPORTS LIST ========== */
.reports-list {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.report-card {
  background: white;
  border-radius: 20px;
  padding: 20px;
  cursor: pointer;
  transition: all 0.2s;
  border: 1px solid #e2e8f0;
  position: relative;
}

.report-card:hover {
  transform: translateX(5px);
  border-color: #0f3b2c;
  box-shadow: 0 4px 12px rgba(0, 0, 0, 0.08);
}

.report-card.urgent {
  border-left: 4px solid #ef4444;
}
.report-card.penting {
  border-left: 4px solid #f59e0b;
}

.recent-list {
  display: flex;
  flex-direction: column;
  gap: 12px;
}

.report-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 12px;
  flex-wrap: wrap;
  gap: 8px;
}

.report-nama {
  font-weight: 700;
  color: #1e293b;
}

.report-badge {
  padding: 4px 12px;
  border-radius: 30px;
  font-size: 11px;
  font-weight: 600;
}

.badge-jenis {
  background: #e2e8f0;
  color: #334155;
}

.report-deskripsi {
  color: #475569;
  font-size: 14px;
  margin-bottom: 12px;
  line-height: 1.5;
}

.report-footer {
  display: flex;
  justify-content: space-between;
  align-items: center;
  font-size: 12px;
  color: #94a3b8;
  flex-wrap: wrap;
  gap: 8px;
}

.status {
  padding: 4px 10px;
  border-radius: 30px;
  font-size: 11px;
  font-weight: 600;
}
.status-Menunggu {
  background: #fef3c7;
  color: #92400e;
}
.status-Diproses {
  background: #dbeafe;
  color: #1e40af;
}
.status-Selesai {
  background: #dcfce7;
  color: #166534;
}

/* ========== MODAL DETAIL ========== */
.modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.6);
  z-index: 1100;
  justify-content: center;
  align-items: center;
}

.modal-content {
  background: white;
  border-radius: 28px;
  max-width: 600px;
  width: 90%;
  max-height: 85vh;
  overflow: auto;
}

.modal-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  padding: 20px 24px;
  border-bottom: 1px solid #e2e8f0;
}

.modal-close {
  background: none;
  border: none;
  font-size: 28px;
  cursor: pointer;
  color: #94a3b8;
}

.modal-body {
  padding: 24px;
}

.modal-body p {
  margin-bottom: 12px;
  line-height: 1.6;
}

.modal-body img {
  max-width: 100%;
  border-radius: 12px;
  margin-top: 12px;
}

.modal-footer {
  display: flex;
  gap: 12px;
  padding: 20px 24px;
  border-top: 1px solid #e2e8f0;
  flex-wrap: wrap;
}

@media (max-width: 550px) {
  .modal-footer {
    flex-direction: column;
  }
}

.btn-edit,
.btn-delete,
.btn-pdf,
.btn-wa,
.btn-status {
  flex: 1;
  padding: 12px;
  border: none;
  border-radius: 40px;
  font-weight: 600;
  cursor: pointer;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
  transition: all 0.2s;
}

.btn-edit {
  background: #3b82f6;
  color: white;
}
.btn-edit:hover {
  background: #2563eb;
  transform: translateY(-2px);
}
.btn-delete {
  background: #ef4444;
  color: white;
}
.btn-delete:hover {
  background: #dc2626;
  transform: translateY(-2px);
}
.btn-pdf {
  background: #dc2626;
  color: white;
}
.btn-pdf:hover {
  background: #b91c1c;
  transform: translateY(-2px);
}
.btn-wa {
  background: #25d366;
  color: white;
}
.btn-wa:hover {
  background: #128c7e;
  transform: translateY(-2px);
}
.btn-status {
  background: #0f3b2c;
  color: white;
}
.btn-status:hover {
  background: #0a2a1f;
  transform: translateY(-2px);
}

/* ========== MODAL KONFIRMASI CSS ========== */
.confirm-modal {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.7);
  backdrop-filter: blur(4px);
  z-index: 1200;
  justify-content: center;
  align-items: center;
  animation: fadeIn 0.2s ease;
}

.confirm-modal-content {
  background: white;
  border-radius: 28px;
  width: 400px;
  max-width: 90%;
  overflow: hidden;
  animation: slideUp 0.3s ease;
}

@keyframes slideUp {
  from {
    opacity: 0;
    transform: translateY(30px);
  }
  to {
    opacity: 1;
    transform: translateY(0);
  }
}

.confirm-modal-header {
  padding: 24px;
  text-align: center;
  background: linear-gradient(135deg, #0f3b2c 0%, #0a2a1f 100%);
  color: white;
}

.confirm-modal-header i {
  font-size: 48px;
  margin-bottom: 12px;
}

.confirm-modal-header h3 {
  font-size: 20px;
  font-weight: 700;
}

.confirm-modal-body {
  padding: 32px 24px;
  text-align: center;
}

.confirm-modal-body p {
  font-size: 16px;
  color: #334155;
  line-height: 1.5;
}

.confirm-modal-footer {
  display: flex;
  gap: 12px;
  padding: 20px 24px;
  border-top: 1px solid #e2e8f0;
}

.confirm-btn {
  flex: 1;
  padding: 12px;
  border: none;
  border-radius: 40px;
  font-weight: 600;
  font-size: 14px;
  cursor: pointer;
  transition: all 0.2s;
  display: flex;
  align-items: center;
  justify-content: center;
  gap: 8px;
}

.confirm-yes {
  background: #ef4444;
  color: white;
}

.confirm-yes:hover {
  background: #dc2626;
  transform: scale(1.02);
}

.confirm-no {
  background: #e2e8f0;
  color: #334155;
}

.confirm-no:hover {
  background: #cbd5e1;
  transform: scale(1.02);
}

/* ========== TOAST NOTIFICATION CSS ========== */
.toast {
  position: fixed;
  bottom: 30px;
  right: 30px;
  background: white;
  border-radius: 16px;
  padding: 16px 20px;
  display: flex;
  align-items: center;
  gap: 14px;
  box-shadow:
    0 10px 25px -5px rgba(0, 0, 0, 0.15),
    0 8px 10px -6px rgba(0, 0, 0, 0.1);
  z-index: 2000;
  transform: translateX(400px);
  transition: transform 0.3s ease;
  min-width: 320px;
  max-width: 400px;
  border-left: 5px solid #0f3b2c;
}

@media (max-width: 500px) {
  .toast {
    left: 16px;
    right: 16px;
    bottom: 16px;
    min-width: auto;
    max-width: none;
    transform: translateY(100px);
  }
  .toast.show {
    transform: translateY(0);
  }
}

.toast.show {
  transform: translateX(0);
}

.toast-icon {
  width: 40px;
  height: 40px;
  border-radius: 30px;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 22px;
}

.toast-icon.success {
  background: #dcfce7;
  color: #166534;
}
.toast-icon.error {
  background: #fee2e2;
  color: #b91c1c;
}
.toast-icon.warning {
  background: #fef3c7;
  color: #92400e;
}
.toast-icon.info {
  background: #dbeafe;
  color: #1e40af;
}

.toast-content {
  flex: 1;
}

.toast-title {
  font-weight: 700;
  font-size: 14px;
  color: #1e293b;
}

.toast-message {
  font-size: 13px;
  color: #64748b;
  margin-top: 2px;
}

.toast-close {
  background: none;
  border: none;
  font-size: 20px;
  cursor: pointer;
  color: #94a3b8;
  transition: color 0.2s;
}

.toast-close:hover {
  color: #475569;
}

/* ========== LOADING OVERLAY ========== */
.loading-overlay {
  display: none;
  position: fixed;
  top: 0;
  left: 0;
  width: 100%;
  height: 100%;
  background: rgba(0, 0, 0, 0.5);
  backdrop-filter: blur(4px);
  z-index: 1500;
  justify-content: center;
  align-items: center;
}

.loading-overlay.active {
  display: flex;
}

.loading-spinner {
  background: white;
  padding: 32px;
  border-radius: 24px;
  text-align: center;
  box-shadow: 0 20px 35px -8px rgba(0, 0, 0, 0.2);
}

.spinner {
  width: 50px;
  height: 50px;
  border: 4px solid #e2e8f0;
  border-top-color: #0f3b2c;
  border-radius: 50%;
  animation: spin 0.8s linear infinite;
  margin: 0 auto 16px;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.loading-spinner p {
  color: #334155;
  font-weight: 500;
}

/* ========== ABOUT PAGE ========== */
.about-card {
  background: white;
  border-radius: 28px;
  padding: 32px;
  text-align: center;
}

@media (max-width: 500px) {
  .about-card {
    padding: 20px;
  }
}

.about-header i {
  font-size: 56px;
  color: #0f3b2c;
  margin-bottom: 16px;
}

.about-header h2 {
  font-size: 28px;
  color: #0f3b2c;
}

.alamat {
  color: #64748b;
  margin-top: 6px;
}

.about-divisi {
  margin: 32px 0;
  padding: 24px;
  background: #f1f5f9;
  border-radius: 20px;
}

.about-divisi h3 {
  margin-bottom: 20px;
}

.divisi-list {
  display: flex;
  flex-wrap: wrap;
  justify-content: center;
  gap: 12px;
}

.divisi-list span {
  background: white;
  padding: 8px 16px;
  border-radius: 30px;
  font-size: 13px;
  font-weight: 500;
}

.about-features {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 24px;
  margin: 32px 0;
}

@media (max-width: 768px) {
  .about-features {
    grid-template-columns: 1fr;
  }
}

.feature {
  text-align: center;
  padding: 20px;
}

.feature i {
  font-size: 36px;
  color: #0f3b2c;
  margin-bottom: 12px;
}

.feature p {
  font-size: 13px;
  color: #64748b;
}

.contact-card {
  background: linear-gradient(135deg, #0f3b2c 0%, #0a2a1f 100%);
  color: white;
  padding: 24px;
  border-radius: 20px;
  margin-top: 16px;
}

.contact-card p {
  font-size: 20px;
  font-weight: 700;
  margin: 8px 0;
}

.empty-state {
  text-align: center;
  padding: 60px;
  color: #94a3b8;
}
