/* ============================================================
   project.css  —  Daftar Proyek + File Manager Modal
   Lokasi: get/css/project.css
   ============================================================ */

/* ── Tabel Proyek ──────────────────────────────────────────── */
#projects-table {
  width: 100%;
  border-collapse: collapse;
}

#projects-table th {
  color: var(--get-hover, #c0392b);
  font-size: 0.82rem;
  font-weight: 700;
  letter-spacing: 0.06em;
  text-transform: uppercase;
  padding: 12px 14px;
  border-bottom: 1px solid #2a2a30;
  text-align: left;
  white-space: nowrap;
}

#projects-table td {
  padding: 14px 14px;
  border-bottom: 1px solid rgba(255, 255, 255, 0.04);
  vertical-align: middle;
  font-size: 0.92rem;
  color: var(--get-text, #c8c8d0);
}

#projects-table tbody tr:hover {
  background: rgba(192, 57, 43, 0.05);
}
#projects-table tbody tr:last-child td {
  border-bottom: none;
}
#projects-table td strong {
  font-size: 0.95rem;
}

.status-badge {
  display: inline-block;
  padding: 3px 12px;
  border-radius: 20px;
  font-size: 0.78rem;
  font-weight: 600;
}
.status-aktif {
  background: rgba(34, 197, 94, 0.15);
  color: #1f9d3a;
  border: 1px solid rgba(34, 197, 94, 0.3);
}
.status-selesai {
  background: rgba(192, 57, 43, 0.15);
  color: #c0392b;
  border: 1px solid rgba(192, 57, 43, 0.3);
}
.status-pending {
  background: rgba(251, 191, 36, 0.15);
  color: #f5b21f;
  border: 1px solid rgba(251, 191, 36, 0.3);
}

.btn-action {
  display: inline-flex;
  align-items: center;
  gap: 0.4rem;
  padding: 5px 12px;
  border: none;
  border-radius: 7px;
  font-size: 0.8rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s;
}
.btn-view {
  background: rgba(192, 57, 43, 0.15);
  color: var(--get-hover, #c0392b);
  border: 1px solid rgba(192, 57, 43, 0.3);
}
.btn-view:hover {
  background: var(--get-hover, #c0392b);
  color: #fff;
  transform: translateY(-1px);
  box-shadow: 0 4px 12px rgba(192, 57, 43, 0.3);
}
.btn-delete {
  background: rgba(239, 68, 68, 0.12);
  color: #c0392b;
  border: 1px solid rgba(239, 68, 68, 0.25);
}
.btn-delete:hover {
  background: #c0392b;
  color: #fff;
  transform: translateY(-1px);
}
.actions-column {
  white-space: nowrap;
  text-align: right;
}

/* ════════════════════════════════════════════════════════════
   FILE MANAGER MODAL  (#vpf-modal)
   ════════════════════════════════════════════════════════════ */

#vpf-modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.78);
  z-index: 1000;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  backdrop-filter: blur(4px);
}
#vpf-modal.open {
  display: flex;
}

.vpf-wrap {
  width: max(100%);
  height: max(60%);
  display: flex;
  flex-direction: column;
  background: rgba(6, 10, 60, 0.98);
  border: 1px solid #3a3a3f;
  border-radius: 18px;
  box-shadow: 0 30px 80px rgba(0, 0, 0, 0.7);
  overflow: hidden;
  animation: vpfIn 0.22s ease;
}
@keyframes vpfIn {
  from {
    opacity: 0;
    transform: translateY(-16px) scale(0.97);
  }
  to {
    opacity: 1;
    transform: translateY(0) scale(1);
  }
}

