.bg-fx {
  position: fixed;
  inset: 0;
  z-index: -1;
  overflow: hidden;
  pointer-events: none;
}

.bg-fx::before {
  content: "";
  position: absolute;
  inset: 0;
  background:
    radial-gradient(
      800px 600px at 15% 10%,
      var(--primary-a15),
      transparent 60%
    ),
    radial-gradient(
      800px 600px at 85% 20%,
      var(--glow-secondary-a30),
      transparent 60%
    ),
    radial-gradient(
      700px 500px at 50% 100%,
      rgba(0, 255, 102, 0.08),
      transparent 60%
    );
}

#vacantes-seccion {
  scroll-margin-top: 12rem;
}

#servicios {
  scroll-margin-top: 12rem;
}

.section-title-vacantes {
  margin-top: 8rem;
  font-size: clamp(2rem, 4vw, 3rem);
  font-weight: 700;
  color: var(--foreground);
}

.hero-desc {
  font-size: 1.125rem;
  color: var(--text-secondary);
  max-width: 228rem;
  line-height: 1.7;
}

.vacantes-grid {
  display: grid;
  grid-template-columns: repeat(auto-fill, minmax(320px, 1fr));
  gap: 28px;
}

.vacante-card {
  position: relative;
  border-radius: 24px;
  padding: 2.5rem 2rem 2rem 2rem;
  background: var(--surface-glass);
  border: 1px solid var(--border);
  backdrop-filter: blur(14px);
  display: flex;
  flex-direction: column;
  min-height: 380px;
  transition: all 0.4s cubic-bezier(0.16, 1, 0.3, 1);
}

.vacante-card:hover {
  transform: translateY(-6px);
  border-color: var(--primary-a50);
  box-shadow: 0 10px 40px -10px var(--primary-a30);
}

.vacante-badge {
  align-self: flex-start;
  background: var(--primary-a15);
  color: var(--primary);
  font-size: 0.75rem;
  font-weight: 700;
  padding: 0.4rem 0.8rem;
  border-radius: 999px;
  border: 1px solid var(--primary-a30);
  text-transform: uppercase;
  letter-spacing: 0.05em;
  margin-bottom: 1.5rem;
}

.vacante-title-wrapper {
  display: flex;
  justify-content: space-between;
  align-items: flex-start;
  gap: 1rem;
  margin-bottom: 1rem;
}

.vacante-title {
  font-size: 1.4rem;
  font-weight: 700;
  color: var(--foreground);
  margin: 0;
  line-height: 1.3;
}

.vacante-spots {
  font-size: 0.8rem;
  font-weight: 600;
  color: var(--primary);
  background: var(--primary-a10);
  padding: 0.25rem 0.65rem;
  border-radius: 999px;
  border: 1px solid var(--primary-a30);
  white-space: nowrap;
  flex-shrink: 0;
  margin-top: 0.2rem;
}

.vacante-meta {
  display: flex;
  flex-wrap: wrap;
  gap: 1rem;
  margin-bottom: 1.5rem;
  font-size: 0.85rem;
  color: var(--muted-fg);
}

.vacante-meta span {
  display: flex;
  align-items: center;
  gap: 0.4rem;
}

.vacante-meta svg {
  width: 16px;
  height: 16px;
  color: var(--primary);
}

.vacante-desc {
  font-size: 0.95rem;
  color: var(--text-secondary);
  line-height: 1.6;
  margin-bottom: 2rem;
  flex-grow: 1;
}

.vacante-card .btn-primary {
  width: 100%;
  text-align: center;
  border: none;
  cursor: pointer;
  background: var(--primary);
  color: var(--background);
  padding: 0.875rem;
  border-radius: 9999px;
  font-weight: 600;
  transition: all 0.3s ease;
  margin-top: auto;
}

.vacante-card .btn-primary:hover {
  box-shadow: 0 0 30px -5px var(--primary-a60);
  transform: scale(1.02);
}

