/* ============================================
   UI COMPONENTS — PROJECTCARS STYLE
   ============================================ */

/* ========== GLASS CARD (blur panel) ========== */
.glass-card {
  backdrop-filter: blur(30px);
  -webkit-backdrop-filter: blur(30px);
  background-color: var(--glass-bg);
  border: 1px solid transparent;
  border-radius: var(--r-lg);
  padding: 1.5rem;
  transition: all 0.3s;
}

.glass-card:hover {
  border-color: var(--accent);
  box-shadow: 0 0 10px 3px var(--accent-glow);
}

.glass-card-no-hover:hover {
  border-color: transparent;
  box-shadow: none;
}

/* ========== CARD GRID ========== */
.card-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(300px, 1fr));
  gap: 6px;
}

/* ========== STATUS BADGE ========== */
.status-badge {
  display: inline-flex;
  align-items: center;
  gap: 6px;
  padding: 4px 12px;
  border-radius: var(--r-full);
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 1px;
}

.status-borrador { background: var(--white-10); color: var(--white-50); }
.status-documentacion { background: var(--info-bg); color: var(--accent); }
.status-pago_pendiente { background: var(--warning-bg); color: var(--warning); }
.status-en_tramite { background: rgba(115, 172, 249, 0.2); color: var(--accent); }
.status-completada { background: var(--success-bg); color: var(--success); }
.status-rechazada { background: var(--error-bg); color: var(--error); }
.status-cancelada { background: var(--white-10); color: var(--white-50); }

/* ========== STEPPER ========== */
.stepper {
  display: flex;
  align-items: center;
  justify-content: center;
  margin-bottom: 2rem;
}

.stepper-step {
  display: flex;
  align-items: center;
  gap: 0.5rem;
}

.stepper-circle {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: 50%;
  display: flex;
  align-items: center;
  justify-content: center;
  font-size: 0.875rem;
  font-weight: 600;
  background: #0a0a0a;
  color: var(--white);
  border: 1px solid rgba(255,255,255,0.15);
  transition: all 0.3s;
}

.stepper-step.active .stepper-circle {
  background: #DC2626;
  color: var(--white);
  border-color: #DC2626;
  box-shadow: 0 0 12px rgba(220,38,38,0.4);
}

.stepper-step.completed .stepper-circle {
  background: #0a0a0a;
  color: var(--success);
  border-color: var(--success);
}

.stepper-label {
  font-size: 0.875rem;
  font-weight: 300;
  color: var(--white-50);
}

.stepper-step.active .stepper-label { color: #DC2626; font-weight: 400; }
.stepper-step.completed .stepper-label { color: var(--success); }

.stepper-line {
  width: 3rem;
  height: 1px;
  background: rgba(255,255,255,0.15);
  margin: 0 0.5rem;
}

.stepper-line.completed { background: #DC2626; }

/* ========== FILE UPLOAD ========== */
.file-drop-zone {
  border: 2px dashed var(--white-20);
  border-radius: var(--r-lg);
  padding: 2rem;
  text-align: center;
  cursor: pointer;
  transition: all 0.3s;
}

.file-drop-zone:hover, .file-drop-zone.dragover {
  border-color: var(--accent);
  background: rgba(115, 172, 249, 0.05);
  box-shadow: 0 0 10px 3px var(--accent-glow);
}

.file-drop-zone i {
  font-size: 2rem;
  color: var(--white-50);
  margin-bottom: 1rem;
}

.file-drop-zone.dragover i { color: var(--accent); }

.file-list { margin-top: 1rem; }

.file-item {
  display: flex;
  align-items: center;
  justify-content: space-between;
  padding: 0.75rem;
  backdrop-filter: blur(30px);
  background: var(--glass-light);
  border-radius: var(--r-md);
  margin-bottom: 6px;
}

.file-item-info { display: flex; align-items: center; gap: 0.75rem; }

.file-item-icon {
  width: 2.5rem;
  height: 2.5rem;
  border-radius: var(--r-sm);
  background: var(--info-bg);
  display: flex;
  align-items: center;
  justify-content: center;
  color: var(--accent);
}

/* ========== TOAST ========== */
#toast-container {
  position: fixed;
  top: 5rem;
  right: 1.5rem;
  z-index: var(--z-toast);
  display: flex;
  flex-direction: column;
  gap: 6px;
}

.toast {
  display: flex;
  align-items: center;
  gap: 0.75rem;
  padding: 0.75rem 1.25rem;
  border-radius: var(--r-md);
  backdrop-filter: blur(30px);
  background: var(--glass-bg);
  min-width: 280px;
  max-width: 420px;
  animation: toastIn 0.3s cubic-bezier(0.165, 0.84, 0.44, 1) forwards;
}

.toast.removing { animation: toastOut 0.3s ease forwards; }

.toast-success { border-left: 3px solid var(--success); }
.toast-error { border-left: 3px solid var(--error); }
.toast-warning { border-left: 3px solid var(--warning); }
.toast-info { border-left: 3px solid var(--accent); }

.toast-message { flex: 1; font-size: 0.9rem; font-weight: 300; }

.toast-close {
  background: none;
  border: none;
  color: var(--white-50);
  cursor: pointer;
  padding: 4px;
  font-size: 1rem;
}

@keyframes toastIn {
  from { opacity: 0; transform: translateX(100px); }
  to { opacity: 1; transform: translateX(0); }
}

@keyframes toastOut {
  from { opacity: 1; transform: translateX(0); }
  to { opacity: 0; transform: translateX(100px); }
}

/* ========== MODAL ========== */
.modal-overlay {
  position: fixed;
  inset: 0;
  background: var(--glass-strong);
  backdrop-filter: blur(8px);
  z-index: var(--z-modal);
  display: flex;
  align-items: center;
  justify-content: center;
  animation: fadeIn 0.2s ease;
}

.modal { max-width: 500px; width: 90%; max-height: 80vh; overflow-y: auto; }

.modal-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 1.25rem;
}