/* Header */
.vpf-head {
  display: flex;
  align-items: center;
  gap: 0.8rem;
  padding: 1.1rem 1.4rem;
  border-bottom: 1px solid #2a2a30;
  flex-shrink: 0;
}
.vpf-head-icon {
  font-size: 1.4rem;
  color: #f5b21f;
}
.vpf-head-info {
  flex: 1;
}
.vpf-head-name {
  font-size: 1.1rem;
  font-weight: 700;
  color: var(--get-text, #c8c8d0);
}
.vpf-head-meta {
  font-size: 0.78rem;
  color: #8c8c92;
  margin-top: 1px;
}
.vpf-close {
  background: none;
  border: none;
  color: #8c8c92;
  font-size: 1.7rem;
  line-height: 1;
  cursor: pointer;
  padding: 0 0.3rem;
  transition: color 0.2s;
}
.vpf-close:hover {
  color: #c0392b;
}

/* Toolbar: breadcrumb + tombol tambah */
.vpf-toolbar {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  padding: 0.6rem 1.4rem;
  border-bottom: 1px solid #1a1a20;
  background: rgba(0, 0, 0, 0.18);
  flex-shrink: 0;
  flex-wrap: wrap;
}
.vpf-breadcrumb {
  display: flex;
  align-items: center;
  gap: 0.3rem;
  flex: 1;
  flex-wrap: wrap;
}
.vpf-bc-btn {
  background: rgba(255, 255, 255, 0.05);
  border: 1px solid #3a3a3f;
  color: #8c8c92;
  padding: 3px 11px;
  border-radius: 20px;
  font-size: 0.78rem;
  cursor: pointer;
  transition: all 0.18s;
  white-space: nowrap;
}
.vpf-bc-btn:hover {
  background: var(--get-hover, #c0392b);
  color: #fff;
  border-color: var(--get-hover, #c0392b);
}
.vpf-bc-sep {
  color: #3a3a3f;
  font-size: 0.85rem;
  user-select: none;
}

/* Tombol di toolbar */
.vpf-tool-btn {
  display: inline-flex;
  align-items: center;
  gap: 0.35rem;
  padding: 5px 13px;
  border-radius: 8px;
  font-size: 0.79rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.18s;
  white-space: nowrap;
  flex-shrink: 0;
  border: 1px solid transparent;
}
.vpf-tool-btn.add-folder {
  background: rgba(251, 191, 36, 0.13);
  color: #f5b21f;
  border-color: rgba(251, 191, 36, 0.35);
}
.vpf-tool-btn.add-folder:hover {
  background: #f5b21f;
  color: #000;
}
.vpf-tool-btn.add-file {
  background: rgba(192, 57, 43, 0.13);
  color: #c0392b;
  border-color: rgba(192, 57, 43, 0.35);
}
.vpf-tool-btn.add-file:hover {
  background: #8b1a1a;
  color: #fff;
}
.vpf-tool-divider {
  width: 1px;
  height: 22px;
  background: #2a2a30;
  flex-shrink: 0;
  margin: 0 2px;
}

/* Body browser */
.vpf-body {
  flex: 1;
  overflow-y: auto;
  padding: 0.3rem 0;
  min-height: 200px;
}
.vpf-body::-webkit-scrollbar {
  width: 5px;
}
.vpf-body::-webkit-scrollbar-track {
  background: transparent;
}
.vpf-body::-webkit-scrollbar-thumb {
  background: #3a3a3f;
  border-radius: 4px;
}

/* Item */
.vpf-item {
  display: flex;
  align-items: center;
  gap: 0.85rem;
  padding: 10px 1.4rem;
  border-bottom: 1px solid rgba(255, 255, 255, 0.03);
  transition: background 0.15s;
}
.vpf-item:last-child {
  border-bottom: none;
}
.vpf-item.is-folder {
  cursor: pointer;
}
.vpf-item:hover {
  background: rgba(192, 57, 43, 0.1);
}

.vpf-item-icon {
  font-size: 1.1rem;
  width: 22px;
  text-align: center;
  flex-shrink: 0;
}
.vpf-ic-folder {
  color: #f5b21f;
}
.vpf-ic-file {
  color: #8c8c92;
}
.vpf-ic-file.py {
  color: #c8c8d0;
}
.vpf-ic-file.js {
  color: #fbd45e;
}
.vpf-ic-file.html {
  color: #c0392b;
}
.vpf-ic-file.css {
  color: #c0392b;
}
.vpf-ic-file.json {
  color: #7adb8e;
}
.vpf-ic-file.md {
  color: #c0392b;
}
.vpf-ic-file.zip {
  color: #f5b21f;
}
.vpf-ic-file.pdf {
  color: #f87171;
}
.vpf-ic-file.png,
.vpf-ic-file.jpg,
.vpf-ic-file.jpeg,
.vpf-ic-file.gif,
.vpf-ic-file.webp {
  color: #1f9d3a;
}

.vpf-item-name {
  flex: 1;
  color: var(--get-text, #c8c8d0);
  font-size: 0.9rem;
  word-break: break-all;
}
.vpf-item-meta {
  color: #6c6c72;
  font-size: 0.78rem;
  white-space: nowrap;
}
.vpf-folder-badge {
  background: rgba(251, 191, 36, 0.13);
  color: #f5b21f;
  padding: 1px 8px;
  border-radius: 10px;
  font-size: 0.72rem;
  white-space: nowrap;
}
.vpf-item-del {
  background: none;
  border: none;
  color: #6c6c72;
  font-size: 0.85rem;
  cursor: pointer;
  padding: 3px 7px;
  border-radius: 5px;
  transition: all 0.18s;
  flex-shrink: 0;
  opacity: 0;
}
.vpf-item:hover .vpf-item-del {
  opacity: 1;
}
.vpf-item-del:hover {
  background: rgba(239, 68, 68, 0.15);
  color: #c0392b;
}

/* States */
.vpf-empty,
.vpf-loading,
.vpf-error {
  text-align: center;
  padding: 3.5rem 1rem;
  color: #6c6c72;
}
.vpf-empty i {
  font-size: 2.5rem;
  display: block;
  margin-bottom: 0.8rem;
  color: #3a3a3f;
}
.vpf-empty p {
  margin: 0 0 0.3rem;
}
.vpf-empty small {
  font-size: 0.8rem;
  color: #6c6c72;
}
.vpf-loading p {
  margin-top: 0.5rem;
  font-size: 0.9rem;
}
.vpf-error {
  color: #c0392b;
}
.vpf-error i {
  font-size: 2rem;
  display: block;
  margin-bottom: 0.5rem;
}

/* ════════════════════════════════════════════════════════════
   SUB-MODAL UPLOAD/TAMBAH  (#vpf-sub-modal)
   ════════════════════════════════════════════════════════════ */

#vpf-sub-modal {
  display: none;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.65);
  z-index: 1100;
  align-items: center;
  justify-content: center;
  padding: 1rem;
  backdrop-filter: blur(3px);
}
#vpf-sub-modal.open {
  display: flex;
}

.vpf-sub-wrap {
  width: min(500px, 96vw);
  background: rgba(5, 8, 55, 0.99);
  border: 1px solid #3a3a3f;
  border-radius: 16px;
  overflow: hidden;
  box-shadow: 0 24px 64px rgba(0, 0, 0, 0.7);
  animation: vpfIn 0.18s ease;
}

.vpf-sub-head {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 1rem 1.3rem;
  border-bottom: 1px solid #2a2a30;
}
.vpf-sub-head h3 {
  margin: 0;
  font-size: 1rem;
  color: var(--get-text, #c8c8d0);
  display: flex;
  align-items: center;
  gap: 0.5rem;
}
.vpf-sub-close {
  background: none;
  border: none;
  color: #8c8c92;
  font-size: 1.5rem;
  cursor: pointer;
  line-height: 1;
  transition: color 0.2s;
}
.vpf-sub-close:hover {
  color: #c0392b;
}

.vpf-sub-body {
  padding: 1.2rem 1.3rem;
  display: flex;
  flex-direction: column;
  gap: 1rem;
}

/* Label field */
.vpf-field-label {
  font-size: 0.8rem;
  font-weight: 600;
  color: #8c8c92;
  letter-spacing: 0.04em;
  text-transform: uppercase;
  margin-bottom: 0.35rem;
  display: block;
}

/* Lokasi selector */
.vpf-loc-box {
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid #3a3a3f;
  border-radius: 9px;
  padding: 0.7rem 1rem;
  display: flex;
  align-items: center;
  gap: 0.6rem;
}
.vpf-loc-box i {
  color: #f5b21f;
  font-size: 0.9rem;
}
.vpf-loc-path {
  color: var(--get-text, #c8c8d0);
  font-size: 0.88rem;
  font-family: monospace;
}

/* Select lokasi tujuan */
.vpf-dest-select {
  width: 100%;
  padding: 10px 14px;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid #3a3a3f;
  border-radius: 9px;
  color: var(--get-text, #c8c8d0);
  font-size: 0.9rem;
  outline: none;
  cursor: pointer;
  transition: border-color 0.2s;
  box-sizing: border-box;
}
.vpf-dest-select:focus {
  border-color: var(--get-hover, #c0392b);
}
.vpf-dest-select option {
  background: #1a1a20;
}

/* Input nama */
.vpf-name-input {
  width: 100%;
  padding: 10px 14px;
  background: rgba(0, 0, 0, 0.3);
  border: 1px solid #3a3a3f;
  border-radius: 9px;
  color: var(--get-text, #c8c8d0);
  font-size: 0.9rem;
  font-family: inherit;
  outline: none;
  box-sizing: border-box;
  transition: border-color 0.2s;
}
.vpf-name-input:focus {
  border-color: var(--get-hover, #c0392b);
}
.vpf-name-input::placeholder {
  color: #6c6c72;
}

/* Drop-zone upload file */
.vpf-dropzone {
  border: 2px dashed #3a3a3f;
  border-radius: 10px;
  padding: 1.6rem 1rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.22s;
  position: relative;
}
.vpf-dropzone:hover,
.vpf-dropzone.drag {
  border-color: var(--get-hover, #c0392b);
  background: rgba(192, 57, 43, 0.05);
}
.vpf-dropzone input[type="file"] {
  position: absolute;
  inset: 0;
  opacity: 0;
  cursor: pointer;
  width: 100%;
  height: 100%;
}
.vpf-dropzone i {
  font-size: 2rem;
  color: var(--get-hover, #c0392b);
  margin-bottom: 0.5rem;
  display: block;
}
.vpf-dropzone p {
  margin: 0;
  color: #8c8c92;
  font-size: 0.88rem;
}
.vpf-dropzone small {
  font-size: 0.78rem;
  color: #6c6c72;
}

/* File terpilih */
.vpf-selected-file {
  display: none;
  align-items: center;
  gap: 0.75rem;
  padding: 0.7rem 1rem;
  background: rgba(192, 57, 43, 0.1);
  border: 1px solid rgba(192, 57, 43, 0.25);
  border-radius: 8px;
}
.vpf-selected-file.show {
  display: flex;
}
.vpf-selected-file i {
  color: var(--get-hover, #c0392b);
  font-size: 1.1rem;
}
.vpf-selected-file span {
  flex: 1;
  font-size: 0.85rem;
  color: var(--get-text, #c8c8d0);
  word-break: break-all;
}
.vpf-file-clear {
  background: none;
  border: none;
  color: #8c8c92;
  cursor: pointer;
  font-size: 1rem;
  transition: color 0.2s;
  padding: 0;
}
.vpf-file-clear:hover {
  color: #c0392b;
}

/* Progress upload */
.vpf-progress {
  display: none;
  flex-direction: column;
  gap: 0.4rem;
}
.vpf-progress.show {
  display: flex;
}
.vpf-progress-bar {
  height: 5px;
  background: rgba(255, 255, 255, 0.08);
  border-radius: 4px;
  overflow: hidden;
}
.vpf-progress-fill {
  height: 100%;
  width: 0%;
  background: linear-gradient(90deg, var(--get-hover, #c0392b), #8b1a1a);
  border-radius: 4px;
  transition: width 0.3s;
}
.vpf-progress-text {
  font-size: 0.78rem;
  color: #8c8c92;
}

/* Footer sub-modal */
.vpf-sub-foot {
  display: flex;
  justify-content: flex-end;
  gap: 0.7rem;
  padding: 0.9rem 1.3rem;
  border-top: 1px solid #2a2a30;
}
.vpf-btn-cancel {
  background: rgba(255, 255, 255, 0.06);
  border: 1px solid #3a3a3f;
  color: #8c8c92;
  padding: 7px 18px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.85rem;
  transition: all 0.2s;
}
.vpf-btn-cancel:hover {
  border-color: #8c8c92;
  color: #fff;
}
.vpf-btn-ok {
  background: var(--get-hover, #c0392b);
  border: none;
  color: #fff;
  padding: 7px 22px;
  border-radius: 8px;
  cursor: pointer;
  font-size: 0.85rem;
  font-weight: 600;
  transition: filter 0.2s;
}
.vpf-btn-ok:hover {
  filter: brightness(1.15);
}
.vpf-btn-ok:disabled {
  opacity: 0.45;
  cursor: not-allowed;
  filter: none;
}
