body {
  font-family: Inter, system-ui, -apple-system, "Segoe UI", Roboto, Arial, sans-serif;
  background: #f4f6f9;
  margin: 0;
}

/* Sidebar */
.sidebar {
  position: fixed;
  top: 0;
  left: 0;
  width: 260px;
  height: 100vh;
  background: linear-gradient(180deg, #1e1e2f, #2d2d44);
  border-right: 1px solid #e5e7eb;
  padding: 24px;
  box-shadow: 2px 0 8px rgba(0,0,0,0.05);
}

.sidebar .menu a.active {
  background: linear-gradient(90deg, #007bff, #6f42c1);
  color: #fff;
  border-left: 4px solid #00d4ff;
}

.sidebar h3 {
  font-size: 18px;
  margin-bottom: 12px;
}

.sidebar nav a {
  display: block;
  padding: 10px 12px;
  border-radius: 6px;
  margin-bottom: 6px;
  color: #f1e7e7;
  font-weight: 500;
  text-decoration: none;
  transition: 0.2s ease;
}

.sidebar nav a:hover {
  background: #fdecea;
  color: #414671;
}

/* Main */
main {
  margin-left: 260px; /* agar konten tidak tertutup sidebar */
  padding: 24px;
}

/* Card */
.card {
  background: #fff;
  border-radius: 12px;
  padding: 24px;
  margin-bottom: 20px;
  margin-left: 40px;
  box-shadow: 0 4px 14px rgba(0,0,0,0.08);
}

/* ========== FORM KHUSUS SUBMIT ABSTRACT ========== */
.form-card {
  max-width: 700px;
  margin: 0 auto;
  padding: 32px;
}

.form-title {
  margin-bottom: 24px;
  font-size: 22px;
  font-weight: 600;
  color: #111827;
  text-align: center;
}

/* Input & Textarea */
.abstract-form .form-group {
  margin-bottom: 20px;
}

.abstract-form input,
.abstract-form textarea {
  width: 100%;
  padding: 14px 16px;
  border: 1px solid #d1d5db;
  border-radius: 8px;
  font-size: 15px;
  font-family: inherit;
  background: #fff;
  transition: border-color 0.2s ease, box-shadow 0.2s ease;
}

.abstract-form input:focus,
.abstract-form textarea:focus {
  border-color: #d32f2f;
  outline: none;
  box-shadow: 0 0 0 3px rgba(211,47,47,0.2);
}

/* Form Group */
.form-group {
  margin-bottom: 16px;
  margin-left: 20px;
  margin-right: 20px;
}

.form-group input[type="text"],
.form-group input[type="file"],
.form-group textarea {
  width: 90%;
  padding: 10px 12px;
  border: 1px solid #ddd;
  border-radius: 8px;
  font-size: 14px;
}

/* Error Alert */
.alert-error {
  background: #fdecea;
  color: #b71c1c;
  padding: 12px;
  border-radius: 6px;
  margin-bottom: 16px;
}


/* Actions (Tombol) */
.form-actions {
  display: flex;
  gap: 14px;
  margin-top: 24px;
}

.btn-secondary {
  background: #e5e7eb;
  color: #333;
}

.btn-secondary:hover {
  background: #d1d5db;
}

/* Alert Error */
.alert-error {
  background: #fdecea;
  padding: 12px 16px;
  border-radius: 6px;
  margin-bottom: 16px;
  color: #b71c1c;
  border: 1px solid #f5c2c7;
}

/* Alert Success */
.alert-success {
  background: #e8f5e9;
  padding: 12px 16px;
  border-radius: 6px;
  margin-bottom: 16px;
  color: #256029;
  border: 1px solid #c8e6c9;
}

/* Table */
.table {
  width: 100%;
  border-collapse: collapse;
  margin-top: 12px;
}
.table th, .table td {
  padding: 10px;
  border-bottom: 1px solid #eee;
  text-align: left;
}
.table thead {
  background: #fdecea;
}

/* Button */
.btn {
  padding: 10px 16px;
  border-radius: 8px;
  font-weight: 500;
  border: none;
  cursor: pointer;
  text-decoration: none;
}
.btn-red {
  background: #d32f2f;
  color: #fff;
}
.btn-red:hover {
  background: #b71c1c;
}

/* ===================== TAMBAHAN UNTUK TABEL LoA ===================== */
.table-container {
  overflow-x: auto;
  margin-top: 16px;
}

/* Perbaiki tampilan tabel agar konsisten */
.table {
  width: 100%;
  border-collapse: collapse;
  font-size: 15px;
  background: #fff;
  border-radius: 12px;
  overflow: hidden;
}

.table thead {
  background: #fdecea;
}

.table th {
  font-weight: 600;
  color: #333;
  padding: 12px 14px;
  text-align: left;
  border-bottom: 2px solid #f0f0f0;
}

.table td {
  padding: 12px 14px;
  border-bottom: 1px solid #f0f0f0;
  color: #444;
}

.table tr:hover {
  background-color: #f9f9f9;
  transition: background 0.2s ease;
}

.table a {
  color: #d32f2f;
  text-decoration: none;
  font-weight: 500;
}

.table a:hover {
  text-decoration: underline;
}

/* Card LoA khusus agar sedikit lega dari card form */
.card-loa {
  margin-top: 24px;
  margin-left: 40px;
  padding: 24px;
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 4px 14px rgba(0,0,0,0.08);
}

.card-loa h3 {
  font-size: 20px;
  font-weight: 600;
  color: #111827;
  margin-bottom: 20px;
  text-align: left;
}

/* =============== MATERIAL PAGE STYLES =============== */

/* Active link highlight */
.sidebar nav a.active {
  /* background: #fdecea;
  color: #d32f2f; */
  background: linear-gradient(90deg, #007bff, #6f42c1);
  color: #fff;
  border-left: 4px solid #00d4ff;
}

/* Heading */
main h2 {
  font-size: 22px;
  font-weight: 600;
  color: #111827;
  margin-bottom: 24px;
}

/* Materi Card */
.materi-card {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 4px 14px rgba(0, 0, 0, 0.08);
  padding: 20px;
  margin-bottom: 20px;
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.materi-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.1);
}

/* Judul */
.materi-title {
  font-size: 18px;
  font-weight: 600;
  color: #111827;
  margin-bottom: 8px;
}

/* Deskripsi */
.materi-desc {
  color: #444;
  line-height: 1.6;
  margin-bottom: 12px;
}

/* Metadata waktu */
.materi-meta {
  font-size: 13px;
  color: #777;
  margin-bottom: 14px;
}

/* Tombol Download */
.btn-download {
  display: inline-block;
  background: #d32f2f;
  color: #fff;
  padding: 10px 16px;
  border-radius: 8px;
  text-decoration: none;
  font-weight: 500;
  transition: background 0.2s ease;
}

.btn-download:hover {
  background: #b71c1c;
}

/* ===========================
   STYLING HALAMAN MATERI
=========================== */

.card-material {
  padding: 32px;
  border-radius: 14px;
  background: #fff;
  box-shadow: 0 6px 18px rgba(0, 0, 0, 0.06);
}

.card-header {
  margin-bottom: 28px;
}

.card-header h2 {
  font-size: 24px;
  font-weight: 600;
  color: #111827;
  margin-bottom: 8px;
}

.card-header .subtitle {
  color: #555;
  font-size: 15px;
}

/* Grid untuk daftar materi */
.materials-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 20px;
}

/* Kartu materi */
.materi-card {
  background: #fff;
  border: 1px solid #e5e7eb;
  border-radius: 12px;
  padding: 20px;
  box-shadow: 0 3px 8px rgba(0,0,0,0.04);
  transition: all 0.2s ease;
}

.materi-card:hover {
  transform: translateY(-3px);
  box-shadow: 0 6px 16px rgba(0,0,0,0.08);
}

/* Header & Deskripsi */
.materi-header h3 {
  font-size: 18px;
  color: #d32f2f;
  font-weight: 600;
  margin: 0;
}

.materi-date {
  font-size: 13px;
  color: #888;
  margin-top: 4px;
}

.materi-desc {
  color: #444;
  line-height: 1.6;
  margin: 16px 0;
  min-height: 60px;
}

/* Footer */
.materi-footer {
  display: flex;
  justify-content: flex-end;
}

/* Empty state */
.empty-state {
  text-align: center;
  padding: 60px 20px;
  color: #666;
}

.empty-state img.empty-icon {
  width: 120px;
  opacity: 0.7;
  margin-bottom: 16px;
}

.card-flow h3 {
  margin-bottom: 16px;
  font-size: 20px;
  font-weight: 600;
  color: #222;
}

.steps {
  display: flex;
  flex-direction: column;
  gap: 16px;
}

.step {
  display: flex;
  align-items: flex-start;
  gap: 12px;
}

.step-number {
  background: #d32f2f;
  color: #fff;
  font-weight: 600;
  width: 28px;
  height: 28px;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  flex-shrink: 0;
  box-shadow: 0 2px 6px rgba(0,0,0,0.1);
}

.step p {
  margin: 0;
  color: #444;
  line-height: 1.5;
}

.step .highlight {
  font-weight: 600;
  color: #d32f2f;
}

/* Profil & Payment */
.profile-card, .payment-card {
  max-width: 700px;
  margin: 20px auto;
  background: #fff;
  padding: 24px;
  border-radius: 12px;
  box-shadow: 0 2px 6px rgba(0,0,0,0.08);
}

.status-badge {
  padding: 4px 10px;
  border-radius: 8px;
  font-weight: 600;
  color: #fff;
}
.status-green { background: #3cb371; }
.status-orange { background: #ff9800; }
.status-red { background: #f44336; }

.payment-info a.btn-view {
  display: inline-block;
  margin-top: 4px;
  padding: 6px 12px;
  background: #0077cc;
  color: white;
  border-radius: 6px;
  text-decoration: none;
}

/* Pengumuman */
.announcement-section {
  max-width: 800px;
  margin: 40px auto;
}
.announcement-card {
  background: #fff;
  padding: 16px 20px;
  border-radius: 12px;
  box-shadow: 0 2px 5px rgba(0,0,0,0.05);
  margin-bottom: 16px;
  border-left: 5px solid #c62828;
}
.announcement-card h3 {
  margin-top: 0;
  color: #c62828;
}
.announce-date {
  font-size: 0.85em;
  color: #777;
}

/* === ABSTRACT FORM STYLING === */
.main-content {
  margin-left: 260px;
  padding: 30px;
  background: #f7f9fb;
  min-height: 100vh;
  font-family: 'Segoe UI', sans-serif;
}

.page-title {
  font-size: 1.8rem;
  color: #333;
  margin-bottom: 20px;
  border-bottom: 2px solid #e74c3c;
  padding-bottom: 5px;
}

.cardabstract {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 3px 10px rgba(0,0,0,0.1);
  padding: 25px 30px;
  max-width: 800px;
  margin: auto;
}

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

.form-group label {
  font-weight: 600;
  display: block;
  margin-bottom: 6px;
  color: #444;
}

.form-group input,
.form-group textarea {
  width: 100%;
  border: 1px solid #ccc;
  border-radius: 8px;
  padding: 10px;
  font-size: 15px;
  outline: none;
  transition: 0.2s;
}

.form-group input:focus,
.form-group textarea:focus {
  border-color: #e74c3c;
  box-shadow: 0 0 3px rgba(231,76,60,0.4);
}

.form-actions {
  margin-top: 20px;
  display: flex;
  gap: 12px;
}

.btn {
  border: none;
  padding: 10px 18px;
  border-radius: 6px;
  cursor: pointer;
  text-decoration: none;
  font-weight: 600;
  transition: 0.3s;
}

.btn-red {
  background: #e74c3c;
  color: #fff;
}

.btn-red:hover {
  background: #c0392b;
}

.btn-secondary {
  background: #bdc3c7;
  color: #333;
}

.btn-secondary:hover {
  background: #95a5a6;
}

.btn-edit {
  background: #c0392b;
  color: white;
  padding: 8px 14px;
  border-radius: 6px;
}

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

.alert {
  padding: 10px;
  border-radius: 6px;
  margin-bottom: 10px;
  font-size: 14px;
}

.alert.success {
  background: #eafaf1;
  border-left: 4px solid #2ecc71;
  color: #2e7d32;
}

.alert.error {
  background: #fdecea;
  border-left: 4px solid #e74c3c;
  color: #c0392b;
}

.abstract-display h3 {
  font-size: 1.5rem;
  color: #222;
  margin-bottom: 10px;
}

.abstract-display p {
  line-height: 1.6;
  color: #555;
}

.abstract-content {
  background: #fafafa;
  border: 1px solid #eee;
  padding: 10px;
  border-radius: 6px;
  margin-top: 8px;
}

/* ==== Submit Full Paper Styling ==== */
.card-container {
  max-width: 900px;
  margin: 10px auto;
  padding: 0 20px
}

.upload-card {
  background: #fff;
  border-radius: 12px;
  box-shadow: 0 4px 16px rgba(0,0,0,0.1);
  padding: 30px;
}

.upload-card h2 {
  color: #000000;
  margin-bottom: 20px;
}

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

.upload-form label {
  font-weight: bold;
  display: block;
  margin-bottom: 8px;
}

.upload-form input[type="text"],
.upload-form input[type="file"] {
  width: 100%;
  padding: 10px;
  border-radius: 8px;
  border: 1px solid #ccc;
  font-size: 15px;
}

.form-actions {
  display: flex;
  gap: 10px;
  justify-content: flex-end;
}

.alert {
  padding: 10px 15px;
  border-radius: 8px;
  margin-bottom: 20px;
}

.alert-success {
  background: #e6ffed;
  color: #2e7d32;
  border: 1px solid #a5d6a7;
}

.alert-error {
  background: #ffebee;
  color: #c62828;
  border: 1px solid #ef9a9a;
}

.paper-info {
  background: #fafafa;
  padding: 20px;
  border-radius: 12px;
  border: 1px solid #ddd;
}

.paper-info h3 {
  color: #222;
}

.pdf-preview {
  margin-top: 20px;
  border: 1px solid #ddd;
  border-radius: 8px;
  overflow: hidden;
}

.btn-link {
  color: #007bff;
  text-decoration: none;
}

.btn-link:hover {
  text-decoration: underline;
}

/* Wrapper untuk custom dropdown */
.custom-select-wrapper {
  position: relative;
  width: 100%;
}

/* Dropdown dasar */
.custom-select-wrapper select {
  width: 100%;
  padding: 10px 40px 10px 12px; /* space untuk panah */
  border: 1px solid #ccc;
  border-radius: 6px;
  background-color: #fff;
  font-size: 16px;
  appearance: none;       /* hilangkan styling default browser */
  -webkit-appearance: none;
  -moz-appearance: none;
  cursor: pointer;
  transition: border-color 0.2s, box-shadow 0.2s;
}

/* Panah custom */
.custom-arrow {
  position: absolute;
  top: 50%;
  right: 12px;
  transform: translateY(-50%);
  pointer-events: none; /* biar klik tetap ke select */
  font-size: 14px;
  color: #555;
}

/* Efek fokus */
.custom-select-wrapper select:focus {
  border-color: #e63946;
  box-shadow: 0 0 5px rgba(230, 57, 70, 0.3);
  outline: none;
}

/* ====== DASHBOARD SUPERADMIN ====== */
.stats-grid {
  display: grid;
  grid-template-columns: repeat(auto-fit, minmax(160px, 1fr));
  gap: 20px;
  margin: 30px 40px;
}

.stat-box {
  background: #fff;
  border-radius: 12px;
  padding: 20px;
  text-align: center;
  box-shadow: 0 3px 10px rgba(0,0,0,0.05);
  transition: transform 0.2s ease, box-shadow 0.2s ease;
}

.stat-box:hover {
  transform: translateY(-4px);
  box-shadow: 0 6px 18px rgba(0,0,0,0.1);
}

.stat-value {
  font-size: 28px;
  font-weight: 700;
  color: #d32f2f;
}

.stat-label {
  color: #555;
  font-size: 15px;
  margin-top: 4px;
}

/* Warna variasi */
.stat-box.verified .stat-value { color: #2e7d32; }
.stat-box.unverified .stat-value { color: #f57c00; }
.stat-box.online .stat-value { color: #1976d2; }
.stat-box.offline .stat-value { color: #6a1b9a; }

/* Peserta Terbaru */
.table-card h3 {
  margin-bottom: 16px;
  font-size: 18px;
  color: #111827;
}

.table-container {
  overflow-x: auto;
}

.status-badge {
  padding: 6px 10px;
  border-radius: 8px;
  font-weight: 600;
  font-size: 13px;
}

.status-verified {
  background: #e8f5e9;
  color: #2e7d32;
}

.status-pending {
  background: #fff3e0;
  color: #ef6c00;
}

/* Responsiveness */
@media (max-width: 768px) {
  .stats-grid {
    margin: 20px;
  }
  .card {
    margin-left: 0;
  }
  main {
    margin-left: 0;
  }
}