#modal-postulacion,
#modal-verificacion,
#modal-error-custom,
#modal-exito {
  display: none;
  z-index: 100000;
  position: fixed;
  inset: 0;
  background: rgba(0, 0, 0, 0.8);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  align-items: center;
  justify-content: center;
  padding: 20px;
}

#modal-postulacion.show,
#modal-verificacion.show,
#modal-error-custom.show,
#modal-exito.show {
  display: flex !important;
  opacity: 1 !important;
  visibility: visible !important;
  pointer-events: auto !important;
}

.modal-vacante-content {
  width: 100%;
  max-width: 650px;
  max-height: 90vh;
  margin: auto;
  background: var(--surface-glass);
  border: 1px solid var(--primary-a30);
  border-radius: 24px;
  position: relative;
  box-shadow:
    0 20px 60px -10px rgba(0, 0, 0, 0.5),
    0 0 0 1px var(--primary-a30);
  display: flex;
  flex-direction: column;
  overflow: hidden;
}

.modal-sticky-header {
  padding: 2.5rem 4.5rem 1.5rem 2.5rem;
  background: rgba(10, 10, 10, 0.95);
  backdrop-filter: blur(10px);
  -webkit-backdrop-filter: blur(10px);
  border-bottom: 1px solid var(--border);
  position: relative;
  z-index: 20;
  flex-shrink: 0;
}

.modal-scroll-body {
  padding: 1.5rem 2.5rem 2.5rem 2.5rem;
  overflow-y: auto;
  flex: 1;
}

.close-vacante-btn {
  position: absolute;
  top: 20px;
  right: 20px;
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: var(--surface-glass);
  border: 1px solid var(--border);
  color: var(--text-secondary);
  display: flex;
  align-items: center;
  justify-content: center;
  cursor: pointer;
  font-size: 14px;
  transition: all 0.3s ease;
  z-index: 50;
}

.close-vacante-btn:hover {
  color: var(--primary);
  border-color: var(--primary-a30);
  background: var(--primary-a15);
}

#form-postulacion .form-group,
#form-verificacion .form-group {
  margin-bottom: 1.5rem;
}