.modal-header h3 { font-size: 1.5rem; font-weight: 400; }

.modal-close {
  background: none;
  border: none;
  color: var(--white-50);
  font-size: 1.2rem;
  cursor: pointer;
}

@keyframes fadeIn { from { opacity: 0; } to { opacity: 1; } }

/* ========== TABLES ========== */
.data-table { width: 100%; border-collapse: collapse; }

.data-table th {
  text-align: left;
  padding: 0.75rem;
  font-size: 0.75rem;
  font-weight: 600;
  text-transform: uppercase;
  letter-spacing: 2px;
  color: var(--white-50);
  border-bottom: 1px solid var(--white-10);
}

.data-table td {
  padding: 0.75rem;
  font-size: 0.9rem;
  font-weight: 300;
  border-bottom: 1px solid var(--white-10);
}

.data-table tr { cursor: pointer; transition: all 0.3s; }
.data-table tr:hover td { background: var(--glass-light); }

/* ========== TRANSFER CARD ========== */
.transfer-card { cursor: pointer; }

.transfer-card:hover {
  transform: translateY(-2px);
  border-color: var(--accent);
  box-shadow: 0 0 15px 3px var(--accent-glow);
}

.transfer-card-header {
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-bottom: 0.75rem;
}

.transfer-reference { font-size: 1.25rem; font-weight: 600; }

.transfer-vehicle {
  display: flex;
  align-items: center;
  gap: 0.5rem;
  color: var(--white-50);
  font-size: 1rem;
  font-weight: 300;
}

.transfer-vehicle i { color: var(--accent); }

.transfer-meta {
  display: flex;
  justify-content: space-between;
  margin-top: 0.75rem;
  font-size: 0.8rem;
  font-weight: 300;
  color: var(--white-50);
}

/* ========== PRICING CARD ========== */
.pricing-card {
  text-align: center;
  position: relative;
  overflow: hidden;
  border: 2px solid transparent;
}

.pricing-card:hover {
  border-color: var(--accent);
  box-shadow: 0 0 20px 5px var(--accent-glow);
}

.pricing-amount {
  font-size: 3.5rem;
  font-weight: 700;
  color: var(--accent);
  margin: 1.5rem 0;
}

.pricing-amount span { font-size: 1.25rem; font-weight: 300; color: var(--white-50); }

.pricing-features { list-style: none; text-align: left; margin: 1.5rem 0; }

.pricing-features li {
  padding: 0.4rem 0;
  display: flex;
  align-items: center;
  gap: 0.75rem;
  color: var(--white);
  font-size: 1rem;
  font-weight: 300;
}

.pricing-features li i { color: var(--accent); font-size: 0.8rem; }

/* ========== TIMELINE ========== */
.timeline { position: relative; padding-left: 30px; }

.timeline::before {
  content: '';
  position: absolute;
  left: 12px;
  top: 0;
  bottom: 0;
  width: 1px;
  background: var(--white-50);
}

.timeline-item { position: relative; padding-bottom: 1.25rem; }

.timeline-dot {
  position: absolute;
  left: -22px;
  width: 10px;
  height: 10px;
  border-radius: 50%;
  background: var(--accent);
}

.timeline-item.completed .timeline-dot { background: var(--success); }
.timeline-item.active .timeline-dot {
  background: var(--accent);
  box-shadow: 0 0 10px var(--accent-glow-strong);
}

.timeline-date { font-size: 0.75rem; color: var(--white-50); font-weight: 300; }
.timeline-content { font-size: 1rem; font-weight: 300; }

/* ========== SKELETON ========== */
.skeleton {
  background: linear-gradient(90deg, var(--glass-light) 25%, var(--glass-bg) 50%, var(--glass-light) 75%);
  background-size: 200% 100%;
  animation: shimmer 1.5s infinite;
  border-radius: var(--r-md);
}

.skeleton-text { height: 16px; margin-bottom: 6px; }
.skeleton-title { height: 24px; width: 60%; margin-bottom: 12px; }
.skeleton-card { height: 200px; }

@keyframes shimmer { 0% { background-position: 200% 0; } 100% { background-position: -200% 0; } }

/* ========== RESPONSIVE ========== */
@media (max-width: 768px) {
  .stepper { flex-wrap: wrap; gap: 0.4rem; }
  .stepper-label { display: none; }
  .stepper-line { width: 1.5rem; }
  .card-grid { grid-template-columns: 1fr; }
  .toast { min-width: auto; max-width: calc(100vw - 2rem); }
}