.error-box {
  background: rgba(255, 60, 60, 0.1);
  border: 1px solid rgba(255, 60, 60, 0.3);
  color: var(--error-color, #ff6b6b);
  padding: 1rem;
  border-radius: 12px;
  margin-bottom: 1.5rem;
  font-size: 0.9rem;
  text-align: center;
}

.loader-container {
  grid-column: 1 / -1;
  display: flex;
  flex-direction: column;
  align-items: center;
  justify-content: center;
  padding: 4rem 0;
  color: var(--muted-fg);
}
.spinner {
  width: 40px;
  height: 40px;
  border: 3px solid var(--primary-a30);
  border-top-color: var(--primary);
  border-radius: 50%;
  animation: spin 1s linear infinite;
  margin-bottom: 1rem;
}

@keyframes spin {
  to {
    transform: rotate(360deg);
  }
}

.modal-scroll-body::-webkit-scrollbar {
  width: 8px;
}
.modal-scroll-body::-webkit-scrollbar-track {
  background: transparent;
}
.modal-scroll-body::-webkit-scrollbar-thumb {
  background-color: var(--border);
  border-radius: 10px;
}

@media (max-width: 768px) {
  .modal-scroll-body {
    padding: 1.5rem 1.5rem 2rem 1.5rem;
  }
  .modal-sticky-header {
    padding: 2rem 3.5rem 1.5rem 1.5rem;
  }
  .modal-vacante-content {
    max-width: 95%;
    max-height: 85vh;
  }
}

.services-section {
  width: 100%;
  max-width: 1100px;
  margin: 0 auto;
  padding: 0 24px 2rem 24px;
  position: relative;
  z-index: 1;
  margin-top: 10rem;
  margin-bottom: 10rem;
}

.services-grid {
  display: grid;
  grid-template-columns: repeat(3, 1fr);
  gap: 20px;
}

.service-card {
  position: relative;
  border-radius: 20px;
  background: rgba(255, 255, 255, 0.02);
  border: 1px solid rgba(255, 255, 255, 0.06);
  transition: all 0.5s cubic-bezier(0.175, 0.885, 0.32, 1.275);
  cursor: pointer;
  overflow: hidden;
  -webkit-tap-highlight-color: transparent;
  outline: none;
}

.service-card:focus,
.service-card:active {
  outline: none;
}

.glow-line {
  position: absolute;
  top: 0;
  left: 0;
  width: 100%;
  height: 2px;
  background: var(--brand-color);
  opacity: 0;
  transition: opacity 0.4s ease;
  box-shadow: 0 0 20px var(--brand-color);
  z-index: 3;
}

.service-card:hover {
  background: rgba(255, 255, 255, 0.04);
  border-color: rgba(255, 255, 255, 0.12);
  transform: translateY(-8px);
  box-shadow: 0 24px 48px -12px rgba(0, 0, 0, 0.5);
}

.service-card:hover .glow-line {
  opacity: 1;
}

.card-inner {
  display: flex;
  flex-direction: column;
  height: 100%;
  position: relative;
  z-index: 2;
}

.card-visual {
  margin: 10px 10px 0 10px;
  height: 160px;
  border-radius: 14px;
  overflow: hidden;
  position: relative;
  background: #000;
}

.card-visual img {
  width: 100%;
  height: 100%;
  object-fit: cover;
  opacity: 0.6;
  filter: grayscale(80%) contrast(1.2);
  transition: all 0.7s cubic-bezier(0.16, 1, 0.3, 1);
}

.service-card:hover .card-visual img {
  opacity: 1;
  filter: grayscale(0%) contrast(1);
  transform: scale(1.08);
}

.glass-icon {
  position: absolute;
  top: 12px;
  right: 12px;
  width: 40px;
  height: 40px;
  background: rgba(10, 10, 12, 0.6);
  backdrop-filter: blur(12px);
  -webkit-backdrop-filter: blur(12px);
  border: 1px solid rgba(255, 255, 255, 0.1);
  border-radius: 10px;
  display: grid;
  place-items: center;
  color: #fff;
  transition: all 0.4s ease;
}

.glass-icon svg {
  width: 20px;
  height: 20px;
}

.service-card:hover .glass-icon {
  background: var(--brand-color);
  color: #000;
  border-color: var(--brand-color);
  transform: scale(1.05) rotate(5deg);
  box-shadow: 0 10px 20px -5px var(--brand-color);
}

/* ESTILOS SI NO HAY IMAGEN  */
.standalone-icon {
  margin: 20px 20px 0 20px;
  width: 50px;
  height: 50px;
  border-radius: 14px;
  background: rgba(255, 255, 255, 0.03);
  border: 1px solid rgba(255, 255, 255, 0.08);
  display: grid;
  place-items: center;
  color: var(--brand-color);
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.standalone-icon svg {
  width: 24px;
  height: 24px;
}

.service-card:hover .standalone-icon {
  background: rgba(255, 255, 255, 0.06);
  border-color: var(--brand-color);
  transform: translateY(-4px) scale(1.05);
  box-shadow: 0 12px 24px -12px var(--brand-color);
}

.card-content {
  padding: 20px;
  display: flex;
  flex-direction: column;
  flex-grow: 1;
  justify-content: space-between;
  position: relative;
}

.card-content::before {
  content: "";
  position: absolute;
  bottom: 0;
  left: 50%;
  transform: translateX(-50%);
  width: 100%;
  height: 100%;
  background: radial-gradient(
    circle at bottom,
    var(--brand-color) 0%,
    transparent 70%
  );
  opacity: 0;
  pointer-events: none;
  transition: opacity 0.5s ease;
  z-index: 0;
}

.service-card:hover .card-content::before {
  opacity: 0.12;
}

.text-wrapper {
  position: relative;
  z-index: 1;
}

.service-title {
  font-size: 1.25rem;
  font-weight: 700;
  color: #fff;
  margin: 0 0 10px 0;
  letter-spacing: -0.01em;
}

.service-desc {
  font-size: 0.9rem;
  color: var(--v-muted, #a1a1aa);
  line-height: 1.5;
  margin: 0;
}

.card-action {
  position: relative;
  z-index: 1;
  display: flex;
  align-items: center;
  justify-content: space-between;
  margin-top: 24px;
  padding-top: 16px;
  border-top: 1px solid rgba(255, 255, 255, 0.05);
}

.action-text {
  font-size: 0.9rem;
  font-weight: 600;
  color: #fff;
  transition: color 0.3s ease;
}

.service-card:hover .action-text {
  color: var(--brand-color);
}

.icon-arrow {
  width: 32px;
  height: 32px;
  border-radius: 50%;
  background: rgba(255, 255, 255, 0.05);
  display: grid;
  place-items: center;
  color: #fff;
  transition: all 0.4s cubic-bezier(0.175, 0.885, 0.32, 1.275);
}

.icon-arrow svg {
  width: 14px;
  height: 14px;
}

.service-card:hover .icon-arrow {
  background: var(--brand-color);
  color: #000;
  transform: translateX(4px);
}

.btn-primary:disabled {
  background: var(--surface-glass);
  color: var(--muted-fg);
  border: 1px solid var(--border);
  cursor: not-allowed;
  opacity: 0.6;
  box-shadow: none;
  transform: none;
}

.btn-primary-lg:disabled {
  background: var(--surface-glass);
  color: var(--muted-fg);
  border: 1px solid var(--border);
  cursor: not-allowed;
  opacity: 0.6;
  box-shadow: none;
  transform: none;
}

.no-scroll {
  overflow: hidden !important;
  height: 100vh !important;
  touch-action: none;
}

.file-upload-wrapper {
  display: flex;
  align-items: center;
  gap: 15px;
  background: var(--surface-glass);
  border: 1px dashed var(--border);
  padding: 8px;
  border-radius: 12px;
  margin-top: 5px;
  transition: all 0.3s ease;
}

.file-upload-wrapper:hover {
  border-color: var(--primary-a50);
}

.file-upload-input {
  position: absolute;
  width: 1px;
  height: 1px;
  padding: 0;
  margin: -1px;
  overflow: hidden;
  clip: rect(0, 0, 0, 0);
  white-space: nowrap;
  border-width: 0;
}

.file-upload-button {
  display: flex;
  align-items: center;
  gap: 8px;
  background: var(--primary-a15);
  color: var(--primary);
  padding: 10px 16px;
  border-radius: 8px;
  font-size: 0.9rem;
  font-weight: 600;
  cursor: pointer;
  transition: all 0.2s ease;
  border: 1px solid transparent;
}

.file-upload-button:hover {
  background: var(--primary-a30);
  border-color: var(--primary);
}

.file-upload-name {
  color: var(--foreground);
  font-size: 0.85rem;
  white-space: nowrap;
  overflow: hidden;
  text-overflow: ellipsis;
  max-width: 200px;
}

.form-group label {
    display: block;
    font-size: 0.75rem;
    font-weight: 500;
    text-transform: uppercase;
    letter-spacing: 0.1em;
    color: var(--foreground);
    margin-bottom: 0.25rem;
}

/* RESPONSIVE DESIGN */
@media (max-width: 1024px) {
  .services-grid {
    grid-template-columns: repeat(2, 1fr);
  }
}

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

  .services-section {
    padding: 0 20px 2rem 20px;
  }
}

@media (max-width: 767px) {
  .hero {
    padding-top: 12rem;
    padding-bottom: 7rem !important;
    height: auto !important;
    text-align: center;
  }

  .hero h1 {
    margin-top: 2rem;
  }

  .section-title {
    margin-top: 1rem;
    font-size: clamp(2rem, 4vw, 3rem);
    font-weight: 700;
    color: var(--foreground);
  }
}